1 2017-10-18 Yao Qi <yao.qi@linaro.org>
3 * features/tic6x-c62x-linux.c: Remove.
5 2017-10-17 Tom Tromey <tom@tromey.com>
7 * disasm.c (do_mixed_source_and_assembly_deprecated): Use
8 gdb::optional, ui_out_emit_list, ui_out_emit_tuple.
9 (do_mixed_source_and_assembly): Likewise.
11 2017-10-17 Tom Tromey <tom@tromey.com>
13 * regcache.c (regcache::xfer_part): Remove assertion.
15 2017-10-17 Pedro Alves <palves@redhat.com>
17 * xml-support.c (xml_fetch_content_from_file): Call
18 unique_ptr::release() instead unique_ptr::get() when passing
21 2017-10-17 Yao Qi <yao.qi@linaro.org>
23 * regcache.c (regcache::xfer_part): Remove parameters read and
24 write, add parameter is_raw. All callers are updated.
26 2017-10-16 Keith Seitz <keiths@redhat.com>
28 * c-typeprint.c (enum access_specifier): Moved here from
30 (output_access_specifier): New function.
31 (c_type_print_base): Consider typedefs when assessing
32 whether access labels are needed.
33 Use output_access_specifier as needed.
34 Output access specifier for typedefs, if needed.
35 * dwarf2read.c (dwarf2_add_typedef): Record DW_AT_accessibility.
36 * gdbtypes.h (struct typedef_field) <is_protected, is_private>: New
38 (TYPE_TYPEDEF_FIELD_PROTECTED, TYPE_TYPEDEF_FIELD_PRIVATE): New
41 2017-10-16 Tom Tromey <tom@tromey.com>
43 * linux-tdep.c (linux_info_proc, linux_find_memory_regions_full)
44 (linux_fill_prpsinfo, linux_vsyscall_range_raw): Update.
45 * target.c (target_fileio_read_stralloc): Update.
46 * sparc64-tdep.c (adi_is_addr_mapped): Update.
47 * target.h (target_fileio_read_stralloc): Return
50 2017-10-16 Tom Tromey <tom@tromey.com>
52 * xml-syscall.c (xml_init_syscalls_info): Update.
53 * xml-support.c (xinclude_start_include): Update.
54 (xml_fetch_content_from_file): Return unique_xmalloc_ptr.
55 * xml-support.h (xml_fetch_another): Return unique_xmalloc_ptr.
56 (xml_fetch_content_from_file): Likewise.
57 * osdata.c (get_osdata): Update.
58 * target.h (target_read_stralloc, target_get_osdata): Return
60 * solib-aix.c (solib_aix_get_library_list): Update.
61 * solib-target.c (solib_target_current_sos): Update.
62 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Update.
63 * xml-tdesc.c (fetch_available_features_from_target): Update.
64 (target_fetch_description_xml): Update.
65 (file_read_description_xml): Update.
66 * remote.c (remote_get_threads_with_qxfer, remote_memory_map)
67 (remote_traceframe_info, btrace_read_config, remote_read_btrace)
68 (remote_pid_to_exec_file): Update.
69 * target.c (target_read_stralloc): Return unique_xmalloc_ptr.
70 (target_get_osdata): Likewise.
72 2017-10-16 Tom Tromey <tom@tromey.com>
74 * remote.c (remote_register_number_and_offset): Use std::vector.
75 (remote_set_syscall_catchpoint): Use gdb::unique_xmalloc_ptr.
76 (putpkt_binary): Use gdb::def_vector.
77 (compare_sections_command): Use gdb::byte_vector.
79 2017-10-16 Tom Tromey <tom@tromey.com>
81 * ppc-linux-nat.c (hwdebug_insert_point): Use
82 gdb::unique_xmalloc_ptr, XDUP.
84 2017-10-16 Tom Tromey <tom@tromey.com>
86 * probe.c (parse_probes): Use std::string.
87 (info_probes_for_ops, enable_probes_command)
88 (disable_probes_command): Remove cleanups.
90 2017-10-16 Tom Tromey <tom@tromey.com>
92 * buildsym.c (block_compar): Remove.
93 (end_symtab_get_static_block): Use std::vector.
95 2017-10-16 Simon Marchi <simon.marchi@ericsson.com>
97 * memrange.h (struct mem_range): Define operator< and operator==.
98 (mem_range_s): Remove.
99 (DEF_VEC_O (mem_range_s)): Remove.
100 (normalize_mem_ranges): Change parameter type to std::vector.
101 * memrange.c (compare_mem_ranges): Remove.
102 (normalize_mem_ranges): Change parameter type to std::vector,
103 adjust to vector change.
104 * exec.c (section_table_available_memory): Return vector, remove
106 (section_table_read_available_memory): Adjust to std::vector
108 * remote.c (remote_read_bytes): Adjust to std::vector
110 * tracepoint.h (traceframe_available_memory): Change parameter
112 * tracepoint.c (traceframe_available_memory): Change parameter
113 type to std::vector, adjust.
114 * gdb/mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to
116 * gdb/Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
117 unittests/memrange-selftests.c.
118 (SUBDIR_UNITTESTS_OBS): Add memrange-selftests.o.
119 * gdb/unittests/memrange-selftests.c: New file.
121 2017-10-16 Pedro Alves <palves@redhat.com>
123 * elfread.c (probe_key_free): Rename range-for variable.
124 * probe.c (parse_probes_in_pspace, find_probes_in_objfile)
125 (find_probe_by_pc, collect_probes): Rename range-for variable.
127 2017-10-16 Yao Qi <yao.qi@linaro.org>
129 * features/Makefile (XMLTOC): Remove tic6x-*.xml.
130 * features/tic6x-c62x.c: Remove.
131 * features/tic6x-c64x-linux.c: Remove.
132 * features/tic6x-c64x.c: Remove.
133 * features/tic6x-c64xp-linux.c: Remove.
134 * features/tic6x-c64xp.c: Remove.
135 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Don't call
136 initialize_tdesc_tic6x_*_linux functions.
137 * tic6x-tdep.c (_initialize_tic6x_tdep): Don't call
138 initialize_tdesc_tic6x_* functions.
140 2017-10-16 Yao Qi <yao.qi@linaro.org>
142 * features/Makefile (WHICH): Remove tic6x-c64xp, tic6x-c64x
144 * regformats/tic6x-c62x.dat: Remove.
145 * regformats/tic6x-c64x.dat: Remove.
146 * regformats/tic6x-c64xp.dat: Remove.
148 2017-10-15 Simon Marchi <simon.marchi@ericsson.com>
150 * tracepoint.c (parse_traceframe_info): Return a unique_ptr
151 (the !HAVE_LIBEXPAT version).
153 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
155 * nat/linux-osdata.c (struct pid_pgid_entry) <operator<>: Make
158 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
160 * target.h: Include tracepoint.h.
161 (enum trace_find_type): Move to tracepoint.h.
162 (struct target_ops) <to_traceframe_info>: Return a unique ptr.
163 * tracepoint.h: Don't include target.h
164 (enum trace_find_type): Move from target.h.
165 (parse_traceframe_info): Return a unique ptr.
166 * tracepoint.c (current_traceframe_info): Change type to unique
168 (free_traceframe_info): Remove.
169 (clear_traceframe_info): Don't manually free
170 current_traceframe_info.
171 (free_result): Remove.
172 (parse_traceframe_info): Return a unique ptr.
173 (get_traceframe_info): Adjust to unique ptr.
174 * ctf.c (ctf_traceframe_info): Return a unique ptr.
175 * remote.c (remote_traceframe_info): Return a unique ptr.
176 * tracefile-tfile.c (tfile_traceframe_info): Return a unique
178 * target-debug.h (target_debug_print_traceframe_info_up): New
180 * target-delegates.c: Regenerate.
182 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
184 * memrange.h (struct mem_range): Add constructors.
185 * tracepoint.h (struct traceframe_info) <memory>: Change type to
186 std::vector<mem_range>.
187 * tracepoint.c (free_traceframe_info): Don't manually free
189 (traceframe_info_start_memory): Adjust to vector change.
190 (traceframe_available_memory): Likewise.
191 * tracefile-tfile.c (build_traceframe_info): Likewise.
192 * ctf.c (ctf_traceframe_info): Likewise.
194 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
196 * tracepoint.h (struct traceframe_info) <tvars>: Change type to
198 * tracepoint.c (free_traceframe_info): Deallocate with delete.
199 (traceframe_info_start_tvar): Adjust to vector change.
200 (parse_traceframe_info): Allocate with new.
201 * ctf.c (ctf_traceframe_info): Allocate with new, adjust to
203 * tracefile-tfile.c (build_traceframe_info): Adjust to vector
205 tfile_traceframe_info): Allocate with new.
206 * mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to vector
209 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
211 * tracepoint.c (traceframe_info): Rename to...
212 (current_traceframe_info): ...this.
213 (clear_traceframe_info): Adjust.
214 (get_traceframe_info): Adjust.
216 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
218 * nat/linux-osdata.c: Include algorithm.
219 (compare_processes): Remove.
220 (struct pid_pgid_entry): New struct.
221 (linux_xfer_osdata_processgroups): Use std::vector instead of
224 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
226 * objfiles.h: Don't include symfile.h.
227 (struct partial_symbol): Remove forward-declaration.
228 (struct objfile) <global_psymbols, static_psymbols>: Change type
229 to std::vector<partial_symbol *>.
230 * objfiles.c (objfile::objfile): Don't memset those fields.
231 (objfile::~objfile): Don't free those fields.
232 * psympriv.h (struct psymbol_allocation_list): Remove
234 (add_psymbol_to_list): Change psymbol_allocation_list parameter
236 (start_psymtab_common): Change parameters to std::vector.
237 * psymtab.c: Include algorithm.
238 (require_partial_symbols): Call shrink_to_fit.
239 (find_pc_sect_psymbol): Adjust to vector change.
240 (match_partial_symbol): Likewise.
241 (lookup_partial_symbol): Likewise.
242 (psym_relocate): Likewise.
243 (dump_psymtab): Likewise.
244 (recursively_search_psymtabs): Likewise.
245 (compare_psymbols): Remove.
246 (sort_pst_symbols): Adjust to vector change.
247 (start_psymtab_common): Likewise.
248 (end_psymtab_common): Likewise.
249 (psymbol_bcache_full): De-constify return value.
250 (add_psymbol_to_bcache): Likewise.
251 (extend_psymbol_list): Remove.
252 (append_psymbol_to_list): Adjust to vector change.
253 (add_psymbol_to_list): Likewise.
254 (init_psymbol_list): Likewise.
255 (maintenance_info_psymtabs): Likewise.
256 (maintenance_check_psymtabs): Likewise.
257 * symfile.h (struct psymbol_allocation_list): Remove.
258 * symfile.c (reread_symbols): Adjust to vector change.
259 * dbxread.c (start_psymtab): Change type of parameters.
260 (dbx_symfile_read): Adjust to vector change.
261 (read_dbx_symtab): Likewise.
262 (start_psymtab): Change type of parameters.
263 * dwarf2read.c (dwarf2_build_psymtabs): Adjust to vector change.
264 (create_partial_symtab): Likewise.
265 (add_partial_symbol): Likewise.
266 (write_one_signatured_type): Likewise.
267 (recursively_write_psymbols): Likewise.
268 * mdebugread.c (parse_partial_symbols): Likewise.
269 * xcoffread.c (xcoff_start_psymtab): Change type of parameters.
270 (scan_xcoff_symtab): Adjust to vector change.
271 (xcoff_initial_scan): Likewise.
273 2017-10-13 Simon Marchi <simon.marchi@ericsson.com>
275 * ada-typeprint.c (print_dynamic_range_bound): Use std::string.
277 2017-10-13 Yao Qi <yao.qi@linaro.org>
279 * features/Makefile: Remove tic6x-*-expedite, add tic6x-expedite.
280 Remove s390x-*-expedite, add s390x-expedite.
282 2017-10-13 Yao Qi <yao.qi@linaro.org>
284 * features/s390-gs-linux64.c: Regenerated.
285 * features/s390x-gs-linux64.c: Regenerated.
287 2017-10-13 Tom Tromey <tom@tromey.com>
289 * compile/compile-object-run.c (do_module_cleanup): Use delete.
290 * solib.c (update_solib_list, reload_shared_libraries_1): Use
292 * symfile.c (symbol_file_add_with_addrs): Use new.
293 (symbol_file_add_separate): Update comment.
294 (syms_from_objfile_1, remove_symbol_file_command): Use delete.
295 * jit.c (jit_object_close_impl): Use new.
296 (jit_unregister_code): Use delete.
297 * objfiles.c (objfile::objfile): Rename from allocate_objfile.
298 (~objfile): Rename from free_objfile.
299 (free_objfile_separate_debug, do_free_objfile_cleanup)
300 (free_all_objfiles, objfile_purge_solibs): Use delete.
301 * objfiles.h (struct objfile): Add constructor and destructor.
302 Use DISABLE_COPY_AND_ASSIGN. Add initializers to data members.
303 (allocate_objfile, free_objfile): Don't declare.
304 (struct objstats): Add initializers.
306 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
308 * arch-utils.h (simple_displaced_step_copy_insn): Remove.
309 * arch-utils.c (simple_displaced_step_copy_insn): Remove.
310 * gdbarch.sh (displaced_step_copy_insn): Adjust comment.
311 * gdbarch.h: Regenerate.
312 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
314 * i386-tdep.c (i386_displaced_step_copy_insn): Adjust comment.
315 (i386_displaced_step_fixup): Adjust comment.
316 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Adjust comment.
318 2017-10-12 Tom Tromey <tom@tromey.com>
320 * prologue-value.h (pv_area::store_would_trash): Return bool.
321 (pv_area::find_reg): Likewise.
322 * prologue-value.c (pv_area::store_would_trash): Return bool.
323 (pv_area::find_reg): Likewise.
325 2017-10-12 Tom Tromey <tom@tromey.com>
327 * s390-linux-tdep.c (s390_store, s390_load)
328 (s390_check_for_saved, s390_analyze_prologue): Update.
329 * rx-tdep.c (check_for_saved, rx_analyze_prologue): Update.
330 * rl78-tdep.c (rl78_analyze_prologue, check_for_saved): Update.
331 * prologue-value.h (class pv_area): Move from prologue-value.c.
332 Change names of members. Add constructor, destructor, member
334 (make_pv_area, free_pv_area, make_cleanup_free_pv_area)
335 (pv_area_store, pv_area_fetch, pv_area_store_would_trash)
336 (pv_area_fetch, pv_area_scan): Don't declare.
337 * prologue-value.c (struct pv_area::area_entry): Now member of
339 (struct pv_area): Move to prologue-value.h.
340 (pv_area::pv_area): Rename from make_pv_area.
341 (pv_area::~pv_area): Rename from free_pv_area.
342 (do_free_pv_area_cleanup, make_cleanup_free_pv_area): Remove.
343 (clear_entries, find_entry, overlaps, store_would_trash, store)
344 (fetch, find_reg, scan): Now member of pv_area.
345 Remove "area" argument. Update.
346 * msp430-tdep.c (check_for_saved, msp430_analyze_prologue):
348 * mn10300-tdep.c (push_reg, check_for_saved)
349 (mn10300_analyze_prologue): Update.
350 * mep-tdep.c (is_arg_spill, check_for_saved)
351 (mep_analyze_prologue): Update.
352 * m32c-tdep.c (m32c_pv_push, m32c_srcdest_fetch)
353 (m32c_srcdest_store, m32c_pv_enter, m32c_is_arg_spill)
354 (m32c_is_struct_return, m32c_analyze_prologue): Update.
355 * arm-tdep.c (thumb_analyze_prologue, arm_analyze_prologue):
357 * arc-tdep.c (arc_is_in_prologue, arc_analyze_prologue): Update.
358 * aarch64-tdep.c (aarch64_analyze_prologue): Update.
360 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
362 * linux-nat.h (linux_nat_set_delete_thread): New declaration.
363 * linux-nat.c (linux_nat_delete_thread): New variable.
364 (lwp_free): Invoke linux_nat_delete_thread if set.
365 (linux_nat_set_delete_thread): New function.
366 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Assign
367 thread delete callback.
368 * arm-linux-nat.c (arm_linux_delete_thread): New function.
369 (_initialize_arm_linux_nat): Assign thread delete callback.
370 * s390-linux-nat.c (s390_delete_thread): New function.
371 (_initialize_s390_nat): Assign thread delete callback.
372 * x86-linux-nat.c (x86_linux_add_target): Likewise.
373 * nat/aarch64-linux.c (aarch64_linux_delete_thread): New
375 * nat/aarch64-linux.h (aarch64_linux_delete_thread): New
377 * nat/x86-linux.c (x86_linux_delete_thread): New function.
378 * nat/x86-linux.h (x86_linux_delete_thread): New declaration.
380 2017-10-09 Tom Tromey <tom@tromey.com>
382 * tui/tui-win.c (tui_set_win_height, parse_scrolling_args): Use
384 * tui/tui-layout.c (enum tui_status): Use std::string.
386 2017-10-11 Tom Tromey <tom@tromey.com>
388 * gdbthread.h (thread_command): Constify.
389 * inferior.h (detach_command): Constify.
390 * top.h (set_history, show_history): Constify.
391 * arm-tdep.c (set_arm_command, show_arm_command): Constify.
392 * serial.c (serial_set_cmd, serial_show_cmd): Constify.
393 * bsd-kvm.c (bsd_kvm_cmd): Constify.
394 * printcmd.c (set_command): Constify.
395 (non_const_set_command): New function.
396 * dcache.c (set_dcache_command, show_dcache_command): Constify.
397 * breakpoint.c (enable_command, disable_command, delete_command)
398 (catch_command, tcatch_command, set_breakpoint_cmd)
399 (show_breakpoint_cmd): Constify.
400 * macrocmd.c (macro_command): Constify.
401 * infcmd.c (unset_command, kill_command, detach_command)
402 (info_proc_cmd): Constify.
403 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Constify.
404 * auto-load.c (show_auto_load_cmd, set_auto_load_cmd)
405 (info_auto_load_cmd): Constify.
406 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
407 (unset_tdesc_cmd): Constify.
408 * ada-lang.c (set_ada_command, show_ada_command)
409 (maint_set_ada_cmd, maint_show_ada_cmd): Constify.
410 * guile/guile.c (set_guile_command, show_guile_command)
411 (info_guile_command): Constify.
412 * tui/tui-win.c (tui_command, set_tui_cmd, show_tui_cmd):
414 * skip.c (skip_command): Constify.
415 * compile/compile.c (_initialize_compile): Constify.
416 * dwarf2read.c (set_dwarf_cmd, show_dwarf_cmd): Constify.
417 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
418 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
419 (maint_btrace_pt_show_cmd): Constify.
420 * remote.c (set_remote_cmd, show_remote_cmd, remote_command):
422 * python/python.c (user_show_python, user_set_python): Constify.
423 * mips-tdep.c (set_mips_command, show_mips_command)
424 (set_mipsfpu_command): Constify.
425 * record-btrace.c (cmd_record_btrace_start)
426 (cmd_set_record_btrace, cmd_show_record_btrace)
427 (cmd_set_record_btrace_bts, cmd_show_record_btrace_bts)
428 (cmd_set_record_btrace_pt, cmd_show_record_btrace_pt): Constify.
429 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command):
431 * symfile.c (overlay_command): Constify.
432 * spu-tdep.c (set_spu_command, show_spu_command): Constify.
433 * cli/cli-logging.c (set_logging_command, show_logging_command):
435 * cli/cli-dump.c (dump_command, append_command)
436 (srec_dump_command, ihex_dump_command, verilog_dump_command)
437 (tekhex_dump_command, binary_dump_command)
438 (binary_append_command): Constify.
439 * cli/cli-decode.c (struct cmd_list_element): Change type of
441 * cli/cli-cmds.c (info_command, show_command, set_debug)
442 (show_debug): Constify.
443 (show_command): Add non-const overload.
444 * top.c (set_history, show_history): Constify.
445 * sh-tdep.c (set_sh_command, show_sh_command): Constify.
446 * command.h (add_prefix_cmd): Accept a cmd_const_cfunc_ftype.
447 * target.c (target_command): Constify.
448 * sparc64-tdep.c (info_adi_command): Constify.
449 * record-full.c (cmd_record_full_start): Constify.
450 (set_record_full_command): Constify. Fix typo.
451 (show_record_full_command): Constify.
452 * thread.c (thread_command, thread_apply_command): Constify.
453 * memattr.c (dummy_cmd): Constify.
454 * value.c (function_command): Constify.
455 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Constify.
456 * probe.c (info_probes_command): Constify.
457 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Constify.
458 * gnu-nat.c (set_task_cmd, show_task_cmd, set_thread_cmd)
459 (show_thread_cmd, set_thread_default_cmd)
460 (show_thread_default_cmd): Constify.
461 (check_empty): Constify.
462 * tracepoint.c (tfind_command): Constify.
463 * cp-support.c (maint_cplus_command): Constify.
464 * windows-tdep.c (info_w32_command): Constify.
465 * record.c (cmd_record_start, set_record_command)
466 (show_record_command, info_record_command, cmd_record_goto):
468 * ravenscar-thread.c (set_ravenscar_command)
469 (show_ravenscar_command): Constify.
470 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
472 (add_internal_problem_command): Remove casts.
473 * arc-tdep.c (maintenance_print_arc_command): Constify.
474 * valprint.c (set_print, show_print, set_print_raw)
475 (show_print_raw): Constify.
476 * maint.c (maintenance_command, maintenance_info_command)
477 (maintenance_print_command, maintenance_set_cmd)
478 (maintenance_show_cmd, set_per_command_cmd)
479 (show_per_command_cmd, maintenance_check_command): Constify.
480 * language.c (set_check, show_check): Constify.
481 * typeprint.c (show_print_type, set_print_type): Constify.
482 * go32-nat.c (go32_info_dos_command): Constify.
484 2017-10-11 Tom Tromey <tom@tromey.com>
486 * breakpoint.c (prepare_re_set_context): Remove.
487 (breakpoint_re_set_one): Update. Don't use cleanups.
488 (breakpoint_re_set): Use scoped_restore, std::string, and
489 scoped_restore_current_language.
491 2017-10-11 Tom Tromey <tom@tromey.com>
493 * breakpoint.c (commands_command_1): Use std::string.
494 (cleanup_executing_breakpoints): Remove.
495 (bpstat_do_actions_1): Use scoped_restore.
496 (bpstat_check_watchpoint): Use std::string.
497 (decode_static_tracepoint_spec): Likewise.
498 (break_range_command): Likewise.
499 (watch_command_1): Likewise.
500 (compare_breakpoints): Change argument types.
501 (clear_command): Use std::vector.
502 (cleanup_executing_breakpoints): Remove.
503 (update_global_location_list): Use unique_xmalloc_ptr.
504 (strace_command): Remove unused declaration.
506 2017-10-11 John Baldwin <jhb@FreeBSD.org>
508 * Makefile.in (ALLDEPFILES): Add arm-fbsd-nat.c.
509 * NEWS: Mention new FreeBSD/arm native configuration.
510 * configure.host: Add arm*-*-freebsd*.
511 * configure.nat: Likewise.
512 * arm-fbsd-nat.c: New file.
514 2017-10-11 John Baldwin <jhb@FreeBSD.org>
516 * Makefile.in (ALL_TARGET_OBS): Add arm-fbsd-tdep.o.
517 (ALLDEPFILES): Add arm-fbsd-tdep.c.
518 * NEWS: Mention new FreeBSD/arm target.
519 * configure.tgt: Add arm*-*-freebsd*.
520 * arm-fbsd-tdep.c: New file.
521 * arm-fbsd-tdep.h: New file.
523 2017-10-11 Maciej W. Rozycki <macro@imgtec.com>
525 * linux-tdep.c (linux_make_corefile_notes): Remove call to
526 `gdbarch_elfcore_write_linux_prpsinfo'.
527 * gdbarch.sh (elfcore_write_linux_prpsinfo): Remove architecture
529 (elf_internal_linux_prpsinfo): Remove declaration.
530 * gdbarch.h: Regenerate.
531 * gdbarch.c: Regenerate.
533 2017-10-11 Maciej W. Rozycki <macro@imgtec.com>
535 * ppc-linux-tdep.c (ppc_linux_init_abi): Remove call to
536 `set_gdbarch_elfcore_write_linux_prpsinfo'.
538 2017-10-11 Pedro Alves <palves@redhat.com>
540 * breakpoint.c (reattach_breakpoints): Delete.
541 * breakpoint.h (reattach_breakpoints): Delete.
543 2017-10-11 Simon Marchi <simon.marchi@ericsson.com>
545 * symfile.c (registered_sym_fns): Make struct, not typedef.
546 (DEF_VEC_O (registered_sym_fns)): Remove.
547 (symtab_fns): Change type to std::vector.
548 (add_symtab_fns): Adjust.
549 (find_sym_fns): Adjust.
551 2017-10-11 Anton Kolesov <Anton.Kolesov@synopsys.com>
553 * arc-tdep.c (arc_gdbarch_init): Pass proper cpu value to disassembler.
554 * arc-tdep.h (arc_arch_is_em): New function.
555 (arc_arch_is_hs): Likewise.
557 2017-10-11 Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
559 * macrotab.h (macro_lookup_inclusion): Remove unnecessary
560 parentheses in the declaration.
561 (macro_lookup_inclusion): Likewise.
562 (macro_lookup_definition): Likewise.
563 * p-lang.h (pascal_builtin_types): Likewise.
564 * tui/tui-data.c (tui_win_list): Likewise.
565 * tui/tui-data.h (tui_win_list): Likewise.
566 * utils.h (make_cleanup_free_section_addr_info): Likewise.
568 2017-10-11 Mark Rages <markrages@gmail.com>
570 * target-memory.c (block_boundaries): Fix for block address not
571 aligned on block size.
573 2017-10-10 Pedro Alves <palves@redhat.com>
574 Tom Tromey <tom@tromey.com>
576 * breakpoint.c (struct captured_breakpoint_query_args)
577 (do_captured_breakpoint_query, gdb_breakpoint_query): Delete.
578 (print_breakpoint): New.
579 * breakpoint.h (print_breakpoint): Declare.
580 * common/common-exceptions.h (enum return_reason): Remove
581 references to catch_exceptions.
582 * exceptions.c (catch_exceptions, catch_exceptions_with_msg):
584 * exceptions.h (catch_exceptions_ftype, catch_exceptions)
585 (catch_exception_ftype, catch_exceptions_with_msg): Delete.
587 * gdbthread.h (thread_select): Declare.
588 * mi/mi-cmd-break.c: Don't include gdb.h.
589 (breakpoint_notify): Use print_breakpoint.
590 * mi/mi-cmd-catch.c: Don't include gdb.h.
591 * mi/mi-interp.c: Don't include gdb.h.
592 (mi_print_breakpoint_for_event): New.
593 (mi_breakpoint_created, mi_breakpoint_modified): Use
594 mi_print_breakpoint_for_event.
595 * mi/mi-main.c: Don't include gdb.h.
596 (mi_cmd_thread_select): Parse the global thread ID here. Use
597 thread_select instead of gdb_thread_select.
598 (mi_cmd_thread_list_ids): Output "thread-ids" tuple here instead
599 of using gdb_list_thread_ids.
600 * remote-fileio.c (do_remote_fileio_request): Change type. Reply
602 (remote_fileio_request): Use TRY/CATCH instead of
604 * symfile-mem.c (struct symbol_file_add_from_memory_args)
605 (symbol_file_add_from_memory_wrapper): Delete.
606 (add_vsyscall_page): Use TRY/CATCH instead of catch_exceptions.
607 * thread.c: Don't include gdb.h.
608 (do_captured_list_thread_ids, gdb_list_thread_ids): Delete.
609 (thread_alive): Use thread_select.
610 (do_captured_thread_select): Delete, parts salvaged as ...
611 (thread_select): ... this new function.
612 (gdb_thread_select): Delete.
614 2017-10-10 Pedro Alves <palves@redhat.com>
615 Tom Tromey <tom@tromey.com>
617 * breakpoint.c (breakpoint_cond_eval): Change return type to bool
619 (WP_DELETED, WP_VALUE_CHANGED, WP_VALUE_NOT_CHANGED, WP_IGNORE):
620 No longer macros. Instead ...
621 (enum wp_check_result): They're now values of this new
623 (watchpoint_check): Change return type to wp_check_result and
624 parameter type to bpstat.
625 (bpstat_check_watchpoint): Use TRY/CATCH instead of catch_errors.
626 (bpstat_check_breakpoint_conditions): Use TRY/CATCH instead of
627 catch_errors. Reverse logic of watchpoint_check call.
628 (breakpoint_re_set_one): Now returns void and takes a breakpoint
629 pointer as parameter.
630 (breakpoint_re_set): Use TRY/CATCH instead of catch_errors.
631 * common/common-exceptions.c (throw_exception_sjlj): Update
632 comments to avoid mentioning catch_errors.
633 * exceptions.c (catch_errors): Delete.
634 * exceptions.h: Update comments to avoid mentioning catch_errors.
635 (catch_errors_ftype, catch_errors): Delete.
636 * infrun.c (normal_stop): Use TRY/CATCH instead of catch_errors.
637 (hook_stop_stub): Delete.
638 (restore_selected_frame): Change return type to void, and
639 parameter type to const frame_id &.
640 (restore_infcall_control_state): Use TRY/CATCH instead of
642 * main.c (captured_command_loop): Return void and remove
643 parameter. Remove references to catch_errors.
644 (captured_main): Use TRY/CATCH instead of catch_errors.
645 * objc-lang.c (objc_submethod_helper_data)
646 (find_objc_msgcall_submethod_helper): Delete.
647 (find_objc_msgcall_submethod): Use TRY/CATCH instead of
649 * record-full.c (record_full_message): Return void.
650 (record_full_message_args, record_full_message_wrapper): Delete.
651 (record_full_message_wrapper_safe): Return bool and use TRY/CATCH
652 instead of catch_errors.
653 * solib-aix.c (solib_aix_open_symbol_file_object): Change
654 parameter type to int.
655 * solib-darwin.c (open_symbol_file_object): Ditto.
656 * solib-dsbt.c (open_symbol_file_object): Ditto.
657 * solib-frv.c (open_symbol_file_object): Ditto.
658 * solib-svr4.c (open_symbol_file_object): Ditto.
659 * solib-target.c (solib_target_open_symbol_file_object): Ditto.
660 * solib.c (update_solib_list): Use TRY/CATCH instead of
662 * solist.h (struct target_so_ops) <open_symbol_file_object>:
664 * symmisc.c (struct print_symbol_args): Remove.
665 (dump_symtab_1): Use TRY/CATCH instead of catch_errors.
666 (print_symbol): Change type.
667 * windows-nat.c (handle_load_dll, handle_unload_dll): Return void
668 and remove parameters.
670 (get_windows_debug_event): Adjust.
672 2017-10-09 Tom Tromey <tom@tromey.com>
674 * mi/mi-main.c (free_splay_tree): Remove.
675 (list_available_thread_groups): Use splay_tree_up.
676 * common/gdb_splay_tree.h: New file.
678 2017-10-09 Tom Tromey <tom@tromey.com>
680 * mi/mi-main.c (do_nothing): Remove.
681 (list_available_thread_groups): Update.
683 2017-10-09 Pedro Alves <palves@redhat.com>
685 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>: Skip
686 reading registers when switching context.
688 2017-10-09 John Baldwin <jhb@FreeBSD.org>
690 * fbsd-nat.c (fbsd_siginfo_size): Use gdbarch_long_bit.
691 (fbsd_convert_siginfo): Likewise.
692 * fbsd-tdep.c (fbsd_core_xfer_siginfo): Likewise.
694 2017-10-09 Simon Marchi <simon.marchi@polymtl.ca>
696 * configure.ac (try_guile_versions): Remove guile-2.2.
697 * configure: Regenerate.
699 2017-10-09 Tom Tromey <tom@tromey.com>
701 * Makefile.in (COMPILE.post, POSTCOMPILE): Restore $(basename).
702 (COMPILE.pre): Use $(CXX).
704 2017-10-09 Pedro Alves <palves@redhat.com>
706 * cp-support.c (cp_remove_params): Return a gdb::unique_xmalloc_ptr.
708 (overload_list_add_symbol): Adjust to use gdb::unique_xmalloc_ptr.
709 * cp-support.h (cp_remove_params): Now returns a
710 gdb::unique_xmalloc_ptr.
711 * dwarf2read.c (find_slot_in_mapped_hash): Now returns bool.
712 Adjust to cp_remove_params returning a gdb::unique_xmalloc_ptr.
713 * psymtab.c (psymtab_search_name): Adjust to cp_remove_params
714 returning a gdb::unique_xmalloc_ptr.
715 (lookup_partial_symbol): Adjust to use gdb::unique_xmalloc_ptr.
716 * stack.c (find_frame_funname): Adjust to cp_remove_params
717 returning a gdb::unique_xmalloc_ptr.
719 2017-10-08 Tom Tromey <tom@tromey.com>
721 * dwarf2read.c (dwarf2_get_dwz_file): Use
722 gdb::unique_xmalloc_ptr.
723 (find_slot_in_mapped_hash): Likewise.
724 (dwarf2_physname): Likewise.
725 (create_dwo_unit_in_dwp_v1): Use std::string.
726 (create_dwo_unit_in_dwp_v2): Likewise.
727 (lookup_dwo_cutu): Likewise.
728 (inherit_abstract_dies): Use std::vector.
729 (read_array_type): Likewise.
730 (dwarf_decode_macros): Remove unused declaration.
731 (unsigned_int_compar): Remove.
732 (dwarf2_build_psymtabs_hard): Use scoped_restore.
733 (psymtabs_addrmap_cleanup): Remove.
735 2017-10-08 Tom Tromey <tom@tromey.com>
737 * frame-unwind.c (frame_unwind_try_unwinder): Update.
738 * frame.h (frame_cleanup_after_sniffer): Declare.
739 (frame_prepare_for_sniffer): Return void.
740 * frame.c (frame_cleanup_after_sniffer): No longer static. Change
742 (frame_prepare_for_sniffer): Return void.
744 2017-10-08 Tom Tromey <tom@tromey.com>
746 * utils.h (make_cleanup_value_free): Remove.
747 * utils.c (do_value_free, struct cleanup): Remove.
748 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full) <DWARF_VALUE_STACK>:
750 * value.h (struct value_deleter): New.
751 (gdb_value_up): New typedef.
753 2017-10-08 Tom Tromey <tom@tromey.com>
755 * symtab.c (free_search_symbols, do_free_search_symbols_cleanup)
756 (make_cleanup_free_search_symbols): Remove.
757 (search_symbols): Return std::vector.
758 (symbol_search::compare_search_syms): Now member of
759 symbol_search. Change arguments.
760 (sort_search_symbols_remove_dups): Change arguments. Rewrite.
761 (symtab_symbol_info, rbreak_command): Update.
762 * symtab.h (struct symbol_search) <next>: Remove.
764 (symbol_search::operator<): New function.
765 (symbol_search::operator==): New function.
766 (search_symbols): Remove std::vector.
767 (free_search_symbols, make_cleanup_free_search_symbols): Remove.
768 (symbol_search::compare_search_syms): Declare.
770 2017-10-06 Yao Qi <yao.qi@linaro.org>
772 * Makefile.in (ALL_64_TARGET_OBS): Replace aarch64-insn.o with
775 * configure.tgt: Replace aarch64-insn.o with arch/aarch64-insn.o.
777 2017-10-06 Yao Qi <yao.qi@linaro.org>
779 * Makefile.in (ALL_TARGET_OBS): Replace arm.o, arm-get-next-pcs.o,
780 and arm-linux.o with arch/arm.o, arch/arm-get-next-pcs.o and
781 arch/arm-linux.o respectively.
782 * configure.tgt: Likewise.
784 2017-10-06 Yao Qi <yao.qi@linaro.org>
786 * Makefile.in (ALL_TARGET_OBS): Rename i386.o to arch/i386.o.
787 * configure.tgt (i386_tobjs): Replace i386.o with arch/i386.o.
789 2017-10-06 Pedro Alves <palves@redhat.com>
791 * windows-nat.c: Include <algorithm>.
793 2017-10-06 Yao Qi <yao.qi@linaro.org>
795 * configure.tgt (i386_tobjs): New variable.
796 (amd64_tobjs): New variable.
797 Set $cpu_obs and $os_obs.
799 2017-10-06 Yao Qi <yao.qi@linaro.org>
801 * Makefile.in (CONFIG_SRC_SUBDIR): New.
802 (ALL_64_TARGET_OBS): Replace amd64.o with arch/amd64.o.
803 (clean): Remove object files and dependency files.
804 (distclean): Remove the directory.
805 * configure.ac: Invoke AC_CONFIG_COMMANDS.
806 * configure: Re-generated.
807 * configure.tgt: Replace amd64.o with arch/amd64.o.
809 2017-10-05 Jose E. Marchesi <jose.marchesi@oracle.com>
812 * arm-tdep.c (arm_decode_misc_memhint_neon): Fix decoding of CPS
815 2017-10-05 Pedro Alves <palves@redhat.com>
817 * linux-nat.c (linux_child_follow_fork): When following the parent
818 and detaching the child, consult the parent thread's architecture
819 instead of the child's.
821 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
823 * ax.h: Do not include "doublest.h".
824 (union agent_val): Remove.
826 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
828 * dfp.h (MAX_DECIMAL_STRING): Move to dfp.c.
829 (decimal_to_string): Return std::string object.
830 (decimal_from_string): Accept std::string object. Return bool.
831 (decimal_from_integral, decimal_from_doublest): Remove.
832 (decimal_from_longest): Add prototype.
833 (decimal_from_ulongest): Likewise.
834 (decimal_to_longest): Likewise.
835 (decimal_from_doublest): Likewise.
836 * dfp.c: Do not include "gdbtypes.h" or "value.h".
837 (MAX_DECIMAL_STRING): Move here.
838 (decimal_to_string): Return std::string object.
839 (decimal_from_string): Accept std::string object. Return bool.
840 (decimal_from_integral): Remove, replace by ...
841 (decimal_from_longest, decimal_from_ulongest): ... these new functions.
842 (decimal_to_longest): New function.
843 (decimal_from_floating): Remove, replace by ...
844 (decimal_from_doublest): ... this new function.
845 (decimal_to_doublest): Update to new decimal_to_string interface.
847 * value.c (unpack_long): Use decimal_to_longest.
848 * valops.c (value_cast): Use decimal_from_doublest instead of
849 decimal_from_floating. Use decimal_from_[u]longest isntead of
850 decimal_from_integral.
851 * valarith.c (value_args_as_decimal): Likewise.
852 * valprint.c (print_decimal_floating): Update to new
853 decimal_to_string interface.
854 * printcmd.c (printf_decfloat): Likewise.
855 * c-exp.y (parse_number): Update to new decimal_from_string interface.
857 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
859 * doublest.h: Do not include "floatformat.h". Remove stale comments.
860 * gdbtypes.c: Include "floatformat.h".
862 * m68k-tdep.c: Likewise.
864 * findvar.c: Do not include "floatformat.h".
865 * amd64-darwin-tdep.c: Likewise.
866 * arm-linux-tdep.c: Likewise.
867 * i386-darwin-tdep.c: Likewise.
868 * i387-tdep.c: Likewise.
869 * m68k-linux-tdep.c: Likewise.
870 * mep-tdep.c: Likewise.
871 * mips-tdep.c: Likewise.
872 * nios2-tdep.c: Likewise.
873 * s390-linux-tdep.c: Likewise.
874 * sparc-obsd-tdep.c: Likewise.
875 * sparc-tdep.c: Likewise.
876 * sparc64-tdep.c: Likewise.
877 * spu-tdep.c: Likewise.
878 * tic6x-tdep.c: Likewise.
879 * tilegx-tdep.c: Likewise.
880 * vax-tdep.c: Likewise.
881 * xstormy16-tdep.c: Likewise.
882 * xtensa-tdep.c: Likewise.
884 * top.c: Do not include "doublest.h".
885 * aarch64-tdep.c: Likewise.
886 * alpha-tdep.c: Likewise.
887 * arm-linux-tdep.c: Likewise.
888 * m68k-linux-tdep.c: Likewise.
889 * tilegx-tdep.c: Likewise.
890 * xstormy16-tdep.c: Likewise.
892 2017-10-05 John Baldwin <jhb@FreeBSD.org>
894 * mips-fbsd-tdep.c (MIPS_INST_ADDIU_A0_SP_N32): Define.
895 (mipsn32_fbsd_sigframe): Define.
896 (mips_fbsd_init_abi): Install mipsn32_fbsd_sigframe unwinder
899 2017-10-05 John Baldwin <jhb@FreeBSD.org>
901 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_EHDRFLAGS and
904 2017-10-05 Tristan Gingold <tgingold@free.fr>
906 * MAINTAINERS (Misc): Update my email address.
908 2017-10-04 Pedro Alves <palves@redhat.com>
910 * remote.c (get_remote_arch_state): New 'gdbarch' parameter. Use
911 it instead of target_gdbarch.
912 (get_remote_state, get_remote_packet_size): Adjust
913 get_remote_arch_state calls, passing down target_gdbarch
915 (packet_reg_from_regnum, packet_reg_from_pnum): New parameter
916 'gdbarch' and use it instead of target_gdbarch.
917 (get_memory_packet_size): Adjust get_remote_arch_state calls,
918 passing down target_gdbarch explicitly.
919 (struct stop_reply) <arch>: New field.
920 (remote_parse_stop_reply): Use the stopped thread's architecture,
921 not the current inferior's. Save the architecture in the
923 (process_stop_reply): Use the stop reply's architecture.
924 (process_g_packet, remote_fetch_registers)
925 (remote_prepare_to_store, store_registers_using_G)
926 (remote_store_registers): Adjust get_remote_arch_state calls,
927 using the regcache's architecture.
928 (remote_get_trace_status): Adjust get_remote_arch_state calls,
929 passing down target_gdbarch explicitly.
930 * spu-multiarch.c (spu_thread_architecture): Defer to the target
931 beneath instead of calling target_gdbarch.
932 * target.c (default_thread_architecture): Use the specified
933 inferior's architecture, instead of the current inferior's
934 architecture (via target_gdbarch).
936 2017-10-04 Pedro Alves <palves@redhat.com>
938 * regcache.c (get_thread_arch_regcache): Remove null_ptid special
940 (regcache_print): Handle !target_has_registers here instead.
942 2017-10-04 Pedro Alves <palves@redhat.com>
944 * frame.c (create_test_frame): Delete.
945 * frame.h (create_test_frame): Delete.
946 * gdbarch-selftests.c: Include gdbthread.h and target.h.
947 (class regcache_test): Delete.
948 (test_target_has_registers, test_target_has_stack)
949 (test_target_has_memory, test_target_prepare_to_store)
950 (test_target_store_registers): New functions.
951 (test_target_ops): New class.
952 (register_to_value_test): Error out if there's already a
953 process_stratum (or higher) target pushed. Create a fuller mock
954 environment, with mock target_ops, inferior, address space, thread
956 * progspace.c (struct address_space): Move to ...
957 * progspace.h (struct address_space): ... here.
958 * regcache.h (regcache::~regcache, regcache::raw_write)
959 [GDB_SELF_TEST]: No longer virtual.
961 2017-10-04 Simon Marchi <simon.marchi@ericsson.com>
963 * mi/mi-main.c (list_available_thread_groups): Reverse filter logic.
965 2017-10-04 Pedro Alves <palves@redhat.com>
967 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Move code
968 out of 'between TRY and CATCH'.
970 2017-10-04 Pedro Alves <palves@redhat.com>
972 * cli/cli-cmds.c (complete_command): Add missing END_CATCH.
973 * common/common-exceptions.h (TRY): Open an outermost scope.
974 Expand intro comment.
976 (END_CATCH): Close the outermost scope.
977 * completer.c (complete_line_internal): Add missing END_CATCH.
979 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
981 * NEWS (Changes since GDB 8.0): Add entry about new
982 'set-cwd-on-gdbserver' feature.
983 (New remote packets): Add entry for QSetWorkingDir.
984 * common/common-inferior.h (set_inferior_cwd): New prototype.
985 * infcmd.c (set_inferior_cwd): Remove "static".
986 (show_cwd_command): Expand text to include remote debugging.
987 * remote.c: Add PACKET_QSetWorkingDir.
988 (remote_protocol_features) <QSetWorkingDir>: New entry for
989 PACKET_QSetWorkingDir.
990 (extended_remote_set_inferior_cwd): New function.
991 (extended_remote_create_inferior): Call
992 "extended_remote_set_inferior_cwd".
993 (_initialize_remote): Call "add_packet_config_cmd" for
996 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
998 * NEWS (New commands): Mention "set/show cwd".
999 * cli/cli-cmds.c (_initialize_cli_cmds): Mention "set cwd" on
1000 "cd" command's help text.
1001 * common/common-inferior.h (get_inferior_cwd): New prototype.
1002 * infcmd.c (inferior_cwd_scratch): New global variable.
1003 (set_inferior_cwd): New function.
1004 (get_inferior_cwd): Likewise.
1005 (set_cwd_command): Likewise.
1006 (show_cwd_command): Likewise.
1007 (_initialize_infcmd): Add "set/show cwd" commands.
1008 * inferior.h (class inferior) <cwd>: New field.
1009 * nat/fork-inferior.c: Include "gdb_tilde_expand.h".
1010 (fork_inferior): Change inferior's cwd before its execution.
1011 * windows-nat.c (windows_create_inferior): Pass inferior's cwd
1014 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
1016 * Makefile.in (SFILES): Add gdb_tilde_expand.c.
1017 (HFILES_NO_SRCDIR): Add gdb_tilde_expand.h.
1018 (COMMON_OBS): Add gdb_tilde_expand.o.
1019 * common/gdb_tilde_expand.c: New file.
1020 * common/gdb_tilde_expand.h: Likewise.
1022 2017-10-03 Maciej W. Rozycki <macro@imgtec.com>
1024 * gdbarch.sh (objfile): Remove duplicate declaration.
1025 * gdbarch.h: Regenerate.
1027 2017-10-03 Tom Tromey <tom@tromey.com>
1029 * utils.c (internal_vproblem): Use string_vprintf.
1031 2017-10-03 Tom Tromey <tom@tromey.com>
1033 * printcmd.c (info_symbol_command): Use std::string.
1035 2017-10-03 Tom Tromey <tom@tromey.com>
1037 * top.c (gdb_safe_append_history): Use std::string.
1039 2017-10-03 Tom Tromey <tom@tromey.com>
1041 * event-top.c (stdin_event_handler): Update.
1042 * main.c (captured_main_1): Update.
1043 * top.h (make_delete_ui_cleanup): Remove.
1044 (struct ui): Add constructor and destructor.
1045 (new_ui, delete_ui): Remove.
1046 * top.c (make_delete_ui_cleanup): Remove.
1047 (new_ui_command): Use std::unique_ptr.
1048 (delete_ui_cleanup): Remove.
1049 (ui::ui): Rename from new_ui. Update.
1051 (ui::~ui): Rename from delete_ui. Update.
1053 2017-10-03 Tom Tromey <tom@tromey.com>
1055 * symfile.c (load_progress): Use gdb::byte_vector.
1057 2017-10-03 Tom Tromey <tom@tromey.com>
1059 * mi/mi-main.c (mi_cmd_trace_frame_collected): Remove unused
1061 * printcmd.c (x_command): Remove unused declaration.
1062 * symfile.c (symbol_file_command): Remove unused declaration.
1064 2017-10-03 Tom Tromey <tom@tromey.com>
1066 * utils.c (internal_vproblem): Use std::string.
1067 (defaulted_query): Likewise.
1069 2017-10-03 Tom Tromey <tom@tromey.com>
1071 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Update.
1072 * top.c (execute_command_to_string): Update.
1073 * utils.c (make_cleanup_restore_page_info): Remove.
1074 (do_restore_page_info_cleanup): Remove.
1075 (set_batch_flag_and_restore_page_info):
1077 (make_cleanup_restore_page_info): Remove.
1078 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
1079 (~set_batch_flag_and_restore_page_info): New
1080 (make_cleanup_restore_uinteger): Remove.
1081 (make_cleanup_restore_integer): Remove.
1082 (struct restore_integer_closure): Remove.
1083 (restore_integer): Remove.
1084 * utils.h (struct set_batch_flag_and_restore_page_info): New
1086 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
1087 (make_cleanup_restore_page_info): Remove.
1088 (make_cleanup_restore_uinteger) Remove.
1089 (make_cleanup_restore_integer) Remove.
1091 2017-10-03 Tom Tromey <tom@tromey.com>
1093 * record-full.h (record_full_gdb_operation_disable_set): Return
1094 scoped_restore_tmpl<int>.
1095 * infrun.c (adjust_pc_after_break): Update.
1096 (handle_signal_stop): Update.
1097 * record-full.c (record_full_gdb_operation_disable_set): Return
1098 scoped_restore_tmpl<int>.
1099 (record_full_wait_1, record_full_insert_breakpoint)
1100 (record_full_remove_breakpoint, record_full_save)
1101 (record_full_goto_insn): Update.
1103 2017-10-02 Tom Tromey <tom@tromey.com>
1106 * rust-lang.c (rust_val_print_str): New function.
1107 (val_print_struct): Call it.
1108 (rust_subscript): Preserve name of slice type.
1110 2017-10-02 Tom Tromey <tom@tromey.com>
1112 * rust-lang.c (rust_subscript): Handle slices in
1113 EVAL_AVOID_SIDE_EFFECTS case.
1115 2017-10-02 Tom Tromey <tom@tromey.com>
1117 * rust-lang.c (rust_slice_type_p): Recognize &str as a slice type.
1119 2017-10-02 Tom Tromey <tom@tromey.com>
1121 * rust-lang.h (rust_slice_type): Add "extern".
1123 2017-10-02 Tom Tromey <tom@tromey.com>
1124 Pedro Alves <palves@redhat.com>
1126 * ada-lang.h (ada_exc_info::operator<): Make const.
1127 (ada_exc_info::operator==): Make const.
1128 * ada-lang.c (ada_exc_info::operator<, ada_exc_info::operator==):
1131 2017-09-29 Tom Tromey <tom@tromey.com>
1133 * target.c (read_whatever_is_readable): Change type of "result".
1135 (free_memory_read_result_vector): Remove.
1136 (read_memory_robust): Change return type. Update.
1137 * mi/mi-main.c (mi_cmd_data_read_memory_bytes): Update. Use
1138 bin2hex, std::string.
1139 * target.h (memory_read_result_s): Remove typedef.
1140 (free_memory_read_result_vector): Remove.
1141 (read_memory_robust): Return std::vector.
1143 2017-09-29 Tom Tromey <tom@tromey.com>
1145 * mi/mi-main.c (captured_mi_execute_command): Use scope_restore.
1147 2017-09-29 Tom Tromey <tom@tromey.com>
1149 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Update.
1150 * ada-lang.h (struct ada_exc_info): Remove typedef. Declare
1151 operator< and operator==.
1152 (ada_exceptions_list): Return a std::vector.
1153 * ada-lang.c (ada_exc_info::operator<): Rename from
1154 compare_ada_exception_info.
1155 (ada_exc_info::operator==): New.
1156 (sort_remove_dups_ada_exceptions_list): Change type of
1158 (ada_add_standard_exceptions, ada_add_exceptions_from_frame)
1159 (ada_add_global_exceptions): Likewise.
1160 (ada_exceptions_list_1): Return a std::vector.
1161 (ada_exceptions_list): Likewise.
1163 2017-09-29 Tom Tromey <tom@tromey.com>
1165 * mi/mi-main.c (struct print_one_inferior_data) <inferiors>: Now a
1167 (print_one_inferior): Update.
1168 (free_vector_of_ints): Remove.
1169 (list_available_thread_groups): Change "ids" to std::set.
1170 (mi_cmd_list_thread_groups): Update.
1171 (struct collect_cores_data) <core>: Now a std::set.
1172 (collect_cores): Update.
1174 (print_one_inferior): Update.
1176 2017-09-29 Tom Tromey <tom@tromey.com>
1178 * mi/mi-main.c (mi_execute_cli_command): Use std::string.
1179 (mi_execute_async_cli_command): Likewise.
1180 (mi_cmd_trace_frame_collected): Use field_fmt.
1182 2017-09-29 Tom Tromey <tom@tromey.com>
1184 * mi/mi-main.c (mi_cmd_data_write_memory_bytes): Use
1187 2017-09-29 Tom Tromey <tom@tromey.com>
1189 * mi/mi-parse.c (mi_parse): Remove unused declaration.
1191 2017-09-29 Tom Tromey <tom@tromey.com>
1193 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Don't copy "oarg".
1195 2017-09-29 Tom Tromey <tom@tromey.com>
1197 * varobj.h (varobj_gen_name): Return std::string.
1198 * varobj.c (varobj_gen_name): Return std::string.
1199 * mi/mi-cmd-var.c (mi_cmd_var_create): Use std::string.
1200 (mi_cmd_var_delete): Don't copy "name".
1202 2017-09-29 Tom Tromey <tom@tromey.com>
1204 * mi/mi-cmd-break.c (mi_argv_to_format): Return std::string.
1205 (mi_cmd_break_insert_1): Update.
1207 2017-09-29 Tom Tromey <tom@tromey.com>
1209 * target.h (make_scoped_defer_target_commit_resume): Update.
1210 * target.c (make_scoped_defer_target_commit_resume): Rename from
1211 make_cleanup_defer_target_commit_resume. Return a
1213 * infrun.c (proceed): Use make_scoped_defer_target_commit_resume.
1215 2017-09-29 Tom Tromey <tom@tromey.com>
1217 * main.c (captured_main_1): Remove unused declaration.
1218 * spu-multiarch.c (parse_spufs_run): Remove unused declaration.
1220 2017-09-29 Tom Tromey <tom@tromey.com>
1222 * symtab.c (search_symbols): Remove unused outer cleanup.
1223 (make_source_files_completion_list): Remove unused declaration.
1225 2017-09-29 Tom Tromey <tom@tromey.com>
1227 * mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.
1229 2017-09-29 Tom Tromey <tom@tromey.com>
1231 * xstormy16-tdep.c (xstormy16_push_dummy_call): Use
1234 2017-09-29 Tom Tromey <tom@tromey.com>
1236 * complaints.c (vcomplaint): Use std::string.
1238 2017-09-29 Tom Tromey <tom@tromey.com>
1240 * tracepoint.c (trace_variable_command): Use std::string.
1241 (encode_actions_1): Remove unused declarations.
1242 (create_tsv_from_upload): Use std::string.
1244 2017-09-29 Tom Tromey <tom@tromey.com>
1246 * cp-support.c (gdb_demangle): Use std::string.
1248 2017-09-29 Tom Tromey <tom@tromey.com>
1250 * stack.c (parse_frame_specification): Use std::string
1251 (info_frame_command): Use gdb::unique_xmalloc_ptr.
1253 2017-09-29 Tom Tromey <tom@tromey.com>
1255 * tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.
1257 2017-09-29 Tom Tromey <tom@tromey.com>
1259 * utils.c (vfprintf_maybe_filtered): Use std::string.
1260 (vfprintf_unfiltered): Likewise.
1262 2017-09-29 Tom Tromey <tom@tromey.com>
1264 * event-top.c (top_level_prompt): Return std::string.
1265 (display_gdb_prompt): Update.
1267 2017-09-29 Tom Tromey <tom@tromey.com>
1269 * unittests/common-utils-selftests.c (format): New function.
1270 (string_vprintf_tests): New function.
1271 (_initialize_common_utils_selftests): Register new tests.
1272 * common/common-utils.c (string_vprintf): New function.
1273 * common/common-utils.h (string_vprintf): Declare.
1275 2017-09-29 Pedro Alves <palves@redhat.com>
1277 * common/rsp-low.c (unpack_varlen_hex): Constify.
1278 * common/rsp-low.h (unpack_varlen_hex): Constify.
1279 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
1281 * remote.c (remote_set_permissions, read_ptid)
1282 (remote_current_thread, remote_get_threads_with_qthreadinfo)
1283 (remote_static_tracepoint_marker_at)
1284 (remote_static_tracepoint_markers_by_strid)
1285 (stop_reply_extract_thread, remote_parse_stop_reply): Constify.
1286 * tracepoint.c (parse_trace_status, parse_tracepoint_status)
1287 (parse_tracepoint_definition, parse_tsv_definition)
1288 (parse_static_tracepoint_marker_definition): Constify.
1289 * tracepoint.h (parse_static_tracepoint_marker_definition)
1290 (parse_trace_status, parse_tracepoint_status)
1291 (parse_tracepoint_definition, parse_tsv_definition): Constify.
1293 2017-09-29 Pedro Alves <palves@redhat.com>
1295 * remote.c (target_buf, target_buf_size): Delete.
1296 (remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
1297 Use the connection's packet buffer instead.
1298 All callers adjusted.
1299 (_initialize_remote): Remove references to target_buf and
1302 2017-09-28 Pedro Alves <palves@redhat.com>
1304 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1305 unittests/common-utils-selftests.c.
1306 (SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
1307 (COMMON_OBS): Remove utils-selftests.o.
1308 * utils-selftests.c: Move to ...
1309 * unittests/common-utils-selftests.c: ... here and rename self
1310 test to "string_printf".
1312 2017-09-28 Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com> (tiny patch)
1314 * dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
1315 having NULL cus or tus.
1317 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
1319 * arm-tdep.c: (convert_from_extended): Remove.
1320 (convert_to_extended): Likewise.
1321 (arm_extract_return_value): Use convert_typed_floating.
1322 (arm_store_return_value): Likewise.
1324 * sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
1325 * sh-tdep.c: Do not include "floatformat.h".
1326 (sh_littlebyte_bigword_type): New function.
1327 (sh_register_convert_to_virtual): Use convert_typed_floating.
1328 (sh_register_convert_to_raw): Likewise.
1329 * sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
1330 (sh64_littlebyte_bigword_type): New function.
1331 (sh64_extract_return_value): Use convert_typed_floating.
1332 (sh64_register_convert_to_virtual): Likewise.
1333 (sh64_register_convert_to_raw): Likewise.
1335 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
1337 * doublest.h (floatformat_from_type): Move to gdbtypes.h.
1338 * doublest.c (floatformat_from_type): Move to gdbtypes.c.
1340 * gdbtypes.h (union type_specific): Make field floatformat hold
1341 just a single struct floatformat, not an array.
1342 (floatformat_from_type): Move here.
1343 * gdbtypes.c (floatformat_from_type): Move here. Update to
1344 changed TYPE_FLOATFORMAT definition.
1345 (verify_floatformat): Update to changed TYPE_FLOATFORMAT.
1346 (recursive_dump_type): Likewise.
1347 (init_float_type): Install correct floatformat for byte order.
1348 (arch_float_type): Likewise.
1350 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
1352 * gdbtypes.c (init_type): Change incoming argument from
1353 length-in-bytes to length-in-bits. Assert length is a
1354 multiple of TARGET_CHAR_BITS.
1355 (arch_type, arch_flags_type): Likewise.
1356 (init_integer_type): Update call to init_type.
1357 (init_character_type): Likewise.
1358 (init_boolean_type): Likewise.
1359 (init_float_type): Likewise.
1360 (init_decfloat_type): Likewise.
1361 (init_complex_type): Likewise.
1362 (init_pointer_type): Likewise.
1363 (objfile_type): Likewise.
1364 (arch_integer_type): Update call to arch_type.
1365 (arch_character_type): Likewise.
1366 (arch_boolean_type): Likewise.
1367 (arch_float_type): Likewise.
1368 (arch_decfloat_type): Likewise.
1369 (arch_complex_type): Likewise.
1370 (arch_pointer_type): Likewise.
1371 (gdbtypes_post_init): Likewise.
1373 * dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
1374 (read_base_type): Likewise.
1375 * mdebugread.c (basic_type): Likewise.
1376 * stabsread.c (dbx_init_float_type): Likewise.
1377 (rs6000_builtin_type): Likewise.
1378 (read_range_type): Likewise. Also, fix call to init_integer_type
1379 with erroneous length argument.
1381 * ada-lang.c (ada_language_arch_info): Update call to arch_type.
1382 * d-lang.c (build_d_types): Likewise.
1383 * f-lang.c (build_fortran_types): Likewise.
1384 * go-lang.c (build_go_types): Likewise.
1385 * opencl-lang.c (build_opencl_types): Likewise.
1386 * jit.c (finalize_symtab): Likewise.
1387 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
1388 (build_std_type_info_type): Likewise.
1389 * target-descriptions.c (tdesc_gdb_type): Likewise. Also,
1390 update call to arch_flags_type.
1392 * linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
1394 * fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
1395 * windows-tdep.c (windows_get_tlb_type): Likewise.
1397 * avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
1398 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
1399 * m32c-tdep.c (make_types): Likewise.
1400 * rl78-tdep.c (rl78_gdbarch_init): Likewise.
1401 (rl78_psw_type): Update call to arch_flags_type.
1402 * m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
1403 * rx-tdep.c (rx_psw_type): Likewise.
1404 (rx_fpsw_type): Likewise.
1405 * sparc-tdep.c (sparc_psr_type): Likewise.
1406 (sparc_fsr_type): Likewise.
1407 * sparc64-tdep.c (sparc64_pstate_type): Likewise.
1408 (sparc64_ccr_type): Likewise.
1409 (sparc64_fsr_type): Likewise.
1410 (sparc64_fprs_type): Likewise.
1412 2017-09-27 Tom Tromey <tom@tromey.com>
1414 * findcmd.c (find_command): Constify.
1416 2017-09-27 Tom Tromey <tom@tromey.com>
1418 * ada-tasks.c (task_command_1, task_command): Constify.
1420 2017-09-27 Tom Tromey <tom@tromey.com>
1422 * symtab.c (maintenance_print_symbol_cache)
1423 (maintenance_flush_symbol_cache)
1424 (maintenance_print_symbol_cache_statistics): Constify.
1426 2017-09-27 Tom Tromey <tom@tromey.com>
1428 * inferior.c (detach_inferior_command, kill_inferior_command)
1429 (inferior_command): Constify.
1431 2017-09-27 Tom Tromey <tom@tromey.com>
1433 * regcache.c (regcache_print, maintenance_print_registers)
1434 (maintenance_print_raw_registers)
1435 (maintenance_print_cooked_registers)
1436 (maintenance_print_register_groups)
1437 (maintenance_print_remote_registers): Constify.
1439 2017-09-27 Tom Tromey <tom@tromey.com>
1441 * printcmd.c (map_display_numbers, undisplay_command)
1442 (enable_disable_display_command, enable_display_command)
1443 (disable_display_command): Constify.
1445 2017-09-27 Tom Tromey <tom@tromey.com>
1447 * breakpoint.h (delete_command): Don't declare.
1448 * breakpoint.c (delete_command, enable_once_command)
1449 (enable_count_command, enable_delete_command, breakpoint_1)
1450 (maintenance_info_breakpoints, stopin_command, stopat_command)
1451 (delete_command, delete_trace_command, save_breakpoints)
1452 (save_breakpoints_command, save_tracepoints_command): Constify.
1454 2017-09-27 Tom Tromey <tom@tromey.com>
1456 * macrocmd.c (macro_expand_command, macro_expand_once_command)
1457 (skip_ws, extract_identifier, macro_define_command)
1458 (macro_undef_command, macro_list_command): Constify.
1460 2017-09-27 Tom Tromey <tom@tromey.com>
1462 * infcmd.c (environment_info, set_environment_command)
1463 (unset_environment_command, path_info, info_proc_cmd_1)
1464 (info_proc_cmd_mappings, info_proc_cmd_stat)
1465 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
1466 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
1468 2017-09-27 Tom Tromey <tom@tromey.com>
1470 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
1473 2017-09-27 Tom Tromey <tom@tromey.com>
1475 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
1477 2017-09-27 Tom Tromey <tom@tromey.com>
1479 * demangle.c (demangle_command): Constify.
1481 2017-09-27 Tom Tromey <tom@tromey.com>
1483 * progspace.c (maintenance_info_program_spaces_command):
1486 2017-09-27 Tom Tromey <tom@tromey.com>
1488 * compile/compile.c (check_raw_argument, compile_file_command)
1489 (compile_code_command, compile_print_command): Constify.
1491 2017-09-27 Tom Tromey <tom@tromey.com>
1493 * reggroups.c (maintenance_print_reggroups): Constify.
1495 2017-09-27 Tom Tromey <tom@tromey.com>
1497 * dwarf2read.c (save_gdb_index_command): Constify.
1499 2017-09-27 Tom Tromey <tom@tromey.com>
1501 * stap-probe.c (info_probes_stap_command): Constify.
1503 2017-09-27 Tom Tromey <tom@tromey.com>
1505 * fork-child.c (unset_exec_wrapper_command): Constify.
1507 2017-09-27 Tom Tromey <tom@tromey.com>
1509 * btrace.c (get_uint, get_context_size, no_chunk)
1510 (maint_btrace_packet_history_cmd)
1511 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
1512 (maint_info_btrace_cmd): Constify.
1514 2017-09-27 Tom Tromey <tom@tromey.com>
1516 * reverse.c (delete_bookmark_command): Constify.
1518 2017-09-27 Tom Tromey <tom@tromey.com>
1520 * remote.c (set_memory_packet_size)
1521 (set_memory_write_packet_size, show_memory_write_packet_size)
1522 (set_memory_read_packet_size, show_memory_read_packet_size)
1523 (compare_sections_command, packet_command, remote_put_command)
1524 (remote_get_command, remote_delete_command): Constify.
1526 2017-09-27 Tom Tromey <tom@tromey.com>
1528 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
1529 (set_mipsfpu_double_command, set_mipsfpu_none_command)
1530 (set_mipsfpu_auto_command): Constify.
1532 2017-09-27 Tom Tromey <tom@tromey.com>
1534 * cli/cli-cmds.h (cd_command): Constify.
1535 * cli/cli-cmds.c (cd_command): Constify.
1537 2017-09-27 Tom Tromey <tom@tromey.com>
1539 * thread.c (thread_name_command, thread_find_command): Constify.
1541 2017-09-27 Tom Tromey <tom@tromey.com>
1543 * probe.c (enable_probes_command, disable_probes_command):
1546 2017-09-27 Tom Tromey <tom@tromey.com>
1548 * symfile.c (symbol_file_command): Constify.
1549 * gdbcore.h (deprecated_file_changed_hook): Constify.
1550 * exec.c (deprecated_file_changed_hook, exec_file_command)
1551 (file_command): Constify.
1552 * defs.h (symbol_file_command): Constify.
1554 2017-09-27 Tom Tromey <tom@tromey.com>
1556 * remote-fileio.c (set_system_call_allowed)
1557 (show_system_call_allowed): Constify.
1559 2017-09-27 Tom Tromey <tom@tromey.com>
1561 * tracepoint.c (delete_trace_variable_command)
1562 (tfind_end_command, tfind_start_command, tfind_pc_command)
1563 (tfind_tracepoint_command, tfind_line_command)
1564 (tfind_range_command, tfind_outside_command): Constify.
1566 2017-09-27 Tom Tromey <tom@tromey.com>
1568 * ax-gdb.c (maint_agent_printf_command, agent_command)
1569 (agent_eval_command): Constify.
1571 2017-09-27 Tom Tromey <tom@tromey.com>
1573 * tracepoint.c (info_scope_command): Constify.
1574 * python/python.c (gdbpy_decode_line): Constify.
1575 * python/py-breakpoint.c (bppy_init): Constify.
1576 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
1577 * location.h: (new_linespec_location)
1578 (string_to_event_location_basic, string_to_event_location):
1580 * location.c (new_linespec_location)
1581 (string_to_event_location_basic, string_to_event_location):
1583 * linespec.h (decode_line_with_current_source)
1584 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
1585 * linespec.c (linespec_lex_to_end)
1586 (decode_line_with_current_source)
1587 (decode_line_with_last_displayed): Constify.
1588 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
1590 * cli/cli-cmds.c (edit_command, list_command): Constify.
1591 * breakpoint.h (until_break_command, watch_command_wrapper)
1592 (awatch_command_wrapper, rwatch_command_wrapper)
1593 (init_ada_exception_breakpoint): Constify.
1594 * breakpoint.c (break_command_1, dprintf_command)
1595 (break_range_command, watch_command_wrapper)
1596 (rwatch_command_wrapper, awatch_command_wrapper)
1597 (until_break_command, init_ada_exception_breakpoint)
1598 (strace_marker_create_sals_from_location, trace_command)
1599 (ftrace_command, strace_command, struct tracepoint): Constify.
1600 * ax-gdb.c (agent_command_1): Constify.
1601 * ada-lang.c (ada_exception_sal): Constify.
1603 2017-09-27 Tom Tromey <tom@tromey.com>
1605 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
1606 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
1607 (get_context_size, no_chunk, get_insn_history_modifiers)
1608 (cmd_record_insn_history, get_call_history_modifiers)
1609 (cmd_record_call_history): Constify.
1611 2017-09-27 Tom Tromey <tom@tromey.com>
1613 * source.c (show_substitute_path_command)
1614 (unset_substitute_path_command, set_substitute_path_command):
1617 2017-09-27 Tom Tromey <tom@tromey.com>
1619 * typeprint.c (maintenance_print_type): Constify.
1620 * maint.c (maintenance_dump_me, maintenance_demangle)
1621 (maintenance_time_display, maintenance_info_sections)
1622 (maintenance_print_statistics, maintenance_deprecate)
1623 (maintenance_undeprecate): Constify.
1624 (maintenance_do_deprecate): Constify. Use std::string.
1625 (maintenance_selftest): Constify.
1626 * gdbtypes.h (maintenance_print_type): Constify.
1628 2017-09-27 Tom Tromey <tom@tromey.com>
1630 * hppa-tdep.c (unwind_command): Constify.
1632 2017-09-27 Tom Tromey <tom@tromey.com>
1634 * target-descriptions.c (unset_tdesc_filename_cmd)
1635 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
1638 2017-09-27 Tom Tromey <tom@tromey.com>
1640 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
1642 2017-09-27 Tom Tromey <tom@tromey.com>
1644 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
1646 2017-09-27 Tom Tromey <tom@tromey.com>
1648 * tui/tui-regs.c (tui_reg_command): Constify.
1650 2017-09-27 Tom Tromey <tom@tromey.com>
1652 * skip.c (skip_file_command, skip_function_command)
1653 (skip_enable_command, skip_disable_command, skip_delete_command):
1656 2017-09-27 Tom Tromey <tom@tromey.com>
1658 * record-btrace.c (cmd_record_btrace_bts_start)
1659 (cmd_record_btrace_pt_start): Constify.
1661 2017-09-27 Tom Tromey <tom@tromey.com>
1663 * symmisc.c (maintenance_print_symbols)
1664 (maintenance_print_msymbols, maintenance_print_objfiles)
1665 (maintenance_info_symtabs, maintenance_check_symtabs)
1666 (maintenance_expand_symtabs, maintenance_info_line_tables):
1669 2017-09-27 Tom Tromey <tom@tromey.com>
1671 * top.c (new_ui_command): Constify.
1673 2017-09-27 Tom Tromey <tom@tromey.com>
1675 * symfile.c (add_symbol_file_command)
1676 (remove_symbol_file_command, list_overlays_command)
1677 (map_overlay_command, unmap_overlay_command)
1678 (overlay_auto_command, overlay_manual_command)
1679 (overlay_off_command, overlay_load_command): Constify.
1681 2017-09-27 Tom Tromey <tom@tromey.com>
1683 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
1684 (info_spu_mailbox_command, info_spu_dma_command)
1685 (info_spu_proxydma_command): Constify.
1687 2017-09-27 Tom Tromey <tom@tromey.com>
1689 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
1691 2017-09-27 Tom Tromey <tom@tromey.com>
1693 * cli/cli-script.c (user_defined_command): Constify.
1695 2017-09-27 Tom Tromey <tom@tromey.com>
1697 * cli/cli-dump.c (dump_memory_command, dump_value_command)
1698 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
1699 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
1700 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
1701 (dump_binary_value, append_binary_memory, append_binary_value):
1703 (struct dump_context) <func>: Constify.
1704 (add_dump_command): Update.
1706 2017-09-27 Tom Tromey <tom@tromey.com>
1708 * cli/cli-cmds.c (show_version, show_configuration)
1709 (source_command, show_user): Constify.
1711 2017-09-27 Tom Tromey <tom@tromey.com>
1713 * target.c (maintenance_print_target_stack): Constify.
1715 2017-09-27 Tom Tromey <tom@tromey.com>
1717 * interps.c (interpreter_exec_cmd): Constify.
1719 2017-09-27 Tom Tromey <tom@tromey.com>
1721 * record-full.c (cmd_record_full_restore): Constify.
1723 2017-09-27 Tom Tromey <tom@tromey.com>
1725 * memattr.c (enable_mem_command, disable_mem_command)
1726 (delete_mem_command): Constify.
1728 2017-09-27 Tom Tromey <tom@tromey.com>
1730 * value.c (show_convenience): Constify.
1732 2017-09-27 Tom Tromey <tom@tromey.com>
1734 * gdbcore.h (core_file_command): Update.
1735 * corefile.c (core_file_command): Constify.
1737 2017-09-27 Tom Tromey <tom@tromey.com>
1739 * user-regs.c (maintenance_print_user_registers): Constify.
1741 2017-09-27 Tom Tromey <tom@tromey.com>
1743 * cp-namespace.c (maintenance_cplus_namespace): Constify.
1745 2017-09-27 Tom Tromey <tom@tromey.com>
1747 * cp-support.c (first_component_command): Constify.
1749 2017-09-27 Tom Tromey <tom@tromey.com>
1751 * psymtab.c (maintenance_print_psymbols)
1752 (maintenance_info_psymtabs, maintenance_check_psymtabs):
1755 2017-09-27 Tom Tromey <tom@tromey.com>
1757 * windows-tdep.c (display_tib): Constify.
1759 2017-09-27 Tom Tromey <tom@tromey.com>
1761 * linux-fork.c (delete_checkpoint_command)
1762 (detach_checkpoint_command): Constify.
1764 2017-09-27 Tom Tromey <tom@tromey.com>
1766 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
1768 2017-09-27 Tom Tromey <tom@tromey.com>
1770 * arc-tdep.c (dump_arc_instruction_command): Constify.
1772 2017-09-27 Tom Tromey <tom@tromey.com>
1774 * valprint.c (set_radix, show_radix): Constify.
1776 2017-09-27 Tom Tromey <tom@tromey.com>
1778 * dtrace-probe.c (info_probes_dtrace_command): Constify.
1780 2017-09-27 Tom Tromey <tom@tromey.com>
1782 * command.h (not_just_help_class_command): Update.
1783 * cli/cli-decode.h (not_just_help_class_command): Update.
1784 * cli/cli-decode.c (not_just_help_class_command): Constify.
1786 2017-09-27 Tom Tromey <tom@tromey.com>
1788 * gdb_bfd.c (maintenance_info_bfds): Constify.
1790 2017-09-27 Tom Tromey <tom@tromey.com>
1792 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
1794 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
1795 (do_const_cfunc): New function.
1796 (cmd_cfunc_eq): New overload.
1797 (cli_user_command_p): Check do_const_cfunc.
1798 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
1800 * command.h (add_cmd): Add const overload and no-function
1802 (set_cmd_cfunc): Add const overload.
1803 (cmd_const_cfunc_ftype): Declare.
1804 (cmd_cfunc_eq): Add const overload.
1805 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
1806 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
1809 2017-09-27 Tom Tromey <tom@tromey.com>
1811 * macroexp.c (get_next_token_for_substitution): New function.
1812 (substitute_args): Call it. Check for __VA_OPT__.
1814 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
1815 Pedro Alves <palves@redhat.com>
1817 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
1818 producer_is_icc_lt_14.
1819 (producer_is_icc_lt_14): New function.
1820 (check_producer): Add code for checking version of ICC.
1821 (producer_is_icc): Move to producer.c.
1822 (read_structure_type): Restrict ICC workaround to ICC<14.
1823 * producer.c: Include selftest.h.
1824 (producer_is_icc, producer_parsing_tests, _initialize_producer):
1826 * producer.h (producer_is_icc): New declaration.
1828 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
1830 * Makefile.in (SFILES): Add producer.c.
1831 (COMMON_OBS): Add producer.o
1832 * amd64-tdep.c (producer.h): Add new include.
1833 * dwarf2read.c (producer.h): Add new include.
1834 * producer.c: New file.
1835 * producer.h: New file.
1836 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
1838 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
1841 2017-09-26 Matthias Klose <doko@ubuntu.com>
1843 * configure.ac: Search ncursesw before ncurses.
1844 Check ncursesw/ncurses.h before ncurses/ncurses.h.
1845 * gdb_curses.h: Include <ncursesw/ncurses.h>
1846 * config.in, configure: Regenerate.
1848 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1851 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
1853 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
1854 Remove i386sol2 support.
1855 * configure.nat <i386sol2>: Remove.
1856 <sol2-64>: Fold into ...
1858 Move common settings to default section.
1860 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
1861 x86_64-*-solaris2.1[0-9]*>: Rename to ...
1862 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
1863 <i[34567]86-*-solaris*>: Remove.
1864 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
1866 * configure.ac: Remove wctype in libw check.
1867 (_MSE_INT_H): Don't define on Solaris 7-9.
1868 <solaris*>: Remove libthread_db.so.1 check.
1869 * configure: Regenerate.
1870 * config.in: Regenerate.
1872 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
1873 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
1874 (gdb_ps_size_t): Remove.
1875 Use base types in users.
1876 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
1878 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
1880 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1883 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
1884 (adi_is_addr_mapped): Likewise.
1885 (PSR_ICC): Don't redefine.
1886 (PSR_IMPL): Likewise.
1888 2017-09-25 Tom Tromey <tom@tromey.com>
1890 * regcache.c (regcache::dump): Use string_printf.
1892 2017-09-25 Tom Tromey <tom@tromey.com>
1894 * regcache.c (class regcache_invalidator): New.
1895 (struct register_to_invalidate): Remove.
1896 (make_cleanup_regcache_invalidate): Remove.
1897 (regcache::raw_write): Use regcache_invalidator.
1899 2017-09-25 Tom Tromey <tom@tromey.com>
1901 * spu-tdep.c (spu2ppu_sniffer): Update.
1902 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
1903 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
1905 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
1906 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
1907 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
1908 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
1909 (frame_pop): Update.
1911 2017-09-25 Tom Tromey <tom@tromey.com>
1913 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
1914 * regcache.h (regcache_xfree): Don't declare.
1915 * regcache.c (regcache_xfree): Remove.
1916 (do_regcache_xfree): Use delete.
1917 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
1918 * linux-fork.c (free_fork): Use delete.
1919 (fork_save_infrun_state): Likewise.
1920 * jit.c (jit_dealloc_cache): Use delete.
1921 * infrun.c (discard_infcall_suspend_state): Use delete.
1923 2017-09-25 Tom Tromey <tom@tromey.com>
1925 * regcache.h (regcache_xmalloc): Don't declare.
1926 (regcache_raw_set_cached_value): Update comment.
1927 * regcache.c (regcache_xmalloc): Remove.
1928 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
1929 * jit.c (jit_frame_sniffer): Use new.
1930 * frame.c (frame_save_as_regcache): Use new.
1932 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
1934 * NEWS: Advertise support for guarded-storage registers on IBM z.
1936 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
1938 * s390-linux-nat.c (have_regset_gs): New static variable.
1939 (s390_linux_fetch_inferior_registers): Handle guarded-storage
1940 control block and guarded-storage broadcast control regsets.
1941 (s390_read_description): Detect whether the target has
1942 guarded-storage support, return appropriate tdesc.
1943 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
1944 (features/s390x-gs-linux64.c): Likewise.
1945 (struct gdbarch_tdep) <have_gs>: New field.
1946 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
1947 (s390_gsbc_regset): New variables.
1948 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
1949 and s390_gsbc_regset, if applicable.
1950 (s390_core_read_description): Check whether core file was from a
1951 target with guarded-storage support; include appropriate regsets.
1952 (s390_gdbarch_init): Add registers for guarded-storage support.
1953 (_initialize_s390_tdep): Initialize new target descriptions that
1954 include registers for guarded-storage support.
1955 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
1956 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
1957 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
1958 (S390_NUM_REGS): Adjust macro definition.
1959 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
1960 (tdesc_s390x_gs_linux64): New declarations.
1962 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
1964 * features/s390-gs-linux64.xml: New file.
1965 * features/s390-gs.xml: New file.
1966 * features/s390-gsbc.xml: New file.
1967 * features/s390x-gs-linux64.xml: New file.
1968 * features/Makefile (WHICH): Add s390-gs-linux64 and
1970 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
1971 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
1972 * features/s390-gs-linux64.c: New generated file.
1973 * features/s390x-gs-linux64.c: New file.
1974 * regformats/s390-gs-linux64.dat: New file.
1975 * regformats/s390x-gs-linux64.dat: New file.
1977 2017-09-23 Tom Tromey <tom@tromey.com>
1979 * defs.h (make_cleanup_override_quit_handler): Don't declare.
1981 2017-09-22 Tom Tromey <tom@tromey.com>
1983 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
1984 type to scoped_restore_tmpl.
1985 <scoped_input_handler>: Initialize m_quit_handler directly.
1987 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
1989 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
1990 (cd_command): Likewise. Free "current_directory" before
1992 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
1993 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
1994 * top.c (gdb_dirbuf): Remove global declaration.
1995 * top.h (gdb_dirbuf): Likewise.
1997 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
1999 * gnulib/aclocal.m4: Regenerate.
2000 * gnulib/config.in: Regenerate.
2001 * gnulib/configure: Regenerate.
2002 * gnulib/import/Makefile.am: Regenerate.
2003 * gnulib/import/Makefile.in: Regenerate.
2004 * gnulib/import/assure.h: New file.
2005 * gnulib/import/at-func.c: Likewise
2006 * gnulib/import/chdir-long.c: New file.
2007 * gnulib/import/chdir-long.h: New file.
2008 * gnulib/import/cloexec.c: New file.
2009 * gnulib/import/cloexec.h: New file.
2010 * gnulib/import/close.c: New file.
2011 * gnulib/import/closedir.c: New file.
2012 * gnulib/import/dirent-private.h: New file.
2013 * gnulib/import/dup-safer.c: New file.
2014 * gnulib/import/dup.c: New file.
2015 * gnulib/import/dup2.c: New file.
2016 * gnulib/import/error.c: New file.
2017 * gnulib/import/error.h: New file.
2018 * gnulib/import/exitfail.c: New file.
2019 * gnulib/import/exitfail.h: New file.
2020 * gnulib/import/fchdir.c: New file.
2021 * gnulib/import/fcntl.c: New file.
2022 * gnulib/import/fcntl.in.h: New file.
2023 * gnulib/import/fd-hook.c: New file.
2024 * gnulib/import/fd-hook.h: New file.
2025 * gnulib/import/fd-safer.c: New file.
2026 * gnulib/import/fdopendir.c: New file.
2027 * gnulib/import/filename.h: New file.
2028 * gnulib/import/filenamecat-lgpl.c: New file.
2029 * gnulib/import/filenamecat.h: New file.
2030 * gnulib/import/fstat.c: New file.
2031 * gnulib/import/fstatat.c: New file.
2032 * gnulib/import/getcwd-lgpl.c: New file.
2033 * gnulib/import/getcwd.c: New file.
2034 * gnulib/import/getdtablesize.c: New file.
2035 * gnulib/import/getlogin_r.c: New file.
2036 * gnulib/import/getprogname.c: New file.
2037 * gnulib/import/getprogname.h: New file.
2038 * gnulib/import/gettext.h: New file.
2039 * gnulib/import/glob-libc.h: New file.
2040 * gnulib/import/glob.c: New file.
2041 * gnulib/import/glob.in.h: New file.
2042 * gnulib/import/intprops.h: New file.
2043 * gnulib/import/m4/chdir-long.m4: New file.
2044 * gnulib/import/m4/close.m4: New file.
2045 * gnulib/import/m4/closedir.m4: New file.
2046 * gnulib/import/m4/d-ino.m4: New file.
2047 * gnulib/import/m4/d-type.m4: New file.
2048 * gnulib/import/m4/dup.m4: New file.
2049 * gnulib/import/m4/dup2.m4: New file.
2050 * gnulib/import/m4/error.m4: New file.
2051 * gnulib/import/m4/fchdir.m4: New file.
2052 * gnulib/import/m4/fcntl.m4: New file.
2053 * gnulib/import/m4/fcntl_h.m4: New file.
2054 * gnulib/import/m4/fdopendir.m4: New file.
2055 * gnulib/import/m4/filenamecat.m4: New file.
2056 * gnulib/import/m4/fstat.m4: New file.
2057 * gnulib/import/m4/fstatat.m4: New file.
2058 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
2059 * gnulib/import/m4/getcwd-path-max.m4: New file.
2060 * gnulib/import/m4/getcwd.m4: New file.
2061 * gnulib/import/m4/getdtablesize.m4: New file.
2062 * gnulib/import/m4/getlogin_r.m4: New file.
2063 * gnulib/import/m4/getprogname.m4: New file.
2064 * gnulib/import/m4/glob.m4: New file.
2065 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
2066 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
2067 * gnulib/import/m4/mempcpy.m4: New file.
2068 * gnulib/import/m4/memrchr.m4: New file.
2069 * gnulib/import/m4/mode_t.m4: New file.
2070 * gnulib/import/m4/msvc-inval.m4: New file.
2071 * gnulib/import/m4/msvc-nothrow.m4: New file.
2072 * gnulib/import/m4/open.m4: New file.
2073 * gnulib/import/m4/openat.m4: New file.
2074 * gnulib/import/m4/opendir.m4: New file.
2075 * gnulib/import/m4/readdir.m4: New file.
2076 * gnulib/import/m4/realloc.m4: New file.
2077 * gnulib/import/m4/rewinddir.m4: New file.
2078 * gnulib/import/m4/save-cwd.m4: New file.
2079 * gnulib/import/m4/strdup.m4: New file.
2080 * gnulib/import/m4/strerror.m4: New file.
2081 * gnulib/import/m4/unistd-safer.m4: New file.
2082 * gnulib/import/mempcpy.c: New file.
2083 * gnulib/import/memrchr.c: New file.
2084 * gnulib/import/msvc-inval.c: New file.
2085 * gnulib/import/msvc-inval.h: New file.
2086 * gnulib/import/msvc-nothrow.c: New file.
2087 * gnulib/import/msvc-nothrow.h: New file.
2088 * gnulib/import/open.c: New file.
2089 * gnulib/import/openat-die.c: New file.
2090 * gnulib/import/openat-priv.h: New file.
2091 * gnulib/import/openat-proc.c: New file.
2092 * gnulib/import/openat.c: New file.
2093 * gnulib/import/openat.h: New file.
2094 * gnulib/import/opendir.c: New file.
2095 * gnulib/import/pipe-safer.c: New file.
2096 * gnulib/import/readdir.c: New file.
2097 * gnulib/import/realloc.c: New file.
2098 * gnulib/import/rewinddir.c: New file.
2099 * gnulib/import/save-cwd.c: New file.
2100 * gnulib/import/save-cwd.h: New file.
2101 * gnulib/import/strdup.c: New file.
2102 * gnulib/import/strerror-override.c: New file.
2103 * gnulib/import/strerror-override.h: New file.
2104 * gnulib/import/strerror.c: New file.
2105 * gnulib/import/unistd--.h: New file.
2106 * gnulib/import/unistd-safer.h: New file.
2107 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
2108 "getcwd" and "glob".
2109 * ser-tcp.c: Undefine "close" before redefining it.
2111 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
2113 * guile/scm-value.c (gdbscm_value_address): Initialize address,
2116 2017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2118 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
2119 <sol2,sparc>: Likewise.
2120 <sol2-64,i386>: Likewise.
2122 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
2123 -Wdeprecated-declarations on *-*-solaris*.
2124 * configure: Regenerate.
2126 * procfs.c: Include "nat/inferior.h".
2127 (procfs_info_proc): Fix typo.
2129 2017-09-21 Kevin Buettner <kevinb@redhat.com>
2131 * remote.c (vector): Include.
2132 (struct private_thread_info): Add field, thread_handle.
2133 (free_private_thread_info): Deallocate storage associated with
2135 (get_private_info_thread): Initialize `thread_handle' field.
2136 (struct thread_item): Add field, thread_handle.
2137 (clear_threads_listing_context): Deallocate storage associated
2139 (start_thread): Add support for "handle" attribute.
2140 (thread_attributes): Add "handle".
2141 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
2143 (remote_update_thread_list): Update thread_handle.
2144 (remote_thread_handle_to_thread_info): New function.
2145 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
2147 2017-09-21 Kevin Buettner <kevinb@redhat.com>
2149 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
2151 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
2152 * python/python-internal.h (thread_object_type): Declare.
2154 2017-09-21 Kevin Buettner <kevinb@redhat.com>
2156 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
2157 (target_thread_handle_to_thread_info): Declare.
2158 * target.c (target_thread_handle_to_thread_info): New function.
2159 * target-delegates.c: Regenerate.
2160 * gdbthread.h (find_thread_by_handle): Declare.
2161 * thread.c (find_thread_by_handle): New function.
2162 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
2164 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
2166 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
2168 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
2170 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
2172 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
2174 2017-09-21 Yao Qi <yao.qi@linaro.org>
2176 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
2179 2017-09-20 Tom Tromey <tom@tromey.com>
2181 * breakpoint.c (struct counted_command_line): Remove.
2182 (breakpoint_commands): Update.
2183 (alloc_counted_command_line, incref_counted_command_line)
2184 (decref_counted_command_line, do_cleanup_counted_command_line)
2185 (make_cleanup_decref_counted_command_line): Remove.
2186 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
2187 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
2188 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
2189 (save_breakpoints): Update.
2190 * breakpoint.h (counted_command_line): Now a typedef to
2192 (struct breakpoint) <commands>: Now a counted_command_line.
2193 (struct bpstats) <command>: Likewise.
2195 2017-09-20 Tom Tromey <tom@tromey.com>
2197 * breakpoint.c (struct commands_info, do_map_commands_command):
2199 (commands_command_1): Update.
2200 (iterate_over_related_breakpoints): Take a function_view.
2201 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
2202 (delete_command): Update.
2203 (map_breakpoint_numbers): Take a function_view.
2204 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
2205 (disable_command): Update.
2206 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
2207 (enable_command): Update.
2208 (struct disp_data, do_enable_breakpoint_disp)
2209 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
2210 (do_map_enable_delete_breakpoint): Remove.
2211 (enable_once_command, enable_count_command, enable_delete_command)
2212 (delete_trace_variable_command): Update.
2214 2017-09-20 Tom Tromey <tom@tromey.com>
2216 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
2217 (bpstat_clear): Use delete.
2218 (bpstats): New constructors.
2219 (bpstat_copy, bpstat_stop_status): Use new.
2220 (dprintf_after_condition_true): Update.
2221 * breakpoint.h (bpstats::bpstats): Add constructors.
2222 (bpstats::~bpstats): Add destructor.
2224 2017-09-20 Pedro Alves <palves@redhat.com>
2226 * eval.c (make_params): Delete, refactored as ...
2227 (class fake_method): ... this new type's ctor.
2228 (fake_method::~fake_method): New.
2229 (evaluate_subexp_standard): Use 'fake_method'.
2231 2017-09-20 Tom Tromey <tom@tromey.com>
2233 * windows-nat.c (get_windows_debug_event, windows_wait)
2234 (do_initial_windows_stuff, windows_attach): Update.
2235 * utils.c (vwarning, internal_vproblem): Update.
2236 (ui_unregister_input_event_handler_cleanup)
2237 (prepare_to_handle_input): Remove.
2238 (class scoped_input_handler): New.
2239 (defaulted_query, prompt_for_continue): Update.
2240 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
2242 * top.c (undo_terminal_modifications_before_exit): Update.
2243 * target/target.h (target_terminal_init, target_terminal_inferior)
2244 (target_terminal_ours): Don't declare.
2245 (class target_terminal): New.
2246 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
2247 (target_terminal_ours_for_output)
2248 (make_cleanup_restore_target_terminal): Don't declare.
2249 (target_terminal_info): Remove.
2250 * target.c (enum terminal_state, terminal_state): Remove.
2251 (target_terminal::terminal_state): Define.
2252 (target_terminal::init): Rename from target_terminal_init.
2253 (target_terminal::inferior): Rename from
2254 target_terminal_inferior.
2255 (target_terminal::ours): Rename from target_terminal_ours.
2256 (target_terminal::ours_for_output): Rename from
2257 target_terminal_ours_for_output.
2258 (target_terminal::info): New method.
2259 (cleanup_restore_target_terminal)
2260 (make_cleanup_restore_target_terminal): Remove.
2261 * solib.c (handle_solib_event): Update.
2262 * remote.c (remote_serial_quit_handler): Update.
2263 (remote_terminal_inferior, remote_wait_as): Update.
2264 * record-full.c (record_full_wait_1): Update.
2265 * nto-procfs.c (procfs_create_inferior): Update.
2266 * nat/fork-inferior.c (startup_inferior): Update.
2267 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
2268 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
2269 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
2270 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
2271 (mi_breakpoint_created, mi_breakpoint_deleted)
2272 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
2273 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
2274 (mi_user_selected_context_changed, report_initial_inferior):
2276 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
2277 (linux_nat_terminal_inferior): Update.
2278 * infrun.c (follow_fork_inferior)
2279 (handle_vfork_child_exec_or_exit, do_target_resume)
2280 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
2281 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
2283 * inflow.c (child_terminal_init, info_terminal_command): Update.
2284 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
2285 (attach_command): Update.
2286 * infcall.c (call_thread_fsm_should_stop): Update.
2287 * gnu-nat.c (gnu_attach): Update.
2288 * extension.c (struct active_ext_lang_state)
2289 (restore_active_ext_lang): Update.
2290 * exceptions.c (print_flush): Update.
2291 * event-top.c (async_enable_stdin, default_quit_handler): Update.
2292 (struct quit_handler_cleanup_data, restore_quit_handler)
2293 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
2295 * cp-support.c (gdb_demangle): Update.
2296 * breakpoint.c (update_inserted_breakpoint_locations)
2297 (insert_breakpoint_locations, handle_jit_event)
2298 (disable_breakpoints_in_unloaded_shlib): Update.
2299 * annotate.c (annotate_breakpoints_invalid)
2300 (annotate_frames_invalid): Update.
2302 2017-09-20 Tom Tromey <tom@tromey.com>
2304 * main.c (catch_command_errors): Rename from
2305 catch_command_errors_const.
2306 (captured_main_1): Update.
2308 2017-09-20 Pedro Alves <palves@redhat.com>
2310 * cli/cli-cmds.c (list_command): Use print_sal_location.
2311 (print_sal_location): New function.
2312 (ambiguous_line_spec): Use print_sal_location.
2313 * linespec.c (symbol_to_sal): Record the symbol in the sal.
2314 * symtab.c (find_function_start_sal): Likewise.
2315 * symtab.h (symtab_and_line::symbol): New field.
2317 2017-09-20 Pedro Alves <palves@redhat.com>
2319 * linespec.c (minsym_found): Handle non-text minsyms.
2320 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
2322 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
2324 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
2327 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
2329 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
2330 vmovups instead vmovaps.
2331 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
2333 2017-09-19 John Baldwin <jhb@FreeBSD.org>
2335 * NEWS (Changes since GDB 8.0): Add starti.
2336 * infcmd.c (enum run_break): New.
2337 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
2339 (run_command): Use enum run_how.
2340 (start_command): Likewise.
2341 (starti_command): New function.
2342 (RUN_ARGS_HELP): New macro.
2343 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
2344 commands. Add starti command.
2346 2017-09-19 Yao Qi <yao.qi@linaro.org>
2348 * Makefile.in (monitor.o): Remove the rule.
2350 2017-09-19 Yao Qi <yao.qi@linaro.org>
2352 * annotate.h (struct annotate_arg_emitter): Use
2353 DISABLE_COPY_AND_ASSIGN.
2354 * common/refcounted-object.h (refcounted_object): Likewise.
2355 * completer.h (struct completion_result): Likewise.
2356 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
2357 * filename-seen-cache.h (filename_seen_cache): Likewise.
2358 * gdbcore.h (thread_section_name): Likewise.
2359 * gdb_regex.h (compiled_regex): Likewise.
2360 * gdbthread.h (scoped_restore_current_thread): Likewise.
2361 * inferior.h (scoped_restore_current_inferior): Likewise.
2362 * jit.c (jit_reader): Likewise.
2363 * linespec.h (struct linespec_result): Likewise.
2364 * mi/mi-parse.h (struct mi_parse): Likewise.
2365 * nat/fork-inferior.c (execv_argv): Likewise.
2366 * progspace.h (scoped_restore_current_program_space): Likewise.
2367 * python/python-internal.h (class gdbpy_enter): Likewise.
2368 * regcache.h (regcache): Likewise.
2369 * target-descriptions.c (struct tdesc_reg): Likewise.
2370 (struct tdesc_type): Likewise.
2371 (struct tdesc_feature): Likewise.
2372 * ui-out.h (ui_out_emit_type): Likewise.
2374 2017-09-18 Simon Marchi <simon.marchi@ericsson.com>
2376 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
2377 label abort_expression.
2379 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2381 * common/buffer.c (buffer_xml_printf): Adjust.
2382 * common/xml-utils.c (xml_escape_text): Change return type to
2383 std::string, update code accordingly.
2384 * common/xml-utils.h (xml_escape_text): Change return type to
2386 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
2387 * windows-tdep.c (windows_xfer_shared_library): Adjust.
2388 * unittests/xml-utils-selftests.c (test_xml_escape_text):
2391 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2393 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
2394 (SUBDIR_UNITTESTS_OBS): Add new object file.
2395 * unittests/xml-utils-selftests.c: New file.
2397 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2399 * common/selftest.h (selftest): New struct/interface.
2400 (register_test): Add name parameter, add new overload.
2401 (run_tests): Add filter parameter.
2402 (for_each_selftest_ftype): New typedef.
2403 (for_each_selftest): New declaration.
2404 * common/selftest.c (tests): Change type to
2405 map<string, unique_ptr<selftest>>.
2406 (simple_selftest): New struct.
2407 (register_test): New function.
2408 (register_test): Add name parameter and use it.
2409 (run_tests): Add filter parameter and use it. Add prints.
2410 Adjust to vector -> map change.
2411 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
2412 registering selftests.
2413 * arm-tdep.c (_initialize_arm_tdep): Likewise.
2414 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
2415 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
2416 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
2417 * findvar.c (_initialize_findvar): Likewise.
2418 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
2419 * maint.c (maintenance_selftest): Update call to run_tests.
2420 (maintenance_info_selftests): New function.
2421 (_initialize_maint_cmds): Register "maintenance info selftests"
2422 command. Update "maintenance selftest" doc.
2423 * regcache.c (_initialize_regcache): Add names when registering
2425 * rust-exp.y (_initialize_rust_exp): Likewise.
2426 * selftest-arch.c (gdbarch_selftest): New struct.
2427 (gdbarch_tests): Remove.
2428 (register_test_foreach_arch): Add name parameter. Call
2430 (tests_with_arch): Remove, move most content to
2431 gdbarch_selftest::operator().
2432 (_initialize_selftests_foreach_arch): Remove.
2433 * selftest-arch.h (register_test_foreach_arch): Add name
2435 (run_tests_with_arch): New declaration.
2436 * utils-selftests.c (_initialize_utils_selftests): Add names
2437 when registering selftests.
2438 * utils.c (_initialize_utils): Likewise.
2439 * unittests/array-view-selftests.c
2440 (_initialize_array_view_selftests): Likewise.
2441 * unittests/environ-selftests.c (_initialize_environ_selftests):
2443 * unittests/function-view-selftests.c
2444 (_initialize_function_view_selftests): Likewise.
2445 * unittests/offset-type-selftests.c
2446 (_initialize_offset_type_selftests): Likewise.
2447 * unittests/optional-selftests.c
2448 (_initialize_optional_selftests): Likewise.
2449 * unittests/scoped_restore-selftests.c
2450 (_initialize_scoped_restore_selftests): Likewise.
2451 * NEWS: Document "maintenance selftest" and "maint info
2454 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2456 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
2459 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2461 * mi/mi-main.c (mi_load_progress): Make uiout variable
2464 2017-09-15 Pedro Alves <palves@redhat.com>
2466 * compile/compile-c-types.c (convert_enum, convert_int)
2467 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
2469 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2471 * dwarf2read.c (copy_string): Remove.
2472 (parse_macro_definition): Replace copy_string with savestring.
2474 2017-09-15 Yao Qi <yao.qi@linaro.org>
2476 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
2478 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
2480 (i[34567]86-*-linux*): Likewise.
2482 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
2484 * dwarf2expr.h (dwarf_stack_value): Add constructor.
2485 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
2486 <stack>: Change type to std::vector.
2487 <stack_len, stack_allocated>: Remove.
2488 <grow_stack>: Remove.
2489 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
2490 (dwarf_expr_context::~dwarf_expr_context): Remove.
2491 (dwarf_expr_context::grow_stack): Remove.
2492 (dwarf_expr_context::push): Adjust.
2493 (dwarf_expr_context::pop): Adjust.
2494 (dwarf_expr_context::fetch): Adjust.
2495 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
2496 (dwarf_expr_context::stack_empty_p): Adjust.
2497 (dwarf_expr_context::execute_stack_op): Adjust.
2499 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
2501 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
2502 return type to bool.
2503 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
2505 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
2507 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
2508 Change type to bool.
2509 (dwarf_stack_value) <in_stack_memory>: Likewise.
2510 (dwarf_expr_context) <push_address>: Change parameter type to
2512 <fetch_in_stack_memory>: Change return type to bool.
2513 <push>: Change parameter type to bool.
2514 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
2516 (dwarf_expr_context::push_address): Likewise.
2517 (dwarf_expr_context::fetch_in_stack_memory): Change return type
2519 (dwarf_expr_context::execute_stack_op): Adjust.
2520 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
2522 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
2524 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
2525 (struct dwarf_expr_context) <n_pieces>: Remove.
2526 <pieces>: Change type to std::vector.
2527 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
2528 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
2530 (dwarf_expr_context::add_piece): Adjust.
2531 * dwarf2loc.c (struct piece_closure): Initialize fields.
2533 <pieces>: Change type to std::vector.
2534 (allocate_piece_closure): Adjust, change parameter to
2535 std::vector rvalue and std::move it to piece_closure.
2536 (rw_pieced_value): Adjust.
2537 (check_pieced_synthetic_pointer): Adjust.
2538 (indirect_synthetic_pointer): Adjust.
2539 (coerce_pieced_ref): Adjust.
2540 (free_pieced_value_closure): Adjust. Use delete to free
2542 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
2543 to allocate_piece_closure.
2544 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
2546 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
2548 * probe.h (probe_ops_cp): Remove typedef.
2549 (DEF_VEC_P (probe_ops_cp)): Remove.
2550 (all_probe_ops): Change type to std::vector.
2551 * probe.c (info_probes_for_ops): Adjust to vector change.
2552 (probe_linespec_to_ops): Likewise.
2553 (all_probe_ops): Change type to std::vector.
2554 (_initialize_probe): Adjust to vector change.
2555 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
2556 * elfread.c (elf_get_probes): Likewise.
2557 * stap-probe.c (_initialize_stap_probe): Likewise.
2559 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
2561 * probe.h (struct bound_probe): Define constructors.
2562 * probe.c (bound_probe_s): Remove typedef.
2563 (DEF_VEC_O (bound_probe_s)): Remove VEC.
2564 (collect_probes): Change return type to std::vector, remove
2566 (compare_probes): Return bool, change parameter type. Change
2567 semantic to "less than".
2568 (gen_ui_out_table_header_info): Change parameter to std::vector
2570 (exists_probe_with_pops): Likewise.
2571 (info_probes_for_ops): Update to std::vector change.
2572 (enable_probes_command): Likewise.
2573 (disable_probes_command): Likewise.
2575 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
2577 * probe.h (struct probe_ops) <get_probes>: Change parameter from
2579 * probe.c (parse_probes_in_pspace): Update.
2580 (find_probes_in_objfile): Update.
2581 (find_probe_by_pc): Update.
2582 (collect_probes): Update.
2583 (probe_any_get_probes): Update.
2584 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
2585 return type to reference to std::vector.
2586 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
2587 std::vector and update.
2588 (dtrace_process_dof): Likewise.
2589 (dtrace_get_probes): Likewise.
2590 * elfread.c (elf_get_probes): Change return type to std::vector,
2591 store an std::vector in bfd_data.
2592 (probe_key_free): Update to std::vector.
2593 * stap-probe.c (handle_stap_probe): Change parameter to
2594 std::vector and update.
2595 (stap_get_probes): Likewise.
2596 * symfile-debug.c (debug_sym_get_probes): Change return type to
2597 std::vector and update.
2599 2017-09-11 Tom Tromey <tom@tromey.com>
2601 * breakpoint.c (program_breakpoint_here_p): Update.
2602 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
2603 from make_show_memory_breakpoints_cleanup. Return a
2604 scoped_restore_tmpl<int>.
2605 (restore_show_memory_breakpoints): Remove.
2606 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
2607 * mem-break.c (memory_validate_breakpoint): Update.
2608 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
2609 (ia64_memory_remove_breakpoint): Update.
2610 (ia64_breakpoint_from_pc): Update.
2611 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
2612 from make_show_memory_breakpoints_cleanup.
2614 2017-09-11 Tom Tromey <tom@tromey.com>
2616 * d-namespace.c (d_lookup_symbol): Use std::string.
2617 (find_symbol_in_baseclass): Likewise.
2619 2017-09-11 Tom Tromey <tom@tromey.com>
2621 * ctf.c (ctf_start): Use std::string.
2623 2017-09-11 Tom Tromey <tom@tromey.com>
2625 * ada-lang.c (is_known_support_routine): Update.
2626 (ada_unhandled_exception_name_addr_from_raise): Update.
2627 * guile/scm-frame.c (gdbscm_frame_name): Update.
2628 * python/py-frame.c (frapy_name): Update.
2629 (frapy_function): Update.
2630 * stack.h (find_frame_funname): Update.
2631 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
2632 (print_frame): Update.
2634 2017-09-11 Tom Tromey <tom@tromey.com>
2636 * findcmd.c (put_bits): Take a gdb::byte_vector.
2637 (parse_find_args): Return gdb::byte_vector. "args" now const.
2638 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
2640 (find_command): Update.
2642 2017-09-11 Tom Tromey <tom@tromey.com>
2644 * cli/cli-script.c (class scoped_restore_hook_in): New.
2645 (clear_hook_in_cleanup): Remove.
2646 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
2647 scoped_restore_hook_in.
2649 2017-09-11 Tom Tromey <tom@tromey.com>
2651 * cli/cli-script.c (restore_interp): Remove.
2652 (read_command_lines): Use scoped_restore_interp.
2653 * interps.c (scoped_restore_interp::set_temp): Rename from
2655 * interps.h (class scoped_restore_interp): New.
2656 (interp_set_temp): Remove.
2658 2017-09-11 Tom Tromey <tom@tromey.com>
2660 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
2661 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
2662 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
2664 (mi_cmd_break_insert_1): Update.
2665 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
2668 2017-09-11 Tom Tromey <tom@tromey.com>
2670 * demangle.c (demangle_command): Update.
2671 * breakpoint.c (disable_command): Update.
2672 (enable_command): Update.
2673 (find_location_by_number): Make "number" const. Use
2675 * cli/cli-utils.c (extract_arg): Return std::string.
2676 * probe.c (parse_probe_linespec): Update. Change types.
2677 (collect_probes): Take string arguments.
2678 (parse_probe_linespec): Likewise.
2679 (info_probes_for_ops): Update.
2680 (enable_probes_command): Update.
2681 (disable_probes_command): Update.
2682 * break-catch-sig.c (catch_signal_split_args): Update.
2683 * mi/mi-parse.c (mi_parse): Update.
2685 2017-09-11 Tom Tromey <tom@tromey.com>
2687 * language.h (language_enum): Make argument const.
2688 * language.c (language_enum): Make argument const.
2690 2017-09-11 Tom Tromey <tom@tromey.com>
2692 * common/common-utils.h (skip_to_space): Remove macro, redeclare
2694 (skip_to_space): Rename from skip_to_space_const.
2695 * common/common-utils.c (skip_to_space): New function.
2696 (skip_to_space): Rename from skip_to_space_const.
2697 * cli/cli-utils.h (get_number): Rename from get_number_const.
2698 (extract_arg): Rename from extract_arg_const.
2699 * cli/cli-utils.c (get_number): Rename from get_number_const.
2700 (extract_arg): Rename from extract_arg_const.
2701 (number_or_range_parser::get_number): Use ::get_number.
2702 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
2703 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
2704 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
2705 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
2706 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
2707 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
2708 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
2709 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
2711 2017-09-11 Tom Tromey <tom@tromey.com>
2713 * python/python.c (do_start_initialization): Use
2714 py-event-types.def to initialize types.
2715 Define all object type structures.
2716 * python/python-internal.h: Don't declare event initialization
2718 * python/py-threadevent.c (thread_event_object_type): Don't
2720 * python/py-stopevent.c (stop_event_object_type): Don't define.
2721 * python/py-signalevent.c (signal_event_object_type): Don't
2723 * python/py-newobjfileevent.c (new_objfile_event_object_type)
2724 (clear_objfiles_event_object_type): Don't declare or define.
2725 * python/py-infevents.c (inferior_call_pre_event_object_type)
2726 (inferior_call_post_event_object_type)
2727 (register_changed_event_object_type)
2728 (memory_changed_event_object_type): Don't declare or define.
2729 * python/py-inferior.c (new_thread_event_object_type)
2730 (new_inferior_event_object_type)
2731 (inferior_deleted_event_object_type): Don't declare or define.
2732 * python/py-exitedevent.c (exited_event_object_type): Don't
2734 * python/py-evts.c (gdbpy_initialize_py_events): Use
2736 * python/py-events.h (thread_event_object_type): Don't declare.
2737 (events_object): Use py-all-events.def.
2738 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
2740 * python/py-event-types.def: New file.
2741 * python/py-continueevent.c (create_continue_event_object): Don't
2743 * python/py-bpevent.c (breakpoint_event_object_type): Don't
2745 * python/py-all-events.def: New file.
2747 2017-09-11 Tom Tromey <tom@tromey.com>
2749 * python/py-threadevent.c (create_thread_event_object): Return
2751 * python/py-stopevent.h (create_stop_event_object)
2752 (create_breakpoint_event_object, create_signal_event_object):
2754 * python/py-stopevent.c (create_stop_event_object): Return
2756 (emit_stop_event): Update.
2757 * python/py-signalevent.c (create_signal_event_object): Return
2759 * python/py-infevents.c (create_inferior_call_event_object):
2761 * python/py-event.h (create_event_object)
2762 (create_thread_event_object): Update.
2763 * python/py-event.c (create_event_object): Return gdbpy_ref.
2764 * python/py-continueevent.c: Return gdbpy_ref.
2765 * python/py-bpevent.c (create_breakpoint_event_object): Return
2768 2017-09-11 Tom Tromey <tom@tromey.com>
2772 * python/python.c (do_start_initialization): Initialize new event
2774 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
2775 (gdbpy_initialize_inferior_deleted_event)
2776 (gdbpy_initialize_new_thread_event): Declare.
2777 * python/py-threadevent.c (create_thread_event_object): Add option
2779 * python/py-inferior.c (new_thread_event_object_type)
2780 (new_inferior_event_object_type)
2781 (inferior_deleted_event_object_type): Declare.
2782 (python_new_inferior, python_inferior_deleted): New functions.
2783 (add_thread_object): Emit new_thread event.
2784 (gdbpy_initialize_inferior): Attach new functions to corresponding
2786 (new_thread, new_inferior, inferior_deleted): Define new event
2788 * python/py-evts.c (gdbpy_initialize_py_events): Add new
2790 * python/py-events.h (events_object) <new_inferior,
2791 inferior_deleted, new_thread>: New fields.
2792 * python/py-event.h (create_thread_event_breakpoint): Add optional
2795 2017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
2797 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
2798 check current_ui instead.
2799 (internal_vproblem): Likewise.
2801 2017-09-09 Simon Marchi <simon.marchi@ericsson.com>
2803 * thread.c (print_thread_info_1): Remove unnecessary calls to
2804 uiout->is_mi_like_p.
2806 2017-09-09 Tom Tromey <tom@tromey.com>
2808 * namespace.h (add_using_directive): Update.
2809 * namespace.c (add_using_directive): Change type of excludes to
2811 * dwarf2read.c (read_import_statement): Use std::vector.
2812 (read_namespace): Update.
2813 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
2815 2017-09-09 Tom Tromey <tom@tromey.com>
2817 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
2819 2017-09-09 Tom Tromey <tom@tromey.com>
2821 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
2823 2017-09-09 Tom Tromey <tom@tromey.com>
2825 * stack.c (func_command): Use gdb::def_vector.
2827 2017-09-09 Tom Tromey <tom@tromey.com>
2829 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
2830 ui_out_emit_list, ui_out_emit_tuple.
2831 (mi_cmd_var_update): Likewise.
2833 2017-09-09 Tom Tromey <tom@tromey.com>
2835 * mi/mi-interp.c (mi_user_selected_context_changed): Use
2836 ui_out_redirect_pop.
2837 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
2838 ui_out_redirect_pop.
2839 * utils.c (do_ui_out_redirect_pop)
2840 (make_cleanup_ui_out_redirect_pop): Remove.
2841 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
2842 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
2843 * ui-out.h (ui_out_redirect_pop): New class.
2845 2017-09-09 Tom Tromey <tom@tromey.com>
2847 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
2848 (list_available_thread_groups, mi_cmd_list_thread_groups)
2849 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
2850 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
2853 2017-09-09 Tom Tromey <tom@tromey.com>
2855 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
2858 2017-09-09 Tom Tromey <tom@tromey.com>
2860 * target.c (flash_erase_command): Use ui_out_emit_tuple.
2861 * stack.c (print_frame): Use ui_out_emit_tuple.
2862 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
2863 (info_spu_mailbox_command, info_spu_dma_command)
2864 (info_spu_proxydma_command): Likewise.
2865 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
2866 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
2867 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
2869 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
2871 2017-09-09 Tom Tromey <tom@tromey.com>
2873 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
2874 (class ui_out_emit_table): Update comment.
2875 * ui-out.c (do_cleanup_table_end)
2876 (make_cleanup_ui_out_table_begin_end): Remove.
2877 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
2878 (info_spu_dma_cmdlist): Likewise.
2879 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
2880 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
2883 2017-09-09 Tom Tromey <tom@tromey.com>
2885 * thread.c (print_thread_info_1): Use ui_out_emit_table,
2886 ui_out_emit_list, gdb::optional.
2888 2017-09-09 John Baldwin <jhb@FreeBSD.org>
2890 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
2892 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
2894 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
2896 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
2897 * ada-exp.y: Remove _initialize_ada_exp prototype.
2898 * ada-lang.c: Remove _initialize_ada_language prototype.
2899 * ada-tasks.c: Remove _initialize_tasks prototype.
2900 * addrmap.c: Remove _initialize_addrmap prototype.
2901 * agent.c: Remove _initialize_agent prototype.
2902 * aix-thread.c: Remove _initialize_aix_thread prototype.
2903 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
2904 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
2905 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
2907 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
2908 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
2909 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
2910 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
2912 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
2914 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
2915 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
2916 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
2917 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
2919 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
2920 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
2921 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
2922 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
2923 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
2924 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
2925 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
2927 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
2929 * annotate.c: Remove _initialize_annotate prototype.
2930 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
2931 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
2932 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
2933 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
2934 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
2935 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
2936 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
2937 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
2939 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
2940 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
2941 * auto-load.c: Remove _initialize_auto_load prototype.
2942 * auxv.c: Remove _initialize_auxv prototype.
2943 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
2944 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
2945 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
2946 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
2947 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
2948 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
2950 * break-catch-throw.c: Remove _initialize_break_catch_throw
2952 * breakpoint.c: Remove _initialize_breakpoint prototype.
2953 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
2954 * btrace.c: Remove _initialize_btrace prototype.
2955 * charset.c: Remove _initialize_charset prototype.
2956 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
2957 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
2958 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
2959 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
2960 * cli/cli-script.c: Remove _initialize_cli_script prototype.
2961 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
2962 * coffread.c: Remove _initialize_coffread prototype.
2963 * compile/compile.c: Remove _initialize_compile prototype.
2964 * complaints.c: Remove _initialize_complaints prototype.
2965 * completer.c: Remove _initialize_completer prototype.
2966 * copying.awk: Remove _initialize_copying prototype.
2967 * copying.c: Regenerate.
2968 * core-regset.c: Remove _initialize_core_regset prototype.
2969 * corefile.c: Remove _initialize_core prototype.
2970 * corelow.c: Remove _initialize_corelow prototype.
2971 * cp-abi.c: Remove _initialize_cp_abi prototype.
2972 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
2973 * cp-support.c: Remove _initialize_cp_support prototype.
2974 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
2975 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
2976 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
2977 * ctf.c: Remove _initialize_ctf prototype.
2978 * d-lang.c: Remove _initialize_d_language prototype.
2979 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
2981 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
2982 * dbxread.c: Remove _initialize_dbxread prototype.
2983 * dcache.c: Remove _initialize_dcache prototype.
2984 * demangle.c: Remove _initialize_demangler prototype.
2985 * disasm-selftests.c: Remove _initialize_disasm_selftests
2987 * disasm.c: Remove _initialize_disasm prototype.
2988 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
2989 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
2990 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
2992 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
2993 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
2994 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
2995 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
2996 * elfread.c: Remove _initialize_elfread prototype.
2997 * exec.c: Remove _initialize_exec prototype.
2998 * extension.c: Remove _initialize_extension prototype.
2999 * f-lang.c: Remove _initialize_f_language prototype.
3000 * f-valprint.c: Remove _initialize_f_valprint prototype.
3001 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
3002 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
3003 * filesystem.c: Remove _initialize_filesystem prototype.
3004 * findcmd.c: Remove _initialize_mem_search prototype.
3005 * fork-child.c: Remove _initialize_fork_child prototype.
3006 * frame-base.c: Remove _initialize_frame_base prototype.
3007 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
3008 * frame.c: Remove _initialize_frame prototype.
3009 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
3010 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
3011 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
3012 * gcore.c: Remove _initialize_gcore prototype.
3013 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
3014 * gdbarch.c: Regenerate.
3015 * gdbarch.sh: Remove _initialize_gdbarch prototype.
3016 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
3017 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
3018 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
3019 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
3020 * go-lang.c: Remove _initialize_go_language prototype.
3021 * go32-nat.c: Remove _initialize_go32_nat prototype.
3022 * guile/guile.c: Remove _initialize_guile prototype.
3023 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
3024 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
3025 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
3026 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
3027 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
3028 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
3029 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
3030 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
3031 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
3032 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
3034 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
3036 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
3037 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
3038 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
3039 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
3040 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
3041 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
3042 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
3043 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
3044 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
3045 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
3046 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
3047 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
3048 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
3049 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
3050 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
3051 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
3053 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
3055 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
3056 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
3057 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
3058 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
3059 * infcall.c: Remove _initialize_infcall prototype.
3060 * infcmd.c: Remove _initialize_infcmd prototype.
3061 * inferior.c: Remove _initialize_inferiors prototype.
3062 * inflow.c: Remove _initialize_inflow prototype.
3063 * infrun.c: Remove _initialize_infrun prototype.
3064 * interps.c: Remove _initialize_interpreter prototype.
3065 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
3066 * jit.c: Remove _initialize_jit prototype.
3067 * language.c: Remove _initialize_language prototype.
3068 * linux-fork.c: Remove _initialize_linux_fork prototype.
3069 * linux-nat.c: Remove _initialize_linux_nat prototype.
3070 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
3071 * linux-thread-db.c: Remove _initialize_thread_db prototype.
3072 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
3073 * m2-lang.c: Remove _initialize_m2_language prototype.
3074 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
3075 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
3076 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
3077 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
3078 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
3079 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
3080 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
3081 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
3082 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
3083 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
3084 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
3085 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
3086 * machoread.c: Remove _initialize_machoread prototype.
3087 * macrocmd.c: Remove _initialize_macrocmd prototype.
3088 * macroscope.c: Remove _initialize_macroscope prototype.
3089 * maint.c: Remove _initialize_maint_cmds prototype.
3090 * mdebugread.c: Remove _initialize_mdebugread prototype.
3091 * memattr.c: Remove _initialize_mem prototype.
3092 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
3093 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
3094 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
3095 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
3096 * mi/mi-main.c: Remove _initialize_mi_main prototype.
3097 * microblaze-linux-tdep.c: Remove
3098 _initialize_microblaze_linux_tdep prototype.
3099 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
3100 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
3101 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
3102 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
3103 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
3104 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
3105 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
3106 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
3107 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
3108 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
3109 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
3111 * mipsread.c: Remove _initialize_mipsread prototype.
3112 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
3114 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
3115 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
3116 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
3117 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
3118 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
3119 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
3121 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
3122 * nto-procfs.c: Remove _initialize_procfs prototype.
3123 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
3124 * objc-lang.c: Remove _initialize_objc_language prototype.
3125 * objfiles.c: Remove _initialize_objfiles prototype.
3126 * observer.c: Remove observer_test_first_notification_function,
3127 observer_test_second_notification_function,
3128 observer_test_third_notification_function, and
3129 _initialize_observer prototypes.
3130 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
3131 * osabi.c: Remove _initialize_gdb_osabi prototype.
3132 * osdata.c: Remove _initialize_osdata prototype.
3133 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
3134 * parse.c: Remove _initialize_parse prototype.
3135 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
3136 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
3137 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
3138 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
3139 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
3140 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
3141 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
3142 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
3143 * printcmd.c: Remove _initialize_printcmd prototype.
3144 * probe.c: Remove _initialize_probe prototype.
3145 * proc-api.c: Remove _initialize_proc_api prototype.
3146 * proc-events.c: Remove _initialize_proc_events prototype.
3147 * proc-service.c: Remove _initialize_proc_service prototype.
3148 * procfs.c: Remove _initialize_procfs prototype.
3149 * psymtab.c: Remove _initialize_psymtab prototype.
3150 * python/python.c: Remove _initialize_python prototype.
3151 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
3152 * record-btrace.c: Remove _initialize_record_btrace prototype.
3153 * record-full.c: Remove _initialize_record_full prototype.
3154 * record.c: Remove _initialize_record prototype.
3155 * regcache.c: Remove _initialize_regcache prototype.
3156 * reggroups.c: Remove _initialize_reggroup prototype.
3157 * remote-notif.c: Remove _initialize_notif prototype.
3158 * remote-sim.c: Remove _initialize_remote_sim prototype.
3159 * remote.c: Remove _initialize_remote prototype.
3160 * reverse.c: Remove _initialize_reverse prototype.
3161 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
3162 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
3163 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
3165 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
3166 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
3167 * rust-exp.y: Remove _initialize_rust_exp prototype.
3168 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
3169 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
3170 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
3171 * score-tdep.c: Remove _initialize_score_tdep prototype.
3172 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
3174 * ser-go32.c: Remove _initialize_ser_dos prototype.
3175 * ser-mingw.c: Remove _initialize_ser_windows prototype.
3176 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
3177 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
3178 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
3179 * serial.c: Remove _initialize_serial prototype.
3180 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
3181 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
3182 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
3183 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
3184 * skip.c: Remove _initialize_step_skip prototype.
3185 * sol-thread.c: Remove _initialize_sol_thread prototype.
3186 * solib-aix.c: Remove _initialize_solib_aix prototype.
3187 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
3188 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
3189 * solib-frv.c: Remove _initialize_frv_solib prototype.
3190 * solib-spu.c: Remove _initialize_spu_solib prototype.
3191 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
3192 * solib-target.c: Remove _initialize_solib_target prototype.
3193 * solib.c: Remove _initialize_solib prototype.
3194 * source.c: Remove _initialize_source prototype.
3195 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
3196 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
3198 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
3199 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
3200 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
3201 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
3203 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
3204 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
3205 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
3206 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
3208 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
3210 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
3212 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
3214 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
3215 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
3217 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
3219 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
3221 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
3223 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
3225 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
3226 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
3227 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
3228 * stabsread.c: Remove _initialize_stabsread prototype.
3229 * stack.c: Remove _initialize_stack prototype.
3230 * stap-probe.c: Remove _initialize_stap_probe prototype.
3231 * std-regs.c: Remove _initialize_frame_reg prototype.
3232 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
3233 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
3234 * symfile.c: Remove _initialize_symfile prototype.
3235 * symmisc.c: Remove _initialize_symmisc prototype.
3236 * symtab.c: Remove _initialize_symtab prototype.
3237 * target-dcache.c: Remove _initialize_target_dcache prototype.
3238 * target-descriptions.c: Remove _initialize_target_descriptions
3240 * thread.c: Remove _initialize_thread prototype.
3241 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
3243 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
3244 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
3245 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
3247 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
3248 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
3249 * tracefile.c: Remove _initialize_tracefile prototype.
3250 * tracepoint.c: Remove _initialize_tracepoint prototype.
3251 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
3252 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
3253 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
3254 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
3255 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
3256 * tui/tui-win.c: Remove _initialize_tui_win prototype.
3257 * tui/tui.c: Remove _initialize_tui prototype.
3258 * typeprint.c: Remove _initialize_typeprint prototype.
3259 * user-regs.c: Remove _initialize_user_regs prototype.
3260 * utils.c: Remove _initialize_utils prototype.
3261 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
3262 * valarith.c: Remove _initialize_valarith prototype.
3263 * valops.c: Remove _initialize_valops prototype.
3264 * valprint.c: Remove _initialize_valprint prototype.
3265 * value.c: Remove _initialize_values prototype.
3266 * varobj.c: Remove _initialize_varobj prototype.
3267 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
3268 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
3269 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
3270 * windows-nat.c: Remove _initialize_windows_nat,
3271 _initialize_check_for_gdb_ini, and _initialize_loadable
3273 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
3274 * xcoffread.c: Remove _initialize_xcoffread prototype.
3275 * xml-support.c: Remove _initialize_xml_support prototype.
3276 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
3277 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
3279 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
3281 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
3283 2017-09-08 Keith Seitz <keiths@redhat.com>
3285 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
3288 2017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
3290 * f-valprint.c (f_val_print): Remove check for one byte
3291 sized integers. Remove printing of character type.
3293 2017-09-08 Frank Penczek <frank.penczek@intel.com>
3294 Christoph Weinmann <christoph.t.weinmann@intel.com>
3295 Bernhard Heckel <bernhard.heckel@intel.com>
3297 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
3298 to maintain proper indentation when printing pointers/refs.
3300 2017-09-07 Joel Brobecker <brobecker@adacore.com>
3304 2017-09-07 Joel Brobecker <brobecker@adacore.com>
3306 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
3308 2017-09-05 Tom Tromey <tom@tromey.com>
3310 * parse.c (funcall_chain): Now a std::vector.
3311 (start_arglist, end_arglist): Simplify.
3312 (free_funcalls): Remove.
3313 (parse_exp_in_context_1): Remove cleanup.
3315 2017-09-05 Tom Tromey <tom@tromey.com>
3317 * go-exp.y (go_parse): Don't create a cleanup.
3319 2017-09-05 Tom Tromey <tom@tromey.com>
3321 * d-exp.y (PrimaryExpression): Use std::string.
3322 (d_parse): Don't create a cleanup.
3324 2017-09-05 Tom Tromey <tom@tromey.com>
3326 * utils.c (do_clear_parser_state): Remove.
3327 (make_cleanup_clear_parser_state): Remove.
3328 * p-exp.y (pascal_parse): Use scoped_restore.
3329 * m2-exp.y (m2_parse): Use scoped_restore.
3330 * f-exp.y (f_parse): Use scoped_restore.
3331 * d-exp.y (d_parse): Use scoped_restore.
3332 * c-exp.y (c_parse): Use scoped_restore.
3333 * ada-exp.y (ada_parse): Use scoped_restore.
3334 * utils.h (make_cleanup_clear_parser_state): Remove.
3336 2017-09-06 Keith Seitz <keiths@redhat.com>
3338 * dwarf2read.c (dw2_linkage_name_attr): New function.
3339 (dw2_linkage_name): New function.
3340 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
3341 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
3342 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
3344 2017-09-06 Kamil Rytarowski <n54@gmx.com>
3346 * config/djgpp/djconfig.sh: Correct shell portability issue.
3348 2017-09-06 Kamil Rytarowski <n54@gmx.com>
3350 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
3352 2017-09-06 John Baldwin <jhb@FreeBSD.org>
3354 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
3355 * NEWS: Mention new FreeBSD/mips native configuration.
3356 * configure.host: Add aarch64*-*-freebsd*.
3357 * configure.nat: Likewise.
3358 * aarch64-fbsd-nat.c: New file.
3360 2017-09-06 John Baldwin <jhb@FreeBSD.org>
3362 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
3363 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
3364 * NEWS: Mention new FreeBSD/aarch64 target.
3365 * configure.tgt: Add aarch64*-*-freebsd*.
3366 * aarch64-fbsd-tdep.c: New file.
3367 * aarch64-fbsd-tdep.h: New file.
3369 2017-09-06 Kamil Rytarowski <n54@gmx.com>
3371 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
3373 2017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
3375 * parse.c (find_minsym_type_and_address): Don't relocate addresses
3378 2017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3380 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
3383 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
3385 * infrun.c (follow_exec): Call add_thread after
3386 target_find_description.
3388 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
3390 * infrun.c (handle_inferior_event_1): When exec'ing, read
3391 stop_pc after follow_exec.
3393 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
3395 * remote.c (process_g_packet): Update error message.
3397 2017-09-05 Yao Qi <yao.qi@linaro.org>
3399 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
3402 2017-09-05 Pedro Alves <palves@redhat.com>
3404 * eval.c (eval_call, evaluate_funcall): New functions, factored
3406 (evaluate_subexp_standard): ... this.
3408 2017-09-05 Yao Qi <yao.qi@linaro.org>
3410 * amd64-tdep.c (amd64_target_description): Create target
3412 (_initialize_amd64_tdep): Don't call functions
3413 initialize_tdesc_amd64_*. Add self tests.
3414 * arch/amd64.c (amd64_create_target_description): Add parameter
3415 is_linux. Call set_tdesc_osabi if is_linux is true.
3416 * arch/amd64.h (amd64_create_target_description): Update the
3418 * arch/i386.c (i386_create_target_description): Add parameter
3419 is_linux. Call set_tdesc_osabi if is_linux is true.
3420 * arch/i386.h (i386_create_target_description): Update
3422 * configure.tgt: Add i386.o to gdb_target_obs.
3423 * features/Makefile (XMLTOC): Remove i386/*.xml.
3424 * features/i386/amd64-avx-avx512.c: Remove.
3425 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
3426 * features/i386/amd64-avx-mpx.c: Remove.
3427 * features/i386/amd64-avx.c: Remove.
3428 * features/i386/amd64-mpx.c: Remove.
3429 * features/i386/amd64.c: Remove.
3430 * features/i386/i386-avx-avx512.c: Remove.
3431 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
3432 * features/i386/i386-avx-mpx.c: Remove.
3433 * features/i386/i386-avx.c: Remove.
3434 * features/i386/i386-mmx.c: Remove.
3435 * features/i386/i386-mpx.c: Remove.
3436 * features/i386/i386.c: Remove.
3437 * i386-tdep.c: Don't include features/i386/i386*.c., include
3438 target-descriptions.h and arch/i386.h.
3439 (i386_target_description): Create target descriptions.
3440 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
3441 functions. Do self tests.
3443 2017-09-05 Yao Qi <yao.qi@linaro.org>
3445 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
3446 * features/i386/amd64-avx-avx512-linux.c: Removed.
3447 * features/i386/amd64-avx-linux.c: Removed.
3448 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
3449 * features/i386/amd64-avx-mpx-linux.c: Removed.
3450 * features/i386/amd64-linux.c: Removed.
3451 * features/i386/amd64-mpx-linux.c: Removed.
3452 * features/i386/x32-avx-avx512-linux.c: Removed.
3453 * features/i386/x32-avx-linux.c: Removed.
3454 * features/i386/x32-linux.c: Removed.
3456 2017-09-05 Yao Qi <yao.qi@linaro.org>
3458 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
3460 (amd64_linux_read_description): Call
3461 amd64_create_target_description.
3462 * arch/amd64.c: New file.
3463 * arch/amd64.h: New file.
3464 * configure.tgt (x86_64-*-linux*): Append amd64.o.
3465 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
3467 2017-09-05 Yao Qi <yao.qi@linaro.org>
3469 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
3470 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
3471 (amd64_linux_read_description): Create target descriptions.
3472 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
3473 functions. Add unit tests.
3474 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
3476 * features/i386/64bit-avx.c: Generated.
3477 * features/i386/64bit-avx512.c: Generated.
3478 * features/i386/64bit-core.c: Generated.
3479 * features/i386/64bit-linux.c: Generated.
3480 * features/i386/64bit-mpx.c: Generated.
3481 * features/i386/64bit-pkeys.c: Generated.
3482 * features/i386/64bit-segments.c: Generated.
3483 * features/i386/64bit-sse.c: Generated.
3484 * features/i386/x32-core.c: Generated.
3485 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
3486 c files for amd64-linux and x32-linux.
3488 2017-09-05 Yao Qi <yao.qi@linaro.org>
3490 * amd64-linux-tdep.c (amd64_linux_read_description): New
3492 (amd64_linux_core_read_description): Call
3493 amd64_linux_read_description.
3494 (amd64_linux_init_abi): Likewise.
3495 (amd64_x32_linux_init_abi): Likewise.
3496 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
3497 * x86-linux-nat.c (x86_linux_read_description): Call
3498 amd64_linux_read_description.
3500 2017-09-05 Yao Qi <yao.qi@linaro.org>
3502 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
3505 2017-09-05 Yao Qi <yao.qi@linaro.org>
3507 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
3508 * features/i386/i386-avx-avx512-linux.c: Remove.
3509 * features/i386/i386-avx-linux.c: Remove.
3510 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
3511 * features/i386/i386-avx-mpx-linux.c: Remove.
3512 * features/i386/i386-linux.c: Remove.
3513 * features/i386/i386-mmx-linux.c: Remove.
3514 * features/i386/i386-mpx-linux.c: Remove.
3516 2017-09-05 Yao Qi <yao.qi@linaro.org>
3518 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
3519 (SFILES): Add arch/i386.c.
3520 (HFILES_NO_SRCDIR): Add arch/i386.h.
3521 * arch/i386.c: New file.
3522 * arch/i386.h: New file.
3523 * arch/tdesc.h (allocate_target_description): Declare.
3524 (set_tdesc_architecture): Declare.
3525 (set_tdesc_osabi): Declare.
3526 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
3527 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
3528 include arch/i386.h.
3529 (i386_linux_read_description): Remove code and call
3530 i386_create_target_description.
3531 (set_tdesc_architecture): New function.
3532 (set_tdesc_osabi): New function.
3533 * target-descriptions.h (allocate_target_description): Remove.
3535 2017-09-05 Yao Qi <yao.qi@linaro.org>
3537 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
3538 * target-descriptions.c (tdesc_create_feature): Likewise, and
3540 * features/i386/32bit-avx.c: Re-generated.
3541 * features/i386/32bit-avx512.c: Re-generated.
3542 * features/i386/32bit-core.c: Re-generated.
3543 * features/i386/32bit-linux.c: Re-generated.
3544 * features/i386/32bit-mpx.c: Re-generated.
3545 * features/i386/32bit-pkeys.c: Re-generated.
3546 * features/i386/32bit-sse.c: Re-generated.
3548 2017-09-05 Yao Qi <yao.qi@linaro.org>
3550 * regformats/regdef.h (struct reg): Override operator == and !=.
3552 2017-09-05 Yao Qi <yao.qi@linaro.org>
3554 * arch/tdesc.h: New file.
3555 * regformats/regdat.sh: Generate code using tdesc_create_reg.
3556 * target-descriptions.c: Update comments.
3557 * target-descriptions.h: Include "arch/tdesc.h". Remove the
3559 * features/i386/32bit-avx.c: Re-generated.
3560 * features/i386/32bit-avx512.c: Re-generated.
3561 * features/i386/32bit-core.c: Re-generated.
3562 * features/i386/32bit-linux.c: Re-generated.
3563 * features/i386/32bit-mpx.c: Re-generated.
3564 * features/i386/32bit-pkeys.c: Re-generated.
3565 * features/i386/32bit-sse.c: Re-generated.
3567 2017-09-05 Yao Qi <yao.qi@linaro.org>
3569 * regformats/regdat.sh: Update generated code.
3571 2017-09-05 Yao Qi <yao.qi@linaro.org>
3573 * regformats/regdat.sh: Adjust code order.
3575 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
3577 * expprint.c (dump_subexp_body_standard): Use constant format
3578 string in fprintf_filtered call.
3580 2017-09-04 John Baldwin <jhb@FreeBSD.org>
3582 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
3584 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
3586 2017-09-04 John Baldwin <jhb@FreeBSD.org>
3588 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
3590 2017-09-04 John Baldwin <jhb@FreeBSD.org>
3592 * bsd-kvm.o: Define _KMEMUSER.
3593 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
3594 * configure: Regenerate.
3596 2017-09-04 John Baldwin <jhb@FreeBSD.org>
3598 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
3599 * i386-fbsd-nat.c: Likewise.
3601 2017-09-04 John Baldwin <jhb@FreeBSD.org>
3603 * unittests/array-view-selftests.c: Add include of <array>.
3605 2017-09-04 John Baldwin <jhb@FreeBSD.org>
3607 * spu-tdep.c (flush_ea_cache): Add missing argument to
3608 call_function_by_hand.
3610 2017-09-04 Pedro Alves <palves@redhat.com>
3612 * NEWS (Safer support for debugging with no debug info): New.
3614 2017-09-04 Pedro Alves <palves@redhat.com>
3616 * c-exp.y (function_method, function_method_void): Add current
3617 instance flags to TYPE_INSTANCE.
3618 * dwarf2read.c (check_modifier): New.
3619 (compute_delayed_physnames): Assert that only C++ adds delayed
3620 physnames. Mark fn_fields as const/volatile depending on
3622 * eval.c (make_params): New type_instance_flags parameter. Use
3623 it as the new type's instance flags.
3624 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
3625 flags element and pass it to make_params.
3626 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
3627 instance flags element.
3628 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
3629 * gdbtypes.h: Include "enum-flags.h".
3630 (type_instance_flags): New enum-flags type.
3631 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
3632 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
3633 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
3634 (follow_type_instance_flags): New function.
3635 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
3636 * parser-defs.h (follow_type_instance_flags): Declare.
3637 * valops.c (value_struct_elt_for_reference): const/volatile must
3640 2017-09-04 Pedro Alves <palves@redhat.com>
3642 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
3643 function/method scopes; lookup the nested name as a function local
3646 2017-09-04 Pedro Alves <palves@redhat.com>
3648 (%type <voidval>): Add function_method.
3649 * c-exp.y (exp): New production for calls with no arguments.
3650 (function_method, function_method_void_or_typelist): New
3652 (exp): New production for "method()::static_var".
3653 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
3654 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
3655 Handle OP_FUNC_STATIC_VAR.
3656 * parse.c (operator_length_standard):
3657 Handle OP_FUNC_STATIC_VAR.
3659 2017-09-04 Pedro Alves <palves@redhat.com>
3661 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
3663 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
3665 * parse.c (operator_length_standard, operator_check_standard):
3667 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
3669 2017-09-04 Pedro Alves <palves@redhat.com>
3671 * ax-gdb.c: Include "typeprint.h".
3672 (gen_expr_for_cast): New function.
3673 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
3674 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
3676 * dwarf2read.c (new_symbol_full): Fallback to int instead of
3677 nodebug_data_symbol.
3678 * eval.c: Include "typeprint.h".
3679 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
3680 Error out if symbol has unknown type.
3681 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
3682 evaluate_subexp_for_cast.
3683 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
3685 (evaluate_subexp_for_cast): New function.
3686 * gdbtypes.c (init_nodebug_var_type): New function.
3687 (objfile_type): Use it to initialize types of variables with no
3689 * typeprint.c (error_unknown_type): New.
3690 * typeprint.h (error_unknown_type): New declaration.
3691 * compile/compile-c-types.c (convert_type_basic): Handle
3692 TYPE_CODE_ERROR; warn and fallback to int for variables with
3695 2017-09-04 Pedro Alves <palves@redhat.com>
3697 * eval.c (evaluate_var_value): New function, factored out from ...
3698 (evaluate_subexp_standard): ... here.
3700 2017-09-04 Pedro Alves <palves@redhat.com>
3702 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
3703 Remove useless assignments to 'op'.
3705 2017-09-04 Pedro Alves <palves@redhat.com>
3707 * eval.c (eval_skip_value): New function.
3708 (evaluate_subexp_standard): Use it.
3710 2017-09-04 Pedro Alves <palves@redhat.com>
3712 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
3713 function name from symbol/minsym and pass it to
3714 error_call_unknown_return_type.
3716 2017-09-04 Pedro Alves <palves@redhat.com>
3718 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
3719 * ax-gdb.c (gen_msym_var_ref): New function.
3720 (gen_expr): Handle OP_VAR_MSYM_VALUE.
3721 * eval.c (evaluate_var_msym_value): New function.
3722 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
3723 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
3724 to call_function_by_hand.
3725 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
3726 Handle OP_VAR_MSYM_VALUE.
3727 (union exp_element) <msymbol>: New field.
3728 * minsyms.h (struct type): Forward declare.
3729 (find_minsym_type_and_address): Declare.
3730 * parse.c (write_exp_elt_msym): New function.
3731 (write_exp_msymbol): Delete, refactored as ...
3732 (find_minsym_type_and_address): ... this new function.
3733 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
3734 (operator_length_standard, operator_check_standard): Handle
3736 * std-operator.def (OP_VAR_MSYM_VALUE): New.
3738 2017-09-04 Pedro Alves <palves@redhat.com>
3740 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
3741 TYPE_GNU_IFUNC specially here. Throw error if return type is
3743 * ada-typeprint.c (print_func_type): Handle functions with unknown
3745 * c-typeprint.c (c_type_print_base): Handle functions and methods
3746 with unknown return type.
3747 * compile/compile-c-symbols.c (convert_symbol_bmsym)
3748 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
3749 * compile/compile-c-types.c: Include "objfiles.h".
3750 (convert_func): For functions with unknown return type, warn and
3752 * compile/compile-object-run.c (compile_object_run): Adjust call
3753 to call_function_by_hand_dummy.
3754 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
3755 call_function_by_hand.
3756 * eval.c (evaluate_subexp_standard): Adjust calls to
3757 call_function_by_hand. Handle functions and methods with unknown
3758 return type. Pass expect_type to call_function_by_hand.
3759 * f-typeprint.c (f_type_print_base): Handle functions with unknown
3761 * gcore.c (call_target_sbrk): Adjust call to
3762 call_function_by_hand.
3763 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
3764 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
3765 an integer address type instead of nodebug.
3766 * guile/scm-value.c (gdbscm_value_call): Adjust call to
3767 call_function_by_hand.
3768 * infcall.c (error_call_unknown_return_type): New function.
3769 (call_function_by_hand): New "default_return_type" parameter.
3771 (call_function_by_hand_dummy): New "default_return_type"
3772 parameter. Use it instead of defaulting to int. If there's no
3773 default and the return type is unknown, throw an error. If
3774 there's a default return type, and the called function has no
3775 debug info, then assume the function is prototyped.
3776 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
3777 New "default_return_type" parameter.
3778 (error_call_unknown_return_type): New declaration.
3779 * linux-fork.c (call_lseek): Cast return type of lseek.
3780 (inferior_call_waitpid, checkpoint_command): Adjust calls to
3781 call_function_by_hand.
3782 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
3783 calls to call_function_by_hand.
3784 * m2-typeprint.c (m2_procedure): Handle functions with unknown
3786 * objc-lang.c (lookup_objc_class, lookup_child_selector)
3787 (value_nsstring, print_object_command): Adjust calls to
3788 call_function_by_hand.
3789 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
3790 functions with unknown return type.
3791 (pascal_type_print_func_varspec_suffix): New function.
3792 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
3793 TYPE_CODE_METHOD>: Use it.
3794 * python/py-value.c (valpy_call): Adjust call to
3795 call_function_by_hand.
3796 * rust-lang.c (rust_evaluate_funcall): Adjust call to
3797 call_function_by_hand.
3798 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
3799 call_function_by_hand.
3800 * valops.c (value_allocate_space_in_inferior): Adjust call to
3801 call_function_by_hand.
3802 * typeprint.c (type_print_unknown_return_type): New function.
3803 * typeprint.h (type_print_unknown_return_type): New declaration.
3805 2017-09-04 Pedro Alves <palves@redhat.com>
3807 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
3808 types with more than one parameter as prototyped.
3810 2017-09-04 Pedro Alves <palves@redhat.com>
3812 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
3813 (disassemble_command): Use gdb_disassembly_flags instead of bare
3815 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
3816 (dump_insns, do_mixed_source_and_assembly_deprecated)
3817 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
3818 Use gdb_disassembly_flags instead of bare int.
3819 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
3820 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
3821 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
3822 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
3823 (enum gdb_disassembly_flag): ... values of this new enumeration.
3824 (gdb_disassembly_flags): Define.
3826 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
3827 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
3828 gdb_disassembly_flags instead of bare int.
3829 * record-btrace.c (btrace_insn_history)
3830 (record_btrace_insn_history, record_btrace_insn_history_range)
3831 (record_btrace_insn_history_from): Use gdb_disassembly_flags
3832 instead of bare int.
3833 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
3834 Use gdb_disassembly_flags instead of bare int.
3835 * target-debug.h (target_debug_print_gdb_disassembly_flags):
3837 * target-delegates.c: Regenerate.
3838 * target.c (target_insn_history, target_insn_history_from)
3839 (target_insn_history_range): Use gdb_disassembly_flags instead of
3841 * target.h: Include "disasm.h".
3842 (struct target_ops) <to_insn_history, to_insn_history_from,
3843 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
3845 (target_insn_history, target_insn_history_from)
3846 (target_insn_history_range): Use gdb_disassembly_flags instead of
3849 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
3851 * cli/cli-script.c (build_command_line): For if/while commands,
3852 check whether args is empty.
3854 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
3856 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
3857 (enum command_control_type): Likewise.
3858 (struct command_line): Likewise.
3859 (free_command_lines): Likewise.
3860 (struct command_lines_deleter): Likewise.
3861 (command_line_up): Likewise.
3862 (read_command_lines): Likewise.
3863 (read_command_lines_1): Likewise.
3864 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
3865 (enum command_control_type): Likewise.
3866 (struct command_line): Likewise.
3867 (free_command_lines): Likewise.
3868 (struct command_lines_deleter): Likewise.
3869 (command_line_up): Likewise.
3870 (read_command_lines): Likewise.
3871 (read_command_lines_1): Likewise.
3872 * breakpoint.h: Include cli/cli-script.h.
3873 * extension-priv.h: Likewise.
3874 * gdbcmd.h: Likewise.
3876 2017-09-04 Pedro Alves <palves@redhat.com>
3878 * ada-lang.c (is_known_support_routine): Move sal declaration to
3879 where it is initialized.
3880 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
3881 (parse_breakpoint_sals, decode_static_tracepoint_spec)
3882 (clear_command, update_static_tracepoint): Remove init_sal
3883 references. Move declarations closer to initializations.
3884 * cli/cli-cmds.c (list_command): Move sal declarations closer to
3886 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
3887 references. Move sal declarations closer to initializations.
3888 * frame.c (find_frame_sal): Return a symtab_and_line via function
3889 return instead of output parameter. Remove init_sal references.
3890 * frame.h (find_frame_sal): Return a symtab_and_line via function
3891 return instead of output parameter.
3892 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
3893 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
3895 (gdbscm_find_pc_line): Remove init_sal reference.
3896 * infcall.c (call_function_by_hand_dummy): Remove init_sal
3897 references. Move declarations closer to initializations.
3898 * infcmd.c (set_step_frame): Update. Move declarations closer to
3900 (finish_backward): Remove init_sal references. Move declarations
3901 closer to initializations.
3902 * infrun.c (process_event_stop_test, handle_step_into_function)
3903 (insert_hp_step_resume_breakpoint_at_frame)
3904 (insert_step_resume_breakpoint_at_caller): Likewise.
3905 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
3906 (symbol_to_sal): Likewise.
3907 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
3908 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
3909 to its initialization.
3910 * reverse.c (save_bookmark_command): Use new/delete. Remove
3911 init_sal references. Move declarations closer to initializations.
3912 * source.c (get_current_source_symtab_and_line): Remove brace
3914 (set_current_source_symtab_and_line): Now takes the sal by const
3915 reference. Remove brace initialization.
3916 (line_info): Remove init_sal reference.
3917 * source.h (set_current_source_symtab_and_line): Now takes a
3918 symtab_and_line via const reference.
3919 * stack.c (set_current_sal_from_frame): Adjust.
3920 (print_frame_info): Adjust.
3921 (get_last_displayed_sal): Return the sal via function return
3922 instead of via output parameter. Simplify.
3923 (frame_info): Adjust.
3924 * stack.h (get_last_displayed_sal): Return the sal via function
3925 return instead of via output parameter.
3926 * symtab.c (init_sal): Delete.
3927 (find_pc_sect_line): Remove init_sal references. Move
3928 declarations closer to initializations.
3929 (find_function_start_sal): Remove init_sal references. Move
3930 declarations closer to initializations.
3931 * symtab.h (struct symtab_and_line): In-class initialize all
3933 * tracepoint.c (set_traceframe_context)
3934 (print_one_static_tracepoint_marker): Remove init_sal references.
3935 Move declarations closer to initializations.
3936 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
3937 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
3938 declarations closer to initializations.
3939 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
3940 init_sal references. Adjust.
3942 2017-09-04 Pedro Alves <palves@redhat.com>
3944 * ax-gdb.c (agent_command_1): Use range-for.
3945 * break-catch-throw.c (re_set_exception_catchpoint): Update.
3946 * breakpoint.c: Include "common/array-view.h".
3947 (init_breakpoint_sal, create_breakpoint_sal): Change sals
3948 parameter from struct symtabs_and_lines to
3949 array_view<symtab_and_line>. Adjust. Use range-for. Update.
3950 (breakpoint_sals_to_pc): Change sals parameter from struct
3951 symtabs_and_lines to std::vector reference.
3952 (check_fast_tracepoint_sals): Change sals parameter from struct
3953 symtabs_and_lines to std::array_view. Use range-for.
3954 (decode_static_tracepoint_spec): Return a std::vector instead of
3955 symtabs_and_lines. Update.
3956 (create_breakpoint): Update.
3957 (break_range_command, until_break_command, clear_command): Update.
3958 (base_breakpoint_decode_location, bkpt_decode_location)
3959 (bkpt_probe_create_sals_from_location)
3960 (bkpt_probe_decode_location, tracepoint_decode_location)
3961 (tracepoint_probe_decode_location)
3962 (strace_marker_create_sals_from_location): Return a std::vector
3963 instead of symtabs_and_lines.
3964 (strace_marker_create_breakpoints_sal): Update.
3965 (strace_marker_decode_location): Return a std::vector instead of
3966 symtabs_and_lines. Update.
3967 (update_breakpoint_locations): Change struct symtabs_and_lines
3968 parameters to gdb::array_view. Adjust.
3969 (location_to_sals): Return a std::vector instead of
3970 symtabs_and_lines. Update.
3971 (breakpoint_re_set_default): Use std::vector instead of struct
3973 (decode_location_default): Return a std::vector instead of
3974 symtabs_and_lines. Update.
3975 * breakpoint.h: Include "common/array-view.h".
3976 (struct breakpoint_ops) <decode_location>: Now returns a
3977 std::vector instead of returning a symtabs_and_lines via output
3979 (update_breakpoint_locations): Change sals parameters to use
3981 * cli/cli-cmds.c (edit_command, list_command): Update to use
3982 std::vector and gdb::array_view.
3983 (ambiguous_line_spec): Adjust to use gdb::array_view and
3985 (compare_symtabs): Rename to ...
3986 (cmp_symtabs): ... this. Change parameters to symtab_and_line
3987 const reference and adjust.
3988 (filter_sals): Rewrite using std::vector and standard algorithms.
3989 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
3990 (jump_command): Update to use std::vector.
3991 * linespec.c (struct linespec_state) <canonical_names>: Update
3993 (add_sal_to_sals_basic): Delete.
3994 (add_sal_to_sals, filter_results, convert_results_to_lsals)
3995 (decode_line_2, create_sals_line_offset)
3996 (convert_address_location_to_sals, convert_linespec_to_sals)
3997 (convert_explicit_location_to_sals, parse_linespec)
3998 (event_location_to_sals, decode_line_full, decode_line_1)
3999 (decode_line_with_current_source)
4000 (decode_line_with_last_displayed, decode_objc)
4001 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
4002 (linespec_result::~linespec_result): Adjust to use std::vector
4003 instead of symtabs_and_lines.
4004 * linespec.h (linespec_sals::sals): Now a std::vector.
4005 (struct linespec_result): Use std::vector, bool, and in-class
4007 (decode_line_1, decode_line_with_current_source)
4008 (decode_line_with_last_displayed): Return std::vector.
4009 * macrocmd.c (info_macros_command): Use std::vector.
4010 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
4011 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
4013 * probe.h (parse_probes): Return a std::vector.
4014 * python/python.c (gdbpy_decode_line): Use std::vector and
4016 * source.c (select_source_symtab, line_info): Use std::vector.
4017 * stack.c (func_command): Use std::vector.
4018 * symtab.h (struct symtabs_and_lines): Delete.
4019 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
4021 2017-09-04 Pedro Alves <palves@redhat.com>
4023 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4024 unittests/array-view-selftests.c.
4025 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
4026 * common/array-view.h: New file.
4027 * unittests/array-view-selftests.c: New file.
4029 2017-09-04 Pedro Alves <palves@redhat.com>
4031 * cli/cli-cmds.c (edit_command): Pass message to
4032 ambiguous_line_spec.
4033 (list_command): Pass message to ambiguous_line_spec. Say
4034 "first"/"last" instead of "start" and "end" to be consistent with
4036 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
4037 them to print formatted message.
4039 2017-09-04 Pedro Alves <palves@redhat.com>
4041 * btrace.c (ftrace_add_pt): Pass btrace_insn to
4042 ftrace_update_insns by reference instead of pointer.
4044 2017-09-04 Yao Qi <yao.qi@linaro.org>
4046 * i386-go32-tdep.c: Include x86-xstate.h.
4047 (i386_go32_init_abi): Call i386_target_description.
4048 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
4049 if xcr0 is X86_XSTATE_X87_MASK.
4050 * i386-tdep.h (tdesc_i386): Remove the declaration.
4051 (tdesc_i386_mmx): Likewise.
4053 2017-09-04 Yao Qi <yao.qi@linaro.org>
4055 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
4056 X86_XSTATE_SSE_MASK instead of 0.
4058 2017-09-04 Yao Qi <yao.qi@linaro.org>
4060 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
4061 i386_target_description.
4062 * i386-fbsd-nat.c (i386fbsd_read_description): Call
4063 i386_target_description.
4064 * i386-tdep.c (i386_gdbarch_init): Likewise.
4066 2017-09-04 Yao Qi <yao.qi@linaro.org>
4068 * amd64-darwin-tdep.c: Include "x86-xstate.h".
4069 (x86_darwin_init_abi_64): Call amd64_target_description.
4070 * amd64-dicos-tdep.c: Likewise.
4071 * amd64-fbsd-nat.c: Likewise.
4072 * amd64-fbsd-tdep.c: Likewise.
4073 * amd64-nbsd-tdep.c: Likewise.
4074 * amd64-obsd-tdep.c: Likewise.
4075 * amd64-sol2-tdep.c: Likewise.
4076 * amd64-windows-tdep.c: Likewise.
4077 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
4079 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
4081 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
4082 (btrace_function) <insn>: Change type to use std::vector.
4083 * btrace.c (ftrace_debug, ftrace_call_num_insn,
4084 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
4085 ftrace_update_insns, ftrace_compute_global_level_offset,
4086 btrace_stitch_bts, btrace_clear, btrace_insn_get,
4087 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
4088 change to std::vector.
4089 (ftrace_update_insns): Adjust to change to std::vector, change
4090 type of INSN parameter.
4091 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
4092 * record-btrace.c (btrace_call_history_insn_range,
4093 btrace_compute_src_line_range,
4094 record_btrace_frame_prev_register): Adjust to change to
4096 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
4097 to change to std::vector.
4099 2017-09-03 Tom Tromey <tom@tromey.com>
4101 * corefile.c (reopen_exec_file): Use std::string.
4103 2017-09-03 Tom Tromey <tom@tromey.com>
4105 * compile/compile.c (compile_register_name_mangled): Return
4107 * compile/compile-loc2c.c (pushf_register_address): Update.
4108 (pushf_register): Update.
4109 * compile/compile-c-types.c (convert_array): Update.
4110 * compile/compile-c-symbols.c (generate_vla_size): Update.
4111 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
4112 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
4113 (convert_one_symbol): Update.
4114 (generate_c_for_for_one_variable): Update.
4115 * compile/compile-c-support.c (c_get_range_decl_name): Return a
4117 (generate_register_struct): Update.
4118 * compile/compile-internal.h (c_get_range_decl_name): Return a
4120 (compile_register_name_mangled): Return std::string.
4122 2017-09-03 Tom Tromey <tom@tromey.com>
4124 * utils.c (perror_string): Return a std::string.
4125 (throw_perror_with_name, perror_warning_with_name): Update.
4127 2017-09-03 Tom Tromey <tom@tromey.com>
4129 * demangle.c (demangle_command): Use std::string,
4132 2017-09-03 Tom Tromey <tom@tromey.com>
4134 * cli/cli-setshow.c (do_set_command): Use std::string.
4136 2017-09-03 Tom Tromey <tom@tromey.com>
4138 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
4140 2017-09-03 Tom Tromey <tom@tromey.com>
4142 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
4144 2017-09-03 Tom Tromey <tom@tromey.com>
4146 * mi/mi-cmd-env.c (env_execute_cli_command): Use
4147 gdb::unique_xmalloc_ptr.
4149 2017-09-03 Tom Tromey <tom@tromey.com>
4151 * thread.c (print_thread_info_1): Use string_printf.
4152 (thread_apply_command, thread_apply_all_command): Use
4155 2017-09-03 Tom Tromey <tom@tromey.com>
4157 * valprint.c (val_print_string): Update.
4158 * gdbcore.h (memory_error_message): Return std::string.
4159 * corefile.c (memory_error_message): Return std::string.
4160 (memory_error): Update.
4161 * breakpoint.c (insert_bp_location): Update.
4163 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
4165 * target/waitstatus.h (target_waitstatus_to_string): Change
4166 return type to std::string.
4167 * target/waitstatus.c (target_waitstatus_to_string): Return
4169 * target.h (target_waitstatus_to_string): Remove declaration.
4170 * infrun.c (resume, clear_proceed_status_thread,
4171 print_target_wait_results, do_target_wait, save_waitstatus,
4172 stop_all_threads): Adjust.
4173 * record-btrace.c (record_btrace_wait): Adjust.
4175 (target_debug_print_struct_target_waitstatus_p): Adjust.
4177 2017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
4180 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
4183 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
4185 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
4186 for setting/unsetting environment variables on the remote target.
4187 (New remote packets): Add entries for QEnvironmentHexEncoded,
4188 QEnvironmentUnset and QEnvironmentReset.
4189 * common/environ.c (gdb_environ::operator=): Extend method to
4190 handle m_user_set_env_list and m_user_unset_env_list.
4191 (gdb_environ::clear): Likewise.
4192 (match_var_in_string): Change type of first parameter from 'char
4193 *' to 'const char *'.
4194 (gdb_environ::set): Extend method to handle
4195 m_user_set_env_list and m_user_unset_env_list.
4196 (gdb_environ::unset): Likewise.
4197 (gdb_environ::clear_user_set_env): New method.
4198 (gdb_environ::user_set_envp): Likewise.
4199 (gdb_environ::user_unset_envp): Likewise.
4200 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
4201 m_user_unset_env_list on move constructor/assignment.
4202 (unset): Add new default parameter 'update_unset_list = true'.
4203 (clear_user_set_env): New method.
4204 (user_set_envp): Likewise.
4205 (user_unset_envp): Likewise.
4206 (m_user_set_env_list): New std::set.
4207 (m_user_unset_env_list): Likewise.
4208 * common/rsp-low.c (hex2str): New function.
4209 (bin2hex): New overload for bin2hex function.
4210 * common/rsp-low.c (hex2str): New prototype.
4211 (str2hex): New overload prototype.
4212 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
4213 QEnvironmentUnset and QEnvironmentReset.
4214 (remote_protocol_features): Add QEnvironmentHexEncoded,
4215 QEnvironmentUnset and QEnvironmentReset packets.
4216 (send_environment_packet): New function.
4217 (extended_remote_environment_support): Likewise.
4218 (extended_remote_create_inferior): Call
4219 extended_remote_environment_support.
4220 (_initialize_remote): Add QEnvironmentHexEncoded,
4221 QEnvironmentUnset and QEnvironmentReset packet configs.
4222 * unittests/environ-selftests.c (gdb_selftest_env_var):
4224 (test_vector_initialization): New function.
4225 (test_init_from_host_environ): Likewise.
4226 (test_reinit_from_host_environ): Likewise.
4227 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
4229 (test_unset_set_empty_vector): Likewise.
4230 (test_vector_clear): Likewise.
4231 (test_std_move): Likewise.
4232 (test_move_constructor):
4233 (test_self_move): Likewise.
4234 (test_set_unset_reset): Likewise.
4235 (run_tests): Rewrite in terms of the functions above.
4237 2017-08-31 Weimin Pan <weimin.pan@oracle.com>
4239 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
4240 (adi_available): Use a temp variable of type CORE_ADDR as argument
4241 3 when calling target_auxv_search.
4242 (adi_normalize_address): Use masks and xor operators to calculate
4244 (adi_read_versions, adi_write_versions, adi_print_versions)
4245 (do_examine, do_assign): Use paddress.
4247 2017-08-29 John Baldwin <jhb@FreeBSD.org>
4249 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
4250 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
4251 out of loop and add supply of FIR.
4252 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
4255 2017-08-28 Simon Marchi <simon.marchi@ericsson.com>
4258 * cli/cli-script.c (define_command): Don't convert command name
4261 2017-08-25 Joel Brobecker <brobecker@adacore.com>
4263 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
4264 Update all callers accordingly. Remove all code blocks handling
4265 the case where DISPP is not NULL.
4267 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
4270 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
4271 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
4272 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
4274 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
4276 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
4277 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
4278 (read_comp_units_from_section): New parameter abbrev_section, use
4279 read_and_check_comp_unit_head, allocate signatured_type if needed.
4280 (create_all_comp_units): Update read_comp_units_from_section caller.
4282 2017-08-23 Pedro Alves <palves@redhat.com>
4285 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
4286 to null_ptid and switch to thread without reading the registers
4287 after adding the inferior.
4289 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
4291 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
4293 * compile/compile.c (compile_gcc, show_compile_gcc): New.
4294 (compile_to_object): Implement compile_gcc.
4295 (_initialize_compile): Install "set compile-gcc". Initialize
4298 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
4300 * compile/compile.c (compile_to_object): Conditionally call
4301 set_verbose. Conditionally call compile or compile_v0.
4303 2017-08-07 Weimin Pan <weimin.pan@oracle.com>
4305 * sparc64-tdep.h: (adi_normalize_address): New export.
4306 * sparc-nat.h: (open_adi_tag_fd): New export.
4307 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
4308 * sparc64-linux-tdep.c:
4309 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
4310 (sparc64_linux_handle_segmentation_fault): New function.
4311 (sparc64_linux_init_abi): Register
4312 sparc64_linux_handle_segmentation_fault
4313 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
4314 (sparc64_addr_bits_remove): New function.
4315 (sparc64_init_abi): Register sparc64_addr_bits_remove.
4316 (MAX_PROC_NAME_SIZE): New macro.
4317 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
4318 (sparc64adilist): New variable.
4319 (adi_proc_list): New variable.
4320 (find_adi_info): New function.
4321 (add_adi_info): New function.
4322 (get_adi_info_proc): New function.
4323 (get_adi_info): New function.
4324 (info_adi_command): New function.
4325 (read_maps_entry): New function.
4326 (adi_available): New function.
4327 (adi_normalize_address): New function.
4328 (adi_align_address): New function.
4329 (adi_convert_byte_count): New function.
4330 (adi_tag_fd): New function.
4331 (adi_is_addr_mapped): New function.
4332 (adi_read_versions): New function.
4333 (adi_write_versions): New function.
4334 (adi_print_versions): New function.
4335 (do_examine): New function.
4336 (do_assign): New function.
4337 (adi_examine_command): New function.
4338 (adi_assign_command): New function.
4339 (_initialize_sparc64_adi_tdep): New function.
4341 2017-08-22 Simon Marchi <simon.marchi@ericsson.com>
4343 * breakpoint.c (breakpoints_info): Rename to ...
4344 (info_breakpoints_command): ... this.
4345 (watchpoints_info): Rename to ...
4346 (info_watchpoints_command): ... this.
4347 (tracepoints_info): Rename to ...
4348 (info_tracepoints_command): ... this.
4349 (_initialize_breakpoint): Adjust.
4350 * dcache.c (dcache_info): Rename to ...
4351 (info_display_command): ... this.
4352 (_initialize_dcache): Adjust.
4353 * frame.h (args_info): Rename to ...
4354 (info_args_command): ... this.
4355 (locals_info): Rename to ...
4356 (info_locals_command): ... this.
4357 * infcmd.c (nofp_registers_info): Rename to ...
4358 (info_registers_command): ... this.
4359 (float_info): Rename to ...
4360 (info_float_command): ... this.
4361 (program_info): Rename to ...
4362 (info_program_command): ... this.
4363 (all_registers_info): Rename to ...
4364 (info_all_registers_command): ... this.
4365 (vector_info): Rename to ...
4366 (info_vector_command): ... this.
4367 (float_info): Rename to ...
4368 (info_float_command): ... this.
4369 (_initialize_infcmd): Adjust.
4370 * inferior.h (term_info): Rename to ...
4371 (info_terminal_command): ... this.
4372 * inflow.c (term_info): Rename to ...
4373 (info_terminal_command): ... this.
4374 (_initialize_inflow): Adjust.
4375 * infrun.c (signals_info): Rename to ...
4376 (info_signals_command): ... this.
4377 (_initialize_infrun): Adjust.
4378 * objc-lang.c (classes_info): Rename to ...
4379 (info_classes_command): ... this.
4380 (selectors_info): Rename to ...
4381 (info_selectors_command): ... this.
4382 (_initialize_objc_language): Adjust.
4383 * printcmd.c (sym_info): Rename to ...
4384 (info_symbol_command): ... this.
4385 (address_info): Rename to ...
4386 (info_address_command): ... this.
4387 (display_info): Rename to ...
4388 (info_display_command): ... this.
4389 (_initialize_printcmd): Adjust.
4390 * reverse.c (bookmarks_info): Rename to ...
4391 (info_breakpoints_command): ... this.
4392 (_initialize_reverse): Adjust.
4393 * ser-go32.c (dos_info): Rename to ...
4394 (info_serial_command): ... this.
4395 (_initialize_ser_dos): Adjust.
4396 * skip.c (skip_info): Rename to ...
4397 (info_skip_command): ... this.
4398 (_initialize_step_skip): Adjust.
4399 * source.c (line_info): Rename to ...
4400 (info_line_command): ... this.
4401 (source_info): Rename to ...
4402 (info_source_command)
4403 * stack.c (frame_info): Rename to ...
4404 (info_frame_command): ... this.
4405 (locals_info): Rename to ...
4406 (info_locals_command): ... this.
4407 (args_info): Rename to ...
4408 (info_args_command): ... this.
4409 (_initialize_stack): Adjust.
4410 * symtab.c (sources_info): Rename to ...
4411 (info_sources_command): ... this.
4412 (variables_info): Rename to ...
4413 (info_variables_command): ... this.
4414 (functions_info): Rename to ...
4415 (info_functions_command): ... this.
4416 (types_info): Rename to ...
4417 (info_types_command): ... this.
4418 (_initialize_symtab): Adjust.
4419 * target.c (target_info): Rename to ...
4420 (info_target_command): ... this.
4421 (initialize_targets): Adjust.
4422 * tracepoint.c (tvariables_info): Rename to ...
4423 (info_tvariables_command): ... this.
4424 (scope_info): Rename to ...
4425 (info_scope_command): ... this.
4426 (trace_dump_actions): Adjust.
4427 (_initialize_tracepoint): Adjust.
4429 2017-08-22 Tom Tromey <tom@tromey.com>
4431 * breakpoint.h (install_breakpoint): Update.
4432 * breakpoint.c (add_solib_catchpoint): Update.
4433 (install_breakpoint): Change argument to a std::unique_ptr.
4434 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
4435 (create_breakpoint_sal, create_breakpoint): Update.
4436 (watch_command_1, catch_exec_command_1)
4437 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
4438 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
4439 Return the breakpoint.
4440 (set_raw_breakpoint_without_location, set_raw_breakpoint)
4441 (new_single_step_breakpoint): Update.
4442 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
4444 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
4446 * break-catch-sig.c (create_signal_catchpoint): Use
4448 * ada-lang.c (create_ada_exception_catchpoint): Use
4451 2017-08-22 Tom Tromey <tom@tromey.com>
4453 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
4455 2017-08-22 Tom Tromey <tom@tromey.com>
4457 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
4458 (lookup_partial_symbol): Update.
4460 2017-08-22 Tom Tromey <tom@tromey.com>
4462 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
4463 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
4464 (find_and_open_source, symtab_to_fullname): Update.
4465 * psymtab.c (psymtab_to_fullname): Update.
4467 2017-08-22 Tom Tromey <tom@tromey.com>
4469 * exec.c (exec_file_attach): Update.
4470 * linux-thread-db.c (try_thread_db_load): Update.
4471 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
4472 * utils.c (gdb_realpath): Change return type.
4473 (gdb_realpath_keepfile): Update.
4474 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
4475 (_initialize_utils): Register the new self test.
4476 * source.c (openp): Update.
4477 (find_and_open_source): Update.
4478 * nto-tdep.c (nto_find_and_open_solib): Update.
4479 * main.c (set_gdb_data_directory): Update.
4480 (captured_main_1): Update.
4481 * dwarf2read.c (dwarf2_get_dwz_file): Update
4482 (dw2_map_symbol_filenames): Update.
4483 * auto-load.c (auto_load_safe_path_vec_update): Update.
4484 (filename_is_in_auto_load_safe_path_vec): Change type of
4486 (auto_load_objfile_script): Update.
4487 (file_is_auto_load_safe): Update. Use std::string.
4488 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
4490 2017-08-22 Tom Tromey <tom@tromey.com>
4492 * utils.c (gdb_realpath_keepfile): Return a
4493 gdb::unique_xmalloc_ptr.
4494 * exec.c (exec_file_attach): Update.
4495 * utils.h (gdb_realpath_keepfile): Return a
4496 gdb::unique_xmalloc_ptr.
4498 2017-08-22 Tom Tromey <tom@tromey.com>
4500 * compile/compile.c (compile_file_command): Use
4501 gdb::unique_xmalloc_ptr, std::string.
4502 * utils.c (gdb_abspath): Change return type.
4503 * source.c (openp): Update.
4504 * objfiles.c (allocate_objfile): Update.
4505 * main.c (set_gdb_data_directory): Update.
4506 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
4508 2017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
4510 * cli-cmds.c (list_commands): List actual code around more than
4513 2017-08-21 John Baldwin <jhb@FreeBSD.org>
4515 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
4517 2017-08-21 Pedro Alves <palves@redhat.com>
4520 * c-exp.y (variable production): Handle function aliases.
4521 * minsyms.c (msymbol_is_text): New function.
4522 * minsyms.h (msymbol_is_text): Declare.
4523 * symtab.c (find_function_alias_target): New function.
4524 * symtab.h (find_function_alias_target): Declare.
4526 2017-08-21 Pedro Alves <palves@redhat.com>
4528 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
4530 * typeprint.c (whatis_exp): If handling "whatis", and expression
4531 is OP_TYPE, strip one typedef level. Otherwise don't strip
4533 * valops.c (value_cast): Save "to" type before resolving
4534 stubs/typedefs. Use that type as resulting value's type.
4536 2017-08-18 Tom Tromey <tom@tromey.com>
4537 Pedro Alves <palves@redhat.com>
4539 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
4540 * sol-thread.c (sol_thread_resume, sol_thread_wait)
4541 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
4542 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
4543 * proc-service.c (ps_xfer_memory): Use scoped_restore.
4544 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
4545 (linux_get_siginfo_data): Add "thread" argument. Use
4547 * linux-nat.c (linux_child_follow_fork)
4548 (check_stopped_by_watchpoint): Use scoped_restore.
4549 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
4550 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
4551 (restore_inferior_ptid, save_inferior_ptid): Remove.
4552 * btrace.c (btrace_fetch): Use scoped_restore.
4553 * bsd-uthread.c (bsd_uthread_fetch_registers)
4554 (bsd_uthread_store_registers): Use scoped_restore.
4555 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
4557 * aix-thread.c (aix_thread_resume, aix_thread_wait)
4558 (aix_thread_xfer_partial): Use scoped_restore.
4559 * inferior.h (save_inferior_ptid): Remove.
4561 2017-08-18 Yao Qi <yao.qi@linaro.org>
4564 * arm-tdep.c (gdb_print_insn_arm): Mark
4565 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
4567 2017-08-18 Yao Qi <yao.qi@linaro.org>
4569 * NEWS: Mention GDBserver's new option "--selftest".
4570 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
4571 * selftest.c: Move it to common/selftest.c.
4572 * selftest.h: Move it to common/selftest.h.
4573 * selftest-arch.c (reset): New function.
4574 (tests_with_arch): Call reset.
4576 2017-08-18 Yao Qi <yao.qi@linaro.org>
4578 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
4579 instead of exception_fprintf and printf_filtered.
4581 2017-08-18 Yao Qi <yao.qi@linaro.org>
4583 * selftest.c (register_self_test): Rename it to
4584 selftests::register_test.
4585 (run_self_tests): selftest::run_tests.
4586 * selftest.h: Update declarations.
4587 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
4588 selftests::register_test_foreach_arch.
4589 * selftest-arch.h: Update declaration.
4590 * aarch64-tdep.c: Update.
4591 * arm-tdep.c: Likewise.
4592 * disasm-selftests.c: Likewise.
4593 * dwarf2loc.c: Likewise.
4594 * dwarf2-frame.c: Likewise.
4595 * findvar.c: Likewise.
4596 * gdbarch-selftests.c: Likewise.
4597 * maint.c (maintenance_selftest): Likewise.
4598 * regcache.c: Likewise.
4599 * rust-exp.y: Likewise.
4600 * selftest-arch.c: Likewise.
4601 * unittests/environ-selftests.c: Likewise.
4602 * unittests/function-view-selftests.c: Likewise.
4603 * unittests/offset-type-selftests.c: Likewise.
4604 * unittests/optional-selftests.c: Likewise.
4605 * unittests/scoped_restore-selftests.c: Likewise.
4606 * utils-selftests.c: Likewise.
4608 2017-08-17 Pedro Alves <palves@redhat.com>
4610 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
4613 2017-08-17 Pedro Alves <palves@redhat.com>
4615 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
4617 (reset_die_in_process): Delete, replaced by ...
4618 (process_die_scope): ... this new class. Make it responsible for
4619 freeing cu->line_header too.
4620 (process_die): Use process_die_scope.
4621 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
4622 cu->line_header_die_owner. Don't release the line header if it's
4624 (setup_type_unit_groups): Make the CU/DIE own the line header.
4625 Don't release the line header here.
4627 2017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
4629 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
4631 2017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
4633 * NEWS: Mention new shortcuts for nexti and stepi in TUI
4636 2017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
4638 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
4641 2017-08-15 Stafford Horne <shorne@gmail.com>
4643 * MAINTAINERS (Write After Approval): Add Stafford Horne.
4645 2017-08-15 Stafford Horne <shorne@gmail.com>
4647 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
4649 2017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
4652 * infcmd.c (unset_environment_command): Use the 'clear' method on
4653 the environment instead of resetting it.
4655 2017-08-15 John Baldwin <jhb@FreeBSD.org>
4657 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
4660 2017-08-14 Tom Tromey <tom@tromey.com>
4662 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
4663 (print_binary_chars): Likewise.
4664 (BITS_IN_BYTES): Remove.
4666 2017-08-14 Tom Tromey <tom@tromey.com>
4669 * valprint.c (LOW_ZERO): Change value to 034.
4670 (print_octal_chars): Add static_asserts for octal constants.
4671 * printcmd.c (print_scalar_formatted): Add 'd' case.
4673 2017-08-11 Tom Tromey <tom@tromey.com>
4675 * symfile.c (add_symbol_file_command): Use std::vector.
4677 2017-08-14 Tom Tromey <tom@tromey.com>
4679 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
4680 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
4682 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
4684 2017-08-11 Pedro Alves <palves@redhat.com>
4686 * infrun.c (process_event_stop_test): Adjust
4687 function_name_is_marked_for_skip call.
4688 * skip.c: Include <list>.
4689 (skiplist_entry): Make it a class with private fields, and
4691 (skiplist_entry_chain): Delete.
4692 (skiplist_entries): New.
4693 (skiplist_entry_count): Delete.
4694 (highest_skiplist_entry_num): New.
4695 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
4696 (add_skiplist_entry): Delete.
4697 (skiplist_entry::skiplist_entry): New.
4698 (skiplist_entry::add_entry): New.
4699 (skip_file_command, skip_function): Adjust.
4700 (compile_skip_regexp): Delete.
4701 (skip_command): Don't compile regexp here. Adjust to use
4702 skiplist_entry::add_entry.
4703 (skip_info): Adjust to use range-for and getters.
4704 (skip_enable_command, skip_disable_command): Adjust to use
4705 range-for and setters.
4706 (skip_delete_command): Adjust to use std::list.
4707 (add_skiplist_entry): Delete.
4708 (skip_file_p): Delete, refactored as ...
4709 (skiplist_entry::do_skip_file_p): ... this new method.
4710 (skip_gfile_p): Delete, refactored as ...
4711 (skiplist_entry::do_gskip_file_p): ... this new method.
4712 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
4713 (skiplist_entry::skip_function_p): ... this new method.
4714 (function_name_is_marked_for_skip): Now returns bool, and takes
4715 the function sal by const reference. Adjust to use range-for and
4716 skiplist_entry methods.
4717 (_initialize_step_skip): Remove references to
4718 skiplist_entry_chain, skiplist_entry_count.
4719 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
4720 takes the function sal by const reference.
4722 2017-08-11 Yao Qi <yao.qi@linaro.org>
4724 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
4725 (dwarf2_frame_cache): Remove reset_cache_cleanup.
4726 (dwarf2_frame_cache):
4727 * frame-unwind.c (frame_unwind_try_unwinder): Catch
4728 RETURN_MASK_ALL and set *this_case to NULL.
4729 * frame-unwind.h: Update comments.
4731 2017-08-11 Yao Qi <yao.qi@linaro.org>
4733 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
4734 (dwarf2_frame_state_copy_regs): Remove.
4735 (dwarf2_frame_state_free_regs): Remove.
4736 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
4737 (dwarf2_restore_rule): Call method .alloc_regs instead of
4738 dwarf2_frame_state_alloc_regs.
4739 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
4740 constructor. Call std::move.
4741 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
4742 (dwarf2_frame_cache): Likewise.
4744 [GDB_SELF_TEST]: Include selftest.h and
4746 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
4747 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
4748 execute_cfa_program_test.
4750 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
4751 copy ctor, assignment operator, move assignment.
4752 <alloc_regs>: New method.
4754 (struct dwarf2_frame_state): Delete dtor.
4755 (dwarf2_frame_state_alloc_regs): Remove declaration.
4756 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
4757 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
4759 2017-08-11 Yao Qi <yao.qi@linaro.org>
4761 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
4762 (dwarf2_frame_state::dwarf2_frame_state): New.
4763 (dwarf2_frame_state::~dwarf2_frame_state): New.
4764 (dwarf2_fetch_cfa_info): Update.
4765 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
4766 rather than a pointer. Update code.
4767 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
4769 <data_align, code_align, retaddr_column>: Change them to const.
4770 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
4773 2017-08-11 Yao Qi <yao.qi@linaro.org>
4775 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
4776 <loc.exp>: New field.
4777 * dwarf2-frame.c (execute_cfa_program): Update.
4778 (dwarf2_frame_prev_register): Update.
4780 2017-08-10 Pedro Alves <palves@redhat.com>
4782 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
4784 2017-08-09 John Baldwin <jhb@FreeBSD.org>
4786 * fbsd-nat.c (struct fbsd_fork_info): Remove.
4787 (fbsd_pending_children): Use std::list.
4788 (fbsd_remember_child): Likewise.
4789 (fbsd_is_child_pending): Likewise.
4790 (fbsd_pending_vfork_done): Use std::forward_list.
4791 (fbsd_add_vfork_done): Likewise.
4792 (fbsd_is_vfork_done_pending): Likewise.
4793 (fbsd_next_vfork_done): Likewise.
4795 2017-08-09 John Baldwin <jhb@FreeBSD.org>
4797 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
4798 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
4799 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
4801 (fbsd_xfer_partial): Use gdb::byte_vector.
4802 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
4804 2017-08-09 John Baldwin <jhb@FreeBSD.org>
4806 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
4808 (fbsd_find_memory_regions): Fix `mapfile' initialization.
4810 2017-08-09 Tom Tromey <tom@tromey.com>
4812 * skip.c (skiplist_entry): New constructor.
4813 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
4814 (skiplist_entry::file_is_glob): Now bool.
4815 (skiplist_entry::file, skiplist_entry::function): Now
4817 (make_skip_entry): Return a unique_ptr. Use new.
4818 (free_skiplist_entry, free_skiplist_entry_cleanup)
4819 (make_free_skiplist_entry_cleanup): Remove.
4820 (skip_command, skip_disable_command, add_skiplist_entry)
4821 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
4822 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
4823 (function_name_is_marked_for_skip): Update.
4824 (skip_delete_command): Update. Use delete.
4826 2017-08-09 Jiong Wang <jiong.wang@arm.com>
4828 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
4829 (aarch64_linux_core_read_description): New function.
4830 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
4832 2017-08-09 Pedro Alves <palves@redhat.com>
4834 * cp-name-parser.y (cp_comp_to_string): Return a
4835 gdb::unique_xmalloc_ptr<char>.
4836 * cp-support.c (replace_typedefs_qualified_name)
4837 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
4838 (cp_canonicalize_string_full): Use op= instead of explicit
4840 (cp_class_name_from_physname, method_name_from_physname)
4841 (cp_func_name, cp_remove_params): Adjust to use
4842 gdb::unique_xmalloc_ptr<char>.
4843 * cp-support.h (cp_comp_to_string): Return a
4844 gdb::unique_xmalloc_ptr<char>.
4845 * python/py-type.c (typy_lookup_type): Adjust to use
4846 gdb::unique_xmalloc_ptr<char>.
4848 2017-08-09 H.J. Lu <hongjiu.lu@intel.com>
4850 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
4852 2017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
4853 Yao Qi <yao.qi@linaro.org>
4855 * cp-support.c (cp_canonicalize_string_full): Use
4856 gdb::unique_xmalloc_ptr<char>.
4857 (cp_canonicalize_string): Likewise.
4859 2017-08-09 Yao Qi <yao.qi@linaro.org>
4861 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
4862 * regformats/i386/amd64-avx-avx512.dat: Remove.
4863 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
4864 * regformats/i386/amd64-avx-mpx.dat:Remove.
4865 * regformats/i386/amd64-avx.dat: Remove.
4866 * regformats/i386/amd64-mpx.dat: Remove.
4867 * regformats/i386/i386-avx-avx512.dat: Remove.
4868 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
4869 * regformats/i386/i386-avx-mpx.dat: Remove.
4870 * regformats/i386/i386-mmx.dat: Remove.
4871 * regformats/i386/i386-mpx.dat: Remove.
4873 2017-08-09 Yao Qi <yao.qi@linaro.org>
4875 * amd64-tdep.h (tdesc_x32): Remove the declaration.
4876 * amd64-tdep.c: Don't include features/i386/x32*.c.
4877 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
4879 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
4880 and i386/x32-avx-avx512.
4881 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
4883 * features/i386/x32-avx-avx512.c: Removed.
4884 * features/i386/x32-avx-avx512.xml: Removed.
4885 * features/i386/x32-avx.c: Removed.
4886 * features/i386/x32-avx.xml: Removed.
4887 * features/i386/x32.c: Removed.
4888 * features/i386/x32.xml: Removed.
4889 * regformats/i386/x32-avx-avx512.dat: Removed.
4890 * regformats/i386/x32-avx.dat: Removed.
4891 * regformats/i386/x32.dat: Removed.
4893 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
4895 PR breakpoints/21886
4896 * mem-break.c (default_memory_insert_breakpoint): Use
4897 `->placed_address' rather than `->reqstd_address' for the
4898 breakpoint location.
4900 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
4902 * arch-utils.c (default_print_insn): Remove arch/mach/endian
4905 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
4907 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
4908 a union of `tdep_info', `tdesc_data' and `id'.
4909 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
4910 rather than `info.tdep_info'.
4911 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
4912 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
4913 * i386-tdep.c (i386_gdbarch_init): Likewise.
4914 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
4915 * mips-tdep.c (mips_gdbarch_init): Likewise.
4916 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
4917 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
4918 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
4920 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
4922 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
4923 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
4925 * spu-tdep.c (spu_gdbarch_init): Likewise.
4926 * gdbarch.h: Regenerate.
4928 2017-08-07 Leszek Swirski <leszeks@google.com>
4931 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
4933 2017-08-07 Simon Marchi <simon.marchi@ericsson.com>
4935 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
4936 (gdbsim_open): Rename gdb_argv args object to argv.
4938 2017-08-05 Tom Tromey <tom@tromey.com>
4940 * compile/compile-object-load.c (compile_object_load): Use
4941 gdb::unique_xmalloc_ptr.
4942 * cli/cli-dump.c (scan_filename): Rename from
4943 scan_filename_with_cleanup. Change return type.
4944 (scan_expression): Rename from scan_expression_with_cleanup.
4946 (dump_memory_to_file, dump_value_to_file, restore_command):
4947 Use gdb::unique_xmalloc_ptr. Update.
4948 * cli/cli-cmds.c (find_and_open_script): Use
4949 gdb::unique_xmalloc_ptr.
4950 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
4951 * symmisc.c (maintenance_print_symbols)
4952 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
4953 * symfile.c (symfile_bfd_open, generic_load)
4954 (add_symbol_file_command, remove_symbol_file_command): Use
4955 gdb::unique_xmalloc_ptr.
4956 * source.c (openp): Use gdb::unique_xmalloc_ptr.
4957 * psymtab.c (maintenance_print_psymbols): Use
4958 gdb::unique_xmalloc_ptr.
4959 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
4960 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
4961 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
4962 (reload_shared_libraries_1): Likewise.
4964 2017-08-05 Tom Tromey <tom@tromey.com>
4966 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
4967 (rust_op_vector, rust_set_vector): New typedefs.
4968 (current_parser): New global.
4969 (work_obstack): Change to pointer type. Update all users.
4970 (rust_ast, pstate): Remove globals.
4971 (struct rust_parser): New.
4972 (%union) <params, field_inits>: Change type.
4973 (start, tuple_expr, unit_expr, struct_expr_list, literal)
4974 (field_expr, expr_list, maybe_expr_list, type_list): Update.
4975 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
4976 (convert_params_to_types, convert_params_to_expression): Change
4978 (ast_string): Change type of "fields".
4979 (rust_parse): Make a rust_parser. Remove cleanups.
4980 (rust_lex_tests): Make and install an auto_obstack.
4982 2017-08-04 Yao Qi <yao.qi@linaro.org>
4984 * configure.srv (ipa_x32_linux_regobj): New.
4985 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
4986 instead of X86_TDESC_AVX512.
4987 (initialize_low_tracepoint): Call
4988 init_registers_x32_avx_avx512_linux.
4990 2017-08-04 Yao Qi <yao.qi@linaro.org>
4992 * utils.h (gdb_argv): Add namespace std for nullptr_t.
4994 2017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
4996 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
4998 2017-08-03 Tom Tromey <tom@tromey.com>
5000 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
5002 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
5004 2017-08-03 Tom Tromey <tom@tromey.com>
5006 * python/py-param.c (compute_enum_values): Use gdb_argv.
5008 2017-08-03 Tom Tromey <tom@tromey.com>
5010 * utils.h (struct gdb_argv_deleter): New.
5011 (gdb_argv): New class.
5012 * utils.c (gdb_argv::reset): New method.
5013 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
5014 * tracefile.c (tsave_command): Use gdb_argv.
5015 * top.c (new_ui_command): Use gdb_argv.
5016 * symmisc.c (maintenance_print_symbols)
5017 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
5018 * symfile.c (symbol_file_command, generic_load)
5019 (remove_symbol_file_command): Use gdb_argv.
5020 * stack.c (backtrace_command): Use gdb_argv.
5021 * source.c (add_path, show_substitute_path_command)
5022 (unset_substitute_path_command, set_substitute_path_command):
5024 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
5025 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
5026 * remote.c (extended_remote_run, remote_put_command)
5027 (remote_get_command, remote_delete_command): Use gdb_argv.
5028 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
5029 (gdbsim_open): Use gdb_argv.
5030 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
5031 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
5032 * procfs.c (procfs_info_proc): Use gdb_argv.
5033 * interps.c (interpreter_exec_cmd): Use gdb_argv.
5034 * infrun.c (handle_command): Use gdb_argv.
5035 * inferior.c (add_inferior_command, clone_inferior_command):
5037 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
5038 * exec.c (exec_file_command): Use gdb_argv.
5039 * cli/cli-cmds.c (alias_command): Use gdb_argv.
5040 * compile/compile.c (build_argc_argv): Use gdb_argv.
5042 2017-08-03 Tom Tromey <tom@tromey.com>
5044 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
5046 2017-08-03 Tom Tromey <tom@tromey.com>
5048 * python/python.c (compute_python_string): Return std::string.
5049 (gdbpy_eval_from_control_command): Update.
5050 (do_start_initialization): Use std::string.
5051 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
5053 * python/py-breakpoint.c (local_setattro): Use string_printf, not
5056 2017-08-03 Tom Tromey <tom@tromey.com>
5058 * top.h (do_restore_instream_cleanup): Remove.
5059 * top.c (do_restore_instream_cleanup): Remove.
5060 (read_command_file): Use scoped_restore.
5061 * cli/cli-script.c (execute_user_command): Use scoped_restore.
5063 2017-08-03 Tom Tromey <tom@tromey.com>
5065 * cli/cli-script.c (execute_user_command)
5066 (execute_control_command): Use scoped_restore.
5068 2017-08-03 Tom Tromey <tom@tromey.com>
5070 * cli/cli-script.c (do_restore_user_call_depth): Remove.
5071 (execute_user_command): Remove user_call_depth; use
5072 user_args_stack's size instead.
5074 2017-08-03 Tom Tromey <tom@tromey.com>
5076 * top.h (in_user_command): Remove.
5077 * top.c (in_user_command): Remove.
5078 * cli/cli-script.c (do_restore_user_call_depth)
5079 (execute_user_command): Update.
5081 2017-08-03 Tom Tromey <tom@tromey.com>
5083 * valops.c (search_struct_method): Use gdb::byte_vector.
5084 * valarith.c (value_concat): Use std::vector.
5085 * target.c (memory_xfer_partial): Use gdb::byte_vector.
5086 (simple_search_memory): Likewise.
5087 * printcmd.c (find_string_backward): Use gdb::byte_vector.
5088 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
5089 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
5090 * elfread.c (elf_rel_plt_read): Use std::string.
5091 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
5092 * cli/cli-dump.c (restore_section_callback): Use
5095 2017-08-03 Tom Tromey <tom@tromey.com>
5097 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
5099 2017-08-03 Tom Tromey <tom@tromey.com>
5101 * tui/tui-regs.c (tui_restore_gdbout): Remove.
5102 (tui_register_format): Use scoped_restore.
5104 2017-08-03 Tom Tromey <tom@tromey.com>
5106 * reverse.c (exec_direction_default): Remove.
5107 (exec_reverse_once): Use scoped_restore.
5108 * remote.c (restore_remote_timeout): Remove.
5109 (remote_flash_erase, remote_flash_write, remote_flash_done)
5110 (readchar, remote_serial_write): Use scoped_restore.
5111 * cli/cli-script.c (struct source_cleanup_lines_args)
5112 (source_cleanup_lines): Remove.
5113 (script_from_file): Use scoped_restore.
5114 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
5115 (source_command): Use scoped_restore.
5117 2017-08-03 Tom Tromey <tom@tromey.com>
5119 * utils.h (make_cleanup_free_so): Remove.
5120 * utils.c (do_free_so, make_cleanup_free_so): Remove.
5121 * solist.h (struct so_deleter): New.
5122 (so_list_up): New typedef.
5123 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
5125 2017-08-03 Tom Tromey <tom@tromey.com>
5127 * utils.h (make_cleanup_restore_current_language): Remove.
5128 * utils.c (do_restore_current_language)
5129 (make_cleanup_restore_current_language): Remove.
5130 * parse.c (parse_exp_in_context_1)
5131 (parse_expression_with_language): Use
5132 scoped_restore_current_language.
5133 * mi/mi-main.c (mi_cmd_execute): Use
5134 scoped_restore_current_language.
5135 * language.h (scoped_restore_current_language): New class.
5137 2017-08-03 Tom Tromey <tom@tromey.com>
5139 * compile/compile.c (cleanup_unlink_file): Remove.
5140 (compile_to_object): Use gdb::unlinker.
5141 (eval_compile_command): Likewise.
5143 2017-08-03 Tom Tromey <tom@tromey.com>
5145 * utils.h (make_cleanup_fclose): Remove.
5146 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
5148 2017-08-03 Tom Tromey <tom@tromey.com>
5150 * top.c (open_terminal_stream): Return gdb_file_up.
5151 (new_ui_command): Update.
5153 2017-08-03 Tom Tromey <tom@tromey.com>
5155 * source.c (print_source_lines_base, forward_search_command)
5156 (reverse_search_command): Use gdb_file_up.
5158 2017-08-03 Tom Tromey <tom@tromey.com>
5160 * fbsd-nat.c (fbsd_find_memory_regions): Update.
5162 2017-08-03 Tom Tromey <tom@tromey.com>
5164 * cli/cli-cmds.c (find_and_open_script): Change return type.
5165 Remove "streamp" and "full_path" parameters.
5166 (source_script_with_search): Update.
5167 * auto-load.c (source_script_file): Update.
5168 * cli/cli-cmds.h (find_and_open_script): Change type.
5169 (open_script): New struct.
5171 2017-08-03 Tom Tromey <tom@tromey.com>
5173 * xml-support.c (xml_fetch_content_from_file): Update.
5174 * ui-file.c (stdio_file::open): Update.
5175 * tracefile-tfile.c (tfile_start): Update.
5176 * remote.c (remote_file_put, remote_file_get): Update.
5177 * nat/linux-procfs.c (linux_proc_get_int)
5178 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
5179 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
5180 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
5181 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
5182 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
5183 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
5184 * linux-nat.c (linux_proc_pending_signals): Update.
5185 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
5186 (file_closer): Remove.
5187 * compile/compile.c (compile_to_object): Update.
5188 * common/filestuff.h (struct gdb_file_deleter): New.
5189 (gdb_file_up): New typedef.
5190 (gdb_fopen_cloexec): Change return type.
5191 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
5192 * cli/cli-dump.c (fopen_with_cleanup): Remove.
5193 (dump_binary_file, restore_binary_file): Update.
5194 * auto-load.c (auto_load_objfile_script_1): Update.
5196 2017-08-03 Tom Tromey <tom@tromey.com>
5198 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
5199 (info_static_tracepoint_markers_command): Likewise.
5200 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
5201 * skip.c (skip_info): Use ui_out_emit_table.
5202 * progspace.c (print_program_space): Use ui_out_emit_table.
5203 * osdata.c (info_osdata): Use ui_out_emit_table.
5204 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
5206 * linux-thread-db.c (info_auto_load_libthread_db): Use
5208 * inferior.c (print_inferior): Use ui_out_emit_table.
5209 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
5210 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
5211 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
5212 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
5213 * ui-out.h (class ui_out_emit_table): New.
5215 2017-08-02 Maciej W. Rozycki <macro@imgtec.com>
5217 * mips-tdep.c (mips_fpu_type_str): New function.
5218 (mips_dump_tdep): Call it.
5220 2017-08-01 Maciej W. Rozycki <macro@imgtec.com>
5222 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
5225 2017-07-31 Xavier Roirand <roirand@adacore.com>
5227 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
5229 2017-07-27 Xavier Roirand <roirand@adacore.com>
5231 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
5233 2017-07-26 Yao Qi <yao.qi@linaro.org>
5235 * cli/cli-cmds.c (maintenancechecklist): New variable.
5236 * gdbcmd.h (maintenancechecklist): Declare it.
5237 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
5238 Call i386_linux_read_description with different masks.
5239 * maint.c (maintenance_check_command): New function.
5240 (_initialize_maint_cmds): Call add_prefix_cmd.
5241 * target-descriptions.c (tdesc_reg): override operator != and ==.
5242 (tdesc_type): Likewise.
5243 (tdesc_feature): Likewise.
5244 (target_desc): Likewise.
5245 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
5246 (maintenance_check_xml_descriptions): New function.
5247 (_initialize_target_descriptions) Add command "xml-descriptions".
5248 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
5250 2017-07-26 Yao Qi <yao.qi@linaro.org>
5252 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
5253 Include features/i386/32bit-*.c.
5254 (i386_linux_read_description): Generate target description if it
5256 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
5258 * features/i386/32bit-linux.c: Re-generated.
5259 * features/i386/32bit-sse.c: Likewise.
5260 * target-descriptions.c (print_c_feature::visit): Print code to
5261 set register number if needed.
5262 (print_c_feature) <m_next_regnum>: New field.
5264 2017-07-26 Yao Qi <yao.qi@linaro.org>
5266 * features/Makefile (CFILES): Rename with TDESC_CFILES.
5267 (FEATURE_XMLFILES): New.
5268 (FEATURE_CFILES): New.
5270 (clean-cfiles): Remove generated c files.
5271 * features/i386/32bit-avx.c: Generated.
5272 * features/i386/32bit-avx512.c: Generated.
5273 * features/i386/32bit-core.c: Generated.
5274 * features/i386/32bit-linux.c: Generated.
5275 * features/i386/32bit-mpx.c: Generated.
5276 * features/i386/32bit-pkeys.c: Generated.
5277 * features/i386/32bit-sse.c: Generated.
5278 * target-descriptions.c: Include algorithm.
5279 (tdesc_element_visitor): Add method visit_end.
5280 (print_c_tdesc): Implement visit_end.
5281 (print_c_tdesc:: m_filename_after_features): Move it to
5283 (print_c_feature): New class.
5284 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
5285 name starts with "i386/32bit-".
5287 2017-07-26 Yao Qi <yao.qi@linaro.org>
5289 * target-descriptions.c (tdesc_element_visitor): New class.
5290 (tdesc_element): New class.
5291 (tdesc_reg): Inherit from tdesc_element.
5292 (tdesc_reg::accept): New function.
5293 (tdesc_type): Inherit from tdesc_element.
5294 (tdesc_type::accept): New function.
5295 (tdesc_feature): Inherit from tdesc_element.
5296 (tdesc_feature::accept): New function.
5297 (target_desc): Inherit from tdesc_element.
5298 (target_desc::target_desc): New.
5299 (target_desc::~target_desc): New.
5300 (target_desc::accept): New.
5301 (allocate_target_description): Use new.
5302 (free_target_description): Use delete.
5303 (print_c_tdesc): New class.
5304 (maint_print_c_tdesc_cmd): Adjust.
5306 * features/aarch64.c: Re-generated.
5307 * features/arc-arcompact.c: Re-generated.
5308 * features/arc-v2.c: Re-generated.
5309 * features/arm/arm-with-iwmmxt.c: Re-generated.
5310 * features/arm/arm-with-m.c: Re-generated.
5311 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
5312 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
5313 * features/arm/arm-with-neon.c: Re-generated.
5314 * features/arm/arm-with-vfpv2.c: Re-generated.
5315 * features/arm/arm-with-vfpv3.c: Re-generated.
5316 * features/i386/amd64-avx-avx512.c: Re-generated.
5317 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
5318 * features/i386/amd64-avx.c: Re-generated.
5319 * features/i386/amd64-avx-linux.c: Re-generated.
5320 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
5321 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
5322 * features/i386/amd64-avx-mpx.c: Re-generated.
5323 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
5324 * features/i386/amd64.c: Re-generated.
5325 * features/i386/amd64-linux.c: Re-generated.
5326 * features/i386/amd64-mpx.c: Re-generated.
5327 * features/i386/amd64-mpx-linux.c: Re-generated.
5328 * features/i386/i386-avx-avx512.c: Re-generated.
5329 * features/i386/i386-avx-avx512-linux.c: Re-generated.
5330 * features/i386/i386-avx.c: Re-generated.
5331 * features/i386/i386-avx-linux.c: Re-generated.
5332 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
5333 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
5334 * features/i386/i386-avx-mpx.c: Re-generated.
5335 * features/i386/i386-avx-mpx-linux.c: Re-generated.
5336 * features/i386/i386.c: Re-generated.
5337 * features/i386/i386-linux.c: Re-generated.
5338 * features/i386/i386-mmx.c: Re-generated.
5339 * features/i386/i386-mmx-linux.c: Re-generated.
5340 * features/i386/i386-mpx.c: Re-generated.
5341 * features/i386/i386-mpx-linux.c: Re-generated.
5342 * features/i386/x32-avx-avx512.c: Re-generated.
5343 * features/i386/x32-avx-avx512-linux.c: Re-generated.
5344 * features/i386/x32-avx.c: Re-generated.
5345 * features/i386/x32-avx-linux.c: Re-generated.
5346 * features/i386/x32.c: Re-generated.
5347 * features/i386/x32-linux.c: Re-generated.
5348 * features/microblaze.c: Re-generated.
5349 * features/microblaze-with-stack-protect.c: Re-generated.
5350 * features/mips64-dsp-linux.c: Re-generated.
5351 * features/mips64-linux.c: Re-generated.
5352 * features/mips-dsp-linux.c: Re-generated.
5353 * features/mips-linux.c: Re-generated.
5354 * features/nds32.c: Re-generated.
5355 * features/nios2.c: Re-generated.
5356 * features/nios2-linux.c: Re-generated.
5357 * features/rs6000/powerpc-32.c: Re-generated.
5358 * features/rs6000/powerpc-32l.c: Re-generated.
5359 * features/rs6000/powerpc-403.c: Re-generated.
5360 * features/rs6000/powerpc-403gc.c : Re-generated.
5361 * features/rs6000/powerpc-405.c: Re-generated.
5362 * features/rs6000/powerpc-505.c: Re-generated.
5363 * features/rs6000/powerpc-601.c: Re-generated.
5364 * features/rs6000/powerpc-602.c: Re-generated.
5365 * features/rs6000/powerpc-603.c: Re-generated.
5366 * features/rs6000/powerpc-604.c: Re-generated.
5367 * features/rs6000/powerpc-64.c: Re-generated.
5368 * features/rs6000/powerpc-64l.c: Re-generated.
5369 * features/rs6000/powerpc-7400.c: Re-generated.
5370 * features/rs6000/powerpc-750.c: Re-generated.
5371 * features/rs6000/powerpc-860.c: Re-generated.
5372 * features/rs6000/powerpc-altivec32.c: Re-generated.
5373 * features/rs6000/powerpc-altivec32l.c: Re-generated.
5374 * features/rs6000/powerpc-altivec64.c: Re-generated.
5375 * features/rs6000/powerpc-altivec64l.c: Re-generated.
5376 * features/rs6000/powerpc-cell32l.c: Re-generated.
5377 * features/rs6000/powerpc-cell64l.c: Re-generated.
5378 * features/rs6000/powerpc-e500.c: Re-generated.
5379 * features/rs6000/powerpc-e500l.c: Re-generated.
5380 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
5381 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
5382 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
5383 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
5384 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
5385 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
5386 * features/rs6000/powerpc-vsx32.c: Re-generated.
5387 * features/rs6000/powerpc-vsx32l.c: Re-generated.
5388 * features/rs6000/powerpc-vsx64.c: Re-generated.
5389 * features/rs6000/powerpc-vsx64l.c: Re-generated.
5390 * features/rs6000/rs6000.c: Re-generated.
5391 * features/s390-linux32.c: Re-generated.
5392 * features/s390-linux32v1.c: Re-generated.
5393 * features/s390-linux32v2.c: Re-generated.
5394 * features/s390-linux64.c: Re-generated.
5395 * features/s390-linux64v1.c: Re-generated.
5396 * features/s390-linux64v2.c: Re-generated.
5397 * features/s390-te-linux64.c: Re-generated.
5398 * features/s390-tevx-linux64.c: Re-generated.
5399 * features/s390-vx-linux64.c: Re-generated.
5400 * features/s390x-linux64.c: Re-generated.
5401 * features/s390x-linux64v1.c: Re-generated.
5402 * features/s390x-linux64v2.c: Re-generated.
5403 * features/s390x-te-linux64.c: Re-generated.
5404 * features/s390x-tevx-linux64.c: Re-generated.
5405 * features/s390x-vx-linux64.c: Re-generated.
5406 * features/sparc/sparc32-solaris.c: Re-generated.
5407 * features/sparc/sparc64-solaris.c: Re-generated.
5408 * features/tic6x-c62x.c: Re-generated.
5409 * features/tic6x-c62x-linux.c: Re-generated.
5410 * features/tic6x-c64x.c: Re-generated.
5411 * features/tic6x-c64x-linux.c: Re-generated.
5412 * features/tic6x-c64xp.c: Re-generated.
5413 * features/tic6x-c64xp-linux.c: Re-generated.
5415 2017-07-26 Yao Qi <yao.qi@linaro.org>
5417 * i386-linux-tdep.c (i386_linux_read_description): New function.
5418 (i386_linux_core_read_description): Call
5419 i386_linux_read_description.
5420 * i386-linux-tdep.h (i386_linux_read_description): Declare.
5421 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
5422 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
5423 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
5424 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
5425 * x86-linux-nat.c (x86_linux_read_description): Call
5426 i386_linux_read_description.
5428 2017-07-26 Yao Qi <yao.qi@linaro.org>
5431 * features/Makefile (%.c: %.xml): Pass the xml file name to
5432 command "maint print c-tdesc".
5433 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
5436 2017-07-26 Yao Qi <yao.qi@linaro.org>
5438 * target-descriptions.c (target_desc): Add ctor and dtor. Do
5439 in-class initialization.
5440 (tdesc_create_feature): Call new instead of XCNEW.
5441 (free_target_description): Ue delete.
5443 2017-07-25 John Baldwin <jhb@FreeBSD.org>
5445 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
5447 2017-07-25 Yao Qi <yao.qi@linaro.org>
5449 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
5451 (amd64_x32_init_abi): Likewise.
5452 * amd64-tdep.h (amd64_init_abi): Update declaration.
5453 (amd64_x32_init_abi): Likewise.
5455 2017-07-25 Yao Qi <yao.qi@linaro.org>
5458 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
5459 condition for FPSCR.
5460 (arm_linux_store_inferior_registers): Likewise.
5462 2017-07-22 Tom Tromey <tom@tromey.com>
5464 * break-catch-syscall.c (struct catch_syscall_inferior_data)
5465 <syscalls_counts>: Now a std::vector.
5466 (get_catch_syscall_inferior_data): Use "new".
5467 (catch_syscall_inferior_data_cleanup): Use "delete".
5468 (insert_catch_syscall, remove_catch_syscall)
5469 (clear_syscall_counts): Update.
5471 2017-07-22 Tom Tromey <tom@tromey.com>
5473 * break-catch-syscall.c (syscall_catchpoint)
5474 <syscalls_to_be_caught>: Now a std::vector<int>
5475 (~syscall_catchpoint): Remove.
5476 (insert_catch_syscall, remove_catch_syscall)
5477 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
5478 (print_mention_catch_syscall, print_recreate_catch_syscall):
5480 (create_syscall_event_catchpoint): Change type of "filter"
5482 (catch_syscall_split_args): Return a std::vector.
5483 (catch_syscall_command_1, catching_syscall_number_1): Update.
5485 2017-07-22 Tom Tromey <tom@tromey.com>
5487 * break-catch-throw.c (struct exception_catchpoint)
5488 <exception_rx>: Now a std::string.
5489 (~exception_catchpoint): Remove.
5490 (print_one_detail_exception_catchpoint): Update.
5491 (handle_gnu_v3_exceptions): Change type of except_rx.
5492 (extract_exception_regexp): Return a std::string.
5493 (catch_exception_command_1): Update.
5495 2017-07-22 Tom Tromey <tom@tromey.com>
5497 * break-catch-sig.c (gdb_signal_type): Remove typedef.
5498 (struct signal_catchpoint) <signals_to_be_caught>: Now a
5500 <catch_all>: Now a bool.
5501 (~signal_catchpoint): Remove.
5502 (signal_catchpoint_insert_location)
5503 (signal_catchpoint_remove_location)
5504 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
5505 (signal_catchpoint_print_mention)
5506 (signal_catchpoint_print_recreate)
5507 (signal_catchpoint_explains_signal): Update.
5508 (create_signal_catchpoint): Change type of "filter" and
5510 (catch_signal_split_args): Return a std::vector. Change type of
5512 (catch_signal_command): Update.
5514 2017-07-20 Pedro Alves <palves@redhat.com>
5516 * ada-lang.c (ada_language_defn): Make extern.
5517 (_initialize_ada_language): Remove add_language call.
5518 * c-lang.c (c_language_defn, cplus_language_defn)
5519 (asm_language_defn, minimal_language_defn): Make extern.
5520 (_initialize_c_language): Delete.
5521 * completer.c (compare_cstrings): Delete, moved to utils.h.
5522 * d-lang.c (d_language_defn): Make extern.
5523 (_initialize_d_language): Remove add_language calls.
5524 * defs.h (enum language): Add comment.
5525 * f-lang.c (f_language_defn): Make extern.
5526 (_initialize_f_language): Remove add_language call.
5527 * go-lang.c (go_language_defn): Make extern.
5528 (_initialize_go_language): Remove add_language call.
5529 * language.c: Include <algorithm>.
5530 (languages): Redefine as const array.
5531 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
5532 (set_language_command): Handle "local". Use for-range loop.
5533 (set_language): Remove loop.
5534 (language_enum): Rewrite.
5535 (language_def, language_str): Remove loops.
5536 (add_language): Delete.
5537 (add_set_language_command): New, based on add_languages.
5538 (skip_language_trampoline): Adjust.
5539 (local_language_defn): Delete.
5540 (language_gdbarch_post_init): Adjust.
5541 (_initialize_language): Remove add_language calls. Call
5542 add_set_language_command.
5543 * language.h (add_language): Delete.
5544 (auto_language_defn)
5545 (unknown_language_defn, minimal_language_defn, ada_language_defn)
5546 (asm_language_defn, c_language_defn, cplus_language_defn)
5547 (d_language_defn, f_language_defn, go_language_defn)
5548 (m2_language_defn, objc_language_defn, opencl_language_defn)
5549 (pascal_language_defn, rust_language_defn): Declare.
5550 * m2-lang.c (m2_language_defn): Make extern.
5551 (_initialize_m2_language): Remove add_language call.
5552 * objc-lang.c (objc_language_defn): Make extern.
5553 (_initialize_objc_language): Remove add_language call.
5554 * opencl-lang.c (opencl_language_defn): Make extern.
5555 (_initialize_opencl_language): Remove add_language call.
5556 * p-lang.c (pascal_language_defn): Make extern.
5557 (_initialize_pascal_language): Delete.
5558 * rust-lang.c (rust_language_defn): Make extern.
5559 (_initialize_rust_language): Delete.
5560 * utils.h (compare_cstrings): New static inline function.
5562 2017-07-20 Pedro Alves <palves@redhat.com>
5564 * ada-lang.c (ada_to_fixed_type_1): Adjust.
5565 (get_var_value): Constify parameters.
5566 (get_int_var_value): Change prototype.
5567 (to_fixed_range_type): Adjust.
5568 * ada-lang.h (get_int_var_value): Change prototype.
5570 2017-07-20 Pedro Alves <palves@redhat.com>
5572 * dwarf2read.c (dw2_lookup_symbol): Use
5573 SYMBOL_MATCHES_SEARCH_NAME.
5574 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
5576 2017-07-20 Pedro Alves <palves@redhat.com>
5578 * block.c (block_iter_name_step, block_iter_name_first)
5579 (block_iter_name_next): Delete.
5580 (block_lookup_symbol_primary): Adjust to use
5581 dict_iter_match_first/dict_iter_match_next.
5582 * block.h (block_iter_name_first, block_iter_name_next): Delete
5584 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
5585 dict_iter_match_first/dict_iter_match_next.
5587 2017-07-20 Pedro Alves <palves@redhat.com>
5589 * cp-support.c (cp_find_first_component_aux): Add missing case for
5592 2017-07-18 David Blaikie <dblaikie@gmail.com>
5594 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
5595 of dwo_cu's dwo_file.
5597 2017-07-18 Yao Qi <yao.qi@linaro.org>
5599 * remote.c (store_registers_using_G): Remove one line comment.
5601 2017-07-18 Yao Qi <yao.qi@linaro.org>
5603 * regcache.c (regcache_cpy): Simplify it.
5604 (regcache::cpy_no_passthrough): Remove it.
5605 * regcache.h (cpy_no_passthrough): Remove it.
5606 (regcache_dup, regcache_cpy): Update comments.
5608 2017-07-18 Pedro Alves <palves@redhat.com>
5610 * remote-sim.c (sim_command_completer): Adjust to work with a
5611 completion_tracker instead of a VEC.
5613 2017-07-17 Pedro Alves <palves@redhat.com>
5615 * completer.c (complete_source_filenames): New function.
5616 (complete_address_and_linespec_locations): New function.
5617 (location_completer): Use complete_address_and_linespec_locations.
5618 (completion_tracker::build_completion_result): Honor the tracker's
5619 request to suppress append.
5620 * completer.h (completion_tracker::suppress_append_ws)
5621 (completion_tracker::set_suppress_append_ws): New methods.
5622 (completion_tracker::m_suppress_append_ws): New field.
5623 (complete_source_filenames): New declaration.
5624 * linespec.c (linespec_complete_what): New.
5625 (struct ls_parser) <complete_what, completion_word,
5626 completion_quote_char, completion_quote_end, completion_tracker>:
5628 (string_find_incomplete_keyword_at_end): New.
5629 (linespec_lexer_lex_string): Record quote char. If in completion
5631 (linespec_lexer_consume_token): Advance the completion word point.
5632 (linespec_lexer_peek_token): Save/restore completion info.
5633 (save_stream_and_consume_token): New.
5634 (set_completion_after_number): New.
5635 (linespec_parse_basic): Set what to complete next depending on
5636 token. Handle function and label completions specially.
5637 (parse_linespec): Disable objc shortcut in completion mode. Set
5638 what to complete next depending on token type. Skip keyword if in
5640 (complete_linespec_component, linespec_complete): New.
5641 * linespec.h (linespec_complete): Declare.
5643 2017-07-17 Pedro Alves <palves@redhat.com>
5645 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
5646 Handle 'operator<' / 'operator<<'.
5648 2017-07-17 Pedro Alves <palves@redhat.com>
5650 * completer.c (collect_explicit_location_matches): Handle
5652 (convert_explicit_location_to_linespec): New, factored out from
5654 (convert_explicit_location_to_sals): ... this.
5655 (complete_label): New.
5656 (linespec_complete_label, find_label_symbols_in_block): New.
5657 (find_label_symbols): Add completion_mode parameter and adjust to
5658 call find_label_symbols_in_block.
5659 * linespec.h (linespec_complete_label): Declare.
5661 2017-07-17 Pedro Alves <palves@redhat.com>
5663 * ada-lang.c (ada_collect_symbol_completion_matches): Add
5664 complete_symbol_mode parameter.
5665 * cli/cli-cmds.c (complete_command): Get the completion result out
5666 of the handle_brkchars tracker if used a custom word point.
5667 * completer.c: Include "linespec.h".
5668 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
5669 (advance_to_expression_complete_word_point): New.
5670 (completion_tracker::completes_to_completion_word): New.
5671 (complete_files_symbols): Pass down
5672 complete_symbol_mode::EXPRESSION.
5673 (explicit_options, probe_options): New.
5674 (collect_explicit_location_matches): Complete on the
5675 explictit_loc->foo instead of word. Use
5676 linespec_complete_function. Handle MATCH_LINE. Handle offering
5677 keyword and options completions.
5678 (backup_text_ptr): Delete.
5679 (skip_keyword): New.
5680 (complete_explicit_location): Remove 'word' parameter. Add
5681 language, quoted_arg_start and quoted_arg_end parameters.
5682 Rewrite, parsing left to right.
5683 (location_completer): Rewrite.
5684 (location_completer_handle_brkchars): New function.
5685 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
5686 (enum complete_line_internal_reason): Adjust comments.
5687 (completion_tracker::discard_completions): New.
5688 (completer_handle_brkchars_func_for_completer): Handle
5690 (gdb_custom_word_point_brkchars)
5691 (gdb_org_rl_basic_quote_characters): New.
5692 (gdb_completion_word_break_characters_throw)
5693 (completion_find_completion_word): Handle trackers that use a
5695 (completion_tracker::advance_custom_word_point_by): New.
5696 (completion_tracker::build_completion_result): Don't rely on
5697 readline appending the quote char.
5698 (gdb_rl_attempted_completion_function_throw): Handle trackers that
5699 use a custom word point.
5700 (gdb_rl_attempted_completion_function): Restore
5701 rl_basic_quote_characters.
5702 * completer.h (class completion_tracker): Extend intro comment.
5703 (completion_tracker::set_quote_char)
5704 (completion_tracker::quote_char)
5705 (completion_tracker::set_use_custom_word_point)
5706 (completion_tracker::use_custom_word_point)
5707 (completion_tracker::custom_word_point)
5708 (completion_tracker::set_custom_word_point)
5709 (completion_tracker::advance_custom_word_point_by)
5710 (completion_tracker::completes_to_completion_word)
5711 (completion_tracker::discard_completions): New methods.
5712 (completion_tracker::m_quote_char)
5713 (completion_tracker::m_use_custom_word_point)
5714 (completion_tracker::m_custom_word_point): New fields.
5715 (advance_to_expression_complete_word_point): Declare.
5716 * f-lang.c (f_collect_symbol_completion_matches): Add
5717 complete_symbol_mode parameter.
5718 * language.h (struct language_defn)
5719 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
5721 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
5722 (linespec_complete_function): New function.
5723 (linespec_lexer_lex_keyword): Adjust.
5724 * linespec.h (linespec_keywords, linespec_complete_function): New
5726 * location.c (find_end_quote): New function.
5727 (explicit_location_lex_one): Add explicit_completion_info
5728 parameter. Save quoting info. Don't throw if being called for
5729 completion. Don't handle Ada operators here.
5730 (is_cp_operator, skip_op_false_positives, first_of)
5731 (explicit_location_lex_one_function): New function.
5732 (string_to_explicit_location): Replace 'dont_throw' parameter with
5733 an explicit_completion_info pointer parameter. Handle it. Don't
5734 use explicit_location_lex_one to lex function names. Use
5735 explicit_location_lex_one_function instead.
5736 * location.h (struct explicit_completion_info): New.
5737 (string_to_explicit_location): Replace 'dont_throw' parameter with
5738 an explicit_completion_info pointer parameter.
5739 * symtab.c (default_collect_symbol_completion_matches_break_on):
5740 Add complete_symbol_mode parameter. Handle LINESPEC mode.
5741 (default_collect_symbol_completion_matches)
5742 (collect_symbol_completion_matches): Add complete_symbol_mode
5744 (collect_symbol_completion_matches_type): Pass down
5745 complete_symbol_mode::EXPRESSION.
5746 (collect_file_symbol_completion_matches): Add complete_symbol_mode
5747 parameter. Handle LINESPEC mode.
5748 * symtab.h (complete_symbol_mode): New.
5749 (default_collect_symbol_completion_matches_break_on)
5750 (default_collect_symbol_completion_matches)
5751 (collect_symbol_completion_matches)
5752 (collect_file_symbol_completion_matches): Add complete_symbol_mode
5755 2017-07-17 Pedro Alves <palves@redhat.com>
5757 * utils.c (enum class strncmp_iw_mode): New.
5758 (strcmp_iw): Rename to ...
5759 (strncmp_iw_with_mode): ... this. Add string2_len and mode
5760 parameters. Handle them.
5762 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
5763 * utils.h (strncmp_iw): Declare.
5764 (strcmp_iw): Move describing comments here.
5766 2017-07-17 Pedro Alves <palves@redhat.com>
5768 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
5770 * c-typeprint.c (is_type_conversion_operator): Use
5772 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
5773 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
5775 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
5776 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
5777 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
5778 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
5780 * location.c: Include "cp-support.h".
5781 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
5783 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
5786 2017-07-17 Pedro Alves <palves@redhat.com>
5788 * cli/cli-cmds.c (complete_command): Use a completion tracker
5789 along with completion_find_completion_word for handle_brkchars
5791 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
5792 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
5793 (struct gdb_rl_completion_word_info): New.
5794 (gdb_rl_find_completion_word): New.
5795 (completion_find_completion_word): New.
5796 * completer.h (completion_find_completion_word): Declare.
5798 2017-07-17 Pedro Alves <palves@redhat.com>
5800 * ada-lang.c (symbol_completion_match): Adjust comments.
5801 (symbol_completion_add): Replace vector parameter with
5802 completion_tracker parameter. Use it.
5803 (ada_make_symbol_completion_list): Rename to...
5804 (ada_collect_symbol_completion_matches): ... this. Add
5805 completion_tracker parameter and use it.
5806 (ada_language_defn): Adjust.
5807 * break-catch-syscall.c (catch_syscall_completer): Adjust
5808 prototype and work with completion_tracker instead of VEC.
5809 * breakpoint.c (condition_completer): Adjust prototype and work
5810 with completion_tracker instead of VEC.
5811 * c-lang.c (c_language_defn, cplus_language_defn)
5812 (asm_language_defn, minimal_language_defn): Adjust to renames.
5813 * cli/cli-cmds.c (complete_command): Rework using
5814 completion_tracker. Catch exceptions when completing.
5815 * cli/cli-decode.c (integer_unlimited_completer)
5816 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
5817 with completion_tracker instead of VEC.
5818 * command.h (struct completion_tracker): Forward declare.
5819 (completer_ftype, completer_handle_brkchars_ftype): Change
5821 (complete_on_cmdlist, complete_on_enum): Adjust.
5822 * completer.c: Include <algorithm>.
5823 (struct gdb_completer_state): New.
5824 (current_completion): New global.
5825 (readline_line_completion_function): Delete.
5826 (noop_completer, filename_completer)
5827 (filename_completer_handle_brkchars, complete_files_symbols)
5828 (linespec_location_completer): Adjust to work with a
5829 completion_tracker instead of a VEC.
5830 (string_or_empty): New.
5831 (collect_explicit_location_matches): Adjust to work with a
5832 completion_tracker instead of a VEC.
5833 (explicit_location_completer): Rename to ...
5834 (complete_explicit_location): ... this and adjust to work with a
5835 completion_tracker instead of a VEC.
5836 (location_completer): Adjust to work with a completion_tracker
5838 (add_struct_fields): Adjust to work with a completion_list instead
5840 (expression_completer): Rename to ...
5841 (complete_expression): ... this and adjust to work with a
5842 completion_tracker instead of a VEC. Use complete_files_symbols.
5843 (expression_completer): Reimplement on top of complete_expression.
5844 (symbol_completer): Adjust to work with a completion_tracker
5846 (enum complete_line_internal_reason): Add describing comments.
5847 (complete_line_internal_normal_command): Adjust to work with a
5848 completion_tracker instead of a VEC.
5849 (complete_line_internal): Rename to ...
5850 (complete_line_internal_1): ... this and adjust to work with a
5851 completion_tracker instead of a VEC. Assert TEXT is NULL in the
5852 handle_brkchars phase.
5853 (new_completion_tracker): Delete.
5854 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
5855 complete_line_internal_1.
5856 (free_completion_tracker): Delete.
5857 (INITIAL_COMPLETION_HTAB_SIZE): New.
5858 (completion_tracker::completion_tracker)
5859 (completion_tracker::~completion_tracker): New.
5860 (maybe_add_completion): Delete.
5861 (completion_tracker::maybe_add_completion)
5862 (completion_tracker::add_completion)
5863 (completion_tracker::add_completions): New.
5864 (throw_max_completions_reached_error): Delete.
5865 (complete_line): Adjust to work with a completion_tracker instead
5866 of a VEC. Don't create a completion_tracker_t or check for max
5868 (command_completer, command_completer_handle_brkchars)
5869 (signal_completer, reg_or_group_completer_1)
5870 (reg_or_group_completer, default_completer_handle_brkchars):
5871 Adjust to work with a completion_tracker.
5872 (gdb_completion_word_break_characters_throw): New.
5873 (gdb_completion_word_break_characters): Reimplement.
5874 (line_completion_function): Delete.
5875 (completion_tracker::recompute_lowest_common_denominator)
5876 (expand_preserving_ws)
5877 (completion_tracker::build_completion_result)
5878 (completion_result::completion_result)
5879 (completion_result::completion_result)
5880 (completion_result::~completion_result)
5881 (completion_result::completion_result)
5882 (completion_result::release_match_list, compare_cstrings)
5883 (completion_result::sort_match_list)
5884 (completion_result::reset_match_list)
5885 (gdb_rl_attempted_completion_function_throw)
5886 (gdb_rl_attempted_completion_function): New.
5887 * completer.h (completion_list, struct completion_result)
5888 (class completion_tracker): New.
5889 (complete_line): Add completion_tracker parameter.
5890 (readline_line_completion_function): Delete.
5891 (gdb_rl_attempted_completion_function): New.
5892 (noop_completer, filename_completer, expression_completer)
5893 (location_completer, symbol_completer, command_completer)
5894 (signal_completer, reg_or_group_completer): Update prototypes.
5895 (completion_tracker_t, new_completion_tracker)
5896 (make_cleanup_free_completion_tracker): Delete.
5897 (enum maybe_add_completion_enum): Delete.
5898 (maybe_add_completion): Delete.
5899 (throw_max_completions_reached_error): Delete.
5900 * corefile.c (complete_set_gnutarget): Adjust to work with a
5901 completion_tracker instead of a VEC.
5902 * cp-abi.c (cp_abi_completer): Adjust to work with a
5903 completion_tracker instead of a VEC.
5904 * d-lang.c (d_language_defn): Adjust.
5905 * disasm.c (disassembler_options_completer): Adjust to work with a
5906 completion_tracker instead of a VEC.
5907 * f-lang.c (f_make_symbol_completion_list): Rename to ...
5908 (f_collect_symbol_completion_matches): ... this. Adjust to work
5909 with a completion_tracker instead of a VEC.
5910 (f_language_defn): Adjust.
5911 * go-lang.c (go_language_defn): Adjust.
5912 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
5913 Adjust to work with a completion_tracker instead of a VEC.
5914 * infrun.c (handle_completer): Likewise.
5915 * interps.c (interpreter_completer): Likewise.
5916 * interps.h (interpreter_completer): Likewise.
5917 * language.c (unknown_language_defn, auto_language_defn)
5918 (local_language_defn): Adjust.
5919 * language.h (language_defn::la_make_symbol_completion_list):
5921 (language_defn::la_collect_symbol_completion_matches): ... this
5922 and adjust to work with a completion_tracker instead of a VEC.
5923 * m2-lang.c (m2_language_defn): Adjust.
5924 * objc-lang.c (objc_language_defn): Adjust.
5925 * opencl-lang.c (opencl_language_defn): Adjust.
5926 * p-lang.c (pascal_language_defn): Adjust.
5927 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
5928 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
5929 with a completion_tracker.
5930 * rust-lang.c (rust_language_defn): Adjust.
5931 * symtab.c (free_completion_list, do_free_completion_list)
5932 (return_val, completion_tracker): Delete.
5933 (completion_list_add_name, completion_list_add_symbol)
5934 (completion_list_add_msymbol, completion_list_objc_symbol)
5935 (completion_list_add_fields, add_symtab_completions): Add
5936 completion_tracker parameter and use it.
5937 (default_make_symbol_completion_list_break_on_1): Rename to...
5938 (default_collect_symbol_completion_matches_break_on): ... this.
5939 Add completion_tracker parameter and use it instead of allocating
5940 a completion tracker here.
5941 (default_make_symbol_completion_list_break_on): Delete old
5943 (default_make_symbol_completion_list): Delete.
5944 (default_collect_symbol_completion_matches): New.
5945 (make_symbol_completion_list): Delete.
5946 (collect_symbol_completion_matches): New.
5947 (make_symbol_completion_type): Rename to ...
5948 (collect_symbol_completion_matches_type): ... this. Add
5949 completion_tracker parameter and use it instead of VEC.
5950 (make_file_symbol_completion_list_1): Rename to...
5951 (collect_file_symbol_completion_matches): ... this. Add
5952 completion_tracker parameter and use it instead of VEC.
5953 (make_file_symbol_completion_list): Delete.
5954 (add_filename_to_list): Use completion_list instead of a VEC.
5955 (add_partial_filename_data::list): Now a completion_list.
5956 (make_source_files_completion_list): Work with a completion_list
5958 * symtab.h: Include "completer.h".
5959 (default_make_symbol_completion_list_break_on)
5960 (default_make_symbol_completion_list, make_symbol_completion_list)
5961 (make_symbol_completion_type, make_file_symbol_completion_list)
5962 (make_source_files_completion_list): Delete.
5963 (default_collect_symbol_completion_matches_break_on)
5964 (default_collect_symbol_completion_matches)
5965 (collect_symbol_completion_matches)
5966 (collect_symbol_completion_matches_type)
5967 (collect_file_symbol_completion_matches)
5968 (make_source_files_completion_list): New.
5969 * top.c (init_main): Don't install a rl_completion_entry_function
5970 hook. Install a rl_attempted_completion_function hook instead.
5971 * tui/tui-layout.c (layout_completer): Adjust to work with a
5973 * tui/tui-regs.c (tui_reggroup_completer):
5974 * tui/tui-win.c (window_name_completer, focus_completer)
5975 (winheight_completer): Adjust to work with a completion_tracker.
5976 * value.c: Include "completer.h".
5977 (complete_internalvar): Adjust to work with a completion_tracker.
5978 * value.h (complete_internalvar): Likewise.
5980 2017-07-17 Pedro Alves <palves@redhat.com>
5982 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
5984 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
5985 comments to completer_ftype's declaration.
5986 <completer_handle_brkchars>: Change type to
5987 completer_handle_brkchars_ftype.
5988 * command.h (completer_ftype): Add describing comment and give
5989 names to parameters.
5990 (completer_ftype_void): Rename to ...
5991 (completer_handle_brkchars_ftype) ... this. Add describing comment.
5992 (set_cmd_completer_handle_brkchars): Adjust.
5993 * completer.c (filename_completer_handle_brkchars): New function.
5994 (complete_line_internal_normal_command): New function, factored
5996 (complete_line_internal): ... here.
5997 (command_completer_handle_brkchars)
5998 (default_completer_handle_brkchars)
5999 (completer_handle_brkchars_func_for_completer): New functions.
6000 * completer.h (set_gdb_completion_word_break_characters): Delete
6002 (completer_handle_brkchars_func_for_completer): New declaration.
6003 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
6004 completer_handle_brkchars_func_for_completer.
6006 2017-07-17 Pedro Alves <palves@redhat.com>
6008 * completer.c (symbol_completer): New function, based on
6009 make_symbol_completion_list_fn.
6010 * completer.h (symbol_completer): New declaration.
6011 * guile/scm-cmd.c (cmdscm_completers): Adjust.
6012 * python/py-cmd.c (completers): Adjust.
6013 * symtab.c (make_symbol_completion_list_fn): Delete.
6014 * symtab.h (make_symbol_completion_list_fn): Delete.
6015 * cli/cli-decode.c (add_cmd): Adjust.
6017 2017-07-17 Pedro Alves <palves@redhat.com>
6019 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
6020 * dwarf2read.c: Include "filename-seen-cache.h".
6021 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
6022 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
6023 * filename-seen-cache.c: New file.
6024 * filename-seen-cache.h: New file.
6025 * symtab.c: Include "filename-seen-cache.h".
6026 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
6027 (create_filename_seen_cache, clear_filename_seen_cache)
6028 (delete_filename_seen_cache, filename_seen): Delete, parts moved
6029 to filename-seen-cache.h/filename-seen-cache.c.
6030 (output_source_filename, sources_info)
6031 (maybe_add_partial_symtab_filename)
6032 (make_source_files_completion_list): Adjust to use
6033 filename_seen_cache.
6035 2017-07-17 Pedro Alves <palves@redhat.com>
6037 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
6039 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
6040 dwarf2_debug_sections*)): New.
6041 (dwarf2_per_objfile::dwarf2_per_objfile(const
6042 dwarf2_per_objfile&)): Declare as deleted.
6043 (dwarf2_per_objfile::operator=): Declare as deleted.
6044 (dwarf2_per_objfile::dwarf2_per_objfile)
6045 (dwarf2_per_objfile::~dwarf2_per_objfile)
6046 (dwarf2_per_objfile::free_cached_comp_units): New.
6047 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
6048 ctor. Call dwarf2_per_objfile's ctor manually.
6049 (dwarf2_locate_sections): Deleted/refactored as ...
6050 (dwarf2_per_objfile::locate_sections): ... this new method.
6051 (free_cached_comp_units): Defer to
6052 dwarf2_per_objfile::free_cached_comp_units.
6053 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
6055 2017-07-14 Tom Tromey <tom@tromey.com>
6058 * rust-exp.y (convert_ast_to_expression): Add "want_type"
6060 <UNOP_SIZEOF>: Split into separate case.
6061 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
6063 2017-07-14 Tom Tromey <tom@tromey.com>
6066 * symtab.c (symbol_matches_domain): Add language_rust to special
6068 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
6069 treat LOC_TYPEDEF symbols as variables.
6071 2017-07-14 Pedro Alves <palves@redhat.com>
6073 * symtab.c (make_file_symbol_completion_list_1): Iterate over
6074 symtabs matching all symtabs with SRCFILE as file name instead of
6075 only considering the first hit, with lookup_symtab.
6077 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
6079 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
6080 operator_name parameters.
6081 (gen_expr): Update function call.
6083 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
6085 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
6087 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
6089 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
6090 parameter, use agent_expr::gdbarch instead, update function
6092 (locexpr_tracepoint_var_ref): Likewise.
6093 (loclist_tracepoint_var_ref): Likewise.
6094 * ax-gdb.c (gen_trace_static_fields): Likewise.
6095 (gen_traced_pop): Likewise.
6096 (gen_frame_args_address): Likewise.
6097 (gen_frame_locals_address): Likewise.
6098 (gen_var_ref): Likewise.
6099 (gen_struct_ref_recursive): Likewise.
6100 (gen_static_field): Likewise.
6101 (gen_maybe_namespace_elt): Likewise.
6102 (gen_expr): Likewise.
6103 (gen_trace_for_var): Likewise.
6104 (gen_trace_for_expr): Likewise.
6105 (gen_trace_for_return_address): Likewise.
6107 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
6109 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
6111 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
6113 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
6115 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
6116 from ax, update calls.
6117 (gen_usual_arithmetic): Likewise.
6118 (gen_integral_promotions): Likewise.
6119 (gen_bitfield_ref): Likewise.
6120 (gen_primitive_field): Likewise.
6121 (gen_struct_ref_recursive): Likewise.
6122 (gen_struct_ref): Likewise.
6123 (gen_maybe_namespace_elt): Likewise.
6124 (gen_struct_elt_for_reference): Likewise.
6125 (gen_namespace_elt): Likewise.
6126 (gen_aggregate_elt_ref): Likewise.
6127 (gen_expr): Get gdbarch from ax, update calls.
6128 (gen_expr_binop_rest): Likewise.
6130 2017-07-13 Pedro Alves <palves@redhat.com>
6132 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
6134 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
6135 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
6136 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
6137 tdesc_amd64_linux as default tdesc. Get final tdesc from the
6139 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
6140 Get final tdesc from the tdep.
6141 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
6143 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
6144 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
6145 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
6146 Use it as default tdesc.
6147 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
6148 down to amd_init_abi. No longer handle fallback tdesc here.
6149 * amd64-tdep.h (tdesc_x32): Declare.
6150 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
6152 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
6155 2017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
6157 * s390-linux-tdep.c (s390_process_record): Add support for
6158 instructions new in arch12.
6160 2017-07-11 John Baldwin <jhb@FreeBSD.org>
6162 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
6163 PT_GETFSBASE and PT_GETGSBASE.
6164 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
6167 2017-07-11 John Baldwin <jhb@FreeBSD.org>
6169 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
6170 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
6171 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
6173 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
6174 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
6175 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
6176 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
6177 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
6178 * features/i386/amd64.xml: Add 64bit-segments.xml.
6179 * features/i386/amd64-avx-avx512.c: Regenerated.
6180 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
6181 * features/i386/amd64-avx-mpx.c: Regenerated.
6182 * features/i386/amd64-avx.c: Regenerated.
6183 * features/i386/amd64-mpx.c: Regenerated.
6184 * features/i386/amd64.c: Regenerated.
6185 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
6186 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
6187 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
6188 * regformats/i386/amd64-avx.dat: Regenerated.
6189 * regformats/i386/amd64-mpx.dat: Regenerated.
6190 * regformats/i386/amd64.dat: Regenerated.
6192 2017-07-10 Yao Qi <yao.qi@linaro.org>
6194 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
6195 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
6197 2017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
6199 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
6201 * gnulib/aclocal.m4: Regenerate.
6202 * gnulib/config.in: Regenerate.
6203 * gnulib/configure: Regenerate.
6204 * gnulib/import/Makefile.am: Regenerate.
6205 * gnulib/import/Makefile.in: Regenerate.
6206 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
6207 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
6208 * gnulib/import/m4/environ.m4: New file.
6209 * gnulib/import/m4/setenv.m4: New file.
6210 * gnulib/import/setenv.c: New file.
6211 * gnulib/import/unsetenv.c: New file.
6213 2017-07-09 Simon Marchi <simon.marchi@ericsson.com>
6215 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
6216 address when op is DW_OP_addr.
6218 2017-07-09 Tom Tromey <tom@tromey.com>
6220 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
6221 check and apply to outer type.
6223 2017-07-07 John Baldwin <jhb@FreeBSD.org>
6225 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
6226 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
6227 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
6228 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
6230 2017-07-07 John Baldwin <jhb@FreeBSD.org>
6232 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
6234 2017-07-07 John Baldwin <jhb@FreeBSD.org>
6236 * corelow.c (get_core_siginfo): Remove.
6237 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
6238 instead of get_core_siginfo.
6239 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
6240 * gdbarch.h: Re-generate.
6241 * gdbarch.c: Re-generate.
6242 * linux-tdep.c (linux_core_xfer_siginfo): New.
6243 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
6245 2017-07-07 John Baldwin <jhb@FreeBSD.org>
6247 * corelow.c (thread_section_name): Move to ...
6248 * gdbcore.h (thread_section_name): ... here.
6250 2017-07-07 John Baldwin <jhb@FreeBSD.org>
6252 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
6253 (struct siginfo32): New.
6254 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
6255 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
6256 via ptrace(PT_LWPINFO).
6258 2017-07-07 John Baldwin <jhb@FreeBSD.org>
6260 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
6261 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
6262 (fbsd_get_siginfo_type): New.
6263 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
6264 (_initialize_fbsd_tdep): New.
6266 2017-07-06 David Blaikie <dblaikie@gmail.com>
6268 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
6269 a singular dwo_unit*) to support multiple CUs in the same way that
6270 multiple TUs are supported.
6271 (create_cus_hash_table): Replace create_dwo_cu with a function for
6272 parsing multiple CUs from a DWO file.
6273 (open_and_init_dwo_file): Use create_cus_hash_table rather than
6275 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
6276 htab_find, rather than comparing the signature to a singleton CU in
6279 2017-07-06 Pedro Alves <palves@redhat.com>
6281 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
6283 2017-07-04 Pedro Alves <palves@redhat.com>
6285 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
6286 * gdbtypes.h (TYPE_STATIC): Delete.
6287 (struct fn_field) <is_public, is_abstract, is_static, is_final,
6288 is_synchronized, is_native>: Delete.
6290 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
6291 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
6292 (TYPE_FN_FIELD_ABSTRACT): Delete.
6294 2017-07-03 Simon Marchi <simon.marchi@ericsson.com>
6296 * buffer.h (buffer_finish): Fix spelling mistakes.
6298 2017-07-01 Eli Zaretskii <eliz@gnu.org>
6300 * .dir-locals.el: Automatically switch to C-style comments in
6301 versions of Emacs that support the feature.
6303 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
6304 Pedro Alves <palves@redhat.com>
6307 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
6308 (process_next_line): New variable 'inline_cmd'.
6309 Adjust 'if' clauses for "python", "compile" and "guile" to use
6310 'command_name_equals' and check for '!inline_cmd'.
6312 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
6315 * cli/cli-script.c (command_name_equals_not_inline): New function.
6316 (process_next_line): Adjust 'if' clauses for "python", "compile"
6317 and "guile" to use command_name_equals_not_inline.
6319 2017-06-29 Pedro Alves <palves@redhat.com>
6321 * completer.c (expression_completer): Call
6322 linespec_location_completer instead of location_completer.
6324 2017-06-29 Pedro Alves <palves@redhat.com>
6326 * completer.c (expression_completer): Remove code that recomputes
6329 2017-06-29 Yao Qi <yao.qi@linaro.org>
6331 * regformats/regdat.sh: Generate code with
6332 "ifndef IN_PROCESS_AGENT".
6334 2017-06-28 Pedro Alves <palves@redhat.com>
6336 * command.h: Include "common/scoped_restore.h".
6338 2017-06-28 Yao Qi <yao.qi@linaro.org>
6340 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
6341 instead of obstack_grow.
6343 2017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
6346 * symfile.c (reread_symbols): Call objfiles_changed just before
6349 2017-06-27 Pedro Alves <palves@redhat.com>
6351 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
6352 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
6353 (completion_list_add_symbol, completion_list_add_msymbol):
6354 ... these new functions.
6355 (add_symtab_completions)
6356 (default_make_symbol_completion_list_break_on_1): Adjust.
6358 2017-06-27 Pedro Alves <palves@redhat.com>
6360 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
6361 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
6362 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
6364 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
6365 'storage_obstack' field an auto_obstack. In-class initialize all
6366 non-bitfield fields. Make minsyms_read bool.
6367 * symfile.c (read_symbols): Adjust.
6369 2017-06-27 Alan Hayward <alan.hayward@arm.com>
6371 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
6372 (gdbsim_store_register): Likewise.
6374 2017-06-27 Pedro Alves <palves@redhat.com>
6376 * c-exp.y (name_obstack): Now an auto_obstack.
6377 (yylex): Use auto_obstack::clear.
6378 (c_parse): Use auto_obstack::clear instead of reinitializing and
6379 freeing the obstack.
6380 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
6381 * d-exp.y (name_obstack): Now an auto_obstack.
6382 (yylex): Use auto_obstack::clear.
6383 (d_parse): Use auto_obstack::clear instead of reinitializing and
6384 freeing the obstack.
6385 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
6387 * dwarf2read.c (create_addrmap_from_index)
6388 (dwarf2_build_psymtabs_hard)
6389 (update_enumeration_type_from_children): Likewise.
6390 * gdb_obstack.h (auto_obstack): New type.
6391 * go-exp.y (name_obstack): Now an auto_obstack.
6392 (build_packaged_name): Use auto_obstack::clear.
6393 (go_parse): Use auto_obstack::clear instead of reinitializing and
6394 freeing the obstack.
6395 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
6397 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
6398 * rust-exp.y (work_obstack): Now an auto_obstack.
6399 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
6400 reinitializing and freeing the obstack.
6401 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
6402 (host_char_to_target): Use auto_obstack.
6403 * utils.h (make_cleanup_obstack_free): Delete declaration.
6404 * valprint.c (generic_emit_char, generic_printstr): Use
6407 2017-06-27 Simon Marchi <simon.marchi@ericsson.com>
6409 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
6411 (darwin_init_thread_list): Don't update dummy thread.
6412 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
6414 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
6416 * record-full.c (netorder16): Remove.
6418 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
6420 * common/diagnostics.h: Define macros for GCC.
6421 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
6422 * common/vec.h: Include diagnostics.h.
6423 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
6424 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
6427 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
6429 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
6431 * ada-lex.l: Ignore deprecated register warnings.
6433 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
6435 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
6436 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
6438 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
6440 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
6443 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
6445 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
6447 2017-06-23 Alan Hayward <alan.hayward@arm.com>
6449 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
6450 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
6451 (xtensa_register_read_masked): Likewise.
6453 2017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
6455 * common/environ.c (gdb_environ::unset): Update comment.
6457 2017-06-22 Alan Hayward <alan.hayward@arm.com>
6459 * python/py-unwind.c (pyuw_sniffer): Allocate space for
6462 2017-06-22 Alan Hayward <alan.hayward@arm.com>
6464 * record-full.c (record_full_exec_insn): Use byte_vector.
6466 2017-06-22 Yao Qi <yao.qi@linaro.org>
6468 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
6469 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
6471 2017-06-22 Alan Hayward <alan.hayward@arm.com>
6473 * remote.c (cached_reg): Move from here...
6474 * regcache.h (cached_reg): ...to here.
6475 * python/py-unwind.c (struct reg_info): Remove.
6476 (cached_frame_info): Use cached_reg_t.
6477 (pyuw_prev_register): Likewise.
6478 (pyuw_sniffer): Use cached_reg_t and allocate registers.
6479 (pyuw_dealloc_cache): Free all registers.
6481 2017-06-22 Pedro Alves <palves@redhat.com>
6482 Simon Marchi <simon.marchi@ericsson.com>
6484 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
6486 * common/diagnostics.h: New file.
6488 2017-06-22 Pedro Alves <palves@redhat.com>
6490 * common/agent.h: Add include guards.
6492 2017-06-21 Simon Marchi <simon.marchi@ericsson.com>
6494 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
6495 talk about addressable units instead of bytes.
6497 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
6499 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
6500 of '::const_iterator'.
6502 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
6504 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6505 'unittests/environ-selftests.c'.
6506 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
6507 * charset.c (find_charset_names): Declare object 'iconv_env'.
6508 Update code to use 'iconv_env' object. Remove call to
6510 * common/environ.c: Include <utility>.
6511 (make_environ): Delete function.
6512 (free_environ): Delete function.
6513 (gdb_environ::clear): New function.
6514 (gdb_environ::operator=): New function.
6515 (gdb_environ::get): Likewise.
6516 (environ_vector): Delete function.
6517 (set_in_environ): Delete function.
6518 (gdb_environ::set): New function.
6519 (unset_in_environ): Delete function.
6520 (gdb_environ::unset): New function.
6521 (gdb_environ::envp): Likewise.
6522 * common/environ.h: Include <vector>.
6523 (struct gdb_environ): Delete; transform into...
6524 (class gdb_environ): ... this class.
6525 (free_environ): Delete prototype.
6526 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
6527 environ_vector): Likewise.
6528 * infcmd.c (run_command_1): Update code to call
6529 'envp' from 'gdb_environ' class.
6530 (environment_info): Update code to call methods from 'gdb_environ'
6532 (unset_environment_command): Likewise.
6533 (path_info): Likewise.
6534 (path_command): Likewise.
6535 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
6536 (inferior::inferior): Initialize 'environment' using the host's
6538 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
6539 Include "environ.h".
6540 (class inferior) <environment>: Change type from 'struct
6541 gdb_environ' to 'gdb_environ'.
6542 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
6543 methods from 'gdb_environ' class.
6544 * solib.c (solib_find_1): Likewise
6545 * unittests/environ-selftests.c: New file.
6547 2017-06-20 Yao Qi <yao.qi@linaro.org>
6549 * features/i386/i386-linux.xml: Exchange the order of including
6550 32bit-linux.xml and 32bit-sse.xml.
6551 * features/i386/i386-linux.c: Regenerated.
6553 2017-06-20 Yao Qi <yao.qi@linaro.org>
6555 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
6556 Delete copy ctor and assignment operator.
6557 (tdesc_type): Likewise.
6558 (tdesc_feature): Likewise.
6559 (tdesc_free_reg): Remove.
6560 (tdesc_create_reg): Use new.
6561 (tdesc_free_type): Remove.
6562 (tdesc_create_vector): Use new.
6563 (tdesc_create_union): Likewise.
6564 (tdesc_create_flags): Likewise.
6565 (tdesc_create_enum): Likewise.
6566 (tdesc_free_feature): Delete.
6567 (free_target_description): Use delete.
6569 2017-06-19 John Baldwin <jhb@FreeBSD.org>
6571 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
6574 2017-06-19 Pedro Alves <palves@redhat.com>
6576 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
6577 after gdb::unlinker.
6579 2017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
6581 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
6582 gdb_environ to access an environment variable.
6584 2017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
6586 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
6589 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6591 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
6593 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6595 * configure: Re-generate.
6596 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
6598 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6600 * configure: Re-generate.
6601 * warning.m4: Pass -Werror to compiler when checking for
6602 supported warning flags.
6604 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
6606 * Makefile.in (COMPILE.pre): Add "-x c++".
6608 2017-06-16 Alan Hayward <alan.hayward@arm.com>
6609 Pedro Alves <palves@redhat.com>
6610 Yao Qi <yao.qi@linaro.org>
6612 * defs.h (RequireLongest): New.
6613 (extract_integer): Declare function template.
6614 (extract_signed_integer): Remove the declaration, but define it
6616 (extract_unsigned_integer): Likewise.
6617 (store_integer): Declare function template.
6618 (store_signed_integer): Remove the declaration, but define it
6620 (store_unsigned_integer): Likewise.
6621 * findvar.c (extract_integer): New function template.
6622 (extract_signed_integer): Remove.
6623 (extract_unsigned_integer): Remove.
6624 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
6626 (store_integer): New function template.
6627 (store_signed_integer): Remove.
6628 (store_unsigned_integer): Remove.
6629 (store_integer): Explicit instantiations.
6630 * regcache.c (regcache_raw_read_signed): Update.
6631 (regcache::raw_read): New function.
6632 (regcache::raw_read_signed): Remove.
6633 (regcache::raw_read_unsigned): Remove.
6634 (regcache_raw_read_unsigned): Update.
6635 (regcache_raw_write_unsigned): Update.
6636 (regcache::raw_write_signed): Remove.
6637 (regcache::raw_write): New function.
6638 (regcache_cooked_read_signed): Update.
6639 (regcache::raw_write_unsigned): Remove.
6640 (regcache::cooked_read_signed): Remove.
6641 (regcache_cooked_read_unsigned): Update.
6642 (regcache::cooked_read_unsigned): Remove.
6643 (regcache_cooked_write_signed): Update.
6644 (regcache_cooked_write_unsigned): Update.
6645 * regcache.h (regcache) <raw_read_signed>: Remove.
6646 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
6647 <raw_read, raw_write>: New.
6648 <cooked_read_signed, cooked_write_signed>: Remove.
6649 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
6650 <cooked_read, cooked_write>: New.
6651 * sh64-tdep.c (sh64_pseudo_register_read): Update.
6652 (sh64_pseudo_register_write): Update.
6654 2017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
6656 * arc-tdep.c (arc_disassembler_options): New variable.
6657 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
6658 of default_print_insn.
6659 (arc_delayed_print_insn): Set info->section when needed,
6660 use default_print_insn to retrieve a disassembler.
6662 2017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
6665 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
6666 to mention $SHELL and startup-with-shell.
6668 2017-06-14 Max Filippov <jcmvbkbc@gmail.com>
6670 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
6672 2017-06-14 Yao Qi <yao.qi@linaro.org>
6674 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
6675 default_print_insn instead of print_insn_aarch64.
6676 * arm-tdep.c (gdb_print_insn_arm): Call
6677 default_print_insn instead of print_insn_big_arm
6678 and print_insn_little_arm.
6679 * i386-tdep.c (i386_print_insn): Call default_print_insn
6680 instead of print_insn_i386.
6681 * ia64-tdep.c (ia64_print_insn): Call
6682 default_print_insn instead of print_insn_ia64.
6683 * mips-tdep.c (gdb_print_insn_mips): Call
6684 default_print_insn instead of print_insn_big_mips
6685 and print_insn_little_mips.
6686 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
6687 instead of print_insn_spu.
6689 2017-06-14 Pedro Alves <palves@redhat.com>
6691 * ada-lang.c: Include "common/byte-vector.h".
6692 (ada_value_primitive_packed_val): Use gdb::byte_vector.
6693 * charset.c (wchar_iterator::iterate): Resize the vector instead
6695 * common/byte-vector.h: Include "common/def-vector.h".
6696 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
6697 * cli/cli-dump.c: Include "common/byte-vector.h".
6698 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
6699 * common/byte-vector.h: New file.
6700 * common/def-vector.h: New file.
6701 * common/default-init-alloc.h: New file.
6702 * dwarf2loc.c: Include "common/byte-vector.h".
6703 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
6704 instead of reserving it.
6705 * dwarf2read.c: Include "common/byte-vector.h".
6706 (data_buf::m_vec): Now a gdb::byte_vector.
6707 * gdb_regex.c: Include "common/def-vector.h".
6708 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
6709 * mi/mi-main.c: Include "common/byte-vector.h".
6710 (mi_cmd_data_read_memory): Use gdb::byte_vector.
6711 * printcmd.c: Include "common/byte-vector.h".
6712 (print_scalar_formatted): Use gdb::byte_vector.
6713 * valprint.c: Include "common/byte-vector.h".
6714 (maybe_negate_by_bytes, print_decimal_chars): Use
6717 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
6719 * darwin-nat.c: Include "nat/fork-inferior.h".
6721 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
6723 * configure.nat: Factor out Darwin bits that are not
6724 architecture-specific. Add fork-inferior.o.
6726 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
6728 * configure.nat: Factor out AIX bits that are not
6729 architecture-specific. Add fork-inferior.o.
6731 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
6733 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
6734 (read_pieced_value, write_pieced_value): ...here. Reduce to
6735 wrappers that just call rw_pieced_value.
6737 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
6739 * dwarf2loc.c (write_pieced_value): When writing the data for a
6740 memory piece, use write_memory_with_notification instead of
6743 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
6745 * valops.c (read_value_memory): Change embedded_offset to
6746 represent a bit offset instead of a byte offset.
6747 * value.h (read_value_memory): Adjust comment.
6749 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
6751 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
6752 dest_offset_bits and source_offset_bits.
6753 (write_pieced_value): Likewise.
6755 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
6757 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
6758 given by DW_OP_bit_piece.
6759 (write_pieced_value): Likewise.
6761 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
6763 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
6764 some other preparations to the places where sufficient information
6766 (write_pieced_value): Likewise.
6768 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
6770 * dwarf2loc.c (bits_to_bytes): New function.
6771 (read_pieced_value): Fix offset calculations for register pieces
6772 on big-endian targets.
6773 (write_pieced_value): Likewise.
6775 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
6777 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
6778 (write_pieced_value): Likewise.
6780 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
6782 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
6783 transfer the source value's least significant bits, instead of its
6784 lowest-addressed ones. Rename type_len to max_offset.
6785 (read_pieced_value): Mirror above changes to write_pieced_value as
6788 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
6790 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
6791 truncate full bytes from dest_offset_bits before using it as an
6792 offset into the buffer.
6794 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
6796 * dwarf2loc.c (write_pieced_value): Include transfer size in
6799 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
6801 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
6802 calculation of this_size.
6804 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
6806 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
6807 when targeting a bit-field.
6808 (write_pieced_value): Likewise.
6810 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
6812 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
6813 (allocate_piece_closure): Drop addr_size parameter.
6814 (dwarf2_evaluate_loc_desc_full): Adjust call to
6815 allocate_piece_closure.
6817 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
6820 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
6821 the LSB end, independent of endianness.
6823 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
6825 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
6828 2017-06-13 Yao Qi <yao.qi@linaro.org>
6830 * mips-linux-nat.c: Move include features/mips*-linux.c to
6832 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
6833 to mips-linux-tdep.c.
6834 * mips-linux-tdep.c: Include features/mips*-linux.c
6835 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
6837 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
6838 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
6839 (tdesc_mips64_dsp_linux): Declare.
6841 2017-06-12 Tom Tromey <tom@tromey.com>
6843 * valprint.h (val_print_type_code_int): Remove.
6844 * valprint.c (generic_val_print_int): Always call
6845 val_print_scalar_formatted.
6846 (val_print_type_code_int): Remove.
6847 * printcmd.c (print_scalar_formatted): Handle options->format==0.
6848 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
6849 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
6850 * ada-valprint.c (ada_val_print_num): Use
6851 val_print_scalar_formatted.
6853 2017-06-12 Tom Tromey <tom@tromey.com>
6855 * printcmd.c (print_scalar_formatted): Unify the two switches.
6856 Don't convert scalars to LONGEST.
6858 2017-06-12 Tom Tromey <tom@tromey.com>
6861 * valprint.h (print_decimal_chars): Update.
6862 * valprint.c (maybe_negate_by_bytes): New function.
6863 (print_decimal_chars): Add "is_signed" argument.
6864 * printcmd.c (print_scalar_formatted): Update.
6866 2017-06-12 Tom Tromey <tom@tromey.com>
6869 * valprint.h (print_binary_chars, print_hex_chars): Update.
6870 * valprint.c (val_print_type_code_int): Update.
6871 (print_binary_chars): Add "zero_pad" argument.
6872 (emit_octal_digit): New function.
6873 (print_octal_chars): Don't zero-pad.
6874 (print_decimal_chars): Likewise.
6875 (print_hex_chars): Add "zero_pad" argument.
6876 * sh64-tdep.c (sh64_do_fp_register): Update.
6877 * regcache.c (regcache::dump): Update.
6878 * printcmd.c (print_scalar_formatted): Update.
6879 * infcmd.c (default_print_one_register_info): Update.
6881 2017-06-12 Pedro Alves <palves@redhat.com>
6882 Alan Hayward <alan.hayward@arm.com>
6884 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
6885 (mips_eabi_push_dummy_call): Rename local 'regsize' to
6886 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
6887 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
6888 Assert that abi_regsize bytes fit in 'ref_valbuf'.
6890 2017-06-12 Pedro Alves <palves@redhat.com>
6892 * dwarf2read.c (mapped_symtab::data): Now a vector of
6893 symtab_index_entry instead of vector of
6894 std::unique_ptr<symtab_index_entry>. All users adjusted to check
6895 whether an element's name is NULL instead of checking whether the
6896 element itself is NULL.
6897 (find_slot): Change return type. Adjust.
6898 (hash_expand, , add_index_entry, uniquify_cu_indices)
6899 (write_hash_table): Adjust.
6901 2017-06-12 Pedro Alves <palves@redhat.com>
6903 * dwarf2read.c (recursively_count_psymbols): New function.
6904 (write_psymtabs_to_index): Call it to compute number of psyms and
6905 pass estimate size of psyms_seen to unordered_set's ctor.
6907 2017-06-12 Pedro Alves <palves@redhat.com>
6909 * dwarf2read.c (write_hash_table): Check if key already exists
6912 2017-06-12 Pedro Alves <palves@redhat.com>
6914 * dwarf2read.c (data_buf::append_space): Rename to...
6915 (data_buf::grow): ... this, and make private. Adjust all callers.
6916 (data_buf::append_uint): New method.
6917 (add_address_entry, write_one_signatured_type)
6918 (write_psymtabs_to_index): Use it.
6920 2017-06-12 Pedro Alves <palves@redhat.com>
6922 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
6923 (file_write (FILE *, const std::vector<Elem>&)): Delete.
6924 (data_buf::file_write): Call ::fwrite directly.
6926 2017-06-12 Pedro Alves <palves@redhat.com>
6928 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
6931 2017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
6933 Code cleanup: C++ify .gdb_index producer.
6934 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
6935 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
6936 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
6937 (create_strtab, add_string): Remove.
6938 (file_write, data_buf): New.
6939 (struct symtab_index_entry): Use std::vector for cu_indices.
6940 (struct mapped_symtab): Use std::vector for data.
6941 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
6942 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
6944 (find_slot): Change return type. Update it to the new data structures.
6945 (hash_expand, add_index_entry): Update it to the new data structures.
6946 (offset_type_compare): Remove.
6947 (uniquify_cu_indices): Update it to the new data structures.
6948 (c_str_view, c_str_view_hasher, vector_hasher): New.
6949 (add_indices_to_cpool): Remove.
6950 (write_hash_table): Update it to the new data structures.
6951 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
6952 (eq_psymtab_cu_index): Remove.
6953 (psym_index_map): New typedef.
6954 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
6955 reference and std::unordered_map for cu_index_htab.
6956 (add_address_entry, add_address_entry_worker, write_address_map)
6957 (write_psymbols): Update it to the new data structures.
6958 (write_obstack): Remove.
6959 (struct signatured_type_index_data): Change types_list to a data_buf
6960 reference and psyms_seen to a std::unordered_set reference.
6961 (write_one_signatured_type, recursively_write_psymbols)
6962 (write_psymtabs_to_index): Update it to the new data structures.
6964 2017-06-11 Simon Marchi <simon.marchi@ericsson.com>
6966 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
6967 separate-debug-file commands.
6968 * symfile.h (separate_debug_file_debug): New global.
6969 * symfile.c (separate_debug_file_debug): New global.
6970 (separate_debug_file_exists, find_separate_debug_file): Add
6972 (_initialize_symfile): Add "set debug separate-debug-file"
6974 * build-id.c (build_id_to_debug_bfd,
6975 find_separate_debug_file_by_buildid): Add debug output.
6977 2017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
6979 * gdbarch.sh (displaced_step_free_closure): Remove.
6980 * gdbarch.h, gdbarch.c: Re-generate.
6981 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
6982 displaced_step_free_closure.
6983 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
6984 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
6985 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
6986 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
6987 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
6988 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
6989 * arch-utils.h (simple_displaced_step_free_closure): Remove.
6990 * arch-utils.c (simple_displaced_step_free_closure): Remove.
6991 * infrun.c (displaced_step_clear): Call xfree instead of
6992 gdbarch_displaced_step_free_closure.
6994 2017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
6996 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
6999 2017-06-08 Alan Hayward <alan.hayward@arm.com>
7001 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
7002 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
7003 (mn10300_push_dummy_call): Likewise.
7005 2017-06-08 Alan Hayward <alan.hayward@arm.com>
7007 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
7009 2017-06-08 Alan Hayward <alan.hayward@arm.com>
7011 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
7013 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7015 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
7016 able to start inferiors using a shell.
7017 (New remote packets): Announce new packet "QStartupWithShell".
7018 * remote.c: Add PACKET_QStartupWithShell.
7019 (extended_remote_create_inferior): Handle new
7020 PACKET_QStartupWithShell.
7021 (remote_protocol_features) <QStartupWithShell>: New entry for
7022 PACKET_QStartupWithShell.
7023 (_initialize_remote): Call "add_packet_config_cmd" for
7026 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7027 Pedro Alves <palves@redhat.com>
7029 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
7030 and "nat/fork-inferior.h".
7031 * common/common-inferior.h: New file, with contents from
7033 * commom/common-utils.c: Include "common-utils.h".
7034 (stringify_argv): New function.
7035 * common/common-utils.h (stringify_argv): New prototype.
7036 * configure.nat: Add "fork-inferior.o" as a dependency for
7037 "*linux*", "fbsd*" and "nbsd*" hosts.
7038 * corefile.c (get_exec_file): Update comment.
7039 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
7040 instead of "startup_inferior".
7041 (darwin_create_inferior): Call "add_thread_silent" after
7043 * fork-child.c: Cleanup unnecessary includes.
7044 (SHELL_FILE): Move to "common/common-fork-child.c".
7045 (environ): Likewise.
7046 (exec_wrapper): Initialize.
7047 (get_exec_wrapper): New function.
7048 (breakup_args): Move to "common/common-fork-child.c"; rename to
7049 "breakup_args_for_exec".
7050 (escape_bang_in_quoted_argument): Move to
7051 "common/common-fork-child.c".
7052 (saved_ui): New variable.
7053 (prefork_hook): New function.
7054 (postfork_hook): Likewise.
7055 (postfork_child_hook): Likewise.
7056 (gdb_startup_inferior): Likewise.
7057 (fork_inferior): Move to "common/common-fork-child.c". Update
7058 function to support gdbserver.
7059 (startup_inferior): Likewise.
7060 * gdbcore.h (get_exec_file): Remove declaration.
7061 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
7062 instead of "startup_inferior". Call "add_thread_silent" after
7064 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
7065 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
7066 instead of "startup_inferior". Call "add_thread_silent" after
7068 * inferior.h: Include "common-inferior.h".
7069 (trace_start_error): Move to "common/common-utils.h".
7070 (trace_start_error_with_name): Likewise.
7071 (fork_inferior): Move prototype to "nat/fork-inferior.h".
7072 (startup_inferior): Likewise.
7073 (gdb_startup_inferior): New prototype.
7074 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
7075 * nat/fork-inferior.h: New file.
7076 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
7077 instead of "startup_inferior". Call "add_thread_silent" after
7079 * target.h (target_terminal_init): Move prototype to
7081 (target_terminal_inferior): Likewise.
7082 (target_terminal_ours): Likewise.
7083 * target/target.h (target_terminal_init): New prototype, moved
7085 (target_terminal_inferior): Likewise.
7086 (target_terminal_ours): Likewise.
7087 * utils.c (gdb_flush_out_err): New function.
7089 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7091 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
7092 * common/common-gdbthread.h: New file, with parts from
7094 * gdbthread.h: Include "common-gdbthread.h".
7095 (switch_to_thread): Moved to "common/common-gdbthread.h".
7097 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7099 * Makefile.in (SFILES): Add "common/job-control.c".
7100 (HFILES_NO_SRCDIR): Add "common/job-control.h".
7101 (COMMON_OBS): Add "job-control.o".
7102 * common/job-control.c: New file, with contents from
7104 * common/job-control.h: New file, with contents from "terminal.h".
7105 * fork-child.c: Include "job-control.h".
7106 * inflow.c: Include "job-control.h".
7107 (gdb_setpgid): Move to "common/common-inflow.c".
7108 (_initialize_inflow): Move setting of "job_control" to
7109 "handle_job_control".
7110 * terminal.h (job_control): Moved to "common/common-terminal.h".
7111 (gdb_setpgid): Likewise.
7112 * top.c: Include "job_control.h".
7113 * utils.c: Likewise.
7114 (job_control): Moved to "job-control.c".
7116 2017-06-07 Pedro Alves <palves@redhat.com>
7118 * Makefile.in (SFILES): Add gdb_regex.c.
7119 (COMMON_OBS): Add gdb_regex.o.
7120 * ada-lang.c (ada_add_standard_exceptions)
7121 (ada_add_exceptions_from_frame, name_matches_regex)
7122 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
7123 parameter type to compiled_regex. Adjust.
7124 (ada_exceptions_list): Use compiled_regex.
7125 * break-catch-throw.c (exception_catchpoint::pattern): Now a
7126 std::unique_ptr<compiled_regex>.
7127 (exception_catchpoint::~exception_catchpoint): Remove regfree
7129 (check_status_exception_catchpoint): Adjust to use compiled_regex.
7130 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
7131 * breakpoint.c (solib_catchpoint::compiled): Now a
7132 std::unique_ptr<compiled_regex>.
7133 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
7134 (check_status_catch_solib): Adjust to use compiled_regex.
7135 (add_solib_catchpoint): Adjust to use compiled_regex.
7136 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
7137 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
7138 compiled_regex reference. Adjust to use it.
7139 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
7140 declaration. Include "gdb_regex.h".
7141 (apropos_cmd): Change regex parameter to compiled_regex reference.
7142 * gdb_regex.c: New file.
7143 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
7145 (class compiled_regex): New.
7146 * linux-tdep.c: Include "common/gdb_optional.h".
7147 (struct mapping_regexes): New, factored out from
7148 mapping_is_anonymous_p, and adjusted to use compiled_regex.
7149 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
7150 gdb::optional and remove cleanups. Adjust to compiled_regex.
7151 * probe.c: Include "common/gdb_optional.h".
7152 (collect_probes): Use compiled_regex and gdb::optional and remove
7154 * skip.c: Include "common/gdb_optional.h".
7155 (skiplist_entry::compiled_function_regexp): Now a
7156 gdb::optional<compiled_regex>.
7157 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
7158 (free_skiplist_entry): Remove regfree call.
7159 (compile_skip_regexp, skip_rfunction_p): Adjust to use
7160 compiled_regex and gdb::optional.
7161 * symtab.c: Include "common/gdb_optional.h".
7162 (search_symbols): Use compiled_regex and gdb::optional.
7163 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
7164 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
7167 2017-06-07 Alan Hayward <alan.hayward@arm.com>
7169 * regcache.c (regcache::save): Avoid buffer use.
7170 (regcache::dump): Likewise.
7172 2017-06-07 Alan Hayward <alan.hayward@arm.com>
7174 * sh-tdep.c (sh_pseudo_register_read): Remove
7176 (sh_pseudo_register_write): Likewise.
7177 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
7178 (sh64_pseudo_register_write): Likewise
7180 2017-06-07 Alan Hayward <alan.hayward@arm.com>
7182 * aarch64-tdep.c (aarch64_store_return_value): Use
7184 (aarch64_pseudo_read_value): Likewise.
7185 (aarch64_pseudo_write): Likewise.
7187 2017-06-06 Yao Qi <yao.qi@linaro.org>
7189 * regformats/regdef.h (set_register_cache): Remove the
7192 2017-06-06 Alan Hayward <alan.hayward@arm.com>
7194 * frame.c (frame_unwind_register_signed): Use
7195 frame_unwind_register_value.
7197 2017-06-06 Pedro Alves <palves@redhat.com>
7199 PR breakpoints/21553
7200 * breakpoint.c (create_breakpoints_sal_default)
7201 (init_breakpoint_sal, create_breakpoint_sal): Use
7202 gdb::unique_xmalloc_ptr for string parameters.
7203 (create_breakpoint): Constify 'extra_string' and 'cond_string'
7204 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
7205 (base_breakpoint_create_breakpoints_sal)
7206 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
7207 (strace_marker_create_breakpoints_sal)
7208 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
7210 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
7211 gdb::unique_xmalloc_ptr for string parameters.
7212 (create_breakpoint): Constify 'extra_string' and 'cond_string'
7215 2017-06-06 Alan Hayward <alan.hayward@arm.com>
7217 * alpha-tdep.c (alpha_register_to_value): Use
7218 get_frame_register_value.
7219 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
7221 2017-06-06 Alan Hayward <alan.hayward@arm.com>
7223 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
7224 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
7225 (ia64_value_to_register): Likewise.
7226 (ia64_extract_return_value): Likewise.
7227 (ia64_store_return_value): Likewise.
7228 (ia64_push_dummy_call): Likewise.
7230 2017-06-04 Joel Brobecker <brobecker@adacore.com>
7234 2017-06-03 Simon Marchi <simon.marchi@ericsson.com>
7236 * x86-linux-nat.c (struct arch_lwp_info): Remove.
7238 2017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
7240 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
7242 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
7244 2017-06-02 Simon Marchi <simon.marchi@ericsson.com>
7246 * event-loop.c (poll_timers): Unallocate timer using delete
7249 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
7251 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
7252 (struct breakpoint) <~breakpoint>: New.
7253 (struct watchpoint): Inherit from breakpoint.
7256 (struct tracepoint): Inherit from breakpoint.
7258 * breakpoint.c (longjmp_breakpoint_ops): Remove.
7259 (struct longjmp_breakpoint): Inherit from breakpoint.
7260 <~longjmp_breakpoint>: New.
7262 (new_breakpoint_from_type): Remove casts.
7263 (watchpoint_in_thread_scope): Remove reference to base field.
7264 (watchpoint_del_at_next_stop): Likewise.
7265 (update_watchpoint): Likewise.
7266 (watchpoint_check): Likewise.
7267 (bpstat_check_watchpoint): Likewise.
7268 (set_longjmp_breakpoint): Likewise.
7269 (struct fork_catchpoint): Inherit from breakpoint.
7271 (struct solib_catchpoint): Inherit from breakpoint.
7272 <~solib_catchpoint>: New.
7274 (dtor_catch_solib): Change to ...
7275 (solib_catchpoint::~solib_catchpoint): ... this.
7276 (breakpoint_hit_catch_solib): Remove reference to base field.
7277 (add_solib_catchpoint): Likewise.
7278 (create_fork_vfork_event_catchpoint): Likewise.
7279 (struct exec_catchpoint): Inherit from breakpoint.
7280 <~exec_catchpoint>: New.
7282 (dtor_catch_exec): Change to ...
7283 (exec_catchpoint::~exec_catchpoint): ... this.
7284 (dtor_watchpoint): Change to ...
7285 (watchpoint::~watchpoint): ... this.
7286 (watch_command_1): Remove reference to base field.
7287 (catch_exec_command_1): Likewise.
7288 (base_breakpoint_dtor): Change to ...
7289 (breakpoint::~breakpoint): ... this.
7290 (base_breakpoint_ops): Remove dtor field value.
7291 (longjmp_bkpt_dtor): Change to ...
7292 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
7293 (strace_marker_create_breakpoints_sal): Remove reference to base
7295 (delete_breakpoint): Don't manually call breakpoint destructor.
7296 (create_tracepoint_from_upload): Remove reference to base field.
7297 (trace_pass_set_count): Likewise.
7298 (initialize_breakpoint_ops): Don't initialize
7299 momentary_breakpoint_ops, don't set dtors.
7300 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
7301 <~ada_catchpoint>: New.
7303 (create_excep_cond_exprs): Remove reference to base field.
7304 (dtor_exception): Change to ...
7305 (ada_catchpoint::~ada_catchpoint): ... this.
7306 (dtor_catch_exception): Remove.
7307 (dtor_catch_exception_unhandled): Remove.
7308 (dtor_catch_assert): Remove.
7309 (create_ada_exception_catchpoint): Remove reference to base
7311 (initialize_ada_catchpoint_ops): Don't set dtors.
7312 * break-catch-sig.c (struct signal_catchpoint): Inherit from
7314 <~signal_catchpoint>: New.
7316 (signal_catchpoint_dtor): Change to ...
7317 (signal_catchpoint::~signal_catchpoint): ... this.
7318 (create_signal_catchpoint): Remove reference to base field.
7319 (initialize_signal_catchpoint_ops): Don't set dtor.
7320 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
7322 <~syscall_catchpoint>: New.
7324 (dtor_catch_syscall): Change to ...
7325 (syscall_catchpoint::~syscall_catchpoint): ... this.
7326 (create_syscall_event_catchpoint): Remove reference to base
7328 (initialize_syscall_catchpoint_ops): Don't set dtor.
7329 * break-catch-throw.c (struct exception_catchpoint): Inherit
7331 <~exception_catchpoint>: New.
7333 (dtor_exception_catchpoint): Change to ...
7334 (exception_catchpoint::~exception_catchpoint): ... this.
7335 (handle_gnu_v3_exceptions): Remove reference to base field.
7336 (initialize_throw_catchpoint_ops): Don't set dtor.
7337 * ctf.c (ctf_get_traceframe_address): Remove reference to base
7339 * remote.c (remote_get_tracepoint_status): Likewise.
7340 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
7341 * tracefile.c (tracefile_fetch_registers): Likewise.
7342 * tracepoint.c (actions_command): Likewise.
7343 (validate_actionline): Likewise.
7344 (tfind_1): Likewise.
7345 (get_traceframe_location): Likewise.
7346 (find_matching_tracepoint_location): Likewise.
7347 (parse_tracepoint_status): Likewise.
7348 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
7350 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
7352 * breakpoint.c (struct longjmp_breakpoint): New struct.
7353 (is_tracepoint_type): Change return type to bool.
7354 (is_longjmp_type): New function.
7355 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
7356 (set_raw_breakpoint_without_location): Use
7357 new_breakpoint_from_type.
7358 (set_raw_breakpoint): Likewise.
7360 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
7362 * breakpoint.c (new_breakpoint_from_type): New function.
7363 (create_breakpoint_sal): Use new_breakpoint_from_type and
7365 (create_breakpoint): Likewise.
7367 2017-05-31 Simon Marchi <simon.marchi@ericsson.com>
7369 * memattr.c (mem_info_command): Rename to ...
7370 (info_mem_command): ... this.
7371 (mem_enable_command): Rename to ...
7372 (enable_mem_command): ... this.
7373 (mem_disable_command): Rename to ...
7374 (disable_mem_command): ... this.
7375 (mem_delete_command): Rename to ...
7376 (delete_mem_command): ... this.
7377 (_initialize_mem): Adjust function names.
7379 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
7381 * btrace.c (handle_pt_insn_events): New.
7382 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
7383 STATUS. Split into this and ...
7384 (handle_pt_insn_event_flags): ... this.
7386 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
7388 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
7389 and struct pt_insn.resynced.
7390 * configure: Regenerated.
7391 * config.in: Regenerated.
7393 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
7395 * btrace.c (ftrace_find_call_by_number): New function.
7396 (ftrace_new_function): Store objects, not pointers.
7397 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
7398 ftrace_new_gap, ftrace_update_function,
7399 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
7400 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
7401 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
7402 btrace_ends_with_single_insn, btrace_call_get): Account for
7403 btrace_thread_info::functions now storing objects.
7404 * btrace.h (struct btrace_thread_info): Add constructor.
7405 (struct btrace_thread_info) <functions>: Make std::vector.
7406 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
7407 Initialize with default values.
7408 * record-btrace.c (record_btrace_frame_sniffer): Account for
7409 btrace_thread_info::functions now storing objects.
7411 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
7413 * btrace.c: Remove typedef bfun_s.
7414 (ftrace_new_gap): Directly add gaps to the list of gaps.
7415 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
7416 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
7417 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
7420 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
7422 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
7423 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
7424 with btrace_thread_info::next_segment and
7425 btrace_thread_info::prev_segment.
7426 * btrace.h: Remove struct btrace_func_link.
7427 (struct btrace_function): Replace pair of function segment pointers
7428 with pair of indices.
7429 * python/py-record-btrace.c (btpy_call_prev_sibling,
7430 btpy_call_next_sibling): Replace references to
7431 btrace_thread_info::segment with btrace_thread_info::next_segment and
7432 btrace_thread_info::prev_segment.
7433 * record-btrace.c (record_btrace_frame_this_id): Use
7434 btrace_find_call_by_number.
7436 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
7438 * btrace.c (ftrace_new_function, ftrace_fixup_level,
7439 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
7440 btrace_insn_next, btrace_insn_prev): Remove references to
7441 btrace_thread_info::flow.
7442 * btrace.h (struct btrace_function): Remove FLOW.
7444 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
7446 * btrace.c (ftrace_find_call_by_number): New function.
7447 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
7448 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
7449 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
7450 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
7452 * btrace.h (struct btrace_function): Turn UP into an index.
7453 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
7455 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
7456 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
7457 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
7459 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
7461 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
7462 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
7463 ftrace_update_function, ftrace_compute_global_level_offset,
7464 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
7465 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
7466 btrace_insn_end, btrace_is_empty): Remove references to
7467 btrace_thread_info::begin and btrace_thread_info::end.
7468 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
7469 (struct btrace_thread_info) <functions>: Adjust comment.
7470 * record-btrace.c (record_btrace_start_replaying): Remove reference to
7471 btrace_thread_info::begin.
7473 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
7475 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
7476 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
7477 ftrace_update_function): Remove arguments that implicitly were always
7479 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
7480 Don't pass BTINFO->END.
7482 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
7484 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
7485 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
7486 btrace_find_insn_by_number): Replace function segment pointer with
7488 (btrace_insn_cmp): Simplify.
7489 * btrace.h: (struct btrace_insn_iterator) Rename index to
7490 insn_index. Replace function segment pointer with index into function
7492 * record-btrace.c (record_btrace_call_history): Replace function
7493 segment pointer use with index.
7494 (record_btrace_frame_sniffer): Retrieve function call segment through
7496 (record_btrace_set_replay): Remove defunc't safety check.
7498 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
7500 * btrace.c (btrace_ends_with_single_insn): New function.
7501 (btrace_call_get, btrace_call_number, btrace_call_begin,
7502 btrace_call_end, btrace_call_next, btrace_call_prev,
7503 btrace_find_call_by_number): Use index into call segment vector
7505 (btrace_call_cmp): Simplify.
7506 * btrace.h (struct btrace_call_iterator): Replace function call segment
7507 pointer with index into vector.
7508 * record-btrace.c (record_btrace_call_history): Use index instead of
7511 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
7513 * btrace.c (btrace_insn_begin, btrace_insn_end,
7514 btrace_find_insn_by_number): Add btinfo to iterator.
7515 * btrace.h (struct btrace_insn_iterator): Add btinfo.
7517 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
7519 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
7520 and save pointers directly.
7521 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
7522 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
7523 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
7524 changed signature of functions.
7525 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
7526 (btrace_fetch): Remove code that adds btrace_function pointers to
7527 vector of btrace_functions.
7528 (btrace_clear): Simplify freeing vector of btrace_functions.
7530 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
7532 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
7533 Replace VEC_* with std::vector functions.
7534 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
7535 (struct btrace_thread_info)<functions>: Change type to std::vector.
7537 2017-05-30 Simon Marchi <simon.marchi@ericsson.com>
7539 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
7540 "Removed targets and native configurations" up. Merge duplicate
7541 "New commands" sub-sections. Add "New options" sub-sections.
7543 2017-05-26 Alan Hayward <alan.hayward@arm.com>
7545 * defs.h (copy_integer_to_size): New declaration.
7546 * findvar.c (copy_integer_to_size): New function.
7547 (do_cint_test): New selftest function.
7548 (copy_integer_to_size_test): Likewise.
7549 (_initialize_findvar): Likewise.
7550 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
7551 (mips_fbsd_collect_reg): Use raw_collect_integer.
7552 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
7553 (mips64_fill_gregset): Use raw_collect_integer
7554 (mips64_fill_fpregset): Use raw_supply_integer.
7555 * regcache.c (regcache::raw_supply_integer): New function.
7556 (regcache::raw_collect_integer): Likewise.
7557 * regcache.h: (regcache::raw_supply_integer): New declaration.
7558 (regcache::raw_collect_integer): Likewise.
7560 2017-05-24 Yao Qi <yao.qi@linaro.org>
7562 * Makefile.in (SFILES): Add gdbarch-selftests.c.
7563 (COMMON_OBS): Add gdbarch-selftests.o.
7564 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
7565 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
7566 * gdbarch-selftests.c: New file.
7567 * regcache.h (regcache) <~regcache>: Mark it virtual if
7569 <raw_write>: Likewise.
7571 2017-05-24 Yao Qi <yao.qi@linaro.org>
7573 * regcache.c (current_regcache): Change it to
7574 regcache::current_regcache.
7575 (regcache_observer_target_changed): Update.
7576 (regcache_thread_ptid_changed): Make it a regcache static
7578 (regcache_thread_ptid_changed): Update.
7579 (class regcache_access): New.
7580 (current_regcache_test): Update.
7581 (_initialize_regcache): Update.
7582 * regcache.h: Include forward_list.
7583 (regcache): Declare regcache_thread_ptid_changed and declare
7584 registers_changed_ptid as friend.
7586 2017-05-24 Yao Qi <yao.qi@linaro.org>
7588 * i387-tdep.c (i387_register_to_value): Use register_size
7589 instead of TYPE_LENGTH.
7590 * m68k-tdep.c (m68k_register_to_value): Likewise.
7592 2017-05-24 Yao Qi <yao.qi@linaro.org>
7594 * i387-tdep.c (i387_convert_register_p): Return false if type
7595 code isn't TYPE_CODE_FLT.
7597 2017-05-24 Yao Qi <yao.qi@linaro.org>
7599 * alpha-tdep.c (alpha_convert_register_p): Return true if type
7601 (alpha_register_to_value): Remove type length check.
7602 (alpha_value_to_register): Likewise.
7604 2017-05-24 Yao Qi <yao.qi@linaro.org>
7606 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
7609 2017-05-24 Yao Qi <yao.qi@linaro.org>
7611 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
7612 TYPE_CODE_FLT or not.
7614 2017-05-24 Yao Qi <yao.qi@linaro.org>
7616 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
7617 * avr-tdep.c (avr_gdbarch_init): Likewise.
7618 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
7619 * cris-tdep.c (cris_gdbarch_init): Likewise.
7620 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
7621 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
7622 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
7623 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
7624 * mep-tdep.c (mep_gdbarch_init): Likewise.
7625 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
7626 * mips-tdep.c (mips_gdbarch_init): Likewise.
7627 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
7628 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
7629 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
7630 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
7631 * v850-tdep.c (v850_gdbarch_init): Likewise.
7633 2017-05-24 Yao Qi <yao.qi@linaro.org>
7635 * selftest-arch.c (tests_with_arch): Call registers_changed
7636 and reinit_frame_cache.
7637 * selftest.c (run_self_tests): Likewise.
7639 2017-05-24 Yao Qi <yao.qi@linaro.org>
7641 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
7642 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
7644 2017-05-24 Yao Qi <yao.qi@linaro.org>
7646 * rl78-tdep.c (rl78_gdbarch_init): Don't call
7647 set_gdbarch_print_insn.
7649 2017-05-24 Yao Qi <yao.qi@linaro.org>
7651 * h8300-tdep.c (h8300_gdbarch_init): Don't call
7652 set_gdbarch_print_insn.
7654 2017-05-24 Yao Qi <yao.qi@linaro.org>
7656 * alpha-tdep.c (alpha_gdbarch_init): Don't call
7657 set_gdbarch_print_insn.
7658 * arc-tdep.c (arc_gdbarch_init): Likewise.
7659 * arch-utils.c: include dis-asm.h.
7660 (default_print_insn): New function.
7661 * arch-utils.h (default_print_insn): Declare.
7662 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
7663 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
7664 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
7665 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
7666 * frv-tdep.c (frv_gdbarch_init): Likewise.
7667 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
7668 * gdbarch.sh (print_insn): Use default_print_insn.
7669 * gdbarch.c: Regenerated.
7670 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
7671 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
7672 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
7673 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
7674 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
7675 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
7676 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
7677 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
7678 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
7679 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
7680 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
7681 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
7682 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
7683 * mt-tdep.c (mt_gdbarch_init): Likewise.
7684 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
7685 * nios2-tdep.c (nios2_print_insn): Remove.
7686 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
7687 * rx-tdep.c (rx_gdbarch_init): Likewise.
7688 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
7689 * score-tdep.c (score_print_insn): Remove.
7690 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
7691 * sh-tdep.c (sh_gdbarch_init): Likewise.
7692 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
7693 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
7694 * tic6x-tdep.c (tic6x_print_insn): Remove.
7695 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
7696 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
7697 * v850-tdep.c (v850_gdbarch_init): Likewise.
7698 * vax-tdep.c (vax_gdbarch_init): Likewise.
7699 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
7700 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
7702 2017-05-23 John Baldwin <jhb@FreeBSD.org>
7704 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
7705 (MIPS_FP0_REGNUM): Remove.
7706 (MIPS_FSR_REGNUM): Remove.
7707 (mips_fbsd_supply_fpregs): Use mips_regnum.
7708 (mips_fbsd_supply_gregs): Likewise.
7709 (mips_fbsd_collect_fpregs): Likewise.
7710 (mips_fbsd_collect_gregs): Likewise.
7712 2017-05-23 John Baldwin <jhb@FreeBSD.org>
7714 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
7715 (getpfpregs_supplies): New function.
7716 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
7718 (mips_fbsd_store_inferior_registers): Likewise.
7720 2017-05-22 Pedro Alves <palves@redhat.com>
7722 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
7725 2017-05-22 Alan Hayward <alan.hayward@arm.com>
7727 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
7728 (store_register): Likewise.
7729 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
7730 (get_decimal_float_return_value): Likewise.
7731 (do_ppc_sysv_return_value): Likewise.
7732 (ppc64_sysv_abi_push_integer): Likewise.
7733 (ppc64_sysv_abi_push_freg): Likewise.
7734 (ppc64_sysv_abi_return_value_base): Likewise.
7735 (ppc64_sysv_abi_return_value): Likewise.
7736 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
7737 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
7738 * rs6000-nat.c: Likewise.
7739 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
7740 (rs6000_value_to_register): Likewise.
7741 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
7743 2017-05-21 Tom Tromey <tom@tromey.com>
7746 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
7747 arrays as "[T]", not "[T; ]".
7749 2017-05-19 Tom Tromey <tom@tromey.com>
7752 * rust-lang.c (exp_descriptor_rust): New function.
7753 (rust_language_defn): Use it.
7754 * p-lang.c (pascal_language_defn): Update.
7755 * opencl-lang.c (opencl_language_defn): Update.
7756 * objc-lang.c (objc_language_defn): Update.
7757 * m2-lang.c (m2_language_defn): Update.
7758 * language.h (struct language_defn)
7759 <la_watch_location_expression>: New member.
7760 * language.c (unknown_language_defn, auto_language_defn)
7761 (local_language_defn): Update.
7762 * go-lang.c (go_language_defn): Update.
7763 * f-lang.c (f_language_defn): Update.
7764 * d-lang.c (d_language_defn): Update.
7765 * c-lang.h (c_watch_location_expression): Declare.
7766 * c-lang.c (c_watch_location_expression): New function.
7767 (c_language_defn, cplus_language_defn, asm_language_defn)
7768 (minimal_language_defn): Use it.
7769 * breakpoint.c (watch_command_1): Call
7770 la_watch_location_expression.
7771 * ada-lang.c (ada_language_defn): Update.
7773 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7776 * gdb_curses.h (NOMACROS): Define.
7777 (NCURSES_NOMACROS): Define.
7779 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7782 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
7784 * tui/tui-wingeneral.c (box_win): Likewise.
7785 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
7786 (tui_show_source_line): Likewise.
7787 (tui_show_exec_info_content): Likewise.
7789 2017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
7791 * sparc-tdep.c (sparc_structure_return_p)
7792 (sparc_arg_on_registers_p): New functions.
7793 (sparc32_store_arguments): Use them.
7794 * sparc64-tdep.c (sparc64_16_byte_align_p)
7795 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
7796 Handle TYPE_CODE_ARRAY.
7798 2017-05-17 Yao Qi <yao.qi@linaro.org>
7800 * cli/cli-decode.c (add_alias_cmd): New function.
7801 * command.h (add_alias_cmd): Declare.
7802 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
7803 instead call add_alias_cmd.
7805 2017-05-17 Pedro Alves <palves@redhat.com>
7807 * Makefile.in (nat_extra_makefile_frag): Rename to ...
7808 (nat_makefile_frag): ... this. All references updated.
7809 * configure.ac: Likewise.
7810 * configure.nat: Likewise. Enhance comments.
7811 * configure: Regenerate.
7813 2017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7815 * procfs.c (procfs_create_inferior): Change prototype to match
7818 2017-05-13 Eli Zaretskii <eliz@gnu.org>
7820 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
7821 C++ compiler warning.
7823 2017-05-12 Tom Tromey <tom@tromey.com>
7826 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
7827 recurse, just call value_struct_elt directly.
7829 2017-05-12 Tom Tromey <tom@tromey.com>
7831 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
7832 OP_RUST_ARRAY>: Fix.
7834 2017-05-12 Tom Tromey <tom@tromey.com>
7836 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
7838 2017-05-09 Yao Qi <yao.qi@linaro.org>
7840 * regcache.c: Include <forward_list>.
7841 (struct regcache_list): Remove.
7842 (current_regcache): Update.
7843 (get_thread_arch_aspace_regcache): Update for std::forward_list.
7844 (regcache_thread_ptid_changed): Likewise.
7845 (registers_changed_ptid): Likewise.
7846 (current_regcache_size): Likewise.
7848 2017-05-09 Yao Qi <yao.qi@linaro.org>
7850 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
7851 (current_regcache_size): New function.
7852 (current_regcache_test): New function.
7853 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
7855 2017-05-08 Alan Hayward <alan.hayward@arm.com>
7857 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
7858 (print_gp_register_row): Use get_frame_register_value.
7860 2017-05-08 Alan Hayward <alan.hayward@arm.com>
7862 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
7863 (mips_supply_fpregset): Likewise.
7864 (mips64_supply_gregset): Likewise.
7866 2017-05-08 Alan Hayward <alan.hayward@arm.com>
7868 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
7869 regcache->raw_supply_zeroed.
7871 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
7873 * configure.nat: Rearrange 'case' statements to match
7876 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
7878 * Makefile.in: Remove "@host_makefile_frag@". Add variables
7879 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
7880 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
7881 "@nat_extra_makefile_frag@".
7882 (Makefile): Remove dependency on "@frags@".
7883 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
7884 (data-directory/Makefile): Likewise.
7885 * config/aarch64/linux.mh: Deleted; moved contents to
7886 "gdb/configure.nat".
7887 * config/alpha/alpha-linux.mh: Likewise.
7888 * config/alpha/nbsd.mh: Likewise.
7889 * config/arm/linux.mh: Likewise.
7890 * config/arm/nbsdelf.mh: Likewise.
7891 * config/i386/cygwin.mh: Likewise.
7892 * config/i386/cygwin64.mh: Likewise.
7893 * config/i386/darwin.mh: Likewise.
7894 * config/i386/fbsd.mh: Likewise.
7895 * config/i386/fbsd64.mh: Likewise.
7896 * config/i386/go32.mh: Likewise.
7897 * config/i386/i386gnu.mh: Likewise.
7898 * config/i386/i386sol2.mh: Likewise.
7899 * config/i386/linux.mh: Likewise.
7900 * config/i386/linux64.mh: Likewise.
7901 * config/i386/mingw.mh: Likewise.
7902 * config/i386/mingw64.mh: Likewise.
7903 * config/i386/nbsd64.mh: Likewise.
7904 * config/i386/nbsdelf.mh: Likewise.
7905 * config/i386/nto.mh: Likewise.
7906 * config/i386/obsd.mh: Likewise.
7907 * config/i386/obsd64.mh: Likewise.
7908 * config/i386/sol2-64.mh: Likewise.
7909 * config/ia64/linux.mh: Likewise.
7910 * config/m32r/linux.mh: Likewise.
7911 * config/m68k/linux.mh: Likewise.
7912 * config/m68k/nbsdelf.mh: Likewise.
7913 * config/m68k/obsd.mh: Likewise.
7914 * config/m88k/obsd.mh: Likewise.
7915 * config/mips/fbsd.mh: Likewise.
7916 * config/mips/linux.mh: Likewise.
7917 * config/mips/nbsd.mh: Likewise.
7918 * config/mips/obsd64.mh: Likewise.
7919 * config/pa/linux.mh: Likewise.
7920 * config/pa/nbsd.mh: Likewise.
7921 * config/pa/obsd.mh: Likewise.
7922 * config/powerpc/aix.mh: Likewise.
7923 * config/powerpc/fbsd.mh: Likewise.
7924 * config/powerpc/linux.mh: Likewise.
7925 * config/powerpc/nbsd.mh: Likewise.
7926 * config/powerpc/obsd.mh: Likewise.
7927 * config/powerpc/ppc64-linux.mh: Likewise.
7928 * config/powerpc/spu-linux.mh: Likewise.
7929 * config/s390/linux.mh: Likewise.
7930 * config/sh/nbsd.mh: Likewise.
7931 * config/sparc/fbsd.mh: Likewise.
7932 * config/sparc/linux.mh: Likewise.
7933 * config/sparc/linux64.mh: Likewise.
7934 * config/sparc/nbsd64.mh: Likewise.
7935 * config/sparc/nbsdelf.mh: Likewise.
7936 * config/sparc/obsd64.mh: Likewise.
7937 * config/sparc/sol2.mh: Likewise.
7938 * config/tilegx/linux.mh: Likewise.
7939 * config/vax/nbsdelf.mh: Likewise.
7940 * config/vax/obsd.mh: Likewise.
7941 * config/xtensa/linux.mh: Likewise.
7942 * config/i386/i386gnu.mn: New file, with excerpts from
7943 "config/i386/i386gnu.mh".
7944 * configure: Regenerate.
7945 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
7946 *.mh files under "gdb/config".
7947 * configure.nat: New file, with contents from the
7948 "gdb/config/*/*.mh" files.
7950 2017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
7952 * btrace.c (btrace_clear): Free insn vector.
7954 2017-05-05 Pedro Alves <palves@redhat.com>
7956 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
7957 * configure: Regenerate.
7959 2017-05-04 Pedro Alves <palves@redhat.com>
7961 * Makefile.in (SFILES): Add progspace-and-thread.c.
7962 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
7963 (COMMON_OBS): Add progspace-and-thread.o.
7964 * breakpoint.c: Include "progspace-and-thread.h".
7965 (update_inserted_breakpoint_locations)
7966 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
7967 Use scoped_restore_current_pspace_and_thread.
7968 (create_std_terminate_master_breakpoint): Use
7969 scoped_restore_current_program_space.
7970 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
7971 (print_breakpoint_location): Use
7972 scoped_restore_current_program_space.
7973 (bp_loc_is_permanent): Use
7974 scoped_restore_current_pspace_and_thread.
7975 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
7976 (download_tracepoint_locations): Use
7977 scoped_restore_current_pspace_and_thread.
7978 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
7979 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
7980 (enum step_over_calls_kind): Moved from inferior.h.
7981 (class scoped_restore_current_thread): New class.
7982 * gdbthread.h (make_cleanup_restore_current_thread): Delete
7984 (scoped_restore_current_thread): New class.
7985 * infcmd.c: Include "common/gdb_optional.h".
7986 (continue_1, proceed_after_attach): Use
7987 scoped_restore_current_thread.
7988 (notice_new_inferior): Use scoped_restore_current_thread.
7989 * inferior.c: Include "progspace-and-thread.h".
7990 (restore_inferior, save_current_inferior): Delete.
7991 (add_inferior_command, clone_inferior_command): Use
7992 scoped_restore_current_pspace_and_thread.
7993 * inferior.h (scoped_restore_current_inferior): New class.
7994 * infrun.c: Include "progspace-and-thread.h" and
7995 "common/gdb_optional.h".
7996 (follow_fork_inferior): Use
7997 scoped_restore_current_pspace_and_thread.
7998 (scoped_restore_exited_inferior): New class.
7999 (handle_vfork_child_exec_or_exit): Use
8000 scoped_restore_exited_inferior,
8001 scoped_restore_current_pspace_and_thread,
8002 scoped_restore_current_thread and scoped_restore.
8003 (fetch_inferior_event): Use scoped_restore_current_thread.
8004 * linespec.c (decode_line_full, decode_line_1): Use
8005 scoped_restore_current_program_space.
8006 * mi/mi-main.c: Include "progspace-and-thread.h".
8007 (exec_continue): Use scoped_restore_current_thread.
8008 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
8009 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
8010 * proc-service.c (ps_pglobal_lookup): Use
8011 scoped_restore_current_program_space.
8012 * progspace-and-thread.c: New file.
8013 * progspace-and-thread.h: New file.
8014 * progspace.c (release_program_space, clone_program_space): Use
8015 scoped_restore_current_program_space.
8016 (restore_program_space, save_current_program_space)
8017 (save_current_space_and_thread): Delete.
8018 (switch_to_program_space_and_thread): Moved to
8019 progspace-and-thread.c.
8020 * progspace.h (save_current_program_space)
8021 (save_current_space_and_thread): Delete declarations.
8022 (scoped_restore_current_program_space): New class.
8023 * remote.c (remote_btrace_maybe_reopen): Use
8024 scoped_restore_current_thread.
8025 * symtab.c: Include "progspace-and-thread.h".
8026 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
8027 * thread.c (print_thread_info_1): Use
8028 scoped_restore_current_thread.
8029 (struct current_thread_cleanup): Delete.
8030 (do_restore_current_thread_cleanup)
8031 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
8032 (scoped_restore_current_thread::~scoped_restore_current_thread):
8034 (make_cleanup_restore_current_thread): Rename/convert to ...
8035 (scoped_restore_current_thread::scoped_restore_current_thread):
8037 (thread_apply_all_command): Use scoped_restore_current_thread.
8038 (thread_apply_command): Use scoped_restore_current_thread.
8039 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
8040 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
8042 2017-05-04 Pedro Alves <palves@redhat.com>
8044 * thread.c (make_cleanup_restore_current_thread): Move
8045 find_thread_ptid call before the is_stopped call. Assert that the
8046 thread is found. Replace is_stopped call by checking the thread's
8047 state directly. Remove unnecessary NULL-thread check.
8049 2017-05-04 Pedro Alves <palves@redhat.com>
8051 * corelow.c (thread_section_name): New class.
8052 (get_core_register_section, get_core_siginfo): Use it.
8054 2017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
8056 * corelow.c (sniff_core_bfd): Remove extra semicolon.
8057 (get_core_register_section): Remove xfree of NULL pointer.
8059 2017-05-03 Alan Hayward <alan.hayward@arm.com>
8061 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
8062 * regcache.c (regcache::raw_supply_zeroed): New function.
8063 * regcache.h (regcache::raw_supply_zeroed): New declaration.
8065 2017-05-03 Simon Marchi <simon.marchi@ericsson.com>
8067 * gdbarch.sh: Remove commented out definition of
8069 * gdbarch.h: Re-generate.
8071 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
8073 * configure: Regenerate.
8075 2017-05-02 Simon Marchi <simon.marchi@ericsson.com>
8077 * solib-target.c (solib_target_relocate_section_addresses):
8078 Remove num_section_bases, num_bases, segment_bases variables.
8080 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
8082 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
8084 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
8086 * solib-target.c: Include <vector>
8087 (struct lm_info_target) <~lm_info_target>: Remove.
8088 <segment_bases, section_bases>: Change type to
8089 std::vector<CORE_ADDR>.
8090 (library_list_start_segment, library_list_start_section,
8091 library_list_end_library,
8092 solib_target_relocate_section_addresses): Adjust.
8094 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
8096 * gdbarch.sh (software_single_step): Change return type to
8097 std::vector<CORE_ADDR>.
8098 * gdbarch.c, gdbarch.h: Re-generate.
8099 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
8101 (arm_deal_with_atomic_sequence_raw): Adjust.
8102 (thumb_get_next_pcs_raw): Adjust.
8103 (arm_get_next_pcs_raw): Adjust.
8104 (arm_get_next_pcs): Adjust.
8105 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
8106 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
8107 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
8108 (alpha_software_single_step): Adjust.
8109 * alpha-tdep.h (alpha_software_single_step): Adjust.
8110 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
8111 * arm-tdep.c (arm_software_single_step): Adjust.
8112 (arm_breakpoint_kind_from_current_state): Adjust.
8113 * arm-tdep.h (arm_software_single_step): Adjust.
8114 * breakpoint.c (insert_single_step_breakpoint): Adjust.
8115 * cris-tdep.c (cris_software_single_step): Adjust.
8116 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
8117 (micromips_deal_with_atomic_sequence): Adjust.
8118 (deal_with_atomic_sequence): Adjust.
8119 (mips_software_single_step): Adjust.
8120 * mips-tdep.h (mips_software_single_step): Adjust.
8121 * moxie-tdep.c (moxie_software_single_step): Adjust.
8122 * nios2-tdep.c (nios2_software_single_step): Adjust.
8123 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
8124 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
8125 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
8126 * s390-linux-tdep.c (s390_software_single_step): Adjust.
8127 * sparc-tdep.c (sparc_software_single_step): Adjust.
8128 * spu-tdep.c (spu_software_single_step): Adjust.
8129 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
8131 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
8133 * gdbarch.sh: Use semi-colon as field separator instead of colon.
8134 * gdbarch.h: Re-generate.
8136 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
8138 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
8139 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
8140 * python/py-instruction.c, python/py-instruction.h: New file.
8141 * python/py-record.c: Add py-instruction.h include.
8142 (gdbpy_initialize_record): Make gdb.Instruction a super class of
8143 gdb.RecordInstruction.
8144 * python/python-internal.h: Add gdbpy_initialize_instruction
8146 * python/python.c (do_start_initialization): Add
8147 gdbpy_initialize_instruction.
8149 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
8151 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
8153 (btrace_func_from_recpy_func): New function.
8154 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
8155 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
8156 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
8157 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
8158 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
8159 Also, use new helper functions.
8160 (btpy_list_item): Use new helper functions.
8161 (recpy_bt_function_call_history): Use new type name.
8162 (btpy_call_getset): Remove.
8163 (gdbpy_initialize_btrace): Remove code to initialize
8164 gdb.BtraceFunctionCall.
8165 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
8166 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
8167 recpy_bt_func_prev, recpy_bt_func_next): New export.
8168 * python/py-record.c (recpy_func_type): New static object.
8169 (recpy_func_new, recpy_func_level, recpy_func_symbol,
8170 recpy_func_instructions, recpy_func_up, recpy_func_prev,
8171 recpy_func_next): New function.
8172 (recpy_element_hash, recpy_element_richcompare): Updated comment.
8173 (recpy_func_getset): New static object.
8174 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
8175 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
8177 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
8179 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
8180 (btpy_object, btpy_insn_type, btpy_new): Remove.
8181 (btpy_list_object): Use gdb.RecordInstruction type instead of
8182 gdb.BtraceInstruction type.
8183 (btrace_insn_from_recpy_insn): New function.
8184 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
8186 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
8187 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
8188 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
8189 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
8190 instead of btpy_object.
8191 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
8192 btpy_insn_data, btpy_insn_decode): Rename to ...
8193 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
8194 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
8195 recpy_bt_insn_decode): This. Also, use new helper functions.
8196 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
8198 (btpy_insn_getset): Remove.
8199 (gdbpy_initialize_btrace): Remove code to initialize
8200 gdb.BtraceInstruction. Use recpy_element_object.
8201 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
8202 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
8203 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
8204 * python/py-record.c (recpy_insn_type): New static object.
8205 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
8206 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
8207 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
8209 (recpy_insn_getset): New static object.
8210 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
8211 * python/py-record.h (recpy_element_object): New typedef.
8212 (recpy_insn_type, recpy_insn_new): New export.
8214 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
8216 * py-record-btrace.c (btpy_insn_new): Removed.
8217 (btpy_insn_or_gap_new): New function.
8218 (btpy_insn_error): Removed.
8219 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
8220 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
8221 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
8222 btpy_insn_or_gap_new instead of btpy_insn_new.
8223 (btpy_insn_getset): Remove btpy_insn_error.
8224 * py-record.c (recpy_gap_type): New static object.
8225 (recpy_gap_object): New typedef.
8226 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
8227 recpy_gap_reason_string): New function.
8228 (recpy_gap_getset): New static object.
8229 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
8230 * py-record.h (recpy_gap_new): New export.
8232 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
8234 * python/py-record.c (recpy_ptid): Remove.
8235 (recpy_record_getset): Remove recpy_ptid.
8237 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
8239 * btrace.c (btrace_fetch): Set inferior_ptid.
8240 * python/py-record-btrace.c: Add "py-record.h" include.
8241 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
8242 recpy_bt_end, recpy_bt_instruction_history,
8243 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
8244 in gdb.Record object instead of current ptid.
8245 * python/py-record.c: Include new "py-record.h" file.
8246 (recpy_record_object): Moved to py-record.h.
8247 * python/py-record.h: New file.
8249 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
8251 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
8252 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
8255 2017-05-01 Joel Brobecker <brobecker@adacore.com>
8257 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
8258 the past maintainers section.
8260 2017-04-28 Yao Qi <yao.qi@linaro.org>
8262 * infcmd.c (get_return_value): Use regcache ctor, and remove
8265 2017-04-28 Yao Qi <yao.qi@linaro.org>
8266 Pedro Alves <palves@redhat.com>
8268 * regcache.c (regcache::regcache): New tag dispatch ctor.
8269 (do_cooked_read): Moved above.
8270 (regcache_dup): Use the tag dispatch ctor..
8271 * regcache.h (regcache): Declare ctor, delete copy ctor and
8272 assignment operator, remove friend regcache_dup.
8274 2017-04-28 Yao Qi <yao.qi@linaro.org>
8276 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
8277 call method save instead of regcache_cpy.
8278 * regcache.h (struct regcache): Make regcache_dup a friend.
8280 2017-04-28 Yao Qi <yao.qi@linaro.org>
8282 * regcache.c (struct regcache): Move to regcache.h
8283 (regcache::arch): New method.
8284 (regcache_get_ptid): Update.
8285 (get_regcache_arch): Call arch method.
8286 (get_regcache_aspace): Call method aspace.
8287 (register_buffer): Change it to method.
8288 (regcache_save): Change it to regcache::save.
8289 (regcache_restore): Likewise.
8290 (regcache_cpy_no_passthrough): Remove the declaration.
8291 (regcache_cpy): Call methods restore and cpy_no_passthrough.
8292 (regcache_cpy_no_passthrough): Change it to method
8294 (regcache_register_status): Change it to method
8295 get_register_status.
8296 (regcache_invalidate): Change it to method invalidate.
8297 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
8298 (regcache_raw_update): Change it to method raw_update.
8299 (regcache_raw_read): Likewise.
8300 (regcache_raw_read_signed): Likewise.
8301 (regcache_raw_read_unsigned): Likewise.
8302 (regcache_raw_write_signed): Likewise.
8303 (regcache_raw_write_unsigned): Likewise.
8304 (regcache_cooked_read): Likewise.
8305 (regcache_cooked_read_value): Likewise.
8306 (regcache_cooked_read_signed): Likewise.
8307 (regcache_cooked_read_unsigned): Likewise.
8308 (regcache_cooked_write_signed): Likewise.
8309 (regcache_cooked_write_unsigned): Likewise.
8310 (regcache_raw_set_cached_value): Likewise.
8311 (regcache_raw_write): Likewise.
8312 (regcache_cooked_write): Likewise.
8313 (regcache_xfer_part): Likewise.
8314 (regcache_raw_read_part): Likewise.
8315 (regcache_raw_write_part): Likewise.
8316 (regcache_cooked_read_part): Likewise.
8317 (regcache_cooked_write_part): Likewise.
8318 (regcache_raw_supply): Likewise.
8319 (regcache_raw_collect): Likewise.
8320 (regcache_transfer_regset): Likewise.
8321 (regcache_supply_regset): Likewise.
8322 (regcache_collect_regset): Likewise.
8323 (regcache_debug_print_register): Likewise.
8324 (enum regcache_dump_what): Move it to regcache.h.
8325 (regcache_dump): Change it to method dump.
8326 * regcache.h (enum regcache_dump_what): New.
8327 (class regcache): New.
8328 * target.c (target_fetch_registers): Call method
8329 debug_print_register.
8330 (target_store_registers): Likewise.
8332 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
8334 * windows-nat.c (struct lm_info_windows): Initialize field.
8335 (windows_make_so): Allocate lm_info_windows with new.
8336 (windows_free_so): Free lm_info_windows with delete.
8338 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
8340 * solib-darwin.c (struct lm_info_darwin): Initialize field.
8341 (darwin_current_sos): Allocate lm_info_darwin with new, remove
8343 (darwin_free_so): Free lm_info_darwin with delete.
8345 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
8347 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
8348 <l_addr_p>: Change type to bool.
8349 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
8350 (svr4_free_so): Free lm_info_svr4 with delete.
8351 (svr4_copy_library_list): Replace memcpy with call to copy
8353 (library_list_start_library, svr4_default_sos): Allocate
8354 lm_info_svr4 with new.
8356 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
8358 * solib-target.c (struct lm_info_target): Add destructor,
8360 <name>: Change type to std::string.
8361 (library_list_start_library): Allocate lm_info_target with new.
8362 (solib_target_free_library_list): Free lm_info_target with
8364 (solib_target_current_sos): Adapt to std::string.
8365 (solib_target_free_so): Free lm_info_target with delete.
8367 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
8369 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
8371 (frv_current_sos): Allocate lm_info_frv with new.
8372 (frv_relocate_main_executable): Free lm_info_frv with delete,
8374 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
8376 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
8378 * solib-frv.c (struct lm_info_frv): Fix indentation.
8380 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
8382 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
8384 (dsbt_current_sos): Allocate lm_info_dsbt with new.
8385 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
8386 and allocate with new.
8387 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
8389 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
8391 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
8392 <filename, member_name>: Change type to std::string.
8393 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
8394 (library_list_start_library): Allocate lm_info_aix with new.
8395 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
8396 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
8397 with copy constructor.
8399 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
8401 * solist.h (struct lm_info): Remove.
8402 (struct lm_info_base): New class.
8403 (struct so_list) <lm_info>: Change type to lm_info_base *.
8404 * nto-tdep.c (struct lm_info): Remove.
8406 * solib-aix.c (struct lm_info): Rename to ...
8407 (struct lm_info_aix): ... this. Extend lm_info_base.
8408 (lm_info_p): Rename to ...
8409 (lm_info_aix_p): ... this, and adjust.
8410 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
8411 solib_aix_parse_libraries, library_list_start_library,
8412 solib_aix_free_library_list, solib_aix_parse_libraries,
8413 solib_aix_get_library_list,
8414 solib_aix_relocate_section_addresses, solib_aix_free_so,
8415 solib_aix_get_section_offsets,
8416 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
8418 (struct solib_aix_inferior_data) <library_list>: Adjust.
8419 * solib-darwin.c (struct lm_info): Rename to ...
8420 (struct lm_info_darwin): ... this. Extend lm_info_base.
8421 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
8422 * solib-dsbt.c (struct lm_info): Rename to ...
8423 (struct lm_info_dsbt): ... this. Extend lm_info_base.
8424 (struct dsbt_info) <main_executable_lm_info): Adjust.
8425 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
8426 dsbt_relocate_section_addresses): Adjust.
8427 * solib-frv.c (struct lm_info): Rename to ...
8428 (struct lm_info_frv): ... this. Extend lm_info_base.
8429 (main_executable_lm_info): Adjust.
8430 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
8431 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
8432 find_canonical_descriptor_in_load_object,
8433 frv_fdpic_find_canonical_descriptor): Adjust.
8434 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
8436 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
8437 svr4_clear_so, svr4_copy_library_list,
8438 library_list_start_library, svr4_default_sos, svr4_read_so_list,
8439 svr4_current_sos, svr4_fetch_objfile_link_map,
8440 solist_update_incremental): Adjust.
8441 * solib-svr4.h (struct lm_info_svr4): Move here from
8443 * solib-target.c (struct lm_info): Rename to ...
8444 (struct lm_info_target): ... this. Extend lm_info_base.
8445 (lm_info_p): Rename to ...
8446 (lm_info_target_p): ... this.
8447 (solib_target_parse_libraries, library_list_start_segment,
8448 library_list_start_section, library_list_start_library,
8449 library_list_end_library, solib_target_free_library_list,
8450 solib_target_current_sos, solib_target_free_so,
8451 solib_target_relocate_section_addresses): Adjust.
8452 * windows-nat.c (struct lm_info): Rename to ...
8453 (struct lm_info_windows): ... this. Extend lm_info_base.
8454 (windows_make_so, handle_load_dll, handle_unload_dll,
8455 windows_xfer_shared_libraries): Adjust.
8457 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
8459 * solib-darwin.c (struct darwin_so_list): Remove.
8460 (darwin_current_sos): Allocate an so_list object instead of a
8461 darwin_so_list, separately allocate an lm_info object.
8462 (darwin_free_so): Free lm_info.
8464 2017-04-28 John Baldwin <jhb@FreeBSD.org>
8466 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
8467 with fprintf_filtered.
8469 2017-04-28 Yao Qi <yao.qi@linaro.org>
8471 * regcache.c (regcache::regcache): New function.
8472 (regcache::~regcache): New function.
8473 (regcache_xmalloc_1): Remove.
8474 (regcache_xmalloc): Call new regcache.
8475 (regcache_xfree): Call delete regcache.
8476 (get_thread_arch_aspace_regcache): Call new regcache.
8478 2017-04-28 Yao Qi <yao.qi@linaro.org>
8480 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
8481 lwp instead of ptid_get_lwp.
8483 2017-04-28 Yao Qi <yao.qi@linaro.org>
8485 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
8486 lwp_info instead of getting from inferior_ptid.
8488 2017-04-27 Keith Seitz <keiths@redhat.com>
8490 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
8491 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
8492 (CV_CONVERSION_BADNESS): Define.
8493 (rank_one_type): Remove overly restrictive rvalue reference
8495 Add cv-qualifier checks and subranks for type equality.
8496 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
8497 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
8498 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
8500 2017-04-27 Simon Marchi <simon.marchi@ericsson.com>
8502 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
8503 count when creating the object.
8505 2017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
8506 Ulrich Weigand <uweigand@de.ibm.com>
8508 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
8509 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
8511 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
8512 (process_xcoff_symbol): Likewise.
8513 (scan_xcoff_symtab): Likewise.
8515 2017-04-26 Alan Hayward <alan.hayward@arm.com>
8517 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
8518 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
8519 (ia64_access_reg): Use get_frame_register_unsigned.
8520 (ia64_access_rse_reg): Likewise.
8521 (ia64_libunwind_frame_prev_register): Likewise.
8523 2017-04-26 Jiong Wang <jiong.wang@arm.com>
8525 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
8526 * gdbarch.c: Regenerated.
8527 * gdbarch.h: Regenerated.
8528 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
8529 visibility external.
8530 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
8531 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
8532 (enum cfa_how_kind): Move to ...
8533 (struct dwarf2_frame_state_reg_info): Likewise.
8534 (struct dwarf2_frame_state): Likewise.
8535 * dwarf2-frame.h: ... here.
8536 (dwarf2_frame_state_alloc_regs): New declaration.
8537 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
8538 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
8540 2017-04-26 Alan Hayward <alan.hayward@arm.com>
8542 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
8543 regcache_raw_read_unsigned.
8544 (xtensa_pseudo_register_write): Likewise.
8546 2017-04-26 Alan Hayward <alan.hayward@arm.com>
8548 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
8549 (nds32_pseudo_register_write): Likewise.
8551 2017-04-25 Yao Qi <yao.qi@linaro.org>
8553 * regcache.c (struct regcache) <readonly_p>: Change its type
8555 (regcache_xmalloc_1): Update parameter type and callers update.
8557 2017-04-25 Yao Qi <yao.qi@linaro.org>
8559 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
8560 set_gdbarch_wchar_bit.
8561 * arm-tdep.c (arm_gdbarch_init): Likewise.
8563 2017-04-25 Pedro Alves <palves@redhat.com>
8565 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
8566 (BothAreRelocatable, memcopy, memmove): Don't define.
8567 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
8570 2017-04-25 Pedro Alves <palves@redhat.com>
8572 * common/common-defs.h: Include "common/poison.h".
8573 * common/function-view.h: (Not, Or, Requires): Move to traits.h
8575 * common/poison.h: New file.
8576 * common/traits.h: Include <type_traits>.
8577 (Not, Or, Requires): New, moved from common/function-view.h.
8579 2017-04-25 Pedro Alves <palves@redhat.com>
8581 * breakpoint.h (struct breakpoint): In-class initialize all
8582 fields. Make boolean fields "bool".
8583 * breakpoint.c (init_raw_breakpoint_without_location): Remove
8584 memset call and initializations no longer necessary.
8586 2017-04-25 Pedro Alves <palves@redhat.com>
8588 * btrace.c (pt_btrace_insn_flags): Change parameter type to
8590 (pt_btrace_insn): New function.
8591 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
8593 2017-04-25 Pedro Alves <palves@redhat.com>
8595 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
8596 "base" field and inherit from "bp_location" instead. Add
8598 (allocate_location_exception): Use new non-default ctor.
8599 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
8600 (init_bp_location): Convert to ...
8601 (bp_location::bp_location): ... this new ctor, and remove memset
8603 (base_breakpoint_allocate_location): Use the new non-default ctor.
8604 * breakpoint.h (bp_location): Now a class. Declare default and
8605 non-default ctors. In-class initialize all members.
8606 (init_bp_location): Remove declaration.
8608 2017-04-25 Pedro Alves <palves@redhat.com>
8610 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
8611 assignment operator.
8613 2017-04-24 Yao Qi <yao.qi@linaro.org>
8615 * doublest.c (convert_doublest_to_floatformat): Call
8616 floatformat_totalsize_bytes.
8618 2017-04-22 Tom Tromey <tom@tromey.com>
8620 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
8622 * stack.c (print_frame): Use ui_out_emit_list.
8623 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
8625 * mi/mi-main.c (print_one_inferior)
8626 (mi_cmd_data_list_register_names)
8627 (mi_cmd_data_list_register_values, mi_cmd_list_features)
8628 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
8630 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
8631 (mi_output_solib_attribs): Use ui_out_emit_list,
8633 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
8634 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
8635 (mi_cmd_stack_list_args, list_args_or_locals): Use
8637 * disasm.c (do_assembly_only): Use ui_out_emit_list.
8638 * breakpoint.c (print_solib_event, output_thread_groups): Use
8641 2017-04-22 Tom Tromey <tom@tromey.com>
8643 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
8644 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
8645 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
8647 2017-04-22 Tom Tromey <tom@tromey.com>
8649 * tracepoint.c (tvariables_info_1)
8650 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
8652 2017-04-22 Tom Tromey <tom@tromey.com>
8654 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
8655 annotate_arg_emitter.
8656 * breakpoint.c (print_mention_watchpoint)
8657 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
8658 * annotate.h (struct annotate_arg_emitter): New.
8660 2017-04-22 Tom Tromey <tom@tromey.com>
8662 * record-btrace.c (record_btrace_insn_history)
8663 (record_btrace_insn_history_range, record_btrace_call_history)
8664 (record_btrace_call_history_range): Use ui_out_emit_tuple.
8665 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
8667 * stack.c (print_frame_info): Use ui_out_emit_tuple.
8668 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
8669 * skip.c (skip_info): Use ui_out_emit_tuple.
8670 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
8671 * progspace.c (print_program_space): Use ui_out_emit_tuple.
8672 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
8673 * osdata.c (info_osdata): Use ui_out_emit_tuple.
8674 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
8676 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
8677 (output_register, mi_cmd_data_read_memory)
8678 (mi_cmd_data_read_memory_bytes, mi_load_progress)
8679 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
8680 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
8681 Use ui_out_emit_tuple.
8682 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
8684 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
8685 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
8686 * linux-thread-db.c (info_auto_load_libthread_db): Use
8688 * inferior.c (print_inferior): Use ui_out_emit_tuple.
8689 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
8690 * disasm.c (do_mixed_source_and_assembly_deprecated)
8691 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
8692 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
8693 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
8694 * breakpoint.c (print_one_breakpoint_location)
8695 (print_one_breakpoint): Use ui_out_emit_tuple.
8696 * auto-load.c (print_script, info_auto_load_cmd): Use
8698 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
8700 2017-04-21 Simon Marchi <simon.marchi@ericsson.com>
8702 * thread.c (print_thread_info_1): Remove dead code.
8704 2017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
8706 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
8708 * arm-tdep.c (selftests::arm_record_test): Likewise.
8710 2017-04-21 Yao Qi <yao.qi@linaro.org>
8712 * regcache.c (regcache_restore): Remove argument 2. Replace
8713 argument 3 with regcache. Get register status from
8714 src->register_status and get register contents from
8715 register_buffer (src, regnum).
8716 (regcache_cpy): Update.
8718 2017-04-19 Pedro Alves <palves@redhat.com>
8720 * gdbthread.h (thread): Add missing closing parenthesis in
8723 2017-04-19 Pedro Alves <palves@redhat.com>
8725 * common/refcounted-object.h: New file.
8726 * gdbthread.h: Include "common/refcounted-object.h".
8727 (thread_info): Inherit from refcounted_object and add comments.
8728 (thread_info::incref, thread_info::decref)
8729 (thread_info::m_refcount): Delete.
8730 (thread_info::deletable): Use the refcounted_object::refcount()
8732 * inferior.c (current_inferior_): Add comment.
8733 (set_current_inferior): Increment/decrement refcounts.
8734 (prune_inferiors, remove_inferior_command): Skip inferiors marked
8735 not-deletable instead of comparing with the current inferior.
8736 (initialize_inferiors): Increment the initial inferior's refcount.
8737 * inferior.h (struct inferior): Forward declare.
8738 Include "common/refcounted-object.h".
8739 (current_inferior, set_current_inferior): Move declaration to
8740 before struct inferior's definition, and fix comment.
8741 (inferior): Inherit from refcounted_object. Add comments.
8742 * thread.c (switch_to_thread_no_regs): Reference the thread's
8743 inferior pointer directly instead of doing a ptid lookup.
8744 (switch_to_no_thread): New function.
8745 (switch_to_thread(thread_info *)): New function, factored out
8747 (switch_to_thread(ptid_t)): ... this.
8748 (restore_current_thread): Delete.
8749 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
8750 fields, and add 'inf' field.
8751 (do_restore_current_thread_cleanup): Check whether old->inf is
8752 alive instead of looking up an inferior by ptid. Use
8753 switch_to_thread and switch_to_no_thread.
8754 (restore_current_thread_cleanup_dtor): Use old->inf directly
8755 instead of lookup up an inferior by id. Decref the inferior.
8756 Don't restore 'removable'.
8757 (make_cleanup_restore_current_thread): Same the inferior pointer
8758 in old, instead of the inferior number. Incref the inferior.
8759 Don't save/clear 'removable'.
8761 2017-04-19 Pedro Alves <palves@redhat.com>
8763 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8764 unittests/scoped_restore-selftests.c.
8765 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
8766 * common/scoped_restore.h (scoped_restore_base): Make "class".
8767 (scoped_restore_base::release): New public method.
8768 (scoped_restore_base::scoped_restore_base): New protected ctor.
8769 (scoped_restore_base::m_saved_var): New protected field.
8770 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
8771 scoped_restore_base base class instead of m_saved_var directly.
8772 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
8773 (scoped_restore_tmpl::scoped_restore_tmpl(const
8774 scoped_restore_tmpl<T>&)): Likewise.
8775 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
8777 (scoped_restore_tmpl::saved_var): New method.
8778 (scoped_restore_tmpl::m_saved_var): Delete.
8779 * inferior.h (inferior::detaching): Now a bool.
8780 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
8782 * unittests/scoped_restore-selftests.c: New file.
8784 2017-04-19 Pedro Alves <palves@redhat.com>
8786 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
8787 Re-sort in alphabetic order.
8789 2017-04-18 Pedro Alves <palves@redhat.com>
8791 * xml-support.c (obstack_xml_printf): Delete.
8792 * xml-support.h (obstack_xml_printf): Delete.
8794 2017-04-18 Pedro Alves <palves@redhat.com>
8796 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
8797 vdebug, verror, body_text, start_element, end_element, name,
8798 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
8799 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
8800 is_xinclude>: Make private and add m_ prefix.
8801 (gdb_xml_parser::body_text): New method, based on ...
8802 (gdb_xml_body_text): ... this. Adjust.
8803 (gdb_xml_parser::vdebug): New method, based on ...
8804 (gdb_xml_debug): ... this. Adjust.
8805 (gdb_xml_parser::verror): New method, based on ...
8806 (gdb_xml_error): ... this. Adjust.
8807 (gdb_xml_parser::start_element): New method, based on ...
8808 (gdb_xml_start_element): ... this. Adjust.
8809 (gdb_xml_start_element_wrapper): Defer to
8810 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
8811 (gdb_xml_parser::end_element): New method, based on ...
8812 (gdb_xml_end_element_wrapper): ... this. Adjust.
8813 (gdb_xml_parser::~gdb_xml_parser): Adjust.
8814 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
8815 (gdb_xml_parser::use_dtd): New method, based on ...
8816 (gdb_xml_use_dtd): ... this. Adjust.
8817 (gdb_xml_parser::parse): New method, based on ...
8818 (gdb_xml_parse): ... this. Adjust.
8819 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
8820 (xinclude_start_include): Adjust to call the parser's name method.
8821 (xml_xinclude_default, xml_xinclude_start_doctype)
8822 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
8824 (xml_process_xincludes): Adjust to call parser methods.
8825 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
8828 2017-04-18 Pedro Alves <palves@redhat.com>
8830 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
8831 gdb::optional<std::string>.
8832 * xml-support.c: Include <string>.
8833 (scope_level::scope_level(scope_level &&))
8834 (scope_level::~scope_level): Delete.
8835 (scope_level::body): Now a std::string.
8836 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
8837 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
8839 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
8840 (xinclude_parsing_data::output): Now a std::string reference.
8841 (xinclude_start_include): Adjust.
8842 (xml_xinclude_default): Adjust.
8843 (xml_process_xincludes): Add 'output' parameter, and return bool.
8844 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
8846 * xml-tdesc.c: Include <unordered_map> and <string>.
8847 (tdesc_xml_cache): Delete.
8848 (tdesc_xml_cache_s): Delete.
8849 (xml_cache): Now an std::unordered_map.
8850 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
8851 (target_fetch_description_xml): Change return type to
8852 gdb::optional<std::string>, and adjust.
8853 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
8854 (target_fetch_description_xml): Change return type to
8855 gdb::optional<std::string>.
8857 2017-04-18 Pedro Alves <palves@redhat.com>
8859 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8860 unittests/optional-selftests.c.
8861 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
8862 * unittests/optional-selftests.c: New file.
8863 * unittests/optional/assignment/1.cc: New file.
8864 * unittests/optional/assignment/2.cc: New file.
8865 * unittests/optional/assignment/3.cc: New file.
8866 * unittests/optional/assignment/4.cc: New file.
8867 * unittests/optional/assignment/5.cc: New file.
8868 * unittests/optional/assignment/6.cc: New file.
8869 * unittests/optional/assignment/7.cc: New file.
8870 * unittests/optional/cons/copy.cc: New file.
8871 * unittests/optional/cons/default.cc: New file.
8872 * unittests/optional/cons/move.cc: New file.
8873 * unittests/optional/cons/value.cc: New file.
8874 * unittests/optional/in_place.cc: New file.
8875 * unittests/optional/observers/1.cc: New file.
8876 * unittests/optional/observers/2.cc: New file.
8878 2017-04-18 Pedro Alves <palves@redhat.com>
8880 * common/gdb_optional.h: Include common/traits.h.
8881 (in_place_t): New type.
8882 (in_place): New constexpr variable.
8883 (optional::optional): Remove member initialization of
8885 (optional::optional(in_place_t...)): New constructor.
8886 (optional::~optional): Use reset.
8887 (optional::optional(const optional&)): New.
8888 (optional::optional(const optional&&)): New.
8889 (optional::optional(T &)): New.
8890 (optional::optional(T &&)): New.
8891 (operator::operator=(const optional &)): New.
8892 (operator::operator=(optional &&)): New.
8893 (operator::operator= (const T &))
8894 (operator::operator= (T &&))
8895 (operator::emplace (Args &&... args)): Return a T&. Use reset.
8896 (operator::reset): New.
8897 (operator::m_instantiated):: Add in-class initializer.
8898 * common/traits.h: Include <type_traits>.
8899 (struct And): New types.
8901 2017-04-18 Pedro Alves <palves@redhat.com>
8903 * xml-support.c: Include <vector>.
8904 (scope_level::scope_level(const gdb_xml_element *))
8905 (scope_level::scope_level(scope_level&&)): New.
8906 (scope_level::~scope_level): New.
8907 (scope_level_s): Delete.
8908 (gdb_xml_parser::scopes): Now a std::vector.
8909 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
8911 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
8913 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
8914 of the scopes member. Use std::vector::emplace_back.
8916 2017-04-18 Pedro Alves <palves@redhat.com>
8918 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
8920 (gdb_xml_end_element): Change type of first parameter.
8921 (gdb_xml_cleanup): Rename to ...
8922 (gdb_xml_parser::~gdb_xml_parser): ... this.
8923 (gdb_xml_create_parser_and_cleanup): Delete with ...
8924 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
8926 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
8927 using gdb_xml_create_parser_and_cleanup.
8928 (xinclude_parsing_data): Add ctor/dtor.
8929 (xml_xinclude_cleanup): Delete.
8930 (xml_process_xincludes): Create a local xinclude_parsing_data
8931 instead of heap-allocating one. Create a local gdb_xml_parser
8932 instead of heap-allocating one with
8933 gdb_xml_create_parser_and_cleanup.
8935 2017-04-18 John Baldwin <jhb@FreeBSD.org>
8938 * fbsd-nat.c (resume_one_thread_cb): Remove.
8939 (resume_all_threads_cb): Remove.
8940 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
8941 iterate_over_threads.
8943 2017-04-17 Joel Brobecker <brobecker@adacore.com>
8945 * NEWS: Create a new section for the next release branch.
8946 Rename the section of the current branch, now that it has
8949 2017-04-17 Joel Brobecker <brobecker@adacore.com>
8951 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
8952 * version.in: Bump version to 8.0.50.DATE-git.
8954 2017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
8957 * windows-nat.c (windows_create_inferior): Declare 'allargs'
8958 independently of the host, and fix build breakage on Cygwin.
8960 2017-04-13 Pedro Alves <palves@redhat.com>
8962 * inferior.c (free_inferior): Convert to ...
8963 (inferior::~inferior): ... this dtor.
8964 (inferior::inferior): New ctor, factored out from ...
8965 (add_inferior_silent): ... here. Allocate the inferior with a new
8967 (delete_inferior): Call delete instead of free_inferior.
8968 * inferior.h (gdb_environ, continuation): Forward declare.
8969 (inferior): Now a class. Add in-class initialization to all
8970 members. Make boolean fields bool, except 'detaching'.
8971 (inferior::inferior): New explicit ctor.
8972 (inferior::~inferior): New.
8974 2017-04-13 Pedro Alves <palves@redhat.com>
8976 * inferior.c (init_inferior_list): Delete.
8977 * inferior.h (init_inferior_list): Delete.
8979 2017-04-13 Pedro Alves <palves@redhat.com>
8982 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
8983 (top level): Call it twice, with different thread sets.
8985 2017-04-13 Pedro Alves <palves@redhat.com>
8987 * thread.c: Include <algorithm>.
8988 (thread_array_cleanup): Delete.
8989 (scoped_inc_dec_ref): New class.
8990 (live_threads_count): New function.
8991 (set_thread_refcount): Delete.
8992 (tp_array_compar_ascending): Now a bool.
8993 (tp_array_compar): Convert to a std::sort comparison function.
8994 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
8995 and live_threads_count.
8997 2017-04-13 Pedro Alves <palves@redhat.com>
8999 * infrun.c (follow_fork_inferior): Also switch the current
9002 2017-04-13 Pedro Alves <palves@redhat.com>
9004 * breakpoint.c (watch_command_1): Save watchpoint-frame info
9005 before calling create_internal_breakpoint.
9007 2017-04-13 Pedro Alves <palves@redhat.com>
9009 * fork-child.c (execv_argv): New class.
9010 (breakup_args): Refactored as ...
9011 (execv_argv::init_for_no_shell): .. this method of execv_argv.
9012 Copy arguments to storage and replace separators with NULL
9013 terminators in place.
9014 (escape_bang_in_quoted_argument): Adjust to return bool.
9015 (execv_argv::execv_argv): New ctor.
9016 (execv_argv::init_for_shell): New method, factored out from
9017 fork_inferior. Don't strdup strings into the vector.
9018 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
9019 Remove free_vector_argv call.
9021 2017-04-13 Yao Qi <yao.qi@linaro.org>
9023 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
9026 2017-04-13 Yao Qi <yao.qi@linaro.org>
9028 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
9029 * rx-tdep.c (rx_gdbarch_init): Likewise.
9031 2017-04-13 Pedro Alves <palves@redhat.com>
9033 * breakpoint.h (struct breakpoint): Reindent.
9035 2017-04-13 Pedro Alves <palves@redhat.com>
9037 * breakpoint.c (bp_location): Rename to ...
9038 (bp_locations): ... this. All references updated.
9039 (bp_location_count): Rename to ...
9040 (bp_locations_count): ... this. All references updated.
9041 (bp_location_placed_address_before_address_max): Rename to ...
9042 (bp_locations_placed_address_before_address_max): ... this. All
9044 (bp_location_shadow_len_after_address_max): Rename to ...
9045 (bp_locations_shadow_len_after_address_max): ... this. All
9047 (bp_location_compare_addrs): Rename to ...
9048 (bp_locations_compare_addrs): ... this. All references updated.
9049 (bp_location_compare):Rename to ...
9050 (bp_locations_compare): ... this. All references updated.
9051 (bp_location_target_extensions_update): Rename to ...
9052 (bp_locations_target_extensions_update): ... this. All references
9055 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
9057 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
9058 * common/common.m4: Check headers 'termios.h', 'termio.h' and
9060 * common/gdb_termios.h: New file, with parts of "terminal.h".
9061 * inflow.c: Include "gdb_termios.h".
9062 * ser-unix.c: Include "gdb_termios.h".
9063 * terminal.h: Move terminal-related defines to
9064 "common/gdb_termios.h".
9066 2017-04-12 Tom Tromey <tom@tromey.com>
9068 * probe.c (parse_probes): Update.
9069 * location.h (delete_event_location): Don't declare.
9070 (event_location_deleter::operator()): Update.
9071 * location.c (event_location_deleter::operator()): Rename from
9072 delete_event_location.
9073 * linespec.h (linespec_result) <location>: Change type to
9075 * linespec.c (canonicalize_linespec, event_location_to_sals)
9076 (decode_objc): Update.
9077 (linespec_result): Don't call delete_event_location.
9078 * breakpoint.c (create_breakpoints_sal)
9079 (bkpt_probe_create_sals_from_location)
9080 (strace_marker_create_sals_from_location): Update.
9082 2017-04-12 Tom Tromey <tom@tromey.com>
9084 * linespec.h (struct linespec_result): Add constructor and
9086 (init_linespec_result, destroy_linespec_result)
9087 (make_cleanup_destroy_linespec_result): Don't declare.
9088 * linespec.c (init_linespec_result): Remove.
9089 (linespec_result::~linespec_result): Rename from
9090 destroy_linespec_result. Update.
9091 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
9093 * breakpoint.c (create_breakpoint, break_range_command)
9094 (decode_location_default): Update.
9095 * ax-gdb.c (agent_command_1): Update.
9097 2017-04-12 Tom Tromey <tom@tromey.com>
9099 * remote.c (remote_download_tracepoint): Update.
9100 * python/py-breakpoint.c (bppy_get_location): Update.
9101 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
9102 (gdbscm_breakpoint_location): Update.
9103 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
9104 * breakpoint.h (struct breakpoint) <location, location_range_end>:
9105 Change type to event_location_up.
9106 * breakpoint.c (create_overlay_event_breakpoint)
9107 (create_longjmp_master_breakpoint)
9108 (create_std_terminate_master_breakpoint)
9109 (create_exception_master_breakpoint)
9110 (breakpoint_event_location_empty_p, print_breakpoint_location)
9111 (print_one_breakpoint_location, create_thread_event_breakpoint)
9112 (init_breakpoint_sal, create_breakpoint)
9113 (print_recreate_ranged_breakpoint, break_range_command)
9114 (init_ada_exception_breakpoint, say_where): Update.
9115 (base_breakpoint_dtor): Don't call delete_event_location.
9116 (bkpt_print_recreate, tracepoint_print_recreate)
9117 (dprintf_print_recreate, update_static_tracepoint)
9118 (breakpoint_re_set_default): Update.
9120 2017-04-12 Tom Tromey <tom@tromey.com>
9122 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
9123 type of "to_do". Update.
9124 (compute_stack_depth): Use std::vector.
9126 2017-04-12 Tom Tromey <tom@tromey.com>
9128 * printcmd.c (find_instruction_backward): Use std::vector.
9130 2017-04-12 Tom Tromey <tom@tromey.com>
9132 * symfile.c (objfilep): Remove typedef.
9133 (reread_symbols): Use a std::vector.
9135 2017-04-12 Tom Tromey <tom@tromey.com>
9137 * mi/mi-main.c (exec_direction_forward): Remove.
9138 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
9139 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
9141 * guile/guile.c (guile_repl_command, guile_command)
9142 (gdbscm_execute_gdb_command): Use scoped_restore.
9143 * go-exp.y (go_parse): Use scoped_restore.
9144 * d-exp.y (d_parse): Use scoped_restore.
9145 * cli/cli-decode.c (cmd_func): Use scoped_restore.
9146 * c-exp.y (c_parse): Use scoped_restore.
9148 2017-04-12 Tom Tromey <tom@tromey.com>
9150 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
9151 (mi_parse): Update return type.
9152 (mi_parse_free): Remove.
9153 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
9154 (mi_parse::~mi_parse): Rename from mi_parse_free.
9155 (mi_parse_cleanup): Remove.
9156 (mi_parse): Return a unique_ptr. Use new.
9157 * mi/mi-main.c (mi_execute_command): Update.
9159 2017-04-12 Tom Tromey <tom@tromey.com>
9161 * location.c (explicit_location_lex_one): Return a
9163 (string_to_explicit_location): Update. Remove cleanups.
9165 2017-04-12 Tom Tromey <tom@tromey.com>
9167 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
9168 (compare_value_and_voffset): Change type. Update.
9169 (compute_vtable_size): Change type of "offset_vec".
9170 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
9171 (gnuv3_get_typeid): Remove extraneous declaration.
9173 2017-04-12 Tom Tromey <tom@tromey.com>
9175 * charset.h (wchar_iterator): Fix comment.
9177 2017-04-12 Tom Tromey <tom@tromey.com>
9179 * charset.c (iconv_wrapper): New class.
9180 (cleanup_iconv): Remove.
9181 (convert_between_encodings): Use it.
9183 2017-04-12 Tom Tromey <tom@tromey.com>
9185 * symfile.h (increment_reading_symtab): Update type.
9186 * symfile.c (decrement_reading_symtab): Remove.
9187 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
9188 * psymtab.c (psymtab_to_symtab): Update.
9189 * dwarf2read.c (dw2_instantiate_symtab): Update.
9191 2017-04-12 Tom Tromey <tom@tromey.com>
9193 * jit.c (struct jit_reader): Declare separately. Add constructor
9194 and destructor. Change type of "handle".
9195 (loaded_jit_reader): Define separately.
9196 (jit_reader_load): Update. New "new".
9197 (jit_reader_unload_command): Use "delete".
9198 * gdb-dlfcn.h (struct dlclose_deleter): New.
9199 (gdb_dlhandle_up): New typedef.
9200 (gdb_dlopen, gdb_dlsym): Update types.
9201 (gdb_dlclose): Remove.
9202 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
9203 (gdb_dlsym): Change type of "handle".
9204 (make_cleanup_dlclose): Remove.
9205 (dlclose_deleter::operator()): Rename from gdb_dlclose.
9206 * compile/compile-c-support.c (load_libcc): Update.
9208 2017-04-12 Tom Tromey <tom@tromey.com>
9210 * symtab.h (find_pcs_for_symtab_line): Change return type.
9211 * symtab.c (find_pcs_for_symtab_line): Change return type.
9212 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
9213 type of "vec". Update.
9214 (ltpy_get_pcs_for_line): Update.
9215 * linespec.c (decode_digits_ordinary): Update.
9217 2017-04-12 Tom Tromey <tom@tromey.com>
9219 * tracepoint.c (actions_command): Update.
9220 * python/python.c (python_command, python_interactive_command):
9222 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
9223 * guile/guile.c (guile_command): Update.
9224 * defs.h (read_command_lines, read_command_lines_1): Return
9226 (command_lines_deleter): New struct.
9227 (command_line_up): New typedef.
9228 * compile/compile.c (compile_code_command)
9229 (compile_print_command): Update.
9230 * cli/cli-script.h (get_command_line, copy_command_lines): Return
9232 (make_cleanup_free_command_lines): Remove.
9233 * cli/cli-script.c (get_command_line, read_command_lines_1)
9234 (copy_command_lines): Return command_line_up.
9235 (while_command, if_command, read_command_lines, define_command)
9236 (document_command): Update.
9237 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
9239 * breakpoint.h (breakpoint_set_commands): Change type of
9241 * breakpoint.c (breakpoint_set_commands): Change type of
9243 (do_map_commands_command, update_dprintf_command_list)
9244 (create_tracepoint_from_upload): Update.
9246 2017-04-12 Tom Tromey <tom@tromey.com>
9248 * tracepoint.c (scope_info): Update.
9249 * spu-tdep.c (spu_catch_start): Update.
9250 * python/python.c (gdbpy_decode_line): Update.
9251 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
9252 * python/py-breakpoint.c (bppy_init): Update.
9253 * probe.c (parse_probes): Update.
9254 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
9255 * location.h (event_location_deleter): New struct.
9256 (event_location_up): New typedef.
9257 (new_linespec_location, new_address_location, new_probe_location)
9258 (new_explicit_location, copy_event_location)
9259 (string_to_event_location, string_to_event_location_basic)
9260 (string_to_explicit_location): Update return type.
9261 (make_cleanup_delete_event_location): Remove.
9262 * location.c (new_linespec_location, new_address_location)
9263 (new_probe_location, new_explicit_location, copy_event_location):
9264 Return event_location_up.
9265 (delete_event_location_cleanup)
9266 (make_cleanup_delete_event_location): Remove.
9267 (string_to_explicit_location, string_to_event_location_basic)
9268 (string_to_event_location): Return event_location_up.
9269 * linespec.c (canonicalize_linespec, event_location_to_sals)
9270 (decode_line_with_current_source)
9271 (decode_line_with_last_displayed, decode_objc): Update.
9272 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
9273 * completer.c (location_completer): Update.
9274 * cli/cli-cmds.c (edit_command, list_command): Update.
9275 * breakpoint.c (create_overlay_event_breakpoint)
9276 (create_longjmp_master_breakpoint)
9277 (create_std_terminate_master_breakpoint)
9278 (create_exception_master_breakpoint)
9279 (create_thread_event_breakpoint): Update.
9280 (init_breakpoint_sal): Update. Remove some dead code.
9281 (create_breakpoint_sal): Change type of "location". Update.
9282 (create_breakpoints_sal, create_breakpoint, break_command_1)
9283 (dprintf_command, break_range_command, until_break_command)
9284 (init_ada_exception_breakpoint)
9285 (strace_marker_create_sals_from_location)
9286 (update_static_tracepoint, trace_command, ftrace_command)
9287 (strace_command, create_tracepoint_from_upload): Update.
9288 * break-catch-throw.c (re_set_exception_catchpoint): Update.
9289 * ax-gdb.c (agent_command_1): Update.
9291 2017-04-12 Pedro Alves <palves@redhat.com>
9293 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
9294 * configure.tgt: Handle i[34567]86-*-go32* and
9295 i[34567]86-*-msdosdjgpp*.
9296 * i386-tdep.c (i386_svr4_reg_to_regnum):
9298 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
9300 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
9301 * i386-go32-tdep.c: New file.
9302 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
9305 2017-04-12 Simon Marchi <simon.marchi@ericsson.com>
9307 * aix-thread.c (pd_status2str): Change return type to const char *.
9309 2017-04-12 Pedro Alves <palves@redhat.com>
9311 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
9312 calls to set_gdbarch_gnu_triplet_regexp.
9314 2017-04-12 Pedro Alves <palves@redhat.com>
9317 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
9319 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
9320 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
9321 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
9322 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
9323 * gdbarch.h, gdbarch.c: Regenerate.
9324 * aarch64-tdep.c (aarch64_gdbarch_init): Override
9325 gdbarch_wchar_bit and gdbarch_wchar_signed.
9326 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
9327 * arm-tdep.c (arm_gdbarch_init): Likewise.
9328 * avr-tdep.c (avr_gdbarch_init): Likewise.
9329 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
9330 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
9331 * i386-tdep.c (i386_go32_init_abi): Likewise.
9332 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
9333 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
9334 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
9335 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
9336 * sh-tdep.c (sh_gdbarch_init): Likewise.
9337 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
9338 * sparc64-tdep.c (sparc64_init_abi): Likewise.
9339 * windows-tdep.c (windows_init_abi): Likewise.
9340 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
9342 2017-04-12 Pedro Alves <palves@redhat.com>
9345 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
9346 cplus_primitive_type_char32_t>: New enum values.
9347 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
9348 and cplus_primitive_type_char32_t.
9349 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
9350 32, use the archtecture's built-in type for char16_t and char32_t,
9351 respectively. Otherwise, fallback to init_integer_type as before,
9352 but make the type unsigned, and issue a complaint.
9353 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
9355 2017-04-12 Alan Hayward <alan.hayward@arm.com>
9357 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
9358 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
9360 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
9362 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
9365 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
9367 * common/common-utils.c (free_vector_argv): New function.
9368 * common/common-utils.h: Include <vector>.
9369 (free_vector_argv): New prototype.
9370 * darwin-nat.c (darwin_create_inferior): Rewrite function
9371 prototype in order to constify "exec_file" and accept a
9372 "std::string" for "allargs".
9373 * fork-child.c: Include <vector>.
9374 (breakup_args): Rewrite function, using C++.
9375 (fork_inferior): Rewrite function header, constify "exec_file_arg"
9376 and accept "std::string" for "allargs". Update the code to
9377 calculate "argv" based on "allargs". Update calls to "exec_fun"
9379 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
9380 order to constify "exec_file" and accept a "std::string" for
9382 * go32-nat.c (go32_create_inferior): Likewise.
9383 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
9384 * infcmd.c (run_command_1): Constify "exec_file". Use
9385 "std::string" for inferior arguments.
9386 * inferior.h (fork_inferior): Update prototype.
9387 * linux-nat.c (linux_nat_create_inferior): Rewrite function
9388 prototype in order to constify "exec_file" and accept a
9389 "std::string" for "allargs".
9390 * nto-procfs.c (procfs_create_inferior): Likewise.
9391 * procfs.c (procfs_create_inferior): Likewise.
9392 * remote-sim.c (gdbsim_create_inferior): Likewise.
9393 * remote.c (extended_remote_run): Update code to accept
9394 "std::string" as argument.
9395 (extended_remote_create_inferior): Rewrite function prototype in
9396 order to constify "exec_file" and accept a "std::string" for
9398 * rs6000-nat.c (super_create_inferior): Likewise.
9399 (rs6000_create_inferior): Likewise.
9400 * target.h (struct target_ops) <to_create_inferior>: Likewise.
9401 * windows-nat.c (windows_create_inferior): Likewise.
9403 2017-04-11 Pedro Alves <palves@redhat.com>
9405 * thread.c: Fix whitespace throughout.
9407 2017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
9409 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
9411 2017-04-11 Alan Hayward <alan.hayward@arm.com>
9413 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
9415 2017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
9418 * osdata.c (info_osdata): Check if 'type' is an empty string
9421 2017-04-10 Pedro Alves <palves@redhat.com>
9423 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
9424 (ptid_to_global_thread_id, in_thread_list)
9425 (do_captured_list_thread_ids, set_resumed, set_running)
9426 (set_executing, set_stop_requested, finish_thread_state)
9427 (validate_registers_access, can_access_registers_ptid)
9428 (print_thread_info_1, switch_to_thread)
9429 (do_restore_current_thread_cleanup)
9430 (make_cleanup_restore_current_thread, thread_command)
9431 (thread_name_command): Use operator== instead of ptid_equal.
9433 2017-04-10 Pedro Alves <palves@redhat.com>
9435 * thread.c (struct current_thread_cleanup) <next>: Delete field.
9436 (current_thread_cleanup_chain): Delete.
9437 (restore_current_thread_cleanup_dtor)
9438 (make_cleanup_restore_current_thread): Remove references to
9439 current_thread_cleanup_chain.
9441 2017-04-10 Alan Hayward <alan.hayward@arm.com>
9443 * msp430-tdep.c (msp430_pseudo_register_read): Never return
9446 2017-04-10 Yao Qi <yao.qi@linaro.org>
9449 * gdbthread.h (thread_info::deletable): New method.
9450 (thread_info::incref): New method.
9451 (thread_info::decref): New method.
9452 (thread_info::refcount): Move it to private.
9453 * infrun.c (save_stop_context): Call inc_refcount.
9454 (release_stop_context_cleanup): Likewise.
9455 * thread.c (set_thread_exited): New function.
9456 (init_thread_list): Delete "tp" only it is deletable, otherwise
9457 call set_thread_exited.
9458 (delete_thread_1): Call set_thread_exited.
9459 (current_thread_cleanup) <inferior_pid>: Remove.
9460 <thread>: New field.
9461 (restore_current_thread_ptid_changed): Removed.
9462 (do_restore_current_thread_cleanup): Adjust.
9463 (restore_current_thread_cleanup_dtor): Don't call
9465 (set_thread_refcount): Use dec_refcount.
9466 (make_cleanup_restore_current_thread): Adjust.
9467 (thread_apply_all_command): Call inc_refcount.
9468 (_initialize_thread): Don't call
9469 observer_attach_thread_ptid_changed.
9471 2017-04-10 Yao Qi <yao.qi@linaro.org>
9473 * thread.c (delete_thread_1): Hoist code on marking thread as
9476 2017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
9478 * windows-nat.c (windows_detach): Initialize ptid with
9481 2017-04-07 Simon Marchi <simon.marchi@ericsson.com>
9483 * unittests/ptid-selftests.c: Fix erroneous assert messages.
9485 2017-04-07 Alan Hayward <alan.hayward@arm.com>
9487 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
9488 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
9489 (bfin_pseudo_register_write): Likewise
9491 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
9493 * common/ptid.h (struct ptid): Change to...
9494 (class ptid_t): ... this.
9495 <ptid_t>: New constructors.
9496 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
9497 matches>: New methods.
9498 <make_null, make_minus_one>: New static methods.
9505 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
9506 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
9507 as references, move comment to class ptid_t.
9508 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
9509 ptid_t static methods.
9510 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
9511 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
9512 Take ptid arguments as references, implement using ptid_t methods.
9513 * unittests/ptid-selftests.c: New file.
9514 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9515 unittests/ptid-selftests.c.
9516 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
9518 2017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
9520 * python/python.c (python_run_simple_file): Cast mode literal to
9521 non-const char pointer as expected by PyFile_FromString.
9523 2017-04-05 Simon Marchi <simon.marchi@ericsson.com>
9525 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
9526 minus_one_ptid and null_ptid.
9528 2017-04-05 Pedro Alves <palves@redhat.com>
9530 * warning.m4 (build_warnings): Remove -Wno-write-strings.
9531 * configure: Regenerate.
9533 2017-04-05 Pedro Alves <palves@redhat.com>
9535 * ada-exp.y (yyerror): Constify.
9536 * ada-lang.c (bound_name, get_selections)
9537 (ada_variant_discrim_type)
9538 (ada_variant_discrim_name, ada_value_struct_elt)
9539 (ada_lookup_struct_elt_type, is_unchecked_variant)
9540 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
9541 (catch_ada_exception_command_split)
9542 (catch_ada_assert_command_split, catch_assert_command)
9543 (ada_op_name): Constify.
9544 * ada-lang.h (ada_yyerror, get_selections)
9545 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
9546 * arc-tdep.c (arc_print_frame_cache): Constify.
9547 * arm-tdep.c (arm_skip_stub): Constify.
9548 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
9549 (gen_aggregate_elt_ref): Constify.
9550 * bcache.c (print_bcache_statistics): Constify.
9551 * bcache.h (print_bcache_statistics): Constify.
9552 * break-catch-throw.c (catch_exception_command_1):
9553 * breakpoint.c (struct ep_type_description::description):
9555 (add_solib_catchpoint): Constify.
9556 (catch_fork_command_1): Add cast.
9557 (add_catch_command): Constify.
9558 * breakpoint.h (add_catch_command, add_solib_catchpoint):
9560 * bsd-uthread.c (bsd_uthread_state): Constify.
9561 * buildsym.c (patch_subfile_names): Constify.
9562 * buildsym.h (next_symbol_text_func, patch_subfile_names):
9564 * c-exp.y (yyerror): Constify.
9565 (token::oper): Constify.
9566 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
9567 * c-varobj.c (cplus_describe_child): Constify.
9568 * charset.c (find_charset_names): Add cast.
9569 (find_charset_names): Constify array and add const_cast.
9570 * cli/cli-cmds.c (complete_command, cd_command): Constify.
9571 (edit_command): Constify.
9572 * cli/cli-decode.c (lookup_cmd): Constify.
9573 * cli/cli-dump.c (dump_memory_command, dump_value_command):
9575 (struct dump_context): Constify.
9576 (add_dump_command, restore_command): Constify.
9577 * cli/cli-script.c (get_command_line): Constify.
9578 * cli/cli-script.h (get_command_line): Constify.
9579 * cli/cli-utils.c (check_for_argument): Constify.
9580 * cli/cli-utils.h (check_for_argument): Constify.
9581 * coff-pe-read.c (struct read_pe_section_data): Constify.
9582 * command.h (lookup_cmd): Constify.
9583 * common/print-utils.c (decimal2str): Constify.
9584 * completer.c (gdb_print_filename): Constify.
9585 * corefile.c (set_gnutarget): Constify.
9586 * cp-name-parser.y (yyerror): Constify.
9587 * cp-valprint.c (cp_print_class_member): Constify.
9588 * cris-tdep.c (cris_register_name, crisv32_register_name):
9590 * d-exp.y (yyerror): Constify.
9591 (struct token::oper): Constify.
9592 * d-lang.h (d_yyerror): Constify.
9593 * dbxread.c (struct header_file_location::name): Constify.
9594 (add_old_header_file, add_new_header_file, last_function_name)
9595 (dbx_next_symbol_text, add_bincl_to_list)
9596 (find_corresponding_bincl_psymtab, set_namestring)
9597 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
9598 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
9599 * defs.h (command_line_input, print_address_symbolic)
9600 (deprecated_readline_begin_hook): Constify.
9601 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
9603 * event-top.c (handle_line_of_input): Constify and add cast.
9604 * exceptions.c (catch_errors): Constify.
9605 * exceptions.h (catch_errors): Constify.
9606 * expprint.c (print_subexp_standard, op_string, op_name)
9607 (op_name_standard, dump_raw_expression, dump_raw_expression):
9608 * expression.h (op_name, op_string, dump_raw_expression):
9610 * f-exp.y (yyerror): Constify.
9611 (struct token::oper): Constify.
9612 (struct f77_boolean_val::name): Constify.
9613 * f-lang.c (f_word_break_characters): Constify.
9614 * f-lang.h (f_yyerror): Constify.
9615 * fork-child.c (fork_inferior): Add cast.
9616 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
9617 (new_variant): Constify.
9618 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
9619 * gdbarch.c: Regenerate.
9620 * gdbcore.h (set_gnutarget): Constify.
9621 * go-exp.y (yyerror): Constify.
9622 (token::oper): Constify.
9623 * go-lang.h (go_yyerror): Constify.
9624 * go32-nat.c (go32_sysinfo): Constify.
9625 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
9626 * guile/scm-cmd.c (cmdscm_function): Constify.
9627 * guile/scm-param.c (pascm_param_value): Constify.
9628 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
9629 (h8300sx_register_name): Constify.
9630 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
9632 * ia64-tdep.c (ia64_register_names): Constify.
9633 * infcmd.c (construct_inferior_arguments): Constify.
9634 (path_command, attach_post_wait): Constify.
9635 * language.c (show_range_command, show_case_command)
9636 (unk_lang_error): Constify.
9637 * language.h (language_defn::la_error)
9638 (language_defn::la_name_of_this): Constify.
9639 * linespec.c (decode_line_2): Constify.
9640 * linux-thread-db.c (thread_db_err_str): Constify.
9641 * lm32-tdep.c (lm32_register_name): Constify.
9642 * m2-exp.y (yyerror): Constify.
9643 * m2-lang.h (m2_yyerror): Constify.
9644 * m32r-tdep.c (m32r_register_names): Constify and make static.
9645 * m68hc11-tdep.c (m68hc11_register_names): Constify.
9646 * m88k-tdep.c (m88k_register_name): Constify.
9647 * macroexp.c (appendmem): Constify.
9648 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
9649 (upgrade_type, parse_external, parse_partial_symbols)
9650 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
9651 (new_symbol): Constify.
9652 * memattr.c (mem_info_command): Constify.
9653 * mep-tdep.c (register_name_from_keyword): Constify.
9654 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
9656 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
9657 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
9658 * mi/mi-main.c (captured_mi_execute_command): Constify and add
9660 (mi_execute_async_cli_command): Constify.
9661 * mips-tdep.c (mips_register_name): Constify.
9662 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
9663 (am33_register_name, am33_2_register_name)
9664 * moxie-tdep.c (moxie_register_names): Constify.
9665 * nat/linux-osdata.c (osdata_type): Constify fields.
9666 * nto-tdep.c (nto_parse_redirection): Constify.
9667 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
9668 (lookup_child_selector): Constify.
9669 (objc_methcall::name): Constify.
9670 * objc-lang.h (lookup_objc_class, lookup_child_selector)
9671 (lookup_struct_typedef): Constify.
9672 * objfiles.c (pc_in_section): Constify.
9673 * objfiles.h (pc_in_section): Constify.
9674 * p-exp.y (struct token::oper): Constify.
9675 (yyerror): Constify.
9676 * p-lang.h (pascal_yyerror): Constify.
9677 * parser-defs.h (op_name_standard): Constify.
9678 (op_print::string): Constify.
9679 (exp_descriptor::op_name): Constify.
9680 * printcmd.c (print_address_symbolic): Constify.
9681 * psymtab.c (print_partial_symbols): Constify.
9682 * python/py-breakpoint.c (stop_func): Constify.
9683 (bppy_get_expression): Constify.
9684 * python/py-cmd.c (cmdpy_completer::name): Constify.
9685 (cmdpy_function): Constify.
9686 * python/py-event.c (evpy_add_attribute)
9687 (gdbpy_initialize_event_generic): Constify.
9688 * python/py-event.h (evpy_add_attribute)
9689 (gdbpy_initialize_event_generic): Constify.
9690 * python/py-evts.c (add_new_registry): Constify.
9691 * python/py-finishbreakpoint.c (outofscope_func): Constify.
9692 * python/py-framefilter.c (get_py_iter_from_func): Constify.
9693 * python/py-inferior.c (get_buffer): Add cast.
9694 * python/py-param.c (parm_constant::name): Constify.
9695 * python/py-unwind.c (fprint_frame_id): Constify.
9696 * python/python.c (gdbpy_parameter_value): Constify.
9697 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
9698 * remote.c (memory_packet_config::name): Constify.
9699 (show_packet_config_cmd, remote_write_bytes)
9700 (remote_buffer_add_string):
9701 * reverse.c (exec_reverse_once): Constify.
9702 * rs6000-tdep.c (variant::name, variant::description): Constify.
9703 * rust-exp.y (rustyyerror): Constify.
9704 * rust-lang.c (rust_op_name): Constify.
9705 * rust-lang.h (rustyyerror): Constify.
9706 * serial.h (serial_ops::name): Constify.
9707 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
9708 (sh_sh3e_register_name, sh_sh2e_register_name)
9709 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
9710 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
9711 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
9712 (sh_sh4al_dsp_register_name): Constify.
9713 * sh64-tdep.c (sh64_register_name): Constify.
9714 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
9715 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
9716 * stabsread.c (patch_block_stabs, read_type_number)
9717 (ref_map::stabs, ref_add, process_reference)
9718 (symbol_reference_defined, define_symbol, define_symbol)
9719 (error_type, read_type, read_member_functions, read_cpp_abbrev)
9720 (read_one_struct_field, read_struct_fields, read_baseclasses)
9721 (read_tilde_fields, read_struct_type, read_array_type)
9722 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
9723 (read_huge_number, read_range_type, read_args, common_block_start)
9724 (find_name_end): Constify.
9725 * stabsread.h (common_block_start, define_symbol)
9726 (process_one_symbol, symbol_reference_defined, ref_add):
9727 * symfile.c (get_section_index, add_symbol_file_command):
9728 * symfile.h (get_section_index): Constify.
9729 * target-descriptions.c (tdesc_type::name): Constify.
9730 (tdesc_free_type): Add cast.
9731 * target.c (find_default_run_target):
9732 (add_deprecated_target_alias, find_default_run_target)
9733 (target_announce_detach): Constify.
9734 (do_option): Constify.
9735 * target.h (add_deprecated_target_alias): Constify.
9736 * thread.c (print_thread_info_1): Constify.
9737 * top.c (deprecated_readline_begin_hook, command_line_input):
9739 (init_main): Add casts.
9740 * top.h (handle_line_of_input): Constify.
9741 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
9742 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
9743 (tfind_command): Rename to ...
9744 (tfind_command_1): ... this and constify.
9745 (tfind_command): New function.
9746 (tfind_end_command, tfind_start_command): Adjust.
9747 (encode_source_string): Constify.
9748 * tracepoint.h (encode_source_string): Constify.
9749 * tui/tui-data.c (tui_partial_win_by_name): Constify.
9750 * tui/tui-data.h (tui_partial_win_by_name): Constify.
9751 * tui/tui-source.c (tui_set_source_content_nil): Constify.
9752 * tui/tui-source.h (tui_set_source_content_nil): Constify.
9753 * tui/tui-win.c (parse_scrolling_args): Constify.
9754 * tui/tui-windata.c (tui_erase_data_content): Constify.
9755 * tui/tui-windata.h (tui_erase_data_content): Constify.
9756 * tui/tui-winsource.c (tui_erase_source_content): Constify.
9757 * tui/tui.c (tui_enable): Add cast.
9758 * utils.c (defaulted_query): Constify.
9759 (init_page_info): Add cast.
9760 (puts_debug, subset_compare): Constify.
9761 * utils.h (subset_compare): Constify.
9762 * varobj.c (varobj_format_string): Constify.
9763 * varobj.h (varobj_format_string): Constify.
9764 * vax-tdep.c (vax_register_name): Constify.
9765 * windows-nat.c (windows_detach): Constify.
9766 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
9767 * xml-support.c (gdb_xml_end_element): Constify.
9768 * xml-tdesc.c (tdesc_start_reg): Constify.
9769 * xstormy16-tdep.c (xstormy16_register_name): Constify.
9770 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
9771 * xtensa-tdep.h (xtensa_register_t::name): Constify.
9773 2017-04-05 Pedro Alves <palves@redhat.com>
9775 * proc-api.c (struct trans): Constify.
9776 (procfs_note): Constify.
9777 * proc-events.c (struct trans, syscall_table):
9778 * proc-flags.c (struct trans): Constify.
9779 * proc-utils.h (procfs_note): Constify.
9780 * proc-why.c (struct trans): Constify.
9781 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
9782 (procfs_detach): Constify.
9783 * sol-thread.c (struct string_map): Constify.
9784 (td_err_string, td_state_string): Constify.
9786 2017-04-05 Pedro Alves <palves@redhat.com>
9788 * proc-api.c (procfs_filename): Don't initialize
9790 (prepare_to_trace): Assume procfs_filename is non-NULL.
9791 (_initialize_proc_api): Give procfs_filename a default value here.
9793 2017-04-05 Pedro Alves <palves@redhat.com>
9795 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
9796 'cond_string' parameter.
9797 (extract_exception_regexp): Constify 'string' parameter.
9798 (catch_exception_command_1): Constify.
9799 * breakpoint.c (init_catchpoint)
9800 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
9802 (ep_parse_optional_if_clause, catch_fork_command_1)
9803 (catch_exec_command_1): Constify.
9804 * breakpoint.h (init_catchpoint): Constify 'cond_string'
9806 (ep_parse_optional_if_clause): Constify.
9807 * cli/cli-utils.c (remove_trailing_whitespace)
9808 (check_for_argument): Constify.
9809 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
9811 (check_for_argument): Likewise.
9813 2017-04-05 Pedro Alves <palves@redhat.com>
9815 * event-top.c (command_line_handler): Add cast to execute_command
9817 * record-btrace.c (cmd_record_btrace_bts_start)
9818 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
9819 (cmd_record_btrace_start): Add cast to execute_command call.
9820 * record-full.c (record_full_goto_insn):
9821 * record.c (record_start, record_stop): Add cast to
9822 execute_command_to_string calls.
9823 (cmd_record_start): Add cast to execute_command calls.
9825 2017-04-05 Pedro Alves <palves@redhat.com>
9827 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
9828 static inline function.
9829 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
9830 array and use gdb_PyArg_ParseTupleAndKeywords.
9831 * python/py-cmd.c (cmdpy_init): Likewise.
9832 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
9833 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
9834 (infpy_search_memory): Likewise.
9835 * python/py-objfile.c (objfpy_add_separate_debug_file)
9836 (gdbpy_lookup_objfile): Likewise.
9837 * python/py-symbol.c (gdbpy_lookup_symbol)
9838 (gdbpy_lookup_global_symbol): Likewise.
9839 * python/py-type.c (gdbpy_lookup_type): Likewise.
9840 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
9841 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
9844 2017-04-05 Pedro Alves <palves@redhat.com>
9846 * python/python-internal.h (gdb_PyGetSetDef): New type.
9847 * python/py-block.c (block_object_getset)
9848 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
9849 * python/py-event.c (event_object_getset)
9850 (finish_breakpoint_object_getset): Likewise.
9851 * python/py-inferior.c (inferior_object_getset): Likewise.
9852 * python/py-infthread.c (thread_object_getset): Likewise.
9853 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
9854 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
9855 * python/py-objfile.c (objfile_getset): Likewise.
9856 * python/py-progspace.c (pspace_getset): Likewise.
9857 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
9859 * python/py-record.c (recpy_record_getset): Likewise.
9860 * python/py-symbol.c (symbol_object_getset): Likewise.
9861 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
9863 * python/py-type.c (type_object_getset, field_object_getset):
9865 * python/py-value.c (value_object_getset): Likewise.
9867 2017-04-05 Pedro Alves <palves@redhat.com>
9869 * python/python-internal.h (gdb_PyObject_CallMethod)
9870 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
9872 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
9873 (PySys_GetObject, PySys_SetPath): New macros.
9875 2017-04-05 Pedro Alves <palves@redhat.com>
9877 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
9878 info_osdata_command.
9879 * osdata.c (info_osdata_command): Rename to ...
9880 (info_osdata): ... this. Constify 'type' parameter, and remove
9881 the 'from_tty' parameter. Accept NULL TYPE.
9882 (info_osdata_command): New function.
9883 * osdata.h (info_osdata_command): Remove declaration.
9884 (info_osdata): New declaration.
9886 2017-04-05 Pedro Alves <palves@redhat.com>
9888 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
9889 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
9890 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
9892 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
9893 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
9894 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
9896 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
9897 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
9898 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
9899 (mi_cmd_file_list_exec_source_files)
9900 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
9901 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
9902 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
9904 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
9905 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
9906 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
9907 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
9908 (mi_cmd_stack_info_frame): Constify 'command' parameter.
9909 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
9910 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
9911 'command' parameter.
9912 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
9913 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
9914 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
9915 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
9916 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
9917 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
9918 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
9919 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
9920 (mi_cmd_var_set_update_range): Constify 'command' parameter.
9921 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
9922 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
9924 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
9925 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
9926 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
9927 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
9928 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
9929 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
9930 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
9931 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
9932 (mi_cmd_data_list_changed_registers)
9933 (mi_cmd_data_write_register_values)
9934 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
9935 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
9936 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
9937 (mi_cmd_list_features, mi_cmd_list_target_features)
9938 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
9939 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
9940 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
9941 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
9942 (mi_cmd_trace_frame_collected): Constify 'command'
9944 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
9945 'command' parameter.
9947 2017-04-05 Pedro Alves <palves@redhat.com>
9949 * ada-lang.c (ada_completer_word_break_characters): Now a const
9951 (ada_get_gdb_completer_word_break_characters): Constify.
9952 * completer.c (gdb_completer_command_word_break_characters)
9953 (gdb_completer_file_name_break_characters)
9954 (gdb_completer_quote_characters): Now const arrays.
9955 (get_gdb_completer_quote_characters): Constify.
9956 (set_rl_completer_word_break_characters): New function.
9957 (set_gdb_completion_word_break_characters)
9958 (complete_line_internal): Use it.
9959 * completer.h (get_gdb_completer_quote_characters): Constify.
9960 (set_rl_completer_word_break_characters): Declare.
9961 * f-lang.c (f_word_break_characters): Constify.
9962 * language.c (default_word_break_characters): Constify.
9963 * language.h (language_defn::la_word_break_characters): Constify.
9964 (default_word_break_characters): Constify.
9965 * top.c (init_main): Use set_rl_completer_word_break_characters.
9967 2017-04-05 Pedro Alves <palves@redhat.com>
9969 * aix-thread.c (aix_thread_pid_to_str)
9970 (aix_thread_extra_thread_info): Constify.
9971 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
9972 * bsd-uthread.c (bsd_uthread_extra_thread_info)
9973 (bsd_uthread_pid_to_str): Constify.
9974 * corelow.c (core_pid_to_str): Constify.
9975 * darwin-nat.c (darwin_pid_to_str): Constify.
9976 * fbsd-nat.c (fbsd_pid_to_str): Constify.
9977 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
9979 * gnu-nat.c (gnu_pid_to_str): Constify.
9980 * go32-nat.c (go32_pid_to_str): Constify.
9981 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
9982 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
9983 * inferior.c (inferior_pid_to_str): Constify.
9984 * linux-nat.c (linux_nat_pid_to_str): Constify.
9985 * linux-tdep.c (linux_core_pid_to_str): Constify.
9986 * linux-thread-db.c (thread_db_pid_to_str)
9987 (thread_db_extra_thread_info): Constify.
9988 * nto-tdep.c (nto_extra_thread_info): Constify.
9989 * nto-tdep.h (nto_extra_thread_info): Constify.
9990 * obsd-nat.c (obsd_pid_to_str): Constify.
9991 * procfs.c (procfs_pid_to_str): Constify.
9992 * ravenscar-thread.c (ravenscar_extra_thread_info)
9993 (ravenscar_pid_to_str): Constify.
9994 * remote-sim.c (gdbsim_pid_to_str): Constify.
9995 * remote.c (remote_threads_extra_info, remote_pid_to_str):
9997 * sol-thread.c (solaris_pid_to_str): Constify.
9998 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
9999 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
10000 * target.c (default_pid_to_str, target_pid_to_str)
10001 (normal_pid_to_str, default_pid_to_str): Constify.
10002 * target.h (target_ops::to_pid_to_str)
10003 (target_ops::to_extra_thread_info): Constify.
10004 (target_pid_to_str, normal_pid_to_str): Constify.
10005 * windows-nat.c (windows_pid_to_str): Constify.
10006 * gdbarch.sh (core_pid_to_str): Constify.
10007 * target-delegates.c: Regenerate.
10008 * gdbarch.h, gdbarch.c: Regenerate.
10010 2017-04-05 Pedro Alves <palves@redhat.com>
10012 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
10013 the memory of the temporary warning_pre_print override.
10014 * utils.c (warning_pre_print): Constify.
10015 * utils.h (warning_pre_print): Constify.
10017 2017-04-05 Pedro Alves <palves@redhat.com>
10019 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
10020 (shell_command): New function.
10021 (make_command): Use std::string.
10022 (init_cli_cmds): Register shell_command instead of shell_escape.
10024 2017-04-05 Pedro Alves <palves@redhat.com>
10026 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
10027 * tracepoint.c (default_collect): Don't initialize.
10029 2017-04-05 Pedro Alves <palves@redhat.com>
10031 * macroexp.c (macro_buffer::shared): Now a bool.
10032 (init_buffer): Update.
10033 (init_shared_buffer): Constify 'addr' parameter.
10034 (substitute_args, expand, macro_expand, macro_expand_next): Remove
10037 2017-04-05 Pedro Alves <palves@redhat.com>
10039 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
10040 * disasm.c (set_disassembler_options): Constify local.
10041 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
10043 2017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
10046 * tracefile.c (tsave_command): Fix argument parsing for '-r'
10049 2017-04-05 Yao Qi <yao.qi@linaro.org>
10051 * frame.c (frame_unwind_register_unsigned): Call
10052 frame_unwind_register_value.
10054 2017-04-05 Yao Qi <yao.qi@linaro.org>
10056 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
10057 Use gdb_test_multiple, and don't match anchor.
10059 2017-04-05 Pedro Alves <palves@redhat.com>
10061 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
10062 (Write After Approval): Remove Simon Marchi.
10064 2017-04-05 Pedro Alves <palves@redhat.com>
10066 * common/gdb_optional.h (optional::optional): Make constexpr and
10067 initialize m_dummy.
10069 2017-04-04 John Baldwin <jhb@FreeBSD.org>
10071 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
10072 (amd64fbsd_jmp_buf_reg_offset): Remove.
10073 (amd64fbsd_supply_uthread): Remove function.
10074 (amd64fbsd_collect_uthread): Remove function.
10075 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
10076 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
10077 (x86_64-*-freebsd*): Remove bsd-uthread.o.
10078 (fbsd-nat.c): Update comment.
10079 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
10080 (i386fbsd_jmp_buf_reg_offset): Remove.
10081 (i386fbsd_supply_uthread): Remove function.
10082 (i386fbsd_collect_uthread): Remove function.
10083 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
10085 2017-04-04 John Baldwin <jhb@FreeBSD.org>
10087 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
10088 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
10089 * NEWS: Mention that support for FreeBSD/alpha was removed.
10090 * alpha-fbsd-tdep.c: Delete file.
10091 * config/alpha/fbsd.mh: Delete file.
10092 * configure.host: Delete alpha*-*-freebsd* and
10093 alpha*-*-kfreebsd*-gnu.
10094 * configure.tgt: Delete alpha*-*-freebsd* and
10095 alpha*-*-kfreebsd*-gnu.
10097 2017-04-04 John Baldwin <jhb@FreeBSD.org>
10099 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
10100 amd64bsd_store_inferior_registers): Use ptid from regcache.
10102 2017-04-04 Pedro Alves <palves@redhat.com>
10104 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
10105 data fields, make them private and add "m_" prefixes.
10106 (lnp_state_machine::lnp_state_machine): New ctor.
10107 (record_line, check_line_address, handle_set_discriminator)
10108 (handle_set_address, handle_advance_pc, handle_special_opcode)
10109 (handle_advance_line, handle_set_file, handle_negate_stmt)
10110 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
10111 (end_sequence, advance_line): New methods.
10112 (m_gdbarch, m_record_lines_p): New fields.
10113 (lnp_reader_state): Delete.
10114 (dwarf_record_line): Rename to ...
10115 (lnp_state_machine::record_line): ... adjust.
10116 (init_lnp_state_machine): Delete.
10117 (lnp_state_machine::lnp_state_machine): New.
10118 (check_line_address): Rename to ...
10119 (lnp_state_machine::check_line_address): This.
10120 (dwarf_decode_lines_1): Remove reference to "reader_state".
10121 Adjust lnp_state_machine having a non-default ctor. Use bool.
10122 State machine internal state manipulation moved to
10123 lnp_state_machine methods.
10125 2017-04-04 Pedro Alves <palves@redhat.com>
10127 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10128 unittests/offset-type-selftests.c.
10129 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
10130 * common/offset-type.h: New file.
10131 * common/preprocessor.h: New file.
10132 * common/traits.h: New file.
10133 * common/valid-expr.h: New file.
10134 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
10135 sect_offset and cu_offset strong typedefs throughout.
10136 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
10137 typedefs throughout.
10138 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
10139 sect_offset and cu_offset strong typedefs throughout.
10140 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
10141 typedefs throughout.
10142 * gdbtypes.h: Include "common/offset-type.h".
10143 (cu_offset): Now an offset type (strong typedef) instead of a
10145 (sect_offset): Likewise.
10146 (union call_site_parameter_u): Rename "param_offset" field to
10148 * unittests/offset-type-selftests.c: New file.
10150 2017-04-04 Pedro Alves <palves@redhat.com>
10152 * common/underlying.h: New file.
10153 * dwarf2read.c: Include "common/gdb_optional.h" and
10154 "common/underlying.h".
10155 (dir_index, file_name_index): New types.
10156 (file_entry): Use them.
10157 (file_entry::include): Use to_underlying.
10158 (line_header::add_file_name): Use dir_index.
10159 (read_formatted_entries): Use gdb::optional. Read form before
10160 writting to file_entry.
10161 (dwarf_decode_line_header): Use dir_index.
10162 (lnp_state_machine::current_file): Use to_underlying.
10163 (lnp_state_machine::file): Change type to file_name_index.
10164 (dwarf_record_line): Use to_underlying.
10165 (init_lnp_state_machine): Use file_name_index.
10166 (dwarf_decode_lines_1): Use dir_index and file_name_index.
10168 2017-04-04 Pedro Alves <palves@redhat.com>
10170 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
10171 operator bool, has_value and get methods.
10173 2017-04-04 Pedro Alves <palves@redhat.com>
10175 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
10177 (line_header): Initialize all data fields. Change type of
10178 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
10179 Change type of include_dirs to std::vector<const char *>. Remove
10180 num_include_dirs, include_dirs_size. Change type of file_names to
10181 std::vector<file_entry>. Remove num_file_names, file_names_size.
10182 (line_header::line_header): New.
10183 (line_header::add_include_dir, line_header::add_file_name): New
10185 (line_header::include_dir_at): Remove NULL check.
10186 (line_header::file_name_at): Add const overload.
10187 (line_header_up): New unique_ptr typedef.
10188 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
10189 std::vector. Remove free_line_header call.
10190 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
10191 free_line_header call.
10192 (free_cu_line_header): Delete.
10193 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
10194 (setup_type_unit_groups): Use line_header_up instead of cleanups.
10195 Adjust to use std::vector.
10196 (free_line_header): Delete.
10197 (free_line_header_voidp): Use delete.
10198 (add_include_dir): Replace with ...
10199 (line_header::add_include_dir): ... this method. Use std::vector.
10200 (add_file_name): Replace with ...
10201 (line_header::add_file_name): ... this method. Use std::vector.
10202 (add_include_dir_stub): Delete.
10203 (read_formatted_entries): Remove memset.
10204 (dwarf_decode_line_header): Return a line_header_up instead of a
10205 raw pointer. Remove cleanup handling. Pass lambdas to
10206 read_formatted_entries. Adjust to use line_header methods.
10207 (dwarf_decode_lines_1): Adjust to use line_header methods.
10208 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
10211 2017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
10213 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
10214 instead of struct ptid.
10216 2017-05-04 Alan Hayward <alan.hayward@arm.com>
10218 * frame.c (get_frame_register_bytes): Unwind using value.
10219 (put_frame_register_bytes): Likewise.
10221 2017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
10223 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
10226 2017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
10228 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
10230 2017-03-29 Yao Qi <yao.qi@linaro.org>
10232 * gdbthread.h (struct thread_info): Declare constructor and
10233 destructor. Add some in-class member initializers.
10234 * thread.c (free_thread): Remove.
10235 (init_thread_list): Call delete instead of free_thread.
10236 (new_thread): Call thread_info constructor.
10237 (thread_info::thread_info): New function.
10238 (thread_info::~thread_info): New function.
10239 (delete_thread_1): Call delete instead of free_thread.
10240 (make_cleanup_restore_current_thread): Move tp and frame to
10243 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
10245 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
10246 (arc_skip_prologue): Likewise.
10247 (arc_make_frame_cache): Likewise.
10248 (arc_pv_get_operand): New function.
10249 (arc_is_in_prologue): Likewise.
10250 (arc_analyze_prologue): Likewise.
10251 (arc_print_frame_cache): Likewise.
10252 (MAX_PROLOGUE_LENGTH): New constant.
10254 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
10256 * configure.tgt: Add arc-insn.o.
10257 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
10258 (dump_arc_instruction_command): New function.
10259 (arc_fprintf_disasm): Likewise.
10260 (arc_disassemble_info): Likewise.
10261 (arc_insn_get_operand_value): Likewise.
10262 (arc_insn_get_operand_value_signed): Likewise.
10263 (arc_insn_get_memory_base_reg): Likewise.
10264 (arc_insn_get_memory_offset): Likewise.
10265 (arc_insn_get_branch_target): Likewise.
10266 (arc_insn_dump): Likewise.
10267 (arc_insn_get_linear_next_pc): Likewise.
10268 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
10269 (arc_disassemble_info): Likewise.
10270 (arc_insn_get_branch_target): Likewise.
10271 (arc_insn_get_linear_next_pc): Likewise.
10272 * NEWS: Mention new "maint print arc arc-instruction".
10274 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
10276 * arc-tdep (maintenance_print_arc_list): New variable.
10277 (maintenance_print_arc_command): New function.
10279 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
10281 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
10282 Add "limm" and "reserved".
10283 (arc_cannot_fetch_register, arc_cannot_store_register): Add
10284 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
10285 * arc-tdep.h (arc_regnum): Likewise.
10287 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
10289 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
10290 for THREADPTR register.
10291 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
10293 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
10294 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
10295 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
10297 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
10299 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
10300 registers above gdbarch_num_regs (gdbarch) as privileged in
10303 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
10305 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
10306 for a single specified register or for all registers in
10307 a0_base..a0_base + C0_NREGS range.
10308 (supply_gregset_reg): Call regcache_raw_supply for a single
10309 specified register or for all registers in a0_base..a0_base +
10312 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
10314 * arch/xtensa.h (C0_NREGS): Add definition.
10315 * xtensa-tdep.c (C0_NREGS): Remove definition.
10317 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
10319 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
10320 Drop xtensa_default_isa initialization.
10321 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
10323 2017-03-27 Pedro Alves <palves@redhat.com>
10325 * dwarf2read.c (file_entry) <dir_index>: Add comment.
10326 (file_entry::include_dir): New method.
10327 (line_header::include_dir_at, line_header::file_name_at): New
10329 (setup_type_unit_groups, setup_type_unit_groups)
10330 (psymtab_include_file_name): Simplify using the new methods.
10331 (lnp_state_machine) <the_line_header>: New field.
10332 <file>: Add comment.
10333 (lnp_state_machine::current_file): New method.
10334 (dwarf_record_line): Simplify using the new methods.
10335 (init_lnp_state_machine): Initialize the "the_line_header" field.
10336 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
10337 Simplify using the new methods.
10339 2017-03-27 Pedro Alves <palves@redhat.com>
10341 * cp-name-parser.y (make_empty): Delete.
10342 (demangler_special, nested_name, ptr_operator, array_indicator)
10343 (direct_declarator, declarator_1): Use fill_comp instead of
10346 2017-03-27 Pedro Alves <palves@redhat.com>
10348 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
10349 to ATTRIBUTE_PRINTF.
10350 * solib-target.c (library_list_start_list): Print "string" not
10352 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
10353 gdb_xml_error call.
10355 2017-03-27 Pedro Alves <palves@redhat.com>
10357 * dwarf2read.c (struct file_and_directory): New.
10358 (dwarf2_get_dwz_file): Adjust to use std::string.
10359 (dw2_get_file_names_reader): Adjust to use file_and_directory.
10360 (find_file_and_directory): Adjust to return a file_and_directory
10362 (read_file_scope): Adjust to use file_and_directory. Remove
10363 make_cleanup/do_cleanups calls.
10364 (open_and_init_dwp_file): Adjust to use std::string. Remove
10365 make_cleanup/do_cleanups calls.
10366 * python/python.c (do_start_initialization): Adjust to ldirname
10367 returning a std::string.
10368 * utils.c (ldirname): Now returns a std::string.
10369 * utils.h (ldirname): Change return type to std::string.
10370 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
10371 returning a std::string.
10372 * xml-tdesc.c (file_read_description_xml): Likewise.
10374 2017-03-24 Alan Hayward <alan.hayward@arm.com>
10376 * regcache.c (regcache_debug_print_register): New function.
10377 * regcache.h (regcache_debug_print_register): New declaration.
10378 * target.c (debug_print_register): Remove.
10379 (target_fetch_registers): Call regcache_debug_print_register.
10380 (target_store_registers): Likewise.
10382 2017-03-24 Pádraig Brady <pbrady@fb.com>
10384 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
10385 reference beyond the 'lh->include_dirs' array before accessing to
10387 (psymtab_include_file_name): Likewise.
10388 (dwarf_decode_lines_1): Likewise.
10389 (dwarf_decode_lines): Likewise.
10390 (file_file_name): Likewise.
10392 2017-03-23 Simon Marchi <simon.marchi@ericsson.com>
10394 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
10396 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
10397 ps_lsetfpregs): Likewise.
10398 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
10399 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
10400 ps_lsetfpregs): Likewise.
10401 * target.c (target_fetch_registers, target_store_registers):
10404 2017-03-23 Alan Hayward <alan.hayward@arm.com>
10406 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
10408 2017-03-23 Yao Qi <yao.qi@linaro.org>
10410 * aarch64-tdep.c (aarch64_process_record_test): Declare.
10411 (_initialize_aarch64_tdep): Register it.
10412 (aarch64_record_load_store): Handle PRFM instruction.
10413 (aarch64_process_record_test): New function.
10415 2017-03-23 Yao Qi <yao.qi@linaro.org>
10417 * aarch64-tdep.c (aarch64_record_load_store): Fix code
10420 2017-03-23 Yao Qi <yao.qi@linaro.org>
10422 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
10424 2017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10426 python/python.c (do_start_initialization): Fix memory leak.
10428 2017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
10430 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
10431 using get_ptrace_pid.
10432 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
10434 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
10435 inferior_ptid instead of pid.
10437 2017-03-22 Yao Qi <yao.qi@linaro.org>
10439 * aarch64-tdep.c: Wrap locally used classes in anonymous
10441 * arm-tdep.c: Likewise.
10442 * linespec.c: Likewise.
10443 * ui-out.c: Likewise.
10445 2017-03-22 Jonah Graham <jonah@kichwacoders.com>
10448 * python/lib/gdb/printer/bound_registers.py: Import sys.
10450 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
10452 * windows-nat.c (do_windows_fetch_inferior_registers): Add
10453 windows_thread_info parameter and use it instead of
10455 (windows_fetch_inferior_registers): Don't set current_thread,
10456 pass the thread to do_windows_fetch_inferior_registers. Use
10457 ptid from regcache instead of inferior_ptid.
10458 (do_windows_store_inferior_registers): Add windows_thread_info
10459 parameter and use it instead of current_thread.
10460 (windows_store_inferior_registers): Don't set current_thread,
10461 pass the thread to do_windows_store_inferior_registers. Use
10462 ptid from regcache instead of inferior_ptid.
10464 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
10466 * ser-mingw.c (ser_windows_raw): Remove reference to
10467 struct serial::current_timeout.
10469 2017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
10472 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
10473 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
10474 (sparc64_fsr_type): Fix %fsr decoding.
10476 2017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
10478 * python/py-record-btrace.c (btpy_insn_data): Change return type
10481 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
10483 * spu-linux-nat.c (spu_fetch_inferior_registers,
10484 spu_store_inferior_registers): Use ptid from regcache, set and
10485 restore inferior_ptid.
10486 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
10489 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
10491 * i386-linux-nat.c (fetch_register, store_register,
10492 i386_linux_fetch_inferior_registers,
10493 i386_linux_store_inferior_registers): Use ptid from regcache.
10494 * ia64-linux-nat.c (ia64_linux_fetch_register,
10495 ia64_linux_store_register): Likewise.
10496 * inf-ptrace.c (inf_ptrace_fetch_register,
10497 inf_ptrace_store_register): Likewise.
10498 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
10499 m32r_linux_store_inferior_registers): Likewise.
10500 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
10501 m68kbsd_store_inferior_registers): Likewise.
10502 * m68k-linux-nat.c (fetch_register, store_register,
10503 m68k_linux_fetch_inferior_registers,
10504 m68k_linux_store_inferior_registers): Likewise.
10505 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
10506 m88kbsd_store_inferior_registers): Likewise.
10507 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
10508 mips_fbsd_store_inferior_registers): Likewise.
10509 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
10510 mips64_linux_regsets_store_registers): Likewise.
10511 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
10512 mipsnbsd_store_inferior_registers): Likewise.
10513 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
10514 mips64obsd_store_inferior_registers): Likewise.
10515 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
10517 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
10518 ppcfbsd_store_inferior_registers): Likewise.
10519 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
10520 ppc_linux_store_inferior_registers): Likewise.
10521 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
10522 ppcnbsd_store_inferior_registers): Likewise.
10523 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
10524 ppcobsd_store_registers): Likewise.
10525 * procfs.c (procfs_fetch_registers, procfs_store_registers):
10527 * ravenscar-thread.c (ravenscar_fetch_registers,
10528 ravenscar_store_registers, ravenscar_prepare_to_store):
10530 * record-btrace.c (record_btrace_fetch_registers,
10531 record_btrace_store_registers, record_btrace_prepare_to_store):
10533 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
10534 Lookup inferior using ptid from regcache, instead of
10536 * remote.c (remote_fetch_registers, remote_store_registers): Use
10537 ptid from regcache.
10538 * rs6000-nat.c (fetch_register, store_register): Likewise.
10539 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
10540 s390_linux_store_inferior_registers): Likewise.
10541 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
10542 shnbsd_store_inferior_registers): Likewise.
10543 * sol-thread.c (sol_thread_fetch_registers,
10544 sol_thread_store_registers): Likewise.
10545 * sparc-nat.c (sparc_fetch_inferior_registers,
10546 sparc_store_inferior_registers): Likewise.
10547 * tilegx-linux-nat.c (fetch_inferior_registers,
10548 store_inferior_registers): Likewise.
10549 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
10550 vaxbsd_store_inferior_registers): Likewise.
10551 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
10552 store_xtregs): Likewise.
10554 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
10557 * NEWS: Mention support for rvalue references in GDB and python.
10558 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
10559 supports both lvalue and rvalue references.
10561 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
10564 * gdbtypes.c (rank_one_type): Implement overloading
10565 resolution rules regarding rvalue references.
10567 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
10570 * aarch64-tdep.c (aarch64_type_align)
10571 (aarch64_extract_return_value, aarch64_store_return_value): Change
10572 lvalue reference type checks to general reference type checks.
10573 * amd64-tdep.c (amd64_classify): Likewise.
10574 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
10576 * arm-tdep.c (arm_type_align, arm_extract_return_value)
10577 (arm_store_return_value): Likewise.
10578 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
10579 * c-typeprint.c (c_print_type): Likewise.
10580 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
10581 (cplus_number_of_children, cplus_describe_child): Likewise.
10582 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
10583 * completer.c (expression_completer): Likewise.
10584 * cp-support.c (make_symbol_overload_list_adl_namespace):
10586 * darwin-nat-info.c (info_mach_region_command): Likewise.
10587 * dwarf2loc.c (entry_data_value_coerce_ref)
10588 (value_of_dwarf_reg_entry): Likewise.
10589 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
10590 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
10592 * findvar.c (extract_typed_address, store_typed_address):
10594 * gdbtypes.c (rank_one_type): Likewise.
10595 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
10596 * infcall.c (value_arg_coerce): Likewise.
10597 * language.c (pointer_type): Likewise.
10598 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
10600 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
10601 * mn10300-tdep.c (mn10300_type_align): Likewise.
10602 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
10603 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
10604 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
10606 * printcmd.c (print_formatted, x_command): Likewise.
10607 * python/py-type.c (typy_get_composite, typy_template_argument):
10609 * python/py-value.c (valpy_referenced_value)
10610 (valpy_get_dynamic_type, value_has_field): Likewise.
10611 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
10612 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
10613 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
10614 * spu-tdep.c (spu_scalar_value_p): Likewise.
10615 * symtab.c (lookup_symbol_aux): Likewise.
10616 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
10617 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
10619 * valops.c (value_cast_pointers, value_cast)
10620 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
10621 (value_struct_elt, value_struct_elt_bitpos)
10622 (value_find_oload_method_list, find_overload_match)
10623 (value_rtti_indirect_type): Likewise.
10624 * valprint.c (val_print_scalar_type_p, generic_val_print):
10626 * value.c (value_actual_type, value_as_address, unpack_long)
10627 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
10628 (coerce_ref): Likewise.
10629 * varobj.c (varobj_get_value_type): Likewise.
10631 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
10634 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
10635 table of constants.
10636 * python/lib/gdb/command/explore.py: Support exploring values
10637 of rvalue reference types.
10638 * python/lib/gdb/types.py: Implement get_basic_type() for
10639 rvalue reference types.
10640 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
10642 * python/py-value.c (valpy_getitem): Add an rvalue reference
10644 (valpy_reference_value): Add new parameter "refcode".
10645 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
10646 New wrappers for valpy_reference_value().
10647 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
10648 (gdbpy_invoke_xmethod): Likewise.
10650 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
10653 * dwarf2read.c (process_die, read_type_die_1): Handle the
10654 DW_TAG_rvalue_reference_type DIE.
10655 (read_tag_reference_type): Add new parameter "refcode".
10657 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
10660 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
10661 (c_type_print_modifier, c_type_print_varspec_suffix)
10662 (c_type_print_base): Support printing rvalue reference types.
10663 * c-valprint.c (c_val_print, c_value_print): Support printing
10664 rvalue reference values.
10666 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
10669 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
10671 * cp-support.c (replace_typedefs): Handle
10672 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
10673 * python/py-type.c (typy_lookup_type): Likewise.
10675 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
10678 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
10679 * parse.c (insert_type): Change assert statement.
10680 (follow_types): Handle rvalue reference types.
10681 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
10684 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
10687 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
10688 value_ref() interface.
10689 * c-valprint.c (c_value_print): Likewise.
10690 * infcall.c (value_arg_coerce): Likewise.
10691 * python/py-value.c (valpy_reference_value): Likewise.
10692 * valops.c (value_cast, value_reinterpret_cast)
10693 (value_dynamic_cast, typecmp): Likewise.
10694 (value_ref): Parameterize by kind of return value reference type.
10695 * value.h (value_ref): Add new parameter "refcode".
10697 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
10700 * dwarf2read.c (read_tag_reference_type): Use
10701 lookup_lvalue_reference_type() instead of lookup_reference_type().
10702 * eval.c (evaluate_subexp_standard): Likewise.
10703 * f-exp.y: Likewise.
10704 * gdbtypes.c (make_reference_type, lookup_reference_type):
10705 Generalize with rvalue reference types.
10706 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
10707 convenience wrappers for lookup_reference_type().
10708 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
10709 reference kind parameter.
10710 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
10711 wrappers for lookup_reference_type().
10712 * guile/scm-type.c (gdbscm_type_reference): Use
10713 lookup_lvalue_reference_type() instead of lookup_reference_type().
10714 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
10715 * parse.c (follow_types): Likewise.
10716 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
10717 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
10719 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
10720 (gdbpy_invoke_xmethod): Likewise.
10721 * stabsread.c: Provide extra argument to make_reference_type()
10723 * valops.c (value_ref, value_rtti_indirect_type): Use
10724 lookup_lvalue_reference_type() instead of lookup_reference_type().
10726 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
10729 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
10730 (TYPE_IS_REFERENCE): New macro.
10731 (struct type): Add rvalue_reference_type field.
10732 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
10734 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
10736 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
10737 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
10738 New function definition.
10739 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
10740 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
10741 New function declaration.
10742 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
10743 * mi/mi-interp.h: New file.
10744 * solib.c (info_sharedlibrary_command): Replace for loop with
10746 * solib.h (update_solib_list): New function declaration.
10747 (so_list_head): Move macro.
10748 * solist.h (ALL_SO_LIBS): New macro.
10750 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
10752 * infcmd.c (post_create_inferior): Remove unused argument in
10754 * remote.c (remote_start_remote): Likewise.
10755 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
10756 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
10757 (enable_break): Likewise.
10758 * solib.c (update_solib_list): Remove unused target argument
10759 and its documentation.
10760 (solib_add): Remove unused target argument. Remove unused
10761 argument in call to update_solib_list.
10762 (info_sharedlibrary_command): Remove unused argument in call
10763 to update_solib_list.
10764 (sharedlibrary_command): Remove unused argument in call to
10766 (handle_solib_event): Likewise.
10767 (reload_shared_libraries): Likewise.
10768 * solib.h (solib_add): Remove unused target argument.
10770 2017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
10772 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
10773 (s390_displaced_step_fixup): Cover relative branches with the
10774 default fixup handling. This fixes lack of support for some
10775 relative branch instructions.
10777 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
10779 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
10780 ptid from regcache.
10782 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
10784 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
10785 i386_darwin_store_inferior_registers): Use ptid from regcache.
10787 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
10789 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
10790 i386bsd_store_inferior_registers): Use ptid from regcache.
10792 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
10794 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
10795 hppaobsd_store_registers): Use ptid from regcache.
10797 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
10799 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
10800 hppanbsd_store_registers): Use ptid from regcache.
10802 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
10804 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
10805 from regcache. Use get_ptrace_pid.
10807 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
10809 * corelow.c (get_core_register_section): Use ptid from regcache,
10812 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
10814 * bsd-uthread.c (bsd_uthread_fetch_registers,
10815 bsd_uthread_store_registers): Use ptid from regcache, set and
10816 restore inferior_ptid.
10818 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
10820 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
10821 fetch_fp_regs, store_register, store_regs, store_fp_register,
10822 store_fp_regs): Use ptid from regcache.
10824 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
10826 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
10827 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
10828 store_vfp_regs): Use ptid from regcache.
10830 2017-03-17 Pedro Alves <palves@redhat.com>
10833 * ser-base.c (ser_base_wait_for): Add comment.
10834 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
10836 * ser-unix.c (hardwire_raw): Remove reference to
10837 scb->current_timeout.
10838 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
10839 (hardwire_ops): Install ser_base_readchar instead of
10841 * serial.h (struct serial) <current_timeout, timeout_remaining>:
10844 2017-03-17 Jonah Graham <jonah@kichwacoders.com>
10847 * python/lib/gdb/printer/bound_registers.py: Add support for
10850 2017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
10852 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
10853 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
10854 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
10855 byte_offset to subobj_byte_offset. Fix the handling of
10856 DWARF_VALUE_STACK on big-endian targets when coming via an
10858 (dwarf2_evaluate_loc_desc): Adjust call to
10859 dwarf2_evaluate_loc_desc_full.
10860 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
10861 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
10863 2017-03-16 Yao Qi <yao.qi@linaro.org>
10865 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
10866 and REVSH instructions.
10868 2017-03-16 Yao Qi <yao.qi@linaro.org>
10870 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
10871 (arm_record_test): Declare.
10872 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
10873 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
10874 align with the manual.
10875 (thumb_record_misc): Adjust the code order to align with the
10877 (thumb2_record_decode_insn_handler): Fix instruction matching.
10878 (instruction_reader_thumb): New class.
10879 (arm_record_test): New function.
10881 2017-03-16 Yao Qi <yao.qi@linaro.org>
10883 * arm-tdep.c (abstract_memory_reader): New class.
10884 (instruction_reader): New class.
10885 (extract_arm_insn): Add argument 'reader'. Callers updated.
10886 (decode_insn): Likewise.
10888 2017-03-16 Doug Evans <dje@google.com>
10890 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
10891 member. Change type of TYPE member to SCM. All uses updated.
10892 (lsscm_make_lazy_string_smob): Add assert.
10893 (lsscm_make_lazy_string): Flag bad length values.
10894 (lsscm_elt_type): New function.
10895 (gdbscm_lazy_string_to_value): Rewrite to use
10896 lsscm_safe_lazy_string_to_value.
10897 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
10898 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
10899 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
10901 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
10902 * guile/scm-type.c (tyscm_scm_to_type): New function.
10904 2017-03-15 Doug Evans <dje@google.com>
10906 PR python/17728, python/18439, python/18779
10907 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
10908 member. Change type of TYPE member to PyObject *. All uses updated.
10909 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
10910 (gdbpy_create_lazy_string_object): Flag bad length values.
10911 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
10912 Handle typedefs in incoming type.
10913 (stpy_lazy_string_elt_type): New function.
10914 (gdbpy_extract_lazy_string): Call it.
10915 * python/py-value.c (valpy_lazy_string): Flag bad length values.
10916 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
10917 typedefs in incoming type.
10919 2017-03-16 Doug Evans <dje@google.com>
10921 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
10922 * guile/scm-type.c (tyscm_scm_to_type): New function.
10924 2017-03-16 Jiong Wang <jiong.wang@arm.com>
10926 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
10927 "ULONGEST" for "skip".
10929 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
10932 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
10933 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
10934 (inf_ptrace_peek_poke): ...here. New function. Now also loop
10935 over ptrace peek/poke until end of buffer or error.
10937 2017-03-14 Simon Marchi <simon.marchi@ericsson.com>
10939 * parse.c (length_of_subexp): Make static.
10940 * parser-defs.h (length_of_subexp): Remove.
10942 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
10944 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
10947 2017-03-14 Pedro Alves <palves@redhat.com>
10949 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
10950 (main): Use std::unique_ptr. Remove calls to
10951 cp_demangled_name_parse_free.
10953 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
10955 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
10956 alphabsd_store_inferior_registers): Use regcache->ptid instead
10959 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
10961 * aix-thread.c (aix_thread_fetch_registers,
10962 aix_thread_store_registers): Use regcache->ptid instead of
10965 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
10967 * aarch64-linux-nat.c (fetch_gregs_from_thread,
10968 store_gregs_to_thread, fetch_fpregs_from_thread,
10969 store_fpregs_to_thread): Use regcache->ptid instead of
10972 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
10974 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
10975 amd64_linux_fetch_inferior_registers): Use regcache->ptid
10976 instead of inferior_ptid.
10978 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
10980 * target.c (target_fetch_registers, target_store_registers): Add
10983 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
10985 * regcache.h (regcache_get_ptid): New function.
10986 * regcache.c (regcache_get_ptid): New function.
10988 2017-03-13 Mark Wielaard <mark@klomp.org>
10990 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
10992 2017-03-10 Keith Seitz <keiths@redhat.com>
10995 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
10997 2017-03-08 Pedro Alves <palves@redhat.com>
11000 * infrun.c (start_step_over, do_target_resume, resume)
11001 (restart_threads): Assert we're not resuming a thread that is
11002 meant to be stopped.
11003 (infrun_thread_stop_requested_callback): Delete.
11004 (infrun_thread_stop_requested): If the thread is internally
11005 stopped, queue a pending stop event and clear the thread's
11006 inline-frame state.
11007 (handle_stop_requested): New function.
11008 (handle_syscall_event, handle_inferior_event_1): Use
11009 handle_stop_requested.
11010 (handle_stop_requested): New function.
11011 (handle_signal_stop): Set the thread's stop_signal here instead of
11013 (finish_step_over): Clear step over info unconditionally.
11014 (handle_signal_stop): If the user had interrupted the event
11015 thread, consider the stop a random signal.
11016 (handle_signal_stop) <signal arrived while stepping over
11017 breakpoint>: Don't restart threads here.
11018 (stop_waiting): Don't clear step-over info here.
11020 2017-03-08 Pedro Alves <palves@redhat.com>
11023 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
11024 goes to argument 2, not 1.
11026 2017-03-08 Pedro Alves <palves@redhat.com>
11029 * top.c (gdb_readline_wrapper): Avoid passing NULL to
11030 display_gdb_prompt.
11031 (command_line_input): Add comment.
11033 2017-03-08 Pedro Alves <palves@redhat.com>
11036 * tui/tui-file.c (tui_file::write): New.
11037 * tui/tui-file.h (tui_file): Override "write".
11038 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
11039 factored out from ...
11040 (tui_puts): ... here.
11041 (tui_putc): Use them.
11042 (tui_write): New function.
11043 * tui/tui-io.h (tui_write): Declare.
11045 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
11047 * Makefile.in (SFILES): Replace "environ.c" with
11048 "common/environ.c".
11049 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
11050 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
11052 * common/environ.c: ... here.
11053 * environ.h: Moved to...
11054 * common/environ.h: ... here.
11056 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
11058 * gdbarch.sh (pstring_ptr): New static function.
11059 (gdbarch_disassembler_options): Use it.
11060 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
11061 not valid_disassembler_option->name.
11062 * gdbarch.c: Regenerate.
11064 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
11066 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
11068 2017-03-07 Pedro Alves <palves@redhat.com>
11070 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
11072 2017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
11074 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
11075 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
11076 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
11077 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
11079 2017-03-06 Simon Marchi <simon.marchi@ericsson.com>
11081 * xtensa-linux-nat.c (fetch_gregs): Remove const.
11083 2017-03-03 Simon Marchi <simon.marchi@ericsson.com>
11085 * remote.c (remote_add_target_side_commands): Use range-based
11088 2017-03-03 Yao Qi <yao.qi@linaro.org>
11091 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
11093 * valprint.c (common_val_print): Likewise.
11095 2017-02-28 Peter Bergner <bergner@vnet.ibm.com>
11097 * NEWS: Mention new set/show disassembler-options commands.
11098 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
11099 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
11100 (prospective_options): New static variable.
11101 (gdb_disassembler::gdb_disassembler): Initialize
11102 m_di.disassembler_options.
11103 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
11104 (get_disassembler_options): New function.
11105 (set_disassembler_options): Likewise.
11106 (set_disassembler_options_sfunc): Likewise.
11107 (show_disassembler_options_sfunc): Likewise.
11108 (disassembler_options_completer): Likewise.
11109 (_initialize_disasm): Likewise.
11110 * disasm.h (get_disassembler_options): New prototype.
11111 (set_disassembler_options): Likewise.
11112 * gdbarch.sh (gdbarch_disassembler_options): New variable.
11113 (gdbarch_verify_disassembler_options): Likewise.
11114 * gdbarch.c: Regenerate.
11115 * gdbarch.h: Likewise.
11116 * arm-tdep.c (num_disassembly_options): Delete.
11117 (set_disassembly_style): Likewise.
11118 (arm_disassembler_options): New static variable.
11119 (set_disassembly_style_sfunc): Convert short style name into long
11120 option name. Call set_disassembler_options.
11121 (show_disassembly_style_sfunc): New function.
11122 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
11123 set_gdbarch_verify_disassembler_options.
11124 (_initialize_arm_tdep): Delete regnames variable and update callers.
11125 (arm_disassembler_options): Initialize.
11126 (disasm_options): New variable.
11127 (num_disassembly_options): Rename from this...
11128 (num_disassembly_styles): ...to this. Compute by scanning through
11130 (valid_disassembly_styles): Initialize using disasm_options.
11131 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
11132 set_arm_regname_option.
11133 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
11134 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
11135 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
11136 set_gdbarch_verify_disassembler_options.
11137 * s390-tdep.c (s390_disassembler_options): New static variable.
11138 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
11139 set_gdbarch_verify_disassembler_options.
11141 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
11143 * remote.c (remote_add_target_side_condition): Remove "struct"
11144 keyword from range-based for loop.
11146 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
11148 * remote.c (remote_add_target_side_condition): Use range-based
11149 for loop. Update comment.
11151 2017-02-27 Yao Qi <yao.qi@linaro.org>
11153 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
11155 2017-02-26 Alan Hayward <alan.hayward@arm.com>
11157 * regcache.c (regcache_raw_update): New function.
11158 (regcache_raw_read): Move code to regcache_raw_update.
11159 * regcache.h (regcache_raw_update): New declaration.
11160 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
11162 2017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
11164 * dwarf2read.c (create_debug_type_hash_table): Initialize
11165 header.signature and header.type_offset_in_tu.
11167 2017-02-24 Pedro Alves <palves@redhat.com>
11169 * symtab.c (make_file_symbol_completion_list_1): Use
11170 add_symtab_completions.
11172 2017-02-24 Alan Hayward <alan.hayward@arm.com>
11174 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
11176 2017-02-24 Alan Hayward <alan.hayward@arm.com>
11178 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
11179 I386_MAX_REGISTER_SIZE.
11180 (i386_pseudo_register_write): Likewise.
11181 (i386_process_record): Likewise.
11182 * i387-tdep.c (i387_supply_xsave): Likewise.
11183 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
11184 (store_register): Likewise.
11186 2017-02-23 Pedro Alves <palves@redhat.com>
11188 * ada-lang.c: Include "common/function-view.h".
11189 (ada_iterate_over_symbols): Adjust to use function_view as
11191 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
11192 (ada_make_symbol_completion_list): Use a lambda.
11193 (ada_exc_search_name_matches): Delete.
11194 (name_matches_regex): New.
11195 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
11196 * compile/compile-c-support.c: Include "common/function-view.h".
11197 (print_one_macro): Change prototype to accept a ui_file pointer.
11198 (write_macro_definitions): Use a lambda.
11199 * dwarf2read.c: Include "common/function-view.h".
11200 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
11201 (dw2_expand_symtabs_matching): Adjust to use function_view as
11203 * language.h: Include "common/function-view.h".
11204 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
11205 function_view as callback type.
11206 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
11207 * linespec.c: Include "common/function-view.h".
11208 (collect_info::add_symbol): New method.
11209 (struct symbol_and_data_callback, iterate_inline_only, struct
11210 symbol_matcher_data, iterate_name_matcher): Delete.
11211 (iterate_over_all_matching_symtabs): Adjust to use function_view
11212 as callback type and lambdas.
11213 (iterate_over_file_blocks): Adjust to use function_view as
11215 (decode_compound_collector): Now a class with private fields.
11216 (decode_compound_collector::release_symbols): New method.
11217 (collect_one_symbol): Rename to...
11218 (decode_compound_collector::operator()): ... this and adjust.
11219 (lookup_prefix_sym): decode_compound_collector construction bits
11220 move to decode_compound_collector ctor. Pass the
11221 decode_compound_collector object directly as callback. Remove
11222 cleanups and use decode_compound_collector::release_symbols
11224 (symtab_collector): Now a class with private fields.
11225 (symtab_collector::release_symtabs): New method.
11226 (add_symtabs_to_list): Rename to...
11227 (symtab_collector::operator()): ... this and adjust.
11228 (collect_symtabs_from_filename): symtab_collector construction
11229 bits move to symtab_collector ctor. Pass the symtab_collector
11230 object directly as callback. Remove cleanups and use
11231 symtab_collector::release_symtabs instead.
11232 (collect_symbols): Delete.
11233 (add_matching_symbols_to_info): Use lambdas.
11234 * macrocmd.c (print_macro_callback): Delete.
11235 (info_macro_command): Use a lambda.
11236 (info_macros_command): Pass print_macro_definition as callable
11238 (print_one_macro): Remove 'ignore' parameter.
11239 (macro_list_command): Adjust.
11240 * macrotab.c (macro_for_each_data::fn): Now a function_view.
11241 (macro_for_each_data::user_data): Delete field.
11242 (foreach_macro): Adjust to call the function_view.
11243 (macro_for_each): Adjust to use function_view as callback type.
11244 (foreach_macro_in_scope): Adjust to call the function_view.
11245 (macro_for_each_in_scope): Adjust to use function_view as callback
11247 * macrotab.h: Include "common/function-view.h".
11248 (macro_callback_fn): Declare a prototype instead of a pointer.
11249 Remove "user_data" parameter.
11250 (macro_for_each, macro_for_each_in_scope): Adjust to use
11251 function_view as callback type.
11252 * psymtab.c (partial_map_expand_apply)
11253 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
11254 Adjust to use function_view as callback type and to return bool.
11255 (psym_expand_symtabs_matching): Adjust to use function_view as
11257 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
11258 to use function_view as callback type and to return bool.
11259 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
11261 * symfile.c (expand_symtabs_matching): Adjust to use function_view
11263 * symfile.h: Include "common/function-view.h".
11264 (expand_symtabs_file_matcher_ftype)
11265 (expand_symtabs_symbol_matcher_ftype)
11266 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
11268 (quick_symbol_functions::map_symtabs_matching_filename)
11269 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
11270 function_view as callback type and return bool.
11271 (expand_symtabs_matching): Adjust to use function_view as callback
11273 (maintenance_expand_name_matcher)
11274 (maintenance_expand_file_matcher): Delete.
11275 (maintenance_expand_symtabs): Use lambdas.
11276 * symtab.c (iterate_over_some_symtabs): Adjust to use
11277 function_view as callback types and return bool.
11278 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
11280 (lookup_symtab_callback): Delete.
11281 (lookup_symtab): Use a lambda.
11282 (iterate_over_symbols): Adjust to use function_view as callback
11284 (struct search_symbols_data, search_symbols_file_matches)
11285 (search_symbols_name_matches): Delete.
11286 (search_symbols): Use a pair of lambdas.
11287 (struct add_name_data, add_macro_name, symbol_completion_matcher)
11288 (symtab_expansion_callback): Delete.
11289 (default_make_symbol_completion_list_break_on_1): Use lambdas.
11290 * symtab.h: Include "common/function-view.h".
11291 (iterate_over_some_symtabs): Adjust to use function_view as
11292 callback type and return bool.
11293 (iterate_over_symtabs): Adjust to use function_view as callback
11295 (symbol_found_callback_ftype): Remove 'data' parameter and return
11297 (iterate_over_symbols): Adjust to use function_view as callback
11300 2017-02-23 Pedro Alves <palves@redhat.com>
11302 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
11303 (%.o) <unittests/%.c>: New pattern.
11304 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
11305 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
11306 * common/function-view.h: New file.
11307 * unittests/function-view-selftests.c: New file.
11308 * configure: Regenerate.
11310 2017-02-23 Simon Marchi <simon.marchi@ericsson.com>
11312 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
11314 * go32-nat.c (go32_thread_alive): Likewise.
11316 2017-02-23 Yao Qi <yao.qi@linaro.org>
11318 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
11321 2017-02-23 Yao Qi <yao.qi@linaro.org>
11323 * varobj.c (varobj_clear_saved_item): Use delete instead of
11325 (update_dynamic_varobj_children): Likewise.
11327 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
11329 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
11331 2017-02-21 Simon Marchi <simon.marchi@ericsson.com>
11333 * common/enum-flags.h (enum_flags::enum_flags): Initialize
11334 m_enum_value to 0 in default constructor.
11336 2017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
11338 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
11339 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
11340 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
11341 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
11342 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
11343 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
11344 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
11345 IS_STORE_CONDITIONAL_INSN.
11347 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
11349 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
11351 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
11353 * NEWS (Changes since GDB 7.12): Add DWARF-5.
11355 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
11357 * dwarf2read.c (skip_one_die, read_attribute_value)
11358 (dwarf2_const_value_attr, dump_die_shallow)
11359 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
11360 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
11362 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
11364 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
11365 (dwarf_parse_macro_header): Accept DWARF version 5.
11366 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
11368 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
11370 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
11372 * common/common-exceptions.h (enum errors): Likewise.
11373 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
11374 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
11375 (dwarf_expr_context::execute_stack_op): Likewise.
11376 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
11378 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
11379 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
11380 (show_entry_values_debug, call_site_to_target_addr)
11381 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
11382 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
11383 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
11384 (value_of_dwarf_block_entry, indirect_pieced_value)
11385 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
11386 (disassemble_dwarf_expression): Likewise.
11387 * dwarf2read.c (process_die, inherit_abstract_dies)
11388 (read_call_site_scope): Likewise.
11389 * gdbtypes.h (struct func_type, struct call_site_parameter)
11390 (struct call_site): Likewise.
11391 * stack.c (read_frame_arg): Likewise.
11392 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
11394 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
11396 * defs.h (read_unsigned_leb128): New declaration.
11397 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
11398 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
11399 (dwarf2_find_location_expression): Call also
11400 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
11401 * dwarf2loc.h (dwarf2_version): New declaration.
11402 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
11404 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
11406 (struct dwop_section_names): Add loclists_dwo.
11407 (dwop_section_names): Add .debug_loclists.dwo.
11408 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
11409 (struct dwarf2_per_cu_data): Add dwarf_version.
11410 (struct dwo_sections): Add loclists.
11411 (struct attr_abbrev): Add implicit_const.
11412 (read_indirect_line_string): New declaration.
11413 (read_unsigned_leb128): Delete declaration.
11414 (rcuh_kind): New definition.
11415 (read_and_check_comp_unit_head): Change parameter
11416 is_debug_types_section to section_kind.
11417 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
11418 (read_comp_unit_head): Change parameter abfd to section, add parameter
11419 section_kind. Handle DWARF-5.
11420 (error_check_comp_unit_head): Accept also DWARF version 5.
11421 (read_and_check_comp_unit_head): Change parameter
11422 is_debug_types_section to section_kind.
11423 (read_and_check_type_unit_head): Delete function.
11424 (read_abbrev_offset): Handle DWARF-5.
11425 (create_debug_type_hash_table): Add parameter section_kind. Process
11426 only DW_UT_type. Use signature and type_offset_in_tu from struct
11428 (create_debug_types_hash_table): Update create_debug_type_hash_table
11430 (create_all_type_units): Call create_debug_type_hash_table.
11431 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
11432 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
11434 (skip_one_die): Handle DW_FORM_implicit_const.
11435 (dwarf2_rnglists_process): New function.
11436 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
11437 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
11438 (read_attribute_value): Handle DW_FORM_implicit_const,
11440 (read_attribute): Handle DW_FORM_implicit_const.
11441 (read_indirect_string_at_offset_from): New function from
11442 read_indirect_string_at_offset.
11443 (read_indirect_string_at_offset): Call
11444 read_indirect_string_at_offset_from.
11445 (read_indirect_line_string_at_offset): New function.
11446 (read_indirect_string): New function comment.
11447 (read_indirect_line_string): New function.
11448 (read_unsigned_leb128): Make it global.
11449 (dwarf2_string_attr): Handle DWARF-5.
11450 (add_include_dir_stub, read_formatted_entries): New functions.
11451 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
11453 (per_cu_header_read_in): Update read_comp_unit_head caller.
11454 (dwarf2_version): New function.
11455 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
11457 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
11460 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
11462 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
11464 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
11466 * dwarf2read.c (dwarf2_ranges_process): New function from
11467 dwarf2_ranges_read.
11468 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
11469 dwarf2_ranges_process.
11471 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
11473 * dwarf2read.c (create_debug_type_hash_table): New function from
11474 create_debug_types_hash_table.
11475 (create_debug_types_hash_table): Call create_debug_type_hash_table.
11476 (create_all_type_units, open_and_init_dwo_file): Update
11477 create_debug_types_hash_table callers.
11479 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
11482 * fork-child.c (trace_start_error): Fix thinko. va_end should
11483 refer to 'ap', not 'args'.
11485 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
11486 Pedro Alves <palves@redhat.com>
11489 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
11491 * fork-child.c (trace_start_error): New function.
11492 (trace_start_error_with_name): Likewise.
11493 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
11494 * inf-ptrace.c (inf_ptrace_me): Likewise.
11495 * inferior.h (trace_start_error): New prototype.
11496 (trace_start_error_with_name): Likewise.
11498 2017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
11501 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
11502 NULL before using it.
11503 * symmisc.c (maintenance_print_symbols): Likewise.
11504 (maintenance_print_msymbols): Likewise.
11506 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
11508 * NEWS: Add record Python bindings entry.
11510 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
11512 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
11514 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
11515 * python/py-record-btrace.c, python/py-record-btrace.h,
11516 python/py-record-full.c, python/py-record-full.h: New file.
11517 * python/py-record.c: Add include for py-record-btrace.h and
11519 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
11520 recpy_instruction_history, recpy_function_call_history, recpy_begin,
11521 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
11522 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
11524 (gdbpy_initialize_btrace): New export.
11525 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
11527 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
11529 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
11530 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
11531 * python/py-record.c: New file.
11532 * python/python-internal.h (gdbpy_start_recording,
11533 gdbpy_current_recording, gdpy_stop_recording,
11534 gdbpy_initialize_record): New export.
11535 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
11536 (python_GdbMethods): Add gdbpy_start_recording,
11537 gdbpy_current_recording and gdbpy_stop_recording.
11539 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
11541 * record-btrace.c (record_btrace_record_method): New function.
11542 (init_record_btrace_ops): Initialize to_record_method.
11543 * record-full.c (record_full_record_method): New function.
11544 (init_record_full_ops, init_record_full_core_ops): Add
11545 record_full_record_method.
11546 * record.h (enum record_method): New enum.
11547 * target-debug.h (target_debug_print_enum_record_method: New define.
11548 * target-delegates.c: Regenerate.
11549 * target.c (target_record_method): New function.
11550 * target.h: Include record.h.
11551 (struct target_ops) <to_record_method>: New field.
11552 (target_record_method): New export.
11554 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
11556 * record.h (record_start, record_stop): New export.
11557 * record.c (record_start, record_stop): New function.
11559 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
11561 * btrace.c (btrace_fetch): Copy function call segments pointer
11563 (btrace_clear): Clear the vector.
11564 (btrace_find_insn_by_number): Use binary search to find the correct
11565 function call segment.
11566 * btrace.h (brace_fun_p): New typedef.
11567 (struct btrace_thread_info) <functions>: New field.
11569 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
11571 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
11572 * btrace.c (btrace_decode_error): ... here. New function.
11573 * btrace.h (btrace_decode_error): New export.
11575 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
11577 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
11578 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
11579 btrace_find_insn_by_number): Remove special case for gaps.
11580 * btrace.h (btrace_insn_get_error): New export.
11581 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
11582 * record-btrace.c (btrace_insn_history): Print number for gaps.
11583 (record_btrace_info, record_btrace_goto): Handle gaps.
11585 2017-02-14 Tom Tromey <tom@tromey.com>
11588 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
11590 * python/py-evts.c (gdbpy_initialize_py_events): Add
11591 before_prompt registry.
11592 * python/py-events.h (events_object) <before_prompt>: New field.
11594 2017-02-14 Markus Metzger <markus.t.metzger@intel.com>
11596 * btrace.c (ftrace_new_switch): Preserve up link and flags.
11598 2017-02-13 Luis Machado <lgustavo@codesourcery.com>
11600 * symfile (_initialize_symfile): Add usage text to the load command's
11603 2017-02-10 Simon Marchi <simon.marchi@ericsson.com>
11605 * utils.c (defaulted_query): Don't query on secondary UIs.
11607 2017-02-10 Tom Tromey <tom@tromey.com>
11609 * rust-lang.c (rust_get_disr_info): Remove unused variable.
11611 2017-02-10 Tom Tromey <tom@tromey.com>
11613 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
11615 * python/py-type.c (typy_legacy_template_argument): Remove
11616 unnecessary "cleanup" local.
11618 2017-02-10 Tom Tromey <tom@tromey.com>
11620 * python/python.c (do_start_initialization): New function, from
11621 _initialize_python.
11622 (_initialize_python): Call do_start_initialization.
11623 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
11626 2017-02-10 Tom Tromey <tom@tromey.com>
11628 * python/py-prettyprint.c (pretty_print_one_value): Use
11631 2017-02-10 Tom Tromey <tom@tromey.com>
11633 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
11634 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
11636 * python/py-type.c (field_new): Use gdbpy_ref.
11637 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
11639 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
11640 (py_free_pspace): Likewise.
11641 (pspace_to_pspace_object): Likewise.
11642 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
11643 (py_free_objfile): Likewise.
11644 (objfile_to_objfile_object): Likewise.
11645 * python/py-inferior.c (delete_thread_object): Use
11647 (infpy_read_memory): Likewise.
11648 (py_free_inferior): Likewise.
11649 * python/py-evtregistry.c (create_eventregistry_object): Use
11651 * python/py-event.c (create_event_object): Use gdbpy_ref.
11653 2017-02-10 Tom Tromey <tom@tromey.com>
11655 * python/py-ref.h (gdbpy_ref_policy): Now a template.
11656 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
11658 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
11659 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
11660 python/py-exitedevent.c, python/py-finishbreakpoint.c,
11661 python/py-framefilter.c, python/py-function.c,
11662 python/py-inferior.c, python/py-infevents.c,
11663 python/py-linetable.c, python/py-newobjfileevent.c,
11664 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
11665 python/py-signalevent.c, python/py-stopevent.c,
11666 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
11667 python/py-unwind.c, python/py-utils.c, python/py-value.c,
11668 python/py-varobj.c, python/py-xmethods.c, python/python.c,
11669 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
11671 2017-02-10 Tom Tromey <tom@tromey.com>
11673 * ui-out.h (ui_out_emit_type): New class.
11674 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
11675 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
11676 and ui_out_emit_tuple.
11677 (enumerate_locals): Likewise.
11678 (py_mi_print_variables, py_print_locals, py_print_args): Use
11680 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
11682 * common/gdb_optional.h: New file.
11684 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
11686 * MAINTAINERS (Write After Approval): Update my e-mail address.
11688 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
11691 * breakpoint.c (_initialize_breakpoint): Update the help description
11692 of the 'commands' command to indicate that it takes a list argument.
11694 2017-02-09 Simon Marchi <simon.marchi@ericsson.com>
11696 * interps.c (current_interp_set_logging): Remove "return".
11698 2017-02-09 Gary Benson <gbenson@redhat.com>
11700 * symtab.c (add_symtab_completions): Prevent NULL pointer
11703 2017-02-08 Pedro Alves <palves@redhat.com>
11705 * interps.c (interp::interp): Remove reference to quiet_p.
11706 (interp_set): Make static. Remove dead "Switching to" output
11708 (interp_quiet_p, interp_set_quiet): Delete.
11709 (interpreter_exec_cmd): Don't set the interpreter quiet.
11710 * interps.h (interp_quiet_p): Make static.
11711 (class interp) <quiet_p>: Remove field
11713 2017-02-08 Jerome Guitton <guitton@adacore.com>
11715 * cli/cli-decode.c (find_command_name_length): Make it extern.
11716 * cli/cli-decode.h (find_command_name_length): Declare.
11717 * cli/cli-script.c (command_name_equals, line_first_arg):
11719 (process_next_line): Use cli-decode to parse command names.
11720 (build_command_line): Make args a constant pointer.
11722 2017-02-08 Jerome Guitton <guitton@adacore.com>
11724 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
11725 Remove case-insensitive search.
11727 2017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
11729 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
11730 at the end of the line. Avoids an ARI warning.
11732 2017-02-06 Luis Machado <lgustavo@codesourcery.com>
11734 * NEWS: Mention support for record/replay of Intel 64 rdrand and
11735 rdseed instructions.
11736 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
11738 2017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
11741 Provide and use sparc32 and sparc64 target description XML files.
11742 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
11743 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
11744 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
11745 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
11746 * features/sparc/sparc32-solaris.xml: New file.
11747 * features/sparc/sparc64-solaris.xml: New file.
11748 * features/sparc/sparc32-solaris.c: Generated.
11749 * features/sparc/sparc64-solaris.c: Generated.
11750 * sparc-tdep.h: Account for differences in target descriptions.
11751 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
11752 (sparc32_register_type): Use target provided registers.
11753 (validate_tdesc_registers): New function.
11754 (sparc32_gdbarch_init): Use tdesc_has_registers.
11755 Set pseudoregister functions.
11756 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
11757 (sparc64_register_type): Use target provided registers.
11758 (sparc64_init_abi): Set pseudoregister functions.
11760 2017-02-03 Tom Tromey <tom@tromey.com>
11763 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
11764 with a single member.
11766 2017-02-03 Pedro Alves <palves@redhat.com>
11768 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
11769 (cli_interp_base::~cli_interp_base): New.
11770 (cli_interp): New struct.
11771 (as_cli_interp): Cast the interp itself to cli_interp.
11772 (cli_interpreter_pre_command_loop): Rename to ...
11773 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
11775 (cli_interpreter_init): Rename to ...
11776 (cli_interp::init): ... this. Remove 'self' parameter. Use
11777 boolean. Make extern.
11778 (cli_interpreter_resume): Rename to ...
11779 (cli_interp::resume): ... this. Remove 'data' parameter. Make
11781 (cli_interpreter_suspend): Rename to ...
11782 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
11784 (cli_interpreter_exec): Rename to ...
11785 (cli_interp::exec): ... this. Remove 'data' parameter. Make
11787 (cli_interpreter_supports_command_editing): Rename to ...
11788 (cli_interp_base::supports_command_editing): ... this. Remove
11789 'interp' parameter. Make extern.
11790 (cli_ui_out): Rename to ...
11791 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
11793 (cli_set_logging): Rename to ...
11794 (cli_interp_base::set_logging): ... this. Remove 'interp'
11795 parameter. Make extern.
11796 (cli_interp_procs): Delete.
11797 (cli_interp_factory): Adjust to use "new".
11798 * cli/cli-interp.h: Include "interps.h".
11799 (struct cli_interp_base): New struct.
11800 * interps.c (struct interp): Delete. Fields moved to interps.h.
11801 (interp_new): Delete.
11802 (interp::interp, interp::~interp): New.
11803 (interp_set): Use bool, and return void. Assume the interpreter
11804 has suspend, init and resume methods, and that the all return
11806 (set_top_level_interpreter): interp_set returns void.
11807 (interp_ui_out): Adapt.
11808 (current_interp_set_logging): Adapt.
11809 (interp_data): Delete.
11810 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
11811 (interp_exec): Adapt.
11812 (top_level_interpreter_data): Delete.
11813 * interps.h (interp_init_ftype, interp_resume_ftype)
11814 (interp_suspend_ftype, interp_exec_ftype)
11815 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
11816 (class interp): New.
11817 (interp_new): Delete.
11818 (interp_set): Now returns void. Use bool.
11819 (interp_data, top_level_interpreter_data): Delete.
11820 * mi/mi-common.h: Include interps.h.
11821 (class mi_interp): Inherit from interp. Define a ctor. Declare
11822 init, resume, suspect, exec, interp_ui_out, set_logging and
11823 pre_command_loop methods.
11824 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
11825 (mi_interpreter_init): Rename to ...
11826 (mi_interp::init): ... this. Remove the 'interp' parameter, use
11827 bool, return void and make extern. Adjust.
11828 (mi_interpreter_resume): ... Rename to ...
11829 (mi_interp::resume): ... this. Remove the 'data' parameter,
11830 return void and make extern. Adjust.
11831 (mi_interpreter_suspend): ... Rename to ...
11832 (mi_interp::suspend): ... this. Remove the 'data' parameter,
11833 return void and make extern. Adjust.
11834 (mi_interpreter_exec): ... Rename to ...
11835 (mi_interp::exec): ... this. Remove the 'data' parameter and make
11837 (mi_interpreter_pre_command_loop): ... Rename to ...
11838 (mi_interp::pre_command_loop): ... this. Remove the 'self'
11839 parameter and make extern.
11840 (mi_on_normal_stop_1): Adjust.
11841 (mi_ui_out): Rename to ...
11842 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
11843 parameter and make extern. Adjust.
11844 (mi_set_logging): Rename to ...
11845 (mi_interp::set_logging): ... this. Remove the 'interp'
11846 parameter and make extern. Adjust.
11847 (mi_interp_procs): Delete.
11848 (mi_interp_factory): Adjust to use 'new'.
11849 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
11850 (mi_print_exception, mi_execute_command, mi_load_progress):
11852 * tui/tui-interp.c (tui_interp): New class.
11853 (as_tui_interp): Return a tui_interp pointer.
11854 (tui_on_normal_stop, tui_on_signal_received)
11855 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
11856 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
11857 to use interp::interp_ui_out.
11858 (tui_init): Rename to ...
11859 (tui_interp::init): ... this. Remove the 'self' parameter, use
11860 bool, return void and make extern. Adjust.
11861 (tui_resume): Rename to ...
11862 (tui_interp::resume): ... this. Remove the 'data' parameter,
11863 return void and make extern. Adjust.
11864 (tui_suspend): Rename to ...
11865 (tui_interp::suspend): ... this. Remove the 'data' parameter,
11866 return void and make extern. Adjust.
11867 (tui_ui_out): Rename to ...
11868 (tui_interp::interp_ui_out): ... this. Remove the 'self'
11869 parameter, and make extern. Adjust.
11870 (tui_exec): Rename to ...
11871 (tui_interp::exec): ... this. Remove the 'data' parameter and
11873 (tui_interp_procs): Delete.
11874 (tui_interp_factory): Use "new".
11876 2017-02-02 Tom Tromey <tom@tromey.com>
11878 * rust-exp.y (ends_raw_string, space_then_number)
11879 (rust_identifier_start_p): Return bool.
11880 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
11881 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
11882 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
11883 (rust_chartype_p): Return bool.
11884 (val_print_struct, rust_print_struct_def, rust_print_type):
11886 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
11889 2017-02-02 Tom Tromey <tom@tromey.com>
11891 * rust-lang.c: Reindent.
11893 2017-02-02 Tom Tromey <tom@tromey.com>
11895 * rust-lang.h (rust_crate_for_block): Update.
11896 * rust-lang.c (rust_crate_for_block): Return std::string.
11897 (rust_get_disr_info): Use std:;string, not
11898 gdb::unique_xmalloc_ptr.
11899 * rust-exp.y (crate_name): Update.
11901 2017-02-02 Pedro Alves <palves@redhat.com>
11903 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
11904 field out of gdb_disassembler_test and make it static.
11906 2017-02-02 Pedro Alves <palves@redhat.com>
11908 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
11909 mi1_interp and mi_interp fields.
11911 2017-02-02 Pedro Alves <palves@redhat.com>
11913 * cli/cli-interp.c (struct saved_output_files, saved_output):
11914 Moved from cli/cli-logging.c.
11915 (cli_set_logging): New function.
11916 (cli_interp_procs): Install cli_set_logging.
11917 * cli/cli-interp.h (make_logging_output, cli_set_logging):
11919 * cli/cli-logging.c (struct saved_output_files, saved_output):
11920 Moved to cli/cli-interp.c.
11921 (pop_output_files): Don't save outputs here.
11922 (make_logging_output): New function.
11923 (handle_redirections): Don't build tee nor save previous outputs
11925 * interps.c (current_interp_set_logging): Change prototype.
11926 Assume there's always a set_logging_proc method installed.
11927 * interps.h (interp_set_logging_ftype): Change prototype.
11928 (current_interp_set_logging): Change prototype and adjust comment.
11929 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
11930 use make_logging_output.
11931 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
11932 2017-02-02 Pedro Alves <palves@redhat.com>
11934 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
11936 (set_logging_overwrite): ... here.
11937 (logging_no_redirect_file): Delete.
11938 (set_logging_redirect): Don't handle redirection on the fly.
11939 Instead warn that "logging off" / "logging on" is necessary.
11940 (pop_output_files): Delete references to logging_no_redirect_file.
11941 (show_logging_command): Always speak in terms of what will happen
11942 once logging is reenabled.
11944 2017-02-02 Pedro Alves <palves@redhat.com>
11946 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
11948 2017-02-02 Pedro Alves <palves@redhat.com>
11950 * disasm.c (gdb_pretty_print_insn): Rename to ...
11951 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
11952 Remove gdbarch parameter. Adapt to clear the object's buffers
11953 instead of allocating new buffers, and to print using the object's
11954 gdb_disassembler instead of calling gdb_print_insn.
11955 (dump_insns): Use gdb_pretty_print_disassembler.
11956 * disasm.h (gdb_pretty_print_insn): Delete declaration.
11957 (gdb_pretty_print_disassembler): New class.
11958 * record-btrace.c (btrace_insn_history): Use
11959 gdb_pretty_print_disassembler.
11961 2017-02-02 Pedro Alves <palves@redhat.com>
11963 * ada-lang.c (type_as_string): Use string_file.
11964 * ada-valprint.c (ada_print_floating): Use string_file.
11965 * ada-varobj.c (ada_varobj_scalar_image)
11966 (ada_varobj_get_value_image): Use string_file.
11967 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
11968 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
11969 * breakpoint.c (update_inserted_breakpoint_locations)
11970 (insert_breakpoint_locations, reattach_breakpoints)
11971 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
11972 (print_it_watchpoint): Use string_file.
11973 (save_breakpoints): Use stdio_file.
11974 * c-exp.y (oper): Use string_file.
11975 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
11977 (pop_output_files): Use delete.
11978 (handle_redirections): Use stdio_file and tee_file.
11979 * cli/cli-setshow.c (do_show_command): Use string_file.
11980 * compile/compile-c-support.c (c_compute_program): Use
11982 * compile/compile-c-symbols.c (generate_vla_size): Take a
11983 'string_file &' instead of a 'ui_file *'.
11984 (generate_c_for_for_one_variable): Take a 'string_file &' instead
11985 of a 'ui_file *'. Use string_file.
11986 (generate_c_for_variable_locations): Take a 'string_file &'
11987 instead of a 'ui_file *'.
11988 * compile/compile-internal.h (generate_c_for_for_one_variable):
11989 Take a 'string_file &' instead of a 'ui_file *'.
11990 * compile/compile-loc2c.c (push, pushf, unary, binary)
11991 (print_label, pushf_register_address, pushf_register)
11992 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
11993 'ui_file *'. Adjust.
11994 * compile/compile.c (compile_to_object): Use string_file.
11995 * compile/compile.h (compile_dwarf_expr_to_c)
11996 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
11998 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
11999 (replace_typedefs_qualified_name): Use string_file and
12001 * disasm.c (gdb_pretty_print_insn): Use string_file.
12002 (gdb_disassembly): Adjust reference the null_stream global.
12003 (do_ui_file_delete): Delete.
12004 (gdb_insn_length): Use null_stream.
12005 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
12006 * dwarf2loc.c (dwarf2_compile_property_to_c)
12007 (locexpr_generate_c_location, loclist_generate_c_location): Take a
12008 'string_file &' instead of a 'ui_file *'.
12009 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
12010 * dwarf2read.c (do_ui_file_peek_last): Delete.
12011 (dwarf2_compute_name): Use string_file.
12012 * event-top.c (gdb_setup_readline): Use stdio_file.
12013 * gdbarch.sh (verify_gdbarch): Use string_file.
12014 * gdbtypes.c (safe_parse_type): Use null_stream.
12015 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
12017 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
12018 'string_file *' instead of a 'ui_file *'.
12019 (gdbscm_arch_disassemble): Use string_file.
12020 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
12021 * guile/scm-ports.c (class ioscm_file_port): Now a class that
12022 inherits from ui_file.
12023 (ioscm_file_port_delete, ioscm_file_port_rewind)
12024 (ioscm_file_port_put): Delete.
12025 (ioscm_file_port_write): Rename to ...
12026 (ioscm_file_port::write): ... this. Remove file_port_magic
12028 (ioscm_file_port_new): Delete.
12029 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
12031 * guile/scm-type.c (tyscm_type_name): Use string_file.
12032 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
12034 * infcmd.c (print_return_value_1): Use string_file.
12035 * infrun.c (print_target_wait_results): Use string_file.
12036 * language.c (add_language): Use string_file.
12037 * location.c (explicit_to_string_internal): Use string_file.
12038 * main.c (captured_main_1): Use null_file.
12039 * maint.c (maintenance_print_architecture): Use stdio_file.
12040 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
12041 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
12042 event_channel>: Change type to mi_console_file pointer.
12043 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
12044 (mi_console_file_delete): Delete.
12045 (struct mi_console_file): Delete.
12046 (mi_console_file_magic): Delete.
12047 (mi_console_file_new): Delete.
12048 (mi_console_file::mi_console_file): New.
12049 (mi_console_file_delete): Delete.
12050 (mi_console_file_fputs): Delete.
12051 (mi_console_file::write): New.
12052 (mi_console_raw_packet): Delete.
12053 (mi_console_file::flush): New.
12054 (mi_console_file_flush): Delete.
12055 (mi_console_set_raw): Rename to ...
12056 (mi_console_file::set_raw): ... this.
12057 * mi/mi-console.h (class mi_console_file): New class.
12058 (mi_console_file_new, mi_console_set_raw): Delete.
12059 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
12060 (mi_set_logging): Use delete and tee_file. Adjust.
12061 * mi/mi-main.c (output_register): Use string_file.
12062 (mi_cmd_data_evaluate_expression): Use string_file.
12063 (mi_cmd_data_read_memory): Use string_file.
12064 (mi_cmd_execute, print_variable_or_computed): Use string_file.
12065 * mi/mi-out.c (mi_ui_out::main_stream): New.
12066 (mi_ui_out::rewind): Use main_stream and
12068 (mi_ui_out::put): Use main_stream and string_file.
12069 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
12070 Allocate a 'string_file' instead.
12071 (mi_out_new): Don't allocate a mem_fileopen stream here.
12072 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
12073 (mi_ui_out::main_stream): Declare method.
12074 * printcmd.c (eval_command): Use string_file.
12075 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
12076 * python/py-arch.c (archpy_disassemble): Use string_file.
12077 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
12078 * python/py-frame.c (frapy_str): Use string_file.
12079 * python/py-framefilter.c (py_print_type, py_print_single_arg):
12081 * python/py-type.c (typy_str): Use string_file.
12082 * python/py-unwind.c (unwind_infopy_str): Use string_file.
12083 * python/py-value.c (valpy_str): Use string_file.
12084 * record-btrace.c (btrace_insn_history): Use string_file.
12085 * regcache.c (regcache_print): Use stdio_file.
12086 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
12087 * remote.c (escape_buffer): Use string_file.
12088 * rust-lang.c (rust_get_disr_info): Use string_file.
12089 * serial.c (serial_open_ops_1): Use stdio_file.
12090 (do_serial_close): Use delete.
12091 * stack.c (print_frame_arg): Use string_file.
12092 (print_frame_args): Remove local mem_fileopen stream, not used.
12093 (print_frame): Use string_file.
12094 * symmisc.c (maintenance_print_symbols): Use stdio_file.
12095 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
12096 Take a 'string_file *' instead of a 'ui_file *'.
12097 * top.c (new_ui): Use stdio_file and stderr_file.
12098 (free_ui): Use delete.
12099 (execute_command_to_string): Use string_file.
12100 (quit_confirm): Use string_file.
12101 * tracepoint.c (collection_list::append_exp): Use string_file.
12102 * tui/tui-disasm.c (tui_disassemble): Use string_file.
12103 * tui/tui-file.c: Don't include "ui-file.h".
12104 (enum streamtype, struct tui_stream): Delete.
12105 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
12106 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
12107 (tui_file::tui_file): New method.
12108 (tui_file_fputs): Delete.
12109 (tui_file_get_strbuf): Delete.
12110 (tui_file::puts): New method.
12111 (tui_file_adjust_strbuf): Delete.
12112 (tui_file_flush): Delete.
12113 (tui_file::flush): New method.
12114 * tui/tui-file.h: Tweak intro comment.
12116 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
12117 (tui_file_adjust_strbuf): Delete declarations.
12118 (class tui_file): New class.
12119 * tui/tui-io.c (tui_initialize_io): Use tui_file.
12120 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
12121 (tui_register_format): Use string_stream.
12122 * tui/tui-stack.c (tui_make_status_line): Use string_file.
12123 (tui_get_function_from_frame): Use string_file.
12124 * typeprint.c (type_to_string): Use string_file.
12125 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
12126 (null_stream): New global.
12127 (ui_file_delete): Delete.
12128 (ui_file::ui_file): New.
12129 (null_file_isatty): Delete.
12130 (ui_file::~ui_file): New.
12131 (null_file_rewind): Delete.
12132 (ui_file::printf): New.
12133 (null_file_put): Delete.
12134 (null_file_flush): Delete.
12135 (ui_file::putstr): New.
12136 (null_file_write): Delete.
12137 (ui_file::putstrn): New.
12138 (null_file_read): Delete.
12139 (ui_file::putc): New.
12140 (null_file_fputs): Delete.
12141 (null_file_write_async_safe): Delete.
12142 (ui_file::vprintf): New.
12143 (null_file_delete): Delete.
12144 (null_file::write): New.
12145 (null_file_fseek): Delete.
12146 (null_file::puts): New.
12147 (ui_file_data): Delete.
12148 (null_file::write_async_safe): New.
12149 (gdb_flush, ui_file_isatty): Adjust.
12150 (ui_file_put, ui_file_rewind): Delete.
12151 (ui_file_write): Adjust.
12152 (ui_file_write_for_put): Delete.
12153 (ui_file_write_async_safe, ui_file_read): Adjust.
12154 (ui_file_fseek): Delete.
12155 (fputs_unfiltered): Adjust.
12156 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
12157 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
12158 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
12159 (set_ui_file_data): Delete.
12160 (string_file::~string_file, string_file::write)
12161 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
12162 (do_ui_file_as_string, ui_file_as_string): Delete.
12163 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
12164 (struct mem_file): Delete.
12165 (mem_file_new): Delete.
12166 (stdio_file::stdio_file): New.
12167 (mem_file_delete): Delete.
12168 (stdio_file::stdio_file): New.
12169 (mem_fileopen): Delete.
12170 (stdio_file::~stdio_file): New.
12171 (mem_file_rewind): Delete.
12172 (stdio_file::set_stream): New.
12173 (mem_file_put): Delete.
12174 (stdio_file::open): New.
12175 (mem_file_write): Delete.
12176 (stdio_file_magic, struct stdio_file): Delete.
12177 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
12178 (stdio_file::flush): New.
12179 (stdio_file_read): Rename to ...
12180 (stdio_file::read): ... this. Adjust.
12181 (stdio_file_write): Rename to ...
12182 (stdio_file::write): ... this. Adjust.
12183 (stdio_file_write_async_safe): Rename to ...
12184 (stdio_file::write_async_safe) ... this. Adjust.
12185 (stdio_file_fputs): Rename to ...
12186 (stdio_file::puts) ... this. Adjust.
12187 (stdio_file_isatty): Delete.
12188 (stdio_file_fseek): Delete.
12189 (stdio_file::isatty): New.
12190 (stderr_file_write): Rename to ...
12191 (stderr_file::write) ... this. Adjust.
12192 (stderr_file_fputs): Rename to ...
12193 (stderr_file::puts) ... this. Adjust.
12194 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
12195 (stderr_file::stderr_file): New.
12196 (tee_file_magic): Delete.
12197 (struct tee_file): Delete.
12198 (tee_file::tee_file): New.
12199 (tee_file_new): Delete.
12200 (tee_file::~tee_file): New.
12201 (tee_file_delete): Delete.
12202 (tee_file_flush): Rename to ...
12203 (tee_file::flush): ... this. Adjust.
12204 (tee_file_write): Rename to ...
12205 (tee_file::write): ... this. Adjust.
12206 (tee_file::write_async_safe): New.
12207 (tee_file_fputs): Rename to ...
12208 (tee_file::puts): ... this. Adjust.
12209 (tee_file_isatty): Rename to ...
12210 (tee_file::isatty): ... this. Adjust.
12211 * ui-file.h (struct obstack, struct ui_file): Don't
12213 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
12214 (ui_file_write_ftype)
12215 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
12216 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
12217 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
12218 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
12219 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
12220 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
12221 (set_ui_file_fseek): Delete.
12222 (ui_file_data, ui_file_delete, ui_file_rewind)
12223 (struct ui_file): New.
12225 (class null_file): New.
12226 (null_stream): Declare.
12227 (ui_file_write_for_put, ui_file_put): Delete.
12228 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
12230 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
12231 (gdb_fopen, tee_file_new): Delete.
12232 (struct string_file): New.
12233 (struct stdio_file): New.
12234 (stdio_file_up): New.
12235 (struct stderr_file): New.
12236 (class tee_file): New.
12237 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
12238 of a 'ui_file *'. Adjust.
12239 * ui-out.h (class ui_out) <field_stream>: Likewise.
12240 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
12241 (null_stream): Delete.
12242 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
12244 * utils.h (struct ui_file): Delete forward declaration..
12245 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
12246 (error_stream): Take a 'string_file &' instead of a
12248 * varobj.c (varobj_value_get_print_value): Use string_file.
12249 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
12250 * gdbarch.c: Regenerate.
12252 2017-02-02 Pedro Alves <palves@redhat.com>
12254 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
12255 (gdb_pretty_print_insn): ... this. Now a free function. Add back
12256 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
12257 Adjust to call gdb_print_insn instead of
12258 gdb_disassembler::print_insn.
12259 (dump_insns, do_mixed_source_and_assembly_deprecated)
12260 (do_mixed_source_and_assembly, do_assembly_only): Add back a
12261 'gdbarch' parameter. Remove gdb_disassembler parameter.
12262 (gdb_disassembly): Don't allocate a gdb_disassembler here.
12263 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
12265 (gdb_pretty_print_insn): Re-add declaration.
12266 * record-btrace.c (btrace_insn_history): Don't allocate a
12267 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
12269 2017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
12271 * disasm.h (gdb_disassembly): Remove file_string parameter.
12272 * disasm.c (gdb_disassembly): Likewise.
12273 * cli/cli-cmds.c (print_disassembly): Adapt.
12274 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
12275 * stack.c (do_gdb_disassembly): Likewise.
12277 2017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
12279 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
12280 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
12281 targets. And if the implicit value is longer than needed, extract
12282 the first bytes instead of the "least significant" ones.
12284 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
12286 * btrace.c (btrace_enable): Do not call btrace_add_pc for
12287 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
12288 (btrace_fetch): Assert can_access_registers_ptid.
12289 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
12290 validate_registers_access.
12292 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
12294 * gdbthread.h (can_access_registers_ptid): New.
12295 * thread.c (can_access_registers_ptid): New.
12297 2017-02-01 Pedro Alves <palves@redhat.com>
12299 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
12301 2017-01-31 Pedro Alves <palves@redhat.com>
12303 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
12306 2017-01-31 Pedro Alves <palves@redhat.com>
12308 * stack.c (print_frame_args): Remove local mem_fileopen stream,
12311 2017-01-31 Pedro Alves <palves@redhat.com>
12313 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
12315 2017-01-31 Pedro Alves <palves@redhat.com>
12317 * common/scoped_restore.h
12318 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
12319 change the value's parameter type to T2.
12320 (make_scoped_restore): Likewise.
12322 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
12323 Richard Henderson <rth@redhat.com>
12325 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
12326 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
12327 GS_BASE for older kernels.
12328 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
12329 GS_BASE for older kernels.
12330 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
12331 and GS_BASE to the offset table.
12332 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
12333 system register group.
12334 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
12336 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
12338 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
12339 AMD64_GSBASE_REGNUM.
12340 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
12341 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
12342 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
12343 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
12344 i386/64bit-segments.xml in those rules.
12345 * features/i386/64bit-segments.xml: New file.
12346 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
12347 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
12348 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
12349 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
12350 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
12351 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
12352 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
12353 * features/i386/amd64-avx-linux.c: Regenerated.
12354 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
12355 * features/i386/amd64-avx-mpx.c: Regenerated.
12356 * features/i386/amd64-avx512-linux.c: Regenerated.
12357 * features/i386/amd64-linux.c: Regenerated.
12358 * features/i386/amd64-mpx-linux.c: Regenerated.
12359 * features/i386/i386-avx-mpx-linux.c: Regenerated.
12360 * features/i386/i386-avx-mpx.c: Regenerated.
12361 * features/i386/x32-avx-linux.c: Regenerated.
12362 * features/i386/x32-avx512-linux.c: Regenerated.
12363 * regformats/i386/amd64-avx-linux.dat: Regenerated.
12364 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
12365 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
12366 * regformats/i386/amd64-linux.dat: Regenerated.
12367 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
12368 * regformats/i386/x32-avx-linux.dat: Regenerated.
12369 * regformats/i386/x32-avx512-linux.dat: Regenerated.
12370 * regformats/i386/x32-linux.dat: Regenerated.
12372 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
12374 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
12375 Set to AMD64_NUM_REGS.
12377 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
12379 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
12380 that checks validity of a register number.
12382 2017-01-27 Kees Cook <keescook@google.com>
12384 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
12385 fetch_fpregs if target has fpa registers.
12386 (arm_linux_store_inferior_registers): Call store_fpregs if target
12389 2017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
12391 * cris-tdep.c (cris_gdbarch_init): Remove check for
12392 info.byte_order and force it to BFD_ENDIAN_LITTLE.
12394 2017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
12396 * corelow.c (get_core_register_section): Check for regset
12397 existence before checking for REGSET_VARIABLE_SIZE.
12399 2017-01-26 Yao Qi <yao.qi@linaro.org>
12400 Pedro Alves <palves@redhat.com>
12403 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
12404 call memory_error, save memaddr instead.
12405 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
12406 negative, cal memory_error.
12407 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
12409 2017-01-26 Yao Qi <yao.qi@linaro.org>
12411 * disasm-selftests.c (memory_error_test): New function.
12412 (_initialize_disasm_selftests): Register memory_error_test.
12414 2017-01-26 Yao Qi <yao.qi@linaro.org>
12416 * Makefile.in (SFILES): Add disasm-selftests.c and
12418 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
12419 * disasm-selftests.c: New file.
12420 * selftest-arch.c: New file.
12421 * selftest-arch.h: New file.
12423 2017-01-26 Yao Qi <yao.qi@linaro.org>
12425 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
12426 to bfd_arch_mep. Don't return 0 if section is not
12427 found. Call print_insn_mep.
12429 2017-01-26 Pedro Alves <palves@redhat.com>
12430 Yao Qi <yao.qi@linaro.org>
12432 * arm-tdep.c: Include "disasm.h".
12433 (gdb_print_insn_arm): Update code to get gdbarch.
12434 * disasm.c (dis_asm_read_memory): Change it to
12435 gdb_disassembler::dis_asm_read_memory.
12436 (dis_asm_memory_error): Likewise.
12437 (dis_asm_print_address): Likewise.
12438 (gdb_pretty_print_insn): Change it to
12439 gdb_disassembler::pretty_print_insn.
12440 (dump_insns): Add one argument gdb_disassemlber. All
12442 (do_mixed_source_and_assembly_deprecated): Likewise.
12443 (do_mixed_source_and_assembly): Likewise.
12444 (do_assembly_only): Likewise.
12445 (gdb_disassembler::gdb_disassembler): New.
12446 (gdb_disassembler::print_insn): New.
12447 * disasm.h (class gdb_disassembler): New.
12448 (gdb_pretty_print_insn): Remove declaration.
12449 (gdb_disassemble_info): Likewise.
12450 * guile/scm-disasm.c (class gdbscm_disassembler): New.
12451 (gdbscm_disasm_read_memory_worker): Update.
12452 (gdbscm_disasm_read_memory): Update.
12453 (gdbscm_disasm_memory_error): Remove.
12454 (gdbscm_disasm_print_address): Remove.
12455 (gdbscm_disassembler::gdbscm_disassembler): New.
12456 (gdbscm_print_insn_from_port): Update.
12457 * mips-tdep.c: Include disasm.h.
12458 (gdb_print_insn_mips): Update code to get gdbarch.
12459 * record-btrace.c (btrace_insn_history): Update.
12460 * spu-tdep.c: Include disasm.h.
12461 (struct spu_dis_asm_data): Remove.
12462 (struct spu_dis_asm_info): New.
12463 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
12465 (gdb_print_insn_spu): Cast disassemble_info to
12468 2017-01-26 Yao Qi <yao.qi@linaro.org>
12470 * disasm.c (do_ui_file_delete): Delete.
12471 (gdb_insn_length): Move code creating stream to ...
12472 * utils.c (null_stream): ... here. New function.
12473 * utils.h (null_stream): Declare.
12475 2017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
12477 * python/py-inferior.c (find_thread_object): Return directly
12478 from the loop. Remove "found" variable.
12480 2017-01-21 Joel Brobecker <brobecker@adacore.com>
12482 GDB 7.12.1 released.
12484 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
12486 * python/py-function.c (fnpy_call): Reorder declarations to have
12487 the gdbpy_enter object declared first.
12488 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
12490 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
12493 * python/python-internal.h (PyMem_RawMalloc): Define for
12495 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
12496 PyMem_RawMalloc instead of PyMem_Malloc.
12498 2017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
12499 Luis Machado <lgustavo@codesourcery.com>
12501 * NEWS (New commands): Mention flash-erase.
12502 (New MI commands): Mention target-flash-erase.
12503 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
12505 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
12506 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
12507 * target.c (flash_erase_command): New function.
12508 (initialize_targets): Add new flash-erase command.
12509 * target.h (flash_erase_command): New declaration.
12511 2017-01-20 Joel Brobecker <brobecker@adacore.com>
12513 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
12514 HAVE_SYS_PROCFS_H is defined.
12516 2017-01-18 Alan Hayward <alan.hayward@arm.com>
12518 * remote.c (struct cached_reg): Change data into a pointer.
12519 * (stop_reply_dtr): Free data pointers before deleting vector.
12520 (process_stop_reply): Likewise.
12521 (remote_parse_stop_reply): Allocate space for data
12523 2017-01-18 Alan Hayward <alan.hayward@arm.com>
12525 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
12527 (amd64_pseudo_register_read_value): Likewise.
12528 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
12529 (store_register_using_P): Likewise.
12530 * regcache.c (regcache_xfer_part): Likewise.
12532 2017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
12534 Split real and pseudo registers.
12535 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
12536 (sparc32_pseudo_regnum): New enum.
12537 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
12538 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
12539 (SPARC32_CP0_REGISTERS): New macro.
12540 (sparc32_pseudo_register_name): New function.
12541 (sparc32_register_name): Use sparc32_pseudo_register_name.
12542 (sparc32_pseudo_register_type): New function.
12543 (sparc32_register_type): Use sparc32_pseudo_register_type.
12544 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
12545 pseudo register numbers.
12546 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
12547 (SPARC64_CP0_REGISTERS): New macro.
12548 (sparc64_pseudo_register_name): New function.
12549 (sparc64_register_name): Use sparc64_pseudo_register_name.
12550 (sparc64_pseudo_register_type): New function.
12551 (sparc64_register_type): Use sparc64_pseudo_register_type.
12552 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
12553 pseudo register numbers.
12554 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
12555 sparc64_store_arguments): Handle pseudo register numbers.
12557 2017-01-13 Yao Qi <yao.qi@linaro.org>
12559 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
12560 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
12562 (getpkt_or_notif_sane_1): Likewise.
12564 2017-01-13 Yao Qi <yao.qi@linaro.org>
12566 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
12567 of CC. Pass "-x c++-header" instead of "-x c".
12569 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
12571 * remote.c (remote_can_async_p): Update comment.
12573 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
12575 * linux-nat.c (linux_nat_can_async_p): Update comment.
12577 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
12579 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
12581 2017-01-11 Simon Marchi <simon.marchi@ericsson.com>
12583 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
12585 2017-01-10 Tom Tromey <tom@tromey.com>
12587 * python/py-type.c (typy_legacy_template_argument): Update.
12588 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
12589 ~demangle_parse_info): Declare new members.
12590 (cp_demangled_name_to_comp): Return unique_ptr.
12591 (cp_demangled_name_parse_free)
12592 (make_cleanup_cp_demangled_name_parse_free)
12593 (cp_new_demangle_parse_info): Remove.
12594 * cp-support.c (do_demangled_name_parse_free_cleanup)
12595 (make_cleanup_cp_demangled_name_parse_free): Remove.
12596 (inspect_type, cp_canonicalize_string_full)
12597 (cp_canonicalize_string): Update.
12598 (mangled_name_to_comp): Change return type.
12599 (cp_class_name_from_physname, method_name_from_physname)
12600 (cp_func_name, cp_remove_params): Update.
12601 * cp-name-parser.y (demangle_parse_info): New constructor, from
12602 cp_new_demangle_parse_info.
12603 (~demangle_parse_info): New destructor, from
12604 cp_demangled_name_parse_free.
12605 (cp_merge_demangle_parse_infos): Update.
12606 (cp_demangled_name_to_comp): Change return type.
12608 2017-01-10 Tom Tromey <tom@tromey.com>
12610 * top.c (prevent_dont_repeat): Change return type.
12611 * python/python.c (execute_gdb_command): Use std::string.
12613 * guile/guile.c (gdbscm_execute_gdb_command): Update.
12614 * command.h (prevent_dont_repeat): Change return type.
12615 * breakpoint.c (bpstat_do_actions_1): Update.
12617 2017-01-10 Tom Tromey <tom@tromey.com>
12619 * value.h (scoped_value_mark::~scoped_value_mark): Call
12621 (scoped_value_mark::free_to_mark): New method.
12622 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
12625 2017-01-10 Tom Tromey <tom@tromey.com>
12627 * python/py-value.c (valpy_dereference, valpy_referenced_value)
12628 (valpy_reference_value, valpy_const_value, valpy_get_address)
12629 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
12630 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
12631 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
12632 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
12634 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
12635 * value.h (scoped_value_mark): New class.
12637 2017-01-10 Tom Tromey <tom@tromey.com>
12639 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
12640 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
12641 * psymtab.c (discard_psymtabs_upto): Remove.
12642 (make_cleanup_discard_psymtabs): Remove.
12643 (struct psymtab_state): Remove.
12645 2017-01-10 Tom Tromey <tom@tromey.com>
12647 * record-full.c (record_full_save_cleanups): Remove.
12648 (record_full_save): Use gdb::unlinker.
12649 * gcore.c (do_bfd_delete_cleanup): Remove.
12650 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
12652 * dwarf2read.c (unlink_if_set): Remove.
12653 (write_psymtabs_to_index): Use gdb::unlinker.
12654 * common/gdb_unlinker.h: New file.
12656 2017-01-10 Tom Tromey <tom@tromey.com>
12658 * windows-tdep.c (windows_xfer_shared_library): Update.
12659 * windows-nat.c (windows_make_so): Update.
12660 * utils.h (make_cleanup_bfd_unref): Remove.
12661 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
12662 * symfile.h (symfile_bfd_open)
12663 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
12664 * symfile.c (read_symbols, symbol_file_add)
12665 (separate_debug_file_exists): Update.
12666 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
12667 (generic_load, reread_symbols): Update.
12668 * symfile-mem.c (symbol_file_add_from_memory): Update.
12669 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
12670 (spu_symbol_file_add_from_memory): Update.
12671 * solist.h (struct target_so_ops) <bfd_open>: Return
12673 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
12674 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
12676 (solib_map_sections, reload_shared_libraries_1): Update.
12677 * solib-svr4.c (enable_break): Update.
12678 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
12679 * solib-frv.c (enable_break2): Update.
12680 * solib-dsbt.c (enable_break): Update.
12681 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
12683 (darwin_solib_get_all_image_info_addr_at_init): Update.
12684 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
12685 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
12686 * record-full.c (record_full_save): Update.
12687 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
12688 * procfs.c (insert_dbx_link_bpt_in_file): Update.
12689 * minidebug.c (find_separate_debug_file_in_section): Return
12691 * machoread.c (macho_add_oso_symfile): Change abfd to
12693 (macho_symfile_read_all_oso): Update.
12694 (macho_check_dsym): Return gdb_bfd_ref_ptr.
12695 (macho_symfile_read): Update.
12696 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
12697 (jit_bfd_try_read_symtab): Update.
12698 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
12699 (gdb_bfd_openw, gdb_bfd_openr_iovec)
12700 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
12702 (gdb_bfd_ref_policy): New struct.
12703 (gdb_bfd_ref_ptr): New typedef.
12704 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
12705 (gdb_bfd_openw, gdb_bfd_openr_iovec)
12706 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
12708 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
12709 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
12710 (gcore_command): Update.
12711 * exec.c (exec_file_attach): Update.
12712 * elfread.c (elf_symfile_read): Update.
12713 * dwarf2read.c (dwarf2_get_dwz_file): Update.
12714 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
12715 (open_and_init_dwo_file): Update.
12716 (open_dwp_file): Return gdb_bfd_ref_ptr.
12717 (open_and_init_dwp_file): Update.
12718 * corelow.c (core_open): Update.
12719 * compile/compile-object-load.c (compile_object_load): Update.
12720 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
12721 * coffread.c (coff_symfile_read): Update.
12722 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
12723 gdb_bfd_ref_ptr. Rename.
12724 (dump_bfd_file, restore_command): Update.
12725 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
12726 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
12727 (find_separate_debug_file_by_buildid): Update.
12729 2017-01-10 Tom Tromey <tom@tromey.com>
12731 * common/gdb_ref_ptr.h: New file.
12732 * python/py-ref.h (struct gdbpy_ref_policy): New.
12733 (gdbpy_ref): Now a typedef.
12735 2017-01-10 Tom Tromey <tom@tromey.com>
12737 * utils.h (make_cleanup_htab_delete): Don't declare.
12738 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
12740 * linespec.c (decode_compound_collector): Add constructor,
12742 (lookup_prefix_sym): Remove cleanup.
12743 (symtab_collector): Add constructor, destructor.
12744 (collect_symtabs_from_filename): Remove cleanup.
12745 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
12746 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
12748 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
12749 * dwarf2read.c (dw2_expand_symtabs_matching)
12750 (dw2_map_symbol_filenames, dwarf_decode_macros)
12751 (write_psymtabs_to_index): Use htab_up.
12752 * dwarf2loc.c (func_verify_no_selftailcall)
12753 (call_site_find_chain_1, func_verify_no_selftailcall)
12754 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
12755 std::vector, gdb::unique_xmalloc_ptr.
12756 (call_sitep): Remove typedef.
12757 (dwarf2_locexpr_baton_eval): Remove unused variable.
12759 2017-01-10 Tom Tromey <tom@tromey.com>
12761 * python/python-internal.h (make_cleanup_py_decref)
12762 (make_cleanup_py_xdecref): Don't declare.
12763 * python/py-utils.c (py_decref, make_cleanup_py_decref)
12764 (py_xdecref, make_cleanup_py_xdecref): Remove.
12766 2017-01-10 Tom Tromey <tom@tromey.com>
12768 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
12769 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
12771 2017-01-10 Tom Tromey <tom@tromey.com>
12773 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
12775 2017-01-10 Tom Tromey <tom@tromey.com>
12777 * python/py-utils.c (unicode_to_encoded_string)
12778 (python_string_to_target_string)
12779 (python_string_to_target_python_string)
12780 (python_string_to_host_string, gdbpy_obj_to_string)
12781 (get_addr_from_python): Use gdbpy_ref.
12783 2017-01-10 Tom Tromey <tom@tromey.com>
12785 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
12788 2017-01-10 Tom Tromey <tom@tromey.com>
12790 * python/python.c (eval_python_command, gdbpy_decode_line)
12791 (gdbpy_run_events, gdbpy_start_type_printers)
12792 (gdbpy_apply_type_printers): Use gdbpy_ref.
12794 2017-01-10 Tom Tromey <tom@tromey.com>
12796 * python/py-param.c (get_doc_string, compute_enum_values): Use
12799 2017-01-10 Tom Tromey <tom@tromey.com>
12801 * python/py-inferior.c (find_thread_object, build_inferior_list):
12804 2017-01-10 Tom Tromey <tom@tromey.com>
12806 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
12808 2017-01-10 Tom Tromey <tom@tromey.com>
12810 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
12813 2017-01-10 Tom Tromey <tom@tromey.com>
12815 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
12817 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
12820 2017-01-10 Tom Tromey <tom@tromey.com>
12822 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
12825 2017-01-10 Tom Tromey <tom@tromey.com>
12827 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
12828 decref results of PyArg_ParseTupleAndKeywords.
12830 2017-01-10 Tom Tromey <tom@tromey.com>
12832 * python/python.c (python_run_simple_file): Use
12833 unique_xmalloc_ptr, gdbpy_ref.
12835 2017-01-10 Tom Tromey <tom@tromey.com>
12837 * python/py-prettyprint.c (print_stack_unless_memory_error)
12838 (print_string_repr, print_children): Use gdbpy_ref.
12839 (dummy_python_frame): New class.
12840 (dummy_python_frame::dummy_python_frame): Rename from
12841 push_dummy_python_frame.
12842 (py_restore_tstate): Remove.
12844 2017-01-10 Tom Tromey <tom@tromey.com>
12846 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
12848 2017-01-10 Tom Tromey <tom@tromey.com>
12850 * python/python.c (ensure_python_env, restore_python_env):
12852 * python/python-internal.h (ensure_python_env): Don't declare.
12853 * varobj.h (varobj_ensure_python_env): Don't declare.
12854 * varobj.c (varobj_ensure_python_env): Remove.
12856 2017-01-10 Tom Tromey <tom@tromey.com>
12858 * varobj.c (varobj_value_get_print_value): Use
12859 gdbpy_enter_varobj.
12861 2017-01-10 Tom Tromey <tom@tromey.com>
12863 * python/py-prettyprint.c (print_string_repr, print_children):
12865 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
12867 * varobj.c (varobj_value_get_print_value): Update.
12868 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
12870 2017-01-10 Tom Tromey <tom@tromey.com>
12872 * varobj.c (varobj_get_display_hint)
12873 (dynamic_varobj_has_child_method, install_new_value_visualizer)
12874 (varobj_set_visualizer, free_variable): Use
12875 gdbpy_enter_varobj.
12877 2017-01-10 Tom Tromey <tom@tromey.com>
12879 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
12880 (do_finish_initialization): New function. Use gdbpy_ref.
12881 (gdbpy_finish_initialization): Use gdbpy_enter. Call
12882 do_finish_initialization.
12884 2017-01-10 Tom Tromey <tom@tromey.com>
12886 * python/py-param.c (get_set_value, get_show_value): Use
12887 gdbpy_enter, gdbpy_ref.
12889 2017-01-10 Tom Tromey <tom@tromey.com>
12891 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
12893 2017-01-10 Tom Tromey <tom@tromey.com>
12895 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
12897 2017-01-10 Tom Tromey <tom@tromey.com>
12899 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
12900 Use gdbpy_enter_varobj.
12902 2017-01-10 Tom Tromey <tom@tromey.com>
12904 * varobj.c (gdbpy_enter_varobj): New constructor.
12905 * python/python-internal.h (gdbpy_enter_varobj): New class.
12906 * python/py-varobj.c (py_varobj_get_iterator): Use
12907 gdbpy_enter_varobj.
12909 2017-01-10 Tom Tromey <tom@tromey.com>
12911 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
12912 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
12913 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
12914 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
12915 unique_xmalloc_ptr.
12916 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
12918 2017-01-10 Tom Tromey <tom@tromey.com>
12920 * python/py-xmethods.c (invoke_match_method): Use
12923 2017-01-10 Tom Tromey <tom@tromey.com>
12925 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
12926 gdbpy_enter, gdbpy_ref.
12928 2017-01-10 Tom Tromey <tom@tromey.com>
12930 * python/python.c (python_interactive_command): Use gdbpy_enter.
12932 2017-01-10 Tom Tromey <tom@tromey.com>
12934 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
12937 2017-01-10 Tom Tromey <tom@tromey.com>
12939 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
12940 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
12942 2017-01-10 Tom Tromey <tom@tromey.com>
12944 * utils.h (htab_deleter): New struct.
12945 (htab_up): New typedef.
12946 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
12947 gdbpy_enter, gdbpy_ref, htab_up.
12949 2017-01-10 Tom Tromey <tom@tromey.com>
12951 * python/py-unwind.c (pending_frame_invalidate): Remove.
12952 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
12954 2017-01-10 Tom Tromey <tom@tromey.com>
12956 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
12957 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
12959 2017-01-10 Tom Tromey <tom@tromey.com>
12961 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
12963 2017-01-10 Tom Tromey <tom@tromey.com>
12965 * python/python.c (gdbpy_eval_from_control_command)
12966 (gdbpy_source_script, gdbpy_run_events)
12967 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
12968 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
12971 2017-01-10 Tom Tromey <tom@tromey.com>
12973 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
12975 2017-01-10 Tom Tromey <tom@tromey.com>
12977 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
12979 2017-01-10 Tom Tromey <tom@tromey.com>
12981 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
12982 (python_on_inferior_call_pre, python_on_inferior_call_post)
12983 (python_on_memory_change, python_on_register_change)
12984 (python_inferior_exit, python_new_objfile, add_thread_object)
12985 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
12987 2017-01-10 Tom Tromey <tom@tromey.com>
12989 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
12990 (bpfinishpy_handle_exit): Use gdbpy_enter.
12992 2017-01-10 Tom Tromey <tom@tromey.com>
12994 * python/py-cmd.c (cmdpy_destroyer)
12995 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
12998 2017-01-10 Tom Tromey <tom@tromey.com>
13000 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
13002 (gdbpy_breakpoint_has_cond): Likewise.
13004 2017-01-10 Tom Tromey <tom@tromey.com>
13006 * python/python.c (gdbpy_enter): New constructor.
13007 (~gdbpy_enter): New destructor.
13008 (restore_python_env, ensure_python_env): Rewrite.
13009 * python/python-internal.h (gdbpy_enter): New class.
13011 2017-01-10 Tom Tromey <tom@tromey.com>
13013 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
13015 2017-01-10 Tom Tromey <tom@tromey.com>
13017 * python/py-value.c (value_has_field, get_field_flag)
13018 (get_field_type, valpy_getitem, convert_value_from_python): Use
13021 2017-01-10 Tom Tromey <tom@tromey.com>
13023 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
13026 2017-01-10 Tom Tromey <tom@tromey.com>
13028 * python/py-prettyprint.c (search_pp_list)
13029 (find_pretty_printer_from_objfiles)
13030 (find_pretty_printer_from_progspace)
13031 (find_pretty_printer_from_gdb, find_pretty_printer)
13032 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
13035 2017-01-10 Tom Tromey <tom@tromey.com>
13037 * python/py-param.c (call_doc_function): Use gdbpy_ref.
13039 2017-01-10 Tom Tromey <tom@tromey.com>
13041 * python/py-linetable.c (build_line_table_tuple_from_pcs)
13042 (ltpy_get_all_source_lines): Use gdbpy_ref.
13044 2017-01-10 Tom Tromey <tom@tromey.com>
13046 * python/py-framefilter.c (extract_sym, extract_value)
13047 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
13050 2017-01-10 Tom Tromey <tom@tromey.com>
13052 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
13054 2017-01-10 Tom Tromey <tom@tromey.com>
13056 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
13058 2017-01-10 Tom Tromey <tom@tromey.com>
13060 * python/py-function.c (convert_values_to_python, fnpy_init): Use
13063 2017-01-10 Tom Tromey <tom@tromey.com>
13065 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
13067 2017-01-10 Tom Tromey <tom@tromey.com>
13069 * python/py-type.c (convert_field, make_fielditem, typy_fields)
13070 (typy_range): Use gdbpy_ref.
13072 2017-01-10 Tom Tromey <tom@tromey.com>
13074 * python/py-threadevent.c (create_thread_event_object): Use
13076 * python/py-stopevent.c (create_stop_event_object): Simplify.
13077 (emit_stop_event): Use gdbpy_ref.
13078 * python/py-signalevent.c (create_signal_event_object): Use
13080 * python/py-newobjfileevent.c (create_new_objfile_event_object)
13081 (emit_new_objfile_event, create_clear_objfiles_event_object)
13082 (emit_clear_objfiles_event): Use gdbpy_ref.
13083 * python/py-infevents.c (create_inferior_call_event_object)
13084 (create_register_changed_event_object)
13085 (create_memory_changed_event_object, emit_inferior_call_event)
13086 (emit_memory_changed_event, emit_register_changed_event): Use
13088 * python/py-exitedevent.c (create_exited_event_object)
13089 (emit_exited_event): Use gdbpy_ref.
13090 * python/py-event.h (evpy_emit_event): Remove
13091 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
13092 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
13093 * python/py-continueevent.c (emit_continue_event): Use
13095 * python/py-breakpoint.c (gdbpy_breakpoint_created)
13096 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
13098 * python/py-bpevent.c (create_breakpoint_event_object): Use
13101 2017-01-10 Tom Tromey <tom@tromey.com>
13103 * python/py-ref.h: New file.
13105 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
13107 * cli-out.c (cli_ui_out::do_redirect): Change return type to
13109 * cli-out.h (cli_ui_out::do_redirect): Likewise.
13110 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
13111 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
13112 * ui-out.c (ui_out::redirect): Likewise.
13113 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
13114 * cli/cli-logging.c (set_logging_redirect): Update call site of
13116 (handle_redirections): Likewise.
13117 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
13118 * top.c (execute_command_to_string): Likewise.
13119 * utils.c (do_ui_out_redirect_pop): Likewise.
13121 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
13123 * stack.c (_initialize_stack): Update "frame" command help message.
13125 2017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
13127 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
13129 2017-01-06 Yao Qi <yao.qi@linaro.org>
13131 * x86-linux-nat.h: Include gdb_proc_service.h.
13133 2017-01-06 Yao Qi <yao.qi@linaro.org>
13135 * ser-base.h: Include serial.h.
13137 2017-01-06 Yao Qi <yao.qi@linaro.org>
13139 * ppc-linux-tdep.h: Include ppc-tdep.h.
13141 2017-01-06 Yao Qi <yao.qi@linaro.org>
13143 * nat/amd64-linux-siginfo.h: Include signal.h.
13145 2017-01-06 Yao Qi <yao.qi@linaro.org>
13147 * nat/aarch64-linux-hw-point.h: Include break-common.h.
13149 2017-01-06 Yao Qi <yao.qi@linaro.org>
13151 * mi/mi-parse.h: Include mi-cmds.h.
13153 2017-01-06 Yao Qi <yao.qi@linaro.org>
13155 * inf-loop.c: Don't include "target.h".
13156 * inf-loop.h: Include it here.
13158 2017-01-06 Yao Qi <yao.qi@linaro.org>
13160 * dfp.h: Include "dboulest.h" and "expression.h".
13162 2017-01-06 Yao Qi <yao.qi@linaro.org>
13164 * ax-gdb.h: Include "ax.h".
13166 2017-01-06 Yao Qi <yao.qi@linaro.org>
13168 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
13169 with nat/gdb_ptrace.h.
13171 2017-01-05 Yao Qi <yao.qi@linaro.org>
13173 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
13175 (mips64_fbsd_sigframe_init): Likewise.
13177 2017-01-04 John Baldwin <jhb@FreeBSD.org>
13179 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
13180 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
13182 2017-01-04 John Baldwin <jhb@FreeBSD.org>
13184 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
13185 * NEWS: Mention new FreeBSD/mips native configuration.
13186 * config/mips/fbsd.mh: New file.
13187 * configure.host: Add mips*-*-freebsd*.
13188 * mips-fbsd-nat.c: New file.
13190 2017-01-04 John Baldwin <jhb@FreeBSD.org>
13192 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
13193 (ALLDEPFILES): Add mips-fbsd-tdep.c.
13194 * NEWS: Mention new FreeBSD/mips target.
13195 * configure.tgt: Add mips*-*-freebsd*.
13196 * mips-fbsd-tdep.c: New file.
13197 * mips-fbsd-tdep.h: New file.
13199 2017-01-04 Yao Qi <yao.qi@linaro.org>
13201 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
13202 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
13204 2017-01-01 Joel Brobecker <brobecker@adacore.com>
13206 Update copyright year range in all GDB files.
13208 2017-01-01 Joel Brobecker <brobecker@adacore.com>
13210 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
13212 For older changes see ChangeLog-2016.
13218 version-control: never