1 2018-12-27 Tom Tromey <tom@tromey.com>
3 * Makefile.in (stamp-init): Remove gdbtypes special case.
5 2018-12-27 John Baldwin <jhb@FreeBSD.org>
7 * config/i386/nm-fbsd.h: Remove file.
8 * Makefile.in (HFILES_NO_SRCDIR): Remove config/i386/nm-fbsd.h.
9 * configure.nat: Remove NAT_FILE for FreeBSD/i386.
11 2018-12-27 Tom Tromey <tom@tromey.com>
13 * minsyms.h (class minimal_symbol_reader): Use
14 DISABLE_COPY_AND_ASSIGN.
16 2018-12-27 Tom Tromey <tom@tromey.com>
18 * python/python.c (python_interactive_command): Use std::string.
19 (gdbpy_parameter): Likewise.
20 * python/py-utils.c (unicode_to_encoded_string): Update comment.
21 * python/py-symtab.c (salpy_str): Use PyString_FromFormat.
22 * python/py-record-btrace.c (recpy_bt_insn_data): Use
24 * python/py-objfile.c (objfpy_get_build_id): Use
26 * python/py-inferior.c (infpy_read_memory): Use
28 * python/py-cmd.c (gdbpy_parse_command_name): Use std::string.
30 2018-12-26 Simon Marchi <simon.marchi@polymtl.ca>
32 * target.c (target_terminal::restore_inferior): Remove struct keyword.
34 2018-12-26 Simon Marchi <simon.marchi@ericsson.com>
36 * build-id.c (build_id_to_debug_bfd): Enhance debug output.
37 * symfile.c (separate_debug_file_exists): Likewise.
39 2018-12-24 Andrew Burgess <andrew.burgess@embecosm.com>
41 * c-exp.y (field_name): Allow DOUBLE_KEYWORD, INT_KEYWORD, LONG,
42 SHORT, SIGNED_KEYWORD, and UNSIGNED tokens to act as a field
44 (typename_stoken): New function.
46 2018-12-24 Andrew Burgess <andrew.burgess@embecosm.com>
48 * c-exp.y (field_name): New %token, and new rule.
49 (exp): Replace uses of 'name' with 'field_name' where appropriate.
51 2018-12-24 Andrew Burgess <andrew.burgess@embecosm.com>
54 * c-exp.y (typebase): Extend the comment.
55 (ident_tokens): Likewise.
57 2018-12-18 Tom Tromey <tom@tromey.com>
59 * dwarf2read.c (dwarf2_find_containing_comp_unit): Don't take
62 2018-12-23 Joel Brobecker <brobecker@adacore.com>
66 2018-12-22 Andrew Burgess <andrew.burgess@embecosm.com>
68 * riscv-tdep.c (riscv_call_arg_struct): Don't adjust size before
70 (riscv_return_value): Take more care not to read/write outside of
71 argument buffer. Cast return value between the declared type and
74 2018-12-22 Andrew Burgess <andrew.burgess@embecosm.com>
76 * riscv-tdep.c (riscv_register_reggroup_p): Save and restore fcsr,
77 fflags, and frm registers.
79 2018-12-22 Andrew Burgess <andrew.burgess@embecosm.com>
81 * riscv-tdep.c (riscv_dwarf_reg_to_regnum): New function.
82 (riscv_gdbarch_init): Register new function with gdbarch.
83 * riscv-tdep.h: New enum to define RISC-V DWARF register numbers.
85 2018-12-21 Simon Marchi <simon.marchi@ericsson.com>
87 * minsyms.c (mst_str): New.
88 (minimal_symbol_reader::record_full): Add debug output.
90 2018-12-21 John Baldwin <jhb@FreeBSD.org>
92 * fbsd-nat.c (fbsd_handle_debug_trap): Require pl.pl_flags to
94 (fbsd_nat_target::stopped_by_sw_breakpoint): Likewise.
96 2018-12-21 Paul Marechal <paul.marechal@ericsson.com>
99 * target.c (target_read_stralloc): Check for empty vector.
101 2018-12-21 Дилян Палаузов <dilyan.palauzov@aegee.org>
103 * top.c (print_gdb_configuration): Print "--without-python"
104 if GDB was configured without Python.
106 2018-12-21 Andrew Burgess <andrew.burgess@embecosm.com>
108 * riscv-tdep.c (riscv_scan_prologue): Use plongest to format
109 a signed offset as a string.
111 2018-12-21 Dave Murphy <davem@devkitpro.org>
113 * dtrace-probe.c (dtrace_static_probe_ops): Explicit zero
115 * probe.c (any_static_probe_ops): Ditto.
116 * record-btrace.c (record_btrace_thread_observer_token): Ditto.
117 * stap-probe.c (stap_static_probe_ops): Ditto.
118 * tui/tui-hooks.c (tui_observers_token): Ditto.
119 * unittests/observable-selftests.c (token1, token2, token3): Ditto.
121 2018-12-19 Andrew Burgess <andrew.burgess@embecosm.com>
123 * gdb/dummy-frame.c (default_dummy_id): Defined new function.
124 * gdb/dummy-frame.h (default_dummy_id): Declare new function.
125 * gdb/frame-unwind.c (default_unwind_pc): Define new function.
126 (default_unwind_sp): Define new function.
127 * gdb/frame-unwind.h (default_unwind_pc): Declare new function.
128 (default_unwind_sp): Declare new function.
129 * gdb/frame.c (frame_unwind_pc): Assume gdbarch_unwind_pc is
131 (get_frame_sp): Assume that gdbarch_unwind_sp is available.
132 * gdb/gdbarch.c: Regenerate.
133 * gdb/gdbarch.h: Regenerate.
134 * gdb/gdbarch.sh: Update definition of dummy_id, unwind_pc, and
135 unwind_sp. Add additional header files to be included in
138 2018-12-19 Dimitar Dimitrov <dimitar@dinux.eu>
140 * nat/linux-ptrace.c (linux_ptrace_test_ret_to_nx): Remove
143 2018-12-17 Andrew Burgess <andrew.burgess@embecosm.com>
145 * dwarf2read.c (struct dwarf2_cu): Convert the fields 'mark',
146 'has_loclist', 'checked_producer', 'producer_is_gxx_lt_4_6',
147 'producer_is_gcc_lt_4_3', 'producer_is_icc_lt_14',
148 'processing_has_namespace_info' from unsigned int to bool. Update
150 (producer_is_icc_lt_14): Update return type.
151 (producer_is_gcc_lt_4_3): Likewise.
152 (producer_is_gxx_lt_4_6): Likewise.
153 (process_die): Write true instead of 1 into predicate fields.
154 (dwarf2_start_symtab): Likewise.
155 (var_decode_location): Likewise.
156 (dwarf2_mark_helper): Likewise.
157 (dwarf2_mark): Likewise.
158 (dwarf2_clear_marks): Write false instead of 0 into predicate
160 (dwarf2_cu::dwarf2_cu): Initialise predicate fields to false, not
163 2018-12-17 Szabolcs Nagy <szabolcs.nagy@arm.com>
165 * nat/aarch64-sve-linux-ptrace.h: Include signal.h instead of
168 2018-12-17 Philippe Waroquiers <philippe.waroquiers@skynet.be>
170 * nat/linux-ptrace.c (kill_child): Fix ARI warning by removing
171 warning trailing new line.
173 2018-12-16 Philippe Waroquiers <philippe.waroquiers@skynet.be>
175 * nat/linux-ptrace.c (kill_child): New function.
176 (linux_ptrace_test_ret_to_nx): Use kill_child instead of local code.
177 Add a call to kill_child in case of early return after fork.
178 (linux_check_ptrace_features): Use kill_child instead of local code.
179 (linux_test_for_tracefork): Likewise.
181 2018-12-14 Tom Tromey <tom@tromey.com>
183 * Makefile.in: Remove "alloca" comment.
185 (local-maintainer-clean): Don't use INFOFILES.
187 2018-12-13 John Baldwin <jhb@FreeBSD.org>
189 * syscalls/update-freebsd.sh: New file.
190 * syscalls/freebsd.xml: Regenerate.
192 2018-12-13 John Baldwin <jhb@FreeBSD.org>
194 * NEWS: Add entry documenting system call aliases.
195 * break-catch-syscall.c (catch_syscall_split_args): Pass 'result'
196 to get_syscalls_by_name.
197 * gdbarch.sh (UNKNOWN_SYSCALL): Remove.
198 * gdbarch.h: Regenerate.
199 * syscalls/gdb-syscalls.dtd (syscall): Add alias attribute.
200 * xml-syscall.c [!HAVE_LIBEXPAT] (get_syscalls_by_name): Rename
201 from get_syscall_by_name. Now accepts a pointer to a vector of
202 integers and returns a bool.
203 [HAVE_LIBEXPAT] (struct syscall_desc): Add alias member.
204 (syscall_create_syscall_desc): Add alias parameter and pass it to
205 syscall_desc constructor.
206 (syscall_start_syscall): Handle alias attribute.
207 (syscall_attr): Add alias attribute.
208 (xml_get_syscalls_by_name): Rename from xml_get_syscall_number.
209 Now accepts a pointer to a vector of integers and returns a
210 bool. Add syscalls whose alias or name matches the requested
212 (get_syscalls_by_name): Rename from get_syscall_by_name. Now
213 accepts a pointer to a vector of integers and returns a bool.
214 * xml-syscall.h (get_syscalls_by_name): Likewise.
216 2018-12-13 John Baldwin <jhb@FreeBSD.org>
218 * break-catch-syscall.c (catch_syscall_split_args): Pass 'result'
219 to get_syscalls_by_group.
220 * xml-syscall.c [!HAVE_LIBEXPAT] (get_syscalls_by_group): Return
222 [HAVE_LIBEXPAT] (xml_list_syscalls_by_group): Append syscall
223 numbers to an existing vector of integers and return a bool.
224 (get_syscalls_by_group): Accept pointer to vector of integers
225 and change return type to bool.
226 * xml-syscall.h (get_syscalls_by_group): Likewise.
228 2018-12-13 Jim Wilson <jimw@sifive.com>
230 * riscv-tdep.c (riscv_print_one_register_info): For MSTATUS, add
231 comment for SD field, and correct xlen calculation. For MISA, add
232 comment for MXL field, add call to register_size, and correct base
235 2018-12-13 Stafford Horne <shorne@gmail.com>
237 * NEWS(New targets): Add or1k*-*-linux*.
239 2018-12-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
241 * nat/linux-osdata.c (linux_xfer_osdata_info_os_types): Forward
242 declare on one line to fix ARI warning.
244 2018-12-12 Andrew Burgess <andrew.burgess@embecosm.com>
246 * infrun.c (infcall_suspend_state::infcall_suspend_state): New.
247 (infcall_suspend_state::registers): New.
248 (infcall_suspend_state::restore): New.
249 (infcall_suspend_state::thread_suspend): Rename to...
250 (infcall_suspend_state::m_thread_suspend): ...this.
251 (infcall_suspend_state::registers): Rename to...
252 (infcall_suspend_state::m_registers): ...this.
253 (infcall_suspend_state::siginfo_gdbarch): Rename to...
254 (infcall_suspend_state::m_siginfo_gdbarch): ...this.
255 (infcall_suspend_state::siginfo_data): Rename to...
256 (infcall_suspend_state::m_siginfo_data): ...this.
257 (save_infcall_suspend_state): Rewrite to use infcall_suspend_state
259 (restore_infcall_suspend_state): Rewrite to use
260 infcall_suspend_state::restore method.
261 (get_infcall_suspend_state_regcache): Use
262 infcall_suspend_state::registers method.
264 2018-12-12 Andrew Burgess <andrew.burgess@embecosm.com>
266 * riscv-tdep.c (riscv_call_arg_scalar_float): Unnamed (variadic)
267 arguments are passed in integer registers.
268 (riscv_call_arg_complex_float): Likewise.
270 2018-12-11 Philippe Waroquiers <philippe.waroquiers@skynet.be>
272 * nat/linux-osdata.c (common_getter): New function.
273 (struct osdata_type): Change getter to take_snapshot.
274 Add LONGEST len_avail and struct buffer buffer.
275 Change all elements in the initializer.
276 Add an element for the list of types.
277 (linux_xfer_osdata_info_os_types): New function.
278 (linux_common_xfer_osdata): Use common_getter for the list of types.
279 Replace getter call by common_getter.
280 (linux_xfer_osdata_cpus): Remove args READBUF, OFFSET, LEN.
281 Add arg BUFFER. Only keep the code that adds data in BUFFER.
282 (linux_xfer_osdata_fds): Likewise.
283 (linux_xfer_osdata_modules): Likewise.
284 (linux_xfer_osdata_msg): Likewise.
285 (linux_xfer_osdata_processes): Likewise.
286 (linux_xfer_osdata_processgroups): Likewise.
287 (linux_xfer_osdata_sem): Likewise.
288 (linux_xfer_osdata_shm): Likewise.
289 (linux_xfer_osdata_isockets): Likewise.
290 (linux_xfer_osdata_threads): Likewise.
292 2018-12-11 Philippe Waroquiers <philippe.waroquiers@skynet.be>
294 * nat/linux-osdata.c: Removed various trailing spaces.
296 2018-12-10 Andrew Burgess <andrew.burgess@embecosm.com>
298 * riscv-tdep.c (riscv_register_name): Fix ARI warning by removing
299 leading whitespace before #include line.
301 2018-12-08 Simon Marchi <simon.marchi@ericsson.com>
302 Дилян Палаузов <dilyan.palauzov@aegee.org>
305 * configure.ac: Search for tgetent in libtinfow.
306 * configure: Re-generate.
308 2018-12-08 Philippe Waroquiers <philippe.waroquiers@skynet.be>
310 * linux-thread-db.c (struct thread_db_info): Add td_ta_delete_p.
311 (thread_db_err_str): Forward declare.
312 (delete_thread_db_info): Call td_ta_delete_p if available.
313 (try_thread_db_load_1): Acquire td_ta_delete address.
314 * nat/gdb_thread_db.h (td_ta_delete_ftype): Declare.
316 2018-12-08 Pedro Alves <palves@redhat.com>
318 * source.c (forward_search_command): Rename to ...
319 (search_command_helper): ... this. Add 'forward' parameter.
320 Tweak to use a gdb::def_vector<char> instead of a xrealloc'ed
321 buffer. Handle backward searches too.
322 (forward_search_command, reverse_search_command): Reimplement by
323 calling search_command_helper.
325 2018-12-07 Andrew Burgess <andrew.burgess@embecosm.com>
327 * .dir-locals.el: Copy most of the settings from c-mode over to
330 2018-12-08 Stafford Horne <shorne@gmail.com>
332 * Makefile.in (ALL_TARGET_OBS): Add or1k-linux-tdep.o.
333 * configure.tgt: Add or1k*-*-linux*.
334 * or1k-linux-tdep.c: New file.
335 * or1k-tdep.c (or1k_gdbarch_init): Call gdbarch_init_osabi.
337 2018-12-07 Pedro Alves <palves@redhat.com>
339 * dwarf2read.c (get_gdb_index_contents_from_section): Use
340 gdb::make_array_view.
342 2018-12-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
344 * language.c (_initialize_language): Fix leak by assigning
345 a static string to language. Same for range and case_sensitive,
346 even if no leak is detected for these variables.
348 2018-12-05 John Baldwin <jhb@FreeBSD.org>
350 * configure: Re-generate.
351 * configure.ac: Use separate sed expressions to escape variables
352 in auto-load directories.
354 2018-12-05 Andrew Burgess <andrew.burgess@embecosm.com>
356 * riscv-tdep.c (riscv_features_from_gdbarch_info): New function.
357 (riscv_find_default_target_description): Use new function to
358 extract feature from gdbarch_info.
359 (riscv_gdbarch_init): Add error checks for xlen and flen between
360 target description and bfd headers. Be smarter about when we
361 think the hardware floating point abi should be used.
363 2018-12-05 Alan Hayward <alan.hayward@arm.com>
365 * nat/aarch64-linux-hw-point.c
366 (aarch64_linux_any_set_debug_regs_state): New function.
367 * nat/aarch64-linux-hw-point.h
368 (aarch64_linux_any_set_debug_regs_state): New declaration.
369 * nat/aarch64-linux.c (aarch64_linux_new_thread): Check if any
372 2018-11-30 John Baldwin <jhb@FreeBSD.org>
374 * common/filestuff.c [HAVE_KINFO_GETFILE]: Include headers.
375 (fdwalk) [HAVE_KINFO_GETFILE]: Use kinfo_getfile.
377 2018-11-30 Philippe Waroquiers <philippe.waroquiers@skynet.be>
378 Simon Marchi <simon.marchi@ericsson.com>
380 * linespec.c (symtab_vector_up): Remove.
381 (symtabs_from_filename): Change return type to std::vector.
382 (collect_symtabs_from_filename): Likewise.
383 (create_sals_line_offset): Assign return value of
384 collect_symtabs_from_filename to *ls->file_symtabs.
385 (convert_explicit_location_to_linespec): Remove call to release.
386 (parse_linespec): Likewise.
387 (symtab_collector) <symtab_collector>: Remove initialization of
389 <release_symtabs>: Change return type to std::vector<symtab *>.
390 <operator ()>: Adjust.
392 2018-11-30 John Baldwin <jhb@FreeBSD.org>
394 * fbsd-nat.c [__FreeBSD_version >= 700009] (USE_SIGINFO): Macro
396 (union sigval32, struct siginfo32, fbsd_siginfo_size)
397 (fbsd_convert_siginfo): Make conditional on USE_SIGINFO instead
398 of KERN_PROC_AUXV and PT_LWPINFO.
399 (fbsd_nat_target::xfer_partial): Define method unconditionally.
400 Make TARGET_OBJECT_SIGNAL_INFO conditional on USE_SIGINFO.
401 Make TARGET_OBJECT_AUXV conditional on KERN_PROC_AUXV.
402 Make TARGET_OBJECT_FREEBSD_VMMAP and
403 TARGET_OBJECT_FREEBSD_PS_STRINGS conditional on KERN_PROC_VMMAP
404 and KERN_PROC_PS_STRINGS.
405 * fbsd-nat.h: Include <sys/proc.h>.
406 (fbsd_nat_target::xfer_partial): Declare method unconditionally.
408 2018-11-30 Andrew Burgess <andrew.burgess@embecosm.com>
410 * riscv-linux-nat.c: Add 'inferior.h' and 'target-descriptions.h'
412 (riscv_linux_nat_target::read_description): New method.
414 2018-11-30 Andrew Burgess <andrew.burgess@embecosm.com>
416 * arch/riscv.h (riscv_gdbarch_features::hash): New method.
417 * arch/riscv.c (struct riscv_gdbarch_features_hasher): New.
418 (riscv_tdesc_cache): New global.
419 (riscv_create_target_description): Look in the cache before
420 creating a new target description.
422 2018-11-30 Andrew Burgess <andrew.burgess@embecosm.com>
424 * arch/riscv.h (riscv_gdb_features::operator==): New.
425 (riscv_gdb_features::operator!=): New.
426 * riscv-tdep.c (riscv_gdbarch_init): Make use of the inequality
429 2018-11-30 Andrew Burgess <andrew.burgess@embecosm.com>
431 * arch/riscv.h (riscv_create_target_description): Make return type
433 * arch/riscv.c (riscv_create_target_description): Likewise.
434 * riscv-tdep.c (riscv_find_default_target_description): Likewise.
436 2018-11-30 Jan Kratochvil <jan.kratochvil@redhat.com>
437 Keith Seitz <keiths@redhat.com>
438 Tom Tromey <tom@tromey.com>
439 Sergio Durigan Junior <sergiodj@redhat.com>
441 https://bugzilla.redhat.com/show_bug.cgi?id=1613614
442 * dwarf2read.c (dwarf2_find_containing_comp_unit): Add
443 'mid_cu->length' to '*cu_off' when checking if 'sect_off' is
446 2018-11-30 Pedro Alves <palves@redhat.com>
448 * aix-thread.c (aix_thread_target) <aix_thread_target>: Delete.
449 <stratum>: New override.
450 * bfd-target.c (aix_thread_target) <aix_thread_target>: Delete.
451 <stratum>: New override.
452 * bsd-uthread.c (bsd_uthread_target) <bsd_uthread_target>: Delete.
453 <stratum>: New override.
454 * exec.c (exec_target) <exec_target>: Delete.
455 <stratum>: New override.
456 * gdbarch-selftests.c (register_to_value_test): Adjust to use the
457 stratum method instead of the to_stratum field.
458 * linux-thread-db.c (thread_db_target) <thread_db_target>: Delete.
459 <stratum>: New override.
460 (thread_db_target::thread_db_target): Delete.
461 * make-target-delegates (print_class): Don't print a ctor
462 declaration. Print a stratum method override declaration.
463 * process-stratum-target.h (process_stratum_target)
464 <process_stratum_target>: Delete.
465 <stratum>: New override.
466 * ravenscar-thread.c (ravenscar_thread_target)
467 <ravenscar_thread_target>: Delete.
468 <stratum>: New override.
469 * record-btrace.c (record_btrace_target)
470 <record_btrace_target>: Delete.
471 <stratum>: New override.
472 * record-full.c (record_full_base_target)
473 <record_full_base_target>: Delete.
474 <stratum>: New override.
475 * record.c (record_disconnect, record_detach)
476 (record_mourn_inferior, record_kill): Adjust to use the stratum
477 method instead of the to_stratum field.
478 * regcache.c (cooked_read_test, cooked_write_test): Likewise.
479 * sol-thread.c (sol_thread_target)
480 <sol_thread_target>: Delete.
481 <stratum>: New override.
482 * spu-multiarch.c (spu_multiarch_target)
483 <spu_multiarch_target>: Delete.
484 <stratum>: New override.
485 * target-delegates.c: Regenerate.
486 * target.c (target_stack::push, target_stack::unpush)
487 (pop_all_targets_above, pop_all_targets_at_and_above)
488 (info_target_command, target_require_runnable)
489 (target_stack::find_beneath): Adjust to use the stratum method
490 instead of the to_stratum field.
491 (dummy_target::dummy_target): Delete.
492 (dummy_target::stratum): New.
493 (debug_target::debug_target): Delete.
494 (debug_target::stratum): New.
495 (maintenance_print_target_stack): Adjust to use the stratum method
496 instead of the to_stratum field.
497 * target.h (struct target_ops) <stratum>: New method.
498 <to_stratum>: Delete.
499 <is_pushed>: Adjust to use the stratum method
500 instead of the to_stratum field.
502 2018-11-30 Pedro Alves <palves@redhat.com>
504 * corelow.c (core_target) <has_all_memory, has_execution>: New
506 * inf-child.c (inf_child_target::has_all_memory)
507 (inf_child_target::has_memory, inf_child_target::has_stack)
508 (inf_child_target::has_registers)
509 (inf_child_target::has_execution): Delete.
510 * inf-child.h (inf_child_target) <has_all_memory, has_memory,
511 has_stack, has_registers, has_execution>: Delete.
512 * process-stratum-target.c
513 (process_stratum_target::has_all_memory)
514 (process_stratum_target::has_memory)
515 (process_stratum_target::has_stack)
516 (process_stratum_target::has_registers)
517 (process_stratum_target::has_execution): New.
518 * process-stratum-target.h (process_stratum_target)
519 <has_all_memory, has_memory, has_stack, has_registers,
520 has_execution>: New method overrides.
521 * ravenscar-thread.c (ravenscar_thread_target) <has_all_memory,
522 has_memory, has_stack, has_registers, has_execution>: Delete.
523 * remote-sim.c (gdbsim_target) <has_stack, has_registers,
524 has_execution>: Delete.
525 * remote.c (remote_target) <has_all_memory, has_memory, has_stack,
526 has_registers, has_execution>: Delete.
527 * target.c (default_child_has_all_memory)
528 (default_child_has_memory, default_child_has_stack)
529 (default_child_has_registers, default_child_has_execution):
531 * target.h (default_child_has_all_memory)
532 (default_child_has_memory, default_child_has_stack)
533 (default_child_has_registers, default_child_has_execution):
535 * tracefile.h (tracefile_target) <has_execution>: New override.
537 2018-11-30 Pedro Alves <palves@redhat.com>
539 * Makefile.in (COMMON_SFILES): Add process-stratum-target.c.
540 * bsd-kvm.c: Include "process-stratum-target.h".
541 (bsd_kvm_target): Now inherits from process_stratum_target.
542 (bsd_kvm_target::bsd_kvm_target): Default it.
543 * corelow.c: Include "process-stratum-target.h".
544 (core_target): Now inherits from process_stratum_target.
545 (core_target::core_target): Don't set to_stratum here.
546 * inf-child.c (inf_child_target::inf_child_target): Delete.
547 * inf-child.h: Include "process-stratum-target.h".
548 (inf_child_target): Inherit from process_stratum_target.
549 (inf_child_target) <inf_child_target>: Default it.
550 <can_async_p, supports_non_stop, supports_disable_randomization>:
552 * process-stratum-target.c: New file.
553 * process-stratum-target.h: New file.
554 * remote-sim.c: Include "process-stratum-target.h".
555 (gdbsim_target): Inherit from process_stratum_target.
556 <gdbsim_target>: Default it.
557 * remote.c: Include "process-stratum-target.h".
558 (remote_target): Inherit from process_stratum_target.
559 <remote_target>: Default it.
560 * target.c (default_thread_address_space)
561 (default_thread_architecture): Delete.
562 * target.h (target_ops) <thread_architecture>: Now returns NULL by
564 <thread_address_space>: Ditto.
565 * test-target.h: Include "process-stratum-target.h" instead of
567 (test_target_ops): Inherit from process_stratum_target.
568 <test_target_ops>: Default it.
569 * tracefile.c (tracefile_target::tracefile_target): Delete.
570 * tracefile.h: Include "process-stratum-target.h".
571 (tracefile_target): Inherit from process_stratum_target.
572 <tracefile_target>: Default it.
573 * target-delegates.c: Regenerate.
575 2018-11-30 Pedro Alves <palves@redhat.com>
577 * Makefile.in (COMMON_SFILES): Add test-target.c.
578 * gdbarch-selftests.c: Include "test-target.h".
579 * regcache.c: Include "test-target.h".
580 * target.c (test_target_info, test_target_ops::info): Move to ...
581 * test-target.c: ... this new file.
582 * target.h (test_target_ops): Move to ...
583 * test-target.h: ... this new file.
585 2018-11-29 Philippe Waroquiers <philippe.waroquiers@skynet.be>
587 * source.c (forward_search_command): Fix leak by using
588 xrealloc even for the first allocation in the loop, as buf
591 2018-11-29 Rajendra SY <rajendra.sy@gmail.com>
594 * gdb/fbsd-tdep.c (fbsd_gdb_signal_from_target)
595 (fbsd_gdb_signal_to_target): New.
596 (fbsd_init_abi): Install gdbarch "signal_from_target" and
597 "signal_to_target" methods.
599 2018-11-29 Tom Tromey <tom@tromey.com>
601 * valarith.c (value_x_unop): Don't set argvec[3].
603 2018-11-26 Simon Marchi <simon.marchi@ericsson.com>
606 * sparc-linux-nat.c (sparc_linux_nat_target): Remove extraneous
609 2018-11-26 Pedro Alves <palves@redhat.com>
611 * procfs.c (procfs_notice_thread): Replace uses of
612 in_thread_list/is_exited with find_thread_ptid/THREAD_EXITED.
613 * sol-thread.c (sol_thread_target::wait)
614 (sol_update_thread_list_callback): Likewise.
616 2018-11-25 Tom Tromey <tom@tromey.com>
618 * ui-out.c (ui_out::field_fmt): Remove comment.
619 * tui/tui-out.c (tui_ui_out::do_field_fmt): Remove comment.
620 * mi/mi-out.c (mi_ui_out::do_field_fmt): Remove comment.
622 2018-11-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
624 * source.c (open_source_file): Leak fixed in '8e6a5953e1d Fix 4K
625 leak in open_source_file' has been partially undone by '2179fbc36d23
626 Return scoped_fd from open_source_file'. Re-add the transfer of
627 current s->fullname to the unique_xmalloc_ptr fullname given
628 to find_and_open_source.
630 2018-11-23 Pedro Alves <palves@redhat.com>
632 * gdbthread.h (enum thread_state): Move comments here.
633 (is_running, is_stopped, is_exited): Remove declarations.
635 2018-11-22 Pedro Alves <palves@redhat.com>
637 * Makefile.in (COMMON_SFILES): Add thread-iter.c.
638 * breakpoint.c (breakpoints_should_be_inserted_now): Replace
639 ALL_NON_EXITED_THREADS with all_non_exited_threads.
640 (print_one_breakpoint_location): Replace ALL_INFERIORS with
642 * bsd-kvm.c: Include inferior.h.
643 * btrace.c (btrace_free_objfile): Replace ALL_NON_EXITED_THREADS
644 with all_non_exited_threads.
645 * common/filtered-iterator.h: New.
646 * common/safe-iterator.h: New.
647 * corelow.c (core_target_open): Don't call init_thread_list here.
648 * darwin-nat.c (thread_info_from_private_thread_info): Replace
649 ALL_THREADS with all_threads.
650 * fbsd-nat.c (fbsd_nat_target::resume): Replace
651 ALL_NON_EXITED_THREADS with inf->non_exited_threads.
652 * fbsd-tdep.c (fbsd_make_corefile_notes): Replace
653 ALL_NON_EXITED_THREADS with inf->non_exited_threads.
654 * fork-child.c (postfork_hook): Don't call init_thread_list here.
655 * gdbarch-selftests.c (register_to_value_test): Adjust.
656 * gdbthread.h: Don't include "inferior.h" here.
657 (struct inferior): Forward declare.
658 (enum step_over_calls_kind): Moved here from inferior.h.
659 (thread_info::deletable): Definition moved to thread.c.
660 (find_thread_ptid (inferior *, ptid_t)): Declare.
661 (ALL_THREADS, ALL_THREADS_BY_INFERIOR, ALL_THREADS_SAFE): Delete.
662 Include "thread-iter.h".
663 (all_threads, all_non_exited_threads, all_threads_safe): New.
664 (any_thread_p): Declare.
665 (thread_list): Delete.
666 * infcmd.c (signal_command): Replace ALL_NON_EXITED_THREADS with
667 all_non_exited_threads.
668 (proceed_after_attach_callback): Delete.
669 (proceed_after_attach): Take an inferior pointer instead of an
670 integer PID. Adjust to use range-for.
671 (attach_post_wait): Pass down inferior pointer instead of pid.
672 Use range-for instead of ALL_NON_EXITED_THREADS.
673 (detach_command): Remove init_thread_list call.
674 * inferior-iter.h: New.
675 * inferior.c (struct delete_thread_of_inferior_arg): Delete.
676 (delete_thread_of_inferior): Delete.
677 (delete_inferior, exit_inferior_1): Use range-for with
678 inf->threads_safe() instead of iterate_over_threads.
679 (inferior_appeared): Call init_thread_list here.
680 (discard_all_inferiors): Use all_non_exited_inferiors.
681 (find_inferior_id, find_inferior_pid): Use all_inferiors.
682 (iterate_over_inferiors): Use all_inferiors_safe.
683 (have_inferiors, number_of_live_inferiors): Use
684 all_non_exited_inferiors.
685 (number_of_inferiors): Use all_inferiors and std::distance.
686 (print_inferior): Use all_inferiors.
687 * inferior.h: Include gdbthread.h.
688 (enum step_over_calls_kind): Moved to gdbthread.h.
689 (struct inferior) <thread_list>: New field.
690 <threads, non_exited_threads, threads_safe>: New methods.
691 (ALL_INFERIORS): Delete.
692 Include "inferior-iter.h".
693 (ALL_NON_EXITED_INFERIORS): Delete.
694 (all_inferiors_safe, all_inferiors, all_non_exited_inferiors): New
696 * inflow.c (child_interrupt, child_pass_ctrlc): Replace
697 ALL_NON_EXITED_THREADS with all_non_exited_threads.
698 * infrun.c (follow_exec): Use all_threads_safe.
699 (clear_proceed_status, proceed): Use all_non_exited_threads.
700 (init_wait_for_inferior): Don't clear inline frame state here.
701 (infrun_thread_stop_requested, for_each_just_stopped_thread): Use
702 all_threads instead of ALL_NON_EXITED_THREADS.
703 (random_pending_event_thread): Use all_non_exited_threads instead
704 of ALL_NON_EXITED_THREADS. Use a lambda for repeated code.
705 (clean_up_just_stopped_threads_fsms): Use all_non_exited_threads
706 instead of ALL_NON_EXITED_THREADS.
707 (handle_no_resumed): Use all_non_exited_threads instead of
708 ALL_NON_EXITED_THREADS. Use all_inferiors instead of
710 (restart_threads, switch_back_to_stepped_thread): Use
711 all_non_exited_threads instead of ALL_NON_EXITED_THREADS.
712 * linux-nat.c (check_zombie_leaders): Replace ALL_INFERIORS with
714 (kill_unfollowed_fork_children): Use inf->non_exited_threads
715 instead of ALL_NON_EXITED_THREADS.
716 * linux-tdep.c (linux_make_corefile_notes): Use
717 inf->non_exited_threads instead of ALL_NON_EXITED_THREADS.
718 * linux-thread-db.c (thread_db_target::update_thread_list):
719 Replace ALL_INFERIORS with all_inferiors.
720 (thread_db_target::thread_handle_to_thread_info): Use
721 inf->non_exited_threads instead of ALL_NON_EXITED_THREADS.
722 * mi/mi-interp.c (multiple_inferiors_p): New.
723 (mi_on_resume_1): Simplify using all_non_exited_threads and
724 multiple_inferiors_p.
725 * mi/mi-main.c (mi_cmd_thread_list_ids): Use all_non_exited_threads
726 instead of ALL_NON_EXITED_THREADS.
727 * nto-procfs.c (nto_procfs_target::open): Don't call
728 init_thread_list here.
729 * record-btrace.c (record_btrace_target_open)
730 (record_btrace_target::stop_recording)
731 (record_btrace_target::close)
732 (record_btrace_target::record_is_replaying)
733 (record_btrace_target::resume, record_btrace_target::wait)
734 (record_btrace_target::record_stop_replaying): Use
735 all_non_exited_threads instead of ALL_NON_EXITED_THREADS.
736 * record-full.c (record_full_wait_1): Use all_non_exited_threads
737 instead of ALL_NON_EXITED_THREADS.
738 * regcache.c (cooked_read_test): Remove reference to global
740 * remote-sim.c (gdbsim_target::create_inferior): Don't call
741 init_thread_list here.
742 * remote.c (remote_target::update_thread_list): Use
743 all_threads_safe instead of ALL_NON_EXITED_THREADS.
744 (remote_target::process_initial_stop_replies): Replace
745 ALL_INFERIORS with all_non_exited_inferiors and use
746 all_non_exited_threads instead of ALL_NON_EXITED_THREADS.
747 (remote_target::open_1): Don't call init_thread_list here.
748 (remote_target::append_pending_thread_resumptions)
749 (remote_target::remote_resume_with_hc): Use all_non_exited_threads
750 instead of ALL_NON_EXITED_THREADS.
751 (remote_target::commit_resume)
752 (remote_target::remove_new_fork_children): Replace ALL_INFERIORS
753 with all_non_exited_inferiors and use all_non_exited_threads
754 instead of ALL_NON_EXITED_THREADS.
755 (remote_target::kill_new_fork_children): Use
756 all_non_exited_threads instead of ALL_NON_EXITED_THREADS. Remove
757 init_thread_list and init_wait_for_inferior calls.
758 (remote_target::remote_btrace_maybe_reopen)
759 (remote_target::thread_handle_to_thread_info): Use
760 all_non_exited_threads instead of ALL_NON_EXITED_THREADS.
761 * target.c (target_terminal::restore_inferior)
762 (target_terminal_is_ours_kind): Replace ALL_INFERIORS with
763 all_non_exited_inferiors.
764 * thread-iter.c: New file.
765 * thread-iter.h: New file.
766 * thread.c: Include "inline-frame.h".
767 (thread_list): Delete.
768 (clear_thread_inferior_resources): Call clear_inline_frame_state.
769 (init_thread_list): Use all_threads_safe instead of
770 ALL_THREADS_SAFE. Adjust to per-inferior thread lists.
771 (new_thread): Adjust to per-inferior thread lists.
772 (add_thread_silent): Pass inferior to find_thread_ptid.
773 (thread_info::deletable): New, moved from the header.
774 (delete_thread_1): Adjust to per-inferior thread lists.
775 (find_thread_global_id): Use inf->threads().
776 (find_thread_ptid): Use find_inferior_ptid and pass inferior to
778 (find_thread_ptid(inferior*, ptid_t)): New overload.
779 (iterate_over_threads): Use all_threads_safe.
781 (thread_count): Use all_threads and std::distance.
782 (live_threads_count): Use all_non_exited_threads and
784 (valid_global_thread_id): Use all_threads.
785 (in_thread_list): Use find_thread_ptid.
786 (first_thread_of_inferior): Adjust to per-inferior thread lists.
787 (any_thread_of_inferior, any_live_thread_of_inferior): Use
788 inf->non_exited_threads().
789 (prune_threads, delete_exited_threads): Use all_threads_safe.
790 (thread_change_ptid): Pass inferior pointer to find_thread_ptid.
791 (set_resumed, set_running): Use all_non_exited_threads.
792 (is_thread_state, is_stopped, is_exited, is_running)
793 (is_executing): Delete.
794 (set_executing, set_stop_requested, finish_thread_state): Use
795 all_non_exited_threads.
796 (print_thread_info_1): Use all_inferiors and all_threads.
797 (thread_apply_all_command): Use all_non_exited_threads.
798 (thread_find_command): Use all_threads.
799 (update_threads_executing): Use all_non_exited_threads.
800 * tid-parse.c (parse_thread_id): Use inf->threads.
801 * x86-bsd-nat.c (x86bsd_dr_set): Use inf->non_exited_threads ().
803 2018-11-22 Pedro Alves <palves@redhat.com>
805 * infrun.c (follow_exec) <set follow-exec new>: Add thread and
806 switch to it before calling into try_open_exec_file.
808 2018-11-22 Pedro Alves <palves@redhat.com>
810 * cli/cli-interp.c (cli_on_user_selected_context_changed): Use
811 inferior_thread instead of find_thread_ptid, and only when
812 inferior_ptid is not null_ptid.
813 * inferior.c (add_inferior): Don't include target_pid_to_str
814 output when the inferior is not started.
815 * python/py-inferior.c (python_on_normal_stop): Don't use
817 (tui_on_user_selected_context_changed): Use inferior_thread
818 instead of find_thread_ptid, and only when inferior_ptid is not
821 2018-11-21 Benno Fünfstück <benno.fuenfstueck@gmail.com>
824 * gdb/python/python.c (execute_gdb_command): Call
825 prevent_dont_repeat earlier to avoid affecting dont_repeat.
827 2018-11-21 Andrew Burgess <andrew.burgess@embecosm.com>
829 * Makefile.in (ALL_TARGET_OBS): Add arch/riscv.o.
830 (HFILES_NO_SRCDIR): Add arch/riscv.h.
831 * arch/riscv.c: New file.
832 * arch/riscv.h: New file.
833 * configure.tgt: Add cpu_obs list of riscv, move riscv-tdep.o into
834 this list, and add arch/riscv.o.
835 * features/Makefile: Add riscv features.
836 * features/riscv/32bit-cpu.c: New file.
837 * features/riscv/32bit-cpu.xml: New file.
838 * features/riscv/32bit-csr.c: New file.
839 * features/riscv/32bit-csr.xml: New file.
840 * features/riscv/32bit-fpu.c: New file.
841 * features/riscv/32bit-fpu.xml: New file.
842 * features/riscv/64bit-cpu.c: New file.
843 * features/riscv/64bit-cpu.xml: New file.
844 * features/riscv/64bit-csr.c: New file.
845 * features/riscv/64bit-csr.xml: New file.
846 * features/riscv/64bit-fpu.c: New file.
847 * features/riscv/64bit-fpu.xml: New file.
848 * features/riscv/rebuild-csr-xml.sh: New file.
849 * riscv-tdep.c: Add 'arch/riscv.h' include.
850 (riscv_gdb_reg_names): Delete.
851 (csr_reggroup): New global.
852 (struct riscv_register_alias): Delete.
853 (struct riscv_register_feature): New structure.
854 (riscv_register_aliases): Delete.
855 (riscv_xreg_feature): New global.
856 (riscv_freg_feature): New global.
857 (riscv_virtual_feature): New global.
858 (riscv_csr_feature): New global.
859 (riscv_create_csr_aliases): New function.
860 (riscv_read_misa_reg): Delete.
861 (riscv_has_feature): Delete.
862 (riscv_isa_xlen): Simplify, just return cached xlen.
863 (riscv_isa_flen): Simplify, just return cached flen.
864 (riscv_has_fp_abi): Update for changes in struct gdbarch_tdep.
865 (riscv_register_name): Update to make use of tdesc_register_name.
866 Look up xreg and freg names in the new globals riscv_xreg_feature
867 and riscv_freg_feature. Don't supply csr aliases here.
868 (riscv_fpreg_q_type): Delete.
869 (riscv_register_type): Use tdesc_register_type in almost all
870 cases, override the returned type in a few specific cases only.
871 (riscv_print_one_register_info): Handle errors reading registers.
872 (riscv_register_reggroup_p): Use tdesc_register_in_reggroup_p for
873 registers that are otherwise unknown to GDB. Also check the
875 (riscv_print_registers_info): Remove assert about upper register
876 number, and use gdbarch_register_reggroup_p instead of
878 (riscv_find_default_target_description): New function.
879 (riscv_check_tdesc_feature): New function.
880 (riscv_add_reggroups): New function.
881 (riscv_setup_register_aliases): New function.
882 (riscv_init_reggroups): New function.
883 (_initialize_riscv_tdep): Add calls to setup CSR aliases, and
884 setup register groups. Register new riscv debug variable.
885 * riscv-tdep.h: Add 'arch/riscv.h' include.
886 (struct gdbarch_tdep): Remove abi union, and add
887 riscv_gdbarch_features field. Remove cached quad floating point
888 type, and provide initialisation for double type field.
889 * target-descriptions.c (maint_print_c_tdesc_cmd): Add riscv to
890 the list of targets using the feature based target descriptions.
891 * NEWS: Mention target description support.
893 2018-11-21 Pedro Alves <palves@redhat.com>
895 * valops.c (find_method_list, value_find_oload_method_list)
896 (find_overload_match, find_oload_champ): Rename parameters and
899 2018-11-21 Pedro Alves <palves@redhat.com>
901 * valops.c (find_method_list): Replace pointer and length
902 parameters with an gdb::array_view. Adjust.
903 (value_find_oload_method_list): Likewise.
904 (find_overload_match): Use gdb::array_view for methods list.
905 Adjust to find_oload_champ interface change.
906 (find_oload_champ): 'xm_worker_vec' parameter now a pointer/array.
907 'num_fns' parameter now a size_t. Eliminate 'fn_count' local.
909 2018-11-21 Pedro Alves <palves@redhat.com>
911 * gdbtypes.c (compare_badness): Change type of parameters to const
912 reference. Adjust to badness_vector being a std::vector now.
913 (rank_function): Adjust to badness_vector being a std::vector now.
914 * gdbtypes.h (badness_vector): Now a typedef to std::vector.
915 (LENGTH_MATCH): Delete.
916 (compare_badness): Change type of parameters to const reference.
917 (rank_function): Return a badness_vector by value now.
918 (find_overload_match): Adjust to badness_vector being a
919 std::vector now. Remove cleanups.
920 (find_oload_champ_namespace): 'oload_champ_bv' parameter now a
921 badness_vector pointer.
922 (find_oload_champ_namespace_loop): 'oload_champ_bv' parameter now
923 a badness_vector pointer. Adjust to badness_vector being a
924 std::vector now. Remove cleanups.
925 (find_oload_champ): 'oload_champ_bv' parameter now
926 a badness_vector pointer. Adjust to badness_vector being a
927 std::vector now. Remove cleanups.
929 2018-11-21 Pedro Alves <palves@redhat.com>
931 * cp-support.c (sym_return_val_size, sym_return_val_index)
932 (sym_return_val): Delete.
933 (overload_list_add_symbol): Add std::vector parameter. Adjust to
935 (make_symbol_overload_list): Adjust to return a std::vector
936 instead of maintaining a global open coded vector.
937 (make_symbol_overload_list_block): Add std::vector parameter.
938 (make_symbol_overload_list_block): Rename to ...
939 (add_symbol_overload_list_block): ... this and add std::vector
941 (make_symbol_overload_list_namespace): Rename to ...
942 (add_symbol_overload_list_namespace): ... this and add std::vector
944 (make_symbol_overload_list_adl_namespace): Rename to ...
945 (add_symbol_overload_list_adl_namespace): ... this and add
946 std::vector parameter.
947 (make_symbol_overload_list_adl): Delete.
948 (add_symbol_overload_list_adl): New.
949 (make_symbol_overload_list_using): Rename to ...
950 (add_symbol_overload_list_using): ... this and add std::vector
952 (make_symbol_overload_list_qualified): Rename to ...
953 (add_symbol_overload_list_qualified): ... this and add std::vector
955 * cp-support.h: Include "common/array-view.h" and <vector>.
956 (make_symbol_overload_list): Change return type to std::vector.
957 (make_symbol_overload_list_adl): Delete declaration.
958 (add_symbol_overload_list_adl): New declaration.
959 * valops.c (find_overload_match): Local 'oload_syms' now a
961 (find_oload_champ_namespace): 'oload_syms' parameter now a
963 (find_oload_champ_namespace_loop): 'oload_syms' parameter now a
964 std::vector pointer. Adjust to new make_symbol_overload_list
967 2018-11-21 Pedro Alves <palves@redhat.com>
969 * common/array-view.h (array_view::splice(size_type, size_t)): New.
970 (array_view::splice(size_type)): New.
971 * eval.c (eval_call, evaluate_funcall): Adjust to use array_view.
972 * extension.c (xmethod_worker::get_arg_types): Adjust to return an
974 (xmethod_worker::get_result_type): Adjust to use gdb::array_view.
975 * extension.h: Include "common/array-view.h".
976 (xmethod_worker::invoke): Adjust to use gdb::array_view.
977 (xmethod_worker::get_arg_types): Adjust to return an std::vector.
978 (xmethod_worker::get_result_type): Adjust to use gdb::array_view.
979 (xmethod_worker::do_get_arg_types): Adjust to use std::vector.
980 (xmethod_worker::do_get_result_type): Adjust to use
982 * gdbtypes.c (rank_function): Adjust to use gdb::array_view.
983 * gdbtypes.h: Include "common/array-view.h".
984 (rank_function): Adjust to use gdb::array_view.
985 * python/py-xmethods.c (python_xmethod_worker::invoke)
986 (python_xmethod_worker::do_get_arg_types)
987 (python_xmethod_worker::do_get_result_type)
988 (python_xmethod_worker::invoke): Adjust to new interfaces.
989 * valarith.c (value_user_defined_cpp_op, value_user_defined_op)
990 (value_x_binop, value_x_unop): Adjust to use gdb::array_view.
991 * valops.c (find_overload_match, find_oload_champ_namespace)
992 (find_oload_champ_namespace_loop, find_oload_champ): Adjust to use
993 gdb:array_view and the new xmethod_worker interfaces.
994 * value.c (result_type_of_xmethod, call_xmethod): Adjust to use
996 * value.h (find_overload_match, result_type_of_xmethod)
997 (call_xmethod): Adjust to use gdb::array_view.
998 * unittests/array-view-selftests.c: Add slicing tests.
1000 2018-11-21 Pedro Alves <palves@redhat.com>
1002 * ada-lang.c (ada_evaluate_subexp): Adjust to pass an array_view.
1003 * common/array-view.h (make_array_view): New.
1004 * compile/compile-object-run.c (compile_object_run): Adjust to
1006 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust.
1007 * eval.c (eval_call): Adjust to pass an array_view.
1008 (evaluate_subexp_standard): Adjust to pass an array_view.
1009 * gcore.c (call_target_sbrk): Adjust to pass an array_view.
1010 * guile/scm-value.c (gdbscm_value_call): Likewise.
1011 * infcall.c (push_dummy_code): Replace pointer + size parameters
1012 with an array_view parameter.
1013 (call_function_by_hand, call_function_by_hand_dummy): Likewise and
1015 * infcall.h: Include "common/array-view.h".
1016 (call_function_by_hand, call_function_by_hand_dummy): Replace
1017 pointer + size parameters with an array_view parameter.
1018 * linux-fork.c (inferior_call_waitpid): Adjust to use array_view.
1019 * linux-tdep.c (linux_infcall_mmap): Likewise.
1020 * objc-lang.c (lookup_objc_class, lookup_child_selector)
1021 (value_nsstring, print_object_command): Likewise.
1022 * python/py-value.c (valpy_call): Likewise.
1023 * rust-lang.c (rust_evaluate_funcall): Likewise.
1024 * spu-tdep.c (flush_ea_cache): Likewise.
1025 * valarith.c (value_x_binop, value_x_unop): Likewise.
1026 * valops.c (value_allocate_space_in_inferior): Likewise.
1027 * unittests/array-view-selftests.c (run_tests): Add
1028 gdb::make_array_view test.
1030 2018-11-20 Andrew Burgess <andrew.burgess@embecosm.com>
1032 * cli-out.c (cli_ui_out::do_field_int): Use string_printf rather
1033 than a fixed size buffer.
1035 2018-11-20 Andrew Burgess <andrew.burgess@embecosm.com>
1037 * breakpoint.c (print_one_breakpoint_location): Reduce whitespace,
1038 and remove insertion of extra spaces in GDB's output.
1039 * cli-out.c (cli_ui_out::do_field_fmt): Update header comment.
1040 Layout field into a temporary buffer, and then output it as a
1043 2018-11-20 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1045 * NEWS: Document the language choice done by
1046 'info [types|functions|variables]|rbreak'.
1048 2018-11-20 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1050 * symtab.c (treg_matches_sym_type_name): Use
1051 scoped_switch_to_sym_language_if_auto instead of local logic.
1052 (print_symbol_info): Use scoped_switch_to_sym_language_if_auto
1053 to switch to SYM language when language mode is auto.
1055 2018-11-20 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1057 * language.h (scoped_switch_to_sym_language_if_auto): New class.
1059 2018-11-20 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1061 * symtab.c (search_symbols): Properly check absence of type regexp
1062 before entering the loop scanning the minimal symbols.
1064 2018-11-20 John Darrington <john@darrington.wattle.id.au>
1066 * s12z-tdep.c (s12z_extract_return_value): New function.
1067 (inv_reg_perm) New array.
1068 (s12z_return_value): Populate readbuf if non-null.
1070 2018-11-20 Eli Zaretskii <eliz@gnu.org>
1072 * common/filestuff.c (gdb_fopen_cloexec): Disable use of "e" mode
1073 with 'fopen' also if O_CLOEXEC is equal to O_NOINHERIT, to cater
1074 to MinGW fixed by Gnulib.
1075 (O_NOINHERIT): Define if not defined.
1077 2018-11-19 John Darrington <john@darrington.wattle.id.au>
1079 * s12z-tdep.c (s12z_frame_cache): Add an assertion.
1081 2018-11-19 Simon Marchi <simon.marchi@polymtl.ca>
1083 * infrun.c (displaced_step_inferior_state) <next>: Remove.
1085 2018-11-19 Tom Tromey <tom@tromey.com>
1087 * source.c (get_filename_and_charpos): Return void.
1089 2018-11-19 Simon Marchi <simon.marchi@polymtl.ca>
1091 * skip.c (_initialize_step_skip): Fix "info skip" help.
1093 2018-11-16 Tom Tromey <tom@tromey.com>
1096 * rust-lang.c (rust_internal_print_type): Handle TYPE_CODE_PTR.
1098 2018-11-19 Simon Marchi <simon.marchi@ericsson.com>
1100 * infrun.c (displaced_step_inferior_states): Change type to
1102 (get_displaced_stepping_state): Adjust.
1103 (displaced_step_in_progress_any_inferior): Adjust.
1104 (add_displaced_stepping_state): Adjust.
1105 (remove_displaced_stepping_state): Adjust.
1107 2018-11-18 Tom Tromey <tom@tromey.com>
1110 * target-delegates.c: Rebuild.
1111 * ia64-linux-nat.c (class ia64_linux_nat_target)
1112 <have_steppable_watchpoint>: Use override. Return true, not 1.
1113 (ia64_linux_nat_target::can_use_hw_breakpoint): Rename. Remove
1115 (ia64_linux_nat_target::low_new_thread): Rename.
1116 (class ia64_linux_nat_target) <read_description>: Don't declare.
1117 * target.h (struct target_ops) <have_steppable_watchpoint>: Return
1120 2018-11-16 Alan Hayward <alan.hayward@arm.com>
1123 * aarch64-tdep.c (aarch64_push_dummy_call): Remove
1124 lang_struct_return code.
1126 2018-11-16 Alan Hayward <alan.hayward@arm.com>
1128 * aarch64-tdep.c (aarch64_push_dummy_call): Replace arg with
1130 * alpha-tdep.c (alpha_push_dummy_call): Likewise.
1131 * amd64-tdep.c (amd64_push_arguments): Likewise.
1132 (amd64_push_dummy_call): Likewise.
1133 * amd64-windows-tdep.c (amd64_windows_push_arguments): Likewise.
1134 * arc-tdep.c (arc_push_dummy_call): Likewise.
1135 * arm-tdep.c (arm_push_dummy_call): Likewise.
1136 * avr-tdep.c (avr_push_dummy_call): Likewise.
1137 * bfin-tdep.c (bfin_push_dummy_call): Likewise.
1138 * cris-tdep.c (cris_push_dummy_call): Likewise.
1139 * csky-tdep.c (csky_push_dummy_call): Likewise.
1140 * frv-tdep.c (frv_push_dummy_call): Likewise.
1141 * gdbarch.c: Regenerate.
1142 * gdbarch.h: Regenerate.
1143 * gdbarch.sh (gdbarch_push_dummy_call): Replace arg with
1145 * h8300-tdep.c (h8300_push_dummy_call): Likewise.
1146 * hppa-tdep.c (hppa32_push_dummy_call): Likewise.
1147 (hppa64_push_dummy_call): Likewise.
1148 * i386-darwin-tdep.c (i386_darwin_push_dummy_call): Likewise.
1149 * i386-tdep.c (i386_push_dummy_call): Likewise.
1150 * ia64-tdep.c (ia64_push_dummy_call): Likewise.
1151 * infcall.c (call_function_by_hand_dummy): Likewise.
1152 * iq2000-tdep.c (iq2000_push_dummy_call): Likewise.
1153 * lm32-tdep.c (lm32_push_dummy_call): Likewise.
1154 * m32c-tdep.c (m32c_push_dummy_call): Likewise.
1155 * m32r-tdep.c (m32r_push_dummy_call): Likewise.
1156 * m68hc11-tdep.c (m68hc11_push_dummy_call): Likewise.
1157 * m68k-tdep.c (m68k_push_dummy_call): Likewise.
1158 * mep-tdep.c (mep_push_dummy_call): Likewise.
1159 * mips-tdep.c (mips_eabi_push_dummy_call): Likewise.
1160 (mips_n32n64_push_dummy_call): Likewise.
1161 (mips_o32_push_dummy_call): Likewise.
1162 (mips_o64_push_dummy_call): Likewise.
1163 * mn10300-tdep.c (mn10300_push_dummy_call): Likewise.
1164 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
1165 * nds32-tdep.c (nds32_push_dummy_call): Likewise.
1166 * nios2-tdep.c (nios2_push_dummy_call): Likewise.
1167 * or1k-tdep.c (or1k_push_dummy_call): Likewise.
1168 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
1169 (ppc64_sysv_abi_push_dummy_call): Likewise.
1170 * ppc-tdep.h (ppc_sysv_abi_push_dummy_call): Likewise.
1171 (ppc64_sysv_abi_push_dummy_call): Likewise.
1172 * riscv-tdep.c (riscv_push_dummy_call): Likewise.
1173 * rl78-tdep.c (rl78_push_dummy_call): Likewise.
1174 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
1175 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
1176 * rx-tdep.c (rx_push_dummy_call): Likewise.
1177 * s390-tdep.c (s390_push_dummy_call): Likewise.
1178 * score-tdep.c (score_push_dummy_call): Likewise.
1179 * sh-tdep.c (sh_push_dummy_call_fpu): Likewise.
1180 (sh_push_dummy_call_nofpu): Likewise.
1181 * sparc-tdep.c (sparc32_store_arguments): Likewise.
1182 (sparc32_push_dummy_call): Likewise.
1183 * sparc64-tdep.c (sparc64_store_arguments): Likewise.
1184 (sparc64_push_dummy_call): Likewise.
1185 * spu-tdep.c (spu_push_dummy_call): Likewise.
1186 * tic6x-tdep.c (tic6x_push_dummy_call): Likewise.
1187 * tilegx-tdep.c (tilegx_push_dummy_call): Likewise.
1188 * v850-tdep.c (v850_push_dummy_call): Likewise.
1189 * vax-tdep.c (vax_push_dummy_call): Likewise.
1190 * xstormy16-tdep.c (xstormy16_push_dummy_call): Likewise.
1191 * xtensa-tdep.c (xtensa_push_dummy_call): Likewise.
1193 2018-11-16 Alan Hayward <alan.hayward@arm.com>
1195 * gdbarch.sh (enum function_call_return_method): Add enum.
1196 * gdbarch.h: Regenerate.
1197 * infcall.c (call_function_by_hand_dummy): Replace vars with enum.
1199 2018-11-15 Joel Brobecker <brobecker@adacore.com>
1201 * unittests/copy_bitwise-selftests.c: New file.
1202 * utils.c (selftests::bits_to_str, selftests::check_copy_bitwise)
1203 (selftests::copy_bitwise_tests): Delete, moving this code to
1204 unittests/copy_bitwise-selftests.c instead.
1205 (_initialize_utils): Do not register copy_bitwise tests.
1206 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1207 unittests/copy_bitwise-selftests.c.
1209 2018-11-14 Joel Brobecker <brobecker@adacore.com>
1211 * ada-lang.c (move_bits): Delete. Update all callers to use
1212 copy_bitwise instead.
1213 * dwarf2loc.c (copy_bitwise, bits_to_str::bits_to_str)
1214 (selftests::check_copy_bitwise, selftests::copy_bitwise_tests):
1215 Move from here to utils.c.
1216 (_initialize_dwarf2loc): Remove call to register copy_bitwise
1218 * utils.h (copy_bitwise): Add declaration.
1219 * utils.c (copy_bitwise, bits_to_str::bits_to_str)
1220 (selftests::check_copy_bitwise, selftests::copy_bitwise_tests):
1221 Moved here from dwarf2loc.c.
1222 (_initialize_utils): Register copy_bitwise selftests.
1224 2018-11-14 Jim Wilson <jimw@sifive.com>
1226 * riscv-tdep.c (struct riscv_arg_info): New field is_unnamed.
1227 (riscv_call_arg_scalar_int): If unnamed arg with twice xlen alignment,
1228 then increment next_regnum if odd.
1229 (riscv_arg_location): New arg is_unnamed. Set ainfo->is_unnamed.
1230 (riscv_push_dummy_call): New local ftype. Call check_typedef to set
1231 function type. Pass new arg to riscv_arg_location based on function
1233 (riscv_return_value): Pass new arg to riscv_arg_location.
1235 * riscv-tdep.c (BIGGEST_ALIGNMENT): New.
1236 (riscv_type_alignment) <TYPE_CODE_ARRAY>: If TYPE_VECTOR, return min
1237 of TYPE_LENGTH and BIGGEST_ALIGNMENT.
1239 * riscv-tdep.c (riscv_call_arg_scalar_int): Use std::min when
1240 setting len. New local align, set to max of arg align and xlen,
1241 and pass to first riscv_assign_stack_location call.
1243 2018-11-12 Simon Marchi <simon.marchi@polymtl.ca>
1245 * skip.c (complete_skip_number): New function.
1246 (_initialize_step_skip): Add completers to some skip commands.
1248 2018-11-09 Tom Tromey <tom@tromey.com>
1250 * remote.c (remote_g_packet_guess_s): Remove typedef and DEF_VEC.
1251 (struct remote_g_packet_data): Derive from allocate_on_obstack.
1252 <guesses>: Now a std::vector.
1253 (remote_g_packet_data_init, register_remote_g_packet_guess):
1255 (remote_read_description_p): Update. Return bool.
1256 (remote_target::read_description): Update.
1257 (struct remote_g_packet_guess): Add constructor.
1259 2018-11-09 Tom Tromey <tom@tromey.com>
1261 * common/scoped_fd.h (class scoped_fd): Add move constructor and
1262 move assignment operator.
1263 * psymtab.c (psymtab_to_fullname): Update.
1264 * source.h (open_source_file): Return scoped_fd.
1265 (find_and_open_source): Likewise.
1266 * source.c (open_source_file): Return scoped_fd.
1267 (get_filename_and_charpos): Update.
1268 (print_source_lines_base): Update. Use scoped_fd::to_file.
1269 (forward_search_command): Likewise.
1270 (reverse_search_command): Likewise.
1271 (find_and_open_source): Return scoped_fd.
1272 * tui/tui-source.c (tui_set_source_content): Update. Use
1275 2018-11-09 John Baldwin <jhb@FreeBSD.org>
1277 * minsyms.c (minimal_symbol_reader::install): Fix unsigned
1280 2018-11-09 Hafiz Abid Qadeer <abidh@codesourcery.com>
1282 * configure: Regenerate.
1284 2018-11-09 Tom de Vries <tdevries@suse.de>
1286 * symtab.c (symbol_set_names): Call symbol_find_demangled_name
1287 unconditionally, to set the language of the symbol. Manage freeing
1288 returned pointer using gdb::unique_xmalloc_ptr.
1290 2018-11-08 Tom Tromey <tom@tromey.com>
1292 * record.c (require_record_target): Upper-case "<TAB>".
1294 2018-11-08 Tom Tromey <tom@tromey.com>
1296 * python/lib/gdb/command/pretty_printers.py
1297 (InfoPrettyPrinter.invoke): Don't indent "objfile" heading.
1299 2018-11-08 Tom Tromey <tom@tromey.com>
1303 * target.h (target_supports_terminal_ours): Return bool.
1304 * target.c (target_supports_terminal_ours): Handle case where
1305 current_top_target returns nullptr. Return bool.
1307 2018-11-08 Joel Brobecker <brobecker@adacore.com>
1309 * aarch64-tdep.c (aapcs_is_vfp_call_or_return_candidate_1):
1310 return the correct count for potential HFAs.
1312 2018-11-08 Jan Beulich <jbeulich@suse.com>
1314 * i387-tdep.c (i387_supply_xsave): Split handling of
1315 X86_XSTATE_ZMM_H and X86_XSTATE_ZMM.
1316 (i387_collect_xsave): Likewise.
1318 2018-11-08 Andrew Burgess <andrew.burgess@embecosm.com>
1320 * riscv-tdep.c (riscv_insn::decode): Update header comment.
1321 (riscv_frame_this_id): Catch errors thrown while building the
1322 frame cache, leave the frame id as the default, which is the outer
1325 2018-11-07 Joel Brobecker <brobecker@adacore.com>
1327 * ada-lang.c (read_atcb): Only set task_info->called_task if
1328 task_info->state == Entry_Caller_Sleep.
1329 (print_ada_task_info): Do not check task_info->state before
1330 checking task_info->called_task.
1331 (info_task): Likewise.
1333 2018-11-07 Joel Brobecker <brobecker@adacore.com>
1335 * ada-tasks.c (read_atcb): Clear task_info before computing
1336 the value of each of its fields.
1338 2018-11-07 Andrew Burgess <andrew.burgess@embecosm.com>
1340 * dwarf2read.c (dwarf2_init_integer_type): Check for name being
1341 NULL before dereferencing it.
1343 2018-11-06 Tom de Vries <tdevries@suse.de>
1345 * linux-tdep.c (linux_vsyscall_range_raw): Use xmalloc to allocate
1348 2018-11-06 Max Filippov <jcmvbkbc@gmail.com>
1350 * configure.tgt (xtensa*-*-linux*): Change to xtensa*-*-*linux*
1351 so that it applies to uclinux as well.
1353 2018-11-06 Marius Muench <marius.muench@eurecom.fr>
1355 * arm-tdep.c (arm_scan_prologue): Don't dereference FP reg
1358 2018-11-06 John Baldwin <jhb@FreeBSD.org>
1360 * riscv-fbsd-nat.c (getregs_supplies): Return true for
1361 RISCV_CSR_SSTATUS_REGNUM.
1363 2018-11-04 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1365 * source.c (open_source_file): Fix leak by transferring the
1366 current s->fullname to the unique_xmalloc_ptr fullname given
1367 to find_and_open_source.
1369 2018-11-04 Tom Tromey <tom@tromey.com>
1371 * varobj.c (install_default_visualizer): Update.
1372 * python/python-internal.h (gdbpy_get_varobj_pretty_printer):
1374 * python/py-prettyprint.c (search_pp_list): Return gdbpy_ref.
1375 (find_pretty_printer_from_progspace)
1376 (find_pretty_printer_from_gdb, find_pretty_printer)
1377 (gdbpy_get_varobj_pretty_printer): Return gdbpy_ref.
1378 (gdbpy_get_varobj_pretty_printer, gdbpy_default_visualizer):
1381 2018-11-04 Tom Tromey <tom@tromey.com>
1383 * python/python.c (gdbpy_parameter_value): Update.
1384 * python/python-internal.h (python_string_to_unicode)
1385 (python_string_to_target_python_string)
1386 (host_string_to_python_string): Return gdbpy_ref.
1387 * python/py-utils.c (python_string_to_unicode)
1388 (unicode_to_encoded_python_string)
1389 (unicode_to_target_python_string)
1390 (python_string_to_target_string)
1391 (python_string_to_target_python_string): Return gdbpy_ref.
1392 (python_string_to_host_string): Update.
1393 (host_string_to_python_string): Return gdbpy_ref.
1394 * python/py-symtab.c (stpy_get_filename, stpy_get_producer)
1395 (stpy_fullname): Update.
1396 * python/py-progspace.c (pspy_get_filename, pspy_solib_name):
1398 * python/py-prettyprint.c (print_string_repr): Update.
1399 * python/py-objfile.c (objfpy_get_filename, objfpy_get_username)
1400 (objfpy_get_build_id): Update.
1401 * python/py-breakpoint.c (bppy_get_location)
1402 (bppy_get_expression, bppy_get_condition, bppy_get_commands):
1405 2018-11-04 Tom Tromey <tom@tromey.com>
1407 * python/python-internal.h (gdb_py_object_from_longest)
1408 (gdb_py_object_from_ulongest): Return gdbpy_ref.
1409 * python/py-value.c (valpy_int): Update.
1410 * python/py-utils.c (gdb_py_object_from_longest): Return
1412 (gdb_py_object_from_ulongest): Likewise.
1413 * python/py-type.c (typy_get_alignof): Update.
1414 * python/py-linetable.c (ltpy_get_all_source_lines)
1415 (ltpy_entry_get_line, ltpy_entry_get_pc): Update.
1416 * python/py-block.c (blpy_get_start, blpy_get_end): Update.
1418 2018-11-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1420 * ada-lang.c (_initialize_ada_language): Fix typo.
1422 2018-11-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1424 * language.c (type): Remove.
1425 (_initialize_language): Remove assignment to type.
1427 2018-11-02 Joel Brobecker <brobecker@adacore.com>
1429 * aarch64-ravenscar-thread.h, aarch64-ravenscar-thread.c: New files.
1430 * aarch64-tdep.c: #include "aarch64-ravenscar-thread.h".
1431 (aarch64_gdbarch_init): Add call to register_aarch64_ravenscar_ops.
1432 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-ravenscar-thread.o.
1433 (HFILES_NO_SRCDIR): Add aarch64-ravenscar-thread.h.
1434 (ALLDEPFILES): Add aarch64-ravenscar-thread.c.
1435 * configure.tgt (cpu_obs) [aarch64*-*-*]: Add ravenscar-thread.o
1436 and aarch64-ravenscar-thread.o.
1437 * NEWS: Add entry documenting Ravenscar tasking support
1440 2018-11-02 Matthew Malcomson <matthew.malcomson@arm.com>
1442 * symtab.c (info_functions_command): Initialize quiet flag.
1443 * stack.c (info_args_command): Likewise.
1445 2018-11-01 Jim Wilson <jimw@sifive.com>
1447 * riscv-tdep.c (riscv_breakpoint_kind_from_pc): New local unaligned_p.
1448 Set if pcptr if unaligned. Return 2 if unaligned_p true. Update
1451 2018-11-01 Joel Brobecker <brobecker@adacore.com>
1453 * ada-lang.c (ada_watch_location_expression): New function.
1454 (ada_language_defn): Set la_watch_location_expression to
1455 ada_watch_location_expression.
1457 2018-11-01 Joel Brobecker <brobecker@adacore.com>
1459 * print-utils.c (int_string): Remove unnecessary trailing spaces.
1461 2018-11-01 Joel Brobecker <brobecker@adacore.com>
1463 * rs6000-tdep.c (skip_prologue): Fix potential negative left
1466 2018-11-01 Jerome Guitton <guitton@adacore.com>
1467 Joel Brobecker <brobecker@adacore.com>
1469 * defs.h (enum gdb_osabi): Add GDB_OSABI_PIKEOS.
1470 * osabi.c (gdb_osabi_names): Add name for GDB_OSABI_PIKEOS.
1471 * arm-pikeos-tdep.c: New file.
1472 * configure.tgt: Add arm-pikeos-tdep.o to the case of ARM
1474 * Makefile.in (ALL_TARGET_OBS): Add arm-pikeos-tdep.o.
1476 2018-11-01 Simon Marchi <simon.marchi@ericsson.com>
1478 * common/pathstuff.c (get_standard_temp_dir): New.
1479 * common/pathstuff.h (get_standard_temp_dir): New.
1480 * config.in: Re-generate.
1481 * configure: Re-generate.
1482 * configure.ac: Don't check for mkdtemp.
1483 * gnulib/aclocal-m4-deps.mk: Re-generate.
1484 * gnulib/aclocal.m4: Re-generate.
1485 * gnulib/config.in: Re-generate.
1486 * gnulib/configure: Re-generate.
1487 * gnulib/import/Makefile.am: Re-generate.
1488 * gnulib/import/Makefile.in: Re-generate.
1489 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
1490 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
1491 * gnulib/import/m4/mkdtemp.m4: New file.
1492 * gnulib/import/mkdtemp.c: New file.
1493 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES):
1495 * unittests/mkdir-recursive-selftests.c (test): Use
1496 get_standard_temp_dir.
1497 (_initialize_mkdir_recursive_selftests): Remove HAVE_MKDTEMP
1499 * compile/compile.c (get_compile_file_tempdir): Likewise.
1501 2018-11-01 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
1503 * rs6000-aix-tdep.c: Include "trad-frame.h" and "frame-unwind.h".
1504 (SIG_FRAME_LR_OFFSET64): New define.
1505 (SIG_FRAME_FP_OFFSET64): New define.
1506 (aix_sighandle_frame_cache): New Function.
1507 (aix_sighandle_frame_this_id): New Function.
1508 (aix_sighandle_frame_prev_register): New Function.
1509 (aix_sighandle_frame_sniffer): New Function.
1510 (aix_sighandle_frame_unwind): New global variable.
1511 (rs6000_aix_init_osabi): Install new frame unwinder.
1513 2018-10-31 Sergio Durigan Junior <sergiodj@redhat.com>
1516 * common/common-defs.h: Don't redefine _FORTIFY_SOURCE if it's
1519 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1521 * ppc-linux-nat.c: Include nat/linux-ptrace.h.
1523 2018-10-31 Andrew Burgess <andrew.burgess@embecosm.com>
1525 * dwarf2read.c (struct dwarf2_cu): Add producer_is_icc field.
1526 (producer_is_icc): New function.
1527 (check_producer): Set producer_is_icc field on dwarf2_cu.
1528 (dwarf2_init_integer_type): New function.
1529 (read_base_type): Call dwarf2_init_integer_type instead of
1530 init_integer_type in all cases.
1531 (dwarf2_cu::dwarf2_cu): Initialise producer_is_icc field.
1532 * valprint.c (maybe_negate_by_bytes): Add an assertion that the
1533 LEN is greater than 0.
1535 2018-10-30 Tom Tromey <tom@tromey.com>
1537 * main.c (captured_main_1): Check return value of bfd_init.
1539 2018-10-29 Sergio Durigan Junior <sergiodj@redhat.com>
1541 * common/offset-type.h (DEFINE_OFFSET_REL_OP): Delete.
1544 2018-10-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1546 * procfs.c: Include common/pathstuff.h.
1548 2018-10-28 Andrew Burgess <andrew.burgess@embecosm.com>
1550 * riscv-linux-nat.c (riscv_linux_nat_target::fetch_registers):
1551 Add missing braces. No functional change.
1553 2018-10-27 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1555 * macrocmd.c (info_macro_command): Use report_unrecognized_option_error
1556 to report a bad option and fix indentation.
1557 * demangle.c (demangle_command): Use report_unrecognized_option_error
1558 to report a bad option and correctly report the bad option.
1560 2018-10-27 Tom Tromey <tom@tromey.com>
1563 * darwin-nat.c (copied_shell): New global.
1564 (may_have_sip): Rename from should_disable_startup_with_shell.
1565 (copy_shell_to_cache, maybe_cache_shell): New functions.
1566 (darwin_nat_target::create_inferior): Update. Use
1569 2018-10-27 Tom Tromey <tom@tromey.com>
1571 * unittests/scoped_fd-selftests.c (test_to_file): New function.
1572 (run_tests): Call test_to_file.
1573 * dwarf-index-write.c (write_psymtabs_to_index): Do not reopen
1575 * common/scoped_fd.h (scoped_fd::to_file): New method.
1577 2018-10-27 Tom Tromey <tom@tromey.com>
1579 * unittests/scoped_mmap-selftests.c (test_normal): Use
1580 gdb_mkostemp_cloexec.
1581 * unittests/scoped_fd-selftests.c (test_destroy, test_release):
1582 Use gdb_mkostemp_cloexec.
1583 * gnulib/aclocal-m4-deps.mk, gnulib/aclocal.m4,
1584 gnulib/config.in, gnulib/configure,
1585 gnulib/import/Makefile.am, gnulib/import/Makefile.in,
1586 gnulib/import/m4/gnulib-cache.m4,
1587 gnulib/import/m4/gnulib-comp.m4: Update.
1588 * gnulib/import/m4/mkostemp.m4: New file.
1589 * gnulib/import/m4/mkstemp.m4: Remove.
1590 * gnulib/import/mkostemp.c: New file.
1591 * gnulib/import/mkstemp.m4: Remove.
1592 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Remove
1593 mkstemp, add mkostemp. Apply new patch.
1594 * gnulib/import/stdlib.in.h: Apply patch.
1595 * gnulib/patches/0002-mkostemp-mkostemps-Fix-compilation-error-in-C-mode-o.patch:
1597 * dwarf-index-write.c (write_psymtabs_to_index): Use
1598 gdb_mkostemp_cloexec.
1599 * common/filestuff.h (gdb_mkostemp_cloexec): New function.
1601 2018-10-27 Tom Tromey <tom@tromey.com>
1603 * unittests/mkdir-recursive-selftests.c: New file.
1604 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1605 unittests/mkdir-recursive-selftests.c.
1606 * dwarf-index-cache.c (mkdir_recursive): Move to
1608 (index_cache::store): Check return value of mkdir_recursive.
1609 (create_dir_and_check, test_mkdir_recursive): Move to new file.
1610 (_initialize_index_cache): Don't register test.
1611 * common/filestuff.h (mkdir_recursive): Declare.
1612 * common/filestuff.c (mkdir_recursive): Move from
1613 dwarf-index-cache.c. Return bool.
1615 2018-10-27 Tom Tromey <tom@tromey.com>
1617 * dwarf-index-write.c (write_psymtabs_to_index): Move
1618 make_temp_filename to common/pathstuff.c.
1619 * common/pathstuff.h (make_temp_filename): Declare.
1620 * common/pathstuff.c (make_temp_filename): New function, moved
1621 from dwarf-index-write.c.
1623 2018-10-27 Tom Tromey <tom@tromey.com>
1625 * procfs.c (procfs_target::create_inferior): Use get_shell.
1626 * cli/cli-cmds.c (shell_escape): Use get_shell.
1627 * windows-nat.c (windows_nat_target::create_inferior): Use
1629 * common/pathstuff.c (get_shell): New function.
1630 * nat/fork-inferior.c (SHELL_FILE, get_startup_shell): Remove.
1631 (fork_inferior): Use get_shell.
1632 * common/pathstuff.h (get_shell): Declare.
1634 2018-10-27 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1636 * NEWS: Mention changes to 'info [args|functions|locals|variables]'
1638 2018-10-27 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1640 * stack.c (print_variable_and_value_data): Add preg and treg.
1641 (print_frame_local_vars): Add quiet, regexp and t_regexp arguments,
1643 (print_frame_arg_vars): Likewise.
1644 (prepare_reg): New function.
1645 (info_locals_command): Extract info print args and use them.
1646 (info_args_command): Likewise.
1647 (_initialize_stack): Modify on-line help.
1648 * symtab.c (treg_matches_sym_type_name): New function.
1649 (search_symbols): New arg t_regexp.
1650 (symtab_symbol_info): New args quiet, regexp, t_regexp.
1651 (info_variables_command): Extract info print args and use them.
1652 (info_functions_command): Likewise.
1653 (info_types_command): Update call to symtab_symbol_info.
1654 (_initialize_symtab): Modify on-line help.
1655 * symtab.h (treg_matches_sym_type_name): New function.
1656 (search_symbols): New t_regexp arg.
1658 2018-10-27 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1660 * cli-utils.c (extract_arg_maybe_quoted): New function.
1661 (extract_info_print_args): New function.
1662 (info_print_args_help): New function.
1663 (report_unrecognized_option_error): New function.
1664 * cli-utils.h (extract_arg_maybe_quoted): New function.
1665 (extract_info_print_args): New function.
1666 (info_print_args_help): New function.
1667 (report_unrecognized_option_error): New function.
1669 2018-10-26 Tom Tromey <tom@tromey.com>
1671 * dwarf2read.c (recursively_compute_inclusions): Use std::vector.
1672 (compute_compunit_symtab_includes): Update.
1673 * symtab.h: (symtab_ptr): Remove typedef. Don't define a VEC.
1674 (compunit_symtab_ptr): Likewise.
1676 2018-10-26 John Baldwin <jhb@FreeBSD.org>
1678 * fbsd-tdep.c (fbsd_print_auxv_entry): Only use
1679 default_print_auxv_entry for specific tag values.
1681 2018-10-26 John Baldwin <jhb@FreeBSD.org>
1683 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_FREEBSD_HWCAP2.
1685 2018-10-26 Jim Wilson <jimw@sifive.com>
1687 * riscv-linux-tdep.c: Include tramp-frame.h and trad-frame.h.
1688 (riscv_linux_sigframe_init): Declare.
1689 (RISCV_INST_LI_A7_SIGRETURN, RISCV_INT_ECALL): New.
1690 (riscv_linux_sigframe): New.
1691 (SIGFRAME_SIGINFO_SIZE, UCONTEXT_MCONTEXT_OFFSET): New.
1692 (riscv_linux_sigframe_init): Define.
1693 (riscv_linux_init_abi): Call tramp_frame_prepend_unwinder.
1695 * riscv-tdep.c (riscv_isa_xlen): Refer to riscv-tdep.h comment.
1696 (riscv_isa_flen): Likewise. Drop static.
1697 * riscv-tdep.h (riscv_isa_xlen): Move riscv-tdep.c comment to here.
1698 (riscv_isa_flen): Likewise. Declare.
1700 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
1701 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1703 * arch/ppc-linux-tdesc.h (tdesc_powerpc_isa207_htm_vsx32l)
1704 (tdesc_powerpc_isa207_htm_vsx64l): Declare.
1705 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_TM_SPRREGSET)
1706 (PPC32_LINUX_SIZEOF_CGPRREGSET, PPC64_LINUX_SIZEOF_CGPRREGSET)
1707 (PPC_LINUX_SIZEOF_CFPRREGSET, PPC_LINUX_SIZEOF_CVMXREGSET)
1708 (PPC_LINUX_SIZEOF_CVSXREGSET, PPC_LINUX_SIZEOF_CPPRREGSET)
1709 (PPC_LINUX_SIZEOF_CDSCRREGSET, PPC_LINUX_SIZEOF_CTARREGSET):
1711 (struct ppc_linux_features) <htm>: New field.
1712 (ppc_linux_no_features): Add initializer for htm field.
1713 * arch/ppc-linux-common.c (ppc_linux_match_description): Return
1715 * nat/ppc-linux.h (PPC_FEATURE2_HTM, NT_PPC_TM_CGPR)
1716 (NT_PPC_TM_CFPR, NT_PPC_TM_CVMX, NT_PPC_TM_CVSX)
1717 (NT_PPC_TM_SPR, NT_PPC_TM_CTAR, NT_PPC_TM_CPPR, NT_PPC_TM_CDSCR):
1718 Define if not already defined.
1719 * features/Makefile (WHICH): Add rs6000/powerpc-isa207-htm-vsx32l
1720 and rs6000/powerpc-isa207-htm-vsx64l.
1721 (XMLTOC): Add rs6000/powerpc-isa207-htm-vsx32l.xml and
1722 rs6000/powerpc-isa207-htm-vsx64l.xml.
1723 * features/rs6000/power-htm-spr.xml: New file.
1724 * features/rs6000/power-htm-core.xml: New file.
1725 * features/rs6000/power64-htm-core.xml: New file.
1726 * features/rs6000/power-htm-fpu.xml: New file.
1727 * features/rs6000/power-htm-altivec.xml: New file.
1728 * features/rs6000/power-htm-vsx.xml: New file.
1729 * features/rs6000/power-htm-ppr.xml: New file.
1730 * features/rs6000/power-htm-dscr.xml: New file.
1731 * features/rs6000/power-htm-tar.xml: New file.
1732 * features/rs6000/powerpc-isa207-htm-vsx32l.xml: New file.
1733 * features/rs6000/powerpc-isa207-htm-vsx64l.xml: New file.
1734 * features/rs6000/powerpc-isa207-htm-vsx32l.c: Generate.
1735 * features/rs6000/powerpc-isa207-htm-vsx64l.c: Generate.
1736 * regformats/rs6000/powerpc-isa207-htm-vsx32l.dat: Generate.
1737 * regformats/rs6000/powerpc-isa207-htm-vsx64l.dat: Generate.
1738 * ppc-linux-nat.c (fetch_register, fetch_ppc_registers): Call
1739 fetch_regset with HTM regsets.
1740 (store_register, store_ppc_registers): Call store_regset with HTM
1742 (ppc_linux_nat_target::read_description): Set htm field in the
1743 features struct if needed.
1744 * ppc-linux-tdep.c: Include
1745 features/rs6000/powerpc-isa207-htm-vsx32l.c and
1746 features/rs6000/powerpc-isa207-htm-vsx64l.c.
1747 (ppc32_regmap_tm_spr, ppc32_regmap_cgpr, ppc64_le_regmap_cgpr)
1748 (ppc64_be_regmap_cgpr, ppc32_regmap_cfpr, ppc32_le_regmap_cvmx)
1749 (ppc32_be_regmap_cvmx, ppc32_regmap_cvsx, ppc32_regmap_cppr)
1750 (ppc32_regmap_cdscr, ppc32_regmap_ctar): New globals.
1751 (ppc32_linux_tm_sprregset, ppc32_linux_cgprregset)
1752 (ppc64_be_linux_cgprregset, ppc64_le_linux_cgprregset)
1753 (ppc32_linux_cfprregset, ppc32_le_linux_cvmxregset)
1754 (ppc32_be_linux_cvmxregset, ppc32_linux_cvsxregset)
1755 (ppc32_linux_cpprregset, ppc32_linux_cdscrregset)
1756 (ppc32_linux_ctarregset): New globals.
1757 (ppc_linux_cgprregset, ppc_linux_cvmxregset): New functions.
1758 (ppc_linux_collect_core_cpgrregset): New function.
1759 (ppc_linux_iterate_over_regset_sections): Call back with the htm
1761 (ppc_linux_core_read_description): Check if the tm spr section is
1762 present and set htm in the features struct.
1763 (_initialize_ppc_linux_tdep): Call
1764 initialize_tdesc_powerpc_isa207_htm_vsx32l and
1765 initialize_tdesc_powerpc_isa207_htm_vsx64l.
1766 * ppc-linux-tdep.h (ppc_linux_cgprregset, ppc_linux_cvmxregset):
1768 (ppc32_linux_tm_sprregset, ppc32_linux_cfprregset)
1769 (ppc32_linux_cvsxregset, ppc32_linux_cpprregset)
1770 (ppc32_linux_cdscrregset, ppc32_linux_ctarregset): Declare.
1771 * ppc-tdep.h (struct gdbarch_tdep) <have_htm_spr, have_htm_core>:
1773 <have_htm_fpu, have_htm_altivec, have_htm_vsx>:
1775 <ppc_cppr_regnum, ppc_cdscr_regnum, ppc_ctar_regnum>: Likewise.
1776 <ppc_cdl0_regnum, ppc_cvsr0_regnum, ppc_cefpr0_regnum>: Likewise.
1777 (enum) <PPC_TFHAR_REGNUM, PPC_TEXASR_REGNUM, PPC_TFIAR_REGNUM>:
1779 <PPC_CR0_REGNUM, PPC_CCR_REGNUM, PPC_CXER_REGNUM>: Likewise.
1780 <PPC_CLR_REGNUM, PPC_CCTR_REGNUM, PPC_CF0_REGNUM>: Likewise.
1781 <PPC_CFPSCR_REGNUM, PPC_CVR0_REGNUM, PPC_CVSCR_REGNUM>: Likewise.
1782 <PPC_CVRSAVE_REGNUM, PPC_CVSR0_UPPER_REGNUM>: Likewise.
1783 <PPC_CPPR_REGNUM, PPC_CDSCR_REGNUM>: Likewise.
1784 <PPC_CTAR_REGNUM>: Likewise.
1785 (PPC_IS_TMSPR_REGNUM, PPC_IS_CKPTGP_REGNUM, PPC_IS_CKPTFP_REGNUM)
1786 (PPC_IS_CKPTVMX_REGNUM, PPC_IS_CKPTVSX_REGNUM): Define.
1787 * rs6000-tdep.c (IS_CDFP_PSEUDOREG, IS_CVSX_PSEUDOREG)
1788 (IS_CEFP_PSEUDOREG): Define.
1789 (rs6000_register_name): Hide the upper halves of checkpointed VSX
1790 registers. Return names for the checkpointed DFP, VSX, and EFP
1792 (rs6000_pseudo_register_type): Remove initial assert and raise an
1793 internal error in the else clause instead. Return types for the
1794 checkpointed DFP, VSX, and EFP pseudo registers.
1795 (dfp_pseudo_register_read, dfp_pseudo_register_write): Handle
1796 checkpointed DFP pseudo registers.
1797 (vsx_pseudo_register_read, vsx_pseudo_register_write): Handle
1798 checkpointed VSX pseudo registers.
1799 (efp_pseudo_register_read, efp_pseudo_register_write): Rename
1800 from efpr_pseudo_register_read and
1801 efpr_pseudo_register_write. Handle checkpointed EFP pseudo
1803 (rs6000_pseudo_register_read, rs6000_pseudo_register_write):
1804 Handle checkpointed DFP, VSX, and EFP registers.
1805 (dfp_ax_pseudo_register_collect, vsx_ax_pseudo_register_collect)
1806 (efp_ax_pseudo_register_collect): New functions.
1807 (rs6000_ax_pseudo_register_collect): Move DFP, VSX and EFP pseudo
1808 register logic to new functions. Handle checkpointed DFP, VSX,
1809 and EFP pseudo registers.
1810 (rs6000_gdbarch_init): Look for and validate the htm features.
1811 Include checkpointed DFP, VSX and EFP pseudo-registers.
1812 * NEWS: Mention access to PPR, DSCR, TAR, EBB/PMU registers and
1815 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1817 * rs6000-tdep.c (rs6000_gdbarch_init): Reject tdescs with vsx but
1818 without altivec or fpu.
1820 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
1821 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1823 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_EBBREGSET)
1824 (PPC_LINUX_SIZEOF_PMUREGSET): Declare.
1825 * nat/ppc-linux.h (PPC_FEATURE2_EBB, NT_PPC_EBB, NT_PPC_PMU):
1826 Define if not already defined.
1827 * features/rs6000/power-ebb.xml: New file.
1828 * features/rs6000/power-linux-pmu.xml: New file.
1829 * features/rs6000/powerpc-isa207-vsx32l.xml: Include ebb and pmu
1831 * features/rs6000/powerpc-isa207-vsx64l.xml: Likewise.
1832 * features/rs6000/powerpc-isa207-vsx32l.c: Re-generate.
1833 * features/rs6000/powerpc-isa207-vsx64l.c: Re-generate.
1834 * regformats/rs6000/powerpc-isa207-vsx32l.dat: Re-generate.
1835 * regformats/rs6000/powerpc-isa207-vsx64l.dat: Re-generate.
1836 * ppc-linux-nat.c (fetch_register, fetch_ppc_registers): Call
1837 fetch_regset with ebb and pmu regsets.
1838 (store_register, store_ppc_registers): Call store_regset with ebb
1840 (ppc_linux_nat_target::read_description): Set isa207 field in the
1841 features struct if ebb and pmu are avaiable.
1842 * ppc-linux-tdep.c (ppc32_regmap_ebb, ppc32_regmap_pmu)
1843 (ppc32_linux_ebbregset, ppc32_linux_pmuregset): New globals.
1844 (ppc_linux_iterate_over_regset_sections): Call back with the ebb
1846 (ppc_linux_core_read_description): Check if the pmu section is
1847 present and set isa207 in the features struct.
1848 * ppc-linux-tdep.h (ppc32_linux_ebbregset)
1849 (ppc32_linux_pmuregset): Declare.
1850 * ppc-tdep.h (struct gdbarch_tdep) <ppc_mmcr0_regnum>: New field.
1851 <ppc_mmcr2_regnum, ppc_siar_regnum, ppc_sdar_regnum>: New fields.
1852 <ppc_sier_regnum>: New field.
1853 (enum): <PPC_BESCR_REGNUM, PPC_EBBHR_REGNUM, PPC_EBBRR_REGNUM>:
1855 <PPC_MMCR0_REGNUM, PPC_MMCR2_REGNUM, PPC_SIAR_REGNUM>: New enum
1857 <PPC_SDAR_REGNUM, PPC_SIER_REGNUM>: New enum values.
1858 (PPC_IS_EBB_REGNUM, PPC_IS_PMU_REGNUM): Define.
1859 * rs6000-tdep.c (rs6000_gdbarch_init): Look for and validate the
1860 ebb and pmu features.
1862 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
1863 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1865 * arch/ppc-linux-tdesc.h (tdesc_powerpc_isa207_vsx32l)
1866 (tdesc_powerpc_isa207_vsx64l): Declare.
1867 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_TARREGSET): Define.
1868 (struct ppc_linux_features) <isa207>: New field.
1869 (ppc_linux_no_features): Add initializer for isa207 field.
1870 * arch/ppc-linux-common.c (ppc_linux_match_description): Return
1872 * nat/ppc-linux.h (PPC_FEATURE2_ARCH_2_07, PPC_FEATURE2_TAR)
1873 (NT_PPC_TAR): Define if not already defined.
1874 * features/Makefile (WHICH): Add rs6000/powerpc-isa207-vsx32l and
1875 rs6000/powerpc-isa207-vsx64l.
1876 (XMLTOC): Add rs6000/powerpc-isa207-vsx32l.xml and
1877 rs6000/powerpc-isa207-vsx64l.xml.
1878 * features/rs6000/power-tar.xml: New file.
1879 * features/rs6000/powerpc-isa207-vsx32l.xml: New file.
1880 * features/rs6000/powerpc-isa207-vsx64l.xml: New file.
1881 * features/rs6000/powerpc-isa207-vsx32l.c: Generate.
1882 * features/rs6000/powerpc-isa207-vsx64l.c: Generate.
1883 * regformats/rs6000/powerpc-isa207-vsx32l.dat: Generate.
1884 * regformats/rs6000/powerpc-isa207-vsx64l.dat: Generate.
1885 * ppc-linux-nat.c (fetch_register, fetch_ppc_registers): Call
1886 fetch_regset with the TAR regset.
1887 (store_register, store_ppc_registers): Call store_regset with the
1889 (ppc_linux_nat_target::read_description): Set isa207 field in the
1890 features struct if needed.
1891 * ppc-linux-tdep.c: Include
1892 features/rs6000/powerpc-isa207-vsx32l.c and
1893 features/rs6000/powerpc-isa207-vsx64l.c.
1894 (ppc32_regmap_tar, ppc32_linux_tarregset): New globals.
1895 (ppc_linux_iterate_over_regset_sections): Call back with the tar
1897 (ppc_linux_core_read_description): Check if the tar section is
1898 present and set isa207 in the features struct.
1899 (_initialize_ppc_linux_tdep): Call
1900 initialize_tdesc_powerpc_isa207_vsx32l and
1901 initialize_tdesc_powerpc_isa207_vsx64l.
1902 * ppc-linux-tdep.h (ppc32_linux_tarregset): Declare.
1903 * ppc-tdep.h (gdbarch_tdep) <ppc_tar_regnum>: New field.
1904 (enum) <PPC_TAR_REGNUM>: New enum value.
1905 * rs6000-tdep.c (rs6000_gdbarch_init): Look for and validate tar
1907 (ppc_process_record_op31): Record changes to TAR.
1909 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
1910 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1912 * arch/ppc-linux-tdesc.h (tdesc_powerpc_isa205_ppr_dscr_vsx32l)
1913 (tdesc_powerpc_isa205_ppr_dscr_vsx64l): Declare.
1914 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_PPRREGSET)
1915 (PPC_LINUX_SIZEOF_DSCRREGSET): Define.
1916 (struct ppc_linux_features) <ppr_dscr>: New field.
1917 (ppc_linux_no_features): Add initializer for ppr_dscr field.
1918 * arch/ppc-linux-common.c (ppc_linux_match_description): Return
1920 * nat/ppc-linux.h (PPC_FEATURE2_DSCR, NT_PPC_PPR, NT_PPC_DSCR):
1921 Define if not already defined.
1922 * features/Makefile (WHICH): Add
1923 rs6000/powerpc-isa205-ppr-dscr-vsx32l and
1924 rs6000/powerpc-isa205-ppr-dscr-vsx64l.
1925 (XMLTOC): Add rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
1926 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml.
1927 * features/rs6000/power-dscr.xml: New file.
1928 * features/rs6000/power-ppr.xml: New file.
1929 * features/rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml: New file.
1930 * features/rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml: New file.
1931 * features/rs6000/powerpc-isa205-ppr-dscr-vsx32l.c: Generate.
1932 * features/rs6000/powerpc-isa205-ppr-dscr-vsx64l.c: Generate.
1933 * regformats/rs6000/powerpc-isa205-ppr-dscr-vsx32l.dat: Generate.
1934 * regformats/rs6000/powerpc-isa205-ppr-dscr-vsx64l.dat: Generate.
1935 * ppc-linux-nat.c: Include <sys/uio.h>.
1936 (fetch_regset, store_regset, check_regset): New functions.
1937 (fetch_register, fetch_ppc_registers): Call fetch_regset with
1938 DSCR and PPR regsets.
1939 (store_register, store_ppc_registers): Call store_regset with
1940 DSCR and PPR regsets.
1941 (ppc_linux_get_hwcap2): New function.
1942 (ppc_linux_nat_target::read_description): Call
1943 ppc_linux_get_hwcap2 and check_regset, set ppr_dscr field in the
1944 features struct if needed.
1945 * ppc-linux-tdep.c: Include
1946 features/rs6000/powerpc-isa205-ppr-dscr-vsx32l.c and
1947 features/rs6000/powerpc-isa205-ppr-dscr-vsx64l.c.
1948 (ppc32_regmap_ppr, ppc32_regmap_dscr, ppc32_linux_pprregset)
1949 (ppc32_linux_dscrregset): New globals.
1950 (ppc_linux_iterate_over_regset_sections): Call back with the ppr
1952 (ppc_linux_core_read_description): Check if the ppr and dscr
1953 sections are present and set ppr_dscr in the features struct.
1954 (_initialize_ppc_linux_tdep): Call
1955 initialize_tdesc_powerpc_isa205_ppr_dscr_vsx32l and
1956 initialize_tdesc_powerpc_isa205_ppr_dscr_vsx64l.
1957 * ppc-linux-tdep.h (ppc32_linux_pprregset)
1958 (ppc32_linux_dscrregset): Declare.
1959 * ppc-tdep.h (struct gdbarch_tdep) <ppc_ppr_regnum>: New field.
1960 <ppc_dscr_regnum>: New field.
1961 (enum) <PPC_PPR_REGNUM, PPC_DSCR_REGNUM>: New enum values.
1962 * rs6000-tdep.c (rs6000_gdbarch_init): Look for and validate ppr
1964 (ppc_process_record_op31): Record changes to PPR and DSCR.
1966 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1968 * rs6000-tdep.c (rs6000_gdbarch_init): Replace line wrapping by a
1969 second initializer line for the have_* variables. Initialize
1970 have_fpu to 0 instead of 1.
1972 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1974 * arch/ppc-linux-common.c (ppc_linux_match_description):
1975 Parenthesize tdesc assignements and indent them properly.
1977 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1979 * ppc-linux-nat.c (fetch_register): Change if statement to else
1981 (store_register): Likewise.
1983 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1985 * rs6000-tdep.c: Remove reggroups.h include.
1986 (rs6000_pseudo_register_reggroup_p): Remove.
1987 (rs6000_gdbarch_init): Remove call to
1988 set_tdesc_pseudo_register_reggroup_p.
1990 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1992 * reggroups.c (default_register_reggroup_p): Return true for
1993 decfloat registers and float_reggroup.
1995 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1997 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): Remove.
1998 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): Replace
1999 ppc_linux_collect_vrregset by regcache_collect_regset.
2001 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
2003 * linux-tdep.c (linux_collect_regset_section_cb): Use
2004 std::vector<gdb_byte> instead of char * and malloc for buf.
2007 2018-10-26 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
2009 * xcoffread.c (read_xcoff_symtab): Pass deduced language to
2010 symtab_start instead of always using language_unknown.
2012 2018-10-26 Andrew Burgess <andrew.burgess@embecosm.com>
2014 * riscv-tdep.c (riscv_read_misa_reg): Update comment, remove
2015 READ_P parameter, catch and ignore register access errors from
2016 either the old or new MISA location.
2017 (riscv_has_feature): Update call to riscv_read_misa_reg.
2019 2018-10-25 Andrew Burgess <andrew.burgess@embecosm.com>
2021 * python/py-function.c (convert_values_to_python): Return
2022 gdbpy_ref<>. Add header comment.
2023 (fnpy_call): Adjust.
2025 2018-10-25 Andrew Burgess <andrew.burgess@embecosm.com>
2027 * python/py-cmd.c (cmdpy_completer_helper): Return gdbpy_ref<>.
2028 (cmdpy_completer_handle_brkchars): Adjust.
2029 (cmdpy_completer): Adjust.
2031 2018-10-25 Andrew Burgess <andrew.burgess@embecosm.com>
2033 * riscv-linux-nat.c (riscv_linux_nat_target::fetch_registers):
2034 Pass correct regnum to raw_supply_zeroed.
2036 2018-10-23 Hafiz Abid Qadeer <abidh@codesourcery.com>
2038 * regcache.c (cooked_read_test): Add CSKY to the list of
2039 architectures with a save_reggroup
2041 2018-10-23 Simon Marchi <simon.marchi@polymtl.ca>
2044 * infrun.c (follow_exec): In the follow_exec_mode_new case,
2045 transfer terminal state from old new new inferior.
2046 * terminal.h (swap_terminal_info): New function.
2047 * inflow.c (swap_terminal_info): New function.
2049 2018-10-23 Tom Tromey <tom@tromey.com>
2051 * record-btrace.c (get_thread_current_frame_id): Rename from
2052 get_thread_current_frame. Return a frame_id.
2053 (record_btrace_start_replaying): Update.
2055 2018-10-23 Andrew Burgess <andrew.burgess@embecosm.com>
2057 * riscv-tdep.c (riscv_register_name): Use the user-friendly names
2060 2018-10-23 Joel Brobecker <brobecker@adacore.com>
2062 * riscv-tdep.c (riscv_gdbarch_init): Set the gdbarch's
2063 have_nonsteppable_watchpoint attribute to 1.
2065 2018-10-23 Andrew Burgess <andrew.burgess@embecosm.com>
2067 * riscv-tdep.c (riscv_gdb_reg_names): Update comment, and all
2069 (struct register_alias): Rename to...
2070 (struct riscv_register_alias): ...this, and update comment.
2071 (riscv_register_aliases): Update type, and alias names. Remove
2072 CSR names from this list.
2073 (riscv_register_name): Use riscv_gdb_reg_names for int and float
2074 register names. Add an extra assertion.
2075 (riscv_is_regnum_a_named_csr): New function.
2076 (riscv_register_reggroup_p): Use riscv_is_regnum_a_named_csr.
2078 2018-10-23 John Darrington <john@darrington.wattle.id.au>
2080 * configure.tgt: Add configuration for s12z.
2081 * s12z-tdep.c: New file.
2082 * NEWS: Mention new target.
2084 2018-10-22 Jim Wilson <jimw@sifive.com>
2086 * riscv-tdep.c (riscv_push_dummy_call) <in_reg>: Check for value in
2087 FP reg smaller than FP reg size, and fill with -1 instead of 0.
2089 * riscv-tdep.c (riscv_fpreg_d_type, riscv_fpreg_q_type): New.
2090 (riscv_register_type): Use them.
2091 (riscv_print_one_register_info): Handle union of floats same as float.
2092 * riscv-tdep.h (struct gdbarch_tdep): Add riscv_fpreg_d_type and
2093 riscv_fpreg_q_type fields.
2095 2018-10-21 Simon Marchi <simon.marchi@ericsson.com>
2097 * gdbarch.sh (gdbarch_num_cooked_regs): New.
2098 * gdbarch.h: Re-generate.
2099 * ax-gdb.c (gen_expr): Use gdbarch_num_cooked_regs.
2100 * dwarf2-frame.c (dwarf2_frame_cache): Likewise.
2101 * eval.c (evaluate_subexp_standard): Likewise.
2102 * findvar.c (value_of_register): Likewise.
2103 (value_of_register_lazy): Likewise.
2104 (address_from_register): Likewise.
2105 * frame.c (get_frame_register_bytes): Likewise.
2106 * gdbarch-selftests.c (register_to_value_test): Likewise.
2107 * h8300-tdep.c (h8300_register_type): Likewise.
2108 * i386-tdep.c (i386_dbx_reg_to_regnum): Likewise.
2109 (i386_svr4_reg_to_regnum): Likewise.
2110 * infcmd.c (default_print_registers_info): Likewise.
2111 (registers_info): Likewise.
2112 (print_vector_info): Likewise.
2113 (default_print_float_info): Likewise.
2114 * m68hc11-tdep.c (m68hc11_frame_unwind_cache): Likewise.
2115 * mdebugread.c (mdebug_reg_to_regnum): Likewise.
2116 * mi/mi-main.c (mi_cmd_data_list_register_names): Likewise.
2117 (mi_cmd_data_list_changed_registers): Likewise.
2118 (mi_cmd_data_list_register_values): Likewise.
2119 (mi_cmd_data_write_register_values): Likewise.
2120 (mi_cmd_trace_frame_collected): Likewise.
2121 * mips-tdep.c (print_gp_register_row): Likewise.
2122 (mips_print_registers_info): Likewise.
2123 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
2124 * regcache.c (init_regcache_descr): Likewise.
2125 (register_size): Likewise.
2126 (register_dump::dump): Likewise.
2127 (cooked_read_test): Likewise.
2128 (cooked_write_test): Likewise.
2129 * rs6000-tdep.c (rs6000_register_sim_regno): Likewise.
2130 (rs6000_gdbarch_init): Likewise.
2131 * stabsread.c (stab_reg_to_regnum): Likewise.
2132 * stack.c (info_frame_command): Likewise.
2133 * target-descriptions.c (tdesc_register_name): Likewise.
2134 * trad-frame.c (trad_frame_alloc_saved_regs): Likewise.
2135 * tui/tui-regs.c (tui_show_register_group): Likewise.
2136 * user-regs.c (user_reg_map_name_to_regnum): Likewise.
2137 (user_reg_map_regnum_to_name): Likewise.
2138 (value_of_user_reg): Likewise.
2139 (maintenance_print_user_registers): Likewise.
2140 * xtensa-tdep.c (xtensa_find_register_by_name): Likewise.
2141 (xtensa_register_name): Likewise.
2142 (xtensa_register_type): Likewise.
2143 (xtensa_reg_to_regnum): Likewise.
2144 (xtensa_pseudo_register_read): Likewise.
2145 (xtensa_pseudo_register_write): Likewise.
2147 2018-10-21 Simon Marchi <simon.marchi@polymtl.ca>
2149 * amd64-tdep.c (amd64_pseudo_register_read_value): Use
2150 correctly-sized buffer with raw_read.
2151 (amd64_pseudo_register_write): Use correctly-sized buffer for
2154 2018-10-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2156 * typeprint.c (_initialize_typeprint): Fix wrong prefixname arg
2157 in add_prefix_cmd of set print type.
2159 2018-10-19 Tom Tromey <tom@tromey.com>
2162 * NEWS: Mention tabset deprecation.
2163 * tui/tui-win.c (tui_tab_width, internal_tab_width): New globals.
2164 (update_tab_width): New function.
2165 (tui_set_tab_width, tui_show_tab_width): New functions.
2166 (tui_set_tab_width_command): Use update_tab_width.
2167 (_initialize_tui_win): Move to end of file. Deprecate "tabset".
2168 Add new "set tui tab-width" command.
2169 * tui/tui-source.c (tui_set_source_content): Update.
2170 * tui/tui-disasm.c (tui_set_disassem_content): Update.
2171 * tui/tui-data.h (tui_default_tab_len, tui_set_default_tab_len):
2173 (tui_tab_width): Declare.
2174 * tui/tui-data.c (default_tab_len, tui_default_tab_len)
2175 (tui_set_default_tab_len): Remove.
2177 2018-10-19 Tom Tromey <tom@tromey.com>
2179 * tui/tui-io.h (key_is_start_sequence, key_is_end_sequence)
2180 (key_is_backspace, tui_getc): Don't declare.
2181 * tui/tui-io.c (key_is_start_sequence): Now static.
2182 (key_is_end_sequence, key_is_backspace): Remove.
2183 (tui_getc): Now static.
2185 2018-10-19 Tom Tromey <tom@tromey.com>
2187 * symfile.c (reread_symbols): Clear "static_links".
2189 2018-10-19 Alan Hayward <alan.hayward@arm.com>
2191 * aarch64-linux-tdep.c (AARCH64_SIGCONTEXT_RESERVED_SIZE): New
2193 (aarch64_linux_sigframe_init): Extra boundary checks.
2195 2018-10-19 Andreas Arnez <arnez@linux.ibm.com>
2197 * s390-tdep.c (s390_pseudo_register_type): For v0-v15 don't yield
2198 the possibly non-existent tdesc type 'vec128', but the type of raw
2199 register v16 instead.
2201 2018-10-19 Gary Benson <gbenson@redhat.com>
2203 * cli/cli-interp.c (cli_interp::~cli_interp): New function.
2205 2018-10-18 Sergio Durigan Junior <sergiodj@redhat.com>
2208 * cli/cli-dump.c (restore_binary_file): Check if "file" is
2211 2018-10-17 Paul Koning <paul_koning@dell.com>
2213 * charset.c (convert_between_encodings): Fix unsigned overflow.
2215 2018-10-17 John Baldwin <jhb@FreeBSD.org>
2217 * fbsd-nat.c (fbsd_nat_target::info_proc) Use
2218 fbsd_info_proc_mappings_header and fbsd_info_proc_mappings_entry.
2219 * fbsd-tdep.c (fbsd_vm_map_entry_flags): Mark static.
2220 (fbsd_info_proc_mappings_header, fbsd_info_proc_mappings_entry):
2222 (fbsd_core_info_proc_mappings): Use fbsd_info_proc_mappings_header
2223 and fbsd_info_proc_mappings_header.
2224 * fbsd-tdep.h (fbsd_vm_map_entry_flags): Remove.
2225 (fbsd_info_proc_mappings_header, fbsd_info_proc_mappings_entry):
2228 2018-10-17 Joel Brobecker <brobecker@adacore.com>
2230 * MAINTAINERS (Responsible Maintainers): Add Rainer Orth as
2233 2018-10-15 Tom Tromey <tom@tromey.com>
2235 * tui/tui.c (strcat_to_buf): Remove casts.
2236 * tui/tui-winsource.c (tui_show_source_line)
2237 (tui_set_is_exec_point_at, tui_line_is_displayed): Remove casts.
2238 * tui/tui-wingeneral.c (tui_refresh_win, box_win): Remove casts.
2239 * tui/tui-windata.c (tui_first_data_item_displayed)
2240 (tui_delete_data_content_windows, tui_erase_data_content)
2241 (tui_display_all_data, tui_display_data_from)
2242 (tui_refresh_data_win, tui_vertical_data_scroll): Remove casts.
2243 * tui/tui-win.c (tui_set_win_height)
2244 (make_invisible_and_set_new_height, parse_scrolling_args): Remove
2246 * tui/tui-win.c (tui_resize_all): Remove casts.
2247 (tui_scroll_backward_command, tui_set_focus)
2248 (tui_set_tab_width_command): Likewise.
2249 * tui/tui-source.c (tui_vertical_source_scroll): Remove cast.
2250 * tui/tui-regs.c (tui_show_register_group): Remove cast.
2251 * tui/tui-layout.c (tui_set_layout_by_name): Remove cast.
2252 * tui/tui-disasm.c (tui_vertical_disassem_scroll): Remove cast.
2253 * tui/tui-data.c (tui_partial_win_by_name, tui_free_win_content):
2256 2018-10-15 Simon Marchi <simon.marchi@ericsson.com>
2258 * MAINTAINERS (Responsible Maintainers): Add Alan Hayward as
2259 AArch64/ARM maintainer.
2261 2018-10-11 Gary Benson <gbenson@redhat.com>
2263 * interps.h (interp::m_name): Make private and mutable.
2264 * interps.c (interp::~interp): Free m_name.
2266 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
2267 Simon Marchi <simark@simark.ca>
2269 * README (`configure' options): Add documentation for new
2270 "--enable-unit-tests" option.
2271 * acinclude.m4: Include "selftest.m4".
2272 * configure: Regenerate.
2273 * configure.ac: Use "GDB_AC_SELFTEST".
2274 * maint.c (maintenance_selftest): Update message informing
2275 that selftests have been disabled.
2276 (maintenance_info_selftests): Likewise.
2277 * selftest.m4: New file.
2279 2018-10-10 Gary Benson <gbenson@redhat.com>
2281 * remote.c (remote_target::remote_send_printf): Add
2282 missing va_end found by Coverity.
2284 2018-10-10 Markus Metzger <markus.t.metzger@intel.com>
2286 * btrace.c (ftrace_update_function): Add indirect jump heuristic.
2288 2018-10-09 Tom Tromey <tom@tromey.com>
2290 * configure: Rebuild.
2291 * sanitize.m4 (AM_GDB_UBSAN): Default to no.
2292 * NEWS: Update --enable-ubsan documentation.
2294 2018-10-09 Gary Benson <gbenson@redhat.com>
2296 * dwarf2read.c (create_dwp_hash_table): Fix buffer overrun
2299 2018-10-08 Tom Tromey <tom@tromey.com>
2301 * riscv-fbsd-tdep.c (riscv_fbsd_sigframe_init): Remove unused
2303 (riscv_fbsd_init_abi): Likewise.
2305 2018-10-08 Weimin Pan <weimin.pan@oracle.com>
2306 * valops.c (value_struct_elt_for_reference): Rename local variable
2307 to work around the shadowing a previous local warning.
2309 2018-10-08 John Baldwin <jhb@FreeBSD.org>
2311 * Makefile.in (ALLDEPFILES): Add riscv-fbsd-nat.c.
2312 * NEWS: Mention new FreeBSD/riscv native configuration.
2313 * configure.host: Add riscv*-*-freebsd*.
2314 * configure.nat: Likewise.
2315 * riscv-fbsd-nat.c: New file.
2317 2018-10-08 John Baldwin <jhb@FreeBSD.org>
2319 * Makefile.in (ALL_TARGET_OBS): Add riscv-fbsd-tdep.o.
2320 (HFILES_NO_SRCDIR): Add riscv-fbsd-tdep.h.
2321 (ALLDEPFILES): Add riscv-fbsd-tdep.c.
2322 * NEWS: Mention new FreeBSD/riscv target.
2323 * configure.tgt: Add riscv*-*-freebsd*.
2324 * riscv-fbsd-tdep.c: New file.
2325 * riscv-fbsd-tdep.h: New file.
2327 2018-10-08 John Baldwin <jhb@FreeBSD.org>
2329 * regcache.h (struct regcache_map_entry): Note that this type can
2330 be used with traditional frame caches.
2331 * trad-frame.c (trad_frame_set_reg_regmap): New.
2332 * trad-frame.h (trad_frame_set_reg_regmap): New.
2334 2018-10-08 Weimin Pan <weimin.pan@oracle.com>
2337 * valops.c (get_virtual_base_offset): New function.
2338 (value_struct_elt_for_reference): Use it to get virtual base offset
2339 and add it in calculating class member address.
2341 2018-10-08 John Darrington <john@darrington.wattle.id.au>
2343 * dwarf2read.c (dwarf2_cu) <producer_is_codewarrior>: New field.
2344 (check_producer): Check if the producer is codewarrior.
2345 (producer_is_codewarrior): New function.
2346 (lnp_state_machine::record_line): Ignore is_stmt flag for records
2347 produced by codewarrior.
2348 (dwarf2_cu::dwarf2_cu): Initialize producer_is_codewarrior.
2350 2018-10-06 Tom Tromey <tom@tromey.com>
2353 * python/py-inferior.c: Add "architecture" entry.
2354 (infpy_architecture): New function.
2356 2018-10-06 Tom Tromey <tom@tromey.com>
2359 * python/py-symbol.c (gdbpy_initialize_symbols): Redefine
2360 SYMBOL_VARIABLES_DOMAIN, SYMBOL_FUNCTIONS_DOMAIN,
2361 SYMBOL_TYPES_DOMAIN. Define SYMBOL_MODULE_DOMAIN,
2362 SYMBOL_COMMON_BLOCK_DOMAIN, SYMBOL_LOC_COMMON_BLOCK.
2364 2018-10-06 Tom Tromey <tom@tromey.com>
2367 * Makefile.in (OPCODES_CFLAGS): Remove "-I$(OPCODES_SRC)/..".
2368 * arc-tdep.c, frv-tdep.c, lm32-tdep.c, mep-tdep.c,
2369 microblaze-tdep.c, or1k-tdep.h: Use ../opcodes, not opcodes, in
2372 2018-10-06 Tom Tromey <tom@tromey.com>
2374 * python/py-breakpoint.c (bppy_get_location): Handle a
2375 bp_breakpoint without a location.
2377 2018-10-06 Tom Tromey <tom@tromey.com>
2379 * python/lib/gdb/function/strfns.py (_MemEq, _StrLen, _StrEq)
2380 (_RegEx): Reformat help text.
2381 * python/lib/gdb/function/caller_is.py (CallerIs, CallerMatches)
2382 (AnyCallerIs, AnyCallerMatches): Reformat help text.
2383 * python/lib/gdb/function/as_string.py (_AsString): Reformat help
2385 * python/lib/gdb/command/xmethods.py (InfoXMethod)
2386 (EnableXMethod, DisableXMethod): Remove help indentation.
2387 Capitalize meta-syntactic variables.
2388 * python/lib/gdb/command/unwinders.py (InfoUnwinder)
2389 (EnableUnwinder, DisableUnwinder): Remove help indentation.
2390 Capitalize meta-syntactic variables.
2391 * python/lib/gdb/command/explore.py (ExploreCommand)
2392 (ExploreValueCommand, ExploreTypeCommand): Reformat help text.
2393 * python/lib/gdb/command/type_printers.py (InfoTypePrinter)
2394 (EnableTypePrinter, DisableTypePrinter): Remove help indentation.
2395 * python/lib/gdb/command/pretty_printers.py (InfoPrettyPrinter):
2396 Remove help indentation.
2397 (EnablePrettyPrinter, DisablePrettyPrinter): Likewise.
2398 * python/lib/gdb/command/frame_filters.py (EnableFrameFilter)
2399 (DisableFrameFilter, SetFrameFilterPriority)
2400 (ShowFrameFilterPriority, InfoFrameFilter): Reword help text.
2402 2018-10-06 Tom Tromey <tom@tromey.com>
2405 * tui/tui-io.c (gdb_wgetch): New function.
2406 (tui_mld_getc, tui_getc): Use it.
2408 2018-10-05 Tom Tromey <tom@tromey.com>
2410 * sol-thread.c (sol_thread_target::wait): Rename inner
2413 2018-10-04 Tom Tromey <tom@tromey.com>
2415 * configure: Rebuild.
2416 * warning.m4 (AM_GDB_WARNINGS): Add -Wshadow=local.
2418 2018-10-04 Tom Tromey <tom@tromey.com>
2420 * guile/scm-frame.c (gdbscm_frame_read_var): Remove inner
2421 declaration of "block".
2423 2018-10-04 Tom Tromey <tom@tromey.com>
2425 * common/filestuff.c (fdwalk): Remove inner declaration of
2428 2018-10-04 Tom Tromey <tom@tromey.com>
2430 * msp430-tdep.c (msp430_push_dummy_call): Rename inner
2431 "structs_addr" and hoist declaration.
2433 2018-10-04 Tom Tromey <tom@tromey.com>
2435 * linux-tdep.c (linux_make_mappings_corefile_notes): Introduce new
2438 2018-10-04 Tom Tromey <tom@tromey.com>
2440 * mdebugread.c (parse_partial_symbols): Use std::string.
2442 2018-10-04 Tom Tromey <tom@tromey.com>
2444 * ctf.c (SET_ARRAY_FIELD): Rename "u32".
2445 * p-valprint.c (pascal_val_print): Split inner "i" variable.
2446 * xtensa-tdep.c (xtensa_push_dummy_call): Declare "i" in loop
2448 * xstormy16-tdep.c (xstormy16_push_dummy_call): Declare "val" in
2450 * xcoffread.c (read_xcoff_symtab): Rename inner "symbol".
2451 * varobj.c (varobj_update): Rename inner "newobj",
2453 * valprint.c (generic_emit_char): Rename inner "buf".
2454 * valops.c (find_overload_match): Rename inner "temp".
2455 (value_struct_elt_for_reference): Declare "v" in more inner
2457 * v850-tdep.c (v850_push_dummy_call): Rename "len".
2458 * unittests/array-view-selftests.c (run_tests): Rename inner
2460 * tui/tui-stack.c (tui_show_frame_info): Declare "i" in loop
2462 * tracepoint.c (merge_uploaded_trace_state_variables): Declare
2463 "tsv" in more inner scope.
2464 (print_one_static_tracepoint_marker): Rename inner
2466 * tic6x-tdep.c (tic6x_analyze_prologue): Declare "inst" lower.
2467 (tic6x_push_dummy_call): Don't redeclare "addr".
2468 * target-float.c: Declare "dto" lower.
2469 * symtab.c (lookup_local_symbol): Rename inner "sym".
2470 (find_pc_sect_line): Rename inner "pc".
2471 * stack.c (print_frame): Don't redeclare "gdbarch".
2472 (return_command): Rename inner "gdbarch".
2473 * s390-tdep.c (s390_prologue_frame_unwind_cache): Renam inner
2475 * rust-lang.c (rust_internal_print_type): Declare "i" in loop
2477 * rs6000-tdep.c (ppc_process_record): Rename inner "addr".
2478 * riscv-tdep.c (riscv_push_dummy_call): Declare "info" in inner
2480 * remote.c (remote_target::update_thread_list): Don't redeclare
2482 (remote_target::process_initial_stop_replies): Rename inner
2484 (remote_target::remote_parse_stop_reply): Don't redeclare "p".
2485 (remote_target::wait_as): Don't redeclare "stop_reply".
2486 (remote_target::get_thread_local_address): Rename inner
2488 (remote_target::get_tib_address): Likewise.
2490 * regcache.c (cooked_read_test): Rename "regnum".
2491 * record-btrace.c (cmd_record_btrace_start): Rename inner
2493 * ppc-sysv-tdep.c (ppc64_sysv_abi_return_value): Declare "i" in
2495 * ppc-linux-tdep.c (ppc_linux_syscall_record): Declare "i" in loop
2497 (ppu2spu_sniffer): Rename inner "buf".
2498 * parse.c (operator_check_standard): Rename inner "type",
2500 * p-valprint.c (pascal_val_print): Introduce new scope for
2501 "low_bound", "high_bound".
2502 * p-exp.y (yylex): Declare "i" in loop header.
2503 * objfiles.c (objfile_relocate1): Declare "i" in loop header.
2504 Lower declaration of "s".
2505 * nios2-tdep.c (nios2_analyze_prologue): Declare "i" in loop
2507 (nios2_push_dummy_call): Rename "len".
2508 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Rename static
2510 (linux_xfer_osdata_fds, linux_xfer_osdata_shm)
2511 (linux_xfer_osdata_sem, linux_xfer_osdata_msg)
2512 (linux_xfer_osdata_modules): Likewise.
2513 * mips-tdep.c (mips_eabi_push_dummy_call): Rename outer "len".
2514 (mips_n32n64_push_dummy_call, mips_o32_push_dummy_call)
2515 (mips_o64_push_dummy_call): Likewise.
2516 * microblaze-tdep.c (microblaze_analyze_prologue): Rename inner
2518 * mi/mi-main.c (list_available_thread_groups): Rename inner
2520 (mi_cmd_data_read_memory): Rename inner "opts".
2521 * mi/mi-cmd-var.c (varobj_update_one): Rename inner
2523 * mep-tdep.c (mep_analyze_prologue): Declare "rn" in loop header.
2524 * mdebugread.c (parse_symbol): Rename inner "b". Declare "f" in
2526 (parse_partial_symbols): Rename inner "pst", "p", "name"
2527 * main.c (captured_main_1): Rename inner "i"s.
2528 * machoread.c (macho_symfile_read_all_oso): Don't redeclare
2530 * linux-tdep.c (linux_info_proc): Rename inner "filename".
2531 * linespec.c (linespec_lexer_lex_string): Rename inner "p".
2532 * infrun.c (handle_no_resumed): Don't redeclare "thread".
2533 (handle_signal_stop): Rename inner "gdbarch".
2534 (handle_command): Declare "signum" in loop header.
2535 * ia64-tdep.c (ia64_pseudo_register_read): Don't redeclare
2537 (examine_prologue): Rename inner "sol" and "sof".
2538 (ia64_extract_return_value): Rename inner "val". Declare another
2539 "val" in a more inner scope.
2540 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Declare "buf" in
2542 * guile/scm-symbol.c (gdbscm_lookup_symbol): Rename inner
2544 * findvar.c (default_read_var_value): Don't redeclare "addr".
2545 * f-exp.y (yylex): Declare "i" in loop header.
2546 * eval.c (evaluate_subexp_standard): Don't redeclare "type".
2547 Rename inner "type", "expect_type".
2548 (evaluate_subexp_for_sizeof): Rename inner "pc".
2549 * elfread.c (elf_symfile_read): Rename inner "abfd".
2550 * dwarf2read.c (read_debug_names_from_section): Don't redeclare
2552 (process_psymtab_comp_unit_reader): Don't redeclare "gdbarch".
2553 (add_partial_subprogram): Rename inner "lowpc" and "highpc".
2554 (dwarf_decode_line_header): Rename inner "lh".
2555 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Don't redeclare
2556 "offset". Declare "i" in loop header.
2557 (disassemble_dwarf_expression): Rename inner "addr_size".
2558 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Rename
2560 (dwarf_expr_context::execute_stack_op): Rename inner "offset".
2561 * dwarf2-frame.c (decode_frame_entry_1): Rename inner "length"s.
2562 * disasm.c (do_mixed_source_and_assembly_deprecated): Rename inner
2563 "inner_list_emitter".
2564 (do_mixed_source_and_assembly): Rename inner "tuple_emitter".
2565 * disasm-selftests.c (print_one_insn_test): Wrap "bplen"
2566 declaration in a block.
2567 * csky-tdep.c (csky_analyze_prologue): Declare "offset" lower.
2568 * cp-valprint.c (cp_print_value_fields): Don't redeclare
2569 "obstack_final_size".
2570 * cp-support.c (inspect_type): Declare "i" in loop header.
2571 * compile/compile.c (compile_instance::insert_symbol_error):
2573 * common/agent.c (agent_run_command): Remove inner "ret"
2575 * coffread.c (coff_symfile_read): Rename inner "name".
2576 (coff_symfile_read): Rename inner "abfd".
2577 * cli/cli-utils.c (get_number_trailer): Rename inner "val".
2578 * cli/cli-cmds.c (print_disassembly): Rename inner "low" and
2580 * c-exp.y (lex_one_token): Move "len" declaration lower.
2581 * breakpoint.c (create_longjmp_master_breakpoint): Don't redeclare
2583 (create_exception_master_breakpoint): Likewise. Don't redeclare
2585 (watch_command_1): Declare "mark" later.
2586 (clear_command): Don't shadow "a" or "b".
2587 (delete_command): Rename inner "b".
2588 (delete_trace_command): Likewise.
2589 * arm-tdep.c (thumb_process_displaced_32bit_insn): Rename inner
2591 (arm_gdbarch_init): Remove inner "e_flags".
2592 * arch/arm-get-next-pcs.c (thumb_get_next_pcs_raw): Declare
2593 "offset" in inner blocks.
2595 2018-10-04 Simon Marchi <simon.marchi@ericsson.com>
2597 * dwarf-index-write.c (file_write): Don't write if the vector is
2600 2018-10-05 Tom de Vries <tdevries@suse.de>
2602 * python/py-progspace.c (pspy_solib_name): Fix type mismatch in
2603 PyArg_ParseTuple call.
2605 2018-10-05 Tom de Vries <tdevries@suse.de>
2607 * python/py-record-btrace.c (recpy_bt_goto): Fix type mismatch in
2608 PyArg_ParseTuple call.
2610 2018-10-04 Joel Brobecker <brobecker@adacore.com>
2612 * psymtab.c (recursively_search_psymtabs): Reformat parameters
2613 to avoid exceeding 80 characters per line limit.
2615 2018-10-04 Tom Tromey <tom@tromey.com>
2617 * symfile.c (syms_from_objfile_1, finish_new_objfile)
2618 (reread_symbols): Update.
2619 * complaints.h (clear_complaints): Remove argument.
2620 * complaints.c (enum complaint_series): Remove.
2621 (series): Remove global.
2622 (complaint_internal): Update.
2623 (clear_complaints): Remove argument.
2625 2018-10-04 Tom Tromey <tom@tromey.com>
2627 * symfile.c (symbol_file_add_with_addrs): Do not print "no
2628 debugging symbols" message if there is a separate debug objfile.
2630 2018-10-04 Tom Tromey <tom@tromey.com>
2633 * symfile.c (symbol_file_add_with_addrs): Update output.
2634 * psymtab.c (require_partial_symbols): Update output.
2636 2018-10-04 Tom Tromey <tom@tromey.com>
2639 * complaints.c: Emit \n.
2641 2018-10-04 Tom Tromey <tom@tromey.com>
2643 * symfile.c (symbol_file_add_with_addrs, symbol_file_clear)
2644 (separate_debug_file_exists, find_separate_debug_file)
2645 (add_symbol_file_command, reread_symbols, allocate_symtab)
2646 (allocate_compunit_symtab): Use filtered printing, not
2648 * psymtab.c (require_partial_symbols, dump_psymtab)
2649 (allocate_psymtab): Use filtered printing, not unfiltered.
2651 2018-10-04 Tom Tromey <tom@tromey.com>
2653 * complaints.c (complaint_internal): Correctly check complaint
2656 2018-10-04 Tom Tromey <tom@tromey.com>
2658 * complaints.h (struct complaints): Remove declaration.
2659 * complaints.c (clear_complaints): Remove an unused variable.
2661 2018-10-04 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2663 * MAINTAINERS (Write After Approval): Add self.
2665 2018-10-03 Tom Tromey <tom@tromey.com>
2667 * guile/scm-value.c (gdbscm_value_to_string): Initialize
2669 * coffread.c (coff_symtab_read): Initialize "newobj".
2671 2018-10-03 Simon Marchi <simon.marchi@polymtl.ca>
2673 * dwarf2read.c (read_func_scope): Remove struct keyword in
2676 2018-10-03 Tom Tromey <tom@tromey.com>
2678 * README: Mention --enable-ubsan.
2679 * NEWS: Mention --enable-ubsan.
2680 * acinclude.m4: Include sanitize.m4.
2681 * configure: Rebuild.
2682 * configure.ac: Call AM_GDB_UBSAN.
2683 * sanitize.m4: New file.
2685 2018-10-03 Tom Tromey <tom@tromey.com>
2687 * expression.h (enum exp_opcode): Use uint8_t as base type.
2688 * expprint.c (op_name): Handle invalid opcodes.
2690 2018-10-03 Tom Tromey <tom@tromey.com>
2692 * parse.c (prefixify_expression): Add assert.
2693 (parse_exp_in_context_1): Throw exception if the expression is
2696 2018-10-03 Tom Tromey <tom@tromey.com>
2698 * dwarf2read.c (read_signed_leb128): Work in ULONGEST.
2700 2018-10-03 Tom Tromey <tom@tromey.com>
2702 * c-exp.y (parse_number): Work in unsigned. Remove casts.
2704 2018-10-03 Tom Tromey <tom@tromey.com>
2706 * dwarf2read.c (read_subrange_type): Make "negative_mask"
2709 2018-10-03 Tom Tromey <tom@tromey.com>
2711 * findvar.c (extract_integer): Do work in an unsigned type.
2713 2018-10-03 Tom Tromey <tom@tromey.com>
2715 * common/enum-flags.h (enum_flags::operator~): Add static assert.
2716 * symfile-add-flags.h (enum symfile_add_flag): Use unsigned as
2718 * objfile-flags.h (enum objfile_flag): Use unsigned as base type.
2719 * gdbtypes.h (enum type_instance_flag_value): Use unsigned as base
2721 * c-lang.h (enum c_string_type_values): Use unsigned as base
2723 * btrace.h (enum btrace_thread_flag): Use unsigned as base type.
2725 2018-10-03 Tom Tromey <tom@tromey.com>
2727 * dwarf2-frame.h (dwarf2_frame_state_reg_info)
2728 <~dwarf2_frame_state_reg_info>: Update.
2729 <dwarf2_frame_state_reg_info>: Update.
2730 <alloc_regs>: Add assertion. Update.
2731 <reg>: Now a std::vector.
2734 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
2735 (execute_cfa_program_test, dwarf2_frame_cache): Update.
2737 2018-10-03 Tom Tromey <tom@tromey.com>
2739 * namespace.c (add_using_directive): Don't pass NULL to memcpy.
2741 2018-10-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2743 * tid-parse.c (tid_is_in_list): Fix wrong 'See' comment.
2745 2018-10-02 Tom Tromey <tom@tromey.com>
2747 * aarch64-linux-tdep.c (aarch64_linux_sigframe_init): Use pulongest.
2749 2018-10-02 John Darrington <john@darrington.wattle.id.au>
2751 * NEWS: Mention changed commands.
2752 * ser-uds.c: New file.
2753 * configure.ac (SER_HARDWIRE): Add ser-uds.o.
2754 * configure: Regenerate.
2755 * Makefile.in: Add new file.
2756 * serial.c (serial_open): Check if filename is a socket
2757 and lookup the appropriate interface accordingly.
2759 2018-10-01 Alan Hayward <alan.hayward@arm.com>
2761 * aarch64-linux-tdep.c (AARCH64_SIGCONTEXT_RESERVED_OFFSET): Add
2763 (AARCH64_EXTRA_MAGIC): Likewise.
2764 (AARCH64_FPSIMD_MAGIC): Likewise.
2765 (AARCH64_SVE_MAGIC): Likewise.
2766 (AARCH64_EXTRA_DATAP_OFFSET): Likewise.
2767 (AARCH64_FPSIMD_FPSR_OFFSET): Likewise.
2768 (AARCH64_FPSIMD_FPCR_OFFSET): Likewise.
2769 (AARCH64_FPSIMD_V0_OFFSET): Likewise.
2770 (AARCH64_FPSIMD_VREG_SIZE): Likewise.
2771 (AARCH64_SVE_CONTEXT_VL_OFFSET): Likewise.
2772 (AARCH64_SVE_CONTEXT_REGS_OFFSET): Likewise.
2773 (AARCH64_SVE_CONTEXT_P_REGS_OFFSET): Likewise.
2774 (AARCH64_SVE_CONTEXT_FFR_OFFSET): Likewise.
2775 (AARCH64_SVE_CONTEXT_SIZE): Likewise.
2776 (read_aarch64_ctx): Add function.
2777 (aarch64_linux_sigframe_init): Detect FP registers.
2779 2018-10-01 Alan Hayward <alan.hayward@arm.com>
2781 * aarch64-tdep.c (AARCH64_Q0_REGNUM): Move to here.
2782 (AARCH64_D0_REGNUM): Likewise.
2783 (AARCH64_S0_REGNUM): Likewise.
2784 (AARCH64_H0_REGNUM): Likewise.
2785 (AARCH64_B0_REGNUM): Likewise.
2786 (AARCH64_SVE_V0_REGNUM): Likewise.
2787 * arch/aarch64.h (AARCH64_Q0_REGNUM): Move from here.
2788 (AARCH64_D0_REGNUM): Likewise.
2789 (AARCH64_S0_REGNUM): Likewise.
2790 (AARCH64_H0_REGNUM): Likewise.
2791 (AARCH64_B0_REGNUM): Likewise.
2792 (AARCH64_SVE_V0_REGNUM): Likewise.
2794 2018-10-01 Gary Benson <gbenson@redhat.com>
2796 * gdb_proc_service.h (gdb_prfpregset_t): Remove typedef.
2797 * proc-service.c (ps_lgetfpregs, ps_lsetfpregs): Use
2798 prfpregset_t instead of gdb_prfpregset_t.
2799 * configure.ac (PRFPREGSET_T_BROKEN): Remove check.
2800 * configure, config.in: Rebuild.
2802 2018-10-01 Gary Benson <gbenson@redhat.com>
2804 * common/gdb_proc_service.h: New file, factored out from...
2805 * gdb_proc_service.h: Moved common code to the above file.
2806 * Makefile.in (HFILES_NO_SRCDIR): Add the above new file.
2808 2018-10-01 Gary Benson <gbenson@redhat.com>
2810 * gdb_proc_service.h: Use elf_gregset_t if prgregset_t is
2811 undefined. Use elf_fpregset_t if prfpregset_t is undefined.
2813 2018-10-01 Gary Benson <gbenson@redhat.com>
2815 * configure.ac: Check if sys/procfs.h defines elf_fpregset_t.
2816 (AC_CHECK_HEADERS): Check for linux/elf.h.
2817 * configure, config.in: Rebuild.
2818 * gdb_proc_service.h: Include linux/elf.h if sys/procfs.h
2819 doesn't define elf_fpregset_t.
2821 2018-10-01 Gary Benson <gbenson@redhat.com>
2823 * gdb_proc_service.h: Whitespace change.
2825 2018-10-01 Tom Tromey <tom@tromey.com>
2827 * unittests/scoped_mmap-selftests.c: Don't check HAVE_UNISTD_H.
2828 * unittests/scoped_fd-selftests.c: Don't check HAVE_UNISTD_H.
2829 * common/scoped_fd.h: Don't check HAVE_UNISTD_H.
2831 2018-10-01 Tom Tromey <tom@tromey.com>
2833 * README: Minor change.
2835 2018-09-30 Pedro Alves <palves@redhat.com>
2837 * darwin-nat-info.c (darwin_debug_regions_recurse)
2838 (info_mach_exceptions_command): Remove unused local variables.
2839 * darwin-nat.c (darwin_decode_notify_message)
2840 (darwin_nat_target::resume, darwin_nat_target::mourn_inferior)
2841 (darwin_stop_inferior, darwin_setup_exceptions)
2842 (darwin_nat_target::kill, darwin_attach_pid, darwin_ptrace_him)
2843 (darwin_nat_target::attach, darwin_nat_target::detach)
2844 (darwin_read_write_inferior, darwin_read_dyld_info): Remove unused
2846 * i386-darwin-nat.c (i386_darwin_dr_set): Remove unused local
2849 2018-09-29 Tom Tromey <tom@tromey.com>
2851 * README: Remove some leftover text.
2853 2018-09-29 Tom Tromey <tom@tromey.com>
2855 * PROBLEMS: Rewrite.
2858 2018-09-28 John Baldwin <jhb@FreeBSD.org>
2860 * disasm-selftests.c (print_one_insn_test): Add bfd_arch_riscv to
2861 case with explicit breakpoint kind.
2862 * riscv-tdep.c (show_use_compressed_breakpoints): Remove
2863 'additional_info' and related logic.
2864 (riscv_debug_breakpoints): New variable.
2865 (riscv_breakpoint_kind_from_pc): Use the length of the existing
2866 instruction to determine the breakpoint kind.
2867 (_initialize_riscv_tdep): Add 'set/show debug riscv breakpoints'
2868 flag. Update description of 'set/show riscv
2869 use-compressed-breakpoints' flag.
2871 2018-09-28 Andrew Burgess <andrew.burgess@embecosm.com>
2873 (NEWS): Mention changes to frame related commands.
2874 * cli/cli-decode.c (add_cmd_suppress_notification): New function.
2875 (add_prefix_cmd_suppress_notification): New function.
2876 (add_com_suppress_notification): Call
2877 add_cmd_suppress_notification.
2878 * command.h (add_cmd_suppress_notification): Declare.
2879 (add_prefix_cmd_suppress_notification): Declare.
2880 * mi/mi-cmd-stack.c: Add 'safe-ctype.h' include.
2881 (parse_frame_specification): Moved from stack.c, with
2882 simplification to handle a single argument.
2883 (mi_cmd_stack_select_frame): Use parse_frame_specification, the
2884 switch to the selected frame. Add a header comment.
2885 * stack.c: Remove 'safe-ctype.h' include.
2886 (find_frame_for_function): Add declaration.
2887 (find_frame_for_address): New function.
2888 (parse_frame_specification): Moved into mi/mi-cmd-stack.c.
2889 (frame_selection_by_function_completer): New function.
2890 (info_frame_command): Rename to...
2891 (info_frame_command_core): ...this, and update parameter types.
2892 (select_frame_command): Rename to...
2893 (select_frame_command_core): ...this, and update parameter types.
2894 (frame_command): Rename to...
2895 (frame_command_core): ...this, and update parameter types.
2896 (class frame_command_helper): New class to wrap implementations of
2897 frame related sub-commands.
2898 (frame_apply_cmd_list): New static global.
2899 (frame_cmd_list): Make static.
2900 (select_frame_cmd_list): New global for sub-commands.
2901 (info_frame_cmd_list): New global for sub-commands.
2902 (_initialize_stack): Register sub-commands for 'frame',
2903 'select-frame', and 'info frame'. Update 'frame apply' commands
2904 to use frame_apply_cmd_list. Move function local static
2905 frame_apply_list to file static frame_apply_cmd_list for
2907 * stack.h (select_frame_command): Delete declarationn.
2908 (select_frame_for_mi): Declare new function.
2910 2018-09-26 Andrew Burgess <andrew.burgess@embecosm.com>
2912 * riscv-tdep.c (riscv_insn::decode): Decode c.lui.
2913 (riscv_scan_prologue): Split handling of AUIPC, LUI, ADD, ADDI,
2916 2018-09-26 Simon Marchi <simon.marchi@ericsson.com>
2918 * elf32-nds32.c (elf32_nds32_allocate_dynrelocs): Remove.
2920 2018-09-26 Tom Tromey <tom@tromey.com>
2922 * valops.c (auto_abandon): Remove dead code.
2924 2018-09-26 Tom Tromey <tom@tromey.com>
2926 * tui/tui-win.c (WIN_HEIGHT_USAGE): Remove extra ">"s.
2928 2018-09-24 Tom Tromey <tom@tromey.com>
2930 * common/pathstuff.c (get_standard_cache_dir): Make
2931 "xdg_cache_home" and "home" const.
2932 * top.c (init_history): Make "tmpenv" const.
2933 * main.c (get_init_files): Make "homedir" const.
2935 2018-09-23 Tom Tromey <tom@tromey.com>
2938 * python/py-param.c (get_set_value): Use gdbpy_handle_exception.
2940 2018-09-23 Tom Tromey <tom@tromey.com>
2942 * python/py-function.c (fnpy_call): Use gdbpy_handle_exception.
2943 * python/py-cmd.c (cmdpy_function): Use gdbpy_handle_exception.
2944 * python/python-internal.h (gdbpy_handle_exception): Declare.
2945 * python/py-utils.c (gdbpy_handle_exception): New function.
2947 2018-09-23 Tom Tromey <tom@tromey.com>
2950 * python/py-type.c (typy_template_argument): Check for negative
2953 2018-09-23 Tom Tromey <tom@tromey.com>
2956 * python/python.c (gdbpy_run_events): Do not ignore exceptions.
2958 2018-09-23 Tom Tromey <tom@tromey.com>
2961 * python/py-value.c (valpy_int): Allow conversion from pointer
2964 2018-09-23 Tom Tromey <tom@tromey.com>
2967 * python/py-value.c (valpy_int): Respect type sign.
2969 2018-09-23 Tom Tromey <tom@tromey.com>
2972 * python/py-value.c (valpy_float): Allow conversions from int or
2974 (valpy_int, valpy_long): Allow conversions from float.
2976 2018-09-23 Tom Tromey <tom@tromey.com>
2978 * ctf.c (ctf_start): Use gdb_fopen_cloexec.
2979 * common/scoped_mmap.c (mmap_file): Use gdb_open_cloexec.
2981 2018-09-23 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2983 * amd64-sol2-tdep.c (amd64_sol2_sigtramp_p): Also recognize
2985 * i386-sol2-tdep.c (i386_sol2_sigtramp_p): Likewise.
2987 2018-08-02 Jon Turney <jon.turney@dronecode.org.uk>
2989 * windows-nat.c (windows_nat_target::wait): Remove a spurious
2990 target_terminal::ours().
2992 2018-09-23 Simon Marchi <simon.marchi@ericsson.com>
2994 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): Change type
2997 2018-09-21 Yacov Simhony <ysimhony@gmail.com>
2999 * breakpoint.c (update_inserted_breakpoint_locations): Remove
3000 redundant condition.
3002 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3004 * proc-utils.h (PROC_CTL_WORD_TYPE): Remove.
3006 * procfs.c: Don't check for PR_MODEL_NATIVE definition.
3007 * sparc-sol2-nat.c: Likewise. Remove Linux, __arch64__ references.
3008 * sol-thread.c (ps_pdmodel): Don't guard definition.
3010 * procfs.c: Fix formatting.
3012 * procfs.c (sysset_t_alloc): Remove.
3013 (create_procinfo): Use XNEW instead of sysset_t_alloc.
3014 (procfs_debug_inferior): Likewise.
3015 (procfs_set_exec_trap): Likewise.
3016 (proc_set_traced_sysentry): Don't allocate argp dynamically.
3017 (proc_set_traced_sysexit): Likewise.
3019 * procfs.c (create_procinfo): Use xsnprintf to fix ARI warning.
3020 (dead_procinfo): Likewise.
3021 (proc_warn): Likewise.
3022 (proc_error): Likewise.
3023 (proc_get_LDT_entry): Likewise.
3024 (do_attach): Likewise.
3025 (procfs_target::pid_to_str): Likewise.
3026 (iterate_over_mappings): Likewise.
3028 * procfs.c (create_procinfo): Fix ARI warning.
3029 (proc_get_status): Likewise.
3030 (proc_stop_process): Likewise.
3031 (proc_run_process): Likewise.
3032 (proc_kill): Likewise.
3033 (proc_get_LDT_entry): Likewise.
3034 (procfs_find_LDT_entry): Likewise.
3035 (proc_update_threads): Likewise.
3036 (proc_iterate_over_threads): Likewise.
3037 (do_attach): Likewise.
3038 (procfs_xfer_memory): Likewise.
3039 (invalidate_cache): Likewise.
3040 (procfs_target::resume): Likewise.
3041 (procfs_init_inferior): Likewise.
3042 (procfs_set_exec_trap): Likewise.
3043 (procfs_target::thread_alive): Likewise.
3044 (procfs_target::pid_to_exec_file): Likewise.
3045 (iterate_over_mappings): Likewise.
3046 (procfs_target::make_corefile_notes): Likewise.
3047 * sol-thread.c (sol_thread_target::thread_alive): Likewise.
3049 * procfs.c (procfs_find_LDT_entry): Silence ARI warning.
3050 (procfs_find_LDT_entry): Likewise.
3051 * sol-thread.c (ps_lgetLDT): Likewise.
3053 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3056 * procfs.c (procfs_target): Declare pid_to_exec_file.
3057 (procfs_target::pid_to_exec_file): New.
3059 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3061 * auxv.c (default_print_auxv_entry): Reflect AT_SUN_CAP_HW1
3063 Handle AT_SUN_EMULATOR, AT_SUN_BRANDNAME, AT_SUN_BRAND_AUX1,
3064 AT_SUN_BRAND_AUX2, AT_SUN_BRAND_AUX3, AT_SUN_CAP_HW2.
3066 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3068 * i386-v4-nat.c (regmap, supply_gregset, fill_gregset)
3069 (supply_fpregset, fill_fpregset): Move ...
3070 * i386-sol2-nat.c [PR_MODEL_NATIVE != PR_MODEL_LP64]: ... here.
3071 Remove HAVE_GREGSET_T, HAVE_FPREGET_T guards.
3072 Remove references to ioctl-based procfs.
3073 Include <sys/reg.h>.
3074 Remove PR_MODEL_NATIVE guards.
3075 * configure.nat <sol2, i386> (NATDEPFILES): Remove i386-v4-nat.o.
3076 * Makefile.in (ALLDEPFILES): Remove i386-v4-nat.c.
3078 2018-09-19 Xavier Roirand <roirand@adacore.com>
3081 * solib-darwin.c (darwin_get_dyld_bfd): New function.
3082 (darwin_solib_get_all_image_info_addr_at_init): Update call.
3083 (darwin_solib_create_inferior_hook): Handle unrelocated dyld.
3085 2018-09-19 John Baldwin <jhb@FreeBSD.org>
3087 * fbsd-tdep.c (fbsd_print_sockaddr_in): Style fix.
3088 (fbsd_print_sockaddr_in6): Likewise.
3090 2018-09-19 Richard Bunt <richard.bunt@arm.com>
3091 Chris January <chris.january@arm.com>
3093 * eval.c (skip_undetermined_arglist): Skip argument list helper.
3094 (evaluate_subexp_standard): Return a dummy type when
3095 honoring EVAL_SKIP in OP_VAR_VALUE and handle skipping in the
3096 OP_F77_UNDETERMINED_ARGLIST case.
3097 * expression.h (enum noside): Update comment.
3099 2018-09-19 George Vasick <george.vasick@oracle.com>
3101 * solib-svr4.c (svr4_same_1): Also handle amd64 ld.so.1.
3103 2018-09-19 Stefan Teleman <stefan.teleman@oracle.com>
3104 April Chin <april.chin@oracle.com>
3105 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3107 * procfs.c (MAX_PROC_NAME_SIZE): Allow for 6-digit PID_MAX and
3109 (create_procinfo): Print pids in /proc without leading zeros.
3111 2018-09-18 Sandra Loosemore <sandra@codesourcery.com>
3113 * nios2-tdep.c (nios2_gcc_target_options): New.
3114 (nios2_gdb_arch_init): Install new hook.
3116 2018-09-18 Simon Marchi <simon.marchi@ericsson.com>
3118 * patches/0001-Fix-PR-gdb-23558-Use-system-s-getcwd-when-cross-comp.patch:
3120 * update-gnulib.sh: Apply patch.
3121 * configure: Re-generate.
3123 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3125 * infcmd.c (_initialize_infcmd): Remove "running" from "info proc"
3126 description. Make "info proc" command descriptions more
3129 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3131 * NEWS: Mention 'info proc files' command.
3133 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3135 * fbsd-nat.c (fbsd_nat_target::info_proc): List open file
3136 descriptors for IP_FILES and IP_ALL.
3138 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3140 * fbsd-tdep.c (KF_FLAGS, KF_OFFSET, KF_VNODE_TYPE, KF_SOCK_DOMAIN)
3141 (KF_SOCK_TYPE, KF_SOCK_PROTOCOL, KF_SA_LOCAL, KF_SA_PEER)
3142 (KINFO_FILE_TYPE_SOCKET, KINFO_FILE_TYPE_PIPE)
3143 (KINFO_FILE_TYPE_FIFO, KINFO_FILE_TYPE_KQUEUE)
3144 (KINFO_FILE_TYPE_CRYPTO, KINFO_FILE_TYPE_MQUEUE)
3145 (KINFO_FILE_TYPE_SHM, KINFO_FILE_TYPE_SEM, KINFO_FILE_TYPE_PTS)
3146 (KINFO_FILE_TYPE_PROCDESC, KINFO_FILE_FD_TYPE_ROOT)
3147 (KINFO_FILE_FD_TYPE_JAIL, KINFO_FILE_FD_TYPE_TRACE)
3148 (KINFO_FILE_FD_TYPE_CTTY, KINFO_FILE_FLAG_READ)
3149 (KINFO_FILE_FLAG_WRITE, KINFO_FILE_FLAG_APPEND)
3150 (KINFO_FILE_FLAG_ASYNC, KINFO_FILE_FLAG_FSYNC)
3151 (KINFO_FILE_FLAG_NONBLOCK, KINFO_FILE_FLAG_DIRECT)
3152 (KINFO_FILE_FLAG_HASLOCK, KINFO_FILE_FLAG_EXEC)
3153 (KINFO_FILE_VTYPE_VREG, KINFO_FILE_VTYPE_VDIR)
3154 (KINFO_FILE_VTYPE_VCHR, KINFO_FILE_VTYPE_VLNK)
3155 (KINFO_FILE_VTYPE_VSOCK, KINFO_FILE_VTYPE_VFIFO, FBSD_AF_UNIX)
3156 (FBSD_AF_INET, FBSD_AF_INET6, FBSD_SOCK_STREAM, FBSD_SOCK_DGRAM)
3157 (FBSD_SOCK_SEQPACKET, FBSD_IPPROTO_ICMP, FBSD_IPPROTO_TCP)
3158 (FBSD_IPPROTO_UDP, FBSD_IPPROTO_SCTP): New defines.
3159 (struct fbsd_sockaddr_in, struct fbsd_sockaddr_in6)
3160 (struct fbsd_sockaddr_un): New types.
3161 (fbsd_file_fd, fbsd_file_type, fbsd_file_flags, fbsd_ipproto)
3162 (fbsd_print_sockaddr_in, fbsd_print_sockaddr_in6)
3163 (fbsd_info_proc_files_header, fbsd_info_proc_files_entry)
3164 (fbsd_core_info_proc_files): New functions.
3165 (fbsd_core_info_proc): List open file descriptors for IP_FILES and
3167 * fbsd-tdep.h (fbsd_info_proc_files_header)
3168 (fbsd_info_proc_files_entry): New.
3170 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3172 * defs.h (enum info_proc_what) [IP_FILES]: New value.
3173 * infcmd.c (info_proc_cmd_files): New function.
3174 (_initialize_infcmd): Register 'info proc files' command.
3176 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3178 * gnulib/aclocal-m4-deps.mk: Re-generate.
3179 * gnulib/aclocal.m4: Re-generate.
3180 * gnulib/config.in: Re-generate.
3181 * gnulib/configure: Re-generate.
3182 * gnulib/import/Makefile.am: Re-generate.
3183 * gnulib/import/Makefile.in: Re-generate.
3184 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
3185 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
3186 * gnulib/import/arpa_inet.in.h: New file.
3187 * gnulib/import/inet_ntop.c: New file.
3188 * gnulib/import/m4/arpa_inet_h.m4: New file.
3189 * gnulib/import/m4/inet_ntop.m4: New file.
3190 * gnulib/import/m4/netinet_in_h.m4: New file.
3191 * gnulib/import/m4/socklen.m4: New file.
3192 * gnulib/import/m4/sockpfaf.m4: New file.
3193 * gnulib/import/m4/stdalign.m4: New file.
3194 * gnulib/import/m4/sys_uio_h.m4: New file.
3195 * gnulib/import/netinet_in.in.h: New file.
3196 * gnulib/import/stdalign.in.h: New file.
3197 * gnulib/import/sys_socket.c: New file.
3198 * gnulib/import/sys_socket.in.h: New file.
3199 * gnulib/import/sys_uio.in.h: New file.
3200 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add inet_ntop
3203 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3205 * gnulib/aclocal-m4-deps.mk: New file.
3206 * gnulib/update-gnulib.sh: Generate "aclocal-m4-deps.mk"
3209 2018-09-18 John Baldwin <jhb@FreeBSD.org>
3211 * fbsd-tdep.c (fbsd_core_vnode_path): Use KF_PATH instead of
3214 2018-09-18 Tom Tromey <tom@tromey.com>
3216 * compile/compile-object-load.c (struct
3217 link_hash_table_cleanup_data): Add constructor and destructor.
3218 Use DISABLE_COPY_AND_ASSIGN.
3219 (~link_hash_table_cleanup_data): Rename from
3220 link_hash_table_free. Now a destructor.
3221 (copy_sections): Use gdb::unique_xmalloc_ptr. Remove cleanups.
3223 2018-09-18 Tom Tromey <tom@tromey.com>
3225 * compile/compile-object-run.c (do_module_cleanup): Use delete.
3226 * compile/compile-object-load.c (struct munmap_list): Move to
3228 (munmap_list::add): Rename from munmap_list_add; rewrite.
3229 (munmap_list::~munmap_list): Rename from munmap_list_free.
3230 (munmap_listp_free_cleanup): Remove.
3231 (compile_object_load): Update.
3232 * compile/compile-object-load.h (struct munmap_list): Move from
3233 compile-object-load.c. Rewrite.
3235 2018-09-18 Alan Hayward <alan.hayward@arm.com>
3237 * aarch64-tdep.c (pass_in_v): Use register size.
3238 (aarch64_extract_return_value): Likewise.
3239 (aarch64_store_return_value): Likewise.
3241 2018-09-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3243 * utils.c (dump_core) [HAVE_SETRLIMIT]: Cast RLIM_INFINITY to
3246 2018-09-17 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3248 * python/lib/gdb/command/frame_filters.py (EnableFrameFilter):
3249 Fix short help line.
3251 2018-09-17 Tom Tromey <tom@tromey.com>
3254 * configure: Rebuild.
3255 * configure.ac: Conditionally use -DNDEBUG for Python.
3257 2018-09-17 Tom Tromey <tom@tromey.com>
3259 * configure: Rebuild.
3260 * configure.ac: Use gmp as a library dependency when checking for
3263 2018-09-17 Pedro Alves <palves@redhat.com>
3265 * python/py-inferior.c (find_inferior_object): Delete.
3267 2018-09-17 Simon Marchi <simon.marchi@ericsson.com>
3269 * compile/compile-cplus-types.c
3270 (compile_cplus_instance::enter_scope): Don't use new_scope after
3273 2018-09-17 Tom Tromey <tom@tromey.com>
3275 * common/pathstuff.c (get_standard_cache_dir): Use
3276 ~/Library/Caches on macOS.
3277 * common/pathstuff.h (get_standard_cache_dir): Update comment.
3279 2018-09-17 Simon Marchi <simon.marchi@polymtl.ca>
3282 * breakpoint.c (commands_cmd_element): New.
3283 (_initialize_breakpoint): Assign commands_cmd_element.
3284 * breakpoint.h (commands_cmd_element): New.
3285 * cli/cli-script.c (while_cmd_element, if_command,
3286 define_cmd_element): New.
3287 (command_name_equals): Remove.
3288 (process_next_line): Compare commands by pointer, not by name.
3289 (_initialize_cli_script): Assign the various cmd_list_element
3291 * compile/compile.c (compile_cmd_element): New.
3292 (_initialize_compile): Assign compile_cmd_element.
3293 * compile/compile.h (compile_cmd_element): New.
3294 * guile/guile.c (guile_cmd_element): New.
3295 (install_gdb_commands): Assign guile_cmd_element.
3296 * guile/guile.h (guile_cmd_element): New.
3297 * python/python.c (python_cmd_element): New.
3298 (_initialize_python): Assign python_cmd_element.
3299 * python/python.h (python_cmd_element): New.
3300 * tracepoint.c (while_stepping_cmd_element): New.
3301 (_initialize_tracepoint): Assign while_stepping_cmd_element.
3302 * tracepoint.h (while_stepping_cmd_element): New.
3304 2018-09-17 Tom Tromey <tom@tromey.com>
3306 * infrun.c (save_infcall_suspend_state): Return
3307 infcall_suspend_state_up.
3308 (save_infcall_control_state): Return infcall_control_state_up.
3309 * inferior.h (save_infcall_suspend_state)
3310 (save_infcall_control_state): Declare later. Return unique
3313 2018-09-17 Tom Tromey <tom@tromey.com>
3315 * infrun.c (struct stop_context): Declare constructor,
3316 destructor, "changed" method.
3317 (stop_context::stop_context): Rename from save_stop_context.
3318 (stop_context::~stop_context): Rename from
3319 release_stop_context_cleanup.
3320 (normal_stop): Update.
3321 (stop_context::changed): Rename from stop_context_changed. Return
3324 2018-09-17 Tom Tromey <tom@tromey.com>
3326 * inferior.h (struct infcall_suspend_state_deleter): New.
3327 (infcall_suspend_state_up): New typedef.
3328 (struct infcall_control_state_deleter): New.
3329 (infcall_control_state_up): New typedef.
3330 (make_cleanup_restore_infcall_suspend_state)
3331 (make_cleanup_restore_infcall_control_state): Don't declare.
3332 * infcall.c (call_function_by_hand_dummy): Update.
3333 * infrun.c (do_restore_infcall_suspend_state_cleanup)
3334 (make_cleanup_restore_infcall_suspend_state): Remove.
3335 (do_restore_infcall_control_state_cleanup)
3336 (make_cleanup_restore_infcall_control_state): Remove.
3338 2018-09-17 Tom Tromey <tom@tromey.com>
3340 * gdbthread.h (struct thread_control_state): Add initializer.
3341 (class thread_info) <control>: Remove initializer.
3342 * inferior.h (struct inferior_control_state): Add initializer.
3343 (class inferior) <control>: Remove initializer.
3344 (exit_inferior_1): Update.
3345 * infrun.c (struct infcall_control_state): Add constructors.
3346 (save_infcall_control_state): Use new.
3347 (restore_infcall_control_state, discard_infcall_control_state):
3350 2018-09-17 Tom Tromey <tom@tromey.com>
3352 * infrun.c (struct infcall_suspend_state) <registers>: Now a
3354 <siginfo_data>: Now a unique_xmalloc_ptr.
3355 (save_infcall_suspend_state, restore_infcall_suspend_state)
3356 (discard_infcall_suspend_state)
3357 (get_infcall_suspend_state_regcache): Update.
3359 2018-09-17 Tom Tromey <tom@tromey.com>
3361 * gdbthread.h (struct thread_suspend_state): Add initializers.
3362 (class thread_info) <suspend>: Remove initializer.
3363 * infrun.c (struct infcall_suspend_state): Add initializers.
3364 (save_infcall_suspend_state): Use new.
3365 (discard_infcall_suspend_state): Use delete.
3367 2018-09-16 Tom Tromey <tom@tromey.com>
3369 * python/python-internal.h (CPYCHECKER_STEALS_REFERENCE_TO_ARG):
3371 * python/py-varobj.c (py_varobj_iter_ctor): Change pyiter to
3372 rvalue reference. Remove CPYCHECKER_STEALS_REFERENCE_TO_ARG.
3373 (py_varobj_iter_new): Likewise.
3374 (py_varobj_get_iterator): Use gdbpy_ref.
3376 2018-09-16 Tom Tromey <tom@tromey.com>
3378 * python/py-threadevent.c (py_get_event_thread): Simplify.
3379 * python/py-inferior.c (infpy_thread_from_thread_handle):
3380 Return immediately after calling thread_to_thread_object. Use
3382 (thread_to_thread_object): Set the exception on a NULL return.
3384 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
3386 * Makefile.in (LIBGDB_OBS): Sort COMMON_OBS.
3388 2018-09-16 Tom Tromey <tom@tromey.com>
3390 * python/python-internal.h (CPYCHECKER_RETURNS_BORROWED_REF):
3393 2018-09-16 Tom Tromey <tom@tromey.com>
3395 * python/python-internal.h (thread_to_thread_object): Change
3397 * python/py-inferior.c (thread_to_thread_object): Return a new
3399 (infpy_thread_from_thread_handle): Update.
3400 * python/py-infthread.c (gdbpy_selected_thread): Update.
3401 * python/py-stopevent.c (create_stop_event_object): Update.
3402 * python/py-threadevent.c (py_get_event_thread): Return a new
3404 (py_get_event_thread): Update.
3405 * python/py-event.h (py_get_event_thread): Change return type.
3406 * python/py-continueevent.c (create_continue_event_object):
3409 2018-09-16 Tom Tromey <tom@tromey.com>
3411 * python/py-progspace.c (pspy_get_objfiles): Update.
3412 * python/python-internal.h (objfile_to_objfile_object): Change
3414 * python/py-newobjfileevent.c (create_new_objfile_event_object):
3416 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
3418 * python/python.c (gdbpy_get_current_objfile): Update.
3419 (gdbpy_objfiles): Update.
3420 * python/py-objfile.c (objfpy_get_owner, gdbpy_lookup_objfile):
3422 (objfile_to_objfile_object): Return a new reference.
3423 * python/py-symtab.c (stpy_get_objfile): Update.
3424 * python/py-prettyprint.c (find_pretty_printer_from_objfiles):
3427 2018-09-16 Tom Tromey <tom@tromey.com>
3429 * python/py-inferior.c (infpy_get_progspace): Update.
3430 * python/python-internal.h (pspace_to_pspace_object): Change
3432 * python/py-newobjfileevent.c
3433 (create_clear_objfiles_event_object): Update.
3434 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
3436 * python/python.c (gdbpy_get_current_progspace): Update.
3437 (gdbpy_progspaces): Update.
3438 * python/py-progspace.c (pspace_to_pspace_object): Return a new
3440 * python/py-objfile.c (objfpy_get_progspace): Update.
3441 * python/py-prettyprint.c (find_pretty_printer_from_progspace):
3444 2018-09-16 Tom Tromey <tom@tromey.com>
3446 * python/lib/gdb/__init__.py (current_progspace, objfiles)
3447 (solib_name, block_for_pc, find_pc_line): New functions.
3448 (execute_unwinders): Update.
3449 * python/py-block.c (gdbpy_block_for_pc): Remove.
3450 * python/py-inferior.c (infpy_get_progspace): New function.
3451 (inferior_object_getset) <progspace>: Add.
3452 * python/py-progspace.c (pspy_objfiles): Rewrite.
3453 (pspy_solib_name, pspy_block_for_pc)
3454 (pspy_find_pc_line, pspy_is_valid): New functions.
3455 (progspace_object_methods): Add entries for solib_name,
3456 block_for_pc, find_pc_line, is_valid.
3457 * python/python-internal.h (gdbpy_block_for_pc)
3458 (build_objfiles_list): Don't declare.
3459 * python/python.c: Don't include solib.h.
3460 (gdbpy_solib_name, gdbpy_find_pc_line)
3461 (gdbpy_get_current_progspace, build_objfiles_list)
3462 (gdbpy_objfiles): Remove.
3463 (GdbMethods) <current_progspace, objfiles, block_for_pc,
3464 solib_name, find_pc_line>: Remove entries.
3466 2018-09-16 Tom Tromey <tom@tromey.com>
3468 * top.c (new_ui_command): Use GNU style for metasyntactic
3470 * breakpoint.c (stopat_command): Use GNU style for metasyntactic
3472 * maint.c (maintenance_translate_address): Remove "<>" around
3474 * interps.c (interpreter_exec_cmd): Use GNU style for
3475 metasyntactic variables.
3476 * nto-procfs.c (nto_procfs_target_info): Use GNU style for
3477 metasyntactic variables.
3478 * tracepoint.c (tfind_range_command): Use GNU style for
3479 metasyntactic variables.
3480 (tfind_outside_command): Likewise.
3481 (_initialize_tracepoint): Likewise.
3482 * remote.c (extended_remote_target::create_inferior): Use GNU
3483 style for metasyntactic variables.
3484 * sparc64-tdep.c (adi_examine_command): Use GNU style for
3485 metasyntactic variables.
3486 (adi_assign_command): Likewise.
3488 2018-09-16 Tom Tromey <tom@tromey.com>
3490 * disasm.c (show_disassembler_options_sfunc): Use GNU style for
3491 metasyntactic variables. Print message if no disassembler options
3494 2018-09-15 Tom Tromey <tom@tromey.com>
3496 * infcmd.c (get_inferior_args): Return const char *.
3497 * inferior.h (get_inferior_args): Return type now const.
3498 * linux-tdep.c (linux_fill_prpsinfo): Update.
3499 * procfs.c (procfs_target::make_corefile_notes): Update.
3501 2018-09-07 Tom Tromey <tom@tromey.com>
3503 * python/python.c (execute_gdb_command): Call bpstat_do_actions
3506 2018-09-14 Sandra Loosemore <sandra@codesourcery.com>
3508 * nios2-tdep.c (nios2_type_align): New.
3509 (nios2_gdb_arch_init): Install type_align hook.
3511 2018-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
3513 * eval.c (fake_method::fake_method): Call xzalloc directly for a
3514 type that is neither object file owned, nor gdbarch owned.
3515 * gdbtypes.c (get_type_gdbarch): Add an assert that returned
3516 gdbarch is non-NULL.
3517 (alloc_type_instance): Allocate non-objfile owned types on the
3519 (copy_type_recursive): Allocate TYPE_FIELDS and TYPE_RANGE_DATA
3520 using TYPE_ALLOC to ensure memory is allocated on the correct
3522 * gdbtypes.h (TYPE_ALLOC): Allocate space on either the objfile
3523 obstack, or the gdbarch obstack.
3524 (TYPE_ZALLOC): Rewrite using TYPE_ALLOC.
3526 2018-09-14 Tom Tromey <tom@tromey.com>
3528 * infcall.c (call_function_by_hand_dummy): Remove unnecessary
3531 2018-09-14 Tom Tromey <tom@tromey.com>
3533 * nat/fork-inferior.c (get_startup_shell): Remove "static".
3535 2018-09-13 Tom Tromey <tom@tromey.com>
3537 * python/py-inferior.c (infpy_thread_from_thread_handle): Now
3540 2018-09-13 Tom Tromey <tom@tromey.com>
3542 * exec.c (try_open_exec_file): Use std::string.
3544 2018-09-13 Tom Tromey <tom@tromey.com>
3546 * utils.h (gdb_bfd_errmsg): Return std::string.
3547 * exec.c (exec_file_attach): Update.
3548 * compile/compile-object-load.c (compile_object_load): Update.
3549 * utils.c (gdb_bfd_errmsg): Return std::string.
3551 2018-09-13 Tom Tromey <tom@tromey.com>
3553 * procfs.c (struct procinfo_deleter): New.
3554 (procinfo_up): New typedef.
3555 (do_destroy_procinfo_cleanup): Remove.
3556 (procfs_target::info_proc): Use procinfo_up. Remove cleanups.
3558 2018-09-13 Tom Tromey <tom@tromey.com>
3560 * source.c (add_path): Use gdb::unique_xmalloc_ptr.
3562 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
3563 2018-09-13 Tom Tromey <tom@tromey.com>
3565 * python/py-progspace.c (PSPY_REQUIRE_VALID): New macro.
3566 (pspy_get_objfiles): New function.
3567 (progspace_object_methods): New.
3568 (pspace_object_type): Add tp_methods callback.
3569 * python/python-internal.h (build_objfiles_list): New
3571 * python/python.c (build_objfiles_list): New function.
3572 (gdbpy_objfiles): Implement using build_objfiles_list.
3573 * NEWS: Mention the Progspace.objfiles method.
3575 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
3577 * python/py-inferior.c (infpy_get_progspace): New function.
3578 (inferior_object_getset): Add progspace property.
3579 * NEWS: Mention the new property.
3581 2018-09-13 Tom Tromey <tom@tromey.com>
3584 * rust-lang.c (rust_evaluate_subexp): Use field name, not "foo".
3586 2018-09-13 Tom Tromey <tom@tromey.com>
3589 * rust-lang.c (rust_enum_variant): Now static.
3590 (rust_empty_enum_p): New function.
3591 (rust_print_enum, rust_evaluate_subexp, rust_print_struct_def):
3594 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
3596 * python/py-inferior.c (infpy_repr): New.
3597 (inferior_object_type): Register infpy_repr.
3598 * python/py-objfile.c (objfpy_repr): New.
3599 (objfile_object_type): Register objfpy_repr.
3601 2018-09-12 John Baldwin <jhb@FreeBSD.org>
3603 * fbsd-nat.c (fbsd_nat_target::info_proc): Remove unused variable.
3605 2018-09-12 John Baldwin <jhb@FreeBSD.org>
3607 * aarch64-fbsd-tdep.h (AARCH64_FBSD_SIZEOF_GREGSET): Fix comment
3610 2018-09-12 Sergio Durigan Junior <sergiodj@redhat.com>
3612 * common/common-utils.c: Don't include '<sys/stat.h>'.
3613 (is_regular_file): Move to...
3614 * common/filestuff.c (is_regular_file): ... here.
3615 * common/common-utils.h (is_regular_file): Move to...
3616 * common/filestuff.h (is_regular_file): ... here.
3618 2018-09-12 Simon Marchi <simon.marchi@ericsson.com>
3620 * skip.c (debug_skip): New variable.
3621 (skiplist_entry::do_skip_file_p): Add debug output.
3622 (skiplist_entry::do_skip_gfile_p): Likewise.
3623 (skiplist_entry::skip_function_p): Likewise.
3624 (_initialize_step_skip): Create debug command.
3625 * NEWS: Mention set/show debug skip.
3627 2018-09-11 Xavier Roirand <roirand@adacore.com>
3629 * darwin-nat.c (should_disable_startup_with_shell):
3631 (darwin_nat_target::create_inferior): Add call.
3633 2018-09-11 Xavier Roirand <roirand@adacore.com>
3635 * darwin-nat.h (struct darwin_thread_info) <gdb_port,
3636 inf_port, msg_state>: Initialize.
3637 (struct darwin_thread_info) <signaled, single_step>: Change
3638 type and initialize.
3639 (struct darwin_thread_info) <event>: Initialize.
3641 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
3645 * gnulib/import/m4/getcwd-path-max.m4: Add cross-compilation
3648 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
3651 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
3655 * gnulib/aclocal.m4: Regenerate.
3656 * gnulib/config.in: Regenerate.
3657 * gnulib/configure: Regenerate.
3658 * gnulib/import/Makefile.am: Update.
3659 * gnulib/import/Makefile.in: Update.
3660 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
3661 * gnulib/import/_Noreturn.h: ... this.
3662 * gnulib/import/alloca.in.h: Update.
3663 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
3664 * gnulib/import/arg-nonnull.h: ... this.
3665 * gnulib/import/assure.h: Update.
3666 * gnulib/import/at-func.c: Update.
3667 * gnulib/import/basename-lgpl.c: Update.
3668 * gnulib/import/extra/snippet/c++defs.h: Rename to...
3669 * gnulib/import/c++defs.h: ... this.
3670 * gnulib/import/canonicalize-lgpl.c: Update.
3671 * gnulib/import/cdefs.h: Update.
3672 * gnulib/import/chdir-long.c: Update.
3673 * gnulib/import/chdir-long.h: Update.
3674 * gnulib/import/cloexec.c: Update.
3675 * gnulib/import/cloexec.h: Update.
3676 * gnulib/import/close.c: Update.
3677 * gnulib/import/closedir.c: Update.
3678 * gnulib/import/config.charset: Update.
3679 * gnulib/import/dirent-private.h: Update.
3680 * gnulib/import/dirent.in.h: Update.
3681 * gnulib/import/dirfd.c: Update.
3682 * gnulib/import/dirname-lgpl.c: Update.
3683 * gnulib/import/dirname.h: Update.
3684 * gnulib/import/dosname.h: Update.
3685 * gnulib/import/dup-safer-flag.c: Update.
3686 * gnulib/import/dup-safer.c: Update.
3687 * gnulib/import/dup.c: Update.
3688 * gnulib/import/dup2.c: Update.
3689 * gnulib/import/errno.in.h: Update.
3690 * gnulib/import/error.c: Update.
3691 * gnulib/import/error.h: Update.
3692 * gnulib/import/exitfail.c: Update.
3693 * gnulib/import/exitfail.h: Update.
3694 * gnulib/import/extra/update-copyright: Update.
3695 * gnulib/import/fchdir.c: Update.
3696 * gnulib/import/fcntl.c: Update.
3697 * gnulib/import/fcntl.in.h: Update.
3698 * gnulib/import/fd-hook.c: Update.
3699 * gnulib/import/fd-hook.h: Update.
3700 * gnulib/import/fd-safer-flag.c: Update.
3701 * gnulib/import/fd-safer.c: Update.
3702 * gnulib/import/fdopendir.c: Update.
3703 * gnulib/import/filename.h: Update.
3704 * gnulib/import/filenamecat-lgpl.c: Update.
3705 * gnulib/import/filenamecat.h: Update.
3706 * gnulib/import/flexmember.h: Update.
3707 * gnulib/import/float+.h: Update.
3708 * gnulib/import/float.c: Update.
3709 * gnulib/import/float.in.h: Update.
3710 * gnulib/import/fnmatch.c: Update.
3711 * gnulib/import/fnmatch.in.h: Update.
3712 * gnulib/import/fnmatch_loop.c: Update.
3713 * gnulib/import/fpucw.h: Update.
3714 * gnulib/import/frexp.c: Update.
3715 * gnulib/import/frexpl.c: Update.
3716 * gnulib/import/fstat.c: Update.
3717 * gnulib/import/fstatat.c: Update.
3718 * gnulib/import/getcwd-lgpl.c: Update.
3719 * gnulib/import/getcwd.c: Update.
3720 * gnulib/import/getdtablesize.c: Update.
3721 * gnulib/import/getlogin_r.c: Update.
3722 * gnulib/import/getprogname.c: Update.
3723 * gnulib/import/getprogname.h: Update.
3724 * gnulib/import/gettext.h: Update.
3725 * gnulib/import/gettimeofday.c: Update.
3726 * gnulib/import/glob-libc.h: Update.
3727 * gnulib/import/glob.c: Update.
3728 * gnulib/import/glob.in.h: Update.
3729 * gnulib/import/glob_internal.h: Update.
3730 * gnulib/import/glob_pattern_p.c: Update.
3731 * gnulib/import/globfree.c: Update.
3732 * gnulib/import/hard-locale.c: Update.
3733 * gnulib/import/hard-locale.h: Update.
3734 * gnulib/import/intprops.h: Update.
3735 * gnulib/import/inttypes.in.h: Update.
3736 * gnulib/import/isnan.c: Update.
3737 * gnulib/import/isnand-nolibm.h: Update.
3738 * gnulib/import/isnand.c: Update.
3739 * gnulib/import/isnanl-nolibm.h: Update.
3740 * gnulib/import/isnanl.c: Update.
3741 * gnulib/import/itold.c: Update.
3742 * gnulib/import/libc-config.h: Update.
3743 * gnulib/import/limits.in.h: Update.
3744 * gnulib/import/localcharset.c: Update.
3745 * gnulib/import/localcharset.h: Update.
3746 * gnulib/import/localtime-buffer.c: Update.
3747 * gnulib/import/localtime-buffer.h: Update.
3748 * gnulib/import/lstat.c: Update.
3749 * gnulib/import/m4/00gnulib.m4: Update.
3750 * gnulib/import/m4/__inline.m4: Update.
3751 * gnulib/import/m4/absolute-header.m4: Update.
3752 * gnulib/import/m4/alloca.m4: Update.
3753 * gnulib/import/m4/builtin-expect.m4: Update.
3754 * gnulib/import/m4/canonicalize.m4: Update.
3755 * gnulib/import/m4/chdir-long.m4: Update.
3756 * gnulib/import/m4/close.m4: Update.
3757 * gnulib/import/m4/closedir.m4: Update.
3758 * gnulib/import/m4/configmake.m4: Update.
3759 * gnulib/import/m4/d-ino.m4: Update.
3760 * gnulib/import/m4/d-type.m4: Update.
3761 * gnulib/import/m4/dirent_h.m4: Update.
3762 * gnulib/import/m4/dirfd.m4: Update.
3763 * gnulib/import/m4/dirname.m4: Update.
3764 * gnulib/import/m4/double-slash-root.m4: Update.
3765 * gnulib/import/m4/dup.m4: Update.
3766 * gnulib/import/m4/dup2.m4: Update.
3767 * gnulib/import/m4/eealloc.m4: Update.
3768 * gnulib/import/m4/environ.m4: Update.
3769 * gnulib/import/m4/errno_h.m4: Update.
3770 * gnulib/import/m4/error.m4: Update.
3771 * gnulib/import/m4/exponentd.m4: Update.
3772 * gnulib/import/m4/exponentl.m4: Update.
3773 * gnulib/import/m4/extensions.m4: Update.
3774 * gnulib/import/m4/extern-inline.m4: Update.
3775 * gnulib/import/m4/fchdir.m4: Update.
3776 * gnulib/import/m4/fcntl-o.m4: Update.
3777 * gnulib/import/m4/fcntl.m4: Update.
3778 * gnulib/import/m4/fcntl_h.m4: Update.
3779 * gnulib/import/m4/fdopendir.m4: Update.
3780 * gnulib/import/m4/filenamecat.m4: Update.
3781 * gnulib/import/m4/flexmember.m4: Update.
3782 * gnulib/import/m4/float_h.m4: Update.
3783 * gnulib/import/m4/fnmatch.m4: Update.
3784 * gnulib/import/m4/fnmatch_h.m4: Update.
3785 * gnulib/import/m4/fpieee.m4: Update.
3786 * gnulib/import/m4/frexp.m4: Update.
3787 * gnulib/import/m4/frexpl.m4: Update.
3788 * gnulib/import/m4/fstat.m4: Update.
3789 * gnulib/import/m4/fstatat.m4: Update.
3790 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
3791 * gnulib/import/m4/getcwd-path-max.m4: Update.
3792 * gnulib/import/m4/getcwd.m4: Update.
3793 * gnulib/import/m4/getdtablesize.m4: Update.
3794 * gnulib/import/m4/getlogin.m4: Update.
3795 * gnulib/import/m4/getlogin_r.m4: Update.
3796 * gnulib/import/m4/getpagesize.m4: Update.
3797 * gnulib/import/m4/getprogname.m4: Update.
3798 * gnulib/import/m4/gettimeofday.m4: Update.
3799 * gnulib/import/m4/glibc21.m4: Update.
3800 * gnulib/import/m4/glob.m4: Update.
3801 * gnulib/import/m4/glob_h.m4: Update.
3802 * gnulib/import/m4/gnulib-cache.m4: Update.
3803 * gnulib/import/m4/gnulib-common.m4: Update.
3804 * gnulib/import/m4/gnulib-comp.m4: Update.
3805 * gnulib/import/m4/gnulib-tool.m4: Update.
3806 * gnulib/import/m4/hard-locale.m4: Update.
3807 * gnulib/import/m4/include_next.m4: Update.
3808 * gnulib/import/m4/inttypes-pri.m4: Update.
3809 * gnulib/import/m4/inttypes.m4: Update.
3810 * gnulib/import/m4/isnand.m4: Update.
3811 * gnulib/import/m4/isnanl.m4: Update.
3812 * gnulib/import/m4/largefile.m4: Update.
3813 * gnulib/import/m4/limits-h.m4: Update.
3814 * gnulib/import/m4/localcharset.m4: Update.
3815 * gnulib/import/m4/locale-fr.m4: Update.
3816 * gnulib/import/m4/locale-ja.m4: Update.
3817 * gnulib/import/m4/locale-zh.m4: Update.
3818 * gnulib/import/m4/localtime-buffer.m4: Update.
3819 * gnulib/import/m4/longlong.m4: Update.
3820 * gnulib/import/m4/lstat.m4: Update.
3821 * gnulib/import/m4/malloc.m4: Update.
3822 * gnulib/import/m4/malloca.m4: Update.
3823 * gnulib/import/m4/math_h.m4: Update.
3824 * gnulib/import/m4/mbrtowc.m4: Update.
3825 * gnulib/import/m4/mbsinit.m4: Update.
3826 * gnulib/import/m4/mbsrtowcs.m4: Update.
3827 * gnulib/import/m4/mbstate_t.m4: Update.
3828 * gnulib/import/m4/memchr.m4: Update.
3829 * gnulib/import/m4/memmem.m4: Update.
3830 * gnulib/import/m4/mempcpy.m4: Update.
3831 * gnulib/import/m4/memrchr.m4: Update.
3832 * gnulib/import/m4/mkdir.m4: Update.
3833 * gnulib/import/m4/mkstemp.m4: Update.
3834 * gnulib/import/m4/mmap-anon.m4: Update.
3835 * gnulib/import/m4/mode_t.m4: Update.
3836 * gnulib/import/m4/msvc-inval.m4: Update.
3837 * gnulib/import/m4/msvc-nothrow.m4: Update.
3838 * gnulib/import/m4/multiarch.m4: Update.
3839 * gnulib/import/m4/nocrash.m4: Update.
3840 * gnulib/import/m4/off_t.m4: Update.
3841 * gnulib/import/m4/onceonly.m4: Update.
3842 * gnulib/import/m4/open-cloexec.m4: Update.
3843 * gnulib/import/m4/open.m4: Update.
3844 * gnulib/import/m4/openat.m4: Update.
3845 * gnulib/import/m4/opendir.m4: Update.
3846 * gnulib/import/m4/pathmax.m4: Update.
3847 * gnulib/import/m4/rawmemchr.m4: Update.
3848 * gnulib/import/m4/readdir.m4: Update.
3849 * gnulib/import/m4/readlink.m4: Update.
3850 * gnulib/import/m4/realloc.m4: Update.
3851 * gnulib/import/m4/rename.m4: Update.
3852 * gnulib/import/m4/rewinddir.m4: Update.
3853 * gnulib/import/m4/rmdir.m4: Update.
3854 * gnulib/import/m4/save-cwd.m4: Update.
3855 * gnulib/import/m4/secure_getenv.m4: Update.
3856 * gnulib/import/m4/setenv.m4: Update.
3857 * gnulib/import/m4/signal_h.m4: Update.
3858 * gnulib/import/m4/ssize_t.m4: Update.
3859 * gnulib/import/m4/stat-time.m4: Update.
3860 * gnulib/import/m4/stat.m4: Update.
3861 * gnulib/import/m4/std-gnu11.m4: Update.
3862 * gnulib/import/m4/stdbool.m4: Update.
3863 * gnulib/import/m4/stddef_h.m4: Update.
3864 * gnulib/import/m4/stdint.m4: Update.
3865 * gnulib/import/m4/stdio_h.m4: Update.
3866 * gnulib/import/m4/stdlib_h.m4: Update.
3867 * gnulib/import/m4/strchrnul.m4: Update.
3868 * gnulib/import/m4/strdup.m4: Update.
3869 * gnulib/import/m4/strerror.m4: Update.
3870 * gnulib/import/m4/string_h.m4: Update.
3871 * gnulib/import/m4/strstr.m4: Update.
3872 * gnulib/import/m4/strtok_r.m4: Update.
3873 * gnulib/import/m4/sys_socket_h.m4: Update.
3874 * gnulib/import/m4/sys_stat_h.m4: Update.
3875 * gnulib/import/m4/sys_time_h.m4: Update.
3876 * gnulib/import/m4/sys_types_h.m4: Update.
3877 * gnulib/import/m4/tempname.m4: Update.
3878 * gnulib/import/m4/time_h.m4: Update.
3879 * gnulib/import/m4/unistd-safer.m4: Update.
3880 * gnulib/import/m4/unistd_h.m4: Update.
3881 * gnulib/import/m4/warn-on-use.m4: Update.
3882 * gnulib/import/m4/wchar_h.m4: Update.
3883 * gnulib/import/m4/wchar_t.m4: Update.
3884 * gnulib/import/m4/wctype_h.m4: Update.
3885 * gnulib/import/m4/wint_t.m4: Update.
3886 * gnulib/import/malloc.c: Update.
3887 * gnulib/import/malloc/scratch_buffer.h: Update.
3888 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
3889 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
3890 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
3891 * gnulib/import/malloca.c: Update.
3892 * gnulib/import/malloca.h: Update.
3893 * gnulib/import/malloca.valgrind: Update.
3894 * gnulib/import/math.in.h: Update.
3895 * gnulib/import/mbrtowc.c: Update.
3896 * gnulib/import/mbsinit.c: Update.
3897 * gnulib/import/mbsrtowcs-impl.h: Update.
3898 * gnulib/import/mbsrtowcs-state.c: Update.
3899 * gnulib/import/mbsrtowcs.c: Update.
3900 * gnulib/import/memchr.c: Update.
3901 * gnulib/import/memmem.c: Update.
3902 * gnulib/import/mempcpy.c: Update.
3903 * gnulib/import/memrchr.c: Update.
3904 * gnulib/import/mkdir.c: Update.
3905 * gnulib/import/mkstemp.c: Update.
3906 * gnulib/import/msvc-inval.c: Update.
3907 * gnulib/import/msvc-inval.h: Update.
3908 * gnulib/import/msvc-nothrow.c: Update.
3909 * gnulib/import/msvc-nothrow.h: Update.
3910 * gnulib/import/open.c: Update.
3911 * gnulib/import/openat-die.c: Update.
3912 * gnulib/import/openat-priv.h: Update.
3913 * gnulib/import/openat-proc.c: Update.
3914 * gnulib/import/openat.c: Update.
3915 * gnulib/import/openat.h: Update.
3916 * gnulib/import/opendir.c: Update.
3917 * gnulib/import/pathmax.h: Update.
3918 * gnulib/import/pipe-safer.c: Update.
3919 * gnulib/import/rawmemchr.c: Update.
3920 * gnulib/import/readdir.c: Update.
3921 * gnulib/import/readlink.c: Update.
3922 * gnulib/import/realloc.c: Update.
3923 * gnulib/import/ref-add.sin: Update.
3924 * gnulib/import/ref-del.sin: Update.
3925 * gnulib/import/rename.c: Update.
3926 * gnulib/import/rewinddir.c: Update.
3927 * gnulib/import/rmdir.c: Update.
3928 * gnulib/import/same-inode.h: Update.
3929 * gnulib/import/save-cwd.c: Update.
3930 * gnulib/import/save-cwd.h: Update.
3931 * gnulib/import/scratch_buffer.h: Update.
3932 * gnulib/import/secure_getenv.c: Update.
3933 * gnulib/import/setenv.c: Update.
3934 * gnulib/import/signal.in.h: Update.
3935 * gnulib/import/stat-time.c: Update.
3936 * gnulib/import/stat-time.h: Update.
3937 * gnulib/import/stat-w32.c: Update.
3938 * gnulib/import/stat-w32.h: Update.
3939 * gnulib/import/stat.c: Update.
3940 * gnulib/import/stdbool.in.h: Update.
3941 * gnulib/import/stddef.in.h: Update.
3942 * gnulib/import/stdint.in.h: Update.
3943 * gnulib/import/stdio.in.h: Update.
3944 * gnulib/import/stdlib.in.h: Update.
3945 * gnulib/import/str-two-way.h: Update.
3946 * gnulib/import/strchrnul.c: Update.
3947 * gnulib/import/strdup.c: Update.
3948 * gnulib/import/streq.h: Update.
3949 * gnulib/import/strerror-override.c: Update.
3950 * gnulib/import/strerror-override.h: Update.
3951 * gnulib/import/strerror.c: Update.
3952 * gnulib/import/string.in.h: Update.
3953 * gnulib/import/stripslash.c: Update.
3954 * gnulib/import/strnlen1.c: Update.
3955 * gnulib/import/strnlen1.h: Update.
3956 * gnulib/import/strstr.c: Update.
3957 * gnulib/import/strtok_r.c: Update.
3958 * gnulib/import/sys_stat.in.h: Update.
3959 * gnulib/import/sys_time.in.h: Update.
3960 * gnulib/import/sys_types.in.h: Update.
3961 * gnulib/import/tempname.c: Update.
3962 * gnulib/import/tempname.h: Update.
3963 * gnulib/import/time.in.h: Update.
3964 * gnulib/import/unistd--.h: Update.
3965 * gnulib/import/unistd-safer.h: Update.
3966 * gnulib/import/unistd.in.h: Update.
3967 * gnulib/import/unsetenv.c: Update.
3968 * gnulib/import/verify.h: Update.
3969 * gnulib/import/extra/snippet/warn-on-use.h: Update.
3970 * gnulib/import/wchar.in.h: Update.
3971 * gnulib/import/wctype.in.h: Update.
3972 * gnulib/import/xalloc-oversized.h: Update.
3973 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
3974 "53e2c179f26a890fa6685af4b6c1397ee370433b".
3976 2018-09-10 Simon Marchi <simon.marchi@ericsson.com>
3978 * record-btrace.c (get_thread_current_frame): Remove
3981 2018-09-10 Jerome Guitton <guitton@adacore.com>
3983 * ada-lang.c (ada_value_struct_elt): Call ada_to_fixed_type
3984 with check_tag to 1 if and only if the type is tagged and the
3985 component being searched cannot been found in the current
3986 view. Otherwise, always call ada_to_fixed_type with
3989 2018-09-10 Xavier Roirand <roirand@adacore.com>
3991 * ada-lang.c (ada_is_access_to_unconstrained_array): Remove static
3993 * ada-lang.h: add ada_is_access_to_unconstrained_array prototype.
3994 * ada-varobj.c (ada_varobj_get_number_of_children,
3995 ada_varobj_describe_child, ada_value_is_changeable_p): Cleanup code.
3997 2018-09-10 Xavier Roirand <roirand@adacore.com>
3999 * ada-valprint.c (ada_value_print): Use type instead of
4002 2018-09-10 Xavier Roirand <roirand@adacore.com>
4004 * ada-lang.c (ada_value_subscript): Handle case when parameter is
4005 an array of access to unconstrained array.
4007 2018-09-10 Xavier Roirand <roirand@adacore.com>
4009 * ada-lang.c (ada_is_access_to_unconstrained_array): New function.
4010 (ada_check_typedef): Use it.
4012 2018-09-10 Xavier Roirand <roirand@adacore.com>
4014 * ada-varobj.c (ada_varobj_describe_struct_child)
4015 (ada_varobj_describe_child): Handle union case like struct one.
4017 2018-09-10 Tom Tromey <tom@tromey.com>
4020 * python/python.c (_initialize_python): Make example in "python"
4021 help work in Python 3.
4023 2018-09-10 Eli Zaretskii <eliz@gnu.org>
4025 * Makefile.in (transformed_name): Use INSTALL_SCRIPT instead of
4026 INSTALL_PROGRAM to install gdb-add-index.sh. Don't append
4027 $(EXEEXT) to the script, as it is not a program.
4029 2018-09-09 Simon Marchi <simon.marchi@ericsson.com>
4031 * python/py-prettyprint.c (pretty_print_one_value): Return
4033 (print_string_repr): Adjust.
4034 (apply_varobj_pretty_printer): Return gdbpy_ref<>.
4035 * python/python-internal.h (apply_varobj_pretty_printer): Return
4037 * varobj.c (varobj_value_get_print_value): Adjust.
4039 2018-09-08 Tom Tromey <tom@tromey.com>
4042 * python/py-prettyprint.c (pretty_print_one_value): Check for
4045 2018-09-08 Joel Brobecker <brobecker@adacore.com>
4047 * ada-lang.c (resolve_subexp): Pass correct OPLEN in call to
4048 replace_operator_with_call.
4050 2018-09-08 Joel Brobecker <brobecker@adacore.com>
4052 * ada-lang.c (ada_value_cast): Remove unnecessary parentheses.
4054 2018-09-08 Joel Brobecker <brobecker@adacore.com>
4056 * ada-typeprint.c (print_range): Print the bounds using TYPE
4057 rather than its TYPE_TARGET_TYPE.
4059 2018-09-08 Joel Brobecker <brobecker@adacore.com>
4061 * ada-lang.c (ada_to_fixed_value): Minor reformatting in
4062 call to ada_to_fixed_value_create.
4064 2018-09-08 Jerome Guitton <guitton@adacore.com>
4066 * ada-lang.c (ada_decode): strip dot prefix in symbol name.
4068 2018-09-08 Joel Brobecker <brobecker@adacore.com>
4070 * ada-lang.c (ada_exception_sal): Replace gdb_assert calls
4073 2018-09-08 Joel Brobecker <brobecker@adacore.com>
4075 * ada-lang.c (ada_unhandled_exception_name_addr_from_raise):
4076 Move update of loop variable "fi".
4078 2018-09-08 Joel Brobecker <brobecker@adacore.com>
4080 * ada-lang.c (value_assign_to_component): In the case of
4081 big-endian targets, extract the bits of the given VAL
4082 using an src_offset of zero if container is not a scalar.
4084 2018-09-06 Simon Ser <contact@emersion.fr>
4087 * fbsd-nat.c (fbsd_nat_target::xfer_partial): Add support for
4088 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
4089 * fbsd-tdep.c (fbsd_make_note_desc): New.
4090 (fbsd_make_corefile_notes): Write NT_PROCSTAT_AUXV,
4091 NT_PROCSTAT_VMMAP and NT_PROCSTAT_PS_STRINGS notes.
4092 * target.h (enum target_object) Add FreeBSD-specific
4093 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
4095 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
4097 * compile/compile-c.h (generate_c_for_variable_locations):
4098 Change reference to pointer.
4099 * compile/compile-c-support.c (compile_program) <compute>:
4101 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
4102 (generate_c_for_for_one_variable): Likewise
4103 (generate_c_for_variable_locations): Likewise
4104 * compile/compile-c-types.c (compile_c_instance::convert_type):
4106 * compile/compile-cplus-symbols.c (convert_one_symbol):
4107 std::move the scope passed to enter_scope.
4108 * compile/compile-cplus-types.c
4109 (compile_cplus_instance::enter_scope): Make parameter
4111 (compile_cplus_instance::new_scope): Change reference to
4113 (compile_cplus_instance::convert_type): Likewise
4114 (compile_cplus_convert_typedef): std::move the scope passed to
4116 (compile_cplus_convert_struct_or_union): Likewise.
4117 (compile_cplus_convert_enum): Likewise.
4118 (compile_cplus_convert_namespace): Likewise.
4119 * compile/compile-cplus.h (compile_cplus_instance)
4120 <enter_scope>: Make parameter rvalue-reference.
4121 * compile/compile-internal.h (compile_instance)
4122 <get_cached_type>: Likewise
4123 * compile/compile-loc2c.c (push): Likewise
4127 (print_label): Likewise
4128 (pushf_register_address): Likewise
4129 (pushf_register): Likewise
4130 (do_compile_dwarf_expr_to_c): Likewise
4131 (compile_dwarf_expr_to_c): Likewise
4132 (compile_dwarf_bounds_to_c): Likewise
4133 * compile/compile.c (compile_instance::get_cached_type):
4135 * compile/compile.h (compile_dwarf_expr_to_c): Likewise.
4136 (compile_dwarf_bounds_to_c): Likewise
4137 * dwarf2loc.c (locexpr_generate_c_location): Likewise.
4138 (dwarf2_compile_property_to_c): Likewise
4139 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise
4140 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
4143 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
4145 * tui/tui-data.h (struct tui_win_element) <highlight>: Remove.
4146 * tui/tui-data.c (init_content_element): Don't initialize it.
4148 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
4150 * tui/tui-data.h (struct tui_win_info)
4151 <detail::opaque>: Remove.
4152 * tui/tui-data.c (init_win_info): Remove assignment.
4154 2018-09-05 Tom Tromey <tom@tromey.com>
4156 * warning.m4 (AM_GDB_WARNINGS): Add -Wformat when testing
4157 -Wformat-nonliteral.
4158 * target-float.c (host_float_ops<T>::to_string)
4159 (host_float_ops<T>::from_string): Use
4160 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
4161 * configure: Rebuild.
4163 2018-09-05 Simon Marchi <simon.marchi@ericsson.com>
4165 * printcmd.c (printf_c_string): Use
4166 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
4167 (printf_wide_c_string, printf_pointer, ui_printf): Likewise.
4169 2018-09-05 Tom Tromey <tom@tromey.com>
4171 * cli/cli-cmds.c (shell_escape, edit_command): Remove cast.
4173 2018-09-05 Tom de Vries <tdevries@suse.de>
4175 * dwarf2loc.c (sect_variable_value): Call indirect_synthetic_pointer
4176 with resolve_abstract_p == true.
4177 (indirect_synthetic_pointer): Add resolve_abstract_p parameter,
4178 defaulting to false. Propagate resolve_abstract_p to
4179 dwarf2_fetch_die_loc_sect_off.
4180 * dwarf2loc.h (dwarf2_fetch_die_loc_sect_off): Add resolve_abstract_p
4181 parameter, defaulting to false.
4182 * dwarf2read.c (read_variable): Add variable to abstract_to_concrete.
4183 (dwarf2_fetch_die_loc_sect_off): Add and handle resolve_abstract_p
4185 * dwarf2read.h (struct die_info): Forward-declare.
4186 (die_info_ptr): New typedef.
4187 (struct dwarf2_per_objfile): Add abstract_to_concrete field.
4189 2018-09-05 Joel Brobecker <brobecker@adacore.com>
4193 2018-09-04 Sergio Durigan Junior <sergiodj@redhat.com>
4194 Pedro Alves <palves@redhat.com>
4196 * gnulib/Makefile.in (aclocal_m4_deps): Move to
4197 "aclocal-m4-deps.mk". Include file here.
4198 $(srcdir)/aclocal.m4: Add "configure.ac".
4199 * gnulib/aclocal-m4-deps.mk: New file.
4200 * gnulib/update-gnulib.sh: Automatically update
4201 "aclocal-m4-deps.mk".
4203 2018-09-04 Tom Tromey <tom@tromey.com>
4205 * configure: Rebuild.
4206 * configure.ac: Remove multi-ice code.
4208 2018-09-04 Tom Tromey <tom@tromey.com>
4210 * Makefile.in (GDB_WARN_CFLAGS_NO_DEFS): Remove.
4211 (ada-exp.o): Update.
4213 2018-09-04 Tom Tromey <tom@tromey.com>
4215 * Makefile.in (printcmd.o, target-float.o): Remove.
4216 (GDB_WARN_CFLAGS_NO_FORMAT): Remove.
4218 2018-09-04 Tom Tromey <tom@tromey.com>
4220 * gnulib/Makefile.in: Remove obsolete comment.
4221 * Makefile.in: Remove obsolete comment.
4223 2018-09-04 Andrew Burgess <andrew.burgess@embecosm.com>
4225 * riscv-tdep.c (riscv_frame_cache): Fix ARI warning, don't end a
4228 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
4230 * riscv-tdep.c: Add 'prologue-value.h' include.
4231 (struct riscv_unwind_cache): New struct.
4232 (riscv_debug_unwinder): New global.
4233 (riscv_scan_prologue): Update arguments, capture register details
4235 (riscv_skip_prologue): Reformat arguments line, move end of
4236 prologue calculation into riscv_scan_prologue.
4237 (riscv_frame_cache): Update return type, create
4238 riscv_unwind_cache, scan the prologue, and fill in remaining cache
4240 (riscv_frame_this_id): Use frame id computed in riscv_frame_cache.
4241 (riscv_frame_prev_register): Use the trad_frame within the
4243 (_initialize_riscv_tdep): Add 'set/show debug riscv unwinder'
4246 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
4248 * trad-frame.h (trad_frame_set_realreg): Declare.
4249 (trad_frame_set_addr): Declare.
4250 * trad-frame.c (trad_frame_set_realreg): Define new function.
4251 (trad_frame_set_addr): Define new function.
4252 (trad_frame_set_reg_realreg): Use new function.
4253 (trad_frame_set_reg_addr): Use new function.
4255 2018-09-01 Keith Seitz <keiths@redhat.com>
4257 * compile/compile-cplus-types.c (compile_cplus_debug_output_1): Use
4258 pulongest instead of "%lld".
4259 * compile/compile-cplus-symbols.c (gcc_cplus_convert_symbol): Remove
4262 2018-08-31 Tom Tromey <tom@tromey.com>
4264 * dwarf2read.c (dwarf2_add_field): Set the TYPE_LENGTH of the
4267 2018-08-31 Pedro Alves <palves@redhat.com>
4269 * gdbarch.h: Regenerate.
4271 2018-08-31 Pedro Alves <palves@redhat.com>
4273 * gdbarch.sh (have_nonsteppable_watchpoint): Add comment.
4274 * target.h (Hardware watchpoint interfaces): Describe
4275 continuable/steppable/non-steppable watchpoints.
4276 * gdbarch.h, gdbarch.c: Regenerate.
4278 2018-08-31 Pedro Alves <palves@redhat.com>
4280 * nto-procfs.c (nto_procfs_target::have_continuable_watchpoint):
4283 (s390_linux_nat_target::have_continuable_watchpoint): Delete.
4284 * target.h (target_ops::have_continuable_watchpoint): Delete.
4285 (target_have_continuable_watchpoint): Delete.
4286 * x86-nat.h (x86_nat_target::have_continuable_watchpoint): Delete.
4287 * target-delegates.c: Regenerate.
4289 2018-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
4291 * gnulib/Makefile.in (aclocal_m4_deps): Update according to
4292 the files present in "gnulib/import/m4/".
4294 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
4296 * riscv-tdep.c (riscv_insn::decode): Decode c.addi4spn, c.sd,
4297 c.sw, c.swsp, and c.sdsp.
4299 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
4301 * riscv-tdep.c (struct riscv_inferior_data): Delete.
4302 (riscv_read_misa_reg): Don't cache value read into inferior data.
4303 (riscv_new_inferior_data): Delete.
4304 (riscv_inferior_data_cleanup): Delete.
4305 (riscv_inferior_data): Delete.
4306 (riscv_invalidate_inferior_data): Delete.
4307 (_initialize_riscv_tdep): Remove initialisation of inferior data.
4309 2018-08-30 Simon Marchi <simon.marchi@ericsson.com>
4311 * compile/compile-cplus-types.c
4312 (compile_cplus_instance::leave_scope): Take the address of scope
4314 (compile_cplus_instance::convert_qualified_base): Compare quals
4317 2018-08-30 Keith Seitz <keiths@redhat.com>
4319 * compile/compile-cplus-types.c (compile_cplus_instance::enter_scope):
4320 Use "%s" and host_address_to_string instead of "%p" in printf.
4322 2018-08-29 Keith Seitz <keiths@redhat.com>
4324 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Add compile-cplus-symbols.c
4325 and compile-cplus-types.c.
4326 (HFILES_NO_SRCDIR): Add gcc-cp-plugin.h.
4327 * c-lang.c (cplus_language_defn): Set C++ compile functions.
4328 * c-lang.h (cplus_get_compile_context, cplus_compute_program):
4330 * compile/compile-c-support.c: Include compile-cplus.h.
4331 (load_libcompile): Templatize.
4332 (get_compile_context): "New" function.
4333 (c_get_compile_context): Use get_compile_context.
4334 (cplus_get_compile_context): New function.
4335 (cplus_push_user_expression, cplus_pop_user_expression)
4336 (cplus_add_code_header, cplus_add_input, cplus_compile_program)
4337 (cplus_compute_program): Define new structs/functions.
4338 * compile/compile-cplus-symmbols.c: New file.
4339 * compile/compile-cplus-types.c: New file.
4340 * compile/compile-cplus.h: New file.
4341 * compile/compile-internal.h (debug_compile_oracle, GCC_TYPE_NONE):
4343 * compile/compile-object-load.c (get_out_value_type): Use
4344 strncmp_iw when comparing symbol names.
4345 (compile_object_load): Add mst_bss and mst_data.
4346 * compile/compile.c (_initialize_compile): Remove
4347 -Wno-implicit-function-declaration from `compile_args'.
4348 * compile/gcc-cp-plugin.h: New file.
4349 * NEWS: Mention C++ compile support and new debug options.
4351 2018-08-29 Keith Seitz <keiths@redhat.com>
4353 * linespec.c (collect_info::add_symbol): Make virtual.
4354 (struct symbol_searcher_collect_info): New struct.
4355 (symbol_searcher::find_all_symbols): New method.
4356 * symtab.h (class symbol_searcher): New class.
4358 2018-08-29 Keith Seitz <keiths@redhat.com>
4360 * linespec.c (struct linespec) <function_symbols, label_symbols>:
4361 Change to vector of block_symbol. Update all users.
4362 (struct collect_info) <symbols>: Likewise.
4363 (collect_info::add_symbol): Take block_symbol as argument.
4365 (decode_compound_collector) <m_symbols>: Change type to vector
4366 of block_symbol. Update all users.
4367 (decode_compound_collector::operator ()): Change parameter type
4369 (find_method, find_function_symbols, find_linespec_symbols)
4370 (find_label_symbols_in_block, find_label_symbols): Change symbol
4371 vectors to block_symbol vectors.
4372 * symtab.h (symbol_found_callback_ftype): Change parameter type to
4375 2018-08-29 Keith Seitz <keiths@redhat.com>
4377 * linespec.c (symbolp): Remove typedef and VEC definitions.
4378 (bound_minimal_symbol_d): Likewise.
4380 2018-08-29 Keith Seitz <keiths@redhat.com>
4382 * linespec.c (decode_compound_collector::decode_compound_collector):
4383 Remove initialization for `m_symtabs'.
4384 (decode_compound_collector::release_symbols): Change return type
4385 to std::vector. Update all callers.
4386 (class decode_compound_collector) <m_symbols>: Change type to
4388 (lookup_prefix_sym): Change return type to std::vector. Update all
4390 (compare_symbols): Remove.
4391 (std_compare_symbols): Rename to `compare_symbols'.
4392 (find_method): Change `sym_classes' parameter to std::vector.
4393 Update all callers. Use std::sort to sort sym_classes.
4394 (find_linespec_symbols): Remove cleanup.
4396 2018-08-29 Keith Seitz <keiths@redhat.com>
4398 * linespec.c (struct linespec) <minimal_symbols>: Change type to
4399 std::vector. Update all users.
4400 (convert_linespec_to_sals): Use std::sort to sort minimal symbols.
4401 (struct collect_info) <minimal_symbols>: Likewise.
4402 (compare_msymbols): Return bool. Change parameters to const
4403 bound_minimal_symbol references.
4404 (find_method, find_function_symbols, find_linespec_symbols): Change
4405 `minsyms' parameter to std::vector. Update all callers.
4407 2018-08-29 Keith Seitz <keiths@redhat.com>
4409 * linespec.c (struct linespec) <label_symbols>: Change type to
4410 std::vector. Update all users.
4411 (find_label_symbols_in_block): Change `result' parameter to
4412 std::vector. Update all callers.
4413 (find_label_symbols): Return std::vector. Update all callers.
4415 2018-08-29 Keith Seitz <keiths@redhat.com>
4417 * linespec.c (struct linespec) <function_symbols>: Change type to
4418 std::vector. Update all users.
4419 (struct collect_info) <function_symbols>: Likewise.
4420 (convert_linespec_to_sals): Use std::sort to sort function_symbols.
4421 (std_compare_symbols): New function.
4422 (find_method, find_function_symbols, find_linespec_symbols)
4423 (find_label_symbols_in_block): Change `symbols' parameter to
4424 std::vector. Update all callers.
4425 (find_label_symbols): Likewise for `function_symbols' and
4428 2018-08-29 Keith Seitz <keiths@redhat.com>
4430 * linespec.c (symtab_vector_up): Define.
4431 (struct linespec) <file_symtabs>: Change type to std::vector *.
4433 (struct collect_info) <file_symtabs>: Likewise.
4434 (collect_symtabs_from_filename): Return symtab_vector_up.
4436 (decode_objc): Remove cleanup.
4437 (symtab_collector::symtab_collector): Initialize `m_symtabs'.
4438 (symtab_collector::release_symtabs): Return symtab_vector_up.
4440 (class symtab_collector) <m_symtabs>: Change type to symtab_vector_up.
4442 (collect_symtabs_from_filename, symtabs_from_filename): Return
4443 symtab_vector_up. Update all callers.
4445 2018-08-29 Tom Tromey <tom@tromey.com>
4447 * csky-tdep.c (csky_analyze_prologue): Use
4448 core_addr_to_string_nz.
4450 2018-08-29 Tom Tromey <tom@tromey.com>
4452 * windows-nat.c (struct xlate_exception) <them>: Change type to
4454 (xlate): Fix formatting. Remove last entry.
4455 (struct xlate_exception, xlate): Comment out.
4456 (windows_nat_target::resume): Use ranged for.
4458 2018-08-29 Jim Wilson <jimw@sifive.com>
4460 * riscv-linux-nat.c: Include elf/common.h instead of elf.h.
4461 (riscv_linux_nat_target::fetch_registers): Use NT_FPREGSET instead
4463 (riscv_linux_nat_target::store_registers): Likewise.
4465 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
4469 * gnulib/aclocal.m4: Regenerate.
4470 * gnulib/config.in: Regenerate.
4471 * gnulib/configure: Regenerate.
4472 * gnulib/import/Makefile.am: Update.
4473 * gnulib/import/Makefile.in: Update.
4474 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
4475 * gnulib/import/_Noreturn.h: ... this.
4476 * gnulib/import/alloca.in.h: Update.
4477 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
4478 * gnulib/import/arg-nonnull.h: ... this.
4479 * gnulib/import/assure.h: Update.
4480 * gnulib/import/at-func.c: Update.
4481 * gnulib/import/basename-lgpl.c: Update.
4482 * gnulib/import/extra/snippet/c++defs.h: Rename to...
4483 * gnulib/import/c++defs.h: ... this.
4484 * gnulib/import/canonicalize-lgpl.c: Update.
4485 * gnulib/import/cdefs.h: Update.
4486 * gnulib/import/chdir-long.c: Update.
4487 * gnulib/import/chdir-long.h: Update.
4488 * gnulib/import/cloexec.c: Update.
4489 * gnulib/import/cloexec.h: Update.
4490 * gnulib/import/close.c: Update.
4491 * gnulib/import/closedir.c: Update.
4492 * gnulib/import/config.charset: Update.
4493 * gnulib/import/dirent-private.h: Update.
4494 * gnulib/import/dirent.in.h: Update.
4495 * gnulib/import/dirfd.c: Update.
4496 * gnulib/import/dirname-lgpl.c: Update.
4497 * gnulib/import/dirname.h: Update.
4498 * gnulib/import/dosname.h: Update.
4499 * gnulib/import/dup-safer-flag.c: Update.
4500 * gnulib/import/dup-safer.c: Update.
4501 * gnulib/import/dup.c: Update.
4502 * gnulib/import/dup2.c: Update.
4503 * gnulib/import/errno.in.h: Update.
4504 * gnulib/import/error.c: Update.
4505 * gnulib/import/error.h: Update.
4506 * gnulib/import/exitfail.c: Update.
4507 * gnulib/import/exitfail.h: Update.
4508 * gnulib/import/extra/update-copyright: Update.
4509 * gnulib/import/fchdir.c: Update.
4510 * gnulib/import/fcntl.c: Update.
4511 * gnulib/import/fcntl.in.h: Update.
4512 * gnulib/import/fd-hook.c: Update.
4513 * gnulib/import/fd-hook.h: Update.
4514 * gnulib/import/fd-safer-flag.c: Update.
4515 * gnulib/import/fd-safer.c: Update.
4516 * gnulib/import/fdopendir.c: Update.
4517 * gnulib/import/filename.h: Update.
4518 * gnulib/import/filenamecat-lgpl.c: Update.
4519 * gnulib/import/filenamecat.h: Update.
4520 * gnulib/import/flexmember.h: Update.
4521 * gnulib/import/float+.h: Update.
4522 * gnulib/import/float.c: Update.
4523 * gnulib/import/float.in.h: Update.
4524 * gnulib/import/fnmatch.c: Update.
4525 * gnulib/import/fnmatch.in.h: Update.
4526 * gnulib/import/fnmatch_loop.c: Update.
4527 * gnulib/import/fpucw.h: Update.
4528 * gnulib/import/frexp.c: Update.
4529 * gnulib/import/frexpl.c: Update.
4530 * gnulib/import/fstat.c: Update.
4531 * gnulib/import/fstatat.c: Update.
4532 * gnulib/import/getcwd-lgpl.c: Update.
4533 * gnulib/import/getcwd.c: Update.
4534 * gnulib/import/getdtablesize.c: Update.
4535 * gnulib/import/getlogin_r.c: Update.
4536 * gnulib/import/getprogname.c: Update.
4537 * gnulib/import/getprogname.h: Update.
4538 * gnulib/import/gettext.h: Update.
4539 * gnulib/import/gettimeofday.c: Update.
4540 * gnulib/import/glob-libc.h: Update.
4541 * gnulib/import/glob.c: Update.
4542 * gnulib/import/glob.in.h: Update.
4543 * gnulib/import/glob_internal.h: Update.
4544 * gnulib/import/glob_pattern_p.c: Update.
4545 * gnulib/import/globfree.c: Update.
4546 * gnulib/import/hard-locale.c: Update.
4547 * gnulib/import/hard-locale.h: Update.
4548 * gnulib/import/intprops.h: Update.
4549 * gnulib/import/inttypes.in.h: Update.
4550 * gnulib/import/isnan.c: Update.
4551 * gnulib/import/isnand-nolibm.h: Update.
4552 * gnulib/import/isnand.c: Update.
4553 * gnulib/import/isnanl-nolibm.h: Update.
4554 * gnulib/import/isnanl.c: Update.
4555 * gnulib/import/itold.c: Update.
4556 * gnulib/import/libc-config.h: Update.
4557 * gnulib/import/limits.in.h: Update.
4558 * gnulib/import/localcharset.c: Update.
4559 * gnulib/import/localcharset.h: Update.
4560 * gnulib/import/localtime-buffer.c: Update.
4561 * gnulib/import/localtime-buffer.h: Update.
4562 * gnulib/import/lstat.c: Update.
4563 * gnulib/import/m4/00gnulib.m4: Update.
4564 * gnulib/import/m4/__inline.m4: Update.
4565 * gnulib/import/m4/absolute-header.m4: Update.
4566 * gnulib/import/m4/alloca.m4: Update.
4567 * gnulib/import/m4/builtin-expect.m4: Update.
4568 * gnulib/import/m4/canonicalize.m4: Update.
4569 * gnulib/import/m4/chdir-long.m4: Update.
4570 * gnulib/import/m4/close.m4: Update.
4571 * gnulib/import/m4/closedir.m4: Update.
4572 * gnulib/import/m4/configmake.m4: Update.
4573 * gnulib/import/m4/d-ino.m4: Update.
4574 * gnulib/import/m4/d-type.m4: Update.
4575 * gnulib/import/m4/dirent_h.m4: Update.
4576 * gnulib/import/m4/dirfd.m4: Update.
4577 * gnulib/import/m4/dirname.m4: Update.
4578 * gnulib/import/m4/double-slash-root.m4: Update.
4579 * gnulib/import/m4/dup.m4: Update.
4580 * gnulib/import/m4/dup2.m4: Update.
4581 * gnulib/import/m4/eealloc.m4: Update.
4582 * gnulib/import/m4/environ.m4: Update.
4583 * gnulib/import/m4/errno_h.m4: Update.
4584 * gnulib/import/m4/error.m4: Update.
4585 * gnulib/import/m4/exponentd.m4: Update.
4586 * gnulib/import/m4/exponentl.m4: Update.
4587 * gnulib/import/m4/extensions.m4: Update.
4588 * gnulib/import/m4/extern-inline.m4: Update.
4589 * gnulib/import/m4/fchdir.m4: Update.
4590 * gnulib/import/m4/fcntl-o.m4: Update.
4591 * gnulib/import/m4/fcntl.m4: Update.
4592 * gnulib/import/m4/fcntl_h.m4: Update.
4593 * gnulib/import/m4/fdopendir.m4: Update.
4594 * gnulib/import/m4/filenamecat.m4: Update.
4595 * gnulib/import/m4/flexmember.m4: Update.
4596 * gnulib/import/m4/float_h.m4: Update.
4597 * gnulib/import/m4/fnmatch.m4: Update.
4598 * gnulib/import/m4/fnmatch_h.m4: Update.
4599 * gnulib/import/m4/fpieee.m4: Update.
4600 * gnulib/import/m4/frexp.m4: Update.
4601 * gnulib/import/m4/frexpl.m4: Update.
4602 * gnulib/import/m4/fstat.m4: Update.
4603 * gnulib/import/m4/fstatat.m4: Update.
4604 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
4605 * gnulib/import/m4/getcwd-path-max.m4: Update.
4606 * gnulib/import/m4/getcwd.m4: Update.
4607 * gnulib/import/m4/getdtablesize.m4: Update.
4608 * gnulib/import/m4/getlogin.m4: Update.
4609 * gnulib/import/m4/getlogin_r.m4: Update.
4610 * gnulib/import/m4/getpagesize.m4: Update.
4611 * gnulib/import/m4/getprogname.m4: Update.
4612 * gnulib/import/m4/gettimeofday.m4: Update.
4613 * gnulib/import/m4/glibc21.m4: Update.
4614 * gnulib/import/m4/glob.m4: Update.
4615 * gnulib/import/m4/glob_h.m4: Update.
4616 * gnulib/import/m4/gnulib-cache.m4: Update.
4617 * gnulib/import/m4/gnulib-common.m4: Update.
4618 * gnulib/import/m4/gnulib-comp.m4: Update.
4619 * gnulib/import/m4/gnulib-tool.m4: Update.
4620 * gnulib/import/m4/hard-locale.m4: Update.
4621 * gnulib/import/m4/include_next.m4: Update.
4622 * gnulib/import/m4/inttypes-pri.m4: Update.
4623 * gnulib/import/m4/inttypes.m4: Update.
4624 * gnulib/import/m4/isnand.m4: Update.
4625 * gnulib/import/m4/isnanl.m4: Update.
4626 * gnulib/import/m4/largefile.m4: Update.
4627 * gnulib/import/m4/limits-h.m4: Update.
4628 * gnulib/import/m4/localcharset.m4: Update.
4629 * gnulib/import/m4/locale-fr.m4: Update.
4630 * gnulib/import/m4/locale-ja.m4: Update.
4631 * gnulib/import/m4/locale-zh.m4: Update.
4632 * gnulib/import/m4/localtime-buffer.m4: Update.
4633 * gnulib/import/m4/longlong.m4: Update.
4634 * gnulib/import/m4/lstat.m4: Update.
4635 * gnulib/import/m4/malloc.m4: Update.
4636 * gnulib/import/m4/malloca.m4: Update.
4637 * gnulib/import/m4/math_h.m4: Update.
4638 * gnulib/import/m4/mbrtowc.m4: Update.
4639 * gnulib/import/m4/mbsinit.m4: Update.
4640 * gnulib/import/m4/mbsrtowcs.m4: Update.
4641 * gnulib/import/m4/mbstate_t.m4: Update.
4642 * gnulib/import/m4/memchr.m4: Update.
4643 * gnulib/import/m4/memmem.m4: Update.
4644 * gnulib/import/m4/mempcpy.m4: Update.
4645 * gnulib/import/m4/memrchr.m4: Update.
4646 * gnulib/import/m4/mkdir.m4: Update.
4647 * gnulib/import/m4/mkstemp.m4: Update.
4648 * gnulib/import/m4/mmap-anon.m4: Update.
4649 * gnulib/import/m4/mode_t.m4: Update.
4650 * gnulib/import/m4/msvc-inval.m4: Update.
4651 * gnulib/import/m4/msvc-nothrow.m4: Update.
4652 * gnulib/import/m4/multiarch.m4: Update.
4653 * gnulib/import/m4/nocrash.m4: Update.
4654 * gnulib/import/m4/off_t.m4: Update.
4655 * gnulib/import/m4/onceonly.m4: Update.
4656 * gnulib/import/m4/open-cloexec.m4: Update.
4657 * gnulib/import/m4/open.m4: Update.
4658 * gnulib/import/m4/openat.m4: Update.
4659 * gnulib/import/m4/opendir.m4: Update.
4660 * gnulib/import/m4/pathmax.m4: Update.
4661 * gnulib/import/m4/rawmemchr.m4: Update.
4662 * gnulib/import/m4/readdir.m4: Update.
4663 * gnulib/import/m4/readlink.m4: Update.
4664 * gnulib/import/m4/realloc.m4: Update.
4665 * gnulib/import/m4/rename.m4: Update.
4666 * gnulib/import/m4/rewinddir.m4: Update.
4667 * gnulib/import/m4/rmdir.m4: Update.
4668 * gnulib/import/m4/save-cwd.m4: Update.
4669 * gnulib/import/m4/secure_getenv.m4: Update.
4670 * gnulib/import/m4/setenv.m4: Update.
4671 * gnulib/import/m4/signal_h.m4: Update.
4672 * gnulib/import/m4/ssize_t.m4: Update.
4673 * gnulib/import/m4/stat-time.m4: Update.
4674 * gnulib/import/m4/stat.m4: Update.
4675 * gnulib/import/m4/std-gnu11.m4: Update.
4676 * gnulib/import/m4/stdbool.m4: Update.
4677 * gnulib/import/m4/stddef_h.m4: Update.
4678 * gnulib/import/m4/stdint.m4: Update.
4679 * gnulib/import/m4/stdio_h.m4: Update.
4680 * gnulib/import/m4/stdlib_h.m4: Update.
4681 * gnulib/import/m4/strchrnul.m4: Update.
4682 * gnulib/import/m4/strdup.m4: Update.
4683 * gnulib/import/m4/strerror.m4: Update.
4684 * gnulib/import/m4/string_h.m4: Update.
4685 * gnulib/import/m4/strstr.m4: Update.
4686 * gnulib/import/m4/strtok_r.m4: Update.
4687 * gnulib/import/m4/sys_socket_h.m4: Update.
4688 * gnulib/import/m4/sys_stat_h.m4: Update.
4689 * gnulib/import/m4/sys_time_h.m4: Update.
4690 * gnulib/import/m4/sys_types_h.m4: Update.
4691 * gnulib/import/m4/tempname.m4: Update.
4692 * gnulib/import/m4/time_h.m4: Update.
4693 * gnulib/import/m4/unistd-safer.m4: Update.
4694 * gnulib/import/m4/unistd_h.m4: Update.
4695 * gnulib/import/m4/warn-on-use.m4: Update.
4696 * gnulib/import/m4/wchar_h.m4: Update.
4697 * gnulib/import/m4/wchar_t.m4: Update.
4698 * gnulib/import/m4/wctype_h.m4: Update.
4699 * gnulib/import/m4/wint_t.m4: Update.
4700 * gnulib/import/malloc.c: Update.
4701 * gnulib/import/malloc/scratch_buffer.h: Update.
4702 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
4703 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
4704 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
4705 * gnulib/import/malloca.c: Update.
4706 * gnulib/import/malloca.h: Update.
4707 * gnulib/import/malloca.valgrind: Update.
4708 * gnulib/import/math.in.h: Update.
4709 * gnulib/import/mbrtowc.c: Update.
4710 * gnulib/import/mbsinit.c: Update.
4711 * gnulib/import/mbsrtowcs-impl.h: Update.
4712 * gnulib/import/mbsrtowcs-state.c: Update.
4713 * gnulib/import/mbsrtowcs.c: Update.
4714 * gnulib/import/memchr.c: Update.
4715 * gnulib/import/memmem.c: Update.
4716 * gnulib/import/mempcpy.c: Update.
4717 * gnulib/import/memrchr.c: Update.
4718 * gnulib/import/mkdir.c: Update.
4719 * gnulib/import/mkstemp.c: Update.
4720 * gnulib/import/msvc-inval.c: Update.
4721 * gnulib/import/msvc-inval.h: Update.
4722 * gnulib/import/msvc-nothrow.c: Update.
4723 * gnulib/import/msvc-nothrow.h: Update.
4724 * gnulib/import/open.c: Update.
4725 * gnulib/import/openat-die.c: Update.
4726 * gnulib/import/openat-priv.h: Update.
4727 * gnulib/import/openat-proc.c: Update.
4728 * gnulib/import/openat.c: Update.
4729 * gnulib/import/openat.h: Update.
4730 * gnulib/import/opendir.c: Update.
4731 * gnulib/import/pathmax.h: Update.
4732 * gnulib/import/pipe-safer.c: Update.
4733 * gnulib/import/rawmemchr.c: Update.
4734 * gnulib/import/readdir.c: Update.
4735 * gnulib/import/readlink.c: Update.
4736 * gnulib/import/realloc.c: Update.
4737 * gnulib/import/ref-add.sin: Update.
4738 * gnulib/import/ref-del.sin: Update.
4739 * gnulib/import/rename.c: Update.
4740 * gnulib/import/rewinddir.c: Update.
4741 * gnulib/import/rmdir.c: Update.
4742 * gnulib/import/same-inode.h: Update.
4743 * gnulib/import/save-cwd.c: Update.
4744 * gnulib/import/save-cwd.h: Update.
4745 * gnulib/import/scratch_buffer.h: Update.
4746 * gnulib/import/secure_getenv.c: Update.
4747 * gnulib/import/setenv.c: Update.
4748 * gnulib/import/signal.in.h: Update.
4749 * gnulib/import/stat-time.c: Update.
4750 * gnulib/import/stat-time.h: Update.
4751 * gnulib/import/stat-w32.c: Update.
4752 * gnulib/import/stat-w32.h: Update.
4753 * gnulib/import/stat.c: Update.
4754 * gnulib/import/stdbool.in.h: Update.
4755 * gnulib/import/stddef.in.h: Update.
4756 * gnulib/import/stdint.in.h: Update.
4757 * gnulib/import/stdio.in.h: Update.
4758 * gnulib/import/stdlib.in.h: Update.
4759 * gnulib/import/str-two-way.h: Update.
4760 * gnulib/import/strchrnul.c: Update.
4761 * gnulib/import/strdup.c: Update.
4762 * gnulib/import/streq.h: Update.
4763 * gnulib/import/strerror-override.c: Update.
4764 * gnulib/import/strerror-override.h: Update.
4765 * gnulib/import/strerror.c: Update.
4766 * gnulib/import/string.in.h: Update.
4767 * gnulib/import/stripslash.c: Update.
4768 * gnulib/import/strnlen1.c: Update.
4769 * gnulib/import/strnlen1.h: Update.
4770 * gnulib/import/strstr.c: Update.
4771 * gnulib/import/strtok_r.c: Update.
4772 * gnulib/import/sys_stat.in.h: Update.
4773 * gnulib/import/sys_time.in.h: Update.
4774 * gnulib/import/sys_types.in.h: Update.
4775 * gnulib/import/tempname.c: Update.
4776 * gnulib/import/tempname.h: Update.
4777 * gnulib/import/time.in.h: Update.
4778 * gnulib/import/unistd--.h: Update.
4779 * gnulib/import/unistd-safer.h: Update.
4780 * gnulib/import/unistd.in.h: Update.
4781 * gnulib/import/unsetenv.c: Update.
4782 * gnulib/import/verify.h: Update.
4783 * gnulib/import/extra/snippet/warn-on-use.h: Update.
4784 * gnulib/import/wchar.in.h: Update.
4785 * gnulib/import/wctype.in.h: Update.
4786 * gnulib/import/xalloc-oversized.h: Update.
4787 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
4788 "53e2c179f26a890fa6685af4b6c1397ee370433b".
4790 2018-08-16 Gary Benson <gbenson@redhat.com>
4793 * gdb/main.c (captured_main_1): Exit with nonzero status
4794 in batch mode if the last command to be executed failed.
4795 * NEWS: Mention the above.
4797 2018-08-29 Simon Marchi <simon.marchi@ericsson.com>
4799 * csky-tdep.c (csky_memory_insert_breakpoint): Remove newline at
4800 end of warning message.
4802 2018-08-29 Alan Hayward <alan.hayward@arm.com>
4805 * aarch64-tdep.c (is_hfa_or_hva): Remove function.
4806 (aarch64_extract_return_value): Use
4807 aapcs_is_vfp_call_or_return_candidate.
4808 (aarch64_return_in_memory): Likewise.
4809 (aarch64_store_return_value): Likewise.
4811 2018-08-29 Alan Hayward <alan.hayward@arm.com>
4814 (aapcs_is_vfp_call_or_return_candidate): Make static
4815 (pass_in_v_or_stack): Remove function.
4816 (pass_in_v_vfp_candidate): New function.
4817 (aarch64_push_dummy_call): Check for float register candidates.
4819 2018-08-29 Alan Hayward <alan.hayward@arm.com>
4821 * aarch64-tdep.c (HA_MAX_NUM_FLDS): New macro.
4822 (aapcs_is_vfp_call_or_return_candidate_1): New function.
4823 (aapcs_is_vfp_call_or_return_candidate): Likewise.
4825 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
4828 * common/agent.c (IPA_SYM_STRUCT_NAME): Define.
4829 (struct ipa_sym_addresses): Rename to...
4830 (struct ipa_sym_addresses_common): ... this.
4831 * common/agent.h (IPA_SYM): Use IPA_SYM_STRUCT_NAME.
4833 2018-08-28 Tom Tromey <tom@tromey.com>
4835 * c-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
4836 (token_fifo): Now a std::vector.
4837 (yylex, c_parse): Update.
4838 * d-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
4839 (token_fifo): Now a std::vector.
4840 (yylex, d_parse): Update.
4841 * go-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
4842 (token_fifo): Now a std::vector.
4843 (yylex, go_parse): Update.
4845 2018-08-28 Simon Marchi <simon.marchi@ericsson.com>
4847 * parser-defs.h (struct type_stack) <elements>: Change type to
4848 std::vector<union type_stack_elt>.
4849 <depth, size>: Remove.
4850 * parse.c (parse_exp_in_context_1): Adjust.
4851 (type_stack_reserve): Remove.
4852 (check_type_stack_depth): Remove.
4853 (insert_into_type_stack): Adjust to std::vector.
4854 (insert_type): Likewise.
4855 (push_type): Likewise.
4856 (push_type_int): Likewise.
4857 (insert_type_address_space): Likewise.
4858 (pop_type): Likewise.
4859 (pop_type_int): Likewise.
4860 (pop_typelist): Likewise.
4861 (pop_type_stack): Likewise.
4862 (append_type_stack): Likewise.
4863 (push_type_stack): Likewise.
4864 (get_type_stack): Likewise.
4865 (type_stack_cleanup): Likewise.
4866 (push_typelist): Likewise.
4867 (follow_types): Likewise.
4868 (_initialize_parse): Likewise.
4870 2018-08-28 Hafiz Abid Qadeer <abidh@codesourcery.com>
4872 * NEWS: Mention csky target.
4874 2018-08-28 Jiangshuai Li <jiangshuai_li@c-sky.com>
4875 Hafiz Abid Qadeer <abidh@codesourcery.com>
4876 Don Breazeal <donb@codesourcery.com>
4878 * csky-linux-tdep.c: New file.
4879 * csky-tdep.c: Likewise.
4880 * csky-tdep.h: Likewise.
4881 * Makefile.in (ALL_TARGET_OBS): Add csky-linux-tdep.o and
4883 (HFILES_NO_SRCDIR): Add csky-tdep.h.
4884 (ALLDEPFILES): Add csky-linux-tdep.c and csky-tdep.c
4885 * configure.tgt: Add csky support.
4887 2018-08-27 Jan Vrany <jan.vrany@fit.cvut.cz>
4889 * python/py-framefilter.c (py_print_frame): Print frame architecture
4890 when printing on an MI output.
4892 2018-08-27 Tom Tromey <tom@tromey.com>
4895 * configure: Rebuild.
4896 * warning.m4 (AM_GDB_WARNINGS): Remove -Wno-narrowing.
4898 2018-08-27 Tom Tromey <tom@tromey.com>
4900 * aarch64-linux-tdep.c
4901 (aarch64_linux_iterate_over_regset_sections) <sve_regmap>: Add
4904 2018-08-27 Tom Tromey <tom@tromey.com>
4906 * ppc64-tdep.c (insn_d, insn_ds, insn_xfx): Add casts to
4908 (ppc64_standard_linkage1, ppc64_standard_linkage2)
4909 (ppc64_standard_linkage3, ppc64_standard_linkage4)
4910 (ppc64_standard_linkage5, ppc64_standard_linkage6)
4911 (ppc64_standard_linkage7, ppc64_standard_linkage8): Add casts to
4914 2018-08-27 Tom Tromey <tom@tromey.com>
4916 * xtensa-tdep.h (XTREG_END): Add cast to unsigned.
4917 (XTENSA_GDBARCH_TDEP_INSTANTIATE): Likewise.
4919 2018-08-27 Tom Tromey <tom@tromey.com>
4921 * tramp-frame.h (TRAMP_SENTINEL_INSN): Redefine.
4922 * tilegx-linux-tdep.c (tilegx_linux_rt_sigframe): Use
4924 * tic6x-linux-tdep.c (tic6x_linux_rt_sigreturn_tramp_frame): Use
4926 * sparc64-linux-tdep.c (sparc64_linux_rt_sigframe): Use
4928 * sparc-linux-tdep.c (sparc32_linux_sigframe)
4929 (sparc32_linux_rt_sigframe): Use ULONGEST_MAX.
4930 * ppc-nbsd-tdep.c (ppcnbsd_sigtramp, ppcnbsd2_sigtramp): Use
4932 * ppc-linux-tdep.c (ppc32_linux_sigaction_tramp_frame)
4933 (ppc64_linux_sigaction_tramp_frame)
4934 (ppc32_linux_sighandler_tramp_frame)
4935 (ppc64_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
4936 * nios2-linux-tdep.c (nios2_r1_linux_rt_sigreturn_tramp_frame)
4937 (nios2_r2_linux_rt_sigreturn_tramp_frame): Use ULONGEST_MAX.
4938 * mn10300-linux-tdep.c (am33_linux_sigframe)
4939 (am33_linux_rt_sigframe): Use ULONGEST_MAX.
4940 * mips64-obsd-tdep.c (mips64obsd_sigframe): Use ULONGEST_MAX.
4941 * mips-linux-tdep.c (mips_linux_o32_sigframe)
4942 (mips_linux_o32_rt_sigframe, mips_linux_n32_rt_sigframe)
4943 (mips_linux_n64_rt_sigframe, micromips_linux_o32_sigframe)
4944 (micromips_linux_o32_rt_sigframe, micromips_linux_n32_rt_sigframe)
4945 (micromips_linux_n64_rt_sigframe): Use ULONGEST_MAX.
4946 * mips-fbsd-tdep.c (mips_fbsd_sigframe, mipsn32_fbsd_sigframe)
4947 (mips64_fbsd_sigframe): Use ULONGEST_MAX.
4948 * microblaze-linux-tdep.c
4949 (microblaze_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
4950 * i386-nbsd-tdep.c (i386nbsd_sigtramp_sc16, i386nbsd_sigtramp_sc2)
4951 (i386nbsd_sigtramp_si2, i386nbsd_sigtramp_si31)
4952 (i386nbsd_sigtramp_si4): Use ULONGEST_MAX.
4953 * hppa-nbsd-tdep.c (hppanbsd_sigtramp_si4): Use ULONGEST_MAX.
4954 * common/common-types.h (ULONGEST_MAX): New define.
4955 (CORE_ADDR_MAX): Fix formatting.
4956 * bfin-linux-tdep.c (bfin_linux_sigframe): Use ULONGEST_MAX.
4957 * arm-obsd-tdep.c (armobsd_sigframe): Use ULONGEST_MAX.
4958 * arm-linux-tdep.c (arm_linux_sigreturn_tramp_frame)
4959 (arm_linux_rt_sigreturn_tramp_frame)
4960 (arm_eabi_linux_sigreturn_tramp_frame)
4961 (arm_eabi_linux_rt_sigreturn_tramp_frame)
4962 (thumb2_eabi_linux_sigreturn_tramp_frame)
4963 (thumb2_eabi_linux_rt_sigreturn_tramp_frame)
4964 (arm_linux_restart_syscall_tramp_frame)
4965 (arm_kernel_linux_restart_syscall_tramp_frame): Use ULONGEST_MAX.
4966 * arm-fbsd-tdep.c (arm_fbsd_sigframe): Use ULONGEST_MAX.
4967 * aarch64-linux-tdep.c (aarch64_linux_rt_sigframe): Use
4969 * aarch64-fbsd-tdep.c (aarch64_fbsd_sigframe): Use ULONGEST_MAX.
4971 2018-08-27 Tom Tromey <tom@tromey.com>
4973 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Use
4975 * mips-tdep.c (mips_deal_with_atomic_sequence)
4976 (micromips_deal_with_atomic_sequence): Use CORE_ADDR_MAX.
4977 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw)
4978 (arm_deal_with_atomic_sequence_raw): Use CORE_ADDR_MAX.
4979 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Use
4981 * aarch64-tdep.c (aarch64_software_single_step): Use
4984 2018-08-27 Tom Tromey <tom@tromey.com>
4986 * linespec.c (complete_linespec_component): Add cast to "char".
4987 * completer.c (completion_tracker::build_completion_result): Add
4990 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
4992 * solist.h (struct solist, struct target_so_ops): Fix
4995 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
4997 * ada-tasks.c (ada_task_info_s): Remove typedef.
4998 (DEF_VEC_O(ada_task_info_s)): Remove.
4999 (struct ada_tasks_inferior_data): Initialize fields.
5000 <task_list>: Make an std::vector.
5001 (get_ada_tasks_inferior_data): Allocate with new.
5002 (ada_get_task_number): Adjust.
5003 (get_task_number_from_id): Likewise.
5004 (valid_task_id): Likewise.
5005 (ada_get_task_info_from_ptid): Likewise.
5006 (iterate_over_live_ada_tasks): Likewise.
5007 (add_ada_task): Likewise.
5008 (read_known_tasks): Likewise.
5009 (ada_build_task_list): Likewise.
5010 (print_ada_task_info): Likewise.
5011 (info_task): Likewise.
5012 (task_command_1): Likewise.
5014 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
5016 * ada-lang.c (add_angle_brackets): Return std::string.
5018 2018-08-25 Simon Marchi <simon.marchi@polymtl.ca>
5020 * python/py-threadevent.c (py_get_event_thread): Initialize
5023 2018-08-24 Pedro Alves <palves@redhat.com>
5025 * python/py-bpevent.c (create_breakpoint_event_object): Use
5026 copy-initialization.
5027 * python/py-continueevent.c (emit_continue_event): Use
5028 copy-initialization.
5029 * python/py-exitedevent.c (create_exited_event_object): Return a
5031 (emit_exited_event): Use copy-initialization.
5032 * python/py-inferior.c (python_new_inferior)
5033 (python_inferior_deleted, add_thread_object): Use
5034 copy-initialization.
5035 * python/py-infevents.c (create_inferior_call_event_object)
5036 (create_register_changed_event_object)
5037 (create_memory_changed_event_object): Return a gdbpy_ref<>.
5038 (emit_inferior_call_event, emit_memory_changed_event)
5039 (emit_register_changed_event): Use copy-initialization.
5040 * python/py-newobjfileevent.c (create_new_objfile_event_object):
5041 Return a gdbpy_ref<>.
5042 (emit_new_objfile_event): Use copy-initialization.
5043 (create_clear_objfiles_event_object): Return a gdbpy_ref<>.
5044 (emit_clear_objfiles_event): Use copy-initialization.
5045 * python/py-signalevent.c (create_signal_event_object): Use
5046 copy-initialization.
5047 * python/py-threadevent.c (create_thread_event_object): Use
5048 copy-initialization.
5050 2018-08-24 Pedro Alves <palves@redhat.com>
5051 Simon Marchi <simon.marchi@ericsson.com>
5054 * python/py-continueevent.c: Include "gdbthread.h".
5055 (create_continue_event_object): Add intro comment. Add 'ptid'
5056 parameter. Use it to find thread to pass to
5057 create_thread_event_object.
5058 (emit_continue_event): Pass PTID down to
5059 create_continue_event_object.
5060 * python/py-event.h (py_get_event_thread): Declare.
5061 (create_thread_event_object): Remove default from 'thread'
5063 * python/py-stopevent.c (create_stop_event_object): Use
5064 py_get_event_thread.
5065 * python/py-threadevent.c (get_event_thread): Rename to ...
5066 (py_get_event_thread): ... this, make extern, add 'ptid' parameter
5067 and use it to find the thread.
5068 (create_thread_event_object): Assert that THREAD isn't null.
5069 Don't find the event thread here.
5071 2018-08-23 Kevin Buettner <kevinb@redhat.com>
5073 * block.h (blockrange, blockranges): New struct declarations.
5074 (struct block): Add new field named `ranges'.
5075 (BLOCK_RANGES, BLOCK_NRANGES, BLOCK_RANGE, BLOCK_CONTIGUOUS_P)
5076 (BLOCK_RANGE_START, BLOCK_RANGE_END, BLOCK_ENTRY_PC): New
5077 macros for accessing ranges in struct block.
5078 (make_blockranges): New declaration.
5079 block.c (make_blockranges): New function.
5080 * dwarf2read.c (dwarf2_record_block_ranges): Fill in BLOCK_RANGES
5082 * symtab.h (find_pc_partial_function): Add new parameter `block'.
5083 * blockframe.c (cache_pc_function_block): New static global.
5084 (clear_pc_function_cache): Clear cache_pc_function_block.
5085 (find_pc_partial_function): Move comment to symtab.h. Add
5086 support for non-contiguous blocks.
5087 * cli/cli-cmds.c (block.h): Include.
5088 (print_disassembly): Handle printing of non-contiguous blocks.
5089 (disassemble_current_function): Likewise.
5090 (disassemble_command): Likewise.
5092 * ax-gdb.c (gen_var_ref): Use BLOCK_ENTRY_PC in place of
5094 * blockframe.c (get_pc_function_start): Likewise.
5095 * compile/compile-c-symbols.c (convert_one_symbol): Likewise.
5096 (gcc_symbol_address): Likewise.
5097 * compile/compile-object-run.c (compile_object_run): Likewise.
5098 * compile/compile.c (get_expr_block_and_pc): Likewise.
5099 * dwarf2loc.c (dwarf2_find_location_expression): Likewise.
5100 (func_addr_to_tail_call_list): Likewise.
5101 * findvar.c (default_read_var_value): Likewise.
5102 * inline-frame.c (inline_frame_this_id): Likewise.
5103 (skip-inline_frames): Likewise.
5104 * infcmd.c (until_next_command): Likewise.
5105 * linespec.c (convert_linespec_to_sals): Likewise.
5106 * parse.c (parse_exp_in_context_1): Likewise.
5107 * printcmd.c (build_address_symbolic): likewise.
5108 (info_address_command): Likewise.
5109 symtab.c (find_function_start_sal): Likewise.
5110 (skip_prologue_sal): Likewise.
5111 (find_function_alias_target): Likewise.
5112 (find_gnu_ifunc): Likewise.
5113 * stack.c (find_frame_funname): Likewise.
5114 * symtab.c (fixup_symbol_section): Likewise.
5115 (find_function_start_sal): Likewise.
5116 (skip_prologue_sal): Likewsie.
5117 (find_function_alias_target): Likewise.
5118 (find_gnu_ifunc): Likewise.
5119 * tracepoint.c (info_scope_command): Likewise.
5120 * value.c (value_fn_field): Likewise.
5122 * infrun.c (fill_in_stop_func): Use find_function_entry_range_from_pc
5123 in place of find_pc_partial_function.
5124 * blockframe.c (find_function_entry_range_from_pc): New function.
5125 * symtab.h (find_function_entry_range_from_pc): Declare and document.
5126 * objfiles.c (objfile_relocate1): Relocate start and end addresses
5127 for each range in a block.
5130 2018-08-23 Xavier Roirand <roirand@adacore.com>
5132 * machoread.c (macho_symfile_read_all_oso): Remove uneeded
5135 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
5137 * solib-svr4.c (read_program_headers_from_bfd): Return
5138 gdb::optional<gdb::byte_vector>.
5139 (svr4_exec_displacement): Adjust.
5141 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
5143 * solib-svr4.c (read_program_header): Return
5144 gdb::optional<gdb::byte_vector>, remove p_sect_size param.
5145 (find_program_interpreter): Return
5146 gdb::optional<gdb::byte_vector>.
5147 (scan_dyntag_auxv): Adjust.
5148 (enable_break): Adjust.
5149 (svr4_exec_displacement): Adjust.
5151 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
5153 * inf-child.h (inf_child_target) <terminal_save_inferior>: New.
5154 * inf-child.c (inf_child_target::terminal_save_inferior): New.
5156 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
5158 * guile/scm-string.c (gdbscm_scm_from_printf): Use
5160 * guile/scm-utils.c (gdbscm_printf): Likewise.
5161 * serial.c (serial_printf): Likewise.
5162 * xml-support.c (gdb_xml_parser::vdebug): Likewise.
5164 2018-08-22 Jan Vrany <jan.vrany@fit.cvut.cz>
5166 * stack.c (print_frame): Print frame architecture when printing on
5168 * NEWS: Mention new "arch" attribute in frame output.
5170 2018-08-21 Alan Hayward <alan.hayward@arm.com>
5172 * arch/aarch64.h (aarch64_regnum): Update comment.
5174 2018-08-21 Alan Hayward <alan.hayward@arm.com>
5176 * NEWS: Add SVE to 8.2 section.
5178 2018-08-21 Pedro Alves <palves@redhat.com>
5180 * guile/scm-utils.c (gdbscm_parse_function_args_1): New, factored
5181 out from gdbscm_parse_function_args.
5182 (gdbscm_parse_function_args): Rework to use gdbscm_wrap and
5183 gdbscm_parse_function_args_1.
5185 2018-08-21 Simon Marchi <simon.marchi@ericsson.com>
5188 * m32c-tdep.c (m32c_decode_srcdest4): Remove unnecessary ternary
5191 2018-08-19 Simon Marchi <simon.marchi@polymtl.ca>
5193 * solib-svr4.c (svr4_exec_displacement): Fix formatting.
5195 2018-08-19 Michael Spang <spang@google.com>
5198 * solib-svr4.c (svr4_exec_displacement): Ignore memsz fields
5199 for PT_TLS segments.
5201 2018-08-18 Kevin Buettner <kevinb@redhat.com>
5203 * dwarf2expr.h (struct dwarf_expr_context): Add virtual method
5204 dwarf_variable_value.
5205 * dwarf2-frame.c (class dwarf_expr_executor):
5206 Add override for dwarf_variable_value.
5207 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Likewise.
5208 (class symbol_needs_eval_context): Likewise.
5209 (indirect_synthetic_pointer): Add forward declaration.
5210 (sect_variable_value): New function.
5211 (dwarf2_compile_expr_to_ax): Add case for DW_OP_GNU_variable_value.
5212 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Add case
5213 for DW_OP_GNU_variable_value.
5215 2018-08-16 Tom Tromey <tom@tromey.com>
5217 * top.c (read_command_file): Update.
5218 (command_line_input): Remove "repeat" argument.
5219 * ada-lang.c (get_selections): Update.
5220 * linespec.c (decode_line_2): Update.
5221 * defs.h (command_line_input): Remove argument.
5222 * cli/cli-script.c (read_next_line): Update.
5223 * python/py-gdb-readline.c: Update.
5225 2018-08-17 Tom Tromey <tom@tromey.com>
5227 * cli/cli-script.c (read_next_line): Pass 0 as repeat argument to
5230 2018-08-15 Tom Tromey <tom@tromey.com>
5232 * aarch64-linux-tdep.c (aarch64_linux_core_read_vq): Use pulongest.
5234 2018-08-14 Jan Vrany <jan.vrany@fit.cvut.cz>
5236 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Add -a option.
5237 If used, use find_pc_partial_function to find address range
5239 * mi/mi-main.c (mi_cmd_list_features): Report
5240 "data-disassemble-a-option" feature.
5241 * NEWS: Mention new -data-disassemble option -a.
5243 2018-08-13 Tom Tromey <tom@tromey.com>
5245 * common/common-defs.h (_FORTIFY_SOURCE): Define.
5247 2018-08-13 Alan Hayward <alan.hayward@arm.com>
5249 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): New function.
5250 (aarch64_linux_collect_sve_regset): Likewise.
5251 (aarch64_linux_iterate_over_regset_sections): Check for SVE.
5252 * regcache.h (regcache_map_entry_size): New function.
5254 2018-08-13 Alan Hayward <alan.hayward@arm.com>
5256 * aarch64-linux-tdep.c (SVE_HEADER_SIZE_LENGTH): Add define.
5257 (SVE_HEADER_MAX_SIZE_LENGTH): Likewise.
5258 (SVE_HEADER_VL_LENGTH): Likewise.
5259 (SVE_HEADER_MAX_VL_LENGTH): Likewise.
5260 (SVE_HEADER_FLAGS_LENGTH): Likewise.
5261 (SVE_HEADER_RESERVED_LENGTH): Likewise.
5262 (SVE_HEADER_SIZE_OFFSET): Likewise.
5263 (SVE_HEADER_MAX_SIZE_OFFSET): Likewise.
5264 (SVE_HEADER_VL_OFFSET): Likewise.
5265 (SVE_HEADER_MAX_VL_OFFSET): Likewise.
5266 (SVE_HEADER_FLAGS_OFFSET): Likewise.
5267 (SVE_HEADER_RESERVED_OFFSET): Likewise.
5268 (SVE_HEADER_SIZE): Likewise.
5269 (aarch64_linux_core_read_vq): Add function.
5270 (aarch64_linux_core_read_description): Check for SVE section.
5272 2018-08-13 Alan Hayward <alan.hayward@arm.com>
5274 * aarch64-fbsd-tdep.c
5275 (aarch64_fbsd_iterate_over_regset_sections): Add supply_size and
5277 * aarch64-linux-tdep.c
5278 (aarch64_linux_iterate_over_regset_sections): Likewise.
5279 * alpha-linux-tdep.c
5280 (alpha_linux_iterate_over_regset_sections):
5282 (alphanbsd_iterate_over_regset_sections): Likewise.
5284 (amd64fbsd_iterate_over_regset_sections): Likewise.
5285 * amd64-linux-tdep.c
5286 (amd64_linux_iterate_over_regset_sections): Likewise.
5288 (armbsd_iterate_over_regset_sections): Likewise.
5290 (arm_fbsd_iterate_over_regset_sections): Likewise.
5292 (arm_linux_iterate_over_regset_sections): Likewise.
5293 * corelow.c (get_core_registers_cb): Likewise.
5294 (core_target::fetch_registers): Likewise.
5295 * fbsd-tdep.c (fbsd_collect_regset_section_cb): Likewise.
5296 * frv-linux-tdep.c (frv_linux_iterate_over_regset_sections): Likewise.
5297 * gdbarch.h (void): Regenerate.
5298 * gdbarch.sh: Add supply_size and collect_size.
5299 * hppa-linux-tdep.c (hppa_linux_iterate_over_regset_sections): Likewise.
5300 * hppa-nbsd-tdep.c (hppanbsd_iterate_over_regset_sections): Likewise.
5301 * hppa-obsd-tdep.c (hppaobsd_iterate_over_regset_sections): Likewise.
5302 * i386-fbsd-tdep.c (i386fbsd_iterate_over_regset_sections): Likewise.
5303 * i386-linux-tdep.c (i386_linux_iterate_over_regset_sections): Likewise.
5304 * i386-tdep.c (i386_iterate_over_regset_sections): Likewise.
5305 * ia64-linux-tdep.c (ia64_linux_iterate_over_regset_sections): Likewise.
5306 * linux-tdep.c (linux_collect_regset_section_cb): Likewise.
5307 * m32r-linux-tdep.c (m32r_linux_iterate_over_regset_sections): Likewise.
5308 * m68k-bsd-tdep.c (m68kbsd_iterate_over_regset_sections): Likewise.
5309 * m68k-linux-tdep.c (m68k_linux_iterate_over_regset_sections): Likewise.
5310 * mips-fbsd-tdep.c (mips_fbsd_iterate_over_regset_sections): Likewise.
5311 * mips-linux-tdep.c (mips_linux_iterate_over_regset_sections): Likewise.
5312 * mips-nbsd-tdep.c (mipsnbsd_iterate_over_regset_sections): Likewise.
5313 * mips64-obsd-tdep.c (mips64obsd_iterate_over_regset_sections):
5315 * mn10300-linux-tdep.c (am33_iterate_over_regset_sections): Likewise.
5316 * nios2-linux-tdep.c (nios2_iterate_over_regset_sections): Likewise.
5317 * ppc-fbsd-tdep.c (ppcfbsd_iterate_over_regset_sections): Likewise.
5318 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections): Likewise.
5319 * ppc-nbsd-tdep.c (ppcnbsd_iterate_over_regset_sections): Likewise.
5320 * ppc-obsd-tdep.c (ppcobsd_iterate_over_regset_sections): Likewise.
5321 * riscv-linux-tdep.c (riscv_linux_iterate_over_regset_sections):
5323 * rs6000-aix-tdep.c (rs6000_aix_iterate_over_regset_sections): Likewise.
5324 * s390-linux-tdep.c (s390_iterate_over_regset_sections): Likewise.
5325 * score-tdep.c (score7_linux_iterate_over_regset_sections): Likewise.
5326 * sh-tdep.c (sh_iterate_over_regset_sections): Likewise.
5327 * sparc-tdep.c (sparc_iterate_over_regset_sections): Likewise.
5328 * tilegx-linux-tdep.c (tilegx_iterate_over_regset_sections): Likewise.
5329 * vax-tdep.c (vax_iterate_over_regset_sections): Likewise.
5330 * xtensa-tdep.c (xtensa_iterate_over_regset_sections): Likewise.
5332 2018-08-10 Simon Marchi <simon.marchi@ericsson.com>
5334 * nat/linux-osdata.c (commandline_from_pid): Replace xstrprintf
5337 2018-08-10 Keith Seitz <keiths@redhat.com>
5339 * compile/compile-c-support.c (add_code_header, add_code_footer):
5340 Move into policy class.
5341 (c_push_user_expression, pop_user_expression_nop)
5342 (c_add_code_header, c_add_code_footer, c_add_input): New policy class.
5343 (compile_program): New host class.
5344 (c_compile_program): New typedef.
5345 (c_compute_porgram): Use c_compile_program.
5347 2018-08-10 Keith Seitz <keiths@redhat.com>
5349 * compile/compile-internal.h (compile_instance::~compile_instance):
5350 Remove calls to htab_delete.
5351 <m_type_map, m_symbol_err_map>: Switch type to htab_up.
5352 * compile.c (compile_instance::compile_instance): Initialize
5353 htab unique pointers.
5354 (compile_instance::get_cached_type, compile_instance::insert_type)
5355 (compile_instance::error_symbol_once): Update for unique_ptr.
5357 2018-08-10 Keith Seitz <keiths@redhat.com>
5359 * compile/compile-c-symbols.c (struct symbol_error)
5360 (hash_symbol_error, eq_symbol_error, del_symbol_error)
5361 (compile_instance::insert_symbol_error)
5362 (compile_instance::error_symbol_once): Move to ...
5363 * compile/compile.c: ... here.
5365 2018-08-10 Keith Seitz <keiths@redhat.com>
5367 * compile/compile-c-support.c (c_get_compile_context): Use `new'
5368 instead of `new_compile_instance'.
5369 * compile/compile-c-symbols.c (compile_instance::insert_symbol_error):
5371 If the symbol error map is not initialized, create it.
5372 (generate_c_for_for_one_symbol): Do not check/initialize
5373 the symbol error map.
5374 * compile/compile-c-types.c (compile_c_instance): Make a class.
5376 (compile_instance::compile_instance): Initialize the type cache.
5377 (get_cached_type): New function.
5378 (insert_type): Update description.
5379 (compile_c_instance::m_default_cflags): Define.
5380 (convert_type): Update description. Use get_cached_type.
5381 (delete_instance): Moved to destructor.
5382 (new_compile_instance): Moved to constructor.
5383 * compile/compile-c.h (compile_c_instance): Make class inheriting
5384 from compile_instance.
5385 <base>: Remove field.
5386 <type_map, symbol_err_map>: Move to base class.
5387 <c_plugin>: Rename to `m_plugin' and remove pointer type.
5388 * compile/compile-internal.h (compile_instance): Make class.
5389 <type_map_t, symbol_err_map_t>: Define.
5390 <fe>: Rename to `m_gcc_fe'.
5391 <scope, block, gcc_target_options>: Add `m_' prefix.
5392 <m_type_map, m_symbol_err_map>: New fields, moved from
5395 (convert_type, new_compile_instance): Remove.
5396 * compile/compile.c (cleanup_compile_instance): Remove.
5397 (compile_to_object): Use unique_ptr to eliminate cleanups.
5398 (compile_instance::set_print_callback, compile_instance::version)
5399 (compile_instance::set_verbose)
5400 (compile_instance::set_driver_filename)
5401 (compile_instance::set_triplet_regexp)
5402 (compile_instance::set_arguments)
5403 (compile_instance::set_source_file)
5404 (compile_instance::compile): Define.
5406 2018-08-10 Keith Seitz <keiths@redhat.com>
5408 * Makefile.in (HFILES_NO_SRCDIR): Add compile/gcc-c-plugin.h.
5409 * compile/compile-c-types.c: Define GCC_METHODN macros and include
5410 gcc-c-fe.def to define C plugin.
5411 (delete_instance): Delete `c_plugin'.
5412 (new_compile_instance): Initialize `c_plugin'.
5413 * compile/compile-c.h: Include gcc_c_plugin.h.
5414 (struct compile_c_instance) <c_plugin>: New member.
5415 * gcc-c-plugin.h: New file.
5416 Update all callers with API change.
5418 2018-08-10 Keith Seitz <keiths@redhat.com>
5420 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Move header files ...
5421 (HFILES_NO_SRCDIR): ... to here.
5422 Add compile-internal.h and compile-c.h.
5423 * compile/compile-c-support.c: Include compile-c.h.
5424 * compile/compile-c-symbols.c: Include compile-c.h.
5425 (generate_c_for_variable_locations): Update comment.
5426 * compile/compile-c-types.c: Include compile-c.h.
5427 * compile/compile-c.h: New file -- moved C language declarations
5428 from other files here.
5429 * compile/compile-internal.h: Do not include hashtab.h or
5430 common/enum-flags.h.
5431 (gcc_qualifiers_flags, struct compile_c_instance, C_CTX)
5432 (gcc_convert_symbol, gcc_symbol_address)
5433 (generate_c_for_variable_locations, c_get_mode_for_size)
5434 (c_get_range_decl_name): Definitions moved to compile-c.h.
5435 * compile/compile-loc2c.c: Include compile-c.h.
5437 2018-08-10 Keith Seitz <keiths@redhat.com>
5439 * compile/compile-c-symbols.c (symbol_substitution_name): Rename to ...
5440 (c_symbol_substitution_name): ... this.
5443 2018-08-10 Keith Seitz <keiths@redhat.com>
5445 * compile/compile-c-support.c (c_compute_program): Use
5446 unique_xmalloc_ptr to eliminate cleanup.
5447 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
5448 Return a unique_xmalloc_ptr and eliminate cleanup.
5449 * compile/compile-internal.h (generate_c_for_variable_locations):
5450 Return unique_xmalloc_ptr and update description.
5452 2018-08-10 Alan Hayward <alan.hayward@arm.com>
5454 * corelow.c (core_target::get_core_register_section): Rename
5455 min_size to section_min_size.
5457 2018-08-09 Jim Wilson <jimw@sifive.com>
5459 * Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
5460 (ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
5461 * NEWS: Mention new GNU/Linux RISC-V target.
5462 * configure.host: Add riscv*-*-linux*.
5463 * configure.nat: Add riscv*.
5464 * configure.tgt: Add riscv*-*-linux*.
5465 * riscv-linux-nat.c: New file.
5466 * riscv-linux-tdep.c: New file.
5468 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
5470 * infrun.c (resume): Make static, add forward declaration.
5471 (proceed): Update header comment.
5472 * infrun.h (resume): Delete declaration.
5474 2018-08-09 Tom Tromey <tom@tromey.com>
5476 * riscv-tdep.h: Minor formatting fixes.
5478 2018-08-09 Simon Marchi <simon.marchi@ericsson.com>
5480 * common/scoped_mmap.c (mmap_file): Silence ARI warning.
5481 * dwarf-index-cache.c (create_dir_and_check): Likewise.
5482 (test_mkdir_recursive): Likewise.
5483 * dwarf-index-write.c (write_psymtabs_to_index): Likewise.
5485 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
5487 * valarith.c (value_subscripted_rvalue): If an array is not in
5488 memory, and we don't know the upper bound, then we can't know that
5489 the requested element exists or not.
5491 2018-08-08 Simon Marchi <simon.marchi@ericsson.com>
5493 * target.c (str_comma_list_concat_elem): Fix typo in comment.
5494 (target_options_to_string): Add comment.
5496 2018-08-08 Tom Tromey <tom@tromey.com>
5498 * unittests/scoped_mmap-selftests.c: Check result of "write".
5500 2018-08-08 Jim Wilson <jimw@sifive.com>
5502 * riscv-tdep.c (enum opcode): Add jump, branch, lr, and sc opcodes.
5503 (decode_register_index_short): New.
5504 (decode_j_type_insn, decode_cj_type_insn): New.
5505 (decode_b_type_insn, decode_cb_type_insn): New.
5506 (riscv_insn::decode): Add support for jumps, branches, lr, and sc. New
5507 local xlen. Check xlen when decoding ambiguous compressed insns. In
5508 compressed decode, use is_c_lui_insn instead of is_lui_insn, and
5509 is_c_sw_insn instead of is_sw_insn.
5510 (riscv_next_pc, riscv_next_pc_atomic_sequence): New.
5511 (riscv_software_single_step): New.
5512 * riscv-tdep.h (riscv_software_single_step): Declare.
5514 * riscv-tdep.c (riscv_isa_xlen): Drop static.
5515 * riscv-tdep.h (riscv_isa_xlen): Add extern declaration.
5517 2018-08-08 Andrew Burgess <andrew.burgess@embecosm.com>
5520 * target.c (dispose_inferior): Don't dispose of inferiors that are
5523 2018-08-08 Szabolcs Nagy <szabolcs.nagy@arm.com>
5525 * remote.c (remote_target::download_tracepoint): Change char* to
5528 2018-08-07 Simon Marchi <simon.marchi@polymtl.ca>
5530 * target.h (target_options_to_string): Return an std::string.
5531 * target.c (str_comma_list_concat_elem): Return void, use
5533 (do_option): Likewise.
5534 (target_options_to_string): Return an std::string.
5535 * linux-nat.c (linux_nat_target::wait): Adjust.
5536 * target-debug.h (target_debug_print_options): Adjust.
5538 2018-08-07 Tom Tromey <tom@tromey.com>
5540 * Makefile.in (CPPFLAGS): New variable.
5541 (INTERNAL_CPPFLAGS): Use it.
5543 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5545 * NEWS: Mention the index cache.
5547 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5549 * common/pathstuff.h (get_standard_cache_dir): New.
5550 * common/pathstuff.c (get_standard_cache_dir): New.
5551 * build-id.h (build_id_to_string): New.
5552 * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
5553 DEBUG_STR_SUFFIX): Move to here.
5554 * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
5555 DEBUG_STR_SUFFIX): Move from there.
5556 (write_psymtabs_to_index): Make non-static, add basename
5557 parameter. Write to temporary files, rename when done.
5558 (save_gdb_index_command): Adjust call to
5559 write_psymtabs_to_index.
5560 * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
5562 * dwarf2read.c (dwz_file) <index_cache_res>: New field.
5563 (get_gdb_index_contents_from_cache): New.
5564 (get_gdb_index_contents_from_cache_dwz): New.
5565 (dwarf2_initialize_objfile): Read index from cache.
5566 (dwarf2_build_psymtabs): Save to index.
5567 * dwarf-index-cache.h: New file.
5568 * dwarf-index-cache.c: New file.
5569 * dwarf-index-write.h: New file.
5571 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5573 * gnulib/aclocal.m4: Re-generate.
5574 * gnulib/config.in: Re-generate.
5575 * gnulib/configure: Re-generate.
5576 * gnulib/import/Makefile.am: Re-generate.
5577 * gnulib/import/Makefile.in: Re-generate.
5578 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
5579 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
5580 * gnulib/import/m4/mkdir.m4: New file.
5581 * gnulib/import/mkdir.c: New file.
5582 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
5585 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5587 * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
5588 * common/scoped_mmap.c: New file.
5589 * common/scoped_mmap.h (destroy): New method.
5590 (~scoped_mmap, reset): Use destroy.
5591 (scoped_mmap): New move constructor.
5592 (mmap_file): New declaration.
5593 * unittests/scoped_mmap-selftests.c (test_normal,
5594 test_invalid_filename, run_tests): New functions.
5595 (_initialize_scoped_mmap_selftests): Register selftest.
5597 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5599 * dwarf2read.c (read_gdb_index_from_section): Rename to...
5600 (read_gdb_index_from_buffer): ... this. Remove section
5601 parameter, add buffer parameter.
5602 (get_gdb_index_contents_ftype,
5603 get_gdb_index_contents_dwz_ftype): New typedefs.
5604 (dwarf2_read_gdb_index): Add callback parameters to get the
5606 (get_gdb_index_contents_from_section): New.
5607 (dwarf2_initialize_objfile): Update call to
5608 dwarf2_read_gdb_index.
5610 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5612 * common/filestuff.h (gdb_fopen_cloexec): New overload.
5613 (gdb_open_cloexec): Likewise.
5614 * nat/linux-osdata.c (command_from_pid): Use string_printf.
5615 (commandline_from_pid): Likewise.
5616 (linux_xfer_osdata_threads): Likewise.
5617 (linux_xfer_osdata_fds): Likewise.
5618 * ada-lang.c (is_package_name): Likewise.
5619 * auxv.c (procfs_xfer_auxv): Likewise.
5620 * breakpoint.c (print_one_breakpoint_location): Use
5622 (print_one_catch_solib): Use string_printf.
5623 * coff-pe-read.c (add_pe_exported_sym): Likewise.
5624 (add_pe_forwarded_sym): Likewise.
5625 * dwarf2read.c (create_type_unit_group): Likewise.
5626 (build_error_marker_type): Likewise.
5627 * infcall.c (get_function_name): Likewise.
5628 * valprint.c (print_converted_chars_to_obstack): Likewise.
5629 * xtensa-tdep.c (xtensa_register_type): Likewise.
5631 2018-08-06 Simon Marchi <simon.marchi@ericsson.com>
5633 * remote.c (remote_target::download_tracepoint): Fix format
5636 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5638 * tracefile.c: Include common/byte-vector.h.
5639 (trace_save): Change type of buf to gdb::byte_vector. Initialize
5640 with trace_regblock_size if needed. Update uses of buf.
5642 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5644 * tracepoint.h (collection_list) <m_regs_mask>: Change type to
5645 std::vector<unsigned char>.
5646 * tracepoint.c (collection_list::collection_list): Remove
5647 m_regs_mask initializer from initializer list. Resize
5648 m_regs_mask using the largest remote register number.
5649 (collection_list::add_remote_register): Remove size check on
5650 m_regs_mask. Use at to access element.
5651 (collection_list::stringify): Change type of temp_buf to
5652 gdb::char_vector. Update uses of temp_buf. Resize if needed to
5653 stringify the register mask. Use pack_hex_byte for the register
5656 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5658 * tracepoint.h (class collection_list) <add_register>: Remove.
5659 <add_remote_register, add_ax_registers, add_local_register>:
5661 <add_memrange>: Add scope parameter.
5662 * tracepoint.c (encode_actions_1): Likewise.
5663 (collection_list::add_register): Rename to ...
5664 (collection_list::add_remote_register): ... this. Update
5666 (collection_list::add_ax_registers, add_local_register): New
5668 (collection_list::add_memrange): Add scope parameter. Call
5669 add_local_register instead of add_register.
5670 (finalize_tracepoint_aexpr): New function.
5671 (collection_list::collect_symbol): Update calls to add_memrange.
5672 Call add_local_register instead of add_register. Call
5673 add_ax_registers. Call finalize_tracepoint_aexpr.
5674 (encode_actions_1): Get remote regnos for $reg action. Call
5675 add_remote_register, add_ax_registers, and add_local_register.
5676 Update call to add_memrange. Call finalize_tracepoint_aexpr.
5677 (validate_actionline): Call finalize_tracepoint_aexpr.
5679 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5681 * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
5682 Replace array buf with gdb::char_vector buf, of size
5683 get_remote_packet_size (). Replace references to buf and
5684 BUF_SIZE to buf.data () and buf.size (). Replace strcpy, strcat
5685 and xsnprintf with snprintf. Raise errors if the buffer is too
5688 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5690 * remote.c (remote_target::download_tracepoint): Fix the has_more
5691 predicate in the QTDP action list iteration.
5693 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5695 * remote.c (remote_target::download_tracepoint): Fix indentation
5698 2018-08-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5700 * proc-api.c (_initialize_proc_api): Remove c, unused.
5701 * procfs.c (procfs_init_inferior): Remove signals, unused.
5702 (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
5705 2018-08-06 Sergey Korolev <s.korolev@ndmsystems.com>
5706 Andrew Burgess <andrew.burgess@embecosm.com>
5708 * linux-nat.c (linux_nat_target::follow_fork): Avoid using
5709 'W_STOPCODE (0)' as this could be ambiguous.
5711 2018-08-03 Sergio Durigan Junior <sergiodj@redhat.com>
5713 * ser-tcp.c (net_open): Fix thinko when deciding whether to
5714 disable TCP's Nagle algorithm (use "ai_protocol" instead of
5717 2018-08-02 Tom Tromey <tom@tromey.com>
5720 * dwarf2read.c (read_func_scope): Set symtab on template parameter
5722 (process_structure_scope): Likewise.
5724 2018-08-02 Xavier Roirand <roirand@adacore.com>
5727 * darwin-nat.c (darwin_kill_inferior): Fix handling of
5730 2018-08-02 Tom Tromey <tom@tromey.com>
5732 * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
5733 (darwin_suspend_inferior, darwin_resume_inferior)
5734 (darwin_decode_notify_message, darwin_resume_inferior_threads)
5735 (darwin_check_new_threads): Check result of get_darwin_inferior.
5737 2018-07-31 Joel Brobecker <brobecker@adacore.com>
5741 2018-07-31 Jan Vrany <jan.vrany@fit.cvut.cz>
5743 * varobj.c (varobj_get_path_expr_parent): Report an error if
5744 parent is a dynamic varobj.
5746 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
5748 * gnulib/aclocal.m4: Re-generate.
5749 * gnulib/config.in: Re-generate.
5750 * gnulib/configure: Re-generate.
5751 * gnulib/import/Makefile.in: Re-generate.
5752 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
5753 * gnulib/import/m4/onceonly.m4: Re-generate.
5755 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
5757 * target-descriptions.c (struct xml_test_tdesc): New.
5758 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
5759 (record_xml_tdesc): Update.
5760 (maintenance_check_xml_descriptions): Update.
5761 * target-descriptions.h (record_xml_tdesc): Update comment.
5763 2018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
5765 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
5766 checking array bounds are defined.
5768 2018-07-30 Tom Tromey <tom@tromey.com>
5770 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
5771 irreflexivity violation.
5773 2018-07-30 Tom Tromey <tom@tromey.com>
5775 * cli/cli-decode.c (lookup_cmd): Remove lint code.
5776 * value.c (unpack_long): Remove lint code.
5777 * valops.c (value_ind): Remove lint code.
5778 * valarith.c (value_x_binop, value_x_unop, value_equal)
5779 (value_pos): Remove lint code.
5781 2018-07-28 Tom de Vries <tdevries@suse.de>
5783 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
5784 with undefined upper bound as <optimized out>.
5786 2018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
5788 * gcore.in: Rename variable "name" to "prefix". Expand
5791 2018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
5793 * windows-nat.c (windows_nat_target::create_inferior): Update to
5794 call close() in global namespace.
5796 2018-07-26 Tom Tromey <tom@tromey.com>
5798 * dwarf-index-write.c (add_address_entry): Don't add objfile
5800 * dbxread.c (find_stab_function): Rename from
5801 find_stab_function_addr. Return a bound_minimal_symbol.
5802 (read_dbx_symtab): Use raw_text_low, raw_text_high.
5803 Don't add objfile offsets.
5804 (end_psymtab): Use raw_text_low, raw_text_high,
5805 MSYMBOL_VALUE_RAW_ADDRESS.
5806 (read_ofile_symtab): Update.
5807 (process_one_symbol): Update.
5808 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
5810 (dw2_relocate): Remove.
5811 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
5813 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
5815 (process_psymtab_comp_unit_reader, add_partial_symbol)
5816 (add_partial_subprogram, dwarf2_ranges_read): Update.
5817 (load_partial_dies): Update.
5818 (add_address_entry): Don't add objfile offsets.
5819 (dwarf2_build_include_psymtabs): Update.
5820 (create_addrmap_from_aranges): Don't add objfile offsets.
5821 (dw2_find_pc_sect_compunit_symtab): Update.
5822 * mdebugread.c (parse_symbol): Don't add objfile offsets.
5823 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
5825 (parse_partial_symbols): Don't add objfile offsets. Use
5826 raw_text_low, raw_text_high. Update.
5827 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
5828 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
5829 or call 'relocate' quick function. Clear psymbol_map.
5830 * psympriv.h (struct partial_symbol) <address>: Add section
5832 <set_unrelocated_address>: Rename from set_address.
5833 <raw_text_low, raw_text_high>: New methods.
5834 <text_low, text_high>: Add objfile parameter.
5835 (add_psymbol_to_bcache): Add 'section' parameter. Call
5836 set_unrelocated_address.
5837 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
5838 (find_pc_psymbol): Update.
5839 (fixup_psymbol_section, relocate_psymtabs): Remove.
5840 (dump_psymtab, psym_functions): Update.
5841 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
5843 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
5844 (start_psymtab_common): Update.
5845 * symfile-debug.c (debug_qf_relocate): Remove.
5846 (debug_sym_quick_functions): Update.
5847 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
5848 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
5851 2018-07-26 Tom Tromey <tromey@redhat.com>
5853 * dbxread.c (end_psymtab): Use text_high_valid and
5855 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
5856 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
5857 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
5859 <text_low_valid, text_high_valid>: New fields.
5860 <set_text_low, set_text_high>: Update.
5861 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
5863 2018-07-26 Tom Tromey <tom@tromey.com>
5865 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
5867 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
5868 textlow and texthigh fields.
5869 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
5871 * mdebugread.c (parse_lines, parse_partial_symbols)
5872 (psymtab_to_symtab_1): Update.
5873 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
5874 Rename fields. Update comment. Now private.
5875 <text_low, text_high, set_text_low, set_text_high>: New methods.
5876 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
5877 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
5878 (start_psymtab_common, maintenance_info_psymtabs)
5879 (maintenance_check_psymtabs): Update.
5880 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
5882 (scan_xcoff_symtab): Update.
5884 2018-07-26 Tom Tromey <tromey@redhat.com>
5886 * psympriv.h (struct partial_symbol) <unrelocated_address,
5887 address, set_address>: New methods.
5888 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
5889 (fixup_psymbol_section, relocate_psymtabs): Update.
5890 (print_partial_symbols): Add 'objfile' parameter. Update.
5891 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
5894 2018-07-26 Tom Tromey <tom@tromey.com>
5896 * dwarf-index-write.c (write_psymbols, debug_names::insert)
5897 (debug_names::write_psymbols): Update.
5898 * psympriv.h (struct partial_symbol): Derive from
5899 general_symbol_info.
5900 <obj_section>: New method.
5901 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
5902 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
5903 (find_pc_sect_psymbol, fixup_psymbol_section)
5904 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
5905 (print_partial_symbols, recursively_search_psymtabs)
5906 (compare_psymbols, psymbol_hash, psymbol_compare)
5907 (add_psymbol_to_bcache, maintenance_check_psymtabs)
5908 (psymbol_name_matches, psym_fill_psymbol_map): Update.
5910 2018-07-26 Tom Tromey <tromey@redhat.com>
5912 * dbxread.c (end_psymtab): Remove dead code.
5914 2018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
5916 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
5917 DWARF unwinders are disabled.
5918 * dwarf2-frame.c: Add dwarf2read.h include.
5919 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
5921 (dwarf2_frame_unwinders_enabled_p): Define.
5922 (show_dwarf_unwinders_enabled_p): New function.
5923 (_initialize_dwarf2_frame): Register switch to control DWARF
5925 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
5926 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
5927 (show_dwarf_cmdlist): Remove static keyword.
5928 * dwarf2read.h (set_dwarf_cmdlist): Declare.
5929 (show_dwarf_cmdlist): Declare.
5930 * NEWS: Document new feature.
5932 2018-07-26 Tom de Vries <tdevries@suse.de>
5934 PR breakpoints/23366
5935 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
5937 2018-07-26 Tom de Vries <tdevries@suse.de>
5939 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
5940 DW_AT_count can't be translated to a dynamic prop.
5942 2018-07-25 Tom de Vries <tdevries@suse.de>
5944 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
5947 2018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
5949 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
5951 2018-07-25 Joel Brobecker <brobecker@adacore.com>
5953 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
5955 2018-07-24 Keith Seitz <keiths@redhat.comt
5958 * dwarf2read.c (dw2_add_symbol_to_list): New function.
5959 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
5960 instead of add_symbol_to_list.
5961 (read_file_scope): Call prepare_one_comp_unit before reading
5964 2018-07-24 Simon Marchi <simon.marchi@ericsson.com>
5966 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
5968 2018-07-24 Tom Tromey <tom@tromey.com>
5970 * utils.c (malloc, realloc, free): Don't declare.
5971 * configure, config.in: Rebuild.
5972 * configure.ac: Don't check for declarations of free, malloc, or
5975 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
5977 * aarch64-linux-nat.c
5978 (aarch64_linux_nat_target::stopped_data_address): Remove unused
5980 * arm-linux-nat.c (fetch_regs): Likewise.
5981 (store_regs): Likewise.
5982 (fetch_vfp_regs): Likewise.
5983 (store_vfp_regs): Likewise.
5984 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
5985 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
5986 (arm_linux_nat_target::insert_watchpoint): Likewise.
5987 (arm_linux_nat_target::remove_watchpoint): Likewise.
5988 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
5990 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
5992 * ppc-linux-nat.c (fetch_register): Likewise.
5993 (fetch_all_gp_regs): Likewise.
5994 (fetch_ppc_registers): Likewise.
5995 (store_all_gp_regs): Likewise.
5996 (store_ppc_registers): Likewise.
5997 (hwdebug_insert_point): Likewise.
5998 (can_use_watchpoint_cond_accel): Likewise.
5999 * remote-sim.c (gdb_os_write_stdout): Likewise.
6001 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
6002 Tom Tromey <tom@tromey.com>
6004 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
6006 * configure: Rebuild.
6008 2018-07-22 Tom Tromey <tom@tromey.com>
6010 * regformats/regdat.sh: Define xmltarget_${name} inside
6011 #ifndef IN_PROCESS_AGENT.
6013 2018-07-22 Tom Tromey <tom@tromey.com>
6015 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
6017 2018-07-22 Tom Tromey <tom@tromey.com>
6019 * symfile.c (reread_symbols): Notify iter, not objfile.
6021 2018-07-22 Tom Tromey <tom@tromey.com>
6023 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
6025 (ravenscar_thread_target::prepare_to_store): Likewise.
6027 2018-07-22 Tom Tromey <tom@tromey.com>
6029 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
6030 unused variable. Call value_fetch_lazy when needed.
6031 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
6032 Remove unused variable. Call value_fetch_lazy when needed.
6034 2018-07-22 Tom Tromey <tom@tromey.com>
6036 * m32c-tdep.c (mark_dma): Return void.
6037 (make_regs): Remove unused declarations.
6039 2018-07-22 Tom Tromey <tom@tromey.com>
6041 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
6042 cmdscm_get_valid_command_smob_arg_unsafe for effect.
6043 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
6044 bkscm_get_valid_block_smob_arg_unsafe for effect.
6046 2018-07-22 Tom Tromey <tom@tromey.com>
6048 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
6051 2018-07-22 Tom Tromey <tom@tromey.com>
6053 * windows-nat.c (saved_context): Conditionally define.
6054 * remote.c (remote_target::remote_btrace_maybe_reopen):
6055 Conditionally declare "warned".
6056 * inflow.c (sigquit_ours): Conditionally define.
6057 (new_tty): Move "tty" declaration inside #if.
6058 * guile/guile.c (guile_datadir): Conditionally define.
6059 * charset.c (set_be_le_names): Move some declarations inside #if.
6060 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
6062 (parse_xml_btrace_conf): Likewise.
6064 2018-07-22 Tom Tromey <tom@tromey.com>
6066 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
6068 2018-07-22 Tom Tromey <tom@tromey.com>
6070 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
6071 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
6072 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
6073 * buildsym-legacy.c (get_macro_table): Remove unused variable.
6074 * stack.c (frame_apply_level_command): Remove unused variable.
6075 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
6076 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
6077 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
6079 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
6080 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
6081 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
6083 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
6084 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
6086 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
6087 Remove unused variable.
6088 * cli/cli-script.c (recurse_read_control_structure): Remove unused
6090 * common/tdesc.c (print_xml_feature::visit): Remove unused
6092 * compile/compile-object-load.c (store_regs): Remove unused
6094 * complaints.c (clear_complaints): Remove unused variable.
6095 * corelow.c (core_target_open): Remove unused variable.
6096 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
6098 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
6100 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
6102 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
6104 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
6106 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
6108 * ia64-tdep.c (examine_prologue): Remove unused variable.
6109 * infcall.c (run_inferior_call): Remove unused variable.
6110 * inferior.c (exit_inferior): Remove unused variable.
6111 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
6112 * linespec.c (decode_line_2): Remove unused variable.
6113 * linux-nat.c (super_close): Remove.
6114 * linux-tdep.c (linux_info_proc): Remove unused variable.
6115 * mi/mi-main.c (mi_execute_command): Remove unused variable.
6116 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
6117 Remove unused variable.
6118 * parse.c (find_minsym_type_and_address): Remove unused variable.
6119 * printcmd.c (info_symbol_command, printf_floating): Remove unused
6121 * python/py-breakpoint.c (bppy_set_commands): Remove unused
6123 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
6125 * record-btrace.c (record_btrace_target::store_registers): Remove
6127 (cmd_show_record_btrace_cpu): Remove unused variable.
6128 * riscv-tdep.c (riscv_register_reggroup_p)
6129 (riscv_push_dummy_call, riscv_return_value): Remove unused
6131 * rust-exp.y (literal): Remove unused variable.
6132 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
6134 <STRUCTOP_ANONYMOUS>: Likewise.
6135 * s390-linux-tdep.c (s390_linux_init_abi_31)
6136 (s390_linux_init_abi_64): Remove unused variable.
6137 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
6138 (file_select_thread, net_windows_open, _initialize_ser_windows):
6139 Remove unused variables.
6140 * symtab.c (find_pc_sect_line): Remove unused variable.
6141 * target-memory.c (compute_garbled_blocks): Remove unused
6143 (target_write_memory_blocks): Remove unused variable.
6144 * target.c (target_stack::unpush): Remove unused variables.
6145 * tracepoint.c (start_tracing, all_tracepoint_actions)
6146 (merge_uploaded_trace_state_variables)
6147 (print_one_static_tracepoint_marker): Remove unused variable.
6148 * unittests/basic_string_view/element_access/char/1.cc (test01):
6149 Remove unused variable.
6150 * windows-nat.c (windows_continue, windows_add_all_dlls)
6151 (do_initial_windows_stuff, windows_nat_target::create_inferior):
6152 Remove unused variables.
6154 2018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
6156 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
6157 attr_profile in HAVE_ELF.
6158 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
6161 2018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
6163 * frame.c (frame_register_unwind): Change parameter name.
6164 (frame_unwind_register): Likewise.
6165 (frame_unwind_register_value): Likewise.
6166 (frame_unwind_register_signed): Likewise.
6167 (frame_unwind_register_unsigned): Likewise.
6168 * frame.h (frame_register_unwind): Likewise.
6169 (frame_unwind_register): Likewise.
6170 (frame_unwind_register_value): Likewise.
6171 (frame_unwind_register_signed): Likewise.
6172 (frame_unwind_register_unsigned): Likewise.
6173 (frame_unwind_arch): Likewise.
6175 2018-07-20 Maciej W. Rozycki <macro@mips.com>
6177 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
6180 2018-07-20 Maciej W. Rozycki <macro@mips.com>
6182 * mips-linux-nat.c (mips_linux_nat_target::read_description):
6183 Call `get_ptrace_pid' rather than extracting the ptrace PID by
6186 2018-07-20 Keith Seitz <keiths@redhat.com>
6188 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
6189 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
6190 m_compunit_symtab, m_language>: Add "m_" prefix.
6192 * buildsym.c: Update all uses.
6194 2018-07-20 Tom Tromey <tom@tromey.com>
6196 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
6197 * buildsym.h (record_line_ftype): Remove typedef.
6199 2018-07-20 Tom Tromey <tom@tromey.com>
6201 * buildsym-legacy.h (augment_type_symtab): Don't declare.
6202 (end_expandable_symtab): Likewise.
6203 (end_symtab_get_static_block): Likewise.
6204 (end_symtab_from_static_block): Likewise.
6205 * buildsym-legacy.c (augment_type_symtab): Remove.
6206 (end_expandable_symtab): Remove.
6207 (end_symtab_get_static_block): Remove.
6208 (end_symtab_from_static_block): Remove.
6210 2018-07-20 Tom Tromey <tom@tromey.com>
6212 * dwarf2read.c: Include buildsym.h.
6213 (struct dwarf2_cu) <builder>: New method.
6214 (fixup_go_packaging): Update.
6215 (process_full_comp_unit, process_full_type_unit): Update. Don't
6216 use scoped_free_pendings.
6217 (using_directives): Add "cu" parameter, remove "language".
6218 (read_import_statement, setup_type_unit_groups, )
6219 (read_func_scope, read_lexical_block_scope)
6220 (dwarf2_record_block_ranges, read_namespace): Update.
6221 (lnp_state_machine::lnp_state_machine): Add cu parameter.
6222 (lnp_state_machine::handle_end_sequence): Update.
6223 (class lnp_state_machine) <m_cu>: New member.
6224 <m_record_line_callback>: Remove.
6225 <m_currently_recording_lines>: New member.
6226 (lnp_state_machine::handle_set_file): Update.
6227 (noop_record_line): Remove.
6228 (dwarf_record_line_p): Add cu parameter.
6229 (dwarf_record_line_1, dwarf_finish_line): Likewise.
6230 (lnp_state_machine::record_line)
6231 (lnp_state_machine::lnp_state_machine)
6232 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
6233 (dwarf_decode_lines): Update.
6234 (dwarf2_start_subfile): Add cu parameter.
6235 (dwarf2_start_symtab, new_symbol): Update.
6236 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
6237 Remove dwarf2_per_objfile parameter.
6238 (dwarf_decode_macros): Update.
6240 2018-07-20 Tom Tromey <tom@tromey.com>
6242 * stabsread.c (define_symbol): Update.
6243 * buildsym-legacy.h (get_buildsym_compunit): Declare.
6244 * dwarf2read.c (new_symbol): Update.
6245 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
6246 * cp-namespace.c: Include buildsym.h.
6247 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
6248 * buildsym-legacy.c (get_buildsym_compunit): New function.
6250 2018-07-20 Tom Tromey <tom@tromey.com>
6252 * xcoffread.c: Include buildsym-legacy.h.
6253 * windows-nat.c: Include buildsym-legacy.h.
6254 * stabsread.c: Include buildsym-legacy.h.
6255 * mdebugread.c: Include buildsym-legacy.h.
6256 * buildsym-legacy.h: New file.
6257 * buildsym-legacy.c: New file, from buildsym.c.
6258 * go32-nat.c: Include buildsym-legacy.h.
6259 * dwarf2read.c: Include buildsym-legacy.h.
6260 * dbxread.c: Include buildsym-legacy.h.
6261 * cp-namespace.c: Include buildsym-legacy.h.
6262 * coffread.c: Include buildsym-legacy.h.
6263 * buildsym.h: Move some contents to buildsym-legacy.h.
6264 * buildsym.c: Include buildsym-legacy.h. Move many functions to
6266 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
6268 2018-07-20 Tom Tromey <tom@tromey.com>
6270 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
6271 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
6272 (buildsym_compunit::buildsym_compunit)
6273 (buildsym_compunit::~buildsym_compunit)
6274 (buildsym_compunit::get_macro_table): Define.
6276 2018-07-20 Tom Tromey <tom@tromey.com>
6278 * buildsym.c (reset_symtab_globals): Remove.
6279 (buildsym_compunit::end_symtab_from_static_block): Update.
6280 (buildsym_compunit::augment_type_symtab): Update.
6281 (end_symtab_from_static_block): Call free_buildsym_compunit.
6282 (augment_type_symtab, end_symtab, end_expandable_symtab):
6285 2018-07-20 Tom Tromey <tom@tromey.com>
6287 * arch-utils.c: Do not include buildsym.h.
6288 * mipsread.c: Do not include buildsym.h.
6289 * machoread.c: Do not include buildsym.h.
6290 * elfread.c: Do not include buildsym.h.
6292 2018-07-20 Tom Tromey <tom@tromey.com>
6294 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
6296 (buildsym_compunit): Add new constructor.
6297 (struct buildsym_compunit) <get_last_source_file, finish_block,
6298 record_block_range, start_subfile, patch_subfile_names,
6299 push_subfile, pop_subfile, record_line, get_compunit_symtab,
6300 set_last_source_start_addr, get_last_source_start_addr,
6301 get_local_using_directives, set_local_using_directives,
6302 get_global_using_directives, outermost_context_p,
6303 get_current_context_stack, get_context_stack_depth,
6304 get_current_subfile, get_local_symbols, get_file_symbols,
6305 get_global_symbols, record_debugformat, record_producer,
6306 push_context, pop_context, end_symtab_get_static_block,
6307 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
6309 <record_pending_block, finish_block_internal, make_blockvector,
6310 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
6314 2018-05-22 Tom Tromey <tom@tromey.com>
6316 * buildsym.c (record_pending_block): Move earlier. Remove objfile
6318 (finish_block_internal): Update.
6320 2018-07-20 Tom Tromey <tom@tromey.com>
6322 * buildsym.c (record_pending_block): Move earlier. Remove objfile
6324 (finish_block_internal): Update.
6326 2018-07-20 Tom Tromey <tom@tromey.com>
6328 * buildsym.h (EXTERN): Don't define or undef.
6329 * buildsym.c (EXTERN): Don't define.
6331 2018-07-20 Tom Tromey <tom@tromey.com>
6333 * buildsym.c: Remove TODO comment.
6335 2018-07-20 Tom Tromey <tom@tromey.com>
6337 * coffread.c (coff_symtab_read): Update.
6338 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
6339 (xcoff_new_init): Update.
6340 * mipsread.c (mipscoff_new_init): Update.
6341 * mdebugread.c (mdebug_build_psymtabs): Update.
6342 * elfread.c (elf_new_init): Update.
6343 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
6345 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
6346 (coffstab_build_psymtabs, elfstab_build_psymtabs)
6347 (stabsect_build_psymtabs): Update.
6348 * buildsym.h (buildsym_init): Don't declare.
6349 * buildsym.c: Update comment.
6350 (prepare_for_building): Remove.
6351 (start_symtab, restart_symtab): Update.
6352 (reset_symtab_globals): Update comment.
6353 (buildsym_init): Remove.
6355 2018-07-20 Tom Tromey <tom@tromey.com>
6357 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
6358 * stabsread.c (patch_block_stabs, define_symbol, read_type)
6359 (read_enum_type, common_block_start, common_block_end)
6360 (cleanup_undefined_types_1, finish_global_stabs): Update.
6361 * mdebugread.c (psymtab_to_symtab_1): Update.
6362 * dwarf2read.c (fixup_go_packaging, read_func_scope)
6363 (read_lexical_block_scope, new_symbol): Update.
6364 * dbxread.c (process_one_symbol): Update.
6365 * coffread.c (coff_symtab_read, process_coff_symbol)
6366 (coff_read_enum_type): Update.
6367 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
6369 (get_local_symbols, get_file_symbols, get_global_symbols): New
6371 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
6373 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
6374 (~scoped_free_pendings): Update.
6375 (finish_block, prepare_for_building, reset_symtab_globals)
6376 (end_symtab_get_static_block, end_symtab_with_blockvector)
6377 (augment_type_symtab, push_context): Update.
6378 (get_local_symbols, get_file_symbols, get_global_symbols): New
6380 (buildsym_init): Update.
6382 2018-07-20 Tom Tromey <tom@tromey.com>
6384 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
6385 (process_full_type_unit): Likewise.
6386 (dwarf2_start_symtab): Set list_in_scope.
6388 2018-07-20 Tom Tromey <tom@tromey.com>
6390 * dwarf2read.c (process_psymtab_comp_unit_reader)
6391 (build_type_psymtabs_reader): Do not set list_in_scope.
6393 2018-07-20 Tom Tromey <tom@tromey.com>
6395 * buildsym.c (free_pendings): Remove.
6396 (add_symbol_to_list, scoped_free_pendings)
6397 (finish_block_internal, buildsym_init): Update.
6399 2018-07-20 Tom Tromey <tom@tromey.com>
6401 * xcoffread.c (read_xcoff_symtab): Update.
6402 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
6404 * dbxread.c (process_one_symbol): Update.
6405 * coffread.c (coff_symtab_read): Update.
6406 * buildsym.h (finish_block): Update.
6407 * buildsym.c (finish_block): Remove "listhead" argument.
6408 (end_symtab_get_static_block): Update.
6410 2018-07-20 Tom Tromey <tom@tromey.com>
6412 * buildsym.h (class scoped_free_pendings): Remove constructor.
6413 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
6415 <m_pending_block_obstack, m_pending_blocks>: New members.
6416 (pending_block_obstack, pending_blocks): Remove.
6417 (scoped_free_pendings::scoped_free_pendings): Default.
6418 (~scoped_free_pendings): Update.
6419 (free_pending_blocks): Remove.
6420 (finish_block_internal, record_pending_block, make_blockvector)
6421 (end_symtab_get_static_block, augment_type_symtab, push_context)
6422 (buildsym_init): Update.
6424 2018-07-20 Tom Tromey <tom@tromey.com>
6426 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
6427 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
6429 (pending_addrmap, pending_addrmap_obstack)
6430 (pending_addrmap_interesting): Remove.
6431 (scoped_free_pendings, record_block_range, make_blockvector)
6432 (prepare_for_building, reset_symtab_globals, buildsym_init):
6435 2018-07-20 Tom Tromey <tom@tromey.com>
6437 * xcoffread.c (process_linenos): Update.
6438 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
6439 * mdebugread.c (psymtab_to_symtab_1): Update.
6440 * dwarf2read.c (setup_type_unit_groups)
6441 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
6442 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
6443 * dbxread.c (process_one_symbol): Update.
6444 * coffread.c (coff_symtab_read, enter_linenos)
6445 (process_coff_symbol): Update.
6446 * buildsym.h (current_subfile): Don't declare.
6447 (get_current_subfile): Declare.
6448 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
6450 (start_subfile, free_buildsym_compunit, push_subfile)
6451 (prepare_for_building, start_symtab): Update.
6452 (get_current_subfile): New function.
6454 2018-07-20 Tom Tromey <tom@tromey.com>
6456 * coffread.c (coff_symtab_read): Update.
6457 * xcoffread.c (read_xcoff_symtab): Update.
6458 * dwarf2read.c (new_symbol): Update.
6459 (read_func_scope, read_lexical_block_scope): Update.
6460 * dbxread.c (process_one_symbol): Update.
6461 * buildsym.h (context_stack, context_stack_depth): Don't declare.
6462 (outermost_context_p): Remove macro.
6463 (outermost_context_p, get_current_context_stack)
6464 (get_context_stack_depth): Declare.
6465 (pop_context): Return struct context_stack.
6466 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
6468 (context_stack_size): Remove.
6469 (INITIAL_CONTEXT_STACK_SIZE): Remove.
6470 (prepare_for_building, end_symtab_get_static_block)
6471 (augment_type_symtab, push_context): Update.
6472 (pop_context): Return struct context_stack.
6473 (outermost_context_p, get_current_context_stack)
6474 (get_context_stack_depth): New functions.
6475 (buildsym_init): Update.
6477 2018-07-20 Tom Tromey <tom@tromey.com>
6479 * rust-exp.y: Now a pure parser. Update all rules.
6480 (%union): Move earlier.
6481 (current_parser, work_obstack): Remove globals.
6482 (rust_parser, ~rust_parser): Update.
6483 (class rust_parser) <copy_name, concat3, crate_name, super_name,
6484 lex_character, lex_number, lex_string, lex_identifier,
6485 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
6486 convert_name, convert_params_to_expression,
6487 convert_ast_to_expression, ast_basic_type, ast_operation,
6488 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
6489 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
6490 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
6491 ast_array_type, ast_slice_type, ast_reference_type,
6492 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
6493 (rust_parse): Update.
6494 (rustyyerror, rustyylex): Add parser parameter.
6495 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
6496 (rust_lex_stringish_test, rust_lex_test_sequence)
6497 (rust_lex_test_trailing_dot, rust_lex_test_completion)
6498 (rust_lex_test_push_back, rust_lex_tests): Update.
6500 2018-07-19 Pedro Alves <palves@redhat.com>
6502 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
6503 gdb::unique_xmalloc_ptr.
6504 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
6505 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
6506 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
6507 copy-initialization.
6508 * guile/scm-pretty-print.c (ppscm_print_children): Use
6509 gdb::unique_xmalloc_ptr instead of cleanups.
6510 (gdbscm_apply_val_pretty_printer): Remove cleanups.
6511 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
6512 gdb::unique_xmalloc_ptr.
6513 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
6514 Adjust to use gdb::unique_xmalloc_ptr.
6515 * guile/scm-utils.c (extract_arg): Adjust.
6516 * guile/scm-value.c (gdbscm_value_field): Adjust to use
6517 gdb::unique_xmalloc_ptr instead of a cleanup.
6519 2018-07-19 Tom Tromey <tom@tromey.com>
6521 * utils.c (do_value_free_to_mark)
6522 (make_cleanup_value_free_to_mark): Remove.
6523 * utils.h (make_cleanup_value_free_to_mark): Remove.
6525 2018-07-19 Pedro Alves <palves@redhat.com>
6527 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
6528 forwarding reference.
6530 2018-07-18 Pedro Alves <palves@redhat.com>
6532 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
6533 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
6536 2018-07-18 Pedro Alves <palves@redhat.com>
6538 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
6540 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
6542 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
6543 directly instead of a cleanup.
6544 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
6545 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
6546 (vlscm_binop_gdbthrow): New, factored out from ...
6547 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
6548 (vlscm_rich_compare): Use gdbscm_wrap.
6549 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
6550 instead of a cleanup.
6551 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
6553 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
6554 Use xfree directly instead of a cleanup.
6555 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
6556 Adjust to use gdbscm_wrap and scoped_value_mark.
6557 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
6558 (gdbscm_value_address, gdbscm_value_dereference)
6559 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
6561 (gdbscm_value_dynamic_type): Use scoped_value_mark.
6562 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
6564 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
6565 gdbscm_wrap and scoped_value_mark.
6566 (gdbscm_value_to_string): Use xfree directly instead of a
6567 cleanup. Move 'buffer' unique_ptr to TRY scope.
6568 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
6569 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
6571 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
6572 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
6574 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
6577 2018-07-18 Tom de Vries <tdevries@suse.de>
6579 * findvar.c (default_read_var_value): Also resolve dynamic type for
6580 LOC_OPTIMIZED_OUT vars.
6582 2018-07-18 Maciej W. Rozycki <macro@mips.com>
6584 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
6587 2018-07-17 Tom Tromey <tom@tromey.com>
6589 * guile/scm-param.c (pascm_set_func, pascm_show_func)
6590 (compute_enum_list, pascm_set_param_value_x)
6591 (gdbscm_parameter_value): Update.
6592 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
6593 (gdbscm_scm_to_host_string): Update.
6594 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
6596 * guile/scm-cmd.c (cmdscm_add_completion): Update.
6597 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
6598 * guile/scm-string.c (gdbscm_scm_to_string): Return
6600 (gdbscm_scm_to_host_string): Likewise.
6602 2018-07-17 Tom Tromey <tom@tromey.com>
6604 * guile/guile.c (gdbscm_eval_from_control_command): Update.
6605 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
6606 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
6607 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
6610 2018-07-17 Tom Tromey <tom@tromey.com>
6612 * guile/scm-param.c (pascm_signal_setshow_error): Update.
6613 * guile/guile-internal.h (gdbscm_exception_message_to_string):
6615 * guile/scm-cmd.c (cmdscm_function): Update.
6616 * guile/scm-pretty-print.c
6617 (ppscm_print_exception_unless_memory_error): Update.
6618 * guile/scm-exception.c (gdbscm_exception_message_to_string):
6619 Return unique_xmalloc_ptr.
6621 2018-07-17 Tom Tromey <tom@tromey.com>
6623 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
6626 2018-07-17 Jim Wilson <jimw@sifive.com>
6628 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
6629 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
6630 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
6631 unecessary braces after EF_RISCV_RVC test. Delete call to
6632 set_gdbarch_decr_pc_after_break.
6634 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
6635 RISCV_LAST_FP_REGNUM + 1.
6636 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
6638 2018-07-17 Tom Tromey <tom@tromey.com>
6640 * configure.ac: Remove --disable-gdbcli.
6641 * configure: Rebuild.
6642 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
6643 (SUBDIR_CLI_CFLAGS): Remove.
6644 (SFILES): Use SUBDIR_CLI_SRCS.
6645 (COMMON_OBS): Use SUBDIR_CLI_OBS.
6647 2018-07-17 Tom Tromey <tom@tromey.com>
6650 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
6652 2018-07-16 Jim Wilson <jimw@sifive.com>
6654 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
6656 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
6658 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
6660 (libunwind_frame_sniffer): Likewise.
6661 (libunwind_frame_prev_register): Likewise.
6662 (libunwind_sigtramp_frame_sniffer): Likewise.
6663 * ia64-tdep.c (ia64_access_reg): Likewise.
6664 (ia64_access_rse_reg): Likewise.
6665 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
6666 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
6668 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
6670 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
6672 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
6674 * remote-sim.c (gdbsim_target::close,
6675 gdbsim_target::mourn_inferior): Remove unused variables.
6677 2018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
6679 * ia64-tdep.c (ktab_buf): New global.
6680 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
6681 (get_kernel_table): Adjust.
6683 2018-07-16 Tom Tromey <tom@tromey.com>
6685 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
6686 * dwarf2read.c (using_directives, new_symbol): Use
6687 outermost_context_p.
6688 * dbxread.c (process_one_symbol): Use outermost_context_p.
6689 * coffread.c (coff_symtab_read): Use outermost_context_p.
6691 2018-07-16 Tom Tromey <tom@tromey.com>
6693 * dwarf2read.c (using_directives, read_func_scope)
6694 (read_lexical_block_scope): Update.
6695 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
6696 * buildsym.h (local_using_directives, global_using_directives):
6698 (get_local_using_directives, set_local_using_directives)
6699 (get_global_using_directives): Declare.
6700 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
6701 m_global_using_directives>: New members.
6702 (finish_block_internal, prepare_for_building)
6703 (reset_symtab_globals, end_symtab_get_static_block)
6704 (push_context): Update.
6705 (get_local_using_directives, set_local_using_directives)
6706 (get_global_using_directives): New functions.
6707 (buildsym_init): Update.
6709 2018-07-16 Tom Tromey <tom@tromey.com>
6711 * xcoffread.c (xcoff_initial_scan): Don't call
6712 free_pending_blocks.
6713 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
6714 * buildsym.h (class scoped_free_pendings): Add constructor.
6715 (free_pending_blocks): Don't declare.
6716 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
6717 (free_pending_blocks): Now static.
6719 2018-07-16 Tom Tromey <tom@tromey.com>
6721 * buildsym.h (push_subfile, pop_subfile): Update declarations.
6722 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
6724 (struct subfile_stack): Remove.
6725 (subfile_stack): Remove.
6726 (push_subfile, pop_subfile, buildsym_init): Update.
6728 2018-07-16 Tom Tromey <tom@tromey.com>
6730 * buildsym.c (push_subfile): Use gdb_assert.
6731 (pop_subfile): Use gdb_assert.
6733 2018-07-16 Tom Tromey <tom@tromey.com>
6735 * buildsym.h (merge_symbol_lists): Remove.
6736 * buildsym.c (merge_symbol_lists): Remove.
6738 2018-07-16 Tom Tromey <tom@tromey.com>
6740 * stabsread.c (scan_file_globals): Update comment.
6741 * stabsread.h (scan_file_globals): Move from buildsym.h.
6742 * buildsym.h (scan_file_globals): Move to stabsread.h.
6744 2018-07-16 Tom Tromey <tom@tromey.com>
6746 * xcoffread.c (xcoff_new_init): Update.
6747 * mipsread.c (mipscoff_new_init): Update.
6748 * mdebugread.c (mdebug_build_psymtabs): Update.
6749 * elfread.c (elf_new_init): Update.
6750 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
6751 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
6752 * buildsym.h (buildsym_new_init): Don't declare.
6753 * buildsym.c (buildsym_new_init): Remove.
6755 2018-07-16 Tom Tromey <tom@tromey.com>
6757 * stabsread.h (within_function): Move from buildsym.h.
6758 * stabsread.c (start_stabs): Clear within_function.
6759 * coffread.c (coff_start_symtab): Clear within_function.
6760 * buildsym.h (within_function): Move to stabsread.h.
6761 * buildsym.c (prepare_for_building): Update.
6763 2018-07-16 Tom Tromey <tom@tromey.com>
6765 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
6766 * dwarf2read.c (dwarf2_start_symtab): Don't set
6767 processing_gcc_compilation.
6768 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
6770 2018-07-16 Tom Tromey <tom@tromey.com>
6772 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
6773 (next_symbol_text_func): Move from buildsym.h.
6774 * stabsread.c (hashname): Move from buildsym.c.
6775 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
6776 (next_symbol_text_func, hashname): Move to stabsread.h.
6777 * buildsym.c: Don't include bcache.h
6778 (hashname): Move to stasbread.c.
6780 2018-07-16 Tom Tromey <tom@tromey.com>
6782 * buildsym.h (context_stack_size): Don't declare.
6783 * buildsym.c (context_stack_size): New global.
6785 2018-07-16 Tom Tromey <tom@tromey.com>
6787 * dbxread.c (processing_acc_compilation): New global.
6788 * buildsym.h (processing_acc_compilation): Don't declare.
6790 2018-07-16 Tom Tromey <tom@tromey.com>
6792 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
6793 * dbxread.c (read_ofile_symtab): Update.
6794 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
6795 * buildsym.h (last_source_start_addr): Remove.
6796 (set_last_source_start_addr, get_last_source_start_addr):
6798 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
6800 (struct buildsym_compunit) <m_last_source_start_addr>: New
6802 (prepare_for_building): Remove start_addr parameter.
6803 (start_symtab, restart_symtab, end_symtab_get_static_block)
6804 (end_symtab_with_blockvector): Update.
6805 (set_last_source_start_addr, get_last_source_start_addr): New
6808 2018-07-16 Tom Tromey <tom@tromey.com>
6810 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
6812 (have_line_numbers): Remove.
6813 (record_line, prepare_for_building, end_symtab_get_static_block)
6814 (augment_type_symtab): Update.
6816 2018-07-16 Tom Tromey <tom@tromey.com>
6818 * buildsym.c (~buildsym_compunit): Free the macro table.
6819 (struct buildsym_compunit) <get_macro_table, release_macros>: New
6821 <m_pending_macros>: New member.
6822 (pending_macros): Remove.
6823 (~scoped_free_pendings, get_macro_table, prepare_for_building)
6824 (reset_symtab_globals, end_symtab_get_static_block)
6825 (end_symtab_with_blockvector, augment_type_symtab)
6826 (buildsym_init): Update.
6828 2018-07-16 Tom Tromey <tom@tromey.com>
6830 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
6832 (buildsym_compunit::set_last_source_file): New method.
6833 <m_last_source_file>: New member.
6834 (prepare_for_building): Remove "name" parameter.
6835 (start_symtab, restart_symtab, reset_symtab_globals): Update.
6836 (last_source_file): Remove.
6837 (set_last_source_file, get_last_source_file): Update.
6839 2018-07-16 Tom Tromey <tom@tromey.com>
6841 * buildsym.c (prepare_for_building): Add assert.
6843 2018-07-16 Tom Tromey <tom@tromey.com>
6845 * buildsym.c (~buildsym_compunit): Update.
6846 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
6847 (start_subfile, patch_subfile_names)
6848 (end_symtab_with_blockvector): Update.
6850 2018-07-16 Tom Tromey <tom@tromey.com>
6852 * buildsym.c (struct buildsym_compunit): Add constructor,
6853 destructor, initializers.
6854 (start_buildsym_compunit): Remove.
6855 (free_buildsym_compunit): Use "delete".
6856 (start_symtab, restart_symtab): Use "new".
6858 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
6860 * symfile.c (set_objfile_default_section_offset): Remove struct
6863 2018-07-14 Stafford Horne <shorne@gmail.com>
6865 * (Responsible Maintainers): Add myself as or1k maintainer.
6867 2018-07-13 Tom Tromey <tom@tromey.com>
6869 * symfile.c (set_objfile_default_section_offset): Use extra braces
6872 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
6874 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
6877 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6879 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6880 unittests/cli-utils-selftests.c
6881 * unittests/cli-utils-selftests.c: New file.
6883 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6885 * NEWS: Mention new commands. Mention change to 'thread apply'.
6887 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6889 * thread.c (thr_try_catch_cmd): New function.
6890 (thread_apply_all_command): Handle qcs flags.
6891 (thread_apply_command): Handle qcs flags.
6892 (taas_command): New function.
6893 (tfaas_command): New function.
6894 (_initialize_thread): Update to setup the new commands 'taas
6895 and 'tfaas'. Change doc string for 'thread apply'.
6897 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6899 * stack.c: (trailing_outermost_frame): New function, mostly
6900 extracted from backtrace_command_1.
6901 (leading_innermost_frame): New function.
6902 (backtrace_command_1): Update to call trailing_outermost_frame.
6903 (frame_apply_command_count): New function.
6904 (frame_apply_level_command): New function.
6905 (frame_apply_all_command): New function.
6906 (frame_apply_command): New function.
6907 (faas_command): New function.
6908 (frame_cmd_list): New variable.
6909 (_initialize_stack): Update to setup the new commands 'frame apply'
6912 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6914 * cli-utils.c (number_or_range_parser::get_number): Only handle
6915 numbers or convenience var as numbers.
6916 (parse_flags): New function.
6917 (parse_flags_qcs): New function.
6918 (number_or_range_parser::finished): Ensure parsing end is detected
6919 before end of string.
6920 * cli-utils.h (parse_flags): New function.
6921 (parse_flags_qcs): New function.
6922 (number_or_range_parser): Remove m_finished bool.
6923 (number_or_range_parser::skip_range): Set m_in_range to false.
6925 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
6927 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
6930 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
6931 Jan Kratochvil <jan.kratochvil@redhat.com>
6932 Paul Fertser <fercerpav@gmail.com>
6933 Tsutomu Seki <sekiriki@gmail.com>
6934 Pedro Alves <palves@redhat.com>
6936 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6937 'unittests/parse-connection-spec-selftests.c'.
6938 (COMMON_SFILES): Add 'common/netstuff.c'.
6939 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
6940 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
6941 * common/netstuff.c: New file.
6942 * common/netstuff.h: New file.
6943 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
6944 (wait_for_connect): Update comment. New parameter
6945 'gdb::optional<int> sock' instead of 'struct serial *scb'.
6946 Use 'sock' directly instead of 'scb->fd'.
6947 (try_connect): New function, with code from 'net_open'.
6948 (net_open): Rewrite main loop to deal with multiple
6949 sockets/addresses. Handle IPv6-style hostnames; implement
6950 support for IPv6 connections.
6951 * unittests/parse-connection-spec-selftests.c: New file.
6953 2018-07-11 Pedro Alves <palves@redhat.com>
6956 * remote.c (remote_target::remote_detach_pid): Call
6957 set_current_process.
6959 2018-07-11 Pedro Alves <palves@redhat.com>
6961 * h8300-tdep.c (h8300_gdbarch_init): Remove
6962 set_gdbarch_ecoff_reg_to_regnum calls.
6964 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
6967 * c-typeprint.c (c_type_print_base_struct_union): Don't print
6968 offsets/sizes for static members of a class/struct.
6970 2018-07-11 Alan Hayward <alan.hayward@arm.com>
6972 * target-descriptions.c (tdesc_register_bitsize): Rename.
6973 * target-descriptions.h (tdesc_register_bitsize): Likewise.
6974 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
6975 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
6977 2018-07-10 Tom Tromey <tom@tromey.com>
6979 * breakpoint.c (moribund_locations): Now static and a
6981 (breakpoint_init_inferior, moribund_breakpoint_here_p)
6982 (build_bpstat_chain, update_global_location_list)
6983 (breakpoint_retire_moribund): Update.
6984 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
6987 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
6989 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
6990 (riscv_register_reggroup_p): Use new function, remove unneeded
6992 (riscv_push_dummy_call): Extend assert to compare against xlen or
6993 flen based on register type.
6995 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
6997 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
6999 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
7001 * remote.c (show_hardware_watchpoint_limit): New function.
7002 (show_hardware_watchpoint_length_limit): New function.
7003 (show_hardware_breakpoint_limit): New function.
7004 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
7005 where appropriate, update help text.
7007 2018-07-09 Tom Tromey <tom@tromey.com>
7009 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
7010 (CLIBS): Don't mention NAT_CLIBS.
7012 2018-07-09 Tom Tromey <tom@tromey.com>
7014 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
7015 (LIBGDB_OBS, clean mostlyclean): Update.
7016 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
7018 2018-07-09 Tom Tromey <tom@tromey.com>
7020 * Makefile.in (%.c: %.y): Use ECHO_YACC.
7021 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
7022 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
7024 2018-07-09 Tom Tromey <tom@tromey.com>
7026 * Makefile.in (ALLDEPFILES): Remove exec.c.
7027 (COMMON_OBS): Remove exec.o.
7028 (COMMON_SFILES): Add exec.c.
7030 2018-07-09 Tom Tromey <tom@tromey.com>
7032 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
7034 2018-07-09 Tom Tromey <tom@tromey.com>
7036 * Makefile.in (clean mostlyclean): Remove stamp-version.
7037 (version.c): Depend on stamp-version.
7038 (stamp-version): New rule, from version.c rule.
7040 2018-07-09 Tom Tromey <tom@tromey.com>
7042 * Makefile.in (init.c): Depend on stamp-init.
7043 (stamp-init): New rule, from init.c rule.
7044 (clean mostlyclean): Remove stamp-init.
7046 2018-07-09 Tom Tromey <tom@tromey.com>
7048 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
7049 SUBDIR_GCC_COMPILE_SRCS.
7051 2018-07-09 Tom Tromey <tom@tromey.com>
7053 * Makefile.in (init.c): Remove some unused sed rules.
7055 2018-07-09 Tom Tromey <tom@tromey.com>
7057 * Makefile.in (TSOBS): Remove.
7058 (INIT_FILES): Update.
7059 (LIBGDB_OBS): Update.
7060 (COMMON_SFILES): Add inflow.c.
7061 (SFILES): Remove inflow.c.
7063 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
7065 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
7067 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
7069 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
7070 get_saveloc_name, is_signal_frame_name, step_name,
7071 init_remote_name, create_addr_space_name,
7072 destroy_addr_space_name, search_unwind_table_name,
7073 find_dyn_list_name): Constify.
7075 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
7077 * darwin-nat.c (darwin_pthread_kill): New function.
7078 (darwin_resume_thread): Use darwin_pthread_kill.
7080 2018-07-05 Tom de Vries <tdevries@suse.de>
7082 * macroexp.c (macro_buffer) <operator=>: New member function.
7084 2018-07-04 Tom Tromey <tom@tromey.com>
7086 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
7088 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
7090 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
7091 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
7092 * maint.c: Likewise.
7095 2018-07-04 Joel Brobecker <brobecker@adacore.com>
7097 * NEWS: Create a new section for the next release branch.
7098 Rename the section of the current branch, now that it has
7101 2018-07-04 Joel Brobecker <brobecker@adacore.com>
7103 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
7104 * version.in: Bump version to 8.2.50.DATE-git.
7106 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
7107 Pedro Alves <palves@redhat.com>
7109 * linux-nat.c (linux_init_ptrace): Rename to ...
7110 (linux_init_ptrace_procfs): ... this. Call
7111 linux_proc_init_warnings.
7112 (linux_nat_target::post_attach)
7113 (linux_nat_target::post_startup_inferior): Adjust.
7114 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
7115 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
7117 2018-07-04 Tom de Vries <tdevries@suse.de>
7119 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
7121 (read_comp_unit_head): ... here.
7123 2018-07-03 Tom Tromey <tom@tromey.com>
7125 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
7126 (stop_tracing, tstatus_command)
7127 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
7128 (print_one_static_tracepoint_marker): Update.
7129 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
7131 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
7133 (all_tracepoints, static_tracepoints_here): Return std::vector.
7135 2018-07-03 Tom Tromey <tom@tromey.com>
7137 * common/ptid.c (ptid_equal): Remove.
7138 * common/ptid.h (ptid_equal): Don't declare.
7139 * ada-tasks.c: Update.
7140 * breakpoint.c: Update.
7141 * common/agent.c: Update.
7142 * corelow.c: Update.
7143 * darwin-nat-info.c: Update.
7144 * darwin-nat.c: Update.
7146 * dtrace-probe.c: Update.
7147 * dummy-frame.c: Update.
7148 * fbsd-nat.c: Update.
7150 * gdbthread.h: Update.
7151 * gnu-nat.c: Update.
7152 * go32-nat.c: Update.
7153 * inf-loop.c: Update.
7154 * inf-ptrace.c: Update.
7155 * infcall.c: Update.
7159 * linux-fork.c: Update.
7160 * linux-nat.c: Update.
7161 * linux-thread-db.c: Update.
7162 * mi/mi-cmd-var.c: Update.
7163 * mi/mi-interp.c: Update.
7164 * mi/mi-main.c: Update.
7165 * nto-procfs.c: Update.
7166 * ppc-linux-tdep.c: Update.
7168 * python/py-inferior.c: Update.
7169 * python/py-record-btrace.c: Update.
7170 * python/py-record.c: Update.
7171 * ravenscar-thread.c: Update.
7172 * regcache.c: Update.
7173 * remote-sim.c: Update.
7175 * sol-thread.c: Update.
7178 * tui/tui-stack.c: Update.
7180 * windows-nat.c: Update.
7181 * windows-tdep.c: Update.
7183 2018-07-03 Tom Tromey <tom@tromey.com>
7185 * common/ptid.c (ptid_match): Remove.
7186 * common/ptid.h (ptid_match): Don't declare.
7187 * fbsd-nat.c: Update.
7190 * linux-nat.c: Update.
7191 * record-btrace.c: Update.
7192 * regcache.c: Update.
7195 2018-07-03 Tom Tromey <tom@tromey.com>
7197 * common/ptid.c (ptid_tid_p): Remove.
7198 * common/ptid.h (ptid_tid_p): Don't declare.
7199 * sol-thread.c: Update.
7201 2018-07-03 Tom Tromey <tom@tromey.com>
7203 * common/ptid.c (ptid_lwp_p): Remove.
7204 * common/ptid.h (ptid_lwp_p): Don't declare.
7205 * fbsd-nat.c: Update.
7206 * linux-nat.c: Update.
7207 * nat/linux-procfs.c: Update.
7208 * nat/x86-linux-dregs.c: Update.
7209 * sol-thread.c: Update.
7211 2018-07-03 Tom Tromey <tom@tromey.com>
7213 * common/ptid.c (ptid_is_pid): Remove.
7214 * common/ptid.h (ptid_is_pid): Don't declare.
7216 * linux-nat.c: Update.
7217 * mi/mi-interp.c: Update.
7221 2018-07-03 Tom Tromey <tom@tromey.com>
7223 * common/ptid.c (ptid_get_tid): Remove.
7224 * common/ptid.h (ptid_get_tid): Don't declare.
7225 * ada-tasks.c: Update.
7226 * aix-thread.c: Update.
7227 * bsd-uthread.c: Update.
7228 * darwin-nat.c: Update.
7229 * fbsd-nat.c: Update.
7230 * i386-darwin-nat.c: Update.
7232 * linux-tdep.c: Update.
7233 * nto-procfs.c: Update.
7234 * ppc-ravenscar-thread.c: Update.
7235 * python/py-infthread.c: Update.
7236 * ravenscar-thread.c: Update.
7237 * sol-thread.c: Update.
7238 * sparc-ravenscar-thread.c: Update.
7239 * windows-nat.c: Update.
7241 2018-07-03 Tom Tromey <tom@tromey.com>
7243 * common/ptid.c (ptid_get_lwp): Remove.
7244 * common/ptid.h (ptid_get_lwp): Don't declare.
7245 * aarch64-linux-nat.c: Update.
7246 * ada-tasks.c: Update.
7247 * aix-thread.c: Update.
7248 * amd64-linux-nat.c: Update.
7249 * arm-linux-nat.c: Update.
7250 * corelow.c: Update.
7251 * fbsd-nat.c: Update.
7252 * fbsd-tdep.c: Update.
7253 * gnu-nat.c: Update.
7254 * i386-cygwin-tdep.c: Update.
7255 * i386-gnu-nat.c: Update.
7256 * i386-linux-nat.c: Update.
7257 * ia64-linux-nat.c: Update.
7258 * inf-ptrace.c: Update.
7260 * linux-fork.c: Update.
7261 * linux-nat.c: Update.
7262 * linux-tdep.c: Update.
7263 * linux-thread-db.c: Update.
7264 * mips-linux-nat.c: Update.
7265 * nat/aarch64-linux-hw-point.c: Update.
7266 * nat/aarch64-linux.c: Update.
7267 * nat/linux-btrace.c: Update.
7268 * nat/linux-osdata.c: Update.
7269 * nat/linux-procfs.c: Update.
7270 * nat/x86-linux-dregs.c: Update.
7271 * obsd-nat.c: Update.
7272 * ppc-fbsd-nat.c: Update.
7273 * ppc-linux-nat.c: Update.
7275 * python/py-infthread.c: Update.
7276 * ravenscar-thread.c: Update.
7278 * s390-linux-nat.c: Update.
7279 * sol-thread.c: Update.
7280 * sol2-tdep.c: Update.
7281 * spu-linux-nat.c: Update.
7282 * x86-linux-nat.c: Update.
7283 * xtensa-linux-nat.c: Update.
7285 2018-07-03 Tom Tromey <tom@tromey.com>
7287 * common/ptid.c (ptid_get_pid): Remove.
7288 * common/ptid.h (ptid_get_pid): Don't declare.
7289 * aarch64-linux-nat.c: Update.
7290 * ada-lang.c: Update.
7291 * aix-thread.c: Update.
7292 * alpha-bsd-nat.c: Update.
7293 * amd64-fbsd-nat.c: Update.
7294 * amd64-linux-nat.c: Update.
7295 * arm-linux-nat.c: Update.
7296 * arm-nbsd-nat.c: Update.
7298 * break-catch-syscall.c: Update.
7299 * breakpoint.c: Update.
7300 * bsd-uthread.c: Update.
7301 * corelow.c: Update.
7303 * darwin-nat.c: Update.
7304 * fbsd-nat.c: Update.
7305 * fbsd-tdep.c: Update.
7307 * gnu-nat.c: Update.
7308 * hppa-nbsd-nat.c: Update.
7309 * hppa-obsd-nat.c: Update.
7310 * i386-fbsd-nat.c: Update.
7311 * ia64-linux-nat.c: Update.
7312 * inf-ptrace.c: Update.
7314 * inferior.c: Update.
7315 * inferior.h: Update.
7318 * linux-fork.c: Update.
7319 * linux-nat.c: Update.
7320 * linux-tdep.c: Update.
7321 * linux-thread-db.c: Update.
7322 * m68k-bsd-nat.c: Update.
7323 * mi/mi-interp.c: Update.
7324 * mi/mi-main.c: Update.
7325 * mips-linux-nat.c: Update.
7326 * mips-nbsd-nat.c: Update.
7327 * mips64-obsd-nat.c: Update.
7328 * nat/aarch64-linux-hw-point.c: Update.
7329 * nat/aarch64-linux.c: Update.
7330 * nat/linux-btrace.c: Update.
7331 * nat/linux-osdata.c: Update.
7332 * nat/linux-procfs.c: Update.
7333 * nat/x86-linux-dregs.c: Update.
7334 * nto-procfs.c: Update.
7335 * obsd-nat.c: Update.
7336 * ppc-linux-nat.c: Update.
7337 * ppc-nbsd-nat.c: Update.
7338 * ppc-obsd-nat.c: Update.
7339 * proc-service.c: Update.
7341 * python/py-inferior.c: Update.
7342 * python/py-infthread.c: Update.
7343 * ravenscar-thread.c: Update.
7345 * remote-sim.c: Update.
7347 * rs6000-nat.c: Update.
7348 * s390-linux-nat.c: Update.
7349 * sh-nbsd-nat.c: Update.
7350 * sol-thread.c: Update.
7351 * sparc-nat.c: Update.
7352 * sparc64-tdep.c: Update.
7353 * spu-linux-nat.c: Update.
7354 * spu-tdep.c: Update.
7355 * target-debug.h: Update.
7358 * tid-parse.c: Update.
7359 * tracefile-tfile.c: Update.
7360 * vax-bsd-nat.c: Update.
7361 * windows-nat.c: Update.
7362 * x86-linux-nat.c: Update.
7363 * x86-nat.c: Update.
7365 2018-07-03 Tom Tromey <tom@tromey.com>
7367 * common/ptid.c (pid_to_ptid): Remove.
7368 * common/ptid.h (pid_to_ptid): Don't declare.
7369 * aix-thread.c: Update.
7370 * arm-linux-nat.c: Update.
7371 * common/ptid.c: Update.
7372 * common/ptid.h: Update.
7373 * corelow.c: Update.
7375 * darwin-nat.c: Update.
7376 * fbsd-nat.c: Update.
7377 * fork-child.c: Update.
7378 * gnu-nat.c: Update.
7379 * go32-nat.c: Update.
7380 * inf-ptrace.c: Update.
7382 * inferior.c: Update.
7384 * linux-fork.c: Update.
7385 * linux-nat.c: Update.
7386 * nat/aarch64-linux-hw-point.c: Update.
7387 * nat/fork-inferior.c: Update.
7388 * nat/x86-linux-dregs.c: Update.
7389 * nto-procfs.c: Update.
7390 * obsd-nat.c: Update.
7392 * progspace.c: Update.
7394 * rs6000-nat.c: Update.
7395 * s390-linux-nat.c: Update.
7396 * sol-thread.c: Update.
7397 * spu-linux-nat.c: Update.
7400 * tracefile-tfile.c: Update.
7401 * windows-nat.c: Update.
7403 2018-07-03 Tom Tromey <tom@tromey.com>
7405 * common/ptid.h (ptid_build): Don't declare.
7406 * common/ptid.c (ptid_build): Remove.
7407 * aix-thread.c: Update.
7408 * bsd-kvm.c: Update.
7409 * bsd-uthread.c: Update.
7410 * common/agent.c: Update.
7411 * common/ptid.c: Update.
7412 * common/ptid.h: Update.
7413 * corelow.c: Update.
7414 * darwin-nat.c: Update.
7415 * fbsd-nat.c: Update.
7416 * gnu-nat.c: Update.
7417 * linux-fork.c: Update.
7418 * linux-nat.c: Update.
7419 * linux-thread-db.c: Update.
7420 * nat/linux-osdata.c: Update.
7421 * nat/linux-procfs.c: Update.
7422 * nto-procfs.c: Update.
7423 * obsd-nat.c: Update.
7424 * proc-service.c: Update.
7426 * ravenscar-thread.c: Update.
7427 * remote-sim.c: Update.
7429 * sol-thread.c: Update.
7431 * windows-nat.c: Update.
7433 2018-07-03 Tom Tromey <tom@tromey.com>
7435 * infrun.c (follow_exec): Use exit_inferior_silent.
7436 * inferior.c (exit_inferior_num_silent): Remove.
7437 * inferior.h (exit_inferior_num_silent): Don't declare.
7439 2018-07-03 Tom Tromey <tom@tromey.com>
7442 * darwin-nat.c (darwin_attach_pid): Reset inferior and
7443 inferior_ptid on error.
7445 2018-07-02 Maciej W. Rozycki <macro@mips.com>
7446 Simon Marchi <simon.marchi@polymtl.ca>
7449 * disasm.h (gdb_disassembler): Add
7450 `m_disassembler_options_holder'. member
7451 * disasm.c (get_all_disassembler_options): New function.
7452 (gdb_disassembler::gdb_disassembler): Use it.
7453 (gdb_buffered_insn_length_init_dis): Likewise.
7454 (gdb_buffered_insn_length): Adjust accordingly.
7455 (set_disassembler_options): Handle options with arguments.
7456 (show_disassembler_options_sfunc): Likewise. Add a leading new
7457 line if showing options with descriptions.
7458 (disassembler_options_completer): Adapt to using the
7459 `disasm_options_and_args_t' structure.
7460 * mips-tdep.c (mips_disassembler_options): New variable.
7461 (mips_disassembler_options_o32): Likewise.
7462 (mips_disassembler_options_n32): Likewise.
7463 (mips_disassembler_options_n64): Likewise.
7464 (gdb_print_insn_mips): Don't set `disassembler_options'.
7465 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
7467 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
7468 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
7469 `gdbarch_disassembler_options_implicit' and
7470 `gdbarch_valid_disassembler_options'.
7471 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
7472 `disasm_options_and_args_t' structure.
7473 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
7475 (valid_disassembler_options): Switch from `disasm_options_t' to
7476 the `disasm_options_and_args_t' structure.
7477 * NEWS: Document `set disassembler-options' support for the MIPS
7479 * gdbarch.h: Regenerate.
7480 * gdbarch.c: Regenerate.
7482 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
7484 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
7486 2018-06-29 Joel Brobecker <brobecker@adacore.com>
7488 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
7489 parameter in call to amd64_target_description.
7490 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
7491 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
7492 (amd64fbsd_init_abi): Likewise.
7493 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
7494 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
7495 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
7496 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
7498 2018-06-29 Pedro Alves <palves@redhat.com>
7500 * gdb/amd64-tdep.h (amd64_create_target_description): Add
7501 "segments" parameter.
7502 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
7503 (_initialize_amd64_tdep): Update call to
7504 amd64_create_target_description.
7505 (amd64_target_description): Add "segments" parameter. Adjust
7506 the implementation to use it.
7507 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
7508 call to amd64_create_target_description.
7509 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
7510 * gdb/arch/amd64.h (amd64_create_target_description): Add
7511 "segments" register.
7512 * gdb/arch/amd64.c (amd64_create_target_description): Add
7513 "segments" parameter. Call create_feature_i386_64bit_segments
7514 only if SEGMENTS is true.
7515 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
7516 call to amd64_create_target_description.
7518 2018-06-29 Pedro Alves <palves@redhat.com>
7520 * thread.c (thread_target_id_str): New, factored out from ...
7521 (print_thread_info_1): ... here. Use it to compute the max
7522 "Target Id" column width.
7524 2018-06-29 Pedro Alves <palves@redhat.com>
7526 * remote.c (remote_target::extra_thread_info): Delete
7527 'display_buf' and 'n' locals. from the cache, regardless of
7528 packet mechanims is in use. Use cache for qThreadExtra and qP
7531 2018-06-29 Pedro Alves <palves@redhat.com>
7533 * blockframe.c (find_pc_sect_containing_function): New function.
7534 * breakpoint.c (print_breakpoint_location): Don't call
7535 find_pc_sect_function.
7536 * linespec.c (create_sals_line_offset): Record the location's
7538 * linespec.c (convert_address_location_to_sals): Fill in sal's
7539 symbol with find_pc_sect_containing_function.
7540 * symtab.c (find_function_start_sal): Rename to ...
7541 (find_function_start_sal_1): ... this.
7542 (find_function_start_sal): Reimplement as wrapper around
7543 find_function_start_sal_1, and use
7544 find_pc_sect_containing_function to fill in the sal's symbol.
7545 (find_function_start_sal(symbol*, bool)): Adjust.
7546 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
7548 (find_pc_sect_containing_function): Declare.
7550 2018-06-29 Pedro Alves <palves@redhat.com>
7552 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
7553 true if the the location has no symbol.
7555 2018-06-28 Tom Tromey <tom@tromey.com>
7557 * NEWS: Mention --enable-codesign.
7558 * silent-rules.mk (ECHO_SIGN): New variable.
7559 * configure.ac: Add --enable-codesign.
7560 * configure: Rebuild.
7561 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
7562 (gdb$(EXEEXT)): Optionally invoke codesign.
7564 2018-06-28 Pedro Alves <palves@redhat.com>
7566 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
7568 (switch_to_thread_no_regs): Adjust comment.
7569 * infcmd.c (stop_pc): Delete.
7570 (post_create_inferior, info_program_command): Replace references
7571 to stop_pc with references to thread_info->suspend.stop_pc.
7572 * inferior.h (stop_pc): Delete declaration.
7573 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
7574 (handle_inferior_event_1, handle_signal_stop)
7575 (process_event_stop_test, keep_going_stepped_thread)
7576 (handle_step_into_function, handle_step_into_function_backward)
7577 (print_stop_location): Replace references to stop_pc with
7578 references to thread_info->suspend.stop_pc.
7579 (struct infcall_suspend_state) <stop_pc>: Delete field.
7580 (save_infcall_suspend_state, restore_infcall_suspend_state):
7581 Remove references to inf_stat->stop_pc.
7582 * linux-fork.c (fork_load_infrun_state): Likewise.
7583 * record-btrace.c (record_btrace_set_replay): Likewise.
7584 * record-full.c (record_full_goto_entry): Likewise.
7585 * remote.c (print_one_stopped_thread): Likewise.
7586 * target.c (target_resume): Extend comment.
7587 * thread.c (set_executing_thread): New.
7588 (set_executing): Use it.
7589 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
7590 Remove references to stop_pc.
7592 2018-06-28 Pedro Alves <palves@redhat.com>
7594 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
7595 Moving fetching stop_pc until after ecs->event_thread is refreshed.
7597 2018-06-28 Tom Tromey <tom@tromey.com>
7599 * coffread.c (coff_symfile_finish): Update.
7600 * xcoffread.c (xcoff_symfile_finish): Update.
7601 * elfread.c (elf_symfile_finish): Update.
7602 * symfile.h (dwarf2_free_objfile): Don't declare.
7603 * dwarf2read.c (_initialize_dwarf2_read): Use
7604 register_objfile_data_with_cleanup.
7605 (dwarf2_free_objfile): Now static. Change signature.
7607 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
7609 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
7610 option "-o" to add-symbol-file-load to add an offset to each
7611 section's load address.
7612 * symfile.c (set_objfile_default_section_offset): New function.
7614 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
7616 * symfile.c (add_symbol_file_command): Make sure that sections
7617 with the same name are sorted in the same order.
7619 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
7621 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
7622 require the second argument. If omitted, load sections at the
7623 addresses specified in the file.
7625 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
7627 * symfile.c (symbol_file_command, symbol_file_add_main_1)
7628 (_initialize_symfile): Add option "-o" to symbol-file to add an
7629 offset to each section of the symbol file.
7631 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
7633 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
7635 2018-06-27 Tom Tromey <tom@tromey.com>
7637 * stack.c (_initialize_stack): Update "func" help text.
7639 2018-06-27 Tom Tromey <tom@tromey.com>
7641 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
7643 (unwind_infopy_str, pyuw_create_unwind_info)
7644 (unwind_infopy_add_saved_register, pyuw_sniffer)
7645 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
7647 (struct saved_reg): Add constructor.
7648 <value>: Now a gdbpy_ref<>.
7650 2018-06-27 Tom Tromey <tom@tromey.com>
7652 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
7654 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7656 * gdb-gdb.py.in: Format using autopep8.
7658 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7660 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
7661 (type_lookup_function): Recognize CORE_ADDR values.
7663 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7665 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
7668 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7670 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
7673 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7675 * gdb-gdb.py: Move to...
7676 * gdb-gdb.py.in: ... here.
7677 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
7678 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
7680 (distclean): Remove gdb-gdb.py when cleaning.
7681 (gdb-gdb.py, gdb-gdb.gdb): New rules.
7682 * configure: Re-generate.
7684 2018-06-27 Pedro Alves <palves@redhat.com>
7686 * proc-service.c (get_ps_regcache): New.
7687 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
7688 (ps_lsetfpregs): Use it.
7690 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
7693 * dwarf2read.c (lnp_state_machine::check_line_address): Update
7695 (dwarf_decode_lines_1): Adjust.
7697 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7699 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
7701 <info_proc>: Likewise.
7703 2018-06-26 Joel Brobecker <brobecker@adacore.com>
7705 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
7706 to windows_fetch_one_register, and only handle the case of
7707 fetching one register. Move the code that reloads the context
7708 and iterates over all registers if R is negative to...
7709 (windows_nat_target::fetch_registers): ... here.
7710 (do_windows_store_inferior_registers): Rename to
7711 windows_store_one_register, and only handle the case of storing
7712 one register. Move the code that handles the case where r is
7714 (windows_nat_target::store_registers) ... here.
7716 2018-06-26 Tom Tromey <tom@tromey.com>
7719 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
7720 * rust-lang.c (rust_print_struct_def): Add podata parameter.
7722 (rust_internal_print_type): Add podata parameter.
7723 (rust_print_type): Update.
7725 2018-06-26 Tom Tromey <tom@tromey.com>
7727 * typeprint.h (struct print_offset_data) <update, finish,
7728 maybe_print_hole>: New methods.
7729 <indentation>: New constant.
7730 * typeprint.c (print_offset_data::indentation): Define.
7731 (print_offset_data::maybe_print_hole, print_offset_data::update)
7732 (print_offset_data::finish): Move from c-typeprint.c and rename.
7733 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
7734 (print_spaces_filtered_with_print_options): Update.
7735 (c_print_type_union_field_offset, maybe_print_hole)
7736 (c_print_type_struct_field_offset): Move to typeprint.c and
7738 (c_type_print_base_struct_union): Update.
7740 2018-06-25 Pedro Alves <palves@redhat.com>
7742 * gdbthread.h (thread_info_ref, delete_thread)
7743 (delete_thread_silent, first_thread_of_inferior)
7744 (any_thread_of_inferior, switch_to_thread)
7745 (enable_thread_stack_temporaries)
7746 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
7747 (get_last_thread_stack_temporary)
7748 (value_in_thread_stack_temporaries, can_access_registers_thread):
7749 Spell out "struct thread_info" instead of just "thread_info".
7750 * inferior.h (notice_new_inferior): Likewise.
7752 2018-06-25 Pedro Alves <palves@redhat.com>
7754 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
7755 pass thread_info pointer to delete_thread.
7756 (windows_nat_target::detach): Pass inferior pointer to
7758 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
7760 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
7761 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
7762 and pass a thread_info pointer to delete_thread.
7763 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
7764 pass thread_info pointer to delete_thread.
7765 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
7766 delete_thread_silent call.
7767 * procfs.c (procfs_target::detach): Pass inferior pointer to
7769 (procfs_target::wait): Pass thread_info pointer to delete_thread.
7770 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
7771 delete_thread_silent call.
7772 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
7773 pass thread_info pointer to delete_thread.
7774 (windows_nat_target::detach): Pass inferior pointer to
7777 2018-06-22 Alan Hayward <alan.hayward@arm.com>
7779 * regcache.c (readable_regcache::read_part): Fix asserts.
7780 (reg_buffer::raw_collect_part): New function.
7781 (regcache::write_part): Fix asserts.
7782 (reg_buffer::raw_supply_part): New function.
7783 (regcache::transfer_regset_register): New helper function.
7784 (regcache::transfer_regset): Call new functions.
7785 (regcache_supply_regset): Use gdb_byte*.
7786 (regcache::supply_regset): Likewise.
7787 (regcache_collect_regset): Likewise.
7788 (regcache::collect_regset): Likewise.
7789 * regcache.h (reg_buffer::raw_collect_part): New declaration.
7790 (reg_buffer::raw_supply_part): Likewise.
7791 (regcache::transfer_regset_register): Likewise.
7792 (regcache::transfer_regset): Use gdb_byte*.
7794 2018-06-22 Alan Hayward <alan.hayward@arm.com>
7796 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
7798 2018-06-21 Pedro Alves <palves@redhat.com>
7800 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
7801 instead of a ptid_t. All callers adjusted.
7802 * ada-tasks.c (ada_get_task_number): Likewise. All callers
7804 (print_ada_task_info, display_current_task_id, task_command_1):
7806 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
7808 (breakpoint_kind): Adjust.
7809 (remove_breakpoints_pid): Rename to ...
7810 (remove_breakpoints_inf): ... this. Adjust to take an inferior
7811 pointer. All callers adjusted.
7812 (bpstat_clear_actions): Use inferior_thread.
7813 (get_bpstat_thread): New.
7814 (bpstat_do_actions): Use it.
7815 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
7816 to take a thread_info pointer. All callers adjusted.
7817 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
7818 (breakpoint_re_set_thread): Use inferior_thread.
7819 * breakpoint.h (struct inferior): Forward declare.
7820 (bpstat_stop_status): Update.
7821 (remove_breakpoints_pid): Delete.
7822 (remove_breakpoints_inf): New.
7823 * bsd-uthread.c (bsd_uthread_target::wait)
7824 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
7825 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
7826 (maint_btrace_packet_history_cmd)
7827 (maint_btrace_clear_packet_history_cmd): Adjust.
7828 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
7830 * cli/cli-interp.c: Include "inferior.h".
7831 * common/refcounted-object.h (struct
7832 refcounted_object_ref_policy): New.
7833 * compile/compile-object-load.c: Include gdbthread.h.
7834 (store_regs): Use inferior_thread.
7835 * corelow.c (core_target::close): Use current_inferior.
7836 (core_target_open): Adjust to use first_thread_of_inferior and use
7837 the current inferior.
7838 * ctf.c (ctf_target::close): Adjust to use current_inferior.
7839 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
7840 <thread>: ... this new field. All references adjusted.
7841 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
7842 Take a thread_info pointer instead of a ptid_t.
7843 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
7844 (dummy_frame_discard, register_dummy_frame_dtor): Take a
7845 thread_info pointer instead of a ptid_t.
7846 * elfread.c: Include "inferior.h".
7847 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
7848 Use inferior_thread.
7849 * eval.c (evaluate_subexp): Likewise.
7850 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
7852 * gdb_proc_service.h (struct thread_info): Forward declare.
7853 (struct ps_prochandle) <ptid>: Delete, replaced by ...
7854 <thread>: ... this new field. All references adjusted.
7855 * gdbarch.h, gdbarch.c: Regenerate.
7856 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
7857 'thread' parameter. All implementations and callers adjusted.
7858 * gdbthread.h (thread_info) <set_running>: New method.
7859 (delete_thread, delete_thread_silent): Take a thread_info pointer
7861 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
7862 (first_thread_of_process): Delete, replaced by ...
7863 (first_thread_of_inferior): ... this new function. All callers
7865 (any_live_thread_of_process): Delete, replaced by ...
7866 (any_live_thread_of_inferior): ... this new function. All callers
7868 (switch_to_thread, switch_to_no_thread): Declare.
7869 (is_executing): Delete.
7870 (enable_thread_stack_temporaries): Update comment.
7871 <enable_thread_stack_temporaries>: Take a thread_info pointer
7872 instead of a ptid_t. Incref the thread.
7873 <~enable_thread_stack_temporaries>: Decref the thread.
7876 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
7877 (get_last_thread_stack_temporary)
7878 (value_in_thread_stack_temporaries, can_access_registers_thread):
7879 Take a thread_info pointer instead of a ptid_t. All callers
7881 * infcall.c (get_call_return_value): Use inferior_thread.
7882 (run_inferior_call): Work with thread pointers instead of ptid_t.
7883 (call_function_by_hand_dummy): Work with thread pointers instead
7884 of ptid_t. Use thread_info_ref.
7885 * infcmd.c (proceed_thread_callback): Access thread's state
7887 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
7888 access thread's state directly.
7889 (continue_command): Use inferior_thread.
7890 (info_program_command): Use find_thread_ptid and access thread
7892 (proceed_after_attach_callback): Use thread state directly.
7893 (notice_new_inferior): Take a thread_info pointer instead of a
7894 ptid_t. All callers adjusted.
7895 (exit_inferior): Take an inferior pointer instead of a pid. All
7897 (exit_inferior_silent): New.
7898 (detach_inferior): Delete.
7899 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
7900 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
7901 (detach_inferior_command, kill_inferior_command): Use
7902 find_inferior_id instead of valid_gdb_inferior_id and
7903 gdb_inferior_id_to_pid.
7904 (inferior_command): Use inferior and thread pointers.
7905 * inferior.h (struct thread_info): Forward declare.
7906 (notice_new_inferior): Take a thread_info pointer instead of a
7907 ptid_t. All callers adjusted.
7908 (detach_inferior): Delete declaration.
7909 (exit_inferior, exit_inferior_silent): Take an inferior pointer
7910 instead of a pid. All callers adjusted.
7911 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
7912 (valid_gdb_inferior_id): Delete.
7913 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
7914 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
7915 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
7917 <inf>: ... this new field.
7918 <step_ptid>: Delete, replaced by ...
7919 <step_thread>: ... this new field.
7920 (get_displaced_stepping_state): Take an inferior pointer instead
7921 of a pid. All callers adjusted.
7922 (displaced_step_in_progress_any_inferior): Adjust.
7923 (displaced_step_in_progress_thread): Take a thread pointer instead
7924 of a ptid_t. All callers adjusted.
7925 (displaced_step_in_progress, add_displaced_stepping_state): Take
7926 an inferior pointer instead of a pid. All callers adjusted.
7927 (get_displaced_step_closure_by_addr): Adjust.
7928 (remove_displaced_stepping_state): Take an inferior pointer
7929 instead of a pid. All callers adjusted.
7930 (displaced_step_prepare_throw, displaced_step_prepare)
7931 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
7932 All callers adjusted.
7933 (start_step_over): Adjust.
7934 (infrun_thread_ptid_changed): Remove bit updating ptids in the
7935 displaced step queue.
7936 (do_target_resume): Adjust.
7937 (fetch_inferior_event): Use inferior_thread.
7938 (context_switch, get_inferior_stop_soon): Take an
7939 execution_control_state pointer instead of a ptid_t. All callers
7941 (switch_to_thread_cleanup): Delete.
7942 (stop_all_threads): Use scoped_restore_current_thread.
7943 * inline-frame.c: Include "gdbthread.h".
7944 (inline_state) <inline_state>: Take a thread pointer instead of a
7945 ptid_t. All callers adjusted.
7946 <ptid>: Delete, replaced by ...
7947 <thread>: ... this new field.
7948 (find_inline_frame_state): Take a thread pointer instead of a
7949 ptid_t. All callers adjusted.
7950 (skip_inline_frames, step_into_inline_frame)
7951 (inline_skipped_frames, inline_skipped_symbol): Take a thread
7952 pointer instead of a ptid_t. All callers adjusted.
7953 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
7954 (inline_skipped_frames, inline_skipped_symbol): Likewise.
7955 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
7957 * linux-nat.c (get_detach_signal): Likewise.
7958 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
7959 (thread_db_notice_clone): Adjust.
7960 (thread_db_find_new_threads_silently)
7961 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
7962 a thread pointer instead of a ptid_t. All callers adjusted.
7963 * mi/mi-cmd-var.c: Include "inferior.h".
7964 (mi_cmd_var_update_iter): Update to use thread pointers.
7965 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
7967 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
7969 (mi_output_running): ... this new function.
7970 (mi_on_resume_1): Adjust to use it.
7971 (mi_user_selected_context_changed): Adjust to use inferior_thread.
7972 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
7974 (interrupt_thread_callback): : Adjust to use thread and inferior
7976 * proc-service.c: Include "gdbthread.h".
7977 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
7978 * progspace-and-thread.c: Include "inferior.h".
7979 * progspace.c: Include "inferior.h".
7980 * python/py-exitedevent.c (create_exited_event_object): Adjust to
7981 hold a reference to an inferior_object.
7982 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
7984 * python/py-inferior.c (struct inferior_object): Give the type a
7985 tag name instead of a typedef.
7986 (python_on_normal_stop): No need to check if the current thread is
7988 (inferior_to_inferior_object): Change return type to
7989 inferior_object. All callers adjusted.
7990 (find_thread_object): Delete, bits factored out to ...
7991 (thread_to_thread_object): ... this new function.
7992 * python/py-infthread.c (create_thread_object): Use
7993 inferior_to_inferior_object.
7994 (thpy_is_stopped): Use thread pointer directly.
7995 (gdbpy_selected_thread): Use inferior_thread.
7996 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
7997 field, replaced with ...
7998 <thread>: ... this new field. All users adjusted.
7999 (btpy_insn_or_gap_new): Drop const.
8000 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
8002 * python/py-record.c: Include "gdbthread.h".
8003 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
8004 a ptid_t. All callers adjusted.
8005 (gdbpy_current_recording): Use inferior_thread.
8006 * python/py-record.h (recpy_record_object) <ptid>: Delete
8007 field, replaced with ...
8008 <thread>: ... this new field. All users adjusted.
8009 (recpy_element_object) <ptid>: Delete
8010 field, replaced with ...
8011 <thread>: ... this new field. All users adjusted.
8012 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
8013 a ptid_t. All callers adjusted.
8014 * python/py-threadevent.c: Include "gdbthread.h".
8015 (get_event_thread): Use thread_to_thread_object.
8016 * python/python-internal.h (struct inferior_object): Forward
8018 (find_thread_object, find_inferior_object): Delete declarations.
8019 (thread_to_thread_object, inferior_to_inferior_object): New
8021 * record-btrace.c: Include "inferior.h".
8022 (require_btrace_thread): Use inferior_thread.
8023 (record_btrace_frame_sniffer)
8024 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
8025 (get_thread_current_frame): Use scoped_restore_current_thread and
8027 (get_thread_current_frame): Use thread pointer directly.
8028 (record_btrace_replay_at_breakpoint): Use thread's inferior
8030 * record-full.c: Include "inferior.h".
8031 * regcache.c: Include "gdbthread.h".
8032 (get_thread_arch_regcache): Use the inferior's address space
8034 (get_thread_regcache, registers_changed_thread): New.
8035 * regcache.h (get_thread_regcache(thread_info *thread)): New
8037 (registers_changed_thread): New.
8038 (remote_target) <remote_detach_1>: Swap order of parameters.
8039 (remote_add_thread): <remote_add_thread>: Return the new thread.
8040 (get_remote_thread_info(ptid_t)): New overload.
8041 (remote_target::remote_notice_new_inferior): Use thread pointers
8043 (remote_target::process_initial_stop_replies): Use
8044 thread_info::set_running.
8045 (remote_target::remote_detach_1, remote_target::detach)
8046 (extended_remote_target::detach): Adjust.
8047 * stack.c (frame_show_address): Use inferior_thread.
8048 * target-debug.h (target_debug_print_thread_info_pp): New.
8049 * target-delegates.c: Regenerate.
8050 * target.c (default_thread_address_space): Delete.
8051 (memory_xfer_partial_1): Use current_inferior.
8052 (target_detach): Use current_inferior.
8053 (target_thread_address_space): Delete.
8054 (generic_mourn_inferior): Use current_inferior.
8055 * target.h (struct target_ops) <thread_address_space>: Delete.
8056 (target_thread_address_space): Delete.
8057 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
8059 (delete_thread_1, delete_thread, delete_thread_silent): Take a
8060 thread pointer instead of a ptid_t. Adjust all callers.
8061 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
8062 (first_thread_of_process): Delete, replaced by ...
8063 (first_thread_of_inferior): ... this new function. All callers
8065 (any_thread_of_process): Rename to ...
8066 (any_thread_of_inferior): ... this, and take an inferior pointer.
8067 (any_live_thread_of_process): Rename to ...
8068 (any_live_thread_of_inferior): ... this, and take an inferior
8070 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
8071 (value_in_thread_stack_temporaries)
8072 (get_last_thread_stack_temporary): Take a thread pointer instead
8073 of a ptid_t. Adjust all callers.
8074 (thread_info::set_running): New.
8075 (validate_registers_access): Use inferior_thread.
8076 (can_access_registers_ptid): Rename to ...
8077 (can_access_registers_thread): ... this, and take a thread
8079 (print_thread_info_1): Adjust to compare thread pointers instead
8081 (switch_to_no_thread, switch_to_thread): Make extern.
8082 (scoped_restore_current_thread::~scoped_restore_current_thread):
8083 Use m_thread pointer directly.
8084 (scoped_restore_current_thread::scoped_restore_current_thread):
8085 Use inferior_thread.
8086 (thread_command): Use thread pointer directly.
8087 (thread_num_make_value_helper): Use inferior_thread.
8088 * top.c (execute_command): Use inferior_thread.
8089 * tui/tui-interp.c: Include "inferior.h".
8090 * varobj.c (varobj_create): Use inferior_thread.
8091 (value_of_root_1): Use find_thread_global_id instead of
8092 global_thread_id_to_ptid.
8094 2018-06-21 Alan Hayward <alan.hayward@arm.com>
8096 * regcache.c (readable_regcache::read_part): Avoid memcpy when
8098 (regcache::write_part): Likewise.
8099 (readable_regcache::cooked_read_part): Update comment.
8100 (readable_regcache::cooked_write_part): Likewise.
8101 * regcache.h: (readable_regcache::read_part): Likewise.
8102 (regcache::write_part): Likewise.
8104 2018-06-21 Richard Bunt <richard.bunt@arm.com>
8105 Dirk Schubert <dirk.schubert@arm.com>
8107 * aarch64-linux-nat.c (post_attach): New.
8108 (aarch64_linux_nat_target::post_attach): Override post_attach to
8109 record the number of hardware debug registers.
8111 2018-06-20 Tom Tromey <tom@tromey.com>
8113 * python/py-param.c (add_setshow_generic): Make parameters const.
8114 (parmpy_init): Update.
8116 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
8118 * regcache.h (regcache_cooked_read_ftype): Rename to...
8119 (register_read_ftype): ...this, change type to function_view.
8120 (class reg_buffer) <save>: Remove src parameter.
8121 (readonly_detached_regcache) <readonly_detached_regcache>: Make
8122 parameter non-const in first overload. Remove src parameter in
8124 * regcache.c (do_cooked_read): Remove.
8125 (readonly_detached_regcache::readonly_detached_regcache): Make
8126 parameter non-const, adjust call to other constructor.
8127 (reg_buffer::save): Remove src parameter.
8128 * frame.c (do_frame_register_read): Remove.
8129 (frame_save_as_regcache): Use lambda function.
8130 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
8131 parameter to ppu2spu_data *.
8132 (ppu2spu_sniffer): Use lambda function.
8134 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
8136 * record-full.c (record_full_target::insert_breakpoint): Remove
8137 "struct" keyword, add const.
8139 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
8141 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
8142 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
8143 * configure.ac: Remove AC_PREREQ, add missing quoting.
8144 * gnulib/configure.ac: Modernize usage of
8145 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
8146 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
8147 (AUTOMAKE_VERSION): Bump to 1.15.1.
8148 * configure: Re-generate.
8149 * config.in: Re-generate.
8150 * aclocal.m4: Re-generate.
8151 * gnulib/aclocal.m4: Re-generate.
8152 * gnulib/config.in: Re-generate.
8153 * gnulib/configure: Re-generate.
8154 * gnulib/import/Makefile.in: Re-generate.
8156 2018-06-19 Pedro Alves <palves@redhat.com>
8158 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
8159 (lookup_minimal_symbol_by_pc_section): ... here with
8160 gdb_assert_not_reached added.
8162 2018-06-19 Pedro Alves <palves@redhat.com>
8164 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
8165 parameter with a block parameter. Compare location's block symbol
8166 with the frame's block instead of addresses.
8167 (skip_inline_frames): Pass the current block instead of the
8168 frame's address. Break out as soon as we determine the frame
8169 should not be skipped.
8171 2018-06-18 Tom Tromey <tom@tromey.com>
8173 * solib-aix.c (solib_aix_get_section_offsets): Return
8175 (solib_aix_solib_create_inferior_hook): Update.
8177 2018-06-18 Tom Tromey <tom@tromey.com>
8179 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
8181 2018-06-18 Tom Tromey <tom@tromey.com>
8183 * solib-frv.c (frv_relocate_main_executable): Use
8185 * solib-dsbt.c (dsbt_relocate_main_executable): Use
8188 2018-06-18 Tom Tromey <tom@tromey.com>
8190 * objfiles.h (inhibit_section_map_updates): Update.
8191 (resume_section_map_updates, resume_section_map_updates_cleanup):
8193 * solib-svr4.c (svr4_handle_solib_event): Update.
8194 * objfiles.c (inhibit_section_map_updates): Return
8195 scoped_restore_tmpl<int>.
8196 (resume_section_map_updates, resume_section_map_updates_cleanup):
8199 2018-06-18 Tom Tromey <tom@tromey.com>
8201 * valprint.h (read_string): Update.
8202 * valprint.c (read_string): Change type of "buffer".
8203 (val_print_string): Update.
8204 * python/py-value.c (valpy_string): Update.
8205 * language.h (struct language_defn) <la_get_string>: Change
8207 (default_get_string, c_get_string): Update.
8208 * language.c (default_get_string): Change type of "buffer".
8209 * guile/scm-value.c (gdbscm_value_to_string): Update.
8210 * c-lang.c (c_get_string): Change type of "buffer".
8212 2018-06-18 Tom Tromey <tom@tromey.com>
8214 * ser-mingw.c (struct pipe_state_destroyer): New.
8215 (pipe_state_up): New typedef.
8216 (cleanup_pipe_state): Remove.
8217 (pipe_windows_open): Use pipe_state_up. Don't release argv.
8219 2018-06-18 Tom Tromey <tom@tromey.com>
8221 * rust-lang.h (rust_yyerror): Don't declare.
8222 * rust-lang.c (rust_language_defn): Update.
8223 * rust-exp.y (yyerror): Now static.
8224 * parse.c (parse_exp_in_context_1): Update.
8225 * p-lang.h (p_yyerror): Don't declare.
8226 * p-lang.c (p_language_defn): Update.
8227 * p-exp.y (yyerror): Now static.
8228 * opencl-lang.c (opencl_language_defn): Update.
8229 * objc-lang.c (objc_language_defn): Update.
8230 * m2-lang.h (m2_yyerror): Don't declare.
8231 * m2-lang.c (m2_language_defn): Update.
8232 * m2-exp.y (yyerror): Now static.
8233 * language.h (struct language_defn) <la_error>: Remove.
8234 * language.c (unk_lang_error): Remove.
8235 (unknown_language_defn, auto_language_defn): Remove.
8236 * go-lang.h (go_yyerror): Don't declare.
8237 * go-lang.c (go_language_defn): Update.
8238 * go-exp.y (yyerror): Now static.
8239 * f-lang.h (f_yyerror): Don't declare.
8240 * f-lang.c (f_language_defn): Update.
8241 * f-exp.y (yyerror): Now static.
8242 * d-lang.h (d_yyerror): Don't declare.
8243 * d-lang.c (d_language_defn): Update.
8244 * d-exp.y (yyerror): Now static.
8245 * c-lang.h (c_yyerror): Don't declare.
8246 * c-lang.c (c_language_defn, cplus_language_defn)
8247 (asm_language_defn, minimal_language_defn): Update.
8248 * c-exp.y (yyerror): Now static.
8249 * ada-lang.h (ada_yyerror): Don't declare.
8250 * ada-lang.c (ada_language_defn): Update.
8251 * ada-exp.y (yyerror): Now static.
8253 2018-06-18 Alan Hayward <alan.hayward@arm.com>
8255 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
8256 (store_sveregs_to_thread): Likewise.
8257 (aarch64_linux_fetch_inferior_registers): Check for SVE.
8258 (aarch64_linux_store_inferior_registers): Likewise.
8259 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
8261 (aarch64_sve_regs_copy_to_regcache): Likewise.
8262 (aarch64_sve_regs_copy_from_regcache): Likewise.
8263 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
8265 (aarch64_sve_regs_copy_to_regcache): Likewise.
8266 (aarch64_sve_regs_copy_from_regcache): Likewise.
8267 (sve_context): Structure from Linux headers.
8268 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
8269 (SVE_SIG_ZREG_SIZE): Likewise.
8270 (SVE_SIG_PREG_SIZE): Likewise.
8271 (SVE_SIG_FFR_SIZE): Likewise.
8272 (SVE_SIG_REGS_OFFSET): Likewise.
8273 (SVE_SIG_ZREGS_OFFSET): Likewise.
8274 (SVE_SIG_ZREG_OFFSET): Likewise.
8275 (SVE_SIG_ZREGS_SIZE): Likewise.
8276 (SVE_SIG_PREGS_OFFSET): Likewise.
8277 (SVE_SIG_PREG_OFFSET): Likewise.
8278 (SVE_SIG_PREGS_SIZE): Likewise.
8279 (SVE_SIG_FFR_OFFSET): Likewise.
8280 (SVE_SIG_REGS_SIZE): Likewise.
8281 (SVE_SIG_CONTEXT_SIZE): Likewise.
8282 (SVE_PT_REGS_MASK): Likewise.
8283 (SVE_PT_REGS_FPSIMD): Likewise.
8284 (SVE_PT_REGS_SVE): Likewise.
8285 (SVE_PT_VL_INHERIT): Likewise.
8286 (SVE_PT_VL_ONEXEC): Likewise.
8287 (SVE_PT_REGS_OFFSET): Likewise.
8288 (SVE_PT_FPSIMD_OFFSET): Likewise.
8289 (SVE_PT_FPSIMD_SIZE): Likewise.
8290 (SVE_PT_SVE_ZREG_SIZE): Likewise.
8291 (SVE_PT_SVE_PREG_SIZE): Likewise.
8292 (SVE_PT_SVE_FFR_SIZE): Likewise.
8293 (SVE_PT_SVE_FPSR_SIZE): Likewise.
8294 (SVE_PT_SVE_FPCR_SIZE): Likewise.
8295 (__SVE_SIG_TO_PT): Likewise.
8296 (SVE_PT_SVE_OFFSET): Likewise.
8297 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
8298 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
8299 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
8300 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
8301 (SVE_PT_SVE_PREG_OFFSET): Likewise.
8302 (SVE_PT_SVE_PREGS_SIZE): Likewise.
8303 (SVE_PT_SVE_FFR_OFFSET): Likewise.
8304 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
8305 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
8306 (SVE_PT_SVE_SIZE): Likewise.
8307 (SVE_PT_SIZE): Likewise.
8308 (HAS_SVE_STATE): New define.
8310 2018-06-18 Alan Hayward <alan.hayward@arm.com>
8312 * nat/aarch64-sve-linux-sigcontext.h: New file.
8313 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
8315 (SVE_VQ_MIN): Likewise.
8316 (SVE_VQ_MAX): Likewise.
8317 (SVE_VL_MIN): Likewise.
8318 (SVE_VL_MAX): Likewise.
8319 (SVE_NUM_ZREGS): Likewise.
8320 (SVE_NUM_PREGS): Likewise.
8321 (sve_vl_valid): Likewise.
8322 (struct user_sve_header): Likewise.
8324 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
8325 Richard Bunt <Richard.Bunt@arm.com>
8327 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
8328 was requested by GDB.
8330 2018-06-15 Tom de Vries <tdevries@suse.de>
8332 * MAINTAINERS (Write After Approval): Add Tom de Vries.
8334 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
8336 * gnulib/update-gnulib.sh: Print expected versions of
8339 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
8341 * arch-utils.c (default_type_align): Use type_length_units.
8342 * gdbtypes.c (type_align): Use type_length_units.
8344 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8346 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
8347 of 'define' command.
8349 2018-06-14 Tom de Vries <tdevries@suse.de>
8352 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
8353 get_no_prettyformat_print_options.
8355 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
8357 * sparc-nat.h: Include target.h.
8358 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
8359 <fetch_registers>: Remove this argument in function call.
8360 <store_registers>: Remove this argument in function call, remove
8362 <low_forget_process>: Call sparc64_forget_process instead of
8363 sparc_forget_process.
8365 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
8367 * procfs.c (_initialize_procfs): Use add_inf_child_target.
8368 (procfs_target::make_corefile_notes): Adjust to new
8369 target_read_alloc return type.
8371 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
8372 Stephen Roberts <stephen.roberts@arm.com>
8375 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
8376 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
8377 Move should_notify_stop local into more inner scope.
8379 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
8380 Stephen Roberts <stephen.roberts@arm.com>
8383 * infrun.c (resume_1): Add call to mark_async_event_handler.
8385 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
8387 * infrun.c (do_target_wait): Change old version of $pc printed.
8389 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
8391 * dwarf2read.c (read_index_from_section): Rename to...
8392 (read_gdb_index_from_section): ... this, update all callers.
8393 (dwarf2_read_index): Rename to...
8394 (dwarf2_read_gdb_index): ... this, update all callers.
8396 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
8399 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
8400 hppa_linux_nat_target::fetch_registers.
8402 2018-06-11 Alan Hayward <alan.hayward@arm.com>
8404 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
8405 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
8406 (AARCH64_DWARF_SVE_FFR): Likewise.
8407 (AARCH64_DWARF_SVE_P0): Likewise.
8408 (AARCH64_DWARF_SVE_Z0): Likewise.
8410 2018-06-11 Alan Hayward <alan.hayward@arm.com>
8412 * common/common-regcache.h (raw_compare): New function.
8413 * regcache.c (regcache::raw_compare): Likewise.
8414 * regcache.h (regcache::raw_compare): New declaration.
8416 2018-06-11 Alan Hayward <alan.hayward@arm.com>
8418 * common/common-regcache.h (reg_buffer_common): New structure.
8419 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
8420 (reg_buffer::raw_supply): Likewise.
8421 (reg_buffer::raw_supply_integer): Likewise.
8422 (reg_buffer::raw_supply_zeroed): Likewise.
8423 (reg_buffer::raw_collect): Likewise.
8424 (reg_buffer::raw_collect_integer): Likewise.
8425 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
8426 (reg_buffer::raw_supply): Likewise.
8427 (reg_buffer::raw_supply_integer): Likewise.
8428 (reg_buffer::raw_supply_zeroed): Likewise.
8429 (reg_buffer::raw_collect): Likewise.
8430 (reg_buffer::raw_collect_integer): Likewise.
8432 2018-06-10 Tom Tromey <tom@tromey.com>
8434 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
8435 (class remote_state) <stop_reply_queue>: Now std::vector.
8436 (remote_state::~remote_state)
8437 (remote_target::stop_reply_queue_length): Update.
8438 (struct queue_iter_param, remove_child_of_pending_fork)
8439 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
8440 (check_pending_event_prevents_wildcard_vcont_callback)
8441 (remove_stop_reply_for_inferior)
8442 (remove_stop_reply_of_remote_state)
8443 (remote_notif_remove_once_on_match)
8444 (stop_reply_match_ptid_and_ws)
8445 (remote_kill_child_of_pending_fork): Remove.
8446 (remote_target::remove_new_fork_children)
8447 (remote_target::check_pending_events_prevent_wildcard_vcont)
8448 (remote_target::discard_pending_stop_replies)
8449 (remote_target::discard_pending_stop_replies_in_queue)
8450 (remote_target::remote_notif_remove_queued_reply)
8451 (remote_target::queued_stop_reply)
8452 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
8453 (remote_target::wait, remote_target::kill_new_fork_children)
8454 (remote_target::async): Update.
8456 2018-06-10 Tom Tromey <tom@tromey.com>
8458 * record-full.c (record_full_arch_list_cleanups): Remove.
8459 (record_full_message): Use try/catch.
8460 (record_full_wait_cleanups): Remove.
8461 (record_full_wait_1): Use try/catch.
8462 (record_full_restore): Likewise.
8464 2018-06-10 Tom Tromey <tom@tromey.com>
8466 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
8467 declare VEC. Add constructor.
8468 <in_target_beneath>: Now bool.
8469 (record_full_breakpoints): Now a std::vector, static.
8470 (record_full_sync_record_breakpoints)
8471 (record_full_init_record_breakpoints)
8472 (record_full_target::insert_breakpoint)
8473 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
8475 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
8477 * dwarf2read.c (process_cu_includes): Remove struct keyword.
8478 * serial.c (serial_interface_lookup): Remove struct keyword.
8480 2018-06-10 Tom Tromey <tom@tromey.com>
8482 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
8484 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
8486 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
8488 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
8489 "beneath" as a method.
8490 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
8491 Use "beneath" as a method.
8493 2018-06-10 Tom Tromey <tom@tromey.com>
8495 * tracefile.c (struct trace_file_writer_deleter): New.
8496 <operator()>: Rename from trace_file_writer_xfree.
8497 (trace_file_writer_up): New typedef.
8498 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
8500 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
8502 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
8503 <m_registers, m_register_status>: Change type to
8505 * regcache.c (reg_buffer::reg_buffer): Use new instead of
8508 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
8510 * common/common-regcache.h (enum register_status): Add
8511 underlying type "signed char".
8512 * regcache.h (reg_buffer) <m_register_status>: Change type to
8514 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
8515 register_status instead of signed char.
8516 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
8517 (reg_buffer::get_register_status): Remove cast.
8518 (readable_regcache::raw_read): Remove cast.
8519 (readable_regcache::cooked_read): Remove cast.
8521 2018-06-09 Tom Tromey <tom@tromey.com>
8523 * source.c (reverse_search_command, forward_search_command): Use
8526 2018-06-09 Tom Tromey <tom@tromey.com>
8528 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
8529 (serial_ops_list): Now static, std::vector.
8530 (serial_interface_lookup, serial_add_interface): Update.
8532 2018-06-09 Tom Tromey <tom@tromey.com>
8534 * dwarf2read.c (process_cu_includes): Update.
8535 (process_full_comp_unit): Update.
8536 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
8539 2018-06-08 Paul Koning <paul_koning@dell.com>
8543 * python/python.c (do_start_initialization):
8544 Avoid call to internal Python API.
8545 (init__gdb_module): New function.
8547 2018-06-08 Gary Benson <gbenson@redhat.com>
8549 * linux-thread-db.c (valprint.h): New include.
8550 (struct check_thread_db_info): New structure.
8551 (check_thread_db_on_load, tdb_testinfo): New static globals.
8552 (check_thread_db, check_thread_db_callback): New functions.
8553 (try_thread_db_load_1): Run integrity checks if requested.
8554 (maintenance_check_libthread_db): New function.
8555 (_initialize_thread_db): Register "maint check libthread-db"
8556 and "maint set/show check-libthread-db".
8557 * NEWS: Mention the above new commands.
8559 2018-06-08 Tom Tromey <tom@tromey.com>
8561 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
8564 2018-06-08 Tom Tromey <tom@tromey.com>
8566 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
8568 2018-06-08 Tom Tromey <tom@tromey.com>
8570 * common/btrace-common.h (struct btrace_data): Add constructor,
8571 destructor, move assignment operator.
8572 <empty, clear, fini>: New methods.
8573 <format>: Initialize.
8574 (btrace_data_init, btrace_data_fini, btrace_data_clear)
8575 (btrace_data_empty): Don't declare.
8576 * common/btrace-common.c (btrace_data_init): Remove.
8577 (btrace_data::fini): Rename from btrace_data_fini.
8578 (btrace_data::empty): Rename from btrace_data_empty.
8579 (btrace_data::clear): Rename from btrace_data_clear. Return
8581 * btrace.h (make_cleanup_btrace_data): Don't declare.
8582 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
8583 (parse_xml_btrace): Update.
8584 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
8585 (maint_btrace_clear_packet_history_cmd): Update.
8587 2018-06-07 Pedro Alves <palves@redhat.com>
8589 * target.h (target_ops) <beneath>: Now a method. All references
8591 (class target_stack): New.
8592 * target.c (g_target_stack): New.
8593 (g_current_top_target): Delete.
8594 (current_top_target): Get the top target out of g_target_stack.
8595 (target_stack::push, target_stack::unpush): New.
8596 (push_target, unpush_target): Reimplement.
8597 (target_is_pushed): Reimplement in terms of g_target_stack.
8598 (target_ops::beneath, target_stack::find_beneath): New.
8600 2018-06-07 Pedro Alves <palves@redhat.com>
8602 * target.h (find_target_beneath): Delete declaration.
8603 * target.c (find_target_beneath): Delete definition.
8604 * aix-thread.c: All callers of find_target_beneath adjusted to
8605 call target_ops::beneath instead.
8606 * bsd-uthread.c: Likewise.
8607 * linux-thread-db.c: Likewise.
8608 * ravenscar-thread.c: Likewise.
8609 * sol-thread.c: Likewise.
8610 * spu-multiarch.c: Likewise.
8612 2018-06-07 Pedro Alves <palves@redhat.com>
8614 * target.h (target_ops) <beneath>: Now a method. All references
8616 (target_ops) <m_beneath>: New.
8617 * target.c (target_ops::beneath): New.
8618 * corelow.c: Adjust all references to target_ops::beneath.
8619 * linux-thread-db.c: Likewise.
8620 * make-target-delegates: Likewise.
8621 * record-btrace.c: Likewise.
8622 * record-full.c: Likewise.
8623 * remote.c: Likewise.
8624 * target.c: Likewise.
8625 * target-delegates.c: Regenerate.
8627 2018-06-07 Pedro Alves <palves@redhat.com>
8629 * target.h (target_stack): Delete.
8630 (current_top_target): Declare function.
8631 * target.c (target_stack): Delete.
8632 (g_current_top_target): New.
8633 (current_top_target): New function.
8634 * auxv.c: Use current_top_target instead of target_stack
8636 * avr-tdep.c: Likewise.
8637 * breakpoint.c: Likewise.
8638 * corefile.c: Likewise.
8639 * elfread.c: Likewise.
8641 * exceptions.c: Likewise.
8642 * frame.c: Likewise.
8643 * gdbarch-selftests.c: Likewise.
8644 * gnu-v3-abi.c: Likewise.
8645 * ia64-tdep.c: Likewise.
8646 * ia64-vms-tdep.c: Likewise.
8647 * infcall.c: Likewise.
8648 * infcmd.c: Likewise.
8649 * infrun.c: Likewise.
8650 * linespec.c: Likewise.
8651 * linux-tdep.c: Likewise.
8652 * minsyms.c: Likewise.
8653 * ppc-linux-nat.c: Likewise.
8654 * ppc-linux-tdep.c: Likewise.
8655 * procfs.c: Likewise.
8656 * regcache.c: Likewise.
8657 * remote.c: Likewise.
8658 * rs6000-tdep.c: Likewise.
8659 * s390-linux-nat.c: Likewise.
8660 * s390-tdep.c: Likewise.
8661 * solib-aix.c: Likewise.
8662 * solib-darwin.c: Likewise.
8663 * solib-dsbt.c: Likewise.
8664 * solib-spu.c: Likewise.
8665 * solib-svr4.c: Likewise.
8666 * solib-target.c: Likewise.
8667 * sparc-tdep.c: Likewise.
8668 * sparc64-tdep.c: Likewise.
8669 * spu-tdep.c: Likewise.
8670 * symfile.c: Likewise.
8671 * symtab.c: Likewise.
8672 * target-descriptions.c: Likewise.
8673 * target-memory.c: Likewise.
8674 * target.c: Likewise.
8675 * target.h: Likewise.
8676 * tracefile-tfile.c: Likewise.
8677 * tracepoint.c: Likewise.
8678 * valops.c: Likewise.
8679 * valprint.c: Likewise.
8680 * value.c: Likewise.
8681 * windows-tdep.c: Likewise.
8682 * mi/mi-main.c: Likewise.
8684 2018-06-07 Tom Tromey <tom@tromey.com>
8686 * valprint.h (build_address_symbolic): Declare.
8687 * printcmd.c (print_address_symbolic): Update.
8688 (build_address_symbolic): Change "name" and "filename" to
8690 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
8692 * defs.h (build_address_symbolic): Remove declaration.
8694 2018-06-07 Alan Hayward <alan.hayward@arm.com>
8696 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
8697 (aarch64_vnv_type): Add function.
8698 (aarch64_pseudo_register_name): Add V regs for SVE.
8699 (aarch64_pseudo_register_type): Likewise.
8700 (aarch64_pseudo_register_reggroup_p): Likewise.
8701 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
8702 (aarch64_pseudo_read_value): Add V regs for SVE.
8703 (aarch64_pseudo_write_2): Use V0 offset for SVE
8704 (aarch64_pseudo_write): Add V regs for SVE.
8705 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
8707 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
8709 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
8710 (sve_vl_from_vq): Likewise.
8712 2018-06-05 Tom Tromey <tom@tromey.com>
8714 * cli/cli-cmds.c (show_version): Update.
8715 * top.c (print_gdb_version): Add "interactive" parameter.
8717 * main.c (captured_main_1): Update.
8718 * top.h (print_gdb_version): Add "interactive" parameter and a
8721 2018-06-05 David Malcolm <dmalcolm@redhat.com>
8723 * common/enum-flags.h: Add trailing semicolon to example in
8726 2018-06-05 Tom Tromey <tom@tromey.com>
8729 * NEWS: Add entry about pager.
8730 * utils.c (pagination_disabled_for_command): New global.
8731 (prompt_for_continue): Allow "c" response to prompt.
8732 (reinitialize_more_filter): Clear
8733 pagination_disabled_for_command.
8734 (fputs_maybe_filtered): Check pagination_disabled_for_command.
8736 2018-06-04 Tom Tromey <tom@tromey.com>
8738 * ada-lang.h (ada_lookup_symbol_list): Update.
8739 * ada-lang.c (resolve_subexp): Update.
8740 (symbols_are_identical_enums): Change type of syms. Remove nsyms
8742 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
8743 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
8744 results parameter to std::vector.
8745 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
8747 * ada-exp.y (block_lookup): Update.
8748 (select_possible_type_sym): Change type of syms. Remove nsyms
8750 (write_var_or_type, write_name_assoc): Update.
8752 2018-06-04 Joel Brobecker <brobecker@adacore.com>
8754 * windows-nat.c (windows_nat_target::xfer_partial): Return
8755 TARGET_XFER_E_IO if we need to delegate to the target beneath
8756 but BENEATH is NULL.
8758 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
8760 * Makefile.in (config.status): Add configure.nat as a
8763 2018-06-04 Tom Tromey <tom@tromey.com>
8765 * cp-name-parser.y (cpname_state): Add method declarations.
8766 (HANDLE_QUAL): Update.
8767 (cpname_state::d_grab, cpname_state::fill_comp)
8768 (cpname_state::make_operator, cpname_state::make_dtor)
8769 (cpname_state::make_builtin_type, cpname_state::make_name)
8770 (cpname_state::d_qualify, cpname_state::d_int_type)
8771 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
8772 (%union): Move earlier.
8774 2018-06-04 Alan Hayward <alan.hayward@arm.com>
8776 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
8778 2018-06-04 Alan Hayward <alan.hayward@arm.com>
8780 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
8781 (aarch64_pseudo_write_1): Likewise.
8782 (aarch64_pseudo_read_value): Use helper.
8783 (aarch64_pseudo_write): Likewise.
8785 2018-06-04 Pedro Alves <palves@redhat.com>
8787 * darwin-nat.c (darwin_ops): Delete.
8788 (darwin_attach_pid): Use get_native_target.
8790 2018-06-04 Alan Hayward <alan.hayward@arm.com>
8792 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
8793 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
8795 2018-06-04 Alan Hayward <alan.hayward@arm.com>
8797 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
8798 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
8799 (aarch64_gdbarch_init): Check for SVE.
8800 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
8802 2018-06-04 Alan Hayward <alan.hayward@arm.com>
8804 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
8805 * aarch64-tdep.h (aarch64_read_description): Likewise.
8806 * arch/aarch64.c (aarch64_create_target_description): Likewise.
8807 * arch/aarch64.h (aarch64_create_target_description): Likewise.
8808 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
8809 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
8810 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
8812 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
8814 * value.c (value_fetch_lazy_bitfield): New.
8815 (value_fetch_lazy_memory): New.
8816 (value_fetch_lazy_register): New.
8817 (value_fetch_lazy): Factor out to smaller functions.
8819 2018-06-01 Tom Tromey <tom@tromey.com>
8821 * cp-name-parser.y (backslashable, represented): Now const.
8823 2018-06-01 Tom Tromey <tom@tromey.com>
8825 * cp-name-parser.y: Include parser-defs.h.
8826 (parser_fprintf): Remove declaration.
8828 2018-06-01 Tom Tromey <tom@tromey.com>
8830 * cp-name-parser.y: Use %pure-parser, %lex-param, and
8832 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
8833 (global_result): Remove globals.
8834 (struct cpname_state): New.
8835 (yyparse): Don't declare.
8836 (yylex, yyerror): Move declarations after %union.
8837 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
8838 (make_name): Add state parameter.
8840 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
8842 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
8844 (yylex): Add lvalp, state parameters.
8845 (yyerror): Add state parameter.
8846 (cp_demangled_name_to_comp): Update.
8848 2018-06-01 Tom Tromey <tom@tromey.com>
8850 * cp-name-parser.y (parser_fprintf): Declare.
8851 (GDB_YY_REMAP_PREFIX): Define.
8852 Include yy-remap.h. Don't redefine yy* identifiers.
8854 2018-06-01 Tom Tromey <tom@tromey.com>
8856 * python/py-type.c (typy_legacy_template_argument): Update.
8857 * cp-support.h (cp_demangled_name_to_comp): Update.
8858 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
8859 parameter to be a "std::string *".
8862 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
8864 * ada-lex.l: Include "diagnostics.h" instead of
8865 "common/diagnostics.h".
8866 * unittests/environ-selftests.c: Likewise.
8867 * common/diagnostics.h: Moved to ../include.
8869 2018-06-01 Joel Brobecker <brobecker@adacore.com>
8871 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
8872 to language_mode_manual while calling breakpoint_re_set_one.
8874 2018-06-01 Tom Tromey <tom@tromey.com>
8876 * valops.c (value_cast_structs, destructor_name_p): Update.
8877 * symtab.c (gdb_mangle_name): Update.
8878 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
8880 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
8881 (pascal_object_print_value_fields, pascal_object_print_value):
8883 * p-typeprint.c (pascal_type_print_derivation_info): Update.
8884 * linespec.c (find_methods): Update.
8885 * gdbtypes.h (type_name_no_tag): Remove.
8886 (type_name_or_error): Rename from type_name_no_tag_or_error.
8887 * gdbtypes.c (type_name_no_tag): Remove.
8888 (type_name_or_error): Rename from type_name_no_tag_or_error.
8889 (lookup_struct_elt_type, check_typedef): Update.
8890 * expprint.c (print_subexp_standard): Update.
8891 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
8892 * d-namespace.c (d_lookup_nested_symbol): Update.
8893 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
8894 (cp_print_class_member): Update.
8895 * cp-namespace.c (cp_lookup_nested_symbol): Update.
8896 * completer.c (add_struct_fields): Update.
8897 * c-typeprint.c (cp_type_print_derivation_info)
8898 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
8900 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
8901 (ada_prefer_type, ada_is_exception_sym): Update.
8903 2018-06-01 Tom Tromey <tom@tromey.com>
8905 * valops.c (enum_constant_from_type, value_namespace_elt)
8906 (value_maybe_namespace_elt): Update.
8907 * valarith.c (find_size_for_pointer_math): Update.
8908 * target-descriptions.c (make_gdb_type): Update.
8909 * symmisc.c (print_symbol): Update.
8910 * stabsread.c (define_symbol, read_type)
8911 (complain_about_struct_wipeout, add_undefined_type)
8912 (cleanup_undefined_types_1): Update.
8913 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
8914 (rust_range_type_p, val_print_struct, rust_print_struct_def)
8915 (rust_internal_print_type, rust_composite_type)
8916 (rust_evaluate_funcall, rust_evaluate_subexp)
8917 (rust_inclusive_range_type_p): Update.
8918 * python/py-type.c (typy_get_tag): Update.
8919 * p-typeprint.c (pascal_type_print_base): Update.
8920 * mdebugread.c (parse_symbol, parse_type): Update.
8921 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
8923 * guile/scm-type.c (gdbscm_type_tag): Update.
8924 * go-lang.c (sixg_string_p): Update.
8925 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
8927 * gdbtypes.h (struct main_type) <tag_name>: Remove.
8928 (TYPE_TAG_NAME): Remove.
8929 * gdbtypes.c (type_name_no_tag): Simplify.
8930 (check_typedef, check_types_equal, recursive_dump_type)
8931 (copy_type_recursive, arch_composite_type): Update.
8932 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
8933 in summary mode when needed.
8934 * eval.c (evaluate_funcall): Update.
8935 * dwarf2read.c (fixup_go_packaging, read_structure_type)
8936 (process_structure_scope, read_enumeration_type)
8937 (read_namespace_type, read_module_type, determine_prefix): Update.
8938 * cp-support.c (inspect_type): Update.
8939 * coffread.c (process_coff_symbol, decode_base_type): Update.
8940 * c-varobj.c (c_is_path_expr_parent): Update.
8941 * c-typeprint.c (c_type_print_base_struct_union): Update.
8942 (c_type_print_base_1): Update. Print struct/class/union/enum in
8943 summary when using C language.
8944 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
8945 (gen_maybe_namespace_elt): Update.
8946 * ada-lang.c (ada_type_name): Simplify.
8947 (empty_record, ada_template_to_fixed_record_type_1)
8948 (template_to_static_fixed_type)
8949 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
8951 2018-06-01 Tom Tromey <tom@tromey.com>
8953 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
8955 * c-typeprint.c (c_print_type_1): Add "language" parameter.
8956 (c_print_type): Update.
8957 (c_print_type): New overload.
8958 (c_type_print_varspec_prefix, c_type_print_args)
8959 (c_type_print_varspec_suffix, c_print_type_no_offsets)
8960 (c_type_print_base_struct_union, c_type_print_base_1)
8961 (cp_type_print_method_args): Add "language" parameter.
8962 (c_type_print_base): Update.
8963 * c-lang.h (c_print_type): Add new overload.
8965 2018-06-01 Tom Tromey <tom@tromey.com>
8967 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
8968 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
8970 2018-06-01 Alan Hayward <alan.hayward@arm.com>
8972 * aarch64-tdep.c (aarch64_sve_register_names): New const
8974 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
8975 (AARCH64_SVE_Z_REGS_NUM): New define.
8976 (AARCH64_SVE_P_REGS_NUM): Likewise.
8977 (AARCH64_SVE_NUM_REGS): Likewise.
8979 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
8981 * nat/linux-ptrace.h [__alpha__]
8982 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
8985 2018-05-31 Maciej W. Rozycki <macro@mips.com>
8987 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
8988 the endianness selected.
8989 * NEWS: Document `set endian auto' mode operation update.
8991 2018-05-31 Alan Hayward <alan.hayward@arm.com>
8993 * Makefile.in: Add new header.
8994 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
8995 (sve_vl_from_vg): Likewise.
8996 (sve_vq_from_vl): Likewise.
8997 (sve_vl_from_vq): Likewise.
8998 (sve_vq_from_vg): Likewise.
8999 (sve_vg_from_vq): Likewise.
9000 * configure.nat: Add new c file.
9001 * nat/aarch64-sve-linux-ptrace.c: New file.
9002 * nat/aarch64-sve-linux-ptrace.h: New file.
9004 2018-05-31 Alan Hayward <alan.hayward@arm.com>
9006 * aarch64-linux-nat.c (aarch64_linux_read_description):
9008 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
9010 * aarch64-tdep.c (tdesc_aarch64_list): Add.
9011 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
9012 (aarch64_gdbarch_init): Add parmeter zero.
9013 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
9014 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
9015 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
9017 * doc/gdb.texinfo: Describe SVE feature
9018 * features/aarch64-sve.c: New file.
9020 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
9023 * gdbarch.sh (significant_addr_bit): Default to zero when
9024 not set by target architecture.
9025 * gdbarch.c: Re-generated.
9026 * utils.c (address_significant): Update.
9028 2018-05-30 Joel Brobecker <brobecker@adacore.com>
9030 * stack.c (func_command): Remove trailing newline in call to error.
9032 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9034 * regcache.h (regcache_raw_collect): Remove, update callers to
9035 use regcache::raw_collect.
9036 * regcache.c (regcache_raw_collect): Remove.
9038 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9040 * regcache.h (regcache_raw_supply): Remove, update callers to
9041 use detached_regcache::raw_supply.
9042 * regcache.c (regcache_raw_supply): Remove.
9044 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9046 * regcache.h (regcache_cooked_write_part): Remove, update
9047 callers to use regcache::cooked_write_part.
9048 * regcache.c (regcache_cooked_write_part): Remove.
9050 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9052 * regcache.h (regcache_cooked_read_part): Remove, update callers
9053 to use readable_regcache::cooked_read_part.
9054 * regcache.c (regcache_cooked_read_part): Remove.
9056 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9058 * regcache.h (regcache_cooked_read_value): Remove, update
9059 callers to use readable_regcache::cooked_read_value.
9060 * regcache.c (regcache_cooked_read_value): Remove.
9062 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9064 * regcache.h (regcache_cooked_write): Remove, update callers to
9065 use regcache::cooked_write.
9066 * regcache.c (regcache_cooked_write): Remove.
9068 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9070 * regcache.h (regcache_invalidate): Remove, update callers to
9071 use detached_regcache::invalidate instead.
9072 * regcache.c (regcache_invalidate): Remove.
9074 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9076 * regcache.h (regcache_raw_write_part): Remove, update callers
9077 to use regcache::raw_write_part instead.
9078 * regcache.c (regcache_raw_write_part): Remove.
9080 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9082 * regcache.h (regcache_raw_read_part): Remove, update callers to
9083 use readable_regcache::raw_read_part instead.
9084 * regcache.c (regcache_raw_read_part): Remove.
9086 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9088 * regcache.h (regcache_cooked_read): Remove, update callers to
9089 use readable_regcache::cooked_read instead.
9090 * regcache.c (regcache_cooked_read): Remove.
9092 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9094 * regcache.h (regcache_raw_write): Remove, update callers to use
9095 regcache::raw_write instead.
9096 * regcache.c (regcache_raw_write): Remove.
9098 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9100 * regcache.h (regcache_raw_read): Remove, update callers to use
9101 readable_regcache::raw_read instead.
9102 * regcache.c (regcache_raw_read): Remove.
9104 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9106 * regcache.h (regcache_raw_update): Remove, update callers to
9107 use readable_regcache::raw_update instead.
9108 * regcache.c (regcache_raw_update): Remove.
9110 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9112 * regcache.h (regcache_register_status): Remove, update callers
9113 to use reg_buffer::get_register_status directly instead.
9114 * regcache.c (regcache_register_status): Remove.
9116 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9118 * regcache.h (regcache_get_ptid): Remove, update all callers to
9119 call regcache::ptid instead.
9120 * regcache.c (regcache_get_ptid): Remove.
9122 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
9124 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
9126 2018-05-30 Pedro Alves <palves@redhat.com>
9128 * common/common-exceptions.h (exception_rethrow): Use
9131 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
9133 * breakpoint.c (print_solib_event, check_status_catch_solib):
9134 Remove struct keyword in range-based for loops.
9135 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
9136 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
9138 * linespec.c (find_superclass_methods, search_minsyms_for_name):
9140 * symfile.c (addr_info_make_relative): Likewise.
9141 * thread.c (value_in_thread_stack_temporaries): Likewise.
9143 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
9146 * valops.c (value_struct_elt_for_reference): Call check_typedef on
9147 aggregate type to get its real type before accessing it.
9149 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
9151 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
9152 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
9153 * coff-pe-read.c (add_pe_forwarded_sym): Replace
9154 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
9155 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
9156 * jit.c (jit_breakpoint_re_set_internal): Likewise.
9157 * printcmd.c (info_address_command): Likewise.
9159 2018-05-29 Tom Tromey <tom@tromey.com>
9161 * windows-nat.c (handle_exception): Update fall-through comment.
9163 2018-05-29 Tom Tromey <tom@tromey.com>
9165 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
9166 (struct program_space) <added_solibs>: Now a std::vector.
9167 * breakpoint.c (print_solib_event): Update.
9168 (check_status_catch_solib): Update.
9169 * progspace.c (clear_program_space_solib_cache): Update.
9170 * solib.c (update_solib_list): Update.
9172 2018-05-29 Tom Tromey <tom@tromey.com>
9174 * python/py-type.c (typy_richcompare): Update.
9175 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
9176 * gdbtypes.h (types_deeply_equal): Return bool.
9177 (types_equal): Likewise.
9178 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
9180 (check_types_equal): Change worklist to std::vector. Return
9182 (struct type_equality_entry): Add constructor.
9183 (compare_maybe_null_strings): Return bool.
9184 (check_types_worklist): Return bool. Change worklist to
9186 (types_deeply_equal): Use std::vector.
9187 (types_equal): Return bool.
9188 (compare_maybe_null_strings): Simplify.
9190 2018-05-29 Tom Tromey <tom@tromey.com>
9192 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
9194 2018-05-29 Tom Tromey <tom@tromey.com>
9196 * objc-lang.h: Don't include cp-support.h.
9197 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
9200 2018-05-27 Tom Tromey <tom@tromey.com>
9202 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
9204 2018-05-25 Tom Tromey <tom@tromey.com>
9206 * value.c (value::location): Initialize.
9208 2018-05-25 Tom Tromey <tom@tromey.com>
9210 * dbxread.c (init_bincl_list): Remove.
9211 (bincl_list): Now a std::vector.
9212 (bincls_allocated, next_bincl): Remove.
9213 (free_bincl_list, do_free_bincl_list_cleanup)
9214 (make_cleanup_free_bincl_list): Remove.
9215 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
9217 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
9218 (struct header_file_location): Add constructor.
9219 (add_bincl_to_list): Remove.
9221 2018-05-25 Tom Tromey <tom@tromey.com>
9223 * tui/tui.c (tui_enable): Update.
9224 * mi/mi-interp.c (mi_interp::init): Update.
9225 * interps.h (class interp) <name>: New method.
9226 <m_name>: Rename from name.
9227 (~scoped_restore_interp): Update.
9228 * interps.c (interp::interp): Update.
9229 (interp_add, interp_set, interp_lookup_existing)
9230 (current_interp_named_p): Update.
9232 2018-05-25 Tom Tromey <tom@tromey.com>
9234 * interps.c (interp_name): Remove.
9235 * mi/mi-interp.c (mi_interp::init): Update.
9236 * interps.h (interp_name): Remove.
9237 (~scoped_restore_interp): Update.
9238 * tui/tui.c (tui_enable): Update.
9240 2018-05-25 Tom Tromey <tom@tromey.com>
9242 * utils.c (fputs_maybe_filtered): Update.
9243 * linespec.c (decode_line_full): Update.
9244 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
9245 (mi_print_breakpoint_for_event, mi_solib_loaded)
9246 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
9247 (mi_user_selected_context_changed): Update.
9248 * mi/mi-main.c (mi_execute_command): Update.
9249 * cli/cli-script.c (execute_control_command): Update.
9250 * python/python.c (execute_gdb_command): Update.
9251 * solib.c (info_sharedlibrary_command): Update.
9252 * interps.c (interp_ui_out): Remove.
9253 * interps.h (interp_ui_out): Remove.
9255 2018-05-25 Tom Tromey <tom@tromey.com>
9257 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
9258 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
9259 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
9261 2018-05-25 Tom Tromey <tom@tromey.com>
9263 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
9264 * interps.c (interp_exec): Use scoped_restore.
9266 2018-05-25 Tom Tromey <tom@tromey.com>
9268 * remote.c (remote_target::remote_file_get): Use
9270 (remote_target::remote_file_put): Likewise.
9272 2018-05-25 Tom Tromey <tom@tromey.com>
9274 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
9276 (get_pe_section_index, add_pe_exported_sym): Update.
9277 (read_pe_exported_syms): Use gdb::def_vector.
9279 2018-05-25 Tom Tromey <tom@tromey.com>
9281 * frame.c (remove_prev_frame): Remove.
9282 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
9284 2018-05-25 Maciej W. Rozycki <macro@mips.com>
9286 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
9288 * mips-linux-nat.c (supply_fpregset): Always call
9289 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
9290 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
9291 `mips_fill_fpregset'.
9292 * mips-linux-tdep.c (mips_supply_fpregset)
9293 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
9294 (mips_fill_fpregset_wrapper): Remove functions.
9295 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
9296 (mips_linux_fpregset): Remove variable.
9297 (mips_linux_iterate_over_regset_sections): Use
9298 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
9299 (mips_linux_o32_sigframe_init): Remove comment.
9301 2018-05-25 Pedro Alves <palves@redhat.com>
9303 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
9304 (struct readahead_cache, struct packet_reg, struct
9305 remote_arch_state, class remote_state): Move higher up in the
9307 (remote_target::m_remote_state): Now an object instead of a pointer.
9308 (remote_target::get_remote_state): Adjust.
9310 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
9312 * stack.c (select_and_print_frame): Delete.
9313 (struct function_bounds): Move struct within function.
9314 (func_command): Most content moved into new function
9315 find_frame_for_function, use new function, print result, add
9317 (find_frame_for_function): New function, now returns a result.
9319 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9321 * stack.c (iterate_over_block_arg_vars): Fix comment.
9322 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
9324 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
9328 (scoped_restore_selected_frame::scoped_restore_selected_frame):
9330 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
9332 * frame.h (class scoped_restore_selected_frame): New class.
9333 * stack.c (print_frame_local_vars): Remove catching and rethrowing
9334 of any exception, use scoped_restore_selected_frame to restore the
9337 2018-05-24 Pedro Alves <palves@redhat.com>
9339 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
9342 2018-05-23 Tom Tromey <tom@tromey.com>
9344 * complaints.c (struct complaints): Remove.
9345 (symfile_complaint_book): Remove.
9346 (series): New global.
9347 (complaint_internal): Update.
9348 (clear_complaints): Update.
9350 2018-05-23 Tom Tromey <tom@tromey.com>
9352 * complaints.c (counters): New global.
9353 (struct complain): Remove.
9354 (struct complaints) <root>: Remove.
9355 (complaint_sentinel): Remove.
9356 (symfile_complaint_book): Update.
9357 (find_complaint) Remove.
9358 (complaint_internal, clear_complaints): Update.
9360 2018-05-23 Tom Tromey <tom@tromey.com>
9362 * complaints.c (struct complain) <file, line>: Remove.
9363 (find_complaint): Remove file, line parameters.
9364 (complaint_internal): Update.
9366 2018-05-23 Tom Tromey <tom@tromey.com>
9368 * complaints.c (vcomplaint): Remove.
9369 (complaint_internal) Merge in contents of vcomplaint.
9371 2018-05-23 Tom Tromey <tom@tromey.com>
9373 * complaints.c (struct complaints) <explanation>: Remove.
9374 (symfile_explanations): Remove.
9375 (symfile_complaint_book): Update.
9376 (vcomplaint): Update.
9377 (struct explanation): Remove.
9379 2018-05-23 Tom Tromey <tom@tromey.com>
9381 * complaints.c (symfile_complaints): Remove.
9382 (complaint_internal): Remove "complaints" parameter.
9383 (clear_complaints, vcomplaint): Remove "c" parameter.
9384 (get_complaints): Remove.
9385 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
9386 (dwarf2_debug_line_missing_file_complaint)
9387 (dwarf2_debug_line_missing_end_sequence_complaint)
9388 (dwarf2_complex_location_expr_complaint)
9389 (dwarf2_const_value_length_mismatch_complaint)
9390 (dwarf2_section_buffer_overflow_complaint)
9391 (dwarf2_macro_malformed_definition_complaint)
9392 (dwarf2_invalid_attrib_class_complaint)
9393 (create_addrmap_from_index, dw2_symtab_iter_next)
9394 (dw2_expand_marked_cus)
9395 (dw2_debug_names_iterator::find_vec_in_debug_names)
9396 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
9397 (create_debug_type_hash_table, init_cutu_and_read_dies)
9398 (partial_die_parent_scope, add_partial_enumeration)
9399 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
9400 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
9401 (read_import_statement, read_file_scope, create_dwo_cu_reader)
9402 (create_cus_hash_table, create_dwp_hash_table)
9403 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
9404 (dwarf2_rnglists_process, dwarf2_ranges_process)
9405 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
9406 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
9407 (handle_struct_member_die, process_structure_scope)
9408 (read_array_type, read_common_block, read_module_type)
9409 (read_tag_pointer_type, read_typedef, read_base_type)
9410 (read_subrange_type, load_partial_dies, partial_die_info::read)
9411 (partial_die_info::read, partial_die_info::read)
9412 (partial_die_info::read, read_checked_initial_length_and_offset)
9413 (dwarf2_string_attr, read_formatted_entries)
9414 (dwarf_decode_line_header)
9415 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
9416 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
9417 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
9418 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
9419 (get_signatured_type, get_DW_AT_signature_type)
9420 (decode_locdesc, file_file_name, consume_improper_spaces)
9421 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
9422 (dwarf_decode_macro_bytes, dwarf_decode_macros)
9423 (dwarf2_symbol_mark_computed, set_die_type)
9424 (read_attribute_value): Update.
9425 * stap-probe.c (handle_stap_probe, get_stap_base_address):
9427 * dbxread.c (unknown_symtype_complaint)
9428 (lbrac_mismatch_complaint, repeated_header_complaint)
9429 (set_namestring, function_outside_compilation_unit_complaint)
9430 (read_dbx_symtab, process_one_symbol): Update.
9431 * gdbtypes.c (stub_noname_complaint): Update.
9432 * windows-nat.c (handle_unload_dll): Update.
9433 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
9434 (decode_base_type): Update.
9435 * xcoffread.c (bf_notfound_complaint, ef_complaint)
9436 (eb_complaint, record_include_begin, record_include_end)
9437 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
9438 (process_xcoff_symbol, read_symbol)
9439 (function_outside_compilation_unit_complaint)
9440 (scan_xcoff_symtab): Update.
9441 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
9442 * buildsym.c (finish_block_internal, make_blockvector)
9443 (end_symtab_get_static_block, augment_type_symtab): Update.
9444 * dtrace-probe.c (dtrace_process_dof)
9445 (dtrace_static_probe_ops::get_probes): Update.
9446 * complaints.h (struct complaint): Don't declare.
9447 (symfile_complaints): Remove.
9448 (complaint_internal): Remove "complaints" parameter.
9449 (complaint): Likewise.
9450 (clear_complaints): Likewise.
9451 * symfile.c (syms_from_objfile_1, finish_new_objfile)
9452 (reread_symbols): Update.
9453 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
9454 (dwarf2_frame_cache, decode_frame_entry): Update.
9455 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
9456 * objc-lang.c (lookup_objc_class, lookup_child_selector)
9457 (info_selectors_command): Update.
9458 * macrotab.c (macro_include, check_for_redefinition)
9459 (macro_undef): Update.
9460 * objfiles.c (filter_overlapping_sections): Update.
9461 * stabsread.c (invalid_cpp_abbrev_complaint)
9462 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
9463 (define_symbol, error_type, read_type, rs6000_builtin_type)
9464 (stabs_method_name_from_physname, read_member_functions)
9465 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
9466 (attach_fields_to_type, complain_about_struct_wipeout)
9467 (read_range_type, read_args, common_block_start)
9468 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
9470 * mdebugread.c (index_complaint, unknown_ext_complaint)
9471 (basic_type_complaint, bad_tag_guess_complaint)
9472 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
9473 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
9474 (parse_procedure, parse_lines)
9475 (function_outside_compilation_unit_complaint)
9476 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
9477 (bad_tag_guess_complaint, reg_value_complaint): Update.
9478 * cp-support.c (demangled_name_complaint): Update.
9479 * macroscope.c (sal_macro_scope): Update.
9480 * dwarf-index-write.c (class debug_names): Update.
9482 2018-05-23 Tom Tromey <tom@tromey.com>
9484 * complaints.c (clear_complaints): Remove "noisy" parameter.
9485 * complaints.h (clear_complaints): Update.
9486 * symfile.c (syms_from_objfile_1, finish_new_objfile)
9487 (reread_symbols): Update.
9489 2018-05-23 Tom Tromey <tom@tromey.com>
9491 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
9493 (vcomplaint, clear_complaints): Update.
9494 (symfile_explanations): Remove some messages.
9496 2018-05-23 Tom Tromey <tom@tromey.com>
9498 * complaints.c (internal_complaint): Remove.
9499 * complaints.h (internal_complaint): Remove.
9501 2018-05-22 Maciej W. Rozycki <macro@mips.com>
9503 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
9505 2018-05-22 Pedro Alves <palves@redhat.com>
9507 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
9508 (remote_fileio_badfd, remote_fileio_return_errno)
9509 (remote_fileio_return_success, remote_fileio_func_open)
9510 (remote_fileio_func_open, remote_fileio_func_close)
9511 (remote_fileio_func_read, remote_fileio_func_write)
9512 (remote_fileio_func_lseek, remote_fileio_func_rename)
9513 (remote_fileio_func_unlink, remote_fileio_func_stat)
9514 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
9515 (remote_fileio_func_isatty, remote_fileio_func_system): Add
9516 remote_target parameter.
9517 (remote_fio_func_map) <func>: Add remote_target parameter.
9518 (do_remote_fileio_request, remote_fileio_request):
9519 * remote-fileio.h (remote_fileio_request):
9520 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
9521 remote_target parameter.
9522 (remote_notif_process, handle_notification): Adjust to pass down
9524 (remote_notif_state_allocate): Add remote_target parameter. Save
9526 * remote-notif.h (struct remote_target): Forward declare.
9527 (struct notif_client) <parse, ack, can_get_pending_events>: Add
9528 remote_target parameter.
9529 (struct remote_notif_state) <remote>: New field.
9530 (remote_notif_ack, remote_notif_parse): Add remote_target
9532 (remote_notif_state_allocate, remote_notif_state_allocate): Add
9533 remote_target parameter.
9534 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
9535 (threads_listing_context, rmt_thread_action, protocol_feature)
9536 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
9537 (packet_result, struct threads_listing_context, remote_state):
9538 Move definitions and declarations higher up.
9539 (remote_target) <~remote_target>: Declare.
9540 (remote_download_command_source, remote_file_put, remote_file_get)
9541 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
9542 (remote_hostio_pread_vFile, remote_hostio_send_command)
9543 (remote_hostio_set_filesystem, remote_hostio_open)
9544 (remote_hostio_close, remote_hostio_unlink, remote_state)
9545 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
9546 (get_memory_write_packet_size, get_memory_read_packet_size)
9547 (append_pending_thread_resumptions, remote_detach_1)
9548 (append_resumption, remote_resume_with_vcont)
9549 (add_current_inferior_and_thread, wait_ns, wait_as)
9550 (process_stop_reply, remote_notice_new_inferior)
9551 (process_initial_stop_replies, remote_add_thread)
9552 (btrace_sync_conf, remote_btrace_maybe_reopen)
9553 (remove_new_fork_children, kill_new_fork_children)
9554 (discard_pending_stop_replies, stop_reply_queue_length)
9555 (check_pending_events_prevent_wildcard_vcont)
9556 (discard_pending_stop_replies_in_queue, stop_reply)
9557 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
9558 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
9559 (remote_interrupt_as, remote_interrupt_ns)
9560 (remote_get_noisy_reply, remote_query_attached)
9561 (remote_add_inferior, remote_current_thread, get_current_thread)
9562 (set_thread, set_general_thread, set_continue_thread)
9563 (set_general_process, write_ptid)
9564 (remote_unpack_thread_info_response, remote_get_threadinfo)
9565 (parse_threadlist_response, remote_get_threadlist)
9566 (remote_threadlist_iterator, remote_get_threads_with_ql)
9567 (remote_get_threads_with_qxfer)
9568 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
9569 (get_offsets, remote_check_symbols, remote_supported_packet)
9570 (remote_query_supported, remote_packet_size)
9571 (remote_serial_quit_handler, remote_detach_pid)
9572 (remote_vcont_probe, remote_resume_with_hc)
9573 (send_interrupt_sequence, interrupt_query)
9574 (remote_notif_get_pending_events, fetch_register_using_p)
9575 (send_g_packet, process_g_packet, fetch_registers_using_g)
9576 (store_register_using_P, store_registers_using_G)
9577 (set_remote_traceframe, check_binary_download)
9578 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
9579 (remote_xfer_live_readonly_partial, remote_read_bytes)
9580 (remote_send_printf, remote_flash_write, readchar)
9581 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
9582 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
9583 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
9584 (extended_remote_disable_randomization, extended_remote_run)
9585 (send_environment_packet, extended_remote_environment_support)
9586 (extended_remote_set_inferior_cwd, remote_write_qxfer)
9587 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
9588 (packet_command): Now methods of ...
9589 (remote_target): ... this class.
9590 (m_remote_state) <remote_target>: New field.
9591 (struct remote_state) <stop_reply_queue,
9592 remote_async_inferior_event_token, wait_forever_enabled_p>: New
9594 (remote_state::remote_state): Allocate stop_reply_queue.
9595 (remote_state): Delete global.
9596 (get_remote_state_raw): Delete.
9597 (remote_target::get_remote_state): Allocate m_remote_state on
9599 (get_current_remote_target): New.
9600 (remote_ops, extended_remote_ops): Delete.
9601 (wait_forever_enabled_p, remote_async_inferior_event_token):
9602 Delete, moved to struct remote_state.
9603 (remote_target::close): Delete self. Destruction bits split to
9605 (remote_target::~remote_target): ... this.
9606 (show_memory_packet_size): Adjust to use
9607 get_current_remote_target.
9608 (struct protocol_feature) <func>: Add remote_target parameter.
9609 All callers adjusted.
9610 (curr_quit_handler_target): New.
9611 (remote_serial_quit_handler): Reimplement.
9612 (remote_target::open_1): Adjust to use get_current_remote_target.
9613 Heap-allocate remote_target/extended_remote_target instances.
9614 (vcont_builder::vcont_builder): Add remote_target parameter, and
9615 save it in m_remote. All callers adjusted.
9616 (vcont_builder::m_remote): New field.
9617 (vcont_builder::restart, vcont_builder::flush)
9618 (vcont_builder::push_action): Use it.
9619 (remote_target::commit_resume): Use it.
9620 (struct queue_iter_param) <remote>: New field.
9621 (remote_target::remove_new_fork_children): Fill in 'remote' field.
9622 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
9623 (check_pending_event_prevents_wildcard_vcont_callback)
9624 (remote_target::check_pending_events_prevent_wildcard_vcont)
9625 (remote_target::discard_pending_stop_replies)
9626 (remote_target::discard_pending_stop_replies_in_queue)
9627 (remote_target::remote_notif_remove_queued_reply): Fill in
9629 (remote_notif_get_pending_events): New.
9630 (remote_target::readchar, remote_target::remote_serial_write):
9631 Save/restore curr_quit_handler_target.
9633 (kill_new_fork_children): Fill in 'remote' field.
9634 (packet_command): Use get_current_remote_target, defer to
9635 remote_target method of same name.
9636 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
9637 parameter, and save it in m_remote. All callers adjusted.
9638 (scoped_remote_fd::release): Use m_remote.
9639 (scoped_remote_fd::m_remote): New field.
9640 (remote_file_put, remote_file_get, remote_file_delete): Use
9641 get_current_remote_target, defer to remote_target method of same
9643 (remote_btrace_reset): Add remote_state paremeter. Update all
9645 (remote_async_inferior_event_handler). Pass down 'data'.
9646 (remote_new_objfile): Use get_current_remote_target.
9647 (remote_target::vcont_r_supported): New.
9648 (set_range_stepping): Use get_current_remote_target and
9649 remote_target::vcont_r_supported.
9650 (_initialize_remote): Don't allocate 'remote_state' and
9651 'stop_reply_queue' globals.
9652 * remote.h (struct remote_target): Forward declare.
9653 (getpkt, putpkt, remote_notif_get_pending_events): Add
9654 'remote_target' parameter.
9656 2018-05-22 Pedro Alves <palves@redhat.com>
9658 * remote.c (vcont_builder): Now a class. Make all data members
9660 (vcont_builder) <vcont_builder, restart, flush, push_action>:
9662 (vcont_builder_restart): Rename to ...
9663 (vcont_builder::restart): ... this.
9664 (vcont_builder_flush): Rename to ...
9665 (vcont_builder::flush): ... this.
9666 (vcont_builder_push_action): Rename to ...
9667 (vcont_builder::push_action): ... this.
9668 (remote_target::commit_resume): Adjust.
9670 2018-05-22 Pedro Alves <palves@redhat.com>
9672 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
9673 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
9674 (get_fixed_memory_packet_size): New.
9675 (get_memory_packet_size): Use it.
9676 (set_memory_packet_size): Don't override the config size with
9677 DEFAULT_MAX_MEMORY_PACKET_SIZE.
9678 (show_memory_packet_size): Use get_fixed_memory_packet_size.
9679 Don't refer to get_memory_packet_size if not connected to a remote
9680 target. Show "(default)" if configured size is 0.
9682 2018-05-22 Pedro Alves <palves@redhat.com>
9684 * remote.c (remote_target::mourn_inferior): Move
9685 discard_pending_stop_replies call here from ...
9686 (_initialize_remote): ... here.
9688 2018-05-22 Pedro Alves <palves@redhat.com>
9690 * remote.c (compare_section_command): Remove set_general_process
9693 2018-05-22 Pedro Alves <palves@redhat.com>
9695 * remote.c (struct packet_reg, struct remote_arch_state):
9696 Move higher up in the file.
9697 (remote_state) <m_arch_states>: Store remote_arch_state values
9698 instead of remote_arch_state pointers.
9699 (remote_state::get_remote_arch_state): Adjust.
9701 2018-05-22 Pedro Alves <palves@redhat.com>
9703 * remote.c: Include <unordered_map>.
9704 (remote_state): Now a class.
9705 (remote_state) <get_remote_arch_state>: Declare method.
9706 <get_remote_arch_state>: New field.
9707 (remote_arch_state) <remote_arch_state>: Declare ctor.
9708 <regs>: Now a unique_ptr.
9709 (remote_gdbarch_data_handle): Delete.
9710 (get_remote_arch_state): Delete.
9711 (remote_state::get_remote_arch_state): New.
9712 (get_remote_state): Adjust to call remote_state's
9713 get_remote_arch_state method.
9714 (init_remote_state): Delete, bits factored out to ...
9715 (remote_arch_state::remote_arch_state): ... this new method.
9716 (get_remote_packet_size, get_memory_packet_size)
9717 (process_g_packet, remote_target::fetch_registers)
9718 (remote_target::prepare_to_store, store_registers_using_G)
9719 (remote_target::store_registers, remote_target::get_trace_status):
9720 Adjust to call remote_state's method.
9721 (_initialize_remote): Remove reference to
9722 remote_gdbarch_data_handle.
9724 2018-05-22 Pedro Alves <palves@redhat.com>
9726 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
9727 pread>: New method declarations.
9728 (remote_target::open_1): Adjust.
9729 (readahead_cache_invalidate): Rename to ...
9730 (readahead_cache::invalidate): ... this, and adjust to be a class
9732 (readahead_cache_invalidate_fd): Rename to ...
9733 (readahead_cache::invalidate_fd): ... this, and adjust to be a
9735 (remote_hostio_pwrite): Adjust.
9736 (remote_hostio_pread_from_cache): Rename to ...
9737 (readahead_cache::pread): ... this, and adjust to be a class
9739 (remote_hostio_close): Adjust.
9741 2018-05-22 Pedro Alves <palves@redhat.com>
9743 * remote.c (remote_hostio_close_cleanup): Delete.
9744 (class scoped_remote_fd): New.
9745 (remote_file_put, remote_file_get): Use it.
9747 2018-05-22 Pedro Alves <palves@redhat.com>
9749 (struct vCont_action_support): Use bool and initialize all fields.
9750 (struct readahead_cache): Initialize all fields.
9751 (remote_state): Use bool and initialize all fields.
9752 (remote_state::remote_state, remote_state::~remote_state): New.
9753 (new_remote_state): Delete.
9754 (_initialize_remote): Use new to allocate remote_state.
9756 2018-05-22 Pedro Alves <palves@redhat.com>
9760 * c-exp.y: Include "c-support.h".
9761 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
9762 of tolower. Use c_ident_is_alpha to scan names.
9763 * c-lang.c: Include "c-support.h".
9764 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
9765 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
9766 * c-support.h: New file, with bits factored out from ...
9767 * cp-name-parser.y: ... this file.
9768 Include "c-support.h".
9769 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
9770 c-support.h and renamed.
9771 (symbol_end, yylex): Adjust.
9773 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9775 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
9776 parameter type to CORE_ADDR.
9777 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
9778 parameter type in declaration to CORE_ADDR.
9779 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
9780 target_auxv_search to get AT_HWCAP and use the result to get the
9782 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
9783 to CORE_ADDR. Remove the cast of the return value to unsigned
9784 long. Fix error predicate of target_auxv_search.
9785 (ppc_linux_nat_target::read_description): Change the type of the
9786 hwcap variable to CORE_ADDR.
9788 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9790 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
9791 if the size of fpscr is larger than 32 bits.
9793 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9795 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
9796 (ppc32_linux_vsxregmap): New global.
9797 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
9798 regcache_supply_regset, and regcache_collect_regset.
9799 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
9800 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
9801 (fetch_vsx_register, store_vsx_register): Remove.
9802 (fetch_vsx_registers): Add regno parameter. Get regset using
9803 ppc_linux_vsxregset. Use regset to supply registers.
9804 (store_vsx_registers): Add regno parameter. Get regset using
9805 ppc_linux_vsxregset. Use regset to collect registers.
9806 (fetch_register): Call fetch_vsx_registers instead of
9808 (store_register): Call store_vsx_registers instead of
9810 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
9811 new regno parameter.
9812 (store_ppc_registers): Call store_vsx_registers with -1 for the
9813 new regno parameter.
9814 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
9815 (ppc_collect_vsxregset): Remove.
9817 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9819 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
9821 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
9822 for vector register offset fields.
9823 (ppc64_fbsd_reg_offsets): Likewise.
9824 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
9825 to vector register offset fields.
9826 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
9827 to vector register offset fields.
9828 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
9829 vector register offset fields.
9830 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
9831 initializers for vector register offset fields.
9832 (rs6000_aix64_reg_offsets): Likewise.
9833 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
9834 (ppc_supply_vrregset): Remove.
9835 (ppc_collect_vrregset): Remove.
9836 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
9837 (ppc_linux_vrregset) : New function.
9838 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
9839 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
9840 (ppc32_linux_vrregset): Remove.
9841 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
9842 and use result instead of ppc32_linux_vrregset.
9843 (ppc32_linux_reg_offsets): Remove initializers for vector register
9845 (ppc64_linux_reg_offsets): Likewise.
9846 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
9847 * ppc-linux-nat.c: Include regset.h.
9848 (gdb_vrregset_t): Adjust comment to account for little-endian
9850 (supply_vrregset, fill_vrregset): Remove.
9851 (fetch_altivec_register, store_altivec_register): Remove.
9852 (fetch_altivec_registers): Add regno parameter. Get regset using
9853 ppc_linux_vrregset. Use regset to supply registers.
9854 (store_altivec_registers): Add regno parameter. Get regset using
9855 ppc_linux_vrregset. Use regset to collect registers.
9856 (fetch_register): Call fetch_altivec_registers instead of
9857 fetch_altivec_register.
9858 (store_register): Call store_altivec_registers instead of
9859 store_altivec_register.
9860 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
9861 the new regno parameter.
9862 (store_ppc_registers): Call store_altivec_registers with -1 for
9863 the new regno parameter.
9865 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9867 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
9868 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
9869 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
9870 (gdb_vrregset_t): Change array type size to
9871 PPC_LINUX_SIZEOF_VRREGSET.
9872 (gdb_vsxregset_t): Change array type size to
9873 PPC_LINUX_SIZEOF_VSXREGSET.
9874 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
9875 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
9876 PPC_LINUX_SIZEOF_VSXREGSET.
9878 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9880 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
9881 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
9883 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
9884 ppc_linux_target_wordsize with tid.
9885 (ppc_linux_nat_target::read_description): Call ppc_linux_target
9887 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
9888 (ppc64_64bit_inferior_p): Add static and inline specifiers.
9889 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
9890 tid parameter. Remove static specifier.
9891 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
9892 (ppc_linux_target_wordsize): New declaration.
9894 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9896 * arch/ppc-linux-common.c: New file.
9897 * arch/ppc-linux-common.h: New file.
9898 * arch/ppc-linux-tdesc.h: New file.
9899 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
9900 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
9901 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
9902 arch/ppc-linux-tdesc.h.
9903 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
9904 arch/ppc-linux-tdesc.h.
9905 (ppc_linux_nat_target::read_description): Remove target
9906 description matching code. Fill a ppc_linux_features struct and
9907 call ppc_linux_match_description with it. Move comment about ISA
9908 2.05 to ppc-linux-common.c.
9909 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
9910 arch/ppc-linux-tdesc.h.
9911 (ppc_linux_core_read_description): Remove target description
9912 matching code. Fill a ppc_linux_features struct and call
9913 ppc_linux_match_description with it.
9914 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
9915 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
9916 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
9917 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
9918 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
9919 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
9920 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
9921 (tdesc_powerpc_e500l): Remove.
9923 2018-05-22 Joel Brobecker <brobecker@adacore.com>
9925 * ada-lang.c (catch_assert_command): Pass empty string instead
9926 of NULL for excep_string argument.
9928 2018-05-22 Maciej W. Rozycki <macro@mips.com>
9930 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
9931 the width of the requested register exceeds the width of the
9934 2018-05-21 Tom Tromey <tom@tromey.com>
9936 * printcmd.c (output_command): Remove.
9937 (output_command_const): Rename to output_command.
9938 * valprint.h (output_command): Rename from output_command_const.
9939 * tracepoint.c (trace_dump_actions): Call output_command.
9941 2018-05-21 Tom Tromey <tom@tromey.com>
9943 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
9944 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
9945 * ada-lang.h (create_ada_exception_catchpoint): Update.
9946 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
9948 (create_excep_cond_exprs, ~ada_catchpoint)
9949 (should_stop_exception, print_one_exception)
9950 (print_mention_exception, print_recreate_exception): Update.
9951 (ada_get_next_arg): Remove.
9952 (catch_ada_exception_command_split): Use std::string. Change type
9953 of "excep_string", "cond_string".
9954 (catch_ada_exception_command): Update.
9955 (create_ada_exception_catchpoint): Change type of excep_string.
9956 (ada_exception_sal): Remove excep_string parameter.
9957 (~ada_catchpoint): Remove.
9959 2018-05-21 Tom Tromey <tom@tromey.com>
9961 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
9964 2018-05-21 Tom Tromey <tom@tromey.com>
9966 * ada-lang.c (ada_exception_message_1, ada_exception_message):
9967 Return unique_xmalloc_ptr.
9968 (print_it_exception): Update.
9970 2018-05-21 Tom Tromey <tom@tromey.com>
9972 * tracepoint.c (trace_dump_actions): Use std::string.
9974 2018-05-21 Tom Tromey <tom@tromey.com>
9976 * symfile.c (reread_symbols): Use std::string for original_name.
9978 2018-05-21 Tom Tromey <tom@tromey.com>
9980 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
9981 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
9984 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
9986 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
9988 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
9989 * objfiles.c (get_objfile_bfd_data): Allocate
9990 objfile_per_bfd_storage with obstack_new when allocating on
9993 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
9995 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
9997 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
9998 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
9999 * mdebugread.c (mdebug_build_psymtabs): Likewise.
10000 (add_pending): Likewise.
10001 (parse_symbol): Likewise.
10002 (parse_partial_symbols): Likewise.
10003 (psymtab_to_symtab_1): Likewise.
10004 (new_psymtab): Likewise.
10005 (elfmdebug_build_psymtabs): Likewise.
10006 * minsyms.c (terminate_minimal_symbol_table): Likewise.
10007 * objfiles.c (get_objfile_bfd_data): Likewise.
10008 (objfile_register_static_link): Likewise.
10009 * psymtab.c (allocate_psymtab): Likewise.
10010 * stabsread.c (read_member_functions): Likewise.
10011 * xcoffread.c (xcoff_end_psymtab): Likewise.
10013 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
10015 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
10016 compiler supports std::is_trivially_constructible.
10017 * common/poison.h: Include obstack.h.
10018 (IsMallocable): Define to is_trivially_constructible if the
10019 compiler supports it, define to true_type otherwise.
10021 (XOBNEW): Redefine.
10023 (XOBNEWVEC): Redefine.
10024 * gdb_obstack.h (obstack_zalloc): New.
10025 (OBSTACK_ZALLOC): Redefine.
10026 (obstack_calloc): New.
10027 (OBSTACK_CALLOC): Redefine.
10028 (obstack_new): New.
10029 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
10030 (gdbarch_obstack): New declaration in gdbarch.h, definition in
10032 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
10033 obstack_calloc/obstack_zalloc.
10034 (gdbarch_obstack_zalloc): Remove.
10035 * target-descriptions.c (tdesc_data_init): Use obstack_new.
10037 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
10039 * stack.c (backtrace_command_1): Remove useless variable int i.
10041 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
10043 * stack.c (print_frame_info): Fix comment.
10045 2018-05-18 Tom Tromey <tom@tromey.com>
10047 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
10048 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
10049 (~dwarf2_per_objfile): Update
10050 (dwarf2_get_dwz_file): Use new.
10051 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
10054 2018-05-18 Tom Tromey <tom@tromey.com>
10056 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
10058 * dwarf2read.c (struct dwp_file): Add constructor and
10060 (open_and_init_dwp_file): Return a unique_ptr.
10061 (dwarf2_per_objfile, create_dwp_hash_table)
10062 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
10063 (lookup_dwo_unit_in_dwp): Update.
10064 (open_and_init_dwp_file, get_dwp_file): Update.
10066 2018-05-18 Tom Tromey <tom@tromey.com>
10068 * dwarf2read.c (dwarf2_per_objfile): Update.
10069 (struct mapped_index): Add initializers.
10070 (dwarf2_read_index): Use new.
10071 (dw2_symtab_iter_init): Update.
10072 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
10075 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
10077 * dwarf2read.c (mapped_index) <total_size>: Remove.
10079 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
10081 * unittests/format_pieces-selftests.c (test_format_specifier):
10084 2018-05-18 Tom Tromey <tom@tromey.com>
10086 * c-typeprint.c (maybe_print_hole): New function.
10087 (c_print_type_struct_field_offset): Update.
10088 (c_type_print_base_struct_union): Call maybe_print_hole.
10090 2018-05-17 Keith Seitz <keiths@redhat.com>
10092 * breakpoint.c (build_bpstat_chain): New function, moved from
10093 bpstat_stop_status.
10094 (bpstat_stop_status): Add optional parameter, `stop_chain'.
10095 If no stop chain is passed, call build_bpstat_chain to build it.
10096 * breakpoint.h (build_bpstat_chain): Declare.
10097 (bpstat_stop_status): Move documentation here from breakpoint.c.
10098 * infrun.c (handle_signal_stop): Before eliding inlined frames,
10099 build the stop chain and pass it to skip_inline_frames.
10100 Pass this stop chain to bpstat_stop_status.
10101 * inline-frame.c: Include breakpoint.h.
10102 (stopped_by_user_bp_inline_frame): New function.
10103 (skip_inline_frames): Add parameter `stop_chain'.
10104 Move documention to inline-frame.h.
10105 If non-NULL, use stopped_by_user_bp_inline_frame to determine
10106 whether the frame should be elided.
10107 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
10108 Add moved documentation and update for new parameter.
10110 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
10113 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10114 unittests/format_pieces-selftests.c.
10115 * common/format.h (format_piece) <operator==>: New.
10116 (format_pieces) <operator[]>: Remove.
10117 * common/format.c (format_pieces::format_pieces): Handle \e.
10118 * unittests/format_pieces-selftests.c: New.
10120 2018-05-17 Tom Tromey <tom@tromey.com>
10123 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
10124 (dw2_instantiate_symtab): Add skip_partial parameter.
10125 (dw2_find_last_source_symtab, dw2_map_expand_apply)
10126 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
10127 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
10128 (dw2_expand_symtabs_matching_one)
10129 (dw2_find_pc_sect_compunit_symtab)
10130 (dw2_debug_names_lookup_symbol)
10131 (dw2_debug_names_expand_symtabs_for_function): Update.
10132 (init_cutu_and_read_dies): Add skip_partial parameter.
10133 (process_psymtab_comp_unit, build_type_psymtabs_1)
10134 (process_skeletonless_type_unit, load_partial_comp_unit)
10135 (psymtab_to_symtab_1): Update.
10136 (load_full_comp_unit): Add skip_partial parameter.
10137 (process_imported_unit_die, dwarf2_read_addr_index)
10138 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
10139 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
10140 (read_signatured_type): Update.
10142 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
10144 * value.c (release_value): Remove unused variable.
10145 (record_latest_value): Likewise.
10146 (access_value_history): Likewise.
10147 (preserve_values): Likewise.
10149 2018-05-17 Tom Tromey <tom@tromey.com>
10151 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
10154 2018-05-16 Maciej W. Rozycki <macro@mips.com>
10157 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
10158 Also handle registers whose width is not a multiple of
10160 (linux_nat_trad_target::store_register): Likewise.
10162 2018-05-16 Tom Tromey <tom@tromey.com>
10164 * gdbcore.h (core_bfd): Redefine.
10165 * corelow.c (core_target::close): Update.
10166 (core_target_open): Update.
10167 * progspace.h (struct program_space) <cbfd>: Now a
10170 2018-05-16 Tom Tromey <tom@tromey.com>
10173 * symfile-add-flags.h (enum symfile_add_flags)
10174 <SYMFILE_NOT_FILENAME>: New constant.
10175 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
10176 objfile name from BFD.
10177 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
10178 * minidebug.c (find_separate_debug_file_in_section): Put
10179 ".gnu_debugdata" into BFD's file name.
10181 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
10183 * regcache.c (regcache_read_ftype, regcache_write_ftype):
10186 2018-05-15 Tamar Christina <tamar.christina@arm.com>
10189 * aarch64-tdep.c (aarch64_analyze_prologue,
10190 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
10191 Indicate not interested in errors.
10193 2018-05-15 Maciej W. Rozycki <macro@mips.com>
10195 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
10196 Supply the MIPS_ZERO_REGNUM register.
10198 2018-05-15 Maciej W. Rozycki <macro@mips.com>
10200 * mips-tdep.c (mask_address_var): Make variable static.
10202 2018-05-14 Tom Tromey <tom@tromey.com>
10204 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
10206 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
10208 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
10209 FXSAVE_ADDR for the mxcsr register.
10211 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
10213 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
10215 2018-05-11 Pedro Alves <palves@redhat.com>
10217 * corelow.c (core_target) <core_target>: No longer inline.
10218 Initialize m_core_gdbarch, m_core_vec and build the section table
10220 <~core_target>: New.
10221 <core_gdbarch, get_core_register_section>: New methods.
10222 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
10223 factored out from ...
10224 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
10225 (core_ops): Delete.
10226 (sniff_core_bfd): Add gdbarch parameter.
10227 (core_close): Delete, merged into ...
10228 (core_target::close): ... here. Delete self.
10229 (core_close_cleanup): Delete.
10230 (core_target_open): Allocate a core_target on the heap. Use a
10231 unique_ptr instead of a cleanup. Bits moved into the core_target
10232 ctor. Adjust to use core_target methods instead of globals.
10233 (get_core_register_section): Rename to ...
10234 (core_target::get_core_register_section): ... this and adjust.
10235 (struct get_core_registers_cb_data): New.
10236 (get_core_registers_cb): Use it. Use bool.
10237 (core_target::fetch_registers, core_target::files_info)
10238 (core_target::xfer_partial, core_target::read_description)
10239 (core_target::pid_to, core_target::thread_name): Adjust to
10240 reference class fields instead of globals.
10241 * target.h (struct target_ops_deleter, target_ops_up): New.
10243 2018-05-11 Pedro Alves <palves@redhat.com>
10245 * corefile.c (core_file_command): Move to corelow.c.
10246 * corelow.c (the_core_target): Delete.
10247 (core_file_command): Moved from corefile.c. Check exec_bfd
10248 instead of the_core_target. Use target_detach instead of calling
10249 into the_core_target directly.
10250 (maybe_say_no_core_file_now): New.
10251 (core_target::detach): Use it.
10252 (_initialize_corelow): Remove references to the_core_target.
10253 * gdbcore.h (the_core_target): Delete.
10255 2018-05-11 Tom Tromey <tromey@redhat.com>
10256 Pedro Alves <palves@redhat.com>
10258 * corefile.c (core_bfd): Remove.
10259 * gdbcore.h (core_bfd): Now a macro.
10260 * progspace.h (struct program_space) <cbfd>: New field.
10262 2018-05-11 Tom Tromey <tom@tromey.com>
10264 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
10267 2018-05-10 Tom Tromey <tom@tromey.com>
10269 * configure: Rebuild.
10270 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
10272 2018-05-10 Joel Brobecker <brobecker@adacore.com>
10275 * regformats/regdat.sh: Adjust script, following the addition
10276 of the new expedite_regs parameter to init_target_desc.
10278 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
10281 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
10282 set_gdbarch_significant_addr_bit.
10283 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
10284 set_gdbarch_significant_addr_bit.
10285 * utils.c (address_significant): Update to sign extend addr.
10287 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
10289 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
10290 (xtensa_linux_init_abi): Limit tdep->num_regs by
10291 tdep->num_nopriv_regs.
10292 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
10293 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
10296 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
10298 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
10300 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
10302 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
10303 (I387_MXCSR_INIT_VAL): New constant.
10304 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
10305 buffer if it was supplied by the inferior.
10306 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
10307 (i387_xsave_get_clear_bv): New function.
10308 (i387_supply_xsave): Only read x87 control registers from the
10309 xsave buffer if the feature is enabled, and the state will have
10310 been written, otherwise, provide a suitable default.
10311 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
10312 including x87 control registers. Update control registers if they
10313 have changed from the default value, and mark features as enabled
10315 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
10317 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
10319 * spu-tdep.c (info_spu_event_command): Fix output formatting.
10321 2018-05-07 Tom Tromey <tom@tromey.com>
10323 * configure: Rebuild.
10324 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
10326 2018-05-07 Tom Tromey <tom@tromey.com>
10329 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
10330 bit. Use correct value for VDIV.
10332 2018-05-04 Tom Tromey <tom@tromey.com>
10334 * configure: Rebuild.
10335 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
10337 2018-05-04 Tom Tromey <tom@tromey.com>
10339 * linux-record.c (record_linux_system_call) <case
10340 RECORD_SYS_RECVFROM>: Add "break".
10342 2018-05-04 Tom Tromey <tom@tromey.com>
10344 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
10345 Add missing "break".
10346 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
10347 Add missing "break".
10349 2018-05-04 Tom Tromey <tom@tromey.com>
10351 * rs6000-tdep.c (ppc_process_record_op4)
10352 (ppc_process_record_op63): Add fall-through comment.
10354 2018-05-04 Tom Tromey <tom@tromey.com>
10356 * i386-tdep.c (i386_process_record): Add fall-through comment.
10358 2018-05-04 Tom Tromey <tom@tromey.com>
10360 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
10363 2018-05-04 Tom Tromey <tom@tromey.com>
10365 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
10366 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
10367 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
10369 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
10371 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
10374 2018-05-04 Tom Tromey <tom@tromey.com>
10376 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
10378 2018-05-04 Tom Tromey <tom@tromey.com>
10380 * s390-tdep.c (s390_process_record): Fix fall-through comments.
10381 * xcoffread.c (scan_xcoff_symtab): Move comment later.
10382 * symfile.c (section_is_mapped): Fix fall-through comment.
10383 * stabsread.c (define_symbol, read_member_functions): Fix
10384 fall-through comment.
10385 * s390-linux-tdep.c (s390_process_record): Fix fall-through
10387 * remote.c (remote_wait_as): Fix fall-through comment.
10388 * p-exp.y (yylex): Fix fall-through comment.
10389 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
10391 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
10392 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
10393 * jv-exp.y (yylex): Fix fall-through comment.
10394 * go-exp.y (lex_one_token): Fix fall-through comment.
10395 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
10396 fall-through comment.
10397 * f-exp.y (yylex): Fix fall-through comment.
10398 * dwarf2read.c (process_die): Fix fall-through comments.
10399 * dbxread.c (process_one_symbol): Fix fall-through comment.
10400 * d-exp.y (lex_one_token): Fix fall-through comment.
10401 * cp-name-parser.y (yylex): Fix fall-through comment.
10402 * coffread.c (coff_symtab_read): Fix fall-through comment.
10403 * c-exp.y (lex_one_token): Fix fall-through comment.
10404 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
10406 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
10409 2018-05-04 Tom Tromey <tom@tromey.com>
10412 * NEWS: Mention gdb.execute change.
10413 * gdbcmd.h (execute_control_command): Don't declare.
10414 * python/python.c (execute_gdb_command): Use read_command_lines_1,
10415 execute_control_commands, execute_control_commands_to_string.
10416 * cli/cli-script.h (execute_control_commands)
10417 (execute_control_commands_to_string): Declare.
10418 (execute_control_command): Add from_tty parameter.
10419 * cli/cli-script.c (execute_control_commands)
10420 (execute_control_commands_to_string): New functions.
10421 (execute_user_command): Use execute_control_commands.
10422 (execute_control_command_1): Add "from_tty" parameter. Update.
10423 (execute_control_command): Likewise.
10425 2018-05-04 Tom Tromey <tom@tromey.com>
10428 * NEWS: Mention that breakpoint commands are writable.
10429 * python/py-breakpoint.c (bppy_set_commands): New function.
10430 (breakpoint_object_getset) <"commands">: Use it.
10432 2018-05-04 Tom Tromey <tom@tromey.com>
10434 * tracepoint.c (actions_command): Update.
10435 * mi/mi-cmd-break.c (mi_command_line_array)
10436 (mi_command_line_array_cnt, mi_command_line_array_ptr)
10437 (mi_read_next_line): Remove.
10438 (mi_cmd_break_commands): Update.
10439 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
10441 * cli/cli-script.c (get_command_line): Update.
10442 (process_next_line): Use function_view. Constify.
10443 (recurse_read_control_structure, read_command_lines)
10444 (read_command_lines_1): Change argument types to function_view.
10445 (do_define_command, document_command): Update.
10446 * breakpoint.h (check_tracepoint_command): Don't declare.
10447 * breakpoint.c (check_tracepoint_command): Remove.
10448 (commands_command_1, create_tracepoint_from_upload): Update.
10450 2018-05-04 Tom Tromey <tom@tromey.com>
10453 * cli/cli-script.h (enum command_control_type) <define_control>:
10455 * cli/cli-script.c (multi_line_command_p): Handle define_control.
10456 (build_command_line, execute_control_command_1)
10457 (process_next_line): Likewise.
10458 (do_define_command): New function, extracted from define_command.
10459 (define_command): Use it.
10461 2018-05-04 Tom Tromey <tom@tromey.com>
10463 * tracepoint.c (actions_command): Update.
10464 * cli/cli-script.h (read_command_lines): Update.
10465 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
10466 (MAX_TMPBUF): Remove define.
10467 (define_command): Use string_printf.
10468 (document_command): Likewise.
10469 * breakpoint.c (commands_command_1): Update.
10471 2018-05-04 Tom Tromey <tom@tromey.com>
10473 * top.c (execute_command): Update.
10474 * cli/cli-script.h (print_command_lines): Now varargs.
10475 * cli/cli-script.c (print_command_lines): Now varargs.
10476 (execute_control_command_1) <case while_control, case if_control>:
10479 2018-05-04 Tom Tromey <tom@tromey.com>
10481 * tracepoint.c (all_tracepoint_actions): Rename from
10482 all_tracepoint_actions_and_cleanup. Change return type.
10483 (actions_command, encode_actions_1, encode_actions)
10484 (trace_dump_actions, tdump_command): Update.
10485 * remote.c (remote_download_command_source): Update.
10486 * python/python.c (gdbpy_eval_from_control_command)
10487 (python_command, python_interactive_command): Update.
10488 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
10489 * guile/guile.c (guile_command)
10490 (gdbscm_eval_from_control_command, guile_command): Update.
10491 * compile/compile.c (compile_code_command)
10492 (compile_print_command, compile_to_object): Update.
10493 * cli/cli-script.h (struct command_lines_deleter): New.
10494 (counted_command_line): New typedef.
10495 (struct command_line): Add constructor, destructor.
10496 <body_list>: Remove.
10497 <body_list_0, body_list_1>: New members.
10498 (command_line_up): Remove typedef.
10499 (read_command_lines, read_command_lines_1, get_command_line):
10501 (copy_command_lines): Don't declare.
10502 * cli/cli-script.c (build_command_line): Use "new".
10503 (get_command_line): Return counted_command_line.
10504 (print_command_lines, execute_user_command)
10505 (execute_control_command_1, while_command, if_command): Update.
10506 (realloc_body_list): Remove.
10507 (process_next_line, recurse_read_control_structure): Update.
10508 (read_command_lines, read_command_lines_1): Return counted_command_line.
10509 (free_command_lines): Use "delete".
10510 (copy_command_lines): Remove.
10511 (define_command, document_command, show_user_1): Update.
10512 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
10513 a counted_command_line.
10514 * breakpoint.h (counted_command_line): Remove typedef.
10515 (breakpoint_set_commands): Update.
10516 * breakpoint.c (check_no_tracepoint_commands)
10517 (validate_commands_for_breakpoint): Update.
10518 (breakpoint_set_commands): Change commands to be a
10519 counted_command_line.
10520 (commands_command_1, update_dprintf_command_list)
10521 (create_tracepoint_from_upload): Update.
10523 2018-05-04 Tom Tromey <tom@tromey.com>
10525 * cli/cli-decode.h (cmd_list_element): New constructor.
10526 (~cmd_list_element): New destructor.
10527 (struct cmd_list_element): Add initializers.
10528 * cli/cli-decode.c (do_add_cmd): Use "new".
10529 (delete_cmd): Use "delete".
10531 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
10532 Pedro Alves <palves@redhat.com>
10534 PR breakpoints/19806 and support for PR external/20207.
10535 * NEWS: Mention Aarch64 watchpoint improvements.
10536 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
10537 watchpoints and PR external/20207 watchpoints.
10538 * nat/aarch64-linux-hw-point.c
10539 (kernel_supports_any_contiguous_range): New.
10540 (aarch64_watchpoint_offset): New.
10541 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
10542 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
10543 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
10544 (aarch64_align_watchpoint): New parameters aligned_offset_p and
10545 next_addr_orig_p. Support PR external/20207 watchpoints.
10546 (aarch64_downgrade_regs): New.
10547 (aarch64_dr_state_insert_one_point): New parameters offset and
10549 (aarch64_dr_state_remove_one_point): Likewise.
10550 (aarch64_handle_breakpoint): Update caller.
10551 (aarch64_handle_aligned_watchpoint): Likewise.
10552 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
10554 (aarch64_linux_set_debug_regs): Remove const from state. Call
10555 aarch64_downgrade_regs.
10556 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
10557 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
10558 (DR_CONTROL_MASK): ... this.
10559 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
10560 (unsigned int aarch64_watchpoint_offset): New prototype.
10561 (aarch64_linux_set_debug_regs): Remove const from state.
10562 * utils.c (align_up, align_down): Move to ...
10563 * common/common-utils.c (align_up, align_down): ... here.
10564 * utils.h (align_up, align_down): Move to ...
10565 * common/common-utils.h (align_up, align_down): ... here.
10567 2018-05-04 Joel Brobecker <brobecker@adacore.com>
10569 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
10570 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
10571 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
10572 Re-implement to match the ABI as summarized in GCC's
10573 gcc/config/sparc/sparc.c. All callers updated.
10574 (sparc32_store_arguments): Remove assertion.
10576 2018-05-04 Tom Tromey <tom@tromey.com>
10578 * printcmd.c: Don't include tui.h.
10579 (decode_format): Use skip_spaces.
10581 2018-05-04 Tom Tromey <tom@tromey.com>
10584 * printcmd.c (last_count): New global.
10585 (x_command): Use saved count when repeating.
10587 2018-05-04 Tom Tromey <tom@tromey.com>
10589 * nto-procfs.c (do_closedir_cleanup): Remove.
10590 (procfs_pidlist): Use gdb_dir_up.
10591 * procfs.c (do_closedir_cleanup): Remove.
10592 (proc_update_threads): Use gdb_dir_up.
10593 * common/filestuff.h (struct gdb_dir_deleter): New.
10594 (gdb_dir_up): New typedef.
10596 2018-05-04 Tom Tromey <tom@tromey.com>
10598 * ada-lang.c (print_mention_exception): Use std::string.
10600 2018-05-04 Tom Tromey <tom@tromey.com>
10602 * ada-lang.c (create_excep_cond_exprs): Update.
10603 (ada_exception_catchpoint_cond_string): Use std::string.
10605 2018-05-04 Tom Tromey <tom@tromey.com>
10607 * ada-lang.c (xget_renaming_scope): Return std::string.
10608 (old_renaming_is_invisible): Update.
10610 2018-05-04 Tom Tromey <tom@tromey.com>
10612 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
10613 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
10615 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
10617 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
10619 2018-05-04 Tom Tromey <tom@tromey.com>
10621 * remote.c (remote_query_supported_append): Change type.
10622 (remote_check_symbols): Update.
10624 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
10627 * configure.ac: Prepend libpython.
10628 * python/python-config.py: Likewise.
10629 * configure: Regenerate.
10631 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
10633 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
10635 2018-05-03 Pedro Alves <palves@redhat.com>
10638 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
10639 override. Write 'true' instead of '1'.
10640 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
10643 2018-05-02 Pedro Alves <palves@redhat.com>
10645 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
10646 add_inf_child_target.
10647 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
10648 add_inf_child_target.
10649 * aix-thread.c (aix_thread_target_info): New.
10650 (aix_thread_target) <shortname, longname, doc>: Delete.
10652 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
10653 add_inf_child_target.
10654 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
10655 add_inf_child_target.
10656 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
10657 add_inf_child_target.
10658 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
10659 add_inf_child_target.
10660 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
10661 add_inf_child_target.
10662 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
10663 add_inf_child_target.
10664 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
10665 add_inf_child_target.
10666 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
10667 add_inf_child_target.
10668 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
10669 add_inf_child_target.
10670 * bfd-target.c (target_bfd_target_info): New.
10671 (target_bfd) <shortname, longname, doc>: Delete.
10673 * bsd-kvm.c (bsd_kvm_target_info): New.
10674 (bsd_kvm_target) <shortname, longname, doc>: Delete.
10676 (bsd_kvm_target::open): Rename to ...
10677 (bsd_kvm_target_open): ... this. Adjust.
10678 * bsd-uthread.c (bsd_uthread_target_info): New.
10679 (bsd_uthread_target) <shortname, longname, doc>: Delete.
10681 * corefile.c (core_file_command): Adjust.
10682 * corelow.c (core_target_info): New.
10683 (core_target) <shortname, longname, doc>: Delete.
10685 (core_target::open): Rename to ...
10686 (core_target_open): ... this. Adjust.
10687 * ctf.c (ctf_target_info): New.
10688 (ctf_target) <shortname, longname, doc>: Delete.
10690 (ctf_target::open): Rename to ...
10691 (ctf_target_open): ... this.
10692 (_initialize_ctf): Adjust.
10693 * exec.c (exec_target_info): New.
10694 (exec_target) <shortname, longname, doc>: Delete.
10696 (exec_target::open): Rename to ...
10697 (exec_target_open): ... this.
10698 * gdbcore.h (core_target_open): Declare.
10699 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
10700 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
10701 add_inf_child_target.
10702 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
10703 add_inf_child_target.
10704 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
10705 add_inf_child_target.
10706 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
10707 add_inf_child_target.
10708 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
10709 add_inf_child_target.
10710 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
10711 add_inf_child_target.
10712 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
10713 add_inf_child_target.
10714 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
10715 add_inf_child_target.
10716 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
10717 add_inf_child_target.
10718 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
10719 add_inf_child_target.
10720 * inf-child.c (inf_child_target_info): New.
10721 (inf_child_target::info): New.
10722 (inf_child_open_target): Remove 'target' parameter. Use
10723 get_native_target instead.
10724 (inf_child_target::open): Delete.
10725 (add_inf_child_target): New.
10726 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
10729 (add_inf_child_target): Declare.
10730 (inf_child_open_target): Declare.
10731 * linux-thread-db.c (thread_db_target_info): New.
10732 (thread_db_target) <shortname, longname, doc>: Delete.
10734 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
10735 add_inf_child_target.
10736 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
10737 add_inf_child_target.
10738 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
10739 add_inf_child_target.
10740 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
10741 add_inf_child_target.
10742 * make-target-delegates (print_class): Adjust.
10743 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
10744 add_inf_child_target.
10745 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
10746 add_inf_child_target.
10747 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
10748 add_inf_child_target.
10749 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
10750 add_inf_child_target.
10751 * nto-procfs.c (nto_native_target_info): New.
10752 (nto_procfs_target_native) <shortname, longname, doc>:
10755 (nto_procfs_target_info): New.
10756 (nto_procfs_target_procfs) <shortname, longname, doc>:
10759 (init_procfs_targets): Adjust.
10760 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
10761 add_inf_child_target.
10762 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
10763 add_inf_child_target.
10764 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
10765 add_inf_child_target.
10766 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
10767 add_inf_child_target.
10768 * ravenscar-thread.c (ravenscar_target_info): New.
10769 (ravenscar_thread_target) <shortname, longname, doc>:
10772 * record-btrace.c (record_btrace_target_info):
10773 (record_btrace_target) <shortname, longname, doc>: Delete.
10775 (record_btrace_target::open): Rename to ...
10776 (record_btrace_target_open): ... this. Adjust.
10777 * record-full.c (record_longname, record_doc): New.
10778 (record_full_base_target) <shortname, longname, doc>: Delete.
10780 (record_full_target_info): New.
10781 (record_full_target): <shortname>: Delete.
10783 (record_full_core_open_1, record_full_open_1): Update comments.
10784 (record_full_base_target::open): Rename to ...
10785 (record_full_open): ... this.
10786 (cmd_record_full_restore): Update.
10787 (_initialize_record_full): Update.
10788 * remote-sim.c (remote_sim_target_info): New.
10789 (gdbsim_target) <shortname, longname, doc>: Delete.
10791 (gdbsim_target::open): Rename to ...
10792 (gdbsim_target_open): ... this.
10793 (_initialize_remote_sim): Adjust.
10794 * remote.c (remote_doc): New.
10795 (remote_target_info): New.
10796 (remote_target) <shortname, longname, doc>: Delete.
10798 (extended_remote_target_info): New.
10799 (extended_remote_target) <shortname, longname, doc>: Delete.
10801 (remote_target::open_1): Make static. Adjust.
10802 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
10803 * s390-linux-nat.c (_initialize_s390_nat): Use
10804 add_inf_child_target.
10805 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
10806 add_inf_child_target.
10807 * sol-thread.c (thread_db_target_info): New.
10808 (sol_thread_target) <shortname, longname, doc>: Delete.
10810 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
10811 add_inf_child_target.
10812 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
10813 add_inf_child_target.
10814 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
10815 add_inf_child_target.
10816 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
10817 add_inf_child_target.
10818 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
10819 add_inf_child_target.
10820 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
10821 add_inf_child_target.
10822 * spu-linux-nat.c (_initialize_spu_nat): Use
10823 add_inf_child_target.
10824 * spu-multiarch.c (spu_multiarch_target_info): New.
10825 (spu_multiarch_target) <shortname, longname, doc>: Delete.
10827 * target-delegates.c: Regenerate.
10828 * target.c: Include <unordered_map>.
10829 (target_ops_p): Delete.
10830 (DEF_VEC_P(target_ops_p)): Delete.
10831 (target_factories): New.
10832 (test_target_info): New.
10833 (test_target_ops::info): New.
10834 (open_target): Adjust to use target_factories.
10835 (add_target_with_completer): Rename to ...
10836 (add_target): ... this. Change prototype. Register target_info
10837 and open callback in target_factories. Register target_info in
10838 command context instead of target_ops.
10839 (add_target): Delete old implementation.
10840 (add_deprecated_target_alias): Change prototype. Adjust.
10841 (the_native_target): New.
10842 (set_native_target, get_native_target): New.
10843 (find_default_run_target): Use the_native_target.
10844 (find_attach_target, find_run_target): Simplify.
10845 (target_ops::open): Delete.
10846 (dummy_target_info): New.
10847 (dummy_target::shortname, dummy_target::longname)
10848 (dummy_target::doc): Delete.
10849 (dummy_target::info): New.
10850 (debug_target::shortname, debug_target::longname)
10851 (debug_target::doc): Delete.
10852 (debug_target::info): New.
10853 * target.h (struct target_info): New.
10854 (target_ops::~target_ops): Add comment.
10855 (target_ops::info): New.
10856 (target_ops::shortname, target_ops::longname, target_ops::doc): No
10857 longer virtual. Implement in terms of target_info.
10858 (set_native_target, get_native_target): Declare.
10859 (target_open_ftype): New.
10860 (add_target, add_target_with_completer)
10861 (add_deprecated_target_alias): Change prototype.
10862 (test_target) <shortname, longname, doc>: Delete.
10864 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
10865 add_inf_child_target.
10866 * tracefile-tfile.c (tfile_target_info): New.
10867 (tfile_target) <shortname, longname, doc>: Delete.
10869 (tfile_target::open): Rename to ...
10870 (tfile_target_open): ... this.
10871 (_initialize_tracefile_tfile): Adjust.
10872 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
10873 add_inf_child_target.
10874 * windows-nat.c (_initialize_windows_nat): Use
10875 add_inf_child_target.
10876 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
10877 add_inf_child_target.
10879 2018-05-02 Pedro Alves <palves@redhat.com>
10881 * linux-nat.h (linux_nat_target) <low_new_thread,
10882 low_delete_thread, low_new_fork, low_forget_process,
10883 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
10884 New virtual methods.
10885 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
10886 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
10887 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
10888 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
10889 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
10891 * linux-fork.c (delete_fork): Adjust to call low method.
10892 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
10893 (linux_nat_new_fork, linux_nat_forget_process_hook)
10894 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
10895 (linux_nat_status_is_event):
10896 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
10897 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
10898 to call low method.
10899 (sigtrap_is_event): Rename to ...
10900 (linux_nat_target::low_status_is_event): ... this.
10901 (linux_nat_set_status_is_event): Delete.
10902 (save_stop_reason, linux_nat_wait_1)
10903 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
10905 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
10906 (linux_nat_set_new_fork, linux_nat_set_forget_process)
10907 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
10908 (linux_nat_set_prepare_to_resume): Delete.
10909 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
10910 low virtual methods.
10911 * amd64-linux-nat.c: Likewise.
10912 * arm-linux-nat.c: Likewise.
10913 * i386-linux-nat.c: Likewise.
10914 * ia64-linux-nat.c: Likewise.
10915 * mips-linux-nat.c: Likewise.
10916 * ppc-linux-nat.c: Likewise.
10917 * s390-linux-nat.c: Likewise.
10918 * sparc64-linux-nat.c: Likewise.
10919 * x86-linux-nat.c: Likewise.
10920 * x86-linux-nat.h: Include "nat/x86-linux.h".
10921 (x86_linux_nat_target) <low_new_fork, low_forget_process,
10922 low_prepare_to_resume, low_new_thread, low_delete_thread>:
10925 2018-05-02 Pedro Alves <palves@redhat.com>
10927 * target.h (target_ops)
10928 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
10929 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
10930 stopped_by_watchpoint, have_continuable_watchpoint,
10931 stopped_data_address, watchpoint_addr_within_range,
10932 can_accel_watchpoint_condition, can_run, thread_alive,
10933 has_all_memory, has_memory, has_stack, has_registers,
10934 has_execution, can_async_p, is_async_p, supports_non_stop,
10935 always_non_stop_p, can_execute_reverse, supports_multi_process,
10936 supports_enable_disable_tracepoint,
10937 supports_disable_randomization, supports_string_tracing,
10938 supports_evaluation_of_breakpoint_conditions,
10939 can_run_breakpoint_commands, filesystem_is_local,
10940 can_download_tracepoint, get_trace_state_variable_value,
10941 set_trace_notes, get_tib_address, use_agent, can_use_agent,
10942 record_is_replaying, record_will_replay,
10943 augmented_libraries_svr4_read>: Adjust to return bool.
10944 * aarch64-linux-nat.c: All implementations adjusted.
10945 * aix-thread.c: All implementations adjusted.
10946 * arm-linux-nat.c: All implementations adjusted.
10947 * breakpoint.c: All implementations adjusted.
10948 * bsd-kvm.c: All implementations adjusted.
10949 * bsd-uthread.c: All implementations adjusted.
10950 * corelow.c: All implementations adjusted.
10951 * ctf.c: All implementations adjusted.
10952 * darwin-nat.c: All implementations adjusted.
10953 * darwin-nat.h: All implementations adjusted.
10954 * exec.c: All implementations adjusted.
10955 * fbsd-nat.c: All implementations adjusted.
10956 * fbsd-nat.h: All implementations adjusted.
10957 * gnu-nat.c: All implementations adjusted.
10958 * gnu-nat.h: All implementations adjusted.
10959 * go32-nat.c: All implementations adjusted.
10960 * ia64-linux-nat.c: All implementations adjusted.
10961 * inf-child.c: All implementations adjusted.
10962 * inf-child.h: All implementations adjusted.
10963 * inf-ptrace.c: All implementations adjusted.
10964 * inf-ptrace.h: All implementations adjusted.
10965 * linux-nat.c: All implementations adjusted.
10966 * linux-nat.h: All implementations adjusted.
10967 * mips-linux-nat.c: All implementations adjusted.
10968 * nto-procfs.c: All implementations adjusted.
10969 * ppc-linux-nat.c: All implementations adjusted.
10970 * procfs.c: All implementations adjusted.
10971 * ravenscar-thread.c: All implementations adjusted.
10972 * record-btrace.c: All implementations adjusted.
10973 * record-full.c: All implementations adjusted.
10974 * remote-sim.c: All implementations adjusted.
10975 * remote.c: All implementations adjusted.
10976 * s390-linux-nat.c: All implementations adjusted.
10977 * sol-thread.c: All implementations adjusted.
10978 * spu-multiarch.c: All implementations adjusted.
10979 * target-delegates.c: All implementations adjusted.
10980 * target.c: All implementations adjusted.
10981 * target.h: All implementations adjusted.
10982 * tracefile-tfile.c: All implementations adjusted.
10983 * tracefile.c: All implementations adjusted.
10984 * tracefile.h: All implementations adjusted.
10985 * windows-nat.c: All implementations adjusted.
10986 * x86-linux-nat.h: All implementations adjusted.
10987 * x86-nat.h: All implementations adjusted.
10989 2018-05-02 Pedro Alves <palves@redhat.com>
10991 * make-target-delegates (scan_target_h): Don't trim lines here.
10992 Replace sequences of tabs and/or whitespace with a single
10994 (top level, parsing methods): Trim each line before processing it
10997 2018-05-02 Pedro Alves <palves@redhat.com>
10998 John Baldwin <jhb@freebsd.org>
11000 * target.h (enum strata) <debug_stratum>: New.
11001 (struct target_ops) <all delegation methods>: Replace by C++
11002 virtual methods, and drop "to_" prefix. All references updated
11004 <to_shortname, to_longname, to_doc, to_data,
11005 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
11006 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
11007 virtual methods. All references updated throughout.
11008 <can_attach, supports_terminal_ours, can_create_inferior,
11009 get_thread_control_capabilities, attach_no_wait>: New
11011 <insert_breakpoint, remove_breakpoint>: Now
11012 TARGET_DEFAULT_NORETURN methods.
11013 <info_proc>: Now returns bool.
11014 <to_magic>: Delete.
11015 (OPS_MAGIC): Delete.
11016 (current_target): Delete. All references replaced by references
11018 (target_stack): ... this. New.
11019 (target_shortname, target_longname): Adjust.
11020 (target_can_run): Now a function declaration.
11021 (default_child_has_all_memory, default_child_has_memory)
11022 (default_child_has_stack, default_child_has_registers)
11023 (default_child_has_execution): Remove target_ops parameter.
11024 (complete_target_initialization): Delete.
11025 (memory_breakpoint_target): New template class.
11026 (test_target_ops): Refactor as a C++ class with virtual methods.
11027 * make-target-delegates (NAME_PART): Tighten.
11028 (POINTER_PART, CP_SYMBOL): New.
11029 (SIMPLE_RETURN_PART): Reimplement.
11030 (VEC_RETURN_PART): Expect less.
11031 (RETURN_PART, VIRTUAL_PART): New.
11032 (METHOD): Adjust to C++ virtual methods.
11033 (scan_target_h): Remove reference to C99.
11034 (dname): Output "target_ops::" prefix.
11035 (write_function_header): Adjust to output a C++ class method.
11036 (write_declaration): New.
11037 (write_delegator): Adjust to output a C++ class method.
11038 (tdname): Output "dummy_target::" prefix.
11039 (write_tdefault, write_debugmethod): Adjust to output a C++ class
11041 (tdefault_names, debug_names): Delete.
11042 (return_types, tdefaults, styles, argtypes_array): New.
11043 (top level): All methods are delegators.
11044 (print_class): New.
11045 (top level): Print dummy_target and debug_target classes.
11046 * target-delegates.c: Regenerate.
11047 * target-debug.h (target_debug_print_enum_info_proc_what)
11048 (target_debug_print_thread_control_capabilities)
11049 (target_debug_print_thread_info_p): New.
11050 * target.c (dummy_target): Delete.
11051 (the_dummy_target, the_debug_target): New.
11052 (target_stack): Now extern.
11053 (set_targetdebug): Push/unpush debug target.
11054 (default_child_has_all_memory, default_child_has_memory)
11055 (default_child_has_stack, default_child_has_registers)
11056 (default_child_has_execution): Remove target_ops parameter.
11057 (complete_target_initialization): Delete.
11058 (add_target_with_completer): No longer call
11059 complete_target_initialization.
11060 (target_supports_terminal_ours): Use regular delegation.
11061 (update_current_target): Delete.
11062 (push_target): No longer check magic number. Don't call
11063 update_current_target.
11064 (unpush_target): Don't call update_current_target.
11065 (target_is_pushed): No longer check magic number.
11066 (target_require_runnable): Skip for all stratums over
11068 (target_ops::info_proc): New.
11069 (target_info_proc): Use find_target_at and
11070 find_default_run_target.
11071 (target_supports_disable_randomization): Use regular delegation.
11072 (target_get_osdata): Use find_target_at.
11073 (target_ops::open, target_ops::close, target_ops::can_attach)
11074 (target_ops::attach, target_ops::can_create_inferior)
11075 (target_ops::create_inferior, target_ops::can_run)
11076 (target_can_run): New.
11077 (default_fileio_target): Use regular delegation.
11078 (target_ops::fileio_open, target_ops::fileio_pwrite)
11079 (target_ops::fileio_pread, target_ops::fileio_fstat)
11080 (target_ops::fileio_close, target_ops::fileio_unlink)
11081 (target_ops::fileio_readlink): New.
11082 (target_fileio_open_1, target_fileio_unlink)
11083 (target_fileio_readlink): Always call the target method. Handle
11085 (return_zero, return_zero_has_execution): Delete.
11086 (init_dummy_target): Delete.
11087 (dummy_target::dummy_target, dummy_target::shortname)
11088 (dummy_target::longname, dummy_target::doc)
11089 (debug_target::debug_target, debug_target::shortname)
11090 (debug_target::longname, debug_target::doc): New.
11091 (target_supports_delete_record): Use regular delegation.
11092 (setup_target_debug): Delete.
11093 (maintenance_print_target_stack): Skip debug_stratum.
11094 (initialize_targets): Instantiate the_dummy_target and
11096 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
11098 (target_auxv_search, fprint_target_auxv): Adjust.
11099 (info_auxv_command): Adjust to use target_stack.
11100 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
11101 * exceptions.c (print_flush): Handle a NULL target_stack.
11102 * regcache.c (target_ops_no_register): Refactor as class with
11105 * exec.c (exec_target): New class.
11106 (exec_ops): Now an exec_target.
11107 (exec_open, exec_close_1, exec_get_section_table)
11108 (exec_xfer_partial, exec_files_info, exec_has_memory)
11109 (exec_make_note_section): Refactor as exec_target methods.
11110 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
11112 (exec_target::find_memory_regions): New.
11113 (_initialize_exec): Don't call init_exec_ops.
11114 * gdbcore.h (exec_file_clear): Delete.
11116 * corefile.c (core_target): Delete.
11117 (core_file_command): Adjust.
11118 * corelow.c (core_target): New class.
11119 (the_core_target): New.
11120 (core_close): Remove target_ops parameter.
11121 (core_close_cleanup): Adjust.
11122 (core_target::close): New.
11123 (core_open, core_detach, get_core_registers, core_files_info)
11124 (core_xfer_partial, core_thread_alive, core_read_description)
11125 (core_pid_to_str, core_thread_name, core_has_memory)
11126 (core_has_stack, core_has_registers, core_info_proc): Rework as
11127 core_target methods.
11128 (ignore, core_remove_breakpoint, init_core_ops): Delete.
11129 (_initialize_corelow): Initialize the_core_target.
11130 * gdbcore.h (core_target): Delete.
11131 (the_core_target): New.
11133 * ctf.c: (ctf_target): New class.
11134 (ctf_ops): Now a ctf_target.
11135 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
11136 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
11137 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
11139 (init_ctf_ops): Delete.
11140 (_initialize_ctf): Don't call it.
11141 * tracefile-tfile.c (tfile_target): New class.
11142 (tfile_ops): Now a tfile_target.
11143 (tfile_open, tfile_close, tfile_files_info)
11144 (tfile_get_tracepoint_status, tfile_trace_find)
11145 (tfile_fetch_registers, tfile_xfer_partial)
11146 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
11147 Refactor as tfile_target methods.
11148 (tfile_xfer_partial_features): Remove target_ops parameter.
11149 (init_tfile_ops): Delete.
11150 (_initialize_tracefile_tfile): Don't call it.
11151 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
11152 (tracefile_has_stack, tracefile_has_registers)
11153 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
11154 tracefile_target methods.
11155 (init_tracefile_ops): Delete.
11156 (tracefile_target::tracefile_target): New.
11157 * tracefile.h: Include "target.h".
11158 (tracefile_target): New class.
11159 (init_tracefile_ops): Delete.
11161 * spu-multiarch.c (spu_multiarch_target): New class.
11162 (spu_ops): Now a spu_multiarch_target.
11163 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
11164 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
11165 (spu_search_memory, spu_mourn_inferior): Refactor as
11166 spu_multiarch_target methods.
11167 (init_spu_ops): Delete.
11168 (_initialize_spu_multiarch): Remove references to init_spu_ops,
11169 complete_target_initialization.
11171 * ravenscar-thread.c (ravenscar_thread_target): New class.
11172 (ravenscar_ops): Now a ravenscar_thread_target.
11173 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
11174 (ravenscar_thread_alive, ravenscar_pid_to_str)
11175 (ravenscar_fetch_registers, ravenscar_store_registers)
11176 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
11177 (ravenscar_stopped_by_hw_breakpoint)
11178 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
11179 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
11180 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
11182 (init_ravenscar_thread_ops): Delete.
11183 (_initialize_ravenscar): Remove references to
11184 init_ravenscar_thread_ops and complete_target_initialization.
11186 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
11187 (bsd_uthread_target): New class.
11188 (bsd_uthread_ops): Now a bsd_uthread_target.
11189 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
11190 (bsd_uthread_close, bsd_uthread_mourn_inferior)
11191 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
11192 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
11193 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
11194 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
11195 (bsd_uthread_target): Delete function.
11196 (_initialize_bsd_uthread): Remove reference to
11197 complete_target_initialization.
11199 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
11200 (target_bfd): ... this new class.
11201 (target_bfd_xfer_partial, target_bfd_get_section_table)
11202 (target_bfd_close): Refactor as target_bfd methods.
11203 (target_bfd::~target_bfd): New.
11204 (target_bfd_reopen): Adjust.
11205 (target_bfd::close): New.
11207 * record-btrace.c (record_btrace_target): New class.
11208 (record_btrace_ops): Now a record_btrace_target.
11209 (record_btrace_open, record_btrace_stop_recording)
11210 (record_btrace_disconnect, record_btrace_close)
11211 (record_btrace_async, record_btrace_info)
11212 (record_btrace_insn_history, record_btrace_insn_history_range)
11213 (record_btrace_insn_history_from, record_btrace_call_history)
11214 (record_btrace_call_history_range)
11215 (record_btrace_call_history_from, record_btrace_record_method)
11216 (record_btrace_is_replaying, record_btrace_will_replay)
11217 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
11218 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
11219 (record_btrace_store_registers, record_btrace_prepare_to_store)
11220 (record_btrace_to_get_unwinder)
11221 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
11222 (record_btrace_commit_resume, record_btrace_wait)
11223 (record_btrace_stop, record_btrace_can_execute_reverse)
11224 (record_btrace_stopped_by_sw_breakpoint)
11225 (record_btrace_supports_stopped_by_sw_breakpoint)
11226 (record_btrace_stopped_by_hw_breakpoint)
11227 (record_btrace_supports_stopped_by_hw_breakpoint)
11228 (record_btrace_update_thread_list, record_btrace_thread_alive)
11229 (record_btrace_goto_begin, record_btrace_goto_end)
11230 (record_btrace_goto, record_btrace_stop_replaying_all)
11231 (record_btrace_execution_direction)
11232 (record_btrace_prepare_to_generate_core)
11233 (record_btrace_done_generating_core): Refactor as
11234 record_btrace_target methods.
11235 (init_record_btrace_ops): Delete.
11236 (_initialize_record_btrace): Remove reference to
11237 init_record_btrace_ops.
11238 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
11239 the execution_direction global.
11240 (record_full_base_target, record_full_target)
11241 (record_full_core_target): New classes.
11242 (record_full_ops): Now a record_full_target.
11243 (record_full_core_ops): Now a record_full_core_target.
11244 (record_full_target::detach, record_full_target::disconnect)
11245 (record_full_core_target::disconnect)
11246 (record_full_target::mourn_inferior, record_full_target::kill):
11248 (record_full_open, record_full_close, record_full_async): Refactor
11249 as methods of the record_full_base_target class.
11250 (record_full_resume, record_full_commit_resume): Refactor
11251 as methods of the record_full_target class.
11252 (record_full_wait, record_full_stopped_by_watchpoint)
11253 (record_full_stopped_data_address)
11254 (record_full_stopped_by_sw_breakpoint)
11255 (record_full_supports_stopped_by_sw_breakpoint)
11256 (record_full_stopped_by_hw_breakpoint)
11257 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
11258 methods of the record_full_base_target class.
11259 (record_full_store_registers, record_full_xfer_partial)
11260 (record_full_insert_breakpoint, record_full_remove_breakpoint):
11261 Refactor as methods of the record_full_target class.
11262 (record_full_can_execute_reverse, record_full_get_bookmark)
11263 (record_full_goto_bookmark, record_full_execution_direction)
11264 (record_full_record_method, record_full_info, record_full_delete)
11265 (record_full_is_replaying, record_full_will_replay)
11266 (record_full_goto_begin, record_full_goto_end, record_full_goto)
11267 (record_full_stop_replaying): Refactor as methods of the
11268 record_full_base_target class.
11269 (record_full_core_resume, record_full_core_kill)
11270 (record_full_core_fetch_registers)
11271 (record_full_core_prepare_to_store)
11272 (record_full_core_store_registers, record_full_core_xfer_partial)
11273 (record_full_core_insert_breakpoint)
11274 (record_full_core_remove_breakpoint)
11275 (record_full_core_has_execution): Refactor
11276 as methods of the record_full_core_target class.
11277 (record_full_base_target::supports_delete_record): New.
11278 (init_record_full_ops): Delete.
11279 (init_record_full_core_ops): Delete.
11280 (record_full_save): Refactor as method of the
11281 record_full_base_target class.
11282 (_initialize_record_full): Remove references to
11283 init_record_full_ops and init_record_full_core_ops.
11285 * remote.c (remote_target, extended_remote_target): New classes.
11286 (remote_ops): Now a remote_target.
11287 (extended_remote_ops): Now an extended_remote_target.
11288 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
11289 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
11290 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
11291 (remote_pass_signals, remote_set_syscall_catchpoint)
11292 (remote_program_signals, )
11293 (remote_thread_always_alive): Remove target_ops parameter.
11294 (remote_thread_alive, remote_thread_name)
11295 (remote_update_thread_list, remote_threads_extra_info)
11296 (remote_static_tracepoint_marker_at)
11297 (remote_static_tracepoint_markers_by_strid)
11298 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
11299 (remote_open): Refactor as methods of remote_target.
11300 (extended_remote_open, extended_remote_detach)
11301 (extended_remote_attach, extended_remote_post_attach):
11302 (extended_remote_supports_disable_randomization)
11303 (extended_remote_create_inferior): : Refactor as method of
11304 extended_remote_target.
11305 (remote_set_permissions, remote_open_1, remote_detach)
11306 (remote_follow_fork, remote_follow_exec, remote_disconnect)
11307 (remote_resume, remote_commit_resume, remote_stop)
11308 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
11309 (remote_terminal_ours, remote_wait, remote_fetch_registers)
11310 (remote_prepare_to_store, remote_store_registers)
11311 (remote_flash_erase, remote_flash_done, remote_files_info)
11312 (remote_kill, remote_mourn, remote_insert_breakpoint)
11313 (remote_remove_breakpoint, remote_insert_watchpoint)
11314 (remote_watchpoint_addr_within_range)
11315 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
11316 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
11317 (remote_supports_stopped_by_sw_breakpoint)
11318 (remote_stopped_by_hw_breakpoint)
11319 (remote_supports_stopped_by_hw_breakpoint)
11320 (remote_stopped_by_watchpoint, remote_stopped_data_address)
11321 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
11322 (remote_verify_memory): Refactor as methods of remote_target.
11323 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
11325 (remote_xfer_partial, remote_get_memory_xfer_limit)
11326 (remote_search_memory, remote_rcmd, remote_memory_map)
11327 (remote_pid_to_str, remote_get_thread_local_address)
11328 (remote_get_tib_address, remote_read_description): Refactor as
11329 methods of remote_target.
11330 (remote_target::fileio_open, remote_target::fileio_pwrite)
11331 (remote_target::fileio_pread, remote_target::fileio_close): New.
11332 (remote_hostio_readlink, remote_hostio_fstat)
11333 (remote_filesystem_is_local, remote_can_execute_reverse)
11334 (remote_supports_non_stop, remote_supports_disable_randomization)
11335 (remote_supports_multi_process, remote_supports_cond_breakpoints)
11336 (remote_supports_enable_disable_tracepoint)
11337 (remote_supports_string_tracing)
11338 (remote_can_run_breakpoint_commands, remote_trace_init)
11339 (remote_download_tracepoint, remote_can_download_tracepoint)
11340 (remote_download_trace_state_variable, remote_enable_tracepoint)
11341 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
11342 (remote_trace_start, remote_get_trace_status)
11343 (remote_get_tracepoint_status, remote_trace_stop)
11344 (remote_trace_find, remote_get_trace_state_variable_value)
11345 (remote_save_trace_data, remote_get_raw_trace_data)
11346 (remote_set_disconnected_tracing, remote_core_of_thread)
11347 (remote_set_circular_trace_buffer, remote_traceframe_info)
11348 (remote_get_min_fast_tracepoint_insn_len)
11349 (remote_set_trace_buffer_size, remote_set_trace_notes)
11350 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
11351 (remote_disable_btrace, remote_teardown_btrace)
11352 (remote_read_btrace, remote_btrace_conf)
11353 (remote_augmented_libraries_svr4_read, remote_load)
11354 (remote_pid_to_exec_file, remote_can_do_single_step)
11355 (remote_execution_direction, remote_thread_handle_to_thread_info):
11356 Refactor as methods of remote_target.
11357 (init_remote_ops, init_extended_remote_ops): Delete.
11358 (remote_can_async_p, remote_is_async_p, remote_async)
11359 (remote_thread_events, remote_upload_tracepoints)
11360 (remote_upload_trace_state_variables): Refactor as methods of
11362 (_initialize_remote): Remove references to init_remote_ops and
11363 init_extended_remote_ops.
11365 * remote-sim.c (gdbsim_target): New class.
11366 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
11367 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
11368 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
11369 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
11370 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
11371 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
11372 Refactor as methods of gdbsim_target.
11373 (gdbsim_ops): Now a gdbsim_target.
11374 (init_gdbsim_ops): Delete.
11375 (gdbsim_cntrl_c): Adjust.
11376 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
11378 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
11379 (the_amd64_linux_nat_target): New.
11380 (amd64_linux_fetch_inferior_registers)
11381 (amd64_linux_store_inferior_registers): Refactor as methods of
11382 amd64_linux_nat_target.
11383 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
11384 * i386-linux-nat.c: Don't include "linux-nat.h".
11385 (i386_linux_nat_target): New class.
11386 (the_i386_linux_nat_target): New.
11387 (i386_linux_fetch_inferior_registers)
11388 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
11389 as methods of i386_linux_nat_target.
11390 (_initialize_i386_linux_nat): Adjust. Set linux_target.
11391 * inf-child.c (inf_child_ops): Delete.
11392 (inf_child_fetch_inferior_registers)
11393 (inf_child_store_inferior_registers): Delete.
11394 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
11395 methods of inf_child_target.
11396 (inf_child_target::supports_terminal_ours)
11397 (inf_child_target::terminal_init)
11398 (inf_child_target::terminal_inferior)
11399 (inf_child_target::terminal_ours_for_output)
11400 (inf_child_target::terminal_ours, inf_child_target::interrupt)
11401 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
11403 (inf_child_open, inf_child_disconnect, inf_child_close)
11404 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
11405 (inf_child_post_startup_inferior, inf_child_can_run)
11406 (inf_child_pid_to_exec_file): Refactor as methods of
11408 (inf_child_follow_fork): Delete.
11409 (inf_child_target::can_create_inferior)
11410 (inf_child_target::can_attach): New.
11411 (inf_child_target::has_all_memory, inf_child_target::has_memory)
11412 (inf_child_target::has_stack, inf_child_target::has_registers)
11413 (inf_child_target::has_execution): New.
11414 (inf_child_fileio_open, inf_child_fileio_pwrite)
11415 (inf_child_fileio_pread, inf_child_fileio_fstat)
11416 (inf_child_fileio_close, inf_child_fileio_unlink)
11417 (inf_child_fileio_readlink, inf_child_use_agent)
11418 (inf_child_can_use_agent): Refactor as methods of
11420 (return_zero, inf_child_target): Delete.
11421 (inf_child_target::inf_child_target): New.
11422 * inf-child.h: Include "target.h".
11423 (inf_child_target): Delete function prototype.
11424 (inf_child_target): New class.
11425 (inf_child_open_target, inf_child_mourn_inferior)
11426 (inf_child_maybe_unpush_target): Delete.
11427 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
11428 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
11429 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
11430 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
11431 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
11432 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
11433 (inf_ptrace_wait, inf_ptrace_xfer_partial)
11434 (inf_ptrace_thread_alive, inf_ptrace_files_info)
11435 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
11436 methods of inf_ptrace_target.
11437 (inf_ptrace_target): Delete function.
11438 * inf-ptrace.h: Include "inf-child.h".
11439 (inf_ptrace_target): Delete function declaration.
11440 (inf_ptrace_target): New class.
11441 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
11442 * linux-nat.c (linux_target): New.
11443 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
11444 (linux_nat_target::~linux_nat_target): New.
11445 (linux_child_post_attach, linux_child_post_startup_inferior)
11446 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
11447 (linux_child_remove_fork_catchpoint)
11448 (linux_child_insert_vfork_catchpoint)
11449 (linux_child_remove_vfork_catchpoint)
11450 (linux_child_insert_exec_catchpoint)
11451 (linux_child_remove_exec_catchpoint)
11452 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
11453 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
11454 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
11455 (linux_nat_stopped_data_address)
11456 (linux_nat_stopped_by_sw_breakpoint)
11457 (linux_nat_supports_stopped_by_sw_breakpoint)
11458 (linux_nat_stopped_by_hw_breakpoint)
11459 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
11460 (linux_nat_kill, linux_nat_mourn_inferior)
11461 (linux_nat_xfer_partial, linux_nat_thread_alive)
11462 (linux_nat_update_thread_list, linux_nat_pid_to_str)
11463 (linux_nat_thread_name, linux_child_pid_to_exec_file)
11464 (linux_child_static_tracepoint_markers_by_strid)
11465 (linux_nat_is_async_p, linux_nat_can_async_p)
11466 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
11467 (linux_nat_supports_multi_process)
11468 (linux_nat_supports_disable_randomization, linux_nat_async)
11469 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
11470 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
11471 (linux_nat_fileio_open, linux_nat_fileio_readlink)
11472 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
11473 methods of linux_nat_target.
11474 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
11475 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
11477 (check_stopped_by_watchpoint): Adjust.
11478 (linux_xfer_partial): Delete.
11479 (linux_target_install_ops, linux_target, linux_nat_add_target):
11481 (linux_nat_target::linux_nat_target): New.
11482 * linux-nat.h: Include "inf-ptrace.h".
11483 (linux_nat_target): New.
11484 (linux_target, linux_target_install_ops, linux_nat_add_target):
11485 Delete function declarations.
11486 (linux_target): Declare global.
11487 * linux-thread-db.c (thread_db_target): New.
11488 (thread_db_target::thread_db_target): New.
11489 (thread_db_ops): Delete.
11490 (the_thread_db_target): New.
11491 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
11492 (thread_db_update_thread_list, thread_db_pid_to_str)
11493 (thread_db_extra_thread_info)
11494 (thread_db_thread_handle_to_thread_info)
11495 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
11496 (thread_db_resume): Refactor as methods of thread_db_target.
11497 (init_thread_db_ops): Delete.
11498 (_initialize_thread_db): Remove reference to init_thread_db_ops.
11499 * x86-linux-nat.c: Don't include "linux-nat.h".
11500 (super_post_startup_inferior): Delete.
11501 (x86_linux_nat_target::~x86_linux_nat_target): New.
11502 (x86_linux_child_post_startup_inferior)
11503 (x86_linux_read_description, x86_linux_enable_btrace)
11504 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
11505 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
11506 methods of x86_linux_nat_target.
11507 (x86_linux_create_target): Delete. Bits folded ...
11508 (x86_linux_add_target): ... here. Now takes a linux_nat_target
11510 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
11511 (x86_linux_nat_target): New class.
11512 (x86_linux_create_target): Delete.
11513 (x86_linux_add_target): Now takes a linux_nat_target pointer.
11514 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
11515 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
11516 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
11517 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
11518 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
11520 (x86_use_watchpoints): Delete.
11521 * x86-nat.h: Include "breakpoint.h" and "target.h".
11522 (x86_use_watchpoints): Delete.
11523 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
11524 (x86_stopped_by_watchpoint, x86_stopped_data_address)
11525 (x86_insert_watchpoint, x86_remove_watchpoint)
11526 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
11527 (x86_stopped_by_hw_breakpoint): New declarations.
11528 (x86_nat_target): New template class.
11530 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
11531 (the_ppc_linux_nat_target): New.
11532 (ppc_linux_fetch_inferior_registers)
11533 (ppc_linux_can_use_hw_breakpoint)
11534 (ppc_linux_region_ok_for_hw_watchpoint)
11535 (ppc_linux_ranged_break_num_registers)
11536 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
11537 (ppc_linux_insert_mask_watchpoint)
11538 (ppc_linux_remove_mask_watchpoint)
11539 (ppc_linux_can_accel_watchpoint_condition)
11540 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
11541 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
11542 (ppc_linux_watchpoint_addr_within_range)
11543 (ppc_linux_masked_watch_num_registers)
11544 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
11545 (ppc_linux_read_description): Refactor as methods of
11546 ppc_linux_nat_target.
11547 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
11549 * procfs.c (procfs_xfer_partial): Delete forward declaration.
11550 (procfs_target): New class.
11551 (the_procfs_target): New.
11552 (procfs_target): Delete function.
11553 (procfs_auxv_parse, procfs_attach, procfs_detach)
11554 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
11555 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
11556 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
11557 (procfs_create_inferior, procfs_update_thread_list)
11558 (procfs_thread_alive, procfs_pid_to_str)
11559 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
11560 (procfs_stopped_data_address, procfs_insert_watchpoint)
11561 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
11562 (proc_find_memory_regions, procfs_info_proc)
11563 (procfs_make_note_section): Refactor as methods of procfs_target.
11564 (_initialize_procfs): Adjust.
11565 * sol-thread.c (sol_thread_target): New class.
11566 (sol_thread_ops): Now a sol_thread_target.
11567 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
11568 (sol_thread_fetch_registers, sol_thread_store_registers)
11569 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
11570 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
11571 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
11572 (init_sol_thread_ops): Delete.
11573 (_initialize_sol_thread): Adjust. Remove references to
11574 init_sol_thread_ops and complete_target_initialization.
11576 * windows-nat.c (windows_nat_target): New class.
11577 (windows_fetch_inferior_registers)
11578 (windows_store_inferior_registers, windows_resume, windows_wait)
11579 (windows_attach, windows_detach, windows_pid_to_exec_file)
11580 (windows_files_info, windows_create_inferior)
11581 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
11582 (windows_close, windows_pid_to_str, windows_xfer_partial)
11583 (windows_get_tib_address, windows_get_ada_task_ptid)
11584 (windows_thread_name, windows_thread_alive): Refactor as
11585 windows_nat_target methods.
11586 (do_initial_windows_stuff): Adjust.
11587 (windows_target): Delete function.
11588 (_initialize_windows_nat): Adjust.
11590 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
11591 (darwin_mourn_inferior, darwin_kill_inferior)
11592 (darwin_create_inferior, darwin_attach, darwin_detach)
11593 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
11594 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
11595 (darwin_supports_multi_process): Refactor as darwin_nat_target
11597 (darwin_resume_to, darwin_files_info): Delete.
11598 (_initialize_darwin_inferior): Rename to ...
11599 (_initialize_darwin_nat): ... this. Adjust to C++ification.
11600 * darwin-nat.h: Include "inf-child.h".
11601 (darwin_nat_target): New class.
11602 (darwin_complete_target): Delete.
11603 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
11604 (darwin_target): New.
11605 (i386_darwin_fetch_inferior_registers)
11606 (i386_darwin_store_inferior_registers): Refactor as methods of
11608 (darwin_complete_target): Delete, with ...
11609 (_initialize_i386_darwin_nat): ... bits factored out here.
11611 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
11612 (the_alpha_linux_nat_target): New.
11613 (alpha_linux_register_u_offset): Refactor as
11614 alpha_linux_nat_target method.
11615 (_initialize_alpha_linux_nat): Adjust.
11616 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
11617 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
11618 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
11619 methods of linux_nat_trad_target.
11620 (linux_trad_target): Delete.
11621 * linux-nat-trad.h (linux_trad_target): Delete function.
11622 (linux_nat_trad_target): New class.
11623 * mips-linux-nat.c (mips_linux_nat_target): New class.
11624 (super_fetch_registers, super_store_registers, super_close):
11626 (the_mips_linux_nat_target): New.
11627 (mips64_linux_regsets_fetch_registers)
11628 (mips64_linux_regsets_store_registers)
11629 (mips64_linux_fetch_registers, mips64_linux_store_registers)
11630 (mips_linux_register_u_offset, mips_linux_read_description)
11631 (mips_linux_can_use_hw_breakpoint)
11632 (mips_linux_stopped_by_watchpoint)
11633 (mips_linux_stopped_data_address)
11634 (mips_linux_region_ok_for_hw_watchpoint)
11635 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
11636 (mips_linux_close): Refactor as methods of mips_linux_nat.
11637 (_initialize_mips_linux_nat): Adjust to C++ification.
11639 * aix-thread.c (aix_thread_target): New class.
11640 (aix_thread_ops): Now an aix_thread_target.
11641 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
11642 (aix_thread_fetch_registers, aix_thread_store_registers)
11643 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
11644 (aix_thread_thread_alive, aix_thread_pid_to_str)
11645 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
11646 Refactor as methods of aix_thread_target.
11647 (init_aix_thread_ops): Delete.
11648 (_initialize_aix_thread): Remove references to init_aix_thread_ops
11649 and complete_target_initialization.
11650 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
11651 (rs6000_nat_target): New class.
11652 (the_rs6000_nat_target): New.
11653 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
11654 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
11655 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
11656 (super_create_inferior): Delete.
11657 (_initialize_rs6000_nat): Adjust to C++ification.
11659 * arm-linux-nat.c (arm_linux_nat_target): New class.
11660 (the_arm_linux_nat_target): New.
11661 (arm_linux_fetch_inferior_registers)
11662 (arm_linux_store_inferior_registers, arm_linux_read_description)
11663 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
11664 (arm_linux_remove_hw_breakpoint)
11665 (arm_linux_region_ok_for_hw_watchpoint)
11666 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
11667 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
11668 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
11669 arm_linux_nat_target.
11670 (_initialize_arm_linux_nat): Adjust to C++ification.
11672 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
11673 (the_aarch64_linux_nat_target): New.
11674 (aarch64_linux_fetch_inferior_registers)
11675 (aarch64_linux_store_inferior_registers)
11676 (aarch64_linux_child_post_startup_inferior)
11677 (aarch64_linux_read_description)
11678 (aarch64_linux_can_use_hw_breakpoint)
11679 (aarch64_linux_insert_hw_breakpoint)
11680 (aarch64_linux_remove_hw_breakpoint)
11681 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
11682 (aarch64_linux_region_ok_for_hw_watchpoint)
11683 (aarch64_linux_stopped_data_address)
11684 (aarch64_linux_stopped_by_watchpoint)
11685 (aarch64_linux_watchpoint_addr_within_range)
11686 (aarch64_linux_can_do_single_step): Refactor as methods of
11687 aarch64_linux_nat_target.
11688 (super_post_startup_inferior): Delete.
11689 (_initialize_aarch64_linux_nat): Adjust to C++ification.
11691 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
11692 (the_hppa_linux_nat_target): New.
11693 (hppa_linux_fetch_inferior_registers)
11694 (hppa_linux_store_inferior_registers): Refactor as methods of
11695 hppa_linux_nat_target.
11696 (_initialize_hppa_linux_nat): Adjust to C++ification.
11698 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
11699 (the_ia64_linux_nat_target): New.
11700 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
11701 (ia64_linux_stopped_data_address)
11702 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
11703 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
11704 ia64_linux_nat_target methods.
11705 (super_xfer_partial): Delete.
11706 (_initialize_ia64_linux_nat): Adjust to C++ification.
11708 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
11709 (the_m32r_linux_nat_target): New.
11710 (m32r_linux_fetch_inferior_registers)
11711 (m32r_linux_store_inferior_registers): Refactor as
11712 m32r_linux_nat_target methods.
11713 (_initialize_m32r_linux_nat): Adjust to C++ification.
11715 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
11716 (the_m68k_linux_nat_target): New.
11717 (m68k_linux_fetch_inferior_registers)
11718 (m68k_linux_store_inferior_registers): Refactor as
11719 m68k_linux_nat_target methods.
11720 (_initialize_m68k_linux_nat): Adjust to C++ification.
11722 * s390-linux-nat.c (s390_linux_nat_target): New class.
11723 (the_s390_linux_nat_target): New.
11724 (s390_linux_fetch_inferior_registers)
11725 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
11726 (s390_insert_watchpoint, s390_remove_watchpoint)
11727 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
11728 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
11729 (s390_auxv_parse, s390_read_description): Refactor as methods of
11730 s390_linux_nat_target.
11731 (_initialize_s390_nat): Adjust to C++ification.
11733 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
11734 (the_sparc_linux_nat_target): New.
11735 (_initialize_sparc_linux_nat): Adjust to C++ification.
11736 * sparc-nat.c (sparc_fetch_inferior_registers)
11737 (sparc_store_inferior_registers): Remove target_ops parameter.
11738 * sparc-nat.h (sparc_fetch_inferior_registers)
11739 (sparc_store_inferior_registers): Remove target_ops parameter.
11740 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
11741 (the_sparc64_linux_nat_target): New.
11742 (_initialize_sparc64_linux_nat): Adjust to C++ification.
11744 * spu-linux-nat.c (spu_linux_nat_target): New class.
11745 (the_spu_linux_nat_target): New.
11746 (spu_child_post_startup_inferior, spu_child_post_attach)
11747 (spu_child_wait, spu_fetch_inferior_registers)
11748 (spu_store_inferior_registers, spu_xfer_partial)
11749 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
11751 (_initialize_spu_nat): Adjust to C++ification.
11753 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
11754 (the_tilegx_linux_nat_target): New.
11755 (fetch_inferior_registers, store_inferior_registers):
11756 Refactor as methods.
11757 (_initialize_tile_linux_nat): Adjust to C++ification.
11759 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
11760 (the_xtensa_linux_nat_target): New.
11761 (xtensa_linux_fetch_inferior_registers)
11762 (xtensa_linux_store_inferior_registers): Refactor as
11763 xtensa_linux_nat_target methods.
11764 (_initialize_xtensa_linux_nat): Adjust to C++ification.
11766 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
11767 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
11768 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
11769 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
11770 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
11771 (fbsd_stopped_by_sw_breakpoint)
11772 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
11773 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
11774 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
11775 (fbsd_post_startup_inferior, fbsd_post_attach)
11776 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
11777 (fbsd_set_syscall_catchpoint)
11778 (super_xfer_partial, super_resume, super_wait)
11779 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
11780 (fbsd_handle_debug_trap): Remove target_ops parameter.
11781 (fbsd_nat_add_target): Delete.
11782 * fbsd-nat.h: Include "inf-ptrace.h".
11783 (fbsd_nat_add_target): Delete.
11784 (USE_SIGTRAP_SIGINFO): Define.
11785 (fbsd_nat_target): New class.
11787 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
11788 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
11789 (amd64bsd_target): Delete.
11790 * amd64-bsd-nat.h: New file.
11791 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
11793 (amd64_fbsd_nat_target): New class.
11794 (the_amd64_fbsd_nat_target): New.
11795 (amd64fbsd_read_description): Refactor as method of
11796 amd64_fbsd_nat_target.
11797 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
11798 (_initialize_amd64fbsd_nat): Adjust to C++ification.
11799 * amd64-nat.h (amd64bsd_target): Delete function declaration.
11800 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
11801 (i386bsd_store_inferior_registers): Remove target_ops parameter.
11802 (i386bsd_target): Delete.
11803 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
11804 (i386bsd_fetch_inferior_registers)
11805 (i386bsd_store_inferior_registers): Declare.
11806 (i386_bsd_nat_target): New class.
11807 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
11808 (the_i386_fbsd_nat_target): New.
11809 (i386fbsd_resume, i386fbsd_read_description): Refactor as
11810 i386_fbsd_nat_target methods.
11811 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
11812 (_initialize_i386fbsd_nat): Adjust to C++ification.
11813 * x86-bsd-nat.c (super_mourn_inferior): Delete.
11814 (x86bsd_mourn_inferior, x86bsd_target): Delete.
11815 (_initialize_x86_bsd_nat): Adjust to C++ification.
11816 * x86-bsd-nat.h: Include "x86-nat.h".
11817 (x86bsd_target): Delete declaration.
11818 (x86bsd_nat_target): New class.
11820 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
11821 (the_aarch64_fbsd_nat_target): New.
11822 (aarch64_fbsd_fetch_inferior_registers)
11823 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
11824 aarch64_fbsd_nat_target.
11825 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
11826 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
11827 (the_alpha_bsd_nat_target): New.
11828 (alphabsd_fetch_inferior_registers)
11829 (alphabsd_store_inferior_registers): Refactor as
11830 alpha_bsd_nat_target methods.
11831 (_initialize_alphabsd_nat): Refactor as methods of
11832 alpha_bsd_nat_target.
11833 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
11834 (the_amd64_nbsd_nat_target): New.
11835 (_initialize_amd64nbsd_nat): Adjust to C++ification.
11836 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
11837 (the_amd64_obsd_nat_target): New.
11838 (_initialize_amd64obsd_nat): Adjust to C++ification.
11839 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
11840 (the_arm_fbsd_nat_target): New.
11841 (arm_fbsd_fetch_inferior_registers)
11842 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
11843 (_initialize_arm_fbsd_nat): Refactor as methods of
11844 arm_fbsd_nat_target.
11845 (_initialize_arm_fbsd_nat): Adjust to C++ification.
11846 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
11847 (the_arm_netbsd_nat_target): New.
11848 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
11849 arm_netbsd_nat_target.
11850 (_initialize_arm_netbsd_nat): Adjust to C++ification.
11851 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
11852 (the_hppa_nbsd_nat_target): New.
11853 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
11854 hppa_nbsd_nat_target methods.
11855 (_initialize_hppanbsd_nat): Adjust to C++ification.
11856 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
11857 (the_hppa_obsd_nat_target): New.
11858 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
11859 methods of hppa_obsd_nat_target.
11860 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
11862 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
11863 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
11865 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
11866 (_initialize_i386obsd_nat): Use add_target.
11867 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
11868 (the_m68k_bsd_nat_target): New.
11869 (m68kbsd_fetch_inferior_registers)
11870 (m68kbsd_store_inferior_registers): Refactor as methods of
11871 m68k_bsd_nat_target.
11872 (_initialize_m68kbsd_nat): Adjust to C++ification.
11873 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
11874 (the_mips_fbsd_nat_target): New.
11875 (mips_fbsd_fetch_inferior_registers)
11876 (mips_fbsd_store_inferior_registers): Refactor as methods of
11877 mips_fbsd_nat_target.
11878 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
11880 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
11881 (the_mips_nbsd_nat_target): New.
11882 (mipsnbsd_fetch_inferior_registers)
11883 (mipsnbsd_store_inferior_registers): Refactor as methods of
11884 mips_nbsd_nat_target.
11885 (_initialize_mipsnbsd_nat): Adjust to C++ification.
11886 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
11887 (the_mips64_obsd_nat_target): New.
11888 (mips64obsd_fetch_inferior_registers)
11889 (mips64obsd_store_inferior_registers): Refactor as methods of
11890 mips64_obsd_nat_target.
11891 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
11893 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
11895 * nbsd-nat.h: Include "inf-ptrace.h".
11896 (nbsd_nat_target): New class.
11897 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
11898 (obsd_wait): Refactor as methods of obsd_nat_target.
11899 (obsd_add_target): Delete.
11900 * obsd-nat.h: Include "inf-ptrace.h".
11901 (obsd_nat_target): New class.
11902 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
11903 (the_ppc_fbsd_nat_target): New.
11904 (ppcfbsd_fetch_inferior_registers)
11905 (ppcfbsd_store_inferior_registers): Refactor as methods of
11906 ppc_fbsd_nat_target.
11907 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
11909 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
11910 (the_ppc_nbsd_nat_target): New.
11911 (ppcnbsd_fetch_inferior_registers)
11912 (ppcnbsd_store_inferior_registers): Refactor as methods of
11913 ppc_nbsd_nat_target.
11914 (_initialize_ppcnbsd_nat): Adjust to C++ification.
11915 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
11916 (the_ppc_obsd_nat_target): New.
11917 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
11918 methods of ppc_obsd_nat_target.
11919 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
11921 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
11922 (the_sh_nbsd_nat_target): New.
11923 (shnbsd_fetch_inferior_registers)
11924 (shnbsd_store_inferior_registers): Refactor as methods of
11925 sh_nbsd_nat_target.
11926 (_initialize_shnbsd_nat): Adjust to C++ification.
11927 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
11928 (inf_ptrace_xfer_partial): Delete.
11929 (sparc_xfer_partial, sparc_target): Delete.
11930 * sparc-nat.h (sparc_fetch_inferior_registers)
11931 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
11932 (sparc_target): Delete function declaration.
11933 (sparc_target): New template class.
11934 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
11935 (_initialize_sparcnbsd_nat): Adjust to C++ification.
11936 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
11937 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
11939 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
11940 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
11941 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
11942 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
11944 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
11945 (the_vax_bsd_nat_target): New.
11946 (vaxbsd_fetch_inferior_registers)
11947 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
11949 (_initialize_vaxbsd_nat): Adjust to C++ification.
11951 * bsd-kvm.c (bsd_kvm_target): New class.
11952 (bsd_kvm_ops): Now a bsd_kvm_target.
11953 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
11954 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
11955 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
11957 (bsd_kvm_return_one): Delete.
11958 (bsd_kvm_add_target): Adjust to C++ification.
11960 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
11961 (nto_procfs_target_procfs): New classes.
11962 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
11963 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
11964 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
11965 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
11966 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
11967 (procfs_remove_hw_breakpoint, procfs_resume)
11968 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
11969 (procfs_kill_inferior, procfs_store_registers)
11970 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
11971 as methods of nto_procfs_target.
11972 (nto_procfs_ops): Now an nto_procfs_target_procfs.
11973 (nto_native_ops): Delete.
11974 (procfs_open, procfs_native_open): Delete.
11975 (nto_native_ops): Now an nto_procfs_target_native.
11976 (init_procfs_targets): Adjust to C++ification.
11977 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
11978 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
11979 Refactor as methods of nto_procfs_target.
11981 * go32-nat.c (go32_nat_target): New class.
11982 (the_go32_nat_target): New.
11983 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
11984 (go32_store_registers, go32_xfer_partial, go32_files_info)
11985 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
11986 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
11987 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
11988 (go32_pid_to_str): Refactor as methods of go32_nat_target.
11989 (go32_target): Delete.
11990 (_initialize_go32_nat): Adjust to C++ification.
11992 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
11993 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
11994 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
11995 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
11997 (gnu_target): Delete.
11998 * gnu-nat.h (gnu_target): Delete.
11999 (gnu_nat_target): New class.
12000 * i386-gnu-nat.c (gnu_base_target): New.
12001 (i386_gnu_nat_target): New class.
12002 (the_i386_gnu_nat_target): New.
12003 (_initialize_i386gnu_nat): Adjust to C++ification.
12005 2018-05-02 Pedro Alves <palves@redhat.com>
12007 * bfd-target.c (target_bfd_xclose): Rename to ...
12008 (target_bfd_close): ... this.
12009 (target_bfd_reopen): Adjust.
12010 * target.c (target_close): Remove references to to_xclose.
12011 * target.h (target_ops::to_xclose): Delete.
12012 (target_ops::to_close): Update comments.
12014 2018-05-02 Pedro Alves <palves@redhat.com>
12016 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
12018 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
12019 * inf-ptrace.c (inf_ptrace_register_u_offset)
12020 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
12021 (inf_ptrace_store_register, inf_ptrace_store_registers)
12022 (inf_ptrace_trad_target): Move to ...
12023 * linux-nat-trad.c: ... this new file.
12024 * linux-nat-trad.h: New file.
12025 * linux-nat.c (linux_target_install_ops): Make extern.
12026 (linux_trad_target): Delete.
12027 * linux-nat.h (linux_trad_target): Delete declaration.
12028 (linux_target_install_ops): Declare.
12029 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
12032 2018-05-02 Pedro Alves <palves@redhat.com>
12034 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
12035 procfs_target/add_target here.
12036 * procfs.c (procfs_target): Make static.
12037 (_initialize_procfs): Call add_target here.
12038 * procfs.h (struct target_ops): Remove forward declaration.
12039 (procfs_target): Remove declaration.
12040 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
12042 2018-05-02 Pedro Alves <palves@redhat.com>
12044 * procfs.c (procfs_stopped_by_watchpoint)
12045 (procfs_insert_watchpoint, procfs_remove_watchpoint)
12046 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
12048 (procfs_use_watchpoints): Delete, move contents...
12049 (procfs_target): ... here.
12050 * procfs.h (procfs_use_watchpoints): Delete declaration.
12051 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
12052 procfs_use_watchpoints.
12053 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
12054 procfs_use_watchpoints.
12056 2018-05-02 Tom Tromey <tom@tromey.com>
12059 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
12060 and var_zuinteger_unlimited.
12061 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
12062 and PARAM_ZUINTEGER_UNLIMITED.
12063 (set_parameter_value): Handle var_zuinteger and
12064 var_zuinteger_unlimited.
12065 (add_setshow_generic): Likewise.
12066 (parmpy_init): Likewise.
12068 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
12071 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
12072 pointer is not null before dereferencing it.
12074 2018-04-30 Tom Tromey <tom@tromey.com>
12076 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
12079 2018-04-30 Tom Tromey <tom@tromey.com>
12081 * breakpoint.c (mention): Remove use of is_mi_like_p.
12082 (print_mention_ranged_breakpoint): Likewise.
12083 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
12086 2018-04-30 Tom Tromey <tom@tromey.com>
12088 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
12090 2018-04-30 Tom Tromey <tom@tromey.com>
12092 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
12093 (info_spu_event_command): Remove some uses of is_mi_like_p.
12095 2018-04-30 Tom Tromey <tom@tromey.com>
12097 * python/py-framefilter.c (py_print_single_arg)
12098 (enumerate_locals, py_print_args, py_print_frame): Remove some
12099 uses of is_mi_like_p.
12101 2018-04-30 Tom Tromey <tom@tromey.com>
12103 * ui-out.c: Update.
12104 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
12105 * ui-out.h (ui_out::is_mi_like_p): Now const.
12106 (ui_out::do_is_mi_like_p): Now const.
12107 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
12109 2018-04-30 Tom Tromey <tom@tromey.com>
12111 * varobj.c (varobj_set_visualizer): Use new_reference.
12112 * python/python.c (gdbpy_decode_line): Use new_reference.
12113 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
12116 2018-04-30 Tom Tromey <tom@tromey.com>
12118 * varobj.c (install_new_value): Use new_reference.
12119 * value.h (value_incref): Return void. Swap intro comment with
12121 * value.c (set_value_parent): Use new_reference.
12122 (value_incref): Return void. Update intro comment.
12123 (release_value): Use new_reference.
12124 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
12126 2018-04-30 Tom Tromey <tom@tromey.com>
12128 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
12129 * gdb_bfd.h (new_bfd_ref): Remove.
12130 (gdb_bfd_open): Update comment.
12131 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
12132 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
12133 (gdb_bfd_fdopenr): Use new_reference.
12134 * exec.c (exec_file_attach): Use new_reference.
12136 2018-04-30 Tom Tromey <tom@tromey.com>
12138 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
12141 2018-04-30 Tom Tromey <tom@tromey.com>
12143 * jit.c (jit_read_code_entry): Use type_align.
12144 * i386-tdep.c (i386_gdbarch_init): Don't call
12145 set_gdbarch_long_long_align_bit.
12146 * gdbarch.sh: Remove long_long_align_bit.
12147 * gdbarch.c, gdbarch.h: Rebuild.
12148 * arc-tdep.c (arc_type_align): New function.
12149 (arc_gdbarch_init): Use arc_type_align. Don't call
12150 set_gdbarch_long_long_align_bit.
12152 2018-04-30 Tom Tromey <tom@tromey.com>
12154 * rust-lang.c (rust_type_alignment): Remove.
12155 (rust_composite_type): Use type_align.
12157 2018-04-30 Tom Tromey <tom@tromey.com>
12159 * NEWS: Mention Type.align.
12160 * python/py-type.c (typy_get_alignof): New function.
12161 (type_object_getset): Add "alignof".
12163 2018-04-30 Tom Tromey <tom@tromey.com>
12167 * std-operator.def (UNOP_ALIGNOF): New operator.
12168 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
12170 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
12171 * c-lang.c (c_op_print_tab): Add alignof.
12172 * c-exp.y (ALIGNOF): New token.
12173 (exp): Add "ALIGNOF" production.
12174 (ident_tokens): Add _Alignof and alignof.
12176 2018-04-30 Tom Tromey <tom@tromey.com>
12178 * i386-tdep.c (i386_type_align): New function.
12179 (i386_gdbarch_init): Update.
12180 * gdbarch.sh (type_align): New method.
12181 * gdbarch.c, gdbarch.h: Rebuild.
12182 * arch-utils.h (default_type_align): Declare.
12183 * arch-utils.c (default_type_align): New function.
12184 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
12185 (struct type) <align_log2>: New field.
12186 <instance_flags>: Now a bitfield.
12187 (TYPE_RAW_ALIGN): New macro.
12188 (type_align, type_raw_align, set_type_align): Declare.
12189 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
12191 * dwarf2read.c (quirk_rust_enum): Set type alignment.
12192 (get_alignment, maybe_set_alignment): New functions.
12193 (read_structure_type, read_enumeration_type, read_array_type)
12194 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
12195 (read_subrange_type, read_base_type): Set type alignment.
12197 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
12199 * dwarf2read.c (read_index_from_section): Use bool.
12201 2018-04-29 Fabian Groffen <grobian@gentoo.org>
12204 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
12207 2018-04-29 John Reiser <jreiser@BitWagon.com>
12210 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
12211 last step, and do it atomically.
12213 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
12215 * compile/compile-c-types.c (convert_int, convert_float):
12216 Update for C FE v1.
12218 2018-04-27 Tom Tromey <tom@tromey.com>
12221 * rust-lang.c (rust_inclusive_range_type_p): New function.
12222 (rust_range): Handle inclusive ranges.
12223 (rust_compute_range): Likewise.
12224 * rust-exp.y (struct rust_op) <inclusive>: New field.
12225 (DOTDOTEQ): New constant.
12226 (range_expr): Add "..=" productions.
12227 (operator_tokens): Add "..=" token.
12228 (ast_range): Add "inclusive" parameter.
12229 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
12231 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
12233 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
12234 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
12236 * expprint.c (print_subexp_standard): Handle new bounds values.
12237 (dump_subexp_body_standard): Likewise.
12239 2018-04-27 Tom Tromey <tom@tromey.com>
12241 * configure: Rebuild.
12242 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
12243 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
12245 (class symbol_needs_eval_context): Likewise.
12246 * dwarf2read.c (mock_mapped_index::symbol_name_count)
12247 (mock_mapped_index::symbol_name_at): Use "override". Remove
12249 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
12251 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
12252 * aarch64-tdep.c (instruction_reader::read): Use "override".
12253 (instruction_reader_test::read): Likewise.
12254 * arm-tdep.c (instruction_reader::read): Use "override".
12255 (instruction_reader_thumb::read): Likewise.
12257 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
12260 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
12261 instead of remote_send.
12262 (remote_send): Remove.
12264 2018-04-26 Pedro Alves <palves@redhat.com>
12266 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
12267 find_function_start_sal instead of find_pc_line.
12269 2018-04-26 Pedro Alves <palves@redhat.com>
12271 * breakpoint.c (set_breakpoint_location_function): Handle
12272 mst_data_gnu_ifunc.
12273 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
12274 * elfread.c (elf_symtab_read): Give data symbols with
12275 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
12276 (elf_rel_plt_read): Update comment.
12277 * linespec.c (convert_linespec_to_sals): Handle
12278 mst_data_gnu_ifunc.
12279 (minsym_found): Handle mst_data_gnu_ifunc.
12280 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
12281 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
12282 * parse.c (find_minsym_type_and_address): Handle
12283 mst_data_gnu_ifunc.
12284 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
12285 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
12286 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
12288 <mst_data_gnu_ifunc>: New enumerator.
12290 2018-04-26 Pedro Alves <palves@redhat.com>
12292 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
12293 (lookup_minimal_symbol_by_pc_section): ... this. Replace
12294 'want_trampoline' parameter by a lookup_msym_prefer parameter.
12296 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
12297 (lookup_minimal_symbol_by_pc): Adjust.
12298 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
12299 (lookup_solib_trampoline_symbol_by_pc): Adjust.
12300 * minsyms.h (lookup_msym_prefer): New enum.
12301 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
12302 parameter by a lookup_msym_prefer parameter.
12304 2018-04-26 Pedro Alves <palves@redhat.com>
12306 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
12307 ends in "@plt" instead of looking at the symbol's section.
12309 2018-04-26 Pedro Alves <palves@redhat.com>
12311 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
12313 (find_pc_partial_function_gnu_ifunc): Rename to ...
12314 (find_pc_partial_function): ... this, and remove references to
12316 (find_pc_partial_function): Delete old implementation.
12317 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
12319 2018-04-26 Pedro Alves <palves@redhat.com>
12321 * linespec.c (struct bound_minimal_symbol_search_key): New.
12322 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
12323 skip first line if we found a GNU ifunc minimal symbol by name.
12324 (compare_msymbols): Change parameters to work with a destructured
12326 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
12329 2018-04-26 Pedro Alves <palves@redhat.com>
12331 * breakpoint.c (set_breakpoint_location_function): Don't resolve
12332 ifunc targets here. Instead, if we have an ifunc minsym, use its
12334 (add_location_to_breakpoint): Store the minsym and the objfile in
12335 the breakpoint location.
12336 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
12337 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
12338 Record the minsym in the sal.
12339 * symtab.h (symtab_and_line) <msymbol>: New field.
12341 2018-04-26 Pedro Alves <palves@redhat.com>
12343 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
12344 unless we actually resolved the ifunc.
12346 2018-04-26 Pedro Alves <palves@redhat.com>
12348 * c-exp.y (variable production): Prefer ifunc minsyms over
12349 regular function symbols.
12350 * symtab.c (find_gnu_ifunc): New function.
12351 * minsyms.h (lookup_msym_prefer): New enum.
12352 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
12353 parameter by a lookup_msym_prefer parameter.
12354 * symtab.h (find_gnu_ifunc): New declaration.
12356 2018-04-26 Pedro Alves <palves@redhat.com>
12358 * blockframe.c (find_gnu_ifunc_target_type): New function.
12359 (find_function_type): New.
12360 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
12361 return a value with a memory address.
12362 (eval_call): For calls to GNU ifunc functions, try to find the
12363 type of the target function from the type that the resolver
12365 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
12367 * infcall.c (find_function_return_type): Delete.
12368 (find_function_addr): Add 'function_type' parameter. For calls to
12369 GNU ifunc functions, try to find the type of the target function
12370 from the type that the resolver returns, and return it via
12372 (call_function_by_hand_dummy): Adjust to use the function type
12373 returned by find_function_addr.
12374 (find_function_addr): Add 'function_type' parameter and move
12376 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
12379 2018-04-26 Pedro Alves <palves@redhat.com>
12381 * c-exp.y (variable production): Skip finding an alias for ifunc
12384 2018-04-26 Pedro Alves <palves@redhat.com>
12386 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
12388 2018-04-25 Pedro Alves <palves@redhat.com>
12390 * infcmd.c (kill_command): Print the pid as string, not the whole
12391 thread's ptid. Add comment. s/has been killed/killed/ in output
12393 * remote.c (remote_detach_1): Print the pid as string, not the
12394 whole thread's ptid.
12396 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
12397 Sergio Durigan Junior <sergiodj@redhat.com>
12398 Pedro Alves <palves@redhat.com>
12400 * infcmd.c (kill_command): Print message when inferior has
12402 * inferior.c (print_inferior_events): Remove 'static'. Set as
12404 (add_inferior): Improve message printed when
12405 'print_inferior_events' is on.
12406 (exit_inferior): Remove message printed when
12407 'print_inferior_events' is on.
12408 (detach_inferior): Improve message printed when
12409 'print_inferior_events' is on.
12410 (initialize_inferiors): Use 'add_inferior_silent' to set
12411 'current_inferior_'.
12412 * inferior.h (print_inferior_events): Declare here as
12414 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
12415 '[Detaching...]' messages when 'print_inferior_events' is on.
12416 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
12417 as prefix/suffix for messages. Remove periods. Fix erroneous
12418 'Detaching after fork from child...', replace it by '... from
12420 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
12421 prefix/suffix when printing 'Detaching...' messages. Print
12422 them when 'print_inferior_events' is on.
12423 * remote.c (remote_detach_1): Print message when detaching
12424 from inferior and '!is_fork_parent'.
12426 2018-04-24 Tom Tromey <tom@tromey.com>
12428 * cli-out.h: Reindent.
12430 2018-04-24 Tom Tromey <tom@tromey.com>
12432 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
12433 (cli_ui_out::do_field_string): Use fputs_filtered.
12434 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
12436 2018-04-23 Tom Tromey <tom@tromey.com>
12438 * guile/scm-frame.c (gdbscm_frame_read_var): Use
12439 gdb::unique_xmalloc_ptr.
12441 2018-04-23 Tom Tromey <tom@tromey.com>
12443 * configure: Rebuild.
12445 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
12448 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
12449 prepare_for_testing. Set normal_bp to r_debug_state if target
12452 2018-04-21 Pedro Alves <palves@redhat.com>
12453 Rajendra SY <rajendra.sy@gmail.com>
12455 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
12456 * remote.c (extended_remote_attach): In all-stop mode, mark the
12457 thread as executing.
12459 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
12461 * thread.c (thread_apply_all_command): Fix comment.
12462 (thread_command): Fix comment.
12464 2018-04-10 Alan Hayward <alan.hayward@arm.com>
12466 * common/tdesc.h (tdesc_create_feature): Remove xml filename
12468 * features/aarch64-core.c (create_feature_aarch64_core):
12470 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
12472 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
12474 * features/i386/32bit-avx512.c
12475 (create_feature_i386_32bit_avx512): Likewise.
12476 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
12478 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
12480 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
12482 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
12484 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
12486 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
12488 * features/i386/64bit-avx512.c
12489 (create_feature_i386_64bit_avx512): Likewise.
12490 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
12492 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
12494 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
12496 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
12498 * features/i386/64bit-segments.c
12499 (create_feature_i386_64bit_segments): Likewise.
12500 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
12502 * features/i386/x32-core.c
12503 (create_feature_i386_x32_core): Likewise.
12504 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
12505 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
12506 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
12507 * target-descriptions.c: In generated code, don't pass xml
12510 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12512 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
12513 (print_xml_feature::visit_post): Likewise.
12514 (print_xml_feature::visit): Likewise.
12515 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
12516 (print_xml_feature): Add new class.
12517 * regformats/regdat.sh: Null xmltarget on feature targets.
12518 * target-descriptions.c (struct target_desc): Add xmltarget.
12519 (maintenance_check_tdesc_xml_convert): Add unittest function.
12520 (tdesc_get_features_xml): Add function to get xml.
12521 (maintenance_check_xml_descriptions): Test xml generation.
12522 * xml-tdesc.c (string_read_description_xml): Add function.
12523 * xml-tdesc.h (string_read_description_xml): Add declaration.
12525 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12527 * features/Makefile: Add feature marker to targets with new style
12528 target descriptions.
12529 * regformats/aarch64.dat: Regenerate.
12530 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
12531 * regformats/i386/amd64-avx-linux.dat: Likewise.
12532 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
12533 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
12534 * regformats/i386/amd64-linux.dat: Likewise.
12535 * regformats/i386/amd64-mpx-linux.dat: Likewise.
12536 * regformats/i386/amd64.dat: Likewise.
12537 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
12538 * regformats/i386/i386-avx-linux.dat: Likewise.
12539 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
12540 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
12541 * regformats/i386/i386-linux.dat: Likewise.
12542 * regformats/i386/i386-mmx-linux.dat: Likewise.
12543 * regformats/i386/i386-mpx-linux.dat: Likewise.
12544 * regformats/i386/i386.dat: Likewise.
12545 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
12546 * regformats/i386/x32-avx-linux.dat: Likewise.
12547 * regformats/i386/x32-linux.dat: Likewise.
12548 * regformats/tic6x-c62x-linux.dat: Likewise.
12549 * regformats/tic6x-c64x-linux.dat: Likewise.
12550 * regformats/tic6x-c64xp-linux.dat: Likewise.
12551 * regformats/regdat.sh: Parse feature marker.
12553 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12555 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
12556 (tdesc_osabi_name): Likewise.
12557 * target-descriptions.c (tdesc_architecture_name): Add new
12559 (tdesc_osabi_name): Likewise.
12561 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12563 * common/tdesc.c (tdesc_predefined_type): Move to here.
12564 (tdesc_named_type): Likewise.
12565 (tdesc_create_vector): Likewise.
12566 (tdesc_create_struct): Likewise.
12567 (tdesc_set_struct_size): Likewise.
12568 (tdesc_create_union): Likewise.
12569 (tdesc_create_flags): Likewise.
12570 (tdesc_create_enum): Likewise.
12571 (tdesc_add_field): Likewise.
12572 (tdesc_add_typed_bitfield): Likewise.
12573 (tdesc_add_bitfield): Likewise.
12574 (tdesc_add_flag): Likewise.
12575 (tdesc_add_enum_value): Likewise.
12576 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
12577 (struct tdesc_type_vector): Likewise.
12578 (struct tdesc_type_field): Likewise.
12579 (struct tdesc_type_with_fields): Likewise.
12580 (tdesc_create_enum): Add declaration.
12581 (tdesc_add_typed_bitfield): Likewise.
12582 (tdesc_add_enum_value): Likewise.
12583 * target-descriptions.c (tdesc_type_field): Move from here.
12584 (tdesc_type_builtin): Likewise.
12585 (tdesc_type_vector): Likewise.
12586 (tdesc_type_with_fields): Likewise.
12587 (tdesc_predefined_types): Likewise.
12588 (tdesc_named_type): Likewise.
12589 (tdesc_create_vector): Likewise.
12590 (tdesc_create_struct): Likewise.
12591 (tdesc_set_struct_size): Likewise.
12592 (tdesc_create_union): Likewise.
12593 (tdesc_create_flags): Likewise.
12594 (tdesc_create_enum): Likewise.
12595 (tdesc_add_field): Likewise.
12596 (tdesc_add_typed_bitfield): Likewise.
12597 (tdesc_add_bitfield): Likewise.
12598 (tdesc_add_flag): Likewise.
12599 (tdesc_add_enum_value): Likewise.
12600 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
12601 (tdesc_add_typed_bitfield): Likewise.
12602 (tdesc_add_enum_value): Likewise.
12604 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12606 * common/tdesc.c (tdesc_feature::accept): Move to here.
12607 (tdesc_feature::operator==): Likewise.
12608 (tdesc_create_reg): Likewise.
12609 * common/tdesc.h (tdesc_type_kind): Likewise.
12610 (struct tdesc_type): Likewise.
12611 (struct tdesc_feature): Likewise.
12612 * regformats/regdat.sh: Create a feature.
12613 * target-descriptions.c (tdesc_type_kind): Move from here.
12614 (tdesc_type): Likewise.
12615 (tdesc_type_up): Likewise.
12616 (tdesc_feature): Likewise.
12617 (tdesc_create_reg): Likewise.
12619 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12621 * Makefile.in: Add arch/tdesc.c
12622 * common/tdesc.c: New file.
12623 * common/tdesc.h (tdesc_element_visitor): Move to here.
12624 (tdesc_element): Likewise.
12625 (tdesc_reg): Likewise.
12626 (tdesc_reg_up): Likewise.
12627 * regformats/regdef.h (reg): Add offset to constructors.
12628 * target-descriptions.c (tdesc_element_visitor): Move from here.
12629 (tdesc_element): Likewise.
12630 (tdesc_reg): Likewise.
12631 (tdesc_reg_up): Likewise.
12633 2018-04-17 Tom Tromey <tom@tromey.com>
12635 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
12636 discriminant field.
12638 2018-04-17 Tom Tromey <tom@tromey.com>
12640 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
12642 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
12644 * symtab.c (print_symbol_info): Skip printing filename and line
12645 number when `last' is NULL.
12646 (symtab_symbol_info): Use empty string instead of NULL for first
12647 invocation of print_symbol_info.
12648 (rbreak_command): Pass NULL to `last' parameter of
12651 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
12653 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
12654 instead of nullptr.
12656 2018-04-16 Pedro Alves <palves@redhat.com>
12658 * MAINTAINERS (sh): Remove.
12659 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
12660 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
12661 (ALLDEPFILES): Remove sh64-tdep.c.
12662 * NEWS: Mentions that support for SH-5/SH64 is removed.
12663 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
12664 (sh*-*-openbsd*): Ditto.
12665 (sh64-*-elf*): Remove.
12667 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
12668 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
12669 * sh-tdep.c: No longer include "sh64-tdep.h".
12670 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
12671 * sh64-tdep.c, sh64-tdep.h: Remove files.
12673 2018-04-16 Pedro Alves <palves@redhat.com>
12675 * MAINTAINERS: Remove m88k.
12676 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
12677 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
12678 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
12679 * NEWS: Mention that support for m88k was removed.
12680 * configure.host (m88*-*-*): Remove support.
12681 * configure.nat (m88k-*-*): Remove support.
12682 * configure.tgt (m88*-*-openbsd*): Remove.
12683 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
12685 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
12687 * configure.tgt (x86_tobjs): New variable.
12688 (amd64_tobjs, i386_tobjs): Use it.
12690 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
12692 * symtab.c (print_symbol_info): Precede the symbol definition by
12693 the line number when available.
12694 * NEWS: Advertise this enhancement.
12696 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
12698 * NEWS (New options): announce set/show record btrace cpu.
12699 * btrace.c: Include record-btrace.h.
12700 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
12701 the vendor is unknown.
12702 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
12703 Maybe overwrite the btrace configuration's cpu.
12704 (btrace_compute_ftrace): Add cpu parameter. Update callers.
12705 (btrace_fetch): Add cpu parameter. Update callers.
12706 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
12707 Maybe overwrite the btrace configuration's cpu. Skip enabling
12708 errata workarounds if the vendor is unknown.
12709 * python/py-record-btrace.c: Include record-btrace.h.
12710 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
12711 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
12712 * record-btrace.c (record_btrace_cpu_state_kind): New.
12713 (record_btrace_cpu): New.
12714 (set_record_btrace_cpu_cmdlist): New.
12715 (record_btrace_get_cpu): New.
12716 (require_btrace_thread, record_btrace_info)
12717 (record_btrace_resume_thread): Call record_btrace_get_cpu.
12718 (cmd_set_record_btrace_cpu_none): New.
12719 (cmd_set_record_btrace_cpu_auto): New.
12720 (cmd_set_record_btrace_cpu): New.
12721 (cmd_show_record_btrace_cpu): New.
12722 (_initialize_record_btrace): Initialize set/show record btrace cpu
12724 * record-btrace.h (record_btrace_get_cpu): New.
12726 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
12728 * record.c (set_record_command): Fix typo in message.
12730 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
12732 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
12734 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
12736 * infrun.c (process_event_stop_test): Call
12737 gdbarch_in_indirect_branch_thunk.
12738 * gdbarch.sh (in_indirect_branch_thunk): New.
12739 * gdbarch.c: Regenerated.
12740 * gdbarch.h: Regenerated.
12743 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
12744 (HFILES_NO_SRCDIR): Add x86-tdep.h.
12745 (ALLDEPFILES): Add x86-tdep.c.
12746 * arch-utils.h (default_in_indirect_branch_thunk): New.
12747 * arch-utils.c (default_in_indirect_branch_thunk): New.
12748 * i386-tdep: Include x86-tdep.h.
12749 (i386_in_indirect_branch_thunk): New.
12750 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
12752 * amd64-tdep: Include x86-tdep.h.
12753 (amd64_in_indirect_branch_thunk): New.
12754 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
12756 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
12759 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
12760 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
12761 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
12764 2018-04-12 Tom Tromey <tom@tromey.com>
12766 * rust-lang.c (rust_print_struct_def): Remove univariant code.
12767 (rust_evaluate_subexp): Likewise.
12769 2018-04-12 Pedro Alves <palves@redhat.com>
12771 * procfs.c (procfs_detach): Make forward declaration's prototype
12772 match definition's protototype.
12773 (proc_get_LDT_entry): Remove stale do_cleanups call.
12775 2018-04-12 Pedro Alves <palves@redhat.com>
12777 * target.h (target_ops::to_has_exited): Delete.
12778 (target_has_exited): Delete.
12779 * target-delegates.c: Regenerate.
12781 2018-04-11 Pedro Alves <palves@redhat.com>
12783 * target.c (fileio_fh_t::t): Add comment.
12784 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
12785 (target_fileio_close): Handle a NULL target.
12786 (invalidate_fileio_fh): New.
12787 (target_close): Call it.
12788 * remote.c (remote_hostio_send_command): No longer check whether
12789 remote_desc is open.
12791 2018-04-11 Pedro Alves <palves@redhat.com>
12793 * target.c (fileio_fh_t): Make it a named struct instead of a
12795 (fileio_fh_t::is_closed): New method.
12796 (DEF_VEC_O (fileio_fh_t)): Remove.
12797 (fileio_fhandles): Now a std::vector.
12798 (is_closed_fileio_fh): Delete.
12799 (acquire_fileio_fd): Adjust. Rename parameters.
12800 (release_fileio_fd): Adjust.
12801 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
12802 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
12803 (target_fileio_close): Adjust.
12805 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
12807 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
12810 2018-04-10 Pedro Alves <palves@redhat.com>
12812 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
12813 (scoped_finish_thread_state): New class.
12814 * infcmd.c (run_command_1): Use it instead of finish_thread_state
12816 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
12817 (fetch_inferior_event, normal_stop): Likewise.
12818 * thread.c (finish_thread_state_cleanup): Delete.
12820 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12821 Pedro Alves <palves@redhat.com>
12823 * value.c: Include "selftest.h" and "common/array-view.h".
12824 (struct range) <operator ==>: New.
12825 (test_ranges_contain): New.
12826 (check_ranges_vector): New.
12827 (test_insert_into_bit_range_vector): New.
12828 (_initialize_values): Register selftests.
12829 * common/array-view.h (operator==, operator!=): New.
12831 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12833 * common/gdb_vecs.h (unordered_remove): Add overload that takes
12835 * inline-frame.c: Include <algorithm>.
12836 (struct inline_state): Add constructor.
12837 (inline_state_s): Remove.
12838 (DEF_VEC_O(inline_state_s)): Remove.
12839 (inline_states): Change type to std::vector.
12840 (find_inline_frame_state): Adjust to std::vector.
12841 (allocate_inline_frame_state): Remove.
12842 (clear_inline_frame_state): Adjust to std::vector.
12843 (skip_inline_frames): Adjust to std::vector.
12845 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12847 * tracepoint.h (struct trace_state_variable): Add constructor.
12848 <name>: Change type to std::string.
12849 * tracepoint.c (tsv_s): Remove.
12850 (DEF_VEC_O(tsv_s)): Remove.
12851 (tvariables): Change to std::vector.
12852 (create_trace_state_variable): Adjust to std::vector.
12853 (find_trace_state_variable): Likewise.
12854 (find_trace_state_variable_by_number): Likewise.
12855 (delete_trace_state_variable): Likewise.
12856 (trace_variable_command): Adjust to std::string.
12857 (delete_trace_variable_command): Likewise.
12858 (tvariables_info_1): Adjust to std::vector.
12859 (save_trace_state_variables): Likewise.
12860 (start_tracing): Likewise.
12861 (merge_uploaded_trace_state_variables): Adjust to std::vector
12863 * target.h (struct target_ops)
12864 <to_download_trace_state_variable>: Pass reference to
12865 trace_state_variable.
12866 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
12867 * target-delegates.c: Re-generate.
12868 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
12869 (mi_tsv_deleted): Likewise.
12870 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
12871 * remote.c (remote_download_trace_state_variable): Change
12872 pointer to reference and adjust.
12873 * make-target-delegates (parse_argtypes): Handle references.
12874 (write_function_header): Likewise.
12875 (munge_type): Likewise.
12877 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12879 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12880 string_view-selftests.c.
12881 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
12883 * unittests/basic_string_view/cons/char/1.cc: Likewise.
12884 * unittests/basic_string_view/cons/char/2.cc: Likewise.
12885 * unittests/basic_string_view/cons/char/3.cc: Likewise.
12886 * unittests/basic_string_view/element_access/char/1.cc:
12888 * unittests/basic_string_view/element_access/char/empty.cc:
12890 * unittests/basic_string_view/element_access/char/front_back.cc:
12892 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
12893 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
12895 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
12897 * unittests/basic_string_view/modifiers/swap/char/1.cc:
12899 * unittests/basic_string_view/operations/compare/char/1.cc:
12901 * unittests/basic_string_view/operations/compare/char/13650.cc:
12903 * unittests/basic_string_view/operations/copy/char/1.cc:
12905 * unittests/basic_string_view/operations/data/char/1.cc:
12907 * unittests/basic_string_view/operations/find/char/1.cc:
12909 * unittests/basic_string_view/operations/find/char/2.cc:
12911 * unittests/basic_string_view/operations/find/char/3.cc:
12913 * unittests/basic_string_view/operations/find/char/4.cc:
12915 * unittests/basic_string_view/operations/rfind/char/1.cc:
12917 * unittests/basic_string_view/operations/rfind/char/2.cc:
12919 * unittests/basic_string_view/operations/rfind/char/3.cc:
12921 * unittests/basic_string_view/operations/substr/char/1.cc:
12923 * unittests/basic_string_view/operators/char/2.cc: Likewise.
12924 * unittests/string_view-selftests.c: New file.
12926 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12928 * unittests/basic_string_view/capacity/1.cc: New file.
12929 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
12930 * unittests/basic_string_view/cons/char/1.cc: New file.
12931 * unittests/basic_string_view/cons/char/2.cc: New file.
12932 * unittests/basic_string_view/cons/char/3.cc: New file.
12933 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
12934 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
12935 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
12936 * unittests/basic_string_view/element_access/char/1.cc: New file.
12937 * unittests/basic_string_view/element_access/char/2.cc: New file.
12938 * unittests/basic_string_view/element_access/char/empty.cc: New file.
12939 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
12940 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
12941 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
12942 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
12943 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
12944 * unittests/basic_string_view/include.cc: New file.
12945 * unittests/basic_string_view/inserters/char/1.cc: New file.
12946 * unittests/basic_string_view/inserters/char/2.cc: New file.
12947 * unittests/basic_string_view/inserters/char/3.cc: New file.
12948 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
12949 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
12950 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
12951 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
12952 * unittests/basic_string_view/literals/types.cc: New file.
12953 * unittests/basic_string_view/literals/values.cc: New file.
12954 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
12955 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
12956 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
12957 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
12958 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
12959 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
12960 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
12961 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
12962 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
12963 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
12964 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
12965 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
12966 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
12967 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
12968 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
12969 * unittests/basic_string_view/operations/data/char/1.cc: New file.
12970 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
12971 * unittests/basic_string_view/operations/find/char/1.cc: New file.
12972 * unittests/basic_string_view/operations/find/char/2.cc: New file.
12973 * unittests/basic_string_view/operations/find/char/3.cc: New file.
12974 * unittests/basic_string_view/operations/find/char/4.cc: New file.
12975 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
12976 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
12977 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
12978 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
12979 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
12980 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
12981 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
12982 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
12983 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
12984 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
12985 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
12986 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
12987 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
12988 * unittests/basic_string_view/operators/char/2.cc: New file.
12989 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
12990 * unittests/basic_string_view/range_access/char/1.cc: New file.
12991 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
12992 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
12993 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
12994 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
12995 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
12996 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
12997 * unittests/basic_string_view/requirements/typedefs.cc: New file.
12998 * unittests/basic_string_view/typedefs.cc: New file.
12999 * unittests/basic_string_view/types/1.cc: New file.
13001 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
13003 * common/gdb_string_view.h: Remove libstdc++ implementation
13004 details, adjust to gdb reality.
13005 * common/gdb_string_view.tcc: Likewise.
13006 * cli/cli-script.c (struct string_view): Remove.
13007 (user_args) <m_args>: Change element type to gdb::string_view.
13008 (user_args::insert_args): Adjust.
13010 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
13012 * common/gdb_string_view.h: New file.
13013 * common/gdb_string_view.tcc: New file.
13015 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
13017 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
13018 * configure: Re-generate.
13020 2018-04-09 Pedro Alves <palves@redhat.com>
13022 * gdbarch.sh: Include "observable.h" instead of "observer.h".
13023 (set_target_gdbarch): Call
13024 gdb::observers::architecture_changed.notify instead of
13025 observer_notify_architecture_changed.
13027 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13029 * tracepoint.c (struct current_traceframe_cleanup): Remove.
13030 (do_restore_current_traceframe_cleanup): Remove.
13031 (restore_current_traceframe_cleanup_dtor): Remove.
13032 (make_cleanup_restore_current_traceframe): Remove.
13033 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
13035 * tracepoint.h (struct scoped_restore_current_traceframe): New.
13036 * infrun.c (fetch_inferior_event): Use
13037 scoped_restore_current_traceframe.
13039 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13041 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
13043 <n_allocated_type_units>: Remove.
13044 <all_type_units>: Change to std::vector.
13045 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
13046 to std::vector change.
13047 (dwarf2_per_objfile::get_cutu): Likewise.
13048 (dwarf2_per_objfile::get_tu): Likewise.
13049 (create_signatured_type_table_from_index): Likewise.
13050 (create_signatured_type_table_from_debug_names): Likewise.
13051 (dw2_symtab_iter_next): Likewise.
13052 (dw2_print_stats): Likewise.
13053 (dw2_expand_all_symtabs): Likewise.
13054 (dw2_expand_marked_cus): Likewise.
13055 (dw2_debug_names_iterator::next): Likewise.
13056 (dwarf2_initialize_objfile): Likewise.
13057 (add_signatured_type_cu_to_table): Likewise.
13058 (create_all_type_units): Likewise.
13059 (add_type_unit): Likewise.
13060 (struct tu_abbrev_offset): Add constructor.
13061 (build_type_psymtabs_1): Adjust to std::vector change.
13062 (print_tu_stats): Likewise.
13063 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
13064 (write_debug_names): Likewise.
13066 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13068 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
13069 Make an std::vector.
13070 <n_comp_units>: Remove.
13071 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
13072 to std::vector change.
13073 (dwarf2_per_objfile::get_cutu): Likewise.
13074 (dwarf2_per_objfile::get_cu): Likewise.
13075 (create_cus_from_index): Likewise.
13076 (create_addrmap_from_index): Likewise.
13077 (create_addrmap_from_aranges): Likewise.
13078 (dwarf2_read_index): Likewise.
13079 (dw2_find_last_source_symtab): Likewise.
13080 (dw2_map_symtabs_matching_filename): Likewise.
13081 (dw2_symtab_iter_next): Likewise.
13082 (dw2_print_stats): Likewise.
13083 (dw2_expand_all_symtabs): Likewise.
13084 (dw2_expand_symtabs_with_fullname): Likewise.
13085 (dw2_expand_marked_cus): Likewise.
13086 (dw2_map_symbol_filenames): Likewise.
13087 (create_cus_from_debug_names): Likewise.
13088 (dwarf2_read_debug_names): Likewise.
13089 (dw2_debug_names_iterator::next): Likewise.
13090 (dwarf2_initialize_objfile): Likewise.
13091 (set_partial_user): Likewise.
13092 (dwarf2_build_psymtabs_hard): Likewise.
13093 (read_comp_units_from_section): Remove arguments, adjust to
13094 std::vector change.
13095 (create_all_comp_units): Adjust to std::vector and
13096 read_comp_units_from_section changes.
13097 (dwarf2_find_containing_comp_unit): Adjust to std::vector
13099 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
13100 (psyms_seen_size): Likewise.
13101 (write_gdbindex): Likewise.
13102 (write_debug_names): Likewise.
13104 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13106 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
13107 with dwarf2_per_objfile.
13108 (create_cus_from_index): Likewise.
13109 (create_signatured_type_table_from_index): Likewise.
13110 (dwarf2_read_index): Likewise.
13111 (dwarf2_initialize_objfile): Likewise.
13112 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
13113 per_cu rather than get_dwarf2_per_objfile.
13115 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13117 * dwarf2read.h (struct signatured_type): Forward declare.
13118 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
13120 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
13121 (dw2_get_cutu): ...this.
13122 (dwarf2_per_objfile::get_cu): Rename from...
13123 (dw2_get_cu): ...this.
13124 (dwarf2_per_objfile::get_tu): New.
13125 (create_addrmap_from_index): Adjust.
13126 (create_addrmap_from_aranges): Adjust.
13127 (dw2_find_last_source_symtab): Adjust.
13128 (dw2_map_symtabs_matching_filename): Adjust.
13129 (dw2_symtab_iter_next): Adjust.
13130 (dw2_print_stats): Adjust.
13131 (dw2_expand_all_symtabs): Adjust.
13132 (dw2_expand_symtabs_with_fullname): Adjust.
13133 (dw2_expand_marked_cus): Adjust.
13134 (dw_expand_symtabs_matching_file_matcher): Adjust.
13135 (dw2_map_symbol_filenames): Adjust.
13136 (dw2_debug_names_iterator::next): Adjust.
13137 (dwarf2_initialize_objfile): Adjust.
13138 (set_partial_user): Adjust.
13139 (dwarf2_build_psymtabs_hard): Adjust.
13141 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13143 * dwarf2read.c (create_signatured_type_table_from_debug_names):
13144 Remove unused variables.
13145 (dw2_map_symtabs_matching_filename): Likewise.
13146 (dwarf2_record_block_ranges): Likewise.
13147 (dwarf2_read_addr_index): Likewise.
13148 (follow_die_offset): Likewise.
13150 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13152 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
13153 to symbol_file_add_main.
13155 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13158 * mi/mi-console.c (do_fputc_async_safe): New.
13159 (mi_console_file::write_async_safe): New.
13160 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
13161 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
13163 * ui-file.c (ui_file::putstrn): Adjust call to
13164 fputstrn_unfiltered.
13165 * utils.c (printchar): Replace do_fputs and do_fprintf
13166 parameters by do_fputc.
13167 (fputstr_filtered): Adjust call to printchar.
13168 (fputstr_unfiltered): Likewise.
13169 (fputstrn_filtered): Likewise.
13170 (fputstrn_unfiltered): Add do_fputc parameter, pass to
13172 * utils.h (do_fputc_ftype): New typedef.
13173 (fputstrn_unfiltered): Add do_fputc parameter.
13175 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
13177 * regformats/i386/i386-avx.dat: Remove.
13179 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
13182 * amd64-tdep.c (amd64_none_init_abi): New function.
13183 (amd64_x32_none_init_abi): New function.
13184 (_initialize_amd64_tdep): Register handlers for x86-64 and
13185 x64_32 with GDB_OSABI_NONE.
13186 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
13187 GDB_OSABI_NONE osabi.
13189 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
13192 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
13194 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
13195 * osabi.c (gdb_osabi_names): Add "unknown" entry.
13197 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
13199 * common/byte-vector.h (char_vector): New type.
13200 * target.h (target_read_alloc): Return
13201 gdb::optional<byte_vector>.
13202 (target_read_stralloc): Return gdb::optional<char_vector>.
13203 (target_get_osdata): Return gdb::optional<char_vector>.
13204 * target.c (target_read_alloc_1): Templatize. Replacement
13205 manual memory management with vector.
13206 (target_read_alloc): Change return type, adjust.
13207 (target_read_stralloc): Change return type, adjust.
13208 (target_get_osdata): Change return type, adjust.
13209 * auxv.c (struct auxv_info) <length>: Remove.
13210 <data>: Change type to gdb::optional<byte_vector>.
13211 (auxv_inferior_data_cleanup): Free auxv_info with delete.
13212 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
13213 (target_auxv_search): Adjust.
13214 (fprint_target_auxv): Adjust.
13215 * avr-tdep.c (avr_io_reg_read_command): Adjust.
13216 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
13217 (linux_make_corefile_notes): Adjust.
13218 * osdata.c (get_osdata): Adjust.
13219 * remote.c (remote_get_threads_with_qxfer): Adjust.
13220 (remote_memory_map): Adjust.
13221 (remote_traceframe_info): Adjust.
13222 (btrace_read_config): Adjust.
13223 (remote_read_btrace): Adjust.
13224 (remote_pid_to_exec_file): Adjust.
13225 * solib-aix.c (solib_aix_get_library_list): Adjust.
13226 * solib-dsbt.c (decode_loadmap): Don't free buf.
13227 (dsbt_get_initial_loadmaps): Adjust.
13228 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
13229 * solib-target.c (solib_target_current_sos): Adjust.
13230 * tracepoint.c (sdata_make_value): Adjust.
13231 * xml-support.c (xinclude_start_include): Adjust.
13232 (xml_fetch_content_from_file): Adjust.
13233 * xml-support.h (xml_fetch_another): Change return type.
13234 (xml_fetch_content_from_file): Change return type.
13235 * xml-syscall.c (xml_init_syscalls_info): Adjust.
13236 * xml-tdesc.c (file_read_description_xml): Adjust.
13237 (fetch_available_features_from_target): Change return type.
13238 (target_fetch_description_xml): Adjust.
13239 (target_read_description_xml): Adjust.
13241 2018-04-06 Tom Tromey <tom@tromey.com>
13243 * value.c (~value): Update.
13244 (struct value) <contents>: Now unique_xmalloc_ptr.
13245 (value_contents_bits_eq, allocate_value_contents)
13246 (value_contents_raw, value_contents_all_raw)
13247 (value_contents_for_printing, value_contents_for_printing_const)
13248 (set_value_enclosing_type): Update.
13250 2018-04-06 Tom Tromey <tom@tromey.com>
13252 * value.c (range_s): Remove typedef, VEC.
13253 (struct range): Add operator<.
13254 (range_lessthan): Remove.
13255 (ranges_contain): Change type.
13257 (struct value) <unavailable, optimized_out>: Now std::vector.
13258 (value_entirely_available)
13259 (value_entirely_covered_by_range_vector)
13260 (value_entirely_unavailable, value_entirely_optimized_out):
13262 (insert_into_bit_range_vector): Change argument type.
13263 (find_first_range_overlap): Likewise.
13264 (struct ranges_and_idx, value_contents_bits_eq)
13265 (require_not_optimized_out, require_available): Update.
13266 (ranges_copy_adjusted): Change argument types.
13267 (value_optimized_out, value_copy, value_fetch_lazy): Update.
13269 2018-04-06 Tom Tromey <tom@tromey.com>
13271 * value.c (~value): Update.
13272 (struct value) <parent>: Now a value_ref_ptr.
13273 (value_parent, set_value_parent, value_address, value_copy):
13276 2018-04-06 Tom Tromey <tom@tromey.com>
13278 * value.c (struct value): Add constructor, destructor, and member
13280 (allocate_value_lazy, value_decref): Update.
13282 2018-04-06 Tom Tromey <tom@tromey.com>
13284 * value.c (struct value) <released, next>: Remove.
13285 (all_values): Now a std::vector.
13286 (allocate_value_lazy): Update.
13287 (value_next): Remove.
13288 (value_mark, value_free_to_mark, release_value)
13289 (value_release_to_mark): Update.
13291 2018-04-06 Tom Tromey <tom@tromey.com>
13293 * value.h (fetch_subexp_value, value_release_to_mark): Update.
13294 (free_value_chain): Remove.
13295 * value.c (free_value_chain): Remove.
13296 (value_release_to_mark): Return a std::vector.
13297 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
13299 (check_condition): Update.
13300 * eval.c (fetch_subexp_value): Change "val_chain" to a
13302 * breakpoint.c (update_watchpoint): Update.
13303 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
13305 2018-04-06 Tom Tromey <tom@tromey.com>
13307 * value.h (free_all_values): Remove.
13308 * value.c (free_all_values): Remove.
13310 2018-04-06 Tom Tromey <tom@tromey.com>
13312 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
13313 (value_history_chain, value_history_count): Remove.
13314 (value_history): New global.
13315 (record_latest_value, access_value_history, show_values)
13316 (preserve_values): Update.
13318 2018-04-06 Tom Tromey <tom@tromey.com>
13320 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
13321 * varobj.c (varobj_set_display_format, varobj_set_value)
13322 (install_default_visualizer, construct_visualizer)
13323 (install_new_value, ~varobj, varobj_get_value_type)
13324 (my_value_of_variable, varobj_editable_p): Update.
13325 * c-varobj.c (c_describe_child, c_value_of_variable)
13326 (cplus_number_of_children, cplus_describe_child): Update.
13327 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
13328 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
13329 (ada_value_of_variable, ada_value_is_changeable_p): Update.
13331 2018-04-06 Tom Tromey <tom@tromey.com>
13333 * printcmd.c (last_examine_address): Change type to
13335 (do_examine, x_command): Update.
13337 2018-04-06 Tom Tromey <tom@tromey.com>
13339 * value.c (release_value): Update.
13340 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
13341 (struct bpstats) <val>: Now a value_ref_ptr.
13342 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
13343 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
13344 (~watchpoint, print_it_watchpoint, watch_command_1)
13345 (invalidate_bp_value_on_memory_change): Update.
13347 2018-04-06 Tom Tromey <tom@tromey.com>
13349 * varobj.c (varobj_clear_saved_item)
13350 (update_dynamic_varobj_children, install_new_value, ~varobj):
13352 * value.h (value_incref): Move declaration earlier.
13353 (value_decref): Rename from value_free.
13354 (struct value_ref_policy): New.
13355 (value_ref_ptr): New typedef.
13356 (struct value_deleter): Remove.
13357 (gdb_value_up): Remove typedef.
13358 (release_value): Change return type.
13359 (release_value_or_incref): Remove.
13360 * value.c (set_value_parent): Update.
13361 (value_incref): Change return type.
13362 (value_decref): Rename from value_free.
13363 (value_free_to_mark, free_all_values, free_value_chain): Update.
13364 (release_value): Return value_ref_ptr.
13365 (release_value_or_incref): Remove.
13366 (record_latest_value, set_internalvar, clear_internalvar):
13368 * stack.c (info_frame_command): Don't call value_free.
13369 * python/py-value.c (valpy_dealloc, valpy_new)
13370 (value_to_value_object): Update.
13371 * printcmd.c (do_examine): Update.
13372 * opencl-lang.c (lval_func_free_closure): Update.
13373 * mi/mi-main.c (register_changed_p): Don't call value_free.
13374 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
13375 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
13376 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
13378 * guile/scm-value.c (vlscm_free_value_smob)
13379 (vlscm_scm_from_value): Update.
13380 * frame.c (frame_register_unwind, frame_unwind_register_signed)
13381 (frame_unwind_register_unsigned, get_frame_register_bytes)
13382 (put_frame_register_bytes): Don't call value_free.
13383 * findvar.c (address_from_register): Don't call value_free.
13384 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
13385 * dwarf2loc.c (entry_data_value_free_closure)
13386 (value_of_dwarf_reg_entry, free_pieced_value_closure)
13387 (dwarf2_evaluate_loc_desc_full): Update.
13388 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
13389 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
13390 (~watchpoint, watch_command_1)
13391 (invalidate_bp_value_on_memory_change): Update.
13392 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
13394 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
13397 * warning.m4: Add -Wno-error=deprecated-register.
13398 * configure: Re-generate.
13400 2018-04-05 Tom Tromey <tom@tromey.com>
13402 * linespec.h: Remove include of "vec.h".
13404 2018-04-05 Tom Tromey <tom@tromey.com>
13406 * linespec.c (typep): Remove typedef.
13407 (find_methods, find_superclass_methods): Take a std::vector.
13408 (find_method): Use std::vector.
13410 2018-04-05 Tom Tromey <tom@tromey.com>
13412 * utils.c (compare_strings): Remove.
13413 * utils.h (compare_strings): Remove.
13414 * objc-lang.h (find_imps): Update.
13415 * objc-lang.c (find_methods): Take a std::vector.
13416 (uniquify_strings, find_imps): Likewise.
13417 * linespec.c (find_methods): Take a std::vector.
13418 (decode_objc): Use std::vector.
13419 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
13421 (find_method, find_function_symbols): Use std::vector.
13423 2018-04-05 Tom Tromey <tom@tromey.com>
13425 * completer.c (completion_tracker::completion_tracker): Remove
13427 (completion_tracker::discard_completions): Likewise.
13428 * breakpoint.c (ambiguous_names_p): Remove cast.
13429 * ada-lang.c (_initialize_ada_language): Remove cast.
13430 * utils.h (streq): Update.
13431 (streq_hash): Add new declaration.
13432 * utils.c (streq): Return bool.
13433 (streq_hash): New function.
13435 2018-04-05 Tom Tromey <tom@tromey.com>
13437 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
13438 Remove a string copy.
13440 2018-04-05 Tom Tromey <tom@tromey.com>
13442 * linespec.c (filter_results): Use std::vector.
13443 (decode_line_2, decode_line_full): Update.
13445 2018-04-05 Tom Tromey <tom@tromey.com>
13447 * linespec.c (canonical_to_fullform): Return std::string.
13448 (filter_results): Update.
13449 (struct decode_line_2_item): Add constructor.
13450 <fullform, displayform>: Now std::string.
13451 (decode_line_2_compare_items): Now a std::sort comparator.
13452 (decode_line_2): Update.
13454 2018-04-05 Tom Tromey <tom@tromey.com>
13456 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
13457 (unexpected_linespec_error): Update.
13458 (linespec_parse_basic, parse_linespec): Update.
13460 2018-04-05 Tom Tromey <tom@tromey.com>
13462 * linespec.c (linespec_parse_basic): Reindent.
13464 2018-04-05 Tom Tromey <tom@tromey.com>
13466 * minsyms.h (iterate_over_minimal_symbols): Update.
13467 * minsyms.c (iterate_over_minimal_symbols): Take a
13468 gdb::function_view.
13469 * linespec.c (struct collect_minsyms): Remove.
13470 (compare_msyms): Now a std::sort comparator.
13471 (add_minsym): Add parameters.
13472 (search_minsyms_for_name): Update. Use std::vector.
13474 2018-04-03 Tom Tromey <tom@tromey.com>
13476 * mipsread.c (read_alphacoff_dynamic_symtab): Use
13479 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
13481 * MAINTAINERS (Write After Approval): Add Weimin Pan.
13483 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
13486 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
13487 printing static type.
13489 2018-04-01 Tom Tromey <tom@tromey.com>
13491 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
13492 (rs6000_xfer_shared_libraries): Update.
13494 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
13496 * common/gdb_vecs.h (char_ptr): Remove.
13497 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
13499 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
13501 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
13503 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
13505 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
13507 * tracepoint.h (struct uploaded_tp): Initialize fields.
13508 <actions, step_actions, cmd_strings>: Change type to
13509 std::vector<char *>.
13510 * tracepoint.c (get_uploaded_tp): Allocate with new.
13511 (free_uploaded_tps): Free with delete.
13512 (parse_tracepoint_definition): Adjust to std::vector change.
13513 * breakpoint.c (read_uploaded_action): Likewise.
13514 (create_tracepoint_from_upload): Likewise.
13515 * ctf.c (ctf_write_uploaded_tp): Likewise.
13516 (SET_ARRAY_FIELD): Likewise.
13517 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
13519 2018-03-30 Tom Tromey <tom@tromey.com>
13521 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
13523 (svr4_keep_data_in_core): Update.
13524 (svr4_read_so_list): Update.
13526 2018-03-30 Tom Tromey <tom@tromey.com>
13528 * windows-nat.c (handle_output_debug_string, handle_exception):
13530 * target.h (target_read_string): Update.
13531 * target.c (target_read_string): Change "string" to
13532 unique_xmalloc_ptr.
13533 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
13535 * solib-frv.c (frv_current_sos): Update.
13536 * solib-dsbt.c (dsbt_current_sos): Update.
13537 * solib-darwin.c (darwin_current_sos): Update.
13538 * linux-thread-db.c (inferior_has_bug): Update.
13539 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
13540 Update. Remove alloca.
13541 * ada-lang.c (ada_main_name): Update.
13543 2018-03-30 Tom Tromey <tom@tromey.com>
13545 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
13546 (struct dwo_file_deleter): New.
13547 (dwo_file_up): New typedef.
13548 (open_and_init_dwo_file): Use dwo_file_up.
13549 (free_dwo_file_cleanup): Remove.
13551 2018-03-30 Tom Tromey <tom@tromey.com>
13553 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
13554 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
13556 2018-03-30 Tom Tromey <tom@tromey.com>
13558 * dwarf2read.c (class free_cached_comp_units): New class.
13559 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
13560 (free_cached_comp_units): Remove function.
13562 2018-03-30 Tom Tromey <tom@tromey.com>
13564 * utils.h (make_cleanup_unpush_target): Remove.
13565 * inf-ptrace.c (struct target_unpusher): New.
13566 (target_unpush_up) New typedef.
13567 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
13569 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
13571 2018-03-27 Tom Tromey <tom@tromey.com>
13573 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
13575 2018-03-27 Pedro Alves <palves@redhat.com>
13576 Tom Tromey <tom@tromey.com>
13578 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
13579 destructor. Now a class.
13580 (gdb_readline_wrapper_cleanup): Remove function.
13581 (gdb_readline_wrapper): Remove cleanups.
13583 2018-03-27 Tom Tromey <tom@tromey.com>
13585 * typeprint.h (struct type_print_options) <local_typedefs,
13586 global_typedefs>: Remove "struct" keyword.
13587 (class typedef_hash_table): New class.
13588 (recursively_update_typedef_hash, add_template_parameters)
13589 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
13590 (find_typedef_in_hash): Don't declare.
13591 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
13592 (typedef_hash_table::recursively_update): Rename from
13593 recursively_update_typedef_hash. Now a member.
13594 (typedef_hash_table::add_template_parameters): Rename from
13595 add_template_parameters. Now a member.
13596 (typedef_hash_table::typedef_hash_table): Now a constructor;
13597 rename from create_typedef_hash.
13598 (typedef_hash_table::~typedef_hash_table): Now a destructor;
13599 rename from free_typedef_hash.
13600 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
13601 (do_free_global_table): Remove.
13602 (typedef_hash_table::typedef_hash_table): New constructor; renamed
13603 from copy_type_recursive.
13604 (create_global_typedef_table): Remove.
13605 (typedef_hash_table::find_global_typedef): Now a member of
13606 typedef_hash_table.
13607 (typedef_hash_table::find_typedef): Rename from
13608 find_typedef_in_hash; now a member.
13609 (whatis_exp): Update.
13610 * extension.h (struct ext_lang_type_printers): Add constructor and
13612 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
13614 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
13615 Now a constructor; rename from start_ext_lang_type_printers.
13616 (ext_lang_type_printers): Now a destructor; rename from
13617 free_ext_lang_type_printers.
13618 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
13620 (c_type_print_base_struct_union): Update. Remove cleanups.
13622 2018-03-27 Tom Tromey <tom@tromey.com>
13624 * dwarf-index-write.c: Include <cmath>.
13626 2018-03-27 Joel Brobecker <brobecker@adacore.com>
13628 * NEWS: Add entry describing new "set|show varsize-limit" command.
13629 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
13631 * printcmd.c (_initialize_printcmd): Add "set var" alias of
13634 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
13636 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
13637 dwarf-index-write.c
13638 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
13639 * dwarf-index-common.c: New file.
13640 * dwarf-index-common.h: New file.
13641 * dwarf-index-write.c: New file.
13642 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
13643 (struct dwarf2_section_info): Move from here.
13644 (dwarf2_section_info_def): Likewise.
13645 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
13646 (offset_type): Likewise.
13647 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
13648 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
13649 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
13650 (byte_swap): Likewise.
13651 (MAYBE_SWAP): Likewise.
13652 (dwarf2_per_cu_ptr): Likewise.
13653 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
13654 (struct tu_stats): Likewise.
13655 (struct dwarf2_per_objfile): Likewise.
13656 (struct dwarf2_per_cu_data): Likewise.
13657 (struct signatured_type): Likewise.
13658 (sig_type_ptr): Likewise.
13659 (DEF_VEC_P (sig_type_ptr)): Likewise.
13660 (INDEX4_SUFFIX): Likewise.
13661 (INDEX5_SUFFIX): Likewise.
13662 (DEBUG_STR_SUFFIX): Likewise.
13663 (dwarf2_read_section): Make non-static.
13664 (mapped_index_string_hash): Move from here.
13665 (dwarf5_djb_hash): Likewise.
13666 (file_write): Likewise.
13667 (class data_buf): Likewise.
13668 (struct symtab_index_entry): Likewise.
13669 (struct mapped_symtab): Likewise.
13670 (find_slot): Likewise.
13671 (hash_expand): Likewise.
13672 (add_index_entry): Likewise.
13673 (uniquify_cu_indices): Likewise.
13674 (class c_str_view): Likewise.
13675 (class c_str_view_hasher): Likewise.
13676 (class vector_hasher): Likewise.
13677 (write_hash_table): Likewise.
13678 (psym_index_map): Likewise.
13679 (struct addrmap_index_data): Likewise.
13680 (add_address_entry): Likewise.
13681 (add_address_entry_worker): Likewise.
13682 (write_address_map): Likewise.
13683 (symbol_kind): Likewise.
13684 (write_psymbols): Likewise.
13685 (struct signatured_type_index_data): Likewise.
13686 (write_one_signatured_type): Likewise.
13687 (recursively_count_psymbols): Likewise.
13688 (recursively_write_psymbols): Likewise.
13689 (class debug_names): Likewise.
13690 (check_dwarf64_offsets): Likewise.
13691 (psyms_seen_size): Likewise.
13692 (write_gdbindex): Likewise.
13693 (write_debug_names): Likewise.
13694 (assert_file_size): Likewise.
13695 (write_psymtabs_to_index): Likewise.
13696 (save_gdb_index_command): Likewise.
13697 (_initialize_dwarf2_read): Don't register the "save gdb-index"
13699 * dwarf2read.h: New file.
13701 2018-03-27 Joel Brobecker <brobecker@adacore.com>
13704 * dwarf2read.c (dwarf2_physname): Do not return the demangled
13705 symbol name if the CU's language stores symbol names in linkage
13707 * language.h (struct language_defn)
13708 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
13709 all instances of this struct.
13711 2018-03-26 Tom Tromey <tom@tromey.com>
13713 * stack.c (backtrace_command_1): Remove verbose code.
13715 2018-03-26 Tom Tromey <tom@tromey.com>
13717 * python/py-framefilter.c (py_print_type): Don't catch
13718 exceptions. Return void.
13719 (py_print_value): Likewise.
13720 (py_print_single_arg): Likewise.
13721 (enumerate_args): Don't catch exceptions.
13722 (py_print_args): Likewise.
13723 (py_print_frame): Likewise.
13724 (gdbpy_apply_frame_filter): Catch exceptions here.
13726 2018-03-26 Tom Tromey <tom@tromey.com>
13728 * stack.c (_initialize_stack): Remove trailing newlines from help
13729 text. Add "Usage" line to "backtrace" help.
13731 2018-03-26 Tom Tromey <tom@tromey.com>
13734 * python/py-framefilter.c (py_print_args): Call wrap_hint.
13736 2018-03-26 Tom Tromey <tom@tromey.com>
13738 * python/py-framefilter.c (py_print_single_arg): Return
13739 EXT_LANG_BT_ERROR from catch.
13741 2018-03-26 Tom Tromey <tom@tromey.com>
13743 PR backtrace/15584:
13744 * stack.c (backtrace_command_1): Move some code into no-filters
13747 2018-03-26 Tom Tromey <tom@tromey.com>
13749 * python/py-framefilter.c (throw_quit_or_print_exception): New
13751 (gdbpy_apply_frame_filter): Use it.
13753 2018-03-26 Tom Tromey <tom@tromey.com>
13756 * python/py-framefilter.c (py_print_type, py_print_value)
13757 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
13760 2018-03-26 Tom Tromey <tom@tromey.com>
13762 * python/py-framefilter.c (enumerate_args): Use
13763 gdb::unique_xmalloc_ptr.
13765 2018-03-26 Tom Tromey <tom@tromey.com>
13767 * python/py-framefilter.c (py_print_frame): Return
13769 (gdbpy_apply_frame_filter): Update comment.
13770 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
13772 <EXT_LANG_BT_NO_FILTERS>: Change value.
13774 2018-03-26 Tom Tromey <tom@tromey.com>
13776 PR backtrace/15582:
13777 * stack.c (backtrace_command): Parse "hide" argument.
13778 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
13779 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
13782 2018-03-26 Tom Tromey <tom@tromey.com>
13784 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
13786 (backtrace_command): Remove "fulltrace", add "flags".
13788 2018-03-26 Tom Tromey <tom@tromey.com>
13790 * stack.c (backtrace_command): Rewrite command line parsing.
13792 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
13794 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
13796 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
13798 * filename-seen-cache.h: Add include guard.
13800 2018-03-26 Keith Seitz <keiths@redhat.com>
13802 * symfile.c (place_section): Remove "struct" from section_addr_info
13804 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
13805 "struct" keyword from section_addr_info.
13807 2018-03-26 Alan Hayward <alan.hayward@arm.com>
13809 * regformats/regdef.h (reg): Add constructors.
13811 2018-03-25 Pedro Alves <palves@redhat.com>
13813 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
13814 if then/else bodies in var_func_name extraction.
13816 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
13818 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
13819 lookup_minimal_symbol() to find symbol entry.
13820 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
13822 2018-03-23 Keith Seitz <keiths@redhat.com>
13825 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
13826 nested type definitions for C++, too.
13828 2018-03-23 Tom Tromey <tom@tromey.com>
13830 * machoread.c (struct oso_el): Add a constructor. Don't define as
13832 (macho_register_oso): Remove.
13833 (macho_symtab_read): Take a std::vector.
13834 (oso_el_compare_name): Now a std::sort comparator.
13835 (macho_symfile_read_all_oso): Take a std::vector.
13836 (macho_symfile_read): Use std::vector. Remove cleanups.
13838 2018-03-22 Tom Tromey <tom@tromey.com>
13840 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
13841 (record_full_goto_bookmark): Use std::string.
13843 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
13846 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
13849 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
13851 * rs6000-tdep.c (store_insn_p): New function.
13852 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
13853 and cr_reg to their unshifted values. Use store_insn_p to
13854 match LR saves using either R1 or fdata->alloca_reg. Use
13855 store_insn_p to match CR saves. Set alloca_reg_offset
13856 when alloca_reg and framep are set. Remove lr_reg shift
13857 when assigning to fdata->lr_register.
13859 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
13861 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
13862 command line args instead of emitting a warning.
13864 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
13866 * tracepoint.h (struct static_tracepoint_marker): Initialize
13867 fields, define default constructor, move constructor and move
13868 assignment, disable the rest.
13869 <str_id, extra>: Make std::string.
13870 (release_static_tracepoint_marker): Remove.
13871 (free_current_marker): Remove.
13872 * tracepoint.c (free_current_marker): Remove.
13873 (parse_static_tracepoint_marker_definition): Adjust to
13874 std::string, use new hex2str overload.
13875 (release_static_tracepoint_marker): Remove.
13876 (print_one_static_tracepoint_marker): Get marker by reference
13877 and adjust to std::string.
13878 (info_static_tracepoint_markers_command): Adjust to std::vector
13880 * target.h (static_tracepoint_marker_p): Remove typedef.
13881 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
13882 (struct target_ops) <to_static_tracepoint_marker_at>: Return
13884 <to_static_tracepoint_markers_by_strid>: Return std::vector.
13886 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
13887 (target_debug_print_std_vector_static_tracepoint_marker): New.
13888 (target_debug_print_struct_static_tracepoint_marker_p): Rename
13890 (target_debug_print_static_tracepoint_marker_p): ... this.
13891 * target-delegates.c: Re-generate.
13892 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
13894 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
13895 (decode_static_tracepoint_spec): Adjust to std::vector.
13896 (tracepoint_print_one_detail): Adjust to std::string.
13897 (strace_marker_decode_location): Adjust to std::string.
13898 (update_static_tracepoint): Adjust to std::string, remove call
13899 to release_static_tracepoint_marker.
13900 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
13901 Adjust to std::vector.
13902 * remote.c (remote_static_tracepoint_marker_at): Return bool.
13903 (remote_static_tracepoint_markers_by_strid): Adjust to
13905 * common/rsp-low.h (hex2str): New overload with explicit count
13907 * common/rsp-low.c (hex2str): New overload with explicit count
13909 * unittests/rsp-low-selftests.c (test_hex2str): New function.
13910 (_initialize_rsp_low_selftests): Add test_hex2str test.
13911 * unittests/tracepoint-selftests.c
13912 (test_parse_static_tracepoint_marker_definition): Adjust to
13915 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
13917 * tracepoint.c (parse_static_tracepoint_marker_definition):
13918 Consider case where the definition is followed by more
13920 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13921 tracepoint-selftests.c.
13922 * unittests/tracepoint-selftests.c: New.
13924 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
13926 * MAINTAINERS (Write After Approval): Add Pedro Franco de
13929 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
13931 * symtab.c (find_pc_sect_line): fixed indentation.
13933 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
13935 * symtab.c (find_pc_sect_line): now uses binary search.
13937 2018-03-19 Tom Tromey <tom@tromey.com>
13939 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
13940 "IDENT" production.
13942 2018-03-19 Pedro Alves <palves@redhat.com>
13943 Tom Tromey <tom@tromey.com>
13945 * unittests/observable-selftests.c: New file.
13946 * common/observable.h: New file.
13947 * observable.h: New file.
13948 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
13949 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
13950 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
13951 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
13952 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
13953 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
13954 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
13955 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
13956 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
13957 python/py-breakpoint.c, python/py-finishbreakpoint.c,
13958 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
13959 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
13960 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
13961 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
13962 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
13963 tui/tui-interp.c, valops.c: Update all users.
13964 * tui/tui-hooks.c (tui_bp_created_observer)
13965 (tui_bp_deleted_observer, tui_bp_modified_observer)
13966 (tui_inferior_exit_observer, tui_before_prompt_observer)
13967 (tui_normal_stop_observer, tui_register_changed_observer):
13969 (tui_observers_token): New global.
13970 (attach_or_detach, tui_attach_detach_observers): New functions.
13971 (tui_install_hooks, tui_remove_hooks): Use
13972 tui_attach_detach_observers.
13973 * record-btrace.c (record_btrace_thread_observer): Remove.
13974 (record_btrace_thread_observer_token): New global.
13975 * observer.sh: Remove.
13976 * observer.c: Rename to observable.c.
13977 * observable.c (namespace gdb_observers): Define new objects.
13978 (observer_debug): Move into gdb_observers namespace.
13979 (struct observer, struct observer_list, xalloc_observer_list_node)
13980 (xfree_observer_list_node, generic_observer_attach)
13981 (generic_observer_detach, generic_observer_notify): Remove.
13982 (_initialize_observer): Update.
13983 Don't include observer.inc.
13984 * Makefile.in (generated_files): Remove observer.h, observer.inc.
13985 (clean mostlyclean): Likewise.
13986 (observer.h, observer.inc): Remove targets.
13987 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
13988 (COMMON_SFILES): Use observable.c, not observer.c.
13989 * .gitignore: Remove observer.h.
13991 2018-03-18 Tom Tromey <tom@tromey.com>
13993 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
13995 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
13997 2018-03-17 Tom Tromey <tom@tromey.com>
13999 * auto-load.c (auto_load_objfile_script_1): Use std::string.
14001 2018-03-17 Tom Tromey <tom@tromey.com>
14003 * target.c (class scoped_target_fd): New.
14004 (target_fileio_close_cleanup): Remove.
14005 (target_fileio_read_alloc_1): Use scoped_target_fd.
14007 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
14009 * silent-rules.mk: New.
14010 * Makefile.in: Include silent-rules.mk
14011 (srcdir, VPATH, top_srcdir): Move up.
14012 (COMPILE): Add ECHO_CXX.
14013 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
14014 (init.c): Add ECHO_INIT_C.
14015 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
14016 (version.c): Add ECHO_GEN.
14017 (printcmd.o): Add ECHO_CXX.
14018 (target-float.o): Add ECHO_CXX.
14019 (ada-exp.o): Add ECHO_CXX.
14020 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
14021 (insight$(EXEEXT)): Add ECHO_CXXLD.
14022 * gnulib/configure.ac: Add AM_SILENT_RULES.
14023 * gnulib/aclocal.m4: Re-generate.
14024 * gnulib/configure: Re-generate.
14025 * gnulib/import/Makefile.in: Re-generate.
14027 2018-03-16 Tom Tromey <tom@tromey.com>
14029 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
14030 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
14031 * utils.c (do_free_section_addr_info)
14032 (make_cleanup_free_section_addr_info): Remove.
14033 * symfile.h (struct other_sections): Add constructor.
14034 (struct section_addr_info): Remove.
14035 (section_addr_info): New typedef.
14036 (struct sym_fns) <sym_offsets>: Change type of parameter.
14037 (build_section_addr_info_from_objfile)
14038 (relative_addr_info_to_section_offsets, addr_info_make_relative)
14039 (default_symfile_offsets, symbol_file_add)
14040 (symbol_file_add_from_bfd)
14041 (build_section_addr_info_from_section_table): Update.
14042 (alloc_section_addr_info, free_section_addr_info): Don't declare.
14043 * symfile.c (alloc_section_addr_info): Remove.
14044 (build_section_addr_info_from_section_table): Change return type.
14046 (build_section_addr_info_from_bfd)
14047 (build_section_addr_info_from_objfile): Likewise.
14048 (free_section_addr_info): Remove.
14049 (relative_addr_info_to_section_offsets): Change type of "addrs".
14050 (addrs_section_compar): Now a std::sort comparator.
14051 (addrs_section_sort): Change return type.
14052 (addr_info_make_relative): Change type of "addrs". Update.
14053 (default_symfile_offsets, syms_from_objfile_1)
14054 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
14055 (symbol_file_add_separate): Update.
14056 (symbol_file_add): Change type of "addrs". Update.
14057 (add_symbol_file_command): Update. Remove cleanups.
14058 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
14060 * symfile-debug.c (debug_sym_offsets): Change type of "info".
14061 * solib.c (solib_read_symbols): Update.
14062 * objfiles.c (objfile_relocate): Update. Remove cleanups.
14063 * machoread.c (macho_symfile_offsets): Update.
14064 * jit.c (jit_bfd_try_read_symtab): Update.
14066 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
14068 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
14069 unittests/utils-selftests.c.
14070 * unittests/utils-selftests.c: New file.
14072 2018-03-14 Tom Tromey <tom@tromey.com>
14075 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
14078 2018-03-14 Tom Tromey <tom@tromey.com>
14081 * printcmd.c (printf_pointer): Allow "-" in format.
14083 2018-03-14 Tom Tromey <tom@tromey.com>
14085 * printcmd.c (_initialize_printcmd): Add usage to printf.
14087 2018-03-14 Yao Qi <qiyao@sourceware.org>
14089 * MAINTAINERS: Update my email address.
14091 2018-03-13 Tom Tromey <tom@tromey.com>
14093 * machoread.c (macho_check_dsym): Change filenamep to a
14095 (macho_symfile_read): Update.
14096 * symfile.c (load_command): Use std::string.
14098 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
14100 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
14101 to error message string.
14102 (riscv_register_name): Use xsnprintf instead of sprintf.
14103 (riscv_insn::fetch_instruction): Use gdb_assert instead of
14105 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
14107 (riscv_push_dummy_call): Likewise.
14109 2018-03-12 Tom Tromey <tom@tromey.com>
14111 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
14112 Use gdb::byte_vector.
14113 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
14115 2018-03-12 Yao Qi <yao.qi@linaro.org>
14117 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
14118 parameter type to readable_regcache.
14119 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
14122 2018-03-11 Tom Tromey <tom@tromey.com>
14124 * dwarf2read.c (struct nextfield): Add initializers.
14125 (struct nextfnfield): Remove.
14126 (struct fnfieldlist): Add initializers. Remove "length" and
14127 "head", use std::vector.
14128 (struct decl_field_list): Remove.
14129 (struct field_info): Add initializers.
14130 <fields, baseclasses>: Now std::vector.
14131 <nbaseclasses, nfnfields, typedef_field_list_count,
14132 nested_types_list_count>: Remove.
14133 (dwarf2_add_field, dwarf2_add_type_defn)
14134 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
14135 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
14136 (process_structure_scope): Update.
14138 2018-03-11 Tom Tromey <tom@tromey.com>
14140 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
14141 for use by std::sort.
14142 (build_type_psymtabs_1): Use std::vector.
14144 2018-03-09 Eli Zaretskii <eliz@gnu.org>
14146 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
14147 and LIBMPFR in the printed configuration.
14149 2018-03-08 Tom Tromey <tom@tromey.com>
14151 * source.c (get_filename_and_charpos): Use scoped_fd.
14152 * nto-procfs.c (procfs_open_1): Use scoped_fd.
14153 (procfs_pidlist): Likewise.
14154 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
14155 (iterate_over_mappings): Likewise.
14157 2018-03-08 Tom Tromey <tom@tromey.com>
14159 * infcall.c (struct call_return_meta_info)
14160 <stack_temporaries_enabled>: Remove.
14161 (get_call_return_value, call_function_by_hand_dummy): Update.
14162 * thread.c (disable_thread_stack_temporaries): Remove.
14163 (enable_thread_stack_temporaries): Remove.
14164 (thread_stack_temporaries_enabled_p): Return bool.
14165 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
14166 (get_last_thread_stack_temporary): Update.
14167 * eval.c (evaluate_subexp): Update.
14168 * gdbthread.h (class enable_thread_stack_temporaries): Now a
14169 class, not a function.
14170 (value_ptr, value_vec): Remove typedefs.
14171 (class thread_info) <stack_temporaries_enabled>: Now bool.
14172 <stack_temporaries>: Now a std::vector.
14173 (thread_stack_temporaries_enabled_p)
14174 (value_in_thread_stack_temporaries): Return bool.
14176 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
14178 * remote.c (putpkt_binary): Fix omitted bytes reporting.
14179 (getpkt_or_notif_sane_1): Likewise.
14181 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
14183 * build-id.c (build_id_to_debug_bfd): Use std::string.
14185 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
14187 * build-id.c (find_separate_debug_file_by_buildid): Return
14189 * build-id.h (find_separate_debug_file_by_buildid): Return
14191 * coffread.c (coff_symfile_read): Adjust to std::string.
14192 * elfread.c (elf_symfile_read): Adjust to std::string.
14193 * symfile.c (separate_debug_file_exists): Change parameter to
14195 (find_separate_debug_file): Return std::string.
14196 (find_separate_debug_file_by_debuglink): Return std::string.
14197 * symfile.h (find_separate_debug_file_by_debuglink): Return
14200 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
14202 * common/xml-utils.c (xml_escape_text): Move code to...
14203 (xml_escape_text_append): ... this new function.
14204 * common/xml-utils.h (xml_escape_text_append): New declaration.
14205 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
14207 (_initialize_xml_utils): register test_xml_escape_text_append as
14210 2018-03-07 Alan Hayward <alan.hayward@arm.com>
14212 * defs.h: Remove MAX_REGISTER_SIZE.
14213 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
14215 * python/py-unwind.c (pyuw_sniffer): Likewise.
14217 2018-03-07 Tom Tromey <tom@tromey.com>
14219 * linux-tdep.c (linux_info_proc): Update.
14220 * target.h (struct target_ops) <to_fileio_readlink>: Return
14222 (target_fileio_readlink): Return optional<string>.
14223 * remote.c (remote_hostio_readlink): Return optional<string>.
14224 * inf-child.c (inf_child_fileio_readlink): Return
14226 * target.c (target_fileio_readlink): Return optional<string>.
14228 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
14230 * regcache.c (cooked_read_test): Add riscv to the list of
14231 architectures that have a save_reggroup.
14233 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
14235 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
14236 value is not a dynamic class object.
14238 2018-03-06 Tom Tromey <tom@tromey.com>
14240 * rust-exp.y: Formatting fixes.
14242 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14244 * riscv-tdep.c (riscv_register_name): Remove target description
14246 (riscv_gdbarch_init): Remove target description check.
14248 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14250 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
14252 * riscv-tdep.h: Likewise.
14254 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14256 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
14257 (riscv_pseudo_register_write): Delete.
14258 (riscv_gdbarch_init): Remove all use of pseudo registers.
14260 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
14262 * record-btrace.c (btrace_print_lines): Replace cleanup
14263 parameter with RAII equivalents.
14264 (btrace_insn_history): Replace cleanup with RAII equivalents.
14265 * ui-out.h (make_cleanup_ui_out_list_begin_end,
14266 make_cleanup_ui_out_tuple_begin_end): Remove.
14267 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
14268 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
14269 make_cleanup_ui_out_list_begin_end): Remove.
14271 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
14273 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
14274 parameter types to std::vector. Use bool.
14275 (record_btrace_wait): Replace VEC(tp_t) with
14276 std::vector<thread_info *>.
14277 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
14279 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
14281 * record-btrace.c (record_btrace_disable_callback): Remove.
14282 (struct scoped_btrace_disable): New.
14283 (record_btrace_open): Use scoped_btrace_disable.
14285 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14287 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
14288 reading values from registers.
14290 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14292 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
14295 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14297 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
14298 change parameter type. Use GDB's print functions, and use
14299 core_addr_to_string where appropriate.
14300 (riscv_push_dummy_call): Use core_addr_to_string where
14301 appropriate, update call to riscv_print_arg_location, and reindent
14303 (riscv_return_value): Update call to riscv_print_arg_location.
14305 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14306 Tim Newsome <tim@sifive.com>
14307 Albert Ou <a0u@eecs.berkeley.edu>
14308 Darius Rad <darius@bluespec.com>
14310 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
14311 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
14312 (ALLDEPFILES): Add riscv-tdep.c
14313 * configure.tgt: Add riscv support.
14314 * riscv-tdep.c: New file.
14315 * riscv-tdep.h: New file.
14316 * NEWS: Mention new target.
14317 * MAINTAINERS: Add entry for riscv.
14319 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
14321 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
14322 fields within aggregates.
14324 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
14326 * record-btrace.c (btrace_print_lines): Change type of flags to
14327 gdb_disassembly_flags.
14329 2018-03-04 John Baldwin <jhb@FreeBSD.org>
14331 * fbsd-nat.c: Include "inf-ptrace.h".
14332 (USE_SIGTRAP_SIGINFO): Conditionally define.
14333 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
14334 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
14335 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
14337 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
14339 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
14341 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
14342 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
14343 "supports_stopped_by_hw_breakpoint" target methods.
14345 2018-03-04 John Baldwin <jhb@FreeBSD.org>
14347 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
14348 * fbsd-nat.c (debug_fbsd_nat): New variable.
14349 (show_fbsd_nat_debug): New function.
14350 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
14351 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
14353 2018-03-04 John Baldwin <jhb@FreeBSD.org>
14355 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
14356 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
14358 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
14359 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
14362 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
14364 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
14365 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
14367 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
14369 * charset.c (struct charset_vector): New.
14370 (charsets): Change type to charset_vector.
14371 (find_charset_names): Adjust.
14373 (_initialize_charset): Adjust.
14375 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
14377 * progspace.h (struct program_space) <deleted_solibs>: Change
14378 type to std::vector<std::string>.
14379 * progspace.c (clear_program_space_solib_cache): Adjust.
14380 * breakpoint.c (print_solib_event): Adjust.
14381 (check_status_catch_solib): Adjust.
14382 * solib.c (update_solib_list): Adjust.
14383 * ui-out.h (class ui_out) <field_string>: New overload.
14384 * ui-out.c (ui_out::field_string): New overload.
14386 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
14388 * progspace.h (struct program_space): Add constructor and
14389 destructor, initialize fields.
14390 (add_program_space): Remove.
14391 * progspace.c (add_program_space): Rename to...
14392 (program_space::program_space): ... this.
14393 (release_program_space): Rename to...
14394 (program_space::~program_space): ... this.
14395 (delete_program_space): Use delete to delete program_space.
14396 (initialize_progspace): Use new to allocate program_space.
14397 * inferior.c (add_inferior_with_spaces): Likewise.
14398 (clone_inferior_command): Likewise.
14399 * infrun.c (follow_fork_inferior): Likewise.
14400 (handle_vfork_child_exec_or_exit): Likewise.
14402 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
14404 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
14405 (delim_string_to_char_ptr_vec): Return std::vector of
14406 gdb::unique_xmalloc_ptr.
14407 (dirnames_to_char_ptr_vec_append): Take std::vector of
14408 gdb::unique_xmalloc_ptr.
14409 (dirnames_to_char_ptr_vec): Return std::vector of
14410 gdb::unique_xmalloc_ptr.
14411 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
14412 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
14413 (delim_string_to_char_ptr_vec): Return an std::vector of
14414 gdb::unique_xmalloc_ptr, adjust the code.
14415 (dirnames_to_char_ptr_vec_append): Take an std::vector of
14416 gdb::unique_xmalloc_ptr, adjust the code.
14417 (dirnames_to_char_ptr_vec): Return an std::vector of
14418 gdb::unique_xmalloc_ptr, adjust the code.
14419 * auto-load.c (auto_load_safe_path_vec): Change type to
14420 std::vector of gdb::unique_xmalloc_ptr.
14421 (auto_load_expand_dir_vars): Return an std::vector of
14422 gdb::unique_xmalloc_ptr, adjust the code.
14423 (auto_load_safe_path_vec_update): Adjust.
14424 (filename_is_in_auto_load_safe_path_vec): Adjust.
14425 (auto_load_objfile_script_1): Adjust.
14426 * build-id.c (build_id_to_debug_bfd): Adjust.
14427 * linux-thread-db.c (thread_db_load_search): Adjust.
14428 * source.c (add_path): Adjust.
14430 * symfile.c (find_separate_debug_file): Adjust.
14431 * utils.c (do_free_char_ptr_vec): Remove.
14432 (make_cleanup_free_char_ptr_vec): Remove.
14434 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
14437 * common/pathstuff.c: Conditionally include "<windows.h>".
14439 2018-03-01 Georg Sauthoff <mail@georg.so>
14442 * gcore.in: Quote variables and switch interpreter to bash.
14444 2018-03-01 Tom Tromey <tom@tromey.com>
14446 * dwarf2read.c (alloc_discriminant_info): Fix default_index
14447 assertion. Add assertion for discriminant_index.
14448 (quirk_rust_enum): Use correct base type name in univariant case.
14450 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
14452 * record.c (get_call_history_modifiers): Return a
14453 record_print_flags.
14454 (cmd_record_call_history): Adjust.
14455 * record-btrace.c (record_btrace_call_history): Adjust.
14456 (record_btrace_call_history_range): Adjust.
14457 (record_btrace_call_history_from): Adjust.
14458 * target-debug.h (target_debug_print_record_print_flags): New.
14459 * target-delegates.c: Re-generate.
14460 * target.c (target_call_history): Change flags type.
14461 (target_call_history_from): Likewise.
14462 (target_call_history_range): Likewise.
14463 * target.h (struct target_ops) <target_call_history>: Likewise.
14464 (target_call_history_from): Likewise.
14465 (target_call_history_range): Likewise.
14467 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
14468 Simon Marchi <simon.marchi@polymtl.ca>
14470 * common/common-utils.c: Include "sys/stat.h".
14471 (is_regular_file): Move here from "source.c"; change return
14473 * common/common-utils.h (is_regular_file): New prototype.
14474 * common/pathstuff.c (contains_dir_separator): New function.
14475 * common/pathstuff.h (contains_dir_separator): New prototype.
14476 * source.c: Don't include "sys/stat.h".
14477 (is_regular_file): Move to "common/common-utils.c".
14479 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
14481 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
14482 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
14483 * auto-load.c: Include "common/pathstuff.h".
14484 * common/common-def.h (current_directory): Move here.
14485 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
14487 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
14489 * common/pathstuff.c: New file.
14490 * common/pathstuff.h: New file.
14491 * compile/compile.c: Include "common/pathstuff.h".
14492 * defs.h (current_directory): Move to "common/common-defs.h".
14493 * dwarf2read.c: Include "common/pathstuff.h".
14494 * exec.c: Likewise.
14495 * guile/scm-safe-call.c: Likewise.
14496 * linux-thread-db.c: Likewise.
14497 * main.c: Likewise.
14498 * nto-tdep.c: Likewise.
14499 * objfiles.c: Likewise.
14500 * source.c: Likewise.
14501 * symtab.c: Likewise.
14502 * utils.c: Include "common/pathstuff.h".
14503 (gdb_realpath): Move to "common/pathstuff.c".
14504 (gdb_realpath_keepfile): Likewise.
14505 (gdb_abspath): Likewise.
14506 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
14507 (gdb_realpath_keepfile): Likewise.
14508 (gdb_abspath): Likewise.
14510 2018-02-28 John Baldwin <jhb@FreeBSD.org>
14512 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
14513 wildcard process pid for super_resume for kernels with a
14516 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
14518 * compile/compile.c (get_args): Add additional comments
14519 explaining function.
14521 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
14522 Tom Tromey <tom@tromey.com>
14524 * target.h (memory_write_request_s): Remove typedef. Don't define
14526 (target_write_memory_blocks): Change argument to std::vector.
14527 (struct memory_write_request): Add constructor.
14528 * target-memory.c (compare_block_starting_address): Return bool.
14529 Change argument types.
14530 (claim_memory): Change arguments to use std::vector.
14531 (split_regular_and_flash_blocks, blocks_to_erase)
14532 (compute_garbled_blocks): Likewise.
14533 (cleanup_request_data, cleanup_write_requests_vector): Remove.
14534 (target_write_memory_blocks): Change argument to std::vector.
14535 * symfile.c (struct load_section_data): Add constructor and
14536 destructor. Use std::vector for "requests".
14537 (struct load_progress_data): Add initializers.
14538 (load_section_callback): Update. Use "new".
14539 (clear_memory_write_data): Remove.
14540 (generic_load): Update.
14542 2018-02-27 Alan Hayward <alan.hayward@arm.com>
14544 * arch/aarch64.h: Use common/tdesc.h.
14546 2018-02-26 Maciej W. Rozycki <macro@mips.com>
14548 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
14549 architecture with a 64-bit ABI.
14551 2018-02-26 Maciej W. Rozycki <macro@mips.com>
14553 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
14554 ahead of target description loading.
14556 2018-02-26 Tom Tromey <tom@tromey.com>
14558 * stack.c (backtrace_command_1): Update.
14559 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
14561 * python/py-framefilter.c (py_print_frame)
14562 (gdbpy_apply_frame_filter): Change type of "flags".
14563 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
14565 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
14566 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
14567 * extension.h (enum frame_filter_flag): Rename from
14568 frame_filter_flags.
14569 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
14570 (apply_ext_lang_frame_filter): Change type of "flags".
14571 * extension.c (apply_ext_lang_frame_filter): Change type of
14573 * extension-priv.h (struct extension_language_ops)
14574 <apply_frame_filter>: Change type of "flags".
14576 2018-02-26 Tom Tromey <tom@tromey.com>
14579 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
14580 off-by-one in py_end computation.
14581 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
14583 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
14586 2018-02-26 Tom Tromey <tom@tromey.com>
14588 * dwarf2read.c (struct variant_field): New.
14589 (struct nextfield) <variant>: New field.
14590 (dwarf2_add_field): Handle DW_TAG_variant_part.
14591 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
14592 discriminated union.
14593 (read_structure_type): Handle DW_TAG_variant_part.
14594 (handle_struct_member_die): New function, extracted from
14595 process_structure_scope. Handle DW_TAG_variant.
14596 (process_structure_scope): Handle discriminated unions. Call
14597 handle_struct_member_die.
14599 2018-02-26 Tom Tromey <tom@tromey.com>
14601 * rust-lang.h (rust_last_path_segment): Declare.
14602 * rust-lang.c (rust_last_path_segment): Now public. Change
14604 (struct disr_info): Remove.
14605 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
14606 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
14607 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
14608 (rust_enum_p, rust_enum_variant): New function.
14609 (rust_underscore_fields): Remove "offset" parameter.
14610 (rust_print_enum): New function.
14611 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
14612 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
14613 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
14615 (rust_internal_print_type): New function, from rust_print_type.
14617 (rust_print_type): Call rust_internal_print_type.
14618 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
14619 Update enum handling.
14620 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
14621 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
14622 (rust_union_quirks): New functions.
14623 (process_full_comp_unit, process_full_type_unit): Call
14625 (process_structure_scope): Update rust_unions if necessary.
14627 2018-02-26 Tom Tromey <tom@tromey.com>
14629 * value.h (value_union_variant): Declare.
14630 * valops.c (value_union_variant): New function.
14631 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
14632 (struct discriminant_info): New.
14633 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
14635 (struct main_type) <flag_discriminated_union>: New field.
14637 2018-02-26 Tom Tromey <tom@tromey.com>
14639 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
14640 unittests/unpack-selftests.c.
14641 * unittests/unpack-selftests.c: New file.
14642 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
14644 2018-02-26 Yao Qi <yao.qi@linaro.org>
14646 * dwarf2read.c (struct partial_die_info) <read>: New method.
14647 (read_partial_die): Remove the declaration.
14648 (load_partial_dies): Update.
14649 (partial_die_info::partial_die_info):
14650 (read_partial_die): Change it to partial_die_info::read.
14652 2018-02-26 Yao Qi <yao.qi@linaro.org>
14654 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
14655 (fixup_partial_die): Remove declaration.
14656 (scan_partial_symbols): Update.
14657 (partial_die_parent_scope): Likewise.
14658 (partial_die_full_name): Likewise.
14659 (fixup_partial_die): Change it to partial_die_info::fixup.
14661 2018-02-26 Yao Qi <yao.qi@linaro.org>
14663 * dwarf2read.c (read_partial_die): Update the declaration.
14664 (load_partial_dies): Caller update.
14665 (read_partial_die): Remove one argument abbrev_len.
14667 2018-02-26 Yao Qi <yao.qi@linaro.org>
14669 * dwarf2read.c (struct partial_die_info): Add ctor, delete
14670 assignment operator.
14671 (load_partial_dies): Use ctor and copy ctor.
14672 (read_partial_die): Update.
14673 (dwarf2_cu::find_partial_die): Use ctor.
14675 2018-02-26 Yao Qi <yao.qi@linaro.org>
14677 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
14678 (find_partial_die_in_comp_unit): Change it to
14679 dwarf2_cu::find_partial_die.
14680 (find_partial_die): Update.
14682 2018-02-26 Yao Qi <yao.qi@linaro.org>
14684 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
14687 2018-02-26 Yao Qi <yao.qi@linaro.org>
14689 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
14691 2018-02-26 Alan Hayward <alan.hayward@arm.com>
14693 * arch/amd64.h: Use common/tdesc.h.
14694 * arch/i386.c: Likewise.
14695 * arch/i386.h: Likewise.
14696 * arch/tic6x.c: Likewise.
14697 * arch/tdesc.h: Move file from here...
14698 * common/tdesc.h: ...to here.
14699 * features/aarch64-core.c: Regenerate.
14700 * features/aarch64-fpu.c: Regenerate.
14701 * features/i386/32bit-avx.c: Regenerate.
14702 * features/i386/32bit-avx512.c: Regenerate.
14703 * features/i386/32bit-core.c: Regenerate.
14704 * features/i386/32bit-linux.c: Regenerate.
14705 * features/i386/32bit-mpx.c: Regenerate.
14706 * features/i386/32bit-pkeys.c: Regenerate.
14707 * features/i386/32bit-sse.c: Regenerate.
14708 * features/i386/64bit-avx.c: Regenerate.
14709 * features/i386/64bit-avx512.c: Regenerate.
14710 * features/i386/64bit-core.c: Regenerate.
14711 * features/i386/64bit-linux.c: Regenerate.
14712 * features/i386/64bit-mpx.c: Regenerate.
14713 * features/i386/64bit-pkeys.c: Regenerate.
14714 * features/i386/64bit-segments.c: Regenerate.
14715 * features/i386/64bit-sse.c: Regenerate.
14716 * features/i386/x32-core.c: Regenerate.
14717 * features/tic6x-c6xp.c: Regenerate.
14718 * features/tic6x-core.c: Regenerate.
14719 * features/tic6x-gp.c: Regenerate.
14720 * target-descriptions.c: Use common/tdesc.h.
14721 * target-descriptions.h: Likewise.
14723 2018-02-24 Tom Tromey <tom@tromey.com>
14725 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
14726 (try_thread_db_load_from_dir, thread_db_load_search): Use
14728 (info_auto_load_libthread_db_compare): Return bool. Change
14730 (info_auto_load_libthread_db): Use std::vector, std::string.
14733 2018-02-24 Tom Tromey <tom@tromey.com>
14735 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
14737 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
14739 * gdbarch.c: Rebuild.
14740 * gdbarch.h: Rebuild.
14741 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
14742 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
14743 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
14746 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
14748 * gdbtypes.h (sect_offset): Change type to uint64_t.
14749 (sect_offset_str): New function.
14750 * dwarf2read.c (create_addrmap_from_aranges): Use
14752 (error_check_comp_unit_head): Likewise.
14753 (create_debug_type_hash_table): Likewise.
14754 (read_cutu_die_from_dwo): Likewise.
14755 (init_cutu_and_read_dies): Likewise.
14756 (init_cutu_and_read_dies_no_follow): Likewise.
14757 (process_psymtab_comp_unit_reader): Likewise.
14758 (partial_die_parent_scope): Likewise.
14759 (peek_die_abbrev): Likewise.
14760 (process_queue): Likewise.
14761 (dwarf2_physname): Likewise.
14762 (read_namespace_alias): Likewise.
14763 (read_import_statement): Likewise.
14764 (create_dwo_cu_reader): Likewise.
14765 (create_cus_hash_table): Likewise.
14766 (lookup_dwo_cutu): Likewise.
14767 (inherit_abstract_dies): Likewise.
14768 (read_func_scope): Likewise.
14769 (read_call_site_scope): Likewise.
14770 (dwarf2_add_member_fn): Likewise.
14771 (read_common_block): Likewise.
14772 (read_module_type): Likewise.
14773 (read_typedef): Likewise.
14774 (read_subrange_type): Likewise.
14775 (load_partial_dies): Likewise.
14776 (read_partial_die): Likewise.
14777 (find_partial_die): Likewise.
14778 (read_str_index): Likewise.
14779 (dwarf2_string_attr): Likewise.
14780 (build_error_marker_type): Likewise.
14781 (lookup_die_type): Likewise.
14782 (dump_die_shallow): Likewise.
14783 (follow_die_ref): Likewise.
14784 (dwarf2_fetch_die_loc_sect_off): Likewise.
14785 (dwarf2_fetch_constant_bytes): Likewise.
14786 (follow_die_sig): Likewise.
14787 (get_signatured_type): Likewise.
14788 (get_DW_AT_signature_type): Likewise.
14789 (dwarf2_find_containing_comp_unit): Likewise.
14790 (set_die_type): Likewise.
14792 2018-02-21 John Baldwin <jhb@FreeBSD.org>
14794 * arch/aarch64.c: Include "common-defs.h".
14795 * arch/amd64.c: Likewise.
14796 * arch/i386.c: Likewise.
14798 2018-02-21 Tom Tromey <tom@tromey.com>
14800 * value.h: (extract_field_op): Update.
14801 * eval.c (extract_field_op): Return a const char *.
14802 * expression.h (parse_expression_for_completion): Update.
14803 * completer.c (complete_expression): Update.
14804 (add_struct_fields): Make fieldname const.
14805 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
14806 (mark_completion_tag, parse_exp_in_context_1): Update.
14807 (parse_expression_for_completion): Change "name" to
14808 unique_xmalloc_ptr*.
14810 2018-02-21 Tom Tromey <tom@tromey.com>
14812 * infcall.c (call_function_by_hand_dummy): Use std::vector.
14814 2018-02-21 Yao Qi <yao.qi@linaro.org>
14816 * avr-tdep.c (avr_read_pc): Change parameter type to
14818 * gdbarch.sh (read_pc): Likewise.
14819 * gdbarch.c: Re-generated.
14820 * gdbarch.h: Re-generated.
14821 * hppa-tdep.c (hppa_read_pc): Change parameter type to
14823 * ia64-tdep.c (ia64_read_pc): Likewise.
14824 * mips-tdep.c (mips_read_pc): Likewise.
14825 * spu-tdep.c (spu_read_pc): Likewise.
14827 2018-02-21 Yao Qi <yao.qi@linaro.org>
14829 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
14830 * regcache-dump.c: New file.
14831 * regcache.c: Move register_dump to regcache-dump.c.
14832 (maintenance_print_registers): Likewise.
14833 (maintenance_print_raw_registers): Likewise.
14834 (maintenance_print_cooked_registers): Likewise.
14835 (maintenance_print_register_groups): Likewise.
14836 (maintenance_print_remote_registers): Likewise.
14837 (_initialize_regcache): Likewise.
14838 * regcache.h (register_dump): Moved from regcache.c.
14840 2018-02-21 Yao Qi <yao.qi@linaro.org>
14842 * regcache.c (regcache::regcache): Update.
14843 (regcache::invalidate): Move it to detached_regcache::invalidate.
14844 (get_thread_arch_aspace_regcache): Update.
14845 (regcache::raw_update): Update.
14846 (regcache::cooked_read): Remove some code.
14847 (regcache::cooked_read_value): Likewise.
14848 (regcache::raw_write): Remove assert on m_readonly_p.
14849 (regcache::raw_supply_integer): Move it to
14850 detached_regcache::raw_supply_integer.
14851 (regcache::raw_supply_zeroed): Likewise.
14852 * regcache.h (detached_regcache) <raw_supply_integer>: New
14854 <raw_supply_zeroed, invalidate>: Likewise.
14855 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
14856 <invalidate>: Likewise.
14857 <m_readonly_p>: Removed.
14859 2018-02-21 Yao Qi <yao.qi@linaro.org>
14861 * infcmd.c (get_return_value): Let stop_regs point to
14862 get_current_regcache.
14863 * regcache.c (regcache::regcache): Remove.
14864 (register_dump_reg_buffer): New class.
14865 (regcache_print): Adjust.
14866 * regcache.h (regcache): Remove constructors.
14868 2018-02-21 Yao Qi <yao.qi@linaro.org>
14870 * regcache.c (class register_dump): New class.
14871 (register_dump_regcache, register_dump_none): New class.
14872 (register_dump_remote, register_dump_groups): New class.
14873 (regcache_print): Update.
14874 * regcache.h (regcache_dump_what): Move it to regcache.c.
14875 (regcache) <dump>: Remove.
14877 2018-02-21 Yao Qi <yao.qi@linaro.org>
14879 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
14881 (jit_unwind_reg_set_impl): Call raw_supply.
14882 (jit_frame_sniffer): Use reg_buffer_rw.
14883 * record-full.c (record_full_core_regbuf): Change its type.
14884 (record_full_core_open_1): Use reg_buffer_rw.
14885 (record_full_close): Likewise.
14886 (record_full_core_fetch_registers): Use regcache->raw_supply.
14887 (record_full_core_store_registers): Likewise.
14888 * regcache.c (regcache::get_register_status): Move it to
14890 (regcache_raw_set_cached_value): Remove.
14891 (regcache::raw_set_cached_value): Remove.
14892 (regcache::raw_write): Call raw_supply.
14893 (regcache::raw_supply): Move it to reg_buffer_rw.
14894 * regcache.h (regcache_raw_set_cached_value): Remove.
14895 (reg_buffer_rw): New class.
14897 2018-02-21 Yao Qi <yao.qi@linaro.org>
14899 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
14900 readonly_detached_regcache.
14901 (dummy_frame_prev_register): Use regcache->cooked_read.
14902 * frame.c (frame_save_as_regcache): Change return type.
14903 (frame_pop): Update.
14904 * frame.h (frame_save_as_regcache): Update declaration.
14905 * inferior.h (get_infcall_suspend_state_regcache): Update
14907 * infrun.c (infcall_suspend_state) <registers>: use
14908 readonly_detached_regcache.
14909 (save_infcall_suspend_state): Don't use regcache_dup.
14910 (get_infcall_suspend_state_regcache): Change return type.
14911 * linux-fork.c (struct fork_info) <savedregs>: Change to
14912 readonly_detached_regcache.
14914 (fork_save_infrun_state): Don't use regcache_dup.
14915 (info_checkpoints_command): Adjust.
14916 * mi/mi-main.c (register_changed_p): Update declaration.
14917 (mi_cmd_data_list_changed_registers): Use
14918 readonly_detached_regcache.
14919 (register_changed_p): Change parameter type to
14920 readonly_detached_regcache.
14921 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
14922 readonly_detached_regcache.
14923 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
14924 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
14926 (regcache::save): Move it to reg_buffer.
14927 (regcache::restore): Change parameter type.
14928 (regcache_dup): Remove.
14929 * regcache.h (reg_buffer) <save>: New method.
14930 (readonly_detached_regcache): New class.
14931 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
14932 readonly_detached_regcache.
14933 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
14935 2018-02-21 Yao Qi <yao.qi@linaro.org>
14937 * frame.c (frame_save_as_regcache): Use regcache method save.
14938 (frame_pop): Use regcache method restore.
14939 * infrun.c (restore_infcall_suspend_state): Likewise.
14940 * linux-fork.c (fork_load_infrun_state): Likewise.
14941 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
14943 * regcache.c (regcache_save): Remove.
14944 (regcache::restore): More asserts.
14945 (regcache_cpy): Remove.
14946 * regcache.h (regcache_save): Remove the declaration.
14947 (regcache::restore): Move from private to public.
14948 Remove the friend declaration of regcache_cpy.
14949 (regcache_cpy): Remove declaration.
14951 2018-02-21 Yao Qi <yao.qi@linaro.org>
14953 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
14954 parameter type to 'readable_regcache *'.
14955 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
14956 * arm-tdep.c (arm_neon_quad_read): Likewise.
14957 (arm_pseudo_read): Likewise.
14958 * avr-tdep.c (avr_pseudo_register_read): Likewise.
14959 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
14960 * frv-tdep.c (frv_pseudo_register_read): Likewise.
14961 * gdbarch.c: Re-generated.
14962 * gdbarch.h: Re-generated.
14963 * gdbarch.sh (pseudo_register_read): Change parameter type to
14964 'readable_regcache *'.
14965 (pseudo_register_read_value): Likewise.
14966 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
14967 (h8300_pseudo_register_read): Likewise.
14968 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
14969 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
14970 (i386_pseudo_register_read_into_value): Likewise.
14971 (i386_pseudo_register_read_value): Likewise.
14972 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
14974 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
14975 * m32c-tdep.c (m32c_raw_read): Likewise.
14976 (m32c_read_flg): Likewise.
14977 (m32c_banked_register): Likewise.
14978 (m32c_banked_read): Likewise.
14979 (m32c_sb_read): Likewise.
14980 (m32c_part_read): Likewise.
14981 (m32c_cat_read): Likewise.
14982 (m32c_r3r2r1r0_read): Likewise.
14983 (m32c_pseudo_register_read): Likewise.
14984 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
14985 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
14986 (mep_pseudo_cr64_read): Likewise.
14987 (mep_pseudo_register_read): Likewise.
14988 * mips-tdep.c (mips_pseudo_register_read): Likewise.
14989 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
14990 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
14991 * regcache.c (regcache::raw_read): Move it to readable_regcache.
14992 (regcache::cooked_read): Likewise.
14993 (regcache::cooked_read_value): Likewise.
14994 (regcache_cooked_read_signed):
14995 (regcache::cooked_read): Likewise.
14996 * regcache.h (readable_regcache): New class.
14997 (regcache): Inherit readable_regcache. Move some methods to
14999 * rl78-tdep.c (rl78_pseudo_register_read): Change
15000 parameter type to 'readable_regcache *'.
15001 * rs6000-tdep.c (do_regcache_raw_read): Remove.
15002 (e500_pseudo_register_read): Change parameter type to
15003 'readable_regcache *'.
15004 (dfp_pseudo_register_read): Likewise.
15005 (vsx_pseudo_register_read): Likewise.
15006 (efpr_pseudo_register_read): Likewise.
15007 * s390-tdep.c (s390_pseudo_register_read): Likewise.
15008 * sh-tdep.c (sh_pseudo_register_read): Likewise.
15009 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
15010 (sh64_pseudo_register_read): Likewise.
15011 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
15012 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
15013 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
15014 (spu_pseudo_register_read): Likewise.
15015 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
15016 (xtensa_pseudo_register_read): Likewise.
15018 2018-02-21 Yao Qi <yao.qi@linaro.org>
15020 * regcache.c (regcache::regcache): Call reg_buffer ctor.
15021 (regcache::arch): Move it to reg_buffer::arch.
15022 (regcache::register_buffer): Likewise.
15023 (regcache::assert_regnum): Likewise.
15024 (regcache::num_raw_registers): Likewise.
15025 * regcache.h (reg_buffer): New class.
15026 (regcache): Inherit reg_buffer.
15028 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
15030 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
15031 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
15033 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
15035 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
15037 2018-02-19 Alan Hayward <alan.hayward@arm.com>
15039 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
15040 (SFILES): Remove common/*.c files.
15041 (COMMON_OBS): Remove some *.o files built from common/*.c files.
15042 * common/common.host: Add common reference.
15043 * configure.ac: Likewise.
15044 * configure: Regenerate.
15046 2018-02-16 Yao Qi <yao.qi@linaro.org>
15048 * block.c (block_namespace_info): Inherit allocate_on_obstack.
15049 (block_initialize_namespace): Use new.
15050 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
15051 (dwarf2_free_objfile): Use delete.
15052 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
15053 (copy_type_recursive): Use new.
15054 * gdb_obstack.h (allocate_on_obstack): New.
15056 2018-02-15 Yao Qi <yao.qi@linaro.org>
15059 * inferior.c (exit_inferior_1): Reset inf->control.
15061 2018-02-15 Joel Brobecker <brobecker@adacore.com>
15063 * ada-lang.c (ada_to_fixed_value_create): Delete advance
15066 2018-02-14 Pedro Alves <palves@redhat.com>
15068 * frame-unwind.c (frame_unwind_try_unwinder): Always call
15069 frame_cleanup_after_sniffer on exception.
15071 2018-02-14 Tom Tromey <tom@tromey.com>
15073 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
15075 (solib_bfd_open): Make pathname const.
15076 * solib.c (solib_bfd_open): Make pathname const.
15077 * solib-spu.c (spu_bfd_fopen): Make name const.
15078 (spu_bfd_open): Make pathname const.
15079 * solib-darwin.c (darwin_bfd_open): Make pathname const.
15080 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
15082 2018-02-14 Tom Tromey <tom@tromey.com>
15084 * symfile.c (symfile_bfd_open): Update.
15085 * source.h (openp, source_full_path_of, find_and_open_source):
15086 Change argument type to unique_xmalloc_ptr.
15087 * source.c (openp): Take a unique_xmalloc_ptr.
15088 (source_full_path_of, find_and_open_source): Likewise.
15089 (open_source_file, symtab_to_fullname): Update.
15090 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
15091 unique_xmalloc_ptr.
15092 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
15093 (exec_file_find): Update.
15094 * psymtab.c (psymtab_to_fullname): Update.
15095 * nto-tdep.h (nto_find_and_open_solib): Update.
15096 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
15097 unique_xmalloc_ptr.
15098 * exec.c (exec_file_attach): Update.
15099 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
15100 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
15102 2018-02-14 Tom Tromey <tom@tromey.com>
15104 * solib.c: Include source.h.
15105 * nto-tdep.c: Include source.h.
15106 * mi/mi-cmd-env.c: Include source.h.
15107 * infcmd.c: Include source.h.
15108 * exec.c: Include source.h.
15109 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
15110 (add_path, directory_switch, source_path, init_source_path): Move
15112 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
15113 (add_path, directory_switch, source_path, init_source_path):
15116 2018-02-14 Tom Tromey <tom@tromey.com>
15118 * solist.h (exec_file_find, solib_find): Return
15119 unique_xmalloc_ptr.
15120 (solib_bfd_fopen): Take a const char *.
15121 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
15122 (exec_file_find, solib_find): Likewise.
15123 (solib_bfd_fopen): Do not take ownership of "pathname".
15124 (solib_bfd_open): Use unique_xmalloc_ptr.
15125 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
15126 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
15127 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
15128 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
15130 2018-02-14 Joel Brobecker <brobecker@adacore.com>
15132 * ada-lang.c (name_match_type_from_name): Remove reference to
15133 ada_name_for_lookup in function's documentation.
15134 * ada-lang.h (ada_name_for_lookup): Delete declaration.
15136 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
15138 * defs.h (enum openp_flags): New enum.
15139 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
15140 Move to enum openp_flags.
15141 (openp_flags): New enum flags.
15142 (openp): Change parameter type to openp_flags.
15143 * source.c (openp): Change parameter type to openp_flags.
15144 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
15145 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
15147 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
15149 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
15152 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
15154 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
15156 (class dwarf2_queue_guard): ...the destructor of this new class.
15157 (dw2_do_instantiate_symtab): Create instance of the new class
15158 dwarf2_queue_guard, remove cleanup.
15160 2018-02-09 Tom Tromey <tom@tromey.com>
15162 * source.c (find_source_lines): Don't reference past the end of
15165 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15167 * remote.c (remote_btrace_maybe_reopen): Change error message.
15168 * btrace.c (btrace_enable): Likewise.
15169 (parse_xml_btrace): Likewise.
15170 (parse_xml_btrace_conf): Likewise.
15172 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15174 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
15175 (linux_enable_pt, linux_enable_bts): Call
15176 diagnose_perf_event_open_fail.
15178 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15180 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
15181 Remove parameter and change return type. Update callers. Move it.
15182 (linux_enable_bts, linux_enable_pt): Improve error message.
15183 (linux_enable_pt): Remove zero buffer size check.
15184 (linux_enable_btrace): Improve error messages. Remove NULL return
15187 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15189 * btrace.c (btrace_enable): Remove target_supports_btrace call.
15190 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
15191 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
15192 (linux_supports_pt, linux_supports_btrace): Remove.
15193 (linux_enable_bts): Call cpu_supports_bts.
15194 * nat/linux-btrace.h (linux_supports_btrace): Remove.
15195 * remote.c (remote_supports_btrace): Remove.
15196 (init_remote_ops): Remove remote_supports_btrace.
15197 * target-delegates.c: Regenerated.
15198 * target.c (target_supports_btrace): Remove.
15199 * target.h (target_ops) <to_supports_btrace>: Remove
15200 (target_supports_btrace): Remove.
15201 * x86-linux-nat.c (x86_linux_create_target): Remove
15202 linux_supports_btrace.
15204 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15206 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
15208 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
15209 exception and use message in own exception.
15211 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15213 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
15214 (perf_event_pt_event_type): Use gdb_file_up.
15215 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
15216 scoped_fd, and scoped_mmap.
15218 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15220 * common/scoped_mmap.h: New.
15221 * unittests/scoped_mmap-selftest.c: New.
15222 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
15223 unittests/scoped_mmap-selftest.c.
15225 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
15227 * common/scoped_fd.h: New.
15228 * unittests/scoped_fd-selftest.c: New.
15229 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
15230 unittests/scoped_fd-selftest.c.
15232 2018-02-09 Tom Tromey <tom@tromey.com>
15234 * auto-load.c (auto_load_section_scripts): Use
15235 gdb::unique_xmalloc_ptr.
15237 2018-02-09 Tom Tromey <tom@tromey.com>
15239 * auto-load.c (execute_script_contents): Use std::string.
15241 2018-02-09 Joel Brobecker <brobecker@adacore.com>
15243 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
15244 Python function, rather than a new command.
15246 2018-02-08 Tom Tromey <tom@tromey.com>
15248 * solib.c (solib_find_1): Use std::string.
15249 (solib_bfd_fopen): Use unique_xmalloc_ptr.
15251 2018-02-08 Tom Tromey <tom@tromey.com>
15253 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
15255 2018-02-08 Tom Tromey <tom@tromey.com>
15257 * source.c (find_source_lines): Use gdb::def_vector.
15259 2018-02-08 Tom Tromey <tom@tromey.com>
15261 * macrocmd.c (struct temporary_macro_definition): New.
15262 (macro_define_command): Use temporary_macro_definition. Remove
15264 (free_macro_definition_ptr): Remove.
15266 2018-02-08 Tom Tromey <tom@tromey.com>
15268 * macroexp.c (maybe_expand): Use std::string.
15270 2018-02-08 Tom Tromey <tom@tromey.com>
15272 * macroexp.c (struct macro_buffer): Add initializers for some
15274 (init_buffer, init_shared_buffer, free_buffer)
15275 (free_buffer_return_text): Remove.
15276 (macro_buffer): New constructors.
15277 (~macro_buffer): New destructor.
15278 (macro_buffer::set_shared): New method.
15279 (macro_buffer::resize_buffer, macro_buffer::appendc)
15280 (macro_buffer::appendmem): Now methods, not free functions.
15281 (set_token, append_tokens_without_splicing, stringify)
15282 (macro_stringify): Update.
15283 (gather_arguments): Change return type. Remove argc_p argument,
15284 add args_ptr argument. Use std::vector.
15285 (substitute_args): Remove argc argument. Accept std::vector.
15286 (expand): Update. Use std::vector.
15287 (scan, macro_expand, macro_expand_next): Update.
15289 2018-02-08 Tom Tromey <tom@tromey.com>
15291 * symtab.c (default_collect_symbol_completion_matches_break_on):
15292 Use unique_xmalloc_ptr.
15293 * macroscope.h: (sal_macro_scope, user_macro_scope)
15294 (default_macro_scope): Return unique_xmalloc_ptr.
15295 * macroscope.c (sal_macro_scope, user_macro_scope)
15296 (default_macro_scope): Return unique_xmalloc_ptr.
15297 * macroexp.h (macro_expand, macro_expand_once): Return
15298 unique_xmalloc_ptr.
15299 * macroexp.c (macro_expand, macro_expand_once): Return
15300 unique_xmalloc_ptr.
15301 * macrocmd.c (macro_expand_command, macro_expand_once_command)
15302 (info_macro_command, info_macros_command): Use
15303 unique_xmalloc_ptr.
15304 * compile/compile-c-support.c (write_macro_definitions): Use
15305 unique_xmalloc_ptr.
15306 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
15308 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
15310 * value.c (value_static_field): Assign field type instead of
15311 containing type when returning an optimized out value.
15313 2018-02-06 Yao Qi <yao.qi@linaro.org>
15315 * ft32-tdep.c (ft32_read_pc): Remove.
15316 (ft32_write_pc): Remove.
15317 (ft32_gdbarch_init): Update.
15318 * m32r-tdep.c (m32r_read_pc): Remove.
15319 (m32r_gdbarch_init): Update.
15320 * mep-tdep.c (mep_read_pc): Remove.
15321 (mep_gdbarch_init): Update.
15322 * microblaze-tdep.c (microblaze_write_pc): Remove.
15323 (microblaze_gdbarch_init): Update.
15324 * mn10300-tdep.c (mn10300_read_pc): Remove.
15325 (mn10300_write_pc): Remove.
15326 (mn10300_gdbarch_init): Update.
15327 * moxie-tdep.c (moxie_read_pc): Remove.
15328 (moxie_write_pc): Remove.
15329 (moxie_gdbarch_init): Update.
15331 2018-02-06 Yao Qi <yao.qi@linaro.org>
15333 * expprint.c (print_subexp_standard): Handle
15334 OP_F77_UNDETERMINED_ARGLIST.
15335 (dump_subexp_body_standard): Likewise.
15337 2018-02-05 Alan Hayward <alan.hayward@arm.com>
15339 * target-descriptions.c (tdesc_element_visitor) Add empty
15341 (tdesc_type): Move make_gdb_type from here.
15342 (tdesc_type_builtin): Likewise.
15343 (tdesc_type_vector): Likewise.
15344 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
15345 (make_gdb_type_struct): Move from tdesc_type_with_fields.
15346 (make_gdb_type_union): Likewise.
15347 (make_gdb_type_flags): Likewise.
15348 (make_gdb_type_enum): Likewise.
15349 (make_gdb_type): New function.
15350 (tdesc_register_type): Use static make_gdb_type.
15352 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
15354 * infcmd.c (default_print_one_register_info): Align natural-format
15355 column values consistently one under another.
15356 (pad_to_column): New function.
15358 2018-02-05 Joel Brobecker <brobecker@adacore.com>
15360 * dwarf2read.c (dwarf2_physname): Move commment.
15362 2018-02-01 Leszek Swirski <leszeks@google.com>
15364 * varobj.c (varobj_formatted_print_options): Allow recursive
15365 pretty printing if pretty printing is enabled.
15367 2018-02-01 Leszek Swirski <leszeks@google.com>
15369 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
15370 names after a structop as a filename.
15372 2018-02-01 Yao Qi <yao.qi@linaro.org>
15374 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
15375 (arm_record_coproc_data_proc): Likewise.
15377 2018-02-01 Yao Qi <yao.qi@linaro.org>
15379 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
15381 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
15383 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
15384 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
15386 2018-01-31 Pedro Alves <palves@redhat.com>
15388 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
15389 * inflow.c (child_terminal_save_inferior): Wrap reference to
15390 tcgetpgrp in HAVE_TERMIOS_H.
15391 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
15393 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
15394 always iterate over all inferiors.
15395 (gdbsim_cntrl_c): Adjust.
15396 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
15398 2018-01-31 Joel Brobecker <brobecker@adacore.com>
15400 * gdbtypes.c (lookup_array_range_type): Make sure the array's
15401 index type is objfile-owned if the element type is as well.
15403 2018-01-31 Joel Brobecker <brobecker@adacore.com>
15407 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
15409 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
15410 "features/s390x-linux64.c".
15411 (_initialize_s390_linux_tdep): Remove initialization of tdescs
15412 s390_linux32 and s390x_linux64.
15413 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
15415 * s390-tdep.c: Include "features/s390-linux32.c" and
15416 "features/s390x-linux64.c".
15417 (s390_tdesc_valid): Add check for tdesc_has_registers.
15418 (s390_gdbarch_init): Make sure there is always a valid tdesc.
15419 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
15420 tdesc_s390x_linux64.
15421 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
15422 tdesc_s390x_linux64 to...
15423 * s390-tdep.h: ...here.
15425 2018-01-30 Pedro Alves <palves@redhat.com>
15428 * config.in, configure: Regenerate.
15429 * configure.ac: Check for getpgid.
15430 * go32-nat.c (go32_pass_ctrlc): New.
15431 (go32_target): Install it.
15432 * inf-child.c (inf_child_target): Install
15433 child_terminal_save_inferior, child_pass_ctrlc and
15435 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
15436 (inf_ptrace_target): No longer install it.
15437 * infcmd.c (interrupt_target_1): Adjust.
15438 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
15439 (child_interrupt): Declare.
15440 (inferior::terminal_state): New.
15441 * inflow.c (struct terminal_info): Update comments.
15442 (inferior_process_group): Delete.
15443 (terminal_is_ours): Delete.
15444 (gdb_tty_state): New.
15445 (child_terminal_init): Adjust.
15446 (is_gdb_terminal, sharing_input_terminal_1)
15447 (sharing_input_terminal): New functions.
15448 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
15449 Set the process's actual process group in the foreground if
15450 possible. Handle is_ours_for_output/is_ours distinction. Don't
15451 mark terminal as the inferior's if not sharing GDB's terminal.
15452 Don't check attach_flag.
15453 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
15454 pass down a target_terminal_state.
15455 (child_terminal_save_inferior): New, factored out from ...
15456 (child_terminal_ours_1): ... this. Handle
15457 target_terminal_state::is_ours_for_output.
15458 (child_interrupt, child_pass_ctrlc): New.
15459 (inflow_inferior_exit): Clear the inferior's terminal_state.
15460 (copy_terminal_info): Copy the inferior's terminal state.
15461 (_initialize_inflow): Remove reference to terminal_is_ours.
15462 * inflow.h (inferior_process_group): Delete.
15463 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
15464 * procfs.c (procfs_target): Don't install procfs_interrupt.
15465 (procfs_interrupt): Delete.
15466 * remote.c (remote_serial_quit_handler): Adjust.
15467 (remote_interrupt): Remove ptid parameter. Adjust.
15468 * target-delegates.c: Regenerate.
15469 * target.c: Include "terminal.h".
15470 (target_terminal::terminal_state): Rename to ...
15471 (target_terminal::m_terminal_state): ... this.
15472 (target_terminal::init): Adjust.
15473 (target_terminal::inferior): Adjust to per-inferior
15475 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
15476 (target_terminal::ours, target_terminal::ours_for_output): Use
15477 target_terminal_is_ours_kind.
15478 (target_interrupt): Remove ptid parameter. Adjust.
15479 (default_target_pass_ctrlc): Adjust.
15480 * target.h (target_ops::to_terminal_save_inferior): New field.
15481 (target_ops::to_interrupt): Remove ptid_t parameter.
15482 (target_interrupt): Remove ptid_t parameter. Update comment.
15483 (target_pass_ctrlc): Update comment.
15484 * target/target.h (target_terminal_state): New scoped enum,
15485 factored out of ...
15486 (target_terminal::terminal_state): ... here.
15487 (target_terminal::inferior): Update comments.
15488 (target_terminal::restore_inferior): New.
15489 (target_terminal::is_inferior, target_terminal::is_ours)
15490 (target_terminal::is_ours_for_output): Adjust.
15491 (target_terminal::scoped_restore_terminal_state): Adjust to
15492 rename, and call restore_inferior() instead of inferior().
15493 (target_terminal::scoped_restore_terminal_state::m_state): Change
15495 (target_terminal::terminal_state): Rename to ...
15496 (target_terminal::m_terminal_state): ... this and change type.
15498 2018-01-30 Pedro Alves <palves@redhat.com>
15500 * linux-nat.c (wait_for_signal): New function.
15501 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
15503 (async_terminal_is_ours)
15504 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
15505 (linux_nat_add_target): Don't override
15506 to_terminal_inferior/to_terminal_ours.
15508 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
15510 * remote.c (remote_follow_fork): Don't call "detach_inferior".
15512 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
15514 * dwarf2read.c (free_dwo_files): Add forward-declaration.
15515 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
15516 dwarf2_per_objfile_free here.
15517 (dwarf2_per_objfile_free): Remove.
15518 (_initialize_dwarf2_read): Don't register
15519 dwarf2_per_objfile_free as a registry cleanup.
15521 2018-01-27 Eli Zaretskii <eliz@gnu.org>
15523 Avoid compilation errors in MinGW native builds
15525 The error is triggered by including python-internal.h, and the
15528 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
15529 from build-gnulib/import/math.h:27,
15530 from d:/usr/Python26/include/pyport.h:235,
15531 from d:/usr/Python26/include/Python.h:58,
15532 from python/python-internal.h:94,
15533 from python/py-arch.c:24:
15534 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
15538 This happens because Python headers define 'hypot' to expand t
15539 '_hypot' in the Windows builds.
15540 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
15541 'hypoth'. This avoids a compilation error.
15543 2018-01-26 Alan Hayward <alan.hayward@arm.com>
15545 * MAINTAINERS (Write After Approval): Fix ordering.
15547 2018-01-26 Alan Hayward <alan.hayward@arm.com>
15549 * MAINTAINERS (Write After Approval): Add Alan Hayward.
15551 2018-01-26 Alan Modra <amodra@gmail.com>
15553 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
15554 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
15555 Remove nop. Make const. Comment.
15556 (powerpc32_plt_stub_so_2): New.
15557 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
15558 Correct count. Update uses.
15559 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
15560 Move common code reading PLT entry word. Correct
15561 powerpc32_plt_stub PLT address calculation.
15562 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
15563 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
15564 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
15565 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
15566 (ppc64_standard_linkage8): Likewise.
15567 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
15568 Correct insns description.
15569 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
15571 2018-01-24 Pedro Alves <palves@redhat.com>
15573 GCC PR libstdc++/83906
15574 * gdbtypes.c (operator==(const dynamic_prop &,
15575 const dynamic_prop &)): New.
15576 (operator==(const range_bounds &, const range_bounds &)): New.
15577 (check_types_equal): Use them instead of memcmp.
15578 * gdbtypes.h (operator==(const dynamic_prop &,
15579 const dynamic_prop &)): Declare.
15580 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
15581 (operator==(const range_bounds &, const range_bounds &)): Declare.
15582 (operator!=(const range_bounds &, const range_bounds &)): Declare.
15584 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15586 * s390-linux-tdep.c (s390_record_address_mask)
15587 (s390_record_calc_disp_common, s390_record_calc_disp)
15588 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
15589 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
15590 (s390_process_record): Move to s390-tdep.c.
15591 (s390_linux_init_abi_any): Adjust.
15592 * s390-tdep.c (s390_record_address_mask)
15593 (s390_record_calc_disp_common, s390_record_calc_disp)
15594 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
15595 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
15596 (s390_process_record): Moved from s390-linux-tdep.c
15597 (s390_gdbarch_init): Adjust.
15599 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15601 * s390-linux-nat.c (s390-tdep.h): New include.
15602 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
15603 (HFILES_NO_SRCDIR): Add s390-tdep.h.
15604 (ALLDEPFILES): Add s390-tdep.c.
15605 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
15606 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
15607 * s390-tdep.h: ...this. New file.
15608 * s390-linux-tdep.c (s390-tdep.h): New include.
15609 (_initialize_s390_tdep): Rename to...
15610 (_initialize_s390_linux_tdep): ...this and adjust.
15611 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
15612 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
15614 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
15615 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
15616 (s390_is_partial_instruction, s390_software_single_step)
15617 (is_non_branch_ril, s390_displaced_step_copy_insn)
15618 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
15619 (s390_prologue_data, s390_addr, s390_store, s390_load)
15620 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
15621 (s390_register_call_saved, s390_guess_tracepoint_registers)
15622 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
15623 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
15624 (s390_pseudo_register_name, s390_pseudo_register_type)
15625 (s390_pseudo_register_read, s390_pseudo_register_write)
15626 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
15627 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
15628 (s390_addr_bits_remove, s390_address_class_type_flags)
15629 (s390_address_class_type_flags_to_name)
15630 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
15631 (s390_function_arg_float, s390_function_arg_vector)
15632 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
15633 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
15634 (s390_frame_align, s390_register_return_value, s390_return_value)
15635 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
15636 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
15637 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
15638 (s390_trad_frame_prev_register, s390_unwind_cache)
15639 (s390_prologue_frame_unwind_cache)
15640 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
15641 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
15642 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
15643 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
15644 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
15645 (s390_frame_base_address, s390_local_base_address)
15646 (s390_frame_base, s390_gcc_target_options)
15647 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
15648 (s390_validate_reg_range, s390_tdesc_valid)
15649 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
15650 * s390-tdep.c: ...this. New file.
15652 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15654 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
15655 (s390_process_record, s390_gdbarch_tdep_alloc)
15656 (s390_linux_init_abi_any): Use/set new hook.
15658 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15660 * s390-linux-tdep.c (osabi.h): New include.
15661 (s390_linux_init_abi_31, s390_linux_init_abi_64)
15662 (s390_linux_init_abi_any): New functions.
15663 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
15665 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15667 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
15668 tdesc_has_registers check
15670 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15672 * s390-linux-tdep.c (s390_tdesc_valid): New function.
15673 (s390_validate_reg_range): New macro.
15674 (s390_gdbarch_init): Adjust.
15676 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15678 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
15679 (s390_gdbarch_tdep_alloc): Adjust.
15680 (s390_gdbarch_init): Adjust.
15682 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15684 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
15685 <have_tdb>: Change type to bool.
15686 (s390_gdbarch_tdep_alloc): Adjust.
15687 (s390_gdbarch_init): Adjust.
15689 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15691 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
15692 (gdbarch_tdep) <have_upper, have_vx>: New fields.
15693 (s390_gdbarch_tdep_alloc): New function.
15694 (s390_gdbarch_init): Allocate tdep at start and use its fields
15695 instead of separate variables.
15697 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15699 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
15700 when looking for cached gdbarch and add comment for remaining.
15702 2018-01-22 Pedro Alves <palves@redhat.com>
15703 Sergio Durigan Junior <sergiodj@redhat.com>
15705 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
15708 2018-01-22 Maciej W. Rozycki <macro@mips.com>
15710 * MAINTAINERS: Update my company e-mail address.
15712 2018-01-22 Yao Qi <yao.qi@linaro.org>
15714 * regcache.c (cooked_write_test): New function.
15715 (_initialize_regcache): Register the test.
15717 2018-01-22 Yao Qi <yao.qi@linaro.org>
15719 * ia64-tdep.c (ia64_pseudo_register_read): Call
15720 regcache->cooked_read instead of regcache_cooked_read_unsigned.
15721 * m32c-tdep.c (m32c_cat_read): Likewise.
15722 (m32c_r3r2r1r0_read): Likewise.
15723 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
15724 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
15726 2018-01-22 Yao Qi <yao.qi@linaro.org>
15728 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
15729 method raw_read instead of regcache_raw_read.
15730 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
15731 * arm-tdep.c (arm_neon_quad_read): Likewise.
15732 * avr-tdep.c (avr_pseudo_register_read): Likewise.
15733 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
15734 * frv-tdep.c (frv_pseudo_register_read): Likewise.
15735 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
15736 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
15737 (i386_pseudo_register_read_into_value): Likewise.
15738 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
15739 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
15740 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
15741 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
15742 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
15743 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
15744 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
15745 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
15746 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
15748 2018-01-22 Yao Qi <yao.qi@linaro.org>
15750 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
15751 * configure.tgt: Remove target mt.
15752 * mt-tdep.c: Remove.
15753 * regcache.c (cooked_read_test): Remove the check for mt.
15755 2018-01-22 Yao Qi <yao.qi@linaro.org>
15757 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
15758 instead of gdbarch_pseudo_register_read_value.
15760 2018-01-22 Joel Brobecker <brobecker@adacore.com>
15762 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
15765 2018-01-22 Joel Brobecker <brobecker@adacore.com>
15767 * linespec.c (create_sals_line_offset): Remove code that preserved
15768 the symtab_and_line's line number.
15770 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
15772 * varobj.c (varobj_create): Don't set valid_block when creating a
15775 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
15777 * varobj.c (varobj_create): Remove out of date comment.
15779 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
15782 * ada-exp.y (write_var_from_sym): Pass extra parameter when
15783 updating innermost block.
15784 * parse.c (innermost_block_tracker::update): Take extra type
15785 parameter, and check types match before updating innermost block.
15786 (write_dollar_variable): Update innermost block for registers.
15787 * parser-defs.h (enum innermost_block_tracker_type): New enum.
15788 (innermost_block_tracker::innermost_block_tracker): Initialise
15790 (innermost_block_tracker::reset): Take type parameter.
15791 (innermost_block_tracker::update): Take type parameter, and pass
15792 type through as needed.
15793 (innermost_block_tracker::m_types): New member.
15794 * varobj.c (varobj_create): Pass type when reseting innermost
15797 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
15799 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
15800 * ada-lang.c (resolve_subexp): Likewise.
15801 * breakpoint.c (set_breakpoint_condition) Likewise.
15802 (watch_command_1) Likewise.
15803 * c-exp.y (variable): Likewise.
15804 * d-exp.y (PrimaryExpression): Likewise.
15805 * f-exp.y (variable): Likewise.
15806 * go-exp.y (variable): Likewise.
15807 * m2-exp.y (variable): Likewise.
15808 * objfiles.c (objfile::~objfile): Likewise.
15809 * p-exp.y (variable): Likewise.
15810 * parse.c (innermost_block): Change type.
15811 * parser-defs.h (class innermost_block_tracker): New.
15812 (innermost_block): Change to innermost_block_tracker.
15813 * printcmd.c (display_command): Switch to innermost_block API.
15814 (do_one_display): Likewise.
15815 * rust-exp.y (do_one_display): Likewise.
15816 * symfile.c (clear_symtab_users): Likewise.
15817 * varobj.c (varobj_create): Switch to innermost_block API, replace
15818 use of innermost_block with block stored on varobj object.
15820 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
15822 * expression.h (innermost_block): Remove declaration.
15823 * varobj.c: Add 'parser-defs.h' include.
15825 2018-01-19 Tom Tromey <tom@tromey.com>
15827 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
15828 symbols in the static and global blocks.
15830 2018-01-19 James Clarke <jrtc27@jrtc27.com>
15832 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
15833 gdb_ptrace.h, and move including gdb_wait.h ...
15834 * nat/linux-ptrace.h: ... to here.
15836 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
15838 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
15839 inf_ptrace_detach_success.
15840 (inf_ptrace_detach_success): Add inferior parameter, use it
15841 instead of inferior_ptid, pass it to detach_inferior.
15842 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
15844 * inferior.c (detach_inferior): Add overload that takes an
15846 * inferior.h (detach_inferior): Likewise.
15847 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
15848 use inferior_ptid, adjust call to inf_ptrace_detach_success.
15849 * linux-thread-db.c (thread_db_detach): Use inf parameter.
15851 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
15853 * target.h (struct target_ops) <to_detach>: Add inferior
15855 (target_detach): Likewise.
15856 * target.c (dispose_inferior): Pass inferior down.
15857 (target_detach): Pass inferior down. Assert that it is equal to
15858 the current inferior.
15859 * aix-thread.c (aix_thread_detach): Pass inferior down.
15860 * corefile.c (core_file_command): Pass current_inferior() down.
15861 * corelow.c (core_detach): Add inferior parameter.
15862 * darwin-nat.c (darwin_detach): Likewise.
15863 * gnu-nat.c (gnu_detach): Likewise.
15864 * inf-ptrace.c (inf_ptrace_detach): Likewise.
15865 * infcmd.c (detach_command): Pass current_inferior() down to
15867 * infrun.c (follow_fork_inferior): Pass parent_inf to
15869 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
15871 * linux-nat.c (linux_nat_detach): Add inferior parameter.
15872 * linux-thread-db.c (thread_db_detach): Likewise.
15873 * nto-procfs.c (procfs_detach): Likewise.
15874 * procfs.c (procfs_detach): Likewise.
15875 * record.c (record_detach): Likewise.
15876 * record.h (struct inferior): Forward-declare.
15877 (record_detach): Add inferior parameter.
15878 * remote-sim.c (gdbsim_detach): Likewise.
15879 * remote.c (remote_detach_1): Likewise.
15880 (remote_detach): Likewise.
15881 (extended_remote_detach): Likewise.
15882 * sol-thread.c (sol_thread_detach): Likewise.
15883 * target-debug.h (target_debug_print_inferior_p): New macro.
15884 * target-delegates.c: Re-generate.
15885 * top.c (kill_or_detach): Pass inferior down to target_detach.
15886 * windows-nat.c (windows_detach): Add inferior parameter.
15888 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
15890 * target.h (struct target_ops) <to_detach>: Remove args
15892 (target_detach): Likewise.
15893 * target.c (dispose_inferior): Adjust.
15894 (target_detach): Remove args parameter, adjust.
15895 * aix-thread.c (aix_thread_detach): Adjust.
15896 * corefile.c (core_file_command): Adjust.
15897 * corelow.c (core_detach): Adjust.
15898 * darwin-nat.c (darwin_detach): Adjust.
15899 * gnu-nat.c (gnu_detach): Adjust.
15900 * inf-ptrace.c (inf_ptrace_detach): Adjust.
15901 * infcmd.c (detach_command): Adjust
15902 * infrun.c (follow_fork_inferior): Adjust.
15903 (handle_vfork_child_exec_or_exit): Adjust.
15904 * linux-fork.c (linux_fork_detach): Remove args parameter.
15905 * linux-fork.h (linux_fork_detach): Likewise.
15906 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
15907 * linux-thread-db.c (thread_db_detach): Likewise.
15908 * nto-procfs.c (procfs_detach): Likewise.
15909 * procfs.c (procfs_detach): Likewise.
15910 (do_detach): Remove signo parameter.
15911 * record.c (record_detach): Remove args parameter.
15912 * record.h (record_detach): Likewise.
15913 * remote-sim.c (gdbsim_detach): Likewise.
15914 * remote.c (remote_detach_1): Likewise.
15915 (remote_detach): Likewise.
15916 (extended_remote_detach): Likewise.
15917 * sol-thread.c (sol_thread_detach): Likewise.
15918 * target-delegates.c: Re-generate.
15919 * top.c (struct qt_args) <args>: Remove field.
15920 (kill_or_detach): Don't pass args.
15921 (quit_force): Don't set args.
15922 * windows-nat.c (windows_detach): Remove args parameter.
15924 2018-01-19 Yao Qi <yao.qi@linaro.org>
15926 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
15927 (arm_linux_init_abi): Install it.
15929 2018-01-19 Yao Qi <yao.qi@linaro.org>
15931 * osabi.c (gdb_osabi_names): Extend the regexp for
15932 arm-linux-gnueabihf.
15934 2018-01-18 Yao Qi <yao.qi@linaro.org>
15936 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
15938 (abbrev_table::add_abbrev): Update.
15939 (abbrev_table::lookup_abbrev): Update.
15941 2018-01-18 Yao Qi <yao.qi@linaro.org>
15943 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
15945 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
15947 * compile/compile.c (compile_to_object): Convert "triplet_rx"
15950 2018-01-17 Tom Tromey <tom@tromey.com>
15952 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
15954 2018-01-17 Tom Tromey <tom@tromey.com>
15956 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
15957 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
15958 (create_array_type_with_stride): Update.
15959 * dwarf2read.c (set_die_type): Update.
15961 2018-01-17 Tom Tromey <tom@tromey.com>
15963 * dwarf2read.c (delayed_method_info): Remove typedef.
15964 (dwarf2_cu::method_info): Now a std::vector.
15965 (add_to_method_list): Update.
15966 (free_delayed_list): Remove.
15967 (compute_delayed_physnames): Update.
15968 (process_full_comp_unit, process_full_type_unit): Clear the method
15969 list. Remove cleanups.
15970 (psymtab_include_file_name): Add name_holder parameter. Use
15971 unique_xmalloc_ptr.
15972 (dwarf_decode_lines): Update.
15974 2018-01-17 Tom Tromey <tom@tromey.com>
15975 Simon Marchi <simon.marchi@ericsson.com>
15977 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
15978 (dwarf2_per_objfile::free_cached_comp_units)
15979 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
15980 (init_cutu_and_read_dies_no_follow): Update.
15981 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
15982 (dwarf2_cu::~dwarf2_cu): New.
15983 (free_heap_comp_unit, free_stack_comp_unit): Remove.
15984 (age_cached_comp_units, free_one_cached_comp_unit): Update.
15986 2018-01-17 Tom Tromey <tom@tromey.com>
15987 Simon Marchi <simon.marchi@ericsson.com>
15989 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
15990 (struct die_reader_specs) <abbrev_table>: New member.
15991 (struct abbrev_table): Add constructor.
15992 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
15993 <abbrev_obstack>: Now an auto_obstack.
15994 (abbrev_table_up): New typedef.
15995 (init_cu_die_reader): Add abbrev_table parameter.
15996 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
15997 Add result_dwo_abbrev_table.
15998 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
15999 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
16001 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
16003 (skip_children): Update.
16004 (abbrev_table::alloc_abbrev): Rename from
16005 abbrev_table_alloc_abbrev.
16006 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
16007 (abbrev_table::lookup_abbrev): Rename from
16008 abbrev_table_lookup_abbrev.
16009 (abbrev_table_read_table): Return abbrev_table_up.
16010 (abbrev_table_free, abbrev_table_free_cleanup)
16011 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
16012 (load_partial_dies): Update.
16014 2018-01-17 Tom Tromey <tom@tromey.com>
16016 * dwarf2read.c (dwarf2_compute_name): Update comment.
16017 (read_func_scope, read_variable): Update.
16018 (new_symbol): Remove.
16019 (new_symbol_full): Rename to new_symbol.
16021 2018-01-17 Mike Gulick <mgulick@mathworks.com>
16024 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
16025 a warning instead of throwing an error, set section size to 0 and return
16027 * gdb_bfd.h (gdb_bfd_map_section): Update description.
16029 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
16031 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
16033 (linux_ptrace_attach_fail_reason_string): Likewise.
16034 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
16036 (linux_ptrace_attach_fail_reason_string): Likewise.
16037 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
16039 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
16041 * linux-nat.c (linux_nat_attach): Remove xstrdup.
16043 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
16046 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
16047 checking for fs_base/gs_base fields in struct user_regs_struct.
16048 * configure: Regenerate.
16050 2018-01-17 Yao Qi <yao.qi@linaro.org>
16052 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
16054 (aarch64_linux_init_abi): Install it to gdbarch hook
16055 gcc_target_options.
16057 2018-01-15 Pedro Alves <palves@redhat.com>
16059 * common/signals-state-save-restore.c
16060 (save_original_signals_state): Fix typos.
16062 2017-01-12 Tom Tromey <tom@tromey.com>
16063 Sergio Durigan Junior <sergiodj@redhat.com>
16065 * Makefile.in (install-only): Install gdb-add-index.
16067 2018-01-12 John Baldwin <jhb@FreeBSD.org>
16069 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
16071 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
16073 * infrun.c (keep_going_pass_signal): Clear step-over info when
16074 insert_breakpoints fails.
16076 2018-01-11 Pedro Alves <palves@redhat.com>
16079 * infrun.c (resume): Rename to ...
16080 (resume_1): ... this.
16081 (resume): Reimplement as wrapper around resume_1.
16083 2018-01-11 Pedro Alves <palves@redhat.com>
16086 * remote.c (remote_parse_stop_reply): Default to the last-set
16087 general thread instead of to 'magic_null_ptid'.
16089 2018-01-10 Pedro Alves <palves@redhat.com>
16091 * language.h (language_get_symbol_name_matcher): Rename ...
16092 (get_symbol_name_matcher): ... this.
16093 * language.c (language_get_symbol_name_matcher): Ditto.
16094 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
16097 2018-01-10 Pedro Alves <palves@redhat.com>
16101 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
16102 Adjust to use language_get_symbol_name_matcher instead of
16103 language_defn::la_get_symbol_name_matcher.
16104 * language.c (language_get_symbol_name_matcher): If in Ada mode
16105 and the lookup name is a verbatim match, return Ada's matcher.
16106 * language.h (language_get_symbol_name_matcher): Adjust comment.
16107 (ada_lookup_name_info::verbatim_p):: New method.
16109 2018-01-10 Pedro Alves <palves@redhat.com>
16112 * ada-lang.c (ada_collect_symbol_completion_matches): If the
16113 minsym's language is language_auto or language_cplus, pass down
16114 language_ada instead.
16115 * symtab.c (compare_symbol_name): Don't frob symbol language here.
16117 2018-01-10 Pedro Alves <palves@redhat.com>
16120 * minsyms.c (linkage_name_str): New function.
16121 (iterate_over_minimal_symbols): Use it.
16123 2018-01-09 John Baldwin <jhb@FreeBSD.org>
16125 * NEWS: Document that 'info proc' now works on FreeBSD.
16127 2018-01-09 John Baldwin <jhb@FreeBSD.org>
16129 * configure.ac: Check for kinfo_getfile in libutil.
16130 * configure: Regenerate.
16131 * config.in: Regenerate.
16132 * fbsd-nat.c: Include "fbsd-tdep.h".
16133 (fbsd_fetch_cmdline): New.
16134 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
16135 rather than calling error.
16136 (fbsd_info_proc): New.
16137 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
16138 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
16139 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
16141 2018-01-09 John Baldwin <jhb@FreeBSD.org>
16143 * fbsd-nat.c (struct free_deleter): Remove.
16144 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
16146 2018-01-09 John Baldwin <jhb@FreeBSD.org>
16148 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
16149 NULL for an empty pathname.
16151 2018-01-09 John Baldwin <jhb@FreeBSD.org>
16153 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
16154 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
16155 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
16156 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
16157 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
16158 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
16159 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
16160 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
16161 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
16162 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
16163 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
16164 (fbsd_core_fetch_timeval, fbsd_print_sigset)
16165 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
16166 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
16167 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
16169 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
16171 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
16172 (gnu_xfer_auxv): New function.
16173 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
16174 TARGET_OBJECT_AUXV.
16176 2018-01-08 Yao Qi <yao.qi@linaro.org>
16177 Simon Marchi <simon.marchi@ericsson.com>
16179 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
16181 (COMMON_OBS): Remove selftest.o.
16182 * configure.ac: Append selftest-arch.c and common/selftest.c to
16183 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
16184 * configure: Re-generated.
16185 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
16187 (maintenance_info_selftests): Likewise.
16189 2018-01-08 Xavier Roirand <roirand@adacore.com>
16191 * ada-valprint.c (val_print_packed_array_elements): Use
16192 proper number of elements when printing an array indexed
16193 by an enumeration type.
16195 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
16197 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
16198 (dw2_get_file_names_reader): Adjust.
16199 (lookup_dwo_signatured_type): Adjust.
16200 (lookup_dwp_signatured_type): Adjust.
16201 (lookup_signatured_type): Adjust.
16202 (create_type_unit_group): Adjust.
16203 (get_type_unit_group): Adjust.
16204 (process_psymtab_comp_unit_reader): Adjust.
16205 (build_type_psymtabs_reader): Adjust.
16206 (scan_partial_symbols): Adjust.
16207 (add_partial_symbol): Adjust.
16208 (add_partial_subprogram): Adjust.
16209 (peek_die_abbrev): Adjust.
16210 (fixup_go_packaging): Adjust.
16211 (process_imported_unit_die): Adjust.
16212 (dwarf2_compute_name): Adjust.
16213 (dwarf2_physname): Adjust.
16214 (read_import_statement): Adjust.
16215 (handle_DW_AT_stmt_list): Adjust.
16216 (read_file_scope): Adjust.
16217 (read_func_scope): Adjust.
16218 (read_lexical_block_scope): Adjust.
16219 (read_call_site_scope): Adjust.
16220 (read_variable): Adjust.
16221 (dwarf2_rnglists_process): Adjust.
16222 (dwarf2_ranges_process): Adjust.
16223 (dwarf2_ranges_read): Adjust.
16224 (dwarf2_get_pc_bounds): Adjust.
16225 (dwarf2_record_block_ranges): Adjust.
16226 (dwarf2_add_field): Adjust.
16227 (dwarf2_add_member_fn): Adjust.
16228 (read_structure_type): Adjust.
16229 (process_structure_scope): Adjust.
16230 (read_enumeration_type): Adjust.
16231 (read_array_type): Adjust.
16232 (mark_common_block_symbol_computed): Adjust.
16233 (read_common_block): Adjust.
16234 (read_namespace_type): Adjust.
16235 (read_namespace): Adjust.
16236 (read_module_type): Adjust.
16237 (read_tag_pointer_type): Adjust.
16238 (read_tag_ptr_to_member_type): Adjust.
16239 (read_tag_string_type): Adjust.
16240 (read_subroutine_type): Adjust.
16241 (read_typedef): Adjust.
16242 (read_base_type): Adjust.
16243 (attr_to_dynamic_prop): Adjust.
16244 (read_subrange_type): Adjust.
16245 (read_unspecified_type): Adjust.
16246 (dwarf2_read_abbrevs): Adjust.
16247 (load_partial_dies): Adjust.
16248 (read_partial_die): Adjust.
16249 (find_partial_die): Adjust.
16250 (guess_partial_die_structure_name): Adjust.
16251 (fixup_partial_die): Adjust.
16252 (read_attribute_value): Adjust.
16253 (read_addr_index): Adjust.
16254 (read_addr_index_from_leb128): Adjust.
16255 (read_str_index): Adjust.
16256 (dwarf2_string_attr): Adjust.
16257 (get_debug_line_section): Adjust.
16258 (dwarf_decode_line_header): Adjust.
16259 (lnp_state_machine::check_line_address): Adjust.
16260 (dwarf_decode_lines_1): Adjust.
16261 (dwarf_decode_lines): Adjust.
16262 (dwarf2_start_symtab): Adjust.
16263 (var_decode_location): Adjust.
16264 (new_symbol_full): Adjust.
16265 (dwarf2_const_value_data): Adjust.
16266 (dwarf2_const_value_attr): Adjust.
16267 (dwarf2_const_value): Adjust.
16268 (die_type): Adjust.
16269 (die_containing_type): Adjust.
16270 (build_error_marker_type): Adjust.
16271 (lookup_die_type): Adjust.
16272 (guess_full_die_structure_name): Adjust.
16273 (anonymous_struct_prefix): Adjust.
16274 (determine_prefix): Adjust.
16275 (dwarf2_name): Adjust.
16276 (follow_die_ref_or_sig): Adjust.
16277 (follow_die_offset): Adjust.
16278 (follow_die_ref): Adjust.
16279 (follow_die_sig_1): Adjust.
16280 (follow_die_sig): Adjust.
16281 (get_signatured_type): Adjust.
16282 (get_DW_AT_signature_type): Adjust.
16283 (decode_locdesc): Adjust.
16284 (dwarf_decode_macros): Adjust.
16285 (cu_debug_loc_section): Adjust.
16286 (fill_in_loclist_baton): Adjust.
16287 (dwarf2_symbol_mark_computed): Adjust.
16288 (init_one_comp_unit): Don't assign
16289 dwarf2_cu::dwarf2_per_objfile.
16290 (set_die_type): Adjust.
16292 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
16294 * dwarf2read.c (struct mapped_debug_names): Add constructor.
16295 <dwarf2_per_objfile>: New field.
16296 (dwarf2_per_objfile): Remove global.
16297 (get_dwarf2_per_objfile): New function.
16298 (set_dwarf2_per_objfile): New function.
16299 (dwarf2_build_psymtabs_hard): Change objfile parameter to
16300 dwarf2_per_objfile.
16301 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
16302 (read_abbrev_offset): Likewise.
16303 (read_indirect_string): Likewise.
16304 (read_indirect_line_string): Likewise.
16305 (read_indirect_string_at_offset): Likewise.
16306 (read_indirect_string_from_dwz): Likewise.
16307 (dwarf2_find_containing_comp_unit): Change objfile parameter to
16308 dwarf2_per_objfile.
16309 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
16310 (create_all_comp_units): Change objfile parameter to
16311 dwarf2_per_objfile.
16312 (create_all_type_units): Likewise.
16313 (process_queue): Add dwarf2_per_objfile parameter.
16314 (read_and_check_comp_unit_head): Likewise.
16315 (lookup_dwo_unit_in_dwp): Likewise.
16316 (get_dwp_file): Likewise.
16317 (process_cu_includes): Likewise.
16318 (struct free_dwo_file_cleanup_data): New struct.
16319 (dwarf2_has_info): Use get_dwarf2_per_objfile and
16320 set_dwarf2_per_objfile.
16321 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
16322 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
16323 context, adjust calls.
16324 (dw2_instantiate_symtab): Likewise.
16325 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
16326 (dw2_get_cu): Likewise.
16327 (create_cu_from_index_list): Change objfile parameter to
16328 dwarf2_per_objfile.
16329 (create_cus_from_index_list): Get dwarf2_per_objfile from
16330 context, adjust calls.
16331 (create_cus_from_index): Likewise.
16332 (create_signatured_type_table_from_index): Change objfile
16333 parameter to dwarf2_per_objfile.
16334 (create_signatured_type_table_from_debug_names): Change objfile
16335 parameter to dwarf2_per_objfile.
16336 (create_addrmap_from_index): Likewise.
16337 (create_addrmap_from_aranges): Likewise.
16338 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
16339 (dw2_setup): Remove.
16340 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
16342 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
16343 get_dwarf2_per_objfile.
16344 (dw2_forget_cached_source_info): Likewise.
16345 (dw2_map_symtabs_matching_filename): Likewise.
16346 (struct dw2_symtab_iterator) <index>: Remove.
16347 <dwarf2_per_objfile>: New field.
16348 (dw2_symtab_iter_init): Replace index parameter with
16349 dwarf2_per_objfile.
16350 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
16351 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
16352 (dw2_print_stats): Likewise.
16353 (dw2_dump): Likewise.
16354 (dw2_expand_symtabs_for_function): Likewise.
16355 (dw2_expand_all_symtabs): Likewise.
16356 (dw2_expand_symtabs_with_fullname): Likewise.
16357 (dw2_expand_marked_cus): Replace index and objfile parameters
16358 with dwarf2_per_objfile.
16359 (dw_expand_symtabs_matching_file_matcher): Add
16360 dwarf2_per_objfile parameter and adjust calls.
16361 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
16363 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
16364 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
16366 (create_cus_from_debug_names_list): Replace objfile parameter
16367 with dwarf2_per_objfile and adjust calls.
16368 (create_cus_from_debug_names): Likewise.
16369 (dwarf2_read_debug_names): Likewise.
16370 (mapped_debug_names::namei_to_name): Adjust call.
16371 (dw2_debug_names_iterator::next): Likewise.
16372 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
16373 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
16374 (dw2_debug_names_dump): Likewise.
16375 (dw2_debug_names_expand_symtabs_for_function): Likewise.
16376 (dw2_debug_names_expand_symtabs_matching): Likewise.
16377 (dwarf2_initialize_objfile): Likewise.
16378 (dwarf2_build_psymtabs): Likewise.
16379 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
16381 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
16382 (read_and_check_comp_unit_head): Likewise.
16383 (read_abbrev_offset): Likewise.
16384 (create_debug_type_hash_table): Likewise.
16385 (create_debug_types_hash_table): Likewise.
16386 (create_all_type_units): Replace objfile parameter with
16387 dwarf2_per_objfile.
16388 (add_type_unit): Add dwarf2_per_objfile parameter.
16389 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
16390 with dwarf2_per_objfile.
16391 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
16392 (lookup_dwp_signatured_type): Likewise.
16393 (lookup_signatured_type): Likewise.
16394 (read_cutu_die_from_dwo): Likewise.
16395 (init_tu_and_read_dwo_dies): Likewise.
16396 (init_cutu_and_read_dies): Likewise.
16397 (init_cutu_and_read_dies_no_follow): Likewise.
16398 (allocate_type_unit_groups_table): Add objfile parameter.
16399 (create_type_unit_group): Use dwarf2_per_objfile from cu.
16400 (get_type_unit_group): Likewise.
16401 (process_psymtab_comp_unit): Update call.
16402 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
16403 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
16404 (print_tu_stats): Likewise.
16405 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
16406 in void* parameter.
16407 (build_type_psymtabs): Change objfile parameter to
16408 dwarf2_per_objfile.
16409 (process_skeletonless_type_unit): Use dwarf2_per_objfile
16410 passed in void* parameter.
16411 (process_skeletonless_type_units): Change objfile parameter to
16412 dwarf2_per_objfile.
16413 (set_partial_user): Likewise.
16414 (dwarf2_build_psymtabs_hard): Likewise.
16415 (read_comp_units_from_section): Likewise.
16416 (create_all_comp_units): Likewise.
16417 (scan_partial_symbols): Update calls.
16418 (add_partial_symbol): Likewise.
16419 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
16420 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
16421 (process_queue): Add dwarf2_per_objfile parameter.
16422 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
16423 (compute_compunit_symtab_includes): Likewise.
16424 (process_cu_includes): Add dwarf2_per_objfile parameter.
16425 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
16426 (process_full_type_unit): Likewise.
16427 (process_imported_unit_die): Update call.
16428 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
16429 (read_file_scope): Likewise.
16430 (allocate_dwo_file_hash_table): Add objfile parameter.
16431 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
16432 (create_cus_hash_table): Likewise.
16433 (create_dwp_hash_table): Likewise.
16434 (create_dwo_unit_in_dwp_v1): Likewise.
16435 (create_dwp_v2_section): Likewise.
16436 (create_dwo_unit_in_dwp_v2): Likewise.
16437 (lookup_dwo_unit_in_dwp): Likewise.
16438 (try_open_dwop_file): Likewise.
16439 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
16440 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
16441 cleanup to include a reference to dwarf2_per_objfile.
16442 (open_dwp_file): Add dwarf2_per_objfile parameter.
16443 (open_and_init_dwp_file): Likewise.
16444 (get_dwp_file): Likewise.
16445 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
16446 (queue_and_load_all_dwo_tus): Update call.
16447 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
16449 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
16450 (dwarf2_ranges_process): Likewise.
16451 (dwarf2_get_pc_bounds): Likewise.
16452 (mark_common_block_symbol_computed): Likewise.
16453 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
16454 (dwarf2_read_abbrevs): Update call.
16455 (read_partial_die): Use dwarf2_per_objfile from cu.
16456 (find_partial_die): Likewise.
16457 (fixup_partial_die): Likewise.
16458 (read_attribute_value): Likewise.
16459 (read_indirect_string_at_offset_from): Add objfile parameter.
16460 (read_indirect_string_at_offset): Add dwarf2_per_objfile
16462 (read_indirect_string_from_dwz): Add objfile parameter.
16463 (read_indirect_string): Add objfile parameter.
16464 (read_addr_index_1): Add dwarf2_per_objfile parameter.
16465 (read_addr_index): Use dwarf2_per_objfile from cu.
16466 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
16468 (read_str_index): Use dwarf2_per_objfile from cu.
16469 (get_debug_line_section): Likewise.
16470 (read_formatted_entries): Add dwarf2_per_objfile parameter.
16471 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
16472 (new_symbol_full): Use dwarf2_per_objfile from cu.
16473 (build_error_marker_type): Likewise.
16474 (lookup_die_type): Likewise.
16475 (determine_prefix): Likewise.
16476 (follow_die_offset): Likewise.
16477 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
16478 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
16479 (dwarf2_fetch_die_type_sect_off): Likewise.
16480 (dwarf2_get_die_type): Likewise.
16481 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
16482 (get_signatured_type): Likewise.
16483 (get_DW_AT_signature_type): Likewise.
16484 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
16485 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
16486 (cu_debug_loc_section): Likewise.
16487 (fill_in_loclist_baton): Likewise.
16488 (dwarf2_symbol_mark_computed): Likewise.
16489 (dwarf2_find_containing_comp_unit): Change objfile parameter to
16490 dwarf2_per_objfile.
16491 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
16493 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
16494 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
16495 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
16496 (set_die_type): Use dwarf2_free_objfile from cu.
16497 (get_die_type_at_offset): Likewise.
16498 (dwarf2_per_objfile_free): Don't assign global variable.
16499 (debug_names) <constructor>: Add dwarf2_per_objfile
16500 parameter, update m_debugstrlookup construction.
16501 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
16503 <m_dwarf2_per_objfile>: New field.
16504 <lookup>: Use m_dwarf2_per_objfile.
16505 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
16506 (psyms_seen_size): Likewise.
16507 (write_gdbindex): Replace objfile parameter with
16508 dwarf2_per_objfile.
16509 (write_debug_names): Likewise.
16510 (write_psymtabs_to_index): Likewise.
16511 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
16514 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
16516 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
16517 <dwarf2_per_objfile>: New field.
16518 (struct dwarf2_per_cu_data) <objfile>: Remove.
16519 <dwarf2_per_objfile>: New field.
16520 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
16522 (create_signatured_type_table_from_index): Likewise.
16523 (create_debug_type_hash_table): Likewise.
16524 (fill_in_sig_entry_from_dwo_entry): Likewise.
16525 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
16526 (create_type_unit_group): Assign dwarf2_per_objfile instead of
16528 (create_partial_symtab): Access objfile through
16529 dwarf2_per_objfile.
16530 (process_psymtab_comp_unit_reader): Likewise.
16531 (read_comp_units_from_section): Likewise.
16532 (scan_partial_symbols): Likewise.
16533 (add_partial_symbol): Likewise.
16534 (add_partial_subprogram): Likewise.
16535 (peek_die_abbrev): Likewise.
16536 (fixup_go_packaging): Likewise.
16537 (process_full_comp_unit): Likewise.
16538 (process_full_type_unit): Likewise.
16539 (process_imported_unit_die): Likewise.
16540 (dwarf2_compute_name): Likewise.
16541 (dwarf2_physname): Likewise.
16542 (read_import_statement): Likewise.
16543 (create_cus_hash_table): Assign dwarf2_physname instead of
16545 (read_func_scope): Access objfile through dwarf2_per_objfile.
16546 (read_lexical_block_scope): Likewise.
16547 (read_call_site_scope): Likewise.
16548 (read_variable): Likewise.
16549 (dwarf2_rnglists_process): Likewise.
16550 (dwarf2_ranges_process): Likewise.
16551 (dwarf2_ranges_read): Likewise.
16552 (dwarf2_record_block_ranges): Likewise.
16553 (dwarf2_add_field): Likewise.
16554 (dwarf2_add_member_fn): Likewise.
16555 (read_structure_type): Likewise.
16556 (process_structure_scope): Likewise.
16557 (read_enumeration_type): Likewise.
16558 (read_array_type): Likewise.
16559 (read_common_block): Likewise.
16560 (read_namespace_type): Likewise.
16561 (read_namespace): Likewise.
16562 (read_module_type): Likewise.
16563 (read_tag_pointer_type): Likewise.
16564 (read_tag_ptr_to_member_type): Likewise.
16565 (read_tag_string_type): Likewise.
16566 (read_subroutine_type): Likewise.
16567 (read_typedef): Likewise.
16568 (read_base_type): Likewise.
16569 (attr_to_dynamic_prop): Likewise.
16570 (read_subrange_type): Likewise.
16571 (read_unspecified_type): Likewise.
16572 (load_partial_dies): Likewise.
16573 (read_partial_die): Likewise.
16574 (find_partial_die): Likewise.
16575 (guess_partial_die_structure_name): Likewise.
16576 (fixup_partial_die): Likewise.
16577 (read_attribute_value): Likewise.
16578 (read_addr_index_from_leb128): Likewise.
16579 (dwarf2_read_addr_index): Likewise.
16580 (dwarf2_string_attr): Likewise.
16581 (lnp_state_machine::check_line_address): Likewise.
16582 (dwarf_decode_lines_1): Likewise.
16583 (dwarf_decode_lines): Likewise.
16584 (dwarf2_start_symtab): Likewise.
16585 (var_decode_location): Likewise.
16586 (new_symbol_full): Likewise.
16587 (dwarf2_const_value_data): Likewise.
16588 (dwarf2_const_value_attr): Likewise.
16589 (dwarf2_const_value): Likewise.
16590 (die_type): Likewise.
16591 (die_containing_type): Likewise.
16592 (lookup_die_type): Likewise.
16593 (guess_full_die_structure_name): Likewise.
16594 (anonymous_struct_prefix): Likewise.
16595 (dwarf2_name): Likewise.
16596 (follow_die_ref_or_sig): Likewise.
16597 (follow_die_offset): Likewise.
16598 (follow_die_ref): Likewise.
16599 (dwarf2_fetch_die_loc_sect_off): Likewise.
16600 (dwarf2_fetch_constant_bytes): Likewise.
16601 (dwarf2_fetch_die_type_sect_off): Likewise.
16602 (dwarf2_get_die_type): Likewise.
16603 (follow_die_sig): Likewise.
16604 (decode_locdesc): Likewise.
16605 (dwarf2_per_cu_objfile): Likewise.
16606 (dwarf2_per_cu_text_offset): Likewise.
16607 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
16609 (set_die_type): Access objfile through
16610 dwarf2_per_objfile.
16612 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
16614 * valprint.c (converted_character_d): Remove typedef.
16615 (DEF_VEC_O (converted_character_d)): Remove.
16616 (count_next_character): Use std::vector.
16617 (print_converted_chars_to_obstack): Likewise.
16618 (generic_printstr): Likewise.
16620 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
16622 * xml-support.h (struct gdb_xml_value): Add constructor.
16623 <value>: Change type to unique_xmalloc_ptr.
16624 (gdb_xml_value_s): Remove typedef.
16625 (DEF_VEC_O (gdb_xml_value_s)): Remove.
16626 (gdb_xml_element_start_handler): Change parameter type to
16628 (xml_find_attribute): Likewise.
16629 * xml-support.c (xml_find_attribute): Change parameter type to
16630 std::vector and adjust.
16631 (gdb_xml_values_cleanup): Remove.
16632 (gdb_xml_parser::start_element): Adjust to std::vector.
16633 (xinclude_start_include): Change paraeter type to std::vector
16635 * btrace.c (check_xml_btrace_version): Likewise.
16636 (parse_xml_btrace_block): Likewise.
16637 (parse_xml_btrace_pt_config_cpu): Likewise.
16638 (parse_xml_btrace_pt): Likewise.
16639 (parse_xml_btrace_conf_bts): Likewise.
16640 (parse_xml_btrace_conf_pt): Likewise.
16641 * memory-map.c (memory_map_start_memory): Likewise.
16642 (memory_map_start_property): Likewise.
16643 * osdata.c (osdata_start_osdata): Likewise.
16644 (osdata_start_item): Likewise.
16645 (osdata_start_column): Likewise.
16646 * remote.c (start_thread): Likewise.
16647 * solib-aix.c (library_list_start_library): Likewise.
16648 (library_list_start_list): Likewise.
16649 * solib-svr4.c (library_list_start_library): Likewise.
16650 (svr4_library_list_start_list): Likewise.
16651 * solib-target.c (library_list_start_segment): Likewise.
16652 (library_list_start_section): Likewise.
16653 (library_list_start_library): Likewise.
16654 (library_list_start_list): Likewise.
16655 * tracepoint.c (traceframe_info_start_memory): Likewise.
16656 (traceframe_info_start_tvar): Likewise.
16657 * xml-syscall.c (syscall_start_syscall): Likewise.
16658 * xml-tdesc.c (tdesc_start_target): Likewise.
16659 (tdesc_start_feature): Likewise.
16660 (tdesc_start_reg): Likewise.
16661 (tdesc_start_union): Likewise.
16662 (tdesc_start_struct): Likewise.
16663 (tdesc_start_flags): Likewise.
16664 (tdesc_start_enum): Likewise.
16665 (tdesc_start_field): Likewise.
16666 (tdesc_start_enum_value): Likewise.
16667 (tdesc_start_vector): Likewise.
16669 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
16671 * extension.h (struct xmethod_worker) <clone>: Remove.
16672 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
16674 (python_xmethod_worker::clone): Remove.
16675 * valops.c (find_overload_match): Use std::move instead of
16678 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
16680 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
16681 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
16682 <free_xmethod_worker_data>: Remove.
16683 <get_matching_xmethod_workers>: Chance VEC to std::vector.
16684 <get_xmethod_arg_types>: Remove.
16685 <get_xmethod_result_type>: Remove.
16686 <invoke_xmethod>: Remove.
16687 * extension.c (new_xmethod_worker): Remove.
16688 (clone_xmethod_worker): Remove.
16689 (get_matching_xmethod_workers): Return void, pass std::vector by
16691 (get_xmethod_arg_types): Rename to...
16692 (xmethod_worker::get_arg_types): ... this, and adjust.
16693 (get_xmethod_result_type): Rename to...
16694 (xmethod_worker::get_result_type): ... this, and adjust.
16695 (invoke_xmethod): Remove.
16696 (free_xmethod_worker): Remove.
16697 (free_xmethod_worker_vec): Remove.
16698 * extension.h (enum ext_lang_rc): Move here from
16700 (struct xmethod_worker): Add constructor and destructor.
16703 <invoke, clone, do_get_result_type, do_get_arg_types>: New
16704 virtual pure methods.
16705 <get_arg_types, get_result_type>: New methods.
16706 (xmethod_worker_ptr): Remove typedef.
16707 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
16708 (xmethod_worker_vec): Remove typedef.
16709 (xmethod_worker_up): New typedef.
16710 (invoke_xmethod): Remove.
16711 (clone_xmethod_worker): Remove.
16712 (free_xmethod_worker): Remove.
16713 (free_xmethod_worker_vec): Remove.
16714 (get_xmethod_arg_types): Remove.
16715 (get_xmethod_result_type): Remove.
16716 * valops.c (find_method_list): Use std::vector, don't use
16717 intermediate vector.
16718 (value_find_oload_method_list): Use std::vector.
16719 (find_overload_match): Use std::vector.
16720 (find_oload_champ): Use std::vector.
16721 * value.c (value_free): Use operator delete.
16722 (value_of_xmethod): Rename to...
16723 (value_from_xmethod): ... this. Don't assign
16724 xmethod_worker::value, take rvalue-reference.
16725 (result_type_of_xmethod): Adjust.
16726 (call_xmethod): Adjust.
16727 * value.h: Include extension.h.
16728 (struct xmethod_worker): Don't forward-declare.
16729 (value_of_xmethod): Rename to...
16730 (value_from_xmethod): ... this, take rvalue-reference.
16731 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
16732 (struct python_xmethod_worker): ... this, add constructor and
16734 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
16735 (gdbpy_free_xmethod_worker_data): Rename to...
16736 (python_xmethod_worker::~python_xmethod_worker): ... this and
16738 (gdbpy_clone_xmethod_worker_data): Rename to...
16739 (python_xmethod_worker::clone): ... this and adjust.
16740 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
16742 (gdbpy_get_xmethod_arg_types): Rename to...
16743 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
16744 (gdbpy_get_xmethod_result_type): Rename to...
16745 (python_xmethod_worker::do_get_result_type): ... this and
16747 (gdbpy_invoke_xmethod): Rename to...
16748 (python_xmethod_worker::invoke): ... this and adjust.
16749 (new_python_xmethod_worker): Rename to...
16750 (python_xmethod_worker::python_xmethod_worker): ... this and
16752 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
16754 (gdbpy_free_xmethod_worker_data): Remove.
16755 (gdbpy_get_matching_xmethod_workers): Use std::vector.
16756 (gdbpy_get_xmethod_arg_types): Remove.
16757 (gdbpy_get_xmethod_result_type): Remove.
16758 (gdbpy_invoke_xmethod): Remove.
16759 * python/python.c (python_extension_ops): Remove obsolete
16762 2018-01-05 Pedro Alves <palves@redhat.com>
16765 * common/signals-state-save-restore.c
16766 (save_original_signals_state): New parameter 'quiet'. Warn if we
16767 find a custom handler preinstalled, instead of internal erroring.
16768 But only warn if !quiet.
16769 * common/signals-state-save-restore.h
16770 (save_original_signals_state): New parameter 'quiet'.
16771 * main.c (captured_main_1): Move save_original_signals_state call
16772 after option handling, and pass QUIET.
16774 2018-01-05 Pedro Alves <palves@redhat.com>
16776 * spu-tdep.c (spu_catch_start): Pass
16777 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
16779 2018-01-05 Pedro Alves <palves@redhat.com>
16782 * ada-lang.c (literal_symbol_name_matcher): New function.
16783 (ada_get_symbol_name_matcher): Use it for
16784 symbol_name_match_type::SEARCH_NAME.
16785 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
16786 it down instead of assuming symbol_name_match_type::FULL.
16787 * block.h (block_lookup_symbol): New parameter 'match_type'.
16788 * c-valprint.c (print_unpacked_pointer): Use
16789 lookup_symbol_search_name instead of lookup_symbol.
16790 * compile/compile-object-load.c (get_out_value_type): Pass down
16791 symbol_name_match_type::SEARCH_NAME.
16792 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
16793 symbol_name_match_type::FULL.
16794 * cp-support.c (cp_get_symbol_name_matcher): Handle
16795 symbol_name_match_type::SEARCH_NAME.
16796 * infrun.c (insert_exception_resume_breakpoint): Use
16797 lookup_symbol_search_name.
16798 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
16799 * psymtab.c (maintenance_check_psymtabs): Use
16800 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
16801 * stack.c (print_frame_args): Use lookup_symbol_search_name and
16802 SYMBOL_SEARCH_NAME.
16803 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
16804 if symbol_name_match_type::SEARCH_NAME.
16805 (lookup_symbol_in_language): Pass down
16806 symbol_name_match_type::FULL.
16807 (lookup_symbol_search_name): New.
16808 (lookup_language_this): Pass down
16809 symbol_name_match_type::SEARCH_NAME.
16810 (lookup_symbol_aux, lookup_local_symbol): New parameter
16811 'match_type'. Pass it down.
16812 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
16813 (lookup_symbol_search_name): New declaration.
16814 (lookup_symbol_in_block): New 'match_type' parameter.
16816 2018-01-05 Pedro Alves <palves@redhat.com>
16819 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
16821 (ada_lookup_symbol): Reimplement in terms of
16822 ada_lookup_symbol_list, bits factored out from
16823 ada_lookup_encoded_symbol.
16825 2018-01-05 Joel Brobecker <brobecker@adacore.com>
16827 * ada-exp.y (write_object_renaming): When subscripting an array
16828 using a symbol as the index, pass the block in call to
16829 ada_lookup_encoded_symbol when looking that symbol up.
16831 2018-01-05 Jerome Guitton <guitton@adacore.com>
16833 * ada-lang.c (ada_array_length): Use ada_index_type instead of
16836 2018-01-05 Joel Brobecker <brobecker@adacore.com>
16838 * ada-lang.c (ada_to_fixed_value_create): Add handling of
16839 the case where VALUE_LVAL (val0) is not lval_memory.
16841 2018-01-05 Xavier Roirand <roirand@adacore.com>
16843 * ada-valprint.c (print_optional_low_bound): Handle
16844 character-indexed array printing like boolean-indexed array
16847 2018-01-05 Joel Brobecker <brobecker@adacore.com>
16849 * NEWS: Create a new section for the next release branch.
16850 Rename the section of the current branch, now that it has
16853 2018-01-05 Joel Brobecker <brobecker@adacore.com>
16855 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
16856 * version.in: Bump version to 8.1.50.DATE-git.
16858 2018-01-03 Xavier Roirand <roirand@adacore.com>
16860 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
16862 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
16864 (default_exception_support_info) <catch_handlers_sym>: Add field.
16865 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
16866 (ada_exception_name_addr_1): Add "catch handlers" handling.
16867 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
16868 Update all callers.
16869 (create_excep_cond_exprs) <ex>: Add parameter.
16870 (re_set_exception): Update create_excep_cond_exprs call.
16871 (print_it_exception, print_one_exception, print_mention_exception)
16872 (print_recreate_exception): Add "catch handler" handling.
16873 (allocate_location_catch_handlers, re_set_catch_handlers)
16874 (check_status_catch_handlers, print_it_catch_handlers)
16875 (print_one_catch_handlers, print_mention_catch_handlers)
16876 (print_recreate_catch_handlers): New function.
16877 (catch_handlers_breakpoint_ops): New variable.
16878 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
16879 Add parameter. Add "catch handler" handling.
16880 (ada_exception_sym_name, ada_exception_breakpoint_ops):
16881 Add "catch handler" handling.
16882 (ada_exception_catchpoint_cond_string): Add "catch handler"
16884 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
16886 (catch_ada_handlers_command): New function.
16887 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
16888 operations structure.
16889 (_initialize_ada_language): Add "catch handlers" command entry.
16890 * NEWS: Document "catch handlers" feature.
16892 2018-01-02 Joel Brobecker <brobecker@adacore.com>
16894 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
16895 account when creating the array type of the slice.
16896 (ada_value_slice): Likewise.
16898 2018-01-02 Joel Brobecker <brobecker@adacore.com>
16900 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
16902 (create_array_type_with_stride): Add byte_stride_prop parameter.
16903 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
16904 New parameter. Update all callers in this file.
16905 (array_type_has_dynamic_stride): New function.
16906 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
16907 of arrays with dynamic byte strides.
16908 * dwarf2read.c (read_array_type): Add support for dynamic
16909 DW_AT_byte_stride attributes.
16911 2018-01-02 Joel Brobecker <brobecker@adacore.com>
16913 * dwarf2read.c (read_unspecified_type): Treat
16914 DW_TAG_enumeration_type DIEs from Ada units as stubs.
16916 2018-01-01 Joel Brobecker <brobecker@adacore.com>
16918 Update copyright year range in all GDB files.
16920 2018-01-01, 18 Joel Brobecker <brobecker@adacore.com>
16922 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
16923 and gdb/testsuite/gdb.base/step-line.c.
16925 2018-01-01 Joel Brobecker <brobecker@adacore.com>
16927 * copyright.py (main): Dump the contents of
16928 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
16929 even if BY_HAND is empty.
16931 2018-01-01 Joel Brobecker <brobecker@adacore.com>
16933 * top.c (print_gdb_version): Update Copyright year in version
16936 2018-01-01 Joel Brobecker <brobecker@adacore.com>
16938 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
16940 For older changes see ChangeLog-2017.
16946 version-control: never