1 2017-11-04 Tom Tromey <tom@tromey.com>
3 * objfiles.c (do_free_objfile_cleanup): Remove.
4 * compile/compile-object-load.c (compile_object_load): Update.
5 * objfiles.h (make_cleanup_free_objfile): Remove.
7 2017-11-04 Tom Tromey <tom@tromey.com>
9 * sparc64-tdep.c (do_examine): Use gdb::def_vector.
10 (adi_read_versions): Change "tags" to "gdb_byte *".
11 (adi_print_versions): Likewise.
13 2017-11-04 Tom Tromey <tom@tromey.com>
16 (scoped_rbreak_breakpoints::scoped_rbreak_breakpoints): Rename
17 from start_rbreak_breakpoints.
18 (scoped_rbreak_breakpoints): Rename from end_rbreak_breakpoints.
19 * breakpoint.h (class scoped_rbreak_breakpoints): New.
20 (start_rbreak_breakpoints, end_rbreak_breakpoints): Remove.
21 * symtab.c (do_end_rbreak_breakpoints): Remove.
22 (rbreak_command): Use scoped_rbreak_breakpoints, std::string.
24 2017-11-04 Tom Tromey <tom@tromey.com>
26 * cp-namespace.c (reset_directive_searched): Remove.
27 (cp_lookup_symbol_via_imports): Use scoped_restore.
28 * cp-support.c (reset_directive_searched): Remove.
29 (make_symbol_overload_list_using): Use scoped_restore.
30 * d-namespace.c (d_lookup_symbol_imports): Use scoped_restore.
31 (reset_directive_searched): Remove.
33 2017-11-04 Tom Tromey <tom@tromey.com>
35 * symfile.c (find_separate_debug_file_by_debuglink): Use
38 2017-11-04 Tom Tromey <tom@tromey.com>
40 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
42 (compute_stack_depth): Likewise.
43 (do_compile_dwarf_expr_to_c): Use std::vector.
45 2017-11-04 Tom Tromey <tom@tromey.com>
47 * compile/compile-object-load.c (link_callbacks_einfo): Use
50 2017-11-04 Tom Tromey <tom@tromey.com>
52 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
53 Use scoped_free_pendings.
54 * dbxread.c (dbx_symfile_read, dbx_psymtab_to_symtab_1): Use
56 * xcoffread.c (xcoff_psymtab_to_symtab_1): Use scoped_free_pendings.
57 (xcoff_initial_scan): Likewise.
58 * buildsym.c (reset_symtab_globals): Update comment.
59 (scoped_free_pendings): Rename from really_free_pendings.
60 (prepare_for_building): Update comment.
61 (buildsym_init): Likewise.
62 * buildsym.h (class scoped_free_pendings): New class.
63 (really_free_pendings): Don't declare.
65 2017-11-03 Ulrich Weigand <uweigand@de.ibm.com>
67 * doublest.c (convert_doublest_to_floatformat): Fix uninitialized
68 output when converting a zero value to a special byteorder format.
70 2017-11-02 Yao Qi <yao.qi@linaro.org>
72 * frame.c (do_frame_register_read): Remove aspace.
73 * jit.c (jit_frame_sniffer): Likwise.
74 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
75 * regcache.c (regcache::regcache): Pass nullptr.
76 (regcache_print): Caller updated.
77 * regcache.h (regcache::regcache): Remove one constructor
80 2017-11-02 Yao Qi <yao.qi@linaro.org>
82 * regcache.h (regcache) <m_readonly_p>: Change it to const bool.
84 2017-11-02 Yao Qi <yao.qi@linaro.org>
86 * breakpoint.c (insert_single_step_breakpoints): Update.
87 * frame.c (struct frame_info) <aspace>: Add const.
88 (frame_save_as_regcache): Add const.
89 (get_frame_address_space): Return const address_space *.
90 * frame.h (get_frame_address_space): Update declaration.
91 * infrun.c (struct step_over_info) <aspace>: Add const.
92 (set_step_over_info): Make aspace const.
93 (displaced_step_prepare_throw): Change variable const.
96 (adjust_pc_after_break): Likewise.
97 (save_waitstatus): Likewise.
98 (handle_signal_stop): Likewise.
99 (keep_going_pass_signal): Likewise.
100 * jit.c (jit_frame_sniffer): Add const.
101 * mips-tdep.c (mips_single_step_through_delay): Likewise.
102 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
103 * record-full.c (record_full_wait_1): Likewise.
104 * regcache.c (regcache::regcache): Change parameter to const.
105 * regcache.h (regcache::regcache): Likewise.
106 (regcache::aspace): Return const address_space *.
107 (regcache) <m_aspace>: Add const.
109 2017-11-02 Yao Qi <yao.qi@linaro.org>
111 * darwin-nat.c (cancel_breakpoint): Use regcache->aspace ().
112 * frame.c (create_sentinel_frame): Likewise.
113 * infrun.c (displaced_step_prepare_throw): Likewise.
115 (thread_still_needs_step_over_bp): Likewise.
117 (do_target_wait): Likewise.
118 (adjust_pc_after_break): Likewise.
119 (handle_syscall_event): Likewise.
120 (save_waitstatus): Likewise.
121 (handle_inferior_event_1): Likewise.
122 (handle_signal_stop): Likewise.
123 (keep_going_pass_signal): Likewise.
124 * linux-nat.c (status_callback): Likewise.
125 (save_stop_reason): Likewise.
126 (resume_stopped_resumed_lwps): Likewise.
127 * record-full.c (record_full_exec_insn): Likewise.
128 (record_full_wait_1): Likewise.
129 * regcache.c (get_regcache_aspace): Remove.
130 * regcache.h (get_regcache_aspace): Remove.
132 2017-11-02 Yao Qi <yao.qi@linaro.org>
134 * regcache.c (struct regcache_descr) <nr_raw_registers>: Remove.
135 (init_regcache_descr): Use gdbarch_num_regs.
136 (regcache::regcache): Likewise.
137 (regcache::get_register_status): Likewise.
138 (regcache::assert_raw_regnum): Likewise.
139 (regcache::cooked_read): Likewise.
140 (regcache::cooked_read_value): Likewise.
141 (regcache::cooked_write): Likewise.
142 (regcache::dump): Likewise.
143 (regcache::num_raw_registers): New method.
144 * regcache.h (class regcache) <num_raw_registers>: New.
146 2017-11-02 Yao Qi <yao.qi@linaro.org>
148 * regcache.c (regcache::assert_regnum): New method.
149 (regcache::invalidate): Call assert_regnum.
150 (regcache::raw_update): Likewise.
151 (regcache::raw_write): Likewise.
152 (regcache::raw_read_part): Likewise.
153 (regcache::raw_write_part): Likewise.
154 (regcache::raw_supply): Likewise.
155 (regcache::raw_supply_integer): Likewise.
156 (regcache::raw_supply_zeroed): Likewise.
157 (regcache::raw_collect): Likewise.
158 (regcache::raw_collect_integer): Likewise.
159 * regcache.h (regcache::assert_regnum): Declare.
161 2017-11-02 Yao Qi <yao.qi@linaro.org>
163 * regcache.c (regcache::dump): Remove code.
165 2017-11-02 Yao Qi <yao.qi@linaro.org>
167 * regcache.c (struct regcache_descr) <sizeof_raw_register_status>:
169 <sizeof_cooked_register_status>: Remove.
170 (init_regcache_descr): Update.
171 (regcache::regcache): Use nr_cooked_registers and nr_raw_registers.
172 (regcache::save): Likewise.
173 (regcache::dump): Likewise.
175 2017-11-01 James Bowman <james.bowman@ftdichip.com>
177 * ft32-tdep.c (ft32_fetch_instruction): New function.
178 (ft32_analyze_prologue): Use ft32_fetch_instruction().
180 2017-10-31 Simon Marchi <simon.marchi@polymtl.ca>
182 * cli/cli-script.c (execute_control_command): Rename to ...
183 (execute_control_command_1): ... this.
184 (execute_control_command): New function.
186 2017-10-31 Simon Marchi <simon.marchi@ericsson.com>
188 * tracepoint.c (tfind_command): Remove const_cast.
190 2017-10-30 Mike Gulick <mgulick@mathworks.com>
192 * Makefile.in (HFILES_NO_SRCDIR): Remove reference to gdb.h.
194 2017-10-30 Simon Marchi <simon.marchi@ericsson.com>
196 * common/common-utils.h (in_inclusive_range): New function.
197 * arm-tdep.c (arm_record_extension_space): Use
199 (thumb_record_ld_st_reg_offset): Use in_inclusive_range.
200 * cris-tdep.c (cris_spec_reg_applicable): Use
203 2017-10-30 Pedro Alves <palves@redhat.com>
204 Simon Marchi <simon.marchi@ericsson.com>
206 * remote.c (remote_set_syscall_catchpoint): Build a std::string
207 instead of a gdb::unique_xmalloc_ptr, using string_appendf.
209 2017-10-30 Pedro Alves <palves@redhat.com>
211 * common/common-utils.c (string_appendf, string_vappendf): New
213 * common/common-utils.h (string_appendf, string_vappendf): New
215 * unittests/common-utils-selftests.c (string_appendf_func)
216 (test_appendf_func, string_vappendf_wrapper, string_appendf_tests)
217 (string_vappendf_tests): New functions.
218 (_initialize_common_utils_selftests): Register "string_appendf" and
219 "string_vappendf tests".
221 2017-10-30 Pedro Alves <palves@redhat.com>
223 * unittests/common-utils-selftests.c (format_func): New typedef.
224 (string_printf_tests, string_vprintf_tests): Tests factored out
226 (test_format_func): ... this new function.
227 (string_printf_tests, string_vprintf_tests): Reimplement on top of
230 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
232 * darwin-nat.c: Remove include of gdb.h.
234 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
236 * xtensa-xtregs.c: Fix formatting issues.
238 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
240 * xtensa-xtregs.c (xtensa_regtable_t) <name>: Constify.
242 2017-10-28 Maksim Dzabraev <dzabraew@gmail.com>
245 * python/py-infthread.c (thpy_get_inferior): Increment reference
246 of inferior before returning it.
248 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
250 * unittests/common-utils-selftests.c (format): Add
253 2017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
255 * xml-syscall.c (struct syscall_desc): Add constructor.
256 <name>: Change type to std::string.
257 (syscall_desc_up): New typedef.
258 (syscall_desc_p): Remove typeder.
259 (DEF_VEC_P(syscall_desc_p)): Remove.
260 (struct syscall_group_desc): Add constructor.
261 <name>: Change type to std::string.
262 <syscalls>: Change type to std::vector.
263 (syscall_group_desc_up): New typedef.
264 (syscall_group_desc_p): Remove typedef.
265 (DEF_VEC_P(syscall_group_desc_p)): Remove.
266 (struct syscalls_info) <syscalls>: Change type to std::vector of
269 <my_gdb_datadir>: Change type to std::string.
270 (syscalls_info_up): New typedef.
271 (allocate_syscalls_info): Remove.
272 (syscalls_info_free_syscalls_desc): Remove.
273 (syscalls_info_free_syscall_group_desc): Remove.
274 (free_syscalls_info): Remove.
275 (make_cleanup_free_syscalls_info): Remove.
276 (syscall_group_create_syscall_group_desc): Adjust.
277 (syscall_group_add_syscall): Adjust.
278 (syscall_create_syscall_desc): Adjust.
279 (syscall_parse_xml): Adjust, use unique_ptr instead of cleanup.
280 (init_syscalls_info): Adjust.
281 (syscall_group_get_group_by_name): Adjust.
282 (xml_get_syscall_number): Adjust.
283 (xml_get_syscall_name): Adjust.
284 (xml_list_of_syscalls): Adjust.
285 (xml_list_syscalls_by_group): Adjust.
286 (xml_list_of_groups): Adjust.
288 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
290 * probe.h: Don't include gdb_vecs.h.
291 (DEF_VEC_P (probe_p)): Remove.
292 (find_probes_in_objfile): Return an std::vector.
293 * probe.c (find_probes_in_objfile): Likewise.
294 * breakpoint.c (breakpoint_objfile_data)
295 <longjmp_probes>: Change type to std::vector.
296 <exception_probes>: Likewise.
297 (free_breakpoint_probes): Don't manually free vectors.
298 (create_longjmp_master_breakpoint): Adjust.
299 (create_exception_master_breakpoint): Adjust.
300 * solib-svr4.c (svr4_create_probe_breakpoints): Change
301 parameter type, adjust.
302 (svr4_create_solib_event_breakpoints): Adjust.
304 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
306 * breakpoint.c (breakpoint_objfile_data): Initialize fields.
307 (get_breakpoint_objfile_data): Allocate breakpoint_objfile_data
309 (free_breakpoint_probes): Rename to ...
310 (free_breakpoint_objfile_data): ... this, and call delete on
313 2017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
315 * auto-load.c: Don't include gdb_vecs.h, include algorithm.
316 (loaded_script_ptr): Remove typedef.
317 (DEF_VEC_P (loaded_script_ptr)): Remove.
318 (struct collect_matching_scripts_data): Add constructor.
319 <scripts_p>: Change type to (pointer to) std::vector.
320 (collect_matching_scripts_data): Adjust.
321 (sort_scripts_by_name): Make suitable for std::sort.
322 (print_scripts): Don't sort vector, adjust to std::vector.
323 (auto_load_info_scripts): Sort vectors, adjust to std::vector.
325 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
327 * symfile.c (filename_language): Make struct, not typedef. Add
329 <ext>: Change type to std::string.
330 (DEF_VEC_O (filename_language)): Remove.
331 (filename_language_table): Change type to std::vector.
332 (add_filename_language): Adjust.
333 (set_ext_lang_command): Adjust.
334 (info_ext_lang_command): Adjust.
335 (deduce_language_from_filename): Adjust.
336 (class scoped_restore_filename_language_table): Remove.
337 (test_filename_language): Use scoped_restore.
338 (test_set_ext_lang_command): Use scoped_restore, adjust to
341 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
343 * symfile.c: Include selftest.h.
344 (class scoped_restore_filename_language_table): New.
345 (test_filename_language): New test.
346 (test_set_ext_lang_command): New test.
347 (_initialize_symfile): Register tests.
349 2017-10-27 Keith Seitz <keiths@redhat.com>
351 * breakpoint.c (print_breakpoint_location): Use the symbol saved
352 in the bp_location, falling back to find_pc_sect_function when
354 (add_location_to_breakpoint): Save sal->symbol.
355 * breakpoint.h (struct bp_location) <symbol>: New field.
356 * symtab.c (find_function_start_sal): Save the symbol into the SaL.
357 * symtab.h (struct symtab_and_line) <symbol>: New field.
359 2017-10-26 Patrick Frants <osscontribute@gmail.com>
362 * cp-valprint.c (cp_print_value_fields): Use obstack_blank_fast
365 2017-10-26 Pedro Alves <palves@redhat.com>
367 * remote.c (remote_async_terminal_ours_p): Delete.
368 (remote_open_1, remote_terminal_inferior, remote_terminal_ours):
369 Remove references to 'remote_async_terminal_ours_p'.
371 2017-10-26 Yao Qi <yao.qi@linaro.org>
373 * breakpoint.h (regular_breakpoint_inserted_here_p): Remove.
375 2017-10-26 Yao Qi <yao.qi@linaro.org>
377 * break-catch-sig.c (signal_catchpoint_breakpoint_hit): Make
379 * break-catch-syscall.c (breakpoint_hit_catch_syscall):
381 * breakpoint.c (bpstat_check_location): Remove cast.
382 (breakpoint_hit_catch_fork): Make aspce const.
383 (breakpoint_hit_catch_solib): Likewise.
384 (breakpoint_hit_catch_exec): Likewise.
385 (breakpoint_hit_ranged_breakpoint): Likewise.
386 (breakpoint_hit_watchpoint): Likewise.
387 (base_breakpoint_breakpoint_hit): Likewise.
388 (bkpt_breakpoint_hit): Likewise.
389 (dprintf_breakpoint_hit): Likewise.
390 (tracepoint_breakpoint_hit): Likewise.
391 * breakpoint.h (breakpoint_ops) <breakpoint_hit>: Likewise.
393 2017-10-26 Yao Qi <yao.qi@linaro.org>
395 * breakpoint.c (breakpoint_location_address_match): Change
396 "struct address_space *" to "const address_space".
397 (breakpoint_location_address_range_overlap): Likewise.
398 (breakpoint_here_p): Likewise.
399 (breakpoint_in_range_p): Likewise.
400 (moribund_breakpoint_here_p): Likewise.
401 (bp_location_inserted_here_p): Likewise.
402 (software_breakpoint_inserted_here_p): Likewise.
403 (hardware_breakpoint_inserted_here_p): Likewise.
404 (hardware_watchpoint_inserted_in_range): Likewise.
405 (bpstat_check_location): Likewise.
406 (bpstat_stop_status): Likewise.
407 (breakpoint_address_match): Likewise.
408 (breakpoint_address_match_range): Likewise.
409 (breakpoint_location_address_match): Likewise.
410 (breakpoint_location_address_range_overlap): Likewise.
411 (insert_single_step_breakpoint): Likewise.
412 (breakpoint_has_location_inserted_here): Likewise.
413 (single_step_breakpoint_inserted_here_p): Likewise.
414 (pc_at_non_inline_function): Likewise.
415 * breakpoint.h (bpstat_stop_status): Update declaration.
416 (breakpoint_here_p): Likewise.
417 (breakpoint_in_range_p): Likewise.
418 (moribund_breakpoint_here_p): Likewise.
419 (breakpoint_inserted_here_p): Likewise.
420 (software_breakpoint_inserted_here_p): Likewise.
421 (hardware_breakpoint_inserted_here_p): Likewise.
422 (breakpoint_has_location_inserted_here): Likewise.
423 (single_step_breakpoint_inserted_here_p): Likewise.
424 (hardware_watchpoint_inserted_in_range): Likewise.
425 (breakpoint_address_match): Likewise.
426 (insert_single_step_breakpoint): Likewise.
427 (pc_at_non_inline_function): Likewise.
428 * gdbthread.h (thread_has_single_step_breakpoint_here): Likewise.
429 * record.c (record_check_stopped_by_breakpoint): Likewise.
430 * record.h (record_check_stopped_by_breakpoint): Likewise.
431 * thread.c (thread_has_single_step_breakpoint_here): Likewise.
433 2017-10-25 Yao Qi <yao.qi@linaro.org>
435 * aarch32-linux-nat.c (aarch32_gp_regcache_supply): Use
436 regcache->arch () instead get_regcache_arch.
437 * aarch64-fbsd-nat.c (aarch64_fbsd_fetch_inferior_registers):
439 (aarch64_fbsd_store_inferior_registers): Likewise.
440 * aarch64-linux-nat.c (fetch_gregs_from_thread): Likewise.
441 (store_gregs_to_thread): Likewise.
442 (fetch_fpregs_from_thread): Likewise.
443 (store_fpregs_to_thread): Likewise.
444 * aarch64-tdep.c (aarch64_extract_return_value): Likewise.
445 (aarch64_store_return_value): Likewise.
446 (aarch64_software_single_step): Likewise.
447 * aix-thread.c (aix_thread_wait): Likewise.
448 (supply_reg32): Likewise.
449 (supply_sprs64): Likewise.
450 (supply_sprs32): Likewise.
451 (fill_gprs64): Likewise.
452 (fill_gprs32): Likewise.
453 (fill_sprs64): Likewise.
454 (fill_sprs32): Likewise.
455 (store_regs_user_thread): Likewise.
456 (store_regs_kernel_thread): Likewise.
457 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers): Likewise.
458 (alphabsd_store_inferior_registers): Likewise.
459 * alpha-tdep.c (alpha_extract_return_value): Likewise.
460 (alpha_store_return_value): Likewise.
461 (alpha_deal_with_atomic_sequence): Likewise.
462 (alpha_next_pc): Likewise.
463 (alpha_software_single_step): Likewise.
464 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Likewise.
465 (amd64bsd_store_inferior_registers): Likewise.
466 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers):
468 (amd64_linux_store_inferior_registers): Likewise.
469 * amd64-nat.c (amd64_supply_native_gregset): Likewise.
470 (amd64_collect_native_gregset): Likewise.
471 * amd64-obsd-tdep.c (amd64obsd_supply_uthread): Likewise.
472 (amd64obsd_collect_uthread): Likewise.
473 * amd64-tdep.c (amd64_supply_fpregset): Likewise.
474 (amd64_collect_fpregset): Likewise.
475 (amd64_supply_fxsave): Likewise.
476 (amd64_supply_xsave): Likewise.
477 (amd64_collect_fxsave): Likewise.
478 (amd64_collect_xsave): Likewise.
479 * arc-tdep.c (arc_write_pc): Likewise.
480 * arch-utils.c (default_skip_permanent_breakpoint): Likewise.
481 * arm-fbsd-nat.c (arm_fbsd_fetch_inferior_registers): Likewise.
482 (arm_fbsd_store_inferior_registers): Likewise.
483 * arm-linux-nat.c (fetch_vfp_regs): Likewise.
484 (store_vfp_regs): Likewise.
485 (arm_linux_fetch_inferior_registers): Likewise.
486 (arm_linux_store_inferior_registers): Likewise.
487 * arm-linux-tdep.c (arm_linux_supply_gregset): Likewise.
488 (arm_linux_sigreturn_next_pc): Likewise.
489 (arm_linux_get_next_pcs_syscall_next_pc): Likewise.
490 * arm-nbsd-nat.c (arm_supply_gregset): Likewise.
491 (fetch_register): Likewise.
492 (store_register): Likewise.
493 * arm-tdep.c (arm_is_thumb): Likewise.
494 (displaced_in_arm_mode): Likewise.
495 (bx_write_pc): Likewise.
496 (arm_get_next_pcs_addr_bits_remove): Likewise.
497 (arm_software_single_step): Likewise.
498 (arm_extract_return_value): Likewise.
499 (arm_store_return_value): Likewise.
500 (arm_write_pc): Likewise.
501 * bfin-tdep.c (bfin_extract_return_value): Likewise.
502 * bsd-uthread.c (bsd_uthread_fetch_registers): Likewise.
503 (bsd_uthread_store_registers): Likewise.
504 * core-regset.c (fetch_core_registers): Likewise.
505 * corelow.c (get_core_registers): Likewise.
506 * cris-tdep.c (cris_store_return_value): Likewise.
507 (cris_extract_return_value): Likewise.
508 (find_step_target): Likewise.
509 (find_step_target): Likewise.
510 (cris_software_single_step): Likewise.
511 * ctf.c (ctf_fetch_registers): Likewise.
512 * darwin-nat.c (cancel_breakpoint): Likewise.
513 * fbsd-tdep.c (fbsd_collect_thread_registers): Likewise.
514 * frv-tdep.c (frv_extract_return_value): Likewise.
515 * ft32-tdep.c (ft32_store_return_value): Likewise.
516 (ft32_extract_return_value): Likewise.
517 * go32-nat.c (fetch_register): Likewise.
518 (go32_fetch_registers): Likewise.
519 (go32_store_registers): Likewise.
520 (store_register): Likewise.
521 * h8300-tdep.c (h8300_extract_return_value): Likewise.
522 (h8300_store_return_value): Likewise.
523 * hppa-linux-nat.c (fetch_register): Likewise.
524 (store_register): Likewise.
525 (hppa_linux_fetch_inferior_registers): Likewise.
526 (hppa_linux_store_inferior_registers): Likewise.
527 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers): Likewise.
528 (i386_darwin_store_inferior_registers): Likewise.
529 * i386-gnu-nat.c (gnu_fetch_registers): Likewise.
530 (gnu_store_registers): Likewise.
531 * i386-linux-nat.c (fetch_register): Likewise.
532 (store_register): Likewise.
533 (supply_gregset): Likewise.
534 (fill_gregset): Likewise.
535 (i386_linux_fetch_inferior_registers): Likewise.
536 (i386_linux_store_inferior_registers): Likewise.
537 (i386_linux_resume): Likewise.
538 * i386-linux-tdep.c (i386_linux_get_syscall_number_from_regcache):
540 * i386-nto-tdep.c (i386nto_supply_gregset): Likewise.
541 * i386-obsd-nat.c (i386obsd_supply_pcb): Likewise.
542 * i386-obsd-tdep.c (i386obsd_supply_uthread): Likewise.
543 (i386obsd_collect_uthread): Likewise.
544 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
545 (i386_supply_gregset): Likewise.
546 (i386_collect_gregset): Likewise.
547 (i386_supply_fpregset): Likewise.
548 (i386_collect_fpregset): Likewise.
549 (i386_mpx_bd_base): Likewise.
550 * i386-v4-nat.c (supply_fpregset): Likewise.
551 (fill_fpregset): Likewise.
552 * i387-tdep.c (i387_supply_fsave): Likewise.
553 (i387_collect_fsave): Likewise.
554 (i387_supply_fxsave): Likewise.
555 (i387_collect_fxsave): Likewise.
556 (i387_supply_xsave): Likewise.
557 (i387_collect_xsave): Likewise.
558 * ia64-linux-nat.c (ia64_linux_fetch_registers): Likewise.
559 (ia64_linux_store_registers): Likewise.
560 * ia64-tdep.c (ia64_access_rse_reg): Likewise.
561 (ia64_extract_return_value): Likewise.
562 (ia64_store_return_value): Likewise.
563 (find_func_descr): Likewise.
564 * inf-child.c (inf_child_fetch_inferior_registers): Likewise.
565 * inf-ptrace.c (inf_ptrace_fetch_registers): Likewise.
566 (inf_ptrace_store_registers): Likewise.
567 * infrun.c (use_displaced_stepping): Likewise.
568 (displaced_step_prepare_throw): Likewise.
571 (do_target_wait): Likewise.
572 (adjust_pc_after_break): Likewise.
573 (handle_inferior_event_1): Likewise.
574 (handle_signal_stop): Likewise.
575 (save_infcall_suspend_state): Likewise.
576 (restore_infcall_suspend_state): Likewise.
577 * iq2000-tdep.c (iq2000_extract_return_value): Likewise.
578 * jit.c (jit_frame_prev_register): Likewise.
579 * linux-nat.c (save_stop_reason): Likewise.
580 (linux_nat_wait_1): Likewise.
581 (resume_stopped_resumed_lwps): Likewise.
582 * linux-record.c (record_linux_sockaddr): Likewise.
583 (record_linux_msghdr): Likewise.
584 (record_linux_system_call): Likewise.
585 * linux-tdep.c (linux_collect_thread_registers): Likewise.
586 * lm32-tdep.c (lm32_extract_return_value): Likewise.
587 (lm32_store_return_value): Likewise.
588 * m32c-tdep.c (m32c_read_flg): Likewise.
589 (m32c_pseudo_register_read): Likewise.
590 (m32c_pseudo_register_write): Likewise.
591 * m32r-linux-tdep.c (m32r_linux_supply_gregset): Likewise.
592 (m32r_linux_collect_gregset): Likewise.
593 * m32r-tdep.c (m32r_store_return_value): Likewise.
594 (m32r_extract_return_value): Likewise.
595 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
596 (m68kbsd_collect_fpregset): Likewise.
597 * m68k-bsd-tdep.c (m68kbsd_supply_fpregset): Likewise.
598 * m68k-linux-nat.c (fetch_register): Likewise.
599 (old_fetch_inferior_registers): Likewise.
600 (old_store_inferior_registers): Likewise.
601 (store_regs): Likewise.
602 * m68k-tdep.c (m68k_svr4_extract_return_value): Likewise.
603 (m68k_svr4_store_return_value): Likewise.
604 * m88k-tdep.c (m88k_store_arguments): Likewise.
605 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Likewise.
606 (mi_cmd_data_write_register_values): Likewise.
607 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers): Likewise.
608 (mips_fbsd_store_inferior_registers): Likewise.
609 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Likewise.
610 (mips_fbsd_supply_gregs): Likewise.
611 (mips_fbsd_collect_fpregs): Likewise.
612 (mips_fbsd_collect_gregs): Likewise.
613 (mips_fbsd_supply_fpregset): Likewise.
614 (mips_fbsd_collect_fpregset): Likewise.
615 (mips_fbsd_supply_gregset): Likewise.
616 (mips_fbsd_collect_gregset): Likewise.
617 * mips-linux-nat.c (supply_gregset): Likewise.
618 (fill_gregset): Likewise.
619 (supply_fpregset): Likewise.
620 (fill_fpregset): Likewise.
621 * mips-linux-tdep.c (mips_supply_gregset): Likewise.
622 (mips_fill_gregset): Likewise.
623 (mips_supply_fpregset): Likewise.
624 (mips_fill_fpregset): Likewise.
625 (mips64_supply_gregset): Likewise.
626 (micromips_linux_sigframe_validate): Likewise.
627 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers): Likewise.
628 (mipsnbsd_fetch_inferior_registers): Likewise.
629 (mipsnbsd_store_inferior_registers): Likewise.
630 * mips-nbsd-tdep.c (mipsnbsd_supply_fpregset): Likewise.
631 (mipsnbsd_supply_gregset): Likewise.
632 (mipsnbsd_iterate_over_regset_sections): Likewise.
633 (mipsnbsd_supply_reg): Likewise.
634 (mipsnbsd_supply_fpreg): Likewise.
635 * mips-tdep.c (mips_in_frame_stub): Likewise.
636 (mips_dummy_id): Likewise.
637 (is_octeon_bbit_op): Likewise.
638 (micromips_bc1_pc): Likewise.
639 (extended_mips16_next_pc): Likewise.
640 (mips16_next_pc): Likewise.
641 (deal_with_atomic_sequence): Likewise.
642 * moxie-tdep.c (moxie_process_readu): Likewise.
643 * nios2-tdep.c (nios2_get_next_pc): Likewise.
644 * nto-procfs.c (procfs_store_registers): Likewise.
645 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers): Likewise.
646 (ppcfbsd_store_inferior_registers): Likewise.
647 * ppc-linux-nat.c (fetch_vsx_register): Likewise.
648 (fetch_altivec_register): Likewise.
649 (get_spe_registers): Likewise.
650 (fetch_spe_register): Likewise.
651 (fetch_altivec_registers): Likewise.
652 (fetch_all_gp_regs): Likewise.
653 (fetch_all_fp_regs): Likewise.
654 (store_vsx_register): Likewise.
655 (store_altivec_register): Likewise.
656 (set_spe_registers): Likewise.
657 (store_spe_register): Likewise.
658 (store_altivec_registers): Likewise.
659 (store_all_gp_regs): Likewise.
660 (store_all_fp_regs): Likewise.
661 * ppc-linux-tdep.c (ppc_linux_supply_gregset): Likewise.
662 (ppc_linux_collect_gregset): Likewise.
663 (ppc_canonicalize_syscall): Likewise.
664 (ppc_linux_record_signal): Likewise.
665 (ppu2spu_prev_register): Likewise.
666 * ppc-nbsd-nat.c (ppcnbsd_supply_pcb): Likewise.
667 * ppc-obsd-nat.c (ppcobsd_fetch_registers): Likewise.
668 (ppcobsd_store_registers): Likewise.
669 * ppc-ravenscar-thread.c (ppc_ravenscar_generic_fetch_registers):
671 (ppc_ravenscar_generic_store_registers): Likewise.
672 * procfs.c (procfs_fetch_registers): Likewise.
673 (procfs_store_registers): Likewise.
674 * ravenscar-thread.c (ravenscar_fetch_registers): Likewise.
675 (ravenscar_store_registers): Likewise.
676 (ravenscar_prepare_to_store): Likewise.
677 * record-btrace.c (record_btrace_fetch_registers): Likewise.
678 * record-full.c (record_full_wait_1): Likewise.
679 (record_full_registers_change): Likewise.
680 (record_full_store_registers): Likewise.
681 (record_full_core_fetch_registers): Likewise.
682 (record_full_save): Likewise.
683 (record_full_goto_insn): Likewise.
684 * regcache.c (regcache_register_size): Likewise.
685 (get_regcache_arch): Remove.
686 (regcache_read_pc): Likewise.
687 * regcache.h (get_regcache_arch): Remove.
688 * remote-sim.c (gdbsim_fetch_register): Likewise.
689 (gdbsim_store_register): Likewise.
690 * remote.c (fetch_register_using_p): Likewise.
691 (send_g_packet): Likewise.
692 (remote_prepare_to_store): Likewise.
693 (store_registers_using_G): Likewise.
694 * reverse.c (save_bookmark_command): Likewise.
695 (goto_bookmark_command): Likewise.
696 * rs6000-aix-tdep.c (branch_dest): Likewise.
697 * rs6000-nat.c (rs6000_ptrace64): Likewise.
698 (fetch_register): Likewise.
699 * rs6000-tdep.c (ppc_supply_reg): Likewise.
700 (ppc_collect_reg): Likewise.
701 (ppc_collect_gregset): Likewise.
702 (ppc_collect_fpregset): Likewise.
703 (ppc_collect_vsxregset): Likewise.
704 (ppc_collect_vrregset): Likewise.
705 (ppc_displaced_step_hw_singlestep): Likewise.
706 (rs6000_pseudo_register_read): Likewise.
707 (rs6000_pseudo_register_write): Likewise.
708 * s390-linux-nat.c (supply_gregset): Likewise.
709 (fill_gregset): Likewise.
710 (s390_linux_fetch_inferior_registers): Likewise.
711 * s390-linux-tdep.c (s390_write_pc): Likewise.
712 (s390_software_single_step): Likewise.
713 (s390_all_but_pc_registers_record): Likewise.
714 (s390_linux_syscall_record): Likewise.
715 * sentinel-frame.c (sentinel_frame_prev_arch): Likewise.
716 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers): Likewise.
717 (shnbsd_store_inferior_registers): Likewise.
718 * sh-tdep.c (sh_extract_return_value_nofpu): Likewise.
719 (sh_extract_return_value_fpu): Likewise.
720 (sh_store_return_value_nofpu): Likewise.
721 (sh_corefile_supply_regset): Likewise.
722 (sh_corefile_collect_regset): Likewise.
723 * sh64-tdep.c (sh64_extract_return_value): Likewise.
724 (sh64_store_return_value): Likewise.
725 * sparc-linux-tdep.c (sparc32_linux_collect_core_fpregset): Likewise.
726 * sparc-nat.c (sparc_fetch_inferior_registers): Likewise.
727 (sparc_store_inferior_registers): Likewise.
728 * sparc-ravenscar-thread.c (register_in_thread_descriptor_p): Likewise.
729 (sparc_ravenscar_prepare_to_store): Likewise.
730 * sparc-tdep.c (sparc32_store_arguments): Likewise.
731 (sparc_analyze_control_transfer): Likewise.
732 (sparc_step_trap): Likewise.
733 (sparc_software_single_step): Likewise.
734 (sparc32_gdbarch_init): Likewise.
735 (sparc_supply_rwindow): Likewise.
736 (sparc_collect_rwindow): Likewise.
737 * sparc64-linux-tdep.c (sparc64_linux_collect_core_fpregset): Likewise.
738 * sparc64-nbsd-nat.c (sparc64nbsd_supply_gregset): Likewise.
739 (sparc64nbsd_collect_gregset): Likewise.
740 (sparc64nbsd_supply_fpregset): Likewise.
741 (sparc64nbsd_collect_fpregset): Likewise.
742 * sparc64-tdep.c (sparc64_store_arguments): Likewise.
743 (sparc64_supply_gregset): Likewise.
744 (sparc64_collect_gregset): Likewise.
745 (sparc64_supply_fpregset): Likewise.
746 (sparc64_collect_fpregset): Likewise.
747 * spu-linux-nat.c (spu_fetch_inferior_registers): Likewise.
748 * spu-tdep.c (spu_unwind_sp): Likewise.
749 (spu2ppu_prev_register): Likewise.
750 (spu_memory_remove_breakpoint): Likewise.
751 * stack.c (return_command): Likewise.
752 * tic6x-tdep.c (tic6x_extract_signed_field): Likewise.
753 * tracefile-tfile.c (tfile_fetch_registers): Likewise.
754 * tracefile.c (trace_save_ctf): Likewise.
755 * windows-nat.c (do_windows_fetch_inferior_registers): Likewise.
756 (do_windows_store_inferior_registers): Likewise.
757 (windows_resume): Likewise.
758 * xtensa-linux-nat.c (fill_gregset): Likewise.
759 (supply_gregset_reg): Likewise.
760 * xtensa-tdep.c (xtensa_register_write_masked): Likewise.
761 (xtensa_register_read_masked): Likewise.
762 (xtensa_supply_gregset): Likewise.
763 (xtensa_extract_return_value): Likewise.
764 (xtensa_store_return_value): Likewise.
766 2017-10-25 Ulrich Weigand <uweigand@de.ibm.com>
768 * doublest.c (floatformat_from_string): New function.
769 * doublest.h (floatformat_from_string): Add prototype.
771 * std-operator.def (OP_DOUBLE, OP_DECFLOAT): Remove, replace by ...
772 (OP_FLOAT): ... this.
773 * expression.h: Do not include "doublest.h".
774 (union exp_element): Replace doubleconst and decfloatconst by
775 new element floatconst.
776 * ada-lang.c (resolve_subexp): Handle OP_FLOAT instead of OP_DOUBLE.
777 (ada_evaluate_subexp): Likewise.
778 * eval.c (evaluate_subexp_standard): Handle OP_FLOAT instead of
779 OP_DOUBLE and OP_DECFLOAT.
780 * expprint.c (print_subexp_standard): Likewise.
781 (dump_subexp_body_standard): Likewise.
782 * breakpoint.c (watchpoint_exp_is_const): Likewise.
784 * parse.c: Include "dfp.h".
785 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
786 (write_exp_elt_floatcst): New function.
787 (operator_length_standard): Handle OP_FLOAT instead of OP_DOUBLE
789 (operator_check_standard): Likewise.
790 (parse_float): Do not accept suffix. Take type as input. Return bool.
791 Return target format buffer instead of host DOUBLEST.
792 Use floatformat_from_string and decimal_from_string to parse
793 either binary or decimal floating-point types.
794 (parse_c_float): Remove.
795 * parser-defs.h: Do not include "doublest.h".
796 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
797 (write_exp_elt_floatcst): Add prototype.
798 (parse_float): Update prototype.
799 (parse_c_float): Remove.
801 * c-exp.y: Do not include "dfp.h".
802 (typed_val_float): Use byte buffer instead of DOUBLEST.
803 (typed_val_decfloat): Remove.
805 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
806 (parse_number): Update to new parse_float interface.
807 Parse suffixes and determine type before calling parse_float.
808 Handle decimal and binary FP types the same way.
810 * d-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
811 (FLOAT_LITERAL): Use OP_FLOAT and write_exp_elt_floatcst.
812 (parse_number): Update to new parse_float interface.
813 Parse suffixes and determine type before calling parse_float.
815 * f-exp.y: Replace dval by typed_val_float.
816 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
817 (parse_number): Use parse_float instead of atof.
819 * go-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
820 (parse_go_float): Remove.
821 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
822 (parse_number): Call parse_float instead of parse_go_float.
823 Parse suffixes and determine type before calling parse_float.
825 * p-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
826 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
827 (parse_number): Update to new parse_float interface.
828 Parse suffixes and determine type before calling parse_float.
830 * m2-exp.y: Replace dval by byte buffer val.
831 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
832 (parse_number): Call parse_float instead of atof.
834 * rust-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
835 (lex_number): Call parse_float instead of strtod.
836 (ast_dliteral): Use OP_FLOAT instead of OP_DOUBLE.
837 (convert_ast_to_expression): Handle OP_FLOAT instead of OP_DOUBLE.
838 Use write_exp_elt_floatcst.
839 (unit_testing): Remove static variable.
840 (rust_type): Do not check unit_testing.
841 (rust_lex_tests): Do not set uint_testing. Set up dummy rust_parser.
843 * ada-exp.y (type_float, type_double): Remove.
844 (typed_val_float): Use byte buffer instead of DOUBLEST.
845 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
846 * ada-lex.l (processReal): Use parse_float instead of sscanf.
848 2017-10-25 Alan Hayward <alan.hayward@arm.com>
850 * aarch64-tdep.h (enum aarch64_regnum): Remove.
851 * arch/aarch64.h: New file.
853 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
855 * dfp.h (decimal_from_string): Use const reference for argument.
856 * dfp.c (decimal_from_string): Likewise.
858 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
860 * i387-tdep.c (print_i387_value): Use floatformat_to_string.
861 * sh64-tdep.c (sh64_do_fp_register): Likewise.
862 * mips-tdep.c (mips_print_fp_register): Likewise.
864 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
866 * common/format.h (enum argclass): Replace decfloat_arg by
867 dec32float_arg, dec64float_arg, and dec128float_arg.
868 * common/format.c (parse_format_string): Update to return
869 new decimal float argument classes.
871 * printcmd.c (printf_decfloat): Rename to ...
872 (printf_floating): ... this. Add argclass argument, and use it
873 instead of parsing the format string again. Add support for
874 binary floating-point values, using floatformat_to_string.
875 Convert value to the target format if it doesn't already match.
876 (ui_printf): Call printf_floating instead of printf_decfloat,
877 also for double_arg / long_double_arg. Pass argclass.
879 * dfp.c (decimal_to_string): Add format string argument.
880 * dfp.h (decimal_to_string): Likewise.
882 * doublest.c (floatformat_to_string): Add format string argument.
883 * doublest.h (floatformat_to_string): Likewise.
885 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
887 * doublest.c (floatformat_precision): New routine.
888 (floatformat_to_string): Likewise.
889 * doublest.c (floatformat_to_string): Add prototype.
891 * printcmd.c (print_scalar_formatted): Only call print_floating
892 on floating-point types.
893 * valprint.c: Do not include "floatformat.h".
894 (generic_val_print_decfloat): Remove.
895 (generic_val_print): Call generic_val_print_float for both
896 TYPE_CODE_FLT and TYPE_CODE_DECFLOAT.
897 (print_floating): Use floatformat_to_string. Handle decimal float.
898 (print_decimal_floating): Remove, merge into floatformat_to_string.
899 * value.h (print_decimal_floating): Remove.
901 * Makefile.in: Do not build doublest.c with -Wformat-nonliteral.
903 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
905 * buildsym.c (end_symtab_get_static_block): Use std::stable_sort.
907 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
909 * memattr.h: Don't include vec.h.
910 (struct mem_attrib): Initialize fields.
911 <unknown>: New static method.
912 (struct mem_region): Add constructors, operator<, initialize
914 * memattr.c: Include algorithm.
915 (default_mem_attrib, unknown_mem_attrib): Remove.
916 (user_mem_region_list): New global.
917 (target_mem_region_list, mem_region_list): Change type to
918 std::vector<mem_region>.
919 (mem_use_target): Now a function.
920 (target_mem_regions_valid): Change type to bool.
921 (mem_region_lessthan, mem_region_cmp, mem_region_init): Remove.
922 (require_user_regions): Adjust.
923 (require_target_regions): Adjust.
924 (create_mem_region): Adjust.
925 (lookup_mem_region): Adjust.
926 (invalidate_target_mem_regions): Adjust.
927 (mem_clear): Rename to...
928 (user_mem_clear): ... this, and adjust.
929 (mem_command): Adjust.
930 (info_mem_command): Adjust.
931 (mem_enable, enable_mem_command, mem_disable,
932 disable_mem_command): Adjust.
933 (mem_delete): Adjust.
934 (delete_mem_command): Adjust.
935 * memory-map.h (parse_memory_map): Return an std::vector.
936 * memory-map.c (parse_memory_map): Likewise.
937 (struct memory_map_parsing_data): Add constructor.
938 <memory_map>: Point to std::vector.
939 (memory_map_start_memory): Adjust.
940 (memory_map_end_memory): Adjust.
941 (memory_map_end_property): Adjust.
942 (clear_result): Remove.
943 * remote.c (remote_memory_map): Return an std::vector.
944 * target-debug.h (target_debug_print_VEC_mem_region_s__p):
946 (target_debug_print_mem_region_vector): New.
947 * target-delegates.c: Regenerate.
948 * target.h (mem_region_vector): New typedef.
949 (to_memory_map): Return mem_region_vector.
950 (target_memory_map): Return an std::vector.
951 * target.c (target_memory_map): Return an std::vector.
952 (flash_erase_command): Adjust.
954 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
956 * memory-map.c (struct memory_map_parsing_data) <property_name>:
957 Change type to std::string.
958 (memory_map_start_property): Adjust.
959 (memory_map_end_property): Adjust.
961 2017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
963 * infrun.h: Include common/byte-vector.h.
964 (struct displaced_step_closure): New struct.
965 (struct buf_displaced_step_closure): New struct.
966 * infrun.c (displaced_step_closure::~displaced_step_closure):
967 Provide default implementation.
968 (displaced_step_clear): Deallocate step closure with delete.
969 * aarch64-tdep.c (displaced_step_closure): Rename to ...
970 (aarch64_displaced_step_closure): ... this, extend
971 displaced_step_closure.
972 (aarch64_displaced_step_data) <dsc>: Change type to
973 aarch64_displaced_step_closure.
974 (aarch64_displaced_step_copy_insn): Adjust to type change, use
976 (aarch64_displaced_step_fixup): Add cast for displaced step
978 * amd64-tdep.c (displaced_step_closure): Rename to ...
979 (amd64_displaced_step_closure): ... this, extend
980 displaced_step_closure.
981 <insn_buf>: Change type to std::vector<gdb_byte>.
983 (fixup_riprel): Change type of DSC parameter, adjust to type
985 (fixup_displaced_copy): Change type of DSC parameter.
986 (amd64_displaced_step_copy_insn): Instantiate
987 amd64_displaced_step_closure.
988 (amd64_displaced_step_fixup): Add cast for closure type, adjust
989 to type change of insn_buf.
990 * arm-linux-tdep.c (arm_linux_cleanup_svc): Change type of
992 (arm_linux_copy_svc): Likewise.
993 (cleanup_kernel_helper_return): Likewise.
994 (arm_catch_kernel_helper_return): Likewise.
995 (arm_linux_displaced_step_copy_insn): Instantiate
996 arm_displaced_step_closure.
997 * arm-tdep.c (arm_pc_is_thumb): Add cast for closure.
998 (displaced_read_reg): Change type of parameter DSC.
999 (branch_write_pc): Likewise.
1000 (load_write_pc): Likewise.
1001 (alu_write_pc): Likewise.
1002 (displaced_write_reg): Likewise.
1003 (arm_copy_unmodified): Likewise.
1004 (thumb_copy_unmodified_32bit): Likewise.
1005 (thumb_copy_unmodified_16bit): Likewise.
1006 (cleanup_preload): Likewise.
1007 (install_preload): Likewise.
1008 (arm_copy_preload): Likewise.
1009 (thumb2_copy_preload): Likewise.
1010 (install_preload_reg): Likewise.
1011 (arm_copy_preload_reg): Likewise.
1012 (cleanup_copro_load_store): Likewise.
1013 (install_copro_load_store): Likewise.
1014 (arm_copy_copro_load_store) Likewise.
1015 (thumb2_copy_copro_load_store): Likewise.
1016 (cleanup_branch): Likewise.
1017 (install_b_bl_blx): Likewise.
1018 (arm_copy_b_bl_blx): Likewise.
1019 (thumb2_copy_b_bl_blx): Likewise.
1020 (thumb_copy_b): Likewise.
1021 (install_bx_blx_reg): Likewise.
1022 (arm_copy_bx_blx_reg): Likewise.
1023 (thumb_copy_bx_blx_reg): Likewise.
1024 (cleanup_alu_imm): Likewise.
1025 (arm_copy_alu_imm): Likewise.
1026 (thumb2_copy_alu_imm): Likewise.
1027 (cleanup_alu_reg): Likewise.
1028 (install_alu_reg): Likewise.
1029 (arm_copy_alu_reg): Likewise.
1030 (thumb_copy_alu_reg): Likewise.
1031 (cleanup_alu_shifted_reg): Likewise.
1032 (install_alu_shifted_reg): Likewise.
1033 (arm_copy_alu_shifted_reg): Likewise.
1034 (cleanup_load): Likewise.
1035 (cleanup_store): Likewise.
1036 (arm_copy_extra_ld_st): Likewise.
1037 (install_load_store): Likewise.
1038 (thumb2_copy_load_literal): Likewise.
1039 (thumb2_copy_load_reg_imm): Likewise.
1040 (arm_copy_ldr_str_ldrb_strb): Likewise.
1041 (cleanup_block_load_all): Likewise.
1042 (cleanup_block_store_pc): Likewise.
1043 (cleanup_block_load_pc): Likewise.
1044 (arm_copy_block_xfer): Likewise.
1045 (thumb2_copy_block_xfer): Likewise.
1046 (cleanup_svc): Likewise.
1047 (install_svc): Likewise.
1048 (arm_copy_svc): Likewise.
1049 (thumb_copy_svc): Likewise.
1050 (arm_copy_undef): Likewise.
1051 (thumb_32bit_copy_undef): Likewise.
1052 (arm_copy_unpred): Likewise.
1053 (arm_decode_misc_memhint_neon): Likewise.
1054 (arm_decode_unconditional): Likewise.
1055 (arm_decode_miscellaneous): Likewise.
1056 (arm_decode_dp_misc): Likewise.
1057 (arm_decode_ld_st_word_ubyte): Likewise.
1058 (arm_decode_media): Likewise.
1059 (arm_decode_b_bl_ldmstm): Likewise.
1060 (arm_decode_ext_reg_ld_st): Likewise.
1061 (thumb2_decode_dp_shift_reg): Likewise.
1062 (thumb2_decode_ext_reg_ld_st): Likewise.
1063 (arm_decode_svc_copro): Likewise.
1064 (thumb2_decode_svc_copro): Likewise.
1065 (install_pc_relative): Likewise.
1066 (thumb_copy_pc_relative_16bit): Likewise.
1067 (thumb_decode_pc_relative_16bit): Likewise.
1068 (thumb_copy_pc_relative_32bit): Likewise.
1069 (thumb_copy_16bit_ldr_literal): Likewise.
1070 (thumb_copy_cbnz_cbz): Likewise.
1071 (thumb2_copy_table_branch): Likewise.
1072 (cleanup_pop_pc_16bit_all): Likewise.
1073 (thumb_copy_pop_pc_16bit): Likewise.
1074 (thumb_process_displaced_16bit_insn): Likewise.
1075 (decode_thumb_32bit_ld_mem_hints): Likewise.
1076 (thumb_process_displaced_32bit_insn): Likewise.
1077 (thumb_process_displaced_insn): Likewise.
1078 (arm_process_displaced_insn): Likewise.
1079 (arm_displaced_init_closure): Likewise.
1080 (arm_displaced_step_fixup): Add cast for closure.
1081 * arm-tdep.h: Include infrun.h.
1082 (displaced_step_closure): Rename to ...
1083 (arm_displaced_step_closure): ... this, extend
1084 displaced_step_closure.
1085 <u::svc::copy_svc_os>: Change type of parameter DSC.
1086 <cleanup>: Likewise.
1087 (arm_process_displaced_insn): Likewise.
1088 (arm_displaced_init_closure): Likewise.
1089 (displaced_read_reg): Likewise.
1090 (displaced_write_reg): Likewise.
1091 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
1093 * i386-tdep.h: Include infrun.h.
1094 (i386_displaced_step_closure): New typedef.
1095 * i386-tdep.c (i386_displaced_step_copy_insn): Use
1096 i386_displaced_step_closure.
1097 (i386_displaced_step_fixup): Adjust.
1098 * rs6000-tdep.c (ppc_displaced_step_closure): New typedef.
1099 (ppc_displaced_step_copy_insn): Use ppc_displaced_step_closure
1101 (ppc_displaced_step_fixup): Adjust.
1102 * s390-linux-tdep.c (s390_displaced_step_closure): New typedef.
1103 (s390_displaced_step_copy_insn): Use s390_displaced_step_closure
1105 (s390_displaced_step_fixup): Adjust.
1107 2017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
1109 * interps.h (interp_resume, interp_suspend, interp_set_temp):
1110 Remove declarations.
1112 2017-10-20 Tom Tromey <tom@tromey.com>
1114 * gdb_bfd.c (struct gdb_bfd_data) <included_bfds>: Now a
1116 (gdb_bfd_record_inclusion): Update.
1117 (bfdp): Remove typedef.
1119 2017-10-20 Tom Tromey <tom@tromey.com>
1121 * gdb_bfd.c (gdb_bfd_ref): Use new.
1122 (struct gdb_bfd_data): Add constructor, destructor, and member
1124 (gdb_bfd_unref): Use delete.
1126 2017-10-20 Tom Tromey <tom@tromey.com>
1128 * exec.c (exec_file_attach): Use new_bfd_ref.
1129 * symfile-mem.c (symbol_file_add_from_memory): Use new_bfd_ref.
1130 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
1131 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_fdopenr): Use
1133 * gdb_bfd.h (new_bfd_ref): New function.
1135 2017-10-20 Pedro Alves <palves@redhat.com>
1137 * main.c (captured_command_loop): Add attribute noinline.
1139 2017-10-19 Simon Marchi <simon.marchi@ericsson.com>
1141 * interps.c (struct interp_factory): Add constructor.
1142 (interp_factory_p): Remove typedef.
1143 (DEF_VEC_P(interp_factory_p)): Remove.
1144 (interpreter_factories): Change type to std::vector.
1145 (interp_factory_register): Adjust.
1146 (interp_lookup): Adjust.
1147 (interpreter_completer): Adjust.
1149 2017-10-19 Tom Tromey <tom@tromey.com>
1151 * break-catch-syscall.c (catch_syscall_completer): Use
1152 std::string, gdb::unique_xmalloc_ptr.
1154 2017-10-19 Tom Tromey <tom@tromey.com>
1156 * infcall.c (call_function_by_hand_dummy): Use std::string.
1158 2017-10-19 Tom Tromey <tom@tromey.com>
1160 * mi/mi-main.c (mi_cmd_execute): Update.
1161 * top.h (prepare_execute_command): Return scoped_value_mark.
1162 * value.h (class scoped_value_mark): Use DISABLE_COPY_AND_ASSIGN.
1163 Add move constructor.
1164 * top.c (prepare_execute_command): Return scoped_value_mark.
1165 (execute_command): Update.
1167 2017-10-19 Pedro Alves <palves@redhat.com>
1169 * xml-support.c (xml_fetch_content_from_file): Check fread's
1172 2017-10-19 Pedro Alves <palves@redhat.com>
1174 * ser-base.c (ser_base_read_error_fd): Delete the file handler if
1176 (handle_error_fd): New function.
1177 (ser_base_async): Add/delete an event loop file handler for
1180 2017-10-19 Pedro Alves <palves@redhat.com>
1182 * xml-support.c (xml_fetch_content_from_file): Don't read in
1183 chunks. Instead use fseek to determine the file's size, and read
1186 2017-11-18 Keith Seitz <keiths@redhat.com>
1188 * c-exp.y (oper): Canonicalize conversion operators of user-defined
1190 Add whitespace to front of type name.
1192 2017-10-18 Keith Seitz <keiths@redhat.com>
1194 * dwarf2read.c (dwarf2_add_typedef): Issue a complaint on unhandled
1195 DW_AT_accessibility.
1197 2017-10-18 Yao Qi <yao.qi@linaro.org>
1199 * features/tic6x-c62x-linux.c: Remove.
1201 2017-10-17 Tom Tromey <tom@tromey.com>
1203 * disasm.c (do_mixed_source_and_assembly_deprecated): Use
1204 gdb::optional, ui_out_emit_list, ui_out_emit_tuple.
1205 (do_mixed_source_and_assembly): Likewise.
1207 2017-10-17 Tom Tromey <tom@tromey.com>
1209 * regcache.c (regcache::xfer_part): Remove assertion.
1211 2017-10-17 Pedro Alves <palves@redhat.com>
1213 * xml-support.c (xml_fetch_content_from_file): Call
1214 unique_ptr::release() instead unique_ptr::get() when passing
1217 2017-10-17 Yao Qi <yao.qi@linaro.org>
1219 * regcache.c (regcache::xfer_part): Remove parameters read and
1220 write, add parameter is_raw. All callers are updated.
1222 2017-10-16 Keith Seitz <keiths@redhat.com>
1224 * c-typeprint.c (enum access_specifier): Moved here from
1226 (output_access_specifier): New function.
1227 (c_type_print_base): Consider typedefs when assessing
1228 whether access labels are needed.
1229 Use output_access_specifier as needed.
1230 Output access specifier for typedefs, if needed.
1231 * dwarf2read.c (dwarf2_add_typedef): Record DW_AT_accessibility.
1232 * gdbtypes.h (struct typedef_field) <is_protected, is_private>: New
1234 (TYPE_TYPEDEF_FIELD_PROTECTED, TYPE_TYPEDEF_FIELD_PRIVATE): New
1237 2017-10-16 Tom Tromey <tom@tromey.com>
1239 * linux-tdep.c (linux_info_proc, linux_find_memory_regions_full)
1240 (linux_fill_prpsinfo, linux_vsyscall_range_raw): Update.
1241 * target.c (target_fileio_read_stralloc): Update.
1242 * sparc64-tdep.c (adi_is_addr_mapped): Update.
1243 * target.h (target_fileio_read_stralloc): Return
1246 2017-10-16 Tom Tromey <tom@tromey.com>
1248 * xml-syscall.c (xml_init_syscalls_info): Update.
1249 * xml-support.c (xinclude_start_include): Update.
1250 (xml_fetch_content_from_file): Return unique_xmalloc_ptr.
1251 * xml-support.h (xml_fetch_another): Return unique_xmalloc_ptr.
1252 (xml_fetch_content_from_file): Likewise.
1253 * osdata.c (get_osdata): Update.
1254 * target.h (target_read_stralloc, target_get_osdata): Return
1256 * solib-aix.c (solib_aix_get_library_list): Update.
1257 * solib-target.c (solib_target_current_sos): Update.
1258 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Update.
1259 * xml-tdesc.c (fetch_available_features_from_target): Update.
1260 (target_fetch_description_xml): Update.
1261 (file_read_description_xml): Update.
1262 * remote.c (remote_get_threads_with_qxfer, remote_memory_map)
1263 (remote_traceframe_info, btrace_read_config, remote_read_btrace)
1264 (remote_pid_to_exec_file): Update.
1265 * target.c (target_read_stralloc): Return unique_xmalloc_ptr.
1266 (target_get_osdata): Likewise.
1268 2017-10-16 Tom Tromey <tom@tromey.com>
1270 * remote.c (remote_register_number_and_offset): Use std::vector.
1271 (remote_set_syscall_catchpoint): Use gdb::unique_xmalloc_ptr.
1272 (putpkt_binary): Use gdb::def_vector.
1273 (compare_sections_command): Use gdb::byte_vector.
1275 2017-10-16 Tom Tromey <tom@tromey.com>
1277 * ppc-linux-nat.c (hwdebug_insert_point): Use
1278 gdb::unique_xmalloc_ptr, XDUP.
1280 2017-10-16 Tom Tromey <tom@tromey.com>
1282 * probe.c (parse_probes): Use std::string.
1283 (info_probes_for_ops, enable_probes_command)
1284 (disable_probes_command): Remove cleanups.
1286 2017-10-16 Tom Tromey <tom@tromey.com>
1288 * buildsym.c (block_compar): Remove.
1289 (end_symtab_get_static_block): Use std::vector.
1291 2017-10-16 Simon Marchi <simon.marchi@ericsson.com>
1293 * memrange.h (struct mem_range): Define operator< and operator==.
1294 (mem_range_s): Remove.
1295 (DEF_VEC_O (mem_range_s)): Remove.
1296 (normalize_mem_ranges): Change parameter type to std::vector.
1297 * memrange.c (compare_mem_ranges): Remove.
1298 (normalize_mem_ranges): Change parameter type to std::vector,
1299 adjust to vector change.
1300 * exec.c (section_table_available_memory): Return vector, remove
1302 (section_table_read_available_memory): Adjust to std::vector
1304 * remote.c (remote_read_bytes): Adjust to std::vector
1306 * tracepoint.h (traceframe_available_memory): Change parameter
1307 type to std::vector.
1308 * tracepoint.c (traceframe_available_memory): Change parameter
1309 type to std::vector, adjust.
1310 * gdb/mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to
1312 * gdb/Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1313 unittests/memrange-selftests.c.
1314 (SUBDIR_UNITTESTS_OBS): Add memrange-selftests.o.
1315 * gdb/unittests/memrange-selftests.c: New file.
1317 2017-10-16 Pedro Alves <palves@redhat.com>
1319 * elfread.c (probe_key_free): Rename range-for variable.
1320 * probe.c (parse_probes_in_pspace, find_probes_in_objfile)
1321 (find_probe_by_pc, collect_probes): Rename range-for variable.
1323 2017-10-16 Yao Qi <yao.qi@linaro.org>
1325 * features/Makefile (XMLTOC): Remove tic6x-*.xml.
1326 * features/tic6x-c62x.c: Remove.
1327 * features/tic6x-c64x-linux.c: Remove.
1328 * features/tic6x-c64x.c: Remove.
1329 * features/tic6x-c64xp-linux.c: Remove.
1330 * features/tic6x-c64xp.c: Remove.
1331 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Don't call
1332 initialize_tdesc_tic6x_*_linux functions.
1333 * tic6x-tdep.c (_initialize_tic6x_tdep): Don't call
1334 initialize_tdesc_tic6x_* functions.
1336 2017-10-16 Yao Qi <yao.qi@linaro.org>
1338 * features/Makefile (WHICH): Remove tic6x-c64xp, tic6x-c64x
1340 * regformats/tic6x-c62x.dat: Remove.
1341 * regformats/tic6x-c64x.dat: Remove.
1342 * regformats/tic6x-c64xp.dat: Remove.
1344 2017-10-15 Simon Marchi <simon.marchi@ericsson.com>
1346 * tracepoint.c (parse_traceframe_info): Return a unique_ptr
1347 (the !HAVE_LIBEXPAT version).
1349 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
1351 * nat/linux-osdata.c (struct pid_pgid_entry) <operator<>: Make
1354 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1356 * target.h: Include tracepoint.h.
1357 (enum trace_find_type): Move to tracepoint.h.
1358 (struct target_ops) <to_traceframe_info>: Return a unique ptr.
1359 * tracepoint.h: Don't include target.h
1360 (enum trace_find_type): Move from target.h.
1361 (parse_traceframe_info): Return a unique ptr.
1362 * tracepoint.c (current_traceframe_info): Change type to unique
1364 (free_traceframe_info): Remove.
1365 (clear_traceframe_info): Don't manually free
1366 current_traceframe_info.
1367 (free_result): Remove.
1368 (parse_traceframe_info): Return a unique ptr.
1369 (get_traceframe_info): Adjust to unique ptr.
1370 * ctf.c (ctf_traceframe_info): Return a unique ptr.
1371 * remote.c (remote_traceframe_info): Return a unique ptr.
1372 * tracefile-tfile.c (tfile_traceframe_info): Return a unique
1374 * target-debug.h (target_debug_print_traceframe_info_up): New
1376 * target-delegates.c: Regenerate.
1378 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1380 * memrange.h (struct mem_range): Add constructors.
1381 * tracepoint.h (struct traceframe_info) <memory>: Change type to
1382 std::vector<mem_range>.
1383 * tracepoint.c (free_traceframe_info): Don't manually free
1385 (traceframe_info_start_memory): Adjust to vector change.
1386 (traceframe_available_memory): Likewise.
1387 * tracefile-tfile.c (build_traceframe_info): Likewise.
1388 * ctf.c (ctf_traceframe_info): Likewise.
1390 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1392 * tracepoint.h (struct traceframe_info) <tvars>: Change type to
1394 * tracepoint.c (free_traceframe_info): Deallocate with delete.
1395 (traceframe_info_start_tvar): Adjust to vector change.
1396 (parse_traceframe_info): Allocate with new.
1397 * ctf.c (ctf_traceframe_info): Allocate with new, adjust to
1399 * tracefile-tfile.c (build_traceframe_info): Adjust to vector
1401 tfile_traceframe_info): Allocate with new.
1402 * mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to vector
1405 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1407 * tracepoint.c (traceframe_info): Rename to...
1408 (current_traceframe_info): ...this.
1409 (clear_traceframe_info): Adjust.
1410 (get_traceframe_info): Adjust.
1412 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
1414 * nat/linux-osdata.c: Include algorithm.
1415 (compare_processes): Remove.
1416 (struct pid_pgid_entry): New struct.
1417 (linux_xfer_osdata_processgroups): Use std::vector instead of
1420 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
1422 * objfiles.h: Don't include symfile.h.
1423 (struct partial_symbol): Remove forward-declaration.
1424 (struct objfile) <global_psymbols, static_psymbols>: Change type
1425 to std::vector<partial_symbol *>.
1426 * objfiles.c (objfile::objfile): Don't memset those fields.
1427 (objfile::~objfile): Don't free those fields.
1428 * psympriv.h (struct psymbol_allocation_list): Remove
1429 forward-declaration.
1430 (add_psymbol_to_list): Change psymbol_allocation_list parameter
1432 (start_psymtab_common): Change parameters to std::vector.
1433 * psymtab.c: Include algorithm.
1434 (require_partial_symbols): Call shrink_to_fit.
1435 (find_pc_sect_psymbol): Adjust to vector change.
1436 (match_partial_symbol): Likewise.
1437 (lookup_partial_symbol): Likewise.
1438 (psym_relocate): Likewise.
1439 (dump_psymtab): Likewise.
1440 (recursively_search_psymtabs): Likewise.
1441 (compare_psymbols): Remove.
1442 (sort_pst_symbols): Adjust to vector change.
1443 (start_psymtab_common): Likewise.
1444 (end_psymtab_common): Likewise.
1445 (psymbol_bcache_full): De-constify return value.
1446 (add_psymbol_to_bcache): Likewise.
1447 (extend_psymbol_list): Remove.
1448 (append_psymbol_to_list): Adjust to vector change.
1449 (add_psymbol_to_list): Likewise.
1450 (init_psymbol_list): Likewise.
1451 (maintenance_info_psymtabs): Likewise.
1452 (maintenance_check_psymtabs): Likewise.
1453 * symfile.h (struct psymbol_allocation_list): Remove.
1454 * symfile.c (reread_symbols): Adjust to vector change.
1455 * dbxread.c (start_psymtab): Change type of parameters.
1456 (dbx_symfile_read): Adjust to vector change.
1457 (read_dbx_symtab): Likewise.
1458 (start_psymtab): Change type of parameters.
1459 * dwarf2read.c (dwarf2_build_psymtabs): Adjust to vector change.
1460 (create_partial_symtab): Likewise.
1461 (add_partial_symbol): Likewise.
1462 (write_one_signatured_type): Likewise.
1463 (recursively_write_psymbols): Likewise.
1464 * mdebugread.c (parse_partial_symbols): Likewise.
1465 * xcoffread.c (xcoff_start_psymtab): Change type of parameters.
1466 (scan_xcoff_symtab): Adjust to vector change.
1467 (xcoff_initial_scan): Likewise.
1469 2017-10-13 Simon Marchi <simon.marchi@ericsson.com>
1471 * ada-typeprint.c (print_dynamic_range_bound): Use std::string.
1473 2017-10-13 Yao Qi <yao.qi@linaro.org>
1475 * features/Makefile: Remove tic6x-*-expedite, add tic6x-expedite.
1476 Remove s390x-*-expedite, add s390x-expedite.
1478 2017-10-13 Yao Qi <yao.qi@linaro.org>
1480 * features/s390-gs-linux64.c: Regenerated.
1481 * features/s390x-gs-linux64.c: Regenerated.
1483 2017-10-13 Tom Tromey <tom@tromey.com>
1485 * compile/compile-object-run.c (do_module_cleanup): Use delete.
1486 * solib.c (update_solib_list, reload_shared_libraries_1): Use
1488 * symfile.c (symbol_file_add_with_addrs): Use new.
1489 (symbol_file_add_separate): Update comment.
1490 (syms_from_objfile_1, remove_symbol_file_command): Use delete.
1491 * jit.c (jit_object_close_impl): Use new.
1492 (jit_unregister_code): Use delete.
1493 * objfiles.c (objfile::objfile): Rename from allocate_objfile.
1494 (~objfile): Rename from free_objfile.
1495 (free_objfile_separate_debug, do_free_objfile_cleanup)
1496 (free_all_objfiles, objfile_purge_solibs): Use delete.
1497 * objfiles.h (struct objfile): Add constructor and destructor.
1498 Use DISABLE_COPY_AND_ASSIGN. Add initializers to data members.
1499 (allocate_objfile, free_objfile): Don't declare.
1500 (struct objstats): Add initializers.
1502 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
1504 * arch-utils.h (simple_displaced_step_copy_insn): Remove.
1505 * arch-utils.c (simple_displaced_step_copy_insn): Remove.
1506 * gdbarch.sh (displaced_step_copy_insn): Adjust comment.
1507 * gdbarch.h: Regenerate.
1508 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
1510 * i386-tdep.c (i386_displaced_step_copy_insn): Adjust comment.
1511 (i386_displaced_step_fixup): Adjust comment.
1512 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Adjust comment.
1514 2017-10-12 Tom Tromey <tom@tromey.com>
1516 * prologue-value.h (pv_area::store_would_trash): Return bool.
1517 (pv_area::find_reg): Likewise.
1518 * prologue-value.c (pv_area::store_would_trash): Return bool.
1519 (pv_area::find_reg): Likewise.
1521 2017-10-12 Tom Tromey <tom@tromey.com>
1523 * s390-linux-tdep.c (s390_store, s390_load)
1524 (s390_check_for_saved, s390_analyze_prologue): Update.
1525 * rx-tdep.c (check_for_saved, rx_analyze_prologue): Update.
1526 * rl78-tdep.c (rl78_analyze_prologue, check_for_saved): Update.
1527 * prologue-value.h (class pv_area): Move from prologue-value.c.
1528 Change names of members. Add constructor, destructor, member
1530 (make_pv_area, free_pv_area, make_cleanup_free_pv_area)
1531 (pv_area_store, pv_area_fetch, pv_area_store_would_trash)
1532 (pv_area_fetch, pv_area_scan): Don't declare.
1533 * prologue-value.c (struct pv_area::area_entry): Now member of
1535 (struct pv_area): Move to prologue-value.h.
1536 (pv_area::pv_area): Rename from make_pv_area.
1537 (pv_area::~pv_area): Rename from free_pv_area.
1538 (do_free_pv_area_cleanup, make_cleanup_free_pv_area): Remove.
1539 (clear_entries, find_entry, overlaps, store_would_trash, store)
1540 (fetch, find_reg, scan): Now member of pv_area.
1541 Remove "area" argument. Update.
1542 * msp430-tdep.c (check_for_saved, msp430_analyze_prologue):
1544 * mn10300-tdep.c (push_reg, check_for_saved)
1545 (mn10300_analyze_prologue): Update.
1546 * mep-tdep.c (is_arg_spill, check_for_saved)
1547 (mep_analyze_prologue): Update.
1548 * m32c-tdep.c (m32c_pv_push, m32c_srcdest_fetch)
1549 (m32c_srcdest_store, m32c_pv_enter, m32c_is_arg_spill)
1550 (m32c_is_struct_return, m32c_analyze_prologue): Update.
1551 * arm-tdep.c (thumb_analyze_prologue, arm_analyze_prologue):
1553 * arc-tdep.c (arc_is_in_prologue, arc_analyze_prologue): Update.
1554 * aarch64-tdep.c (aarch64_analyze_prologue): Update.
1556 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
1558 * linux-nat.h (linux_nat_set_delete_thread): New declaration.
1559 * linux-nat.c (linux_nat_delete_thread): New variable.
1560 (lwp_free): Invoke linux_nat_delete_thread if set.
1561 (linux_nat_set_delete_thread): New function.
1562 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Assign
1563 thread delete callback.
1564 * arm-linux-nat.c (arm_linux_delete_thread): New function.
1565 (_initialize_arm_linux_nat): Assign thread delete callback.
1566 * s390-linux-nat.c (s390_delete_thread): New function.
1567 (_initialize_s390_nat): Assign thread delete callback.
1568 * x86-linux-nat.c (x86_linux_add_target): Likewise.
1569 * nat/aarch64-linux.c (aarch64_linux_delete_thread): New
1571 * nat/aarch64-linux.h (aarch64_linux_delete_thread): New
1573 * nat/x86-linux.c (x86_linux_delete_thread): New function.
1574 * nat/x86-linux.h (x86_linux_delete_thread): New declaration.
1576 2017-10-09 Tom Tromey <tom@tromey.com>
1578 * tui/tui-win.c (tui_set_win_height, parse_scrolling_args): Use
1580 * tui/tui-layout.c (enum tui_status): Use std::string.
1582 2017-10-11 Tom Tromey <tom@tromey.com>
1584 * gdbthread.h (thread_command): Constify.
1585 * inferior.h (detach_command): Constify.
1586 * top.h (set_history, show_history): Constify.
1587 * arm-tdep.c (set_arm_command, show_arm_command): Constify.
1588 * serial.c (serial_set_cmd, serial_show_cmd): Constify.
1589 * bsd-kvm.c (bsd_kvm_cmd): Constify.
1590 * printcmd.c (set_command): Constify.
1591 (non_const_set_command): New function.
1592 * dcache.c (set_dcache_command, show_dcache_command): Constify.
1593 * breakpoint.c (enable_command, disable_command, delete_command)
1594 (catch_command, tcatch_command, set_breakpoint_cmd)
1595 (show_breakpoint_cmd): Constify.
1596 * macrocmd.c (macro_command): Constify.
1597 * infcmd.c (unset_command, kill_command, detach_command)
1598 (info_proc_cmd): Constify.
1599 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Constify.
1600 * auto-load.c (show_auto_load_cmd, set_auto_load_cmd)
1601 (info_auto_load_cmd): Constify.
1602 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
1603 (unset_tdesc_cmd): Constify.
1604 * ada-lang.c (set_ada_command, show_ada_command)
1605 (maint_set_ada_cmd, maint_show_ada_cmd): Constify.
1606 * guile/guile.c (set_guile_command, show_guile_command)
1607 (info_guile_command): Constify.
1608 * tui/tui-win.c (tui_command, set_tui_cmd, show_tui_cmd):
1610 * skip.c (skip_command): Constify.
1611 * compile/compile.c (_initialize_compile): Constify.
1612 * dwarf2read.c (set_dwarf_cmd, show_dwarf_cmd): Constify.
1613 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
1614 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
1615 (maint_btrace_pt_show_cmd): Constify.
1616 * remote.c (set_remote_cmd, show_remote_cmd, remote_command):
1618 * python/python.c (user_show_python, user_set_python): Constify.
1619 * mips-tdep.c (set_mips_command, show_mips_command)
1620 (set_mipsfpu_command): Constify.
1621 * record-btrace.c (cmd_record_btrace_start)
1622 (cmd_set_record_btrace, cmd_show_record_btrace)
1623 (cmd_set_record_btrace_bts, cmd_show_record_btrace_bts)
1624 (cmd_set_record_btrace_pt, cmd_show_record_btrace_pt): Constify.
1625 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command):
1627 * symfile.c (overlay_command): Constify.
1628 * spu-tdep.c (set_spu_command, show_spu_command): Constify.
1629 * cli/cli-logging.c (set_logging_command, show_logging_command):
1631 * cli/cli-dump.c (dump_command, append_command)
1632 (srec_dump_command, ihex_dump_command, verilog_dump_command)
1633 (tekhex_dump_command, binary_dump_command)
1634 (binary_append_command): Constify.
1635 * cli/cli-decode.c (struct cmd_list_element): Change type of
1637 * cli/cli-cmds.c (info_command, show_command, set_debug)
1638 (show_debug): Constify.
1639 (show_command): Add non-const overload.
1640 * top.c (set_history, show_history): Constify.
1641 * sh-tdep.c (set_sh_command, show_sh_command): Constify.
1642 * command.h (add_prefix_cmd): Accept a cmd_const_cfunc_ftype.
1643 * target.c (target_command): Constify.
1644 * sparc64-tdep.c (info_adi_command): Constify.
1645 * record-full.c (cmd_record_full_start): Constify.
1646 (set_record_full_command): Constify. Fix typo.
1647 (show_record_full_command): Constify.
1648 * thread.c (thread_command, thread_apply_command): Constify.
1649 * memattr.c (dummy_cmd): Constify.
1650 * value.c (function_command): Constify.
1651 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Constify.
1652 * probe.c (info_probes_command): Constify.
1653 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Constify.
1654 * gnu-nat.c (set_task_cmd, show_task_cmd, set_thread_cmd)
1655 (show_thread_cmd, set_thread_default_cmd)
1656 (show_thread_default_cmd): Constify.
1657 (check_empty): Constify.
1658 * tracepoint.c (tfind_command): Constify.
1659 * cp-support.c (maint_cplus_command): Constify.
1660 * windows-tdep.c (info_w32_command): Constify.
1661 * record.c (cmd_record_start, set_record_command)
1662 (show_record_command, info_record_command, cmd_record_goto):
1664 * ravenscar-thread.c (set_ravenscar_command)
1665 (show_ravenscar_command): Constify.
1666 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
1668 (add_internal_problem_command): Remove casts.
1669 * arc-tdep.c (maintenance_print_arc_command): Constify.
1670 * valprint.c (set_print, show_print, set_print_raw)
1671 (show_print_raw): Constify.
1672 * maint.c (maintenance_command, maintenance_info_command)
1673 (maintenance_print_command, maintenance_set_cmd)
1674 (maintenance_show_cmd, set_per_command_cmd)
1675 (show_per_command_cmd, maintenance_check_command): Constify.
1676 * language.c (set_check, show_check): Constify.
1677 * typeprint.c (show_print_type, set_print_type): Constify.
1678 * go32-nat.c (go32_info_dos_command): Constify.
1680 2017-10-11 Tom Tromey <tom@tromey.com>
1682 * breakpoint.c (prepare_re_set_context): Remove.
1683 (breakpoint_re_set_one): Update. Don't use cleanups.
1684 (breakpoint_re_set): Use scoped_restore, std::string, and
1685 scoped_restore_current_language.
1687 2017-10-11 Tom Tromey <tom@tromey.com>
1689 * breakpoint.c (commands_command_1): Use std::string.
1690 (cleanup_executing_breakpoints): Remove.
1691 (bpstat_do_actions_1): Use scoped_restore.
1692 (bpstat_check_watchpoint): Use std::string.
1693 (decode_static_tracepoint_spec): Likewise.
1694 (break_range_command): Likewise.
1695 (watch_command_1): Likewise.
1696 (compare_breakpoints): Change argument types.
1697 (clear_command): Use std::vector.
1698 (cleanup_executing_breakpoints): Remove.
1699 (update_global_location_list): Use unique_xmalloc_ptr.
1700 (strace_command): Remove unused declaration.
1702 2017-10-11 John Baldwin <jhb@FreeBSD.org>
1704 * Makefile.in (ALLDEPFILES): Add arm-fbsd-nat.c.
1705 * NEWS: Mention new FreeBSD/arm native configuration.
1706 * configure.host: Add arm*-*-freebsd*.
1707 * configure.nat: Likewise.
1708 * arm-fbsd-nat.c: New file.
1710 2017-10-11 John Baldwin <jhb@FreeBSD.org>
1712 * Makefile.in (ALL_TARGET_OBS): Add arm-fbsd-tdep.o.
1713 (ALLDEPFILES): Add arm-fbsd-tdep.c.
1714 * NEWS: Mention new FreeBSD/arm target.
1715 * configure.tgt: Add arm*-*-freebsd*.
1716 * arm-fbsd-tdep.c: New file.
1717 * arm-fbsd-tdep.h: New file.
1719 2017-10-11 Maciej W. Rozycki <macro@imgtec.com>
1721 * linux-tdep.c (linux_make_corefile_notes): Remove call to
1722 `gdbarch_elfcore_write_linux_prpsinfo'.
1723 * gdbarch.sh (elfcore_write_linux_prpsinfo): Remove architecture
1725 (elf_internal_linux_prpsinfo): Remove declaration.
1726 * gdbarch.h: Regenerate.
1727 * gdbarch.c: Regenerate.
1729 2017-10-11 Maciej W. Rozycki <macro@imgtec.com>
1731 * ppc-linux-tdep.c (ppc_linux_init_abi): Remove call to
1732 `set_gdbarch_elfcore_write_linux_prpsinfo'.
1734 2017-10-11 Pedro Alves <palves@redhat.com>
1736 * breakpoint.c (reattach_breakpoints): Delete.
1737 * breakpoint.h (reattach_breakpoints): Delete.
1739 2017-10-11 Simon Marchi <simon.marchi@ericsson.com>
1741 * symfile.c (registered_sym_fns): Make struct, not typedef.
1742 (DEF_VEC_O (registered_sym_fns)): Remove.
1743 (symtab_fns): Change type to std::vector.
1744 (add_symtab_fns): Adjust.
1745 (find_sym_fns): Adjust.
1747 2017-10-11 Anton Kolesov <Anton.Kolesov@synopsys.com>
1749 * arc-tdep.c (arc_gdbarch_init): Pass proper cpu value to disassembler.
1750 * arc-tdep.h (arc_arch_is_em): New function.
1751 (arc_arch_is_hs): Likewise.
1753 2017-10-11 Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
1755 * macrotab.h (macro_lookup_inclusion): Remove unnecessary
1756 parentheses in the declaration.
1757 (macro_lookup_inclusion): Likewise.
1758 (macro_lookup_definition): Likewise.
1759 * p-lang.h (pascal_builtin_types): Likewise.
1760 * tui/tui-data.c (tui_win_list): Likewise.
1761 * tui/tui-data.h (tui_win_list): Likewise.
1762 * utils.h (make_cleanup_free_section_addr_info): Likewise.
1764 2017-10-11 Mark Rages <markrages@gmail.com>
1766 * target-memory.c (block_boundaries): Fix for block address not
1767 aligned on block size.
1769 2017-10-10 Pedro Alves <palves@redhat.com>
1770 Tom Tromey <tom@tromey.com>
1772 * breakpoint.c (struct captured_breakpoint_query_args)
1773 (do_captured_breakpoint_query, gdb_breakpoint_query): Delete.
1774 (print_breakpoint): New.
1775 * breakpoint.h (print_breakpoint): Declare.
1776 * common/common-exceptions.h (enum return_reason): Remove
1777 references to catch_exceptions.
1778 * exceptions.c (catch_exceptions, catch_exceptions_with_msg):
1780 * exceptions.h (catch_exceptions_ftype, catch_exceptions)
1781 (catch_exception_ftype, catch_exceptions_with_msg): Delete.
1783 * gdbthread.h (thread_select): Declare.
1784 * mi/mi-cmd-break.c: Don't include gdb.h.
1785 (breakpoint_notify): Use print_breakpoint.
1786 * mi/mi-cmd-catch.c: Don't include gdb.h.
1787 * mi/mi-interp.c: Don't include gdb.h.
1788 (mi_print_breakpoint_for_event): New.
1789 (mi_breakpoint_created, mi_breakpoint_modified): Use
1790 mi_print_breakpoint_for_event.
1791 * mi/mi-main.c: Don't include gdb.h.
1792 (mi_cmd_thread_select): Parse the global thread ID here. Use
1793 thread_select instead of gdb_thread_select.
1794 (mi_cmd_thread_list_ids): Output "thread-ids" tuple here instead
1795 of using gdb_list_thread_ids.
1796 * remote-fileio.c (do_remote_fileio_request): Change type. Reply
1798 (remote_fileio_request): Use TRY/CATCH instead of
1800 * symfile-mem.c (struct symbol_file_add_from_memory_args)
1801 (symbol_file_add_from_memory_wrapper): Delete.
1802 (add_vsyscall_page): Use TRY/CATCH instead of catch_exceptions.
1803 * thread.c: Don't include gdb.h.
1804 (do_captured_list_thread_ids, gdb_list_thread_ids): Delete.
1805 (thread_alive): Use thread_select.
1806 (do_captured_thread_select): Delete, parts salvaged as ...
1807 (thread_select): ... this new function.
1808 (gdb_thread_select): Delete.
1810 2017-10-10 Pedro Alves <palves@redhat.com>
1811 Tom Tromey <tom@tromey.com>
1813 * breakpoint.c (breakpoint_cond_eval): Change return type to bool
1815 (WP_DELETED, WP_VALUE_CHANGED, WP_VALUE_NOT_CHANGED, WP_IGNORE):
1816 No longer macros. Instead ...
1817 (enum wp_check_result): They're now values of this new
1819 (watchpoint_check): Change return type to wp_check_result and
1820 parameter type to bpstat.
1821 (bpstat_check_watchpoint): Use TRY/CATCH instead of catch_errors.
1822 (bpstat_check_breakpoint_conditions): Use TRY/CATCH instead of
1823 catch_errors. Reverse logic of watchpoint_check call.
1824 (breakpoint_re_set_one): Now returns void and takes a breakpoint
1825 pointer as parameter.
1826 (breakpoint_re_set): Use TRY/CATCH instead of catch_errors.
1827 * common/common-exceptions.c (throw_exception_sjlj): Update
1828 comments to avoid mentioning catch_errors.
1829 * exceptions.c (catch_errors): Delete.
1830 * exceptions.h: Update comments to avoid mentioning catch_errors.
1831 (catch_errors_ftype, catch_errors): Delete.
1832 * infrun.c (normal_stop): Use TRY/CATCH instead of catch_errors.
1833 (hook_stop_stub): Delete.
1834 (restore_selected_frame): Change return type to void, and
1835 parameter type to const frame_id &.
1836 (restore_infcall_control_state): Use TRY/CATCH instead of
1838 * main.c (captured_command_loop): Return void and remove
1839 parameter. Remove references to catch_errors.
1840 (captured_main): Use TRY/CATCH instead of catch_errors.
1841 * objc-lang.c (objc_submethod_helper_data)
1842 (find_objc_msgcall_submethod_helper): Delete.
1843 (find_objc_msgcall_submethod): Use TRY/CATCH instead of
1845 * record-full.c (record_full_message): Return void.
1846 (record_full_message_args, record_full_message_wrapper): Delete.
1847 (record_full_message_wrapper_safe): Return bool and use TRY/CATCH
1848 instead of catch_errors.
1849 * solib-aix.c (solib_aix_open_symbol_file_object): Change
1850 parameter type to int.
1851 * solib-darwin.c (open_symbol_file_object): Ditto.
1852 * solib-dsbt.c (open_symbol_file_object): Ditto.
1853 * solib-frv.c (open_symbol_file_object): Ditto.
1854 * solib-svr4.c (open_symbol_file_object): Ditto.
1855 * solib-target.c (solib_target_open_symbol_file_object): Ditto.
1856 * solib.c (update_solib_list): Use TRY/CATCH instead of
1858 * solist.h (struct target_so_ops) <open_symbol_file_object>:
1860 * symmisc.c (struct print_symbol_args): Remove.
1861 (dump_symtab_1): Use TRY/CATCH instead of catch_errors.
1862 (print_symbol): Change type.
1863 * windows-nat.c (handle_load_dll, handle_unload_dll): Return void
1864 and remove parameters.
1865 (catch_errors): New.
1866 (get_windows_debug_event): Adjust.
1868 2017-10-09 Tom Tromey <tom@tromey.com>
1870 * mi/mi-main.c (free_splay_tree): Remove.
1871 (list_available_thread_groups): Use splay_tree_up.
1872 * common/gdb_splay_tree.h: New file.
1874 2017-10-09 Tom Tromey <tom@tromey.com>
1876 * mi/mi-main.c (do_nothing): Remove.
1877 (list_available_thread_groups): Update.
1879 2017-10-09 Pedro Alves <palves@redhat.com>
1881 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>: Skip
1882 reading registers when switching context.
1884 2017-10-09 John Baldwin <jhb@FreeBSD.org>
1886 * fbsd-nat.c (fbsd_siginfo_size): Use gdbarch_long_bit.
1887 (fbsd_convert_siginfo): Likewise.
1888 * fbsd-tdep.c (fbsd_core_xfer_siginfo): Likewise.
1890 2017-10-09 Simon Marchi <simon.marchi@polymtl.ca>
1892 * configure.ac (try_guile_versions): Remove guile-2.2.
1893 * configure: Regenerate.
1895 2017-10-09 Tom Tromey <tom@tromey.com>
1897 * Makefile.in (COMPILE.post, POSTCOMPILE): Restore $(basename).
1898 (COMPILE.pre): Use $(CXX).
1900 2017-10-09 Pedro Alves <palves@redhat.com>
1902 * cp-support.c (cp_remove_params): Return a gdb::unique_xmalloc_ptr.
1904 (overload_list_add_symbol): Adjust to use gdb::unique_xmalloc_ptr.
1905 * cp-support.h (cp_remove_params): Now returns a
1906 gdb::unique_xmalloc_ptr.
1907 * dwarf2read.c (find_slot_in_mapped_hash): Now returns bool.
1908 Adjust to cp_remove_params returning a gdb::unique_xmalloc_ptr.
1909 * psymtab.c (psymtab_search_name): Adjust to cp_remove_params
1910 returning a gdb::unique_xmalloc_ptr.
1911 (lookup_partial_symbol): Adjust to use gdb::unique_xmalloc_ptr.
1912 * stack.c (find_frame_funname): Adjust to cp_remove_params
1913 returning a gdb::unique_xmalloc_ptr.
1915 2017-10-08 Tom Tromey <tom@tromey.com>
1917 * dwarf2read.c (dwarf2_get_dwz_file): Use
1918 gdb::unique_xmalloc_ptr.
1919 (find_slot_in_mapped_hash): Likewise.
1920 (dwarf2_physname): Likewise.
1921 (create_dwo_unit_in_dwp_v1): Use std::string.
1922 (create_dwo_unit_in_dwp_v2): Likewise.
1923 (lookup_dwo_cutu): Likewise.
1924 (inherit_abstract_dies): Use std::vector.
1925 (read_array_type): Likewise.
1926 (dwarf_decode_macros): Remove unused declaration.
1927 (unsigned_int_compar): Remove.
1928 (dwarf2_build_psymtabs_hard): Use scoped_restore.
1929 (psymtabs_addrmap_cleanup): Remove.
1931 2017-10-08 Tom Tromey <tom@tromey.com>
1933 * frame-unwind.c (frame_unwind_try_unwinder): Update.
1934 * frame.h (frame_cleanup_after_sniffer): Declare.
1935 (frame_prepare_for_sniffer): Return void.
1936 * frame.c (frame_cleanup_after_sniffer): No longer static. Change
1938 (frame_prepare_for_sniffer): Return void.
1940 2017-10-08 Tom Tromey <tom@tromey.com>
1942 * utils.h (make_cleanup_value_free): Remove.
1943 * utils.c (do_value_free, struct cleanup): Remove.
1944 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full) <DWARF_VALUE_STACK>:
1946 * value.h (struct value_deleter): New.
1947 (gdb_value_up): New typedef.
1949 2017-10-08 Tom Tromey <tom@tromey.com>
1951 * symtab.c (free_search_symbols, do_free_search_symbols_cleanup)
1952 (make_cleanup_free_search_symbols): Remove.
1953 (search_symbols): Return std::vector.
1954 (symbol_search::compare_search_syms): Now member of
1955 symbol_search. Change arguments.
1956 (sort_search_symbols_remove_dups): Change arguments. Rewrite.
1957 (symtab_symbol_info, rbreak_command): Update.
1958 * symtab.h (struct symbol_search) <next>: Remove.
1960 (symbol_search::operator<): New function.
1961 (symbol_search::operator==): New function.
1962 (search_symbols): Remove std::vector.
1963 (free_search_symbols, make_cleanup_free_search_symbols): Remove.
1964 (symbol_search::compare_search_syms): Declare.
1966 2017-10-06 Yao Qi <yao.qi@linaro.org>
1968 * Makefile.in (ALL_64_TARGET_OBS): Replace aarch64-insn.o with
1969 arch/aarch64-insn.o.
1971 * configure.tgt: Replace aarch64-insn.o with arch/aarch64-insn.o.
1973 2017-10-06 Yao Qi <yao.qi@linaro.org>
1975 * Makefile.in (ALL_TARGET_OBS): Replace arm.o, arm-get-next-pcs.o,
1976 and arm-linux.o with arch/arm.o, arch/arm-get-next-pcs.o and
1977 arch/arm-linux.o respectively.
1978 * configure.tgt: Likewise.
1980 2017-10-06 Yao Qi <yao.qi@linaro.org>
1982 * Makefile.in (ALL_TARGET_OBS): Rename i386.o to arch/i386.o.
1983 * configure.tgt (i386_tobjs): Replace i386.o with arch/i386.o.
1985 2017-10-06 Pedro Alves <palves@redhat.com>
1987 * windows-nat.c: Include <algorithm>.
1989 2017-10-06 Yao Qi <yao.qi@linaro.org>
1991 * configure.tgt (i386_tobjs): New variable.
1992 (amd64_tobjs): New variable.
1993 Set $cpu_obs and $os_obs.
1995 2017-10-06 Yao Qi <yao.qi@linaro.org>
1997 * Makefile.in (CONFIG_SRC_SUBDIR): New.
1998 (ALL_64_TARGET_OBS): Replace amd64.o with arch/amd64.o.
1999 (clean): Remove object files and dependency files.
2000 (distclean): Remove the directory.
2001 * configure.ac: Invoke AC_CONFIG_COMMANDS.
2002 * configure: Re-generated.
2003 * configure.tgt: Replace amd64.o with arch/amd64.o.
2005 2017-10-05 Jose E. Marchesi <jose.marchesi@oracle.com>
2008 * arm-tdep.c (arm_decode_misc_memhint_neon): Fix decoding of CPS
2011 2017-10-05 Pedro Alves <palves@redhat.com>
2013 * linux-nat.c (linux_child_follow_fork): When following the parent
2014 and detaching the child, consult the parent thread's architecture
2015 instead of the child's.
2017 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
2019 * ax.h: Do not include "doublest.h".
2020 (union agent_val): Remove.
2022 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
2024 * dfp.h (MAX_DECIMAL_STRING): Move to dfp.c.
2025 (decimal_to_string): Return std::string object.
2026 (decimal_from_string): Accept std::string object. Return bool.
2027 (decimal_from_integral, decimal_from_doublest): Remove.
2028 (decimal_from_longest): Add prototype.
2029 (decimal_from_ulongest): Likewise.
2030 (decimal_to_longest): Likewise.
2031 (decimal_from_doublest): Likewise.
2032 * dfp.c: Do not include "gdbtypes.h" or "value.h".
2033 (MAX_DECIMAL_STRING): Move here.
2034 (decimal_to_string): Return std::string object.
2035 (decimal_from_string): Accept std::string object. Return bool.
2036 (decimal_from_integral): Remove, replace by ...
2037 (decimal_from_longest, decimal_from_ulongest): ... these new functions.
2038 (decimal_to_longest): New function.
2039 (decimal_from_floating): Remove, replace by ...
2040 (decimal_from_doublest): ... this new function.
2041 (decimal_to_doublest): Update to new decimal_to_string interface.
2043 * value.c (unpack_long): Use decimal_to_longest.
2044 * valops.c (value_cast): Use decimal_from_doublest instead of
2045 decimal_from_floating. Use decimal_from_[u]longest isntead of
2046 decimal_from_integral.
2047 * valarith.c (value_args_as_decimal): Likewise.
2048 * valprint.c (print_decimal_floating): Update to new
2049 decimal_to_string interface.
2050 * printcmd.c (printf_decfloat): Likewise.
2051 * c-exp.y (parse_number): Update to new decimal_from_string interface.
2053 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
2055 * doublest.h: Do not include "floatformat.h". Remove stale comments.
2056 * gdbtypes.c: Include "floatformat.h".
2057 * value.c: Likewise.
2058 * m68k-tdep.c: Likewise.
2060 * findvar.c: Do not include "floatformat.h".
2061 * amd64-darwin-tdep.c: Likewise.
2062 * arm-linux-tdep.c: Likewise.
2063 * i386-darwin-tdep.c: Likewise.
2064 * i387-tdep.c: Likewise.
2065 * m68k-linux-tdep.c: Likewise.
2066 * mep-tdep.c: Likewise.
2067 * mips-tdep.c: Likewise.
2068 * nios2-tdep.c: Likewise.
2069 * s390-linux-tdep.c: Likewise.
2070 * sparc-obsd-tdep.c: Likewise.
2071 * sparc-tdep.c: Likewise.
2072 * sparc64-tdep.c: Likewise.
2073 * spu-tdep.c: Likewise.
2074 * tic6x-tdep.c: Likewise.
2075 * tilegx-tdep.c: Likewise.
2076 * vax-tdep.c: Likewise.
2077 * xstormy16-tdep.c: Likewise.
2078 * xtensa-tdep.c: Likewise.
2080 * top.c: Do not include "doublest.h".
2081 * aarch64-tdep.c: Likewise.
2082 * alpha-tdep.c: Likewise.
2083 * arm-linux-tdep.c: Likewise.
2084 * m68k-linux-tdep.c: Likewise.
2085 * tilegx-tdep.c: Likewise.
2086 * xstormy16-tdep.c: Likewise.
2088 2017-10-05 John Baldwin <jhb@FreeBSD.org>
2090 * mips-fbsd-tdep.c (MIPS_INST_ADDIU_A0_SP_N32): Define.
2091 (mipsn32_fbsd_sigframe): Define.
2092 (mips_fbsd_init_abi): Install mipsn32_fbsd_sigframe unwinder
2093 for FreeBSD/mipsn32.
2095 2017-10-05 John Baldwin <jhb@FreeBSD.org>
2097 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_EHDRFLAGS and
2100 2017-10-05 Tristan Gingold <tgingold@free.fr>
2102 * MAINTAINERS (Misc): Update my email address.
2104 2017-10-04 Pedro Alves <palves@redhat.com>
2106 * remote.c (get_remote_arch_state): New 'gdbarch' parameter. Use
2107 it instead of target_gdbarch.
2108 (get_remote_state, get_remote_packet_size): Adjust
2109 get_remote_arch_state calls, passing down target_gdbarch
2111 (packet_reg_from_regnum, packet_reg_from_pnum): New parameter
2112 'gdbarch' and use it instead of target_gdbarch.
2113 (get_memory_packet_size): Adjust get_remote_arch_state calls,
2114 passing down target_gdbarch explicitly.
2115 (struct stop_reply) <arch>: New field.
2116 (remote_parse_stop_reply): Use the stopped thread's architecture,
2117 not the current inferior's. Save the architecture in the
2119 (process_stop_reply): Use the stop reply's architecture.
2120 (process_g_packet, remote_fetch_registers)
2121 (remote_prepare_to_store, store_registers_using_G)
2122 (remote_store_registers): Adjust get_remote_arch_state calls,
2123 using the regcache's architecture.
2124 (remote_get_trace_status): Adjust get_remote_arch_state calls,
2125 passing down target_gdbarch explicitly.
2126 * spu-multiarch.c (spu_thread_architecture): Defer to the target
2127 beneath instead of calling target_gdbarch.
2128 * target.c (default_thread_architecture): Use the specified
2129 inferior's architecture, instead of the current inferior's
2130 architecture (via target_gdbarch).
2132 2017-10-04 Pedro Alves <palves@redhat.com>
2134 * regcache.c (get_thread_arch_regcache): Remove null_ptid special
2136 (regcache_print): Handle !target_has_registers here instead.
2138 2017-10-04 Pedro Alves <palves@redhat.com>
2140 * frame.c (create_test_frame): Delete.
2141 * frame.h (create_test_frame): Delete.
2142 * gdbarch-selftests.c: Include gdbthread.h and target.h.
2143 (class regcache_test): Delete.
2144 (test_target_has_registers, test_target_has_stack)
2145 (test_target_has_memory, test_target_prepare_to_store)
2146 (test_target_store_registers): New functions.
2147 (test_target_ops): New class.
2148 (register_to_value_test): Error out if there's already a
2149 process_stratum (or higher) target pushed. Create a fuller mock
2150 environment, with mock target_ops, inferior, address space, thread
2152 * progspace.c (struct address_space): Move to ...
2153 * progspace.h (struct address_space): ... here.
2154 * regcache.h (regcache::~regcache, regcache::raw_write)
2155 [GDB_SELF_TEST]: No longer virtual.
2157 2017-10-04 Simon Marchi <simon.marchi@ericsson.com>
2159 * mi/mi-main.c (list_available_thread_groups): Reverse filter logic.
2161 2017-10-04 Pedro Alves <palves@redhat.com>
2163 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Move code
2164 out of 'between TRY and CATCH'.
2166 2017-10-04 Pedro Alves <palves@redhat.com>
2168 * cli/cli-cmds.c (complete_command): Add missing END_CATCH.
2169 * common/common-exceptions.h (TRY): Open an outermost scope.
2170 Expand intro comment.
2172 (END_CATCH): Close the outermost scope.
2173 * completer.c (complete_line_internal): Add missing END_CATCH.
2175 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2177 * NEWS (Changes since GDB 8.0): Add entry about new
2178 'set-cwd-on-gdbserver' feature.
2179 (New remote packets): Add entry for QSetWorkingDir.
2180 * common/common-inferior.h (set_inferior_cwd): New prototype.
2181 * infcmd.c (set_inferior_cwd): Remove "static".
2182 (show_cwd_command): Expand text to include remote debugging.
2183 * remote.c: Add PACKET_QSetWorkingDir.
2184 (remote_protocol_features) <QSetWorkingDir>: New entry for
2185 PACKET_QSetWorkingDir.
2186 (extended_remote_set_inferior_cwd): New function.
2187 (extended_remote_create_inferior): Call
2188 "extended_remote_set_inferior_cwd".
2189 (_initialize_remote): Call "add_packet_config_cmd" for
2192 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2194 * NEWS (New commands): Mention "set/show cwd".
2195 * cli/cli-cmds.c (_initialize_cli_cmds): Mention "set cwd" on
2196 "cd" command's help text.
2197 * common/common-inferior.h (get_inferior_cwd): New prototype.
2198 * infcmd.c (inferior_cwd_scratch): New global variable.
2199 (set_inferior_cwd): New function.
2200 (get_inferior_cwd): Likewise.
2201 (set_cwd_command): Likewise.
2202 (show_cwd_command): Likewise.
2203 (_initialize_infcmd): Add "set/show cwd" commands.
2204 * inferior.h (class inferior) <cwd>: New field.
2205 * nat/fork-inferior.c: Include "gdb_tilde_expand.h".
2206 (fork_inferior): Change inferior's cwd before its execution.
2207 * windows-nat.c (windows_create_inferior): Pass inferior's cwd
2210 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2212 * Makefile.in (SFILES): Add gdb_tilde_expand.c.
2213 (HFILES_NO_SRCDIR): Add gdb_tilde_expand.h.
2214 (COMMON_OBS): Add gdb_tilde_expand.o.
2215 * common/gdb_tilde_expand.c: New file.
2216 * common/gdb_tilde_expand.h: Likewise.
2218 2017-10-03 Maciej W. Rozycki <macro@imgtec.com>
2220 * gdbarch.sh (objfile): Remove duplicate declaration.
2221 * gdbarch.h: Regenerate.
2223 2017-10-03 Tom Tromey <tom@tromey.com>
2225 * utils.c (internal_vproblem): Use string_vprintf.
2227 2017-10-03 Tom Tromey <tom@tromey.com>
2229 * printcmd.c (info_symbol_command): Use std::string.
2231 2017-10-03 Tom Tromey <tom@tromey.com>
2233 * top.c (gdb_safe_append_history): Use std::string.
2235 2017-10-03 Tom Tromey <tom@tromey.com>
2237 * event-top.c (stdin_event_handler): Update.
2238 * main.c (captured_main_1): Update.
2239 * top.h (make_delete_ui_cleanup): Remove.
2240 (struct ui): Add constructor and destructor.
2241 (new_ui, delete_ui): Remove.
2242 * top.c (make_delete_ui_cleanup): Remove.
2243 (new_ui_command): Use std::unique_ptr.
2244 (delete_ui_cleanup): Remove.
2245 (ui::ui): Rename from new_ui. Update.
2247 (ui::~ui): Rename from delete_ui. Update.
2249 2017-10-03 Tom Tromey <tom@tromey.com>
2251 * symfile.c (load_progress): Use gdb::byte_vector.
2253 2017-10-03 Tom Tromey <tom@tromey.com>
2255 * mi/mi-main.c (mi_cmd_trace_frame_collected): Remove unused
2257 * printcmd.c (x_command): Remove unused declaration.
2258 * symfile.c (symbol_file_command): Remove unused declaration.
2260 2017-10-03 Tom Tromey <tom@tromey.com>
2262 * utils.c (internal_vproblem): Use std::string.
2263 (defaulted_query): Likewise.
2265 2017-10-03 Tom Tromey <tom@tromey.com>
2267 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Update.
2268 * top.c (execute_command_to_string): Update.
2269 * utils.c (make_cleanup_restore_page_info): Remove.
2270 (do_restore_page_info_cleanup): Remove.
2271 (set_batch_flag_and_restore_page_info):
2273 (make_cleanup_restore_page_info): Remove.
2274 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
2275 (~set_batch_flag_and_restore_page_info): New
2276 (make_cleanup_restore_uinteger): Remove.
2277 (make_cleanup_restore_integer): Remove.
2278 (struct restore_integer_closure): Remove.
2279 (restore_integer): Remove.
2280 * utils.h (struct set_batch_flag_and_restore_page_info): New
2282 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
2283 (make_cleanup_restore_page_info): Remove.
2284 (make_cleanup_restore_uinteger) Remove.
2285 (make_cleanup_restore_integer) Remove.
2287 2017-10-03 Tom Tromey <tom@tromey.com>
2289 * record-full.h (record_full_gdb_operation_disable_set): Return
2290 scoped_restore_tmpl<int>.
2291 * infrun.c (adjust_pc_after_break): Update.
2292 (handle_signal_stop): Update.
2293 * record-full.c (record_full_gdb_operation_disable_set): Return
2294 scoped_restore_tmpl<int>.
2295 (record_full_wait_1, record_full_insert_breakpoint)
2296 (record_full_remove_breakpoint, record_full_save)
2297 (record_full_goto_insn): Update.
2299 2017-10-02 Tom Tromey <tom@tromey.com>
2302 * rust-lang.c (rust_val_print_str): New function.
2303 (val_print_struct): Call it.
2304 (rust_subscript): Preserve name of slice type.
2306 2017-10-02 Tom Tromey <tom@tromey.com>
2308 * rust-lang.c (rust_subscript): Handle slices in
2309 EVAL_AVOID_SIDE_EFFECTS case.
2311 2017-10-02 Tom Tromey <tom@tromey.com>
2313 * rust-lang.c (rust_slice_type_p): Recognize &str as a slice type.
2315 2017-10-02 Tom Tromey <tom@tromey.com>
2317 * rust-lang.h (rust_slice_type): Add "extern".
2319 2017-10-02 Tom Tromey <tom@tromey.com>
2320 Pedro Alves <palves@redhat.com>
2322 * ada-lang.h (ada_exc_info::operator<): Make const.
2323 (ada_exc_info::operator==): Make const.
2324 * ada-lang.c (ada_exc_info::operator<, ada_exc_info::operator==):
2327 2017-09-29 Tom Tromey <tom@tromey.com>
2329 * target.c (read_whatever_is_readable): Change type of "result".
2331 (free_memory_read_result_vector): Remove.
2332 (read_memory_robust): Change return type. Update.
2333 * mi/mi-main.c (mi_cmd_data_read_memory_bytes): Update. Use
2334 bin2hex, std::string.
2335 * target.h (memory_read_result_s): Remove typedef.
2336 (free_memory_read_result_vector): Remove.
2337 (read_memory_robust): Return std::vector.
2339 2017-09-29 Tom Tromey <tom@tromey.com>
2341 * mi/mi-main.c (captured_mi_execute_command): Use scope_restore.
2343 2017-09-29 Tom Tromey <tom@tromey.com>
2345 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Update.
2346 * ada-lang.h (struct ada_exc_info): Remove typedef. Declare
2347 operator< and operator==.
2348 (ada_exceptions_list): Return a std::vector.
2349 * ada-lang.c (ada_exc_info::operator<): Rename from
2350 compare_ada_exception_info.
2351 (ada_exc_info::operator==): New.
2352 (sort_remove_dups_ada_exceptions_list): Change type of
2354 (ada_add_standard_exceptions, ada_add_exceptions_from_frame)
2355 (ada_add_global_exceptions): Likewise.
2356 (ada_exceptions_list_1): Return a std::vector.
2357 (ada_exceptions_list): Likewise.
2359 2017-09-29 Tom Tromey <tom@tromey.com>
2361 * mi/mi-main.c (struct print_one_inferior_data) <inferiors>: Now a
2363 (print_one_inferior): Update.
2364 (free_vector_of_ints): Remove.
2365 (list_available_thread_groups): Change "ids" to std::set.
2366 (mi_cmd_list_thread_groups): Update.
2367 (struct collect_cores_data) <core>: Now a std::set.
2368 (collect_cores): Update.
2370 (print_one_inferior): Update.
2372 2017-09-29 Tom Tromey <tom@tromey.com>
2374 * mi/mi-main.c (mi_execute_cli_command): Use std::string.
2375 (mi_execute_async_cli_command): Likewise.
2376 (mi_cmd_trace_frame_collected): Use field_fmt.
2378 2017-09-29 Tom Tromey <tom@tromey.com>
2380 * mi/mi-main.c (mi_cmd_data_write_memory_bytes): Use
2383 2017-09-29 Tom Tromey <tom@tromey.com>
2385 * mi/mi-parse.c (mi_parse): Remove unused declaration.
2387 2017-09-29 Tom Tromey <tom@tromey.com>
2389 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Don't copy "oarg".
2391 2017-09-29 Tom Tromey <tom@tromey.com>
2393 * varobj.h (varobj_gen_name): Return std::string.
2394 * varobj.c (varobj_gen_name): Return std::string.
2395 * mi/mi-cmd-var.c (mi_cmd_var_create): Use std::string.
2396 (mi_cmd_var_delete): Don't copy "name".
2398 2017-09-29 Tom Tromey <tom@tromey.com>
2400 * mi/mi-cmd-break.c (mi_argv_to_format): Return std::string.
2401 (mi_cmd_break_insert_1): Update.
2403 2017-09-29 Tom Tromey <tom@tromey.com>
2405 * target.h (make_scoped_defer_target_commit_resume): Update.
2406 * target.c (make_scoped_defer_target_commit_resume): Rename from
2407 make_cleanup_defer_target_commit_resume. Return a
2409 * infrun.c (proceed): Use make_scoped_defer_target_commit_resume.
2411 2017-09-29 Tom Tromey <tom@tromey.com>
2413 * main.c (captured_main_1): Remove unused declaration.
2414 * spu-multiarch.c (parse_spufs_run): Remove unused declaration.
2416 2017-09-29 Tom Tromey <tom@tromey.com>
2418 * symtab.c (search_symbols): Remove unused outer cleanup.
2419 (make_source_files_completion_list): Remove unused declaration.
2421 2017-09-29 Tom Tromey <tom@tromey.com>
2423 * mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.
2425 2017-09-29 Tom Tromey <tom@tromey.com>
2427 * xstormy16-tdep.c (xstormy16_push_dummy_call): Use
2430 2017-09-29 Tom Tromey <tom@tromey.com>
2432 * complaints.c (vcomplaint): Use std::string.
2434 2017-09-29 Tom Tromey <tom@tromey.com>
2436 * tracepoint.c (trace_variable_command): Use std::string.
2437 (encode_actions_1): Remove unused declarations.
2438 (create_tsv_from_upload): Use std::string.
2440 2017-09-29 Tom Tromey <tom@tromey.com>
2442 * cp-support.c (gdb_demangle): Use std::string.
2444 2017-09-29 Tom Tromey <tom@tromey.com>
2446 * stack.c (parse_frame_specification): Use std::string
2447 (info_frame_command): Use gdb::unique_xmalloc_ptr.
2449 2017-09-29 Tom Tromey <tom@tromey.com>
2451 * tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.
2453 2017-09-29 Tom Tromey <tom@tromey.com>
2455 * utils.c (vfprintf_maybe_filtered): Use std::string.
2456 (vfprintf_unfiltered): Likewise.
2458 2017-09-29 Tom Tromey <tom@tromey.com>
2460 * event-top.c (top_level_prompt): Return std::string.
2461 (display_gdb_prompt): Update.
2463 2017-09-29 Tom Tromey <tom@tromey.com>
2465 * unittests/common-utils-selftests.c (format): New function.
2466 (string_vprintf_tests): New function.
2467 (_initialize_common_utils_selftests): Register new tests.
2468 * common/common-utils.c (string_vprintf): New function.
2469 * common/common-utils.h (string_vprintf): Declare.
2471 2017-09-29 Pedro Alves <palves@redhat.com>
2473 * common/rsp-low.c (unpack_varlen_hex): Constify.
2474 * common/rsp-low.h (unpack_varlen_hex): Constify.
2475 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
2477 * remote.c (remote_set_permissions, read_ptid)
2478 (remote_current_thread, remote_get_threads_with_qthreadinfo)
2479 (remote_static_tracepoint_marker_at)
2480 (remote_static_tracepoint_markers_by_strid)
2481 (stop_reply_extract_thread, remote_parse_stop_reply): Constify.
2482 * tracepoint.c (parse_trace_status, parse_tracepoint_status)
2483 (parse_tracepoint_definition, parse_tsv_definition)
2484 (parse_static_tracepoint_marker_definition): Constify.
2485 * tracepoint.h (parse_static_tracepoint_marker_definition)
2486 (parse_trace_status, parse_tracepoint_status)
2487 (parse_tracepoint_definition, parse_tsv_definition): Constify.
2489 2017-09-29 Pedro Alves <palves@redhat.com>
2491 * remote.c (target_buf, target_buf_size): Delete.
2492 (remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
2493 Use the connection's packet buffer instead.
2494 All callers adjusted.
2495 (_initialize_remote): Remove references to target_buf and
2498 2017-09-28 Pedro Alves <palves@redhat.com>
2500 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2501 unittests/common-utils-selftests.c.
2502 (SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
2503 (COMMON_OBS): Remove utils-selftests.o.
2504 * utils-selftests.c: Move to ...
2505 * unittests/common-utils-selftests.c: ... here and rename self
2506 test to "string_printf".
2508 2017-09-28 Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com> (tiny patch)
2510 * dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
2511 having NULL cus or tus.
2513 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
2515 * arm-tdep.c: (convert_from_extended): Remove.
2516 (convert_to_extended): Likewise.
2517 (arm_extract_return_value): Use convert_typed_floating.
2518 (arm_store_return_value): Likewise.
2520 * sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
2521 * sh-tdep.c: Do not include "floatformat.h".
2522 (sh_littlebyte_bigword_type): New function.
2523 (sh_register_convert_to_virtual): Use convert_typed_floating.
2524 (sh_register_convert_to_raw): Likewise.
2525 * sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
2526 (sh64_littlebyte_bigword_type): New function.
2527 (sh64_extract_return_value): Use convert_typed_floating.
2528 (sh64_register_convert_to_virtual): Likewise.
2529 (sh64_register_convert_to_raw): Likewise.
2531 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
2533 * doublest.h (floatformat_from_type): Move to gdbtypes.h.
2534 * doublest.c (floatformat_from_type): Move to gdbtypes.c.
2536 * gdbtypes.h (union type_specific): Make field floatformat hold
2537 just a single struct floatformat, not an array.
2538 (floatformat_from_type): Move here.
2539 * gdbtypes.c (floatformat_from_type): Move here. Update to
2540 changed TYPE_FLOATFORMAT definition.
2541 (verify_floatformat): Update to changed TYPE_FLOATFORMAT.
2542 (recursive_dump_type): Likewise.
2543 (init_float_type): Install correct floatformat for byte order.
2544 (arch_float_type): Likewise.
2546 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
2548 * gdbtypes.c (init_type): Change incoming argument from
2549 length-in-bytes to length-in-bits. Assert length is a
2550 multiple of TARGET_CHAR_BITS.
2551 (arch_type, arch_flags_type): Likewise.
2552 (init_integer_type): Update call to init_type.
2553 (init_character_type): Likewise.
2554 (init_boolean_type): Likewise.
2555 (init_float_type): Likewise.
2556 (init_decfloat_type): Likewise.
2557 (init_complex_type): Likewise.
2558 (init_pointer_type): Likewise.
2559 (objfile_type): Likewise.
2560 (arch_integer_type): Update call to arch_type.
2561 (arch_character_type): Likewise.
2562 (arch_boolean_type): Likewise.
2563 (arch_float_type): Likewise.
2564 (arch_decfloat_type): Likewise.
2565 (arch_complex_type): Likewise.
2566 (arch_pointer_type): Likewise.
2567 (gdbtypes_post_init): Likewise.
2569 * dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
2570 (read_base_type): Likewise.
2571 * mdebugread.c (basic_type): Likewise.
2572 * stabsread.c (dbx_init_float_type): Likewise.
2573 (rs6000_builtin_type): Likewise.
2574 (read_range_type): Likewise. Also, fix call to init_integer_type
2575 with erroneous length argument.
2577 * ada-lang.c (ada_language_arch_info): Update call to arch_type.
2578 * d-lang.c (build_d_types): Likewise.
2579 * f-lang.c (build_fortran_types): Likewise.
2580 * go-lang.c (build_go_types): Likewise.
2581 * opencl-lang.c (build_opencl_types): Likewise.
2582 * jit.c (finalize_symtab): Likewise.
2583 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
2584 (build_std_type_info_type): Likewise.
2585 * target-descriptions.c (tdesc_gdb_type): Likewise. Also,
2586 update call to arch_flags_type.
2588 * linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
2590 * fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
2591 * windows-tdep.c (windows_get_tlb_type): Likewise.
2593 * avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
2594 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
2595 * m32c-tdep.c (make_types): Likewise.
2596 * rl78-tdep.c (rl78_gdbarch_init): Likewise.
2597 (rl78_psw_type): Update call to arch_flags_type.
2598 * m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
2599 * rx-tdep.c (rx_psw_type): Likewise.
2600 (rx_fpsw_type): Likewise.
2601 * sparc-tdep.c (sparc_psr_type): Likewise.
2602 (sparc_fsr_type): Likewise.
2603 * sparc64-tdep.c (sparc64_pstate_type): Likewise.
2604 (sparc64_ccr_type): Likewise.
2605 (sparc64_fsr_type): Likewise.
2606 (sparc64_fprs_type): Likewise.
2608 2017-09-27 Tom Tromey <tom@tromey.com>
2610 * findcmd.c (find_command): Constify.
2612 2017-09-27 Tom Tromey <tom@tromey.com>
2614 * ada-tasks.c (task_command_1, task_command): Constify.
2616 2017-09-27 Tom Tromey <tom@tromey.com>
2618 * symtab.c (maintenance_print_symbol_cache)
2619 (maintenance_flush_symbol_cache)
2620 (maintenance_print_symbol_cache_statistics): Constify.
2622 2017-09-27 Tom Tromey <tom@tromey.com>
2624 * inferior.c (detach_inferior_command, kill_inferior_command)
2625 (inferior_command): Constify.
2627 2017-09-27 Tom Tromey <tom@tromey.com>
2629 * regcache.c (regcache_print, maintenance_print_registers)
2630 (maintenance_print_raw_registers)
2631 (maintenance_print_cooked_registers)
2632 (maintenance_print_register_groups)
2633 (maintenance_print_remote_registers): Constify.
2635 2017-09-27 Tom Tromey <tom@tromey.com>
2637 * printcmd.c (map_display_numbers, undisplay_command)
2638 (enable_disable_display_command, enable_display_command)
2639 (disable_display_command): Constify.
2641 2017-09-27 Tom Tromey <tom@tromey.com>
2643 * breakpoint.h (delete_command): Don't declare.
2644 * breakpoint.c (delete_command, enable_once_command)
2645 (enable_count_command, enable_delete_command, breakpoint_1)
2646 (maintenance_info_breakpoints, stopin_command, stopat_command)
2647 (delete_command, delete_trace_command, save_breakpoints)
2648 (save_breakpoints_command, save_tracepoints_command): Constify.
2650 2017-09-27 Tom Tromey <tom@tromey.com>
2652 * macrocmd.c (macro_expand_command, macro_expand_once_command)
2653 (skip_ws, extract_identifier, macro_define_command)
2654 (macro_undef_command, macro_list_command): Constify.
2656 2017-09-27 Tom Tromey <tom@tromey.com>
2658 * infcmd.c (environment_info, set_environment_command)
2659 (unset_environment_command, path_info, info_proc_cmd_1)
2660 (info_proc_cmd_mappings, info_proc_cmd_stat)
2661 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
2662 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
2664 2017-09-27 Tom Tromey <tom@tromey.com>
2666 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
2669 2017-09-27 Tom Tromey <tom@tromey.com>
2671 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
2673 2017-09-27 Tom Tromey <tom@tromey.com>
2675 * demangle.c (demangle_command): Constify.
2677 2017-09-27 Tom Tromey <tom@tromey.com>
2679 * progspace.c (maintenance_info_program_spaces_command):
2682 2017-09-27 Tom Tromey <tom@tromey.com>
2684 * compile/compile.c (check_raw_argument, compile_file_command)
2685 (compile_code_command, compile_print_command): Constify.
2687 2017-09-27 Tom Tromey <tom@tromey.com>
2689 * reggroups.c (maintenance_print_reggroups): Constify.
2691 2017-09-27 Tom Tromey <tom@tromey.com>
2693 * dwarf2read.c (save_gdb_index_command): Constify.
2695 2017-09-27 Tom Tromey <tom@tromey.com>
2697 * stap-probe.c (info_probes_stap_command): Constify.
2699 2017-09-27 Tom Tromey <tom@tromey.com>
2701 * fork-child.c (unset_exec_wrapper_command): Constify.
2703 2017-09-27 Tom Tromey <tom@tromey.com>
2705 * btrace.c (get_uint, get_context_size, no_chunk)
2706 (maint_btrace_packet_history_cmd)
2707 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
2708 (maint_info_btrace_cmd): Constify.
2710 2017-09-27 Tom Tromey <tom@tromey.com>
2712 * reverse.c (delete_bookmark_command): Constify.
2714 2017-09-27 Tom Tromey <tom@tromey.com>
2716 * remote.c (set_memory_packet_size)
2717 (set_memory_write_packet_size, show_memory_write_packet_size)
2718 (set_memory_read_packet_size, show_memory_read_packet_size)
2719 (compare_sections_command, packet_command, remote_put_command)
2720 (remote_get_command, remote_delete_command): Constify.
2722 2017-09-27 Tom Tromey <tom@tromey.com>
2724 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
2725 (set_mipsfpu_double_command, set_mipsfpu_none_command)
2726 (set_mipsfpu_auto_command): Constify.
2728 2017-09-27 Tom Tromey <tom@tromey.com>
2730 * cli/cli-cmds.h (cd_command): Constify.
2731 * cli/cli-cmds.c (cd_command): Constify.
2733 2017-09-27 Tom Tromey <tom@tromey.com>
2735 * thread.c (thread_name_command, thread_find_command): Constify.
2737 2017-09-27 Tom Tromey <tom@tromey.com>
2739 * probe.c (enable_probes_command, disable_probes_command):
2742 2017-09-27 Tom Tromey <tom@tromey.com>
2744 * symfile.c (symbol_file_command): Constify.
2745 * gdbcore.h (deprecated_file_changed_hook): Constify.
2746 * exec.c (deprecated_file_changed_hook, exec_file_command)
2747 (file_command): Constify.
2748 * defs.h (symbol_file_command): Constify.
2750 2017-09-27 Tom Tromey <tom@tromey.com>
2752 * remote-fileio.c (set_system_call_allowed)
2753 (show_system_call_allowed): Constify.
2755 2017-09-27 Tom Tromey <tom@tromey.com>
2757 * tracepoint.c (delete_trace_variable_command)
2758 (tfind_end_command, tfind_start_command, tfind_pc_command)
2759 (tfind_tracepoint_command, tfind_line_command)
2760 (tfind_range_command, tfind_outside_command): Constify.
2762 2017-09-27 Tom Tromey <tom@tromey.com>
2764 * ax-gdb.c (maint_agent_printf_command, agent_command)
2765 (agent_eval_command): Constify.
2767 2017-09-27 Tom Tromey <tom@tromey.com>
2769 * tracepoint.c (info_scope_command): Constify.
2770 * python/python.c (gdbpy_decode_line): Constify.
2771 * python/py-breakpoint.c (bppy_init): Constify.
2772 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
2773 * location.h: (new_linespec_location)
2774 (string_to_event_location_basic, string_to_event_location):
2776 * location.c (new_linespec_location)
2777 (string_to_event_location_basic, string_to_event_location):
2779 * linespec.h (decode_line_with_current_source)
2780 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
2781 * linespec.c (linespec_lex_to_end)
2782 (decode_line_with_current_source)
2783 (decode_line_with_last_displayed): Constify.
2784 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
2786 * cli/cli-cmds.c (edit_command, list_command): Constify.
2787 * breakpoint.h (until_break_command, watch_command_wrapper)
2788 (awatch_command_wrapper, rwatch_command_wrapper)
2789 (init_ada_exception_breakpoint): Constify.
2790 * breakpoint.c (break_command_1, dprintf_command)
2791 (break_range_command, watch_command_wrapper)
2792 (rwatch_command_wrapper, awatch_command_wrapper)
2793 (until_break_command, init_ada_exception_breakpoint)
2794 (strace_marker_create_sals_from_location, trace_command)
2795 (ftrace_command, strace_command, struct tracepoint): Constify.
2796 * ax-gdb.c (agent_command_1): Constify.
2797 * ada-lang.c (ada_exception_sal): Constify.
2799 2017-09-27 Tom Tromey <tom@tromey.com>
2801 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
2802 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
2803 (get_context_size, no_chunk, get_insn_history_modifiers)
2804 (cmd_record_insn_history, get_call_history_modifiers)
2805 (cmd_record_call_history): Constify.
2807 2017-09-27 Tom Tromey <tom@tromey.com>
2809 * source.c (show_substitute_path_command)
2810 (unset_substitute_path_command, set_substitute_path_command):
2813 2017-09-27 Tom Tromey <tom@tromey.com>
2815 * typeprint.c (maintenance_print_type): Constify.
2816 * maint.c (maintenance_dump_me, maintenance_demangle)
2817 (maintenance_time_display, maintenance_info_sections)
2818 (maintenance_print_statistics, maintenance_deprecate)
2819 (maintenance_undeprecate): Constify.
2820 (maintenance_do_deprecate): Constify. Use std::string.
2821 (maintenance_selftest): Constify.
2822 * gdbtypes.h (maintenance_print_type): Constify.
2824 2017-09-27 Tom Tromey <tom@tromey.com>
2826 * hppa-tdep.c (unwind_command): Constify.
2828 2017-09-27 Tom Tromey <tom@tromey.com>
2830 * target-descriptions.c (unset_tdesc_filename_cmd)
2831 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
2834 2017-09-27 Tom Tromey <tom@tromey.com>
2836 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
2838 2017-09-27 Tom Tromey <tom@tromey.com>
2840 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
2842 2017-09-27 Tom Tromey <tom@tromey.com>
2844 * tui/tui-regs.c (tui_reg_command): Constify.
2846 2017-09-27 Tom Tromey <tom@tromey.com>
2848 * skip.c (skip_file_command, skip_function_command)
2849 (skip_enable_command, skip_disable_command, skip_delete_command):
2852 2017-09-27 Tom Tromey <tom@tromey.com>
2854 * record-btrace.c (cmd_record_btrace_bts_start)
2855 (cmd_record_btrace_pt_start): Constify.
2857 2017-09-27 Tom Tromey <tom@tromey.com>
2859 * symmisc.c (maintenance_print_symbols)
2860 (maintenance_print_msymbols, maintenance_print_objfiles)
2861 (maintenance_info_symtabs, maintenance_check_symtabs)
2862 (maintenance_expand_symtabs, maintenance_info_line_tables):
2865 2017-09-27 Tom Tromey <tom@tromey.com>
2867 * top.c (new_ui_command): Constify.
2869 2017-09-27 Tom Tromey <tom@tromey.com>
2871 * symfile.c (add_symbol_file_command)
2872 (remove_symbol_file_command, list_overlays_command)
2873 (map_overlay_command, unmap_overlay_command)
2874 (overlay_auto_command, overlay_manual_command)
2875 (overlay_off_command, overlay_load_command): Constify.
2877 2017-09-27 Tom Tromey <tom@tromey.com>
2879 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
2880 (info_spu_mailbox_command, info_spu_dma_command)
2881 (info_spu_proxydma_command): Constify.
2883 2017-09-27 Tom Tromey <tom@tromey.com>
2885 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
2887 2017-09-27 Tom Tromey <tom@tromey.com>
2889 * cli/cli-script.c (user_defined_command): Constify.
2891 2017-09-27 Tom Tromey <tom@tromey.com>
2893 * cli/cli-dump.c (dump_memory_command, dump_value_command)
2894 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
2895 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
2896 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
2897 (dump_binary_value, append_binary_memory, append_binary_value):
2899 (struct dump_context) <func>: Constify.
2900 (add_dump_command): Update.
2902 2017-09-27 Tom Tromey <tom@tromey.com>
2904 * cli/cli-cmds.c (show_version, show_configuration)
2905 (source_command, show_user): Constify.
2907 2017-09-27 Tom Tromey <tom@tromey.com>
2909 * target.c (maintenance_print_target_stack): Constify.
2911 2017-09-27 Tom Tromey <tom@tromey.com>
2913 * interps.c (interpreter_exec_cmd): Constify.
2915 2017-09-27 Tom Tromey <tom@tromey.com>
2917 * record-full.c (cmd_record_full_restore): Constify.
2919 2017-09-27 Tom Tromey <tom@tromey.com>
2921 * memattr.c (enable_mem_command, disable_mem_command)
2922 (delete_mem_command): Constify.
2924 2017-09-27 Tom Tromey <tom@tromey.com>
2926 * value.c (show_convenience): Constify.
2928 2017-09-27 Tom Tromey <tom@tromey.com>
2930 * gdbcore.h (core_file_command): Update.
2931 * corefile.c (core_file_command): Constify.
2933 2017-09-27 Tom Tromey <tom@tromey.com>
2935 * user-regs.c (maintenance_print_user_registers): Constify.
2937 2017-09-27 Tom Tromey <tom@tromey.com>
2939 * cp-namespace.c (maintenance_cplus_namespace): Constify.
2941 2017-09-27 Tom Tromey <tom@tromey.com>
2943 * cp-support.c (first_component_command): Constify.
2945 2017-09-27 Tom Tromey <tom@tromey.com>
2947 * psymtab.c (maintenance_print_psymbols)
2948 (maintenance_info_psymtabs, maintenance_check_psymtabs):
2951 2017-09-27 Tom Tromey <tom@tromey.com>
2953 * windows-tdep.c (display_tib): Constify.
2955 2017-09-27 Tom Tromey <tom@tromey.com>
2957 * linux-fork.c (delete_checkpoint_command)
2958 (detach_checkpoint_command): Constify.
2960 2017-09-27 Tom Tromey <tom@tromey.com>
2962 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
2964 2017-09-27 Tom Tromey <tom@tromey.com>
2966 * arc-tdep.c (dump_arc_instruction_command): Constify.
2968 2017-09-27 Tom Tromey <tom@tromey.com>
2970 * valprint.c (set_radix, show_radix): Constify.
2972 2017-09-27 Tom Tromey <tom@tromey.com>
2974 * dtrace-probe.c (info_probes_dtrace_command): Constify.
2976 2017-09-27 Tom Tromey <tom@tromey.com>
2978 * command.h (not_just_help_class_command): Update.
2979 * cli/cli-decode.h (not_just_help_class_command): Update.
2980 * cli/cli-decode.c (not_just_help_class_command): Constify.
2982 2017-09-27 Tom Tromey <tom@tromey.com>
2984 * gdb_bfd.c (maintenance_info_bfds): Constify.
2986 2017-09-27 Tom Tromey <tom@tromey.com>
2988 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
2990 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
2991 (do_const_cfunc): New function.
2992 (cmd_cfunc_eq): New overload.
2993 (cli_user_command_p): Check do_const_cfunc.
2994 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
2996 * command.h (add_cmd): Add const overload and no-function
2998 (set_cmd_cfunc): Add const overload.
2999 (cmd_const_cfunc_ftype): Declare.
3000 (cmd_cfunc_eq): Add const overload.
3001 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
3002 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
3005 2017-09-27 Tom Tromey <tom@tromey.com>
3007 * macroexp.c (get_next_token_for_substitution): New function.
3008 (substitute_args): Call it. Check for __VA_OPT__.
3010 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
3011 Pedro Alves <palves@redhat.com>
3013 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
3014 producer_is_icc_lt_14.
3015 (producer_is_icc_lt_14): New function.
3016 (check_producer): Add code for checking version of ICC.
3017 (producer_is_icc): Move to producer.c.
3018 (read_structure_type): Restrict ICC workaround to ICC<14.
3019 * producer.c: Include selftest.h.
3020 (producer_is_icc, producer_parsing_tests, _initialize_producer):
3022 * producer.h (producer_is_icc): New declaration.
3024 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
3026 * Makefile.in (SFILES): Add producer.c.
3027 (COMMON_OBS): Add producer.o
3028 * amd64-tdep.c (producer.h): Add new include.
3029 * dwarf2read.c (producer.h): Add new include.
3030 * producer.c: New file.
3031 * producer.h: New file.
3032 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
3034 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
3037 2017-09-26 Matthias Klose <doko@ubuntu.com>
3039 * configure.ac: Search ncursesw before ncurses.
3040 Check ncursesw/ncurses.h before ncurses/ncurses.h.
3041 * gdb_curses.h: Include <ncursesw/ncurses.h>
3042 * config.in, configure: Regenerate.
3044 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3047 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
3049 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
3050 Remove i386sol2 support.
3051 * configure.nat <i386sol2>: Remove.
3052 <sol2-64>: Fold into ...
3054 Move common settings to default section.
3056 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
3057 x86_64-*-solaris2.1[0-9]*>: Rename to ...
3058 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
3059 <i[34567]86-*-solaris*>: Remove.
3060 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
3062 * configure.ac: Remove wctype in libw check.
3063 (_MSE_INT_H): Don't define on Solaris 7-9.
3064 <solaris*>: Remove libthread_db.so.1 check.
3065 * configure: Regenerate.
3066 * config.in: Regenerate.
3068 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
3069 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
3070 (gdb_ps_size_t): Remove.
3071 Use base types in users.
3072 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
3074 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
3076 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3079 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
3080 (adi_is_addr_mapped): Likewise.
3081 (PSR_ICC): Don't redefine.
3082 (PSR_IMPL): Likewise.
3084 2017-09-25 Tom Tromey <tom@tromey.com>
3086 * regcache.c (regcache::dump): Use string_printf.
3088 2017-09-25 Tom Tromey <tom@tromey.com>
3090 * regcache.c (class regcache_invalidator): New.
3091 (struct register_to_invalidate): Remove.
3092 (make_cleanup_regcache_invalidate): Remove.
3093 (regcache::raw_write): Use regcache_invalidator.
3095 2017-09-25 Tom Tromey <tom@tromey.com>
3097 * spu-tdep.c (spu2ppu_sniffer): Update.
3098 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
3099 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
3101 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
3102 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
3103 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
3104 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
3105 (frame_pop): Update.
3107 2017-09-25 Tom Tromey <tom@tromey.com>
3109 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
3110 * regcache.h (regcache_xfree): Don't declare.
3111 * regcache.c (regcache_xfree): Remove.
3112 (do_regcache_xfree): Use delete.
3113 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
3114 * linux-fork.c (free_fork): Use delete.
3115 (fork_save_infrun_state): Likewise.
3116 * jit.c (jit_dealloc_cache): Use delete.
3117 * infrun.c (discard_infcall_suspend_state): Use delete.
3119 2017-09-25 Tom Tromey <tom@tromey.com>
3121 * regcache.h (regcache_xmalloc): Don't declare.
3122 (regcache_raw_set_cached_value): Update comment.
3123 * regcache.c (regcache_xmalloc): Remove.
3124 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
3125 * jit.c (jit_frame_sniffer): Use new.
3126 * frame.c (frame_save_as_regcache): Use new.
3128 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
3130 * NEWS: Advertise support for guarded-storage registers on IBM z.
3132 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
3134 * s390-linux-nat.c (have_regset_gs): New static variable.
3135 (s390_linux_fetch_inferior_registers): Handle guarded-storage
3136 control block and guarded-storage broadcast control regsets.
3137 (s390_read_description): Detect whether the target has
3138 guarded-storage support, return appropriate tdesc.
3139 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
3140 (features/s390x-gs-linux64.c): Likewise.
3141 (struct gdbarch_tdep) <have_gs>: New field.
3142 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
3143 (s390_gsbc_regset): New variables.
3144 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
3145 and s390_gsbc_regset, if applicable.
3146 (s390_core_read_description): Check whether core file was from a
3147 target with guarded-storage support; include appropriate regsets.
3148 (s390_gdbarch_init): Add registers for guarded-storage support.
3149 (_initialize_s390_tdep): Initialize new target descriptions that
3150 include registers for guarded-storage support.
3151 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
3152 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
3153 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
3154 (S390_NUM_REGS): Adjust macro definition.
3155 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
3156 (tdesc_s390x_gs_linux64): New declarations.
3158 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
3160 * features/s390-gs-linux64.xml: New file.
3161 * features/s390-gs.xml: New file.
3162 * features/s390-gsbc.xml: New file.
3163 * features/s390x-gs-linux64.xml: New file.
3164 * features/Makefile (WHICH): Add s390-gs-linux64 and
3166 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
3167 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
3168 * features/s390-gs-linux64.c: New generated file.
3169 * features/s390x-gs-linux64.c: New file.
3170 * regformats/s390-gs-linux64.dat: New file.
3171 * regformats/s390x-gs-linux64.dat: New file.
3173 2017-09-23 Tom Tromey <tom@tromey.com>
3175 * defs.h (make_cleanup_override_quit_handler): Don't declare.
3177 2017-09-22 Tom Tromey <tom@tromey.com>
3179 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
3180 type to scoped_restore_tmpl.
3181 <scoped_input_handler>: Initialize m_quit_handler directly.
3183 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
3185 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
3186 (cd_command): Likewise. Free "current_directory" before
3188 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
3189 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
3190 * top.c (gdb_dirbuf): Remove global declaration.
3191 * top.h (gdb_dirbuf): Likewise.
3193 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
3195 * gnulib/aclocal.m4: Regenerate.
3196 * gnulib/config.in: Regenerate.
3197 * gnulib/configure: Regenerate.
3198 * gnulib/import/Makefile.am: Regenerate.
3199 * gnulib/import/Makefile.in: Regenerate.
3200 * gnulib/import/assure.h: New file.
3201 * gnulib/import/at-func.c: Likewise
3202 * gnulib/import/chdir-long.c: New file.
3203 * gnulib/import/chdir-long.h: New file.
3204 * gnulib/import/cloexec.c: New file.
3205 * gnulib/import/cloexec.h: New file.
3206 * gnulib/import/close.c: New file.
3207 * gnulib/import/closedir.c: New file.
3208 * gnulib/import/dirent-private.h: New file.
3209 * gnulib/import/dup-safer.c: New file.
3210 * gnulib/import/dup.c: New file.
3211 * gnulib/import/dup2.c: New file.
3212 * gnulib/import/error.c: New file.
3213 * gnulib/import/error.h: New file.
3214 * gnulib/import/exitfail.c: New file.
3215 * gnulib/import/exitfail.h: New file.
3216 * gnulib/import/fchdir.c: New file.
3217 * gnulib/import/fcntl.c: New file.
3218 * gnulib/import/fcntl.in.h: New file.
3219 * gnulib/import/fd-hook.c: New file.
3220 * gnulib/import/fd-hook.h: New file.
3221 * gnulib/import/fd-safer.c: New file.
3222 * gnulib/import/fdopendir.c: New file.
3223 * gnulib/import/filename.h: New file.
3224 * gnulib/import/filenamecat-lgpl.c: New file.
3225 * gnulib/import/filenamecat.h: New file.
3226 * gnulib/import/fstat.c: New file.
3227 * gnulib/import/fstatat.c: New file.
3228 * gnulib/import/getcwd-lgpl.c: New file.
3229 * gnulib/import/getcwd.c: New file.
3230 * gnulib/import/getdtablesize.c: New file.
3231 * gnulib/import/getlogin_r.c: New file.
3232 * gnulib/import/getprogname.c: New file.
3233 * gnulib/import/getprogname.h: New file.
3234 * gnulib/import/gettext.h: New file.
3235 * gnulib/import/glob-libc.h: New file.
3236 * gnulib/import/glob.c: New file.
3237 * gnulib/import/glob.in.h: New file.
3238 * gnulib/import/intprops.h: New file.
3239 * gnulib/import/m4/chdir-long.m4: New file.
3240 * gnulib/import/m4/close.m4: New file.
3241 * gnulib/import/m4/closedir.m4: New file.
3242 * gnulib/import/m4/d-ino.m4: New file.
3243 * gnulib/import/m4/d-type.m4: New file.
3244 * gnulib/import/m4/dup.m4: New file.
3245 * gnulib/import/m4/dup2.m4: New file.
3246 * gnulib/import/m4/error.m4: New file.
3247 * gnulib/import/m4/fchdir.m4: New file.
3248 * gnulib/import/m4/fcntl.m4: New file.
3249 * gnulib/import/m4/fcntl_h.m4: New file.
3250 * gnulib/import/m4/fdopendir.m4: New file.
3251 * gnulib/import/m4/filenamecat.m4: New file.
3252 * gnulib/import/m4/fstat.m4: New file.
3253 * gnulib/import/m4/fstatat.m4: New file.
3254 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
3255 * gnulib/import/m4/getcwd-path-max.m4: New file.
3256 * gnulib/import/m4/getcwd.m4: New file.
3257 * gnulib/import/m4/getdtablesize.m4: New file.
3258 * gnulib/import/m4/getlogin_r.m4: New file.
3259 * gnulib/import/m4/getprogname.m4: New file.
3260 * gnulib/import/m4/glob.m4: New file.
3261 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
3262 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
3263 * gnulib/import/m4/mempcpy.m4: New file.
3264 * gnulib/import/m4/memrchr.m4: New file.
3265 * gnulib/import/m4/mode_t.m4: New file.
3266 * gnulib/import/m4/msvc-inval.m4: New file.
3267 * gnulib/import/m4/msvc-nothrow.m4: New file.
3268 * gnulib/import/m4/open.m4: New file.
3269 * gnulib/import/m4/openat.m4: New file.
3270 * gnulib/import/m4/opendir.m4: New file.
3271 * gnulib/import/m4/readdir.m4: New file.
3272 * gnulib/import/m4/realloc.m4: New file.
3273 * gnulib/import/m4/rewinddir.m4: New file.
3274 * gnulib/import/m4/save-cwd.m4: New file.
3275 * gnulib/import/m4/strdup.m4: New file.
3276 * gnulib/import/m4/strerror.m4: New file.
3277 * gnulib/import/m4/unistd-safer.m4: New file.
3278 * gnulib/import/mempcpy.c: New file.
3279 * gnulib/import/memrchr.c: New file.
3280 * gnulib/import/msvc-inval.c: New file.
3281 * gnulib/import/msvc-inval.h: New file.
3282 * gnulib/import/msvc-nothrow.c: New file.
3283 * gnulib/import/msvc-nothrow.h: New file.
3284 * gnulib/import/open.c: New file.
3285 * gnulib/import/openat-die.c: New file.
3286 * gnulib/import/openat-priv.h: New file.
3287 * gnulib/import/openat-proc.c: New file.
3288 * gnulib/import/openat.c: New file.
3289 * gnulib/import/openat.h: New file.
3290 * gnulib/import/opendir.c: New file.
3291 * gnulib/import/pipe-safer.c: New file.
3292 * gnulib/import/readdir.c: New file.
3293 * gnulib/import/realloc.c: New file.
3294 * gnulib/import/rewinddir.c: New file.
3295 * gnulib/import/save-cwd.c: New file.
3296 * gnulib/import/save-cwd.h: New file.
3297 * gnulib/import/strdup.c: New file.
3298 * gnulib/import/strerror-override.c: New file.
3299 * gnulib/import/strerror-override.h: New file.
3300 * gnulib/import/strerror.c: New file.
3301 * gnulib/import/unistd--.h: New file.
3302 * gnulib/import/unistd-safer.h: New file.
3303 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
3304 "getcwd" and "glob".
3305 * ser-tcp.c: Undefine "close" before redefining it.
3307 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
3309 * guile/scm-value.c (gdbscm_value_address): Initialize address,
3312 2017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3314 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
3315 <sol2,sparc>: Likewise.
3316 <sol2-64,i386>: Likewise.
3318 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
3319 -Wdeprecated-declarations on *-*-solaris*.
3320 * configure: Regenerate.
3322 * procfs.c: Include "nat/inferior.h".
3323 (procfs_info_proc): Fix typo.
3325 2017-09-21 Kevin Buettner <kevinb@redhat.com>
3327 * remote.c (vector): Include.
3328 (struct private_thread_info): Add field, thread_handle.
3329 (free_private_thread_info): Deallocate storage associated with
3331 (get_private_info_thread): Initialize `thread_handle' field.
3332 (struct thread_item): Add field, thread_handle.
3333 (clear_threads_listing_context): Deallocate storage associated
3335 (start_thread): Add support for "handle" attribute.
3336 (thread_attributes): Add "handle".
3337 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
3339 (remote_update_thread_list): Update thread_handle.
3340 (remote_thread_handle_to_thread_info): New function.
3341 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
3343 2017-09-21 Kevin Buettner <kevinb@redhat.com>
3345 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
3347 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
3348 * python/python-internal.h (thread_object_type): Declare.
3350 2017-09-21 Kevin Buettner <kevinb@redhat.com>
3352 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
3353 (target_thread_handle_to_thread_info): Declare.
3354 * target.c (target_thread_handle_to_thread_info): New function.
3355 * target-delegates.c: Regenerate.
3356 * gdbthread.h (find_thread_by_handle): Declare.
3357 * thread.c (find_thread_by_handle): New function.
3358 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
3360 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
3362 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
3364 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
3366 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
3368 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
3370 2017-09-21 Yao Qi <yao.qi@linaro.org>
3372 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
3375 2017-09-20 Tom Tromey <tom@tromey.com>
3377 * breakpoint.c (struct counted_command_line): Remove.
3378 (breakpoint_commands): Update.
3379 (alloc_counted_command_line, incref_counted_command_line)
3380 (decref_counted_command_line, do_cleanup_counted_command_line)
3381 (make_cleanup_decref_counted_command_line): Remove.
3382 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
3383 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
3384 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
3385 (save_breakpoints): Update.
3386 * breakpoint.h (counted_command_line): Now a typedef to
3388 (struct breakpoint) <commands>: Now a counted_command_line.
3389 (struct bpstats) <command>: Likewise.
3391 2017-09-20 Tom Tromey <tom@tromey.com>
3393 * breakpoint.c (struct commands_info, do_map_commands_command):
3395 (commands_command_1): Update.
3396 (iterate_over_related_breakpoints): Take a function_view.
3397 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
3398 (delete_command): Update.
3399 (map_breakpoint_numbers): Take a function_view.
3400 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
3401 (disable_command): Update.
3402 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
3403 (enable_command): Update.
3404 (struct disp_data, do_enable_breakpoint_disp)
3405 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
3406 (do_map_enable_delete_breakpoint): Remove.
3407 (enable_once_command, enable_count_command, enable_delete_command)
3408 (delete_trace_variable_command): Update.
3410 2017-09-20 Tom Tromey <tom@tromey.com>
3412 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
3413 (bpstat_clear): Use delete.
3414 (bpstats): New constructors.
3415 (bpstat_copy, bpstat_stop_status): Use new.
3416 (dprintf_after_condition_true): Update.
3417 * breakpoint.h (bpstats::bpstats): Add constructors.
3418 (bpstats::~bpstats): Add destructor.
3420 2017-09-20 Pedro Alves <palves@redhat.com>
3422 * eval.c (make_params): Delete, refactored as ...
3423 (class fake_method): ... this new type's ctor.
3424 (fake_method::~fake_method): New.
3425 (evaluate_subexp_standard): Use 'fake_method'.
3427 2017-09-20 Tom Tromey <tom@tromey.com>
3429 * windows-nat.c (get_windows_debug_event, windows_wait)
3430 (do_initial_windows_stuff, windows_attach): Update.
3431 * utils.c (vwarning, internal_vproblem): Update.
3432 (ui_unregister_input_event_handler_cleanup)
3433 (prepare_to_handle_input): Remove.
3434 (class scoped_input_handler): New.
3435 (defaulted_query, prompt_for_continue): Update.
3436 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
3438 * top.c (undo_terminal_modifications_before_exit): Update.
3439 * target/target.h (target_terminal_init, target_terminal_inferior)
3440 (target_terminal_ours): Don't declare.
3441 (class target_terminal): New.
3442 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
3443 (target_terminal_ours_for_output)
3444 (make_cleanup_restore_target_terminal): Don't declare.
3445 (target_terminal_info): Remove.
3446 * target.c (enum terminal_state, terminal_state): Remove.
3447 (target_terminal::terminal_state): Define.
3448 (target_terminal::init): Rename from target_terminal_init.
3449 (target_terminal::inferior): Rename from
3450 target_terminal_inferior.
3451 (target_terminal::ours): Rename from target_terminal_ours.
3452 (target_terminal::ours_for_output): Rename from
3453 target_terminal_ours_for_output.
3454 (target_terminal::info): New method.
3455 (cleanup_restore_target_terminal)
3456 (make_cleanup_restore_target_terminal): Remove.
3457 * solib.c (handle_solib_event): Update.
3458 * remote.c (remote_serial_quit_handler): Update.
3459 (remote_terminal_inferior, remote_wait_as): Update.
3460 * record-full.c (record_full_wait_1): Update.
3461 * nto-procfs.c (procfs_create_inferior): Update.
3462 * nat/fork-inferior.c (startup_inferior): Update.
3463 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
3464 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
3465 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
3466 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
3467 (mi_breakpoint_created, mi_breakpoint_deleted)
3468 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
3469 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
3470 (mi_user_selected_context_changed, report_initial_inferior):
3472 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
3473 (linux_nat_terminal_inferior): Update.
3474 * infrun.c (follow_fork_inferior)
3475 (handle_vfork_child_exec_or_exit, do_target_resume)
3476 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
3477 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
3479 * inflow.c (child_terminal_init, info_terminal_command): Update.
3480 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
3481 (attach_command): Update.
3482 * infcall.c (call_thread_fsm_should_stop): Update.
3483 * gnu-nat.c (gnu_attach): Update.
3484 * extension.c (struct active_ext_lang_state)
3485 (restore_active_ext_lang): Update.
3486 * exceptions.c (print_flush): Update.
3487 * event-top.c (async_enable_stdin, default_quit_handler): Update.
3488 (struct quit_handler_cleanup_data, restore_quit_handler)
3489 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
3491 * cp-support.c (gdb_demangle): Update.
3492 * breakpoint.c (update_inserted_breakpoint_locations)
3493 (insert_breakpoint_locations, handle_jit_event)
3494 (disable_breakpoints_in_unloaded_shlib): Update.
3495 * annotate.c (annotate_breakpoints_invalid)
3496 (annotate_frames_invalid): Update.
3498 2017-09-20 Tom Tromey <tom@tromey.com>
3500 * main.c (catch_command_errors): Rename from
3501 catch_command_errors_const.
3502 (captured_main_1): Update.
3504 2017-09-20 Pedro Alves <palves@redhat.com>
3506 * cli/cli-cmds.c (list_command): Use print_sal_location.
3507 (print_sal_location): New function.
3508 (ambiguous_line_spec): Use print_sal_location.
3509 * linespec.c (symbol_to_sal): Record the symbol in the sal.
3510 * symtab.c (find_function_start_sal): Likewise.
3511 * symtab.h (symtab_and_line::symbol): New field.
3513 2017-09-20 Pedro Alves <palves@redhat.com>
3515 * linespec.c (minsym_found): Handle non-text minsyms.
3516 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
3518 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
3520 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
3523 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
3525 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
3526 vmovups instead vmovaps.
3527 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
3529 2017-09-19 John Baldwin <jhb@FreeBSD.org>
3531 * NEWS (Changes since GDB 8.0): Add starti.
3532 * infcmd.c (enum run_break): New.
3533 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
3535 (run_command): Use enum run_how.
3536 (start_command): Likewise.
3537 (starti_command): New function.
3538 (RUN_ARGS_HELP): New macro.
3539 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
3540 commands. Add starti command.
3542 2017-09-19 Yao Qi <yao.qi@linaro.org>
3544 * Makefile.in (monitor.o): Remove the rule.
3546 2017-09-19 Yao Qi <yao.qi@linaro.org>
3548 * annotate.h (struct annotate_arg_emitter): Use
3549 DISABLE_COPY_AND_ASSIGN.
3550 * common/refcounted-object.h (refcounted_object): Likewise.
3551 * completer.h (struct completion_result): Likewise.
3552 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
3553 * filename-seen-cache.h (filename_seen_cache): Likewise.
3554 * gdbcore.h (thread_section_name): Likewise.
3555 * gdb_regex.h (compiled_regex): Likewise.
3556 * gdbthread.h (scoped_restore_current_thread): Likewise.
3557 * inferior.h (scoped_restore_current_inferior): Likewise.
3558 * jit.c (jit_reader): Likewise.
3559 * linespec.h (struct linespec_result): Likewise.
3560 * mi/mi-parse.h (struct mi_parse): Likewise.
3561 * nat/fork-inferior.c (execv_argv): Likewise.
3562 * progspace.h (scoped_restore_current_program_space): Likewise.
3563 * python/python-internal.h (class gdbpy_enter): Likewise.
3564 * regcache.h (regcache): Likewise.
3565 * target-descriptions.c (struct tdesc_reg): Likewise.
3566 (struct tdesc_type): Likewise.
3567 (struct tdesc_feature): Likewise.
3568 * ui-out.h (ui_out_emit_type): Likewise.
3570 2017-09-18 Simon Marchi <simon.marchi@ericsson.com>
3572 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
3573 label abort_expression.
3575 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3577 * common/buffer.c (buffer_xml_printf): Adjust.
3578 * common/xml-utils.c (xml_escape_text): Change return type to
3579 std::string, update code accordingly.
3580 * common/xml-utils.h (xml_escape_text): Change return type to
3582 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
3583 * windows-tdep.c (windows_xfer_shared_library): Adjust.
3584 * unittests/xml-utils-selftests.c (test_xml_escape_text):
3587 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3589 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
3590 (SUBDIR_UNITTESTS_OBS): Add new object file.
3591 * unittests/xml-utils-selftests.c: New file.
3593 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3595 * common/selftest.h (selftest): New struct/interface.
3596 (register_test): Add name parameter, add new overload.
3597 (run_tests): Add filter parameter.
3598 (for_each_selftest_ftype): New typedef.
3599 (for_each_selftest): New declaration.
3600 * common/selftest.c (tests): Change type to
3601 map<string, unique_ptr<selftest>>.
3602 (simple_selftest): New struct.
3603 (register_test): New function.
3604 (register_test): Add name parameter and use it.
3605 (run_tests): Add filter parameter and use it. Add prints.
3606 Adjust to vector -> map change.
3607 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
3608 registering selftests.
3609 * arm-tdep.c (_initialize_arm_tdep): Likewise.
3610 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
3611 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
3612 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
3613 * findvar.c (_initialize_findvar): Likewise.
3614 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
3615 * maint.c (maintenance_selftest): Update call to run_tests.
3616 (maintenance_info_selftests): New function.
3617 (_initialize_maint_cmds): Register "maintenance info selftests"
3618 command. Update "maintenance selftest" doc.
3619 * regcache.c (_initialize_regcache): Add names when registering
3621 * rust-exp.y (_initialize_rust_exp): Likewise.
3622 * selftest-arch.c (gdbarch_selftest): New struct.
3623 (gdbarch_tests): Remove.
3624 (register_test_foreach_arch): Add name parameter. Call
3626 (tests_with_arch): Remove, move most content to
3627 gdbarch_selftest::operator().
3628 (_initialize_selftests_foreach_arch): Remove.
3629 * selftest-arch.h (register_test_foreach_arch): Add name
3631 (run_tests_with_arch): New declaration.
3632 * utils-selftests.c (_initialize_utils_selftests): Add names
3633 when registering selftests.
3634 * utils.c (_initialize_utils): Likewise.
3635 * unittests/array-view-selftests.c
3636 (_initialize_array_view_selftests): Likewise.
3637 * unittests/environ-selftests.c (_initialize_environ_selftests):
3639 * unittests/function-view-selftests.c
3640 (_initialize_function_view_selftests): Likewise.
3641 * unittests/offset-type-selftests.c
3642 (_initialize_offset_type_selftests): Likewise.
3643 * unittests/optional-selftests.c
3644 (_initialize_optional_selftests): Likewise.
3645 * unittests/scoped_restore-selftests.c
3646 (_initialize_scoped_restore_selftests): Likewise.
3647 * NEWS: Document "maintenance selftest" and "maint info
3650 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3652 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
3655 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3657 * mi/mi-main.c (mi_load_progress): Make uiout variable
3660 2017-09-15 Pedro Alves <palves@redhat.com>
3662 * compile/compile-c-types.c (convert_enum, convert_int)
3663 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
3665 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3667 * dwarf2read.c (copy_string): Remove.
3668 (parse_macro_definition): Replace copy_string with savestring.
3670 2017-09-15 Yao Qi <yao.qi@linaro.org>
3672 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
3674 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
3676 (i[34567]86-*-linux*): Likewise.
3678 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
3680 * dwarf2expr.h (dwarf_stack_value): Add constructor.
3681 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
3682 <stack>: Change type to std::vector.
3683 <stack_len, stack_allocated>: Remove.
3684 <grow_stack>: Remove.
3685 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
3686 (dwarf_expr_context::~dwarf_expr_context): Remove.
3687 (dwarf_expr_context::grow_stack): Remove.
3688 (dwarf_expr_context::push): Adjust.
3689 (dwarf_expr_context::pop): Adjust.
3690 (dwarf_expr_context::fetch): Adjust.
3691 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
3692 (dwarf_expr_context::stack_empty_p): Adjust.
3693 (dwarf_expr_context::execute_stack_op): Adjust.
3695 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
3697 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
3698 return type to bool.
3699 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
3701 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
3703 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
3704 Change type to bool.
3705 (dwarf_stack_value) <in_stack_memory>: Likewise.
3706 (dwarf_expr_context) <push_address>: Change parameter type to
3708 <fetch_in_stack_memory>: Change return type to bool.
3709 <push>: Change parameter type to bool.
3710 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
3712 (dwarf_expr_context::push_address): Likewise.
3713 (dwarf_expr_context::fetch_in_stack_memory): Change return type
3715 (dwarf_expr_context::execute_stack_op): Adjust.
3716 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
3718 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
3720 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
3721 (struct dwarf_expr_context) <n_pieces>: Remove.
3722 <pieces>: Change type to std::vector.
3723 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
3724 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
3726 (dwarf_expr_context::add_piece): Adjust.
3727 * dwarf2loc.c (struct piece_closure): Initialize fields.
3729 <pieces>: Change type to std::vector.
3730 (allocate_piece_closure): Adjust, change parameter to
3731 std::vector rvalue and std::move it to piece_closure.
3732 (rw_pieced_value): Adjust.
3733 (check_pieced_synthetic_pointer): Adjust.
3734 (indirect_synthetic_pointer): Adjust.
3735 (coerce_pieced_ref): Adjust.
3736 (free_pieced_value_closure): Adjust. Use delete to free
3738 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
3739 to allocate_piece_closure.
3740 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
3742 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
3744 * probe.h (probe_ops_cp): Remove typedef.
3745 (DEF_VEC_P (probe_ops_cp)): Remove.
3746 (all_probe_ops): Change type to std::vector.
3747 * probe.c (info_probes_for_ops): Adjust to vector change.
3748 (probe_linespec_to_ops): Likewise.
3749 (all_probe_ops): Change type to std::vector.
3750 (_initialize_probe): Adjust to vector change.
3751 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
3752 * elfread.c (elf_get_probes): Likewise.
3753 * stap-probe.c (_initialize_stap_probe): Likewise.
3755 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
3757 * probe.h (struct bound_probe): Define constructors.
3758 * probe.c (bound_probe_s): Remove typedef.
3759 (DEF_VEC_O (bound_probe_s)): Remove VEC.
3760 (collect_probes): Change return type to std::vector, remove
3762 (compare_probes): Return bool, change parameter type. Change
3763 semantic to "less than".
3764 (gen_ui_out_table_header_info): Change parameter to std::vector
3766 (exists_probe_with_pops): Likewise.
3767 (info_probes_for_ops): Update to std::vector change.
3768 (enable_probes_command): Likewise.
3769 (disable_probes_command): Likewise.
3771 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
3773 * probe.h (struct probe_ops) <get_probes>: Change parameter from
3775 * probe.c (parse_probes_in_pspace): Update.
3776 (find_probes_in_objfile): Update.
3777 (find_probe_by_pc): Update.
3778 (collect_probes): Update.
3779 (probe_any_get_probes): Update.
3780 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
3781 return type to reference to std::vector.
3782 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
3783 std::vector and update.
3784 (dtrace_process_dof): Likewise.
3785 (dtrace_get_probes): Likewise.
3786 * elfread.c (elf_get_probes): Change return type to std::vector,
3787 store an std::vector in bfd_data.
3788 (probe_key_free): Update to std::vector.
3789 * stap-probe.c (handle_stap_probe): Change parameter to
3790 std::vector and update.
3791 (stap_get_probes): Likewise.
3792 * symfile-debug.c (debug_sym_get_probes): Change return type to
3793 std::vector and update.
3795 2017-09-11 Tom Tromey <tom@tromey.com>
3797 * breakpoint.c (program_breakpoint_here_p): Update.
3798 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
3799 from make_show_memory_breakpoints_cleanup. Return a
3800 scoped_restore_tmpl<int>.
3801 (restore_show_memory_breakpoints): Remove.
3802 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
3803 * mem-break.c (memory_validate_breakpoint): Update.
3804 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
3805 (ia64_memory_remove_breakpoint): Update.
3806 (ia64_breakpoint_from_pc): Update.
3807 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
3808 from make_show_memory_breakpoints_cleanup.
3810 2017-09-11 Tom Tromey <tom@tromey.com>
3812 * d-namespace.c (d_lookup_symbol): Use std::string.
3813 (find_symbol_in_baseclass): Likewise.
3815 2017-09-11 Tom Tromey <tom@tromey.com>
3817 * ctf.c (ctf_start): Use std::string.
3819 2017-09-11 Tom Tromey <tom@tromey.com>
3821 * ada-lang.c (is_known_support_routine): Update.
3822 (ada_unhandled_exception_name_addr_from_raise): Update.
3823 * guile/scm-frame.c (gdbscm_frame_name): Update.
3824 * python/py-frame.c (frapy_name): Update.
3825 (frapy_function): Update.
3826 * stack.h (find_frame_funname): Update.
3827 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
3828 (print_frame): Update.
3830 2017-09-11 Tom Tromey <tom@tromey.com>
3832 * findcmd.c (put_bits): Take a gdb::byte_vector.
3833 (parse_find_args): Return gdb::byte_vector. "args" now const.
3834 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
3836 (find_command): Update.
3838 2017-09-11 Tom Tromey <tom@tromey.com>
3840 * cli/cli-script.c (class scoped_restore_hook_in): New.
3841 (clear_hook_in_cleanup): Remove.
3842 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
3843 scoped_restore_hook_in.
3845 2017-09-11 Tom Tromey <tom@tromey.com>
3847 * cli/cli-script.c (restore_interp): Remove.
3848 (read_command_lines): Use scoped_restore_interp.
3849 * interps.c (scoped_restore_interp::set_temp): Rename from
3851 * interps.h (class scoped_restore_interp): New.
3852 (interp_set_temp): Remove.
3854 2017-09-11 Tom Tromey <tom@tromey.com>
3856 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
3857 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
3858 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
3860 (mi_cmd_break_insert_1): Update.
3861 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
3864 2017-09-11 Tom Tromey <tom@tromey.com>
3866 * demangle.c (demangle_command): Update.
3867 * breakpoint.c (disable_command): Update.
3868 (enable_command): Update.
3869 (find_location_by_number): Make "number" const. Use
3871 * cli/cli-utils.c (extract_arg): Return std::string.
3872 * probe.c (parse_probe_linespec): Update. Change types.
3873 (collect_probes): Take string arguments.
3874 (parse_probe_linespec): Likewise.
3875 (info_probes_for_ops): Update.
3876 (enable_probes_command): Update.
3877 (disable_probes_command): Update.
3878 * break-catch-sig.c (catch_signal_split_args): Update.
3879 * mi/mi-parse.c (mi_parse): Update.
3881 2017-09-11 Tom Tromey <tom@tromey.com>
3883 * language.h (language_enum): Make argument const.
3884 * language.c (language_enum): Make argument const.
3886 2017-09-11 Tom Tromey <tom@tromey.com>
3888 * common/common-utils.h (skip_to_space): Remove macro, redeclare
3890 (skip_to_space): Rename from skip_to_space_const.
3891 * common/common-utils.c (skip_to_space): New function.
3892 (skip_to_space): Rename from skip_to_space_const.
3893 * cli/cli-utils.h (get_number): Rename from get_number_const.
3894 (extract_arg): Rename from extract_arg_const.
3895 * cli/cli-utils.c (get_number): Rename from get_number_const.
3896 (extract_arg): Rename from extract_arg_const.
3897 (number_or_range_parser::get_number): Use ::get_number.
3898 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
3899 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
3900 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
3901 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
3902 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
3903 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
3904 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
3905 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
3907 2017-09-11 Tom Tromey <tom@tromey.com>
3909 * python/python.c (do_start_initialization): Use
3910 py-event-types.def to initialize types.
3911 Define all object type structures.
3912 * python/python-internal.h: Don't declare event initialization
3914 * python/py-threadevent.c (thread_event_object_type): Don't
3916 * python/py-stopevent.c (stop_event_object_type): Don't define.
3917 * python/py-signalevent.c (signal_event_object_type): Don't
3919 * python/py-newobjfileevent.c (new_objfile_event_object_type)
3920 (clear_objfiles_event_object_type): Don't declare or define.
3921 * python/py-infevents.c (inferior_call_pre_event_object_type)
3922 (inferior_call_post_event_object_type)
3923 (register_changed_event_object_type)
3924 (memory_changed_event_object_type): Don't declare or define.
3925 * python/py-inferior.c (new_thread_event_object_type)
3926 (new_inferior_event_object_type)
3927 (inferior_deleted_event_object_type): Don't declare or define.
3928 * python/py-exitedevent.c (exited_event_object_type): Don't
3930 * python/py-evts.c (gdbpy_initialize_py_events): Use
3932 * python/py-events.h (thread_event_object_type): Don't declare.
3933 (events_object): Use py-all-events.def.
3934 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
3936 * python/py-event-types.def: New file.
3937 * python/py-continueevent.c (create_continue_event_object): Don't
3939 * python/py-bpevent.c (breakpoint_event_object_type): Don't
3941 * python/py-all-events.def: New file.
3943 2017-09-11 Tom Tromey <tom@tromey.com>
3945 * python/py-threadevent.c (create_thread_event_object): Return
3947 * python/py-stopevent.h (create_stop_event_object)
3948 (create_breakpoint_event_object, create_signal_event_object):
3950 * python/py-stopevent.c (create_stop_event_object): Return
3952 (emit_stop_event): Update.
3953 * python/py-signalevent.c (create_signal_event_object): Return
3955 * python/py-infevents.c (create_inferior_call_event_object):
3957 * python/py-event.h (create_event_object)
3958 (create_thread_event_object): Update.
3959 * python/py-event.c (create_event_object): Return gdbpy_ref.
3960 * python/py-continueevent.c: Return gdbpy_ref.
3961 * python/py-bpevent.c (create_breakpoint_event_object): Return
3964 2017-09-11 Tom Tromey <tom@tromey.com>
3968 * python/python.c (do_start_initialization): Initialize new event
3970 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
3971 (gdbpy_initialize_inferior_deleted_event)
3972 (gdbpy_initialize_new_thread_event): Declare.
3973 * python/py-threadevent.c (create_thread_event_object): Add option
3975 * python/py-inferior.c (new_thread_event_object_type)
3976 (new_inferior_event_object_type)
3977 (inferior_deleted_event_object_type): Declare.
3978 (python_new_inferior, python_inferior_deleted): New functions.
3979 (add_thread_object): Emit new_thread event.
3980 (gdbpy_initialize_inferior): Attach new functions to corresponding
3982 (new_thread, new_inferior, inferior_deleted): Define new event
3984 * python/py-evts.c (gdbpy_initialize_py_events): Add new
3986 * python/py-events.h (events_object) <new_inferior,
3987 inferior_deleted, new_thread>: New fields.
3988 * python/py-event.h (create_thread_event_breakpoint): Add optional
3991 2017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
3993 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
3994 check current_ui instead.
3995 (internal_vproblem): Likewise.
3997 2017-09-09 Simon Marchi <simon.marchi@ericsson.com>
3999 * thread.c (print_thread_info_1): Remove unnecessary calls to
4000 uiout->is_mi_like_p.
4002 2017-09-09 Tom Tromey <tom@tromey.com>
4004 * namespace.h (add_using_directive): Update.
4005 * namespace.c (add_using_directive): Change type of excludes to
4007 * dwarf2read.c (read_import_statement): Use std::vector.
4008 (read_namespace): Update.
4009 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
4011 2017-09-09 Tom Tromey <tom@tromey.com>
4013 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
4015 2017-09-09 Tom Tromey <tom@tromey.com>
4017 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
4019 2017-09-09 Tom Tromey <tom@tromey.com>
4021 * stack.c (func_command): Use gdb::def_vector.
4023 2017-09-09 Tom Tromey <tom@tromey.com>
4025 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
4026 ui_out_emit_list, ui_out_emit_tuple.
4027 (mi_cmd_var_update): Likewise.
4029 2017-09-09 Tom Tromey <tom@tromey.com>
4031 * mi/mi-interp.c (mi_user_selected_context_changed): Use
4032 ui_out_redirect_pop.
4033 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
4034 ui_out_redirect_pop.
4035 * utils.c (do_ui_out_redirect_pop)
4036 (make_cleanup_ui_out_redirect_pop): Remove.
4037 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
4038 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
4039 * ui-out.h (ui_out_redirect_pop): New class.
4041 2017-09-09 Tom Tromey <tom@tromey.com>
4043 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
4044 (list_available_thread_groups, mi_cmd_list_thread_groups)
4045 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
4046 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
4049 2017-09-09 Tom Tromey <tom@tromey.com>
4051 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
4054 2017-09-09 Tom Tromey <tom@tromey.com>
4056 * target.c (flash_erase_command): Use ui_out_emit_tuple.
4057 * stack.c (print_frame): Use ui_out_emit_tuple.
4058 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
4059 (info_spu_mailbox_command, info_spu_dma_command)
4060 (info_spu_proxydma_command): Likewise.
4061 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
4062 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
4063 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
4065 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
4067 2017-09-09 Tom Tromey <tom@tromey.com>
4069 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
4070 (class ui_out_emit_table): Update comment.
4071 * ui-out.c (do_cleanup_table_end)
4072 (make_cleanup_ui_out_table_begin_end): Remove.
4073 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
4074 (info_spu_dma_cmdlist): Likewise.
4075 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
4076 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
4079 2017-09-09 Tom Tromey <tom@tromey.com>
4081 * thread.c (print_thread_info_1): Use ui_out_emit_table,
4082 ui_out_emit_list, gdb::optional.
4084 2017-09-09 John Baldwin <jhb@FreeBSD.org>
4086 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
4088 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
4090 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
4092 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
4093 * ada-exp.y: Remove _initialize_ada_exp prototype.
4094 * ada-lang.c: Remove _initialize_ada_language prototype.
4095 * ada-tasks.c: Remove _initialize_tasks prototype.
4096 * addrmap.c: Remove _initialize_addrmap prototype.
4097 * agent.c: Remove _initialize_agent prototype.
4098 * aix-thread.c: Remove _initialize_aix_thread prototype.
4099 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
4100 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
4101 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
4103 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
4104 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
4105 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
4106 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
4108 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
4110 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
4111 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
4112 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
4113 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
4115 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
4116 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
4117 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
4118 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
4119 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
4120 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
4121 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
4123 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
4125 * annotate.c: Remove _initialize_annotate prototype.
4126 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
4127 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
4128 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
4129 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
4130 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
4131 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
4132 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
4133 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
4135 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
4136 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
4137 * auto-load.c: Remove _initialize_auto_load prototype.
4138 * auxv.c: Remove _initialize_auxv prototype.
4139 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
4140 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
4141 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
4142 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
4143 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
4144 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
4146 * break-catch-throw.c: Remove _initialize_break_catch_throw
4148 * breakpoint.c: Remove _initialize_breakpoint prototype.
4149 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
4150 * btrace.c: Remove _initialize_btrace prototype.
4151 * charset.c: Remove _initialize_charset prototype.
4152 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
4153 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
4154 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
4155 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
4156 * cli/cli-script.c: Remove _initialize_cli_script prototype.
4157 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
4158 * coffread.c: Remove _initialize_coffread prototype.
4159 * compile/compile.c: Remove _initialize_compile prototype.
4160 * complaints.c: Remove _initialize_complaints prototype.
4161 * completer.c: Remove _initialize_completer prototype.
4162 * copying.awk: Remove _initialize_copying prototype.
4163 * copying.c: Regenerate.
4164 * core-regset.c: Remove _initialize_core_regset prototype.
4165 * corefile.c: Remove _initialize_core prototype.
4166 * corelow.c: Remove _initialize_corelow prototype.
4167 * cp-abi.c: Remove _initialize_cp_abi prototype.
4168 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
4169 * cp-support.c: Remove _initialize_cp_support prototype.
4170 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
4171 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
4172 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
4173 * ctf.c: Remove _initialize_ctf prototype.
4174 * d-lang.c: Remove _initialize_d_language prototype.
4175 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
4177 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
4178 * dbxread.c: Remove _initialize_dbxread prototype.
4179 * dcache.c: Remove _initialize_dcache prototype.
4180 * demangle.c: Remove _initialize_demangler prototype.
4181 * disasm-selftests.c: Remove _initialize_disasm_selftests
4183 * disasm.c: Remove _initialize_disasm prototype.
4184 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
4185 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
4186 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
4188 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
4189 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
4190 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
4191 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
4192 * elfread.c: Remove _initialize_elfread prototype.
4193 * exec.c: Remove _initialize_exec prototype.
4194 * extension.c: Remove _initialize_extension prototype.
4195 * f-lang.c: Remove _initialize_f_language prototype.
4196 * f-valprint.c: Remove _initialize_f_valprint prototype.
4197 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
4198 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
4199 * filesystem.c: Remove _initialize_filesystem prototype.
4200 * findcmd.c: Remove _initialize_mem_search prototype.
4201 * fork-child.c: Remove _initialize_fork_child prototype.
4202 * frame-base.c: Remove _initialize_frame_base prototype.
4203 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
4204 * frame.c: Remove _initialize_frame prototype.
4205 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
4206 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
4207 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
4208 * gcore.c: Remove _initialize_gcore prototype.
4209 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
4210 * gdbarch.c: Regenerate.
4211 * gdbarch.sh: Remove _initialize_gdbarch prototype.
4212 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
4213 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
4214 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
4215 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
4216 * go-lang.c: Remove _initialize_go_language prototype.
4217 * go32-nat.c: Remove _initialize_go32_nat prototype.
4218 * guile/guile.c: Remove _initialize_guile prototype.
4219 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
4220 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
4221 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
4222 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
4223 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
4224 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
4225 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
4226 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
4227 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
4228 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
4230 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
4232 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
4233 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
4234 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
4235 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
4236 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
4237 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
4238 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
4239 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
4240 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
4241 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
4242 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
4243 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
4244 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
4245 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
4246 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
4247 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
4249 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
4251 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
4252 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
4253 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
4254 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
4255 * infcall.c: Remove _initialize_infcall prototype.
4256 * infcmd.c: Remove _initialize_infcmd prototype.
4257 * inferior.c: Remove _initialize_inferiors prototype.
4258 * inflow.c: Remove _initialize_inflow prototype.
4259 * infrun.c: Remove _initialize_infrun prototype.
4260 * interps.c: Remove _initialize_interpreter prototype.
4261 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
4262 * jit.c: Remove _initialize_jit prototype.
4263 * language.c: Remove _initialize_language prototype.
4264 * linux-fork.c: Remove _initialize_linux_fork prototype.
4265 * linux-nat.c: Remove _initialize_linux_nat prototype.
4266 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
4267 * linux-thread-db.c: Remove _initialize_thread_db prototype.
4268 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
4269 * m2-lang.c: Remove _initialize_m2_language prototype.
4270 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
4271 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
4272 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
4273 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
4274 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
4275 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
4276 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
4277 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
4278 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
4279 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
4280 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
4281 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
4282 * machoread.c: Remove _initialize_machoread prototype.
4283 * macrocmd.c: Remove _initialize_macrocmd prototype.
4284 * macroscope.c: Remove _initialize_macroscope prototype.
4285 * maint.c: Remove _initialize_maint_cmds prototype.
4286 * mdebugread.c: Remove _initialize_mdebugread prototype.
4287 * memattr.c: Remove _initialize_mem prototype.
4288 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
4289 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
4290 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
4291 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
4292 * mi/mi-main.c: Remove _initialize_mi_main prototype.
4293 * microblaze-linux-tdep.c: Remove
4294 _initialize_microblaze_linux_tdep prototype.
4295 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
4296 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
4297 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
4298 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
4299 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
4300 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
4301 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
4302 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
4303 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
4304 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
4305 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
4307 * mipsread.c: Remove _initialize_mipsread prototype.
4308 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
4310 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
4311 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
4312 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
4313 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
4314 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
4315 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
4317 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
4318 * nto-procfs.c: Remove _initialize_procfs prototype.
4319 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
4320 * objc-lang.c: Remove _initialize_objc_language prototype.
4321 * objfiles.c: Remove _initialize_objfiles prototype.
4322 * observer.c: Remove observer_test_first_notification_function,
4323 observer_test_second_notification_function,
4324 observer_test_third_notification_function, and
4325 _initialize_observer prototypes.
4326 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
4327 * osabi.c: Remove _initialize_gdb_osabi prototype.
4328 * osdata.c: Remove _initialize_osdata prototype.
4329 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
4330 * parse.c: Remove _initialize_parse prototype.
4331 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
4332 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
4333 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
4334 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
4335 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
4336 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
4337 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
4338 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
4339 * printcmd.c: Remove _initialize_printcmd prototype.
4340 * probe.c: Remove _initialize_probe prototype.
4341 * proc-api.c: Remove _initialize_proc_api prototype.
4342 * proc-events.c: Remove _initialize_proc_events prototype.
4343 * proc-service.c: Remove _initialize_proc_service prototype.
4344 * procfs.c: Remove _initialize_procfs prototype.
4345 * psymtab.c: Remove _initialize_psymtab prototype.
4346 * python/python.c: Remove _initialize_python prototype.
4347 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
4348 * record-btrace.c: Remove _initialize_record_btrace prototype.
4349 * record-full.c: Remove _initialize_record_full prototype.
4350 * record.c: Remove _initialize_record prototype.
4351 * regcache.c: Remove _initialize_regcache prototype.
4352 * reggroups.c: Remove _initialize_reggroup prototype.
4353 * remote-notif.c: Remove _initialize_notif prototype.
4354 * remote-sim.c: Remove _initialize_remote_sim prototype.
4355 * remote.c: Remove _initialize_remote prototype.
4356 * reverse.c: Remove _initialize_reverse prototype.
4357 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
4358 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
4359 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
4361 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
4362 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
4363 * rust-exp.y: Remove _initialize_rust_exp prototype.
4364 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
4365 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
4366 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
4367 * score-tdep.c: Remove _initialize_score_tdep prototype.
4368 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
4370 * ser-go32.c: Remove _initialize_ser_dos prototype.
4371 * ser-mingw.c: Remove _initialize_ser_windows prototype.
4372 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
4373 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
4374 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
4375 * serial.c: Remove _initialize_serial prototype.
4376 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
4377 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
4378 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
4379 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
4380 * skip.c: Remove _initialize_step_skip prototype.
4381 * sol-thread.c: Remove _initialize_sol_thread prototype.
4382 * solib-aix.c: Remove _initialize_solib_aix prototype.
4383 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
4384 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
4385 * solib-frv.c: Remove _initialize_frv_solib prototype.
4386 * solib-spu.c: Remove _initialize_spu_solib prototype.
4387 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
4388 * solib-target.c: Remove _initialize_solib_target prototype.
4389 * solib.c: Remove _initialize_solib prototype.
4390 * source.c: Remove _initialize_source prototype.
4391 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
4392 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
4394 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
4395 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
4396 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
4397 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
4399 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
4400 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
4401 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
4402 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
4404 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
4406 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
4408 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
4410 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
4411 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
4413 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
4415 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
4417 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
4419 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
4421 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
4422 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
4423 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
4424 * stabsread.c: Remove _initialize_stabsread prototype.
4425 * stack.c: Remove _initialize_stack prototype.
4426 * stap-probe.c: Remove _initialize_stap_probe prototype.
4427 * std-regs.c: Remove _initialize_frame_reg prototype.
4428 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
4429 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
4430 * symfile.c: Remove _initialize_symfile prototype.
4431 * symmisc.c: Remove _initialize_symmisc prototype.
4432 * symtab.c: Remove _initialize_symtab prototype.
4433 * target-dcache.c: Remove _initialize_target_dcache prototype.
4434 * target-descriptions.c: Remove _initialize_target_descriptions
4436 * thread.c: Remove _initialize_thread prototype.
4437 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
4439 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
4440 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
4441 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
4443 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
4444 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
4445 * tracefile.c: Remove _initialize_tracefile prototype.
4446 * tracepoint.c: Remove _initialize_tracepoint prototype.
4447 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
4448 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
4449 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
4450 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
4451 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
4452 * tui/tui-win.c: Remove _initialize_tui_win prototype.
4453 * tui/tui.c: Remove _initialize_tui prototype.
4454 * typeprint.c: Remove _initialize_typeprint prototype.
4455 * user-regs.c: Remove _initialize_user_regs prototype.
4456 * utils.c: Remove _initialize_utils prototype.
4457 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
4458 * valarith.c: Remove _initialize_valarith prototype.
4459 * valops.c: Remove _initialize_valops prototype.
4460 * valprint.c: Remove _initialize_valprint prototype.
4461 * value.c: Remove _initialize_values prototype.
4462 * varobj.c: Remove _initialize_varobj prototype.
4463 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
4464 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
4465 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
4466 * windows-nat.c: Remove _initialize_windows_nat,
4467 _initialize_check_for_gdb_ini, and _initialize_loadable
4469 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
4470 * xcoffread.c: Remove _initialize_xcoffread prototype.
4471 * xml-support.c: Remove _initialize_xml_support prototype.
4472 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
4473 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
4475 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
4477 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
4479 2017-09-08 Keith Seitz <keiths@redhat.com>
4481 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
4484 2017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
4486 * f-valprint.c (f_val_print): Remove check for one byte
4487 sized integers. Remove printing of character type.
4489 2017-09-08 Frank Penczek <frank.penczek@intel.com>
4490 Christoph Weinmann <christoph.t.weinmann@intel.com>
4491 Bernhard Heckel <bernhard.heckel@intel.com>
4493 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
4494 to maintain proper indentation when printing pointers/refs.
4496 2017-09-07 Joel Brobecker <brobecker@adacore.com>
4500 2017-09-07 Joel Brobecker <brobecker@adacore.com>
4502 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
4504 2017-09-05 Tom Tromey <tom@tromey.com>
4506 * parse.c (funcall_chain): Now a std::vector.
4507 (start_arglist, end_arglist): Simplify.
4508 (free_funcalls): Remove.
4509 (parse_exp_in_context_1): Remove cleanup.
4511 2017-09-05 Tom Tromey <tom@tromey.com>
4513 * go-exp.y (go_parse): Don't create a cleanup.
4515 2017-09-05 Tom Tromey <tom@tromey.com>
4517 * d-exp.y (PrimaryExpression): Use std::string.
4518 (d_parse): Don't create a cleanup.
4520 2017-09-05 Tom Tromey <tom@tromey.com>
4522 * utils.c (do_clear_parser_state): Remove.
4523 (make_cleanup_clear_parser_state): Remove.
4524 * p-exp.y (pascal_parse): Use scoped_restore.
4525 * m2-exp.y (m2_parse): Use scoped_restore.
4526 * f-exp.y (f_parse): Use scoped_restore.
4527 * d-exp.y (d_parse): Use scoped_restore.
4528 * c-exp.y (c_parse): Use scoped_restore.
4529 * ada-exp.y (ada_parse): Use scoped_restore.
4530 * utils.h (make_cleanup_clear_parser_state): Remove.
4532 2017-09-06 Keith Seitz <keiths@redhat.com>
4534 * dwarf2read.c (dw2_linkage_name_attr): New function.
4535 (dw2_linkage_name): New function.
4536 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
4537 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
4538 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
4540 2017-09-06 Kamil Rytarowski <n54@gmx.com>
4542 * config/djgpp/djconfig.sh: Correct shell portability issue.
4544 2017-09-06 Kamil Rytarowski <n54@gmx.com>
4546 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
4548 2017-09-06 John Baldwin <jhb@FreeBSD.org>
4550 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
4551 * NEWS: Mention new FreeBSD/mips native configuration.
4552 * configure.host: Add aarch64*-*-freebsd*.
4553 * configure.nat: Likewise.
4554 * aarch64-fbsd-nat.c: New file.
4556 2017-09-06 John Baldwin <jhb@FreeBSD.org>
4558 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
4559 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
4560 * NEWS: Mention new FreeBSD/aarch64 target.
4561 * configure.tgt: Add aarch64*-*-freebsd*.
4562 * aarch64-fbsd-tdep.c: New file.
4563 * aarch64-fbsd-tdep.h: New file.
4565 2017-09-06 Kamil Rytarowski <n54@gmx.com>
4567 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
4569 2017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
4571 * parse.c (find_minsym_type_and_address): Don't relocate addresses
4574 2017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4576 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
4579 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
4581 * infrun.c (follow_exec): Call add_thread after
4582 target_find_description.
4584 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
4586 * infrun.c (handle_inferior_event_1): When exec'ing, read
4587 stop_pc after follow_exec.
4589 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
4591 * remote.c (process_g_packet): Update error message.
4593 2017-09-05 Yao Qi <yao.qi@linaro.org>
4595 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
4598 2017-09-05 Pedro Alves <palves@redhat.com>
4600 * eval.c (eval_call, evaluate_funcall): New functions, factored
4602 (evaluate_subexp_standard): ... this.
4604 2017-09-05 Yao Qi <yao.qi@linaro.org>
4606 * amd64-tdep.c (amd64_target_description): Create target
4608 (_initialize_amd64_tdep): Don't call functions
4609 initialize_tdesc_amd64_*. Add self tests.
4610 * arch/amd64.c (amd64_create_target_description): Add parameter
4611 is_linux. Call set_tdesc_osabi if is_linux is true.
4612 * arch/amd64.h (amd64_create_target_description): Update the
4614 * arch/i386.c (i386_create_target_description): Add parameter
4615 is_linux. Call set_tdesc_osabi if is_linux is true.
4616 * arch/i386.h (i386_create_target_description): Update
4618 * configure.tgt: Add i386.o to gdb_target_obs.
4619 * features/Makefile (XMLTOC): Remove i386/*.xml.
4620 * features/i386/amd64-avx-avx512.c: Remove.
4621 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
4622 * features/i386/amd64-avx-mpx.c: Remove.
4623 * features/i386/amd64-avx.c: Remove.
4624 * features/i386/amd64-mpx.c: Remove.
4625 * features/i386/amd64.c: Remove.
4626 * features/i386/i386-avx-avx512.c: Remove.
4627 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
4628 * features/i386/i386-avx-mpx.c: Remove.
4629 * features/i386/i386-avx.c: Remove.
4630 * features/i386/i386-mmx.c: Remove.
4631 * features/i386/i386-mpx.c: Remove.
4632 * features/i386/i386.c: Remove.
4633 * i386-tdep.c: Don't include features/i386/i386*.c., include
4634 target-descriptions.h and arch/i386.h.
4635 (i386_target_description): Create target descriptions.
4636 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
4637 functions. Do self tests.
4639 2017-09-05 Yao Qi <yao.qi@linaro.org>
4641 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
4642 * features/i386/amd64-avx-avx512-linux.c: Removed.
4643 * features/i386/amd64-avx-linux.c: Removed.
4644 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
4645 * features/i386/amd64-avx-mpx-linux.c: Removed.
4646 * features/i386/amd64-linux.c: Removed.
4647 * features/i386/amd64-mpx-linux.c: Removed.
4648 * features/i386/x32-avx-avx512-linux.c: Removed.
4649 * features/i386/x32-avx-linux.c: Removed.
4650 * features/i386/x32-linux.c: Removed.
4652 2017-09-05 Yao Qi <yao.qi@linaro.org>
4654 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
4656 (amd64_linux_read_description): Call
4657 amd64_create_target_description.
4658 * arch/amd64.c: New file.
4659 * arch/amd64.h: New file.
4660 * configure.tgt (x86_64-*-linux*): Append amd64.o.
4661 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
4663 2017-09-05 Yao Qi <yao.qi@linaro.org>
4665 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
4666 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
4667 (amd64_linux_read_description): Create target descriptions.
4668 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
4669 functions. Add unit tests.
4670 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
4672 * features/i386/64bit-avx.c: Generated.
4673 * features/i386/64bit-avx512.c: Generated.
4674 * features/i386/64bit-core.c: Generated.
4675 * features/i386/64bit-linux.c: Generated.
4676 * features/i386/64bit-mpx.c: Generated.
4677 * features/i386/64bit-pkeys.c: Generated.
4678 * features/i386/64bit-segments.c: Generated.
4679 * features/i386/64bit-sse.c: Generated.
4680 * features/i386/x32-core.c: Generated.
4681 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
4682 c files for amd64-linux and x32-linux.
4684 2017-09-05 Yao Qi <yao.qi@linaro.org>
4686 * amd64-linux-tdep.c (amd64_linux_read_description): New
4688 (amd64_linux_core_read_description): Call
4689 amd64_linux_read_description.
4690 (amd64_linux_init_abi): Likewise.
4691 (amd64_x32_linux_init_abi): Likewise.
4692 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
4693 * x86-linux-nat.c (x86_linux_read_description): Call
4694 amd64_linux_read_description.
4696 2017-09-05 Yao Qi <yao.qi@linaro.org>
4698 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
4701 2017-09-05 Yao Qi <yao.qi@linaro.org>
4703 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
4704 * features/i386/i386-avx-avx512-linux.c: Remove.
4705 * features/i386/i386-avx-linux.c: Remove.
4706 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
4707 * features/i386/i386-avx-mpx-linux.c: Remove.
4708 * features/i386/i386-linux.c: Remove.
4709 * features/i386/i386-mmx-linux.c: Remove.
4710 * features/i386/i386-mpx-linux.c: Remove.
4712 2017-09-05 Yao Qi <yao.qi@linaro.org>
4714 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
4715 (SFILES): Add arch/i386.c.
4716 (HFILES_NO_SRCDIR): Add arch/i386.h.
4717 * arch/i386.c: New file.
4718 * arch/i386.h: New file.
4719 * arch/tdesc.h (allocate_target_description): Declare.
4720 (set_tdesc_architecture): Declare.
4721 (set_tdesc_osabi): Declare.
4722 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
4723 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
4724 include arch/i386.h.
4725 (i386_linux_read_description): Remove code and call
4726 i386_create_target_description.
4727 (set_tdesc_architecture): New function.
4728 (set_tdesc_osabi): New function.
4729 * target-descriptions.h (allocate_target_description): Remove.
4731 2017-09-05 Yao Qi <yao.qi@linaro.org>
4733 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
4734 * target-descriptions.c (tdesc_create_feature): Likewise, and
4736 * features/i386/32bit-avx.c: Re-generated.
4737 * features/i386/32bit-avx512.c: Re-generated.
4738 * features/i386/32bit-core.c: Re-generated.
4739 * features/i386/32bit-linux.c: Re-generated.
4740 * features/i386/32bit-mpx.c: Re-generated.
4741 * features/i386/32bit-pkeys.c: Re-generated.
4742 * features/i386/32bit-sse.c: Re-generated.
4744 2017-09-05 Yao Qi <yao.qi@linaro.org>
4746 * regformats/regdef.h (struct reg): Override operator == and !=.
4748 2017-09-05 Yao Qi <yao.qi@linaro.org>
4750 * arch/tdesc.h: New file.
4751 * regformats/regdat.sh: Generate code using tdesc_create_reg.
4752 * target-descriptions.c: Update comments.
4753 * target-descriptions.h: Include "arch/tdesc.h". Remove the
4755 * features/i386/32bit-avx.c: Re-generated.
4756 * features/i386/32bit-avx512.c: Re-generated.
4757 * features/i386/32bit-core.c: Re-generated.
4758 * features/i386/32bit-linux.c: Re-generated.
4759 * features/i386/32bit-mpx.c: Re-generated.
4760 * features/i386/32bit-pkeys.c: Re-generated.
4761 * features/i386/32bit-sse.c: Re-generated.
4763 2017-09-05 Yao Qi <yao.qi@linaro.org>
4765 * regformats/regdat.sh: Update generated code.
4767 2017-09-05 Yao Qi <yao.qi@linaro.org>
4769 * regformats/regdat.sh: Adjust code order.
4771 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
4773 * expprint.c (dump_subexp_body_standard): Use constant format
4774 string in fprintf_filtered call.
4776 2017-09-04 John Baldwin <jhb@FreeBSD.org>
4778 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
4780 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
4782 2017-09-04 John Baldwin <jhb@FreeBSD.org>
4784 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
4786 2017-09-04 John Baldwin <jhb@FreeBSD.org>
4788 * bsd-kvm.o: Define _KMEMUSER.
4789 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
4790 * configure: Regenerate.
4792 2017-09-04 John Baldwin <jhb@FreeBSD.org>
4794 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
4795 * i386-fbsd-nat.c: Likewise.
4797 2017-09-04 John Baldwin <jhb@FreeBSD.org>
4799 * unittests/array-view-selftests.c: Add include of <array>.
4801 2017-09-04 John Baldwin <jhb@FreeBSD.org>
4803 * spu-tdep.c (flush_ea_cache): Add missing argument to
4804 call_function_by_hand.
4806 2017-09-04 Pedro Alves <palves@redhat.com>
4808 * NEWS (Safer support for debugging with no debug info): New.
4810 2017-09-04 Pedro Alves <palves@redhat.com>
4812 * c-exp.y (function_method, function_method_void): Add current
4813 instance flags to TYPE_INSTANCE.
4814 * dwarf2read.c (check_modifier): New.
4815 (compute_delayed_physnames): Assert that only C++ adds delayed
4816 physnames. Mark fn_fields as const/volatile depending on
4818 * eval.c (make_params): New type_instance_flags parameter. Use
4819 it as the new type's instance flags.
4820 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
4821 flags element and pass it to make_params.
4822 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
4823 instance flags element.
4824 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
4825 * gdbtypes.h: Include "enum-flags.h".
4826 (type_instance_flags): New enum-flags type.
4827 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
4828 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
4829 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
4830 (follow_type_instance_flags): New function.
4831 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
4832 * parser-defs.h (follow_type_instance_flags): Declare.
4833 * valops.c (value_struct_elt_for_reference): const/volatile must
4836 2017-09-04 Pedro Alves <palves@redhat.com>
4838 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
4839 function/method scopes; lookup the nested name as a function local
4842 2017-09-04 Pedro Alves <palves@redhat.com>
4844 (%type <voidval>): Add function_method.
4845 * c-exp.y (exp): New production for calls with no arguments.
4846 (function_method, function_method_void_or_typelist): New
4848 (exp): New production for "method()::static_var".
4849 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
4850 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
4851 Handle OP_FUNC_STATIC_VAR.
4852 * parse.c (operator_length_standard):
4853 Handle OP_FUNC_STATIC_VAR.
4855 2017-09-04 Pedro Alves <palves@redhat.com>
4857 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
4859 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
4861 * parse.c (operator_length_standard, operator_check_standard):
4863 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
4865 2017-09-04 Pedro Alves <palves@redhat.com>
4867 * ax-gdb.c: Include "typeprint.h".
4868 (gen_expr_for_cast): New function.
4869 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
4870 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
4872 * dwarf2read.c (new_symbol_full): Fallback to int instead of
4873 nodebug_data_symbol.
4874 * eval.c: Include "typeprint.h".
4875 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
4876 Error out if symbol has unknown type.
4877 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
4878 evaluate_subexp_for_cast.
4879 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
4881 (evaluate_subexp_for_cast): New function.
4882 * gdbtypes.c (init_nodebug_var_type): New function.
4883 (objfile_type): Use it to initialize types of variables with no
4885 * typeprint.c (error_unknown_type): New.
4886 * typeprint.h (error_unknown_type): New declaration.
4887 * compile/compile-c-types.c (convert_type_basic): Handle
4888 TYPE_CODE_ERROR; warn and fallback to int for variables with
4891 2017-09-04 Pedro Alves <palves@redhat.com>
4893 * eval.c (evaluate_var_value): New function, factored out from ...
4894 (evaluate_subexp_standard): ... here.
4896 2017-09-04 Pedro Alves <palves@redhat.com>
4898 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
4899 Remove useless assignments to 'op'.
4901 2017-09-04 Pedro Alves <palves@redhat.com>
4903 * eval.c (eval_skip_value): New function.
4904 (evaluate_subexp_standard): Use it.
4906 2017-09-04 Pedro Alves <palves@redhat.com>
4908 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
4909 function name from symbol/minsym and pass it to
4910 error_call_unknown_return_type.
4912 2017-09-04 Pedro Alves <palves@redhat.com>
4914 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
4915 * ax-gdb.c (gen_msym_var_ref): New function.
4916 (gen_expr): Handle OP_VAR_MSYM_VALUE.
4917 * eval.c (evaluate_var_msym_value): New function.
4918 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
4919 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
4920 to call_function_by_hand.
4921 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
4922 Handle OP_VAR_MSYM_VALUE.
4923 (union exp_element) <msymbol>: New field.
4924 * minsyms.h (struct type): Forward declare.
4925 (find_minsym_type_and_address): Declare.
4926 * parse.c (write_exp_elt_msym): New function.
4927 (write_exp_msymbol): Delete, refactored as ...
4928 (find_minsym_type_and_address): ... this new function.
4929 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
4930 (operator_length_standard, operator_check_standard): Handle
4932 * std-operator.def (OP_VAR_MSYM_VALUE): New.
4934 2017-09-04 Pedro Alves <palves@redhat.com>
4936 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
4937 TYPE_GNU_IFUNC specially here. Throw error if return type is
4939 * ada-typeprint.c (print_func_type): Handle functions with unknown
4941 * c-typeprint.c (c_type_print_base): Handle functions and methods
4942 with unknown return type.
4943 * compile/compile-c-symbols.c (convert_symbol_bmsym)
4944 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
4945 * compile/compile-c-types.c: Include "objfiles.h".
4946 (convert_func): For functions with unknown return type, warn and
4948 * compile/compile-object-run.c (compile_object_run): Adjust call
4949 to call_function_by_hand_dummy.
4950 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
4951 call_function_by_hand.
4952 * eval.c (evaluate_subexp_standard): Adjust calls to
4953 call_function_by_hand. Handle functions and methods with unknown
4954 return type. Pass expect_type to call_function_by_hand.
4955 * f-typeprint.c (f_type_print_base): Handle functions with unknown
4957 * gcore.c (call_target_sbrk): Adjust call to
4958 call_function_by_hand.
4959 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
4960 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
4961 an integer address type instead of nodebug.
4962 * guile/scm-value.c (gdbscm_value_call): Adjust call to
4963 call_function_by_hand.
4964 * infcall.c (error_call_unknown_return_type): New function.
4965 (call_function_by_hand): New "default_return_type" parameter.
4967 (call_function_by_hand_dummy): New "default_return_type"
4968 parameter. Use it instead of defaulting to int. If there's no
4969 default and the return type is unknown, throw an error. If
4970 there's a default return type, and the called function has no
4971 debug info, then assume the function is prototyped.
4972 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
4973 New "default_return_type" parameter.
4974 (error_call_unknown_return_type): New declaration.
4975 * linux-fork.c (call_lseek): Cast return type of lseek.
4976 (inferior_call_waitpid, checkpoint_command): Adjust calls to
4977 call_function_by_hand.
4978 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
4979 calls to call_function_by_hand.
4980 * m2-typeprint.c (m2_procedure): Handle functions with unknown
4982 * objc-lang.c (lookup_objc_class, lookup_child_selector)
4983 (value_nsstring, print_object_command): Adjust calls to
4984 call_function_by_hand.
4985 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
4986 functions with unknown return type.
4987 (pascal_type_print_func_varspec_suffix): New function.
4988 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
4989 TYPE_CODE_METHOD>: Use it.
4990 * python/py-value.c (valpy_call): Adjust call to
4991 call_function_by_hand.
4992 * rust-lang.c (rust_evaluate_funcall): Adjust call to
4993 call_function_by_hand.
4994 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
4995 call_function_by_hand.
4996 * valops.c (value_allocate_space_in_inferior): Adjust call to
4997 call_function_by_hand.
4998 * typeprint.c (type_print_unknown_return_type): New function.
4999 * typeprint.h (type_print_unknown_return_type): New declaration.
5001 2017-09-04 Pedro Alves <palves@redhat.com>
5003 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
5004 types with more than one parameter as prototyped.
5006 2017-09-04 Pedro Alves <palves@redhat.com>
5008 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
5009 (disassemble_command): Use gdb_disassembly_flags instead of bare
5011 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
5012 (dump_insns, do_mixed_source_and_assembly_deprecated)
5013 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
5014 Use gdb_disassembly_flags instead of bare int.
5015 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
5016 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
5017 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
5018 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
5019 (enum gdb_disassembly_flag): ... values of this new enumeration.
5020 (gdb_disassembly_flags): Define.
5022 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
5023 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
5024 gdb_disassembly_flags instead of bare int.
5025 * record-btrace.c (btrace_insn_history)
5026 (record_btrace_insn_history, record_btrace_insn_history_range)
5027 (record_btrace_insn_history_from): Use gdb_disassembly_flags
5028 instead of bare int.
5029 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
5030 Use gdb_disassembly_flags instead of bare int.
5031 * target-debug.h (target_debug_print_gdb_disassembly_flags):
5033 * target-delegates.c: Regenerate.
5034 * target.c (target_insn_history, target_insn_history_from)
5035 (target_insn_history_range): Use gdb_disassembly_flags instead of
5037 * target.h: Include "disasm.h".
5038 (struct target_ops) <to_insn_history, to_insn_history_from,
5039 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
5041 (target_insn_history, target_insn_history_from)
5042 (target_insn_history_range): Use gdb_disassembly_flags instead of
5045 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
5047 * cli/cli-script.c (build_command_line): For if/while commands,
5048 check whether args is empty.
5050 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
5052 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
5053 (enum command_control_type): Likewise.
5054 (struct command_line): Likewise.
5055 (free_command_lines): Likewise.
5056 (struct command_lines_deleter): Likewise.
5057 (command_line_up): Likewise.
5058 (read_command_lines): Likewise.
5059 (read_command_lines_1): Likewise.
5060 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
5061 (enum command_control_type): Likewise.
5062 (struct command_line): Likewise.
5063 (free_command_lines): Likewise.
5064 (struct command_lines_deleter): Likewise.
5065 (command_line_up): Likewise.
5066 (read_command_lines): Likewise.
5067 (read_command_lines_1): Likewise.
5068 * breakpoint.h: Include cli/cli-script.h.
5069 * extension-priv.h: Likewise.
5070 * gdbcmd.h: Likewise.
5072 2017-09-04 Pedro Alves <palves@redhat.com>
5074 * ada-lang.c (is_known_support_routine): Move sal declaration to
5075 where it is initialized.
5076 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
5077 (parse_breakpoint_sals, decode_static_tracepoint_spec)
5078 (clear_command, update_static_tracepoint): Remove init_sal
5079 references. Move declarations closer to initializations.
5080 * cli/cli-cmds.c (list_command): Move sal declarations closer to
5082 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
5083 references. Move sal declarations closer to initializations.
5084 * frame.c (find_frame_sal): Return a symtab_and_line via function
5085 return instead of output parameter. Remove init_sal references.
5086 * frame.h (find_frame_sal): Return a symtab_and_line via function
5087 return instead of output parameter.
5088 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
5089 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
5091 (gdbscm_find_pc_line): Remove init_sal reference.
5092 * infcall.c (call_function_by_hand_dummy): Remove init_sal
5093 references. Move declarations closer to initializations.
5094 * infcmd.c (set_step_frame): Update. Move declarations closer to
5096 (finish_backward): Remove init_sal references. Move declarations
5097 closer to initializations.
5098 * infrun.c (process_event_stop_test, handle_step_into_function)
5099 (insert_hp_step_resume_breakpoint_at_frame)
5100 (insert_step_resume_breakpoint_at_caller): Likewise.
5101 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
5102 (symbol_to_sal): Likewise.
5103 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
5104 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
5105 to its initialization.
5106 * reverse.c (save_bookmark_command): Use new/delete. Remove
5107 init_sal references. Move declarations closer to initializations.
5108 * source.c (get_current_source_symtab_and_line): Remove brace
5110 (set_current_source_symtab_and_line): Now takes the sal by const
5111 reference. Remove brace initialization.
5112 (line_info): Remove init_sal reference.
5113 * source.h (set_current_source_symtab_and_line): Now takes a
5114 symtab_and_line via const reference.
5115 * stack.c (set_current_sal_from_frame): Adjust.
5116 (print_frame_info): Adjust.
5117 (get_last_displayed_sal): Return the sal via function return
5118 instead of via output parameter. Simplify.
5119 (frame_info): Adjust.
5120 * stack.h (get_last_displayed_sal): Return the sal via function
5121 return instead of via output parameter.
5122 * symtab.c (init_sal): Delete.
5123 (find_pc_sect_line): Remove init_sal references. Move
5124 declarations closer to initializations.
5125 (find_function_start_sal): Remove init_sal references. Move
5126 declarations closer to initializations.
5127 * symtab.h (struct symtab_and_line): In-class initialize all
5129 * tracepoint.c (set_traceframe_context)
5130 (print_one_static_tracepoint_marker): Remove init_sal references.
5131 Move declarations closer to initializations.
5132 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
5133 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
5134 declarations closer to initializations.
5135 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
5136 init_sal references. Adjust.
5138 2017-09-04 Pedro Alves <palves@redhat.com>
5140 * ax-gdb.c (agent_command_1): Use range-for.
5141 * break-catch-throw.c (re_set_exception_catchpoint): Update.
5142 * breakpoint.c: Include "common/array-view.h".
5143 (init_breakpoint_sal, create_breakpoint_sal): Change sals
5144 parameter from struct symtabs_and_lines to
5145 array_view<symtab_and_line>. Adjust. Use range-for. Update.
5146 (breakpoint_sals_to_pc): Change sals parameter from struct
5147 symtabs_and_lines to std::vector reference.
5148 (check_fast_tracepoint_sals): Change sals parameter from struct
5149 symtabs_and_lines to std::array_view. Use range-for.
5150 (decode_static_tracepoint_spec): Return a std::vector instead of
5151 symtabs_and_lines. Update.
5152 (create_breakpoint): Update.
5153 (break_range_command, until_break_command, clear_command): Update.
5154 (base_breakpoint_decode_location, bkpt_decode_location)
5155 (bkpt_probe_create_sals_from_location)
5156 (bkpt_probe_decode_location, tracepoint_decode_location)
5157 (tracepoint_probe_decode_location)
5158 (strace_marker_create_sals_from_location): Return a std::vector
5159 instead of symtabs_and_lines.
5160 (strace_marker_create_breakpoints_sal): Update.
5161 (strace_marker_decode_location): Return a std::vector instead of
5162 symtabs_and_lines. Update.
5163 (update_breakpoint_locations): Change struct symtabs_and_lines
5164 parameters to gdb::array_view. Adjust.
5165 (location_to_sals): Return a std::vector instead of
5166 symtabs_and_lines. Update.
5167 (breakpoint_re_set_default): Use std::vector instead of struct
5169 (decode_location_default): Return a std::vector instead of
5170 symtabs_and_lines. Update.
5171 * breakpoint.h: Include "common/array-view.h".
5172 (struct breakpoint_ops) <decode_location>: Now returns a
5173 std::vector instead of returning a symtabs_and_lines via output
5175 (update_breakpoint_locations): Change sals parameters to use
5177 * cli/cli-cmds.c (edit_command, list_command): Update to use
5178 std::vector and gdb::array_view.
5179 (ambiguous_line_spec): Adjust to use gdb::array_view and
5181 (compare_symtabs): Rename to ...
5182 (cmp_symtabs): ... this. Change parameters to symtab_and_line
5183 const reference and adjust.
5184 (filter_sals): Rewrite using std::vector and standard algorithms.
5185 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
5186 (jump_command): Update to use std::vector.
5187 * linespec.c (struct linespec_state) <canonical_names>: Update
5189 (add_sal_to_sals_basic): Delete.
5190 (add_sal_to_sals, filter_results, convert_results_to_lsals)
5191 (decode_line_2, create_sals_line_offset)
5192 (convert_address_location_to_sals, convert_linespec_to_sals)
5193 (convert_explicit_location_to_sals, parse_linespec)
5194 (event_location_to_sals, decode_line_full, decode_line_1)
5195 (decode_line_with_current_source)
5196 (decode_line_with_last_displayed, decode_objc)
5197 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
5198 (linespec_result::~linespec_result): Adjust to use std::vector
5199 instead of symtabs_and_lines.
5200 * linespec.h (linespec_sals::sals): Now a std::vector.
5201 (struct linespec_result): Use std::vector, bool, and in-class
5203 (decode_line_1, decode_line_with_current_source)
5204 (decode_line_with_last_displayed): Return std::vector.
5205 * macrocmd.c (info_macros_command): Use std::vector.
5206 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
5207 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
5209 * probe.h (parse_probes): Return a std::vector.
5210 * python/python.c (gdbpy_decode_line): Use std::vector and
5212 * source.c (select_source_symtab, line_info): Use std::vector.
5213 * stack.c (func_command): Use std::vector.
5214 * symtab.h (struct symtabs_and_lines): Delete.
5215 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
5217 2017-09-04 Pedro Alves <palves@redhat.com>
5219 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5220 unittests/array-view-selftests.c.
5221 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
5222 * common/array-view.h: New file.
5223 * unittests/array-view-selftests.c: New file.
5225 2017-09-04 Pedro Alves <palves@redhat.com>
5227 * cli/cli-cmds.c (edit_command): Pass message to
5228 ambiguous_line_spec.
5229 (list_command): Pass message to ambiguous_line_spec. Say
5230 "first"/"last" instead of "start" and "end" to be consistent with
5232 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
5233 them to print formatted message.
5235 2017-09-04 Pedro Alves <palves@redhat.com>
5237 * btrace.c (ftrace_add_pt): Pass btrace_insn to
5238 ftrace_update_insns by reference instead of pointer.
5240 2017-09-04 Yao Qi <yao.qi@linaro.org>
5242 * i386-go32-tdep.c: Include x86-xstate.h.
5243 (i386_go32_init_abi): Call i386_target_description.
5244 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
5245 if xcr0 is X86_XSTATE_X87_MASK.
5246 * i386-tdep.h (tdesc_i386): Remove the declaration.
5247 (tdesc_i386_mmx): Likewise.
5249 2017-09-04 Yao Qi <yao.qi@linaro.org>
5251 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
5252 X86_XSTATE_SSE_MASK instead of 0.
5254 2017-09-04 Yao Qi <yao.qi@linaro.org>
5256 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
5257 i386_target_description.
5258 * i386-fbsd-nat.c (i386fbsd_read_description): Call
5259 i386_target_description.
5260 * i386-tdep.c (i386_gdbarch_init): Likewise.
5262 2017-09-04 Yao Qi <yao.qi@linaro.org>
5264 * amd64-darwin-tdep.c: Include "x86-xstate.h".
5265 (x86_darwin_init_abi_64): Call amd64_target_description.
5266 * amd64-dicos-tdep.c: Likewise.
5267 * amd64-fbsd-nat.c: Likewise.
5268 * amd64-fbsd-tdep.c: Likewise.
5269 * amd64-nbsd-tdep.c: Likewise.
5270 * amd64-obsd-tdep.c: Likewise.
5271 * amd64-sol2-tdep.c: Likewise.
5272 * amd64-windows-tdep.c: Likewise.
5273 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
5275 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
5277 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
5278 (btrace_function) <insn>: Change type to use std::vector.
5279 * btrace.c (ftrace_debug, ftrace_call_num_insn,
5280 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
5281 ftrace_update_insns, ftrace_compute_global_level_offset,
5282 btrace_stitch_bts, btrace_clear, btrace_insn_get,
5283 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
5284 change to std::vector.
5285 (ftrace_update_insns): Adjust to change to std::vector, change
5286 type of INSN parameter.
5287 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
5288 * record-btrace.c (btrace_call_history_insn_range,
5289 btrace_compute_src_line_range,
5290 record_btrace_frame_prev_register): Adjust to change to
5292 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
5293 to change to std::vector.
5295 2017-09-03 Tom Tromey <tom@tromey.com>
5297 * corefile.c (reopen_exec_file): Use std::string.
5299 2017-09-03 Tom Tromey <tom@tromey.com>
5301 * compile/compile.c (compile_register_name_mangled): Return
5303 * compile/compile-loc2c.c (pushf_register_address): Update.
5304 (pushf_register): Update.
5305 * compile/compile-c-types.c (convert_array): Update.
5306 * compile/compile-c-symbols.c (generate_vla_size): Update.
5307 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
5308 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
5309 (convert_one_symbol): Update.
5310 (generate_c_for_for_one_variable): Update.
5311 * compile/compile-c-support.c (c_get_range_decl_name): Return a
5313 (generate_register_struct): Update.
5314 * compile/compile-internal.h (c_get_range_decl_name): Return a
5316 (compile_register_name_mangled): Return std::string.
5318 2017-09-03 Tom Tromey <tom@tromey.com>
5320 * utils.c (perror_string): Return a std::string.
5321 (throw_perror_with_name, perror_warning_with_name): Update.
5323 2017-09-03 Tom Tromey <tom@tromey.com>
5325 * demangle.c (demangle_command): Use std::string,
5328 2017-09-03 Tom Tromey <tom@tromey.com>
5330 * cli/cli-setshow.c (do_set_command): Use std::string.
5332 2017-09-03 Tom Tromey <tom@tromey.com>
5334 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
5336 2017-09-03 Tom Tromey <tom@tromey.com>
5338 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
5340 2017-09-03 Tom Tromey <tom@tromey.com>
5342 * mi/mi-cmd-env.c (env_execute_cli_command): Use
5343 gdb::unique_xmalloc_ptr.
5345 2017-09-03 Tom Tromey <tom@tromey.com>
5347 * thread.c (print_thread_info_1): Use string_printf.
5348 (thread_apply_command, thread_apply_all_command): Use
5351 2017-09-03 Tom Tromey <tom@tromey.com>
5353 * valprint.c (val_print_string): Update.
5354 * gdbcore.h (memory_error_message): Return std::string.
5355 * corefile.c (memory_error_message): Return std::string.
5356 (memory_error): Update.
5357 * breakpoint.c (insert_bp_location): Update.
5359 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
5361 * target/waitstatus.h (target_waitstatus_to_string): Change
5362 return type to std::string.
5363 * target/waitstatus.c (target_waitstatus_to_string): Return
5365 * target.h (target_waitstatus_to_string): Remove declaration.
5366 * infrun.c (resume, clear_proceed_status_thread,
5367 print_target_wait_results, do_target_wait, save_waitstatus,
5368 stop_all_threads): Adjust.
5369 * record-btrace.c (record_btrace_wait): Adjust.
5371 (target_debug_print_struct_target_waitstatus_p): Adjust.
5373 2017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
5376 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
5379 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
5381 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
5382 for setting/unsetting environment variables on the remote target.
5383 (New remote packets): Add entries for QEnvironmentHexEncoded,
5384 QEnvironmentUnset and QEnvironmentReset.
5385 * common/environ.c (gdb_environ::operator=): Extend method to
5386 handle m_user_set_env_list and m_user_unset_env_list.
5387 (gdb_environ::clear): Likewise.
5388 (match_var_in_string): Change type of first parameter from 'char
5389 *' to 'const char *'.
5390 (gdb_environ::set): Extend method to handle
5391 m_user_set_env_list and m_user_unset_env_list.
5392 (gdb_environ::unset): Likewise.
5393 (gdb_environ::clear_user_set_env): New method.
5394 (gdb_environ::user_set_envp): Likewise.
5395 (gdb_environ::user_unset_envp): Likewise.
5396 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
5397 m_user_unset_env_list on move constructor/assignment.
5398 (unset): Add new default parameter 'update_unset_list = true'.
5399 (clear_user_set_env): New method.
5400 (user_set_envp): Likewise.
5401 (user_unset_envp): Likewise.
5402 (m_user_set_env_list): New std::set.
5403 (m_user_unset_env_list): Likewise.
5404 * common/rsp-low.c (hex2str): New function.
5405 (bin2hex): New overload for bin2hex function.
5406 * common/rsp-low.c (hex2str): New prototype.
5407 (str2hex): New overload prototype.
5408 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
5409 QEnvironmentUnset and QEnvironmentReset.
5410 (remote_protocol_features): Add QEnvironmentHexEncoded,
5411 QEnvironmentUnset and QEnvironmentReset packets.
5412 (send_environment_packet): New function.
5413 (extended_remote_environment_support): Likewise.
5414 (extended_remote_create_inferior): Call
5415 extended_remote_environment_support.
5416 (_initialize_remote): Add QEnvironmentHexEncoded,
5417 QEnvironmentUnset and QEnvironmentReset packet configs.
5418 * unittests/environ-selftests.c (gdb_selftest_env_var):
5420 (test_vector_initialization): New function.
5421 (test_init_from_host_environ): Likewise.
5422 (test_reinit_from_host_environ): Likewise.
5423 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
5425 (test_unset_set_empty_vector): Likewise.
5426 (test_vector_clear): Likewise.
5427 (test_std_move): Likewise.
5428 (test_move_constructor):
5429 (test_self_move): Likewise.
5430 (test_set_unset_reset): Likewise.
5431 (run_tests): Rewrite in terms of the functions above.
5433 2017-08-31 Weimin Pan <weimin.pan@oracle.com>
5435 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
5436 (adi_available): Use a temp variable of type CORE_ADDR as argument
5437 3 when calling target_auxv_search.
5438 (adi_normalize_address): Use masks and xor operators to calculate
5440 (adi_read_versions, adi_write_versions, adi_print_versions)
5441 (do_examine, do_assign): Use paddress.
5443 2017-08-29 John Baldwin <jhb@FreeBSD.org>
5445 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
5446 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
5447 out of loop and add supply of FIR.
5448 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
5451 2017-08-28 Simon Marchi <simon.marchi@ericsson.com>
5454 * cli/cli-script.c (define_command): Don't convert command name
5457 2017-08-25 Joel Brobecker <brobecker@adacore.com>
5459 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
5460 Update all callers accordingly. Remove all code blocks handling
5461 the case where DISPP is not NULL.
5463 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
5466 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
5467 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
5468 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
5470 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
5472 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
5473 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
5474 (read_comp_units_from_section): New parameter abbrev_section, use
5475 read_and_check_comp_unit_head, allocate signatured_type if needed.
5476 (create_all_comp_units): Update read_comp_units_from_section caller.
5478 2017-08-23 Pedro Alves <palves@redhat.com>
5481 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
5482 to null_ptid and switch to thread without reading the registers
5483 after adding the inferior.
5485 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
5487 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
5489 * compile/compile.c (compile_gcc, show_compile_gcc): New.
5490 (compile_to_object): Implement compile_gcc.
5491 (_initialize_compile): Install "set compile-gcc". Initialize
5494 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
5496 * compile/compile.c (compile_to_object): Conditionally call
5497 set_verbose. Conditionally call compile or compile_v0.
5499 2017-08-07 Weimin Pan <weimin.pan@oracle.com>
5501 * sparc64-tdep.h: (adi_normalize_address): New export.
5502 * sparc-nat.h: (open_adi_tag_fd): New export.
5503 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
5504 * sparc64-linux-tdep.c:
5505 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
5506 (sparc64_linux_handle_segmentation_fault): New function.
5507 (sparc64_linux_init_abi): Register
5508 sparc64_linux_handle_segmentation_fault
5509 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
5510 (sparc64_addr_bits_remove): New function.
5511 (sparc64_init_abi): Register sparc64_addr_bits_remove.
5512 (MAX_PROC_NAME_SIZE): New macro.
5513 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
5514 (sparc64adilist): New variable.
5515 (adi_proc_list): New variable.
5516 (find_adi_info): New function.
5517 (add_adi_info): New function.
5518 (get_adi_info_proc): New function.
5519 (get_adi_info): New function.
5520 (info_adi_command): New function.
5521 (read_maps_entry): New function.
5522 (adi_available): New function.
5523 (adi_normalize_address): New function.
5524 (adi_align_address): New function.
5525 (adi_convert_byte_count): New function.
5526 (adi_tag_fd): New function.
5527 (adi_is_addr_mapped): New function.
5528 (adi_read_versions): New function.
5529 (adi_write_versions): New function.
5530 (adi_print_versions): New function.
5531 (do_examine): New function.
5532 (do_assign): New function.
5533 (adi_examine_command): New function.
5534 (adi_assign_command): New function.
5535 (_initialize_sparc64_adi_tdep): New function.
5537 2017-08-22 Simon Marchi <simon.marchi@ericsson.com>
5539 * breakpoint.c (breakpoints_info): Rename to ...
5540 (info_breakpoints_command): ... this.
5541 (watchpoints_info): Rename to ...
5542 (info_watchpoints_command): ... this.
5543 (tracepoints_info): Rename to ...
5544 (info_tracepoints_command): ... this.
5545 (_initialize_breakpoint): Adjust.
5546 * dcache.c (dcache_info): Rename to ...
5547 (info_display_command): ... this.
5548 (_initialize_dcache): Adjust.
5549 * frame.h (args_info): Rename to ...
5550 (info_args_command): ... this.
5551 (locals_info): Rename to ...
5552 (info_locals_command): ... this.
5553 * infcmd.c (nofp_registers_info): Rename to ...
5554 (info_registers_command): ... this.
5555 (float_info): Rename to ...
5556 (info_float_command): ... this.
5557 (program_info): Rename to ...
5558 (info_program_command): ... this.
5559 (all_registers_info): Rename to ...
5560 (info_all_registers_command): ... this.
5561 (vector_info): Rename to ...
5562 (info_vector_command): ... this.
5563 (float_info): Rename to ...
5564 (info_float_command): ... this.
5565 (_initialize_infcmd): Adjust.
5566 * inferior.h (term_info): Rename to ...
5567 (info_terminal_command): ... this.
5568 * inflow.c (term_info): Rename to ...
5569 (info_terminal_command): ... this.
5570 (_initialize_inflow): Adjust.
5571 * infrun.c (signals_info): Rename to ...
5572 (info_signals_command): ... this.
5573 (_initialize_infrun): Adjust.
5574 * objc-lang.c (classes_info): Rename to ...
5575 (info_classes_command): ... this.
5576 (selectors_info): Rename to ...
5577 (info_selectors_command): ... this.
5578 (_initialize_objc_language): Adjust.
5579 * printcmd.c (sym_info): Rename to ...
5580 (info_symbol_command): ... this.
5581 (address_info): Rename to ...
5582 (info_address_command): ... this.
5583 (display_info): Rename to ...
5584 (info_display_command): ... this.
5585 (_initialize_printcmd): Adjust.
5586 * reverse.c (bookmarks_info): Rename to ...
5587 (info_breakpoints_command): ... this.
5588 (_initialize_reverse): Adjust.
5589 * ser-go32.c (dos_info): Rename to ...
5590 (info_serial_command): ... this.
5591 (_initialize_ser_dos): Adjust.
5592 * skip.c (skip_info): Rename to ...
5593 (info_skip_command): ... this.
5594 (_initialize_step_skip): Adjust.
5595 * source.c (line_info): Rename to ...
5596 (info_line_command): ... this.
5597 (source_info): Rename to ...
5598 (info_source_command)
5599 * stack.c (frame_info): Rename to ...
5600 (info_frame_command): ... this.
5601 (locals_info): Rename to ...
5602 (info_locals_command): ... this.
5603 (args_info): Rename to ...
5604 (info_args_command): ... this.
5605 (_initialize_stack): Adjust.
5606 * symtab.c (sources_info): Rename to ...
5607 (info_sources_command): ... this.
5608 (variables_info): Rename to ...
5609 (info_variables_command): ... this.
5610 (functions_info): Rename to ...
5611 (info_functions_command): ... this.
5612 (types_info): Rename to ...
5613 (info_types_command): ... this.
5614 (_initialize_symtab): Adjust.
5615 * target.c (target_info): Rename to ...
5616 (info_target_command): ... this.
5617 (initialize_targets): Adjust.
5618 * tracepoint.c (tvariables_info): Rename to ...
5619 (info_tvariables_command): ... this.
5620 (scope_info): Rename to ...
5621 (info_scope_command): ... this.
5622 (trace_dump_actions): Adjust.
5623 (_initialize_tracepoint): Adjust.
5625 2017-08-22 Tom Tromey <tom@tromey.com>
5627 * breakpoint.h (install_breakpoint): Update.
5628 * breakpoint.c (add_solib_catchpoint): Update.
5629 (install_breakpoint): Change argument to a std::unique_ptr.
5630 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
5631 (create_breakpoint_sal, create_breakpoint): Update.
5632 (watch_command_1, catch_exec_command_1)
5633 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
5634 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
5635 Return the breakpoint.
5636 (set_raw_breakpoint_without_location, set_raw_breakpoint)
5637 (new_single_step_breakpoint): Update.
5638 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
5640 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
5642 * break-catch-sig.c (create_signal_catchpoint): Use
5644 * ada-lang.c (create_ada_exception_catchpoint): Use
5647 2017-08-22 Tom Tromey <tom@tromey.com>
5649 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
5651 2017-08-22 Tom Tromey <tom@tromey.com>
5653 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
5654 (lookup_partial_symbol): Update.
5656 2017-08-22 Tom Tromey <tom@tromey.com>
5658 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
5659 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
5660 (find_and_open_source, symtab_to_fullname): Update.
5661 * psymtab.c (psymtab_to_fullname): Update.
5663 2017-08-22 Tom Tromey <tom@tromey.com>
5665 * exec.c (exec_file_attach): Update.
5666 * linux-thread-db.c (try_thread_db_load): Update.
5667 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
5668 * utils.c (gdb_realpath): Change return type.
5669 (gdb_realpath_keepfile): Update.
5670 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
5671 (_initialize_utils): Register the new self test.
5672 * source.c (openp): Update.
5673 (find_and_open_source): Update.
5674 * nto-tdep.c (nto_find_and_open_solib): Update.
5675 * main.c (set_gdb_data_directory): Update.
5676 (captured_main_1): Update.
5677 * dwarf2read.c (dwarf2_get_dwz_file): Update
5678 (dw2_map_symbol_filenames): Update.
5679 * auto-load.c (auto_load_safe_path_vec_update): Update.
5680 (filename_is_in_auto_load_safe_path_vec): Change type of
5682 (auto_load_objfile_script): Update.
5683 (file_is_auto_load_safe): Update. Use std::string.
5684 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
5686 2017-08-22 Tom Tromey <tom@tromey.com>
5688 * utils.c (gdb_realpath_keepfile): Return a
5689 gdb::unique_xmalloc_ptr.
5690 * exec.c (exec_file_attach): Update.
5691 * utils.h (gdb_realpath_keepfile): Return a
5692 gdb::unique_xmalloc_ptr.
5694 2017-08-22 Tom Tromey <tom@tromey.com>
5696 * compile/compile.c (compile_file_command): Use
5697 gdb::unique_xmalloc_ptr, std::string.
5698 * utils.c (gdb_abspath): Change return type.
5699 * source.c (openp): Update.
5700 * objfiles.c (allocate_objfile): Update.
5701 * main.c (set_gdb_data_directory): Update.
5702 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
5704 2017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
5706 * cli-cmds.c (list_commands): List actual code around more than
5709 2017-08-21 John Baldwin <jhb@FreeBSD.org>
5711 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
5713 2017-08-21 Pedro Alves <palves@redhat.com>
5716 * c-exp.y (variable production): Handle function aliases.
5717 * minsyms.c (msymbol_is_text): New function.
5718 * minsyms.h (msymbol_is_text): Declare.
5719 * symtab.c (find_function_alias_target): New function.
5720 * symtab.h (find_function_alias_target): Declare.
5722 2017-08-21 Pedro Alves <palves@redhat.com>
5724 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
5726 * typeprint.c (whatis_exp): If handling "whatis", and expression
5727 is OP_TYPE, strip one typedef level. Otherwise don't strip
5729 * valops.c (value_cast): Save "to" type before resolving
5730 stubs/typedefs. Use that type as resulting value's type.
5732 2017-08-18 Tom Tromey <tom@tromey.com>
5733 Pedro Alves <palves@redhat.com>
5735 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
5736 * sol-thread.c (sol_thread_resume, sol_thread_wait)
5737 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
5738 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
5739 * proc-service.c (ps_xfer_memory): Use scoped_restore.
5740 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
5741 (linux_get_siginfo_data): Add "thread" argument. Use
5743 * linux-nat.c (linux_child_follow_fork)
5744 (check_stopped_by_watchpoint): Use scoped_restore.
5745 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
5746 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
5747 (restore_inferior_ptid, save_inferior_ptid): Remove.
5748 * btrace.c (btrace_fetch): Use scoped_restore.
5749 * bsd-uthread.c (bsd_uthread_fetch_registers)
5750 (bsd_uthread_store_registers): Use scoped_restore.
5751 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
5753 * aix-thread.c (aix_thread_resume, aix_thread_wait)
5754 (aix_thread_xfer_partial): Use scoped_restore.
5755 * inferior.h (save_inferior_ptid): Remove.
5757 2017-08-18 Yao Qi <yao.qi@linaro.org>
5760 * arm-tdep.c (gdb_print_insn_arm): Mark
5761 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
5763 2017-08-18 Yao Qi <yao.qi@linaro.org>
5765 * NEWS: Mention GDBserver's new option "--selftest".
5766 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
5767 * selftest.c: Move it to common/selftest.c.
5768 * selftest.h: Move it to common/selftest.h.
5769 * selftest-arch.c (reset): New function.
5770 (tests_with_arch): Call reset.
5772 2017-08-18 Yao Qi <yao.qi@linaro.org>
5774 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
5775 instead of exception_fprintf and printf_filtered.
5777 2017-08-18 Yao Qi <yao.qi@linaro.org>
5779 * selftest.c (register_self_test): Rename it to
5780 selftests::register_test.
5781 (run_self_tests): selftest::run_tests.
5782 * selftest.h: Update declarations.
5783 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
5784 selftests::register_test_foreach_arch.
5785 * selftest-arch.h: Update declaration.
5786 * aarch64-tdep.c: Update.
5787 * arm-tdep.c: Likewise.
5788 * disasm-selftests.c: Likewise.
5789 * dwarf2loc.c: Likewise.
5790 * dwarf2-frame.c: Likewise.
5791 * findvar.c: Likewise.
5792 * gdbarch-selftests.c: Likewise.
5793 * maint.c (maintenance_selftest): Likewise.
5794 * regcache.c: Likewise.
5795 * rust-exp.y: Likewise.
5796 * selftest-arch.c: Likewise.
5797 * unittests/environ-selftests.c: Likewise.
5798 * unittests/function-view-selftests.c: Likewise.
5799 * unittests/offset-type-selftests.c: Likewise.
5800 * unittests/optional-selftests.c: Likewise.
5801 * unittests/scoped_restore-selftests.c: Likewise.
5802 * utils-selftests.c: Likewise.
5804 2017-08-17 Pedro Alves <palves@redhat.com>
5806 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
5809 2017-08-17 Pedro Alves <palves@redhat.com>
5811 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
5813 (reset_die_in_process): Delete, replaced by ...
5814 (process_die_scope): ... this new class. Make it responsible for
5815 freeing cu->line_header too.
5816 (process_die): Use process_die_scope.
5817 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
5818 cu->line_header_die_owner. Don't release the line header if it's
5820 (setup_type_unit_groups): Make the CU/DIE own the line header.
5821 Don't release the line header here.
5823 2017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
5825 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
5827 2017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
5829 * NEWS: Mention new shortcuts for nexti and stepi in TUI
5832 2017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
5834 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
5837 2017-08-15 Stafford Horne <shorne@gmail.com>
5839 * MAINTAINERS (Write After Approval): Add Stafford Horne.
5841 2017-08-15 Stafford Horne <shorne@gmail.com>
5843 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
5845 2017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
5848 * infcmd.c (unset_environment_command): Use the 'clear' method on
5849 the environment instead of resetting it.
5851 2017-08-15 John Baldwin <jhb@FreeBSD.org>
5853 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
5856 2017-08-14 Tom Tromey <tom@tromey.com>
5858 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
5859 (print_binary_chars): Likewise.
5860 (BITS_IN_BYTES): Remove.
5862 2017-08-14 Tom Tromey <tom@tromey.com>
5865 * valprint.c (LOW_ZERO): Change value to 034.
5866 (print_octal_chars): Add static_asserts for octal constants.
5867 * printcmd.c (print_scalar_formatted): Add 'd' case.
5869 2017-08-11 Tom Tromey <tom@tromey.com>
5871 * symfile.c (add_symbol_file_command): Use std::vector.
5873 2017-08-14 Tom Tromey <tom@tromey.com>
5875 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
5876 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
5878 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
5880 2017-08-11 Pedro Alves <palves@redhat.com>
5882 * infrun.c (process_event_stop_test): Adjust
5883 function_name_is_marked_for_skip call.
5884 * skip.c: Include <list>.
5885 (skiplist_entry): Make it a class with private fields, and
5887 (skiplist_entry_chain): Delete.
5888 (skiplist_entries): New.
5889 (skiplist_entry_count): Delete.
5890 (highest_skiplist_entry_num): New.
5891 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
5892 (add_skiplist_entry): Delete.
5893 (skiplist_entry::skiplist_entry): New.
5894 (skiplist_entry::add_entry): New.
5895 (skip_file_command, skip_function): Adjust.
5896 (compile_skip_regexp): Delete.
5897 (skip_command): Don't compile regexp here. Adjust to use
5898 skiplist_entry::add_entry.
5899 (skip_info): Adjust to use range-for and getters.
5900 (skip_enable_command, skip_disable_command): Adjust to use
5901 range-for and setters.
5902 (skip_delete_command): Adjust to use std::list.
5903 (add_skiplist_entry): Delete.
5904 (skip_file_p): Delete, refactored as ...
5905 (skiplist_entry::do_skip_file_p): ... this new method.
5906 (skip_gfile_p): Delete, refactored as ...
5907 (skiplist_entry::do_gskip_file_p): ... this new method.
5908 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
5909 (skiplist_entry::skip_function_p): ... this new method.
5910 (function_name_is_marked_for_skip): Now returns bool, and takes
5911 the function sal by const reference. Adjust to use range-for and
5912 skiplist_entry methods.
5913 (_initialize_step_skip): Remove references to
5914 skiplist_entry_chain, skiplist_entry_count.
5915 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
5916 takes the function sal by const reference.
5918 2017-08-11 Yao Qi <yao.qi@linaro.org>
5920 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
5921 (dwarf2_frame_cache): Remove reset_cache_cleanup.
5922 (dwarf2_frame_cache):
5923 * frame-unwind.c (frame_unwind_try_unwinder): Catch
5924 RETURN_MASK_ALL and set *this_case to NULL.
5925 * frame-unwind.h: Update comments.
5927 2017-08-11 Yao Qi <yao.qi@linaro.org>
5929 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
5930 (dwarf2_frame_state_copy_regs): Remove.
5931 (dwarf2_frame_state_free_regs): Remove.
5932 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
5933 (dwarf2_restore_rule): Call method .alloc_regs instead of
5934 dwarf2_frame_state_alloc_regs.
5935 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
5936 constructor. Call std::move.
5937 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
5938 (dwarf2_frame_cache): Likewise.
5940 [GDB_SELF_TEST]: Include selftest.h and
5942 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
5943 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
5944 execute_cfa_program_test.
5946 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
5947 copy ctor, assignment operator, move assignment.
5948 <alloc_regs>: New method.
5950 (struct dwarf2_frame_state): Delete dtor.
5951 (dwarf2_frame_state_alloc_regs): Remove declaration.
5952 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
5953 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
5955 2017-08-11 Yao Qi <yao.qi@linaro.org>
5957 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
5958 (dwarf2_frame_state::dwarf2_frame_state): New.
5959 (dwarf2_frame_state::~dwarf2_frame_state): New.
5960 (dwarf2_fetch_cfa_info): Update.
5961 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
5962 rather than a pointer. Update code.
5963 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
5965 <data_align, code_align, retaddr_column>: Change them to const.
5966 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
5969 2017-08-11 Yao Qi <yao.qi@linaro.org>
5971 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
5972 <loc.exp>: New field.
5973 * dwarf2-frame.c (execute_cfa_program): Update.
5974 (dwarf2_frame_prev_register): Update.
5976 2017-08-10 Pedro Alves <palves@redhat.com>
5978 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
5980 2017-08-09 John Baldwin <jhb@FreeBSD.org>
5982 * fbsd-nat.c (struct fbsd_fork_info): Remove.
5983 (fbsd_pending_children): Use std::list.
5984 (fbsd_remember_child): Likewise.
5985 (fbsd_is_child_pending): Likewise.
5986 (fbsd_pending_vfork_done): Use std::forward_list.
5987 (fbsd_add_vfork_done): Likewise.
5988 (fbsd_is_vfork_done_pending): Likewise.
5989 (fbsd_next_vfork_done): Likewise.
5991 2017-08-09 John Baldwin <jhb@FreeBSD.org>
5993 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
5994 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
5995 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
5997 (fbsd_xfer_partial): Use gdb::byte_vector.
5998 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
6000 2017-08-09 John Baldwin <jhb@FreeBSD.org>
6002 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
6004 (fbsd_find_memory_regions): Fix `mapfile' initialization.
6006 2017-08-09 Tom Tromey <tom@tromey.com>
6008 * skip.c (skiplist_entry): New constructor.
6009 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
6010 (skiplist_entry::file_is_glob): Now bool.
6011 (skiplist_entry::file, skiplist_entry::function): Now
6013 (make_skip_entry): Return a unique_ptr. Use new.
6014 (free_skiplist_entry, free_skiplist_entry_cleanup)
6015 (make_free_skiplist_entry_cleanup): Remove.
6016 (skip_command, skip_disable_command, add_skiplist_entry)
6017 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
6018 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
6019 (function_name_is_marked_for_skip): Update.
6020 (skip_delete_command): Update. Use delete.
6022 2017-08-09 Jiong Wang <jiong.wang@arm.com>
6024 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
6025 (aarch64_linux_core_read_description): New function.
6026 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
6028 2017-08-09 Pedro Alves <palves@redhat.com>
6030 * cp-name-parser.y (cp_comp_to_string): Return a
6031 gdb::unique_xmalloc_ptr<char>.
6032 * cp-support.c (replace_typedefs_qualified_name)
6033 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
6034 (cp_canonicalize_string_full): Use op= instead of explicit
6036 (cp_class_name_from_physname, method_name_from_physname)
6037 (cp_func_name, cp_remove_params): Adjust to use
6038 gdb::unique_xmalloc_ptr<char>.
6039 * cp-support.h (cp_comp_to_string): Return a
6040 gdb::unique_xmalloc_ptr<char>.
6041 * python/py-type.c (typy_lookup_type): Adjust to use
6042 gdb::unique_xmalloc_ptr<char>.
6044 2017-08-09 H.J. Lu <hongjiu.lu@intel.com>
6046 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
6048 2017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
6049 Yao Qi <yao.qi@linaro.org>
6051 * cp-support.c (cp_canonicalize_string_full): Use
6052 gdb::unique_xmalloc_ptr<char>.
6053 (cp_canonicalize_string): Likewise.
6055 2017-08-09 Yao Qi <yao.qi@linaro.org>
6057 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
6058 * regformats/i386/amd64-avx-avx512.dat: Remove.
6059 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
6060 * regformats/i386/amd64-avx-mpx.dat:Remove.
6061 * regformats/i386/amd64-avx.dat: Remove.
6062 * regformats/i386/amd64-mpx.dat: Remove.
6063 * regformats/i386/i386-avx-avx512.dat: Remove.
6064 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
6065 * regformats/i386/i386-avx-mpx.dat: Remove.
6066 * regformats/i386/i386-mmx.dat: Remove.
6067 * regformats/i386/i386-mpx.dat: Remove.
6069 2017-08-09 Yao Qi <yao.qi@linaro.org>
6071 * amd64-tdep.h (tdesc_x32): Remove the declaration.
6072 * amd64-tdep.c: Don't include features/i386/x32*.c.
6073 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
6075 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
6076 and i386/x32-avx-avx512.
6077 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
6079 * features/i386/x32-avx-avx512.c: Removed.
6080 * features/i386/x32-avx-avx512.xml: Removed.
6081 * features/i386/x32-avx.c: Removed.
6082 * features/i386/x32-avx.xml: Removed.
6083 * features/i386/x32.c: Removed.
6084 * features/i386/x32.xml: Removed.
6085 * regformats/i386/x32-avx-avx512.dat: Removed.
6086 * regformats/i386/x32-avx.dat: Removed.
6087 * regformats/i386/x32.dat: Removed.
6089 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
6091 PR breakpoints/21886
6092 * mem-break.c (default_memory_insert_breakpoint): Use
6093 `->placed_address' rather than `->reqstd_address' for the
6094 breakpoint location.
6096 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
6098 * arch-utils.c (default_print_insn): Remove arch/mach/endian
6101 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
6103 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
6104 a union of `tdep_info', `tdesc_data' and `id'.
6105 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
6106 rather than `info.tdep_info'.
6107 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
6108 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
6109 * i386-tdep.c (i386_gdbarch_init): Likewise.
6110 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
6111 * mips-tdep.c (mips_gdbarch_init): Likewise.
6112 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
6113 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
6114 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
6116 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
6118 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
6119 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
6121 * spu-tdep.c (spu_gdbarch_init): Likewise.
6122 * gdbarch.h: Regenerate.
6124 2017-08-07 Leszek Swirski <leszeks@google.com>
6127 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
6129 2017-08-07 Simon Marchi <simon.marchi@ericsson.com>
6131 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
6132 (gdbsim_open): Rename gdb_argv args object to argv.
6134 2017-08-05 Tom Tromey <tom@tromey.com>
6136 * compile/compile-object-load.c (compile_object_load): Use
6137 gdb::unique_xmalloc_ptr.
6138 * cli/cli-dump.c (scan_filename): Rename from
6139 scan_filename_with_cleanup. Change return type.
6140 (scan_expression): Rename from scan_expression_with_cleanup.
6142 (dump_memory_to_file, dump_value_to_file, restore_command):
6143 Use gdb::unique_xmalloc_ptr. Update.
6144 * cli/cli-cmds.c (find_and_open_script): Use
6145 gdb::unique_xmalloc_ptr.
6146 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
6147 * symmisc.c (maintenance_print_symbols)
6148 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
6149 * symfile.c (symfile_bfd_open, generic_load)
6150 (add_symbol_file_command, remove_symbol_file_command): Use
6151 gdb::unique_xmalloc_ptr.
6152 * source.c (openp): Use gdb::unique_xmalloc_ptr.
6153 * psymtab.c (maintenance_print_psymbols): Use
6154 gdb::unique_xmalloc_ptr.
6155 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
6156 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
6157 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
6158 (reload_shared_libraries_1): Likewise.
6160 2017-08-05 Tom Tromey <tom@tromey.com>
6162 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
6163 (rust_op_vector, rust_set_vector): New typedefs.
6164 (current_parser): New global.
6165 (work_obstack): Change to pointer type. Update all users.
6166 (rust_ast, pstate): Remove globals.
6167 (struct rust_parser): New.
6168 (%union) <params, field_inits>: Change type.
6169 (start, tuple_expr, unit_expr, struct_expr_list, literal)
6170 (field_expr, expr_list, maybe_expr_list, type_list): Update.
6171 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
6172 (convert_params_to_types, convert_params_to_expression): Change
6174 (ast_string): Change type of "fields".
6175 (rust_parse): Make a rust_parser. Remove cleanups.
6176 (rust_lex_tests): Make and install an auto_obstack.
6178 2017-08-04 Yao Qi <yao.qi@linaro.org>
6180 * configure.srv (ipa_x32_linux_regobj): New.
6181 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
6182 instead of X86_TDESC_AVX512.
6183 (initialize_low_tracepoint): Call
6184 init_registers_x32_avx_avx512_linux.
6186 2017-08-04 Yao Qi <yao.qi@linaro.org>
6188 * utils.h (gdb_argv): Add namespace std for nullptr_t.
6190 2017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
6192 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
6194 2017-08-03 Tom Tromey <tom@tromey.com>
6196 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
6198 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
6200 2017-08-03 Tom Tromey <tom@tromey.com>
6202 * python/py-param.c (compute_enum_values): Use gdb_argv.
6204 2017-08-03 Tom Tromey <tom@tromey.com>
6206 * utils.h (struct gdb_argv_deleter): New.
6207 (gdb_argv): New class.
6208 * utils.c (gdb_argv::reset): New method.
6209 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
6210 * tracefile.c (tsave_command): Use gdb_argv.
6211 * top.c (new_ui_command): Use gdb_argv.
6212 * symmisc.c (maintenance_print_symbols)
6213 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
6214 * symfile.c (symbol_file_command, generic_load)
6215 (remove_symbol_file_command): Use gdb_argv.
6216 * stack.c (backtrace_command): Use gdb_argv.
6217 * source.c (add_path, show_substitute_path_command)
6218 (unset_substitute_path_command, set_substitute_path_command):
6220 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
6221 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
6222 * remote.c (extended_remote_run, remote_put_command)
6223 (remote_get_command, remote_delete_command): Use gdb_argv.
6224 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
6225 (gdbsim_open): Use gdb_argv.
6226 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
6227 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
6228 * procfs.c (procfs_info_proc): Use gdb_argv.
6229 * interps.c (interpreter_exec_cmd): Use gdb_argv.
6230 * infrun.c (handle_command): Use gdb_argv.
6231 * inferior.c (add_inferior_command, clone_inferior_command):
6233 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
6234 * exec.c (exec_file_command): Use gdb_argv.
6235 * cli/cli-cmds.c (alias_command): Use gdb_argv.
6236 * compile/compile.c (build_argc_argv): Use gdb_argv.
6238 2017-08-03 Tom Tromey <tom@tromey.com>
6240 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
6242 2017-08-03 Tom Tromey <tom@tromey.com>
6244 * python/python.c (compute_python_string): Return std::string.
6245 (gdbpy_eval_from_control_command): Update.
6246 (do_start_initialization): Use std::string.
6247 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
6249 * python/py-breakpoint.c (local_setattro): Use string_printf, not
6252 2017-08-03 Tom Tromey <tom@tromey.com>
6254 * top.h (do_restore_instream_cleanup): Remove.
6255 * top.c (do_restore_instream_cleanup): Remove.
6256 (read_command_file): Use scoped_restore.
6257 * cli/cli-script.c (execute_user_command): Use scoped_restore.
6259 2017-08-03 Tom Tromey <tom@tromey.com>
6261 * cli/cli-script.c (execute_user_command)
6262 (execute_control_command): Use scoped_restore.
6264 2017-08-03 Tom Tromey <tom@tromey.com>
6266 * cli/cli-script.c (do_restore_user_call_depth): Remove.
6267 (execute_user_command): Remove user_call_depth; use
6268 user_args_stack's size instead.
6270 2017-08-03 Tom Tromey <tom@tromey.com>
6272 * top.h (in_user_command): Remove.
6273 * top.c (in_user_command): Remove.
6274 * cli/cli-script.c (do_restore_user_call_depth)
6275 (execute_user_command): Update.
6277 2017-08-03 Tom Tromey <tom@tromey.com>
6279 * valops.c (search_struct_method): Use gdb::byte_vector.
6280 * valarith.c (value_concat): Use std::vector.
6281 * target.c (memory_xfer_partial): Use gdb::byte_vector.
6282 (simple_search_memory): Likewise.
6283 * printcmd.c (find_string_backward): Use gdb::byte_vector.
6284 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
6285 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
6286 * elfread.c (elf_rel_plt_read): Use std::string.
6287 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
6288 * cli/cli-dump.c (restore_section_callback): Use
6291 2017-08-03 Tom Tromey <tom@tromey.com>
6293 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
6295 2017-08-03 Tom Tromey <tom@tromey.com>
6297 * tui/tui-regs.c (tui_restore_gdbout): Remove.
6298 (tui_register_format): Use scoped_restore.
6300 2017-08-03 Tom Tromey <tom@tromey.com>
6302 * reverse.c (exec_direction_default): Remove.
6303 (exec_reverse_once): Use scoped_restore.
6304 * remote.c (restore_remote_timeout): Remove.
6305 (remote_flash_erase, remote_flash_write, remote_flash_done)
6306 (readchar, remote_serial_write): Use scoped_restore.
6307 * cli/cli-script.c (struct source_cleanup_lines_args)
6308 (source_cleanup_lines): Remove.
6309 (script_from_file): Use scoped_restore.
6310 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
6311 (source_command): Use scoped_restore.
6313 2017-08-03 Tom Tromey <tom@tromey.com>
6315 * utils.h (make_cleanup_free_so): Remove.
6316 * utils.c (do_free_so, make_cleanup_free_so): Remove.
6317 * solist.h (struct so_deleter): New.
6318 (so_list_up): New typedef.
6319 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
6321 2017-08-03 Tom Tromey <tom@tromey.com>
6323 * utils.h (make_cleanup_restore_current_language): Remove.
6324 * utils.c (do_restore_current_language)
6325 (make_cleanup_restore_current_language): Remove.
6326 * parse.c (parse_exp_in_context_1)
6327 (parse_expression_with_language): Use
6328 scoped_restore_current_language.
6329 * mi/mi-main.c (mi_cmd_execute): Use
6330 scoped_restore_current_language.
6331 * language.h (scoped_restore_current_language): New class.
6333 2017-08-03 Tom Tromey <tom@tromey.com>
6335 * compile/compile.c (cleanup_unlink_file): Remove.
6336 (compile_to_object): Use gdb::unlinker.
6337 (eval_compile_command): Likewise.
6339 2017-08-03 Tom Tromey <tom@tromey.com>
6341 * utils.h (make_cleanup_fclose): Remove.
6342 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
6344 2017-08-03 Tom Tromey <tom@tromey.com>
6346 * top.c (open_terminal_stream): Return gdb_file_up.
6347 (new_ui_command): Update.
6349 2017-08-03 Tom Tromey <tom@tromey.com>
6351 * source.c (print_source_lines_base, forward_search_command)
6352 (reverse_search_command): Use gdb_file_up.
6354 2017-08-03 Tom Tromey <tom@tromey.com>
6356 * fbsd-nat.c (fbsd_find_memory_regions): Update.
6358 2017-08-03 Tom Tromey <tom@tromey.com>
6360 * cli/cli-cmds.c (find_and_open_script): Change return type.
6361 Remove "streamp" and "full_path" parameters.
6362 (source_script_with_search): Update.
6363 * auto-load.c (source_script_file): Update.
6364 * cli/cli-cmds.h (find_and_open_script): Change type.
6365 (open_script): New struct.
6367 2017-08-03 Tom Tromey <tom@tromey.com>
6369 * xml-support.c (xml_fetch_content_from_file): Update.
6370 * ui-file.c (stdio_file::open): Update.
6371 * tracefile-tfile.c (tfile_start): Update.
6372 * remote.c (remote_file_put, remote_file_get): Update.
6373 * nat/linux-procfs.c (linux_proc_get_int)
6374 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
6375 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
6376 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
6377 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
6378 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
6379 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
6380 * linux-nat.c (linux_proc_pending_signals): Update.
6381 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
6382 (file_closer): Remove.
6383 * compile/compile.c (compile_to_object): Update.
6384 * common/filestuff.h (struct gdb_file_deleter): New.
6385 (gdb_file_up): New typedef.
6386 (gdb_fopen_cloexec): Change return type.
6387 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
6388 * cli/cli-dump.c (fopen_with_cleanup): Remove.
6389 (dump_binary_file, restore_binary_file): Update.
6390 * auto-load.c (auto_load_objfile_script_1): Update.
6392 2017-08-03 Tom Tromey <tom@tromey.com>
6394 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
6395 (info_static_tracepoint_markers_command): Likewise.
6396 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
6397 * skip.c (skip_info): Use ui_out_emit_table.
6398 * progspace.c (print_program_space): Use ui_out_emit_table.
6399 * osdata.c (info_osdata): Use ui_out_emit_table.
6400 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
6402 * linux-thread-db.c (info_auto_load_libthread_db): Use
6404 * inferior.c (print_inferior): Use ui_out_emit_table.
6405 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
6406 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
6407 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
6408 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
6409 * ui-out.h (class ui_out_emit_table): New.
6411 2017-08-02 Maciej W. Rozycki <macro@imgtec.com>
6413 * mips-tdep.c (mips_fpu_type_str): New function.
6414 (mips_dump_tdep): Call it.
6416 2017-08-01 Maciej W. Rozycki <macro@imgtec.com>
6418 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
6421 2017-07-31 Xavier Roirand <roirand@adacore.com>
6423 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
6425 2017-07-27 Xavier Roirand <roirand@adacore.com>
6427 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
6429 2017-07-26 Yao Qi <yao.qi@linaro.org>
6431 * cli/cli-cmds.c (maintenancechecklist): New variable.
6432 * gdbcmd.h (maintenancechecklist): Declare it.
6433 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
6434 Call i386_linux_read_description with different masks.
6435 * maint.c (maintenance_check_command): New function.
6436 (_initialize_maint_cmds): Call add_prefix_cmd.
6437 * target-descriptions.c (tdesc_reg): override operator != and ==.
6438 (tdesc_type): Likewise.
6439 (tdesc_feature): Likewise.
6440 (target_desc): Likewise.
6441 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
6442 (maintenance_check_xml_descriptions): New function.
6443 (_initialize_target_descriptions) Add command "xml-descriptions".
6444 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
6446 2017-07-26 Yao Qi <yao.qi@linaro.org>
6448 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
6449 Include features/i386/32bit-*.c.
6450 (i386_linux_read_description): Generate target description if it
6452 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
6454 * features/i386/32bit-linux.c: Re-generated.
6455 * features/i386/32bit-sse.c: Likewise.
6456 * target-descriptions.c (print_c_feature::visit): Print code to
6457 set register number if needed.
6458 (print_c_feature) <m_next_regnum>: New field.
6460 2017-07-26 Yao Qi <yao.qi@linaro.org>
6462 * features/Makefile (CFILES): Rename with TDESC_CFILES.
6463 (FEATURE_XMLFILES): New.
6464 (FEATURE_CFILES): New.
6466 (clean-cfiles): Remove generated c files.
6467 * features/i386/32bit-avx.c: Generated.
6468 * features/i386/32bit-avx512.c: Generated.
6469 * features/i386/32bit-core.c: Generated.
6470 * features/i386/32bit-linux.c: Generated.
6471 * features/i386/32bit-mpx.c: Generated.
6472 * features/i386/32bit-pkeys.c: Generated.
6473 * features/i386/32bit-sse.c: Generated.
6474 * target-descriptions.c: Include algorithm.
6475 (tdesc_element_visitor): Add method visit_end.
6476 (print_c_tdesc): Implement visit_end.
6477 (print_c_tdesc:: m_filename_after_features): Move it to
6479 (print_c_feature): New class.
6480 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
6481 name starts with "i386/32bit-".
6483 2017-07-26 Yao Qi <yao.qi@linaro.org>
6485 * target-descriptions.c (tdesc_element_visitor): New class.
6486 (tdesc_element): New class.
6487 (tdesc_reg): Inherit from tdesc_element.
6488 (tdesc_reg::accept): New function.
6489 (tdesc_type): Inherit from tdesc_element.
6490 (tdesc_type::accept): New function.
6491 (tdesc_feature): Inherit from tdesc_element.
6492 (tdesc_feature::accept): New function.
6493 (target_desc): Inherit from tdesc_element.
6494 (target_desc::target_desc): New.
6495 (target_desc::~target_desc): New.
6496 (target_desc::accept): New.
6497 (allocate_target_description): Use new.
6498 (free_target_description): Use delete.
6499 (print_c_tdesc): New class.
6500 (maint_print_c_tdesc_cmd): Adjust.
6502 * features/aarch64.c: Re-generated.
6503 * features/arc-arcompact.c: Re-generated.
6504 * features/arc-v2.c: Re-generated.
6505 * features/arm/arm-with-iwmmxt.c: Re-generated.
6506 * features/arm/arm-with-m.c: Re-generated.
6507 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
6508 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
6509 * features/arm/arm-with-neon.c: Re-generated.
6510 * features/arm/arm-with-vfpv2.c: Re-generated.
6511 * features/arm/arm-with-vfpv3.c: Re-generated.
6512 * features/i386/amd64-avx-avx512.c: Re-generated.
6513 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
6514 * features/i386/amd64-avx.c: Re-generated.
6515 * features/i386/amd64-avx-linux.c: Re-generated.
6516 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
6517 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
6518 * features/i386/amd64-avx-mpx.c: Re-generated.
6519 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
6520 * features/i386/amd64.c: Re-generated.
6521 * features/i386/amd64-linux.c: Re-generated.
6522 * features/i386/amd64-mpx.c: Re-generated.
6523 * features/i386/amd64-mpx-linux.c: Re-generated.
6524 * features/i386/i386-avx-avx512.c: Re-generated.
6525 * features/i386/i386-avx-avx512-linux.c: Re-generated.
6526 * features/i386/i386-avx.c: Re-generated.
6527 * features/i386/i386-avx-linux.c: Re-generated.
6528 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
6529 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
6530 * features/i386/i386-avx-mpx.c: Re-generated.
6531 * features/i386/i386-avx-mpx-linux.c: Re-generated.
6532 * features/i386/i386.c: Re-generated.
6533 * features/i386/i386-linux.c: Re-generated.
6534 * features/i386/i386-mmx.c: Re-generated.
6535 * features/i386/i386-mmx-linux.c: Re-generated.
6536 * features/i386/i386-mpx.c: Re-generated.
6537 * features/i386/i386-mpx-linux.c: Re-generated.
6538 * features/i386/x32-avx-avx512.c: Re-generated.
6539 * features/i386/x32-avx-avx512-linux.c: Re-generated.
6540 * features/i386/x32-avx.c: Re-generated.
6541 * features/i386/x32-avx-linux.c: Re-generated.
6542 * features/i386/x32.c: Re-generated.
6543 * features/i386/x32-linux.c: Re-generated.
6544 * features/microblaze.c: Re-generated.
6545 * features/microblaze-with-stack-protect.c: Re-generated.
6546 * features/mips64-dsp-linux.c: Re-generated.
6547 * features/mips64-linux.c: Re-generated.
6548 * features/mips-dsp-linux.c: Re-generated.
6549 * features/mips-linux.c: Re-generated.
6550 * features/nds32.c: Re-generated.
6551 * features/nios2.c: Re-generated.
6552 * features/nios2-linux.c: Re-generated.
6553 * features/rs6000/powerpc-32.c: Re-generated.
6554 * features/rs6000/powerpc-32l.c: Re-generated.
6555 * features/rs6000/powerpc-403.c: Re-generated.
6556 * features/rs6000/powerpc-403gc.c : Re-generated.
6557 * features/rs6000/powerpc-405.c: Re-generated.
6558 * features/rs6000/powerpc-505.c: Re-generated.
6559 * features/rs6000/powerpc-601.c: Re-generated.
6560 * features/rs6000/powerpc-602.c: Re-generated.
6561 * features/rs6000/powerpc-603.c: Re-generated.
6562 * features/rs6000/powerpc-604.c: Re-generated.
6563 * features/rs6000/powerpc-64.c: Re-generated.
6564 * features/rs6000/powerpc-64l.c: Re-generated.
6565 * features/rs6000/powerpc-7400.c: Re-generated.
6566 * features/rs6000/powerpc-750.c: Re-generated.
6567 * features/rs6000/powerpc-860.c: Re-generated.
6568 * features/rs6000/powerpc-altivec32.c: Re-generated.
6569 * features/rs6000/powerpc-altivec32l.c: Re-generated.
6570 * features/rs6000/powerpc-altivec64.c: Re-generated.
6571 * features/rs6000/powerpc-altivec64l.c: Re-generated.
6572 * features/rs6000/powerpc-cell32l.c: Re-generated.
6573 * features/rs6000/powerpc-cell64l.c: Re-generated.
6574 * features/rs6000/powerpc-e500.c: Re-generated.
6575 * features/rs6000/powerpc-e500l.c: Re-generated.
6576 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
6577 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
6578 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
6579 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
6580 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
6581 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
6582 * features/rs6000/powerpc-vsx32.c: Re-generated.
6583 * features/rs6000/powerpc-vsx32l.c: Re-generated.
6584 * features/rs6000/powerpc-vsx64.c: Re-generated.
6585 * features/rs6000/powerpc-vsx64l.c: Re-generated.
6586 * features/rs6000/rs6000.c: Re-generated.
6587 * features/s390-linux32.c: Re-generated.
6588 * features/s390-linux32v1.c: Re-generated.
6589 * features/s390-linux32v2.c: Re-generated.
6590 * features/s390-linux64.c: Re-generated.
6591 * features/s390-linux64v1.c: Re-generated.
6592 * features/s390-linux64v2.c: Re-generated.
6593 * features/s390-te-linux64.c: Re-generated.
6594 * features/s390-tevx-linux64.c: Re-generated.
6595 * features/s390-vx-linux64.c: Re-generated.
6596 * features/s390x-linux64.c: Re-generated.
6597 * features/s390x-linux64v1.c: Re-generated.
6598 * features/s390x-linux64v2.c: Re-generated.
6599 * features/s390x-te-linux64.c: Re-generated.
6600 * features/s390x-tevx-linux64.c: Re-generated.
6601 * features/s390x-vx-linux64.c: Re-generated.
6602 * features/sparc/sparc32-solaris.c: Re-generated.
6603 * features/sparc/sparc64-solaris.c: Re-generated.
6604 * features/tic6x-c62x.c: Re-generated.
6605 * features/tic6x-c62x-linux.c: Re-generated.
6606 * features/tic6x-c64x.c: Re-generated.
6607 * features/tic6x-c64x-linux.c: Re-generated.
6608 * features/tic6x-c64xp.c: Re-generated.
6609 * features/tic6x-c64xp-linux.c: Re-generated.
6611 2017-07-26 Yao Qi <yao.qi@linaro.org>
6613 * i386-linux-tdep.c (i386_linux_read_description): New function.
6614 (i386_linux_core_read_description): Call
6615 i386_linux_read_description.
6616 * i386-linux-tdep.h (i386_linux_read_description): Declare.
6617 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
6618 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
6619 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
6620 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
6621 * x86-linux-nat.c (x86_linux_read_description): Call
6622 i386_linux_read_description.
6624 2017-07-26 Yao Qi <yao.qi@linaro.org>
6627 * features/Makefile (%.c: %.xml): Pass the xml file name to
6628 command "maint print c-tdesc".
6629 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
6632 2017-07-26 Yao Qi <yao.qi@linaro.org>
6634 * target-descriptions.c (target_desc): Add ctor and dtor. Do
6635 in-class initialization.
6636 (tdesc_create_feature): Call new instead of XCNEW.
6637 (free_target_description): Ue delete.
6639 2017-07-25 John Baldwin <jhb@FreeBSD.org>
6641 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
6643 2017-07-25 Yao Qi <yao.qi@linaro.org>
6645 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
6647 (amd64_x32_init_abi): Likewise.
6648 * amd64-tdep.h (amd64_init_abi): Update declaration.
6649 (amd64_x32_init_abi): Likewise.
6651 2017-07-25 Yao Qi <yao.qi@linaro.org>
6654 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
6655 condition for FPSCR.
6656 (arm_linux_store_inferior_registers): Likewise.
6658 2017-07-22 Tom Tromey <tom@tromey.com>
6660 * break-catch-syscall.c (struct catch_syscall_inferior_data)
6661 <syscalls_counts>: Now a std::vector.
6662 (get_catch_syscall_inferior_data): Use "new".
6663 (catch_syscall_inferior_data_cleanup): Use "delete".
6664 (insert_catch_syscall, remove_catch_syscall)
6665 (clear_syscall_counts): Update.
6667 2017-07-22 Tom Tromey <tom@tromey.com>
6669 * break-catch-syscall.c (syscall_catchpoint)
6670 <syscalls_to_be_caught>: Now a std::vector<int>
6671 (~syscall_catchpoint): Remove.
6672 (insert_catch_syscall, remove_catch_syscall)
6673 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
6674 (print_mention_catch_syscall, print_recreate_catch_syscall):
6676 (create_syscall_event_catchpoint): Change type of "filter"
6678 (catch_syscall_split_args): Return a std::vector.
6679 (catch_syscall_command_1, catching_syscall_number_1): Update.
6681 2017-07-22 Tom Tromey <tom@tromey.com>
6683 * break-catch-throw.c (struct exception_catchpoint)
6684 <exception_rx>: Now a std::string.
6685 (~exception_catchpoint): Remove.
6686 (print_one_detail_exception_catchpoint): Update.
6687 (handle_gnu_v3_exceptions): Change type of except_rx.
6688 (extract_exception_regexp): Return a std::string.
6689 (catch_exception_command_1): Update.
6691 2017-07-22 Tom Tromey <tom@tromey.com>
6693 * break-catch-sig.c (gdb_signal_type): Remove typedef.
6694 (struct signal_catchpoint) <signals_to_be_caught>: Now a
6696 <catch_all>: Now a bool.
6697 (~signal_catchpoint): Remove.
6698 (signal_catchpoint_insert_location)
6699 (signal_catchpoint_remove_location)
6700 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
6701 (signal_catchpoint_print_mention)
6702 (signal_catchpoint_print_recreate)
6703 (signal_catchpoint_explains_signal): Update.
6704 (create_signal_catchpoint): Change type of "filter" and
6706 (catch_signal_split_args): Return a std::vector. Change type of
6708 (catch_signal_command): Update.
6710 2017-07-20 Pedro Alves <palves@redhat.com>
6712 * ada-lang.c (ada_language_defn): Make extern.
6713 (_initialize_ada_language): Remove add_language call.
6714 * c-lang.c (c_language_defn, cplus_language_defn)
6715 (asm_language_defn, minimal_language_defn): Make extern.
6716 (_initialize_c_language): Delete.
6717 * completer.c (compare_cstrings): Delete, moved to utils.h.
6718 * d-lang.c (d_language_defn): Make extern.
6719 (_initialize_d_language): Remove add_language calls.
6720 * defs.h (enum language): Add comment.
6721 * f-lang.c (f_language_defn): Make extern.
6722 (_initialize_f_language): Remove add_language call.
6723 * go-lang.c (go_language_defn): Make extern.
6724 (_initialize_go_language): Remove add_language call.
6725 * language.c: Include <algorithm>.
6726 (languages): Redefine as const array.
6727 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
6728 (set_language_command): Handle "local". Use for-range loop.
6729 (set_language): Remove loop.
6730 (language_enum): Rewrite.
6731 (language_def, language_str): Remove loops.
6732 (add_language): Delete.
6733 (add_set_language_command): New, based on add_languages.
6734 (skip_language_trampoline): Adjust.
6735 (local_language_defn): Delete.
6736 (language_gdbarch_post_init): Adjust.
6737 (_initialize_language): Remove add_language calls. Call
6738 add_set_language_command.
6739 * language.h (add_language): Delete.
6740 (auto_language_defn)
6741 (unknown_language_defn, minimal_language_defn, ada_language_defn)
6742 (asm_language_defn, c_language_defn, cplus_language_defn)
6743 (d_language_defn, f_language_defn, go_language_defn)
6744 (m2_language_defn, objc_language_defn, opencl_language_defn)
6745 (pascal_language_defn, rust_language_defn): Declare.
6746 * m2-lang.c (m2_language_defn): Make extern.
6747 (_initialize_m2_language): Remove add_language call.
6748 * objc-lang.c (objc_language_defn): Make extern.
6749 (_initialize_objc_language): Remove add_language call.
6750 * opencl-lang.c (opencl_language_defn): Make extern.
6751 (_initialize_opencl_language): Remove add_language call.
6752 * p-lang.c (pascal_language_defn): Make extern.
6753 (_initialize_pascal_language): Delete.
6754 * rust-lang.c (rust_language_defn): Make extern.
6755 (_initialize_rust_language): Delete.
6756 * utils.h (compare_cstrings): New static inline function.
6758 2017-07-20 Pedro Alves <palves@redhat.com>
6760 * ada-lang.c (ada_to_fixed_type_1): Adjust.
6761 (get_var_value): Constify parameters.
6762 (get_int_var_value): Change prototype.
6763 (to_fixed_range_type): Adjust.
6764 * ada-lang.h (get_int_var_value): Change prototype.
6766 2017-07-20 Pedro Alves <palves@redhat.com>
6768 * dwarf2read.c (dw2_lookup_symbol): Use
6769 SYMBOL_MATCHES_SEARCH_NAME.
6770 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
6772 2017-07-20 Pedro Alves <palves@redhat.com>
6774 * block.c (block_iter_name_step, block_iter_name_first)
6775 (block_iter_name_next): Delete.
6776 (block_lookup_symbol_primary): Adjust to use
6777 dict_iter_match_first/dict_iter_match_next.
6778 * block.h (block_iter_name_first, block_iter_name_next): Delete
6780 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
6781 dict_iter_match_first/dict_iter_match_next.
6783 2017-07-20 Pedro Alves <palves@redhat.com>
6785 * cp-support.c (cp_find_first_component_aux): Add missing case for
6788 2017-07-18 David Blaikie <dblaikie@gmail.com>
6790 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
6791 of dwo_cu's dwo_file.
6793 2017-07-18 Yao Qi <yao.qi@linaro.org>
6795 * remote.c (store_registers_using_G): Remove one line comment.
6797 2017-07-18 Yao Qi <yao.qi@linaro.org>
6799 * regcache.c (regcache_cpy): Simplify it.
6800 (regcache::cpy_no_passthrough): Remove it.
6801 * regcache.h (cpy_no_passthrough): Remove it.
6802 (regcache_dup, regcache_cpy): Update comments.
6804 2017-07-18 Pedro Alves <palves@redhat.com>
6806 * remote-sim.c (sim_command_completer): Adjust to work with a
6807 completion_tracker instead of a VEC.
6809 2017-07-17 Pedro Alves <palves@redhat.com>
6811 * completer.c (complete_source_filenames): New function.
6812 (complete_address_and_linespec_locations): New function.
6813 (location_completer): Use complete_address_and_linespec_locations.
6814 (completion_tracker::build_completion_result): Honor the tracker's
6815 request to suppress append.
6816 * completer.h (completion_tracker::suppress_append_ws)
6817 (completion_tracker::set_suppress_append_ws): New methods.
6818 (completion_tracker::m_suppress_append_ws): New field.
6819 (complete_source_filenames): New declaration.
6820 * linespec.c (linespec_complete_what): New.
6821 (struct ls_parser) <complete_what, completion_word,
6822 completion_quote_char, completion_quote_end, completion_tracker>:
6824 (string_find_incomplete_keyword_at_end): New.
6825 (linespec_lexer_lex_string): Record quote char. If in completion
6827 (linespec_lexer_consume_token): Advance the completion word point.
6828 (linespec_lexer_peek_token): Save/restore completion info.
6829 (save_stream_and_consume_token): New.
6830 (set_completion_after_number): New.
6831 (linespec_parse_basic): Set what to complete next depending on
6832 token. Handle function and label completions specially.
6833 (parse_linespec): Disable objc shortcut in completion mode. Set
6834 what to complete next depending on token type. Skip keyword if in
6836 (complete_linespec_component, linespec_complete): New.
6837 * linespec.h (linespec_complete): Declare.
6839 2017-07-17 Pedro Alves <palves@redhat.com>
6841 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
6842 Handle 'operator<' / 'operator<<'.
6844 2017-07-17 Pedro Alves <palves@redhat.com>
6846 * completer.c (collect_explicit_location_matches): Handle
6848 (convert_explicit_location_to_linespec): New, factored out from
6850 (convert_explicit_location_to_sals): ... this.
6851 (complete_label): New.
6852 (linespec_complete_label, find_label_symbols_in_block): New.
6853 (find_label_symbols): Add completion_mode parameter and adjust to
6854 call find_label_symbols_in_block.
6855 * linespec.h (linespec_complete_label): Declare.
6857 2017-07-17 Pedro Alves <palves@redhat.com>
6859 * ada-lang.c (ada_collect_symbol_completion_matches): Add
6860 complete_symbol_mode parameter.
6861 * cli/cli-cmds.c (complete_command): Get the completion result out
6862 of the handle_brkchars tracker if used a custom word point.
6863 * completer.c: Include "linespec.h".
6864 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
6865 (advance_to_expression_complete_word_point): New.
6866 (completion_tracker::completes_to_completion_word): New.
6867 (complete_files_symbols): Pass down
6868 complete_symbol_mode::EXPRESSION.
6869 (explicit_options, probe_options): New.
6870 (collect_explicit_location_matches): Complete on the
6871 explictit_loc->foo instead of word. Use
6872 linespec_complete_function. Handle MATCH_LINE. Handle offering
6873 keyword and options completions.
6874 (backup_text_ptr): Delete.
6875 (skip_keyword): New.
6876 (complete_explicit_location): Remove 'word' parameter. Add
6877 language, quoted_arg_start and quoted_arg_end parameters.
6878 Rewrite, parsing left to right.
6879 (location_completer): Rewrite.
6880 (location_completer_handle_brkchars): New function.
6881 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
6882 (enum complete_line_internal_reason): Adjust comments.
6883 (completion_tracker::discard_completions): New.
6884 (completer_handle_brkchars_func_for_completer): Handle
6886 (gdb_custom_word_point_brkchars)
6887 (gdb_org_rl_basic_quote_characters): New.
6888 (gdb_completion_word_break_characters_throw)
6889 (completion_find_completion_word): Handle trackers that use a
6891 (completion_tracker::advance_custom_word_point_by): New.
6892 (completion_tracker::build_completion_result): Don't rely on
6893 readline appending the quote char.
6894 (gdb_rl_attempted_completion_function_throw): Handle trackers that
6895 use a custom word point.
6896 (gdb_rl_attempted_completion_function): Restore
6897 rl_basic_quote_characters.
6898 * completer.h (class completion_tracker): Extend intro comment.
6899 (completion_tracker::set_quote_char)
6900 (completion_tracker::quote_char)
6901 (completion_tracker::set_use_custom_word_point)
6902 (completion_tracker::use_custom_word_point)
6903 (completion_tracker::custom_word_point)
6904 (completion_tracker::set_custom_word_point)
6905 (completion_tracker::advance_custom_word_point_by)
6906 (completion_tracker::completes_to_completion_word)
6907 (completion_tracker::discard_completions): New methods.
6908 (completion_tracker::m_quote_char)
6909 (completion_tracker::m_use_custom_word_point)
6910 (completion_tracker::m_custom_word_point): New fields.
6911 (advance_to_expression_complete_word_point): Declare.
6912 * f-lang.c (f_collect_symbol_completion_matches): Add
6913 complete_symbol_mode parameter.
6914 * language.h (struct language_defn)
6915 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
6917 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
6918 (linespec_complete_function): New function.
6919 (linespec_lexer_lex_keyword): Adjust.
6920 * linespec.h (linespec_keywords, linespec_complete_function): New
6922 * location.c (find_end_quote): New function.
6923 (explicit_location_lex_one): Add explicit_completion_info
6924 parameter. Save quoting info. Don't throw if being called for
6925 completion. Don't handle Ada operators here.
6926 (is_cp_operator, skip_op_false_positives, first_of)
6927 (explicit_location_lex_one_function): New function.
6928 (string_to_explicit_location): Replace 'dont_throw' parameter with
6929 an explicit_completion_info pointer parameter. Handle it. Don't
6930 use explicit_location_lex_one to lex function names. Use
6931 explicit_location_lex_one_function instead.
6932 * location.h (struct explicit_completion_info): New.
6933 (string_to_explicit_location): Replace 'dont_throw' parameter with
6934 an explicit_completion_info pointer parameter.
6935 * symtab.c (default_collect_symbol_completion_matches_break_on):
6936 Add complete_symbol_mode parameter. Handle LINESPEC mode.
6937 (default_collect_symbol_completion_matches)
6938 (collect_symbol_completion_matches): Add complete_symbol_mode
6940 (collect_symbol_completion_matches_type): Pass down
6941 complete_symbol_mode::EXPRESSION.
6942 (collect_file_symbol_completion_matches): Add complete_symbol_mode
6943 parameter. Handle LINESPEC mode.
6944 * symtab.h (complete_symbol_mode): New.
6945 (default_collect_symbol_completion_matches_break_on)
6946 (default_collect_symbol_completion_matches)
6947 (collect_symbol_completion_matches)
6948 (collect_file_symbol_completion_matches): Add complete_symbol_mode
6951 2017-07-17 Pedro Alves <palves@redhat.com>
6953 * utils.c (enum class strncmp_iw_mode): New.
6954 (strcmp_iw): Rename to ...
6955 (strncmp_iw_with_mode): ... this. Add string2_len and mode
6956 parameters. Handle them.
6958 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
6959 * utils.h (strncmp_iw): Declare.
6960 (strcmp_iw): Move describing comments here.
6962 2017-07-17 Pedro Alves <palves@redhat.com>
6964 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
6966 * c-typeprint.c (is_type_conversion_operator): Use
6968 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
6969 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
6971 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
6972 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
6973 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
6974 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
6976 * location.c: Include "cp-support.h".
6977 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
6979 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
6982 2017-07-17 Pedro Alves <palves@redhat.com>
6984 * cli/cli-cmds.c (complete_command): Use a completion tracker
6985 along with completion_find_completion_word for handle_brkchars
6987 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
6988 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
6989 (struct gdb_rl_completion_word_info): New.
6990 (gdb_rl_find_completion_word): New.
6991 (completion_find_completion_word): New.
6992 * completer.h (completion_find_completion_word): Declare.
6994 2017-07-17 Pedro Alves <palves@redhat.com>
6996 * ada-lang.c (symbol_completion_match): Adjust comments.
6997 (symbol_completion_add): Replace vector parameter with
6998 completion_tracker parameter. Use it.
6999 (ada_make_symbol_completion_list): Rename to...
7000 (ada_collect_symbol_completion_matches): ... this. Add
7001 completion_tracker parameter and use it.
7002 (ada_language_defn): Adjust.
7003 * break-catch-syscall.c (catch_syscall_completer): Adjust
7004 prototype and work with completion_tracker instead of VEC.
7005 * breakpoint.c (condition_completer): Adjust prototype and work
7006 with completion_tracker instead of VEC.
7007 * c-lang.c (c_language_defn, cplus_language_defn)
7008 (asm_language_defn, minimal_language_defn): Adjust to renames.
7009 * cli/cli-cmds.c (complete_command): Rework using
7010 completion_tracker. Catch exceptions when completing.
7011 * cli/cli-decode.c (integer_unlimited_completer)
7012 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
7013 with completion_tracker instead of VEC.
7014 * command.h (struct completion_tracker): Forward declare.
7015 (completer_ftype, completer_handle_brkchars_ftype): Change
7017 (complete_on_cmdlist, complete_on_enum): Adjust.
7018 * completer.c: Include <algorithm>.
7019 (struct gdb_completer_state): New.
7020 (current_completion): New global.
7021 (readline_line_completion_function): Delete.
7022 (noop_completer, filename_completer)
7023 (filename_completer_handle_brkchars, complete_files_symbols)
7024 (linespec_location_completer): Adjust to work with a
7025 completion_tracker instead of a VEC.
7026 (string_or_empty): New.
7027 (collect_explicit_location_matches): Adjust to work with a
7028 completion_tracker instead of a VEC.
7029 (explicit_location_completer): Rename to ...
7030 (complete_explicit_location): ... this and adjust to work with a
7031 completion_tracker instead of a VEC.
7032 (location_completer): Adjust to work with a completion_tracker
7034 (add_struct_fields): Adjust to work with a completion_list instead
7036 (expression_completer): Rename to ...
7037 (complete_expression): ... this and adjust to work with a
7038 completion_tracker instead of a VEC. Use complete_files_symbols.
7039 (expression_completer): Reimplement on top of complete_expression.
7040 (symbol_completer): Adjust to work with a completion_tracker
7042 (enum complete_line_internal_reason): Add describing comments.
7043 (complete_line_internal_normal_command): Adjust to work with a
7044 completion_tracker instead of a VEC.
7045 (complete_line_internal): Rename to ...
7046 (complete_line_internal_1): ... this and adjust to work with a
7047 completion_tracker instead of a VEC. Assert TEXT is NULL in the
7048 handle_brkchars phase.
7049 (new_completion_tracker): Delete.
7050 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
7051 complete_line_internal_1.
7052 (free_completion_tracker): Delete.
7053 (INITIAL_COMPLETION_HTAB_SIZE): New.
7054 (completion_tracker::completion_tracker)
7055 (completion_tracker::~completion_tracker): New.
7056 (maybe_add_completion): Delete.
7057 (completion_tracker::maybe_add_completion)
7058 (completion_tracker::add_completion)
7059 (completion_tracker::add_completions): New.
7060 (throw_max_completions_reached_error): Delete.
7061 (complete_line): Adjust to work with a completion_tracker instead
7062 of a VEC. Don't create a completion_tracker_t or check for max
7064 (command_completer, command_completer_handle_brkchars)
7065 (signal_completer, reg_or_group_completer_1)
7066 (reg_or_group_completer, default_completer_handle_brkchars):
7067 Adjust to work with a completion_tracker.
7068 (gdb_completion_word_break_characters_throw): New.
7069 (gdb_completion_word_break_characters): Reimplement.
7070 (line_completion_function): Delete.
7071 (completion_tracker::recompute_lowest_common_denominator)
7072 (expand_preserving_ws)
7073 (completion_tracker::build_completion_result)
7074 (completion_result::completion_result)
7075 (completion_result::completion_result)
7076 (completion_result::~completion_result)
7077 (completion_result::completion_result)
7078 (completion_result::release_match_list, compare_cstrings)
7079 (completion_result::sort_match_list)
7080 (completion_result::reset_match_list)
7081 (gdb_rl_attempted_completion_function_throw)
7082 (gdb_rl_attempted_completion_function): New.
7083 * completer.h (completion_list, struct completion_result)
7084 (class completion_tracker): New.
7085 (complete_line): Add completion_tracker parameter.
7086 (readline_line_completion_function): Delete.
7087 (gdb_rl_attempted_completion_function): New.
7088 (noop_completer, filename_completer, expression_completer)
7089 (location_completer, symbol_completer, command_completer)
7090 (signal_completer, reg_or_group_completer): Update prototypes.
7091 (completion_tracker_t, new_completion_tracker)
7092 (make_cleanup_free_completion_tracker): Delete.
7093 (enum maybe_add_completion_enum): Delete.
7094 (maybe_add_completion): Delete.
7095 (throw_max_completions_reached_error): Delete.
7096 * corefile.c (complete_set_gnutarget): Adjust to work with a
7097 completion_tracker instead of a VEC.
7098 * cp-abi.c (cp_abi_completer): Adjust to work with a
7099 completion_tracker instead of a VEC.
7100 * d-lang.c (d_language_defn): Adjust.
7101 * disasm.c (disassembler_options_completer): Adjust to work with a
7102 completion_tracker instead of a VEC.
7103 * f-lang.c (f_make_symbol_completion_list): Rename to ...
7104 (f_collect_symbol_completion_matches): ... this. Adjust to work
7105 with a completion_tracker instead of a VEC.
7106 (f_language_defn): Adjust.
7107 * go-lang.c (go_language_defn): Adjust.
7108 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
7109 Adjust to work with a completion_tracker instead of a VEC.
7110 * infrun.c (handle_completer): Likewise.
7111 * interps.c (interpreter_completer): Likewise.
7112 * interps.h (interpreter_completer): Likewise.
7113 * language.c (unknown_language_defn, auto_language_defn)
7114 (local_language_defn): Adjust.
7115 * language.h (language_defn::la_make_symbol_completion_list):
7117 (language_defn::la_collect_symbol_completion_matches): ... this
7118 and adjust to work with a completion_tracker instead of a VEC.
7119 * m2-lang.c (m2_language_defn): Adjust.
7120 * objc-lang.c (objc_language_defn): Adjust.
7121 * opencl-lang.c (opencl_language_defn): Adjust.
7122 * p-lang.c (pascal_language_defn): Adjust.
7123 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
7124 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
7125 with a completion_tracker.
7126 * rust-lang.c (rust_language_defn): Adjust.
7127 * symtab.c (free_completion_list, do_free_completion_list)
7128 (return_val, completion_tracker): Delete.
7129 (completion_list_add_name, completion_list_add_symbol)
7130 (completion_list_add_msymbol, completion_list_objc_symbol)
7131 (completion_list_add_fields, add_symtab_completions): Add
7132 completion_tracker parameter and use it.
7133 (default_make_symbol_completion_list_break_on_1): Rename to...
7134 (default_collect_symbol_completion_matches_break_on): ... this.
7135 Add completion_tracker parameter and use it instead of allocating
7136 a completion tracker here.
7137 (default_make_symbol_completion_list_break_on): Delete old
7139 (default_make_symbol_completion_list): Delete.
7140 (default_collect_symbol_completion_matches): New.
7141 (make_symbol_completion_list): Delete.
7142 (collect_symbol_completion_matches): New.
7143 (make_symbol_completion_type): Rename to ...
7144 (collect_symbol_completion_matches_type): ... this. Add
7145 completion_tracker parameter and use it instead of VEC.
7146 (make_file_symbol_completion_list_1): Rename to...
7147 (collect_file_symbol_completion_matches): ... this. Add
7148 completion_tracker parameter and use it instead of VEC.
7149 (make_file_symbol_completion_list): Delete.
7150 (add_filename_to_list): Use completion_list instead of a VEC.
7151 (add_partial_filename_data::list): Now a completion_list.
7152 (make_source_files_completion_list): Work with a completion_list
7154 * symtab.h: Include "completer.h".
7155 (default_make_symbol_completion_list_break_on)
7156 (default_make_symbol_completion_list, make_symbol_completion_list)
7157 (make_symbol_completion_type, make_file_symbol_completion_list)
7158 (make_source_files_completion_list): Delete.
7159 (default_collect_symbol_completion_matches_break_on)
7160 (default_collect_symbol_completion_matches)
7161 (collect_symbol_completion_matches)
7162 (collect_symbol_completion_matches_type)
7163 (collect_file_symbol_completion_matches)
7164 (make_source_files_completion_list): New.
7165 * top.c (init_main): Don't install a rl_completion_entry_function
7166 hook. Install a rl_attempted_completion_function hook instead.
7167 * tui/tui-layout.c (layout_completer): Adjust to work with a
7169 * tui/tui-regs.c (tui_reggroup_completer):
7170 * tui/tui-win.c (window_name_completer, focus_completer)
7171 (winheight_completer): Adjust to work with a completion_tracker.
7172 * value.c: Include "completer.h".
7173 (complete_internalvar): Adjust to work with a completion_tracker.
7174 * value.h (complete_internalvar): Likewise.
7176 2017-07-17 Pedro Alves <palves@redhat.com>
7178 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
7180 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
7181 comments to completer_ftype's declaration.
7182 <completer_handle_brkchars>: Change type to
7183 completer_handle_brkchars_ftype.
7184 * command.h (completer_ftype): Add describing comment and give
7185 names to parameters.
7186 (completer_ftype_void): Rename to ...
7187 (completer_handle_brkchars_ftype) ... this. Add describing comment.
7188 (set_cmd_completer_handle_brkchars): Adjust.
7189 * completer.c (filename_completer_handle_brkchars): New function.
7190 (complete_line_internal_normal_command): New function, factored
7192 (complete_line_internal): ... here.
7193 (command_completer_handle_brkchars)
7194 (default_completer_handle_brkchars)
7195 (completer_handle_brkchars_func_for_completer): New functions.
7196 * completer.h (set_gdb_completion_word_break_characters): Delete
7198 (completer_handle_brkchars_func_for_completer): New declaration.
7199 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
7200 completer_handle_brkchars_func_for_completer.
7202 2017-07-17 Pedro Alves <palves@redhat.com>
7204 * completer.c (symbol_completer): New function, based on
7205 make_symbol_completion_list_fn.
7206 * completer.h (symbol_completer): New declaration.
7207 * guile/scm-cmd.c (cmdscm_completers): Adjust.
7208 * python/py-cmd.c (completers): Adjust.
7209 * symtab.c (make_symbol_completion_list_fn): Delete.
7210 * symtab.h (make_symbol_completion_list_fn): Delete.
7211 * cli/cli-decode.c (add_cmd): Adjust.
7213 2017-07-17 Pedro Alves <palves@redhat.com>
7215 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
7216 * dwarf2read.c: Include "filename-seen-cache.h".
7217 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
7218 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
7219 * filename-seen-cache.c: New file.
7220 * filename-seen-cache.h: New file.
7221 * symtab.c: Include "filename-seen-cache.h".
7222 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
7223 (create_filename_seen_cache, clear_filename_seen_cache)
7224 (delete_filename_seen_cache, filename_seen): Delete, parts moved
7225 to filename-seen-cache.h/filename-seen-cache.c.
7226 (output_source_filename, sources_info)
7227 (maybe_add_partial_symtab_filename)
7228 (make_source_files_completion_list): Adjust to use
7229 filename_seen_cache.
7231 2017-07-17 Pedro Alves <palves@redhat.com>
7233 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
7235 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
7236 dwarf2_debug_sections*)): New.
7237 (dwarf2_per_objfile::dwarf2_per_objfile(const
7238 dwarf2_per_objfile&)): Declare as deleted.
7239 (dwarf2_per_objfile::operator=): Declare as deleted.
7240 (dwarf2_per_objfile::dwarf2_per_objfile)
7241 (dwarf2_per_objfile::~dwarf2_per_objfile)
7242 (dwarf2_per_objfile::free_cached_comp_units): New.
7243 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
7244 ctor. Call dwarf2_per_objfile's ctor manually.
7245 (dwarf2_locate_sections): Deleted/refactored as ...
7246 (dwarf2_per_objfile::locate_sections): ... this new method.
7247 (free_cached_comp_units): Defer to
7248 dwarf2_per_objfile::free_cached_comp_units.
7249 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
7251 2017-07-14 Tom Tromey <tom@tromey.com>
7254 * rust-exp.y (convert_ast_to_expression): Add "want_type"
7256 <UNOP_SIZEOF>: Split into separate case.
7257 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
7259 2017-07-14 Tom Tromey <tom@tromey.com>
7262 * symtab.c (symbol_matches_domain): Add language_rust to special
7264 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
7265 treat LOC_TYPEDEF symbols as variables.
7267 2017-07-14 Pedro Alves <palves@redhat.com>
7269 * symtab.c (make_file_symbol_completion_list_1): Iterate over
7270 symtabs matching all symtabs with SRCFILE as file name instead of
7271 only considering the first hit, with lookup_symtab.
7273 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
7275 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
7276 operator_name parameters.
7277 (gen_expr): Update function call.
7279 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
7281 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
7283 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
7285 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
7286 parameter, use agent_expr::gdbarch instead, update function
7288 (locexpr_tracepoint_var_ref): Likewise.
7289 (loclist_tracepoint_var_ref): Likewise.
7290 * ax-gdb.c (gen_trace_static_fields): Likewise.
7291 (gen_traced_pop): Likewise.
7292 (gen_frame_args_address): Likewise.
7293 (gen_frame_locals_address): Likewise.
7294 (gen_var_ref): Likewise.
7295 (gen_struct_ref_recursive): Likewise.
7296 (gen_static_field): Likewise.
7297 (gen_maybe_namespace_elt): Likewise.
7298 (gen_expr): Likewise.
7299 (gen_trace_for_var): Likewise.
7300 (gen_trace_for_expr): Likewise.
7301 (gen_trace_for_return_address): Likewise.
7303 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
7305 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
7307 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
7309 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
7311 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
7312 from ax, update calls.
7313 (gen_usual_arithmetic): Likewise.
7314 (gen_integral_promotions): Likewise.
7315 (gen_bitfield_ref): Likewise.
7316 (gen_primitive_field): Likewise.
7317 (gen_struct_ref_recursive): Likewise.
7318 (gen_struct_ref): Likewise.
7319 (gen_maybe_namespace_elt): Likewise.
7320 (gen_struct_elt_for_reference): Likewise.
7321 (gen_namespace_elt): Likewise.
7322 (gen_aggregate_elt_ref): Likewise.
7323 (gen_expr): Get gdbarch from ax, update calls.
7324 (gen_expr_binop_rest): Likewise.
7326 2017-07-13 Pedro Alves <palves@redhat.com>
7328 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
7330 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
7331 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
7332 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
7333 tdesc_amd64_linux as default tdesc. Get final tdesc from the
7335 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
7336 Get final tdesc from the tdep.
7337 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
7339 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
7340 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
7341 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
7342 Use it as default tdesc.
7343 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
7344 down to amd_init_abi. No longer handle fallback tdesc here.
7345 * amd64-tdep.h (tdesc_x32): Declare.
7346 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
7348 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
7351 2017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7353 * s390-linux-tdep.c (s390_process_record): Add support for
7354 instructions new in arch12.
7356 2017-07-11 John Baldwin <jhb@FreeBSD.org>
7358 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
7359 PT_GETFSBASE and PT_GETGSBASE.
7360 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
7363 2017-07-11 John Baldwin <jhb@FreeBSD.org>
7365 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
7366 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
7367 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
7369 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
7370 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
7371 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
7372 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
7373 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
7374 * features/i386/amd64.xml: Add 64bit-segments.xml.
7375 * features/i386/amd64-avx-avx512.c: Regenerated.
7376 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
7377 * features/i386/amd64-avx-mpx.c: Regenerated.
7378 * features/i386/amd64-avx.c: Regenerated.
7379 * features/i386/amd64-mpx.c: Regenerated.
7380 * features/i386/amd64.c: Regenerated.
7381 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
7382 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
7383 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
7384 * regformats/i386/amd64-avx.dat: Regenerated.
7385 * regformats/i386/amd64-mpx.dat: Regenerated.
7386 * regformats/i386/amd64.dat: Regenerated.
7388 2017-07-10 Yao Qi <yao.qi@linaro.org>
7390 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
7391 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
7393 2017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
7395 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
7397 * gnulib/aclocal.m4: Regenerate.
7398 * gnulib/config.in: Regenerate.
7399 * gnulib/configure: Regenerate.
7400 * gnulib/import/Makefile.am: Regenerate.
7401 * gnulib/import/Makefile.in: Regenerate.
7402 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
7403 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
7404 * gnulib/import/m4/environ.m4: New file.
7405 * gnulib/import/m4/setenv.m4: New file.
7406 * gnulib/import/setenv.c: New file.
7407 * gnulib/import/unsetenv.c: New file.
7409 2017-07-09 Simon Marchi <simon.marchi@ericsson.com>
7411 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
7412 address when op is DW_OP_addr.
7414 2017-07-09 Tom Tromey <tom@tromey.com>
7416 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
7417 check and apply to outer type.
7419 2017-07-07 John Baldwin <jhb@FreeBSD.org>
7421 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
7422 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
7423 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
7424 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
7426 2017-07-07 John Baldwin <jhb@FreeBSD.org>
7428 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
7430 2017-07-07 John Baldwin <jhb@FreeBSD.org>
7432 * corelow.c (get_core_siginfo): Remove.
7433 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
7434 instead of get_core_siginfo.
7435 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
7436 * gdbarch.h: Re-generate.
7437 * gdbarch.c: Re-generate.
7438 * linux-tdep.c (linux_core_xfer_siginfo): New.
7439 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
7441 2017-07-07 John Baldwin <jhb@FreeBSD.org>
7443 * corelow.c (thread_section_name): Move to ...
7444 * gdbcore.h (thread_section_name): ... here.
7446 2017-07-07 John Baldwin <jhb@FreeBSD.org>
7448 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
7449 (struct siginfo32): New.
7450 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
7451 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
7452 via ptrace(PT_LWPINFO).
7454 2017-07-07 John Baldwin <jhb@FreeBSD.org>
7456 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
7457 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
7458 (fbsd_get_siginfo_type): New.
7459 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
7460 (_initialize_fbsd_tdep): New.
7462 2017-07-06 David Blaikie <dblaikie@gmail.com>
7464 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
7465 a singular dwo_unit*) to support multiple CUs in the same way that
7466 multiple TUs are supported.
7467 (create_cus_hash_table): Replace create_dwo_cu with a function for
7468 parsing multiple CUs from a DWO file.
7469 (open_and_init_dwo_file): Use create_cus_hash_table rather than
7471 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
7472 htab_find, rather than comparing the signature to a singleton CU in
7475 2017-07-06 Pedro Alves <palves@redhat.com>
7477 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
7479 2017-07-04 Pedro Alves <palves@redhat.com>
7481 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
7482 * gdbtypes.h (TYPE_STATIC): Delete.
7483 (struct fn_field) <is_public, is_abstract, is_static, is_final,
7484 is_synchronized, is_native>: Delete.
7486 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
7487 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
7488 (TYPE_FN_FIELD_ABSTRACT): Delete.
7490 2017-07-03 Simon Marchi <simon.marchi@ericsson.com>
7492 * buffer.h (buffer_finish): Fix spelling mistakes.
7494 2017-07-01 Eli Zaretskii <eliz@gnu.org>
7496 * .dir-locals.el: Automatically switch to C-style comments in
7497 versions of Emacs that support the feature.
7499 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
7500 Pedro Alves <palves@redhat.com>
7503 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
7504 (process_next_line): New variable 'inline_cmd'.
7505 Adjust 'if' clauses for "python", "compile" and "guile" to use
7506 'command_name_equals' and check for '!inline_cmd'.
7508 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
7511 * cli/cli-script.c (command_name_equals_not_inline): New function.
7512 (process_next_line): Adjust 'if' clauses for "python", "compile"
7513 and "guile" to use command_name_equals_not_inline.
7515 2017-06-29 Pedro Alves <palves@redhat.com>
7517 * completer.c (expression_completer): Call
7518 linespec_location_completer instead of location_completer.
7520 2017-06-29 Pedro Alves <palves@redhat.com>
7522 * completer.c (expression_completer): Remove code that recomputes
7525 2017-06-29 Yao Qi <yao.qi@linaro.org>
7527 * regformats/regdat.sh: Generate code with
7528 "ifndef IN_PROCESS_AGENT".
7530 2017-06-28 Pedro Alves <palves@redhat.com>
7532 * command.h: Include "common/scoped_restore.h".
7534 2017-06-28 Yao Qi <yao.qi@linaro.org>
7536 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
7537 instead of obstack_grow.
7539 2017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
7542 * symfile.c (reread_symbols): Call objfiles_changed just before
7545 2017-06-27 Pedro Alves <palves@redhat.com>
7547 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
7548 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
7549 (completion_list_add_symbol, completion_list_add_msymbol):
7550 ... these new functions.
7551 (add_symtab_completions)
7552 (default_make_symbol_completion_list_break_on_1): Adjust.
7554 2017-06-27 Pedro Alves <palves@redhat.com>
7556 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
7557 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
7558 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
7560 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
7561 'storage_obstack' field an auto_obstack. In-class initialize all
7562 non-bitfield fields. Make minsyms_read bool.
7563 * symfile.c (read_symbols): Adjust.
7565 2017-06-27 Alan Hayward <alan.hayward@arm.com>
7567 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
7568 (gdbsim_store_register): Likewise.
7570 2017-06-27 Pedro Alves <palves@redhat.com>
7572 * c-exp.y (name_obstack): Now an auto_obstack.
7573 (yylex): Use auto_obstack::clear.
7574 (c_parse): Use auto_obstack::clear instead of reinitializing and
7575 freeing the obstack.
7576 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
7577 * d-exp.y (name_obstack): Now an auto_obstack.
7578 (yylex): Use auto_obstack::clear.
7579 (d_parse): Use auto_obstack::clear instead of reinitializing and
7580 freeing the obstack.
7581 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
7583 * dwarf2read.c (create_addrmap_from_index)
7584 (dwarf2_build_psymtabs_hard)
7585 (update_enumeration_type_from_children): Likewise.
7586 * gdb_obstack.h (auto_obstack): New type.
7587 * go-exp.y (name_obstack): Now an auto_obstack.
7588 (build_packaged_name): Use auto_obstack::clear.
7589 (go_parse): Use auto_obstack::clear instead of reinitializing and
7590 freeing the obstack.
7591 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
7593 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
7594 * rust-exp.y (work_obstack): Now an auto_obstack.
7595 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
7596 reinitializing and freeing the obstack.
7597 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
7598 (host_char_to_target): Use auto_obstack.
7599 * utils.h (make_cleanup_obstack_free): Delete declaration.
7600 * valprint.c (generic_emit_char, generic_printstr): Use
7603 2017-06-27 Simon Marchi <simon.marchi@ericsson.com>
7605 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
7607 (darwin_init_thread_list): Don't update dummy thread.
7608 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
7610 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
7612 * record-full.c (netorder16): Remove.
7614 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
7616 * common/diagnostics.h: Define macros for GCC.
7617 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
7618 * common/vec.h: Include diagnostics.h.
7619 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
7620 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
7623 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
7625 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
7627 * ada-lex.l: Ignore deprecated register warnings.
7629 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
7631 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
7632 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
7634 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
7636 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
7639 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
7641 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
7643 2017-06-23 Alan Hayward <alan.hayward@arm.com>
7645 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
7646 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
7647 (xtensa_register_read_masked): Likewise.
7649 2017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
7651 * common/environ.c (gdb_environ::unset): Update comment.
7653 2017-06-22 Alan Hayward <alan.hayward@arm.com>
7655 * python/py-unwind.c (pyuw_sniffer): Allocate space for
7658 2017-06-22 Alan Hayward <alan.hayward@arm.com>
7660 * record-full.c (record_full_exec_insn): Use byte_vector.
7662 2017-06-22 Yao Qi <yao.qi@linaro.org>
7664 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
7665 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
7667 2017-06-22 Alan Hayward <alan.hayward@arm.com>
7669 * remote.c (cached_reg): Move from here...
7670 * regcache.h (cached_reg): ...to here.
7671 * python/py-unwind.c (struct reg_info): Remove.
7672 (cached_frame_info): Use cached_reg_t.
7673 (pyuw_prev_register): Likewise.
7674 (pyuw_sniffer): Use cached_reg_t and allocate registers.
7675 (pyuw_dealloc_cache): Free all registers.
7677 2017-06-22 Pedro Alves <palves@redhat.com>
7678 Simon Marchi <simon.marchi@ericsson.com>
7680 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
7682 * common/diagnostics.h: New file.
7684 2017-06-22 Pedro Alves <palves@redhat.com>
7686 * common/agent.h: Add include guards.
7688 2017-06-21 Simon Marchi <simon.marchi@ericsson.com>
7690 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
7691 talk about addressable units instead of bytes.
7693 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
7695 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
7696 of '::const_iterator'.
7698 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
7700 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7701 'unittests/environ-selftests.c'.
7702 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
7703 * charset.c (find_charset_names): Declare object 'iconv_env'.
7704 Update code to use 'iconv_env' object. Remove call to
7706 * common/environ.c: Include <utility>.
7707 (make_environ): Delete function.
7708 (free_environ): Delete function.
7709 (gdb_environ::clear): New function.
7710 (gdb_environ::operator=): New function.
7711 (gdb_environ::get): Likewise.
7712 (environ_vector): Delete function.
7713 (set_in_environ): Delete function.
7714 (gdb_environ::set): New function.
7715 (unset_in_environ): Delete function.
7716 (gdb_environ::unset): New function.
7717 (gdb_environ::envp): Likewise.
7718 * common/environ.h: Include <vector>.
7719 (struct gdb_environ): Delete; transform into...
7720 (class gdb_environ): ... this class.
7721 (free_environ): Delete prototype.
7722 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
7723 environ_vector): Likewise.
7724 * infcmd.c (run_command_1): Update code to call
7725 'envp' from 'gdb_environ' class.
7726 (environment_info): Update code to call methods from 'gdb_environ'
7728 (unset_environment_command): Likewise.
7729 (path_info): Likewise.
7730 (path_command): Likewise.
7731 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
7732 (inferior::inferior): Initialize 'environment' using the host's
7734 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
7735 Include "environ.h".
7736 (class inferior) <environment>: Change type from 'struct
7737 gdb_environ' to 'gdb_environ'.
7738 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
7739 methods from 'gdb_environ' class.
7740 * solib.c (solib_find_1): Likewise
7741 * unittests/environ-selftests.c: New file.
7743 2017-06-20 Yao Qi <yao.qi@linaro.org>
7745 * features/i386/i386-linux.xml: Exchange the order of including
7746 32bit-linux.xml and 32bit-sse.xml.
7747 * features/i386/i386-linux.c: Regenerated.
7749 2017-06-20 Yao Qi <yao.qi@linaro.org>
7751 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
7752 Delete copy ctor and assignment operator.
7753 (tdesc_type): Likewise.
7754 (tdesc_feature): Likewise.
7755 (tdesc_free_reg): Remove.
7756 (tdesc_create_reg): Use new.
7757 (tdesc_free_type): Remove.
7758 (tdesc_create_vector): Use new.
7759 (tdesc_create_union): Likewise.
7760 (tdesc_create_flags): Likewise.
7761 (tdesc_create_enum): Likewise.
7762 (tdesc_free_feature): Delete.
7763 (free_target_description): Use delete.
7765 2017-06-19 John Baldwin <jhb@FreeBSD.org>
7767 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
7770 2017-06-19 Pedro Alves <palves@redhat.com>
7772 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
7773 after gdb::unlinker.
7775 2017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
7777 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
7778 gdb_environ to access an environment variable.
7780 2017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
7782 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
7785 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7787 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
7789 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7791 * configure: Re-generate.
7792 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
7794 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7796 * configure: Re-generate.
7797 * warning.m4: Pass -Werror to compiler when checking for
7798 supported warning flags.
7800 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7802 * Makefile.in (COMPILE.pre): Add "-x c++".
7804 2017-06-16 Alan Hayward <alan.hayward@arm.com>
7805 Pedro Alves <palves@redhat.com>
7806 Yao Qi <yao.qi@linaro.org>
7808 * defs.h (RequireLongest): New.
7809 (extract_integer): Declare function template.
7810 (extract_signed_integer): Remove the declaration, but define it
7812 (extract_unsigned_integer): Likewise.
7813 (store_integer): Declare function template.
7814 (store_signed_integer): Remove the declaration, but define it
7816 (store_unsigned_integer): Likewise.
7817 * findvar.c (extract_integer): New function template.
7818 (extract_signed_integer): Remove.
7819 (extract_unsigned_integer): Remove.
7820 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
7822 (store_integer): New function template.
7823 (store_signed_integer): Remove.
7824 (store_unsigned_integer): Remove.
7825 (store_integer): Explicit instantiations.
7826 * regcache.c (regcache_raw_read_signed): Update.
7827 (regcache::raw_read): New function.
7828 (regcache::raw_read_signed): Remove.
7829 (regcache::raw_read_unsigned): Remove.
7830 (regcache_raw_read_unsigned): Update.
7831 (regcache_raw_write_unsigned): Update.
7832 (regcache::raw_write_signed): Remove.
7833 (regcache::raw_write): New function.
7834 (regcache_cooked_read_signed): Update.
7835 (regcache::raw_write_unsigned): Remove.
7836 (regcache::cooked_read_signed): Remove.
7837 (regcache_cooked_read_unsigned): Update.
7838 (regcache::cooked_read_unsigned): Remove.
7839 (regcache_cooked_write_signed): Update.
7840 (regcache_cooked_write_unsigned): Update.
7841 * regcache.h (regcache) <raw_read_signed>: Remove.
7842 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
7843 <raw_read, raw_write>: New.
7844 <cooked_read_signed, cooked_write_signed>: Remove.
7845 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
7846 <cooked_read, cooked_write>: New.
7847 * sh64-tdep.c (sh64_pseudo_register_read): Update.
7848 (sh64_pseudo_register_write): Update.
7850 2017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
7852 * arc-tdep.c (arc_disassembler_options): New variable.
7853 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
7854 of default_print_insn.
7855 (arc_delayed_print_insn): Set info->section when needed,
7856 use default_print_insn to retrieve a disassembler.
7858 2017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
7861 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
7862 to mention $SHELL and startup-with-shell.
7864 2017-06-14 Max Filippov <jcmvbkbc@gmail.com>
7866 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
7868 2017-06-14 Yao Qi <yao.qi@linaro.org>
7870 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
7871 default_print_insn instead of print_insn_aarch64.
7872 * arm-tdep.c (gdb_print_insn_arm): Call
7873 default_print_insn instead of print_insn_big_arm
7874 and print_insn_little_arm.
7875 * i386-tdep.c (i386_print_insn): Call default_print_insn
7876 instead of print_insn_i386.
7877 * ia64-tdep.c (ia64_print_insn): Call
7878 default_print_insn instead of print_insn_ia64.
7879 * mips-tdep.c (gdb_print_insn_mips): Call
7880 default_print_insn instead of print_insn_big_mips
7881 and print_insn_little_mips.
7882 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
7883 instead of print_insn_spu.
7885 2017-06-14 Pedro Alves <palves@redhat.com>
7887 * ada-lang.c: Include "common/byte-vector.h".
7888 (ada_value_primitive_packed_val): Use gdb::byte_vector.
7889 * charset.c (wchar_iterator::iterate): Resize the vector instead
7891 * common/byte-vector.h: Include "common/def-vector.h".
7892 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
7893 * cli/cli-dump.c: Include "common/byte-vector.h".
7894 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
7895 * common/byte-vector.h: New file.
7896 * common/def-vector.h: New file.
7897 * common/default-init-alloc.h: New file.
7898 * dwarf2loc.c: Include "common/byte-vector.h".
7899 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
7900 instead of reserving it.
7901 * dwarf2read.c: Include "common/byte-vector.h".
7902 (data_buf::m_vec): Now a gdb::byte_vector.
7903 * gdb_regex.c: Include "common/def-vector.h".
7904 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
7905 * mi/mi-main.c: Include "common/byte-vector.h".
7906 (mi_cmd_data_read_memory): Use gdb::byte_vector.
7907 * printcmd.c: Include "common/byte-vector.h".
7908 (print_scalar_formatted): Use gdb::byte_vector.
7909 * valprint.c: Include "common/byte-vector.h".
7910 (maybe_negate_by_bytes, print_decimal_chars): Use
7913 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
7915 * darwin-nat.c: Include "nat/fork-inferior.h".
7917 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
7919 * configure.nat: Factor out Darwin bits that are not
7920 architecture-specific. Add fork-inferior.o.
7922 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
7924 * configure.nat: Factor out AIX bits that are not
7925 architecture-specific. Add fork-inferior.o.
7927 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7929 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
7930 (read_pieced_value, write_pieced_value): ...here. Reduce to
7931 wrappers that just call rw_pieced_value.
7933 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7935 * dwarf2loc.c (write_pieced_value): When writing the data for a
7936 memory piece, use write_memory_with_notification instead of
7939 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7941 * valops.c (read_value_memory): Change embedded_offset to
7942 represent a bit offset instead of a byte offset.
7943 * value.h (read_value_memory): Adjust comment.
7945 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7947 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
7948 dest_offset_bits and source_offset_bits.
7949 (write_pieced_value): Likewise.
7951 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7953 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
7954 given by DW_OP_bit_piece.
7955 (write_pieced_value): Likewise.
7957 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7959 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
7960 some other preparations to the places where sufficient information
7962 (write_pieced_value): Likewise.
7964 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7966 * dwarf2loc.c (bits_to_bytes): New function.
7967 (read_pieced_value): Fix offset calculations for register pieces
7968 on big-endian targets.
7969 (write_pieced_value): Likewise.
7971 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7973 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
7974 (write_pieced_value): Likewise.
7976 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7978 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
7979 transfer the source value's least significant bits, instead of its
7980 lowest-addressed ones. Rename type_len to max_offset.
7981 (read_pieced_value): Mirror above changes to write_pieced_value as
7984 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7986 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
7987 truncate full bytes from dest_offset_bits before using it as an
7988 offset into the buffer.
7990 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7992 * dwarf2loc.c (write_pieced_value): Include transfer size in
7995 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7997 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
7998 calculation of this_size.
8000 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
8002 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
8003 when targeting a bit-field.
8004 (write_pieced_value): Likewise.
8006 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
8008 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
8009 (allocate_piece_closure): Drop addr_size parameter.
8010 (dwarf2_evaluate_loc_desc_full): Adjust call to
8011 allocate_piece_closure.
8013 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
8016 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
8017 the LSB end, independent of endianness.
8019 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
8021 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
8024 2017-06-13 Yao Qi <yao.qi@linaro.org>
8026 * mips-linux-nat.c: Move include features/mips*-linux.c to
8028 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
8029 to mips-linux-tdep.c.
8030 * mips-linux-tdep.c: Include features/mips*-linux.c
8031 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
8033 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
8034 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
8035 (tdesc_mips64_dsp_linux): Declare.
8037 2017-06-12 Tom Tromey <tom@tromey.com>
8039 * valprint.h (val_print_type_code_int): Remove.
8040 * valprint.c (generic_val_print_int): Always call
8041 val_print_scalar_formatted.
8042 (val_print_type_code_int): Remove.
8043 * printcmd.c (print_scalar_formatted): Handle options->format==0.
8044 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
8045 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
8046 * ada-valprint.c (ada_val_print_num): Use
8047 val_print_scalar_formatted.
8049 2017-06-12 Tom Tromey <tom@tromey.com>
8051 * printcmd.c (print_scalar_formatted): Unify the two switches.
8052 Don't convert scalars to LONGEST.
8054 2017-06-12 Tom Tromey <tom@tromey.com>
8057 * valprint.h (print_decimal_chars): Update.
8058 * valprint.c (maybe_negate_by_bytes): New function.
8059 (print_decimal_chars): Add "is_signed" argument.
8060 * printcmd.c (print_scalar_formatted): Update.
8062 2017-06-12 Tom Tromey <tom@tromey.com>
8065 * valprint.h (print_binary_chars, print_hex_chars): Update.
8066 * valprint.c (val_print_type_code_int): Update.
8067 (print_binary_chars): Add "zero_pad" argument.
8068 (emit_octal_digit): New function.
8069 (print_octal_chars): Don't zero-pad.
8070 (print_decimal_chars): Likewise.
8071 (print_hex_chars): Add "zero_pad" argument.
8072 * sh64-tdep.c (sh64_do_fp_register): Update.
8073 * regcache.c (regcache::dump): Update.
8074 * printcmd.c (print_scalar_formatted): Update.
8075 * infcmd.c (default_print_one_register_info): Update.
8077 2017-06-12 Pedro Alves <palves@redhat.com>
8078 Alan Hayward <alan.hayward@arm.com>
8080 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
8081 (mips_eabi_push_dummy_call): Rename local 'regsize' to
8082 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
8083 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
8084 Assert that abi_regsize bytes fit in 'ref_valbuf'.
8086 2017-06-12 Pedro Alves <palves@redhat.com>
8088 * dwarf2read.c (mapped_symtab::data): Now a vector of
8089 symtab_index_entry instead of vector of
8090 std::unique_ptr<symtab_index_entry>. All users adjusted to check
8091 whether an element's name is NULL instead of checking whether the
8092 element itself is NULL.
8093 (find_slot): Change return type. Adjust.
8094 (hash_expand, , add_index_entry, uniquify_cu_indices)
8095 (write_hash_table): Adjust.
8097 2017-06-12 Pedro Alves <palves@redhat.com>
8099 * dwarf2read.c (recursively_count_psymbols): New function.
8100 (write_psymtabs_to_index): Call it to compute number of psyms and
8101 pass estimate size of psyms_seen to unordered_set's ctor.
8103 2017-06-12 Pedro Alves <palves@redhat.com>
8105 * dwarf2read.c (write_hash_table): Check if key already exists
8108 2017-06-12 Pedro Alves <palves@redhat.com>
8110 * dwarf2read.c (data_buf::append_space): Rename to...
8111 (data_buf::grow): ... this, and make private. Adjust all callers.
8112 (data_buf::append_uint): New method.
8113 (add_address_entry, write_one_signatured_type)
8114 (write_psymtabs_to_index): Use it.
8116 2017-06-12 Pedro Alves <palves@redhat.com>
8118 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
8119 (file_write (FILE *, const std::vector<Elem>&)): Delete.
8120 (data_buf::file_write): Call ::fwrite directly.
8122 2017-06-12 Pedro Alves <palves@redhat.com>
8124 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
8127 2017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
8129 Code cleanup: C++ify .gdb_index producer.
8130 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
8131 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
8132 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
8133 (create_strtab, add_string): Remove.
8134 (file_write, data_buf): New.
8135 (struct symtab_index_entry): Use std::vector for cu_indices.
8136 (struct mapped_symtab): Use std::vector for data.
8137 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
8138 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
8140 (find_slot): Change return type. Update it to the new data structures.
8141 (hash_expand, add_index_entry): Update it to the new data structures.
8142 (offset_type_compare): Remove.
8143 (uniquify_cu_indices): Update it to the new data structures.
8144 (c_str_view, c_str_view_hasher, vector_hasher): New.
8145 (add_indices_to_cpool): Remove.
8146 (write_hash_table): Update it to the new data structures.
8147 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
8148 (eq_psymtab_cu_index): Remove.
8149 (psym_index_map): New typedef.
8150 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
8151 reference and std::unordered_map for cu_index_htab.
8152 (add_address_entry, add_address_entry_worker, write_address_map)
8153 (write_psymbols): Update it to the new data structures.
8154 (write_obstack): Remove.
8155 (struct signatured_type_index_data): Change types_list to a data_buf
8156 reference and psyms_seen to a std::unordered_set reference.
8157 (write_one_signatured_type, recursively_write_psymbols)
8158 (write_psymtabs_to_index): Update it to the new data structures.
8160 2017-06-11 Simon Marchi <simon.marchi@ericsson.com>
8162 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
8163 separate-debug-file commands.
8164 * symfile.h (separate_debug_file_debug): New global.
8165 * symfile.c (separate_debug_file_debug): New global.
8166 (separate_debug_file_exists, find_separate_debug_file): Add
8168 (_initialize_symfile): Add "set debug separate-debug-file"
8170 * build-id.c (build_id_to_debug_bfd,
8171 find_separate_debug_file_by_buildid): Add debug output.
8173 2017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
8175 * gdbarch.sh (displaced_step_free_closure): Remove.
8176 * gdbarch.h, gdbarch.c: Re-generate.
8177 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
8178 displaced_step_free_closure.
8179 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
8180 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
8181 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
8182 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
8183 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
8184 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
8185 * arch-utils.h (simple_displaced_step_free_closure): Remove.
8186 * arch-utils.c (simple_displaced_step_free_closure): Remove.
8187 * infrun.c (displaced_step_clear): Call xfree instead of
8188 gdbarch_displaced_step_free_closure.
8190 2017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
8192 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
8195 2017-06-08 Alan Hayward <alan.hayward@arm.com>
8197 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
8198 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
8199 (mn10300_push_dummy_call): Likewise.
8201 2017-06-08 Alan Hayward <alan.hayward@arm.com>
8203 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
8205 2017-06-08 Alan Hayward <alan.hayward@arm.com>
8207 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
8209 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
8211 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
8212 able to start inferiors using a shell.
8213 (New remote packets): Announce new packet "QStartupWithShell".
8214 * remote.c: Add PACKET_QStartupWithShell.
8215 (extended_remote_create_inferior): Handle new
8216 PACKET_QStartupWithShell.
8217 (remote_protocol_features) <QStartupWithShell>: New entry for
8218 PACKET_QStartupWithShell.
8219 (_initialize_remote): Call "add_packet_config_cmd" for
8222 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
8223 Pedro Alves <palves@redhat.com>
8225 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
8226 and "nat/fork-inferior.h".
8227 * common/common-inferior.h: New file, with contents from
8229 * commom/common-utils.c: Include "common-utils.h".
8230 (stringify_argv): New function.
8231 * common/common-utils.h (stringify_argv): New prototype.
8232 * configure.nat: Add "fork-inferior.o" as a dependency for
8233 "*linux*", "fbsd*" and "nbsd*" hosts.
8234 * corefile.c (get_exec_file): Update comment.
8235 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
8236 instead of "startup_inferior".
8237 (darwin_create_inferior): Call "add_thread_silent" after
8239 * fork-child.c: Cleanup unnecessary includes.
8240 (SHELL_FILE): Move to "common/common-fork-child.c".
8241 (environ): Likewise.
8242 (exec_wrapper): Initialize.
8243 (get_exec_wrapper): New function.
8244 (breakup_args): Move to "common/common-fork-child.c"; rename to
8245 "breakup_args_for_exec".
8246 (escape_bang_in_quoted_argument): Move to
8247 "common/common-fork-child.c".
8248 (saved_ui): New variable.
8249 (prefork_hook): New function.
8250 (postfork_hook): Likewise.
8251 (postfork_child_hook): Likewise.
8252 (gdb_startup_inferior): Likewise.
8253 (fork_inferior): Move to "common/common-fork-child.c". Update
8254 function to support gdbserver.
8255 (startup_inferior): Likewise.
8256 * gdbcore.h (get_exec_file): Remove declaration.
8257 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
8258 instead of "startup_inferior". Call "add_thread_silent" after
8260 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
8261 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
8262 instead of "startup_inferior". Call "add_thread_silent" after
8264 * inferior.h: Include "common-inferior.h".
8265 (trace_start_error): Move to "common/common-utils.h".
8266 (trace_start_error_with_name): Likewise.
8267 (fork_inferior): Move prototype to "nat/fork-inferior.h".
8268 (startup_inferior): Likewise.
8269 (gdb_startup_inferior): New prototype.
8270 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
8271 * nat/fork-inferior.h: New file.
8272 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
8273 instead of "startup_inferior". Call "add_thread_silent" after
8275 * target.h (target_terminal_init): Move prototype to
8277 (target_terminal_inferior): Likewise.
8278 (target_terminal_ours): Likewise.
8279 * target/target.h (target_terminal_init): New prototype, moved
8281 (target_terminal_inferior): Likewise.
8282 (target_terminal_ours): Likewise.
8283 * utils.c (gdb_flush_out_err): New function.
8285 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
8287 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
8288 * common/common-gdbthread.h: New file, with parts from
8290 * gdbthread.h: Include "common-gdbthread.h".
8291 (switch_to_thread): Moved to "common/common-gdbthread.h".
8293 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
8295 * Makefile.in (SFILES): Add "common/job-control.c".
8296 (HFILES_NO_SRCDIR): Add "common/job-control.h".
8297 (COMMON_OBS): Add "job-control.o".
8298 * common/job-control.c: New file, with contents from
8300 * common/job-control.h: New file, with contents from "terminal.h".
8301 * fork-child.c: Include "job-control.h".
8302 * inflow.c: Include "job-control.h".
8303 (gdb_setpgid): Move to "common/common-inflow.c".
8304 (_initialize_inflow): Move setting of "job_control" to
8305 "handle_job_control".
8306 * terminal.h (job_control): Moved to "common/common-terminal.h".
8307 (gdb_setpgid): Likewise.
8308 * top.c: Include "job_control.h".
8309 * utils.c: Likewise.
8310 (job_control): Moved to "job-control.c".
8312 2017-06-07 Pedro Alves <palves@redhat.com>
8314 * Makefile.in (SFILES): Add gdb_regex.c.
8315 (COMMON_OBS): Add gdb_regex.o.
8316 * ada-lang.c (ada_add_standard_exceptions)
8317 (ada_add_exceptions_from_frame, name_matches_regex)
8318 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
8319 parameter type to compiled_regex. Adjust.
8320 (ada_exceptions_list): Use compiled_regex.
8321 * break-catch-throw.c (exception_catchpoint::pattern): Now a
8322 std::unique_ptr<compiled_regex>.
8323 (exception_catchpoint::~exception_catchpoint): Remove regfree
8325 (check_status_exception_catchpoint): Adjust to use compiled_regex.
8326 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
8327 * breakpoint.c (solib_catchpoint::compiled): Now a
8328 std::unique_ptr<compiled_regex>.
8329 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
8330 (check_status_catch_solib): Adjust to use compiled_regex.
8331 (add_solib_catchpoint): Adjust to use compiled_regex.
8332 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
8333 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
8334 compiled_regex reference. Adjust to use it.
8335 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
8336 declaration. Include "gdb_regex.h".
8337 (apropos_cmd): Change regex parameter to compiled_regex reference.
8338 * gdb_regex.c: New file.
8339 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
8341 (class compiled_regex): New.
8342 * linux-tdep.c: Include "common/gdb_optional.h".
8343 (struct mapping_regexes): New, factored out from
8344 mapping_is_anonymous_p, and adjusted to use compiled_regex.
8345 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
8346 gdb::optional and remove cleanups. Adjust to compiled_regex.
8347 * probe.c: Include "common/gdb_optional.h".
8348 (collect_probes): Use compiled_regex and gdb::optional and remove
8350 * skip.c: Include "common/gdb_optional.h".
8351 (skiplist_entry::compiled_function_regexp): Now a
8352 gdb::optional<compiled_regex>.
8353 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
8354 (free_skiplist_entry): Remove regfree call.
8355 (compile_skip_regexp, skip_rfunction_p): Adjust to use
8356 compiled_regex and gdb::optional.
8357 * symtab.c: Include "common/gdb_optional.h".
8358 (search_symbols): Use compiled_regex and gdb::optional.
8359 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
8360 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
8363 2017-06-07 Alan Hayward <alan.hayward@arm.com>
8365 * regcache.c (regcache::save): Avoid buffer use.
8366 (regcache::dump): Likewise.
8368 2017-06-07 Alan Hayward <alan.hayward@arm.com>
8370 * sh-tdep.c (sh_pseudo_register_read): Remove
8372 (sh_pseudo_register_write): Likewise.
8373 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
8374 (sh64_pseudo_register_write): Likewise
8376 2017-06-07 Alan Hayward <alan.hayward@arm.com>
8378 * aarch64-tdep.c (aarch64_store_return_value): Use
8380 (aarch64_pseudo_read_value): Likewise.
8381 (aarch64_pseudo_write): Likewise.
8383 2017-06-06 Yao Qi <yao.qi@linaro.org>
8385 * regformats/regdef.h (set_register_cache): Remove the
8388 2017-06-06 Alan Hayward <alan.hayward@arm.com>
8390 * frame.c (frame_unwind_register_signed): Use
8391 frame_unwind_register_value.
8393 2017-06-06 Pedro Alves <palves@redhat.com>
8395 PR breakpoints/21553
8396 * breakpoint.c (create_breakpoints_sal_default)
8397 (init_breakpoint_sal, create_breakpoint_sal): Use
8398 gdb::unique_xmalloc_ptr for string parameters.
8399 (create_breakpoint): Constify 'extra_string' and 'cond_string'
8400 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
8401 (base_breakpoint_create_breakpoints_sal)
8402 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
8403 (strace_marker_create_breakpoints_sal)
8404 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
8406 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
8407 gdb::unique_xmalloc_ptr for string parameters.
8408 (create_breakpoint): Constify 'extra_string' and 'cond_string'
8411 2017-06-06 Alan Hayward <alan.hayward@arm.com>
8413 * alpha-tdep.c (alpha_register_to_value): Use
8414 get_frame_register_value.
8415 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
8417 2017-06-06 Alan Hayward <alan.hayward@arm.com>
8419 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
8420 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
8421 (ia64_value_to_register): Likewise.
8422 (ia64_extract_return_value): Likewise.
8423 (ia64_store_return_value): Likewise.
8424 (ia64_push_dummy_call): Likewise.
8426 2017-06-04 Joel Brobecker <brobecker@adacore.com>
8430 2017-06-03 Simon Marchi <simon.marchi@ericsson.com>
8432 * x86-linux-nat.c (struct arch_lwp_info): Remove.
8434 2017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
8436 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
8438 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
8440 2017-06-02 Simon Marchi <simon.marchi@ericsson.com>
8442 * event-loop.c (poll_timers): Unallocate timer using delete
8445 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
8447 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
8448 (struct breakpoint) <~breakpoint>: New.
8449 (struct watchpoint): Inherit from breakpoint.
8452 (struct tracepoint): Inherit from breakpoint.
8454 * breakpoint.c (longjmp_breakpoint_ops): Remove.
8455 (struct longjmp_breakpoint): Inherit from breakpoint.
8456 <~longjmp_breakpoint>: New.
8458 (new_breakpoint_from_type): Remove casts.
8459 (watchpoint_in_thread_scope): Remove reference to base field.
8460 (watchpoint_del_at_next_stop): Likewise.
8461 (update_watchpoint): Likewise.
8462 (watchpoint_check): Likewise.
8463 (bpstat_check_watchpoint): Likewise.
8464 (set_longjmp_breakpoint): Likewise.
8465 (struct fork_catchpoint): Inherit from breakpoint.
8467 (struct solib_catchpoint): Inherit from breakpoint.
8468 <~solib_catchpoint>: New.
8470 (dtor_catch_solib): Change to ...
8471 (solib_catchpoint::~solib_catchpoint): ... this.
8472 (breakpoint_hit_catch_solib): Remove reference to base field.
8473 (add_solib_catchpoint): Likewise.
8474 (create_fork_vfork_event_catchpoint): Likewise.
8475 (struct exec_catchpoint): Inherit from breakpoint.
8476 <~exec_catchpoint>: New.
8478 (dtor_catch_exec): Change to ...
8479 (exec_catchpoint::~exec_catchpoint): ... this.
8480 (dtor_watchpoint): Change to ...
8481 (watchpoint::~watchpoint): ... this.
8482 (watch_command_1): Remove reference to base field.
8483 (catch_exec_command_1): Likewise.
8484 (base_breakpoint_dtor): Change to ...
8485 (breakpoint::~breakpoint): ... this.
8486 (base_breakpoint_ops): Remove dtor field value.
8487 (longjmp_bkpt_dtor): Change to ...
8488 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
8489 (strace_marker_create_breakpoints_sal): Remove reference to base
8491 (delete_breakpoint): Don't manually call breakpoint destructor.
8492 (create_tracepoint_from_upload): Remove reference to base field.
8493 (trace_pass_set_count): Likewise.
8494 (initialize_breakpoint_ops): Don't initialize
8495 momentary_breakpoint_ops, don't set dtors.
8496 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
8497 <~ada_catchpoint>: New.
8499 (create_excep_cond_exprs): Remove reference to base field.
8500 (dtor_exception): Change to ...
8501 (ada_catchpoint::~ada_catchpoint): ... this.
8502 (dtor_catch_exception): Remove.
8503 (dtor_catch_exception_unhandled): Remove.
8504 (dtor_catch_assert): Remove.
8505 (create_ada_exception_catchpoint): Remove reference to base
8507 (initialize_ada_catchpoint_ops): Don't set dtors.
8508 * break-catch-sig.c (struct signal_catchpoint): Inherit from
8510 <~signal_catchpoint>: New.
8512 (signal_catchpoint_dtor): Change to ...
8513 (signal_catchpoint::~signal_catchpoint): ... this.
8514 (create_signal_catchpoint): Remove reference to base field.
8515 (initialize_signal_catchpoint_ops): Don't set dtor.
8516 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
8518 <~syscall_catchpoint>: New.
8520 (dtor_catch_syscall): Change to ...
8521 (syscall_catchpoint::~syscall_catchpoint): ... this.
8522 (create_syscall_event_catchpoint): Remove reference to base
8524 (initialize_syscall_catchpoint_ops): Don't set dtor.
8525 * break-catch-throw.c (struct exception_catchpoint): Inherit
8527 <~exception_catchpoint>: New.
8529 (dtor_exception_catchpoint): Change to ...
8530 (exception_catchpoint::~exception_catchpoint): ... this.
8531 (handle_gnu_v3_exceptions): Remove reference to base field.
8532 (initialize_throw_catchpoint_ops): Don't set dtor.
8533 * ctf.c (ctf_get_traceframe_address): Remove reference to base
8535 * remote.c (remote_get_tracepoint_status): Likewise.
8536 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
8537 * tracefile.c (tracefile_fetch_registers): Likewise.
8538 * tracepoint.c (actions_command): Likewise.
8539 (validate_actionline): Likewise.
8540 (tfind_1): Likewise.
8541 (get_traceframe_location): Likewise.
8542 (find_matching_tracepoint_location): Likewise.
8543 (parse_tracepoint_status): Likewise.
8544 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
8546 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
8548 * breakpoint.c (struct longjmp_breakpoint): New struct.
8549 (is_tracepoint_type): Change return type to bool.
8550 (is_longjmp_type): New function.
8551 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
8552 (set_raw_breakpoint_without_location): Use
8553 new_breakpoint_from_type.
8554 (set_raw_breakpoint): Likewise.
8556 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
8558 * breakpoint.c (new_breakpoint_from_type): New function.
8559 (create_breakpoint_sal): Use new_breakpoint_from_type and
8561 (create_breakpoint): Likewise.
8563 2017-05-31 Simon Marchi <simon.marchi@ericsson.com>
8565 * memattr.c (mem_info_command): Rename to ...
8566 (info_mem_command): ... this.
8567 (mem_enable_command): Rename to ...
8568 (enable_mem_command): ... this.
8569 (mem_disable_command): Rename to ...
8570 (disable_mem_command): ... this.
8571 (mem_delete_command): Rename to ...
8572 (delete_mem_command): ... this.
8573 (_initialize_mem): Adjust function names.
8575 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
8577 * btrace.c (handle_pt_insn_events): New.
8578 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
8579 STATUS. Split into this and ...
8580 (handle_pt_insn_event_flags): ... this.
8582 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
8584 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
8585 and struct pt_insn.resynced.
8586 * configure: Regenerated.
8587 * config.in: Regenerated.
8589 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8591 * btrace.c (ftrace_find_call_by_number): New function.
8592 (ftrace_new_function): Store objects, not pointers.
8593 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
8594 ftrace_new_gap, ftrace_update_function,
8595 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
8596 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
8597 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
8598 btrace_ends_with_single_insn, btrace_call_get): Account for
8599 btrace_thread_info::functions now storing objects.
8600 * btrace.h (struct btrace_thread_info): Add constructor.
8601 (struct btrace_thread_info) <functions>: Make std::vector.
8602 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
8603 Initialize with default values.
8604 * record-btrace.c (record_btrace_frame_sniffer): Account for
8605 btrace_thread_info::functions now storing objects.
8607 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8609 * btrace.c: Remove typedef bfun_s.
8610 (ftrace_new_gap): Directly add gaps to the list of gaps.
8611 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
8612 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
8613 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
8616 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8618 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
8619 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
8620 with btrace_thread_info::next_segment and
8621 btrace_thread_info::prev_segment.
8622 * btrace.h: Remove struct btrace_func_link.
8623 (struct btrace_function): Replace pair of function segment pointers
8624 with pair of indices.
8625 * python/py-record-btrace.c (btpy_call_prev_sibling,
8626 btpy_call_next_sibling): Replace references to
8627 btrace_thread_info::segment with btrace_thread_info::next_segment and
8628 btrace_thread_info::prev_segment.
8629 * record-btrace.c (record_btrace_frame_this_id): Use
8630 btrace_find_call_by_number.
8632 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8634 * btrace.c (ftrace_new_function, ftrace_fixup_level,
8635 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
8636 btrace_insn_next, btrace_insn_prev): Remove references to
8637 btrace_thread_info::flow.
8638 * btrace.h (struct btrace_function): Remove FLOW.
8640 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8642 * btrace.c (ftrace_find_call_by_number): New function.
8643 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
8644 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
8645 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
8646 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
8648 * btrace.h (struct btrace_function): Turn UP into an index.
8649 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
8651 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
8652 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
8653 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
8655 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8657 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
8658 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
8659 ftrace_update_function, ftrace_compute_global_level_offset,
8660 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
8661 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
8662 btrace_insn_end, btrace_is_empty): Remove references to
8663 btrace_thread_info::begin and btrace_thread_info::end.
8664 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
8665 (struct btrace_thread_info) <functions>: Adjust comment.
8666 * record-btrace.c (record_btrace_start_replaying): Remove reference to
8667 btrace_thread_info::begin.
8669 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8671 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
8672 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
8673 ftrace_update_function): Remove arguments that implicitly were always
8675 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
8676 Don't pass BTINFO->END.
8678 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8680 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
8681 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
8682 btrace_find_insn_by_number): Replace function segment pointer with
8684 (btrace_insn_cmp): Simplify.
8685 * btrace.h: (struct btrace_insn_iterator) Rename index to
8686 insn_index. Replace function segment pointer with index into function
8688 * record-btrace.c (record_btrace_call_history): Replace function
8689 segment pointer use with index.
8690 (record_btrace_frame_sniffer): Retrieve function call segment through
8692 (record_btrace_set_replay): Remove defunc't safety check.
8694 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8696 * btrace.c (btrace_ends_with_single_insn): New function.
8697 (btrace_call_get, btrace_call_number, btrace_call_begin,
8698 btrace_call_end, btrace_call_next, btrace_call_prev,
8699 btrace_find_call_by_number): Use index into call segment vector
8701 (btrace_call_cmp): Simplify.
8702 * btrace.h (struct btrace_call_iterator): Replace function call segment
8703 pointer with index into vector.
8704 * record-btrace.c (record_btrace_call_history): Use index instead of
8707 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8709 * btrace.c (btrace_insn_begin, btrace_insn_end,
8710 btrace_find_insn_by_number): Add btinfo to iterator.
8711 * btrace.h (struct btrace_insn_iterator): Add btinfo.
8713 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8715 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
8716 and save pointers directly.
8717 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
8718 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
8719 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
8720 changed signature of functions.
8721 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
8722 (btrace_fetch): Remove code that adds btrace_function pointers to
8723 vector of btrace_functions.
8724 (btrace_clear): Simplify freeing vector of btrace_functions.
8726 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8728 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
8729 Replace VEC_* with std::vector functions.
8730 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
8731 (struct btrace_thread_info)<functions>: Change type to std::vector.
8733 2017-05-30 Simon Marchi <simon.marchi@ericsson.com>
8735 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
8736 "Removed targets and native configurations" up. Merge duplicate
8737 "New commands" sub-sections. Add "New options" sub-sections.
8739 2017-05-26 Alan Hayward <alan.hayward@arm.com>
8741 * defs.h (copy_integer_to_size): New declaration.
8742 * findvar.c (copy_integer_to_size): New function.
8743 (do_cint_test): New selftest function.
8744 (copy_integer_to_size_test): Likewise.
8745 (_initialize_findvar): Likewise.
8746 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
8747 (mips_fbsd_collect_reg): Use raw_collect_integer.
8748 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
8749 (mips64_fill_gregset): Use raw_collect_integer
8750 (mips64_fill_fpregset): Use raw_supply_integer.
8751 * regcache.c (regcache::raw_supply_integer): New function.
8752 (regcache::raw_collect_integer): Likewise.
8753 * regcache.h: (regcache::raw_supply_integer): New declaration.
8754 (regcache::raw_collect_integer): Likewise.
8756 2017-05-24 Yao Qi <yao.qi@linaro.org>
8758 * Makefile.in (SFILES): Add gdbarch-selftests.c.
8759 (COMMON_OBS): Add gdbarch-selftests.o.
8760 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
8761 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
8762 * gdbarch-selftests.c: New file.
8763 * regcache.h (regcache) <~regcache>: Mark it virtual if
8765 <raw_write>: Likewise.
8767 2017-05-24 Yao Qi <yao.qi@linaro.org>
8769 * regcache.c (current_regcache): Change it to
8770 regcache::current_regcache.
8771 (regcache_observer_target_changed): Update.
8772 (regcache_thread_ptid_changed): Make it a regcache static
8774 (regcache_thread_ptid_changed): Update.
8775 (class regcache_access): New.
8776 (current_regcache_test): Update.
8777 (_initialize_regcache): Update.
8778 * regcache.h: Include forward_list.
8779 (regcache): Declare regcache_thread_ptid_changed and declare
8780 registers_changed_ptid as friend.
8782 2017-05-24 Yao Qi <yao.qi@linaro.org>
8784 * i387-tdep.c (i387_register_to_value): Use register_size
8785 instead of TYPE_LENGTH.
8786 * m68k-tdep.c (m68k_register_to_value): Likewise.
8788 2017-05-24 Yao Qi <yao.qi@linaro.org>
8790 * i387-tdep.c (i387_convert_register_p): Return false if type
8791 code isn't TYPE_CODE_FLT.
8793 2017-05-24 Yao Qi <yao.qi@linaro.org>
8795 * alpha-tdep.c (alpha_convert_register_p): Return true if type
8797 (alpha_register_to_value): Remove type length check.
8798 (alpha_value_to_register): Likewise.
8800 2017-05-24 Yao Qi <yao.qi@linaro.org>
8802 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
8805 2017-05-24 Yao Qi <yao.qi@linaro.org>
8807 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
8808 TYPE_CODE_FLT or not.
8810 2017-05-24 Yao Qi <yao.qi@linaro.org>
8812 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
8813 * avr-tdep.c (avr_gdbarch_init): Likewise.
8814 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
8815 * cris-tdep.c (cris_gdbarch_init): Likewise.
8816 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
8817 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
8818 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
8819 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
8820 * mep-tdep.c (mep_gdbarch_init): Likewise.
8821 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
8822 * mips-tdep.c (mips_gdbarch_init): Likewise.
8823 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
8824 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
8825 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
8826 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
8827 * v850-tdep.c (v850_gdbarch_init): Likewise.
8829 2017-05-24 Yao Qi <yao.qi@linaro.org>
8831 * selftest-arch.c (tests_with_arch): Call registers_changed
8832 and reinit_frame_cache.
8833 * selftest.c (run_self_tests): Likewise.
8835 2017-05-24 Yao Qi <yao.qi@linaro.org>
8837 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
8838 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
8840 2017-05-24 Yao Qi <yao.qi@linaro.org>
8842 * rl78-tdep.c (rl78_gdbarch_init): Don't call
8843 set_gdbarch_print_insn.
8845 2017-05-24 Yao Qi <yao.qi@linaro.org>
8847 * h8300-tdep.c (h8300_gdbarch_init): Don't call
8848 set_gdbarch_print_insn.
8850 2017-05-24 Yao Qi <yao.qi@linaro.org>
8852 * alpha-tdep.c (alpha_gdbarch_init): Don't call
8853 set_gdbarch_print_insn.
8854 * arc-tdep.c (arc_gdbarch_init): Likewise.
8855 * arch-utils.c: include dis-asm.h.
8856 (default_print_insn): New function.
8857 * arch-utils.h (default_print_insn): Declare.
8858 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
8859 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
8860 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
8861 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
8862 * frv-tdep.c (frv_gdbarch_init): Likewise.
8863 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
8864 * gdbarch.sh (print_insn): Use default_print_insn.
8865 * gdbarch.c: Regenerated.
8866 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
8867 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
8868 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
8869 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
8870 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
8871 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
8872 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
8873 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
8874 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
8875 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
8876 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
8877 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
8878 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
8879 * mt-tdep.c (mt_gdbarch_init): Likewise.
8880 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
8881 * nios2-tdep.c (nios2_print_insn): Remove.
8882 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
8883 * rx-tdep.c (rx_gdbarch_init): Likewise.
8884 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
8885 * score-tdep.c (score_print_insn): Remove.
8886 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
8887 * sh-tdep.c (sh_gdbarch_init): Likewise.
8888 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
8889 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
8890 * tic6x-tdep.c (tic6x_print_insn): Remove.
8891 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
8892 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
8893 * v850-tdep.c (v850_gdbarch_init): Likewise.
8894 * vax-tdep.c (vax_gdbarch_init): Likewise.
8895 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
8896 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
8898 2017-05-23 John Baldwin <jhb@FreeBSD.org>
8900 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
8901 (MIPS_FP0_REGNUM): Remove.
8902 (MIPS_FSR_REGNUM): Remove.
8903 (mips_fbsd_supply_fpregs): Use mips_regnum.
8904 (mips_fbsd_supply_gregs): Likewise.
8905 (mips_fbsd_collect_fpregs): Likewise.
8906 (mips_fbsd_collect_gregs): Likewise.
8908 2017-05-23 John Baldwin <jhb@FreeBSD.org>
8910 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
8911 (getpfpregs_supplies): New function.
8912 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
8914 (mips_fbsd_store_inferior_registers): Likewise.
8916 2017-05-22 Pedro Alves <palves@redhat.com>
8918 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
8921 2017-05-22 Alan Hayward <alan.hayward@arm.com>
8923 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
8924 (store_register): Likewise.
8925 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
8926 (get_decimal_float_return_value): Likewise.
8927 (do_ppc_sysv_return_value): Likewise.
8928 (ppc64_sysv_abi_push_integer): Likewise.
8929 (ppc64_sysv_abi_push_freg): Likewise.
8930 (ppc64_sysv_abi_return_value_base): Likewise.
8931 (ppc64_sysv_abi_return_value): Likewise.
8932 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
8933 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
8934 * rs6000-nat.c: Likewise.
8935 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
8936 (rs6000_value_to_register): Likewise.
8937 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
8939 2017-05-21 Tom Tromey <tom@tromey.com>
8942 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
8943 arrays as "[T]", not "[T; ]".
8945 2017-05-19 Tom Tromey <tom@tromey.com>
8948 * rust-lang.c (exp_descriptor_rust): New function.
8949 (rust_language_defn): Use it.
8950 * p-lang.c (pascal_language_defn): Update.
8951 * opencl-lang.c (opencl_language_defn): Update.
8952 * objc-lang.c (objc_language_defn): Update.
8953 * m2-lang.c (m2_language_defn): Update.
8954 * language.h (struct language_defn)
8955 <la_watch_location_expression>: New member.
8956 * language.c (unknown_language_defn, auto_language_defn)
8957 (local_language_defn): Update.
8958 * go-lang.c (go_language_defn): Update.
8959 * f-lang.c (f_language_defn): Update.
8960 * d-lang.c (d_language_defn): Update.
8961 * c-lang.h (c_watch_location_expression): Declare.
8962 * c-lang.c (c_watch_location_expression): New function.
8963 (c_language_defn, cplus_language_defn, asm_language_defn)
8964 (minimal_language_defn): Use it.
8965 * breakpoint.c (watch_command_1): Call
8966 la_watch_location_expression.
8967 * ada-lang.c (ada_language_defn): Update.
8969 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
8972 * gdb_curses.h (NOMACROS): Define.
8973 (NCURSES_NOMACROS): Define.
8975 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
8978 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
8980 * tui/tui-wingeneral.c (box_win): Likewise.
8981 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
8982 (tui_show_source_line): Likewise.
8983 (tui_show_exec_info_content): Likewise.
8985 2017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
8987 * sparc-tdep.c (sparc_structure_return_p)
8988 (sparc_arg_on_registers_p): New functions.
8989 (sparc32_store_arguments): Use them.
8990 * sparc64-tdep.c (sparc64_16_byte_align_p)
8991 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
8992 Handle TYPE_CODE_ARRAY.
8994 2017-05-17 Yao Qi <yao.qi@linaro.org>
8996 * cli/cli-decode.c (add_alias_cmd): New function.
8997 * command.h (add_alias_cmd): Declare.
8998 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
8999 instead call add_alias_cmd.
9001 2017-05-17 Pedro Alves <palves@redhat.com>
9003 * Makefile.in (nat_extra_makefile_frag): Rename to ...
9004 (nat_makefile_frag): ... this. All references updated.
9005 * configure.ac: Likewise.
9006 * configure.nat: Likewise. Enhance comments.
9007 * configure: Regenerate.
9009 2017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
9011 * procfs.c (procfs_create_inferior): Change prototype to match
9014 2017-05-13 Eli Zaretskii <eliz@gnu.org>
9016 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
9017 C++ compiler warning.
9019 2017-05-12 Tom Tromey <tom@tromey.com>
9022 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
9023 recurse, just call value_struct_elt directly.
9025 2017-05-12 Tom Tromey <tom@tromey.com>
9027 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
9028 OP_RUST_ARRAY>: Fix.
9030 2017-05-12 Tom Tromey <tom@tromey.com>
9032 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
9034 2017-05-09 Yao Qi <yao.qi@linaro.org>
9036 * regcache.c: Include <forward_list>.
9037 (struct regcache_list): Remove.
9038 (current_regcache): Update.
9039 (get_thread_arch_aspace_regcache): Update for std::forward_list.
9040 (regcache_thread_ptid_changed): Likewise.
9041 (registers_changed_ptid): Likewise.
9042 (current_regcache_size): Likewise.
9044 2017-05-09 Yao Qi <yao.qi@linaro.org>
9046 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
9047 (current_regcache_size): New function.
9048 (current_regcache_test): New function.
9049 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
9051 2017-05-08 Alan Hayward <alan.hayward@arm.com>
9053 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
9054 (print_gp_register_row): Use get_frame_register_value.
9056 2017-05-08 Alan Hayward <alan.hayward@arm.com>
9058 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
9059 (mips_supply_fpregset): Likewise.
9060 (mips64_supply_gregset): Likewise.
9062 2017-05-08 Alan Hayward <alan.hayward@arm.com>
9064 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
9065 regcache->raw_supply_zeroed.
9067 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
9069 * configure.nat: Rearrange 'case' statements to match
9072 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
9074 * Makefile.in: Remove "@host_makefile_frag@". Add variables
9075 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
9076 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
9077 "@nat_extra_makefile_frag@".
9078 (Makefile): Remove dependency on "@frags@".
9079 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
9080 (data-directory/Makefile): Likewise.
9081 * config/aarch64/linux.mh: Deleted; moved contents to
9082 "gdb/configure.nat".
9083 * config/alpha/alpha-linux.mh: Likewise.
9084 * config/alpha/nbsd.mh: Likewise.
9085 * config/arm/linux.mh: Likewise.
9086 * config/arm/nbsdelf.mh: Likewise.
9087 * config/i386/cygwin.mh: Likewise.
9088 * config/i386/cygwin64.mh: Likewise.
9089 * config/i386/darwin.mh: Likewise.
9090 * config/i386/fbsd.mh: Likewise.
9091 * config/i386/fbsd64.mh: Likewise.
9092 * config/i386/go32.mh: Likewise.
9093 * config/i386/i386gnu.mh: Likewise.
9094 * config/i386/i386sol2.mh: Likewise.
9095 * config/i386/linux.mh: Likewise.
9096 * config/i386/linux64.mh: Likewise.
9097 * config/i386/mingw.mh: Likewise.
9098 * config/i386/mingw64.mh: Likewise.
9099 * config/i386/nbsd64.mh: Likewise.
9100 * config/i386/nbsdelf.mh: Likewise.
9101 * config/i386/nto.mh: Likewise.
9102 * config/i386/obsd.mh: Likewise.
9103 * config/i386/obsd64.mh: Likewise.
9104 * config/i386/sol2-64.mh: Likewise.
9105 * config/ia64/linux.mh: Likewise.
9106 * config/m32r/linux.mh: Likewise.
9107 * config/m68k/linux.mh: Likewise.
9108 * config/m68k/nbsdelf.mh: Likewise.
9109 * config/m68k/obsd.mh: Likewise.
9110 * config/m88k/obsd.mh: Likewise.
9111 * config/mips/fbsd.mh: Likewise.
9112 * config/mips/linux.mh: Likewise.
9113 * config/mips/nbsd.mh: Likewise.
9114 * config/mips/obsd64.mh: Likewise.
9115 * config/pa/linux.mh: Likewise.
9116 * config/pa/nbsd.mh: Likewise.
9117 * config/pa/obsd.mh: Likewise.
9118 * config/powerpc/aix.mh: Likewise.
9119 * config/powerpc/fbsd.mh: Likewise.
9120 * config/powerpc/linux.mh: Likewise.
9121 * config/powerpc/nbsd.mh: Likewise.
9122 * config/powerpc/obsd.mh: Likewise.
9123 * config/powerpc/ppc64-linux.mh: Likewise.
9124 * config/powerpc/spu-linux.mh: Likewise.
9125 * config/s390/linux.mh: Likewise.
9126 * config/sh/nbsd.mh: Likewise.
9127 * config/sparc/fbsd.mh: Likewise.
9128 * config/sparc/linux.mh: Likewise.
9129 * config/sparc/linux64.mh: Likewise.
9130 * config/sparc/nbsd64.mh: Likewise.
9131 * config/sparc/nbsdelf.mh: Likewise.
9132 * config/sparc/obsd64.mh: Likewise.
9133 * config/sparc/sol2.mh: Likewise.
9134 * config/tilegx/linux.mh: Likewise.
9135 * config/vax/nbsdelf.mh: Likewise.
9136 * config/vax/obsd.mh: Likewise.
9137 * config/xtensa/linux.mh: Likewise.
9138 * config/i386/i386gnu.mn: New file, with excerpts from
9139 "config/i386/i386gnu.mh".
9140 * configure: Regenerate.
9141 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
9142 *.mh files under "gdb/config".
9143 * configure.nat: New file, with contents from the
9144 "gdb/config/*/*.mh" files.
9146 2017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
9148 * btrace.c (btrace_clear): Free insn vector.
9150 2017-05-05 Pedro Alves <palves@redhat.com>
9152 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
9153 * configure: Regenerate.
9155 2017-05-04 Pedro Alves <palves@redhat.com>
9157 * Makefile.in (SFILES): Add progspace-and-thread.c.
9158 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
9159 (COMMON_OBS): Add progspace-and-thread.o.
9160 * breakpoint.c: Include "progspace-and-thread.h".
9161 (update_inserted_breakpoint_locations)
9162 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
9163 Use scoped_restore_current_pspace_and_thread.
9164 (create_std_terminate_master_breakpoint): Use
9165 scoped_restore_current_program_space.
9166 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
9167 (print_breakpoint_location): Use
9168 scoped_restore_current_program_space.
9169 (bp_loc_is_permanent): Use
9170 scoped_restore_current_pspace_and_thread.
9171 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
9172 (download_tracepoint_locations): Use
9173 scoped_restore_current_pspace_and_thread.
9174 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
9175 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
9176 (enum step_over_calls_kind): Moved from inferior.h.
9177 (class scoped_restore_current_thread): New class.
9178 * gdbthread.h (make_cleanup_restore_current_thread): Delete
9180 (scoped_restore_current_thread): New class.
9181 * infcmd.c: Include "common/gdb_optional.h".
9182 (continue_1, proceed_after_attach): Use
9183 scoped_restore_current_thread.
9184 (notice_new_inferior): Use scoped_restore_current_thread.
9185 * inferior.c: Include "progspace-and-thread.h".
9186 (restore_inferior, save_current_inferior): Delete.
9187 (add_inferior_command, clone_inferior_command): Use
9188 scoped_restore_current_pspace_and_thread.
9189 * inferior.h (scoped_restore_current_inferior): New class.
9190 * infrun.c: Include "progspace-and-thread.h" and
9191 "common/gdb_optional.h".
9192 (follow_fork_inferior): Use
9193 scoped_restore_current_pspace_and_thread.
9194 (scoped_restore_exited_inferior): New class.
9195 (handle_vfork_child_exec_or_exit): Use
9196 scoped_restore_exited_inferior,
9197 scoped_restore_current_pspace_and_thread,
9198 scoped_restore_current_thread and scoped_restore.
9199 (fetch_inferior_event): Use scoped_restore_current_thread.
9200 * linespec.c (decode_line_full, decode_line_1): Use
9201 scoped_restore_current_program_space.
9202 * mi/mi-main.c: Include "progspace-and-thread.h".
9203 (exec_continue): Use scoped_restore_current_thread.
9204 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
9205 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
9206 * proc-service.c (ps_pglobal_lookup): Use
9207 scoped_restore_current_program_space.
9208 * progspace-and-thread.c: New file.
9209 * progspace-and-thread.h: New file.
9210 * progspace.c (release_program_space, clone_program_space): Use
9211 scoped_restore_current_program_space.
9212 (restore_program_space, save_current_program_space)
9213 (save_current_space_and_thread): Delete.
9214 (switch_to_program_space_and_thread): Moved to
9215 progspace-and-thread.c.
9216 * progspace.h (save_current_program_space)
9217 (save_current_space_and_thread): Delete declarations.
9218 (scoped_restore_current_program_space): New class.
9219 * remote.c (remote_btrace_maybe_reopen): Use
9220 scoped_restore_current_thread.
9221 * symtab.c: Include "progspace-and-thread.h".
9222 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
9223 * thread.c (print_thread_info_1): Use
9224 scoped_restore_current_thread.
9225 (struct current_thread_cleanup): Delete.
9226 (do_restore_current_thread_cleanup)
9227 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
9228 (scoped_restore_current_thread::~scoped_restore_current_thread):
9230 (make_cleanup_restore_current_thread): Rename/convert to ...
9231 (scoped_restore_current_thread::scoped_restore_current_thread):
9233 (thread_apply_all_command): Use scoped_restore_current_thread.
9234 (thread_apply_command): Use scoped_restore_current_thread.
9235 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
9236 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
9238 2017-05-04 Pedro Alves <palves@redhat.com>
9240 * thread.c (make_cleanup_restore_current_thread): Move
9241 find_thread_ptid call before the is_stopped call. Assert that the
9242 thread is found. Replace is_stopped call by checking the thread's
9243 state directly. Remove unnecessary NULL-thread check.
9245 2017-05-04 Pedro Alves <palves@redhat.com>
9247 * corelow.c (thread_section_name): New class.
9248 (get_core_register_section, get_core_siginfo): Use it.
9250 2017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
9252 * corelow.c (sniff_core_bfd): Remove extra semicolon.
9253 (get_core_register_section): Remove xfree of NULL pointer.
9255 2017-05-03 Alan Hayward <alan.hayward@arm.com>
9257 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
9258 * regcache.c (regcache::raw_supply_zeroed): New function.
9259 * regcache.h (regcache::raw_supply_zeroed): New declaration.
9261 2017-05-03 Simon Marchi <simon.marchi@ericsson.com>
9263 * gdbarch.sh: Remove commented out definition of
9265 * gdbarch.h: Re-generate.
9267 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
9269 * configure: Regenerate.
9271 2017-05-02 Simon Marchi <simon.marchi@ericsson.com>
9273 * solib-target.c (solib_target_relocate_section_addresses):
9274 Remove num_section_bases, num_bases, segment_bases variables.
9276 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
9278 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
9280 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
9282 * solib-target.c: Include <vector>
9283 (struct lm_info_target) <~lm_info_target>: Remove.
9284 <segment_bases, section_bases>: Change type to
9285 std::vector<CORE_ADDR>.
9286 (library_list_start_segment, library_list_start_section,
9287 library_list_end_library,
9288 solib_target_relocate_section_addresses): Adjust.
9290 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
9292 * gdbarch.sh (software_single_step): Change return type to
9293 std::vector<CORE_ADDR>.
9294 * gdbarch.c, gdbarch.h: Re-generate.
9295 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
9297 (arm_deal_with_atomic_sequence_raw): Adjust.
9298 (thumb_get_next_pcs_raw): Adjust.
9299 (arm_get_next_pcs_raw): Adjust.
9300 (arm_get_next_pcs): Adjust.
9301 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
9302 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
9303 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
9304 (alpha_software_single_step): Adjust.
9305 * alpha-tdep.h (alpha_software_single_step): Adjust.
9306 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
9307 * arm-tdep.c (arm_software_single_step): Adjust.
9308 (arm_breakpoint_kind_from_current_state): Adjust.
9309 * arm-tdep.h (arm_software_single_step): Adjust.
9310 * breakpoint.c (insert_single_step_breakpoint): Adjust.
9311 * cris-tdep.c (cris_software_single_step): Adjust.
9312 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
9313 (micromips_deal_with_atomic_sequence): Adjust.
9314 (deal_with_atomic_sequence): Adjust.
9315 (mips_software_single_step): Adjust.
9316 * mips-tdep.h (mips_software_single_step): Adjust.
9317 * moxie-tdep.c (moxie_software_single_step): Adjust.
9318 * nios2-tdep.c (nios2_software_single_step): Adjust.
9319 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
9320 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
9321 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
9322 * s390-linux-tdep.c (s390_software_single_step): Adjust.
9323 * sparc-tdep.c (sparc_software_single_step): Adjust.
9324 * spu-tdep.c (spu_software_single_step): Adjust.
9325 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
9327 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
9329 * gdbarch.sh: Use semi-colon as field separator instead of colon.
9330 * gdbarch.h: Re-generate.
9332 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
9334 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
9335 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
9336 * python/py-instruction.c, python/py-instruction.h: New file.
9337 * python/py-record.c: Add py-instruction.h include.
9338 (gdbpy_initialize_record): Make gdb.Instruction a super class of
9339 gdb.RecordInstruction.
9340 * python/python-internal.h: Add gdbpy_initialize_instruction
9342 * python/python.c (do_start_initialization): Add
9343 gdbpy_initialize_instruction.
9345 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
9347 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
9349 (btrace_func_from_recpy_func): New function.
9350 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
9351 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
9352 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
9353 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
9354 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
9355 Also, use new helper functions.
9356 (btpy_list_item): Use new helper functions.
9357 (recpy_bt_function_call_history): Use new type name.
9358 (btpy_call_getset): Remove.
9359 (gdbpy_initialize_btrace): Remove code to initialize
9360 gdb.BtraceFunctionCall.
9361 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
9362 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
9363 recpy_bt_func_prev, recpy_bt_func_next): New export.
9364 * python/py-record.c (recpy_func_type): New static object.
9365 (recpy_func_new, recpy_func_level, recpy_func_symbol,
9366 recpy_func_instructions, recpy_func_up, recpy_func_prev,
9367 recpy_func_next): New function.
9368 (recpy_element_hash, recpy_element_richcompare): Updated comment.
9369 (recpy_func_getset): New static object.
9370 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
9371 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
9373 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
9375 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
9376 (btpy_object, btpy_insn_type, btpy_new): Remove.
9377 (btpy_list_object): Use gdb.RecordInstruction type instead of
9378 gdb.BtraceInstruction type.
9379 (btrace_insn_from_recpy_insn): New function.
9380 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
9382 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
9383 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
9384 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
9385 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
9386 instead of btpy_object.
9387 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
9388 btpy_insn_data, btpy_insn_decode): Rename to ...
9389 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
9390 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
9391 recpy_bt_insn_decode): This. Also, use new helper functions.
9392 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
9394 (btpy_insn_getset): Remove.
9395 (gdbpy_initialize_btrace): Remove code to initialize
9396 gdb.BtraceInstruction. Use recpy_element_object.
9397 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
9398 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
9399 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
9400 * python/py-record.c (recpy_insn_type): New static object.
9401 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
9402 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
9403 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
9405 (recpy_insn_getset): New static object.
9406 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
9407 * python/py-record.h (recpy_element_object): New typedef.
9408 (recpy_insn_type, recpy_insn_new): New export.
9410 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
9412 * py-record-btrace.c (btpy_insn_new): Removed.
9413 (btpy_insn_or_gap_new): New function.
9414 (btpy_insn_error): Removed.
9415 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
9416 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
9417 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
9418 btpy_insn_or_gap_new instead of btpy_insn_new.
9419 (btpy_insn_getset): Remove btpy_insn_error.
9420 * py-record.c (recpy_gap_type): New static object.
9421 (recpy_gap_object): New typedef.
9422 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
9423 recpy_gap_reason_string): New function.
9424 (recpy_gap_getset): New static object.
9425 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
9426 * py-record.h (recpy_gap_new): New export.
9428 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
9430 * python/py-record.c (recpy_ptid): Remove.
9431 (recpy_record_getset): Remove recpy_ptid.
9433 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
9435 * btrace.c (btrace_fetch): Set inferior_ptid.
9436 * python/py-record-btrace.c: Add "py-record.h" include.
9437 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
9438 recpy_bt_end, recpy_bt_instruction_history,
9439 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
9440 in gdb.Record object instead of current ptid.
9441 * python/py-record.c: Include new "py-record.h" file.
9442 (recpy_record_object): Moved to py-record.h.
9443 * python/py-record.h: New file.
9445 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
9447 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
9448 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
9451 2017-05-01 Joel Brobecker <brobecker@adacore.com>
9453 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
9454 the past maintainers section.
9456 2017-04-28 Yao Qi <yao.qi@linaro.org>
9458 * infcmd.c (get_return_value): Use regcache ctor, and remove
9461 2017-04-28 Yao Qi <yao.qi@linaro.org>
9462 Pedro Alves <palves@redhat.com>
9464 * regcache.c (regcache::regcache): New tag dispatch ctor.
9465 (do_cooked_read): Moved above.
9466 (regcache_dup): Use the tag dispatch ctor..
9467 * regcache.h (regcache): Declare ctor, delete copy ctor and
9468 assignment operator, remove friend regcache_dup.
9470 2017-04-28 Yao Qi <yao.qi@linaro.org>
9472 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
9473 call method save instead of regcache_cpy.
9474 * regcache.h (struct regcache): Make regcache_dup a friend.
9476 2017-04-28 Yao Qi <yao.qi@linaro.org>
9478 * regcache.c (struct regcache): Move to regcache.h
9479 (regcache::arch): New method.
9480 (regcache_get_ptid): Update.
9481 (get_regcache_arch): Call arch method.
9482 (get_regcache_aspace): Call method aspace.
9483 (register_buffer): Change it to method.
9484 (regcache_save): Change it to regcache::save.
9485 (regcache_restore): Likewise.
9486 (regcache_cpy_no_passthrough): Remove the declaration.
9487 (regcache_cpy): Call methods restore and cpy_no_passthrough.
9488 (regcache_cpy_no_passthrough): Change it to method
9490 (regcache_register_status): Change it to method
9491 get_register_status.
9492 (regcache_invalidate): Change it to method invalidate.
9493 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
9494 (regcache_raw_update): Change it to method raw_update.
9495 (regcache_raw_read): Likewise.
9496 (regcache_raw_read_signed): Likewise.
9497 (regcache_raw_read_unsigned): Likewise.
9498 (regcache_raw_write_signed): Likewise.
9499 (regcache_raw_write_unsigned): Likewise.
9500 (regcache_cooked_read): Likewise.
9501 (regcache_cooked_read_value): Likewise.
9502 (regcache_cooked_read_signed): Likewise.
9503 (regcache_cooked_read_unsigned): Likewise.
9504 (regcache_cooked_write_signed): Likewise.
9505 (regcache_cooked_write_unsigned): Likewise.
9506 (regcache_raw_set_cached_value): Likewise.
9507 (regcache_raw_write): Likewise.
9508 (regcache_cooked_write): Likewise.
9509 (regcache_xfer_part): Likewise.
9510 (regcache_raw_read_part): Likewise.
9511 (regcache_raw_write_part): Likewise.
9512 (regcache_cooked_read_part): Likewise.
9513 (regcache_cooked_write_part): Likewise.
9514 (regcache_raw_supply): Likewise.
9515 (regcache_raw_collect): Likewise.
9516 (regcache_transfer_regset): Likewise.
9517 (regcache_supply_regset): Likewise.
9518 (regcache_collect_regset): Likewise.
9519 (regcache_debug_print_register): Likewise.
9520 (enum regcache_dump_what): Move it to regcache.h.
9521 (regcache_dump): Change it to method dump.
9522 * regcache.h (enum regcache_dump_what): New.
9523 (class regcache): New.
9524 * target.c (target_fetch_registers): Call method
9525 debug_print_register.
9526 (target_store_registers): Likewise.
9528 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9530 * windows-nat.c (struct lm_info_windows): Initialize field.
9531 (windows_make_so): Allocate lm_info_windows with new.
9532 (windows_free_so): Free lm_info_windows with delete.
9534 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9536 * solib-darwin.c (struct lm_info_darwin): Initialize field.
9537 (darwin_current_sos): Allocate lm_info_darwin with new, remove
9539 (darwin_free_so): Free lm_info_darwin with delete.
9541 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9543 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
9544 <l_addr_p>: Change type to bool.
9545 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
9546 (svr4_free_so): Free lm_info_svr4 with delete.
9547 (svr4_copy_library_list): Replace memcpy with call to copy
9549 (library_list_start_library, svr4_default_sos): Allocate
9550 lm_info_svr4 with new.
9552 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9554 * solib-target.c (struct lm_info_target): Add destructor,
9556 <name>: Change type to std::string.
9557 (library_list_start_library): Allocate lm_info_target with new.
9558 (solib_target_free_library_list): Free lm_info_target with
9560 (solib_target_current_sos): Adapt to std::string.
9561 (solib_target_free_so): Free lm_info_target with delete.
9563 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9565 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
9567 (frv_current_sos): Allocate lm_info_frv with new.
9568 (frv_relocate_main_executable): Free lm_info_frv with delete,
9570 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
9572 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9574 * solib-frv.c (struct lm_info_frv): Fix indentation.
9576 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9578 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
9580 (dsbt_current_sos): Allocate lm_info_dsbt with new.
9581 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
9582 and allocate with new.
9583 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
9585 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9587 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
9588 <filename, member_name>: Change type to std::string.
9589 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
9590 (library_list_start_library): Allocate lm_info_aix with new.
9591 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
9592 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
9593 with copy constructor.
9595 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9597 * solist.h (struct lm_info): Remove.
9598 (struct lm_info_base): New class.
9599 (struct so_list) <lm_info>: Change type to lm_info_base *.
9600 * nto-tdep.c (struct lm_info): Remove.
9602 * solib-aix.c (struct lm_info): Rename to ...
9603 (struct lm_info_aix): ... this. Extend lm_info_base.
9604 (lm_info_p): Rename to ...
9605 (lm_info_aix_p): ... this, and adjust.
9606 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
9607 solib_aix_parse_libraries, library_list_start_library,
9608 solib_aix_free_library_list, solib_aix_parse_libraries,
9609 solib_aix_get_library_list,
9610 solib_aix_relocate_section_addresses, solib_aix_free_so,
9611 solib_aix_get_section_offsets,
9612 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
9614 (struct solib_aix_inferior_data) <library_list>: Adjust.
9615 * solib-darwin.c (struct lm_info): Rename to ...
9616 (struct lm_info_darwin): ... this. Extend lm_info_base.
9617 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
9618 * solib-dsbt.c (struct lm_info): Rename to ...
9619 (struct lm_info_dsbt): ... this. Extend lm_info_base.
9620 (struct dsbt_info) <main_executable_lm_info): Adjust.
9621 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
9622 dsbt_relocate_section_addresses): Adjust.
9623 * solib-frv.c (struct lm_info): Rename to ...
9624 (struct lm_info_frv): ... this. Extend lm_info_base.
9625 (main_executable_lm_info): Adjust.
9626 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
9627 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
9628 find_canonical_descriptor_in_load_object,
9629 frv_fdpic_find_canonical_descriptor): Adjust.
9630 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
9632 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
9633 svr4_clear_so, svr4_copy_library_list,
9634 library_list_start_library, svr4_default_sos, svr4_read_so_list,
9635 svr4_current_sos, svr4_fetch_objfile_link_map,
9636 solist_update_incremental): Adjust.
9637 * solib-svr4.h (struct lm_info_svr4): Move here from
9639 * solib-target.c (struct lm_info): Rename to ...
9640 (struct lm_info_target): ... this. Extend lm_info_base.
9641 (lm_info_p): Rename to ...
9642 (lm_info_target_p): ... this.
9643 (solib_target_parse_libraries, library_list_start_segment,
9644 library_list_start_section, library_list_start_library,
9645 library_list_end_library, solib_target_free_library_list,
9646 solib_target_current_sos, solib_target_free_so,
9647 solib_target_relocate_section_addresses): Adjust.
9648 * windows-nat.c (struct lm_info): Rename to ...
9649 (struct lm_info_windows): ... this. Extend lm_info_base.
9650 (windows_make_so, handle_load_dll, handle_unload_dll,
9651 windows_xfer_shared_libraries): Adjust.
9653 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9655 * solib-darwin.c (struct darwin_so_list): Remove.
9656 (darwin_current_sos): Allocate an so_list object instead of a
9657 darwin_so_list, separately allocate an lm_info object.
9658 (darwin_free_so): Free lm_info.
9660 2017-04-28 John Baldwin <jhb@FreeBSD.org>
9662 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
9663 with fprintf_filtered.
9665 2017-04-28 Yao Qi <yao.qi@linaro.org>
9667 * regcache.c (regcache::regcache): New function.
9668 (regcache::~regcache): New function.
9669 (regcache_xmalloc_1): Remove.
9670 (regcache_xmalloc): Call new regcache.
9671 (regcache_xfree): Call delete regcache.
9672 (get_thread_arch_aspace_regcache): Call new regcache.
9674 2017-04-28 Yao Qi <yao.qi@linaro.org>
9676 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
9677 lwp instead of ptid_get_lwp.
9679 2017-04-28 Yao Qi <yao.qi@linaro.org>
9681 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
9682 lwp_info instead of getting from inferior_ptid.
9684 2017-04-27 Keith Seitz <keiths@redhat.com>
9686 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
9687 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
9688 (CV_CONVERSION_BADNESS): Define.
9689 (rank_one_type): Remove overly restrictive rvalue reference
9691 Add cv-qualifier checks and subranks for type equality.
9692 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
9693 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
9694 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
9696 2017-04-27 Simon Marchi <simon.marchi@ericsson.com>
9698 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
9699 count when creating the object.
9701 2017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
9702 Ulrich Weigand <uweigand@de.ibm.com>
9704 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
9705 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
9707 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
9708 (process_xcoff_symbol): Likewise.
9709 (scan_xcoff_symtab): Likewise.
9711 2017-04-26 Alan Hayward <alan.hayward@arm.com>
9713 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
9714 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
9715 (ia64_access_reg): Use get_frame_register_unsigned.
9716 (ia64_access_rse_reg): Likewise.
9717 (ia64_libunwind_frame_prev_register): Likewise.
9719 2017-04-26 Jiong Wang <jiong.wang@arm.com>
9721 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
9722 * gdbarch.c: Regenerated.
9723 * gdbarch.h: Regenerated.
9724 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
9725 visibility external.
9726 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
9727 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
9728 (enum cfa_how_kind): Move to ...
9729 (struct dwarf2_frame_state_reg_info): Likewise.
9730 (struct dwarf2_frame_state): Likewise.
9731 * dwarf2-frame.h: ... here.
9732 (dwarf2_frame_state_alloc_regs): New declaration.
9733 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
9734 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
9736 2017-04-26 Alan Hayward <alan.hayward@arm.com>
9738 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
9739 regcache_raw_read_unsigned.
9740 (xtensa_pseudo_register_write): Likewise.
9742 2017-04-26 Alan Hayward <alan.hayward@arm.com>
9744 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
9745 (nds32_pseudo_register_write): Likewise.
9747 2017-04-25 Yao Qi <yao.qi@linaro.org>
9749 * regcache.c (struct regcache) <readonly_p>: Change its type
9751 (regcache_xmalloc_1): Update parameter type and callers update.
9753 2017-04-25 Yao Qi <yao.qi@linaro.org>
9755 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
9756 set_gdbarch_wchar_bit.
9757 * arm-tdep.c (arm_gdbarch_init): Likewise.
9759 2017-04-25 Pedro Alves <palves@redhat.com>
9761 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
9762 (BothAreRelocatable, memcopy, memmove): Don't define.
9763 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
9766 2017-04-25 Pedro Alves <palves@redhat.com>
9768 * common/common-defs.h: Include "common/poison.h".
9769 * common/function-view.h: (Not, Or, Requires): Move to traits.h
9771 * common/poison.h: New file.
9772 * common/traits.h: Include <type_traits>.
9773 (Not, Or, Requires): New, moved from common/function-view.h.
9775 2017-04-25 Pedro Alves <palves@redhat.com>
9777 * breakpoint.h (struct breakpoint): In-class initialize all
9778 fields. Make boolean fields "bool".
9779 * breakpoint.c (init_raw_breakpoint_without_location): Remove
9780 memset call and initializations no longer necessary.
9782 2017-04-25 Pedro Alves <palves@redhat.com>
9784 * btrace.c (pt_btrace_insn_flags): Change parameter type to
9786 (pt_btrace_insn): New function.
9787 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
9789 2017-04-25 Pedro Alves <palves@redhat.com>
9791 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
9792 "base" field and inherit from "bp_location" instead. Add
9794 (allocate_location_exception): Use new non-default ctor.
9795 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
9796 (init_bp_location): Convert to ...
9797 (bp_location::bp_location): ... this new ctor, and remove memset
9799 (base_breakpoint_allocate_location): Use the new non-default ctor.
9800 * breakpoint.h (bp_location): Now a class. Declare default and
9801 non-default ctors. In-class initialize all members.
9802 (init_bp_location): Remove declaration.
9804 2017-04-25 Pedro Alves <palves@redhat.com>
9806 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
9807 assignment operator.
9809 2017-04-24 Yao Qi <yao.qi@linaro.org>
9811 * doublest.c (convert_doublest_to_floatformat): Call
9812 floatformat_totalsize_bytes.
9814 2017-04-22 Tom Tromey <tom@tromey.com>
9816 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
9818 * stack.c (print_frame): Use ui_out_emit_list.
9819 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
9821 * mi/mi-main.c (print_one_inferior)
9822 (mi_cmd_data_list_register_names)
9823 (mi_cmd_data_list_register_values, mi_cmd_list_features)
9824 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
9826 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
9827 (mi_output_solib_attribs): Use ui_out_emit_list,
9829 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
9830 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
9831 (mi_cmd_stack_list_args, list_args_or_locals): Use
9833 * disasm.c (do_assembly_only): Use ui_out_emit_list.
9834 * breakpoint.c (print_solib_event, output_thread_groups): Use
9837 2017-04-22 Tom Tromey <tom@tromey.com>
9839 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
9840 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
9841 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
9843 2017-04-22 Tom Tromey <tom@tromey.com>
9845 * tracepoint.c (tvariables_info_1)
9846 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
9848 2017-04-22 Tom Tromey <tom@tromey.com>
9850 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
9851 annotate_arg_emitter.
9852 * breakpoint.c (print_mention_watchpoint)
9853 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
9854 * annotate.h (struct annotate_arg_emitter): New.
9856 2017-04-22 Tom Tromey <tom@tromey.com>
9858 * record-btrace.c (record_btrace_insn_history)
9859 (record_btrace_insn_history_range, record_btrace_call_history)
9860 (record_btrace_call_history_range): Use ui_out_emit_tuple.
9861 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
9863 * stack.c (print_frame_info): Use ui_out_emit_tuple.
9864 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
9865 * skip.c (skip_info): Use ui_out_emit_tuple.
9866 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
9867 * progspace.c (print_program_space): Use ui_out_emit_tuple.
9868 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
9869 * osdata.c (info_osdata): Use ui_out_emit_tuple.
9870 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
9872 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
9873 (output_register, mi_cmd_data_read_memory)
9874 (mi_cmd_data_read_memory_bytes, mi_load_progress)
9875 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
9876 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
9877 Use ui_out_emit_tuple.
9878 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
9880 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
9881 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
9882 * linux-thread-db.c (info_auto_load_libthread_db): Use
9884 * inferior.c (print_inferior): Use ui_out_emit_tuple.
9885 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
9886 * disasm.c (do_mixed_source_and_assembly_deprecated)
9887 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
9888 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
9889 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
9890 * breakpoint.c (print_one_breakpoint_location)
9891 (print_one_breakpoint): Use ui_out_emit_tuple.
9892 * auto-load.c (print_script, info_auto_load_cmd): Use
9894 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
9896 2017-04-21 Simon Marchi <simon.marchi@ericsson.com>
9898 * thread.c (print_thread_info_1): Remove dead code.
9900 2017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
9902 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
9904 * arm-tdep.c (selftests::arm_record_test): Likewise.
9906 2017-04-21 Yao Qi <yao.qi@linaro.org>
9908 * regcache.c (regcache_restore): Remove argument 2. Replace
9909 argument 3 with regcache. Get register status from
9910 src->register_status and get register contents from
9911 register_buffer (src, regnum).
9912 (regcache_cpy): Update.
9914 2017-04-19 Pedro Alves <palves@redhat.com>
9916 * gdbthread.h (thread): Add missing closing parenthesis in
9919 2017-04-19 Pedro Alves <palves@redhat.com>
9921 * common/refcounted-object.h: New file.
9922 * gdbthread.h: Include "common/refcounted-object.h".
9923 (thread_info): Inherit from refcounted_object and add comments.
9924 (thread_info::incref, thread_info::decref)
9925 (thread_info::m_refcount): Delete.
9926 (thread_info::deletable): Use the refcounted_object::refcount()
9928 * inferior.c (current_inferior_): Add comment.
9929 (set_current_inferior): Increment/decrement refcounts.
9930 (prune_inferiors, remove_inferior_command): Skip inferiors marked
9931 not-deletable instead of comparing with the current inferior.
9932 (initialize_inferiors): Increment the initial inferior's refcount.
9933 * inferior.h (struct inferior): Forward declare.
9934 Include "common/refcounted-object.h".
9935 (current_inferior, set_current_inferior): Move declaration to
9936 before struct inferior's definition, and fix comment.
9937 (inferior): Inherit from refcounted_object. Add comments.
9938 * thread.c (switch_to_thread_no_regs): Reference the thread's
9939 inferior pointer directly instead of doing a ptid lookup.
9940 (switch_to_no_thread): New function.
9941 (switch_to_thread(thread_info *)): New function, factored out
9943 (switch_to_thread(ptid_t)): ... this.
9944 (restore_current_thread): Delete.
9945 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
9946 fields, and add 'inf' field.
9947 (do_restore_current_thread_cleanup): Check whether old->inf is
9948 alive instead of looking up an inferior by ptid. Use
9949 switch_to_thread and switch_to_no_thread.
9950 (restore_current_thread_cleanup_dtor): Use old->inf directly
9951 instead of lookup up an inferior by id. Decref the inferior.
9952 Don't restore 'removable'.
9953 (make_cleanup_restore_current_thread): Same the inferior pointer
9954 in old, instead of the inferior number. Incref the inferior.
9955 Don't save/clear 'removable'.
9957 2017-04-19 Pedro Alves <palves@redhat.com>
9959 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9960 unittests/scoped_restore-selftests.c.
9961 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
9962 * common/scoped_restore.h (scoped_restore_base): Make "class".
9963 (scoped_restore_base::release): New public method.
9964 (scoped_restore_base::scoped_restore_base): New protected ctor.
9965 (scoped_restore_base::m_saved_var): New protected field.
9966 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
9967 scoped_restore_base base class instead of m_saved_var directly.
9968 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
9969 (scoped_restore_tmpl::scoped_restore_tmpl(const
9970 scoped_restore_tmpl<T>&)): Likewise.
9971 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
9973 (scoped_restore_tmpl::saved_var): New method.
9974 (scoped_restore_tmpl::m_saved_var): Delete.
9975 * inferior.h (inferior::detaching): Now a bool.
9976 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
9978 * unittests/scoped_restore-selftests.c: New file.
9980 2017-04-19 Pedro Alves <palves@redhat.com>
9982 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
9983 Re-sort in alphabetic order.
9985 2017-04-18 Pedro Alves <palves@redhat.com>
9987 * xml-support.c (obstack_xml_printf): Delete.
9988 * xml-support.h (obstack_xml_printf): Delete.
9990 2017-04-18 Pedro Alves <palves@redhat.com>
9992 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
9993 vdebug, verror, body_text, start_element, end_element, name,
9994 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
9995 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
9996 is_xinclude>: Make private and add m_ prefix.
9997 (gdb_xml_parser::body_text): New method, based on ...
9998 (gdb_xml_body_text): ... this. Adjust.
9999 (gdb_xml_parser::vdebug): New method, based on ...
10000 (gdb_xml_debug): ... this. Adjust.
10001 (gdb_xml_parser::verror): New method, based on ...
10002 (gdb_xml_error): ... this. Adjust.
10003 (gdb_xml_parser::start_element): New method, based on ...
10004 (gdb_xml_start_element): ... this. Adjust.
10005 (gdb_xml_start_element_wrapper): Defer to
10006 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
10007 (gdb_xml_parser::end_element): New method, based on ...
10008 (gdb_xml_end_element_wrapper): ... this. Adjust.
10009 (gdb_xml_parser::~gdb_xml_parser): Adjust.
10010 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
10011 (gdb_xml_parser::use_dtd): New method, based on ...
10012 (gdb_xml_use_dtd): ... this. Adjust.
10013 (gdb_xml_parser::parse): New method, based on ...
10014 (gdb_xml_parse): ... this. Adjust.
10015 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
10016 (xinclude_start_include): Adjust to call the parser's name method.
10017 (xml_xinclude_default, xml_xinclude_start_doctype)
10018 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
10020 (xml_process_xincludes): Adjust to call parser methods.
10021 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
10024 2017-04-18 Pedro Alves <palves@redhat.com>
10026 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
10027 gdb::optional<std::string>.
10028 * xml-support.c: Include <string>.
10029 (scope_level::scope_level(scope_level &&))
10030 (scope_level::~scope_level): Delete.
10031 (scope_level::body): Now a std::string.
10032 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
10033 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
10035 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
10036 (xinclude_parsing_data::output): Now a std::string reference.
10037 (xinclude_start_include): Adjust.
10038 (xml_xinclude_default): Adjust.
10039 (xml_process_xincludes): Add 'output' parameter, and return bool.
10040 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
10042 * xml-tdesc.c: Include <unordered_map> and <string>.
10043 (tdesc_xml_cache): Delete.
10044 (tdesc_xml_cache_s): Delete.
10045 (xml_cache): Now an std::unordered_map.
10046 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
10047 (target_fetch_description_xml): Change return type to
10048 gdb::optional<std::string>, and adjust.
10049 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
10050 (target_fetch_description_xml): Change return type to
10051 gdb::optional<std::string>.
10053 2017-04-18 Pedro Alves <palves@redhat.com>
10055 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10056 unittests/optional-selftests.c.
10057 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
10058 * unittests/optional-selftests.c: New file.
10059 * unittests/optional/assignment/1.cc: New file.
10060 * unittests/optional/assignment/2.cc: New file.
10061 * unittests/optional/assignment/3.cc: New file.
10062 * unittests/optional/assignment/4.cc: New file.
10063 * unittests/optional/assignment/5.cc: New file.
10064 * unittests/optional/assignment/6.cc: New file.
10065 * unittests/optional/assignment/7.cc: New file.
10066 * unittests/optional/cons/copy.cc: New file.
10067 * unittests/optional/cons/default.cc: New file.
10068 * unittests/optional/cons/move.cc: New file.
10069 * unittests/optional/cons/value.cc: New file.
10070 * unittests/optional/in_place.cc: New file.
10071 * unittests/optional/observers/1.cc: New file.
10072 * unittests/optional/observers/2.cc: New file.
10074 2017-04-18 Pedro Alves <palves@redhat.com>
10076 * common/gdb_optional.h: Include common/traits.h.
10077 (in_place_t): New type.
10078 (in_place): New constexpr variable.
10079 (optional::optional): Remove member initialization of
10081 (optional::optional(in_place_t...)): New constructor.
10082 (optional::~optional): Use reset.
10083 (optional::optional(const optional&)): New.
10084 (optional::optional(const optional&&)): New.
10085 (optional::optional(T &)): New.
10086 (optional::optional(T &&)): New.
10087 (operator::operator=(const optional &)): New.
10088 (operator::operator=(optional &&)): New.
10089 (operator::operator= (const T &))
10090 (operator::operator= (T &&))
10091 (operator::emplace (Args &&... args)): Return a T&. Use reset.
10092 (operator::reset): New.
10093 (operator::m_instantiated):: Add in-class initializer.
10094 * common/traits.h: Include <type_traits>.
10095 (struct And): New types.
10097 2017-04-18 Pedro Alves <palves@redhat.com>
10099 * xml-support.c: Include <vector>.
10100 (scope_level::scope_level(const gdb_xml_element *))
10101 (scope_level::scope_level(scope_level&&)): New.
10102 (scope_level::~scope_level): New.
10103 (scope_level_s): Delete.
10104 (gdb_xml_parser::scopes): Now a std::vector.
10105 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
10107 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
10108 scope cleanup code.
10109 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
10110 of the scopes member. Use std::vector::emplace_back.
10112 2017-04-18 Pedro Alves <palves@redhat.com>
10114 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
10116 (gdb_xml_end_element): Change type of first parameter.
10117 (gdb_xml_cleanup): Rename to ...
10118 (gdb_xml_parser::~gdb_xml_parser): ... this.
10119 (gdb_xml_create_parser_and_cleanup): Delete with ...
10120 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
10122 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
10123 using gdb_xml_create_parser_and_cleanup.
10124 (xinclude_parsing_data): Add ctor/dtor.
10125 (xml_xinclude_cleanup): Delete.
10126 (xml_process_xincludes): Create a local xinclude_parsing_data
10127 instead of heap-allocating one. Create a local gdb_xml_parser
10128 instead of heap-allocating one with
10129 gdb_xml_create_parser_and_cleanup.
10131 2017-04-18 John Baldwin <jhb@FreeBSD.org>
10134 * fbsd-nat.c (resume_one_thread_cb): Remove.
10135 (resume_all_threads_cb): Remove.
10136 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
10137 iterate_over_threads.
10139 2017-04-17 Joel Brobecker <brobecker@adacore.com>
10141 * NEWS: Create a new section for the next release branch.
10142 Rename the section of the current branch, now that it has
10145 2017-04-17 Joel Brobecker <brobecker@adacore.com>
10147 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
10148 * version.in: Bump version to 8.0.50.DATE-git.
10150 2017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
10153 * windows-nat.c (windows_create_inferior): Declare 'allargs'
10154 independently of the host, and fix build breakage on Cygwin.
10156 2017-04-13 Pedro Alves <palves@redhat.com>
10158 * inferior.c (free_inferior): Convert to ...
10159 (inferior::~inferior): ... this dtor.
10160 (inferior::inferior): New ctor, factored out from ...
10161 (add_inferior_silent): ... here. Allocate the inferior with a new
10163 (delete_inferior): Call delete instead of free_inferior.
10164 * inferior.h (gdb_environ, continuation): Forward declare.
10165 (inferior): Now a class. Add in-class initialization to all
10166 members. Make boolean fields bool, except 'detaching'.
10167 (inferior::inferior): New explicit ctor.
10168 (inferior::~inferior): New.
10170 2017-04-13 Pedro Alves <palves@redhat.com>
10172 * inferior.c (init_inferior_list): Delete.
10173 * inferior.h (init_inferior_list): Delete.
10175 2017-04-13 Pedro Alves <palves@redhat.com>
10178 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
10179 (top level): Call it twice, with different thread sets.
10181 2017-04-13 Pedro Alves <palves@redhat.com>
10183 * thread.c: Include <algorithm>.
10184 (thread_array_cleanup): Delete.
10185 (scoped_inc_dec_ref): New class.
10186 (live_threads_count): New function.
10187 (set_thread_refcount): Delete.
10188 (tp_array_compar_ascending): Now a bool.
10189 (tp_array_compar): Convert to a std::sort comparison function.
10190 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
10191 and live_threads_count.
10193 2017-04-13 Pedro Alves <palves@redhat.com>
10195 * infrun.c (follow_fork_inferior): Also switch the current
10198 2017-04-13 Pedro Alves <palves@redhat.com>
10200 * breakpoint.c (watch_command_1): Save watchpoint-frame info
10201 before calling create_internal_breakpoint.
10203 2017-04-13 Pedro Alves <palves@redhat.com>
10205 * fork-child.c (execv_argv): New class.
10206 (breakup_args): Refactored as ...
10207 (execv_argv::init_for_no_shell): .. this method of execv_argv.
10208 Copy arguments to storage and replace separators with NULL
10209 terminators in place.
10210 (escape_bang_in_quoted_argument): Adjust to return bool.
10211 (execv_argv::execv_argv): New ctor.
10212 (execv_argv::init_for_shell): New method, factored out from
10213 fork_inferior. Don't strdup strings into the vector.
10214 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
10215 Remove free_vector_argv call.
10217 2017-04-13 Yao Qi <yao.qi@linaro.org>
10219 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
10222 2017-04-13 Yao Qi <yao.qi@linaro.org>
10224 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
10225 * rx-tdep.c (rx_gdbarch_init): Likewise.
10227 2017-04-13 Pedro Alves <palves@redhat.com>
10229 * breakpoint.h (struct breakpoint): Reindent.
10231 2017-04-13 Pedro Alves <palves@redhat.com>
10233 * breakpoint.c (bp_location): Rename to ...
10234 (bp_locations): ... this. All references updated.
10235 (bp_location_count): Rename to ...
10236 (bp_locations_count): ... this. All references updated.
10237 (bp_location_placed_address_before_address_max): Rename to ...
10238 (bp_locations_placed_address_before_address_max): ... this. All
10239 references updated.
10240 (bp_location_shadow_len_after_address_max): Rename to ...
10241 (bp_locations_shadow_len_after_address_max): ... this. All
10242 references updated.
10243 (bp_location_compare_addrs): Rename to ...
10244 (bp_locations_compare_addrs): ... this. All references updated.
10245 (bp_location_compare):Rename to ...
10246 (bp_locations_compare): ... this. All references updated.
10247 (bp_location_target_extensions_update): Rename to ...
10248 (bp_locations_target_extensions_update): ... this. All references
10251 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
10253 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
10254 * common/common.m4: Check headers 'termios.h', 'termio.h' and
10256 * common/gdb_termios.h: New file, with parts of "terminal.h".
10257 * inflow.c: Include "gdb_termios.h".
10258 * ser-unix.c: Include "gdb_termios.h".
10259 * terminal.h: Move terminal-related defines to
10260 "common/gdb_termios.h".
10262 2017-04-12 Tom Tromey <tom@tromey.com>
10264 * probe.c (parse_probes): Update.
10265 * location.h (delete_event_location): Don't declare.
10266 (event_location_deleter::operator()): Update.
10267 * location.c (event_location_deleter::operator()): Rename from
10268 delete_event_location.
10269 * linespec.h (linespec_result) <location>: Change type to
10271 * linespec.c (canonicalize_linespec, event_location_to_sals)
10272 (decode_objc): Update.
10273 (linespec_result): Don't call delete_event_location.
10274 * breakpoint.c (create_breakpoints_sal)
10275 (bkpt_probe_create_sals_from_location)
10276 (strace_marker_create_sals_from_location): Update.
10278 2017-04-12 Tom Tromey <tom@tromey.com>
10280 * linespec.h (struct linespec_result): Add constructor and
10282 (init_linespec_result, destroy_linespec_result)
10283 (make_cleanup_destroy_linespec_result): Don't declare.
10284 * linespec.c (init_linespec_result): Remove.
10285 (linespec_result::~linespec_result): Rename from
10286 destroy_linespec_result. Update.
10287 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
10289 * breakpoint.c (create_breakpoint, break_range_command)
10290 (decode_location_default): Update.
10291 * ax-gdb.c (agent_command_1): Update.
10293 2017-04-12 Tom Tromey <tom@tromey.com>
10295 * remote.c (remote_download_tracepoint): Update.
10296 * python/py-breakpoint.c (bppy_get_location): Update.
10297 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
10298 (gdbscm_breakpoint_location): Update.
10299 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
10300 * breakpoint.h (struct breakpoint) <location, location_range_end>:
10301 Change type to event_location_up.
10302 * breakpoint.c (create_overlay_event_breakpoint)
10303 (create_longjmp_master_breakpoint)
10304 (create_std_terminate_master_breakpoint)
10305 (create_exception_master_breakpoint)
10306 (breakpoint_event_location_empty_p, print_breakpoint_location)
10307 (print_one_breakpoint_location, create_thread_event_breakpoint)
10308 (init_breakpoint_sal, create_breakpoint)
10309 (print_recreate_ranged_breakpoint, break_range_command)
10310 (init_ada_exception_breakpoint, say_where): Update.
10311 (base_breakpoint_dtor): Don't call delete_event_location.
10312 (bkpt_print_recreate, tracepoint_print_recreate)
10313 (dprintf_print_recreate, update_static_tracepoint)
10314 (breakpoint_re_set_default): Update.
10316 2017-04-12 Tom Tromey <tom@tromey.com>
10318 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
10319 type of "to_do". Update.
10320 (compute_stack_depth): Use std::vector.
10322 2017-04-12 Tom Tromey <tom@tromey.com>
10324 * printcmd.c (find_instruction_backward): Use std::vector.
10326 2017-04-12 Tom Tromey <tom@tromey.com>
10328 * symfile.c (objfilep): Remove typedef.
10329 (reread_symbols): Use a std::vector.
10331 2017-04-12 Tom Tromey <tom@tromey.com>
10333 * mi/mi-main.c (exec_direction_forward): Remove.
10334 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
10335 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
10337 * guile/guile.c (guile_repl_command, guile_command)
10338 (gdbscm_execute_gdb_command): Use scoped_restore.
10339 * go-exp.y (go_parse): Use scoped_restore.
10340 * d-exp.y (d_parse): Use scoped_restore.
10341 * cli/cli-decode.c (cmd_func): Use scoped_restore.
10342 * c-exp.y (c_parse): Use scoped_restore.
10344 2017-04-12 Tom Tromey <tom@tromey.com>
10346 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
10347 (mi_parse): Update return type.
10348 (mi_parse_free): Remove.
10349 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
10350 (mi_parse::~mi_parse): Rename from mi_parse_free.
10351 (mi_parse_cleanup): Remove.
10352 (mi_parse): Return a unique_ptr. Use new.
10353 * mi/mi-main.c (mi_execute_command): Update.
10355 2017-04-12 Tom Tromey <tom@tromey.com>
10357 * location.c (explicit_location_lex_one): Return a
10358 unique_xmalloc_ptr.
10359 (string_to_explicit_location): Update. Remove cleanups.
10361 2017-04-12 Tom Tromey <tom@tromey.com>
10363 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
10364 (compare_value_and_voffset): Change type. Update.
10365 (compute_vtable_size): Change type of "offset_vec".
10366 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
10367 (gnuv3_get_typeid): Remove extraneous declaration.
10369 2017-04-12 Tom Tromey <tom@tromey.com>
10371 * charset.h (wchar_iterator): Fix comment.
10373 2017-04-12 Tom Tromey <tom@tromey.com>
10375 * charset.c (iconv_wrapper): New class.
10376 (cleanup_iconv): Remove.
10377 (convert_between_encodings): Use it.
10379 2017-04-12 Tom Tromey <tom@tromey.com>
10381 * symfile.h (increment_reading_symtab): Update type.
10382 * symfile.c (decrement_reading_symtab): Remove.
10383 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
10384 * psymtab.c (psymtab_to_symtab): Update.
10385 * dwarf2read.c (dw2_instantiate_symtab): Update.
10387 2017-04-12 Tom Tromey <tom@tromey.com>
10389 * jit.c (struct jit_reader): Declare separately. Add constructor
10390 and destructor. Change type of "handle".
10391 (loaded_jit_reader): Define separately.
10392 (jit_reader_load): Update. New "new".
10393 (jit_reader_unload_command): Use "delete".
10394 * gdb-dlfcn.h (struct dlclose_deleter): New.
10395 (gdb_dlhandle_up): New typedef.
10396 (gdb_dlopen, gdb_dlsym): Update types.
10397 (gdb_dlclose): Remove.
10398 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
10399 (gdb_dlsym): Change type of "handle".
10400 (make_cleanup_dlclose): Remove.
10401 (dlclose_deleter::operator()): Rename from gdb_dlclose.
10402 * compile/compile-c-support.c (load_libcc): Update.
10404 2017-04-12 Tom Tromey <tom@tromey.com>
10406 * symtab.h (find_pcs_for_symtab_line): Change return type.
10407 * symtab.c (find_pcs_for_symtab_line): Change return type.
10408 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
10409 type of "vec". Update.
10410 (ltpy_get_pcs_for_line): Update.
10411 * linespec.c (decode_digits_ordinary): Update.
10413 2017-04-12 Tom Tromey <tom@tromey.com>
10415 * tracepoint.c (actions_command): Update.
10416 * python/python.c (python_command, python_interactive_command):
10418 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
10419 * guile/guile.c (guile_command): Update.
10420 * defs.h (read_command_lines, read_command_lines_1): Return
10422 (command_lines_deleter): New struct.
10423 (command_line_up): New typedef.
10424 * compile/compile.c (compile_code_command)
10425 (compile_print_command): Update.
10426 * cli/cli-script.h (get_command_line, copy_command_lines): Return
10428 (make_cleanup_free_command_lines): Remove.
10429 * cli/cli-script.c (get_command_line, read_command_lines_1)
10430 (copy_command_lines): Return command_line_up.
10431 (while_command, if_command, read_command_lines, define_command)
10432 (document_command): Update.
10433 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
10435 * breakpoint.h (breakpoint_set_commands): Change type of
10437 * breakpoint.c (breakpoint_set_commands): Change type of
10438 "commands". Update.
10439 (do_map_commands_command, update_dprintf_command_list)
10440 (create_tracepoint_from_upload): Update.
10442 2017-04-12 Tom Tromey <tom@tromey.com>
10444 * tracepoint.c (scope_info): Update.
10445 * spu-tdep.c (spu_catch_start): Update.
10446 * python/python.c (gdbpy_decode_line): Update.
10447 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
10448 * python/py-breakpoint.c (bppy_init): Update.
10449 * probe.c (parse_probes): Update.
10450 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
10451 * location.h (event_location_deleter): New struct.
10452 (event_location_up): New typedef.
10453 (new_linespec_location, new_address_location, new_probe_location)
10454 (new_explicit_location, copy_event_location)
10455 (string_to_event_location, string_to_event_location_basic)
10456 (string_to_explicit_location): Update return type.
10457 (make_cleanup_delete_event_location): Remove.
10458 * location.c (new_linespec_location, new_address_location)
10459 (new_probe_location, new_explicit_location, copy_event_location):
10460 Return event_location_up.
10461 (delete_event_location_cleanup)
10462 (make_cleanup_delete_event_location): Remove.
10463 (string_to_explicit_location, string_to_event_location_basic)
10464 (string_to_event_location): Return event_location_up.
10465 * linespec.c (canonicalize_linespec, event_location_to_sals)
10466 (decode_line_with_current_source)
10467 (decode_line_with_last_displayed, decode_objc): Update.
10468 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
10469 * completer.c (location_completer): Update.
10470 * cli/cli-cmds.c (edit_command, list_command): Update.
10471 * breakpoint.c (create_overlay_event_breakpoint)
10472 (create_longjmp_master_breakpoint)
10473 (create_std_terminate_master_breakpoint)
10474 (create_exception_master_breakpoint)
10475 (create_thread_event_breakpoint): Update.
10476 (init_breakpoint_sal): Update. Remove some dead code.
10477 (create_breakpoint_sal): Change type of "location". Update.
10478 (create_breakpoints_sal, create_breakpoint, break_command_1)
10479 (dprintf_command, break_range_command, until_break_command)
10480 (init_ada_exception_breakpoint)
10481 (strace_marker_create_sals_from_location)
10482 (update_static_tracepoint, trace_command, ftrace_command)
10483 (strace_command, create_tracepoint_from_upload): Update.
10484 * break-catch-throw.c (re_set_exception_catchpoint): Update.
10485 * ax-gdb.c (agent_command_1): Update.
10487 2017-04-12 Pedro Alves <palves@redhat.com>
10489 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
10490 * configure.tgt: Handle i[34567]86-*-go32* and
10491 i[34567]86-*-msdosdjgpp*.
10492 * i386-tdep.c (i386_svr4_reg_to_regnum):
10494 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
10496 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
10497 * i386-go32-tdep.c: New file.
10498 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
10501 2017-04-12 Simon Marchi <simon.marchi@ericsson.com>
10503 * aix-thread.c (pd_status2str): Change return type to const char *.
10505 2017-04-12 Pedro Alves <palves@redhat.com>
10507 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
10508 calls to set_gdbarch_gnu_triplet_regexp.
10510 2017-04-12 Pedro Alves <palves@redhat.com>
10513 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
10515 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
10516 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
10517 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
10518 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
10519 * gdbarch.h, gdbarch.c: Regenerate.
10520 * aarch64-tdep.c (aarch64_gdbarch_init): Override
10521 gdbarch_wchar_bit and gdbarch_wchar_signed.
10522 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
10523 * arm-tdep.c (arm_gdbarch_init): Likewise.
10524 * avr-tdep.c (avr_gdbarch_init): Likewise.
10525 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
10526 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
10527 * i386-tdep.c (i386_go32_init_abi): Likewise.
10528 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
10529 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
10530 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
10531 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
10532 * sh-tdep.c (sh_gdbarch_init): Likewise.
10533 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
10534 * sparc64-tdep.c (sparc64_init_abi): Likewise.
10535 * windows-tdep.c (windows_init_abi): Likewise.
10536 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
10538 2017-04-12 Pedro Alves <palves@redhat.com>
10541 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
10542 cplus_primitive_type_char32_t>: New enum values.
10543 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
10544 and cplus_primitive_type_char32_t.
10545 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
10546 32, use the archtecture's built-in type for char16_t and char32_t,
10547 respectively. Otherwise, fallback to init_integer_type as before,
10548 but make the type unsigned, and issue a complaint.
10549 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
10551 2017-04-12 Alan Hayward <alan.hayward@arm.com>
10553 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
10554 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
10556 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
10558 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
10561 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
10563 * common/common-utils.c (free_vector_argv): New function.
10564 * common/common-utils.h: Include <vector>.
10565 (free_vector_argv): New prototype.
10566 * darwin-nat.c (darwin_create_inferior): Rewrite function
10567 prototype in order to constify "exec_file" and accept a
10568 "std::string" for "allargs".
10569 * fork-child.c: Include <vector>.
10570 (breakup_args): Rewrite function, using C++.
10571 (fork_inferior): Rewrite function header, constify "exec_file_arg"
10572 and accept "std::string" for "allargs". Update the code to
10573 calculate "argv" based on "allargs". Update calls to "exec_fun"
10575 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
10576 order to constify "exec_file" and accept a "std::string" for
10578 * go32-nat.c (go32_create_inferior): Likewise.
10579 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
10580 * infcmd.c (run_command_1): Constify "exec_file". Use
10581 "std::string" for inferior arguments.
10582 * inferior.h (fork_inferior): Update prototype.
10583 * linux-nat.c (linux_nat_create_inferior): Rewrite function
10584 prototype in order to constify "exec_file" and accept a
10585 "std::string" for "allargs".
10586 * nto-procfs.c (procfs_create_inferior): Likewise.
10587 * procfs.c (procfs_create_inferior): Likewise.
10588 * remote-sim.c (gdbsim_create_inferior): Likewise.
10589 * remote.c (extended_remote_run): Update code to accept
10590 "std::string" as argument.
10591 (extended_remote_create_inferior): Rewrite function prototype in
10592 order to constify "exec_file" and accept a "std::string" for
10594 * rs6000-nat.c (super_create_inferior): Likewise.
10595 (rs6000_create_inferior): Likewise.
10596 * target.h (struct target_ops) <to_create_inferior>: Likewise.
10597 * windows-nat.c (windows_create_inferior): Likewise.
10599 2017-04-11 Pedro Alves <palves@redhat.com>
10601 * thread.c: Fix whitespace throughout.
10603 2017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
10605 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
10607 2017-04-11 Alan Hayward <alan.hayward@arm.com>
10609 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
10611 2017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
10614 * osdata.c (info_osdata): Check if 'type' is an empty string
10617 2017-04-10 Pedro Alves <palves@redhat.com>
10619 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
10620 (ptid_to_global_thread_id, in_thread_list)
10621 (do_captured_list_thread_ids, set_resumed, set_running)
10622 (set_executing, set_stop_requested, finish_thread_state)
10623 (validate_registers_access, can_access_registers_ptid)
10624 (print_thread_info_1, switch_to_thread)
10625 (do_restore_current_thread_cleanup)
10626 (make_cleanup_restore_current_thread, thread_command)
10627 (thread_name_command): Use operator== instead of ptid_equal.
10629 2017-04-10 Pedro Alves <palves@redhat.com>
10631 * thread.c (struct current_thread_cleanup) <next>: Delete field.
10632 (current_thread_cleanup_chain): Delete.
10633 (restore_current_thread_cleanup_dtor)
10634 (make_cleanup_restore_current_thread): Remove references to
10635 current_thread_cleanup_chain.
10637 2017-04-10 Alan Hayward <alan.hayward@arm.com>
10639 * msp430-tdep.c (msp430_pseudo_register_read): Never return
10642 2017-04-10 Yao Qi <yao.qi@linaro.org>
10645 * gdbthread.h (thread_info::deletable): New method.
10646 (thread_info::incref): New method.
10647 (thread_info::decref): New method.
10648 (thread_info::refcount): Move it to private.
10649 * infrun.c (save_stop_context): Call inc_refcount.
10650 (release_stop_context_cleanup): Likewise.
10651 * thread.c (set_thread_exited): New function.
10652 (init_thread_list): Delete "tp" only it is deletable, otherwise
10653 call set_thread_exited.
10654 (delete_thread_1): Call set_thread_exited.
10655 (current_thread_cleanup) <inferior_pid>: Remove.
10656 <thread>: New field.
10657 (restore_current_thread_ptid_changed): Removed.
10658 (do_restore_current_thread_cleanup): Adjust.
10659 (restore_current_thread_cleanup_dtor): Don't call
10661 (set_thread_refcount): Use dec_refcount.
10662 (make_cleanup_restore_current_thread): Adjust.
10663 (thread_apply_all_command): Call inc_refcount.
10664 (_initialize_thread): Don't call
10665 observer_attach_thread_ptid_changed.
10667 2017-04-10 Yao Qi <yao.qi@linaro.org>
10669 * thread.c (delete_thread_1): Hoist code on marking thread as
10672 2017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10674 * windows-nat.c (windows_detach): Initialize ptid with
10677 2017-04-07 Simon Marchi <simon.marchi@ericsson.com>
10679 * unittests/ptid-selftests.c: Fix erroneous assert messages.
10681 2017-04-07 Alan Hayward <alan.hayward@arm.com>
10683 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
10684 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
10685 (bfin_pseudo_register_write): Likewise
10687 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
10689 * common/ptid.h (struct ptid): Change to...
10690 (class ptid_t): ... this.
10691 <ptid_t>: New constructors.
10692 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
10693 matches>: New methods.
10694 <make_null, make_minus_one>: New static methods.
10695 <pid>: Rename to...
10697 <lwp>: Rename to...
10699 <tid>: Rename to...
10701 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
10702 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
10703 as references, move comment to class ptid_t.
10704 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
10705 ptid_t static methods.
10706 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
10707 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
10708 Take ptid arguments as references, implement using ptid_t methods.
10709 * unittests/ptid-selftests.c: New file.
10710 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10711 unittests/ptid-selftests.c.
10712 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
10714 2017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
10716 * python/python.c (python_run_simple_file): Cast mode literal to
10717 non-const char pointer as expected by PyFile_FromString.
10719 2017-04-05 Simon Marchi <simon.marchi@ericsson.com>
10721 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
10722 minus_one_ptid and null_ptid.
10724 2017-04-05 Pedro Alves <palves@redhat.com>
10726 * warning.m4 (build_warnings): Remove -Wno-write-strings.
10727 * configure: Regenerate.
10729 2017-04-05 Pedro Alves <palves@redhat.com>
10731 * ada-exp.y (yyerror): Constify.
10732 * ada-lang.c (bound_name, get_selections)
10733 (ada_variant_discrim_type)
10734 (ada_variant_discrim_name, ada_value_struct_elt)
10735 (ada_lookup_struct_elt_type, is_unchecked_variant)
10736 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
10737 (catch_ada_exception_command_split)
10738 (catch_ada_assert_command_split, catch_assert_command)
10739 (ada_op_name): Constify.
10740 * ada-lang.h (ada_yyerror, get_selections)
10741 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
10742 * arc-tdep.c (arc_print_frame_cache): Constify.
10743 * arm-tdep.c (arm_skip_stub): Constify.
10744 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
10745 (gen_aggregate_elt_ref): Constify.
10746 * bcache.c (print_bcache_statistics): Constify.
10747 * bcache.h (print_bcache_statistics): Constify.
10748 * break-catch-throw.c (catch_exception_command_1):
10749 * breakpoint.c (struct ep_type_description::description):
10751 (add_solib_catchpoint): Constify.
10752 (catch_fork_command_1): Add cast.
10753 (add_catch_command): Constify.
10754 * breakpoint.h (add_catch_command, add_solib_catchpoint):
10756 * bsd-uthread.c (bsd_uthread_state): Constify.
10757 * buildsym.c (patch_subfile_names): Constify.
10758 * buildsym.h (next_symbol_text_func, patch_subfile_names):
10760 * c-exp.y (yyerror): Constify.
10761 (token::oper): Constify.
10762 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
10763 * c-varobj.c (cplus_describe_child): Constify.
10764 * charset.c (find_charset_names): Add cast.
10765 (find_charset_names): Constify array and add const_cast.
10766 * cli/cli-cmds.c (complete_command, cd_command): Constify.
10767 (edit_command): Constify.
10768 * cli/cli-decode.c (lookup_cmd): Constify.
10769 * cli/cli-dump.c (dump_memory_command, dump_value_command):
10771 (struct dump_context): Constify.
10772 (add_dump_command, restore_command): Constify.
10773 * cli/cli-script.c (get_command_line): Constify.
10774 * cli/cli-script.h (get_command_line): Constify.
10775 * cli/cli-utils.c (check_for_argument): Constify.
10776 * cli/cli-utils.h (check_for_argument): Constify.
10777 * coff-pe-read.c (struct read_pe_section_data): Constify.
10778 * command.h (lookup_cmd): Constify.
10779 * common/print-utils.c (decimal2str): Constify.
10780 * completer.c (gdb_print_filename): Constify.
10781 * corefile.c (set_gnutarget): Constify.
10782 * cp-name-parser.y (yyerror): Constify.
10783 * cp-valprint.c (cp_print_class_member): Constify.
10784 * cris-tdep.c (cris_register_name, crisv32_register_name):
10786 * d-exp.y (yyerror): Constify.
10787 (struct token::oper): Constify.
10788 * d-lang.h (d_yyerror): Constify.
10789 * dbxread.c (struct header_file_location::name): Constify.
10790 (add_old_header_file, add_new_header_file, last_function_name)
10791 (dbx_next_symbol_text, add_bincl_to_list)
10792 (find_corresponding_bincl_psymtab, set_namestring)
10793 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
10794 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
10795 * defs.h (command_line_input, print_address_symbolic)
10796 (deprecated_readline_begin_hook): Constify.
10797 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
10799 * event-top.c (handle_line_of_input): Constify and add cast.
10800 * exceptions.c (catch_errors): Constify.
10801 * exceptions.h (catch_errors): Constify.
10802 * expprint.c (print_subexp_standard, op_string, op_name)
10803 (op_name_standard, dump_raw_expression, dump_raw_expression):
10804 * expression.h (op_name, op_string, dump_raw_expression):
10806 * f-exp.y (yyerror): Constify.
10807 (struct token::oper): Constify.
10808 (struct f77_boolean_val::name): Constify.
10809 * f-lang.c (f_word_break_characters): Constify.
10810 * f-lang.h (f_yyerror): Constify.
10811 * fork-child.c (fork_inferior): Add cast.
10812 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
10813 (new_variant): Constify.
10814 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
10815 * gdbarch.c: Regenerate.
10816 * gdbcore.h (set_gnutarget): Constify.
10817 * go-exp.y (yyerror): Constify.
10818 (token::oper): Constify.
10819 * go-lang.h (go_yyerror): Constify.
10820 * go32-nat.c (go32_sysinfo): Constify.
10821 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
10822 * guile/scm-cmd.c (cmdscm_function): Constify.
10823 * guile/scm-param.c (pascm_param_value): Constify.
10824 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
10825 (h8300sx_register_name): Constify.
10826 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
10828 * ia64-tdep.c (ia64_register_names): Constify.
10829 * infcmd.c (construct_inferior_arguments): Constify.
10830 (path_command, attach_post_wait): Constify.
10831 * language.c (show_range_command, show_case_command)
10832 (unk_lang_error): Constify.
10833 * language.h (language_defn::la_error)
10834 (language_defn::la_name_of_this): Constify.
10835 * linespec.c (decode_line_2): Constify.
10836 * linux-thread-db.c (thread_db_err_str): Constify.
10837 * lm32-tdep.c (lm32_register_name): Constify.
10838 * m2-exp.y (yyerror): Constify.
10839 * m2-lang.h (m2_yyerror): Constify.
10840 * m32r-tdep.c (m32r_register_names): Constify and make static.
10841 * m68hc11-tdep.c (m68hc11_register_names): Constify.
10842 * m88k-tdep.c (m88k_register_name): Constify.
10843 * macroexp.c (appendmem): Constify.
10844 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
10845 (upgrade_type, parse_external, parse_partial_symbols)
10846 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
10847 (new_symbol): Constify.
10848 * memattr.c (mem_info_command): Constify.
10849 * mep-tdep.c (register_name_from_keyword): Constify.
10850 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
10852 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
10853 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
10854 * mi/mi-main.c (captured_mi_execute_command): Constify and add
10856 (mi_execute_async_cli_command): Constify.
10857 * mips-tdep.c (mips_register_name): Constify.
10858 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
10859 (am33_register_name, am33_2_register_name)
10860 * moxie-tdep.c (moxie_register_names): Constify.
10861 * nat/linux-osdata.c (osdata_type): Constify fields.
10862 * nto-tdep.c (nto_parse_redirection): Constify.
10863 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
10864 (lookup_child_selector): Constify.
10865 (objc_methcall::name): Constify.
10866 * objc-lang.h (lookup_objc_class, lookup_child_selector)
10867 (lookup_struct_typedef): Constify.
10868 * objfiles.c (pc_in_section): Constify.
10869 * objfiles.h (pc_in_section): Constify.
10870 * p-exp.y (struct token::oper): Constify.
10871 (yyerror): Constify.
10872 * p-lang.h (pascal_yyerror): Constify.
10873 * parser-defs.h (op_name_standard): Constify.
10874 (op_print::string): Constify.
10875 (exp_descriptor::op_name): Constify.
10876 * printcmd.c (print_address_symbolic): Constify.
10877 * psymtab.c (print_partial_symbols): Constify.
10878 * python/py-breakpoint.c (stop_func): Constify.
10879 (bppy_get_expression): Constify.
10880 * python/py-cmd.c (cmdpy_completer::name): Constify.
10881 (cmdpy_function): Constify.
10882 * python/py-event.c (evpy_add_attribute)
10883 (gdbpy_initialize_event_generic): Constify.
10884 * python/py-event.h (evpy_add_attribute)
10885 (gdbpy_initialize_event_generic): Constify.
10886 * python/py-evts.c (add_new_registry): Constify.
10887 * python/py-finishbreakpoint.c (outofscope_func): Constify.
10888 * python/py-framefilter.c (get_py_iter_from_func): Constify.
10889 * python/py-inferior.c (get_buffer): Add cast.
10890 * python/py-param.c (parm_constant::name): Constify.
10891 * python/py-unwind.c (fprint_frame_id): Constify.
10892 * python/python.c (gdbpy_parameter_value): Constify.
10893 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
10894 * remote.c (memory_packet_config::name): Constify.
10895 (show_packet_config_cmd, remote_write_bytes)
10896 (remote_buffer_add_string):
10897 * reverse.c (exec_reverse_once): Constify.
10898 * rs6000-tdep.c (variant::name, variant::description): Constify.
10899 * rust-exp.y (rustyyerror): Constify.
10900 * rust-lang.c (rust_op_name): Constify.
10901 * rust-lang.h (rustyyerror): Constify.
10902 * serial.h (serial_ops::name): Constify.
10903 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
10904 (sh_sh3e_register_name, sh_sh2e_register_name)
10905 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
10906 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
10907 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
10908 (sh_sh4al_dsp_register_name): Constify.
10909 * sh64-tdep.c (sh64_register_name): Constify.
10910 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
10911 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
10912 * stabsread.c (patch_block_stabs, read_type_number)
10913 (ref_map::stabs, ref_add, process_reference)
10914 (symbol_reference_defined, define_symbol, define_symbol)
10915 (error_type, read_type, read_member_functions, read_cpp_abbrev)
10916 (read_one_struct_field, read_struct_fields, read_baseclasses)
10917 (read_tilde_fields, read_struct_type, read_array_type)
10918 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
10919 (read_huge_number, read_range_type, read_args, common_block_start)
10920 (find_name_end): Constify.
10921 * stabsread.h (common_block_start, define_symbol)
10922 (process_one_symbol, symbol_reference_defined, ref_add):
10923 * symfile.c (get_section_index, add_symbol_file_command):
10924 * symfile.h (get_section_index): Constify.
10925 * target-descriptions.c (tdesc_type::name): Constify.
10926 (tdesc_free_type): Add cast.
10927 * target.c (find_default_run_target):
10928 (add_deprecated_target_alias, find_default_run_target)
10929 (target_announce_detach): Constify.
10930 (do_option): Constify.
10931 * target.h (add_deprecated_target_alias): Constify.
10932 * thread.c (print_thread_info_1): Constify.
10933 * top.c (deprecated_readline_begin_hook, command_line_input):
10935 (init_main): Add casts.
10936 * top.h (handle_line_of_input): Constify.
10937 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
10938 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
10939 (tfind_command): Rename to ...
10940 (tfind_command_1): ... this and constify.
10941 (tfind_command): New function.
10942 (tfind_end_command, tfind_start_command): Adjust.
10943 (encode_source_string): Constify.
10944 * tracepoint.h (encode_source_string): Constify.
10945 * tui/tui-data.c (tui_partial_win_by_name): Constify.
10946 * tui/tui-data.h (tui_partial_win_by_name): Constify.
10947 * tui/tui-source.c (tui_set_source_content_nil): Constify.
10948 * tui/tui-source.h (tui_set_source_content_nil): Constify.
10949 * tui/tui-win.c (parse_scrolling_args): Constify.
10950 * tui/tui-windata.c (tui_erase_data_content): Constify.
10951 * tui/tui-windata.h (tui_erase_data_content): Constify.
10952 * tui/tui-winsource.c (tui_erase_source_content): Constify.
10953 * tui/tui.c (tui_enable): Add cast.
10954 * utils.c (defaulted_query): Constify.
10955 (init_page_info): Add cast.
10956 (puts_debug, subset_compare): Constify.
10957 * utils.h (subset_compare): Constify.
10958 * varobj.c (varobj_format_string): Constify.
10959 * varobj.h (varobj_format_string): Constify.
10960 * vax-tdep.c (vax_register_name): Constify.
10961 * windows-nat.c (windows_detach): Constify.
10962 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
10963 * xml-support.c (gdb_xml_end_element): Constify.
10964 * xml-tdesc.c (tdesc_start_reg): Constify.
10965 * xstormy16-tdep.c (xstormy16_register_name): Constify.
10966 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
10967 * xtensa-tdep.h (xtensa_register_t::name): Constify.
10969 2017-04-05 Pedro Alves <palves@redhat.com>
10971 * proc-api.c (struct trans): Constify.
10972 (procfs_note): Constify.
10973 * proc-events.c (struct trans, syscall_table):
10974 * proc-flags.c (struct trans): Constify.
10975 * proc-utils.h (procfs_note): Constify.
10976 * proc-why.c (struct trans): Constify.
10977 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
10978 (procfs_detach): Constify.
10979 * sol-thread.c (struct string_map): Constify.
10980 (td_err_string, td_state_string): Constify.
10982 2017-04-05 Pedro Alves <palves@redhat.com>
10984 * proc-api.c (procfs_filename): Don't initialize
10986 (prepare_to_trace): Assume procfs_filename is non-NULL.
10987 (_initialize_proc_api): Give procfs_filename a default value here.
10989 2017-04-05 Pedro Alves <palves@redhat.com>
10991 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
10992 'cond_string' parameter.
10993 (extract_exception_regexp): Constify 'string' parameter.
10994 (catch_exception_command_1): Constify.
10995 * breakpoint.c (init_catchpoint)
10996 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
10998 (ep_parse_optional_if_clause, catch_fork_command_1)
10999 (catch_exec_command_1): Constify.
11000 * breakpoint.h (init_catchpoint): Constify 'cond_string'
11002 (ep_parse_optional_if_clause): Constify.
11003 * cli/cli-utils.c (remove_trailing_whitespace)
11004 (check_for_argument): Constify.
11005 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
11006 non-const overload.
11007 (check_for_argument): Likewise.
11009 2017-04-05 Pedro Alves <palves@redhat.com>
11011 * event-top.c (command_line_handler): Add cast to execute_command
11013 * record-btrace.c (cmd_record_btrace_bts_start)
11014 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
11015 (cmd_record_btrace_start): Add cast to execute_command call.
11016 * record-full.c (record_full_goto_insn):
11017 * record.c (record_start, record_stop): Add cast to
11018 execute_command_to_string calls.
11019 (cmd_record_start): Add cast to execute_command calls.
11021 2017-04-05 Pedro Alves <palves@redhat.com>
11023 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
11024 static inline function.
11025 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
11026 array and use gdb_PyArg_ParseTupleAndKeywords.
11027 * python/py-cmd.c (cmdpy_init): Likewise.
11028 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
11029 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
11030 (infpy_search_memory): Likewise.
11031 * python/py-objfile.c (objfpy_add_separate_debug_file)
11032 (gdbpy_lookup_objfile): Likewise.
11033 * python/py-symbol.c (gdbpy_lookup_symbol)
11034 (gdbpy_lookup_global_symbol): Likewise.
11035 * python/py-type.c (gdbpy_lookup_type): Likewise.
11036 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
11037 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
11040 2017-04-05 Pedro Alves <palves@redhat.com>
11042 * python/python-internal.h (gdb_PyGetSetDef): New type.
11043 * python/py-block.c (block_object_getset)
11044 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
11045 * python/py-event.c (event_object_getset)
11046 (finish_breakpoint_object_getset): Likewise.
11047 * python/py-inferior.c (inferior_object_getset): Likewise.
11048 * python/py-infthread.c (thread_object_getset): Likewise.
11049 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
11050 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
11051 * python/py-objfile.c (objfile_getset): Likewise.
11052 * python/py-progspace.c (pspace_getset): Likewise.
11053 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
11055 * python/py-record.c (recpy_record_getset): Likewise.
11056 * python/py-symbol.c (symbol_object_getset): Likewise.
11057 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
11059 * python/py-type.c (type_object_getset, field_object_getset):
11061 * python/py-value.c (value_object_getset): Likewise.
11063 2017-04-05 Pedro Alves <palves@redhat.com>
11065 * python/python-internal.h (gdb_PyObject_CallMethod)
11066 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
11068 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
11069 (PySys_GetObject, PySys_SetPath): New macros.
11071 2017-04-05 Pedro Alves <palves@redhat.com>
11073 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
11074 info_osdata_command.
11075 * osdata.c (info_osdata_command): Rename to ...
11076 (info_osdata): ... this. Constify 'type' parameter, and remove
11077 the 'from_tty' parameter. Accept NULL TYPE.
11078 (info_osdata_command): New function.
11079 * osdata.h (info_osdata_command): Remove declaration.
11080 (info_osdata): New declaration.
11082 2017-04-05 Pedro Alves <palves@redhat.com>
11084 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
11085 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
11086 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
11088 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
11089 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
11090 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
11092 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
11093 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
11094 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
11095 (mi_cmd_file_list_exec_source_files)
11096 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
11097 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
11098 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
11100 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
11101 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
11102 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
11103 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
11104 (mi_cmd_stack_info_frame): Constify 'command' parameter.
11105 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
11106 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
11107 'command' parameter.
11108 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
11109 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
11110 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
11111 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
11112 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
11113 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
11114 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
11115 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
11116 (mi_cmd_var_set_update_range): Constify 'command' parameter.
11117 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
11118 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
11120 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
11121 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
11122 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
11123 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
11124 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
11125 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
11126 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
11127 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
11128 (mi_cmd_data_list_changed_registers)
11129 (mi_cmd_data_write_register_values)
11130 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
11131 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
11132 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
11133 (mi_cmd_list_features, mi_cmd_list_target_features)
11134 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
11135 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
11136 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
11137 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
11138 (mi_cmd_trace_frame_collected): Constify 'command'
11140 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
11141 'command' parameter.
11143 2017-04-05 Pedro Alves <palves@redhat.com>
11145 * ada-lang.c (ada_completer_word_break_characters): Now a const
11147 (ada_get_gdb_completer_word_break_characters): Constify.
11148 * completer.c (gdb_completer_command_word_break_characters)
11149 (gdb_completer_file_name_break_characters)
11150 (gdb_completer_quote_characters): Now const arrays.
11151 (get_gdb_completer_quote_characters): Constify.
11152 (set_rl_completer_word_break_characters): New function.
11153 (set_gdb_completion_word_break_characters)
11154 (complete_line_internal): Use it.
11155 * completer.h (get_gdb_completer_quote_characters): Constify.
11156 (set_rl_completer_word_break_characters): Declare.
11157 * f-lang.c (f_word_break_characters): Constify.
11158 * language.c (default_word_break_characters): Constify.
11159 * language.h (language_defn::la_word_break_characters): Constify.
11160 (default_word_break_characters): Constify.
11161 * top.c (init_main): Use set_rl_completer_word_break_characters.
11163 2017-04-05 Pedro Alves <palves@redhat.com>
11165 * aix-thread.c (aix_thread_pid_to_str)
11166 (aix_thread_extra_thread_info): Constify.
11167 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
11168 * bsd-uthread.c (bsd_uthread_extra_thread_info)
11169 (bsd_uthread_pid_to_str): Constify.
11170 * corelow.c (core_pid_to_str): Constify.
11171 * darwin-nat.c (darwin_pid_to_str): Constify.
11172 * fbsd-nat.c (fbsd_pid_to_str): Constify.
11173 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
11175 * gnu-nat.c (gnu_pid_to_str): Constify.
11176 * go32-nat.c (go32_pid_to_str): Constify.
11177 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
11178 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
11179 * inferior.c (inferior_pid_to_str): Constify.
11180 * linux-nat.c (linux_nat_pid_to_str): Constify.
11181 * linux-tdep.c (linux_core_pid_to_str): Constify.
11182 * linux-thread-db.c (thread_db_pid_to_str)
11183 (thread_db_extra_thread_info): Constify.
11184 * nto-tdep.c (nto_extra_thread_info): Constify.
11185 * nto-tdep.h (nto_extra_thread_info): Constify.
11186 * obsd-nat.c (obsd_pid_to_str): Constify.
11187 * procfs.c (procfs_pid_to_str): Constify.
11188 * ravenscar-thread.c (ravenscar_extra_thread_info)
11189 (ravenscar_pid_to_str): Constify.
11190 * remote-sim.c (gdbsim_pid_to_str): Constify.
11191 * remote.c (remote_threads_extra_info, remote_pid_to_str):
11193 * sol-thread.c (solaris_pid_to_str): Constify.
11194 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
11195 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
11196 * target.c (default_pid_to_str, target_pid_to_str)
11197 (normal_pid_to_str, default_pid_to_str): Constify.
11198 * target.h (target_ops::to_pid_to_str)
11199 (target_ops::to_extra_thread_info): Constify.
11200 (target_pid_to_str, normal_pid_to_str): Constify.
11201 * windows-nat.c (windows_pid_to_str): Constify.
11202 * gdbarch.sh (core_pid_to_str): Constify.
11203 * target-delegates.c: Regenerate.
11204 * gdbarch.h, gdbarch.c: Regenerate.
11206 2017-04-05 Pedro Alves <palves@redhat.com>
11208 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
11209 the memory of the temporary warning_pre_print override.
11210 * utils.c (warning_pre_print): Constify.
11211 * utils.h (warning_pre_print): Constify.
11213 2017-04-05 Pedro Alves <palves@redhat.com>
11215 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
11216 (shell_command): New function.
11217 (make_command): Use std::string.
11218 (init_cli_cmds): Register shell_command instead of shell_escape.
11220 2017-04-05 Pedro Alves <palves@redhat.com>
11222 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
11223 * tracepoint.c (default_collect): Don't initialize.
11225 2017-04-05 Pedro Alves <palves@redhat.com>
11227 * macroexp.c (macro_buffer::shared): Now a bool.
11228 (init_buffer): Update.
11229 (init_shared_buffer): Constify 'addr' parameter.
11230 (substitute_args, expand, macro_expand, macro_expand_next): Remove
11233 2017-04-05 Pedro Alves <palves@redhat.com>
11235 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
11236 * disasm.c (set_disassembler_options): Constify local.
11237 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
11239 2017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
11242 * tracefile.c (tsave_command): Fix argument parsing for '-r'
11245 2017-04-05 Yao Qi <yao.qi@linaro.org>
11247 * frame.c (frame_unwind_register_unsigned): Call
11248 frame_unwind_register_value.
11250 2017-04-05 Yao Qi <yao.qi@linaro.org>
11252 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
11253 Use gdb_test_multiple, and don't match anchor.
11255 2017-04-05 Pedro Alves <palves@redhat.com>
11257 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
11258 (Write After Approval): Remove Simon Marchi.
11260 2017-04-05 Pedro Alves <palves@redhat.com>
11262 * common/gdb_optional.h (optional::optional): Make constexpr and
11263 initialize m_dummy.
11265 2017-04-04 John Baldwin <jhb@FreeBSD.org>
11267 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
11268 (amd64fbsd_jmp_buf_reg_offset): Remove.
11269 (amd64fbsd_supply_uthread): Remove function.
11270 (amd64fbsd_collect_uthread): Remove function.
11271 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
11272 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
11273 (x86_64-*-freebsd*): Remove bsd-uthread.o.
11274 (fbsd-nat.c): Update comment.
11275 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
11276 (i386fbsd_jmp_buf_reg_offset): Remove.
11277 (i386fbsd_supply_uthread): Remove function.
11278 (i386fbsd_collect_uthread): Remove function.
11279 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
11281 2017-04-04 John Baldwin <jhb@FreeBSD.org>
11283 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
11284 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
11285 * NEWS: Mention that support for FreeBSD/alpha was removed.
11286 * alpha-fbsd-tdep.c: Delete file.
11287 * config/alpha/fbsd.mh: Delete file.
11288 * configure.host: Delete alpha*-*-freebsd* and
11289 alpha*-*-kfreebsd*-gnu.
11290 * configure.tgt: Delete alpha*-*-freebsd* and
11291 alpha*-*-kfreebsd*-gnu.
11293 2017-04-04 John Baldwin <jhb@FreeBSD.org>
11295 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
11296 amd64bsd_store_inferior_registers): Use ptid from regcache.
11298 2017-04-04 Pedro Alves <palves@redhat.com>
11300 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
11301 data fields, make them private and add "m_" prefixes.
11302 (lnp_state_machine::lnp_state_machine): New ctor.
11303 (record_line, check_line_address, handle_set_discriminator)
11304 (handle_set_address, handle_advance_pc, handle_special_opcode)
11305 (handle_advance_line, handle_set_file, handle_negate_stmt)
11306 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
11307 (end_sequence, advance_line): New methods.
11308 (m_gdbarch, m_record_lines_p): New fields.
11309 (lnp_reader_state): Delete.
11310 (dwarf_record_line): Rename to ...
11311 (lnp_state_machine::record_line): ... adjust.
11312 (init_lnp_state_machine): Delete.
11313 (lnp_state_machine::lnp_state_machine): New.
11314 (check_line_address): Rename to ...
11315 (lnp_state_machine::check_line_address): This.
11316 (dwarf_decode_lines_1): Remove reference to "reader_state".
11317 Adjust lnp_state_machine having a non-default ctor. Use bool.
11318 State machine internal state manipulation moved to
11319 lnp_state_machine methods.
11321 2017-04-04 Pedro Alves <palves@redhat.com>
11323 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11324 unittests/offset-type-selftests.c.
11325 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
11326 * common/offset-type.h: New file.
11327 * common/preprocessor.h: New file.
11328 * common/traits.h: New file.
11329 * common/valid-expr.h: New file.
11330 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
11331 sect_offset and cu_offset strong typedefs throughout.
11332 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
11333 typedefs throughout.
11334 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
11335 sect_offset and cu_offset strong typedefs throughout.
11336 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
11337 typedefs throughout.
11338 * gdbtypes.h: Include "common/offset-type.h".
11339 (cu_offset): Now an offset type (strong typedef) instead of a
11341 (sect_offset): Likewise.
11342 (union call_site_parameter_u): Rename "param_offset" field to
11344 * unittests/offset-type-selftests.c: New file.
11346 2017-04-04 Pedro Alves <palves@redhat.com>
11348 * common/underlying.h: New file.
11349 * dwarf2read.c: Include "common/gdb_optional.h" and
11350 "common/underlying.h".
11351 (dir_index, file_name_index): New types.
11352 (file_entry): Use them.
11353 (file_entry::include): Use to_underlying.
11354 (line_header::add_file_name): Use dir_index.
11355 (read_formatted_entries): Use gdb::optional. Read form before
11356 writting to file_entry.
11357 (dwarf_decode_line_header): Use dir_index.
11358 (lnp_state_machine::current_file): Use to_underlying.
11359 (lnp_state_machine::file): Change type to file_name_index.
11360 (dwarf_record_line): Use to_underlying.
11361 (init_lnp_state_machine): Use file_name_index.
11362 (dwarf_decode_lines_1): Use dir_index and file_name_index.
11364 2017-04-04 Pedro Alves <palves@redhat.com>
11366 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
11367 operator bool, has_value and get methods.
11369 2017-04-04 Pedro Alves <palves@redhat.com>
11371 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
11373 (line_header): Initialize all data fields. Change type of
11374 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
11375 Change type of include_dirs to std::vector<const char *>. Remove
11376 num_include_dirs, include_dirs_size. Change type of file_names to
11377 std::vector<file_entry>. Remove num_file_names, file_names_size.
11378 (line_header::line_header): New.
11379 (line_header::add_include_dir, line_header::add_file_name): New
11381 (line_header::include_dir_at): Remove NULL check.
11382 (line_header::file_name_at): Add const overload.
11383 (line_header_up): New unique_ptr typedef.
11384 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
11385 std::vector. Remove free_line_header call.
11386 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
11387 free_line_header call.
11388 (free_cu_line_header): Delete.
11389 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
11390 (setup_type_unit_groups): Use line_header_up instead of cleanups.
11391 Adjust to use std::vector.
11392 (free_line_header): Delete.
11393 (free_line_header_voidp): Use delete.
11394 (add_include_dir): Replace with ...
11395 (line_header::add_include_dir): ... this method. Use std::vector.
11396 (add_file_name): Replace with ...
11397 (line_header::add_file_name): ... this method. Use std::vector.
11398 (add_include_dir_stub): Delete.
11399 (read_formatted_entries): Remove memset.
11400 (dwarf_decode_line_header): Return a line_header_up instead of a
11401 raw pointer. Remove cleanup handling. Pass lambdas to
11402 read_formatted_entries. Adjust to use line_header methods.
11403 (dwarf_decode_lines_1): Adjust to use line_header methods.
11404 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
11407 2017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
11409 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
11410 instead of struct ptid.
11412 2017-05-04 Alan Hayward <alan.hayward@arm.com>
11414 * frame.c (get_frame_register_bytes): Unwind using value.
11415 (put_frame_register_bytes): Likewise.
11417 2017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
11419 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
11422 2017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
11424 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
11426 2017-03-29 Yao Qi <yao.qi@linaro.org>
11428 * gdbthread.h (struct thread_info): Declare constructor and
11429 destructor. Add some in-class member initializers.
11430 * thread.c (free_thread): Remove.
11431 (init_thread_list): Call delete instead of free_thread.
11432 (new_thread): Call thread_info constructor.
11433 (thread_info::thread_info): New function.
11434 (thread_info::~thread_info): New function.
11435 (delete_thread_1): Call delete instead of free_thread.
11436 (make_cleanup_restore_current_thread): Move tp and frame to
11439 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
11441 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
11442 (arc_skip_prologue): Likewise.
11443 (arc_make_frame_cache): Likewise.
11444 (arc_pv_get_operand): New function.
11445 (arc_is_in_prologue): Likewise.
11446 (arc_analyze_prologue): Likewise.
11447 (arc_print_frame_cache): Likewise.
11448 (MAX_PROLOGUE_LENGTH): New constant.
11450 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
11452 * configure.tgt: Add arc-insn.o.
11453 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
11454 (dump_arc_instruction_command): New function.
11455 (arc_fprintf_disasm): Likewise.
11456 (arc_disassemble_info): Likewise.
11457 (arc_insn_get_operand_value): Likewise.
11458 (arc_insn_get_operand_value_signed): Likewise.
11459 (arc_insn_get_memory_base_reg): Likewise.
11460 (arc_insn_get_memory_offset): Likewise.
11461 (arc_insn_get_branch_target): Likewise.
11462 (arc_insn_dump): Likewise.
11463 (arc_insn_get_linear_next_pc): Likewise.
11464 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
11465 (arc_disassemble_info): Likewise.
11466 (arc_insn_get_branch_target): Likewise.
11467 (arc_insn_get_linear_next_pc): Likewise.
11468 * NEWS: Mention new "maint print arc arc-instruction".
11470 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
11472 * arc-tdep (maintenance_print_arc_list): New variable.
11473 (maintenance_print_arc_command): New function.
11475 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
11477 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
11478 Add "limm" and "reserved".
11479 (arc_cannot_fetch_register, arc_cannot_store_register): Add
11480 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
11481 * arc-tdep.h (arc_regnum): Likewise.
11483 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
11485 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
11486 for THREADPTR register.
11487 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
11489 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
11490 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
11491 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
11493 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
11495 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
11496 registers above gdbarch_num_regs (gdbarch) as privileged in
11499 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
11501 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
11502 for a single specified register or for all registers in
11503 a0_base..a0_base + C0_NREGS range.
11504 (supply_gregset_reg): Call regcache_raw_supply for a single
11505 specified register or for all registers in a0_base..a0_base +
11508 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
11510 * arch/xtensa.h (C0_NREGS): Add definition.
11511 * xtensa-tdep.c (C0_NREGS): Remove definition.
11513 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
11515 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
11516 Drop xtensa_default_isa initialization.
11517 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
11519 2017-03-27 Pedro Alves <palves@redhat.com>
11521 * dwarf2read.c (file_entry) <dir_index>: Add comment.
11522 (file_entry::include_dir): New method.
11523 (line_header::include_dir_at, line_header::file_name_at): New
11525 (setup_type_unit_groups, setup_type_unit_groups)
11526 (psymtab_include_file_name): Simplify using the new methods.
11527 (lnp_state_machine) <the_line_header>: New field.
11528 <file>: Add comment.
11529 (lnp_state_machine::current_file): New method.
11530 (dwarf_record_line): Simplify using the new methods.
11531 (init_lnp_state_machine): Initialize the "the_line_header" field.
11532 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
11533 Simplify using the new methods.
11535 2017-03-27 Pedro Alves <palves@redhat.com>
11537 * cp-name-parser.y (make_empty): Delete.
11538 (demangler_special, nested_name, ptr_operator, array_indicator)
11539 (direct_declarator, declarator_1): Use fill_comp instead of
11542 2017-03-27 Pedro Alves <palves@redhat.com>
11544 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
11545 to ATTRIBUTE_PRINTF.
11546 * solib-target.c (library_list_start_list): Print "string" not
11548 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
11549 gdb_xml_error call.
11551 2017-03-27 Pedro Alves <palves@redhat.com>
11553 * dwarf2read.c (struct file_and_directory): New.
11554 (dwarf2_get_dwz_file): Adjust to use std::string.
11555 (dw2_get_file_names_reader): Adjust to use file_and_directory.
11556 (find_file_and_directory): Adjust to return a file_and_directory
11558 (read_file_scope): Adjust to use file_and_directory. Remove
11559 make_cleanup/do_cleanups calls.
11560 (open_and_init_dwp_file): Adjust to use std::string. Remove
11561 make_cleanup/do_cleanups calls.
11562 * python/python.c (do_start_initialization): Adjust to ldirname
11563 returning a std::string.
11564 * utils.c (ldirname): Now returns a std::string.
11565 * utils.h (ldirname): Change return type to std::string.
11566 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
11567 returning a std::string.
11568 * xml-tdesc.c (file_read_description_xml): Likewise.
11570 2017-03-24 Alan Hayward <alan.hayward@arm.com>
11572 * regcache.c (regcache_debug_print_register): New function.
11573 * regcache.h (regcache_debug_print_register): New declaration.
11574 * target.c (debug_print_register): Remove.
11575 (target_fetch_registers): Call regcache_debug_print_register.
11576 (target_store_registers): Likewise.
11578 2017-03-24 Pádraig Brady <pbrady@fb.com>
11580 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
11581 reference beyond the 'lh->include_dirs' array before accessing to
11583 (psymtab_include_file_name): Likewise.
11584 (dwarf_decode_lines_1): Likewise.
11585 (dwarf_decode_lines): Likewise.
11586 (file_file_name): Likewise.
11588 2017-03-23 Simon Marchi <simon.marchi@ericsson.com>
11590 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
11592 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
11593 ps_lsetfpregs): Likewise.
11594 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
11595 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
11596 ps_lsetfpregs): Likewise.
11597 * target.c (target_fetch_registers, target_store_registers):
11600 2017-03-23 Alan Hayward <alan.hayward@arm.com>
11602 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
11604 2017-03-23 Yao Qi <yao.qi@linaro.org>
11606 * aarch64-tdep.c (aarch64_process_record_test): Declare.
11607 (_initialize_aarch64_tdep): Register it.
11608 (aarch64_record_load_store): Handle PRFM instruction.
11609 (aarch64_process_record_test): New function.
11611 2017-03-23 Yao Qi <yao.qi@linaro.org>
11613 * aarch64-tdep.c (aarch64_record_load_store): Fix code
11616 2017-03-23 Yao Qi <yao.qi@linaro.org>
11618 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
11620 2017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
11622 python/python.c (do_start_initialization): Fix memory leak.
11624 2017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
11626 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
11627 using get_ptrace_pid.
11628 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
11630 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
11631 inferior_ptid instead of pid.
11633 2017-03-22 Yao Qi <yao.qi@linaro.org>
11635 * aarch64-tdep.c: Wrap locally used classes in anonymous
11637 * arm-tdep.c: Likewise.
11638 * linespec.c: Likewise.
11639 * ui-out.c: Likewise.
11641 2017-03-22 Jonah Graham <jonah@kichwacoders.com>
11644 * python/lib/gdb/printer/bound_registers.py: Import sys.
11646 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
11648 * windows-nat.c (do_windows_fetch_inferior_registers): Add
11649 windows_thread_info parameter and use it instead of
11651 (windows_fetch_inferior_registers): Don't set current_thread,
11652 pass the thread to do_windows_fetch_inferior_registers. Use
11653 ptid from regcache instead of inferior_ptid.
11654 (do_windows_store_inferior_registers): Add windows_thread_info
11655 parameter and use it instead of current_thread.
11656 (windows_store_inferior_registers): Don't set current_thread,
11657 pass the thread to do_windows_store_inferior_registers. Use
11658 ptid from regcache instead of inferior_ptid.
11660 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
11662 * ser-mingw.c (ser_windows_raw): Remove reference to
11663 struct serial::current_timeout.
11665 2017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
11668 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
11669 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
11670 (sparc64_fsr_type): Fix %fsr decoding.
11672 2017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
11674 * python/py-record-btrace.c (btpy_insn_data): Change return type
11677 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
11679 * spu-linux-nat.c (spu_fetch_inferior_registers,
11680 spu_store_inferior_registers): Use ptid from regcache, set and
11681 restore inferior_ptid.
11682 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
11685 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
11687 * i386-linux-nat.c (fetch_register, store_register,
11688 i386_linux_fetch_inferior_registers,
11689 i386_linux_store_inferior_registers): Use ptid from regcache.
11690 * ia64-linux-nat.c (ia64_linux_fetch_register,
11691 ia64_linux_store_register): Likewise.
11692 * inf-ptrace.c (inf_ptrace_fetch_register,
11693 inf_ptrace_store_register): Likewise.
11694 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
11695 m32r_linux_store_inferior_registers): Likewise.
11696 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
11697 m68kbsd_store_inferior_registers): Likewise.
11698 * m68k-linux-nat.c (fetch_register, store_register,
11699 m68k_linux_fetch_inferior_registers,
11700 m68k_linux_store_inferior_registers): Likewise.
11701 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
11702 m88kbsd_store_inferior_registers): Likewise.
11703 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
11704 mips_fbsd_store_inferior_registers): Likewise.
11705 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
11706 mips64_linux_regsets_store_registers): Likewise.
11707 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
11708 mipsnbsd_store_inferior_registers): Likewise.
11709 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
11710 mips64obsd_store_inferior_registers): Likewise.
11711 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
11713 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
11714 ppcfbsd_store_inferior_registers): Likewise.
11715 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
11716 ppc_linux_store_inferior_registers): Likewise.
11717 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
11718 ppcnbsd_store_inferior_registers): Likewise.
11719 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
11720 ppcobsd_store_registers): Likewise.
11721 * procfs.c (procfs_fetch_registers, procfs_store_registers):
11723 * ravenscar-thread.c (ravenscar_fetch_registers,
11724 ravenscar_store_registers, ravenscar_prepare_to_store):
11726 * record-btrace.c (record_btrace_fetch_registers,
11727 record_btrace_store_registers, record_btrace_prepare_to_store):
11729 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
11730 Lookup inferior using ptid from regcache, instead of
11732 * remote.c (remote_fetch_registers, remote_store_registers): Use
11733 ptid from regcache.
11734 * rs6000-nat.c (fetch_register, store_register): Likewise.
11735 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
11736 s390_linux_store_inferior_registers): Likewise.
11737 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
11738 shnbsd_store_inferior_registers): Likewise.
11739 * sol-thread.c (sol_thread_fetch_registers,
11740 sol_thread_store_registers): Likewise.
11741 * sparc-nat.c (sparc_fetch_inferior_registers,
11742 sparc_store_inferior_registers): Likewise.
11743 * tilegx-linux-nat.c (fetch_inferior_registers,
11744 store_inferior_registers): Likewise.
11745 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
11746 vaxbsd_store_inferior_registers): Likewise.
11747 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
11748 store_xtregs): Likewise.
11750 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
11753 * NEWS: Mention support for rvalue references in GDB and python.
11754 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
11755 supports both lvalue and rvalue references.
11757 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
11760 * gdbtypes.c (rank_one_type): Implement overloading
11761 resolution rules regarding rvalue references.
11763 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
11766 * aarch64-tdep.c (aarch64_type_align)
11767 (aarch64_extract_return_value, aarch64_store_return_value): Change
11768 lvalue reference type checks to general reference type checks.
11769 * amd64-tdep.c (amd64_classify): Likewise.
11770 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
11772 * arm-tdep.c (arm_type_align, arm_extract_return_value)
11773 (arm_store_return_value): Likewise.
11774 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
11775 * c-typeprint.c (c_print_type): Likewise.
11776 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
11777 (cplus_number_of_children, cplus_describe_child): Likewise.
11778 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
11779 * completer.c (expression_completer): Likewise.
11780 * cp-support.c (make_symbol_overload_list_adl_namespace):
11782 * darwin-nat-info.c (info_mach_region_command): Likewise.
11783 * dwarf2loc.c (entry_data_value_coerce_ref)
11784 (value_of_dwarf_reg_entry): Likewise.
11785 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
11786 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
11788 * findvar.c (extract_typed_address, store_typed_address):
11790 * gdbtypes.c (rank_one_type): Likewise.
11791 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
11792 * infcall.c (value_arg_coerce): Likewise.
11793 * language.c (pointer_type): Likewise.
11794 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
11796 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
11797 * mn10300-tdep.c (mn10300_type_align): Likewise.
11798 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
11799 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
11800 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
11802 * printcmd.c (print_formatted, x_command): Likewise.
11803 * python/py-type.c (typy_get_composite, typy_template_argument):
11805 * python/py-value.c (valpy_referenced_value)
11806 (valpy_get_dynamic_type, value_has_field): Likewise.
11807 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
11808 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
11809 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
11810 * spu-tdep.c (spu_scalar_value_p): Likewise.
11811 * symtab.c (lookup_symbol_aux): Likewise.
11812 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
11813 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
11815 * valops.c (value_cast_pointers, value_cast)
11816 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
11817 (value_struct_elt, value_struct_elt_bitpos)
11818 (value_find_oload_method_list, find_overload_match)
11819 (value_rtti_indirect_type): Likewise.
11820 * valprint.c (val_print_scalar_type_p, generic_val_print):
11822 * value.c (value_actual_type, value_as_address, unpack_long)
11823 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
11824 (coerce_ref): Likewise.
11825 * varobj.c (varobj_get_value_type): Likewise.
11827 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
11830 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
11831 table of constants.
11832 * python/lib/gdb/command/explore.py: Support exploring values
11833 of rvalue reference types.
11834 * python/lib/gdb/types.py: Implement get_basic_type() for
11835 rvalue reference types.
11836 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
11838 * python/py-value.c (valpy_getitem): Add an rvalue reference
11840 (valpy_reference_value): Add new parameter "refcode".
11841 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
11842 New wrappers for valpy_reference_value().
11843 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
11844 (gdbpy_invoke_xmethod): Likewise.
11846 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
11849 * dwarf2read.c (process_die, read_type_die_1): Handle the
11850 DW_TAG_rvalue_reference_type DIE.
11851 (read_tag_reference_type): Add new parameter "refcode".
11853 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
11856 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
11857 (c_type_print_modifier, c_type_print_varspec_suffix)
11858 (c_type_print_base): Support printing rvalue reference types.
11859 * c-valprint.c (c_val_print, c_value_print): Support printing
11860 rvalue reference values.
11862 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
11865 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
11867 * cp-support.c (replace_typedefs): Handle
11868 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
11869 * python/py-type.c (typy_lookup_type): Likewise.
11871 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
11874 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
11875 * parse.c (insert_type): Change assert statement.
11876 (follow_types): Handle rvalue reference types.
11877 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
11880 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
11883 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
11884 value_ref() interface.
11885 * c-valprint.c (c_value_print): Likewise.
11886 * infcall.c (value_arg_coerce): Likewise.
11887 * python/py-value.c (valpy_reference_value): Likewise.
11888 * valops.c (value_cast, value_reinterpret_cast)
11889 (value_dynamic_cast, typecmp): Likewise.
11890 (value_ref): Parameterize by kind of return value reference type.
11891 * value.h (value_ref): Add new parameter "refcode".
11893 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
11896 * dwarf2read.c (read_tag_reference_type): Use
11897 lookup_lvalue_reference_type() instead of lookup_reference_type().
11898 * eval.c (evaluate_subexp_standard): Likewise.
11899 * f-exp.y: Likewise.
11900 * gdbtypes.c (make_reference_type, lookup_reference_type):
11901 Generalize with rvalue reference types.
11902 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
11903 convenience wrappers for lookup_reference_type().
11904 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
11905 reference kind parameter.
11906 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
11907 wrappers for lookup_reference_type().
11908 * guile/scm-type.c (gdbscm_type_reference): Use
11909 lookup_lvalue_reference_type() instead of lookup_reference_type().
11910 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
11911 * parse.c (follow_types): Likewise.
11912 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
11913 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
11915 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
11916 (gdbpy_invoke_xmethod): Likewise.
11917 * stabsread.c: Provide extra argument to make_reference_type()
11919 * valops.c (value_ref, value_rtti_indirect_type): Use
11920 lookup_lvalue_reference_type() instead of lookup_reference_type().
11922 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
11925 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
11926 (TYPE_IS_REFERENCE): New macro.
11927 (struct type): Add rvalue_reference_type field.
11928 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
11930 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
11932 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
11933 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
11934 New function definition.
11935 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
11936 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
11937 New function declaration.
11938 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
11939 * mi/mi-interp.h: New file.
11940 * solib.c (info_sharedlibrary_command): Replace for loop with
11942 * solib.h (update_solib_list): New function declaration.
11943 (so_list_head): Move macro.
11944 * solist.h (ALL_SO_LIBS): New macro.
11946 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
11948 * infcmd.c (post_create_inferior): Remove unused argument in
11950 * remote.c (remote_start_remote): Likewise.
11951 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
11952 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
11953 (enable_break): Likewise.
11954 * solib.c (update_solib_list): Remove unused target argument
11955 and its documentation.
11956 (solib_add): Remove unused target argument. Remove unused
11957 argument in call to update_solib_list.
11958 (info_sharedlibrary_command): Remove unused argument in call
11959 to update_solib_list.
11960 (sharedlibrary_command): Remove unused argument in call to
11962 (handle_solib_event): Likewise.
11963 (reload_shared_libraries): Likewise.
11964 * solib.h (solib_add): Remove unused target argument.
11966 2017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
11968 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
11969 (s390_displaced_step_fixup): Cover relative branches with the
11970 default fixup handling. This fixes lack of support for some
11971 relative branch instructions.
11973 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11975 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
11976 ptid from regcache.
11978 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11980 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
11981 i386_darwin_store_inferior_registers): Use ptid from regcache.
11983 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11985 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
11986 i386bsd_store_inferior_registers): Use ptid from regcache.
11988 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11990 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
11991 hppaobsd_store_registers): Use ptid from regcache.
11993 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11995 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
11996 hppanbsd_store_registers): Use ptid from regcache.
11998 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
12000 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
12001 from regcache. Use get_ptrace_pid.
12003 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
12005 * corelow.c (get_core_register_section): Use ptid from regcache,
12008 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
12010 * bsd-uthread.c (bsd_uthread_fetch_registers,
12011 bsd_uthread_store_registers): Use ptid from regcache, set and
12012 restore inferior_ptid.
12014 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
12016 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
12017 fetch_fp_regs, store_register, store_regs, store_fp_register,
12018 store_fp_regs): Use ptid from regcache.
12020 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
12022 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
12023 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
12024 store_vfp_regs): Use ptid from regcache.
12026 2017-03-17 Pedro Alves <palves@redhat.com>
12029 * ser-base.c (ser_base_wait_for): Add comment.
12030 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
12032 * ser-unix.c (hardwire_raw): Remove reference to
12033 scb->current_timeout.
12034 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
12035 (hardwire_ops): Install ser_base_readchar instead of
12037 * serial.h (struct serial) <current_timeout, timeout_remaining>:
12040 2017-03-17 Jonah Graham <jonah@kichwacoders.com>
12043 * python/lib/gdb/printer/bound_registers.py: Add support for
12046 2017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
12048 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
12049 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
12050 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
12051 byte_offset to subobj_byte_offset. Fix the handling of
12052 DWARF_VALUE_STACK on big-endian targets when coming via an
12054 (dwarf2_evaluate_loc_desc): Adjust call to
12055 dwarf2_evaluate_loc_desc_full.
12056 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
12057 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
12059 2017-03-16 Yao Qi <yao.qi@linaro.org>
12061 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
12062 and REVSH instructions.
12064 2017-03-16 Yao Qi <yao.qi@linaro.org>
12066 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
12067 (arm_record_test): Declare.
12068 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
12069 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
12070 align with the manual.
12071 (thumb_record_misc): Adjust the code order to align with the
12073 (thumb2_record_decode_insn_handler): Fix instruction matching.
12074 (instruction_reader_thumb): New class.
12075 (arm_record_test): New function.
12077 2017-03-16 Yao Qi <yao.qi@linaro.org>
12079 * arm-tdep.c (abstract_memory_reader): New class.
12080 (instruction_reader): New class.
12081 (extract_arm_insn): Add argument 'reader'. Callers updated.
12082 (decode_insn): Likewise.
12084 2017-03-16 Doug Evans <dje@google.com>
12086 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
12087 member. Change type of TYPE member to SCM. All uses updated.
12088 (lsscm_make_lazy_string_smob): Add assert.
12089 (lsscm_make_lazy_string): Flag bad length values.
12090 (lsscm_elt_type): New function.
12091 (gdbscm_lazy_string_to_value): Rewrite to use
12092 lsscm_safe_lazy_string_to_value.
12093 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
12094 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
12095 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
12097 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
12098 * guile/scm-type.c (tyscm_scm_to_type): New function.
12100 2017-03-15 Doug Evans <dje@google.com>
12102 PR python/17728, python/18439, python/18779
12103 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
12104 member. Change type of TYPE member to PyObject *. All uses updated.
12105 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
12106 (gdbpy_create_lazy_string_object): Flag bad length values.
12107 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
12108 Handle typedefs in incoming type.
12109 (stpy_lazy_string_elt_type): New function.
12110 (gdbpy_extract_lazy_string): Call it.
12111 * python/py-value.c (valpy_lazy_string): Flag bad length values.
12112 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
12113 typedefs in incoming type.
12115 2017-03-16 Doug Evans <dje@google.com>
12117 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
12118 * guile/scm-type.c (tyscm_scm_to_type): New function.
12120 2017-03-16 Jiong Wang <jiong.wang@arm.com>
12122 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
12123 "ULONGEST" for "skip".
12125 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
12128 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
12129 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
12130 (inf_ptrace_peek_poke): ...here. New function. Now also loop
12131 over ptrace peek/poke until end of buffer or error.
12133 2017-03-14 Simon Marchi <simon.marchi@ericsson.com>
12135 * parse.c (length_of_subexp): Make static.
12136 * parser-defs.h (length_of_subexp): Remove.
12138 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
12140 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
12143 2017-03-14 Pedro Alves <palves@redhat.com>
12145 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
12146 (main): Use std::unique_ptr. Remove calls to
12147 cp_demangled_name_parse_free.
12149 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
12151 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
12152 alphabsd_store_inferior_registers): Use regcache->ptid instead
12155 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
12157 * aix-thread.c (aix_thread_fetch_registers,
12158 aix_thread_store_registers): Use regcache->ptid instead of
12161 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
12163 * aarch64-linux-nat.c (fetch_gregs_from_thread,
12164 store_gregs_to_thread, fetch_fpregs_from_thread,
12165 store_fpregs_to_thread): Use regcache->ptid instead of
12168 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
12170 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
12171 amd64_linux_fetch_inferior_registers): Use regcache->ptid
12172 instead of inferior_ptid.
12174 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
12176 * target.c (target_fetch_registers, target_store_registers): Add
12179 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
12181 * regcache.h (regcache_get_ptid): New function.
12182 * regcache.c (regcache_get_ptid): New function.
12184 2017-03-13 Mark Wielaard <mark@klomp.org>
12186 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
12188 2017-03-10 Keith Seitz <keiths@redhat.com>
12191 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
12193 2017-03-08 Pedro Alves <palves@redhat.com>
12196 * infrun.c (start_step_over, do_target_resume, resume)
12197 (restart_threads): Assert we're not resuming a thread that is
12198 meant to be stopped.
12199 (infrun_thread_stop_requested_callback): Delete.
12200 (infrun_thread_stop_requested): If the thread is internally
12201 stopped, queue a pending stop event and clear the thread's
12202 inline-frame state.
12203 (handle_stop_requested): New function.
12204 (handle_syscall_event, handle_inferior_event_1): Use
12205 handle_stop_requested.
12206 (handle_stop_requested): New function.
12207 (handle_signal_stop): Set the thread's stop_signal here instead of
12209 (finish_step_over): Clear step over info unconditionally.
12210 (handle_signal_stop): If the user had interrupted the event
12211 thread, consider the stop a random signal.
12212 (handle_signal_stop) <signal arrived while stepping over
12213 breakpoint>: Don't restart threads here.
12214 (stop_waiting): Don't clear step-over info here.
12216 2017-03-08 Pedro Alves <palves@redhat.com>
12219 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
12220 goes to argument 2, not 1.
12222 2017-03-08 Pedro Alves <palves@redhat.com>
12225 * top.c (gdb_readline_wrapper): Avoid passing NULL to
12226 display_gdb_prompt.
12227 (command_line_input): Add comment.
12229 2017-03-08 Pedro Alves <palves@redhat.com>
12232 * tui/tui-file.c (tui_file::write): New.
12233 * tui/tui-file.h (tui_file): Override "write".
12234 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
12235 factored out from ...
12236 (tui_puts): ... here.
12237 (tui_putc): Use them.
12238 (tui_write): New function.
12239 * tui/tui-io.h (tui_write): Declare.
12241 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
12243 * Makefile.in (SFILES): Replace "environ.c" with
12244 "common/environ.c".
12245 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
12246 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
12248 * common/environ.c: ... here.
12249 * environ.h: Moved to...
12250 * common/environ.h: ... here.
12252 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
12254 * gdbarch.sh (pstring_ptr): New static function.
12255 (gdbarch_disassembler_options): Use it.
12256 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
12257 not valid_disassembler_option->name.
12258 * gdbarch.c: Regenerate.
12260 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
12262 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
12264 2017-03-07 Pedro Alves <palves@redhat.com>
12266 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
12268 2017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
12270 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
12271 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
12272 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
12273 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
12275 2017-03-06 Simon Marchi <simon.marchi@ericsson.com>
12277 * xtensa-linux-nat.c (fetch_gregs): Remove const.
12279 2017-03-03 Simon Marchi <simon.marchi@ericsson.com>
12281 * remote.c (remote_add_target_side_commands): Use range-based
12284 2017-03-03 Yao Qi <yao.qi@linaro.org>
12287 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
12289 * valprint.c (common_val_print): Likewise.
12291 2017-02-28 Peter Bergner <bergner@vnet.ibm.com>
12293 * NEWS: Mention new set/show disassembler-options commands.
12294 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
12295 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
12296 (prospective_options): New static variable.
12297 (gdb_disassembler::gdb_disassembler): Initialize
12298 m_di.disassembler_options.
12299 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
12300 (get_disassembler_options): New function.
12301 (set_disassembler_options): Likewise.
12302 (set_disassembler_options_sfunc): Likewise.
12303 (show_disassembler_options_sfunc): Likewise.
12304 (disassembler_options_completer): Likewise.
12305 (_initialize_disasm): Likewise.
12306 * disasm.h (get_disassembler_options): New prototype.
12307 (set_disassembler_options): Likewise.
12308 * gdbarch.sh (gdbarch_disassembler_options): New variable.
12309 (gdbarch_verify_disassembler_options): Likewise.
12310 * gdbarch.c: Regenerate.
12311 * gdbarch.h: Likewise.
12312 * arm-tdep.c (num_disassembly_options): Delete.
12313 (set_disassembly_style): Likewise.
12314 (arm_disassembler_options): New static variable.
12315 (set_disassembly_style_sfunc): Convert short style name into long
12316 option name. Call set_disassembler_options.
12317 (show_disassembly_style_sfunc): New function.
12318 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
12319 set_gdbarch_verify_disassembler_options.
12320 (_initialize_arm_tdep): Delete regnames variable and update callers.
12321 (arm_disassembler_options): Initialize.
12322 (disasm_options): New variable.
12323 (num_disassembly_options): Rename from this...
12324 (num_disassembly_styles): ...to this. Compute by scanning through
12326 (valid_disassembly_styles): Initialize using disasm_options.
12327 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
12328 set_arm_regname_option.
12329 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
12330 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
12331 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
12332 set_gdbarch_verify_disassembler_options.
12333 * s390-tdep.c (s390_disassembler_options): New static variable.
12334 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
12335 set_gdbarch_verify_disassembler_options.
12337 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
12339 * remote.c (remote_add_target_side_condition): Remove "struct"
12340 keyword from range-based for loop.
12342 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
12344 * remote.c (remote_add_target_side_condition): Use range-based
12345 for loop. Update comment.
12347 2017-02-27 Yao Qi <yao.qi@linaro.org>
12349 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
12351 2017-02-26 Alan Hayward <alan.hayward@arm.com>
12353 * regcache.c (regcache_raw_update): New function.
12354 (regcache_raw_read): Move code to regcache_raw_update.
12355 * regcache.h (regcache_raw_update): New declaration.
12356 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
12358 2017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
12360 * dwarf2read.c (create_debug_type_hash_table): Initialize
12361 header.signature and header.type_offset_in_tu.
12363 2017-02-24 Pedro Alves <palves@redhat.com>
12365 * symtab.c (make_file_symbol_completion_list_1): Use
12366 add_symtab_completions.
12368 2017-02-24 Alan Hayward <alan.hayward@arm.com>
12370 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
12372 2017-02-24 Alan Hayward <alan.hayward@arm.com>
12374 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
12375 I386_MAX_REGISTER_SIZE.
12376 (i386_pseudo_register_write): Likewise.
12377 (i386_process_record): Likewise.
12378 * i387-tdep.c (i387_supply_xsave): Likewise.
12379 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
12380 (store_register): Likewise.
12382 2017-02-23 Pedro Alves <palves@redhat.com>
12384 * ada-lang.c: Include "common/function-view.h".
12385 (ada_iterate_over_symbols): Adjust to use function_view as
12387 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
12388 (ada_make_symbol_completion_list): Use a lambda.
12389 (ada_exc_search_name_matches): Delete.
12390 (name_matches_regex): New.
12391 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
12392 * compile/compile-c-support.c: Include "common/function-view.h".
12393 (print_one_macro): Change prototype to accept a ui_file pointer.
12394 (write_macro_definitions): Use a lambda.
12395 * dwarf2read.c: Include "common/function-view.h".
12396 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
12397 (dw2_expand_symtabs_matching): Adjust to use function_view as
12399 * language.h: Include "common/function-view.h".
12400 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
12401 function_view as callback type.
12402 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
12403 * linespec.c: Include "common/function-view.h".
12404 (collect_info::add_symbol): New method.
12405 (struct symbol_and_data_callback, iterate_inline_only, struct
12406 symbol_matcher_data, iterate_name_matcher): Delete.
12407 (iterate_over_all_matching_symtabs): Adjust to use function_view
12408 as callback type and lambdas.
12409 (iterate_over_file_blocks): Adjust to use function_view as
12411 (decode_compound_collector): Now a class with private fields.
12412 (decode_compound_collector::release_symbols): New method.
12413 (collect_one_symbol): Rename to...
12414 (decode_compound_collector::operator()): ... this and adjust.
12415 (lookup_prefix_sym): decode_compound_collector construction bits
12416 move to decode_compound_collector ctor. Pass the
12417 decode_compound_collector object directly as callback. Remove
12418 cleanups and use decode_compound_collector::release_symbols
12420 (symtab_collector): Now a class with private fields.
12421 (symtab_collector::release_symtabs): New method.
12422 (add_symtabs_to_list): Rename to...
12423 (symtab_collector::operator()): ... this and adjust.
12424 (collect_symtabs_from_filename): symtab_collector construction
12425 bits move to symtab_collector ctor. Pass the symtab_collector
12426 object directly as callback. Remove cleanups and use
12427 symtab_collector::release_symtabs instead.
12428 (collect_symbols): Delete.
12429 (add_matching_symbols_to_info): Use lambdas.
12430 * macrocmd.c (print_macro_callback): Delete.
12431 (info_macro_command): Use a lambda.
12432 (info_macros_command): Pass print_macro_definition as callable
12434 (print_one_macro): Remove 'ignore' parameter.
12435 (macro_list_command): Adjust.
12436 * macrotab.c (macro_for_each_data::fn): Now a function_view.
12437 (macro_for_each_data::user_data): Delete field.
12438 (foreach_macro): Adjust to call the function_view.
12439 (macro_for_each): Adjust to use function_view as callback type.
12440 (foreach_macro_in_scope): Adjust to call the function_view.
12441 (macro_for_each_in_scope): Adjust to use function_view as callback
12443 * macrotab.h: Include "common/function-view.h".
12444 (macro_callback_fn): Declare a prototype instead of a pointer.
12445 Remove "user_data" parameter.
12446 (macro_for_each, macro_for_each_in_scope): Adjust to use
12447 function_view as callback type.
12448 * psymtab.c (partial_map_expand_apply)
12449 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
12450 Adjust to use function_view as callback type and to return bool.
12451 (psym_expand_symtabs_matching): Adjust to use function_view as
12453 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
12454 to use function_view as callback type and to return bool.
12455 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
12457 * symfile.c (expand_symtabs_matching): Adjust to use function_view
12459 * symfile.h: Include "common/function-view.h".
12460 (expand_symtabs_file_matcher_ftype)
12461 (expand_symtabs_symbol_matcher_ftype)
12462 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
12464 (quick_symbol_functions::map_symtabs_matching_filename)
12465 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
12466 function_view as callback type and return bool.
12467 (expand_symtabs_matching): Adjust to use function_view as callback
12469 (maintenance_expand_name_matcher)
12470 (maintenance_expand_file_matcher): Delete.
12471 (maintenance_expand_symtabs): Use lambdas.
12472 * symtab.c (iterate_over_some_symtabs): Adjust to use
12473 function_view as callback types and return bool.
12474 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
12476 (lookup_symtab_callback): Delete.
12477 (lookup_symtab): Use a lambda.
12478 (iterate_over_symbols): Adjust to use function_view as callback
12480 (struct search_symbols_data, search_symbols_file_matches)
12481 (search_symbols_name_matches): Delete.
12482 (search_symbols): Use a pair of lambdas.
12483 (struct add_name_data, add_macro_name, symbol_completion_matcher)
12484 (symtab_expansion_callback): Delete.
12485 (default_make_symbol_completion_list_break_on_1): Use lambdas.
12486 * symtab.h: Include "common/function-view.h".
12487 (iterate_over_some_symtabs): Adjust to use function_view as
12488 callback type and return bool.
12489 (iterate_over_symtabs): Adjust to use function_view as callback
12491 (symbol_found_callback_ftype): Remove 'data' parameter and return
12493 (iterate_over_symbols): Adjust to use function_view as callback
12496 2017-02-23 Pedro Alves <palves@redhat.com>
12498 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
12499 (%.o) <unittests/%.c>: New pattern.
12500 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
12501 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
12502 * common/function-view.h: New file.
12503 * unittests/function-view-selftests.c: New file.
12504 * configure: Regenerate.
12506 2017-02-23 Simon Marchi <simon.marchi@ericsson.com>
12508 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
12510 * go32-nat.c (go32_thread_alive): Likewise.
12512 2017-02-23 Yao Qi <yao.qi@linaro.org>
12514 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
12517 2017-02-23 Yao Qi <yao.qi@linaro.org>
12519 * varobj.c (varobj_clear_saved_item): Use delete instead of
12521 (update_dynamic_varobj_children): Likewise.
12523 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12525 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
12527 2017-02-21 Simon Marchi <simon.marchi@ericsson.com>
12529 * common/enum-flags.h (enum_flags::enum_flags): Initialize
12530 m_enum_value to 0 in default constructor.
12532 2017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
12534 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
12535 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
12536 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
12537 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
12538 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
12539 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
12540 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
12541 IS_STORE_CONDITIONAL_INSN.
12543 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12545 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
12547 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12549 * NEWS (Changes since GDB 7.12): Add DWARF-5.
12551 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12553 * dwarf2read.c (skip_one_die, read_attribute_value)
12554 (dwarf2_const_value_attr, dump_die_shallow)
12555 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
12556 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
12558 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12560 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
12561 (dwarf_parse_macro_header): Accept DWARF version 5.
12562 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
12564 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12566 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
12568 * common/common-exceptions.h (enum errors): Likewise.
12569 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
12570 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
12571 (dwarf_expr_context::execute_stack_op): Likewise.
12572 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
12574 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
12575 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
12576 (show_entry_values_debug, call_site_to_target_addr)
12577 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
12578 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
12579 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
12580 (value_of_dwarf_block_entry, indirect_pieced_value)
12581 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
12582 (disassemble_dwarf_expression): Likewise.
12583 * dwarf2read.c (process_die, inherit_abstract_dies)
12584 (read_call_site_scope): Likewise.
12585 * gdbtypes.h (struct func_type, struct call_site_parameter)
12586 (struct call_site): Likewise.
12587 * stack.c (read_frame_arg): Likewise.
12588 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
12590 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12592 * defs.h (read_unsigned_leb128): New declaration.
12593 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
12594 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
12595 (dwarf2_find_location_expression): Call also
12596 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
12597 * dwarf2loc.h (dwarf2_version): New declaration.
12598 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
12600 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
12602 (struct dwop_section_names): Add loclists_dwo.
12603 (dwop_section_names): Add .debug_loclists.dwo.
12604 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
12605 (struct dwarf2_per_cu_data): Add dwarf_version.
12606 (struct dwo_sections): Add loclists.
12607 (struct attr_abbrev): Add implicit_const.
12608 (read_indirect_line_string): New declaration.
12609 (read_unsigned_leb128): Delete declaration.
12610 (rcuh_kind): New definition.
12611 (read_and_check_comp_unit_head): Change parameter
12612 is_debug_types_section to section_kind.
12613 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
12614 (read_comp_unit_head): Change parameter abfd to section, add parameter
12615 section_kind. Handle DWARF-5.
12616 (error_check_comp_unit_head): Accept also DWARF version 5.
12617 (read_and_check_comp_unit_head): Change parameter
12618 is_debug_types_section to section_kind.
12619 (read_and_check_type_unit_head): Delete function.
12620 (read_abbrev_offset): Handle DWARF-5.
12621 (create_debug_type_hash_table): Add parameter section_kind. Process
12622 only DW_UT_type. Use signature and type_offset_in_tu from struct
12624 (create_debug_types_hash_table): Update create_debug_type_hash_table
12626 (create_all_type_units): Call create_debug_type_hash_table.
12627 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
12628 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
12630 (skip_one_die): Handle DW_FORM_implicit_const.
12631 (dwarf2_rnglists_process): New function.
12632 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
12633 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
12634 (read_attribute_value): Handle DW_FORM_implicit_const,
12636 (read_attribute): Handle DW_FORM_implicit_const.
12637 (read_indirect_string_at_offset_from): New function from
12638 read_indirect_string_at_offset.
12639 (read_indirect_string_at_offset): Call
12640 read_indirect_string_at_offset_from.
12641 (read_indirect_line_string_at_offset): New function.
12642 (read_indirect_string): New function comment.
12643 (read_indirect_line_string): New function.
12644 (read_unsigned_leb128): Make it global.
12645 (dwarf2_string_attr): Handle DWARF-5.
12646 (add_include_dir_stub, read_formatted_entries): New functions.
12647 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
12649 (per_cu_header_read_in): Update read_comp_unit_head caller.
12650 (dwarf2_version): New function.
12651 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
12653 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
12656 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12658 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
12660 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12662 * dwarf2read.c (dwarf2_ranges_process): New function from
12663 dwarf2_ranges_read.
12664 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
12665 dwarf2_ranges_process.
12667 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12669 * dwarf2read.c (create_debug_type_hash_table): New function from
12670 create_debug_types_hash_table.
12671 (create_debug_types_hash_table): Call create_debug_type_hash_table.
12672 (create_all_type_units, open_and_init_dwo_file): Update
12673 create_debug_types_hash_table callers.
12675 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
12678 * fork-child.c (trace_start_error): Fix thinko. va_end should
12679 refer to 'ap', not 'args'.
12681 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
12682 Pedro Alves <palves@redhat.com>
12685 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
12687 * fork-child.c (trace_start_error): New function.
12688 (trace_start_error_with_name): Likewise.
12689 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
12690 * inf-ptrace.c (inf_ptrace_me): Likewise.
12691 * inferior.h (trace_start_error): New prototype.
12692 (trace_start_error_with_name): Likewise.
12694 2017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
12697 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
12698 NULL before using it.
12699 * symmisc.c (maintenance_print_symbols): Likewise.
12700 (maintenance_print_msymbols): Likewise.
12702 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12704 * NEWS: Add record Python bindings entry.
12706 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12708 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
12710 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
12711 * python/py-record-btrace.c, python/py-record-btrace.h,
12712 python/py-record-full.c, python/py-record-full.h: New file.
12713 * python/py-record.c: Add include for py-record-btrace.h and
12715 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
12716 recpy_instruction_history, recpy_function_call_history, recpy_begin,
12717 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
12718 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
12720 (gdbpy_initialize_btrace): New export.
12721 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
12723 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12725 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
12726 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
12727 * python/py-record.c: New file.
12728 * python/python-internal.h (gdbpy_start_recording,
12729 gdbpy_current_recording, gdpy_stop_recording,
12730 gdbpy_initialize_record): New export.
12731 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
12732 (python_GdbMethods): Add gdbpy_start_recording,
12733 gdbpy_current_recording and gdbpy_stop_recording.
12735 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12737 * record-btrace.c (record_btrace_record_method): New function.
12738 (init_record_btrace_ops): Initialize to_record_method.
12739 * record-full.c (record_full_record_method): New function.
12740 (init_record_full_ops, init_record_full_core_ops): Add
12741 record_full_record_method.
12742 * record.h (enum record_method): New enum.
12743 * target-debug.h (target_debug_print_enum_record_method: New define.
12744 * target-delegates.c: Regenerate.
12745 * target.c (target_record_method): New function.
12746 * target.h: Include record.h.
12747 (struct target_ops) <to_record_method>: New field.
12748 (target_record_method): New export.
12750 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12752 * record.h (record_start, record_stop): New export.
12753 * record.c (record_start, record_stop): New function.
12755 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12757 * btrace.c (btrace_fetch): Copy function call segments pointer
12759 (btrace_clear): Clear the vector.
12760 (btrace_find_insn_by_number): Use binary search to find the correct
12761 function call segment.
12762 * btrace.h (brace_fun_p): New typedef.
12763 (struct btrace_thread_info) <functions>: New field.
12765 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12767 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
12768 * btrace.c (btrace_decode_error): ... here. New function.
12769 * btrace.h (btrace_decode_error): New export.
12771 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12773 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
12774 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
12775 btrace_find_insn_by_number): Remove special case for gaps.
12776 * btrace.h (btrace_insn_get_error): New export.
12777 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
12778 * record-btrace.c (btrace_insn_history): Print number for gaps.
12779 (record_btrace_info, record_btrace_goto): Handle gaps.
12781 2017-02-14 Tom Tromey <tom@tromey.com>
12784 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
12786 * python/py-evts.c (gdbpy_initialize_py_events): Add
12787 before_prompt registry.
12788 * python/py-events.h (events_object) <before_prompt>: New field.
12790 2017-02-14 Markus Metzger <markus.t.metzger@intel.com>
12792 * btrace.c (ftrace_new_switch): Preserve up link and flags.
12794 2017-02-13 Luis Machado <lgustavo@codesourcery.com>
12796 * symfile (_initialize_symfile): Add usage text to the load command's
12799 2017-02-10 Simon Marchi <simon.marchi@ericsson.com>
12801 * utils.c (defaulted_query): Don't query on secondary UIs.
12803 2017-02-10 Tom Tromey <tom@tromey.com>
12805 * rust-lang.c (rust_get_disr_info): Remove unused variable.
12807 2017-02-10 Tom Tromey <tom@tromey.com>
12809 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
12811 * python/py-type.c (typy_legacy_template_argument): Remove
12812 unnecessary "cleanup" local.
12814 2017-02-10 Tom Tromey <tom@tromey.com>
12816 * python/python.c (do_start_initialization): New function, from
12817 _initialize_python.
12818 (_initialize_python): Call do_start_initialization.
12819 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
12822 2017-02-10 Tom Tromey <tom@tromey.com>
12824 * python/py-prettyprint.c (pretty_print_one_value): Use
12827 2017-02-10 Tom Tromey <tom@tromey.com>
12829 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
12830 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
12832 * python/py-type.c (field_new): Use gdbpy_ref.
12833 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
12835 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
12836 (py_free_pspace): Likewise.
12837 (pspace_to_pspace_object): Likewise.
12838 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
12839 (py_free_objfile): Likewise.
12840 (objfile_to_objfile_object): Likewise.
12841 * python/py-inferior.c (delete_thread_object): Use
12843 (infpy_read_memory): Likewise.
12844 (py_free_inferior): Likewise.
12845 * python/py-evtregistry.c (create_eventregistry_object): Use
12847 * python/py-event.c (create_event_object): Use gdbpy_ref.
12849 2017-02-10 Tom Tromey <tom@tromey.com>
12851 * python/py-ref.h (gdbpy_ref_policy): Now a template.
12852 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
12854 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
12855 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
12856 python/py-exitedevent.c, python/py-finishbreakpoint.c,
12857 python/py-framefilter.c, python/py-function.c,
12858 python/py-inferior.c, python/py-infevents.c,
12859 python/py-linetable.c, python/py-newobjfileevent.c,
12860 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
12861 python/py-signalevent.c, python/py-stopevent.c,
12862 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
12863 python/py-unwind.c, python/py-utils.c, python/py-value.c,
12864 python/py-varobj.c, python/py-xmethods.c, python/python.c,
12865 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
12867 2017-02-10 Tom Tromey <tom@tromey.com>
12869 * ui-out.h (ui_out_emit_type): New class.
12870 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
12871 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
12872 and ui_out_emit_tuple.
12873 (enumerate_locals): Likewise.
12874 (py_mi_print_variables, py_print_locals, py_print_args): Use
12876 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
12878 * common/gdb_optional.h: New file.
12880 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
12882 * MAINTAINERS (Write After Approval): Update my e-mail address.
12884 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
12887 * breakpoint.c (_initialize_breakpoint): Update the help description
12888 of the 'commands' command to indicate that it takes a list argument.
12890 2017-02-09 Simon Marchi <simon.marchi@ericsson.com>
12892 * interps.c (current_interp_set_logging): Remove "return".
12894 2017-02-09 Gary Benson <gbenson@redhat.com>
12896 * symtab.c (add_symtab_completions): Prevent NULL pointer
12899 2017-02-08 Pedro Alves <palves@redhat.com>
12901 * interps.c (interp::interp): Remove reference to quiet_p.
12902 (interp_set): Make static. Remove dead "Switching to" output
12904 (interp_quiet_p, interp_set_quiet): Delete.
12905 (interpreter_exec_cmd): Don't set the interpreter quiet.
12906 * interps.h (interp_quiet_p): Make static.
12907 (class interp) <quiet_p>: Remove field
12909 2017-02-08 Jerome Guitton <guitton@adacore.com>
12911 * cli/cli-decode.c (find_command_name_length): Make it extern.
12912 * cli/cli-decode.h (find_command_name_length): Declare.
12913 * cli/cli-script.c (command_name_equals, line_first_arg):
12915 (process_next_line): Use cli-decode to parse command names.
12916 (build_command_line): Make args a constant pointer.
12918 2017-02-08 Jerome Guitton <guitton@adacore.com>
12920 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
12921 Remove case-insensitive search.
12923 2017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
12925 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
12926 at the end of the line. Avoids an ARI warning.
12928 2017-02-06 Luis Machado <lgustavo@codesourcery.com>
12930 * NEWS: Mention support for record/replay of Intel 64 rdrand and
12931 rdseed instructions.
12932 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
12934 2017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
12937 Provide and use sparc32 and sparc64 target description XML files.
12938 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
12939 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
12940 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
12941 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
12942 * features/sparc/sparc32-solaris.xml: New file.
12943 * features/sparc/sparc64-solaris.xml: New file.
12944 * features/sparc/sparc32-solaris.c: Generated.
12945 * features/sparc/sparc64-solaris.c: Generated.
12946 * sparc-tdep.h: Account for differences in target descriptions.
12947 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
12948 (sparc32_register_type): Use target provided registers.
12949 (validate_tdesc_registers): New function.
12950 (sparc32_gdbarch_init): Use tdesc_has_registers.
12951 Set pseudoregister functions.
12952 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
12953 (sparc64_register_type): Use target provided registers.
12954 (sparc64_init_abi): Set pseudoregister functions.
12956 2017-02-03 Tom Tromey <tom@tromey.com>
12959 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
12960 with a single member.
12962 2017-02-03 Pedro Alves <palves@redhat.com>
12964 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
12965 (cli_interp_base::~cli_interp_base): New.
12966 (cli_interp): New struct.
12967 (as_cli_interp): Cast the interp itself to cli_interp.
12968 (cli_interpreter_pre_command_loop): Rename to ...
12969 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
12971 (cli_interpreter_init): Rename to ...
12972 (cli_interp::init): ... this. Remove 'self' parameter. Use
12973 boolean. Make extern.
12974 (cli_interpreter_resume): Rename to ...
12975 (cli_interp::resume): ... this. Remove 'data' parameter. Make
12977 (cli_interpreter_suspend): Rename to ...
12978 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
12980 (cli_interpreter_exec): Rename to ...
12981 (cli_interp::exec): ... this. Remove 'data' parameter. Make
12983 (cli_interpreter_supports_command_editing): Rename to ...
12984 (cli_interp_base::supports_command_editing): ... this. Remove
12985 'interp' parameter. Make extern.
12986 (cli_ui_out): Rename to ...
12987 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
12989 (cli_set_logging): Rename to ...
12990 (cli_interp_base::set_logging): ... this. Remove 'interp'
12991 parameter. Make extern.
12992 (cli_interp_procs): Delete.
12993 (cli_interp_factory): Adjust to use "new".
12994 * cli/cli-interp.h: Include "interps.h".
12995 (struct cli_interp_base): New struct.
12996 * interps.c (struct interp): Delete. Fields moved to interps.h.
12997 (interp_new): Delete.
12998 (interp::interp, interp::~interp): New.
12999 (interp_set): Use bool, and return void. Assume the interpreter
13000 has suspend, init and resume methods, and that the all return
13002 (set_top_level_interpreter): interp_set returns void.
13003 (interp_ui_out): Adapt.
13004 (current_interp_set_logging): Adapt.
13005 (interp_data): Delete.
13006 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
13007 (interp_exec): Adapt.
13008 (top_level_interpreter_data): Delete.
13009 * interps.h (interp_init_ftype, interp_resume_ftype)
13010 (interp_suspend_ftype, interp_exec_ftype)
13011 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
13012 (class interp): New.
13013 (interp_new): Delete.
13014 (interp_set): Now returns void. Use bool.
13015 (interp_data, top_level_interpreter_data): Delete.
13016 * mi/mi-common.h: Include interps.h.
13017 (class mi_interp): Inherit from interp. Define a ctor. Declare
13018 init, resume, suspect, exec, interp_ui_out, set_logging and
13019 pre_command_loop methods.
13020 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
13021 (mi_interpreter_init): Rename to ...
13022 (mi_interp::init): ... this. Remove the 'interp' parameter, use
13023 bool, return void and make extern. Adjust.
13024 (mi_interpreter_resume): ... Rename to ...
13025 (mi_interp::resume): ... this. Remove the 'data' parameter,
13026 return void and make extern. Adjust.
13027 (mi_interpreter_suspend): ... Rename to ...
13028 (mi_interp::suspend): ... this. Remove the 'data' parameter,
13029 return void and make extern. Adjust.
13030 (mi_interpreter_exec): ... Rename to ...
13031 (mi_interp::exec): ... this. Remove the 'data' parameter and make
13033 (mi_interpreter_pre_command_loop): ... Rename to ...
13034 (mi_interp::pre_command_loop): ... this. Remove the 'self'
13035 parameter and make extern.
13036 (mi_on_normal_stop_1): Adjust.
13037 (mi_ui_out): Rename to ...
13038 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
13039 parameter and make extern. Adjust.
13040 (mi_set_logging): Rename to ...
13041 (mi_interp::set_logging): ... this. Remove the 'interp'
13042 parameter and make extern. Adjust.
13043 (mi_interp_procs): Delete.
13044 (mi_interp_factory): Adjust to use 'new'.
13045 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
13046 (mi_print_exception, mi_execute_command, mi_load_progress):
13048 * tui/tui-interp.c (tui_interp): New class.
13049 (as_tui_interp): Return a tui_interp pointer.
13050 (tui_on_normal_stop, tui_on_signal_received)
13051 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
13052 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
13053 to use interp::interp_ui_out.
13054 (tui_init): Rename to ...
13055 (tui_interp::init): ... this. Remove the 'self' parameter, use
13056 bool, return void and make extern. Adjust.
13057 (tui_resume): Rename to ...
13058 (tui_interp::resume): ... this. Remove the 'data' parameter,
13059 return void and make extern. Adjust.
13060 (tui_suspend): Rename to ...
13061 (tui_interp::suspend): ... this. Remove the 'data' parameter,
13062 return void and make extern. Adjust.
13063 (tui_ui_out): Rename to ...
13064 (tui_interp::interp_ui_out): ... this. Remove the 'self'
13065 parameter, and make extern. Adjust.
13066 (tui_exec): Rename to ...
13067 (tui_interp::exec): ... this. Remove the 'data' parameter and
13069 (tui_interp_procs): Delete.
13070 (tui_interp_factory): Use "new".
13072 2017-02-02 Tom Tromey <tom@tromey.com>
13074 * rust-exp.y (ends_raw_string, space_then_number)
13075 (rust_identifier_start_p): Return bool.
13076 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
13077 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
13078 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
13079 (rust_chartype_p): Return bool.
13080 (val_print_struct, rust_print_struct_def, rust_print_type):
13082 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
13085 2017-02-02 Tom Tromey <tom@tromey.com>
13087 * rust-lang.c: Reindent.
13089 2017-02-02 Tom Tromey <tom@tromey.com>
13091 * rust-lang.h (rust_crate_for_block): Update.
13092 * rust-lang.c (rust_crate_for_block): Return std::string.
13093 (rust_get_disr_info): Use std:;string, not
13094 gdb::unique_xmalloc_ptr.
13095 * rust-exp.y (crate_name): Update.
13097 2017-02-02 Pedro Alves <palves@redhat.com>
13099 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
13100 field out of gdb_disassembler_test and make it static.
13102 2017-02-02 Pedro Alves <palves@redhat.com>
13104 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
13105 mi1_interp and mi_interp fields.
13107 2017-02-02 Pedro Alves <palves@redhat.com>
13109 * cli/cli-interp.c (struct saved_output_files, saved_output):
13110 Moved from cli/cli-logging.c.
13111 (cli_set_logging): New function.
13112 (cli_interp_procs): Install cli_set_logging.
13113 * cli/cli-interp.h (make_logging_output, cli_set_logging):
13115 * cli/cli-logging.c (struct saved_output_files, saved_output):
13116 Moved to cli/cli-interp.c.
13117 (pop_output_files): Don't save outputs here.
13118 (make_logging_output): New function.
13119 (handle_redirections): Don't build tee nor save previous outputs
13121 * interps.c (current_interp_set_logging): Change prototype.
13122 Assume there's always a set_logging_proc method installed.
13123 * interps.h (interp_set_logging_ftype): Change prototype.
13124 (current_interp_set_logging): Change prototype and adjust comment.
13125 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
13126 use make_logging_output.
13127 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
13128 2017-02-02 Pedro Alves <palves@redhat.com>
13130 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
13132 (set_logging_overwrite): ... here.
13133 (logging_no_redirect_file): Delete.
13134 (set_logging_redirect): Don't handle redirection on the fly.
13135 Instead warn that "logging off" / "logging on" is necessary.
13136 (pop_output_files): Delete references to logging_no_redirect_file.
13137 (show_logging_command): Always speak in terms of what will happen
13138 once logging is reenabled.
13140 2017-02-02 Pedro Alves <palves@redhat.com>
13142 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
13144 2017-02-02 Pedro Alves <palves@redhat.com>
13146 * disasm.c (gdb_pretty_print_insn): Rename to ...
13147 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
13148 Remove gdbarch parameter. Adapt to clear the object's buffers
13149 instead of allocating new buffers, and to print using the object's
13150 gdb_disassembler instead of calling gdb_print_insn.
13151 (dump_insns): Use gdb_pretty_print_disassembler.
13152 * disasm.h (gdb_pretty_print_insn): Delete declaration.
13153 (gdb_pretty_print_disassembler): New class.
13154 * record-btrace.c (btrace_insn_history): Use
13155 gdb_pretty_print_disassembler.
13157 2017-02-02 Pedro Alves <palves@redhat.com>
13159 * ada-lang.c (type_as_string): Use string_file.
13160 * ada-valprint.c (ada_print_floating): Use string_file.
13161 * ada-varobj.c (ada_varobj_scalar_image)
13162 (ada_varobj_get_value_image): Use string_file.
13163 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
13164 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
13165 * breakpoint.c (update_inserted_breakpoint_locations)
13166 (insert_breakpoint_locations, reattach_breakpoints)
13167 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
13168 (print_it_watchpoint): Use string_file.
13169 (save_breakpoints): Use stdio_file.
13170 * c-exp.y (oper): Use string_file.
13171 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
13173 (pop_output_files): Use delete.
13174 (handle_redirections): Use stdio_file and tee_file.
13175 * cli/cli-setshow.c (do_show_command): Use string_file.
13176 * compile/compile-c-support.c (c_compute_program): Use
13178 * compile/compile-c-symbols.c (generate_vla_size): Take a
13179 'string_file &' instead of a 'ui_file *'.
13180 (generate_c_for_for_one_variable): Take a 'string_file &' instead
13181 of a 'ui_file *'. Use string_file.
13182 (generate_c_for_variable_locations): Take a 'string_file &'
13183 instead of a 'ui_file *'.
13184 * compile/compile-internal.h (generate_c_for_for_one_variable):
13185 Take a 'string_file &' instead of a 'ui_file *'.
13186 * compile/compile-loc2c.c (push, pushf, unary, binary)
13187 (print_label, pushf_register_address, pushf_register)
13188 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
13189 'ui_file *'. Adjust.
13190 * compile/compile.c (compile_to_object): Use string_file.
13191 * compile/compile.h (compile_dwarf_expr_to_c)
13192 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
13194 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
13195 (replace_typedefs_qualified_name): Use string_file and
13197 * disasm.c (gdb_pretty_print_insn): Use string_file.
13198 (gdb_disassembly): Adjust reference the null_stream global.
13199 (do_ui_file_delete): Delete.
13200 (gdb_insn_length): Use null_stream.
13201 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
13202 * dwarf2loc.c (dwarf2_compile_property_to_c)
13203 (locexpr_generate_c_location, loclist_generate_c_location): Take a
13204 'string_file &' instead of a 'ui_file *'.
13205 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
13206 * dwarf2read.c (do_ui_file_peek_last): Delete.
13207 (dwarf2_compute_name): Use string_file.
13208 * event-top.c (gdb_setup_readline): Use stdio_file.
13209 * gdbarch.sh (verify_gdbarch): Use string_file.
13210 * gdbtypes.c (safe_parse_type): Use null_stream.
13211 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
13213 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
13214 'string_file *' instead of a 'ui_file *'.
13215 (gdbscm_arch_disassemble): Use string_file.
13216 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
13217 * guile/scm-ports.c (class ioscm_file_port): Now a class that
13218 inherits from ui_file.
13219 (ioscm_file_port_delete, ioscm_file_port_rewind)
13220 (ioscm_file_port_put): Delete.
13221 (ioscm_file_port_write): Rename to ...
13222 (ioscm_file_port::write): ... this. Remove file_port_magic
13224 (ioscm_file_port_new): Delete.
13225 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
13227 * guile/scm-type.c (tyscm_type_name): Use string_file.
13228 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
13230 * infcmd.c (print_return_value_1): Use string_file.
13231 * infrun.c (print_target_wait_results): Use string_file.
13232 * language.c (add_language): Use string_file.
13233 * location.c (explicit_to_string_internal): Use string_file.
13234 * main.c (captured_main_1): Use null_file.
13235 * maint.c (maintenance_print_architecture): Use stdio_file.
13236 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
13237 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
13238 event_channel>: Change type to mi_console_file pointer.
13239 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
13240 (mi_console_file_delete): Delete.
13241 (struct mi_console_file): Delete.
13242 (mi_console_file_magic): Delete.
13243 (mi_console_file_new): Delete.
13244 (mi_console_file::mi_console_file): New.
13245 (mi_console_file_delete): Delete.
13246 (mi_console_file_fputs): Delete.
13247 (mi_console_file::write): New.
13248 (mi_console_raw_packet): Delete.
13249 (mi_console_file::flush): New.
13250 (mi_console_file_flush): Delete.
13251 (mi_console_set_raw): Rename to ...
13252 (mi_console_file::set_raw): ... this.
13253 * mi/mi-console.h (class mi_console_file): New class.
13254 (mi_console_file_new, mi_console_set_raw): Delete.
13255 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
13256 (mi_set_logging): Use delete and tee_file. Adjust.
13257 * mi/mi-main.c (output_register): Use string_file.
13258 (mi_cmd_data_evaluate_expression): Use string_file.
13259 (mi_cmd_data_read_memory): Use string_file.
13260 (mi_cmd_execute, print_variable_or_computed): Use string_file.
13261 * mi/mi-out.c (mi_ui_out::main_stream): New.
13262 (mi_ui_out::rewind): Use main_stream and
13264 (mi_ui_out::put): Use main_stream and string_file.
13265 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
13266 Allocate a 'string_file' instead.
13267 (mi_out_new): Don't allocate a mem_fileopen stream here.
13268 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
13269 (mi_ui_out::main_stream): Declare method.
13270 * printcmd.c (eval_command): Use string_file.
13271 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
13272 * python/py-arch.c (archpy_disassemble): Use string_file.
13273 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
13274 * python/py-frame.c (frapy_str): Use string_file.
13275 * python/py-framefilter.c (py_print_type, py_print_single_arg):
13277 * python/py-type.c (typy_str): Use string_file.
13278 * python/py-unwind.c (unwind_infopy_str): Use string_file.
13279 * python/py-value.c (valpy_str): Use string_file.
13280 * record-btrace.c (btrace_insn_history): Use string_file.
13281 * regcache.c (regcache_print): Use stdio_file.
13282 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
13283 * remote.c (escape_buffer): Use string_file.
13284 * rust-lang.c (rust_get_disr_info): Use string_file.
13285 * serial.c (serial_open_ops_1): Use stdio_file.
13286 (do_serial_close): Use delete.
13287 * stack.c (print_frame_arg): Use string_file.
13288 (print_frame_args): Remove local mem_fileopen stream, not used.
13289 (print_frame): Use string_file.
13290 * symmisc.c (maintenance_print_symbols): Use stdio_file.
13291 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
13292 Take a 'string_file *' instead of a 'ui_file *'.
13293 * top.c (new_ui): Use stdio_file and stderr_file.
13294 (free_ui): Use delete.
13295 (execute_command_to_string): Use string_file.
13296 (quit_confirm): Use string_file.
13297 * tracepoint.c (collection_list::append_exp): Use string_file.
13298 * tui/tui-disasm.c (tui_disassemble): Use string_file.
13299 * tui/tui-file.c: Don't include "ui-file.h".
13300 (enum streamtype, struct tui_stream): Delete.
13301 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
13302 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
13303 (tui_file::tui_file): New method.
13304 (tui_file_fputs): Delete.
13305 (tui_file_get_strbuf): Delete.
13306 (tui_file::puts): New method.
13307 (tui_file_adjust_strbuf): Delete.
13308 (tui_file_flush): Delete.
13309 (tui_file::flush): New method.
13310 * tui/tui-file.h: Tweak intro comment.
13312 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
13313 (tui_file_adjust_strbuf): Delete declarations.
13314 (class tui_file): New class.
13315 * tui/tui-io.c (tui_initialize_io): Use tui_file.
13316 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
13317 (tui_register_format): Use string_stream.
13318 * tui/tui-stack.c (tui_make_status_line): Use string_file.
13319 (tui_get_function_from_frame): Use string_file.
13320 * typeprint.c (type_to_string): Use string_file.
13321 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
13322 (null_stream): New global.
13323 (ui_file_delete): Delete.
13324 (ui_file::ui_file): New.
13325 (null_file_isatty): Delete.
13326 (ui_file::~ui_file): New.
13327 (null_file_rewind): Delete.
13328 (ui_file::printf): New.
13329 (null_file_put): Delete.
13330 (null_file_flush): Delete.
13331 (ui_file::putstr): New.
13332 (null_file_write): Delete.
13333 (ui_file::putstrn): New.
13334 (null_file_read): Delete.
13335 (ui_file::putc): New.
13336 (null_file_fputs): Delete.
13337 (null_file_write_async_safe): Delete.
13338 (ui_file::vprintf): New.
13339 (null_file_delete): Delete.
13340 (null_file::write): New.
13341 (null_file_fseek): Delete.
13342 (null_file::puts): New.
13343 (ui_file_data): Delete.
13344 (null_file::write_async_safe): New.
13345 (gdb_flush, ui_file_isatty): Adjust.
13346 (ui_file_put, ui_file_rewind): Delete.
13347 (ui_file_write): Adjust.
13348 (ui_file_write_for_put): Delete.
13349 (ui_file_write_async_safe, ui_file_read): Adjust.
13350 (ui_file_fseek): Delete.
13351 (fputs_unfiltered): Adjust.
13352 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
13353 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
13354 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
13355 (set_ui_file_data): Delete.
13356 (string_file::~string_file, string_file::write)
13357 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
13358 (do_ui_file_as_string, ui_file_as_string): Delete.
13359 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
13360 (struct mem_file): Delete.
13361 (mem_file_new): Delete.
13362 (stdio_file::stdio_file): New.
13363 (mem_file_delete): Delete.
13364 (stdio_file::stdio_file): New.
13365 (mem_fileopen): Delete.
13366 (stdio_file::~stdio_file): New.
13367 (mem_file_rewind): Delete.
13368 (stdio_file::set_stream): New.
13369 (mem_file_put): Delete.
13370 (stdio_file::open): New.
13371 (mem_file_write): Delete.
13372 (stdio_file_magic, struct stdio_file): Delete.
13373 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
13374 (stdio_file::flush): New.
13375 (stdio_file_read): Rename to ...
13376 (stdio_file::read): ... this. Adjust.
13377 (stdio_file_write): Rename to ...
13378 (stdio_file::write): ... this. Adjust.
13379 (stdio_file_write_async_safe): Rename to ...
13380 (stdio_file::write_async_safe) ... this. Adjust.
13381 (stdio_file_fputs): Rename to ...
13382 (stdio_file::puts) ... this. Adjust.
13383 (stdio_file_isatty): Delete.
13384 (stdio_file_fseek): Delete.
13385 (stdio_file::isatty): New.
13386 (stderr_file_write): Rename to ...
13387 (stderr_file::write) ... this. Adjust.
13388 (stderr_file_fputs): Rename to ...
13389 (stderr_file::puts) ... this. Adjust.
13390 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
13391 (stderr_file::stderr_file): New.
13392 (tee_file_magic): Delete.
13393 (struct tee_file): Delete.
13394 (tee_file::tee_file): New.
13395 (tee_file_new): Delete.
13396 (tee_file::~tee_file): New.
13397 (tee_file_delete): Delete.
13398 (tee_file_flush): Rename to ...
13399 (tee_file::flush): ... this. Adjust.
13400 (tee_file_write): Rename to ...
13401 (tee_file::write): ... this. Adjust.
13402 (tee_file::write_async_safe): New.
13403 (tee_file_fputs): Rename to ...
13404 (tee_file::puts): ... this. Adjust.
13405 (tee_file_isatty): Rename to ...
13406 (tee_file::isatty): ... this. Adjust.
13407 * ui-file.h (struct obstack, struct ui_file): Don't
13409 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
13410 (ui_file_write_ftype)
13411 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
13412 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
13413 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
13414 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
13415 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
13416 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
13417 (set_ui_file_fseek): Delete.
13418 (ui_file_data, ui_file_delete, ui_file_rewind)
13419 (struct ui_file): New.
13421 (class null_file): New.
13422 (null_stream): Declare.
13423 (ui_file_write_for_put, ui_file_put): Delete.
13424 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
13426 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
13427 (gdb_fopen, tee_file_new): Delete.
13428 (struct string_file): New.
13429 (struct stdio_file): New.
13430 (stdio_file_up): New.
13431 (struct stderr_file): New.
13432 (class tee_file): New.
13433 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
13434 of a 'ui_file *'. Adjust.
13435 * ui-out.h (class ui_out) <field_stream>: Likewise.
13436 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
13437 (null_stream): Delete.
13438 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
13440 * utils.h (struct ui_file): Delete forward declaration..
13441 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
13442 (error_stream): Take a 'string_file &' instead of a
13444 * varobj.c (varobj_value_get_print_value): Use string_file.
13445 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
13446 * gdbarch.c: Regenerate.
13448 2017-02-02 Pedro Alves <palves@redhat.com>
13450 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
13451 (gdb_pretty_print_insn): ... this. Now a free function. Add back
13452 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
13453 Adjust to call gdb_print_insn instead of
13454 gdb_disassembler::print_insn.
13455 (dump_insns, do_mixed_source_and_assembly_deprecated)
13456 (do_mixed_source_and_assembly, do_assembly_only): Add back a
13457 'gdbarch' parameter. Remove gdb_disassembler parameter.
13458 (gdb_disassembly): Don't allocate a gdb_disassembler here.
13459 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
13461 (gdb_pretty_print_insn): Re-add declaration.
13462 * record-btrace.c (btrace_insn_history): Don't allocate a
13463 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
13465 2017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
13467 * disasm.h (gdb_disassembly): Remove file_string parameter.
13468 * disasm.c (gdb_disassembly): Likewise.
13469 * cli/cli-cmds.c (print_disassembly): Adapt.
13470 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
13471 * stack.c (do_gdb_disassembly): Likewise.
13473 2017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
13475 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
13476 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
13477 targets. And if the implicit value is longer than needed, extract
13478 the first bytes instead of the "least significant" ones.
13480 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
13482 * btrace.c (btrace_enable): Do not call btrace_add_pc for
13483 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
13484 (btrace_fetch): Assert can_access_registers_ptid.
13485 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
13486 validate_registers_access.
13488 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
13490 * gdbthread.h (can_access_registers_ptid): New.
13491 * thread.c (can_access_registers_ptid): New.
13493 2017-02-01 Pedro Alves <palves@redhat.com>
13495 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
13497 2017-01-31 Pedro Alves <palves@redhat.com>
13499 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
13502 2017-01-31 Pedro Alves <palves@redhat.com>
13504 * stack.c (print_frame_args): Remove local mem_fileopen stream,
13507 2017-01-31 Pedro Alves <palves@redhat.com>
13509 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
13511 2017-01-31 Pedro Alves <palves@redhat.com>
13513 * common/scoped_restore.h
13514 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
13515 change the value's parameter type to T2.
13516 (make_scoped_restore): Likewise.
13518 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
13519 Richard Henderson <rth@redhat.com>
13521 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
13522 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
13523 GS_BASE for older kernels.
13524 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
13525 GS_BASE for older kernels.
13526 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
13527 and GS_BASE to the offset table.
13528 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
13529 system register group.
13530 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
13532 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
13534 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
13535 AMD64_GSBASE_REGNUM.
13536 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
13537 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
13538 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
13539 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
13540 i386/64bit-segments.xml in those rules.
13541 * features/i386/64bit-segments.xml: New file.
13542 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
13543 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
13544 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
13545 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
13546 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
13547 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
13548 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
13549 * features/i386/amd64-avx-linux.c: Regenerated.
13550 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
13551 * features/i386/amd64-avx-mpx.c: Regenerated.
13552 * features/i386/amd64-avx512-linux.c: Regenerated.
13553 * features/i386/amd64-linux.c: Regenerated.
13554 * features/i386/amd64-mpx-linux.c: Regenerated.
13555 * features/i386/i386-avx-mpx-linux.c: Regenerated.
13556 * features/i386/i386-avx-mpx.c: Regenerated.
13557 * features/i386/x32-avx-linux.c: Regenerated.
13558 * features/i386/x32-avx512-linux.c: Regenerated.
13559 * regformats/i386/amd64-avx-linux.dat: Regenerated.
13560 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
13561 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
13562 * regformats/i386/amd64-linux.dat: Regenerated.
13563 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
13564 * regformats/i386/x32-avx-linux.dat: Regenerated.
13565 * regformats/i386/x32-avx512-linux.dat: Regenerated.
13566 * regformats/i386/x32-linux.dat: Regenerated.
13568 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
13570 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
13571 Set to AMD64_NUM_REGS.
13573 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
13575 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
13576 that checks validity of a register number.
13578 2017-01-27 Kees Cook <keescook@google.com>
13580 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
13581 fetch_fpregs if target has fpa registers.
13582 (arm_linux_store_inferior_registers): Call store_fpregs if target
13585 2017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
13587 * cris-tdep.c (cris_gdbarch_init): Remove check for
13588 info.byte_order and force it to BFD_ENDIAN_LITTLE.
13590 2017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
13592 * corelow.c (get_core_register_section): Check for regset
13593 existence before checking for REGSET_VARIABLE_SIZE.
13595 2017-01-26 Yao Qi <yao.qi@linaro.org>
13596 Pedro Alves <palves@redhat.com>
13599 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
13600 call memory_error, save memaddr instead.
13601 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
13602 negative, cal memory_error.
13603 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
13605 2017-01-26 Yao Qi <yao.qi@linaro.org>
13607 * disasm-selftests.c (memory_error_test): New function.
13608 (_initialize_disasm_selftests): Register memory_error_test.
13610 2017-01-26 Yao Qi <yao.qi@linaro.org>
13612 * Makefile.in (SFILES): Add disasm-selftests.c and
13614 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
13615 * disasm-selftests.c: New file.
13616 * selftest-arch.c: New file.
13617 * selftest-arch.h: New file.
13619 2017-01-26 Yao Qi <yao.qi@linaro.org>
13621 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
13622 to bfd_arch_mep. Don't return 0 if section is not
13623 found. Call print_insn_mep.
13625 2017-01-26 Pedro Alves <palves@redhat.com>
13626 Yao Qi <yao.qi@linaro.org>
13628 * arm-tdep.c: Include "disasm.h".
13629 (gdb_print_insn_arm): Update code to get gdbarch.
13630 * disasm.c (dis_asm_read_memory): Change it to
13631 gdb_disassembler::dis_asm_read_memory.
13632 (dis_asm_memory_error): Likewise.
13633 (dis_asm_print_address): Likewise.
13634 (gdb_pretty_print_insn): Change it to
13635 gdb_disassembler::pretty_print_insn.
13636 (dump_insns): Add one argument gdb_disassemlber. All
13638 (do_mixed_source_and_assembly_deprecated): Likewise.
13639 (do_mixed_source_and_assembly): Likewise.
13640 (do_assembly_only): Likewise.
13641 (gdb_disassembler::gdb_disassembler): New.
13642 (gdb_disassembler::print_insn): New.
13643 * disasm.h (class gdb_disassembler): New.
13644 (gdb_pretty_print_insn): Remove declaration.
13645 (gdb_disassemble_info): Likewise.
13646 * guile/scm-disasm.c (class gdbscm_disassembler): New.
13647 (gdbscm_disasm_read_memory_worker): Update.
13648 (gdbscm_disasm_read_memory): Update.
13649 (gdbscm_disasm_memory_error): Remove.
13650 (gdbscm_disasm_print_address): Remove.
13651 (gdbscm_disassembler::gdbscm_disassembler): New.
13652 (gdbscm_print_insn_from_port): Update.
13653 * mips-tdep.c: Include disasm.h.
13654 (gdb_print_insn_mips): Update code to get gdbarch.
13655 * record-btrace.c (btrace_insn_history): Update.
13656 * spu-tdep.c: Include disasm.h.
13657 (struct spu_dis_asm_data): Remove.
13658 (struct spu_dis_asm_info): New.
13659 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
13661 (gdb_print_insn_spu): Cast disassemble_info to
13664 2017-01-26 Yao Qi <yao.qi@linaro.org>
13666 * disasm.c (do_ui_file_delete): Delete.
13667 (gdb_insn_length): Move code creating stream to ...
13668 * utils.c (null_stream): ... here. New function.
13669 * utils.h (null_stream): Declare.
13671 2017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
13673 * python/py-inferior.c (find_thread_object): Return directly
13674 from the loop. Remove "found" variable.
13676 2017-01-21 Joel Brobecker <brobecker@adacore.com>
13678 GDB 7.12.1 released.
13680 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
13682 * python/py-function.c (fnpy_call): Reorder declarations to have
13683 the gdbpy_enter object declared first.
13684 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
13686 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
13689 * python/python-internal.h (PyMem_RawMalloc): Define for
13691 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
13692 PyMem_RawMalloc instead of PyMem_Malloc.
13694 2017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
13695 Luis Machado <lgustavo@codesourcery.com>
13697 * NEWS (New commands): Mention flash-erase.
13698 (New MI commands): Mention target-flash-erase.
13699 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
13701 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
13702 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
13703 * target.c (flash_erase_command): New function.
13704 (initialize_targets): Add new flash-erase command.
13705 * target.h (flash_erase_command): New declaration.
13707 2017-01-20 Joel Brobecker <brobecker@adacore.com>
13709 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
13710 HAVE_SYS_PROCFS_H is defined.
13712 2017-01-18 Alan Hayward <alan.hayward@arm.com>
13714 * remote.c (struct cached_reg): Change data into a pointer.
13715 * (stop_reply_dtr): Free data pointers before deleting vector.
13716 (process_stop_reply): Likewise.
13717 (remote_parse_stop_reply): Allocate space for data
13719 2017-01-18 Alan Hayward <alan.hayward@arm.com>
13721 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
13723 (amd64_pseudo_register_read_value): Likewise.
13724 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
13725 (store_register_using_P): Likewise.
13726 * regcache.c (regcache_xfer_part): Likewise.
13728 2017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
13730 Split real and pseudo registers.
13731 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
13732 (sparc32_pseudo_regnum): New enum.
13733 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
13734 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
13735 (SPARC32_CP0_REGISTERS): New macro.
13736 (sparc32_pseudo_register_name): New function.
13737 (sparc32_register_name): Use sparc32_pseudo_register_name.
13738 (sparc32_pseudo_register_type): New function.
13739 (sparc32_register_type): Use sparc32_pseudo_register_type.
13740 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
13741 pseudo register numbers.
13742 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
13743 (SPARC64_CP0_REGISTERS): New macro.
13744 (sparc64_pseudo_register_name): New function.
13745 (sparc64_register_name): Use sparc64_pseudo_register_name.
13746 (sparc64_pseudo_register_type): New function.
13747 (sparc64_register_type): Use sparc64_pseudo_register_type.
13748 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
13749 pseudo register numbers.
13750 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
13751 sparc64_store_arguments): Handle pseudo register numbers.
13753 2017-01-13 Yao Qi <yao.qi@linaro.org>
13755 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
13756 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
13758 (getpkt_or_notif_sane_1): Likewise.
13760 2017-01-13 Yao Qi <yao.qi@linaro.org>
13762 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
13763 of CC. Pass "-x c++-header" instead of "-x c".
13765 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
13767 * remote.c (remote_can_async_p): Update comment.
13769 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
13771 * linux-nat.c (linux_nat_can_async_p): Update comment.
13773 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
13775 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
13777 2017-01-11 Simon Marchi <simon.marchi@ericsson.com>
13779 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
13781 2017-01-10 Tom Tromey <tom@tromey.com>
13783 * python/py-type.c (typy_legacy_template_argument): Update.
13784 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
13785 ~demangle_parse_info): Declare new members.
13786 (cp_demangled_name_to_comp): Return unique_ptr.
13787 (cp_demangled_name_parse_free)
13788 (make_cleanup_cp_demangled_name_parse_free)
13789 (cp_new_demangle_parse_info): Remove.
13790 * cp-support.c (do_demangled_name_parse_free_cleanup)
13791 (make_cleanup_cp_demangled_name_parse_free): Remove.
13792 (inspect_type, cp_canonicalize_string_full)
13793 (cp_canonicalize_string): Update.
13794 (mangled_name_to_comp): Change return type.
13795 (cp_class_name_from_physname, method_name_from_physname)
13796 (cp_func_name, cp_remove_params): Update.
13797 * cp-name-parser.y (demangle_parse_info): New constructor, from
13798 cp_new_demangle_parse_info.
13799 (~demangle_parse_info): New destructor, from
13800 cp_demangled_name_parse_free.
13801 (cp_merge_demangle_parse_infos): Update.
13802 (cp_demangled_name_to_comp): Change return type.
13804 2017-01-10 Tom Tromey <tom@tromey.com>
13806 * top.c (prevent_dont_repeat): Change return type.
13807 * python/python.c (execute_gdb_command): Use std::string.
13809 * guile/guile.c (gdbscm_execute_gdb_command): Update.
13810 * command.h (prevent_dont_repeat): Change return type.
13811 * breakpoint.c (bpstat_do_actions_1): Update.
13813 2017-01-10 Tom Tromey <tom@tromey.com>
13815 * value.h (scoped_value_mark::~scoped_value_mark): Call
13817 (scoped_value_mark::free_to_mark): New method.
13818 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
13821 2017-01-10 Tom Tromey <tom@tromey.com>
13823 * python/py-value.c (valpy_dereference, valpy_referenced_value)
13824 (valpy_reference_value, valpy_const_value, valpy_get_address)
13825 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
13826 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
13827 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
13828 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
13830 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
13831 * value.h (scoped_value_mark): New class.
13833 2017-01-10 Tom Tromey <tom@tromey.com>
13835 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
13836 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
13837 * psymtab.c (discard_psymtabs_upto): Remove.
13838 (make_cleanup_discard_psymtabs): Remove.
13839 (struct psymtab_state): Remove.
13841 2017-01-10 Tom Tromey <tom@tromey.com>
13843 * record-full.c (record_full_save_cleanups): Remove.
13844 (record_full_save): Use gdb::unlinker.
13845 * gcore.c (do_bfd_delete_cleanup): Remove.
13846 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
13848 * dwarf2read.c (unlink_if_set): Remove.
13849 (write_psymtabs_to_index): Use gdb::unlinker.
13850 * common/gdb_unlinker.h: New file.
13852 2017-01-10 Tom Tromey <tom@tromey.com>
13854 * windows-tdep.c (windows_xfer_shared_library): Update.
13855 * windows-nat.c (windows_make_so): Update.
13856 * utils.h (make_cleanup_bfd_unref): Remove.
13857 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
13858 * symfile.h (symfile_bfd_open)
13859 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
13860 * symfile.c (read_symbols, symbol_file_add)
13861 (separate_debug_file_exists): Update.
13862 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
13863 (generic_load, reread_symbols): Update.
13864 * symfile-mem.c (symbol_file_add_from_memory): Update.
13865 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
13866 (spu_symbol_file_add_from_memory): Update.
13867 * solist.h (struct target_so_ops) <bfd_open>: Return
13869 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
13870 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
13872 (solib_map_sections, reload_shared_libraries_1): Update.
13873 * solib-svr4.c (enable_break): Update.
13874 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
13875 * solib-frv.c (enable_break2): Update.
13876 * solib-dsbt.c (enable_break): Update.
13877 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
13879 (darwin_solib_get_all_image_info_addr_at_init): Update.
13880 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
13881 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
13882 * record-full.c (record_full_save): Update.
13883 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
13884 * procfs.c (insert_dbx_link_bpt_in_file): Update.
13885 * minidebug.c (find_separate_debug_file_in_section): Return
13887 * machoread.c (macho_add_oso_symfile): Change abfd to
13889 (macho_symfile_read_all_oso): Update.
13890 (macho_check_dsym): Return gdb_bfd_ref_ptr.
13891 (macho_symfile_read): Update.
13892 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
13893 (jit_bfd_try_read_symtab): Update.
13894 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
13895 (gdb_bfd_openw, gdb_bfd_openr_iovec)
13896 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
13898 (gdb_bfd_ref_policy): New struct.
13899 (gdb_bfd_ref_ptr): New typedef.
13900 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
13901 (gdb_bfd_openw, gdb_bfd_openr_iovec)
13902 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
13904 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
13905 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
13906 (gcore_command): Update.
13907 * exec.c (exec_file_attach): Update.
13908 * elfread.c (elf_symfile_read): Update.
13909 * dwarf2read.c (dwarf2_get_dwz_file): Update.
13910 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
13911 (open_and_init_dwo_file): Update.
13912 (open_dwp_file): Return gdb_bfd_ref_ptr.
13913 (open_and_init_dwp_file): Update.
13914 * corelow.c (core_open): Update.
13915 * compile/compile-object-load.c (compile_object_load): Update.
13916 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
13917 * coffread.c (coff_symfile_read): Update.
13918 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
13919 gdb_bfd_ref_ptr. Rename.
13920 (dump_bfd_file, restore_command): Update.
13921 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
13922 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
13923 (find_separate_debug_file_by_buildid): Update.
13925 2017-01-10 Tom Tromey <tom@tromey.com>
13927 * common/gdb_ref_ptr.h: New file.
13928 * python/py-ref.h (struct gdbpy_ref_policy): New.
13929 (gdbpy_ref): Now a typedef.
13931 2017-01-10 Tom Tromey <tom@tromey.com>
13933 * utils.h (make_cleanup_htab_delete): Don't declare.
13934 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
13936 * linespec.c (decode_compound_collector): Add constructor,
13938 (lookup_prefix_sym): Remove cleanup.
13939 (symtab_collector): Add constructor, destructor.
13940 (collect_symtabs_from_filename): Remove cleanup.
13941 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
13942 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
13944 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
13945 * dwarf2read.c (dw2_expand_symtabs_matching)
13946 (dw2_map_symbol_filenames, dwarf_decode_macros)
13947 (write_psymtabs_to_index): Use htab_up.
13948 * dwarf2loc.c (func_verify_no_selftailcall)
13949 (call_site_find_chain_1, func_verify_no_selftailcall)
13950 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
13951 std::vector, gdb::unique_xmalloc_ptr.
13952 (call_sitep): Remove typedef.
13953 (dwarf2_locexpr_baton_eval): Remove unused variable.
13955 2017-01-10 Tom Tromey <tom@tromey.com>
13957 * python/python-internal.h (make_cleanup_py_decref)
13958 (make_cleanup_py_xdecref): Don't declare.
13959 * python/py-utils.c (py_decref, make_cleanup_py_decref)
13960 (py_xdecref, make_cleanup_py_xdecref): Remove.
13962 2017-01-10 Tom Tromey <tom@tromey.com>
13964 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
13965 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
13967 2017-01-10 Tom Tromey <tom@tromey.com>
13969 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
13971 2017-01-10 Tom Tromey <tom@tromey.com>
13973 * python/py-utils.c (unicode_to_encoded_string)
13974 (python_string_to_target_string)
13975 (python_string_to_target_python_string)
13976 (python_string_to_host_string, gdbpy_obj_to_string)
13977 (get_addr_from_python): Use gdbpy_ref.
13979 2017-01-10 Tom Tromey <tom@tromey.com>
13981 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
13984 2017-01-10 Tom Tromey <tom@tromey.com>
13986 * python/python.c (eval_python_command, gdbpy_decode_line)
13987 (gdbpy_run_events, gdbpy_start_type_printers)
13988 (gdbpy_apply_type_printers): Use gdbpy_ref.
13990 2017-01-10 Tom Tromey <tom@tromey.com>
13992 * python/py-param.c (get_doc_string, compute_enum_values): Use
13995 2017-01-10 Tom Tromey <tom@tromey.com>
13997 * python/py-inferior.c (find_thread_object, build_inferior_list):
14000 2017-01-10 Tom Tromey <tom@tromey.com>
14002 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
14004 2017-01-10 Tom Tromey <tom@tromey.com>
14006 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
14009 2017-01-10 Tom Tromey <tom@tromey.com>
14011 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
14013 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
14016 2017-01-10 Tom Tromey <tom@tromey.com>
14018 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
14021 2017-01-10 Tom Tromey <tom@tromey.com>
14023 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
14024 decref results of PyArg_ParseTupleAndKeywords.
14026 2017-01-10 Tom Tromey <tom@tromey.com>
14028 * python/python.c (python_run_simple_file): Use
14029 unique_xmalloc_ptr, gdbpy_ref.
14031 2017-01-10 Tom Tromey <tom@tromey.com>
14033 * python/py-prettyprint.c (print_stack_unless_memory_error)
14034 (print_string_repr, print_children): Use gdbpy_ref.
14035 (dummy_python_frame): New class.
14036 (dummy_python_frame::dummy_python_frame): Rename from
14037 push_dummy_python_frame.
14038 (py_restore_tstate): Remove.
14040 2017-01-10 Tom Tromey <tom@tromey.com>
14042 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
14044 2017-01-10 Tom Tromey <tom@tromey.com>
14046 * python/python.c (ensure_python_env, restore_python_env):
14048 * python/python-internal.h (ensure_python_env): Don't declare.
14049 * varobj.h (varobj_ensure_python_env): Don't declare.
14050 * varobj.c (varobj_ensure_python_env): Remove.
14052 2017-01-10 Tom Tromey <tom@tromey.com>
14054 * varobj.c (varobj_value_get_print_value): Use
14055 gdbpy_enter_varobj.
14057 2017-01-10 Tom Tromey <tom@tromey.com>
14059 * python/py-prettyprint.c (print_string_repr, print_children):
14061 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
14063 * varobj.c (varobj_value_get_print_value): Update.
14064 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
14066 2017-01-10 Tom Tromey <tom@tromey.com>
14068 * varobj.c (varobj_get_display_hint)
14069 (dynamic_varobj_has_child_method, install_new_value_visualizer)
14070 (varobj_set_visualizer, free_variable): Use
14071 gdbpy_enter_varobj.
14073 2017-01-10 Tom Tromey <tom@tromey.com>
14075 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
14076 (do_finish_initialization): New function. Use gdbpy_ref.
14077 (gdbpy_finish_initialization): Use gdbpy_enter. Call
14078 do_finish_initialization.
14080 2017-01-10 Tom Tromey <tom@tromey.com>
14082 * python/py-param.c (get_set_value, get_show_value): Use
14083 gdbpy_enter, gdbpy_ref.
14085 2017-01-10 Tom Tromey <tom@tromey.com>
14087 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
14089 2017-01-10 Tom Tromey <tom@tromey.com>
14091 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
14093 2017-01-10 Tom Tromey <tom@tromey.com>
14095 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
14096 Use gdbpy_enter_varobj.
14098 2017-01-10 Tom Tromey <tom@tromey.com>
14100 * varobj.c (gdbpy_enter_varobj): New constructor.
14101 * python/python-internal.h (gdbpy_enter_varobj): New class.
14102 * python/py-varobj.c (py_varobj_get_iterator): Use
14103 gdbpy_enter_varobj.
14105 2017-01-10 Tom Tromey <tom@tromey.com>
14107 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
14108 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
14109 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
14110 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
14111 unique_xmalloc_ptr.
14112 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
14114 2017-01-10 Tom Tromey <tom@tromey.com>
14116 * python/py-xmethods.c (invoke_match_method): Use
14119 2017-01-10 Tom Tromey <tom@tromey.com>
14121 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
14122 gdbpy_enter, gdbpy_ref.
14124 2017-01-10 Tom Tromey <tom@tromey.com>
14126 * python/python.c (python_interactive_command): Use gdbpy_enter.
14128 2017-01-10 Tom Tromey <tom@tromey.com>
14130 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
14133 2017-01-10 Tom Tromey <tom@tromey.com>
14135 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
14136 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
14138 2017-01-10 Tom Tromey <tom@tromey.com>
14140 * utils.h (htab_deleter): New struct.
14141 (htab_up): New typedef.
14142 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
14143 gdbpy_enter, gdbpy_ref, htab_up.
14145 2017-01-10 Tom Tromey <tom@tromey.com>
14147 * python/py-unwind.c (pending_frame_invalidate): Remove.
14148 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
14150 2017-01-10 Tom Tromey <tom@tromey.com>
14152 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
14153 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
14155 2017-01-10 Tom Tromey <tom@tromey.com>
14157 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
14159 2017-01-10 Tom Tromey <tom@tromey.com>
14161 * python/python.c (gdbpy_eval_from_control_command)
14162 (gdbpy_source_script, gdbpy_run_events)
14163 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
14164 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
14167 2017-01-10 Tom Tromey <tom@tromey.com>
14169 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
14171 2017-01-10 Tom Tromey <tom@tromey.com>
14173 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
14175 2017-01-10 Tom Tromey <tom@tromey.com>
14177 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
14178 (python_on_inferior_call_pre, python_on_inferior_call_post)
14179 (python_on_memory_change, python_on_register_change)
14180 (python_inferior_exit, python_new_objfile, add_thread_object)
14181 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
14183 2017-01-10 Tom Tromey <tom@tromey.com>
14185 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
14186 (bpfinishpy_handle_exit): Use gdbpy_enter.
14188 2017-01-10 Tom Tromey <tom@tromey.com>
14190 * python/py-cmd.c (cmdpy_destroyer)
14191 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
14194 2017-01-10 Tom Tromey <tom@tromey.com>
14196 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
14198 (gdbpy_breakpoint_has_cond): Likewise.
14200 2017-01-10 Tom Tromey <tom@tromey.com>
14202 * python/python.c (gdbpy_enter): New constructor.
14203 (~gdbpy_enter): New destructor.
14204 (restore_python_env, ensure_python_env): Rewrite.
14205 * python/python-internal.h (gdbpy_enter): New class.
14207 2017-01-10 Tom Tromey <tom@tromey.com>
14209 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
14211 2017-01-10 Tom Tromey <tom@tromey.com>
14213 * python/py-value.c (value_has_field, get_field_flag)
14214 (get_field_type, valpy_getitem, convert_value_from_python): Use
14217 2017-01-10 Tom Tromey <tom@tromey.com>
14219 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
14222 2017-01-10 Tom Tromey <tom@tromey.com>
14224 * python/py-prettyprint.c (search_pp_list)
14225 (find_pretty_printer_from_objfiles)
14226 (find_pretty_printer_from_progspace)
14227 (find_pretty_printer_from_gdb, find_pretty_printer)
14228 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
14231 2017-01-10 Tom Tromey <tom@tromey.com>
14233 * python/py-param.c (call_doc_function): Use gdbpy_ref.
14235 2017-01-10 Tom Tromey <tom@tromey.com>
14237 * python/py-linetable.c (build_line_table_tuple_from_pcs)
14238 (ltpy_get_all_source_lines): Use gdbpy_ref.
14240 2017-01-10 Tom Tromey <tom@tromey.com>
14242 * python/py-framefilter.c (extract_sym, extract_value)
14243 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
14246 2017-01-10 Tom Tromey <tom@tromey.com>
14248 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
14250 2017-01-10 Tom Tromey <tom@tromey.com>
14252 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
14254 2017-01-10 Tom Tromey <tom@tromey.com>
14256 * python/py-function.c (convert_values_to_python, fnpy_init): Use
14259 2017-01-10 Tom Tromey <tom@tromey.com>
14261 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
14263 2017-01-10 Tom Tromey <tom@tromey.com>
14265 * python/py-type.c (convert_field, make_fielditem, typy_fields)
14266 (typy_range): Use gdbpy_ref.
14268 2017-01-10 Tom Tromey <tom@tromey.com>
14270 * python/py-threadevent.c (create_thread_event_object): Use
14272 * python/py-stopevent.c (create_stop_event_object): Simplify.
14273 (emit_stop_event): Use gdbpy_ref.
14274 * python/py-signalevent.c (create_signal_event_object): Use
14276 * python/py-newobjfileevent.c (create_new_objfile_event_object)
14277 (emit_new_objfile_event, create_clear_objfiles_event_object)
14278 (emit_clear_objfiles_event): Use gdbpy_ref.
14279 * python/py-infevents.c (create_inferior_call_event_object)
14280 (create_register_changed_event_object)
14281 (create_memory_changed_event_object, emit_inferior_call_event)
14282 (emit_memory_changed_event, emit_register_changed_event): Use
14284 * python/py-exitedevent.c (create_exited_event_object)
14285 (emit_exited_event): Use gdbpy_ref.
14286 * python/py-event.h (evpy_emit_event): Remove
14287 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
14288 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
14289 * python/py-continueevent.c (emit_continue_event): Use
14291 * python/py-breakpoint.c (gdbpy_breakpoint_created)
14292 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
14294 * python/py-bpevent.c (create_breakpoint_event_object): Use
14297 2017-01-10 Tom Tromey <tom@tromey.com>
14299 * python/py-ref.h: New file.
14301 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
14303 * cli-out.c (cli_ui_out::do_redirect): Change return type to
14305 * cli-out.h (cli_ui_out::do_redirect): Likewise.
14306 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
14307 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
14308 * ui-out.c (ui_out::redirect): Likewise.
14309 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
14310 * cli/cli-logging.c (set_logging_redirect): Update call site of
14312 (handle_redirections): Likewise.
14313 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
14314 * top.c (execute_command_to_string): Likewise.
14315 * utils.c (do_ui_out_redirect_pop): Likewise.
14317 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
14319 * stack.c (_initialize_stack): Update "frame" command help message.
14321 2017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
14323 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
14325 2017-01-06 Yao Qi <yao.qi@linaro.org>
14327 * x86-linux-nat.h: Include gdb_proc_service.h.
14329 2017-01-06 Yao Qi <yao.qi@linaro.org>
14331 * ser-base.h: Include serial.h.
14333 2017-01-06 Yao Qi <yao.qi@linaro.org>
14335 * ppc-linux-tdep.h: Include ppc-tdep.h.
14337 2017-01-06 Yao Qi <yao.qi@linaro.org>
14339 * nat/amd64-linux-siginfo.h: Include signal.h.
14341 2017-01-06 Yao Qi <yao.qi@linaro.org>
14343 * nat/aarch64-linux-hw-point.h: Include break-common.h.
14345 2017-01-06 Yao Qi <yao.qi@linaro.org>
14347 * mi/mi-parse.h: Include mi-cmds.h.
14349 2017-01-06 Yao Qi <yao.qi@linaro.org>
14351 * inf-loop.c: Don't include "target.h".
14352 * inf-loop.h: Include it here.
14354 2017-01-06 Yao Qi <yao.qi@linaro.org>
14356 * dfp.h: Include "dboulest.h" and "expression.h".
14358 2017-01-06 Yao Qi <yao.qi@linaro.org>
14360 * ax-gdb.h: Include "ax.h".
14362 2017-01-06 Yao Qi <yao.qi@linaro.org>
14364 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
14365 with nat/gdb_ptrace.h.
14367 2017-01-05 Yao Qi <yao.qi@linaro.org>
14369 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
14371 (mips64_fbsd_sigframe_init): Likewise.
14373 2017-01-04 John Baldwin <jhb@FreeBSD.org>
14375 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
14376 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
14378 2017-01-04 John Baldwin <jhb@FreeBSD.org>
14380 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
14381 * NEWS: Mention new FreeBSD/mips native configuration.
14382 * config/mips/fbsd.mh: New file.
14383 * configure.host: Add mips*-*-freebsd*.
14384 * mips-fbsd-nat.c: New file.
14386 2017-01-04 John Baldwin <jhb@FreeBSD.org>
14388 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
14389 (ALLDEPFILES): Add mips-fbsd-tdep.c.
14390 * NEWS: Mention new FreeBSD/mips target.
14391 * configure.tgt: Add mips*-*-freebsd*.
14392 * mips-fbsd-tdep.c: New file.
14393 * mips-fbsd-tdep.h: New file.
14395 2017-01-04 Yao Qi <yao.qi@linaro.org>
14397 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
14398 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
14400 2017-01-01 Joel Brobecker <brobecker@adacore.com>
14402 Update copyright year range in all GDB files.
14404 2017-01-01 Joel Brobecker <brobecker@adacore.com>
14406 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
14408 For older changes see ChangeLog-2016.
14414 version-control: never