]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - gdb/ChangeLog
Use gdb::byte_vector in ppc-linux-tdep.c
[thirdparty/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
779bc38e
TT
12017-11-04 Tom Tromey <tom@tromey.com>
2
3 * ppc-linux-tdep.c (ppc_linux_get_syscall_number): Use
4 gdb::byte_vector.
5
ed2b3126
TT
62017-11-04 Tom Tromey <tom@tromey.com>
7
8 * objfiles.c (do_free_objfile_cleanup): Remove.
9 * compile/compile-object-load.c (compile_object_load): Update.
10 * objfiles.h (make_cleanup_free_objfile): Remove.
11
7f6743fd
TT
122017-11-04 Tom Tromey <tom@tromey.com>
13
14 * sparc64-tdep.c (do_examine): Use gdb::def_vector.
15 (adi_read_versions): Change "tags" to "gdb_byte *".
16 (adi_print_versions): Likewise.
17
c80049d3
TT
182017-11-04 Tom Tromey <tom@tromey.com>
19
20 * breakpoint.c
21 (scoped_rbreak_breakpoints::scoped_rbreak_breakpoints): Rename
22 from start_rbreak_breakpoints.
23 (scoped_rbreak_breakpoints): Rename from end_rbreak_breakpoints.
24 * breakpoint.h (class scoped_rbreak_breakpoints): New.
25 (start_rbreak_breakpoints, end_rbreak_breakpoints): Remove.
26 * symtab.c (do_end_rbreak_breakpoints): Remove.
27 (rbreak_command): Use scoped_rbreak_breakpoints, std::string.
28
167b0be1
TT
292017-11-04 Tom Tromey <tom@tromey.com>
30
31 * cp-namespace.c (reset_directive_searched): Remove.
32 (cp_lookup_symbol_via_imports): Use scoped_restore.
33 * cp-support.c (reset_directive_searched): Remove.
34 (make_symbol_overload_list_using): Use scoped_restore.
35 * d-namespace.c (d_lookup_symbol_imports): Use scoped_restore.
36 (reset_directive_searched): Remove.
37
5eae7aea
TT
382017-11-04 Tom Tromey <tom@tromey.com>
39
40 * symfile.c (find_separate_debug_file_by_debuglink): Use
41 unique_xmalloc_ptr.
42
c6bcad5f
TT
432017-11-04 Tom Tromey <tom@tromey.com>
44
45 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
46 type of "info".
47 (compute_stack_depth): Likewise.
48 (do_compile_dwarf_expr_to_c): Use std::vector.
49
20dcd8ca
TT
502017-11-04 Tom Tromey <tom@tromey.com>
51
52 * compile/compile-object-load.c (link_callbacks_einfo): Use
53 std::string.
54
33c7c59d
TT
552017-11-04 Tom Tromey <tom@tromey.com>
56
57 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
58 Use scoped_free_pendings.
59 * dbxread.c (dbx_symfile_read, dbx_psymtab_to_symtab_1): Use
60 scoped_free_pendings.
61 * xcoffread.c (xcoff_psymtab_to_symtab_1): Use scoped_free_pendings.
62 (xcoff_initial_scan): Likewise.
63 * buildsym.c (reset_symtab_globals): Update comment.
64 (scoped_free_pendings): Rename from really_free_pendings.
65 (prepare_for_building): Update comment.
66 (buildsym_init): Likewise.
67 * buildsym.h (class scoped_free_pendings): New class.
68 (really_free_pendings): Don't declare.
69
67fa57cf
UW
702017-11-03 Ulrich Weigand <uweigand@de.ibm.com>
71
72 * doublest.c (convert_doublest_to_floatformat): Fix uninitialized
73 output when converting a zero value to a special byteorder format.
74
f26ae15b
YQ
752017-11-02 Yao Qi <yao.qi@linaro.org>
76
77 * frame.c (do_frame_register_read): Remove aspace.
78 * jit.c (jit_frame_sniffer): Likwise.
79 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
80 * regcache.c (regcache::regcache): Pass nullptr.
81 (regcache_print): Caller updated.
82 * regcache.h (regcache::regcache): Remove one constructor
83 parameter aspace.
84
6c6e9412
YQ
852017-11-02 Yao Qi <yao.qi@linaro.org>
86
87 * regcache.h (regcache) <m_readonly_p>: Change it to const bool.
88
8b86c959
YQ
892017-11-02 Yao Qi <yao.qi@linaro.org>
90
91 * breakpoint.c (insert_single_step_breakpoints): Update.
92 * frame.c (struct frame_info) <aspace>: Add const.
93 (frame_save_as_regcache): Add const.
94 (get_frame_address_space): Return const address_space *.
95 * frame.h (get_frame_address_space): Update declaration.
96 * infrun.c (struct step_over_info) <aspace>: Add const.
97 (set_step_over_info): Make aspace const.
98 (displaced_step_prepare_throw): Change variable const.
99 (resume): Likewise.
100 (proceed): Likewise.
101 (adjust_pc_after_break): Likewise.
102 (save_waitstatus): Likewise.
103 (handle_signal_stop): Likewise.
104 (keep_going_pass_signal): Likewise.
105 * jit.c (jit_frame_sniffer): Add const.
106 * mips-tdep.c (mips_single_step_through_delay): Likewise.
107 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
108 * record-full.c (record_full_wait_1): Likewise.
109 * regcache.c (regcache::regcache): Change parameter to const.
110 * regcache.h (regcache::regcache): Likewise.
111 (regcache::aspace): Return const address_space *.
112 (regcache) <m_aspace>: Add const.
113
a01bda52
YQ
1142017-11-02 Yao Qi <yao.qi@linaro.org>
115
116 * darwin-nat.c (cancel_breakpoint): Use regcache->aspace ().
117 * frame.c (create_sentinel_frame): Likewise.
118 * infrun.c (displaced_step_prepare_throw): Likewise.
119 (resume): Likewise.
120 (thread_still_needs_step_over_bp): Likewise.
121 (proceed): Likewise.
122 (do_target_wait): Likewise.
123 (adjust_pc_after_break): Likewise.
124 (handle_syscall_event): Likewise.
125 (save_waitstatus): Likewise.
126 (handle_inferior_event_1): Likewise.
127 (handle_signal_stop): Likewise.
128 (keep_going_pass_signal): Likewise.
129 * linux-nat.c (status_callback): Likewise.
130 (save_stop_reason): Likewise.
131 (resume_stopped_resumed_lwps): Likewise.
132 * record-full.c (record_full_exec_insn): Likewise.
133 (record_full_wait_1): Likewise.
134 * regcache.c (get_regcache_aspace): Remove.
135 * regcache.h (get_regcache_aspace): Remove.
136
d999647b
YQ
1372017-11-02 Yao Qi <yao.qi@linaro.org>
138
139 * regcache.c (struct regcache_descr) <nr_raw_registers>: Remove.
140 (init_regcache_descr): Use gdbarch_num_regs.
141 (regcache::regcache): Likewise.
142 (regcache::get_register_status): Likewise.
143 (regcache::assert_raw_regnum): Likewise.
144 (regcache::cooked_read): Likewise.
145 (regcache::cooked_read_value): Likewise.
146 (regcache::cooked_write): Likewise.
147 (regcache::dump): Likewise.
148 (regcache::num_raw_registers): New method.
149 * regcache.h (class regcache) <num_raw_registers>: New.
150
4e888c28
YQ
1512017-11-02 Yao Qi <yao.qi@linaro.org>
152
153 * regcache.c (regcache::assert_regnum): New method.
154 (regcache::invalidate): Call assert_regnum.
155 (regcache::raw_update): Likewise.
156 (regcache::raw_write): Likewise.
157 (regcache::raw_read_part): Likewise.
158 (regcache::raw_write_part): Likewise.
159 (regcache::raw_supply): Likewise.
160 (regcache::raw_supply_integer): Likewise.
161 (regcache::raw_supply_zeroed): Likewise.
162 (regcache::raw_collect): Likewise.
163 (regcache::raw_collect_integer): Likewise.
164 * regcache.h (regcache::assert_regnum): Declare.
165
2e1b49b3
YQ
1662017-11-02 Yao Qi <yao.qi@linaro.org>
167
168 * regcache.c (regcache::dump): Remove code.
169
6c5218df
YQ
1702017-11-02 Yao Qi <yao.qi@linaro.org>
171
172 * regcache.c (struct regcache_descr) <sizeof_raw_register_status>:
173 Remove.
174 <sizeof_cooked_register_status>: Remove.
175 (init_regcache_descr): Update.
176 (regcache::regcache): Use nr_cooked_registers and nr_raw_registers.
177 (regcache::save): Likewise.
178 (regcache::dump): Likewise.
179
dcc31d28
JB
1802017-11-01 James Bowman <james.bowman@ftdichip.com>
181
182 * ft32-tdep.c (ft32_fetch_instruction): New function.
183 (ft32_analyze_prologue): Use ft32_fetch_instruction().
184
3a87ae65
SM
1852017-10-31 Simon Marchi <simon.marchi@polymtl.ca>
186
187 * cli/cli-script.c (execute_control_command): Rename to ...
188 (execute_control_command_1): ... this.
189 (execute_control_command): New function.
190
09b847f3
SM
1912017-10-31 Simon Marchi <simon.marchi@ericsson.com>
192
193 * tracepoint.c (tfind_command): Remove const_cast.
194
f871c485
MG
1952017-10-30 Mike Gulick <mgulick@mathworks.com>
196
197 * Makefile.in (HFILES_NO_SRCDIR): Remove reference to gdb.h.
198
b020ff80
SM
1992017-10-30 Simon Marchi <simon.marchi@ericsson.com>
200
201 * common/common-utils.h (in_inclusive_range): New function.
202 * arm-tdep.c (arm_record_extension_space): Use
203 in_inclusive_range.
204 (thumb_record_ld_st_reg_offset): Use in_inclusive_range.
205 * cris-tdep.c (cris_spec_reg_applicable): Use
206 in_inclusive_range.
207
1b81856f
PA
2082017-10-30 Pedro Alves <palves@redhat.com>
209 Simon Marchi <simon.marchi@ericsson.com>
210
211 * remote.c (remote_set_syscall_catchpoint): Build a std::string
212 instead of a gdb::unique_xmalloc_ptr, using string_appendf.
213
31b833b3
PA
2142017-10-30 Pedro Alves <palves@redhat.com>
215
216 * common/common-utils.c (string_appendf, string_vappendf): New
217 functions.
218 * common/common-utils.h (string_appendf, string_vappendf): New
219 declarations.
220 * unittests/common-utils-selftests.c (string_appendf_func)
221 (test_appendf_func, string_vappendf_wrapper, string_appendf_tests)
222 (string_vappendf_tests): New functions.
223 (_initialize_common_utils_selftests): Register "string_appendf" and
224 "string_vappendf tests".
225
4a250334
PA
2262017-10-30 Pedro Alves <palves@redhat.com>
227
228 * unittests/common-utils-selftests.c (format_func): New typedef.
229 (string_printf_tests, string_vprintf_tests): Tests factored out
230 and merged to ...
231 (test_format_func): ... this new function.
232 (string_printf_tests, string_vprintf_tests): Reimplement on top of
233 test_format_func.
234
16c5c17e
SM
2352017-10-29 Simon Marchi <simon.marchi@ericsson.com>
236
237 * darwin-nat.c: Remove include of gdb.h.
238
7ca51576
SM
2392017-10-29 Simon Marchi <simon.marchi@ericsson.com>
240
241 * xtensa-xtregs.c: Fix formatting issues.
242
c1342859
SM
2432017-10-29 Simon Marchi <simon.marchi@ericsson.com>
244
245 * xtensa-xtregs.c (xtensa_regtable_t) <name>: Constify.
246
484d8d36
MD
2472017-10-28 Maksim Dzabraev <dzabraew@gmail.com>
248
249 PR python/21213
250 * python/py-infthread.c (thpy_get_inferior): Increment reference
251 of inferior before returning it.
252
b5540b5f
SM
2532017-10-27 Simon Marchi <simon.marchi@ericsson.com>
254
255 * unittests/common-utils-selftests.c (format): Add
256 ATTRIBUTE_PRINTF.
257
5a9dcda1
SM
2582017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
259
260 * xml-syscall.c (struct syscall_desc): Add constructor.
261 <name>: Change type to std::string.
262 (syscall_desc_up): New typedef.
263 (syscall_desc_p): Remove typeder.
264 (DEF_VEC_P(syscall_desc_p)): Remove.
265 (struct syscall_group_desc): Add constructor.
266 <name>: Change type to std::string.
267 <syscalls>: Change type to std::vector.
268 (syscall_group_desc_up): New typedef.
269 (syscall_group_desc_p): Remove typedef.
270 (DEF_VEC_P(syscall_group_desc_p)): Remove.
271 (struct syscalls_info) <syscalls>: Change type to std::vector of
272 unique_ptr.
273 <groups>: Likewise.
274 <my_gdb_datadir>: Change type to std::string.
275 (syscalls_info_up): New typedef.
276 (allocate_syscalls_info): Remove.
277 (syscalls_info_free_syscalls_desc): Remove.
278 (syscalls_info_free_syscall_group_desc): Remove.
279 (free_syscalls_info): Remove.
280 (make_cleanup_free_syscalls_info): Remove.
281 (syscall_group_create_syscall_group_desc): Adjust.
282 (syscall_group_add_syscall): Adjust.
283 (syscall_create_syscall_desc): Adjust.
284 (syscall_parse_xml): Adjust, use unique_ptr instead of cleanup.
285 (init_syscalls_info): Adjust.
286 (syscall_group_get_group_by_name): Adjust.
287 (xml_get_syscall_number): Adjust.
288 (xml_get_syscall_name): Adjust.
289 (xml_list_of_syscalls): Adjust.
290 (xml_list_syscalls_by_group): Adjust.
291 (xml_list_of_groups): Adjust.
292
45461e0d
SM
2932017-10-27 Simon Marchi <simon.marchi@ericsson.com>
294
295 * probe.h: Don't include gdb_vecs.h.
296 (DEF_VEC_P (probe_p)): Remove.
297 (find_probes_in_objfile): Return an std::vector.
298 * probe.c (find_probes_in_objfile): Likewise.
299 * breakpoint.c (breakpoint_objfile_data)
300 <longjmp_probes>: Change type to std::vector.
301 <exception_probes>: Likewise.
302 (free_breakpoint_probes): Don't manually free vectors.
303 (create_longjmp_master_breakpoint): Adjust.
304 (create_exception_master_breakpoint): Adjust.
305 * solib-svr4.c (svr4_create_probe_breakpoints): Change
306 parameter type, adjust.
307 (svr4_create_solib_event_breakpoints): Adjust.
308
43dce439
SM
3092017-10-27 Simon Marchi <simon.marchi@ericsson.com>
310
311 * breakpoint.c (breakpoint_objfile_data): Initialize fields.
312 (get_breakpoint_objfile_data): Allocate breakpoint_objfile_data
313 with new.
314 (free_breakpoint_probes): Rename to ...
315 (free_breakpoint_objfile_data): ... this, and call delete on
316 bp_objfile_data..
317
6a1b9516
SM
3182017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
319
320 * auto-load.c: Don't include gdb_vecs.h, include algorithm.
321 (loaded_script_ptr): Remove typedef.
322 (DEF_VEC_P (loaded_script_ptr)): Remove.
323 (struct collect_matching_scripts_data): Add constructor.
324 <scripts_p>: Change type to (pointer to) std::vector.
325 (collect_matching_scripts_data): Adjust.
326 (sort_scripts_by_name): Make suitable for std::sort.
327 (print_scripts): Don't sort vector, adjust to std::vector.
328 (auto_load_info_scripts): Sort vectors, adjust to std::vector.
329
593e3209
SM
3302017-10-27 Simon Marchi <simon.marchi@ericsson.com>
331
332 * symfile.c (filename_language): Make struct, not typedef. Add
333 constructor.
334 <ext>: Change type to std::string.
335 (DEF_VEC_O (filename_language)): Remove.
336 (filename_language_table): Change type to std::vector.
337 (add_filename_language): Adjust.
338 (set_ext_lang_command): Adjust.
339 (info_ext_lang_command): Adjust.
340 (deduce_language_from_filename): Adjust.
341 (class scoped_restore_filename_language_table): Remove.
342 (test_filename_language): Use scoped_restore.
343 (test_set_ext_lang_command): Use scoped_restore, adjust to
344 std::vector change.
345
32fa66eb
SM
3462017-10-27 Simon Marchi <simon.marchi@ericsson.com>
347
348 * symfile.c: Include selftest.h.
349 (class scoped_restore_filename_language_table): New.
350 (test_filename_language): New test.
351 (test_set_ext_lang_command): New test.
352 (_initialize_symfile): Register tests.
353
4a27f119
KS
3542017-10-27 Keith Seitz <keiths@redhat.com>
355
356 * breakpoint.c (print_breakpoint_location): Use the symbol saved
357 in the bp_location, falling back to find_pc_sect_function when
358 needed.
359 (add_location_to_breakpoint): Save sal->symbol.
360 * breakpoint.h (struct bp_location) <symbol>: New field.
361 * symtab.c (find_function_start_sal): Save the symbol into the SaL.
362 * symtab.h (struct symtab_and_line) <symbol>: New field.
363
a43f3893
PF
3642017-10-26 Patrick Frants <osscontribute@gmail.com>
365
7453e6b2 366 PR gdb/13669
a43f3893
PF
367 * cp-valprint.c (cp_print_value_fields): Use obstack_blank_fast
368 to rewind obstack.
369
23cc4e1b
PA
3702017-10-26 Pedro Alves <palves@redhat.com>
371
372 * remote.c (remote_async_terminal_ours_p): Delete.
373 (remote_open_1, remote_terminal_inferior, remote_terminal_ours):
374 Remove references to 'remote_async_terminal_ours_p'.
375
6abc18bb
YQ
3762017-10-26 Yao Qi <yao.qi@linaro.org>
377
378 * breakpoint.h (regular_breakpoint_inserted_here_p): Remove.
379
bd522513
YQ
3802017-10-26 Yao Qi <yao.qi@linaro.org>
381
382 * break-catch-sig.c (signal_catchpoint_breakpoint_hit): Make
383 aspace const.
384 * break-catch-syscall.c (breakpoint_hit_catch_syscall):
385 Likewise.
386 * breakpoint.c (bpstat_check_location): Remove cast.
387 (breakpoint_hit_catch_fork): Make aspce const.
388 (breakpoint_hit_catch_solib): Likewise.
389 (breakpoint_hit_catch_exec): Likewise.
390 (breakpoint_hit_ranged_breakpoint): Likewise.
391 (breakpoint_hit_watchpoint): Likewise.
392 (base_breakpoint_breakpoint_hit): Likewise.
393 (bkpt_breakpoint_hit): Likewise.
394 (dprintf_breakpoint_hit): Likewise.
395 (tracepoint_breakpoint_hit): Likewise.
396 * breakpoint.h (breakpoint_ops) <breakpoint_hit>: Likewise.
397
accd0bcd
YQ
3982017-10-26 Yao Qi <yao.qi@linaro.org>
399
400 * breakpoint.c (breakpoint_location_address_match): Change
401 "struct address_space *" to "const address_space".
402 (breakpoint_location_address_range_overlap): Likewise.
403 (breakpoint_here_p): Likewise.
404 (breakpoint_in_range_p): Likewise.
405 (moribund_breakpoint_here_p): Likewise.
406 (bp_location_inserted_here_p): Likewise.
407 (software_breakpoint_inserted_here_p): Likewise.
408 (hardware_breakpoint_inserted_here_p): Likewise.
409 (hardware_watchpoint_inserted_in_range): Likewise.
410 (bpstat_check_location): Likewise.
411 (bpstat_stop_status): Likewise.
412 (breakpoint_address_match): Likewise.
413 (breakpoint_address_match_range): Likewise.
414 (breakpoint_location_address_match): Likewise.
415 (breakpoint_location_address_range_overlap): Likewise.
416 (insert_single_step_breakpoint): Likewise.
417 (breakpoint_has_location_inserted_here): Likewise.
418 (single_step_breakpoint_inserted_here_p): Likewise.
419 (pc_at_non_inline_function): Likewise.
420 * breakpoint.h (bpstat_stop_status): Update declaration.
421 (breakpoint_here_p): Likewise.
422 (breakpoint_in_range_p): Likewise.
423 (moribund_breakpoint_here_p): Likewise.
424 (breakpoint_inserted_here_p): Likewise.
425 (software_breakpoint_inserted_here_p): Likewise.
426 (hardware_breakpoint_inserted_here_p): Likewise.
427 (breakpoint_has_location_inserted_here): Likewise.
428 (single_step_breakpoint_inserted_here_p): Likewise.
429 (hardware_watchpoint_inserted_in_range): Likewise.
430 (breakpoint_address_match): Likewise.
431 (insert_single_step_breakpoint): Likewise.
432 (pc_at_non_inline_function): Likewise.
433 * gdbthread.h (thread_has_single_step_breakpoint_here): Likewise.
434 * record.c (record_check_stopped_by_breakpoint): Likewise.
435 * record.h (record_check_stopped_by_breakpoint): Likewise.
436 * thread.c (thread_has_single_step_breakpoint_here): Likewise.
437
ac7936df
YQ
4382017-10-25 Yao Qi <yao.qi@linaro.org>
439
440 * aarch32-linux-nat.c (aarch32_gp_regcache_supply): Use
441 regcache->arch () instead get_regcache_arch.
442 * aarch64-fbsd-nat.c (aarch64_fbsd_fetch_inferior_registers):
443 Likewise.
444 (aarch64_fbsd_store_inferior_registers): Likewise.
445 * aarch64-linux-nat.c (fetch_gregs_from_thread): Likewise.
446 (store_gregs_to_thread): Likewise.
447 (fetch_fpregs_from_thread): Likewise.
448 (store_fpregs_to_thread): Likewise.
449 * aarch64-tdep.c (aarch64_extract_return_value): Likewise.
450 (aarch64_store_return_value): Likewise.
451 (aarch64_software_single_step): Likewise.
452 * aix-thread.c (aix_thread_wait): Likewise.
453 (supply_reg32): Likewise.
454 (supply_sprs64): Likewise.
455 (supply_sprs32): Likewise.
456 (fill_gprs64): Likewise.
457 (fill_gprs32): Likewise.
458 (fill_sprs64): Likewise.
459 (fill_sprs32): Likewise.
460 (store_regs_user_thread): Likewise.
461 (store_regs_kernel_thread): Likewise.
462 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers): Likewise.
463 (alphabsd_store_inferior_registers): Likewise.
464 * alpha-tdep.c (alpha_extract_return_value): Likewise.
465 (alpha_store_return_value): Likewise.
466 (alpha_deal_with_atomic_sequence): Likewise.
467 (alpha_next_pc): Likewise.
468 (alpha_software_single_step): Likewise.
469 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Likewise.
470 (amd64bsd_store_inferior_registers): Likewise.
471 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers):
472 Likewise.
473 (amd64_linux_store_inferior_registers): Likewise.
474 * amd64-nat.c (amd64_supply_native_gregset): Likewise.
475 (amd64_collect_native_gregset): Likewise.
476 * amd64-obsd-tdep.c (amd64obsd_supply_uthread): Likewise.
477 (amd64obsd_collect_uthread): Likewise.
478 * amd64-tdep.c (amd64_supply_fpregset): Likewise.
479 (amd64_collect_fpregset): Likewise.
480 (amd64_supply_fxsave): Likewise.
481 (amd64_supply_xsave): Likewise.
482 (amd64_collect_fxsave): Likewise.
483 (amd64_collect_xsave): Likewise.
484 * arc-tdep.c (arc_write_pc): Likewise.
485 * arch-utils.c (default_skip_permanent_breakpoint): Likewise.
486 * arm-fbsd-nat.c (arm_fbsd_fetch_inferior_registers): Likewise.
487 (arm_fbsd_store_inferior_registers): Likewise.
488 * arm-linux-nat.c (fetch_vfp_regs): Likewise.
489 (store_vfp_regs): Likewise.
490 (arm_linux_fetch_inferior_registers): Likewise.
491 (arm_linux_store_inferior_registers): Likewise.
492 * arm-linux-tdep.c (arm_linux_supply_gregset): Likewise.
493 (arm_linux_sigreturn_next_pc): Likewise.
494 (arm_linux_get_next_pcs_syscall_next_pc): Likewise.
495 * arm-nbsd-nat.c (arm_supply_gregset): Likewise.
496 (fetch_register): Likewise.
497 (store_register): Likewise.
498 * arm-tdep.c (arm_is_thumb): Likewise.
499 (displaced_in_arm_mode): Likewise.
500 (bx_write_pc): Likewise.
501 (arm_get_next_pcs_addr_bits_remove): Likewise.
502 (arm_software_single_step): Likewise.
503 (arm_extract_return_value): Likewise.
504 (arm_store_return_value): Likewise.
505 (arm_write_pc): Likewise.
506 * bfin-tdep.c (bfin_extract_return_value): Likewise.
507 * bsd-uthread.c (bsd_uthread_fetch_registers): Likewise.
508 (bsd_uthread_store_registers): Likewise.
509 * core-regset.c (fetch_core_registers): Likewise.
510 * corelow.c (get_core_registers): Likewise.
511 * cris-tdep.c (cris_store_return_value): Likewise.
512 (cris_extract_return_value): Likewise.
513 (find_step_target): Likewise.
514 (find_step_target): Likewise.
515 (cris_software_single_step): Likewise.
516 * ctf.c (ctf_fetch_registers): Likewise.
517 * darwin-nat.c (cancel_breakpoint): Likewise.
518 * fbsd-tdep.c (fbsd_collect_thread_registers): Likewise.
519 * frv-tdep.c (frv_extract_return_value): Likewise.
520 * ft32-tdep.c (ft32_store_return_value): Likewise.
521 (ft32_extract_return_value): Likewise.
522 * go32-nat.c (fetch_register): Likewise.
523 (go32_fetch_registers): Likewise.
524 (go32_store_registers): Likewise.
525 (store_register): Likewise.
526 * h8300-tdep.c (h8300_extract_return_value): Likewise.
527 (h8300_store_return_value): Likewise.
528 * hppa-linux-nat.c (fetch_register): Likewise.
529 (store_register): Likewise.
530 (hppa_linux_fetch_inferior_registers): Likewise.
531 (hppa_linux_store_inferior_registers): Likewise.
532 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers): Likewise.
533 (i386_darwin_store_inferior_registers): Likewise.
534 * i386-gnu-nat.c (gnu_fetch_registers): Likewise.
535 (gnu_store_registers): Likewise.
536 * i386-linux-nat.c (fetch_register): Likewise.
537 (store_register): Likewise.
538 (supply_gregset): Likewise.
539 (fill_gregset): Likewise.
540 (i386_linux_fetch_inferior_registers): Likewise.
541 (i386_linux_store_inferior_registers): Likewise.
542 (i386_linux_resume): Likewise.
543 * i386-linux-tdep.c (i386_linux_get_syscall_number_from_regcache):
544 Likewise.
545 * i386-nto-tdep.c (i386nto_supply_gregset): Likewise.
546 * i386-obsd-nat.c (i386obsd_supply_pcb): Likewise.
547 * i386-obsd-tdep.c (i386obsd_supply_uthread): Likewise.
548 (i386obsd_collect_uthread): Likewise.
549 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
550 (i386_supply_gregset): Likewise.
551 (i386_collect_gregset): Likewise.
552 (i386_supply_fpregset): Likewise.
553 (i386_collect_fpregset): Likewise.
554 (i386_mpx_bd_base): Likewise.
555 * i386-v4-nat.c (supply_fpregset): Likewise.
556 (fill_fpregset): Likewise.
557 * i387-tdep.c (i387_supply_fsave): Likewise.
558 (i387_collect_fsave): Likewise.
559 (i387_supply_fxsave): Likewise.
560 (i387_collect_fxsave): Likewise.
561 (i387_supply_xsave): Likewise.
562 (i387_collect_xsave): Likewise.
563 * ia64-linux-nat.c (ia64_linux_fetch_registers): Likewise.
564 (ia64_linux_store_registers): Likewise.
565 * ia64-tdep.c (ia64_access_rse_reg): Likewise.
566 (ia64_extract_return_value): Likewise.
567 (ia64_store_return_value): Likewise.
568 (find_func_descr): Likewise.
569 * inf-child.c (inf_child_fetch_inferior_registers): Likewise.
570 * inf-ptrace.c (inf_ptrace_fetch_registers): Likewise.
571 (inf_ptrace_store_registers): Likewise.
572 * infrun.c (use_displaced_stepping): Likewise.
573 (displaced_step_prepare_throw): Likewise.
574 (resume): Likewise.
575 (proceed): Likewise.
576 (do_target_wait): Likewise.
577 (adjust_pc_after_break): Likewise.
578 (handle_inferior_event_1): Likewise.
579 (handle_signal_stop): Likewise.
580 (save_infcall_suspend_state): Likewise.
581 (restore_infcall_suspend_state): Likewise.
582 * iq2000-tdep.c (iq2000_extract_return_value): Likewise.
583 * jit.c (jit_frame_prev_register): Likewise.
584 * linux-nat.c (save_stop_reason): Likewise.
585 (linux_nat_wait_1): Likewise.
586 (resume_stopped_resumed_lwps): Likewise.
587 * linux-record.c (record_linux_sockaddr): Likewise.
588 (record_linux_msghdr): Likewise.
589 (record_linux_system_call): Likewise.
590 * linux-tdep.c (linux_collect_thread_registers): Likewise.
591 * lm32-tdep.c (lm32_extract_return_value): Likewise.
592 (lm32_store_return_value): Likewise.
593 * m32c-tdep.c (m32c_read_flg): Likewise.
594 (m32c_pseudo_register_read): Likewise.
595 (m32c_pseudo_register_write): Likewise.
596 * m32r-linux-tdep.c (m32r_linux_supply_gregset): Likewise.
597 (m32r_linux_collect_gregset): Likewise.
598 * m32r-tdep.c (m32r_store_return_value): Likewise.
599 (m32r_extract_return_value): Likewise.
600 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
601 (m68kbsd_collect_fpregset): Likewise.
602 * m68k-bsd-tdep.c (m68kbsd_supply_fpregset): Likewise.
603 * m68k-linux-nat.c (fetch_register): Likewise.
604 (old_fetch_inferior_registers): Likewise.
605 (old_store_inferior_registers): Likewise.
606 (store_regs): Likewise.
607 * m68k-tdep.c (m68k_svr4_extract_return_value): Likewise.
608 (m68k_svr4_store_return_value): Likewise.
609 * m88k-tdep.c (m88k_store_arguments): Likewise.
610 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Likewise.
611 (mi_cmd_data_write_register_values): Likewise.
612 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers): Likewise.
613 (mips_fbsd_store_inferior_registers): Likewise.
614 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Likewise.
615 (mips_fbsd_supply_gregs): Likewise.
616 (mips_fbsd_collect_fpregs): Likewise.
617 (mips_fbsd_collect_gregs): Likewise.
618 (mips_fbsd_supply_fpregset): Likewise.
619 (mips_fbsd_collect_fpregset): Likewise.
620 (mips_fbsd_supply_gregset): Likewise.
621 (mips_fbsd_collect_gregset): Likewise.
622 * mips-linux-nat.c (supply_gregset): Likewise.
623 (fill_gregset): Likewise.
624 (supply_fpregset): Likewise.
625 (fill_fpregset): Likewise.
626 * mips-linux-tdep.c (mips_supply_gregset): Likewise.
627 (mips_fill_gregset): Likewise.
628 (mips_supply_fpregset): Likewise.
629 (mips_fill_fpregset): Likewise.
630 (mips64_supply_gregset): Likewise.
631 (micromips_linux_sigframe_validate): Likewise.
632 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers): Likewise.
633 (mipsnbsd_fetch_inferior_registers): Likewise.
634 (mipsnbsd_store_inferior_registers): Likewise.
635 * mips-nbsd-tdep.c (mipsnbsd_supply_fpregset): Likewise.
636 (mipsnbsd_supply_gregset): Likewise.
637 (mipsnbsd_iterate_over_regset_sections): Likewise.
638 (mipsnbsd_supply_reg): Likewise.
639 (mipsnbsd_supply_fpreg): Likewise.
640 * mips-tdep.c (mips_in_frame_stub): Likewise.
641 (mips_dummy_id): Likewise.
642 (is_octeon_bbit_op): Likewise.
643 (micromips_bc1_pc): Likewise.
644 (extended_mips16_next_pc): Likewise.
645 (mips16_next_pc): Likewise.
646 (deal_with_atomic_sequence): Likewise.
647 * moxie-tdep.c (moxie_process_readu): Likewise.
648 * nios2-tdep.c (nios2_get_next_pc): Likewise.
649 * nto-procfs.c (procfs_store_registers): Likewise.
650 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers): Likewise.
651 (ppcfbsd_store_inferior_registers): Likewise.
652 * ppc-linux-nat.c (fetch_vsx_register): Likewise.
653 (fetch_altivec_register): Likewise.
654 (get_spe_registers): Likewise.
655 (fetch_spe_register): Likewise.
656 (fetch_altivec_registers): Likewise.
657 (fetch_all_gp_regs): Likewise.
658 (fetch_all_fp_regs): Likewise.
659 (store_vsx_register): Likewise.
660 (store_altivec_register): Likewise.
661 (set_spe_registers): Likewise.
662 (store_spe_register): Likewise.
663 (store_altivec_registers): Likewise.
664 (store_all_gp_regs): Likewise.
665 (store_all_fp_regs): Likewise.
666 * ppc-linux-tdep.c (ppc_linux_supply_gregset): Likewise.
667 (ppc_linux_collect_gregset): Likewise.
668 (ppc_canonicalize_syscall): Likewise.
669 (ppc_linux_record_signal): Likewise.
670 (ppu2spu_prev_register): Likewise.
671 * ppc-nbsd-nat.c (ppcnbsd_supply_pcb): Likewise.
672 * ppc-obsd-nat.c (ppcobsd_fetch_registers): Likewise.
673 (ppcobsd_store_registers): Likewise.
674 * ppc-ravenscar-thread.c (ppc_ravenscar_generic_fetch_registers):
675 Likewise.
676 (ppc_ravenscar_generic_store_registers): Likewise.
677 * procfs.c (procfs_fetch_registers): Likewise.
678 (procfs_store_registers): Likewise.
679 * ravenscar-thread.c (ravenscar_fetch_registers): Likewise.
680 (ravenscar_store_registers): Likewise.
681 (ravenscar_prepare_to_store): Likewise.
682 * record-btrace.c (record_btrace_fetch_registers): Likewise.
683 * record-full.c (record_full_wait_1): Likewise.
684 (record_full_registers_change): Likewise.
685 (record_full_store_registers): Likewise.
686 (record_full_core_fetch_registers): Likewise.
687 (record_full_save): Likewise.
688 (record_full_goto_insn): Likewise.
689 * regcache.c (regcache_register_size): Likewise.
690 (get_regcache_arch): Remove.
691 (regcache_read_pc): Likewise.
692 * regcache.h (get_regcache_arch): Remove.
693 * remote-sim.c (gdbsim_fetch_register): Likewise.
694 (gdbsim_store_register): Likewise.
695 * remote.c (fetch_register_using_p): Likewise.
696 (send_g_packet): Likewise.
697 (remote_prepare_to_store): Likewise.
698 (store_registers_using_G): Likewise.
699 * reverse.c (save_bookmark_command): Likewise.
700 (goto_bookmark_command): Likewise.
701 * rs6000-aix-tdep.c (branch_dest): Likewise.
702 * rs6000-nat.c (rs6000_ptrace64): Likewise.
703 (fetch_register): Likewise.
704 * rs6000-tdep.c (ppc_supply_reg): Likewise.
705 (ppc_collect_reg): Likewise.
706 (ppc_collect_gregset): Likewise.
707 (ppc_collect_fpregset): Likewise.
708 (ppc_collect_vsxregset): Likewise.
709 (ppc_collect_vrregset): Likewise.
710 (ppc_displaced_step_hw_singlestep): Likewise.
711 (rs6000_pseudo_register_read): Likewise.
712 (rs6000_pseudo_register_write): Likewise.
713 * s390-linux-nat.c (supply_gregset): Likewise.
714 (fill_gregset): Likewise.
715 (s390_linux_fetch_inferior_registers): Likewise.
716 * s390-linux-tdep.c (s390_write_pc): Likewise.
717 (s390_software_single_step): Likewise.
718 (s390_all_but_pc_registers_record): Likewise.
719 (s390_linux_syscall_record): Likewise.
720 * sentinel-frame.c (sentinel_frame_prev_arch): Likewise.
721 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers): Likewise.
722 (shnbsd_store_inferior_registers): Likewise.
723 * sh-tdep.c (sh_extract_return_value_nofpu): Likewise.
724 (sh_extract_return_value_fpu): Likewise.
725 (sh_store_return_value_nofpu): Likewise.
726 (sh_corefile_supply_regset): Likewise.
727 (sh_corefile_collect_regset): Likewise.
728 * sh64-tdep.c (sh64_extract_return_value): Likewise.
729 (sh64_store_return_value): Likewise.
730 * sparc-linux-tdep.c (sparc32_linux_collect_core_fpregset): Likewise.
731 * sparc-nat.c (sparc_fetch_inferior_registers): Likewise.
732 (sparc_store_inferior_registers): Likewise.
733 * sparc-ravenscar-thread.c (register_in_thread_descriptor_p): Likewise.
734 (sparc_ravenscar_prepare_to_store): Likewise.
735 * sparc-tdep.c (sparc32_store_arguments): Likewise.
736 (sparc_analyze_control_transfer): Likewise.
737 (sparc_step_trap): Likewise.
738 (sparc_software_single_step): Likewise.
739 (sparc32_gdbarch_init): Likewise.
740 (sparc_supply_rwindow): Likewise.
741 (sparc_collect_rwindow): Likewise.
742 * sparc64-linux-tdep.c (sparc64_linux_collect_core_fpregset): Likewise.
743 * sparc64-nbsd-nat.c (sparc64nbsd_supply_gregset): Likewise.
744 (sparc64nbsd_collect_gregset): Likewise.
745 (sparc64nbsd_supply_fpregset): Likewise.
746 (sparc64nbsd_collect_fpregset): Likewise.
747 * sparc64-tdep.c (sparc64_store_arguments): Likewise.
748 (sparc64_supply_gregset): Likewise.
749 (sparc64_collect_gregset): Likewise.
750 (sparc64_supply_fpregset): Likewise.
751 (sparc64_collect_fpregset): Likewise.
752 * spu-linux-nat.c (spu_fetch_inferior_registers): Likewise.
753 * spu-tdep.c (spu_unwind_sp): Likewise.
754 (spu2ppu_prev_register): Likewise.
755 (spu_memory_remove_breakpoint): Likewise.
756 * stack.c (return_command): Likewise.
757 * tic6x-tdep.c (tic6x_extract_signed_field): Likewise.
758 * tracefile-tfile.c (tfile_fetch_registers): Likewise.
759 * tracefile.c (trace_save_ctf): Likewise.
760 * windows-nat.c (do_windows_fetch_inferior_registers): Likewise.
761 (do_windows_store_inferior_registers): Likewise.
762 (windows_resume): Likewise.
763 * xtensa-linux-nat.c (fill_gregset): Likewise.
764 (supply_gregset_reg): Likewise.
765 * xtensa-tdep.c (xtensa_register_write_masked): Likewise.
766 (xtensa_register_read_masked): Likewise.
767 (xtensa_supply_gregset): Likewise.
768 (xtensa_extract_return_value): Likewise.
769 (xtensa_store_return_value): Likewise.
770
edd079d9
UW
7712017-10-25 Ulrich Weigand <uweigand@de.ibm.com>
772
773 * doublest.c (floatformat_from_string): New function.
774 * doublest.h (floatformat_from_string): Add prototype.
775
776 * std-operator.def (OP_DOUBLE, OP_DECFLOAT): Remove, replace by ...
777 (OP_FLOAT): ... this.
778 * expression.h: Do not include "doublest.h".
779 (union exp_element): Replace doubleconst and decfloatconst by
780 new element floatconst.
781 * ada-lang.c (resolve_subexp): Handle OP_FLOAT instead of OP_DOUBLE.
782 (ada_evaluate_subexp): Likewise.
783 * eval.c (evaluate_subexp_standard): Handle OP_FLOAT instead of
784 OP_DOUBLE and OP_DECFLOAT.
785 * expprint.c (print_subexp_standard): Likewise.
786 (dump_subexp_body_standard): Likewise.
787 * breakpoint.c (watchpoint_exp_is_const): Likewise.
788
789 * parse.c: Include "dfp.h".
790 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
791 (write_exp_elt_floatcst): New function.
792 (operator_length_standard): Handle OP_FLOAT instead of OP_DOUBLE
793 and OP_DECFLOAT.
794 (operator_check_standard): Likewise.
795 (parse_float): Do not accept suffix. Take type as input. Return bool.
796 Return target format buffer instead of host DOUBLEST.
797 Use floatformat_from_string and decimal_from_string to parse
798 either binary or decimal floating-point types.
799 (parse_c_float): Remove.
800 * parser-defs.h: Do not include "doublest.h".
801 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
802 (write_exp_elt_floatcst): Add prototype.
803 (parse_float): Update prototype.
804 (parse_c_float): Remove.
805
806 * c-exp.y: Do not include "dfp.h".
807 (typed_val_float): Use byte buffer instead of DOUBLEST.
808 (typed_val_decfloat): Remove.
809 (DECFLOAT): Remove.
810 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
811 (parse_number): Update to new parse_float interface.
812 Parse suffixes and determine type before calling parse_float.
813 Handle decimal and binary FP types the same way.
814
815 * d-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
816 (FLOAT_LITERAL): Use OP_FLOAT and write_exp_elt_floatcst.
817 (parse_number): Update to new parse_float interface.
818 Parse suffixes and determine type before calling parse_float.
819
820 * f-exp.y: Replace dval by typed_val_float.
821 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
822 (parse_number): Use parse_float instead of atof.
823
824 * go-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
825 (parse_go_float): Remove.
826 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
827 (parse_number): Call parse_float instead of parse_go_float.
828 Parse suffixes and determine type before calling parse_float.
829
830 * p-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
831 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
832 (parse_number): Update to new parse_float interface.
833 Parse suffixes and determine type before calling parse_float.
834
835 * m2-exp.y: Replace dval by byte buffer val.
836 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
837 (parse_number): Call parse_float instead of atof.
838
839 * rust-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
840 (lex_number): Call parse_float instead of strtod.
841 (ast_dliteral): Use OP_FLOAT instead of OP_DOUBLE.
842 (convert_ast_to_expression): Handle OP_FLOAT instead of OP_DOUBLE.
843 Use write_exp_elt_floatcst.
844 (unit_testing): Remove static variable.
845 (rust_type): Do not check unit_testing.
846 (rust_lex_tests): Do not set uint_testing. Set up dummy rust_parser.
847
848 * ada-exp.y (type_float, type_double): Remove.
849 (typed_val_float): Use byte buffer instead of DOUBLEST.
850 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
851 * ada-lex.l (processReal): Use parse_float instead of sscanf.
852
cc628f3d
AH
8532017-10-25 Alan Hayward <alan.hayward@arm.com>
854
855 * aarch64-tdep.h (enum aarch64_regnum): Remove.
856 * arch/aarch64.h: New file.
857
09a7c6aa
UW
8582017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
859
860 * dfp.h (decimal_from_string): Use const reference for argument.
861 * dfp.c (decimal_from_string): Likewise.
862
8ba0dd51
UW
8632017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
864
865 * i387-tdep.c (print_i387_value): Use floatformat_to_string.
866 * sh64-tdep.c (sh64_do_fp_register): Likewise.
867 * mips-tdep.c (mips_print_fp_register): Likewise.
868
16e812b2
UW
8692017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
870
871 * common/format.h (enum argclass): Replace decfloat_arg by
872 dec32float_arg, dec64float_arg, and dec128float_arg.
873 * common/format.c (parse_format_string): Update to return
874 new decimal float argument classes.
875
876 * printcmd.c (printf_decfloat): Rename to ...
877 (printf_floating): ... this. Add argclass argument, and use it
878 instead of parsing the format string again. Add support for
879 binary floating-point values, using floatformat_to_string.
880 Convert value to the target format if it doesn't already match.
881 (ui_printf): Call printf_floating instead of printf_decfloat,
882 also for double_arg / long_double_arg. Pass argclass.
883
884 * dfp.c (decimal_to_string): Add format string argument.
885 * dfp.h (decimal_to_string): Likewise.
886
887 * doublest.c (floatformat_to_string): Add format string argument.
888 * doublest.h (floatformat_to_string): Likewise.
889
fdf0cbc2
UW
8902017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
891
892 * doublest.c (floatformat_precision): New routine.
893 (floatformat_to_string): Likewise.
894 * doublest.c (floatformat_to_string): Add prototype.
895
896 * printcmd.c (print_scalar_formatted): Only call print_floating
897 on floating-point types.
898 * valprint.c: Do not include "floatformat.h".
899 (generic_val_print_decfloat): Remove.
900 (generic_val_print): Call generic_val_print_float for both
901 TYPE_CODE_FLT and TYPE_CODE_DECFLOAT.
902 (print_floating): Use floatformat_to_string. Handle decimal float.
903 (print_decimal_floating): Remove, merge into floatformat_to_string.
904 * value.h (print_decimal_floating): Remove.
905
906 * Makefile.in: Do not build doublest.c with -Wformat-nonliteral.
907
5033013f
UW
9082017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
909
910 * buildsym.c (end_symtab_get_static_block): Use std::stable_sort.
911
a664f67e
SM
9122017-10-21 Simon Marchi <simon.marchi@ericsson.com>
913
914 * memattr.h: Don't include vec.h.
915 (struct mem_attrib): Initialize fields.
916 <unknown>: New static method.
917 (struct mem_region): Add constructors, operator<, initialize
918 fields.
919 * memattr.c: Include algorithm.
920 (default_mem_attrib, unknown_mem_attrib): Remove.
921 (user_mem_region_list): New global.
922 (target_mem_region_list, mem_region_list): Change type to
923 std::vector<mem_region>.
924 (mem_use_target): Now a function.
925 (target_mem_regions_valid): Change type to bool.
926 (mem_region_lessthan, mem_region_cmp, mem_region_init): Remove.
927 (require_user_regions): Adjust.
928 (require_target_regions): Adjust.
929 (create_mem_region): Adjust.
930 (lookup_mem_region): Adjust.
931 (invalidate_target_mem_regions): Adjust.
932 (mem_clear): Rename to...
933 (user_mem_clear): ... this, and adjust.
934 (mem_command): Adjust.
935 (info_mem_command): Adjust.
936 (mem_enable, enable_mem_command, mem_disable,
937 disable_mem_command): Adjust.
938 (mem_delete): Adjust.
939 (delete_mem_command): Adjust.
940 * memory-map.h (parse_memory_map): Return an std::vector.
941 * memory-map.c (parse_memory_map): Likewise.
942 (struct memory_map_parsing_data): Add constructor.
943 <memory_map>: Point to std::vector.
944 (memory_map_start_memory): Adjust.
945 (memory_map_end_memory): Adjust.
946 (memory_map_end_property): Adjust.
947 (clear_result): Remove.
948 * remote.c (remote_memory_map): Return an std::vector.
949 * target-debug.h (target_debug_print_VEC_mem_region_s__p):
950 Remove.
951 (target_debug_print_mem_region_vector): New.
952 * target-delegates.c: Regenerate.
953 * target.h (mem_region_vector): New typedef.
954 (to_memory_map): Return mem_region_vector.
955 (target_memory_map): Return an std::vector.
956 * target.c (target_memory_map): Return an std::vector.
957 (flash_erase_command): Adjust.
958
6e17c565
SM
9592017-10-21 Simon Marchi <simon.marchi@ericsson.com>
960
961 * memory-map.c (struct memory_map_parsing_data) <property_name>:
962 Change type to std::string.
963 (memory_map_start_property): Adjust.
964 (memory_map_end_property): Adjust.
965
cfba9872
SM
9662017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
967
968 * infrun.h: Include common/byte-vector.h.
969 (struct displaced_step_closure): New struct.
970 (struct buf_displaced_step_closure): New struct.
971 * infrun.c (displaced_step_closure::~displaced_step_closure):
972 Provide default implementation.
973 (displaced_step_clear): Deallocate step closure with delete.
974 * aarch64-tdep.c (displaced_step_closure): Rename to ...
975 (aarch64_displaced_step_closure): ... this, extend
976 displaced_step_closure.
977 (aarch64_displaced_step_data) <dsc>: Change type to
978 aarch64_displaced_step_closure.
979 (aarch64_displaced_step_copy_insn): Adjust to type change, use
980 unique_ptr.
981 (aarch64_displaced_step_fixup): Add cast for displaced step
982 closure.
983 * amd64-tdep.c (displaced_step_closure): Rename to ...
984 (amd64_displaced_step_closure): ... this, extend
985 displaced_step_closure.
986 <insn_buf>: Change type to std::vector<gdb_byte>.
987 <max_len>: Remove.
988 (fixup_riprel): Change type of DSC parameter, adjust to type
989 change of insn_buf.
990 (fixup_displaced_copy): Change type of DSC parameter.
991 (amd64_displaced_step_copy_insn): Instantiate
992 amd64_displaced_step_closure.
993 (amd64_displaced_step_fixup): Add cast for closure type, adjust
994 to type change of insn_buf.
995 * arm-linux-tdep.c (arm_linux_cleanup_svc): Change type of
996 parameter DSC.
997 (arm_linux_copy_svc): Likewise.
998 (cleanup_kernel_helper_return): Likewise.
999 (arm_catch_kernel_helper_return): Likewise.
1000 (arm_linux_displaced_step_copy_insn): Instantiate
1001 arm_displaced_step_closure.
1002 * arm-tdep.c (arm_pc_is_thumb): Add cast for closure.
1003 (displaced_read_reg): Change type of parameter DSC.
1004 (branch_write_pc): Likewise.
1005 (load_write_pc): Likewise.
1006 (alu_write_pc): Likewise.
1007 (displaced_write_reg): Likewise.
1008 (arm_copy_unmodified): Likewise.
1009 (thumb_copy_unmodified_32bit): Likewise.
1010 (thumb_copy_unmodified_16bit): Likewise.
1011 (cleanup_preload): Likewise.
1012 (install_preload): Likewise.
1013 (arm_copy_preload): Likewise.
1014 (thumb2_copy_preload): Likewise.
1015 (install_preload_reg): Likewise.
1016 (arm_copy_preload_reg): Likewise.
1017 (cleanup_copro_load_store): Likewise.
1018 (install_copro_load_store): Likewise.
1019 (arm_copy_copro_load_store) Likewise.
1020 (thumb2_copy_copro_load_store): Likewise.
1021 (cleanup_branch): Likewise.
1022 (install_b_bl_blx): Likewise.
1023 (arm_copy_b_bl_blx): Likewise.
1024 (thumb2_copy_b_bl_blx): Likewise.
1025 (thumb_copy_b): Likewise.
1026 (install_bx_blx_reg): Likewise.
1027 (arm_copy_bx_blx_reg): Likewise.
1028 (thumb_copy_bx_blx_reg): Likewise.
1029 (cleanup_alu_imm): Likewise.
1030 (arm_copy_alu_imm): Likewise.
1031 (thumb2_copy_alu_imm): Likewise.
1032 (cleanup_alu_reg): Likewise.
1033 (install_alu_reg): Likewise.
1034 (arm_copy_alu_reg): Likewise.
1035 (thumb_copy_alu_reg): Likewise.
1036 (cleanup_alu_shifted_reg): Likewise.
1037 (install_alu_shifted_reg): Likewise.
1038 (arm_copy_alu_shifted_reg): Likewise.
1039 (cleanup_load): Likewise.
1040 (cleanup_store): Likewise.
1041 (arm_copy_extra_ld_st): Likewise.
1042 (install_load_store): Likewise.
1043 (thumb2_copy_load_literal): Likewise.
1044 (thumb2_copy_load_reg_imm): Likewise.
1045 (arm_copy_ldr_str_ldrb_strb): Likewise.
1046 (cleanup_block_load_all): Likewise.
1047 (cleanup_block_store_pc): Likewise.
1048 (cleanup_block_load_pc): Likewise.
1049 (arm_copy_block_xfer): Likewise.
1050 (thumb2_copy_block_xfer): Likewise.
1051 (cleanup_svc): Likewise.
1052 (install_svc): Likewise.
1053 (arm_copy_svc): Likewise.
1054 (thumb_copy_svc): Likewise.
1055 (arm_copy_undef): Likewise.
1056 (thumb_32bit_copy_undef): Likewise.
1057 (arm_copy_unpred): Likewise.
1058 (arm_decode_misc_memhint_neon): Likewise.
1059 (arm_decode_unconditional): Likewise.
1060 (arm_decode_miscellaneous): Likewise.
1061 (arm_decode_dp_misc): Likewise.
1062 (arm_decode_ld_st_word_ubyte): Likewise.
1063 (arm_decode_media): Likewise.
1064 (arm_decode_b_bl_ldmstm): Likewise.
1065 (arm_decode_ext_reg_ld_st): Likewise.
1066 (thumb2_decode_dp_shift_reg): Likewise.
1067 (thumb2_decode_ext_reg_ld_st): Likewise.
1068 (arm_decode_svc_copro): Likewise.
1069 (thumb2_decode_svc_copro): Likewise.
1070 (install_pc_relative): Likewise.
1071 (thumb_copy_pc_relative_16bit): Likewise.
1072 (thumb_decode_pc_relative_16bit): Likewise.
1073 (thumb_copy_pc_relative_32bit): Likewise.
1074 (thumb_copy_16bit_ldr_literal): Likewise.
1075 (thumb_copy_cbnz_cbz): Likewise.
1076 (thumb2_copy_table_branch): Likewise.
1077 (cleanup_pop_pc_16bit_all): Likewise.
1078 (thumb_copy_pop_pc_16bit): Likewise.
1079 (thumb_process_displaced_16bit_insn): Likewise.
1080 (decode_thumb_32bit_ld_mem_hints): Likewise.
1081 (thumb_process_displaced_32bit_insn): Likewise.
1082 (thumb_process_displaced_insn): Likewise.
1083 (arm_process_displaced_insn): Likewise.
1084 (arm_displaced_init_closure): Likewise.
1085 (arm_displaced_step_fixup): Add cast for closure.
1086 * arm-tdep.h: Include infrun.h.
1087 (displaced_step_closure): Rename to ...
1088 (arm_displaced_step_closure): ... this, extend
1089 displaced_step_closure.
1090 <u::svc::copy_svc_os>: Change type of parameter DSC.
1091 <cleanup>: Likewise.
1092 (arm_process_displaced_insn): Likewise.
1093 (arm_displaced_init_closure): Likewise.
1094 (displaced_read_reg): Likewise.
1095 (displaced_write_reg): Likewise.
1096 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
1097 Adjust.
1098 * i386-tdep.h: Include infrun.h.
1099 (i386_displaced_step_closure): New typedef.
1100 * i386-tdep.c (i386_displaced_step_copy_insn): Use
1101 i386_displaced_step_closure.
1102 (i386_displaced_step_fixup): Adjust.
1103 * rs6000-tdep.c (ppc_displaced_step_closure): New typedef.
1104 (ppc_displaced_step_copy_insn): Use ppc_displaced_step_closure
1105 and unique_ptr.
1106 (ppc_displaced_step_fixup): Adjust.
1107 * s390-linux-tdep.c (s390_displaced_step_closure): New typedef.
1108 (s390_displaced_step_copy_insn): Use s390_displaced_step_closure
1109 and unique_ptr.
1110 (s390_displaced_step_fixup): Adjust.
1111
b392b304
SM
11122017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
1113
1114 * interps.h (interp_resume, interp_suspend, interp_set_temp):
1115 Remove declarations.
1116
d5833c62
TT
11172017-10-20 Tom Tromey <tom@tromey.com>
1118
1119 * gdb_bfd.c (struct gdb_bfd_data) <included_bfds>: Now a
1120 std::vector.
1121 (gdb_bfd_record_inclusion): Update.
1122 (bfdp): Remove typedef.
1123
06d5bbc8
TT
11242017-10-20 Tom Tromey <tom@tromey.com>
1125
1126 * gdb_bfd.c (gdb_bfd_ref): Use new.
1127 (struct gdb_bfd_data): Add constructor, destructor, and member
1128 initializers.
1129 (gdb_bfd_unref): Use delete.
1130
2712ce2e
TT
11312017-10-20 Tom Tromey <tom@tromey.com>
1132
1133 * exec.c (exec_file_attach): Use new_bfd_ref.
1134 * symfile-mem.c (symbol_file_add_from_memory): Use new_bfd_ref.
1135 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
1136 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_fdopenr): Use
1137 new_bfd_ref.
1138 * gdb_bfd.h (new_bfd_ref): New function.
1139
fcc8fb2f
PA
11402017-10-20 Pedro Alves <palves@redhat.com>
1141
1142 * main.c (captured_command_loop): Add attribute noinline.
1143
4c2287b0
SM
11442017-10-19 Simon Marchi <simon.marchi@ericsson.com>
1145
1146 * interps.c (struct interp_factory): Add constructor.
1147 (interp_factory_p): Remove typedef.
1148 (DEF_VEC_P(interp_factory_p)): Remove.
1149 (interpreter_factories): Change type to std::vector.
1150 (interp_factory_register): Adjust.
1151 (interp_lookup): Adjust.
1152 (interpreter_completer): Adjust.
1153
3d415c26
TT
11542017-10-19 Tom Tromey <tom@tromey.com>
1155
1156 * break-catch-syscall.c (catch_syscall_completer): Use
1157 std::string, gdb::unique_xmalloc_ptr.
1158
395423c4
TT
11592017-10-19 Tom Tromey <tom@tromey.com>
1160
1161 * infcall.c (call_function_by_hand_dummy): Use std::string.
1162
54f70bc1
TT
11632017-10-19 Tom Tromey <tom@tromey.com>
1164
1165 * mi/mi-main.c (mi_cmd_execute): Update.
1166 * top.h (prepare_execute_command): Return scoped_value_mark.
1167 * value.h (class scoped_value_mark): Use DISABLE_COPY_AND_ASSIGN.
1168 Add move constructor.
1169 * top.c (prepare_execute_command): Return scoped_value_mark.
1170 (execute_command): Update.
1171
63929e84
PA
11722017-10-19 Pedro Alves <palves@redhat.com>
1173
1174 * xml-support.c (xml_fetch_content_from_file): Check fread's
1175 return.
1176
a75868f5
PA
11772017-10-19 Pedro Alves <palves@redhat.com>
1178
1179 * ser-base.c (ser_base_read_error_fd): Delete the file handler if
1180 async.
1181 (handle_error_fd): New function.
1182 (ser_base_async): Add/delete an event loop file handler for
1183 error_fd.
1184
2edf834e
PA
11852017-10-19 Pedro Alves <palves@redhat.com>
1186
1187 * xml-support.c (xml_fetch_content_from_file): Don't read in
1188 chunks. Instead use fseek to determine the file's size, and read
1189 it in one go.
1190
c8ba13ad
KS
11912017-11-18 Keith Seitz <keiths@redhat.com>
1192
1193 * c-exp.y (oper): Canonicalize conversion operators of user-defined
1194 types.
1195 Add whitespace to front of type name.
1196
37534686
KS
11972017-10-18 Keith Seitz <keiths@redhat.com>
1198
1199 * dwarf2read.c (dwarf2_add_typedef): Issue a complaint on unhandled
1200 DW_AT_accessibility.
1201
28c7c158
YQ
12022017-10-18 Yao Qi <yao.qi@linaro.org>
1203
1204 * features/tic6x-c62x-linux.c: Remove.
1205
30f0b101
TT
12062017-10-17 Tom Tromey <tom@tromey.com>
1207
1208 * disasm.c (do_mixed_source_and_assembly_deprecated): Use
1209 gdb::optional, ui_out_emit_list, ui_out_emit_tuple.
1210 (do_mixed_source_and_assembly): Likewise.
1211
57e12da9
TT
12122017-10-17 Tom Tromey <tom@tromey.com>
1213
1214 * regcache.c (regcache::xfer_part): Remove assertion.
1215
7b700999
PA
12162017-10-17 Pedro Alves <palves@redhat.com>
1217
1218 * xml-support.c (xml_fetch_content_from_file): Call
1219 unique_ptr::release() instead unique_ptr::get() when passing
1220 through xrealloc.
1221
d3037ba6
YQ
12222017-10-17 Yao Qi <yao.qi@linaro.org>
1223
1224 * regcache.c (regcache::xfer_part): Remove parameters read and
1225 write, add parameter is_raw. All callers are updated.
1226
83d5a34d
KS
12272017-10-16 Keith Seitz <keiths@redhat.com>
1228
1229 * c-typeprint.c (enum access_specifier): Moved here from
1230 c_type_print_base.
1231 (output_access_specifier): New function.
1232 (c_type_print_base): Consider typedefs when assessing
1233 whether access labels are needed.
1234 Use output_access_specifier as needed.
1235 Output access specifier for typedefs, if needed.
1236 * dwarf2read.c (dwarf2_add_typedef): Record DW_AT_accessibility.
1237 * gdbtypes.h (struct typedef_field) <is_protected, is_private>: New
1238 fields.
1239 (TYPE_TYPEDEF_FIELD_PROTECTED, TYPE_TYPEDEF_FIELD_PRIVATE): New
1240 accessor macros.
1241
87028b87
TT
12422017-10-16 Tom Tromey <tom@tromey.com>
1243
1244 * linux-tdep.c (linux_info_proc, linux_find_memory_regions_full)
1245 (linux_fill_prpsinfo, linux_vsyscall_range_raw): Update.
1246 * target.c (target_fileio_read_stralloc): Update.
1247 * sparc64-tdep.c (adi_is_addr_mapped): Update.
1248 * target.h (target_fileio_read_stralloc): Return
1249 unique_xmalloc_ptr.
1250
b7b030ad
TT
12512017-10-16 Tom Tromey <tom@tromey.com>
1252
1253 * xml-syscall.c (xml_init_syscalls_info): Update.
1254 * xml-support.c (xinclude_start_include): Update.
1255 (xml_fetch_content_from_file): Return unique_xmalloc_ptr.
1256 * xml-support.h (xml_fetch_another): Return unique_xmalloc_ptr.
1257 (xml_fetch_content_from_file): Likewise.
1258 * osdata.c (get_osdata): Update.
1259 * target.h (target_read_stralloc, target_get_osdata): Return
1260 unique_xmalloc_ptr.
1261 * solib-aix.c (solib_aix_get_library_list): Update.
1262 * solib-target.c (solib_target_current_sos): Update.
1263 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Update.
1264 * xml-tdesc.c (fetch_available_features_from_target): Update.
1265 (target_fetch_description_xml): Update.
1266 (file_read_description_xml): Update.
1267 * remote.c (remote_get_threads_with_qxfer, remote_memory_map)
1268 (remote_traceframe_info, btrace_read_config, remote_read_btrace)
1269 (remote_pid_to_exec_file): Update.
1270 * target.c (target_read_stralloc): Return unique_xmalloc_ptr.
1271 (target_get_osdata): Likewise.
1272
b80406ac
TT
12732017-10-16 Tom Tromey <tom@tromey.com>
1274
1275 * remote.c (remote_register_number_and_offset): Use std::vector.
1276 (remote_set_syscall_catchpoint): Use gdb::unique_xmalloc_ptr.
1277 (putpkt_binary): Use gdb::def_vector.
1278 (compare_sections_command): Use gdb::byte_vector.
1279
a90ecff8
TT
12802017-10-16 Tom Tromey <tom@tromey.com>
1281
1282 * ppc-linux-nat.c (hwdebug_insert_point): Use
1283 gdb::unique_xmalloc_ptr, XDUP.
1284
2dc0e219
TT
12852017-10-16 Tom Tromey <tom@tromey.com>
1286
1287 * probe.c (parse_probes): Use std::string.
1288 (info_probes_for_ops, enable_probes_command)
1289 (disable_probes_command): Remove cleanups.
1290
b05628f0
TT
12912017-10-16 Tom Tromey <tom@tromey.com>
1292
1293 * buildsym.c (block_compar): Remove.
1294 (end_symtab_get_static_block): Use std::vector.
1295
a79b1bc6
SM
12962017-10-16 Simon Marchi <simon.marchi@ericsson.com>
1297
1298 * memrange.h (struct mem_range): Define operator< and operator==.
1299 (mem_range_s): Remove.
1300 (DEF_VEC_O (mem_range_s)): Remove.
1301 (normalize_mem_ranges): Change parameter type to std::vector.
1302 * memrange.c (compare_mem_ranges): Remove.
1303 (normalize_mem_ranges): Change parameter type to std::vector,
1304 adjust to vector change.
1305 * exec.c (section_table_available_memory): Return vector, remove
1306 parameter.
1307 (section_table_read_available_memory): Adjust to std::vector
1308 change.
1309 * remote.c (remote_read_bytes): Adjust to std::vector
1310 change.
1311 * tracepoint.h (traceframe_available_memory): Change parameter
1312 type to std::vector.
1313 * tracepoint.c (traceframe_available_memory): Change parameter
1314 type to std::vector, adjust.
1315 * gdb/mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to
1316 std::vector change.
1317 * gdb/Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1318 unittests/memrange-selftests.c.
1319 (SUBDIR_UNITTESTS_OBS): Add memrange-selftests.o.
1320 * gdb/unittests/memrange-selftests.c: New file.
1321
63f0e930
PA
13222017-10-16 Pedro Alves <palves@redhat.com>
1323
1324 * elfread.c (probe_key_free): Rename range-for variable.
1325 * probe.c (parse_probes_in_pspace, find_probes_in_objfile)
1326 (find_probe_by_pc, collect_probes): Rename range-for variable.
1327
c40c7bfc
YQ
13282017-10-16 Yao Qi <yao.qi@linaro.org>
1329
1330 * features/Makefile (XMLTOC): Remove tic6x-*.xml.
1331 * features/tic6x-c62x.c: Remove.
1332 * features/tic6x-c64x-linux.c: Remove.
1333 * features/tic6x-c64x.c: Remove.
1334 * features/tic6x-c64xp-linux.c: Remove.
1335 * features/tic6x-c64xp.c: Remove.
1336 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Don't call
1337 initialize_tdesc_tic6x_*_linux functions.
1338 * tic6x-tdep.c (_initialize_tic6x_tdep): Don't call
1339 initialize_tdesc_tic6x_* functions.
1340
df27ae6a
YQ
13412017-10-16 Yao Qi <yao.qi@linaro.org>
1342
1343 * features/Makefile (WHICH): Remove tic6x-c64xp, tic6x-c64x
1344 tic6x-c62x.
1345 * regformats/tic6x-c62x.dat: Remove.
1346 * regformats/tic6x-c64x.dat: Remove.
1347 * regformats/tic6x-c64xp.dat: Remove.
1348
86766165
SM
13492017-10-15 Simon Marchi <simon.marchi@ericsson.com>
1350
1351 * tracepoint.c (parse_traceframe_info): Return a unique_ptr
1352 (the !HAVE_LIBEXPAT version).
1353
824dfcc3
SM
13542017-10-14 Simon Marchi <simon.marchi@ericsson.com>
1355
1356 * nat/linux-osdata.c (struct pid_pgid_entry) <operator<>: Make
1357 const.
1358
2098b393
SM
13592017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1360
1361 * target.h: Include tracepoint.h.
1362 (enum trace_find_type): Move to tracepoint.h.
1363 (struct target_ops) <to_traceframe_info>: Return a unique ptr.
1364 * tracepoint.h: Don't include target.h
1365 (enum trace_find_type): Move from target.h.
1366 (parse_traceframe_info): Return a unique ptr.
1367 * tracepoint.c (current_traceframe_info): Change type to unique
1368 ptr.
1369 (free_traceframe_info): Remove.
1370 (clear_traceframe_info): Don't manually free
1371 current_traceframe_info.
1372 (free_result): Remove.
1373 (parse_traceframe_info): Return a unique ptr.
1374 (get_traceframe_info): Adjust to unique ptr.
1375 * ctf.c (ctf_traceframe_info): Return a unique ptr.
1376 * remote.c (remote_traceframe_info): Return a unique ptr.
1377 * tracefile-tfile.c (tfile_traceframe_info): Return a unique
1378 ptr.
1379 * target-debug.h (target_debug_print_traceframe_info_up): New
1380 macro.
1381 * target-delegates.c: Regenerate.
1382
4cdd21a8
SM
13832017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1384
1385 * memrange.h (struct mem_range): Add constructors.
1386 * tracepoint.h (struct traceframe_info) <memory>: Change type to
1387 std::vector<mem_range>.
1388 * tracepoint.c (free_traceframe_info): Don't manually free
1389 vector.
1390 (traceframe_info_start_memory): Adjust to vector change.
1391 (traceframe_available_memory): Likewise.
1392 * tracefile-tfile.c (build_traceframe_info): Likewise.
1393 * ctf.c (ctf_traceframe_info): Likewise.
1394
d0d292a2
SM
13952017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1396
1397 * tracepoint.h (struct traceframe_info) <tvars>: Change type to
1398 std::vector<int>.
1399 * tracepoint.c (free_traceframe_info): Deallocate with delete.
1400 (traceframe_info_start_tvar): Adjust to vector change.
1401 (parse_traceframe_info): Allocate with new.
1402 * ctf.c (ctf_traceframe_info): Allocate with new, adjust to
1403 vector change.
1404 * tracefile-tfile.c (build_traceframe_info): Adjust to vector
1405 change.
1406 tfile_traceframe_info): Allocate with new.
1407 * mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to vector
1408 change.
1409
8d3c73ef
SM
14102017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1411
1412 * tracepoint.c (traceframe_info): Rename to...
1413 (current_traceframe_info): ...this.
1414 (clear_traceframe_info): Adjust.
1415 (get_traceframe_info): Adjust.
1416
b129dcac
SM
14172017-10-14 Simon Marchi <simon.marchi@ericsson.com>
1418
1419 * nat/linux-osdata.c: Include algorithm.
1420 (compare_processes): Remove.
1421 (struct pid_pgid_entry): New struct.
1422 (linux_xfer_osdata_processgroups): Use std::vector instead of
1423 XNEWVEC.
1424
af5bf4ad
SM
14252017-10-14 Simon Marchi <simon.marchi@ericsson.com>
1426
1427 * objfiles.h: Don't include symfile.h.
1428 (struct partial_symbol): Remove forward-declaration.
1429 (struct objfile) <global_psymbols, static_psymbols>: Change type
1430 to std::vector<partial_symbol *>.
1431 * objfiles.c (objfile::objfile): Don't memset those fields.
1432 (objfile::~objfile): Don't free those fields.
1433 * psympriv.h (struct psymbol_allocation_list): Remove
1434 forward-declaration.
1435 (add_psymbol_to_list): Change psymbol_allocation_list parameter
1436 to std::vector.
1437 (start_psymtab_common): Change parameters to std::vector.
1438 * psymtab.c: Include algorithm.
1439 (require_partial_symbols): Call shrink_to_fit.
1440 (find_pc_sect_psymbol): Adjust to vector change.
1441 (match_partial_symbol): Likewise.
1442 (lookup_partial_symbol): Likewise.
1443 (psym_relocate): Likewise.
1444 (dump_psymtab): Likewise.
1445 (recursively_search_psymtabs): Likewise.
1446 (compare_psymbols): Remove.
1447 (sort_pst_symbols): Adjust to vector change.
1448 (start_psymtab_common): Likewise.
1449 (end_psymtab_common): Likewise.
1450 (psymbol_bcache_full): De-constify return value.
1451 (add_psymbol_to_bcache): Likewise.
1452 (extend_psymbol_list): Remove.
1453 (append_psymbol_to_list): Adjust to vector change.
1454 (add_psymbol_to_list): Likewise.
1455 (init_psymbol_list): Likewise.
1456 (maintenance_info_psymtabs): Likewise.
1457 (maintenance_check_psymtabs): Likewise.
1458 * symfile.h (struct psymbol_allocation_list): Remove.
1459 * symfile.c (reread_symbols): Adjust to vector change.
1460 * dbxread.c (start_psymtab): Change type of parameters.
1461 (dbx_symfile_read): Adjust to vector change.
1462 (read_dbx_symtab): Likewise.
1463 (start_psymtab): Change type of parameters.
1464 * dwarf2read.c (dwarf2_build_psymtabs): Adjust to vector change.
1465 (create_partial_symtab): Likewise.
1466 (add_partial_symbol): Likewise.
1467 (write_one_signatured_type): Likewise.
1468 (recursively_write_psymbols): Likewise.
1469 * mdebugread.c (parse_partial_symbols): Likewise.
1470 * xcoffread.c (xcoff_start_psymtab): Change type of parameters.
1471 (scan_xcoff_symtab): Adjust to vector change.
1472 (xcoff_initial_scan): Likewise.
1473
3ec5942f
SM
14742017-10-13 Simon Marchi <simon.marchi@ericsson.com>
1475
1476 * ada-typeprint.c (print_dynamic_range_bound): Use std::string.
1477
2399fe6a
YQ
14782017-10-13 Yao Qi <yao.qi@linaro.org>
1479
1480 * features/Makefile: Remove tic6x-*-expedite, add tic6x-expedite.
1481 Remove s390x-*-expedite, add s390x-expedite.
1482
4bf3f4a8
YQ
14832017-10-13 Yao Qi <yao.qi@linaro.org>
1484
1485 * features/s390-gs-linux64.c: Regenerated.
1486 * features/s390x-gs-linux64.c: Regenerated.
1487
9e86da07
TT
14882017-10-13 Tom Tromey <tom@tromey.com>
1489
1490 * compile/compile-object-run.c (do_module_cleanup): Use delete.
1491 * solib.c (update_solib_list, reload_shared_libraries_1): Use
1492 delete.
1493 * symfile.c (symbol_file_add_with_addrs): Use new.
1494 (symbol_file_add_separate): Update comment.
1495 (syms_from_objfile_1, remove_symbol_file_command): Use delete.
1496 * jit.c (jit_object_close_impl): Use new.
1497 (jit_unregister_code): Use delete.
1498 * objfiles.c (objfile::objfile): Rename from allocate_objfile.
1499 (~objfile): Rename from free_objfile.
1500 (free_objfile_separate_debug, do_free_objfile_cleanup)
1501 (free_all_objfiles, objfile_purge_solibs): Use delete.
1502 * objfiles.h (struct objfile): Add constructor and destructor.
1503 Use DISABLE_COPY_AND_ASSIGN. Add initializers to data members.
1504 (allocate_objfile, free_objfile): Don't declare.
1505 (struct objstats): Add initializers.
1506
c2508e90
SM
15072017-10-12 Simon Marchi <simon.marchi@ericsson.com>
1508
1509 * arch-utils.h (simple_displaced_step_copy_insn): Remove.
1510 * arch-utils.c (simple_displaced_step_copy_insn): Remove.
1511 * gdbarch.sh (displaced_step_copy_insn): Adjust comment.
1512 * gdbarch.h: Regenerate.
1513 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
1514 Adjust comment.
1515 * i386-tdep.c (i386_displaced_step_copy_insn): Adjust comment.
1516 (i386_displaced_step_fixup): Adjust comment.
1517 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Adjust comment.
1518
a900ff72
TT
15192017-10-12 Tom Tromey <tom@tromey.com>
1520
1521 * prologue-value.h (pv_area::store_would_trash): Return bool.
1522 (pv_area::find_reg): Likewise.
1523 * prologue-value.c (pv_area::store_would_trash): Return bool.
1524 (pv_area::find_reg): Likewise.
1525
f7b7ed97
TT
15262017-10-12 Tom Tromey <tom@tromey.com>
1527
1528 * s390-linux-tdep.c (s390_store, s390_load)
1529 (s390_check_for_saved, s390_analyze_prologue): Update.
1530 * rx-tdep.c (check_for_saved, rx_analyze_prologue): Update.
1531 * rl78-tdep.c (rl78_analyze_prologue, check_for_saved): Update.
1532 * prologue-value.h (class pv_area): Move from prologue-value.c.
1533 Change names of members. Add constructor, destructor, member
1534 functions.
1535 (make_pv_area, free_pv_area, make_cleanup_free_pv_area)
1536 (pv_area_store, pv_area_fetch, pv_area_store_would_trash)
1537 (pv_area_fetch, pv_area_scan): Don't declare.
1538 * prologue-value.c (struct pv_area::area_entry): Now member of
1539 pv_area.
1540 (struct pv_area): Move to prologue-value.h.
1541 (pv_area::pv_area): Rename from make_pv_area.
1542 (pv_area::~pv_area): Rename from free_pv_area.
1543 (do_free_pv_area_cleanup, make_cleanup_free_pv_area): Remove.
1544 (clear_entries, find_entry, overlaps, store_would_trash, store)
1545 (fetch, find_reg, scan): Now member of pv_area.
1546 Remove "area" argument. Update.
1547 * msp430-tdep.c (check_for_saved, msp430_analyze_prologue):
1548 Update.
1549 * mn10300-tdep.c (push_reg, check_for_saved)
1550 (mn10300_analyze_prologue): Update.
1551 * mep-tdep.c (is_arg_spill, check_for_saved)
1552 (mep_analyze_prologue): Update.
1553 * m32c-tdep.c (m32c_pv_push, m32c_srcdest_fetch)
1554 (m32c_srcdest_store, m32c_pv_enter, m32c_is_arg_spill)
1555 (m32c_is_struct_return, m32c_analyze_prologue): Update.
1556 * arm-tdep.c (thumb_analyze_prologue, arm_analyze_prologue):
1557 Update.
1558 * arc-tdep.c (arc_is_in_prologue, arc_analyze_prologue): Update.
1559 * aarch64-tdep.c (aarch64_analyze_prologue): Update.
1560
466eecee
SM
15612017-10-12 Simon Marchi <simon.marchi@ericsson.com>
1562
1563 * linux-nat.h (linux_nat_set_delete_thread): New declaration.
1564 * linux-nat.c (linux_nat_delete_thread): New variable.
1565 (lwp_free): Invoke linux_nat_delete_thread if set.
1566 (linux_nat_set_delete_thread): New function.
1567 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Assign
1568 thread delete callback.
1569 * arm-linux-nat.c (arm_linux_delete_thread): New function.
1570 (_initialize_arm_linux_nat): Assign thread delete callback.
1571 * s390-linux-nat.c (s390_delete_thread): New function.
1572 (_initialize_s390_nat): Assign thread delete callback.
1573 * x86-linux-nat.c (x86_linux_add_target): Likewise.
1574 * nat/aarch64-linux.c (aarch64_linux_delete_thread): New
1575 function.
1576 * nat/aarch64-linux.h (aarch64_linux_delete_thread): New
1577 declaration.
1578 * nat/x86-linux.c (x86_linux_delete_thread): New function.
1579 * nat/x86-linux.h (x86_linux_delete_thread): New declaration.
1580
f71c8822
TT
15812017-10-09 Tom Tromey <tom@tromey.com>
1582
1583 * tui/tui-win.c (tui_set_win_height, parse_scrolling_args): Use
1584 std::string.
1585 * tui/tui-layout.c (enum tui_status): Use std::string.
1586
981a3fb3
TT
15872017-10-11 Tom Tromey <tom@tromey.com>
1588
1589 * gdbthread.h (thread_command): Constify.
1590 * inferior.h (detach_command): Constify.
1591 * top.h (set_history, show_history): Constify.
1592 * arm-tdep.c (set_arm_command, show_arm_command): Constify.
1593 * serial.c (serial_set_cmd, serial_show_cmd): Constify.
1594 * bsd-kvm.c (bsd_kvm_cmd): Constify.
1595 * printcmd.c (set_command): Constify.
1596 (non_const_set_command): New function.
1597 * dcache.c (set_dcache_command, show_dcache_command): Constify.
1598 * breakpoint.c (enable_command, disable_command, delete_command)
1599 (catch_command, tcatch_command, set_breakpoint_cmd)
1600 (show_breakpoint_cmd): Constify.
1601 * macrocmd.c (macro_command): Constify.
1602 * infcmd.c (unset_command, kill_command, detach_command)
1603 (info_proc_cmd): Constify.
1604 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Constify.
1605 * auto-load.c (show_auto_load_cmd, set_auto_load_cmd)
1606 (info_auto_load_cmd): Constify.
1607 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
1608 (unset_tdesc_cmd): Constify.
1609 * ada-lang.c (set_ada_command, show_ada_command)
1610 (maint_set_ada_cmd, maint_show_ada_cmd): Constify.
1611 * guile/guile.c (set_guile_command, show_guile_command)
1612 (info_guile_command): Constify.
1613 * tui/tui-win.c (tui_command, set_tui_cmd, show_tui_cmd):
1614 Constify.
1615 * skip.c (skip_command): Constify.
1616 * compile/compile.c (_initialize_compile): Constify.
1617 * dwarf2read.c (set_dwarf_cmd, show_dwarf_cmd): Constify.
1618 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
1619 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
1620 (maint_btrace_pt_show_cmd): Constify.
1621 * remote.c (set_remote_cmd, show_remote_cmd, remote_command):
1622 Constify.
1623 * python/python.c (user_show_python, user_set_python): Constify.
1624 * mips-tdep.c (set_mips_command, show_mips_command)
1625 (set_mipsfpu_command): Constify.
1626 * record-btrace.c (cmd_record_btrace_start)
1627 (cmd_set_record_btrace, cmd_show_record_btrace)
1628 (cmd_set_record_btrace_bts, cmd_show_record_btrace_bts)
1629 (cmd_set_record_btrace_pt, cmd_show_record_btrace_pt): Constify.
1630 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command):
1631 Constify.
1632 * symfile.c (overlay_command): Constify.
1633 * spu-tdep.c (set_spu_command, show_spu_command): Constify.
1634 * cli/cli-logging.c (set_logging_command, show_logging_command):
1635 Constify.
1636 * cli/cli-dump.c (dump_command, append_command)
1637 (srec_dump_command, ihex_dump_command, verilog_dump_command)
1638 (tekhex_dump_command, binary_dump_command)
1639 (binary_append_command): Constify.
1640 * cli/cli-decode.c (struct cmd_list_element): Change type of
1641 "fun".
1642 * cli/cli-cmds.c (info_command, show_command, set_debug)
1643 (show_debug): Constify.
1644 (show_command): Add non-const overload.
1645 * top.c (set_history, show_history): Constify.
1646 * sh-tdep.c (set_sh_command, show_sh_command): Constify.
1647 * command.h (add_prefix_cmd): Accept a cmd_const_cfunc_ftype.
1648 * target.c (target_command): Constify.
1649 * sparc64-tdep.c (info_adi_command): Constify.
1650 * record-full.c (cmd_record_full_start): Constify.
1651 (set_record_full_command): Constify. Fix typo.
1652 (show_record_full_command): Constify.
1653 * thread.c (thread_command, thread_apply_command): Constify.
1654 * memattr.c (dummy_cmd): Constify.
1655 * value.c (function_command): Constify.
1656 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Constify.
1657 * probe.c (info_probes_command): Constify.
1658 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Constify.
1659 * gnu-nat.c (set_task_cmd, show_task_cmd, set_thread_cmd)
1660 (show_thread_cmd, set_thread_default_cmd)
1661 (show_thread_default_cmd): Constify.
1662 (check_empty): Constify.
1663 * tracepoint.c (tfind_command): Constify.
1664 * cp-support.c (maint_cplus_command): Constify.
1665 * windows-tdep.c (info_w32_command): Constify.
1666 * record.c (cmd_record_start, set_record_command)
1667 (show_record_command, info_record_command, cmd_record_goto):
1668 Constify.
1669 * ravenscar-thread.c (set_ravenscar_command)
1670 (show_ravenscar_command): Constify.
1671 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
1672 Constify.
1673 (add_internal_problem_command): Remove casts.
1674 * arc-tdep.c (maintenance_print_arc_command): Constify.
1675 * valprint.c (set_print, show_print, set_print_raw)
1676 (show_print_raw): Constify.
1677 * maint.c (maintenance_command, maintenance_info_command)
1678 (maintenance_print_command, maintenance_set_cmd)
1679 (maintenance_show_cmd, set_per_command_cmd)
1680 (show_per_command_cmd, maintenance_check_command): Constify.
1681 * language.c (set_check, show_check): Constify.
1682 * typeprint.c (show_print_type, set_print_type): Constify.
1683 * go32-nat.c (go32_info_dos_command): Constify.
1684
fdf44873
TT
16852017-10-11 Tom Tromey <tom@tromey.com>
1686
1687 * breakpoint.c (prepare_re_set_context): Remove.
1688 (breakpoint_re_set_one): Update. Don't use cleanups.
1689 (breakpoint_re_set): Use scoped_restore, std::string, and
1690 scoped_restore_current_language.
1691
81b1e71c
TT
16922017-10-11 Tom Tromey <tom@tromey.com>
1693
1694 * breakpoint.c (commands_command_1): Use std::string.
1695 (cleanup_executing_breakpoints): Remove.
1696 (bpstat_do_actions_1): Use scoped_restore.
1697 (bpstat_check_watchpoint): Use std::string.
1698 (decode_static_tracepoint_spec): Likewise.
1699 (break_range_command): Likewise.
1700 (watch_command_1): Likewise.
1701 (compare_breakpoints): Change argument types.
1702 (clear_command): Use std::vector.
1703 (cleanup_executing_breakpoints): Remove.
1704 (update_global_location_list): Use unique_xmalloc_ptr.
1705 (strace_command): Remove unused declaration.
1706
4f9d9906
JB
17072017-10-11 John Baldwin <jhb@FreeBSD.org>
1708
1709 * Makefile.in (ALLDEPFILES): Add arm-fbsd-nat.c.
1710 * NEWS: Mention new FreeBSD/arm native configuration.
1711 * configure.host: Add arm*-*-freebsd*.
1712 * configure.nat: Likewise.
1713 * arm-fbsd-nat.c: New file.
1714
7176dfd2
JB
17152017-10-11 John Baldwin <jhb@FreeBSD.org>
1716
1717 * Makefile.in (ALL_TARGET_OBS): Add arm-fbsd-tdep.o.
1718 (ALLDEPFILES): Add arm-fbsd-tdep.c.
1719 * NEWS: Mention new FreeBSD/arm target.
1720 * configure.tgt: Add arm*-*-freebsd*.
1721 * arm-fbsd-tdep.c: New file.
1722 * arm-fbsd-tdep.h: New file.
1723
fe220226
MR
17242017-10-11 Maciej W. Rozycki <macro@imgtec.com>
1725
1726 * linux-tdep.c (linux_make_corefile_notes): Remove call to
1727 `gdbarch_elfcore_write_linux_prpsinfo'.
1728 * gdbarch.sh (elfcore_write_linux_prpsinfo): Remove architecture
1729 method.
1730 (elf_internal_linux_prpsinfo): Remove declaration.
1731 * gdbarch.h: Regenerate.
1732 * gdbarch.c: Regenerate.
1733
a2f63b2e
MR
17342017-10-11 Maciej W. Rozycki <macro@imgtec.com>
1735
1736 * ppc-linux-tdep.c (ppc_linux_init_abi): Remove call to
1737 `set_gdbarch_elfcore_write_linux_prpsinfo'.
1738
458ca1d0
PA
17392017-10-11 Pedro Alves <palves@redhat.com>
1740
1741 * breakpoint.c (reattach_breakpoints): Delete.
1742 * breakpoint.h (reattach_breakpoints): Delete.
1743
905014d7
SM
17442017-10-11 Simon Marchi <simon.marchi@ericsson.com>
1745
1746 * symfile.c (registered_sym_fns): Make struct, not typedef.
1747 (DEF_VEC_O (registered_sym_fns)): Remove.
1748 (symtab_fns): Change type to std::vector.
1749 (add_symtab_fns): Adjust.
1750 (find_sym_fns): Adjust.
1751
56d704da
AK
17522017-10-11 Anton Kolesov <Anton.Kolesov@synopsys.com>
1753
1754 * arc-tdep.c (arc_gdbarch_init): Pass proper cpu value to disassembler.
1755 * arc-tdep.h (arc_arch_is_em): New function.
1756 (arc_arch_is_hs): Likewise.
1757
7fa29be9
EB
17582017-10-11 Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
1759
1760 * macrotab.h (macro_lookup_inclusion): Remove unnecessary
1761 parentheses in the declaration.
1762 (macro_lookup_inclusion): Likewise.
1763 (macro_lookup_definition): Likewise.
1764 * p-lang.h (pascal_builtin_types): Likewise.
1765 * tui/tui-data.c (tui_win_list): Likewise.
1766 * tui/tui-data.h (tui_win_list): Likewise.
1767 * utils.h (make_cleanup_free_section_addr_info): Likewise.
1768
d9b477e3
KB
17692017-10-11 Mark Rages <markrages@gmail.com>
1770
1771 * target-memory.c (block_boundaries): Fix for block address not
1772 aligned on block size.
1773
65630365
PA
17742017-10-10 Pedro Alves <palves@redhat.com>
1775 Tom Tromey <tom@tromey.com>
1776
1777 * breakpoint.c (struct captured_breakpoint_query_args)
1778 (do_captured_breakpoint_query, gdb_breakpoint_query): Delete.
1779 (print_breakpoint): New.
1780 * breakpoint.h (print_breakpoint): Declare.
1781 * common/common-exceptions.h (enum return_reason): Remove
1782 references to catch_exceptions.
1783 * exceptions.c (catch_exceptions, catch_exceptions_with_msg):
1784 Delete.
1785 * exceptions.h (catch_exceptions_ftype, catch_exceptions)
1786 (catch_exception_ftype, catch_exceptions_with_msg): Delete.
1787 * gdb.h: Delete.
1788 * gdbthread.h (thread_select): Declare.
1789 * mi/mi-cmd-break.c: Don't include gdb.h.
1790 (breakpoint_notify): Use print_breakpoint.
1791 * mi/mi-cmd-catch.c: Don't include gdb.h.
1792 * mi/mi-interp.c: Don't include gdb.h.
1793 (mi_print_breakpoint_for_event): New.
1794 (mi_breakpoint_created, mi_breakpoint_modified): Use
1795 mi_print_breakpoint_for_event.
1796 * mi/mi-main.c: Don't include gdb.h.
1797 (mi_cmd_thread_select): Parse the global thread ID here. Use
1798 thread_select instead of gdb_thread_select.
1799 (mi_cmd_thread_list_ids): Output "thread-ids" tuple here instead
1800 of using gdb_list_thread_ids.
1801 * remote-fileio.c (do_remote_fileio_request): Change type. Reply
1802 FILEIO_ENOSYS here.
1803 (remote_fileio_request): Use TRY/CATCH instead of
1804 catch_exceptions.
1805 * symfile-mem.c (struct symbol_file_add_from_memory_args)
1806 (symbol_file_add_from_memory_wrapper): Delete.
1807 (add_vsyscall_page): Use TRY/CATCH instead of catch_exceptions.
1808 * thread.c: Don't include gdb.h.
1809 (do_captured_list_thread_ids, gdb_list_thread_ids): Delete.
1810 (thread_alive): Use thread_select.
1811 (do_captured_thread_select): Delete, parts salvaged as ...
1812 (thread_select): ... this new function.
1813 (gdb_thread_select): Delete.
1814
bf469271
PA
18152017-10-10 Pedro Alves <palves@redhat.com>
1816 Tom Tromey <tom@tromey.com>
1817
1818 * breakpoint.c (breakpoint_cond_eval): Change return type to bool
1819 and reverse logic.
1820 (WP_DELETED, WP_VALUE_CHANGED, WP_VALUE_NOT_CHANGED, WP_IGNORE):
1821 No longer macros. Instead ...
1822 (enum wp_check_result): They're now values of this new
1823 enumeration.
1824 (watchpoint_check): Change return type to wp_check_result and
1825 parameter type to bpstat.
1826 (bpstat_check_watchpoint): Use TRY/CATCH instead of catch_errors.
1827 (bpstat_check_breakpoint_conditions): Use TRY/CATCH instead of
1828 catch_errors. Reverse logic of watchpoint_check call.
1829 (breakpoint_re_set_one): Now returns void and takes a breakpoint
1830 pointer as parameter.
1831 (breakpoint_re_set): Use TRY/CATCH instead of catch_errors.
1832 * common/common-exceptions.c (throw_exception_sjlj): Update
1833 comments to avoid mentioning catch_errors.
1834 * exceptions.c (catch_errors): Delete.
1835 * exceptions.h: Update comments to avoid mentioning catch_errors.
1836 (catch_errors_ftype, catch_errors): Delete.
1837 * infrun.c (normal_stop): Use TRY/CATCH instead of catch_errors.
1838 (hook_stop_stub): Delete.
1839 (restore_selected_frame): Change return type to void, and
1840 parameter type to const frame_id &.
1841 (restore_infcall_control_state): Use TRY/CATCH instead of
1842 catch_errors.
1843 * main.c (captured_command_loop): Return void and remove
1844 parameter. Remove references to catch_errors.
1845 (captured_main): Use TRY/CATCH instead of catch_errors.
1846 * objc-lang.c (objc_submethod_helper_data)
1847 (find_objc_msgcall_submethod_helper): Delete.
1848 (find_objc_msgcall_submethod): Use TRY/CATCH instead of
1849 catch_errors.
1850 * record-full.c (record_full_message): Return void.
1851 (record_full_message_args, record_full_message_wrapper): Delete.
1852 (record_full_message_wrapper_safe): Return bool and use TRY/CATCH
1853 instead of catch_errors.
1854 * solib-aix.c (solib_aix_open_symbol_file_object): Change
1855 parameter type to int.
1856 * solib-darwin.c (open_symbol_file_object): Ditto.
1857 * solib-dsbt.c (open_symbol_file_object): Ditto.
1858 * solib-frv.c (open_symbol_file_object): Ditto.
1859 * solib-svr4.c (open_symbol_file_object): Ditto.
1860 * solib-target.c (solib_target_open_symbol_file_object): Ditto.
1861 * solib.c (update_solib_list): Use TRY/CATCH instead of
1862 catch_errors.
1863 * solist.h (struct target_so_ops) <open_symbol_file_object>:
1864 Change type.
1865 * symmisc.c (struct print_symbol_args): Remove.
1866 (dump_symtab_1): Use TRY/CATCH instead of catch_errors.
1867 (print_symbol): Change type.
1868 * windows-nat.c (handle_load_dll, handle_unload_dll): Return void
1869 and remove parameters.
1870 (catch_errors): New.
1871 (get_windows_debug_event): Adjust.
1872
1a56bfa5
TT
18732017-10-09 Tom Tromey <tom@tromey.com>
1874
1875 * mi/mi-main.c (free_splay_tree): Remove.
1876 (list_available_thread_groups): Use splay_tree_up.
1877 * common/gdb_splay_tree.h: New file.
1878
0c478e2d
TT
18792017-10-09 Tom Tromey <tom@tromey.com>
1880
1881 * mi/mi-main.c (do_nothing): Remove.
1882 (list_available_thread_groups): Update.
1883
cbd2b4e3
PA
18842017-10-09 Pedro Alves <palves@redhat.com>
1885
1886 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>: Skip
1887 reading registers when switching context.
1888
a181c0bf
JB
18892017-10-09 John Baldwin <jhb@FreeBSD.org>
1890
1891 * fbsd-nat.c (fbsd_siginfo_size): Use gdbarch_long_bit.
1892 (fbsd_convert_siginfo): Likewise.
1893 * fbsd-tdep.c (fbsd_core_xfer_siginfo): Likewise.
1894
6e66f753
SM
18952017-10-09 Simon Marchi <simon.marchi@polymtl.ca>
1896
1897 * configure.ac (try_guile_versions): Remove guile-2.2.
1898 * configure: Regenerate.
1899
890e9790
TT
19002017-10-09 Tom Tromey <tom@tromey.com>
1901
1902 * Makefile.in (COMPILE.post, POSTCOMPILE): Restore $(basename).
1903 (COMPILE.pre): Use $(CXX).
1904
109483d9
PA
19052017-10-09 Pedro Alves <palves@redhat.com>
1906
1907 * cp-support.c (cp_remove_params): Return a gdb::unique_xmalloc_ptr.
1908 Use bool.
1909 (overload_list_add_symbol): Adjust to use gdb::unique_xmalloc_ptr.
1910 * cp-support.h (cp_remove_params): Now returns a
1911 gdb::unique_xmalloc_ptr.
1912 * dwarf2read.c (find_slot_in_mapped_hash): Now returns bool.
1913 Adjust to cp_remove_params returning a gdb::unique_xmalloc_ptr.
1914 * psymtab.c (psymtab_search_name): Adjust to cp_remove_params
1915 returning a gdb::unique_xmalloc_ptr.
1916 (lookup_partial_symbol): Adjust to use gdb::unique_xmalloc_ptr.
1917 * stack.c (find_frame_funname): Adjust to cp_remove_params
1918 returning a gdb::unique_xmalloc_ptr.
1919
791afaa2
TT
19202017-10-08 Tom Tromey <tom@tromey.com>
1921
1922 * dwarf2read.c (dwarf2_get_dwz_file): Use
1923 gdb::unique_xmalloc_ptr.
1924 (find_slot_in_mapped_hash): Likewise.
1925 (dwarf2_physname): Likewise.
1926 (create_dwo_unit_in_dwp_v1): Use std::string.
1927 (create_dwo_unit_in_dwp_v2): Likewise.
1928 (lookup_dwo_cutu): Likewise.
1929 (inherit_abstract_dies): Use std::vector.
1930 (read_array_type): Likewise.
1931 (dwarf_decode_macros): Remove unused declaration.
1932 (unsigned_int_compar): Remove.
1933 (dwarf2_build_psymtabs_hard): Use scoped_restore.
1934 (psymtabs_addrmap_cleanup): Remove.
1935
30a9c02f
TT
19362017-10-08 Tom Tromey <tom@tromey.com>
1937
1938 * frame-unwind.c (frame_unwind_try_unwinder): Update.
1939 * frame.h (frame_cleanup_after_sniffer): Declare.
1940 (frame_prepare_for_sniffer): Return void.
1941 * frame.c (frame_cleanup_after_sniffer): No longer static. Change
1942 type of argument.
1943 (frame_prepare_for_sniffer): Return void.
1944
757325a3
TT
19452017-10-08 Tom Tromey <tom@tromey.com>
1946
1947 * utils.h (make_cleanup_value_free): Remove.
1948 * utils.c (do_value_free, struct cleanup): Remove.
1949 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full) <DWARF_VALUE_STACK>:
1950 Use gdb_value_up.
1951 * value.h (struct value_deleter): New.
1952 (gdb_value_up): New typedef.
1953
b9c04fb2
TT
19542017-10-08 Tom Tromey <tom@tromey.com>
1955
1956 * symtab.c (free_search_symbols, do_free_search_symbols_cleanup)
1957 (make_cleanup_free_search_symbols): Remove.
1958 (search_symbols): Return std::vector.
1959 (symbol_search::compare_search_syms): Now member of
1960 symbol_search. Change arguments.
1961 (sort_search_symbols_remove_dups): Change arguments. Rewrite.
1962 (symtab_symbol_info, rbreak_command): Update.
1963 * symtab.h (struct symbol_search) <next>: Remove.
1964 Add constructors.
1965 (symbol_search::operator<): New function.
1966 (symbol_search::operator==): New function.
1967 (search_symbols): Remove std::vector.
1968 (free_search_symbols, make_cleanup_free_search_symbols): Remove.
1969 (symbol_search::compare_search_syms): Declare.
1970
0d28b0a5
YQ
19712017-10-06 Yao Qi <yao.qi@linaro.org>
1972
1973 * Makefile.in (ALL_64_TARGET_OBS): Replace aarch64-insn.o with
1974 arch/aarch64-insn.o.
1975 Remove one rule.
1976 * configure.tgt: Replace aarch64-insn.o with arch/aarch64-insn.o.
1977
71917808
YQ
19782017-10-06 Yao Qi <yao.qi@linaro.org>
1979
1980 * Makefile.in (ALL_TARGET_OBS): Replace arm.o, arm-get-next-pcs.o,
1981 and arm-linux.o with arch/arm.o, arch/arm-get-next-pcs.o and
1982 arch/arm-linux.o respectively.
1983 * configure.tgt: Likewise.
1984
2081b2b2
YQ
19852017-10-06 Yao Qi <yao.qi@linaro.org>
1986
1987 * Makefile.in (ALL_TARGET_OBS): Rename i386.o to arch/i386.o.
1988 * configure.tgt (i386_tobjs): Replace i386.o with arch/i386.o.
1989
a1b85d28
PA
19902017-10-06 Pedro Alves <palves@redhat.com>
1991
1992 * windows-nat.c: Include <algorithm>.
1993
d97987e2
YQ
19942017-10-06 Yao Qi <yao.qi@linaro.org>
1995
1996 * configure.tgt (i386_tobjs): New variable.
1997 (amd64_tobjs): New variable.
1998 Set $cpu_obs and $os_obs.
1999
f38307f5
YQ
20002017-10-06 Yao Qi <yao.qi@linaro.org>
2001
2002 * Makefile.in (CONFIG_SRC_SUBDIR): New.
2003 (ALL_64_TARGET_OBS): Replace amd64.o with arch/amd64.o.
2004 (clean): Remove object files and dependency files.
2005 (distclean): Remove the directory.
2006 * configure.ac: Invoke AC_CONFIG_COMMANDS.
2007 * configure: Re-generated.
2008 * configure.tgt: Replace amd64.o with arch/amd64.o.
2009
2f924de6
JM
20102017-10-05 Jose E. Marchesi <jose.marchesi@oracle.com>
2011
2012 PR build/22188
2013 * arm-tdep.c (arm_decode_misc_memhint_neon): Fix decoding of CPS
2014 and SETEND.
2015
2fd9d7ca
PA
20162017-10-05 Pedro Alves <palves@redhat.com>
2017
2018 * linux-nat.c (linux_child_follow_fork): When following the parent
2019 and detaching the child, consult the parent thread's architecture
2020 instead of the child's.
2021
d13b8493
UW
20222017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
2023
2024 * ax.h: Do not include "doublest.h".
2025 (union agent_val): Remove.
2026
3b4b2f16
UW
20272017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
2028
2029 * dfp.h (MAX_DECIMAL_STRING): Move to dfp.c.
2030 (decimal_to_string): Return std::string object.
2031 (decimal_from_string): Accept std::string object. Return bool.
2032 (decimal_from_integral, decimal_from_doublest): Remove.
2033 (decimal_from_longest): Add prototype.
2034 (decimal_from_ulongest): Likewise.
2035 (decimal_to_longest): Likewise.
2036 (decimal_from_doublest): Likewise.
2037 * dfp.c: Do not include "gdbtypes.h" or "value.h".
2038 (MAX_DECIMAL_STRING): Move here.
2039 (decimal_to_string): Return std::string object.
2040 (decimal_from_string): Accept std::string object. Return bool.
2041 (decimal_from_integral): Remove, replace by ...
2042 (decimal_from_longest, decimal_from_ulongest): ... these new functions.
2043 (decimal_to_longest): New function.
2044 (decimal_from_floating): Remove, replace by ...
2045 (decimal_from_doublest): ... this new function.
2046 (decimal_to_doublest): Update to new decimal_to_string interface.
2047
2048 * value.c (unpack_long): Use decimal_to_longest.
2049 * valops.c (value_cast): Use decimal_from_doublest instead of
2050 decimal_from_floating. Use decimal_from_[u]longest isntead of
2051 decimal_from_integral.
2052 * valarith.c (value_args_as_decimal): Likewise.
2053 * valprint.c (print_decimal_floating): Update to new
2054 decimal_to_string interface.
2055 * printcmd.c (printf_decfloat): Likewise.
2056 * c-exp.y (parse_number): Update to new decimal_from_string interface.
2057
1841ee5d
UW
20582017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
2059
2060 * doublest.h: Do not include "floatformat.h". Remove stale comments.
2061 * gdbtypes.c: Include "floatformat.h".
2062 * value.c: Likewise.
2063 * m68k-tdep.c: Likewise.
2064
2065 * findvar.c: Do not include "floatformat.h".
2066 * amd64-darwin-tdep.c: Likewise.
2067 * arm-linux-tdep.c: Likewise.
2068 * i386-darwin-tdep.c: Likewise.
2069 * i387-tdep.c: Likewise.
2070 * m68k-linux-tdep.c: Likewise.
2071 * mep-tdep.c: Likewise.
2072 * mips-tdep.c: Likewise.
2073 * nios2-tdep.c: Likewise.
2074 * s390-linux-tdep.c: Likewise.
2075 * sparc-obsd-tdep.c: Likewise.
2076 * sparc-tdep.c: Likewise.
2077 * sparc64-tdep.c: Likewise.
2078 * spu-tdep.c: Likewise.
2079 * tic6x-tdep.c: Likewise.
2080 * tilegx-tdep.c: Likewise.
2081 * vax-tdep.c: Likewise.
2082 * xstormy16-tdep.c: Likewise.
2083 * xtensa-tdep.c: Likewise.
2084
2085 * top.c: Do not include "doublest.h".
2086 * aarch64-tdep.c: Likewise.
2087 * alpha-tdep.c: Likewise.
2088 * arm-linux-tdep.c: Likewise.
2089 * m68k-linux-tdep.c: Likewise.
2090 * tilegx-tdep.c: Likewise.
2091 * xstormy16-tdep.c: Likewise.
2092
a80a6471
JB
20932017-10-05 John Baldwin <jhb@FreeBSD.org>
2094
2095 * mips-fbsd-tdep.c (MIPS_INST_ADDIU_A0_SP_N32): Define.
2096 (mipsn32_fbsd_sigframe): Define.
2097 (mips_fbsd_init_abi): Install mipsn32_fbsd_sigframe unwinder
2098 for FreeBSD/mipsn32.
2099
12c4bd7f
JB
21002017-10-05 John Baldwin <jhb@FreeBSD.org>
2101
2102 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_EHDRFLAGS and
2103 AT_HWCAP.
2104
c91933e9
TG
21052017-10-05 Tristan Gingold <tgingold@free.fr>
2106
2107 * MAINTAINERS (Misc): Update my email address.
2108
5cd63fda
PA
21092017-10-04 Pedro Alves <palves@redhat.com>
2110
2111 * remote.c (get_remote_arch_state): New 'gdbarch' parameter. Use
2112 it instead of target_gdbarch.
2113 (get_remote_state, get_remote_packet_size): Adjust
2114 get_remote_arch_state calls, passing down target_gdbarch
2115 explicitly.
2116 (packet_reg_from_regnum, packet_reg_from_pnum): New parameter
2117 'gdbarch' and use it instead of target_gdbarch.
2118 (get_memory_packet_size): Adjust get_remote_arch_state calls,
2119 passing down target_gdbarch explicitly.
2120 (struct stop_reply) <arch>: New field.
2121 (remote_parse_stop_reply): Use the stopped thread's architecture,
2122 not the current inferior's. Save the architecture in the
2123 stop_reply.
2124 (process_stop_reply): Use the stop reply's architecture.
2125 (process_g_packet, remote_fetch_registers)
2126 (remote_prepare_to_store, store_registers_using_G)
2127 (remote_store_registers): Adjust get_remote_arch_state calls,
2128 using the regcache's architecture.
2129 (remote_get_trace_status): Adjust get_remote_arch_state calls,
2130 passing down target_gdbarch explicitly.
2131 * spu-multiarch.c (spu_thread_architecture): Defer to the target
2132 beneath instead of calling target_gdbarch.
2133 * target.c (default_thread_architecture): Use the specified
2134 inferior's architecture, instead of the current inferior's
2135 architecture (via target_gdbarch).
2136
ed4227b7
PA
21372017-10-04 Pedro Alves <palves@redhat.com>
2138
2139 * regcache.c (get_thread_arch_regcache): Remove null_ptid special
2140 case.
2141 (regcache_print): Handle !target_has_registers here instead.
2142
55b11ddf
PA
21432017-10-04 Pedro Alves <palves@redhat.com>
2144
2145 * frame.c (create_test_frame): Delete.
2146 * frame.h (create_test_frame): Delete.
2147 * gdbarch-selftests.c: Include gdbthread.h and target.h.
2148 (class regcache_test): Delete.
2149 (test_target_has_registers, test_target_has_stack)
2150 (test_target_has_memory, test_target_prepare_to_store)
2151 (test_target_store_registers): New functions.
2152 (test_target_ops): New class.
2153 (register_to_value_test): Error out if there's already a
2154 process_stratum (or higher) target pushed. Create a fuller mock
2155 environment, with mock target_ops, inferior, address space, thread
2156 and inferior_ptid.
2157 * progspace.c (struct address_space): Move to ...
2158 * progspace.h (struct address_space): ... here.
2159 * regcache.h (regcache::~regcache, regcache::raw_write)
2160 [GDB_SELF_TEST]: No longer virtual.
2161
4c71c105
SM
21622017-10-04 Simon Marchi <simon.marchi@ericsson.com>
2163
2164 * mi/mi-main.c (list_available_thread_groups): Reverse filter logic.
2165
73dcd72d
PA
21662017-10-04 Pedro Alves <palves@redhat.com>
2167
2168 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Move code
2169 out of 'between TRY and CATCH'.
2170
44704526
PA
21712017-10-04 Pedro Alves <palves@redhat.com>
2172
2173 * cli/cli-cmds.c (complete_command): Add missing END_CATCH.
2174 * common/common-exceptions.h (TRY): Open an outermost scope.
2175 Expand intro comment.
2176 (CATCH): Reindent.
2177 (END_CATCH): Close the outermost scope.
2178 * completer.c (complete_line_internal): Add missing END_CATCH.
2179
bc3b087d
SDJ
21802017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2181
2182 * NEWS (Changes since GDB 8.0): Add entry about new
2183 'set-cwd-on-gdbserver' feature.
2184 (New remote packets): Add entry for QSetWorkingDir.
2185 * common/common-inferior.h (set_inferior_cwd): New prototype.
2186 * infcmd.c (set_inferior_cwd): Remove "static".
2187 (show_cwd_command): Expand text to include remote debugging.
2188 * remote.c: Add PACKET_QSetWorkingDir.
2189 (remote_protocol_features) <QSetWorkingDir>: New entry for
2190 PACKET_QSetWorkingDir.
2191 (extended_remote_set_inferior_cwd): New function.
2192 (extended_remote_create_inferior): Call
2193 "extended_remote_set_inferior_cwd".
2194 (_initialize_remote): Call "add_packet_config_cmd" for
2195 QSetWorkingDir.
2196
d092c5a2
SDJ
21972017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2198
2199 * NEWS (New commands): Mention "set/show cwd".
2200 * cli/cli-cmds.c (_initialize_cli_cmds): Mention "set cwd" on
2201 "cd" command's help text.
2202 * common/common-inferior.h (get_inferior_cwd): New prototype.
2203 * infcmd.c (inferior_cwd_scratch): New global variable.
2204 (set_inferior_cwd): New function.
2205 (get_inferior_cwd): Likewise.
2206 (set_cwd_command): Likewise.
2207 (show_cwd_command): Likewise.
2208 (_initialize_infcmd): Add "set/show cwd" commands.
2209 * inferior.h (class inferior) <cwd>: New field.
2210 * nat/fork-inferior.c: Include "gdb_tilde_expand.h".
2211 (fork_inferior): Change inferior's cwd before its execution.
2212 * windows-nat.c (windows_create_inferior): Pass inferior's cwd
2213 to CreateProcess.
2214
7da0a886
SDJ
22152017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2216
2217 * Makefile.in (SFILES): Add gdb_tilde_expand.c.
2218 (HFILES_NO_SRCDIR): Add gdb_tilde_expand.h.
2219 (COMMON_OBS): Add gdb_tilde_expand.o.
2220 * common/gdb_tilde_expand.c: New file.
2221 * common/gdb_tilde_expand.h: Likewise.
2222
db8dd160
MR
22232017-10-03 Maciej W. Rozycki <macro@imgtec.com>
2224
2225 * gdbarch.sh (objfile): Remove duplicate declaration.
2226 * gdbarch.h: Regenerate.
2227
f8bfbf22
TT
22282017-10-03 Tom Tromey <tom@tromey.com>
2229
2230 * utils.c (internal_vproblem): Use string_vprintf.
2231
5178ed48
TT
22322017-10-03 Tom Tromey <tom@tromey.com>
2233
2234 * printcmd.c (info_symbol_command): Use std::string.
2235
8cff8730
TT
22362017-10-03 Tom Tromey <tom@tromey.com>
2237
2238 * top.c (gdb_safe_append_history): Use std::string.
2239
895b8f30
TT
22402017-10-03 Tom Tromey <tom@tromey.com>
2241
2242 * event-top.c (stdin_event_handler): Update.
2243 * main.c (captured_main_1): Update.
2244 * top.h (make_delete_ui_cleanup): Remove.
2245 (struct ui): Add constructor and destructor.
2246 (new_ui, delete_ui): Remove.
2247 * top.c (make_delete_ui_cleanup): Remove.
2248 (new_ui_command): Use std::unique_ptr.
2249 (delete_ui_cleanup): Remove.
2250 (ui::ui): Rename from new_ui. Update.
2251 (free_ui): Remove.
2252 (ui::~ui): Rename from delete_ui. Update.
2253
0efef640
TT
22542017-10-03 Tom Tromey <tom@tromey.com>
2255
2256 * symfile.c (load_progress): Use gdb::byte_vector.
2257
245ad7d3
TT
22582017-10-03 Tom Tromey <tom@tromey.com>
2259
2260 * mi/mi-main.c (mi_cmd_trace_frame_collected): Remove unused
2261 declaration.
2262 * printcmd.c (x_command): Remove unused declaration.
2263 * symfile.c (symbol_file_command): Remove unused declaration.
2264
e05550d7
TT
22652017-10-03 Tom Tromey <tom@tromey.com>
2266
2267 * utils.c (internal_vproblem): Use std::string.
2268 (defaulted_query): Likewise.
2269
b95de2b7
TT
22702017-10-03 Tom Tromey <tom@tromey.com>
2271
2272 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Update.
2273 * top.c (execute_command_to_string): Update.
2274 * utils.c (make_cleanup_restore_page_info): Remove.
2275 (do_restore_page_info_cleanup): Remove.
2276 (set_batch_flag_and_restore_page_info):
2277 New.
2278 (make_cleanup_restore_page_info): Remove.
2279 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
2280 (~set_batch_flag_and_restore_page_info): New
2281 (make_cleanup_restore_uinteger): Remove.
2282 (make_cleanup_restore_integer): Remove.
2283 (struct restore_integer_closure): Remove.
2284 (restore_integer): Remove.
2285 * utils.h (struct set_batch_flag_and_restore_page_info): New
2286 class.
2287 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
2288 (make_cleanup_restore_page_info): Remove.
2289 (make_cleanup_restore_uinteger) Remove.
2290 (make_cleanup_restore_integer) Remove.
2291
07036511
TT
22922017-10-03 Tom Tromey <tom@tromey.com>
2293
2294 * record-full.h (record_full_gdb_operation_disable_set): Return
2295 scoped_restore_tmpl<int>.
2296 * infrun.c (adjust_pc_after_break): Update.
2297 (handle_signal_stop): Update.
2298 * record-full.c (record_full_gdb_operation_disable_set): Return
2299 scoped_restore_tmpl<int>.
2300 (record_full_wait_1, record_full_insert_breakpoint)
2301 (record_full_remove_breakpoint, record_full_save)
2302 (record_full_goto_insn): Update.
2303
45320ffa
TT
23042017-10-02 Tom Tromey <tom@tromey.com>
2305
2306 PR rust/22236:
2307 * rust-lang.c (rust_val_print_str): New function.
2308 (val_print_struct): Call it.
2309 (rust_subscript): Preserve name of slice type.
2310
b3e3859b
TT
23112017-10-02 Tom Tromey <tom@tromey.com>
2312
2313 * rust-lang.c (rust_subscript): Handle slices in
2314 EVAL_AVOID_SIDE_EFFECTS case.
2315
01af5e0d
TT
23162017-10-02 Tom Tromey <tom@tromey.com>
2317
2318 * rust-lang.c (rust_slice_type_p): Recognize &str as a slice type.
2319
888e3ddb
TT
23202017-10-02 Tom Tromey <tom@tromey.com>
2321
2322 * rust-lang.h (rust_slice_type): Add "extern".
2323
cc536b21
PA
23242017-10-02 Tom Tromey <tom@tromey.com>
2325 Pedro Alves <palves@redhat.com>
2326
2327 * ada-lang.h (ada_exc_info::operator<): Make const.
2328 (ada_exc_info::operator==): Make const.
2329 * ada-lang.c (ada_exc_info::operator<, ada_exc_info::operator==):
2330 Make const.
2331
386c8614
TT
23322017-09-29 Tom Tromey <tom@tromey.com>
2333
2334 * target.c (read_whatever_is_readable): Change type of "result".
2335 Update.
2336 (free_memory_read_result_vector): Remove.
2337 (read_memory_robust): Change return type. Update.
2338 * mi/mi-main.c (mi_cmd_data_read_memory_bytes): Update. Use
2339 bin2hex, std::string.
2340 * target.h (memory_read_result_s): Remove typedef.
2341 (free_memory_read_result_vector): Remove.
2342 (read_memory_robust): Return std::vector.
2343
789c4b5e
TT
23442017-09-29 Tom Tromey <tom@tromey.com>
2345
2346 * mi/mi-main.c (captured_mi_execute_command): Use scope_restore.
2347
ab816a27
TT
23482017-09-29 Tom Tromey <tom@tromey.com>
2349
2350 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Update.
2351 * ada-lang.h (struct ada_exc_info): Remove typedef. Declare
2352 operator< and operator==.
2353 (ada_exceptions_list): Return a std::vector.
2354 * ada-lang.c (ada_exc_info::operator<): Rename from
2355 compare_ada_exception_info.
2356 (ada_exc_info::operator==): New.
2357 (sort_remove_dups_ada_exceptions_list): Change type of
2358 "exceptions".
2359 (ada_add_standard_exceptions, ada_add_exceptions_from_frame)
2360 (ada_add_global_exceptions): Likewise.
2361 (ada_exceptions_list_1): Return a std::vector.
2362 (ada_exceptions_list): Likewise.
2363
52f9abe4
TT
23642017-09-29 Tom Tromey <tom@tromey.com>
2365
2366 * mi/mi-main.c (struct print_one_inferior_data) <inferiors>: Now a
2367 'std::set *'.
2368 (print_one_inferior): Update.
2369 (free_vector_of_ints): Remove.
2370 (list_available_thread_groups): Change "ids" to std::set.
2371 (mi_cmd_list_thread_groups): Update.
2372 (struct collect_cores_data) <core>: Now a std::set.
2373 (collect_cores): Update.
2374 (unique): Remove.
2375 (print_one_inferior): Update.
2376
dcd5ddcc
TT
23772017-09-29 Tom Tromey <tom@tromey.com>
2378
2379 * mi/mi-main.c (mi_execute_cli_command): Use std::string.
2380 (mi_execute_async_cli_command): Likewise.
2381 (mi_cmd_trace_frame_collected): Use field_fmt.
2382
45d288cc
TT
23832017-09-29 Tom Tromey <tom@tromey.com>
2384
2385 * mi/mi-main.c (mi_cmd_data_write_memory_bytes): Use
2386 gdb::byte_vector.
2387
6afe2f4a
TT
23882017-09-29 Tom Tromey <tom@tromey.com>
2389
2390 * mi/mi-parse.c (mi_parse): Remove unused declaration.
2391
9813429a
TT
23922017-09-29 Tom Tromey <tom@tromey.com>
2393
2394 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Don't copy "oarg".
2395
2d6960b4
TT
23962017-09-29 Tom Tromey <tom@tromey.com>
2397
2398 * varobj.h (varobj_gen_name): Return std::string.
2399 * varobj.c (varobj_gen_name): Return std::string.
2400 * mi/mi-cmd-var.c (mi_cmd_var_create): Use std::string.
2401 (mi_cmd_var_delete): Don't copy "name".
2402
784c453a
TT
24032017-09-29 Tom Tromey <tom@tromey.com>
2404
2405 * mi/mi-cmd-break.c (mi_argv_to_format): Return std::string.
2406 (mi_cmd_break_insert_1): Update.
2407
a9bc57b9
TT
24082017-09-29 Tom Tromey <tom@tromey.com>
2409
2410 * target.h (make_scoped_defer_target_commit_resume): Update.
2411 * target.c (make_scoped_defer_target_commit_resume): Rename from
2412 make_cleanup_defer_target_commit_resume. Return a
2413 scoped_restore.
2414 * infrun.c (proceed): Use make_scoped_defer_target_commit_resume.
2415
9754d8c4
TT
24162017-09-29 Tom Tromey <tom@tromey.com>
2417
2418 * main.c (captured_main_1): Remove unused declaration.
2419 * spu-multiarch.c (parse_spufs_run): Remove unused declaration.
2420
99ef965c
TT
24212017-09-29 Tom Tromey <tom@tromey.com>
2422
2423 * symtab.c (search_symbols): Remove unused outer cleanup.
2424 (make_source_files_completion_list): Remove unused declaration.
2425
42518ba7
TT
24262017-09-29 Tom Tromey <tom@tromey.com>
2427
2428 * mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.
2429
726b2169
TT
24302017-09-29 Tom Tromey <tom@tromey.com>
2431
2432 * xstormy16-tdep.c (xstormy16_push_dummy_call): Use
2433 gdb::byte_vector.
2434
55b06432
TT
24352017-09-29 Tom Tromey <tom@tromey.com>
2436
2437 * complaints.c (vcomplaint): Use std::string.
2438
8abcee91
TT
24392017-09-29 Tom Tromey <tom@tromey.com>
2440
2441 * tracepoint.c (trace_variable_command): Use std::string.
2442 (encode_actions_1): Remove unused declarations.
2443 (create_tsv_from_upload): Use std::string.
2444
6ad94bc7
TT
24452017-09-29 Tom Tromey <tom@tromey.com>
2446
2447 * cp-support.c (gdb_demangle): Use std::string.
2448
2003f3d8
TT
24492017-09-29 Tom Tromey <tom@tromey.com>
2450
2451 * stack.c (parse_frame_specification): Use std::string
2452 (info_frame_command): Use gdb::unique_xmalloc_ptr.
2453
8f8accb5
TT
24542017-09-29 Tom Tromey <tom@tromey.com>
2455
2456 * tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.
2457
200aa7b1
TT
24582017-09-29 Tom Tromey <tom@tromey.com>
2459
2460 * utils.c (vfprintf_maybe_filtered): Use std::string.
2461 (vfprintf_unfiltered): Likewise.
2462
606aae8a
TT
24632017-09-29 Tom Tromey <tom@tromey.com>
2464
2465 * event-top.c (top_level_prompt): Return std::string.
2466 (display_gdb_prompt): Update.
2467
bd413795
TT
24682017-09-29 Tom Tromey <tom@tromey.com>
2469
2470 * unittests/common-utils-selftests.c (format): New function.
2471 (string_vprintf_tests): New function.
2472 (_initialize_common_utils_selftests): Register new tests.
2473 * common/common-utils.c (string_vprintf): New function.
2474 * common/common-utils.h (string_vprintf): Declare.
2475
256642e8
PA
24762017-09-29 Pedro Alves <palves@redhat.com>
2477
2478 * common/rsp-low.c (unpack_varlen_hex): Constify.
2479 * common/rsp-low.h (unpack_varlen_hex): Constify.
2480 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
2481 Constify.
2482 * remote.c (remote_set_permissions, read_ptid)
2483 (remote_current_thread, remote_get_threads_with_qthreadinfo)
2484 (remote_static_tracepoint_marker_at)
2485 (remote_static_tracepoint_markers_by_strid)
2486 (stop_reply_extract_thread, remote_parse_stop_reply): Constify.
2487 * tracepoint.c (parse_trace_status, parse_tracepoint_status)
2488 (parse_tracepoint_definition, parse_tsv_definition)
2489 (parse_static_tracepoint_marker_definition): Constify.
2490 * tracepoint.h (parse_static_tracepoint_marker_definition)
2491 (parse_trace_status, parse_tracepoint_status)
2492 (parse_tracepoint_definition, parse_tsv_definition): Constify.
2493
b6bb3468
PA
24942017-09-29 Pedro Alves <palves@redhat.com>
2495
2496 * remote.c (target_buf, target_buf_size): Delete.
2497 (remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
2498 Use the connection's packet buffer instead.
2499 All callers adjusted.
2500 (_initialize_remote): Remove references to target_buf and
2501 target_buf_size.
2502
b2f8eb7a
PA
25032017-09-28 Pedro Alves <palves@redhat.com>
2504
2505 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2506 unittests/common-utils-selftests.c.
2507 (SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
2508 (COMMON_OBS): Remove utils-selftests.o.
2509 * utils-selftests.c: Move to ...
2510 * unittests/common-utils-selftests.c: ... here and rename self
2511 test to "string_printf".
2512
08302ed2
DE
25132017-09-28 Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com> (tiny patch)
2514
2515 * dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
2516 having NULL cus or tus.
2517
96a5a1d3
UW
25182017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
2519
2520 * arm-tdep.c: (convert_from_extended): Remove.
2521 (convert_to_extended): Likewise.
2522 (arm_extract_return_value): Use convert_typed_floating.
2523 (arm_store_return_value): Likewise.
2524
2525 * sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
2526 * sh-tdep.c: Do not include "floatformat.h".
2527 (sh_littlebyte_bigword_type): New function.
2528 (sh_register_convert_to_virtual): Use convert_typed_floating.
2529 (sh_register_convert_to_raw): Likewise.
2530 * sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
2531 (sh64_littlebyte_bigword_type): New function.
2532 (sh64_extract_return_value): Use convert_typed_floating.
2533 (sh64_register_convert_to_virtual): Likewise.
2534 (sh64_register_convert_to_raw): Likewise.
2535
0db7851f
UW
25362017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
2537
2538 * doublest.h (floatformat_from_type): Move to gdbtypes.h.
2539 * doublest.c (floatformat_from_type): Move to gdbtypes.c.
2540
2541 * gdbtypes.h (union type_specific): Make field floatformat hold
2542 just a single struct floatformat, not an array.
2543 (floatformat_from_type): Move here.
2544 * gdbtypes.c (floatformat_from_type): Move here. Update to
2545 changed TYPE_FLOATFORMAT definition.
2546 (verify_floatformat): Update to changed TYPE_FLOATFORMAT.
2547 (recursive_dump_type): Likewise.
2548 (init_float_type): Install correct floatformat for byte order.
2549 (arch_float_type): Likewise.
2550
77b7c781
UW
25512017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
2552
2553 * gdbtypes.c (init_type): Change incoming argument from
2554 length-in-bytes to length-in-bits. Assert length is a
2555 multiple of TARGET_CHAR_BITS.
2556 (arch_type, arch_flags_type): Likewise.
2557 (init_integer_type): Update call to init_type.
2558 (init_character_type): Likewise.
2559 (init_boolean_type): Likewise.
2560 (init_float_type): Likewise.
2561 (init_decfloat_type): Likewise.
2562 (init_complex_type): Likewise.
2563 (init_pointer_type): Likewise.
2564 (objfile_type): Likewise.
2565 (arch_integer_type): Update call to arch_type.
2566 (arch_character_type): Likewise.
2567 (arch_boolean_type): Likewise.
2568 (arch_float_type): Likewise.
2569 (arch_decfloat_type): Likewise.
2570 (arch_complex_type): Likewise.
2571 (arch_pointer_type): Likewise.
2572 (gdbtypes_post_init): Likewise.
2573
2574 * dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
2575 (read_base_type): Likewise.
2576 * mdebugread.c (basic_type): Likewise.
2577 * stabsread.c (dbx_init_float_type): Likewise.
2578 (rs6000_builtin_type): Likewise.
2579 (read_range_type): Likewise. Also, fix call to init_integer_type
2580 with erroneous length argument.
2581
2582 * ada-lang.c (ada_language_arch_info): Update call to arch_type.
2583 * d-lang.c (build_d_types): Likewise.
2584 * f-lang.c (build_fortran_types): Likewise.
2585 * go-lang.c (build_go_types): Likewise.
2586 * opencl-lang.c (build_opencl_types): Likewise.
2587 * jit.c (finalize_symtab): Likewise.
2588 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
2589 (build_std_type_info_type): Likewise.
2590 * target-descriptions.c (tdesc_gdb_type): Likewise. Also,
2591 update call to arch_flags_type.
2592
2593 * linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
2594 arch_type.
2595 * fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
2596 * windows-tdep.c (windows_get_tlb_type): Likewise.
2597
2598 * avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
2599 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
2600 * m32c-tdep.c (make_types): Likewise.
2601 * rl78-tdep.c (rl78_gdbarch_init): Likewise.
2602 (rl78_psw_type): Update call to arch_flags_type.
2603 * m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
2604 * rx-tdep.c (rx_psw_type): Likewise.
2605 (rx_fpsw_type): Likewise.
2606 * sparc-tdep.c (sparc_psr_type): Likewise.
2607 (sparc_fsr_type): Likewise.
2608 * sparc64-tdep.c (sparc64_pstate_type): Likewise.
2609 (sparc64_ccr_type): Likewise.
2610 (sparc64_fsr_type): Likewise.
2611 (sparc64_fprs_type): Likewise.
2612
f21b4d5c
TT
26132017-09-27 Tom Tromey <tom@tromey.com>
2614
2615 * findcmd.c (find_command): Constify.
2616
643c2ffa
TT
26172017-09-27 Tom Tromey <tom@tromey.com>
2618
2619 * ada-tasks.c (task_command_1, task_command): Constify.
2620
510e5e56
TT
26212017-09-27 Tom Tromey <tom@tromey.com>
2622
2623 * symtab.c (maintenance_print_symbol_cache)
2624 (maintenance_flush_symbol_cache)
2625 (maintenance_print_symbol_cache_statistics): Constify.
2626
e503b191
TT
26272017-09-27 Tom Tromey <tom@tromey.com>
2628
2629 * inferior.c (detach_inferior_command, kill_inferior_command)
2630 (inferior_command): Constify.
2631
4e001312
TT
26322017-09-27 Tom Tromey <tom@tromey.com>
2633
2634 * regcache.c (regcache_print, maintenance_print_registers)
2635 (maintenance_print_raw_registers)
2636 (maintenance_print_cooked_registers)
2637 (maintenance_print_register_groups)
2638 (maintenance_print_remote_registers): Constify.
2639
77763700
TT
26402017-09-27 Tom Tromey <tom@tromey.com>
2641
2642 * printcmd.c (map_display_numbers, undisplay_command)
2643 (enable_disable_display_command, enable_display_command)
2644 (disable_display_command): Constify.
2645
4495129a
TT
26462017-09-27 Tom Tromey <tom@tromey.com>
2647
2648 * breakpoint.h (delete_command): Don't declare.
2649 * breakpoint.c (delete_command, enable_once_command)
2650 (enable_count_command, enable_delete_command, breakpoint_1)
2651 (maintenance_info_breakpoints, stopin_command, stopat_command)
2652 (delete_command, delete_trace_command, save_breakpoints)
2653 (save_breakpoints_command, save_tracepoints_command): Constify.
2654
3088cf40
TT
26552017-09-27 Tom Tromey <tom@tromey.com>
2656
2657 * macrocmd.c (macro_expand_command, macro_expand_once_command)
2658 (skip_ws, extract_identifier, macro_define_command)
2659 (macro_undef_command, macro_list_command): Constify.
2660
69f476a3
TT
26612017-09-27 Tom Tromey <tom@tromey.com>
2662
2663 * infcmd.c (environment_info, set_environment_command)
2664 (unset_environment_command, path_info, info_proc_cmd_1)
2665 (info_proc_cmd_mappings, info_proc_cmd_stat)
2666 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
2667 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
2668
c4a3e68e
TT
26692017-09-27 Tom Tromey <tom@tromey.com>
2670
2671 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
2672 Constify.
2673
c9d31bd6
TT
26742017-09-27 Tom Tromey <tom@tromey.com>
2675
2676 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
2677
1f3f85eb
TT
26782017-09-27 Tom Tromey <tom@tromey.com>
2679
2680 * demangle.c (demangle_command): Constify.
2681
9c504b5d
TT
26822017-09-27 Tom Tromey <tom@tromey.com>
2683
2684 * progspace.c (maintenance_info_program_spaces_command):
2685 Constify.
2686
6663cf91
TT
26872017-09-27 Tom Tromey <tom@tromey.com>
2688
2689 * compile/compile.c (check_raw_argument, compile_file_command)
2690 (compile_code_command, compile_print_command): Constify.
2691
34e5fa26
TT
26922017-09-27 Tom Tromey <tom@tromey.com>
2693
2694 * reggroups.c (maintenance_print_reggroups): Constify.
2695
8384c356
TT
26962017-09-27 Tom Tromey <tom@tromey.com>
2697
2698 * dwarf2read.c (save_gdb_index_command): Constify.
2699
884beb0c
TT
27002017-09-27 Tom Tromey <tom@tromey.com>
2701
2702 * stap-probe.c (info_probes_stap_command): Constify.
2703
e0b2930c
TT
27042017-09-27 Tom Tromey <tom@tromey.com>
2705
2706 * fork-child.c (unset_exec_wrapper_command): Constify.
2707
f938677d
TT
27082017-09-27 Tom Tromey <tom@tromey.com>
2709
2710 * btrace.c (get_uint, get_context_size, no_chunk)
2711 (maint_btrace_packet_history_cmd)
2712 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
2713 (maint_info_btrace_cmd): Constify.
2714
8949cb87
TT
27152017-09-27 Tom Tromey <tom@tromey.com>
2716
2717 * reverse.c (delete_bookmark_command): Constify.
2718
ac88e2de
TT
27192017-09-27 Tom Tromey <tom@tromey.com>
2720
2721 * remote.c (set_memory_packet_size)
2722 (set_memory_write_packet_size, show_memory_write_packet_size)
2723 (set_memory_read_packet_size, show_memory_read_packet_size)
2724 (compare_sections_command, packet_command, remote_put_command)
2725 (remote_get_command, remote_delete_command): Constify.
2726
bd4c9dfe
TT
27272017-09-27 Tom Tromey <tom@tromey.com>
2728
2729 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
2730 (set_mipsfpu_double_command, set_mipsfpu_none_command)
2731 (set_mipsfpu_auto_command): Constify.
2732
5e93d4c6
TT
27332017-09-27 Tom Tromey <tom@tromey.com>
2734
2735 * cli/cli-cmds.h (cd_command): Constify.
2736 * cli/cli-cmds.c (cd_command): Constify.
2737
fc41a75b
TT
27382017-09-27 Tom Tromey <tom@tromey.com>
2739
2740 * thread.c (thread_name_command, thread_find_command): Constify.
2741
67810076
TT
27422017-09-27 Tom Tromey <tom@tromey.com>
2743
2744 * probe.c (enable_probes_command, disable_probes_command):
2745 Constify.
2746
1d8b34a7
TT
27472017-09-27 Tom Tromey <tom@tromey.com>
2748
2749 * symfile.c (symbol_file_command): Constify.
2750 * gdbcore.h (deprecated_file_changed_hook): Constify.
2751 * exec.c (deprecated_file_changed_hook, exec_file_command)
2752 (file_command): Constify.
2753 * defs.h (symbol_file_command): Constify.
2754
442019e1
TT
27552017-09-27 Tom Tromey <tom@tromey.com>
2756
2757 * remote-fileio.c (set_system_call_allowed)
2758 (show_system_call_allowed): Constify.
2759
2983f7cb
TT
27602017-09-27 Tom Tromey <tom@tromey.com>
2761
2762 * tracepoint.c (delete_trace_variable_command)
2763 (tfind_end_command, tfind_start_command, tfind_pc_command)
2764 (tfind_tracepoint_command, tfind_line_command)
2765 (tfind_range_command, tfind_outside_command): Constify.
2766
4fd41b24
TT
27672017-09-27 Tom Tromey <tom@tromey.com>
2768
2769 * ax-gdb.c (maint_agent_printf_command, agent_command)
2770 (agent_eval_command): Constify.
2771
f2fc3015
TT
27722017-09-27 Tom Tromey <tom@tromey.com>
2773
2774 * tracepoint.c (info_scope_command): Constify.
2775 * python/python.c (gdbpy_decode_line): Constify.
2776 * python/py-breakpoint.c (bppy_init): Constify.
2777 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
2778 * location.h: (new_linespec_location)
2779 (string_to_event_location_basic, string_to_event_location):
2780 Constify.
2781 * location.c (new_linespec_location)
2782 (string_to_event_location_basic, string_to_event_location):
2783 Constify.
2784 * linespec.h (decode_line_with_current_source)
2785 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
2786 * linespec.c (linespec_lex_to_end)
2787 (decode_line_with_current_source)
2788 (decode_line_with_last_displayed): Constify.
2789 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
2790 Constify.
2791 * cli/cli-cmds.c (edit_command, list_command): Constify.
2792 * breakpoint.h (until_break_command, watch_command_wrapper)
2793 (awatch_command_wrapper, rwatch_command_wrapper)
2794 (init_ada_exception_breakpoint): Constify.
2795 * breakpoint.c (break_command_1, dprintf_command)
2796 (break_range_command, watch_command_wrapper)
2797 (rwatch_command_wrapper, awatch_command_wrapper)
2798 (until_break_command, init_ada_exception_breakpoint)
2799 (strace_marker_create_sals_from_location, trace_command)
2800 (ftrace_command, strace_command, struct tracepoint): Constify.
2801 * ax-gdb.c (agent_command_1): Constify.
2802 * ada-lang.c (ada_exception_sal): Constify.
2803
8c2f95f4
TT
28042017-09-27 Tom Tromey <tom@tromey.com>
2805
2806 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
2807 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
2808 (get_context_size, no_chunk, get_insn_history_modifiers)
2809 (cmd_record_insn_history, get_call_history_modifiers)
2810 (cmd_record_call_history): Constify.
2811
a0d65762
TT
28122017-09-27 Tom Tromey <tom@tromey.com>
2813
2814 * source.c (show_substitute_path_command)
2815 (unset_substitute_path_command, set_substitute_path_command):
2816 Constify.
2817
58971144
TT
28182017-09-27 Tom Tromey <tom@tromey.com>
2819
2820 * typeprint.c (maintenance_print_type): Constify.
2821 * maint.c (maintenance_dump_me, maintenance_demangle)
2822 (maintenance_time_display, maintenance_info_sections)
2823 (maintenance_print_statistics, maintenance_deprecate)
2824 (maintenance_undeprecate): Constify.
2825 (maintenance_do_deprecate): Constify. Use std::string.
2826 (maintenance_selftest): Constify.
2827 * gdbtypes.h (maintenance_print_type): Constify.
2828
c482f52c
TT
28292017-09-27 Tom Tromey <tom@tromey.com>
2830
2831 * hppa-tdep.c (unwind_command): Constify.
2832
e100df1a
TT
28332017-09-27 Tom Tromey <tom@tromey.com>
2834
2835 * target-descriptions.c (unset_tdesc_filename_cmd)
2836 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
2837 Constify.
2838
31d56ade
TT
28392017-09-27 Tom Tromey <tom@tromey.com>
2840
2841 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
2842
b961da0b
TT
28432017-09-27 Tom Tromey <tom@tromey.com>
2844
2845 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
2846
e2d8ae16
TT
28472017-09-27 Tom Tromey <tom@tromey.com>
2848
2849 * tui/tui-regs.c (tui_reg_command): Constify.
2850
863779b0
TT
28512017-09-27 Tom Tromey <tom@tromey.com>
2852
2853 * skip.c (skip_file_command, skip_function_command)
2854 (skip_enable_command, skip_disable_command, skip_delete_command):
2855 Constify.
2856
cdb34d4a
TT
28572017-09-27 Tom Tromey <tom@tromey.com>
2858
2859 * record-btrace.c (cmd_record_btrace_bts_start)
2860 (cmd_record_btrace_pt_start): Constify.
2861
e99c83e7
TT
28622017-09-27 Tom Tromey <tom@tromey.com>
2863
2864 * symmisc.c (maintenance_print_symbols)
2865 (maintenance_print_msymbols, maintenance_print_objfiles)
2866 (maintenance_info_symtabs, maintenance_check_symtabs)
2867 (maintenance_expand_symtabs, maintenance_info_line_tables):
2868 Constify.
2869
32faf971
TT
28702017-09-27 Tom Tromey <tom@tromey.com>
2871
2872 * top.c (new_ui_command): Constify.
2873
2cf311eb
TT
28742017-09-27 Tom Tromey <tom@tromey.com>
2875
2876 * symfile.c (add_symbol_file_command)
2877 (remove_symbol_file_command, list_overlays_command)
2878 (map_overlay_command, unmap_overlay_command)
2879 (overlay_auto_command, overlay_manual_command)
2880 (overlay_off_command, overlay_load_command): Constify.
2881
e6738699
TT
28822017-09-27 Tom Tromey <tom@tromey.com>
2883
2884 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
2885 (info_spu_mailbox_command, info_spu_dma_command)
2886 (info_spu_proxydma_command): Constify.
2887
aa360cd5
TT
28882017-09-27 Tom Tromey <tom@tromey.com>
2889
2890 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
2891
898241a5
TT
28922017-09-27 Tom Tromey <tom@tromey.com>
2893
2894 * cli/cli-script.c (user_defined_command): Constify.
2895
2d0ac106
TT
28962017-09-27 Tom Tromey <tom@tromey.com>
2897
2898 * cli/cli-dump.c (dump_memory_command, dump_value_command)
2899 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
2900 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
2901 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
2902 (dump_binary_value, append_binary_memory, append_binary_value):
2903 Constify.
2904 (struct dump_context) <func>: Constify.
2905 (add_dump_command): Update.
2906
dede02ce
TT
29072017-09-27 Tom Tromey <tom@tromey.com>
2908
2909 * cli/cli-cmds.c (show_version, show_configuration)
2910 (source_command, show_user): Constify.
2911
d3cb6b99
TT
29122017-09-27 Tom Tromey <tom@tromey.com>
2913
2914 * target.c (maintenance_print_target_stack): Constify.
2915
1970a12f
TT
29162017-09-27 Tom Tromey <tom@tromey.com>
2917
2918 * interps.c (interpreter_exec_cmd): Constify.
2919
41243651
TT
29202017-09-27 Tom Tromey <tom@tromey.com>
2921
2922 * record-full.c (cmd_record_full_restore): Constify.
2923
4465d9db
TT
29242017-09-27 Tom Tromey <tom@tromey.com>
2925
2926 * memattr.c (enable_mem_command, disable_mem_command)
2927 (delete_mem_command): Constify.
2928
ad25e423
TT
29292017-09-27 Tom Tromey <tom@tromey.com>
2930
2931 * value.c (show_convenience): Constify.
2932
d64097b1
TT
29332017-09-27 Tom Tromey <tom@tromey.com>
2934
2935 * gdbcore.h (core_file_command): Update.
2936 * corefile.c (core_file_command): Constify.
2937
4d4589ef
TT
29382017-09-27 Tom Tromey <tom@tromey.com>
2939
2940 * user-regs.c (maintenance_print_user_registers): Constify.
2941
32a7bf17
TT
29422017-09-27 Tom Tromey <tom@tromey.com>
2943
2944 * cp-namespace.c (maintenance_cplus_namespace): Constify.
2945
4a475551
TT
29462017-09-27 Tom Tromey <tom@tromey.com>
2947
2948 * cp-support.c (first_component_command): Constify.
2949
990b9f9f
TT
29502017-09-27 Tom Tromey <tom@tromey.com>
2951
2952 * psymtab.c (maintenance_print_psymbols)
2953 (maintenance_info_psymtabs, maintenance_check_psymtabs):
2954 Constify.
2955
c281872e
TT
29562017-09-27 Tom Tromey <tom@tromey.com>
2957
2958 * windows-tdep.c (display_tib): Constify.
2959
5b64bf74
TT
29602017-09-27 Tom Tromey <tom@tromey.com>
2961
2962 * linux-fork.c (delete_checkpoint_command)
2963 (detach_checkpoint_command): Constify.
2964
4ada038f
TT
29652017-09-27 Tom Tromey <tom@tromey.com>
2966
2967 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
2968
57f5a81b
TT
29692017-09-27 Tom Tromey <tom@tromey.com>
2970
2971 * arc-tdep.c (dump_arc_instruction_command): Constify.
2972
b0a8e6c4
TT
29732017-09-27 Tom Tromey <tom@tromey.com>
2974
2975 * valprint.c (set_radix, show_radix): Constify.
2976
8d97dc1c
TT
29772017-09-27 Tom Tromey <tom@tromey.com>
2978
2979 * dtrace-probe.c (info_probes_dtrace_command): Constify.
2980
eb7c454d
TT
29812017-09-27 Tom Tromey <tom@tromey.com>
2982
2983 * command.h (not_just_help_class_command): Update.
2984 * cli/cli-decode.h (not_just_help_class_command): Update.
2985 * cli/cli-decode.c (not_just_help_class_command): Constify.
2986
e4e33335
TT
29872017-09-27 Tom Tromey <tom@tromey.com>
2988
2989 * gdb_bfd.c (maintenance_info_bfds): Constify.
2990
0450cc4c
TT
29912017-09-27 Tom Tromey <tom@tromey.com>
2992
2993 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
2994 overloads.
2995 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
2996 (do_const_cfunc): New function.
2997 (cmd_cfunc_eq): New overload.
2998 (cli_user_command_p): Check do_const_cfunc.
2999 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
3000 const_cfunc.
3001 * command.h (add_cmd): Add const overload and no-function
3002 overload.
3003 (set_cmd_cfunc): Add const overload.
3004 (cmd_const_cfunc_ftype): Declare.
3005 (cmd_cfunc_eq): Add const overload.
3006 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
3007 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
3008 overload.
3009
a9bbfbd8
TT
30102017-09-27 Tom Tromey <tom@tromey.com>
3011
3012 * macroexp.c (get_next_token_for_substitution): New function.
3013 (substitute_args): Call it. Check for __VA_OPT__.
3014
5230b05a
WT
30152017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
3016 Pedro Alves <palves@redhat.com>
3017
3018 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
3019 producer_is_icc_lt_14.
3020 (producer_is_icc_lt_14): New function.
3021 (check_producer): Add code for checking version of ICC.
3022 (producer_is_icc): Move to producer.c.
3023 (read_structure_type): Restrict ICC workaround to ICC<14.
3024 * producer.c: Include selftest.h.
3025 (producer_is_icc, producer_parsing_tests, _initialize_producer):
3026 New functions.
3027 * producer.h (producer_is_icc): New declaration.
3028
b32b108a
WT
30292017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
3030
3031 * Makefile.in (SFILES): Add producer.c.
3032 (COMMON_OBS): Add producer.o
3033 * amd64-tdep.c (producer.h): Add new include.
3034 * dwarf2read.c (producer.h): Add new include.
3035 * producer.c: New file.
3036 * producer.h: New file.
3037 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
3038 producer.c.
3039 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
3040 producer.h.
3041
5007d765
MK
30422017-09-26 Matthias Klose <doko@ubuntu.com>
3043
3044 * configure.ac: Search ncursesw before ncurses.
3045 Check ncursesw/ncurses.h before ncurses/ncurses.h.
3046 * gdb_curses.h: Include <ncursesw/ncurses.h>
3047 * config.in, configure: Regenerate.
3048
281c4447
RO
30492017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3050
3051 PR gdb/22185
3052 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
3053 obsolete.
3054 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
3055 Remove i386sol2 support.
3056 * configure.nat <i386sol2>: Remove.
3057 <sol2-64>: Fold into ...
3058 <sol2>: ... this.
3059 Move common settings to default section.
3060 Add sol-thread.o.
3061 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
3062 x86_64-*-solaris2.1[0-9]*>: Rename to ...
3063 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
3064 <i[34567]86-*-solaris*>: Remove.
3065 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
3066
3067 * configure.ac: Remove wctype in libw check.
3068 (_MSE_INT_H): Don't define on Solaris 7-9.
3069 <solaris*>: Remove libthread_db.so.1 check.
3070 * configure: Regenerate.
3071 * config.in: Regenerate.
3072
3073 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
3074 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
3075 (gdb_ps_size_t): Remove.
3076 Use base types in users.
3077 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
3078
3079 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
3080
39b06c20
RO
30812017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3082
3083 PR build/22206
3084 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
3085 (adi_is_addr_mapped): Likewise.
3086 (PSR_ICC): Don't redefine.
3087 (PSR_IMPL): Likewise.
3088
6c3e20f1
TT
30892017-09-25 Tom Tromey <tom@tromey.com>
3090
3091 * regcache.c (regcache::dump): Use string_printf.
3092
b292235f
TT
30932017-09-25 Tom Tromey <tom@tromey.com>
3094
3095 * regcache.c (class regcache_invalidator): New.
3096 (struct register_to_invalidate): Remove.
3097 (make_cleanup_regcache_invalidate): Remove.
3098 (regcache::raw_write): Use regcache_invalidator.
3099
9ac86b52
TT
31002017-09-25 Tom Tromey <tom@tromey.com>
3101
3102 * spu-tdep.c (spu2ppu_sniffer): Update.
3103 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
3104 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
3105 Remove.
3106 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
3107 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
3108 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
3109 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
3110 (frame_pop): Update.
3111
c0e383c6
TT
31122017-09-25 Tom Tromey <tom@tromey.com>
3113
3114 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
3115 * regcache.h (regcache_xfree): Don't declare.
3116 * regcache.c (regcache_xfree): Remove.
3117 (do_regcache_xfree): Use delete.
3118 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
3119 * linux-fork.c (free_fork): Use delete.
3120 (fork_save_infrun_state): Likewise.
3121 * jit.c (jit_dealloc_cache): Use delete.
3122 * infrun.c (discard_infcall_suspend_state): Use delete.
3123
791199cc
TT
31242017-09-25 Tom Tromey <tom@tromey.com>
3125
3126 * regcache.h (regcache_xmalloc): Don't declare.
3127 (regcache_raw_set_cached_value): Update comment.
3128 * regcache.c (regcache_xmalloc): Remove.
3129 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
3130 * jit.c (jit_frame_sniffer): Use new.
3131 * frame.c (frame_save_as_regcache): Use new.
3132
289e23aa
AA
31332017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
3134
3135 * NEWS: Advertise support for guarded-storage registers on IBM z.
3136
1b63490c
AA
31372017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
3138
3139 * s390-linux-nat.c (have_regset_gs): New static variable.
3140 (s390_linux_fetch_inferior_registers): Handle guarded-storage
3141 control block and guarded-storage broadcast control regsets.
3142 (s390_read_description): Detect whether the target has
3143 guarded-storage support, return appropriate tdesc.
3144 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
3145 (features/s390x-gs-linux64.c): Likewise.
3146 (struct gdbarch_tdep) <have_gs>: New field.
3147 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
3148 (s390_gsbc_regset): New variables.
3149 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
3150 and s390_gsbc_regset, if applicable.
3151 (s390_core_read_description): Check whether core file was from a
3152 target with guarded-storage support; include appropriate regsets.
3153 (s390_gdbarch_init): Add registers for guarded-storage support.
3154 (_initialize_s390_tdep): Initialize new target descriptions that
3155 include registers for guarded-storage support.
3156 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
3157 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
3158 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
3159 (S390_NUM_REGS): Adjust macro definition.
3160 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
3161 (tdesc_s390x_gs_linux64): New declarations.
3162
96235dc1
AA
31632017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
3164
3165 * features/s390-gs-linux64.xml: New file.
3166 * features/s390-gs.xml: New file.
3167 * features/s390-gsbc.xml: New file.
3168 * features/s390x-gs-linux64.xml: New file.
3169 * features/Makefile (WHICH): Add s390-gs-linux64 and
3170 s390x-gs-linux64.
3171 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
3172 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
3173 * features/s390-gs-linux64.c: New generated file.
3174 * features/s390x-gs-linux64.c: New file.
3175 * regformats/s390-gs-linux64.dat: New file.
3176 * regformats/s390x-gs-linux64.dat: New file.
3177
b4a7c699
TT
31782017-09-23 Tom Tromey <tom@tromey.com>
3179
3180 * defs.h (make_cleanup_override_quit_handler): Don't declare.
3181
c2f97536
TT
31822017-09-22 Tom Tromey <tom@tromey.com>
3183
3184 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
3185 type to scoped_restore_tmpl.
3186 <scoped_input_handler>: Initialize m_quit_handler directly.
3187
43573013
SDJ
31882017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
3189
3190 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
3191 (cd_command): Likewise. Free "current_directory" before
3192 assigning to it.
3193 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
3194 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
3195 * top.c (gdb_dirbuf): Remove global declaration.
3196 * top.h (gdb_dirbuf): Likewise.
3197
6ec2e0f5
SDJ
31982017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
3199
3200 * gnulib/aclocal.m4: Regenerate.
3201 * gnulib/config.in: Regenerate.
3202 * gnulib/configure: Regenerate.
3203 * gnulib/import/Makefile.am: Regenerate.
3204 * gnulib/import/Makefile.in: Regenerate.
3205 * gnulib/import/assure.h: New file.
3206 * gnulib/import/at-func.c: Likewise
3207 * gnulib/import/chdir-long.c: New file.
3208 * gnulib/import/chdir-long.h: New file.
3209 * gnulib/import/cloexec.c: New file.
3210 * gnulib/import/cloexec.h: New file.
3211 * gnulib/import/close.c: New file.
3212 * gnulib/import/closedir.c: New file.
3213 * gnulib/import/dirent-private.h: New file.
3214 * gnulib/import/dup-safer.c: New file.
3215 * gnulib/import/dup.c: New file.
3216 * gnulib/import/dup2.c: New file.
3217 * gnulib/import/error.c: New file.
3218 * gnulib/import/error.h: New file.
3219 * gnulib/import/exitfail.c: New file.
3220 * gnulib/import/exitfail.h: New file.
3221 * gnulib/import/fchdir.c: New file.
3222 * gnulib/import/fcntl.c: New file.
3223 * gnulib/import/fcntl.in.h: New file.
3224 * gnulib/import/fd-hook.c: New file.
3225 * gnulib/import/fd-hook.h: New file.
3226 * gnulib/import/fd-safer.c: New file.
3227 * gnulib/import/fdopendir.c: New file.
3228 * gnulib/import/filename.h: New file.
3229 * gnulib/import/filenamecat-lgpl.c: New file.
3230 * gnulib/import/filenamecat.h: New file.
3231 * gnulib/import/fstat.c: New file.
3232 * gnulib/import/fstatat.c: New file.
3233 * gnulib/import/getcwd-lgpl.c: New file.
3234 * gnulib/import/getcwd.c: New file.
3235 * gnulib/import/getdtablesize.c: New file.
3236 * gnulib/import/getlogin_r.c: New file.
3237 * gnulib/import/getprogname.c: New file.
3238 * gnulib/import/getprogname.h: New file.
3239 * gnulib/import/gettext.h: New file.
3240 * gnulib/import/glob-libc.h: New file.
3241 * gnulib/import/glob.c: New file.
3242 * gnulib/import/glob.in.h: New file.
3243 * gnulib/import/intprops.h: New file.
3244 * gnulib/import/m4/chdir-long.m4: New file.
3245 * gnulib/import/m4/close.m4: New file.
3246 * gnulib/import/m4/closedir.m4: New file.
3247 * gnulib/import/m4/d-ino.m4: New file.
3248 * gnulib/import/m4/d-type.m4: New file.
3249 * gnulib/import/m4/dup.m4: New file.
3250 * gnulib/import/m4/dup2.m4: New file.
3251 * gnulib/import/m4/error.m4: New file.
3252 * gnulib/import/m4/fchdir.m4: New file.
3253 * gnulib/import/m4/fcntl.m4: New file.
3254 * gnulib/import/m4/fcntl_h.m4: New file.
3255 * gnulib/import/m4/fdopendir.m4: New file.
3256 * gnulib/import/m4/filenamecat.m4: New file.
3257 * gnulib/import/m4/fstat.m4: New file.
3258 * gnulib/import/m4/fstatat.m4: New file.
3259 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
3260 * gnulib/import/m4/getcwd-path-max.m4: New file.
3261 * gnulib/import/m4/getcwd.m4: New file.
3262 * gnulib/import/m4/getdtablesize.m4: New file.
3263 * gnulib/import/m4/getlogin_r.m4: New file.
3264 * gnulib/import/m4/getprogname.m4: New file.
3265 * gnulib/import/m4/glob.m4: New file.
3266 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
3267 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
3268 * gnulib/import/m4/mempcpy.m4: New file.
3269 * gnulib/import/m4/memrchr.m4: New file.
3270 * gnulib/import/m4/mode_t.m4: New file.
3271 * gnulib/import/m4/msvc-inval.m4: New file.
3272 * gnulib/import/m4/msvc-nothrow.m4: New file.
3273 * gnulib/import/m4/open.m4: New file.
3274 * gnulib/import/m4/openat.m4: New file.
3275 * gnulib/import/m4/opendir.m4: New file.
3276 * gnulib/import/m4/readdir.m4: New file.
3277 * gnulib/import/m4/realloc.m4: New file.
3278 * gnulib/import/m4/rewinddir.m4: New file.
3279 * gnulib/import/m4/save-cwd.m4: New file.
3280 * gnulib/import/m4/strdup.m4: New file.
3281 * gnulib/import/m4/strerror.m4: New file.
3282 * gnulib/import/m4/unistd-safer.m4: New file.
3283 * gnulib/import/mempcpy.c: New file.
3284 * gnulib/import/memrchr.c: New file.
3285 * gnulib/import/msvc-inval.c: New file.
3286 * gnulib/import/msvc-inval.h: New file.
3287 * gnulib/import/msvc-nothrow.c: New file.
3288 * gnulib/import/msvc-nothrow.h: New file.
3289 * gnulib/import/open.c: New file.
3290 * gnulib/import/openat-die.c: New file.
3291 * gnulib/import/openat-priv.h: New file.
3292 * gnulib/import/openat-proc.c: New file.
3293 * gnulib/import/openat.c: New file.
3294 * gnulib/import/openat.h: New file.
3295 * gnulib/import/opendir.c: New file.
3296 * gnulib/import/pipe-safer.c: New file.
3297 * gnulib/import/readdir.c: New file.
3298 * gnulib/import/realloc.c: New file.
3299 * gnulib/import/rewinddir.c: New file.
3300 * gnulib/import/save-cwd.c: New file.
3301 * gnulib/import/save-cwd.h: New file.
3302 * gnulib/import/strdup.c: New file.
3303 * gnulib/import/strerror-override.c: New file.
3304 * gnulib/import/strerror-override.h: New file.
3305 * gnulib/import/strerror.c: New file.
3306 * gnulib/import/unistd--.h: New file.
3307 * gnulib/import/unistd-safer.h: New file.
3308 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
3309 "getcwd" and "glob".
3310 * ser-tcp.c: Undefine "close" before redefining it.
3311
432ae719
SM
33122017-09-21 Simon Marchi <simon.marchi@ericsson.com>
3313
3314 * guile/scm-value.c (gdbscm_value_address): Initialize address,
3315 get rid of res_val.
3316
4fa7574e
RO
33172017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3318
3319 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
3320 <sol2,sparc>: Likewise.
3321 <sol2-64,i386>: Likewise.
3322
3323 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
3324 -Wdeprecated-declarations on *-*-solaris*.
3325 * configure: Regenerate.
3326
3327 * procfs.c: Include "nat/inferior.h".
3328 (procfs_info_proc): Fix typo.
3329
f6327dcb
KB
33302017-09-21 Kevin Buettner <kevinb@redhat.com>
3331
3332 * remote.c (vector): Include.
3333 (struct private_thread_info): Add field, thread_handle.
3334 (free_private_thread_info): Deallocate storage associated with
3335 thread handle.
3336 (get_private_info_thread): Initialize `thread_handle' field.
3337 (struct thread_item): Add field, thread_handle.
3338 (clear_threads_listing_context): Deallocate storage associated
3339 with thread handle.
3340 (start_thread): Add support for "handle" attribute.
3341 (thread_attributes): Add "handle".
3342 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
3343 field.
3344 (remote_update_thread_list): Update thread_handle.
3345 (remote_thread_handle_to_thread_info): New function.
3346 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
3347
fbbe5337
KB
33482017-09-21 Kevin Buettner <kevinb@redhat.com>
3349
3350 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
3351 function.
3352 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
3353 * python/python-internal.h (thread_object_type): Declare.
3354
e04ee09e
KB
33552017-09-21 Kevin Buettner <kevinb@redhat.com>
3356
3357 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
3358 (target_thread_handle_to_thread_info): Declare.
3359 * target.c (target_thread_handle_to_thread_info): New function.
3360 * target-delegates.c: Regenerate.
3361 * gdbthread.h (find_thread_by_handle): Declare.
3362 * thread.c (find_thread_by_handle): New function.
3363 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
3364 function.
3365 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
3366
1e5b66ed
SM
33672017-09-21 Simon Marchi <simon.marchi@ericsson.com>
3368
3369 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
3370
ebe48ba0
SM
33712017-09-21 Simon Marchi <simon.marchi@ericsson.com>
3372
3373 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
3374
0a0bf5dc
YQ
33752017-09-21 Yao Qi <yao.qi@linaro.org>
3376
3377 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
3378 to gdb_target_obs.
3379
d1b0a7bf
TT
33802017-09-20 Tom Tromey <tom@tromey.com>
3381
3382 * breakpoint.c (struct counted_command_line): Remove.
3383 (breakpoint_commands): Update.
3384 (alloc_counted_command_line, incref_counted_command_line)
3385 (decref_counted_command_line, do_cleanup_counted_command_line)
3386 (make_cleanup_decref_counted_command_line): Remove.
3387 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
3388 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
3389 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
3390 (save_breakpoints): Update.
3391 * breakpoint.h (counted_command_line): Now a typedef to
3392 shared_ptr.
3393 (struct breakpoint) <commands>: Now a counted_command_line.
3394 (struct bpstats) <command>: Likewise.
3395
48649e1b
TT
33962017-09-20 Tom Tromey <tom@tromey.com>
3397
3398 * breakpoint.c (struct commands_info, do_map_commands_command):
3399 Remove.
3400 (commands_command_1): Update.
3401 (iterate_over_related_breakpoints): Take a function_view.
3402 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
3403 (delete_command): Update.
3404 (map_breakpoint_numbers): Take a function_view.
3405 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
3406 (disable_command): Update.
3407 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
3408 (enable_command): Update.
3409 (struct disp_data, do_enable_breakpoint_disp)
3410 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
3411 (do_map_enable_delete_breakpoint): Remove.
3412 (enable_once_command, enable_count_command, enable_delete_command)
3413 (delete_trace_variable_command): Update.
3414
04afa70c
TT
34152017-09-20 Tom Tromey <tom@tromey.com>
3416
3417 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
3418 (bpstat_clear): Use delete.
3419 (bpstats): New constructors.
3420 (bpstat_copy, bpstat_stop_status): Use new.
3421 (dprintf_after_condition_true): Update.
3422 * breakpoint.h (bpstats::bpstats): Add constructors.
3423 (bpstats::~bpstats): Add destructor.
3424
c83833f4
PA
34252017-09-20 Pedro Alves <palves@redhat.com>
3426
3427 * eval.c (make_params): Delete, refactored as ...
3428 (class fake_method): ... this new type's ctor.
3429 (fake_method::~fake_method): New.
3430 (evaluate_subexp_standard): Use 'fake_method'.
3431
223ffa71
TT
34322017-09-20 Tom Tromey <tom@tromey.com>
3433
3434 * windows-nat.c (get_windows_debug_event, windows_wait)
3435 (do_initial_windows_stuff, windows_attach): Update.
3436 * utils.c (vwarning, internal_vproblem): Update.
3437 (ui_unregister_input_event_handler_cleanup)
3438 (prepare_to_handle_input): Remove.
3439 (class scoped_input_handler): New.
3440 (defaulted_query, prompt_for_continue): Update.
3441 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
3442 Update.
3443 * top.c (undo_terminal_modifications_before_exit): Update.
3444 * target/target.h (target_terminal_init, target_terminal_inferior)
3445 (target_terminal_ours): Don't declare.
3446 (class target_terminal): New.
3447 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
3448 (target_terminal_ours_for_output)
3449 (make_cleanup_restore_target_terminal): Don't declare.
3450 (target_terminal_info): Remove.
3451 * target.c (enum terminal_state, terminal_state): Remove.
3452 (target_terminal::terminal_state): Define.
3453 (target_terminal::init): Rename from target_terminal_init.
3454 (target_terminal::inferior): Rename from
3455 target_terminal_inferior.
3456 (target_terminal::ours): Rename from target_terminal_ours.
3457 (target_terminal::ours_for_output): Rename from
3458 target_terminal_ours_for_output.
3459 (target_terminal::info): New method.
3460 (cleanup_restore_target_terminal)
3461 (make_cleanup_restore_target_terminal): Remove.
3462 * solib.c (handle_solib_event): Update.
3463 * remote.c (remote_serial_quit_handler): Update.
3464 (remote_terminal_inferior, remote_wait_as): Update.
3465 * record-full.c (record_full_wait_1): Update.
3466 * nto-procfs.c (procfs_create_inferior): Update.
3467 * nat/fork-inferior.c (startup_inferior): Update.
3468 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
3469 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
3470 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
3471 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
3472 (mi_breakpoint_created, mi_breakpoint_deleted)
3473 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
3474 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
3475 (mi_user_selected_context_changed, report_initial_inferior):
3476 Update.
3477 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
3478 (linux_nat_terminal_inferior): Update.
3479 * infrun.c (follow_fork_inferior)
3480 (handle_vfork_child_exec_or_exit, do_target_resume)
3481 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
3482 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
3483 Update.
3484 * inflow.c (child_terminal_init, info_terminal_command): Update.
3485 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
3486 (attach_command): Update.
3487 * infcall.c (call_thread_fsm_should_stop): Update.
3488 * gnu-nat.c (gnu_attach): Update.
3489 * extension.c (struct active_ext_lang_state)
3490 (restore_active_ext_lang): Update.
3491 * exceptions.c (print_flush): Update.
3492 * event-top.c (async_enable_stdin, default_quit_handler): Update.
3493 (struct quit_handler_cleanup_data, restore_quit_handler)
3494 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
3495 Remove.
3496 * cp-support.c (gdb_demangle): Update.
3497 * breakpoint.c (update_inserted_breakpoint_locations)
3498 (insert_breakpoint_locations, handle_jit_event)
3499 (disable_breakpoints_in_unloaded_shlib): Update.
3500 * annotate.c (annotate_breakpoints_invalid)
3501 (annotate_frames_invalid): Update.
3502
013af3fc
TT
35032017-09-20 Tom Tromey <tom@tromey.com>
3504
3505 * main.c (catch_command_errors): Rename from
3506 catch_command_errors_const.
3507 (captured_main_1): Update.
3508
06871ae8
PA
35092017-09-20 Pedro Alves <palves@redhat.com>
3510
3511 * cli/cli-cmds.c (list_command): Use print_sal_location.
3512 (print_sal_location): New function.
3513 (ambiguous_line_spec): Use print_sal_location.
3514 * linespec.c (symbol_to_sal): Record the symbol in the sal.
3515 * symtab.c (find_function_start_sal): Likewise.
3516 * symtab.h (symtab_and_line::symbol): New field.
3517
e5f25bc5
PA
35182017-09-20 Pedro Alves <palves@redhat.com>
3519
3520 * linespec.c (minsym_found): Handle non-text minsyms.
3521 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
3522
1b7fa39e
WT
35232017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
3524
3525 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
3526 backslash.
3527
37dd0825
WT
35282017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
3529
3530 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
3531 vmovups instead vmovaps.
3532 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
3533
4e5a4f58
JB
35342017-09-19 John Baldwin <jhb@FreeBSD.org>
3535
3536 * NEWS (Changes since GDB 8.0): Add starti.
3537 * infcmd.c (enum run_break): New.
3538 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
3539 case.
3540 (run_command): Use enum run_how.
3541 (start_command): Likewise.
3542 (starti_command): New function.
3543 (RUN_ARGS_HELP): New macro.
3544 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
3545 commands. Add starti command.
3546
aa70c9f1
YQ
35472017-09-19 Yao Qi <yao.qi@linaro.org>
3548
3549 * Makefile.in (monitor.o): Remove the rule.
3550
d6541620
YQ
35512017-09-19 Yao Qi <yao.qi@linaro.org>
3552
3553 * annotate.h (struct annotate_arg_emitter): Use
3554 DISABLE_COPY_AND_ASSIGN.
3555 * common/refcounted-object.h (refcounted_object): Likewise.
3556 * completer.h (struct completion_result): Likewise.
3557 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
3558 * filename-seen-cache.h (filename_seen_cache): Likewise.
3559 * gdbcore.h (thread_section_name): Likewise.
3560 * gdb_regex.h (compiled_regex): Likewise.
3561 * gdbthread.h (scoped_restore_current_thread): Likewise.
3562 * inferior.h (scoped_restore_current_inferior): Likewise.
3563 * jit.c (jit_reader): Likewise.
3564 * linespec.h (struct linespec_result): Likewise.
3565 * mi/mi-parse.h (struct mi_parse): Likewise.
3566 * nat/fork-inferior.c (execv_argv): Likewise.
3567 * progspace.h (scoped_restore_current_program_space): Likewise.
3568 * python/python-internal.h (class gdbpy_enter): Likewise.
3569 * regcache.h (regcache): Likewise.
3570 * target-descriptions.c (struct tdesc_reg): Likewise.
3571 (struct tdesc_type): Likewise.
3572 (struct tdesc_feature): Likewise.
3573 * ui-out.h (ui_out_emit_type): Likewise.
3574
0615127c
SM
35752017-09-18 Simon Marchi <simon.marchi@ericsson.com>
3576
3577 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
3578 label abort_expression.
3579
5e187554
SM
35802017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3581
3582 * common/buffer.c (buffer_xml_printf): Adjust.
3583 * common/xml-utils.c (xml_escape_text): Change return type to
3584 std::string, update code accordingly.
3585 * common/xml-utils.h (xml_escape_text): Change return type to
3586 std::string.
3587 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
3588 * windows-tdep.c (windows_xfer_shared_library): Adjust.
3589 * unittests/xml-utils-selftests.c (test_xml_escape_text):
3590 Adjust.
3591
c3d7b541
SM
35922017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3593
3594 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
3595 (SUBDIR_UNITTESTS_OBS): Add new object file.
3596 * unittests/xml-utils-selftests.c: New file.
3597
1526853e
SM
35982017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3599
3600 * common/selftest.h (selftest): New struct/interface.
3601 (register_test): Add name parameter, add new overload.
3602 (run_tests): Add filter parameter.
3603 (for_each_selftest_ftype): New typedef.
3604 (for_each_selftest): New declaration.
3605 * common/selftest.c (tests): Change type to
3606 map<string, unique_ptr<selftest>>.
3607 (simple_selftest): New struct.
3608 (register_test): New function.
3609 (register_test): Add name parameter and use it.
3610 (run_tests): Add filter parameter and use it. Add prints.
3611 Adjust to vector -> map change.
3612 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
3613 registering selftests.
3614 * arm-tdep.c (_initialize_arm_tdep): Likewise.
3615 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
3616 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
3617 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
3618 * findvar.c (_initialize_findvar): Likewise.
3619 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
3620 * maint.c (maintenance_selftest): Update call to run_tests.
3621 (maintenance_info_selftests): New function.
3622 (_initialize_maint_cmds): Register "maintenance info selftests"
3623 command. Update "maintenance selftest" doc.
3624 * regcache.c (_initialize_regcache): Add names when registering
3625 selftests.
3626 * rust-exp.y (_initialize_rust_exp): Likewise.
3627 * selftest-arch.c (gdbarch_selftest): New struct.
3628 (gdbarch_tests): Remove.
3629 (register_test_foreach_arch): Add name parameter. Call
3630 register_test.
3631 (tests_with_arch): Remove, move most content to
3632 gdbarch_selftest::operator().
3633 (_initialize_selftests_foreach_arch): Remove.
3634 * selftest-arch.h (register_test_foreach_arch): Add name
3635 parameter.
3636 (run_tests_with_arch): New declaration.
3637 * utils-selftests.c (_initialize_utils_selftests): Add names
3638 when registering selftests.
3639 * utils.c (_initialize_utils): Likewise.
3640 * unittests/array-view-selftests.c
3641 (_initialize_array_view_selftests): Likewise.
3642 * unittests/environ-selftests.c (_initialize_environ_selftests):
3643 Likewise.
3644 * unittests/function-view-selftests.c
3645 (_initialize_function_view_selftests): Likewise.
3646 * unittests/offset-type-selftests.c
3647 (_initialize_offset_type_selftests): Likewise.
3648 * unittests/optional-selftests.c
3649 (_initialize_optional_selftests): Likewise.
3650 * unittests/scoped_restore-selftests.c
3651 (_initialize_scoped_restore_selftests): Likewise.
3652 * NEWS: Document "maintenance selftest" and "maint info
3653 selftests".
3654
5846367a
SM
36552017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3656
3657 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
3658 scoped_restore.
3659
bd77e8ff
SM
36602017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3661
3662 * mi/mi-main.c (mi_load_progress): Make uiout variable
3663 a unique_ptr.
3664
26a67918
PA
36652017-09-15 Pedro Alves <palves@redhat.com>
3666
3667 * compile/compile-c-types.c (convert_enum, convert_int)
3668 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
3669
3f8a7804
SM
36702017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3671
3672 * dwarf2read.c (copy_string): Remove.
3673 (parse_macro_definition): Replace copy_string with savestring.
3674
8d200706
YQ
36752017-09-15 Yao Qi <yao.qi@linaro.org>
3676
3677 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
3678 gdb_target_obs.
3679 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
3680 Likewise.
3681 (i[34567]86-*-linux*): Likewise.
3682
d185219d
SM
36832017-09-14 Simon Marchi <simon.marchi@ericsson.com>
3684
3685 * dwarf2expr.h (dwarf_stack_value): Add constructor.
3686 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
3687 <stack>: Change type to std::vector.
3688 <stack_len, stack_allocated>: Remove.
3689 <grow_stack>: Remove.
3690 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
3691 (dwarf_expr_context::~dwarf_expr_context): Remove.
3692 (dwarf_expr_context::grow_stack): Remove.
3693 (dwarf_expr_context::push): Adjust.
3694 (dwarf_expr_context::pop): Adjust.
3695 (dwarf_expr_context::fetch): Adjust.
3696 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
3697 (dwarf_expr_context::stack_empty_p): Adjust.
3698 (dwarf_expr_context::execute_stack_op): Adjust.
3699
eccd80d6
SM
37002017-09-14 Simon Marchi <simon.marchi@ericsson.com>
3701
3702 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
3703 return type to bool.
3704 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
3705
69009882
SM
37062017-09-14 Simon Marchi <simon.marchi@ericsson.com>
3707
3708 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
3709 Change type to bool.
3710 (dwarf_stack_value) <in_stack_memory>: Likewise.
3711 (dwarf_expr_context) <push_address>: Change parameter type to
3712 bool.
3713 <fetch_in_stack_memory>: Change return type to bool.
3714 <push>: Change parameter type to bool.
3715 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
3716 to bool.
3717 (dwarf_expr_context::push_address): Likewise.
3718 (dwarf_expr_context::fetch_in_stack_memory): Change return type
3719 to bool.
3720 (dwarf_expr_context::execute_stack_op): Adjust.
3721 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
3722
1e467161
SM
37232017-09-14 Simon Marchi <simon.marchi@ericsson.com>
3724
3725 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
3726 (struct dwarf_expr_context) <n_pieces>: Remove.
3727 <pieces>: Change type to std::vector.
3728 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
3729 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
3730 pieces.
3731 (dwarf_expr_context::add_piece): Adjust.
3732 * dwarf2loc.c (struct piece_closure): Initialize fields.
3733 <n_pieces>: Remove.
3734 <pieces>: Change type to std::vector.
3735 (allocate_piece_closure): Adjust, change parameter to
3736 std::vector rvalue and std::move it to piece_closure.
3737 (rw_pieced_value): Adjust.
3738 (check_pieced_synthetic_pointer): Adjust.
3739 (indirect_synthetic_pointer): Adjust.
3740 (coerce_pieced_ref): Adjust.
3741 (free_pieced_value_closure): Adjust. Use delete to free
3742 piece_closure.
3743 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
3744 to allocate_piece_closure.
3745 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
3746
0782db84
SM
37472017-09-12 Simon Marchi <simon.marchi@ericsson.com>
3748
3749 * probe.h (probe_ops_cp): Remove typedef.
3750 (DEF_VEC_P (probe_ops_cp)): Remove.
3751 (all_probe_ops): Change type to std::vector.
3752 * probe.c (info_probes_for_ops): Adjust to vector change.
3753 (probe_linespec_to_ops): Likewise.
3754 (all_probe_ops): Change type to std::vector.
3755 (_initialize_probe): Adjust to vector change.
3756 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
3757 * elfread.c (elf_get_probes): Likewise.
3758 * stap-probe.c (_initialize_stap_probe): Likewise.
3759
1eac6bea
SM
37602017-09-12 Simon Marchi <simon.marchi@ericsson.com>
3761
3762 * probe.h (struct bound_probe): Define constructors.
3763 * probe.c (bound_probe_s): Remove typedef.
3764 (DEF_VEC_O (bound_probe_s)): Remove VEC.
3765 (collect_probes): Change return type to std::vector, remove
3766 cleanup.
3767 (compare_probes): Return bool, change parameter type. Change
3768 semantic to "less than".
3769 (gen_ui_out_table_header_info): Change parameter to std::vector
3770 and update.
3771 (exists_probe_with_pops): Likewise.
3772 (info_probes_for_ops): Update to std::vector change.
3773 (enable_probes_command): Likewise.
3774 (disable_probes_command): Likewise.
3775
aaa63a31
SM
37762017-09-12 Simon Marchi <simon.marchi@ericsson.com>
3777
3778 * probe.h (struct probe_ops) <get_probes>: Change parameter from
3779 vec to std::vector.
3780 * probe.c (parse_probes_in_pspace): Update.
3781 (find_probes_in_objfile): Update.
3782 (find_probe_by_pc): Update.
3783 (collect_probes): Update.
3784 (probe_any_get_probes): Update.
3785 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
3786 return type to reference to std::vector.
3787 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
3788 std::vector and update.
3789 (dtrace_process_dof): Likewise.
3790 (dtrace_get_probes): Likewise.
3791 * elfread.c (elf_get_probes): Change return type to std::vector,
3792 store an std::vector in bfd_data.
3793 (probe_key_free): Update to std::vector.
3794 * stap-probe.c (handle_stap_probe): Change parameter to
3795 std::vector and update.
3796 (stap_get_probes): Likewise.
3797 * symfile-debug.c (debug_sym_get_probes): Change return type to
3798 std::vector and update.
3799
cb85b21b
TT
38002017-09-11 Tom Tromey <tom@tromey.com>
3801
3802 * breakpoint.c (program_breakpoint_here_p): Update.
3803 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
3804 from make_show_memory_breakpoints_cleanup. Return a
3805 scoped_restore_tmpl<int>.
3806 (restore_show_memory_breakpoints): Remove.
3807 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
3808 * mem-break.c (memory_validate_breakpoint): Update.
3809 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
3810 (ia64_memory_remove_breakpoint): Update.
3811 (ia64_breakpoint_from_pc): Update.
3812 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
3813 from make_show_memory_breakpoints_cleanup.
3814
8fbc99ef
TT
38152017-09-11 Tom Tromey <tom@tromey.com>
3816
3817 * d-namespace.c (d_lookup_symbol): Use std::string.
3818 (find_symbol_in_baseclass): Likewise.
3819
50feb4bd
TT
38202017-09-11 Tom Tromey <tom@tromey.com>
3821
3822 * ctf.c (ctf_start): Use std::string.
3823
c6dc63a1
TT
38242017-09-11 Tom Tromey <tom@tromey.com>
3825
3826 * ada-lang.c (is_known_support_routine): Update.
3827 (ada_unhandled_exception_name_addr_from_raise): Update.
3828 * guile/scm-frame.c (gdbscm_frame_name): Update.
3829 * python/py-frame.c (frapy_name): Update.
3830 (frapy_function): Update.
3831 * stack.h (find_frame_funname): Update.
3832 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
3833 (print_frame): Update.
3834
d6b9b80f
TT
38352017-09-11 Tom Tromey <tom@tromey.com>
3836
3837 * findcmd.c (put_bits): Take a gdb::byte_vector.
3838 (parse_find_args): Return gdb::byte_vector. "args" now const.
3839 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
3840 cleanups.
3841 (find_command): Update.
3842
a9921622
TT
38432017-09-11 Tom Tromey <tom@tromey.com>
3844
3845 * cli/cli-script.c (class scoped_restore_hook_in): New.
3846 (clear_hook_in_cleanup): Remove.
3847 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
3848 scoped_restore_hook_in.
3849
be0d7abb
TT
38502017-09-11 Tom Tromey <tom@tromey.com>
3851
3852 * cli/cli-script.c (restore_interp): Remove.
3853 (read_command_lines): Use scoped_restore_interp.
3854 * interps.c (scoped_restore_interp::set_temp): Rename from
3855 interp_set_temp.
3856 * interps.h (class scoped_restore_interp): New.
3857 (interp_set_temp): Remove.
3858
00f675ff
TT
38592017-09-11 Tom Tromey <tom@tromey.com>
3860
3861 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
3862 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
3863 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
3864 scoped_restore.
3865 (mi_cmd_break_insert_1): Update.
3866 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
3867 scoped_restore.
3868
cb791d59
TT
38692017-09-11 Tom Tromey <tom@tromey.com>
3870
3871 * demangle.c (demangle_command): Update.
3872 * breakpoint.c (disable_command): Update.
3873 (enable_command): Update.
3874 (find_location_by_number): Make "number" const. Use
3875 get_number_trailer.
3876 * cli/cli-utils.c (extract_arg): Return std::string.
3877 * probe.c (parse_probe_linespec): Update. Change types.
3878 (collect_probes): Take string arguments.
3879 (parse_probe_linespec): Likewise.
3880 (info_probes_for_ops): Update.
3881 (enable_probes_command): Update.
3882 (disable_probes_command): Update.
3883 * break-catch-sig.c (catch_signal_split_args): Update.
3884 * mi/mi-parse.c (mi_parse): Update.
3885
2039bd9f
TT
38862017-09-11 Tom Tromey <tom@tromey.com>
3887
3888 * language.h (language_enum): Make argument const.
3889 * language.c (language_enum): Make argument const.
3890
f1735a53
TT
38912017-09-11 Tom Tromey <tom@tromey.com>
3892
3893 * common/common-utils.h (skip_to_space): Remove macro, redeclare
3894 as function.
3895 (skip_to_space): Rename from skip_to_space_const.
3896 * common/common-utils.c (skip_to_space): New function.
3897 (skip_to_space): Rename from skip_to_space_const.
3898 * cli/cli-utils.h (get_number): Rename from get_number_const.
3899 (extract_arg): Rename from extract_arg_const.
3900 * cli/cli-utils.c (get_number): Rename from get_number_const.
3901 (extract_arg): Rename from extract_arg_const.
3902 (number_or_range_parser::get_number): Use ::get_number.
3903 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
3904 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
3905 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
3906 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
3907 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
3908 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
3909 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
3910 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
3911
7d221d74
TT
39122017-09-11 Tom Tromey <tom@tromey.com>
3913
3914 * python/python.c (do_start_initialization): Use
3915 py-event-types.def to initialize types.
3916 Define all object type structures.
3917 * python/python-internal.h: Don't declare event initialization
3918 functions.
3919 * python/py-threadevent.c (thread_event_object_type): Don't
3920 define.
3921 * python/py-stopevent.c (stop_event_object_type): Don't define.
3922 * python/py-signalevent.c (signal_event_object_type): Don't
3923 declare or define.
3924 * python/py-newobjfileevent.c (new_objfile_event_object_type)
3925 (clear_objfiles_event_object_type): Don't declare or define.
3926 * python/py-infevents.c (inferior_call_pre_event_object_type)
3927 (inferior_call_post_event_object_type)
3928 (register_changed_event_object_type)
3929 (memory_changed_event_object_type): Don't declare or define.
3930 * python/py-inferior.c (new_thread_event_object_type)
3931 (new_inferior_event_object_type)
3932 (inferior_deleted_event_object_type): Don't declare or define.
3933 * python/py-exitedevent.c (exited_event_object_type): Don't
3934 declare or define.
3935 * python/py-evts.c (gdbpy_initialize_py_events): Use
3936 py-all-events.def.
3937 * python/py-events.h (thread_event_object_type): Don't declare.
3938 (events_object): Use py-all-events.def.
3939 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
3940 py-event-types.def.
3941 * python/py-event-types.def: New file.
3942 * python/py-continueevent.c (create_continue_event_object): Don't
3943 declare or define.
3944 * python/py-bpevent.c (breakpoint_event_object_type): Don't
3945 declare or define.
3946 * python/py-all-events.def: New file.
3947
35c61a1d
TT
39482017-09-11 Tom Tromey <tom@tromey.com>
3949
3950 * python/py-threadevent.c (create_thread_event_object): Return
3951 gdbpy_ref.
3952 * python/py-stopevent.h (create_stop_event_object)
3953 (create_breakpoint_event_object, create_signal_event_object):
3954 Update.
3955 * python/py-stopevent.c (create_stop_event_object): Return
3956 gdbpy_ref.
3957 (emit_stop_event): Update.
3958 * python/py-signalevent.c (create_signal_event_object): Return
3959 gdbpy_ref.
3960 * python/py-infevents.c (create_inferior_call_event_object):
3961 Update.
3962 * python/py-event.h (create_event_object)
3963 (create_thread_event_object): Update.
3964 * python/py-event.c (create_event_object): Return gdbpy_ref.
3965 * python/py-continueevent.c: Return gdbpy_ref.
3966 * python/py-bpevent.c (create_breakpoint_event_object): Return
3967 gdbpy_ref.
3968
7c96f8c1
TT
39692017-09-11 Tom Tromey <tom@tromey.com>
3970
3971 PR python/15622:
3972 * NEWS: Add entry.
3973 * python/python.c (do_start_initialization): Initialize new event
3974 types.
3975 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
3976 (gdbpy_initialize_inferior_deleted_event)
3977 (gdbpy_initialize_new_thread_event): Declare.
3978 * python/py-threadevent.c (create_thread_event_object): Add option
3979 "thread" parameter.
3980 * python/py-inferior.c (new_thread_event_object_type)
3981 (new_inferior_event_object_type)
3982 (inferior_deleted_event_object_type): Declare.
3983 (python_new_inferior, python_inferior_deleted): New functions.
3984 (add_thread_object): Emit new_thread event.
3985 (gdbpy_initialize_inferior): Attach new functions to corresponding
3986 observers.
3987 (new_thread, new_inferior, inferior_deleted): Define new event
3988 types.
3989 * python/py-evts.c (gdbpy_initialize_py_events): Add new
3990 registries.
3991 * python/py-events.h (events_object) <new_inferior,
3992 inferior_deleted, new_thread>: New fields.
3993 * python/py-event.h (create_thread_event_breakpoint): Add optional
3994 "thread" parameter.
3995
72542b8e
AB
39962017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
3997
3998 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
3999 check current_ui instead.
4000 (internal_vproblem): Likewise.
4001
0d64823e
SM
40022017-09-09 Simon Marchi <simon.marchi@ericsson.com>
4003
4004 * thread.c (print_thread_info_1): Remove unnecessary calls to
4005 uiout->is_mi_like_p.
4006
eb1e02fd
TT
40072017-09-09 Tom Tromey <tom@tromey.com>
4008
4009 * namespace.h (add_using_directive): Update.
4010 * namespace.c (add_using_directive): Change type of excludes to
4011 std::vector.
4012 * dwarf2read.c (read_import_statement): Use std::vector.
4013 (read_namespace): Update.
4014 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
4015
0fc21fd8
TT
40162017-09-09 Tom Tromey <tom@tromey.com>
4017
4018 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
4019
49663d05
TT
40202017-09-09 Tom Tromey <tom@tromey.com>
4021
4022 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
4023
0b868b60
TT
40242017-09-09 Tom Tromey <tom@tromey.com>
4025
4026 * stack.c (func_command): Use gdb::def_vector.
4027
c0470d48
TT
40282017-09-09 Tom Tromey <tom@tromey.com>
4029
4030 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
4031 ui_out_emit_list, ui_out_emit_tuple.
4032 (mi_cmd_var_update): Likewise.
4033
ca5909c7
TT
40342017-09-09 Tom Tromey <tom@tromey.com>
4035
4036 * mi/mi-interp.c (mi_user_selected_context_changed): Use
4037 ui_out_redirect_pop.
4038 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
4039 ui_out_redirect_pop.
4040 * utils.c (do_ui_out_redirect_pop)
4041 (make_cleanup_ui_out_redirect_pop): Remove.
4042 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
4043 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
4044 * ui-out.h (ui_out_redirect_pop): New class.
4045
e6a2252a
TT
40462017-09-09 Tom Tromey <tom@tromey.com>
4047
4048 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
4049 (list_available_thread_groups, mi_cmd_list_thread_groups)
4050 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
4051 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
4052 Likewise.
4053
393702cd
TT
40542017-09-09 Tom Tromey <tom@tromey.com>
4055
4056 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
4057 ui_out_emit_tuple.
4058
76f9c9cf
TT
40592017-09-09 Tom Tromey <tom@tromey.com>
4060
4061 * target.c (flash_erase_command): Use ui_out_emit_tuple.
4062 * stack.c (print_frame): Use ui_out_emit_tuple.
4063 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
4064 (info_spu_mailbox_command, info_spu_dma_command)
4065 (info_spu_proxydma_command): Likewise.
4066 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
4067 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
4068 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
4069 ui_out_emit_tuple.
4070 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
4071
dc9fe180
TT
40722017-09-09 Tom Tromey <tom@tromey.com>
4073
4074 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
4075 (class ui_out_emit_table): Update comment.
4076 * ui-out.c (do_cleanup_table_end)
4077 (make_cleanup_ui_out_table_begin_end): Remove.
4078 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
4079 (info_spu_dma_cmdlist): Likewise.
4080 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
4081 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
4082 ui_out_emit_table.
4083
f8cc3da6
TT
40842017-09-09 Tom Tromey <tom@tromey.com>
4085
4086 * thread.c (print_thread_info_1): Use ui_out_emit_table,
4087 ui_out_emit_list, gdb::optional.
4088
481695ed
JB
40892017-09-09 John Baldwin <jhb@FreeBSD.org>
4090
4091 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
4092 prototype.
4093 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
4094 prototype.
4095 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
4096 prototype.
4097 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
4098 * ada-exp.y: Remove _initialize_ada_exp prototype.
4099 * ada-lang.c: Remove _initialize_ada_language prototype.
4100 * ada-tasks.c: Remove _initialize_tasks prototype.
4101 * addrmap.c: Remove _initialize_addrmap prototype.
4102 * agent.c: Remove _initialize_agent prototype.
4103 * aix-thread.c: Remove _initialize_aix_thread prototype.
4104 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
4105 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
4106 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
4107 prototype.
4108 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
4109 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
4110 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
4111 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
4112 prototype.
4113 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
4114 prototype.
4115 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
4116 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
4117 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
4118 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
4119 prototype.
4120 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
4121 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
4122 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
4123 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
4124 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
4125 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
4126 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
4127 prototype.
4128 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
4129 prototype.
4130 * annotate.c: Remove _initialize_annotate prototype.
4131 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
4132 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
4133 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
4134 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
4135 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
4136 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
4137 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
4138 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
4139 prototype.
4140 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
4141 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
4142 * auto-load.c: Remove _initialize_auto_load prototype.
4143 * auxv.c: Remove _initialize_auxv prototype.
4144 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
4145 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
4146 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
4147 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
4148 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
4149 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
4150 prototype.
4151 * break-catch-throw.c: Remove _initialize_break_catch_throw
4152 prototype.
4153 * breakpoint.c: Remove _initialize_breakpoint prototype.
4154 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
4155 * btrace.c: Remove _initialize_btrace prototype.
4156 * charset.c: Remove _initialize_charset prototype.
4157 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
4158 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
4159 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
4160 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
4161 * cli/cli-script.c: Remove _initialize_cli_script prototype.
4162 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
4163 * coffread.c: Remove _initialize_coffread prototype.
4164 * compile/compile.c: Remove _initialize_compile prototype.
4165 * complaints.c: Remove _initialize_complaints prototype.
4166 * completer.c: Remove _initialize_completer prototype.
4167 * copying.awk: Remove _initialize_copying prototype.
4168 * copying.c: Regenerate.
4169 * core-regset.c: Remove _initialize_core_regset prototype.
4170 * corefile.c: Remove _initialize_core prototype.
4171 * corelow.c: Remove _initialize_corelow prototype.
4172 * cp-abi.c: Remove _initialize_cp_abi prototype.
4173 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
4174 * cp-support.c: Remove _initialize_cp_support prototype.
4175 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
4176 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
4177 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
4178 * ctf.c: Remove _initialize_ctf prototype.
4179 * d-lang.c: Remove _initialize_d_language prototype.
4180 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
4181 prototype.
4182 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
4183 * dbxread.c: Remove _initialize_dbxread prototype.
4184 * dcache.c: Remove _initialize_dcache prototype.
4185 * demangle.c: Remove _initialize_demangler prototype.
4186 * disasm-selftests.c: Remove _initialize_disasm_selftests
4187 prototype.
4188 * disasm.c: Remove _initialize_disasm prototype.
4189 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
4190 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
4191 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
4192 prototype.
4193 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
4194 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
4195 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
4196 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
4197 * elfread.c: Remove _initialize_elfread prototype.
4198 * exec.c: Remove _initialize_exec prototype.
4199 * extension.c: Remove _initialize_extension prototype.
4200 * f-lang.c: Remove _initialize_f_language prototype.
4201 * f-valprint.c: Remove _initialize_f_valprint prototype.
4202 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
4203 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
4204 * filesystem.c: Remove _initialize_filesystem prototype.
4205 * findcmd.c: Remove _initialize_mem_search prototype.
4206 * fork-child.c: Remove _initialize_fork_child prototype.
4207 * frame-base.c: Remove _initialize_frame_base prototype.
4208 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
4209 * frame.c: Remove _initialize_frame prototype.
4210 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
4211 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
4212 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
4213 * gcore.c: Remove _initialize_gcore prototype.
4214 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
4215 * gdbarch.c: Regenerate.
4216 * gdbarch.sh: Remove _initialize_gdbarch prototype.
4217 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
4218 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
4219 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
4220 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
4221 * go-lang.c: Remove _initialize_go_language prototype.
4222 * go32-nat.c: Remove _initialize_go32_nat prototype.
4223 * guile/guile.c: Remove _initialize_guile prototype.
4224 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
4225 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
4226 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
4227 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
4228 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
4229 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
4230 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
4231 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
4232 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
4233 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
4234 prototype.
4235 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
4236 prototype.
4237 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
4238 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
4239 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
4240 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
4241 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
4242 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
4243 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
4244 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
4245 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
4246 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
4247 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
4248 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
4249 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
4250 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
4251 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
4252 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
4253 prototype.
4254 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
4255 prototype.
4256 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
4257 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
4258 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
4259 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
4260 * infcall.c: Remove _initialize_infcall prototype.
4261 * infcmd.c: Remove _initialize_infcmd prototype.
4262 * inferior.c: Remove _initialize_inferiors prototype.
4263 * inflow.c: Remove _initialize_inflow prototype.
4264 * infrun.c: Remove _initialize_infrun prototype.
4265 * interps.c: Remove _initialize_interpreter prototype.
4266 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
4267 * jit.c: Remove _initialize_jit prototype.
4268 * language.c: Remove _initialize_language prototype.
4269 * linux-fork.c: Remove _initialize_linux_fork prototype.
4270 * linux-nat.c: Remove _initialize_linux_nat prototype.
4271 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
4272 * linux-thread-db.c: Remove _initialize_thread_db prototype.
4273 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
4274 * m2-lang.c: Remove _initialize_m2_language prototype.
4275 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
4276 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
4277 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
4278 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
4279 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
4280 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
4281 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
4282 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
4283 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
4284 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
4285 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
4286 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
4287 * machoread.c: Remove _initialize_machoread prototype.
4288 * macrocmd.c: Remove _initialize_macrocmd prototype.
4289 * macroscope.c: Remove _initialize_macroscope prototype.
4290 * maint.c: Remove _initialize_maint_cmds prototype.
4291 * mdebugread.c: Remove _initialize_mdebugread prototype.
4292 * memattr.c: Remove _initialize_mem prototype.
4293 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
4294 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
4295 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
4296 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
4297 * mi/mi-main.c: Remove _initialize_mi_main prototype.
4298 * microblaze-linux-tdep.c: Remove
4299 _initialize_microblaze_linux_tdep prototype.
4300 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
4301 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
4302 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
4303 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
4304 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
4305 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
4306 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
4307 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
4308 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
4309 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
4310 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
4311 prototype.
4312 * mipsread.c: Remove _initialize_mipsread prototype.
4313 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
4314 prototype.
4315 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
4316 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
4317 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
4318 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
4319 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
4320 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
4321 prototype.
4322 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
4323 * nto-procfs.c: Remove _initialize_procfs prototype.
4324 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
4325 * objc-lang.c: Remove _initialize_objc_language prototype.
4326 * objfiles.c: Remove _initialize_objfiles prototype.
4327 * observer.c: Remove observer_test_first_notification_function,
4328 observer_test_second_notification_function,
4329 observer_test_third_notification_function, and
4330 _initialize_observer prototypes.
4331 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
4332 * osabi.c: Remove _initialize_gdb_osabi prototype.
4333 * osdata.c: Remove _initialize_osdata prototype.
4334 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
4335 * parse.c: Remove _initialize_parse prototype.
4336 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
4337 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
4338 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
4339 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
4340 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
4341 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
4342 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
4343 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
4344 * printcmd.c: Remove _initialize_printcmd prototype.
4345 * probe.c: Remove _initialize_probe prototype.
4346 * proc-api.c: Remove _initialize_proc_api prototype.
4347 * proc-events.c: Remove _initialize_proc_events prototype.
4348 * proc-service.c: Remove _initialize_proc_service prototype.
4349 * procfs.c: Remove _initialize_procfs prototype.
4350 * psymtab.c: Remove _initialize_psymtab prototype.
4351 * python/python.c: Remove _initialize_python prototype.
4352 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
4353 * record-btrace.c: Remove _initialize_record_btrace prototype.
4354 * record-full.c: Remove _initialize_record_full prototype.
4355 * record.c: Remove _initialize_record prototype.
4356 * regcache.c: Remove _initialize_regcache prototype.
4357 * reggroups.c: Remove _initialize_reggroup prototype.
4358 * remote-notif.c: Remove _initialize_notif prototype.
4359 * remote-sim.c: Remove _initialize_remote_sim prototype.
4360 * remote.c: Remove _initialize_remote prototype.
4361 * reverse.c: Remove _initialize_reverse prototype.
4362 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
4363 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
4364 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
4365 prototype.
4366 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
4367 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
4368 * rust-exp.y: Remove _initialize_rust_exp prototype.
4369 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
4370 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
4371 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
4372 * score-tdep.c: Remove _initialize_score_tdep prototype.
4373 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
4374 prototype.
4375 * ser-go32.c: Remove _initialize_ser_dos prototype.
4376 * ser-mingw.c: Remove _initialize_ser_windows prototype.
4377 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
4378 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
4379 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
4380 * serial.c: Remove _initialize_serial prototype.
4381 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
4382 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
4383 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
4384 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
4385 * skip.c: Remove _initialize_step_skip prototype.
4386 * sol-thread.c: Remove _initialize_sol_thread prototype.
4387 * solib-aix.c: Remove _initialize_solib_aix prototype.
4388 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
4389 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
4390 * solib-frv.c: Remove _initialize_frv_solib prototype.
4391 * solib-spu.c: Remove _initialize_spu_solib prototype.
4392 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
4393 * solib-target.c: Remove _initialize_solib_target prototype.
4394 * solib.c: Remove _initialize_solib prototype.
4395 * source.c: Remove _initialize_source prototype.
4396 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
4397 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
4398 prototype.
4399 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
4400 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
4401 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
4402 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
4403 prototype.
4404 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
4405 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
4406 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
4407 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
4408 prototype.
4409 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
4410 prototype.
4411 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
4412 prototype.
4413 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
4414 prototype.
4415 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
4416 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
4417 prototype.
4418 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
4419 prototype.
4420 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
4421 prototype.
4422 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
4423 prototype.
4424 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
4425 prototype.
4426 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
4427 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
4428 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
4429 * stabsread.c: Remove _initialize_stabsread prototype.
4430 * stack.c: Remove _initialize_stack prototype.
4431 * stap-probe.c: Remove _initialize_stap_probe prototype.
4432 * std-regs.c: Remove _initialize_frame_reg prototype.
4433 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
4434 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
4435 * symfile.c: Remove _initialize_symfile prototype.
4436 * symmisc.c: Remove _initialize_symmisc prototype.
4437 * symtab.c: Remove _initialize_symtab prototype.
4438 * target-dcache.c: Remove _initialize_target_dcache prototype.
4439 * target-descriptions.c: Remove _initialize_target_descriptions
4440 prototype.
4441 * thread.c: Remove _initialize_thread prototype.
4442 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
4443 prototype.
4444 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
4445 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
4446 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
4447 prototype.
4448 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
4449 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
4450 * tracefile.c: Remove _initialize_tracefile prototype.
4451 * tracepoint.c: Remove _initialize_tracepoint prototype.
4452 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
4453 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
4454 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
4455 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
4456 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
4457 * tui/tui-win.c: Remove _initialize_tui_win prototype.
4458 * tui/tui.c: Remove _initialize_tui prototype.
4459 * typeprint.c: Remove _initialize_typeprint prototype.
4460 * user-regs.c: Remove _initialize_user_regs prototype.
4461 * utils.c: Remove _initialize_utils prototype.
4462 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
4463 * valarith.c: Remove _initialize_valarith prototype.
4464 * valops.c: Remove _initialize_valops prototype.
4465 * valprint.c: Remove _initialize_valprint prototype.
4466 * value.c: Remove _initialize_values prototype.
4467 * varobj.c: Remove _initialize_varobj prototype.
4468 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
4469 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
4470 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
4471 * windows-nat.c: Remove _initialize_windows_nat,
4472 _initialize_check_for_gdb_ini, and _initialize_loadable
4473 prototypes.
4474 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
4475 * xcoffread.c: Remove _initialize_xcoffread prototype.
4476 * xml-support.c: Remove _initialize_xml_support prototype.
4477 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
4478 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
4479 prototype.
4480 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
4481 prototype.
4482 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
4483
a611b5cb
KS
44842017-09-08 Keith Seitz <keiths@redhat.com>
4485
4486 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
4487 field.
4488
469412dd
CW
44892017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
4490
4491 * f-valprint.c (f_val_print): Remove check for one byte
4492 sized integers. Remove printing of character type.
4493
a5ad232b
FP
44942017-09-08 Frank Penczek <frank.penczek@intel.com>
4495 Christoph Weinmann <christoph.t.weinmann@intel.com>
4496 Bernhard Heckel <bernhard.heckel@intel.com>
4497
4498 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
4499 to maintain proper indentation when printing pointers/refs.
4500
e5014227
JB
45012017-09-07 Joel Brobecker <brobecker@adacore.com>
4502
4503 GDB 8.0.1 released.
4504
63c99141
JB
45052017-09-07 Joel Brobecker <brobecker@adacore.com>
4506
4507 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
4508
69c1e056
TT
45092017-09-05 Tom Tromey <tom@tromey.com>
4510
4511 * parse.c (funcall_chain): Now a std::vector.
4512 (start_arglist, end_arglist): Simplify.
4513 (free_funcalls): Remove.
4514 (parse_exp_in_context_1): Remove cleanup.
4515
fef704bf
TT
45162017-09-05 Tom Tromey <tom@tromey.com>
4517
4518 * go-exp.y (go_parse): Don't create a cleanup.
4519
5613c585
TT
45202017-09-05 Tom Tromey <tom@tromey.com>
4521
4522 * d-exp.y (PrimaryExpression): Use std::string.
4523 (d_parse): Don't create a cleanup.
4524
eae49211
TT
45252017-09-05 Tom Tromey <tom@tromey.com>
4526
4527 * utils.c (do_clear_parser_state): Remove.
4528 (make_cleanup_clear_parser_state): Remove.
4529 * p-exp.y (pascal_parse): Use scoped_restore.
4530 * m2-exp.y (m2_parse): Use scoped_restore.
4531 * f-exp.y (f_parse): Use scoped_restore.
4532 * d-exp.y (d_parse): Use scoped_restore.
4533 * c-exp.y (c_parse): Use scoped_restore.
4534 * ada-exp.y (ada_parse): Use scoped_restore.
4535 * utils.h (make_cleanup_clear_parser_state): Remove.
4536
73b9be8b
KS
45372017-09-06 Keith Seitz <keiths@redhat.com>
4538
4539 * dwarf2read.c (dw2_linkage_name_attr): New function.
4540 (dw2_linkage_name): New function.
4541 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
4542 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
4543 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
4544
a102602b
KR
45452017-09-06 Kamil Rytarowski <n54@gmx.com>
4546
4547 * config/djgpp/djconfig.sh: Correct shell portability issue.
4548
28ad437d
KR
45492017-09-06 Kamil Rytarowski <n54@gmx.com>
4550
4551 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
4552
351787dd
JB
45532017-09-06 John Baldwin <jhb@FreeBSD.org>
4554
4555 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
4556 * NEWS: Mention new FreeBSD/mips native configuration.
4557 * configure.host: Add aarch64*-*-freebsd*.
4558 * configure.nat: Likewise.
4559 * aarch64-fbsd-nat.c: New file.
4560
c0f84956
JB
45612017-09-06 John Baldwin <jhb@FreeBSD.org>
4562
4563 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
4564 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
4565 * NEWS: Mention new FreeBSD/aarch64 target.
4566 * configure.tgt: Add aarch64*-*-freebsd*.
4567 * aarch64-fbsd-tdep.c: New file.
4568 * aarch64-fbsd-tdep.h: New file.
4569
7610297a
KR
45702017-09-06 Kamil Rytarowski <n54@gmx.com>
4571
4572 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
4573
fbd1b771
JK
45742017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
4575
4576 * parse.c (find_minsym_type_and_address): Don't relocate addresses
4577 of TLS symbols.
4578
5ca79eae
PW
45792017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4580
4581 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
4582 call.
4583
bf93d7ba
SM
45842017-09-05 Simon Marchi <simon.marchi@ericsson.com>
4585
4586 * infrun.c (follow_exec): Call add_thread after
4587 target_find_description.
4588
1bb7c059
SM
45892017-09-05 Simon Marchi <simon.marchi@ericsson.com>
4590
4591 * infrun.c (handle_inferior_event_1): When exec'ing, read
4592 stop_pc after follow_exec.
4593
fc809827
SM
45942017-09-05 Simon Marchi <simon.marchi@ericsson.com>
4595
4596 * remote.c (process_g_packet): Update error message.
4597
d2fcdd85
YQ
45982017-09-05 Yao Qi <yao.qi@linaro.org>
4599
4600 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
4601 targets.
4602
e69570ee
PA
46032017-09-05 Pedro Alves <palves@redhat.com>
4604
4605 * eval.c (eval_call, evaluate_funcall): New functions, factored
4606 out from ...
4607 (evaluate_subexp_standard): ... this.
4608
22916b07
YQ
46092017-09-05 Yao Qi <yao.qi@linaro.org>
4610
4611 * amd64-tdep.c (amd64_target_description): Create target
4612 descriptions.
4613 (_initialize_amd64_tdep): Don't call functions
4614 initialize_tdesc_amd64_*. Add self tests.
4615 * arch/amd64.c (amd64_create_target_description): Add parameter
4616 is_linux. Call set_tdesc_osabi if is_linux is true.
4617 * arch/amd64.h (amd64_create_target_description): Update the
4618 declaration.
4619 * arch/i386.c (i386_create_target_description): Add parameter
4620 is_linux. Call set_tdesc_osabi if is_linux is true.
4621 * arch/i386.h (i386_create_target_description): Update
4622 declaration.
4623 * configure.tgt: Add i386.o to gdb_target_obs.
4624 * features/Makefile (XMLTOC): Remove i386/*.xml.
4625 * features/i386/amd64-avx-avx512.c: Remove.
4626 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
4627 * features/i386/amd64-avx-mpx.c: Remove.
4628 * features/i386/amd64-avx.c: Remove.
4629 * features/i386/amd64-mpx.c: Remove.
4630 * features/i386/amd64.c: Remove.
4631 * features/i386/i386-avx-avx512.c: Remove.
4632 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
4633 * features/i386/i386-avx-mpx.c: Remove.
4634 * features/i386/i386-avx.c: Remove.
4635 * features/i386/i386-mmx.c: Remove.
4636 * features/i386/i386-mpx.c: Remove.
4637 * features/i386/i386.c: Remove.
4638 * i386-tdep.c: Don't include features/i386/i386*.c., include
4639 target-descriptions.h and arch/i386.h.
4640 (i386_target_description): Create target descriptions.
4641 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
4642 functions. Do self tests.
4643
0854b7b1
YQ
46442017-09-05 Yao Qi <yao.qi@linaro.org>
4645
4646 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
4647 * features/i386/amd64-avx-avx512-linux.c: Removed.
4648 * features/i386/amd64-avx-linux.c: Removed.
4649 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
4650 * features/i386/amd64-avx-mpx-linux.c: Removed.
4651 * features/i386/amd64-linux.c: Removed.
4652 * features/i386/amd64-mpx-linux.c: Removed.
4653 * features/i386/x32-avx-avx512-linux.c: Removed.
4654 * features/i386/x32-avx-linux.c: Removed.
4655 * features/i386/x32-linux.c: Removed.
4656
b4570e4b
YQ
46572017-09-05 Yao Qi <yao.qi@linaro.org>
4658
4659 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
4660 features/i386/*.c.
4661 (amd64_linux_read_description): Call
4662 amd64_create_target_description.
4663 * arch/amd64.c: New file.
4664 * arch/amd64.h: New file.
4665 * configure.tgt (x86_64-*-linux*): Append amd64.o.
4666 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
4667
6c73f67f
YQ
46682017-09-05 Yao Qi <yao.qi@linaro.org>
4669
4670 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
4671 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
4672 (amd64_linux_read_description): Create target descriptions.
4673 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
4674 functions. Add unit tests.
4675 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
4676 x32-core.xml.
4677 * features/i386/64bit-avx.c: Generated.
4678 * features/i386/64bit-avx512.c: Generated.
4679 * features/i386/64bit-core.c: Generated.
4680 * features/i386/64bit-linux.c: Generated.
4681 * features/i386/64bit-mpx.c: Generated.
4682 * features/i386/64bit-pkeys.c: Generated.
4683 * features/i386/64bit-segments.c: Generated.
4684 * features/i386/64bit-sse.c: Generated.
4685 * features/i386/x32-core.c: Generated.
4686 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
4687 c files for amd64-linux and x32-linux.
4688
9d3d478b
YQ
46892017-09-05 Yao Qi <yao.qi@linaro.org>
4690
4691 * amd64-linux-tdep.c (amd64_linux_read_description): New
4692 function.
4693 (amd64_linux_core_read_description): Call
4694 amd64_linux_read_description.
4695 (amd64_linux_init_abi): Likewise.
4696 (amd64_x32_linux_init_abi): Likewise.
4697 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
4698 * x86-linux-nat.c (x86_linux_read_description): Call
4699 amd64_linux_read_description.
4700
b9f1d50f
YQ
47012017-09-05 Yao Qi <yao.qi@linaro.org>
4702
4703 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
4704 comments.
4705
188c9e6d
YQ
47062017-09-05 Yao Qi <yao.qi@linaro.org>
4707
4708 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
4709 * features/i386/i386-avx-avx512-linux.c: Remove.
4710 * features/i386/i386-avx-linux.c: Remove.
4711 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
4712 * features/i386/i386-avx-mpx-linux.c: Remove.
4713 * features/i386/i386-linux.c: Remove.
4714 * features/i386/i386-mmx-linux.c: Remove.
4715 * features/i386/i386-mpx-linux.c: Remove.
4716
5f035c07
YQ
47172017-09-05 Yao Qi <yao.qi@linaro.org>
4718
4719 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
4720 (SFILES): Add arch/i386.c.
4721 (HFILES_NO_SRCDIR): Add arch/i386.h.
4722 * arch/i386.c: New file.
4723 * arch/i386.h: New file.
4724 * arch/tdesc.h (allocate_target_description): Declare.
4725 (set_tdesc_architecture): Declare.
4726 (set_tdesc_osabi): Declare.
4727 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
4728 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
4729 include arch/i386.h.
4730 (i386_linux_read_description): Remove code and call
4731 i386_create_target_description.
4732 (set_tdesc_architecture): New function.
4733 (set_tdesc_osabi): New function.
4734 * target-descriptions.h (allocate_target_description): Remove.
4735
0abe8a89
YQ
47362017-09-05 Yao Qi <yao.qi@linaro.org>
4737
4738 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
4739 * target-descriptions.c (tdesc_create_feature): Likewise, and
4740 adjust code.
4741 * features/i386/32bit-avx.c: Re-generated.
4742 * features/i386/32bit-avx512.c: Re-generated.
4743 * features/i386/32bit-core.c: Re-generated.
4744 * features/i386/32bit-linux.c: Re-generated.
4745 * features/i386/32bit-mpx.c: Re-generated.
4746 * features/i386/32bit-pkeys.c: Re-generated.
4747 * features/i386/32bit-sse.c: Re-generated.
4748
0a188386
YQ
47492017-09-05 Yao Qi <yao.qi@linaro.org>
4750
4751 * regformats/regdef.h (struct reg): Override operator == and !=.
4752
f49ff000
YQ
47532017-09-05 Yao Qi <yao.qi@linaro.org>
4754
4755 * arch/tdesc.h: New file.
4756 * regformats/regdat.sh: Generate code using tdesc_create_reg.
4757 * target-descriptions.c: Update comments.
4758 * target-descriptions.h: Include "arch/tdesc.h". Remove the
4759 declarations.
4760 * features/i386/32bit-avx.c: Re-generated.
4761 * features/i386/32bit-avx512.c: Re-generated.
4762 * features/i386/32bit-core.c: Re-generated.
4763 * features/i386/32bit-linux.c: Re-generated.
4764 * features/i386/32bit-mpx.c: Re-generated.
4765 * features/i386/32bit-pkeys.c: Re-generated.
4766 * features/i386/32bit-sse.c: Re-generated.
4767
f7000548
YQ
47682017-09-05 Yao Qi <yao.qi@linaro.org>
4769
4770 * regformats/regdat.sh: Update generated code.
4771
c9a5e2a5
YQ
47722017-09-05 Yao Qi <yao.qi@linaro.org>
4773
4774 * regformats/regdat.sh: Adjust code order.
4775
d6b687ac
SM
47762017-09-05 Simon Marchi <simon.marchi@ericsson.com>
4777
4778 * expprint.c (dump_subexp_body_standard): Use constant format
4779 string in fprintf_filtered call.
4780
a379bfd0
JB
47812017-09-04 John Baldwin <jhb@FreeBSD.org>
4782
4783 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
4784 NetBSD/i386.
4785 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
4786
f7efc967
JB
47872017-09-04 John Baldwin <jhb@FreeBSD.org>
4788
4789 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
4790
c49fbc6c
JB
47912017-09-04 John Baldwin <jhb@FreeBSD.org>
4792
4793 * bsd-kvm.o: Define _KMEMUSER.
4794 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
4795 * configure: Regenerate.
4796
26562e73
JB
47972017-09-04 John Baldwin <jhb@FreeBSD.org>
4798
4799 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
4800 * i386-fbsd-nat.c: Likewise.
4801
31cf1487
JB
48022017-09-04 John Baldwin <jhb@FreeBSD.org>
4803
4804 * unittests/array-view-selftests.c: Add include of <array>.
4805
5b9f8a7c
JB
48062017-09-04 John Baldwin <jhb@FreeBSD.org>
4807
4808 * spu-tdep.c (flush_ea_cache): Add missing argument to
4809 call_function_by_hand.
4810
d69cf9b2
PA
48112017-09-04 Pedro Alves <palves@redhat.com>
4812
4813 * NEWS (Safer support for debugging with no debug info): New.
4814
3693fdb3
PA
48152017-09-04 Pedro Alves <palves@redhat.com>
4816
4817 * c-exp.y (function_method, function_method_void): Add current
4818 instance flags to TYPE_INSTANCE.
4819 * dwarf2read.c (check_modifier): New.
4820 (compute_delayed_physnames): Assert that only C++ adds delayed
4821 physnames. Mark fn_fields as const/volatile depending on
4822 physname.
4823 * eval.c (make_params): New type_instance_flags parameter. Use
4824 it as the new type's instance flags.
4825 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
4826 flags element and pass it to make_params.
4827 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
4828 instance flags element.
4829 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
4830 * gdbtypes.h: Include "enum-flags.h".
4831 (type_instance_flags): New enum-flags type.
4832 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
4833 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
4834 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
4835 (follow_type_instance_flags): New function.
4836 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
4837 * parser-defs.h (follow_type_instance_flags): Declare.
4838 * valops.c (value_struct_elt_for_reference): const/volatile must
4839 match too.
4840
e68cb8e0
PA
48412017-09-04 Pedro Alves <palves@redhat.com>
4842
4843 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
4844 function/method scopes; lookup the nested name as a function local
4845 static variable.
4846
858be34c
PA
48472017-09-04 Pedro Alves <palves@redhat.com>
4848
4849 (%type <voidval>): Add function_method.
4850 * c-exp.y (exp): New production for calls with no arguments.
4851 (function_method, function_method_void_or_typelist): New
4852 productions.
4853 (exp): New production for "method()::static_var".
4854 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
4855 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
4856 Handle OP_FUNC_STATIC_VAR.
4857 * parse.c (operator_length_standard):
4858 Handle OP_FUNC_STATIC_VAR.
4859
dd5901a6
PA
48602017-09-04 Pedro Alves <palves@redhat.com>
4861
4862 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
4863 handling.
4864 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
4865 Ditto.
4866 * parse.c (operator_length_standard, operator_check_standard):
4867 Ditto.
4868 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
4869
46a4882b
PA
48702017-09-04 Pedro Alves <palves@redhat.com>
4871
4872 * ax-gdb.c: Include "typeprint.h".
4873 (gen_expr_for_cast): New function.
4874 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
4875 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
4876 type is unknown.
4877 * dwarf2read.c (new_symbol_full): Fallback to int instead of
4878 nodebug_data_symbol.
4879 * eval.c: Include "typeprint.h".
4880 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
4881 Error out if symbol has unknown type.
4882 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
4883 evaluate_subexp_for_cast.
4884 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
4885 OP_VAR_MSYM_VALUE.
4886 (evaluate_subexp_for_cast): New function.
4887 * gdbtypes.c (init_nodebug_var_type): New function.
4888 (objfile_type): Use it to initialize types of variables with no
4889 debug info.
4890 * typeprint.c (error_unknown_type): New.
4891 * typeprint.h (error_unknown_type): New declaration.
4892 * compile/compile-c-types.c (convert_type_basic): Handle
4893 TYPE_CODE_ERROR; warn and fallback to int for variables with
4894 unknown type.
4895
fe13dfec
PA
48962017-09-04 Pedro Alves <palves@redhat.com>
4897
4898 * eval.c (evaluate_var_value): New function, factored out from ...
4899 (evaluate_subexp_standard): ... here.
4900
d008ee21
PA
49012017-09-04 Pedro Alves <palves@redhat.com>
4902
4903 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
4904 Remove useless assignments to 'op'.
4905
827d0c51
PA
49062017-09-04 Pedro Alves <palves@redhat.com>
4907
4908 * eval.c (eval_skip_value): New function.
4909 (evaluate_subexp_standard): Use it.
4910
2c5a2be1
PA
49112017-09-04 Pedro Alves <palves@redhat.com>
4912
4913 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
4914 function name from symbol/minsym and pass it to
4915 error_call_unknown_return_type.
4916
74ea4be4
PA
49172017-09-04 Pedro Alves <palves@redhat.com>
4918
4919 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
4920 * ax-gdb.c (gen_msym_var_ref): New function.
4921 (gen_expr): Handle OP_VAR_MSYM_VALUE.
4922 * eval.c (evaluate_var_msym_value): New function.
4923 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
4924 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
4925 to call_function_by_hand.
4926 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
4927 Handle OP_VAR_MSYM_VALUE.
4928 (union exp_element) <msymbol>: New field.
4929 * minsyms.h (struct type): Forward declare.
4930 (find_minsym_type_and_address): Declare.
4931 * parse.c (write_exp_elt_msym): New function.
4932 (write_exp_msymbol): Delete, refactored as ...
4933 (find_minsym_type_and_address): ... this new function.
4934 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
4935 (operator_length_standard, operator_check_standard): Handle
4936 OP_VAR_MSYM_VALUE.
4937 * std-operator.def (OP_VAR_MSYM_VALUE): New.
4938
7022349d
PA
49392017-09-04 Pedro Alves <palves@redhat.com>
4940
4941 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
4942 TYPE_GNU_IFUNC specially here. Throw error if return type is
4943 unknown.
4944 * ada-typeprint.c (print_func_type): Handle functions with unknown
4945 return type.
4946 * c-typeprint.c (c_type_print_base): Handle functions and methods
4947 with unknown return type.
4948 * compile/compile-c-symbols.c (convert_symbol_bmsym)
4949 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
4950 * compile/compile-c-types.c: Include "objfiles.h".
4951 (convert_func): For functions with unknown return type, warn and
4952 default to int.
4953 * compile/compile-object-run.c (compile_object_run): Adjust call
4954 to call_function_by_hand_dummy.
4955 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
4956 call_function_by_hand.
4957 * eval.c (evaluate_subexp_standard): Adjust calls to
4958 call_function_by_hand. Handle functions and methods with unknown
4959 return type. Pass expect_type to call_function_by_hand.
4960 * f-typeprint.c (f_type_print_base): Handle functions with unknown
4961 return type.
4962 * gcore.c (call_target_sbrk): Adjust call to
4963 call_function_by_hand.
4964 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
4965 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
4966 an integer address type instead of nodebug.
4967 * guile/scm-value.c (gdbscm_value_call): Adjust call to
4968 call_function_by_hand.
4969 * infcall.c (error_call_unknown_return_type): New function.
4970 (call_function_by_hand): New "default_return_type" parameter.
4971 Pass it down.
4972 (call_function_by_hand_dummy): New "default_return_type"
4973 parameter. Use it instead of defaulting to int. If there's no
4974 default and the return type is unknown, throw an error. If
4975 there's a default return type, and the called function has no
4976 debug info, then assume the function is prototyped.
4977 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
4978 New "default_return_type" parameter.
4979 (error_call_unknown_return_type): New declaration.
4980 * linux-fork.c (call_lseek): Cast return type of lseek.
4981 (inferior_call_waitpid, checkpoint_command): Adjust calls to
4982 call_function_by_hand.
4983 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
4984 calls to call_function_by_hand.
4985 * m2-typeprint.c (m2_procedure): Handle functions with unknown
4986 return type.
4987 * objc-lang.c (lookup_objc_class, lookup_child_selector)
4988 (value_nsstring, print_object_command): Adjust calls to
4989 call_function_by_hand.
4990 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
4991 functions with unknown return type.
4992 (pascal_type_print_func_varspec_suffix): New function.
4993 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
4994 TYPE_CODE_METHOD>: Use it.
4995 * python/py-value.c (valpy_call): Adjust call to
4996 call_function_by_hand.
4997 * rust-lang.c (rust_evaluate_funcall): Adjust call to
4998 call_function_by_hand.
4999 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
5000 call_function_by_hand.
5001 * valops.c (value_allocate_space_in_inferior): Adjust call to
5002 call_function_by_hand.
5003 * typeprint.c (type_print_unknown_return_type): New function.
5004 * typeprint.h (type_print_unknown_return_type): New declaration.
5005
54990598
PA
50062017-09-04 Pedro Alves <palves@redhat.com>
5007
5008 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
5009 types with more than one parameter as prototyped.
5010
9a24775b
PA
50112017-09-04 Pedro Alves <palves@redhat.com>
5012
5013 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
5014 (disassemble_command): Use gdb_disassembly_flags instead of bare
5015 int.
5016 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
5017 (dump_insns, do_mixed_source_and_assembly_deprecated)
5018 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
5019 Use gdb_disassembly_flags instead of bare int.
5020 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
5021 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
5022 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
5023 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
5024 (enum gdb_disassembly_flag): ... values of this new enumeration.
5025 (gdb_disassembly_flags): Define.
5026 (gdb_disassembly)
5027 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
5028 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
5029 gdb_disassembly_flags instead of bare int.
5030 * record-btrace.c (btrace_insn_history)
5031 (record_btrace_insn_history, record_btrace_insn_history_range)
5032 (record_btrace_insn_history_from): Use gdb_disassembly_flags
5033 instead of bare int.
5034 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
5035 Use gdb_disassembly_flags instead of bare int.
5036 * target-debug.h (target_debug_print_gdb_disassembly_flags):
5037 Define.
5038 * target-delegates.c: Regenerate.
5039 * target.c (target_insn_history, target_insn_history_from)
5040 (target_insn_history_range): Use gdb_disassembly_flags instead of
5041 bare int.
5042 * target.h: Include "disasm.h".
5043 (struct target_ops) <to_insn_history, to_insn_history_from,
5044 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
5045 int.
5046 (target_insn_history, target_insn_history_from)
5047 (target_insn_history_range): Use gdb_disassembly_flags instead of
5048 bare int.
5049
80a65e9b
SM
50502017-09-04 Simon Marchi <simon.marchi@ericsson.com>
5051
5052 * cli/cli-script.c (build_command_line): For if/while commands,
5053 check whether args is empty.
5054
6b66338c
SM
50552017-09-04 Simon Marchi <simon.marchi@ericsson.com>
5056
5057 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
5058 (enum command_control_type): Likewise.
5059 (struct command_line): Likewise.
5060 (free_command_lines): Likewise.
5061 (struct command_lines_deleter): Likewise.
5062 (command_line_up): Likewise.
5063 (read_command_lines): Likewise.
5064 (read_command_lines_1): Likewise.
5065 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
5066 (enum command_control_type): Likewise.
5067 (struct command_line): Likewise.
5068 (free_command_lines): Likewise.
5069 (struct command_lines_deleter): Likewise.
5070 (command_line_up): Likewise.
5071 (read_command_lines): Likewise.
5072 (read_command_lines_1): Likewise.
5073 * breakpoint.h: Include cli/cli-script.h.
5074 * extension-priv.h: Likewise.
5075 * gdbcmd.h: Likewise.
5076
51abb421
PA
50772017-09-04 Pedro Alves <palves@redhat.com>
5078
5079 * ada-lang.c (is_known_support_routine): Move sal declaration to
5080 where it is initialized.
5081 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
5082 (parse_breakpoint_sals, decode_static_tracepoint_spec)
5083 (clear_command, update_static_tracepoint): Remove init_sal
5084 references. Move declarations closer to initializations.
5085 * cli/cli-cmds.c (list_command): Move sal declarations closer to
5086 initializations.
5087 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
5088 references. Move sal declarations closer to initializations.
5089 * frame.c (find_frame_sal): Return a symtab_and_line via function
5090 return instead of output parameter. Remove init_sal references.
5091 * frame.h (find_frame_sal): Return a symtab_and_line via function
5092 return instead of output parameter.
5093 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
5094 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
5095 instead of memset.
5096 (gdbscm_find_pc_line): Remove init_sal reference.
5097 * infcall.c (call_function_by_hand_dummy): Remove init_sal
5098 references. Move declarations closer to initializations.
5099 * infcmd.c (set_step_frame): Update. Move declarations closer to
5100 initializations.
5101 (finish_backward): Remove init_sal references. Move declarations
5102 closer to initializations.
5103 * infrun.c (process_event_stop_test, handle_step_into_function)
5104 (insert_hp_step_resume_breakpoint_at_frame)
5105 (insert_step_resume_breakpoint_at_caller): Likewise.
5106 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
5107 (symbol_to_sal): Likewise.
5108 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
5109 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
5110 to its initialization.
5111 * reverse.c (save_bookmark_command): Use new/delete. Remove
5112 init_sal references. Move declarations closer to initializations.
5113 * source.c (get_current_source_symtab_and_line): Remove brace
5114 initialization.
5115 (set_current_source_symtab_and_line): Now takes the sal by const
5116 reference. Remove brace initialization.
5117 (line_info): Remove init_sal reference.
5118 * source.h (set_current_source_symtab_and_line): Now takes a
5119 symtab_and_line via const reference.
5120 * stack.c (set_current_sal_from_frame): Adjust.
5121 (print_frame_info): Adjust.
5122 (get_last_displayed_sal): Return the sal via function return
5123 instead of via output parameter. Simplify.
5124 (frame_info): Adjust.
5125 * stack.h (get_last_displayed_sal): Return the sal via function
5126 return instead of via output parameter.
5127 * symtab.c (init_sal): Delete.
5128 (find_pc_sect_line): Remove init_sal references. Move
5129 declarations closer to initializations.
5130 (find_function_start_sal): Remove init_sal references. Move
5131 declarations closer to initializations.
5132 * symtab.h (struct symtab_and_line): In-class initialize all
5133 fields.
5134 * tracepoint.c (set_traceframe_context)
5135 (print_one_static_tracepoint_marker): Remove init_sal references.
5136 Move declarations closer to initializations.
5137 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
5138 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
5139 declarations closer to initializations.
5140 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
5141 init_sal references. Adjust.
5142
6c5b2ebe
PA
51432017-09-04 Pedro Alves <palves@redhat.com>
5144
5145 * ax-gdb.c (agent_command_1): Use range-for.
5146 * break-catch-throw.c (re_set_exception_catchpoint): Update.
5147 * breakpoint.c: Include "common/array-view.h".
5148 (init_breakpoint_sal, create_breakpoint_sal): Change sals
5149 parameter from struct symtabs_and_lines to
5150 array_view<symtab_and_line>. Adjust. Use range-for. Update.
5151 (breakpoint_sals_to_pc): Change sals parameter from struct
5152 symtabs_and_lines to std::vector reference.
5153 (check_fast_tracepoint_sals): Change sals parameter from struct
5154 symtabs_and_lines to std::array_view. Use range-for.
5155 (decode_static_tracepoint_spec): Return a std::vector instead of
5156 symtabs_and_lines. Update.
5157 (create_breakpoint): Update.
5158 (break_range_command, until_break_command, clear_command): Update.
5159 (base_breakpoint_decode_location, bkpt_decode_location)
5160 (bkpt_probe_create_sals_from_location)
5161 (bkpt_probe_decode_location, tracepoint_decode_location)
5162 (tracepoint_probe_decode_location)
5163 (strace_marker_create_sals_from_location): Return a std::vector
5164 instead of symtabs_and_lines.
5165 (strace_marker_create_breakpoints_sal): Update.
5166 (strace_marker_decode_location): Return a std::vector instead of
5167 symtabs_and_lines. Update.
5168 (update_breakpoint_locations): Change struct symtabs_and_lines
5169 parameters to gdb::array_view. Adjust.
5170 (location_to_sals): Return a std::vector instead of
5171 symtabs_and_lines. Update.
5172 (breakpoint_re_set_default): Use std::vector instead of struct
5173 symtabs_and_lines.
5174 (decode_location_default): Return a std::vector instead of
5175 symtabs_and_lines. Update.
5176 * breakpoint.h: Include "common/array-view.h".
5177 (struct breakpoint_ops) <decode_location>: Now returns a
5178 std::vector instead of returning a symtabs_and_lines via output
5179 parameter.
5180 (update_breakpoint_locations): Change sals parameters to use
5181 gdb::array_view.
5182 * cli/cli-cmds.c (edit_command, list_command): Update to use
5183 std::vector and gdb::array_view.
5184 (ambiguous_line_spec): Adjust to use gdb::array_view and
5185 range-for.
5186 (compare_symtabs): Rename to ...
5187 (cmp_symtabs): ... this. Change parameters to symtab_and_line
5188 const reference and adjust.
5189 (filter_sals): Rewrite using std::vector and standard algorithms.
5190 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
5191 (jump_command): Update to use std::vector.
5192 * linespec.c (struct linespec_state) <canonical_names>: Update
5193 comment.
5194 (add_sal_to_sals_basic): Delete.
5195 (add_sal_to_sals, filter_results, convert_results_to_lsals)
5196 (decode_line_2, create_sals_line_offset)
5197 (convert_address_location_to_sals, convert_linespec_to_sals)
5198 (convert_explicit_location_to_sals, parse_linespec)
5199 (event_location_to_sals, decode_line_full, decode_line_1)
5200 (decode_line_with_current_source)
5201 (decode_line_with_last_displayed, decode_objc)
5202 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
5203 (linespec_result::~linespec_result): Adjust to use std::vector
5204 instead of symtabs_and_lines.
5205 * linespec.h (linespec_sals::sals): Now a std::vector.
5206 (struct linespec_result): Use std::vector, bool, and in-class
5207 initialization.
5208 (decode_line_1, decode_line_with_current_source)
5209 (decode_line_with_last_displayed): Return std::vector.
5210 * macrocmd.c (info_macros_command): Use std::vector.
5211 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
5212 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
5213 std::vector.
5214 * probe.h (parse_probes): Return a std::vector.
5215 * python/python.c (gdbpy_decode_line): Use std::vector and
5216 gdb::array_view.
5217 * source.c (select_source_symtab, line_info): Use std::vector.
5218 * stack.c (func_command): Use std::vector.
5219 * symtab.h (struct symtabs_and_lines): Delete.
5220 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
5221
7c44b49c
PA
52222017-09-04 Pedro Alves <palves@redhat.com>
5223
5224 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5225 unittests/array-view-selftests.c.
5226 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
5227 * common/array-view.h: New file.
5228 * unittests/array-view-selftests.c: New file.
5229
e439fa14
PA
52302017-09-04 Pedro Alves <palves@redhat.com>
5231
5232 * cli/cli-cmds.c (edit_command): Pass message to
5233 ambiguous_line_spec.
5234 (list_command): Pass message to ambiguous_line_spec. Say
5235 "first"/"last" instead of "start" and "end" to be consistent with
5236 the manual.
5237 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
5238 them to print formatted message.
5239
7525b645
PA
52402017-09-04 Pedro Alves <palves@redhat.com>
5241
5242 * btrace.c (ftrace_add_pt): Pass btrace_insn to
5243 ftrace_update_insns by reference instead of pointer.
5244
badc0020
YQ
52452017-09-04 Yao Qi <yao.qi@linaro.org>
5246
5247 * i386-go32-tdep.c: Include x86-xstate.h.
5248 (i386_go32_init_abi): Call i386_target_description.
5249 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
5250 if xcr0 is X86_XSTATE_X87_MASK.
5251 * i386-tdep.h (tdesc_i386): Remove the declaration.
5252 (tdesc_i386_mmx): Likewise.
5253
d78bdb54
YQ
52542017-09-04 Yao Qi <yao.qi@linaro.org>
5255
5256 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
5257 X86_XSTATE_SSE_MASK instead of 0.
5258
ca1fa5ee
YQ
52592017-09-04 Yao Qi <yao.qi@linaro.org>
5260
5261 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
5262 i386_target_description.
5263 * i386-fbsd-nat.c (i386fbsd_read_description): Call
5264 i386_target_description.
5265 * i386-tdep.c (i386_gdbarch_init): Likewise.
5266
2434b019
YQ
52672017-09-04 Yao Qi <yao.qi@linaro.org>
5268
5269 * amd64-darwin-tdep.c: Include "x86-xstate.h".
5270 (x86_darwin_init_abi_64): Call amd64_target_description.
5271 * amd64-dicos-tdep.c: Likewise.
5272 * amd64-fbsd-nat.c: Likewise.
5273 * amd64-fbsd-tdep.c: Likewise.
5274 * amd64-nbsd-tdep.c: Likewise.
5275 * amd64-obsd-tdep.c: Likewise.
5276 * amd64-sol2-tdep.c: Likewise.
5277 * amd64-windows-tdep.c: Likewise.
5278 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
5279
0860c437
SM
52802017-09-04 Simon Marchi <simon.marchi@ericsson.com>
5281
5282 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
5283 (btrace_function) <insn>: Change type to use std::vector.
5284 * btrace.c (ftrace_debug, ftrace_call_num_insn,
5285 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
5286 ftrace_update_insns, ftrace_compute_global_level_offset,
5287 btrace_stitch_bts, btrace_clear, btrace_insn_get,
5288 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
5289 change to std::vector.
5290 (ftrace_update_insns): Adjust to change to std::vector, change
5291 type of INSN parameter.
5292 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
5293 * record-btrace.c (btrace_call_history_insn_range,
5294 btrace_compute_src_line_range,
5295 record_btrace_frame_prev_register): Adjust to change to
5296 std::vector.
5297 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
5298 to change to std::vector.
5299
0638b7f9
TT
53002017-09-03 Tom Tromey <tom@tromey.com>
5301
5302 * corefile.c (reopen_exec_file): Use std::string.
5303
8f84fb0e
TT
53042017-09-03 Tom Tromey <tom@tromey.com>
5305
5306 * compile/compile.c (compile_register_name_mangled): Return
5307 std::string.
5308 * compile/compile-loc2c.c (pushf_register_address): Update.
5309 (pushf_register): Update.
5310 * compile/compile-c-types.c (convert_array): Update.
5311 * compile/compile-c-symbols.c (generate_vla_size): Update.
5312 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
5313 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
5314 (convert_one_symbol): Update.
5315 (generate_c_for_for_one_variable): Update.
5316 * compile/compile-c-support.c (c_get_range_decl_name): Return a
5317 std::string.
5318 (generate_register_struct): Update.
5319 * compile/compile-internal.h (c_get_range_decl_name): Return a
5320 std::string.
5321 (compile_register_name_mangled): Return std::string.
5322
18e9961f
TT
53232017-09-03 Tom Tromey <tom@tromey.com>
5324
5325 * utils.c (perror_string): Return a std::string.
5326 (throw_perror_with_name, perror_warning_with_name): Update.
5327
45343786
TT
53282017-09-03 Tom Tromey <tom@tromey.com>
5329
5330 * demangle.c (demangle_command): Use std::string,
5331 unique_xmalloc_ptr.
5332
b57af503
TT
53332017-09-03 Tom Tromey <tom@tromey.com>
5334
5335 * cli/cli-setshow.c (do_set_command): Use std::string.
5336
6eecf35f
TT
53372017-09-03 Tom Tromey <tom@tromey.com>
5338
5339 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
5340
56496dd4
TT
53412017-09-03 Tom Tromey <tom@tromey.com>
5342
5343 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
5344
e91a1fa7
TT
53452017-09-03 Tom Tromey <tom@tromey.com>
5346
5347 * mi/mi-cmd-env.c (env_execute_cli_command): Use
5348 gdb::unique_xmalloc_ptr.
5349
7ffd83d7
TT
53502017-09-03 Tom Tromey <tom@tromey.com>
5351
5352 * thread.c (print_thread_info_1): Use string_printf.
5353 (thread_apply_command, thread_apply_all_command): Use
5354 std::string.
5355
1ccbe998
TT
53562017-09-03 Tom Tromey <tom@tromey.com>
5357
5358 * valprint.c (val_print_string): Update.
5359 * gdbcore.h (memory_error_message): Return std::string.
5360 * corefile.c (memory_error_message): Return std::string.
5361 (memory_error): Update.
5362 * breakpoint.c (insert_bp_location): Update.
5363
23fdd69e
SM
53642017-09-03 Simon Marchi <simon.marchi@ericsson.com>
5365
5366 * target/waitstatus.h (target_waitstatus_to_string): Change
5367 return type to std::string.
5368 * target/waitstatus.c (target_waitstatus_to_string): Return
5369 std::string.
5370 * target.h (target_waitstatus_to_string): Remove declaration.
5371 * infrun.c (resume, clear_proceed_status_thread,
5372 print_target_wait_results, do_target_wait, save_waitstatus,
5373 stop_all_threads): Adjust.
5374 * record-btrace.c (record_btrace_wait): Adjust.
5375 * target-debug.h
5376 (target_debug_print_struct_target_waitstatus_p): Adjust.
5377
5c811d30
JK
53782017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
5379
5380 PR gdb/22046
5381 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
5382 detection.
5383
0a2dde4a
SDJ
53842017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
5385
5386 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
5387 for setting/unsetting environment variables on the remote target.
5388 (New remote packets): Add entries for QEnvironmentHexEncoded,
5389 QEnvironmentUnset and QEnvironmentReset.
5390 * common/environ.c (gdb_environ::operator=): Extend method to
5391 handle m_user_set_env_list and m_user_unset_env_list.
5392 (gdb_environ::clear): Likewise.
5393 (match_var_in_string): Change type of first parameter from 'char
5394 *' to 'const char *'.
5395 (gdb_environ::set): Extend method to handle
5396 m_user_set_env_list and m_user_unset_env_list.
5397 (gdb_environ::unset): Likewise.
5398 (gdb_environ::clear_user_set_env): New method.
5399 (gdb_environ::user_set_envp): Likewise.
5400 (gdb_environ::user_unset_envp): Likewise.
5401 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
5402 m_user_unset_env_list on move constructor/assignment.
5403 (unset): Add new default parameter 'update_unset_list = true'.
5404 (clear_user_set_env): New method.
5405 (user_set_envp): Likewise.
5406 (user_unset_envp): Likewise.
5407 (m_user_set_env_list): New std::set.
5408 (m_user_unset_env_list): Likewise.
5409 * common/rsp-low.c (hex2str): New function.
5410 (bin2hex): New overload for bin2hex function.
5411 * common/rsp-low.c (hex2str): New prototype.
5412 (str2hex): New overload prototype.
5413 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
5414 QEnvironmentUnset and QEnvironmentReset.
5415 (remote_protocol_features): Add QEnvironmentHexEncoded,
5416 QEnvironmentUnset and QEnvironmentReset packets.
5417 (send_environment_packet): New function.
5418 (extended_remote_environment_support): Likewise.
5419 (extended_remote_create_inferior): Call
5420 extended_remote_environment_support.
5421 (_initialize_remote): Add QEnvironmentHexEncoded,
5422 QEnvironmentUnset and QEnvironmentReset packet configs.
5423 * unittests/environ-selftests.c (gdb_selftest_env_var):
5424 New variable.
5425 (test_vector_initialization): New function.
5426 (test_init_from_host_environ): Likewise.
5427 (test_reinit_from_host_environ): Likewise.
5428 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
5429 Likewise.
5430 (test_unset_set_empty_vector): Likewise.
5431 (test_vector_clear): Likewise.
5432 (test_std_move): Likewise.
5433 (test_move_constructor):
5434 (test_self_move): Likewise.
5435 (test_set_unset_reset): Likewise.
5436 (run_tests): Rewrite in terms of the functions above.
5437
654670a4
WP
54382017-08-31 Weimin Pan <weimin.pan@oracle.com>
5439
5440 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
5441 (adi_available): Use a temp variable of type CORE_ADDR as argument
5442 3 when calling target_auxv_search.
5443 (adi_normalize_address): Use masks and xor operators to calculate
5444 normalized address.
5445 (adi_read_versions, adi_write_versions, adi_print_versions)
5446 (do_examine, do_assign): Use paddress.
5447
7755ddb7
JB
54482017-08-29 John Baldwin <jhb@FreeBSD.org>
5449
5450 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
5451 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
5452 out of loop and add supply of FIR.
5453 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
5454 add collect of FIR.
5455
fd437cbc
SM
54562017-08-28 Simon Marchi <simon.marchi@ericsson.com>
5457
3804a343 5458 PR gdb/21827
fd437cbc
SM
5459 * cli/cli-script.c (define_command): Don't convert command name
5460 to lower case.
5461
988f6b3d
JB
54622017-08-25 Joel Brobecker <brobecker@adacore.com>
5463
5464 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
5465 Update all callers accordingly. Remove all code blocks handling
5466 the case where DISPP is not NULL.
5467
663c44ac
JK
54682017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
5469
5470 PR symtab/22003
5471 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
5472 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
5473 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
5474
f1902523
JK
54752017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
5476
5477 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
5478 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
5479 (read_comp_units_from_section): New parameter abbrev_section, use
5480 read_and_check_comp_unit_head, allocate signatured_type if needed.
5481 (create_all_comp_units): Update read_comp_units_from_section caller.
5482
87215ad1
SDJ
54832017-08-23 Pedro Alves <palves@redhat.com>
5484
5485 PR remote/21852
5486 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
5487 to null_ptid and switch to thread without reading the registers
5488 after adding the inferior.
5489
6e41ddec
JK
54902017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
5491
5492 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
5493 compile-gcc.
5494 * compile/compile.c (compile_gcc, show_compile_gcc): New.
5495 (compile_to_object): Implement compile_gcc.
5496 (_initialize_compile): Install "set compile-gcc". Initialize
5497 compile_gcc.
5498
e68c32d5
JK
54992017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
5500
5501 * compile/compile.c (compile_to_object): Conditionally call
5502 set_verbose. Conditionally call compile or compile_v0.
5503
58afddc6
WP
55042017-08-07 Weimin Pan <weimin.pan@oracle.com>
5505
5506 * sparc64-tdep.h: (adi_normalize_address): New export.
5507 * sparc-nat.h: (open_adi_tag_fd): New export.
5508 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
5509 * sparc64-linux-tdep.c:
5510 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
5511 (sparc64_linux_handle_segmentation_fault): New function.
5512 (sparc64_linux_init_abi): Register
5513 sparc64_linux_handle_segmentation_fault
5514 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
5515 (sparc64_addr_bits_remove): New function.
5516 (sparc64_init_abi): Register sparc64_addr_bits_remove.
5517 (MAX_PROC_NAME_SIZE): New macro.
5518 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
5519 (sparc64adilist): New variable.
5520 (adi_proc_list): New variable.
5521 (find_adi_info): New function.
5522 (add_adi_info): New function.
5523 (get_adi_info_proc): New function.
5524 (get_adi_info): New function.
5525 (info_adi_command): New function.
5526 (read_maps_entry): New function.
5527 (adi_available): New function.
5528 (adi_normalize_address): New function.
5529 (adi_align_address): New function.
5530 (adi_convert_byte_count): New function.
5531 (adi_tag_fd): New function.
5532 (adi_is_addr_mapped): New function.
5533 (adi_read_versions): New function.
5534 (adi_write_versions): New function.
5535 (adi_print_versions): New function.
5536 (do_examine): New function.
5537 (do_assign): New function.
5538 (adi_examine_command): New function.
5539 (adi_assign_command): New function.
5540 (_initialize_sparc64_adi_tdep): New function.
5541
11db9430
SM
55422017-08-22 Simon Marchi <simon.marchi@ericsson.com>
5543
5544 * breakpoint.c (breakpoints_info): Rename to ...
5545 (info_breakpoints_command): ... this.
5546 (watchpoints_info): Rename to ...
5547 (info_watchpoints_command): ... this.
5548 (tracepoints_info): Rename to ...
5549 (info_tracepoints_command): ... this.
5550 (_initialize_breakpoint): Adjust.
5551 * dcache.c (dcache_info): Rename to ...
5552 (info_display_command): ... this.
5553 (_initialize_dcache): Adjust.
5554 * frame.h (args_info): Rename to ...
5555 (info_args_command): ... this.
5556 (locals_info): Rename to ...
5557 (info_locals_command): ... this.
5558 * infcmd.c (nofp_registers_info): Rename to ...
5559 (info_registers_command): ... this.
5560 (float_info): Rename to ...
5561 (info_float_command): ... this.
5562 (program_info): Rename to ...
5563 (info_program_command): ... this.
5564 (all_registers_info): Rename to ...
5565 (info_all_registers_command): ... this.
5566 (vector_info): Rename to ...
5567 (info_vector_command): ... this.
5568 (float_info): Rename to ...
5569 (info_float_command): ... this.
5570 (_initialize_infcmd): Adjust.
5571 * inferior.h (term_info): Rename to ...
5572 (info_terminal_command): ... this.
5573 * inflow.c (term_info): Rename to ...
5574 (info_terminal_command): ... this.
5575 (_initialize_inflow): Adjust.
5576 * infrun.c (signals_info): Rename to ...
5577 (info_signals_command): ... this.
5578 (_initialize_infrun): Adjust.
5579 * objc-lang.c (classes_info): Rename to ...
5580 (info_classes_command): ... this.
5581 (selectors_info): Rename to ...
5582 (info_selectors_command): ... this.
5583 (_initialize_objc_language): Adjust.
5584 * printcmd.c (sym_info): Rename to ...
5585 (info_symbol_command): ... this.
5586 (address_info): Rename to ...
5587 (info_address_command): ... this.
5588 (display_info): Rename to ...
5589 (info_display_command): ... this.
5590 (_initialize_printcmd): Adjust.
5591 * reverse.c (bookmarks_info): Rename to ...
5592 (info_breakpoints_command): ... this.
5593 (_initialize_reverse): Adjust.
5594 * ser-go32.c (dos_info): Rename to ...
5595 (info_serial_command): ... this.
5596 (_initialize_ser_dos): Adjust.
5597 * skip.c (skip_info): Rename to ...
5598 (info_skip_command): ... this.
5599 (_initialize_step_skip): Adjust.
5600 * source.c (line_info): Rename to ...
5601 (info_line_command): ... this.
5602 (source_info): Rename to ...
5603 (info_source_command)
5604 * stack.c (frame_info): Rename to ...
5605 (info_frame_command): ... this.
5606 (locals_info): Rename to ...
5607 (info_locals_command): ... this.
5608 (args_info): Rename to ...
5609 (info_args_command): ... this.
5610 (_initialize_stack): Adjust.
5611 * symtab.c (sources_info): Rename to ...
5612 (info_sources_command): ... this.
5613 (variables_info): Rename to ...
5614 (info_variables_command): ... this.
5615 (functions_info): Rename to ...
5616 (info_functions_command): ... this.
5617 (types_info): Rename to ...
5618 (info_types_command): ... this.
5619 (_initialize_symtab): Adjust.
5620 * target.c (target_info): Rename to ...
5621 (info_target_command): ... this.
5622 (initialize_targets): Adjust.
5623 * tracepoint.c (tvariables_info): Rename to ...
5624 (info_tvariables_command): ... this.
5625 (scope_info): Rename to ...
5626 (info_scope_command): ... this.
5627 (trace_dump_actions): Adjust.
5628 (_initialize_tracepoint): Adjust.
5629
b270e6f9
TT
56302017-08-22 Tom Tromey <tom@tromey.com>
5631
5632 * breakpoint.h (install_breakpoint): Update.
5633 * breakpoint.c (add_solib_catchpoint): Update.
5634 (install_breakpoint): Change argument to a std::unique_ptr.
5635 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
5636 (create_breakpoint_sal, create_breakpoint): Update.
5637 (watch_command_1, catch_exec_command_1)
5638 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
5639 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
5640 Return the breakpoint.
5641 (set_raw_breakpoint_without_location, set_raw_breakpoint)
5642 (new_single_step_breakpoint): Update.
5643 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
5644 std::unique_ptr.
5645 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
5646 std::unique_ptr.
5647 * break-catch-sig.c (create_signal_catchpoint): Use
5648 std::unique_ptr.
5649 * ada-lang.c (create_ada_exception_catchpoint): Use
5650 std::unique_ptr.
5651
36bd8eaa
TT
56522017-08-22 Tom Tromey <tom@tromey.com>
5653
5654 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
5655
56f37645
TT
56562017-08-22 Tom Tromey <tom@tromey.com>
5657
5658 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
5659 (lookup_partial_symbol): Update.
5660
0b581c69
TT
56612017-08-22 Tom Tromey <tom@tromey.com>
5662
5663 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
5664 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
5665 (find_and_open_source, symtab_to_fullname): Update.
5666 * psymtab.c (psymtab_to_fullname): Update.
5667
14278e1f
TT
56682017-08-22 Tom Tromey <tom@tromey.com>
5669
5670 * exec.c (exec_file_attach): Update.
5671 * linux-thread-db.c (try_thread_db_load): Update.
5672 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
5673 * utils.c (gdb_realpath): Change return type.
5674 (gdb_realpath_keepfile): Update.
5675 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
5676 (_initialize_utils): Register the new self test.
5677 * source.c (openp): Update.
5678 (find_and_open_source): Update.
5679 * nto-tdep.c (nto_find_and_open_solib): Update.
5680 * main.c (set_gdb_data_directory): Update.
5681 (captured_main_1): Update.
5682 * dwarf2read.c (dwarf2_get_dwz_file): Update
5683 (dw2_map_symbol_filenames): Update.
5684 * auto-load.c (auto_load_safe_path_vec_update): Update.
5685 (filename_is_in_auto_load_safe_path_vec): Change type of
5686 "filename_realp".
5687 (auto_load_objfile_script): Update.
5688 (file_is_auto_load_safe): Update. Use std::string.
5689 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
5690
4971c9a7
TT
56912017-08-22 Tom Tromey <tom@tromey.com>
5692
5693 * utils.c (gdb_realpath_keepfile): Return a
5694 gdb::unique_xmalloc_ptr.
5695 * exec.c (exec_file_attach): Update.
5696 * utils.h (gdb_realpath_keepfile): Return a
5697 gdb::unique_xmalloc_ptr.
5698
e3e41d58
TT
56992017-08-22 Tom Tromey <tom@tromey.com>
5700
5701 * compile/compile.c (compile_file_command): Use
5702 gdb::unique_xmalloc_ptr, std::string.
5703 * utils.c (gdb_abspath): Change return type.
5704 * source.c (openp): Update.
5705 * objfiles.c (allocate_objfile): Update.
5706 * main.c (set_gdb_data_directory): Update.
5707 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
5708
0d999a6e
ZZ
57092017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
5710
5711 * cli-cmds.c (list_commands): List actual code around more than
5712 one location.
5713
329d5e7e
JB
57142017-08-21 John Baldwin <jhb@FreeBSD.org>
5715
5716 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
5717
bf223d3e
PA
57182017-08-21 Pedro Alves <palves@redhat.com>
5719
5720 PR gdb/19487
5721 * c-exp.y (variable production): Handle function aliases.
5722 * minsyms.c (msymbol_is_text): New function.
5723 * minsyms.h (msymbol_is_text): Declare.
5724 * symtab.c (find_function_alias_target): New function.
5725 * symtab.h (find_function_alias_target): Declare.
5726
c973d0aa
PA
57272017-08-21 Pedro Alves <palves@redhat.com>
5728
5729 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
5730 typedefs.
5731 * typeprint.c (whatis_exp): If handling "whatis", and expression
5732 is OP_TYPE, strip one typedef level. Otherwise don't strip
5733 typedefs here.
5734 * valops.c (value_cast): Save "to" type before resolving
5735 stubs/typedefs. Use that type as resulting value's type.
5736
2989a365
TT
57372017-08-18 Tom Tromey <tom@tromey.com>
5738 Pedro Alves <palves@redhat.com>
5739
5740 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
5741 * sol-thread.c (sol_thread_resume, sol_thread_wait)
5742 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
5743 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
5744 * proc-service.c (ps_xfer_memory): Use scoped_restore.
5745 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
5746 (linux_get_siginfo_data): Add "thread" argument. Use
5747 scoped_restore.
5748 * linux-nat.c (linux_child_follow_fork)
5749 (check_stopped_by_watchpoint): Use scoped_restore.
5750 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
5751 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
5752 (restore_inferior_ptid, save_inferior_ptid): Remove.
5753 * btrace.c (btrace_fetch): Use scoped_restore.
5754 * bsd-uthread.c (bsd_uthread_fetch_registers)
5755 (bsd_uthread_store_registers): Use scoped_restore.
5756 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
5757 scoped_restore.
5758 * aix-thread.c (aix_thread_resume, aix_thread_wait)
5759 (aix_thread_xfer_partial): Use scoped_restore.
5760 * inferior.h (save_inferior_ptid): Remove.
5761
e60eb288
YQ
57622017-08-18 Yao Qi <yao.qi@linaro.org>
5763
5764 PR tdep/21818
5765 * arm-tdep.c (gdb_print_insn_arm): Mark
5766 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
5767
6d580b63
YQ
57682017-08-18 Yao Qi <yao.qi@linaro.org>
5769
5770 * NEWS: Mention GDBserver's new option "--selftest".
5771 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
5772 * selftest.c: Move it to common/selftest.c.
5773 * selftest.h: Move it to common/selftest.h.
5774 * selftest-arch.c (reset): New function.
5775 (tests_with_arch): Call reset.
5776
86dcbf50
YQ
57772017-08-18 Yao Qi <yao.qi@linaro.org>
5778
5779 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
5780 instead of exception_fprintf and printf_filtered.
5781
7649770c
YQ
57822017-08-18 Yao Qi <yao.qi@linaro.org>
5783
5784 * selftest.c (register_self_test): Rename it to
5785 selftests::register_test.
5786 (run_self_tests): selftest::run_tests.
5787 * selftest.h: Update declarations.
5788 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
5789 selftests::register_test_foreach_arch.
5790 * selftest-arch.h: Update declaration.
5791 * aarch64-tdep.c: Update.
5792 * arm-tdep.c: Likewise.
5793 * disasm-selftests.c: Likewise.
5794 * dwarf2loc.c: Likewise.
5795 * dwarf2-frame.c: Likewise.
5796 * findvar.c: Likewise.
5797 * gdbarch-selftests.c: Likewise.
5798 * maint.c (maintenance_selftest): Likewise.
5799 * regcache.c: Likewise.
5800 * rust-exp.y: Likewise.
5801 * selftest-arch.c: Likewise.
5802 * unittests/environ-selftests.c: Likewise.
5803 * unittests/function-view-selftests.c: Likewise.
5804 * unittests/offset-type-selftests.c: Likewise.
5805 * unittests/optional-selftests.c: Likewise.
5806 * unittests/scoped_restore-selftests.c: Likewise.
5807 * utils-selftests.c: Likewise.
5808
b0cba12e
PA
58092017-08-17 Pedro Alves <palves@redhat.com>
5810
5811 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
5812 local.
5813
4c8aa72d
PA
58142017-08-17 Pedro Alves <palves@redhat.com>
5815
5816 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
5817 field.
5818 (reset_die_in_process): Delete, replaced by ...
5819 (process_die_scope): ... this new class. Make it responsible for
5820 freeing cu->line_header too.
5821 (process_die): Use process_die_scope.
5822 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
5823 cu->line_header_die_owner. Don't release the line header if it's
5824 owned by the CU.
5825 (setup_type_unit_groups): Make the CU/DIE own the line header.
5826 Don't release the line header here.
5827
ba713918
AL
58282017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
5829
5830 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
5831
44d0fb3a
RK
58322017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
5833
5834 * NEWS: Mention new shortcuts for nexti and stepi in TUI
5835 Single-Key mode
5836
a5afdb16
RK
58372017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
5838
5839 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
5840 mode command list.
5841
47613aeb
SH
58422017-08-15 Stafford Horne <shorne@gmail.com>
5843
5844 * MAINTAINERS (Write After Approval): Add Stafford Horne.
5845
9c3cc999
SH
58462017-08-15 Stafford Horne <shorne@gmail.com>
5847
5848 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
5849
206726fb
SDJ
58502017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
5851
5852 PR gdb/21954
5853 * infcmd.c (unset_environment_command): Use the 'clear' method on
5854 the environment instead of resetting it.
5855
0335ac6d
JB
58562017-08-15 John Baldwin <jhb@FreeBSD.org>
5857
5858 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
5859 platforms.
5860
d3abe1c8
TT
58612017-08-14 Tom Tromey <tom@tromey.com>
5862
5863 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
5864 (print_binary_chars): Likewise.
5865 (BITS_IN_BYTES): Remove.
5866
d6382fff
TT
58672017-08-14 Tom Tromey <tom@tromey.com>
5868
5869 PR gdb/21675
5870 * valprint.c (LOW_ZERO): Change value to 034.
5871 (print_octal_chars): Add static_asserts for octal constants.
5872 * printcmd.c (print_scalar_formatted): Add 'd' case.
5873
f978cb06
TT
58742017-08-11 Tom Tromey <tom@tromey.com>
5875
5876 * symfile.c (add_symbol_file_command): Use std::vector.
5877
2f5404b3
TT
58782017-08-14 Tom Tromey <tom@tromey.com>
5879
5880 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
5881 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
5882 std::move.
5883 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
5884
de7985c3
PA
58852017-08-11 Pedro Alves <palves@redhat.com>
5886
5887 * infrun.c (process_event_stop_test): Adjust
5888 function_name_is_marked_for_skip call.
5889 * skip.c: Include <list>.
5890 (skiplist_entry): Make it a class with private fields, and
5891 getters/setters.
5892 (skiplist_entry_chain): Delete.
5893 (skiplist_entries): New.
5894 (skiplist_entry_count): Delete.
5895 (highest_skiplist_entry_num): New.
5896 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
5897 (add_skiplist_entry): Delete.
5898 (skiplist_entry::skiplist_entry): New.
5899 (skiplist_entry::add_entry): New.
5900 (skip_file_command, skip_function): Adjust.
5901 (compile_skip_regexp): Delete.
5902 (skip_command): Don't compile regexp here. Adjust to use
5903 skiplist_entry::add_entry.
5904 (skip_info): Adjust to use range-for and getters.
5905 (skip_enable_command, skip_disable_command): Adjust to use
5906 range-for and setters.
5907 (skip_delete_command): Adjust to use std::list.
5908 (add_skiplist_entry): Delete.
5909 (skip_file_p): Delete, refactored as ...
5910 (skiplist_entry::do_skip_file_p): ... this new method.
5911 (skip_gfile_p): Delete, refactored as ...
5912 (skiplist_entry::do_gskip_file_p): ... this new method.
5913 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
5914 (skiplist_entry::skip_function_p): ... this new method.
5915 (function_name_is_marked_for_skip): Now returns bool, and takes
5916 the function sal by const reference. Adjust to use range-for and
5917 skiplist_entry methods.
5918 (_initialize_step_skip): Remove references to
5919 skiplist_entry_chain, skiplist_entry_count.
5920 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
5921 takes the function sal by const reference.
5922
be7d3cd5
YQ
59232017-08-11 Yao Qi <yao.qi@linaro.org>
5924
5925 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
5926 (dwarf2_frame_cache): Remove reset_cache_cleanup.
5927 (dwarf2_frame_cache):
5928 * frame-unwind.c (frame_unwind_try_unwinder): Catch
5929 RETURN_MASK_ALL and set *this_case to NULL.
5930 * frame-unwind.h: Update comments.
5931
1c90d9f0
YQ
59322017-08-11 Yao Qi <yao.qi@linaro.org>
5933
5934 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
5935 (dwarf2_frame_state_copy_regs): Remove.
5936 (dwarf2_frame_state_free_regs): Remove.
5937 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
5938 (dwarf2_restore_rule): Call method .alloc_regs instead of
5939 dwarf2_frame_state_alloc_regs.
5940 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
5941 constructor. Call std::move.
5942 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
5943 (dwarf2_frame_cache): Likewise.
5944
5945 [GDB_SELF_TEST]: Include selftest.h and
5946 selftest-arch.h.
5947 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
5948 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
5949 execute_cfa_program_test.
5950
5951 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
5952 copy ctor, assignment operator, move assignment.
5953 <alloc_regs>: New method.
5954 <swap>: New method.
5955 (struct dwarf2_frame_state): Delete dtor.
5956 (dwarf2_frame_state_alloc_regs): Remove declaration.
5957 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
5958 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
5959
afe37d6b
YQ
59602017-08-11 Yao Qi <yao.qi@linaro.org>
5961
5962 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
5963 (dwarf2_frame_state::dwarf2_frame_state): New.
5964 (dwarf2_frame_state::~dwarf2_frame_state): New.
5965 (dwarf2_fetch_cfa_info): Update.
5966 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
5967 rather than a pointer. Update code.
5968 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
5969 dtor.
5970 <data_align, code_align, retaddr_column>: Change them to const.
5971 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
5972 to bool.
5973
b348037f
YQ
59742017-08-11 Yao Qi <yao.qi@linaro.org>
5975
5976 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
5977 <loc.exp>: New field.
5978 * dwarf2-frame.c (execute_cfa_program): Update.
5979 (dwarf2_frame_prev_register): Update.
5980
e7c9de26
PA
59812017-08-10 Pedro Alves <palves@redhat.com>
5982
5983 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
5984
e8c6b620
JB
59852017-08-09 John Baldwin <jhb@FreeBSD.org>
5986
5987 * fbsd-nat.c (struct fbsd_fork_info): Remove.
5988 (fbsd_pending_children): Use std::list.
5989 (fbsd_remember_child): Likewise.
5990 (fbsd_is_child_pending): Likewise.
5991 (fbsd_pending_vfork_done): Use std::forward_list.
5992 (fbsd_add_vfork_done): Likewise.
5993 (fbsd_is_vfork_done_pending): Likewise.
5994 (fbsd_next_vfork_done): Likewise.
5995
e4a26669
JB
59962017-08-09 John Baldwin <jhb@FreeBSD.org>
5997
5998 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
5999 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
6000 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
6001 for `mapfilename'.
6002 (fbsd_xfer_partial): Use gdb::byte_vector.
af3881e6 6003 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
e4a26669 6004
142311d3
JB
60052017-08-09 John Baldwin <jhb@FreeBSD.org>
6006
6007 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
6008 "filestuff.h".
6009 (fbsd_find_memory_regions): Fix `mapfile' initialization.
6010
42fa2e0e
TT
60112017-08-09 Tom Tromey <tom@tromey.com>
6012
6013 * skip.c (skiplist_entry): New constructor.
6014 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
6015 (skiplist_entry::file_is_glob): Now bool.
6016 (skiplist_entry::file, skiplist_entry::function): Now
6017 std::string.
6018 (make_skip_entry): Return a unique_ptr. Use new.
6019 (free_skiplist_entry, free_skiplist_entry_cleanup)
6020 (make_free_skiplist_entry_cleanup): Remove.
6021 (skip_command, skip_disable_command, add_skiplist_entry)
6022 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
6023 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
6024 (function_name_is_marked_for_skip): Update.
6025 (skip_delete_command): Update. Use delete.
6026
cd3af38d
JW
60272017-08-09 Jiong Wang <jiong.wang@arm.com>
6028
6029 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
6030 (aarch64_linux_core_read_description): New function.
6031 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
6032
29592bde
PA
60332017-08-09 Pedro Alves <palves@redhat.com>
6034
6035 * cp-name-parser.y (cp_comp_to_string): Return a
6036 gdb::unique_xmalloc_ptr<char>.
6037 * cp-support.c (replace_typedefs_qualified_name)
6038 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
6039 (cp_canonicalize_string_full): Use op= instead of explicit
6040 convertion.
6041 (cp_class_name_from_physname, method_name_from_physname)
6042 (cp_func_name, cp_remove_params): Adjust to use
6043 gdb::unique_xmalloc_ptr<char>.
6044 * cp-support.h (cp_comp_to_string): Return a
6045 gdb::unique_xmalloc_ptr<char>.
6046 * python/py-type.c (typy_lookup_type): Adjust to use
6047 gdb::unique_xmalloc_ptr<char>.
6048
b3340438
L
60492017-08-09 H.J. Lu <hongjiu.lu@intel.com>
6050
6051 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
6052
e88e8651
YQ
60532017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
6054 Yao Qi <yao.qi@linaro.org>
6055
6056 * cp-support.c (cp_canonicalize_string_full): Use
6057 gdb::unique_xmalloc_ptr<char>.
6058 (cp_canonicalize_string): Likewise.
6059
f5a29eb0
YQ
60602017-08-09 Yao Qi <yao.qi@linaro.org>
6061
6062 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
6063 * regformats/i386/amd64-avx-avx512.dat: Remove.
6064 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
6065 * regformats/i386/amd64-avx-mpx.dat:Remove.
6066 * regformats/i386/amd64-avx.dat: Remove.
6067 * regformats/i386/amd64-mpx.dat: Remove.
6068 * regformats/i386/i386-avx-avx512.dat: Remove.
6069 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
6070 * regformats/i386/i386-avx-mpx.dat: Remove.
6071 * regformats/i386/i386-mmx.dat: Remove.
6072 * regformats/i386/i386-mpx.dat: Remove.
6073
57757c2f
YQ
60742017-08-09 Yao Qi <yao.qi@linaro.org>
6075
6076 * amd64-tdep.h (tdesc_x32): Remove the declaration.
6077 * amd64-tdep.c: Don't include features/i386/x32*.c.
6078 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
6079 functions.
6080 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
6081 and i386/x32-avx-avx512.
6082 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
6083 and i386/x32.xml.
6084 * features/i386/x32-avx-avx512.c: Removed.
6085 * features/i386/x32-avx-avx512.xml: Removed.
6086 * features/i386/x32-avx.c: Removed.
6087 * features/i386/x32-avx.xml: Removed.
6088 * features/i386/x32.c: Removed.
6089 * features/i386/x32.xml: Removed.
6090 * regformats/i386/x32-avx-avx512.dat: Removed.
6091 * regformats/i386/x32-avx.dat: Removed.
6092 * regformats/i386/x32.dat: Removed.
6093
ba7b109b
MR
60942017-08-07 Maciej W. Rozycki <macro@imgtec.com>
6095
6096 PR breakpoints/21886
6097 * mem-break.c (default_memory_insert_breakpoint): Use
6098 `->placed_address' rather than `->reqstd_address' for the
6099 breakpoint location.
6100
e347efc3
MR
61012017-08-07 Maciej W. Rozycki <macro@imgtec.com>
6102
6103 * arch-utils.c (default_print_insn): Remove arch/mach/endian
6104 assertions.
6105
0dba2a6c
MR
61062017-08-07 Maciej W. Rozycki <macro@imgtec.com>
6107
6108 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
6109 a union of `tdep_info', `tdesc_data' and `id'.
6110 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
6111 rather than `info.tdep_info'.
6112 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
6113 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
6114 * i386-tdep.c (i386_gdbarch_init): Likewise.
6115 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
6116 * mips-tdep.c (mips_gdbarch_init): Likewise.
6117 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
6118 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
6119 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
6120 `info.tdep_info'.
6121 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
6122 `info.tdep_info'.
6123 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
6124 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
6125 `info.tdep_info'.
6126 * spu-tdep.c (spu_gdbarch_init): Likewise.
6127 * gdbarch.h: Regenerate.
6128
16eb6b2d
LS
61292017-08-07 Leszek Swirski <leszeks@google.com>
6130
7b005726 6131 PR symtab/20899
16eb6b2d
LS
6132 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
6133
74cbb09e
SM
61342017-08-07 Simon Marchi <simon.marchi@ericsson.com>
6135
6136 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
6137 (gdbsim_open): Rename gdb_argv args object to argv.
6138
ee0c3293
TT
61392017-08-05 Tom Tromey <tom@tromey.com>
6140
6141 * compile/compile-object-load.c (compile_object_load): Use
6142 gdb::unique_xmalloc_ptr.
6143 * cli/cli-dump.c (scan_filename): Rename from
6144 scan_filename_with_cleanup. Change return type.
6145 (scan_expression): Rename from scan_expression_with_cleanup.
6146 Change return type.
6147 (dump_memory_to_file, dump_value_to_file, restore_command):
6148 Use gdb::unique_xmalloc_ptr. Update.
6149 * cli/cli-cmds.c (find_and_open_script): Use
6150 gdb::unique_xmalloc_ptr.
6151 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
6152 * symmisc.c (maintenance_print_symbols)
6153 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
6154 * symfile.c (symfile_bfd_open, generic_load)
6155 (add_symbol_file_command, remove_symbol_file_command): Use
6156 gdb::unique_xmalloc_ptr.
6157 * source.c (openp): Use gdb::unique_xmalloc_ptr.
6158 * psymtab.c (maintenance_print_psymbols): Use
6159 gdb::unique_xmalloc_ptr.
6160 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
6161 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
6162 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
6163 (reload_shared_libraries_1): Likewise.
6164
3232fabd
TT
61652017-08-05 Tom Tromey <tom@tromey.com>
6166
6167 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
6168 (rust_op_vector, rust_set_vector): New typedefs.
6169 (current_parser): New global.
6170 (work_obstack): Change to pointer type. Update all users.
6171 (rust_ast, pstate): Remove globals.
6172 (struct rust_parser): New.
6173 (%union) <params, field_inits>: Change type.
6174 (start, tuple_expr, unit_expr, struct_expr_list, literal)
6175 (field_expr, expr_list, maybe_expr_list, type_list): Update.
6176 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
6177 (convert_params_to_types, convert_params_to_expression): Change
6178 type of "params".
6179 (ast_string): Change type of "fields".
6180 (rust_parse): Make a rust_parser. Remove cleanups.
6181 (rust_lex_tests): Make and install an auto_obstack.
6182
f02fd774
YQ
61832017-08-04 Yao Qi <yao.qi@linaro.org>
6184
6185 * configure.srv (ipa_x32_linux_regobj): New.
6186 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
6187 instead of X86_TDESC_AVX512.
6188 (initialize_low_tracepoint): Call
6189 init_registers_x32_avx_avx512_linux.
6190
91975afd
YQ
61912017-08-04 Yao Qi <yao.qi@linaro.org>
6192
6193 * utils.h (gdb_argv): Add namespace std for nullptr_t.
6194
2331fa3a
RK
61952017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
6196
6197 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
6198
744e4fe1
TT
61992017-08-03 Tom Tromey <tom@tromey.com>
6200
6201 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
6202 Remove.
6203 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
6204
1c034b67
TT
62052017-08-03 Tom Tromey <tom@tromey.com>
6206
6207 * python/py-param.c (compute_enum_values): Use gdb_argv.
6208
773a1edc
TT
62092017-08-03 Tom Tromey <tom@tromey.com>
6210
6211 * utils.h (struct gdb_argv_deleter): New.
6212 (gdb_argv): New class.
6213 * utils.c (gdb_argv::reset): New method.
6214 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
6215 * tracefile.c (tsave_command): Use gdb_argv.
6216 * top.c (new_ui_command): Use gdb_argv.
6217 * symmisc.c (maintenance_print_symbols)
6218 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
6219 * symfile.c (symbol_file_command, generic_load)
6220 (remove_symbol_file_command): Use gdb_argv.
6221 * stack.c (backtrace_command): Use gdb_argv.
6222 * source.c (add_path, show_substitute_path_command)
6223 (unset_substitute_path_command, set_substitute_path_command):
6224 Use gdb_argv.
6225 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
6226 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
6227 * remote.c (extended_remote_run, remote_put_command)
6228 (remote_get_command, remote_delete_command): Use gdb_argv.
6229 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
6230 (gdbsim_open): Use gdb_argv.
6231 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
6232 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
6233 * procfs.c (procfs_info_proc): Use gdb_argv.
6234 * interps.c (interpreter_exec_cmd): Use gdb_argv.
6235 * infrun.c (handle_command): Use gdb_argv.
6236 * inferior.c (add_inferior_command, clone_inferior_command):
6237 Use gdb_argv.
6238 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
6239 * exec.c (exec_file_command): Use gdb_argv.
6240 * cli/cli-cmds.c (alias_command): Use gdb_argv.
6241 * compile/compile.c (build_argc_argv): Use gdb_argv.
6242
0d50bde3
TT
62432017-08-03 Tom Tromey <tom@tromey.com>
6244
6245 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
6246
7f968c89
TT
62472017-08-03 Tom Tromey <tom@tromey.com>
6248
6249 * python/python.c (compute_python_string): Return std::string.
6250 (gdbpy_eval_from_control_command): Update.
6251 (do_start_initialization): Use std::string.
6252 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
6253 xstrprintf.
6254 * python/py-breakpoint.c (local_setattro): Use string_printf, not
6255 xstrprintf.
6256
3c9ebddd
TT
62572017-08-03 Tom Tromey <tom@tromey.com>
6258
6259 * top.h (do_restore_instream_cleanup): Remove.
6260 * top.c (do_restore_instream_cleanup): Remove.
6261 (read_command_file): Use scoped_restore.
6262 * cli/cli-script.c (execute_user_command): Use scoped_restore.
6263
b51b225e
TT
62642017-08-03 Tom Tromey <tom@tromey.com>
6265
6266 * cli/cli-script.c (execute_user_command)
6267 (execute_control_command): Use scoped_restore.
6268
ac991630
TT
62692017-08-03 Tom Tromey <tom@tromey.com>
6270
6271 * cli/cli-script.c (do_restore_user_call_depth): Remove.
6272 (execute_user_command): Remove user_call_depth; use
6273 user_args_stack's size instead.
6274
898e0c8e
TT
62752017-08-03 Tom Tromey <tom@tromey.com>
6276
6277 * top.h (in_user_command): Remove.
6278 * top.c (in_user_command): Remove.
6279 * cli/cli-script.c (do_restore_user_call_depth)
6280 (execute_user_command): Update.
6281
26fcd5d7
TT
62822017-08-03 Tom Tromey <tom@tromey.com>
6283
6284 * valops.c (search_struct_method): Use gdb::byte_vector.
6285 * valarith.c (value_concat): Use std::vector.
6286 * target.c (memory_xfer_partial): Use gdb::byte_vector.
6287 (simple_search_memory): Likewise.
6288 * printcmd.c (find_string_backward): Use gdb::byte_vector.
6289 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
6290 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
6291 * elfread.c (elf_rel_plt_read): Use std::string.
6292 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
6293 * cli/cli-dump.c (restore_section_callback): Use
6294 gdb::byte_vector.
6295
7c218e6c
TT
62962017-08-03 Tom Tromey <tom@tromey.com>
6297
6298 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
6299
31b68d4a
TT
63002017-08-03 Tom Tromey <tom@tromey.com>
6301
6302 * tui/tui-regs.c (tui_restore_gdbout): Remove.
6303 (tui_register_format): Use scoped_restore.
6304
2ec845e7
TT
63052017-08-03 Tom Tromey <tom@tromey.com>
6306
6307 * reverse.c (exec_direction_default): Remove.
6308 (exec_reverse_once): Use scoped_restore.
6309 * remote.c (restore_remote_timeout): Remove.
6310 (remote_flash_erase, remote_flash_write, remote_flash_done)
6311 (readchar, remote_serial_write): Use scoped_restore.
6312 * cli/cli-script.c (struct source_cleanup_lines_args)
6313 (source_cleanup_lines): Remove.
6314 (script_from_file): Use scoped_restore.
6315 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
6316 (source_command): Use scoped_restore.
6317
b3bc8453
TT
63182017-08-03 Tom Tromey <tom@tromey.com>
6319
6320 * utils.h (make_cleanup_free_so): Remove.
6321 * utils.c (do_free_so, make_cleanup_free_so): Remove.
6322 * solist.h (struct so_deleter): New.
6323 (so_list_up): New typedef.
6324 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
6325
e3ad2841
TT
63262017-08-03 Tom Tromey <tom@tromey.com>
6327
6328 * utils.h (make_cleanup_restore_current_language): Remove.
6329 * utils.c (do_restore_current_language)
6330 (make_cleanup_restore_current_language): Remove.
6331 * parse.c (parse_exp_in_context_1)
6332 (parse_expression_with_language): Use
6333 scoped_restore_current_language.
6334 * mi/mi-main.c (mi_cmd_execute): Use
6335 scoped_restore_current_language.
6336 * language.h (scoped_restore_current_language): New class.
6337
b80cf838
TT
63382017-08-03 Tom Tromey <tom@tromey.com>
6339
6340 * compile/compile.c (cleanup_unlink_file): Remove.
6341 (compile_to_object): Use gdb::unlinker.
6342 (eval_compile_command): Likewise.
6343
fad0444a
TT
63442017-08-03 Tom Tromey <tom@tromey.com>
6345
6346 * utils.h (make_cleanup_fclose): Remove.
6347 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
6348
6e7bc05c
TT
63492017-08-03 Tom Tromey <tom@tromey.com>
6350
6351 * top.c (open_terminal_stream): Return gdb_file_up.
6352 (new_ui_command): Update.
6353
4a45905b
TT
63542017-08-03 Tom Tromey <tom@tromey.com>
6355
6356 * source.c (print_source_lines_base, forward_search_command)
6357 (reverse_search_command): Use gdb_file_up.
6358
7cd06d6e
TT
63592017-08-03 Tom Tromey <tom@tromey.com>
6360
6361 * fbsd-nat.c (fbsd_find_memory_regions): Update.
6362
ed166945
TT
63632017-08-03 Tom Tromey <tom@tromey.com>
6364
6365 * cli/cli-cmds.c (find_and_open_script): Change return type.
6366 Remove "streamp" and "full_path" parameters.
6367 (source_script_with_search): Update.
6368 * auto-load.c (source_script_file): Update.
6369 * cli/cli-cmds.h (find_and_open_script): Change type.
6370 (open_script): New struct.
6371
d419f42d
TT
63722017-08-03 Tom Tromey <tom@tromey.com>
6373
6374 * xml-support.c (xml_fetch_content_from_file): Update.
6375 * ui-file.c (stdio_file::open): Update.
6376 * tracefile-tfile.c (tfile_start): Update.
6377 * remote.c (remote_file_put, remote_file_get): Update.
6378 * nat/linux-procfs.c (linux_proc_get_int)
6379 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
6380 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
6381 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
6382 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
6383 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
6384 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
6385 * linux-nat.c (linux_proc_pending_signals): Update.
6386 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
6387 (file_closer): Remove.
6388 * compile/compile.c (compile_to_object): Update.
6389 * common/filestuff.h (struct gdb_file_deleter): New.
6390 (gdb_file_up): New typedef.
6391 (gdb_fopen_cloexec): Change return type.
6392 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
6393 * cli/cli-dump.c (fopen_with_cleanup): Remove.
6394 (dump_binary_file, restore_binary_file): Update.
6395 * auto-load.c (auto_load_objfile_script_1): Update.
6396
4a2b031d
TT
63972017-08-03 Tom Tromey <tom@tromey.com>
6398
6399 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
6400 (info_static_tracepoint_markers_command): Likewise.
6401 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
6402 * skip.c (skip_info): Use ui_out_emit_table.
6403 * progspace.c (print_program_space): Use ui_out_emit_table.
6404 * osdata.c (info_osdata): Use ui_out_emit_table.
6405 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
6406 ui_out_emit_table.
6407 * linux-thread-db.c (info_auto_load_libthread_db): Use
6408 ui_out_emit_table.
6409 * inferior.c (print_inferior): Use ui_out_emit_table.
6410 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
6411 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
6412 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
6413 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
6414 * ui-out.h (class ui_out_emit_table): New.
6415
a4f320fd
MR
64162017-08-02 Maciej W. Rozycki <macro@imgtec.com>
6417
6418 * mips-tdep.c (mips_fpu_type_str): New function.
6419 (mips_dump_tdep): Call it.
6420
a2f1f308
MR
64212017-08-01 Maciej W. Rozycki <macro@imgtec.com>
6422
6423 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
6424 `->mips_fpu_type'.
6425
7e5ed83b
XR
64262017-07-31 Xavier Roirand <roirand@adacore.com>
6427
6428 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
6429
4c9dc811
XR
64302017-07-27 Xavier Roirand <roirand@adacore.com>
6431
6432 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
6433
27d41eac
YQ
64342017-07-26 Yao Qi <yao.qi@linaro.org>
6435
6436 * cli/cli-cmds.c (maintenancechecklist): New variable.
6437 * gdbcmd.h (maintenancechecklist): Declare it.
6438 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
6439 Call i386_linux_read_description with different masks.
6440 * maint.c (maintenance_check_command): New function.
6441 (_initialize_maint_cmds): Call add_prefix_cmd.
6442 * target-descriptions.c (tdesc_reg): override operator != and ==.
6443 (tdesc_type): Likewise.
6444 (tdesc_feature): Likewise.
6445 (target_desc): Likewise.
6446 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
6447 (maintenance_check_xml_descriptions): New function.
6448 (_initialize_target_descriptions) Add command "xml-descriptions".
6449 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
6450
ea03d0d3
YQ
64512017-07-26 Yao Qi <yao.qi@linaro.org>
6452
6453 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
6454 Include features/i386/32bit-*.c.
6455 (i386_linux_read_description): Generate target description if it
6456 doesn't exist.
6457 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
6458 functions.
6459 * features/i386/32bit-linux.c: Re-generated.
6460 * features/i386/32bit-sse.c: Likewise.
6461 * target-descriptions.c (print_c_feature::visit): Print code to
6462 set register number if needed.
6463 (print_c_feature) <m_next_regnum>: New field.
6464
25aa13e5
YQ
64652017-07-26 Yao Qi <yao.qi@linaro.org>
6466
6467 * features/Makefile (CFILES): Rename with TDESC_CFILES.
6468 (FEATURE_XMLFILES): New.
6469 (FEATURE_CFILES): New.
6470 New rules.
6471 (clean-cfiles): Remove generated c files.
6472 * features/i386/32bit-avx.c: Generated.
6473 * features/i386/32bit-avx512.c: Generated.
6474 * features/i386/32bit-core.c: Generated.
6475 * features/i386/32bit-linux.c: Generated.
6476 * features/i386/32bit-mpx.c: Generated.
6477 * features/i386/32bit-pkeys.c: Generated.
6478 * features/i386/32bit-sse.c: Generated.
6479 * target-descriptions.c: Include algorithm.
6480 (tdesc_element_visitor): Add method visit_end.
6481 (print_c_tdesc): Implement visit_end.
6482 (print_c_tdesc:: m_filename_after_features): Move it to
6483 protected.
6484 (print_c_feature): New class.
6485 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
6486 name starts with "i386/32bit-".
6487
6eb1e6a8
YQ
64882017-07-26 Yao Qi <yao.qi@linaro.org>
6489
6490 * target-descriptions.c (tdesc_element_visitor): New class.
6491 (tdesc_element): New class.
6492 (tdesc_reg): Inherit from tdesc_element.
6493 (tdesc_reg::accept): New function.
6494 (tdesc_type): Inherit from tdesc_element.
6495 (tdesc_type::accept): New function.
6496 (tdesc_feature): Inherit from tdesc_element.
6497 (tdesc_feature::accept): New function.
6498 (target_desc): Inherit from tdesc_element.
6499 (target_desc::target_desc): New.
6500 (target_desc::~target_desc): New.
6501 (target_desc::accept): New.
6502 (allocate_target_description): Use new.
6503 (free_target_description): Use delete.
6504 (print_c_tdesc): New class.
6505 (maint_print_c_tdesc_cmd): Adjust.
6506
6507 * features/aarch64.c: Re-generated.
6508 * features/arc-arcompact.c: Re-generated.
6509 * features/arc-v2.c: Re-generated.
6510 * features/arm/arm-with-iwmmxt.c: Re-generated.
6511 * features/arm/arm-with-m.c: Re-generated.
6512 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
6513 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
6514 * features/arm/arm-with-neon.c: Re-generated.
6515 * features/arm/arm-with-vfpv2.c: Re-generated.
6516 * features/arm/arm-with-vfpv3.c: Re-generated.
6517 * features/i386/amd64-avx-avx512.c: Re-generated.
6518 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
6519 * features/i386/amd64-avx.c: Re-generated.
6520 * features/i386/amd64-avx-linux.c: Re-generated.
6521 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
6522 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
6523 * features/i386/amd64-avx-mpx.c: Re-generated.
6524 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
6525 * features/i386/amd64.c: Re-generated.
6526 * features/i386/amd64-linux.c: Re-generated.
6527 * features/i386/amd64-mpx.c: Re-generated.
6528 * features/i386/amd64-mpx-linux.c: Re-generated.
6529 * features/i386/i386-avx-avx512.c: Re-generated.
6530 * features/i386/i386-avx-avx512-linux.c: Re-generated.
6531 * features/i386/i386-avx.c: Re-generated.
6532 * features/i386/i386-avx-linux.c: Re-generated.
6533 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
6534 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
6535 * features/i386/i386-avx-mpx.c: Re-generated.
6536 * features/i386/i386-avx-mpx-linux.c: Re-generated.
6537 * features/i386/i386.c: Re-generated.
6538 * features/i386/i386-linux.c: Re-generated.
6539 * features/i386/i386-mmx.c: Re-generated.
6540 * features/i386/i386-mmx-linux.c: Re-generated.
6541 * features/i386/i386-mpx.c: Re-generated.
6542 * features/i386/i386-mpx-linux.c: Re-generated.
6543 * features/i386/x32-avx-avx512.c: Re-generated.
6544 * features/i386/x32-avx-avx512-linux.c: Re-generated.
6545 * features/i386/x32-avx.c: Re-generated.
6546 * features/i386/x32-avx-linux.c: Re-generated.
6547 * features/i386/x32.c: Re-generated.
6548 * features/i386/x32-linux.c: Re-generated.
6549 * features/microblaze.c: Re-generated.
6550 * features/microblaze-with-stack-protect.c: Re-generated.
6551 * features/mips64-dsp-linux.c: Re-generated.
6552 * features/mips64-linux.c: Re-generated.
6553 * features/mips-dsp-linux.c: Re-generated.
6554 * features/mips-linux.c: Re-generated.
6555 * features/nds32.c: Re-generated.
6556 * features/nios2.c: Re-generated.
6557 * features/nios2-linux.c: Re-generated.
6558 * features/rs6000/powerpc-32.c: Re-generated.
6559 * features/rs6000/powerpc-32l.c: Re-generated.
6560 * features/rs6000/powerpc-403.c: Re-generated.
6561 * features/rs6000/powerpc-403gc.c : Re-generated.
6562 * features/rs6000/powerpc-405.c: Re-generated.
6563 * features/rs6000/powerpc-505.c: Re-generated.
6564 * features/rs6000/powerpc-601.c: Re-generated.
6565 * features/rs6000/powerpc-602.c: Re-generated.
6566 * features/rs6000/powerpc-603.c: Re-generated.
6567 * features/rs6000/powerpc-604.c: Re-generated.
6568 * features/rs6000/powerpc-64.c: Re-generated.
6569 * features/rs6000/powerpc-64l.c: Re-generated.
6570 * features/rs6000/powerpc-7400.c: Re-generated.
6571 * features/rs6000/powerpc-750.c: Re-generated.
6572 * features/rs6000/powerpc-860.c: Re-generated.
6573 * features/rs6000/powerpc-altivec32.c: Re-generated.
6574 * features/rs6000/powerpc-altivec32l.c: Re-generated.
6575 * features/rs6000/powerpc-altivec64.c: Re-generated.
6576 * features/rs6000/powerpc-altivec64l.c: Re-generated.
6577 * features/rs6000/powerpc-cell32l.c: Re-generated.
6578 * features/rs6000/powerpc-cell64l.c: Re-generated.
6579 * features/rs6000/powerpc-e500.c: Re-generated.
6580 * features/rs6000/powerpc-e500l.c: Re-generated.
6581 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
6582 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
6583 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
6584 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
6585 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
6586 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
6587 * features/rs6000/powerpc-vsx32.c: Re-generated.
6588 * features/rs6000/powerpc-vsx32l.c: Re-generated.
6589 * features/rs6000/powerpc-vsx64.c: Re-generated.
6590 * features/rs6000/powerpc-vsx64l.c: Re-generated.
6591 * features/rs6000/rs6000.c: Re-generated.
6592 * features/s390-linux32.c: Re-generated.
6593 * features/s390-linux32v1.c: Re-generated.
6594 * features/s390-linux32v2.c: Re-generated.
6595 * features/s390-linux64.c: Re-generated.
6596 * features/s390-linux64v1.c: Re-generated.
6597 * features/s390-linux64v2.c: Re-generated.
6598 * features/s390-te-linux64.c: Re-generated.
6599 * features/s390-tevx-linux64.c: Re-generated.
6600 * features/s390-vx-linux64.c: Re-generated.
6601 * features/s390x-linux64.c: Re-generated.
6602 * features/s390x-linux64v1.c: Re-generated.
6603 * features/s390x-linux64v2.c: Re-generated.
6604 * features/s390x-te-linux64.c: Re-generated.
6605 * features/s390x-tevx-linux64.c: Re-generated.
6606 * features/s390x-vx-linux64.c: Re-generated.
6607 * features/sparc/sparc32-solaris.c: Re-generated.
6608 * features/sparc/sparc64-solaris.c: Re-generated.
6609 * features/tic6x-c62x.c: Re-generated.
6610 * features/tic6x-c62x-linux.c: Re-generated.
6611 * features/tic6x-c64x.c: Re-generated.
6612 * features/tic6x-c64x-linux.c: Re-generated.
6613 * features/tic6x-c64xp.c: Re-generated.
6614 * features/tic6x-c64xp-linux.c: Re-generated.
6615
35b4818d
YQ
66162017-07-26 Yao Qi <yao.qi@linaro.org>
6617
6618 * i386-linux-tdep.c (i386_linux_read_description): New function.
6619 (i386_linux_core_read_description): Call
6620 i386_linux_read_description.
6621 * i386-linux-tdep.h (i386_linux_read_description): Declare.
6622 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
6623 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
6624 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
6625 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
6626 * x86-linux-nat.c (x86_linux_read_description): Call
6627 i386_linux_read_description.
6628
8e2141c6
YQ
66292017-07-26 Yao Qi <yao.qi@linaro.org>
6630
6631 * NEWS: Mention it.
6632 * features/Makefile (%.c: %.xml): Pass the xml file name to
6633 command "maint print c-tdesc".
6634 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
6635 name from 'arg'.
6636
b468ff4c
YQ
66372017-07-26 Yao Qi <yao.qi@linaro.org>
6638
6639 * target-descriptions.c (target_desc): Add ctor and dtor. Do
6640 in-class initialization.
6641 (tdesc_create_feature): Call new instead of XCNEW.
6642 (free_target_description): Ue delete.
6643
b9c0e1b4
JB
66442017-07-25 John Baldwin <jhb@FreeBSD.org>
6645
6646 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
6647
a04b5337
YQ
66482017-07-25 Yao Qi <yao.qi@linaro.org>
6649
6650 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
6651 constant.
6652 (amd64_x32_init_abi): Likewise.
6653 * amd64-tdep.h (amd64_init_abi): Update declaration.
6654 (amd64_x32_init_abi): Likewise.
6655
02ad7fc2
YQ
66562017-07-25 Yao Qi <yao.qi@linaro.org>
6657
6658 PR tdep/21717
6659 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
6660 condition for FPSCR.
6661 (arm_linux_store_inferior_registers): Likewise.
6662
b6f48cb0
TT
66632017-07-22 Tom Tromey <tom@tromey.com>
6664
6665 * break-catch-syscall.c (struct catch_syscall_inferior_data)
6666 <syscalls_counts>: Now a std::vector.
6667 (get_catch_syscall_inferior_data): Use "new".
6668 (catch_syscall_inferior_data_cleanup): Use "delete".
6669 (insert_catch_syscall, remove_catch_syscall)
6670 (clear_syscall_counts): Update.
6671
e12c9b7a
TT
66722017-07-22 Tom Tromey <tom@tromey.com>
6673
6674 * break-catch-syscall.c (syscall_catchpoint)
6675 <syscalls_to_be_caught>: Now a std::vector<int>
6676 (~syscall_catchpoint): Remove.
6677 (insert_catch_syscall, remove_catch_syscall)
6678 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
6679 (print_mention_catch_syscall, print_recreate_catch_syscall):
6680 Update.
6681 (create_syscall_event_catchpoint): Change type of "filter"
6682 parameter.
6683 (catch_syscall_split_args): Return a std::vector.
6684 (catch_syscall_command_1, catching_syscall_number_1): Update.
6685
4fa8aeac
TT
66862017-07-22 Tom Tromey <tom@tromey.com>
6687
6688 * break-catch-throw.c (struct exception_catchpoint)
6689 <exception_rx>: Now a std::string.
6690 (~exception_catchpoint): Remove.
6691 (print_one_detail_exception_catchpoint): Update.
6692 (handle_gnu_v3_exceptions): Change type of except_rx.
6693 (extract_exception_regexp): Return a std::string.
6694 (catch_exception_command_1): Update.
6695
f746a154
TT
66962017-07-22 Tom Tromey <tom@tromey.com>
6697
6698 * break-catch-sig.c (gdb_signal_type): Remove typedef.
6699 (struct signal_catchpoint) <signals_to_be_caught>: Now a
6700 std::vector.
6701 <catch_all>: Now a bool.
6702 (~signal_catchpoint): Remove.
6703 (signal_catchpoint_insert_location)
6704 (signal_catchpoint_remove_location)
6705 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
6706 (signal_catchpoint_print_mention)
6707 (signal_catchpoint_print_recreate)
6708 (signal_catchpoint_explains_signal): Update.
6709 (create_signal_catchpoint): Change type of "filter" and
6710 "catch_all".
6711 (catch_signal_split_args): Return a std::vector. Change type of
6712 "catch_all".
6713 (catch_signal_command): Update.
6714
47e77640
PA
67152017-07-20 Pedro Alves <palves@redhat.com>
6716
6717 * ada-lang.c (ada_language_defn): Make extern.
6718 (_initialize_ada_language): Remove add_language call.
6719 * c-lang.c (c_language_defn, cplus_language_defn)
6720 (asm_language_defn, minimal_language_defn): Make extern.
6721 (_initialize_c_language): Delete.
6722 * completer.c (compare_cstrings): Delete, moved to utils.h.
6723 * d-lang.c (d_language_defn): Make extern.
6724 (_initialize_d_language): Remove add_language calls.
6725 * defs.h (enum language): Add comment.
6726 * f-lang.c (f_language_defn): Make extern.
6727 (_initialize_f_language): Remove add_language call.
6728 * go-lang.c (go_language_defn): Make extern.
6729 (_initialize_go_language): Remove add_language call.
6730 * language.c: Include <algorithm>.
6731 (languages): Redefine as const array.
6732 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
6733 (set_language_command): Handle "local". Use for-range loop.
6734 (set_language): Remove loop.
6735 (language_enum): Rewrite.
6736 (language_def, language_str): Remove loops.
6737 (add_language): Delete.
6738 (add_set_language_command): New, based on add_languages.
6739 (skip_language_trampoline): Adjust.
6740 (local_language_defn): Delete.
6741 (language_gdbarch_post_init): Adjust.
6742 (_initialize_language): Remove add_language calls. Call
6743 add_set_language_command.
6744 * language.h (add_language): Delete.
6745 (auto_language_defn)
6746 (unknown_language_defn, minimal_language_defn, ada_language_defn)
6747 (asm_language_defn, c_language_defn, cplus_language_defn)
6748 (d_language_defn, f_language_defn, go_language_defn)
6749 (m2_language_defn, objc_language_defn, opencl_language_defn)
6750 (pascal_language_defn, rust_language_defn): Declare.
6751 * m2-lang.c (m2_language_defn): Make extern.
6752 (_initialize_m2_language): Remove add_language call.
6753 * objc-lang.c (objc_language_defn): Make extern.
6754 (_initialize_objc_language): Remove add_language call.
6755 * opencl-lang.c (opencl_language_defn): Make extern.
6756 (_initialize_opencl_language): Remove add_language call.
6757 * p-lang.c (pascal_language_defn): Make extern.
6758 (_initialize_pascal_language): Delete.
6759 * rust-lang.c (rust_language_defn): Make extern.
6760 (_initialize_rust_language): Delete.
6761 * utils.h (compare_cstrings): New static inline function.
6762
edb0c9cb
PA
67632017-07-20 Pedro Alves <palves@redhat.com>
6764
6765 * ada-lang.c (ada_to_fixed_type_1): Adjust.
6766 (get_var_value): Constify parameters.
6767 (get_int_var_value): Change prototype.
6768 (to_fixed_range_type): Adjust.
6769 * ada-lang.h (get_int_var_value): Change prototype.
6770
a778f165
PA
67712017-07-20 Pedro Alves <palves@redhat.com>
6772
6773 * dwarf2read.c (dw2_lookup_symbol): Use
6774 SYMBOL_MATCHES_SEARCH_NAME.
6775 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
6776
42edd901
PA
67772017-07-20 Pedro Alves <palves@redhat.com>
6778
6779 * block.c (block_iter_name_step, block_iter_name_first)
6780 (block_iter_name_next): Delete.
6781 (block_lookup_symbol_primary): Adjust to use
6782 dict_iter_match_first/dict_iter_match_next.
6783 * block.h (block_iter_name_first, block_iter_name_next): Delete
6784 declarations.
6785 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
6786 dict_iter_match_first/dict_iter_match_next.
6787
cf325299
PA
67882017-07-20 Pedro Alves <palves@redhat.com>
6789
6790 * cp-support.c (cp_find_first_component_aux): Add missing case for
6791 end of string.
6792
c5ed0576
DB
67932017-07-18 David Blaikie <dblaikie@gmail.com>
6794
6795 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
6796 of dwo_cu's dwo_file.
6797
27841e76
YQ
67982017-07-18 Yao Qi <yao.qi@linaro.org>
6799
6800 * remote.c (store_registers_using_G): Remove one line comment.
6801
cfb7e58b
YQ
68022017-07-18 Yao Qi <yao.qi@linaro.org>
6803
6804 * regcache.c (regcache_cpy): Simplify it.
6805 (regcache::cpy_no_passthrough): Remove it.
6806 * regcache.h (cpy_no_passthrough): Remove it.
6807 (regcache_dup, regcache_cpy): Update comments.
6808
386535dd
PA
68092017-07-18 Pedro Alves <palves@redhat.com>
6810
6811 * remote-sim.c (sim_command_completer): Adjust to work with a
6812 completion_tracker instead of a VEC.
6813
c45ec17c
PA
68142017-07-17 Pedro Alves <palves@redhat.com>
6815
6816 * completer.c (complete_source_filenames): New function.
6817 (complete_address_and_linespec_locations): New function.
6818 (location_completer): Use complete_address_and_linespec_locations.
6819 (completion_tracker::build_completion_result): Honor the tracker's
6820 request to suppress append.
6821 * completer.h (completion_tracker::suppress_append_ws)
6822 (completion_tracker::set_suppress_append_ws): New methods.
6823 (completion_tracker::m_suppress_append_ws): New field.
6824 (complete_source_filenames): New declaration.
6825 * linespec.c (linespec_complete_what): New.
6826 (struct ls_parser) <complete_what, completion_word,
6827 completion_quote_char, completion_quote_end, completion_tracker>:
6828 New fields.
6829 (string_find_incomplete_keyword_at_end): New.
6830 (linespec_lexer_lex_string): Record quote char. If in completion
6831 mode, don't throw.
6832 (linespec_lexer_consume_token): Advance the completion word point.
6833 (linespec_lexer_peek_token): Save/restore completion info.
6834 (save_stream_and_consume_token): New.
6835 (set_completion_after_number): New.
6836 (linespec_parse_basic): Set what to complete next depending on
6837 token. Handle function and label completions specially.
6838 (parse_linespec): Disable objc shortcut in completion mode. Set
6839 what to complete next depending on token type. Skip keyword if in
6840 completion mode.
6841 (complete_linespec_component, linespec_complete): New.
6842 * linespec.h (linespec_complete): Declare.
6843
be966d42
PA
68442017-07-17 Pedro Alves <palves@redhat.com>
6845
6846 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
6847 Handle 'operator<' / 'operator<<'.
6848
a2459270
PA
68492017-07-17 Pedro Alves <palves@redhat.com>
6850
6851 * completer.c (collect_explicit_location_matches): Handle
6852 MATCH_LABEL.
6853 (convert_explicit_location_to_linespec): New, factored out from
6854 ...
6855 (convert_explicit_location_to_sals): ... this.
6856 (complete_label): New.
6857 (linespec_complete_label, find_label_symbols_in_block): New.
6858 (find_label_symbols): Add completion_mode parameter and adjust to
6859 call find_label_symbols_in_block.
6860 * linespec.h (linespec_complete_label): Declare.
6861
c6756f62
PA
68622017-07-17 Pedro Alves <palves@redhat.com>
6863
6864 * ada-lang.c (ada_collect_symbol_completion_matches): Add
6865 complete_symbol_mode parameter.
6866 * cli/cli-cmds.c (complete_command): Get the completion result out
6867 of the handle_brkchars tracker if used a custom word point.
6868 * completer.c: Include "linespec.h".
6869 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
6870 (advance_to_expression_complete_word_point): New.
6871 (completion_tracker::completes_to_completion_word): New.
6872 (complete_files_symbols): Pass down
6873 complete_symbol_mode::EXPRESSION.
6874 (explicit_options, probe_options): New.
6875 (collect_explicit_location_matches): Complete on the
6876 explictit_loc->foo instead of word. Use
6877 linespec_complete_function. Handle MATCH_LINE. Handle offering
6878 keyword and options completions.
6879 (backup_text_ptr): Delete.
6880 (skip_keyword): New.
6881 (complete_explicit_location): Remove 'word' parameter. Add
6882 language, quoted_arg_start and quoted_arg_end parameters.
6883 Rewrite, parsing left to right.
6884 (location_completer): Rewrite.
6885 (location_completer_handle_brkchars): New function.
6886 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
6887 (enum complete_line_internal_reason): Adjust comments.
6888 (completion_tracker::discard_completions): New.
6889 (completer_handle_brkchars_func_for_completer): Handle
6890 location_completer.
6891 (gdb_custom_word_point_brkchars)
6892 (gdb_org_rl_basic_quote_characters): New.
6893 (gdb_completion_word_break_characters_throw)
6894 (completion_find_completion_word): Handle trackers that use a
6895 custom word point.
6896 (completion_tracker::advance_custom_word_point_by): New.
6897 (completion_tracker::build_completion_result): Don't rely on
6898 readline appending the quote char.
6899 (gdb_rl_attempted_completion_function_throw): Handle trackers that
6900 use a custom word point.
6901 (gdb_rl_attempted_completion_function): Restore
6902 rl_basic_quote_characters.
6903 * completer.h (class completion_tracker): Extend intro comment.
6904 (completion_tracker::set_quote_char)
6905 (completion_tracker::quote_char)
6906 (completion_tracker::set_use_custom_word_point)
6907 (completion_tracker::use_custom_word_point)
6908 (completion_tracker::custom_word_point)
6909 (completion_tracker::set_custom_word_point)
6910 (completion_tracker::advance_custom_word_point_by)
6911 (completion_tracker::completes_to_completion_word)
6912 (completion_tracker::discard_completions): New methods.
6913 (completion_tracker::m_quote_char)
6914 (completion_tracker::m_use_custom_word_point)
6915 (completion_tracker::m_custom_word_point): New fields.
6916 (advance_to_expression_complete_word_point): Declare.
6917 * f-lang.c (f_collect_symbol_completion_matches): Add
6918 complete_symbol_mode parameter.
6919 * language.h (struct language_defn)
6920 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
6921 parameter.
6922 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
6923 (linespec_complete_function): New function.
6924 (linespec_lexer_lex_keyword): Adjust.
6925 * linespec.h (linespec_keywords, linespec_complete_function): New
6926 declarations.
6927 * location.c (find_end_quote): New function.
6928 (explicit_location_lex_one): Add explicit_completion_info
6929 parameter. Save quoting info. Don't throw if being called for
6930 completion. Don't handle Ada operators here.
6931 (is_cp_operator, skip_op_false_positives, first_of)
6932 (explicit_location_lex_one_function): New function.
6933 (string_to_explicit_location): Replace 'dont_throw' parameter with
6934 an explicit_completion_info pointer parameter. Handle it. Don't
6935 use explicit_location_lex_one to lex function names. Use
6936 explicit_location_lex_one_function instead.
6937 * location.h (struct explicit_completion_info): New.
6938 (string_to_explicit_location): Replace 'dont_throw' parameter with
6939 an explicit_completion_info pointer parameter.
6940 * symtab.c (default_collect_symbol_completion_matches_break_on):
6941 Add complete_symbol_mode parameter. Handle LINESPEC mode.
6942 (default_collect_symbol_completion_matches)
6943 (collect_symbol_completion_matches): Add complete_symbol_mode
6944 parameter.
6945 (collect_symbol_completion_matches_type): Pass down
6946 complete_symbol_mode::EXPRESSION.
6947 (collect_file_symbol_completion_matches): Add complete_symbol_mode
6948 parameter. Handle LINESPEC mode.
6949 * symtab.h (complete_symbol_mode): New.
6950 (default_collect_symbol_completion_matches_break_on)
6951 (default_collect_symbol_completion_matches)
6952 (collect_symbol_completion_matches)
6953 (collect_file_symbol_completion_matches): Add complete_symbol_mode
6954 parameter.
6955
1d550c82
PA
69562017-07-17 Pedro Alves <palves@redhat.com>
6957
6958 * utils.c (enum class strncmp_iw_mode): New.
6959 (strcmp_iw): Rename to ...
6960 (strncmp_iw_with_mode): ... this. Add string2_len and mode
6961 parameters. Handle them.
6962 (strncmp_iw): New.
6963 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
6964 * utils.h (strncmp_iw): Declare.
6965 (strcmp_iw): Move describing comments here.
6966
8090b426
PA
69672017-07-17 Pedro Alves <palves@redhat.com>
6968
6969 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
6970 CP_OPERATOR_STR.
6971 * c-typeprint.c (is_type_conversion_operator): Use
6972 CP_OPERATOR_STR.
6973 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
6974 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
6975 CP_OPERATOR_LEN.
6976 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
6977 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
6978 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
6979 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
6980 CP_OPERATOR_STR.
6981 * location.c: Include "cp-support.h".
6982 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
6983 CP_OPERATOR_STR.
6984 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
6985 CP_OPERATOR_LEN.
6986
6a2c1b87
PA
69872017-07-17 Pedro Alves <palves@redhat.com>
6988
6989 * cli/cli-cmds.c (complete_command): Use a completion tracker
6990 along with completion_find_completion_word for handle_brkchars
6991 phase.
6992 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
6993 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
6994 (struct gdb_rl_completion_word_info): New.
6995 (gdb_rl_find_completion_word): New.
6996 (completion_find_completion_word): New.
6997 * completer.h (completion_find_completion_word): Declare.
6998
eb3ff9a5
PA
69992017-07-17 Pedro Alves <palves@redhat.com>
7000
7001 * ada-lang.c (symbol_completion_match): Adjust comments.
7002 (symbol_completion_add): Replace vector parameter with
7003 completion_tracker parameter. Use it.
7004 (ada_make_symbol_completion_list): Rename to...
7005 (ada_collect_symbol_completion_matches): ... this. Add
7006 completion_tracker parameter and use it.
7007 (ada_language_defn): Adjust.
7008 * break-catch-syscall.c (catch_syscall_completer): Adjust
7009 prototype and work with completion_tracker instead of VEC.
7010 * breakpoint.c (condition_completer): Adjust prototype and work
7011 with completion_tracker instead of VEC.
7012 * c-lang.c (c_language_defn, cplus_language_defn)
7013 (asm_language_defn, minimal_language_defn): Adjust to renames.
7014 * cli/cli-cmds.c (complete_command): Rework using
7015 completion_tracker. Catch exceptions when completing.
7016 * cli/cli-decode.c (integer_unlimited_completer)
7017 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
7018 with completion_tracker instead of VEC.
7019 * command.h (struct completion_tracker): Forward declare.
7020 (completer_ftype, completer_handle_brkchars_ftype): Change
7021 types.
7022 (complete_on_cmdlist, complete_on_enum): Adjust.
7023 * completer.c: Include <algorithm>.
7024 (struct gdb_completer_state): New.
7025 (current_completion): New global.
7026 (readline_line_completion_function): Delete.
7027 (noop_completer, filename_completer)
7028 (filename_completer_handle_brkchars, complete_files_symbols)
7029 (linespec_location_completer): Adjust to work with a
7030 completion_tracker instead of a VEC.
7031 (string_or_empty): New.
7032 (collect_explicit_location_matches): Adjust to work with a
7033 completion_tracker instead of a VEC.
7034 (explicit_location_completer): Rename to ...
7035 (complete_explicit_location): ... this and adjust to work with a
7036 completion_tracker instead of a VEC.
7037 (location_completer): Adjust to work with a completion_tracker
7038 instead of a VEC.
7039 (add_struct_fields): Adjust to work with a completion_list instead
7040 of VEC.
7041 (expression_completer): Rename to ...
7042 (complete_expression): ... this and adjust to work with a
7043 completion_tracker instead of a VEC. Use complete_files_symbols.
7044 (expression_completer): Reimplement on top of complete_expression.
7045 (symbol_completer): Adjust to work with a completion_tracker
7046 instead of a VEC.
7047 (enum complete_line_internal_reason): Add describing comments.
7048 (complete_line_internal_normal_command): Adjust to work with a
7049 completion_tracker instead of a VEC.
7050 (complete_line_internal): Rename to ...
7051 (complete_line_internal_1): ... this and adjust to work with a
7052 completion_tracker instead of a VEC. Assert TEXT is NULL in the
7053 handle_brkchars phase.
7054 (new_completion_tracker): Delete.
7055 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
7056 complete_line_internal_1.
7057 (free_completion_tracker): Delete.
7058 (INITIAL_COMPLETION_HTAB_SIZE): New.
7059 (completion_tracker::completion_tracker)
7060 (completion_tracker::~completion_tracker): New.
7061 (maybe_add_completion): Delete.
7062 (completion_tracker::maybe_add_completion)
7063 (completion_tracker::add_completion)
7064 (completion_tracker::add_completions): New.
7065 (throw_max_completions_reached_error): Delete.
7066 (complete_line): Adjust to work with a completion_tracker instead
7067 of a VEC. Don't create a completion_tracker_t or check for max
7068 completions here.
7069 (command_completer, command_completer_handle_brkchars)
7070 (signal_completer, reg_or_group_completer_1)
7071 (reg_or_group_completer, default_completer_handle_brkchars):
7072 Adjust to work with a completion_tracker.
7073 (gdb_completion_word_break_characters_throw): New.
7074 (gdb_completion_word_break_characters): Reimplement.
7075 (line_completion_function): Delete.
7076 (completion_tracker::recompute_lowest_common_denominator)
7077 (expand_preserving_ws)
7078 (completion_tracker::build_completion_result)
7079 (completion_result::completion_result)
7080 (completion_result::completion_result)
7081 (completion_result::~completion_result)
7082 (completion_result::completion_result)
7083 (completion_result::release_match_list, compare_cstrings)
7084 (completion_result::sort_match_list)
7085 (completion_result::reset_match_list)
7086 (gdb_rl_attempted_completion_function_throw)
7087 (gdb_rl_attempted_completion_function): New.
7088 * completer.h (completion_list, struct completion_result)
7089 (class completion_tracker): New.
7090 (complete_line): Add completion_tracker parameter.
7091 (readline_line_completion_function): Delete.
7092 (gdb_rl_attempted_completion_function): New.
7093 (noop_completer, filename_completer, expression_completer)
7094 (location_completer, symbol_completer, command_completer)
7095 (signal_completer, reg_or_group_completer): Update prototypes.
7096 (completion_tracker_t, new_completion_tracker)
7097 (make_cleanup_free_completion_tracker): Delete.
7098 (enum maybe_add_completion_enum): Delete.
7099 (maybe_add_completion): Delete.
7100 (throw_max_completions_reached_error): Delete.
7101 * corefile.c (complete_set_gnutarget): Adjust to work with a
7102 completion_tracker instead of a VEC.
7103 * cp-abi.c (cp_abi_completer): Adjust to work with a
7104 completion_tracker instead of a VEC.
7105 * d-lang.c (d_language_defn): Adjust.
7106 * disasm.c (disassembler_options_completer): Adjust to work with a
7107 completion_tracker instead of a VEC.
7108 * f-lang.c (f_make_symbol_completion_list): Rename to ...
7109 (f_collect_symbol_completion_matches): ... this. Adjust to work
7110 with a completion_tracker instead of a VEC.
7111 (f_language_defn): Adjust.
7112 * go-lang.c (go_language_defn): Adjust.
7113 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
7114 Adjust to work with a completion_tracker instead of a VEC.
7115 * infrun.c (handle_completer): Likewise.
7116 * interps.c (interpreter_completer): Likewise.
7117 * interps.h (interpreter_completer): Likewise.
7118 * language.c (unknown_language_defn, auto_language_defn)
7119 (local_language_defn): Adjust.
7120 * language.h (language_defn::la_make_symbol_completion_list):
7121 Rename to ...
7122 (language_defn::la_collect_symbol_completion_matches): ... this
7123 and adjust to work with a completion_tracker instead of a VEC.
7124 * m2-lang.c (m2_language_defn): Adjust.
7125 * objc-lang.c (objc_language_defn): Adjust.
7126 * opencl-lang.c (opencl_language_defn): Adjust.
7127 * p-lang.c (pascal_language_defn): Adjust.
7128 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
7129 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
7130 with a completion_tracker.
7131 * rust-lang.c (rust_language_defn): Adjust.
7132 * symtab.c (free_completion_list, do_free_completion_list)
7133 (return_val, completion_tracker): Delete.
7134 (completion_list_add_name, completion_list_add_symbol)
7135 (completion_list_add_msymbol, completion_list_objc_symbol)
7136 (completion_list_add_fields, add_symtab_completions): Add
7137 completion_tracker parameter and use it.
7138 (default_make_symbol_completion_list_break_on_1): Rename to...
7139 (default_collect_symbol_completion_matches_break_on): ... this.
7140 Add completion_tracker parameter and use it instead of allocating
7141 a completion tracker here.
7142 (default_make_symbol_completion_list_break_on): Delete old
7143 implementation.
7144 (default_make_symbol_completion_list): Delete.
7145 (default_collect_symbol_completion_matches): New.
7146 (make_symbol_completion_list): Delete.
7147 (collect_symbol_completion_matches): New.
7148 (make_symbol_completion_type): Rename to ...
7149 (collect_symbol_completion_matches_type): ... this. Add
7150 completion_tracker parameter and use it instead of VEC.
7151 (make_file_symbol_completion_list_1): Rename to...
7152 (collect_file_symbol_completion_matches): ... this. Add
7153 completion_tracker parameter and use it instead of VEC.
7154 (make_file_symbol_completion_list): Delete.
7155 (add_filename_to_list): Use completion_list instead of a VEC.
7156 (add_partial_filename_data::list): Now a completion_list.
7157 (make_source_files_completion_list): Work with a completion_list
7158 instead of a VEC.
7159 * symtab.h: Include "completer.h".
7160 (default_make_symbol_completion_list_break_on)
7161 (default_make_symbol_completion_list, make_symbol_completion_list)
7162 (make_symbol_completion_type, make_file_symbol_completion_list)
7163 (make_source_files_completion_list): Delete.
7164 (default_collect_symbol_completion_matches_break_on)
7165 (default_collect_symbol_completion_matches)
7166 (collect_symbol_completion_matches)
7167 (collect_symbol_completion_matches_type)
7168 (collect_file_symbol_completion_matches)
7169 (make_source_files_completion_list): New.
7170 * top.c (init_main): Don't install a rl_completion_entry_function
7171 hook. Install a rl_attempted_completion_function hook instead.
7172 * tui/tui-layout.c (layout_completer): Adjust to work with a
7173 completion_tracker.
7174 * tui/tui-regs.c (tui_reggroup_completer):
7175 * tui/tui-win.c (window_name_completer, focus_completer)
7176 (winheight_completer): Adjust to work with a completion_tracker.
7177 * value.c: Include "completer.h".
7178 (complete_internalvar): Adjust to work with a completion_tracker.
7179 * value.h (complete_internalvar): Likewise.
7180
6e1dbf8c
PA
71812017-07-17 Pedro Alves <palves@redhat.com>
7182
7183 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
7184 renames.
7185 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
7186 comments to completer_ftype's declaration.
7187 <completer_handle_brkchars>: Change type to
7188 completer_handle_brkchars_ftype.
7189 * command.h (completer_ftype): Add describing comment and give
7190 names to parameters.
7191 (completer_ftype_void): Rename to ...
7192 (completer_handle_brkchars_ftype) ... this. Add describing comment.
7193 (set_cmd_completer_handle_brkchars): Adjust.
7194 * completer.c (filename_completer_handle_brkchars): New function.
7195 (complete_line_internal_normal_command): New function, factored
7196 out from ...
7197 (complete_line_internal): ... here.
7198 (command_completer_handle_brkchars)
7199 (default_completer_handle_brkchars)
7200 (completer_handle_brkchars_func_for_completer): New functions.
7201 * completer.h (set_gdb_completion_word_break_characters): Delete
7202 declaration.
7203 (completer_handle_brkchars_func_for_completer): New declaration.
7204 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
7205 completer_handle_brkchars_func_for_completer.
7206
78b13106
PA
72072017-07-17 Pedro Alves <palves@redhat.com>
7208
7209 * completer.c (symbol_completer): New function, based on
7210 make_symbol_completion_list_fn.
7211 * completer.h (symbol_completer): New declaration.
7212 * guile/scm-cmd.c (cmdscm_completers): Adjust.
7213 * python/py-cmd.c (completers): Adjust.
7214 * symtab.c (make_symbol_completion_list_fn): Delete.
7215 * symtab.h (make_symbol_completion_list_fn): Delete.
7216 * cli/cli-decode.c (add_cmd): Adjust.
7217
bbf2f4df
PA
72182017-07-17 Pedro Alves <palves@redhat.com>
7219
7220 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
7221 * dwarf2read.c: Include "filename-seen-cache.h".
7222 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
7223 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
7224 * filename-seen-cache.c: New file.
7225 * filename-seen-cache.h: New file.
7226 * symtab.c: Include "filename-seen-cache.h".
7227 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
7228 (create_filename_seen_cache, clear_filename_seen_cache)
7229 (delete_filename_seen_cache, filename_seen): Delete, parts moved
7230 to filename-seen-cache.h/filename-seen-cache.c.
7231 (output_source_filename, sources_info)
7232 (maybe_add_partial_symtab_filename)
7233 (make_source_files_completion_list): Adjust to use
7234 filename_seen_cache.
7235
330cdd98
PA
72362017-07-17 Pedro Alves <palves@redhat.com>
7237
7238 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
7239 fields.
7240 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
7241 dwarf2_debug_sections*)): New.
7242 (dwarf2_per_objfile::dwarf2_per_objfile(const
7243 dwarf2_per_objfile&)): Declare as deleted.
7244 (dwarf2_per_objfile::operator=): Declare as deleted.
7245 (dwarf2_per_objfile::dwarf2_per_objfile)
7246 (dwarf2_per_objfile::~dwarf2_per_objfile)
7247 (dwarf2_per_objfile::free_cached_comp_units): New.
7248 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
7249 ctor. Call dwarf2_per_objfile's ctor manually.
7250 (dwarf2_locate_sections): Deleted/refactored as ...
7251 (dwarf2_per_objfile::locate_sections): ... this new method.
7252 (free_cached_comp_units): Defer to
7253 dwarf2_per_objfile::free_cached_comp_units.
7254 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
7255
8880f2a9
TT
72562017-07-14 Tom Tromey <tom@tromey.com>
7257
7258 PR rust/21764:
7259 * rust-exp.y (convert_ast_to_expression): Add "want_type"
7260 parameter.
7261 <UNOP_SIZEOF>: Split into separate case.
7262 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
7263
65547233
TT
72642017-07-14 Tom Tromey <tom@tromey.com>
7265
7266 PR rust/21763:
7267 * symtab.c (symbol_matches_domain): Add language_rust to special
7268 case.
7269 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
7270 treat LOC_TYPEDEF symbols as variables.
7271
8f14146e
PA
72722017-07-14 Pedro Alves <palves@redhat.com>
7273
7274 * symtab.c (make_file_symbol_completion_list_1): Iterate over
7275 symtabs matching all symtabs with SRCFILE as file name instead of
7276 only considering the first hit, with lookup_symtab.
7277
2347965c
SM
72782017-07-14 Simon Marchi <simon.marchi@ericsson.com>
7279
7280 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
7281 operator_name parameters.
7282 (gen_expr): Update function call.
7283
40f4af28
SM
72842017-07-14 Simon Marchi <simon.marchi@ericsson.com>
7285
7286 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
7287 parameter.
7288 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
7289 Likewise.
7290 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
7291 parameter, use agent_expr::gdbarch instead, update function
7292 calls.
7293 (locexpr_tracepoint_var_ref): Likewise.
7294 (loclist_tracepoint_var_ref): Likewise.
7295 * ax-gdb.c (gen_trace_static_fields): Likewise.
7296 (gen_traced_pop): Likewise.
7297 (gen_frame_args_address): Likewise.
7298 (gen_frame_locals_address): Likewise.
7299 (gen_var_ref): Likewise.
7300 (gen_struct_ref_recursive): Likewise.
7301 (gen_static_field): Likewise.
7302 (gen_maybe_namespace_elt): Likewise.
7303 (gen_expr): Likewise.
7304 (gen_trace_for_var): Likewise.
7305 (gen_trace_for_expr): Likewise.
7306 (gen_trace_for_return_address): Likewise.
7307
053f8057
SM
73082017-07-14 Simon Marchi <simon.marchi@ericsson.com>
7309
7310 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
7311 parameter.
7312 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
7313
6661ad48
SM
73142017-07-14 Simon Marchi <simon.marchi@ericsson.com>
7315
7316 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
7317 from ax, update calls.
7318 (gen_usual_arithmetic): Likewise.
7319 (gen_integral_promotions): Likewise.
7320 (gen_bitfield_ref): Likewise.
7321 (gen_primitive_field): Likewise.
7322 (gen_struct_ref_recursive): Likewise.
7323 (gen_struct_ref): Likewise.
7324 (gen_maybe_namespace_elt): Likewise.
7325 (gen_struct_elt_for_reference): Likewise.
7326 (gen_namespace_elt): Likewise.
7327 (gen_aggregate_elt_ref): Likewise.
7328 (gen_expr): Get gdbarch from ax, update calls.
7329 (gen_expr_binop_rest): Likewise.
7330
c55a47e7
PA
73312017-07-13 Pedro Alves <palves@redhat.com>
7332
7333 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
7334 as default tdesc.
7335 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
7336 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
7337 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
7338 tdesc_amd64_linux as default tdesc. Get final tdesc from the
7339 tdep.
7340 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
7341 Get final tdesc from the tdep.
7342 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
7343 default tdesc.
7344 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
7345 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
7346 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
7347 Use it as default tdesc.
7348 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
7349 down to amd_init_abi. No longer handle fallback tdesc here.
7350 * amd64-tdep.h (tdesc_x32): Declare.
7351 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
7352 parameter.
7353 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
7354 as default tdesc.
7355
55efceab
AA
73562017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7357
7358 * s390-linux-tdep.c (s390_process_record): Add support for
7359 instructions new in arch12.
7360
0aa37b65
JB
73612017-07-11 John Baldwin <jhb@FreeBSD.org>
7362
7363 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
7364 PT_GETFSBASE and PT_GETGSBASE.
7365 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
7366 PT_SETGSBASE.
7367
48aeef91
JB
73682017-07-11 John Baldwin <jhb@FreeBSD.org>
7369
7370 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
7371 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
7372 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
7373 those rules.
7374 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
7375 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
7376 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
7377 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
7378 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
7379 * features/i386/amd64.xml: Add 64bit-segments.xml.
7380 * features/i386/amd64-avx-avx512.c: Regenerated.
7381 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
7382 * features/i386/amd64-avx-mpx.c: Regenerated.
7383 * features/i386/amd64-avx.c: Regenerated.
7384 * features/i386/amd64-mpx.c: Regenerated.
7385 * features/i386/amd64.c: Regenerated.
7386 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
7387 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
7388 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
7389 * regformats/i386/amd64-avx.dat: Regenerated.
7390 * regformats/i386/amd64-mpx.dat: Regenerated.
7391 * regformats/i386/amd64.dat: Regenerated.
7392
77c501bc
YQ
73932017-07-10 Yao Qi <yao.qi@linaro.org>
7394
7395 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
7396 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
7397
6dc8d757
AK
73982017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
7399
7400 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
7401 unsetenv.
7402 * gnulib/aclocal.m4: Regenerate.
7403 * gnulib/config.in: Regenerate.
7404 * gnulib/configure: Regenerate.
7405 * gnulib/import/Makefile.am: Regenerate.
7406 * gnulib/import/Makefile.in: Regenerate.
7407 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
7408 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
7409 * gnulib/import/m4/environ.m4: New file.
7410 * gnulib/import/m4/setenv.m4: New file.
7411 * gnulib/import/setenv.c: New file.
7412 * gnulib/import/unsetenv.c: New file.
7413
266934d1
SM
74142017-07-09 Simon Marchi <simon.marchi@ericsson.com>
7415
7416 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
7417 address when op is DW_OP_addr.
7418
03278692
TT
74192017-07-09 Tom Tromey <tom@tromey.com>
7420
7421 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
7422 check and apply to outer type.
7423
4b654465
JB
74242017-07-07 John Baldwin <jhb@FreeBSD.org>
7425
7426 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
7427 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
7428 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
7429 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
7430
2af9fc44
JB
74312017-07-07 John Baldwin <jhb@FreeBSD.org>
7432
7433 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
7434
382b69bb
JB
74352017-07-07 John Baldwin <jhb@FreeBSD.org>
7436
7437 * corelow.c (get_core_siginfo): Remove.
7438 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
7439 instead of get_core_siginfo.
7440 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
7441 * gdbarch.h: Re-generate.
7442 * gdbarch.c: Re-generate.
7443 * linux-tdep.c (linux_core_xfer_siginfo): New.
7444 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
7445
6e5eab33
JB
74462017-07-07 John Baldwin <jhb@FreeBSD.org>
7447
7448 * corelow.c (thread_section_name): Move to ...
7449 * gdbcore.h (thread_section_name): ... here.
7450
929edea9
JB
74512017-07-07 John Baldwin <jhb@FreeBSD.org>
7452
7453 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
7454 (struct siginfo32): New.
7455 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
7456 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
7457 via ptrace(PT_LWPINFO).
7458
762c974a
JB
74592017-07-07 John Baldwin <jhb@FreeBSD.org>
7460
7461 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
7462 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
7463 (fbsd_get_siginfo_type): New.
7464 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
7465 (_initialize_fbsd_tdep): New.
7466
33c5cd75
DB
74672017-07-06 David Blaikie <dblaikie@gmail.com>
7468
7469 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
7470 a singular dwo_unit*) to support multiple CUs in the same way that
7471 multiple TUs are supported.
7472 (create_cus_hash_table): Replace create_dwo_cu with a function for
7473 parsing multiple CUs from a DWO file.
7474 (open_and_init_dwo_file): Use create_cus_hash_table rather than
7475 create_dwo_cu.
7476 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
7477 htab_find, rather than comparing the signature to a singleton CU in
7478 the dwo_file.
7479
8455d262
PA
74802017-07-06 Pedro Alves <palves@redhat.com>
7481
7482 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
7483
4da3eb35
PA
74842017-07-04 Pedro Alves <palves@redhat.com>
7485
7486 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
7487 * gdbtypes.h (TYPE_STATIC): Delete.
7488 (struct fn_field) <is_public, is_abstract, is_static, is_final,
7489 is_synchronized, is_native>: Delete.
7490 <dummy>: Bump.
7491 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
7492 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
7493 (TYPE_FN_FIELD_ABSTRACT): Delete.
7494
5bfd255c
SM
74952017-07-03 Simon Marchi <simon.marchi@ericsson.com>
7496
7497 * buffer.h (buffer_finish): Fix spelling mistakes.
7498
25c54127
EZ
74992017-07-01 Eli Zaretskii <eliz@gnu.org>
7500
7501 * .dir-locals.el: Automatically switch to C-style comments in
7502 versions of Emacs that support the feature.
7503
dc4bde35
SDJ
75042017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
7505 Pedro Alves <palves@redhat.com>
7506
7507 PR cli/21688
7508 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
7509 (process_next_line): New variable 'inline_cmd'.
7510 Adjust 'if' clauses for "python", "compile" and "guile" to use
7511 'command_name_equals' and check for '!inline_cmd'.
7512
51ed89aa
SDJ
75132017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
7514
7515 PR cli/21688
7516 * cli/cli-script.c (command_name_equals_not_inline): New function.
7517 (process_next_line): Adjust 'if' clauses for "python", "compile"
7518 and "guile" to use command_name_equals_not_inline.
7519
eb17d413
PA
75202017-06-29 Pedro Alves <palves@redhat.com>
7521
7522 * completer.c (expression_completer): Call
7523 linespec_location_completer instead of location_completer.
7524
195bcdd5
PA
75252017-06-29 Pedro Alves <palves@redhat.com>
7526
7527 * completer.c (expression_completer): Remove code that recomputes
7528 'text' from 'word'.
7529
adc764e7
YQ
75302017-06-29 Yao Qi <yao.qi@linaro.org>
7531
7532 * regformats/regdat.sh: Generate code with
7533 "ifndef IN_PROCESS_AGENT".
7534
6e75794e
PA
75352017-06-28 Pedro Alves <palves@redhat.com>
7536
7537 * command.h: Include "common/scoped_restore.h".
7538
bc491f2e
YQ
75392017-06-28 Yao Qi <yao.qi@linaro.org>
7540
7541 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
7542 instead of obstack_grow.
7543
41664b45
DG
75442017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
7545
7546 PR gdb/21337
7547 * symfile.c (reread_symbols): Call objfiles_changed just before
7548 read_symbols.
7549
6da67eb1
PA
75502017-06-27 Pedro Alves <palves@redhat.com>
7551
7552 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
7553 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
7554 (completion_list_add_symbol, completion_list_add_msymbol):
7555 ... these new functions.
7556 (add_symtab_completions)
7557 (default_make_symbol_completion_list_break_on_1): Adjust.
7558
23732b1e
PA
75592017-06-27 Pedro Alves <palves@redhat.com>
7560
7561 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
7562 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
7563 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
7564 dtor.
7565 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
7566 'storage_obstack' field an auto_obstack. In-class initialize all
7567 non-bitfield fields. Make minsyms_read bool.
7568 * symfile.c (read_symbols): Adjust.
7569
a4d1e79a
AH
75702017-06-27 Alan Hayward <alan.hayward@arm.com>
7571
7572 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
7573 (gdbsim_store_register): Likewise.
7574
8268c778
PA
75752017-06-27 Pedro Alves <palves@redhat.com>
7576
7577 * c-exp.y (name_obstack): Now an auto_obstack.
7578 (yylex): Use auto_obstack::clear.
7579 (c_parse): Use auto_obstack::clear instead of reinitializing and
7580 freeing the obstack.
7581 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
7582 * d-exp.y (name_obstack): Now an auto_obstack.
7583 (yylex): Use auto_obstack::clear.
7584 (d_parse): Use auto_obstack::clear instead of reinitializing and
7585 freeing the obstack.
7586 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
7587 auto_obstack.
7588 * dwarf2read.c (create_addrmap_from_index)
7589 (dwarf2_build_psymtabs_hard)
7590 (update_enumeration_type_from_children): Likewise.
7591 * gdb_obstack.h (auto_obstack): New type.
7592 * go-exp.y (name_obstack): Now an auto_obstack.
7593 (build_packaged_name): Use auto_obstack::clear.
7594 (go_parse): Use auto_obstack::clear instead of reinitializing and
7595 freeing the obstack.
7596 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
7597 auto_obstack.
7598 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
7599 * rust-exp.y (work_obstack): Now an auto_obstack.
7600 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
7601 reinitializing and freeing the obstack.
7602 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
7603 (host_char_to_target): Use auto_obstack.
7604 * utils.h (make_cleanup_obstack_free): Delete declaration.
7605 * valprint.c (generic_emit_char, generic_printstr): Use
7606 auto_obstack.
7607
db665f42
SM
76082017-06-27 Simon Marchi <simon.marchi@ericsson.com>
7609
7610 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
7611 thread.
7612 (darwin_init_thread_list): Don't update dummy thread.
7613 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
7614
873c0814
SM
76152017-06-26 Simon Marchi <simon.marchi@ericsson.com>
7616
7617 * record-full.c (netorder16): Remove.
7618
8b5a7a6e
SM
76192017-06-26 Simon Marchi <simon.marchi@ericsson.com>
7620
7621 * common/diagnostics.h: Define macros for GCC.
7622 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
7623 * common/vec.h: Include diagnostics.h.
7624 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
7625 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
7626 warning.
7627
d1435379
SM
76282017-06-26 Simon Marchi <simon.marchi@ericsson.com>
7629
7630 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
7631 New macro.
7632 * ada-lex.l: Ignore deprecated register warnings.
7633
cc75e0fd
SM
76342017-06-25 Simon Marchi <simon.marchi@ericsson.com>
7635
7636 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
7637 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
7638
07809eaf
SM
76392017-06-25 Simon Marchi <simon.marchi@ericsson.com>
7640
7641 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
7642 its own line.
7643
f076f034
SM
76442017-06-25 Simon Marchi <simon.marchi@ericsson.com>
7645
7646 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
7647
0dd5cbc5
AH
76482017-06-23 Alan Hayward <alan.hayward@arm.com>
7649
7650 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
7651 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
7652 (xtensa_register_read_masked): Likewise.
7653
d4c6ce5b
SDJ
76542017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
7655
7656 * common/environ.c (gdb_environ::unset): Update comment.
7657
16892a03
AH
76582017-06-22 Alan Hayward <alan.hayward@arm.com>
7659
7660 * python/py-unwind.c (pyuw_sniffer): Allocate space for
7661 registers.
7662
d7dcbefc
AH
76632017-06-22 Alan Hayward <alan.hayward@arm.com>
7664
7665 * record-full.c (record_full_exec_insn): Use byte_vector.
7666
b30ff123
YQ
76672017-06-22 Yao Qi <yao.qi@linaro.org>
7668
7669 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
7670 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
7671
4fa847d7
AH
76722017-06-22 Alan Hayward <alan.hayward@arm.com>
7673
7674 * remote.c (cached_reg): Move from here...
7675 * regcache.h (cached_reg): ...to here.
7676 * python/py-unwind.c (struct reg_info): Remove.
7677 (cached_frame_info): Use cached_reg_t.
7678 (pyuw_prev_register): Likewise.
7679 (pyuw_sniffer): Use cached_reg_t and allocate registers.
7680 (pyuw_dealloc_cache): Free all registers.
7681
f4906a9a
PA
76822017-06-22 Pedro Alves <palves@redhat.com>
7683 Simon Marchi <simon.marchi@ericsson.com>
7684
7685 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
7686 warning.
7687 * common/diagnostics.h: New file.
7688
b45a1208
PA
76892017-06-22 Pedro Alves <palves@redhat.com>
7690
7691 * common/agent.h: Add include guards.
7692
e4da2c61
SM
76932017-06-21 Simon Marchi <simon.marchi@ericsson.com>
7694
7695 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
7696 talk about addressable units instead of bytes.
7697
96160d60
SDJ
76982017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
7699
7700 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
7701 of '::const_iterator'.
7702
9a6c7d9c
SDJ
77032017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
7704
7705 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7706 'unittests/environ-selftests.c'.
7707 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
7708 * charset.c (find_charset_names): Declare object 'iconv_env'.
7709 Update code to use 'iconv_env' object. Remove call to
7710 'free_environ'.
7711 * common/environ.c: Include <utility>.
7712 (make_environ): Delete function.
7713 (free_environ): Delete function.
7714 (gdb_environ::clear): New function.
7715 (gdb_environ::operator=): New function.
7716 (gdb_environ::get): Likewise.
7717 (environ_vector): Delete function.
7718 (set_in_environ): Delete function.
7719 (gdb_environ::set): New function.
7720 (unset_in_environ): Delete function.
7721 (gdb_environ::unset): New function.
7722 (gdb_environ::envp): Likewise.
7723 * common/environ.h: Include <vector>.
7724 (struct gdb_environ): Delete; transform into...
7725 (class gdb_environ): ... this class.
7726 (free_environ): Delete prototype.
7727 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
7728 environ_vector): Likewise.
7729 * infcmd.c (run_command_1): Update code to call
7730 'envp' from 'gdb_environ' class.
7731 (environment_info): Update code to call methods from 'gdb_environ'
7732 class.
7733 (unset_environment_command): Likewise.
7734 (path_info): Likewise.
7735 (path_command): Likewise.
7736 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
7737 (inferior::inferior): Initialize 'environment' using the host's
7738 information.
7739 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
7740 Include "environ.h".
7741 (class inferior) <environment>: Change type from 'struct
7742 gdb_environ' to 'gdb_environ'.
7743 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
7744 methods from 'gdb_environ' class.
7745 * solib.c (solib_find_1): Likewise
7746 * unittests/environ-selftests.c: New file.
7747
75c554cf
YQ
77482017-06-20 Yao Qi <yao.qi@linaro.org>
7749
7750 * features/i386/i386-linux.xml: Exchange the order of including
7751 32bit-linux.xml and 32bit-sse.xml.
7752 * features/i386/i386-linux.c: Regenerated.
7753
72ddacb7
YQ
77542017-06-20 Yao Qi <yao.qi@linaro.org>
7755
7756 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
7757 Delete copy ctor and assignment operator.
7758 (tdesc_type): Likewise.
7759 (tdesc_feature): Likewise.
7760 (tdesc_free_reg): Remove.
7761 (tdesc_create_reg): Use new.
7762 (tdesc_free_type): Remove.
7763 (tdesc_create_vector): Use new.
7764 (tdesc_create_union): Likewise.
7765 (tdesc_create_flags): Likewise.
7766 (tdesc_create_enum): Likewise.
7767 (tdesc_free_feature): Delete.
7768 (free_target_description): Use delete.
7769
325c9fd4
JB
77702017-06-19 John Baldwin <jhb@FreeBSD.org>
7771
7772 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
7773 registers.
7774
16b7a719
PA
77752017-06-19 Pedro Alves <palves@redhat.com>
7776
7777 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
7778 after gdb::unlinker.
7779
1c8e01c9
SDJ
77802017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
7781
7782 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
7783 gdb_environ to access an environment variable.
7784
ffce45d2
TP
77852017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
7786
7787 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
7788 gdb_byte*.
7789
1d4fbac9
SM
77902017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7791
7792 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
7793
8465943a
SM
77942017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7795
7796 * configure: Re-generate.
7797 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
7798
3e019bdc
SM
77992017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7800
7801 * configure: Re-generate.
7802 * warning.m4: Pass -Werror to compiler when checking for
7803 supported warning flags.
7804
cf0dd6f0
SM
78052017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7806
7807 * Makefile.in (COMPILE.pre): Add "-x c++".
7808
6f98355c
YQ
78092017-06-16 Alan Hayward <alan.hayward@arm.com>
7810 Pedro Alves <palves@redhat.com>
7811 Yao Qi <yao.qi@linaro.org>
7812
7813 * defs.h (RequireLongest): New.
7814 (extract_integer): Declare function template.
7815 (extract_signed_integer): Remove the declaration, but define it
7816 static inline.
7817 (extract_unsigned_integer): Likewise.
7818 (store_integer): Declare function template.
7819 (store_signed_integer): Remove the declaration, but define it
7820 static inline.
7821 (store_unsigned_integer): Likewise.
7822 * findvar.c (extract_integer): New function template.
7823 (extract_signed_integer): Remove.
7824 (extract_unsigned_integer): Remove.
7825 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
7826 instantiations.
7827 (store_integer): New function template.
7828 (store_signed_integer): Remove.
7829 (store_unsigned_integer): Remove.
7830 (store_integer): Explicit instantiations.
7831 * regcache.c (regcache_raw_read_signed): Update.
7832 (regcache::raw_read): New function.
7833 (regcache::raw_read_signed): Remove.
7834 (regcache::raw_read_unsigned): Remove.
7835 (regcache_raw_read_unsigned): Update.
7836 (regcache_raw_write_unsigned): Update.
7837 (regcache::raw_write_signed): Remove.
7838 (regcache::raw_write): New function.
7839 (regcache_cooked_read_signed): Update.
7840 (regcache::raw_write_unsigned): Remove.
7841 (regcache::cooked_read_signed): Remove.
7842 (regcache_cooked_read_unsigned): Update.
7843 (regcache::cooked_read_unsigned): Remove.
7844 (regcache_cooked_write_signed): Update.
7845 (regcache_cooked_write_unsigned): Update.
7846 * regcache.h (regcache) <raw_read_signed>: Remove.
7847 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
7848 <raw_read, raw_write>: New.
7849 <cooked_read_signed, cooked_write_signed>: Remove.
7850 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
7851 <cooked_read, cooked_write>: New.
7852 * sh64-tdep.c (sh64_pseudo_register_read): Update.
7853 (sh64_pseudo_register_write): Update.
7854
a87dc45a
AK
78552017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
7856
7857 * arc-tdep.c (arc_disassembler_options): New variable.
7858 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
7859 of default_print_insn.
7860 (arc_delayed_print_insn): Set info->section when needed,
7861 use default_print_insn to retrieve a disassembler.
7862
45159d6a
SDJ
78632017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
7864
7865 PR gdb/21574
7866 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
7867 to mention $SHELL and startup-with-shell.
7868
b46c4cf0
MF
78692017-06-14 Max Filippov <jcmvbkbc@gmail.com>
7870
7871 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
7872
6394c606
YQ
78732017-06-14 Yao Qi <yao.qi@linaro.org>
7874
7875 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
7876 default_print_insn instead of print_insn_aarch64.
7877 * arm-tdep.c (gdb_print_insn_arm): Call
7878 default_print_insn instead of print_insn_big_arm
7879 and print_insn_little_arm.
7880 * i386-tdep.c (i386_print_insn): Call default_print_insn
7881 instead of print_insn_i386.
7882 * ia64-tdep.c (ia64_print_insn): Call
7883 default_print_insn instead of print_insn_ia64.
7884 * mips-tdep.c (gdb_print_insn_mips): Call
7885 default_print_insn instead of print_insn_big_mips
7886 and print_insn_little_mips.
7887 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
7888 instead of print_insn_spu.
7889
d5722aa2
PA
78902017-06-14 Pedro Alves <palves@redhat.com>
7891
7892 * ada-lang.c: Include "common/byte-vector.h".
7893 (ada_value_primitive_packed_val): Use gdb::byte_vector.
7894 * charset.c (wchar_iterator::iterate): Resize the vector instead
7895 of reserving it.
7896 * common/byte-vector.h: Include "common/def-vector.h".
7897 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
7898 * cli/cli-dump.c: Include "common/byte-vector.h".
7899 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
7900 * common/byte-vector.h: New file.
7901 * common/def-vector.h: New file.
7902 * common/default-init-alloc.h: New file.
7903 * dwarf2loc.c: Include "common/byte-vector.h".
7904 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
7905 instead of reserving it.
7906 * dwarf2read.c: Include "common/byte-vector.h".
7907 (data_buf::m_vec): Now a gdb::byte_vector.
7908 * gdb_regex.c: Include "common/def-vector.h".
7909 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
7910 * mi/mi-main.c: Include "common/byte-vector.h".
7911 (mi_cmd_data_read_memory): Use gdb::byte_vector.
7912 * printcmd.c: Include "common/byte-vector.h".
7913 (print_scalar_formatted): Use gdb::byte_vector.
7914 * valprint.c: Include "common/byte-vector.h".
7915 (maybe_negate_by_bytes, print_decimal_chars): Use
7916 gdb::byte_vector.
7917
01ec7a27
SM
79182017-06-13 Simon Marchi <simon.marchi@ericsson.com>
7919
7920 * darwin-nat.c: Include "nat/fork-inferior.h".
7921
848d9074
SM
79222017-06-13 Simon Marchi <simon.marchi@ericsson.com>
7923
7924 * configure.nat: Factor out Darwin bits that are not
7925 architecture-specific. Add fork-inferior.o.
7926
3b912944
SM
79272017-06-13 Simon Marchi <simon.marchi@ericsson.com>
7928
7929 * configure.nat: Factor out AIX bits that are not
7930 architecture-specific. Add fork-inferior.o.
7931
55acdf22
AA
79322017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7933
7934 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
7935 (read_pieced_value, write_pieced_value): ...here. Reduce to
7936 wrappers that just call rw_pieced_value.
7937
f65e2044
AA
79382017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7939
7940 * dwarf2loc.c (write_pieced_value): When writing the data for a
7941 memory piece, use write_memory_with_notification instead of
7942 write_memory.
7943
23f945bf
AA
79442017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7945
7946 * valops.c (read_value_memory): Change embedded_offset to
7947 represent a bit offset instead of a byte offset.
7948 * value.h (read_value_memory): Adjust comment.
7949
f236533e
AA
79502017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7951
7952 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
7953 dest_offset_bits and source_offset_bits.
7954 (write_pieced_value): Likewise.
7955
65d84b76
AA
79562017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7957
7958 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
7959 given by DW_OP_bit_piece.
7960 (write_pieced_value): Likewise.
7961
242d31ab
AA
79622017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7963
7964 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
7965 some other preparations to the places where sufficient information
7966 is available.
7967 (write_pieced_value): Likewise.
7968
03c8af18
AA
79692017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7970
7971 * dwarf2loc.c (bits_to_bytes): New function.
7972 (read_pieced_value): Fix offset calculations for register pieces
7973 on big-endian targets.
7974 (write_pieced_value): Likewise.
7975
840989c1
AA
79762017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7977
7978 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
7979 (write_pieced_value): Likewise.
7980
359b19bb
AA
79812017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7982
7983 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
7984 transfer the source value's least significant bits, instead of its
7985 lowest-addressed ones. Rename type_len to max_offset.
7986 (read_pieced_value): Mirror above changes to write_pieced_value as
7987 applicable.
7988
07c9ca3b
AA
79892017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7990
7991 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
7992 truncate full bytes from dest_offset_bits before using it as an
7993 offset into the buffer.
7994
f1cc9874
AA
79952017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7996
7997 * dwarf2loc.c (write_pieced_value): Include transfer size in
7998 byte-wise check.
7999
cdaac320
AA
80002017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
8001
8002 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
8003 calculation of this_size.
8004
af547a96
AA
80052017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
8006
8007 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
8008 when targeting a bit-field.
8009 (write_pieced_value): Likewise.
8010
ddd7882a
AA
80112017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
8012
8013 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
8014 (allocate_piece_closure): Drop addr_size parameter.
8015 (dwarf2_evaluate_loc_desc_full): Adjust call to
8016 allocate_piece_closure.
8017
e9352324
AA
80182017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
8019
8020 PR gdb/21226
8021 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
8022 the LSB end, independent of endianness.
8023
d5d1163e
AA
80242017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
8025
8026 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
8027 size capping.
8028
032bb6ea
YQ
80292017-06-13 Yao Qi <yao.qi@linaro.org>
8030
8031 * mips-linux-nat.c: Move include features/mips*-linux.c to
8032 mips-linux-tdep.c.
8033 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
8034 to mips-linux-tdep.c.
8035 * mips-linux-tdep.c: Include features/mips*-linux.c
8036 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
8037 functions.
8038 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
8039 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
8040 (tdesc_mips64_dsp_linux): Declare.
8041
f12f6bad
TT
80422017-06-12 Tom Tromey <tom@tromey.com>
8043
8044 * valprint.h (val_print_type_code_int): Remove.
8045 * valprint.c (generic_val_print_int): Always call
8046 val_print_scalar_formatted.
8047 (val_print_type_code_int): Remove.
8048 * printcmd.c (print_scalar_formatted): Handle options->format==0.
8049 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
8050 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
8051 * ada-valprint.c (ada_val_print_num): Use
8052 val_print_scalar_formatted.
8053
d9109c80
TT
80542017-06-12 Tom Tromey <tom@tromey.com>
8055
8056 * printcmd.c (print_scalar_formatted): Unify the two switches.
8057 Don't convert scalars to LONGEST.
8058
4ac0cb1c
TT
80592017-06-12 Tom Tromey <tom@tromey.com>
8060
8061 PR exp/16225:
8062 * valprint.h (print_decimal_chars): Update.
8063 * valprint.c (maybe_negate_by_bytes): New function.
8064 (print_decimal_chars): Add "is_signed" argument.
8065 * printcmd.c (print_scalar_formatted): Update.
8066
30a25466
TT
80672017-06-12 Tom Tromey <tom@tromey.com>
8068
8069 PR exp/16225:
8070 * valprint.h (print_binary_chars, print_hex_chars): Update.
8071 * valprint.c (val_print_type_code_int): Update.
8072 (print_binary_chars): Add "zero_pad" argument.
8073 (emit_octal_digit): New function.
8074 (print_octal_chars): Don't zero-pad.
8075 (print_decimal_chars): Likewise.
8076 (print_hex_chars): Add "zero_pad" argument.
8077 * sh64-tdep.c (sh64_do_fp_register): Update.
8078 * regcache.c (regcache::dump): Update.
8079 * printcmd.c (print_scalar_formatted): Update.
8080 * infcmd.c (default_print_one_register_info): Update.
8081
b3464d03
PA
80822017-06-12 Pedro Alves <palves@redhat.com>
8083 Alan Hayward <alan.hayward@arm.com>
8084
8085 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
8086 (mips_eabi_push_dummy_call): Rename local 'regsize' to
8087 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
8088 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
8089 Assert that abi_regsize bytes fit in 'ref_valbuf'.
8090
4b76cda9
PA
80912017-06-12 Pedro Alves <palves@redhat.com>
8092
8093 * dwarf2read.c (mapped_symtab::data): Now a vector of
8094 symtab_index_entry instead of vector of
8095 std::unique_ptr<symtab_index_entry>. All users adjusted to check
8096 whether an element's name is NULL instead of checking whether the
8097 element itself is NULL.
8098 (find_slot): Change return type. Adjust.
8099 (hash_expand, , add_index_entry, uniquify_cu_indices)
8100 (write_hash_table): Adjust.
8101
e8f8bcb3
PA
81022017-06-12 Pedro Alves <palves@redhat.com>
8103
8104 * dwarf2read.c (recursively_count_psymbols): New function.
8105 (write_psymtabs_to_index): Call it to compute number of psyms and
8106 pass estimate size of psyms_seen to unordered_set's ctor.
8107
70a1152b
PA
81082017-06-12 Pedro Alves <palves@redhat.com>
8109
8110 * dwarf2read.c (write_hash_table): Check if key already exists
8111 before emplacing.
8112
c2f134ac
PA
81132017-06-12 Pedro Alves <palves@redhat.com>
8114
8115 * dwarf2read.c (data_buf::append_space): Rename to...
8116 (data_buf::grow): ... this, and make private. Adjust all callers.
8117 (data_buf::append_uint): New method.
8118 (add_address_entry, write_one_signatured_type)
8119 (write_psymtabs_to_index): Use it.
8120
a81e6d4d
PA
81212017-06-12 Pedro Alves <palves@redhat.com>
8122
8123 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
8124 (file_write (FILE *, const std::vector<Elem>&)): Delete.
8125 (data_buf::file_write): Call ::fwrite directly.
8126
6fd931f2
PA
81272017-06-12 Pedro Alves <palves@redhat.com>
8128
8129 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
8130 std::vector::erase.
8131
bc8f2430
JK
81322017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
8133
8134 Code cleanup: C++ify .gdb_index producer.
8135 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
8136 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
8137 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
8138 (create_strtab, add_string): Remove.
8139 (file_write, data_buf): New.
8140 (struct symtab_index_entry): Use std::vector for cu_indices.
8141 (struct mapped_symtab): Use std::vector for data.
8142 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
8143 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
8144 Remove.
8145 (find_slot): Change return type. Update it to the new data structures.
8146 (hash_expand, add_index_entry): Update it to the new data structures.
8147 (offset_type_compare): Remove.
8148 (uniquify_cu_indices): Update it to the new data structures.
8149 (c_str_view, c_str_view_hasher, vector_hasher): New.
8150 (add_indices_to_cpool): Remove.
8151 (write_hash_table): Update it to the new data structures.
8152 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
8153 (eq_psymtab_cu_index): Remove.
8154 (psym_index_map): New typedef.
8155 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
8156 reference and std::unordered_map for cu_index_htab.
8157 (add_address_entry, add_address_entry_worker, write_address_map)
8158 (write_psymbols): Update it to the new data structures.
8159 (write_obstack): Remove.
8160 (struct signatured_type_index_data): Change types_list to a data_buf
8161 reference and psyms_seen to a std::unordered_set reference.
8162 (write_one_signatured_type, recursively_write_psymbols)
8163 (write_psymtabs_to_index): Update it to the new data structures.
8164
c4dcb155
SM
81652017-06-11 Simon Marchi <simon.marchi@ericsson.com>
8166
8167 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
8168 separate-debug-file commands.
8169 * symfile.h (separate_debug_file_debug): New global.
8170 * symfile.c (separate_debug_file_debug): New global.
8171 (separate_debug_file_exists, find_separate_debug_file): Add
8172 debug output.
8173 (_initialize_symfile): Add "set debug separate-debug-file"
8174 command.
8175 * build-id.c (build_id_to_debug_bfd,
8176 find_separate_debug_file_by_buildid): Add debug output.
8177
6d45d4b4
SM
81782017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
8179
8180 * gdbarch.sh (displaced_step_free_closure): Remove.
8181 * gdbarch.h, gdbarch.c: Re-generate.
8182 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
8183 displaced_step_free_closure.
8184 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
8185 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
8186 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
8187 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
8188 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
8189 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
8190 * arch-utils.h (simple_displaced_step_free_closure): Remove.
8191 * arch-utils.c (simple_displaced_step_free_closure): Remove.
8192 * infrun.c (displaced_step_clear): Call xfree instead of
8193 gdbarch_displaced_step_free_closure.
8194
2f91880f
SDJ
81952017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
8196
8197 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
8198 NULL".
8199
b8b6e72f
AH
82002017-06-08 Alan Hayward <alan.hayward@arm.com>
8201
8202 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
8203 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
8204 (mn10300_push_dummy_call): Likewise.
8205
5369082e
AH
82062017-06-08 Alan Hayward <alan.hayward@arm.com>
8207
8208 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
8209
ff4ca5ac
AH
82102017-06-08 Alan Hayward <alan.hayward@arm.com>
8211
8212 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
8213
aefd8b33
SDJ
82142017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
8215
8216 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
8217 able to start inferiors using a shell.
8218 (New remote packets): Announce new packet "QStartupWithShell".
8219 * remote.c: Add PACKET_QStartupWithShell.
8220 (extended_remote_create_inferior): Handle new
8221 PACKET_QStartupWithShell.
8222 (remote_protocol_features) <QStartupWithShell>: New entry for
8223 PACKET_QStartupWithShell.
8224 (_initialize_remote): Call "add_packet_config_cmd" for
8225 QStartupShell.
8226
2090129c
SDJ
82272017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
8228 Pedro Alves <palves@redhat.com>
8229
8230 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
8231 and "nat/fork-inferior.h".
8232 * common/common-inferior.h: New file, with contents from
8233 "gdb/inferior.h".
8234 * commom/common-utils.c: Include "common-utils.h".
8235 (stringify_argv): New function.
8236 * common/common-utils.h (stringify_argv): New prototype.
8237 * configure.nat: Add "fork-inferior.o" as a dependency for
8238 "*linux*", "fbsd*" and "nbsd*" hosts.
8239 * corefile.c (get_exec_file): Update comment.
8240 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
8241 instead of "startup_inferior".
8242 (darwin_create_inferior): Call "add_thread_silent" after
8243 "fork_inferior".
8244 * fork-child.c: Cleanup unnecessary includes.
8245 (SHELL_FILE): Move to "common/common-fork-child.c".
8246 (environ): Likewise.
8247 (exec_wrapper): Initialize.
8248 (get_exec_wrapper): New function.
8249 (breakup_args): Move to "common/common-fork-child.c"; rename to
8250 "breakup_args_for_exec".
8251 (escape_bang_in_quoted_argument): Move to
8252 "common/common-fork-child.c".
8253 (saved_ui): New variable.
8254 (prefork_hook): New function.
8255 (postfork_hook): Likewise.
8256 (postfork_child_hook): Likewise.
8257 (gdb_startup_inferior): Likewise.
8258 (fork_inferior): Move to "common/common-fork-child.c". Update
8259 function to support gdbserver.
8260 (startup_inferior): Likewise.
8261 * gdbcore.h (get_exec_file): Remove declaration.
8262 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
8263 instead of "startup_inferior". Call "add_thread_silent" after
8264 "fork_inferior".
8265 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
8266 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
8267 instead of "startup_inferior". Call "add_thread_silent" after
8268 "fork_inferior".
8269 * inferior.h: Include "common-inferior.h".
8270 (trace_start_error): Move to "common/common-utils.h".
8271 (trace_start_error_with_name): Likewise.
8272 (fork_inferior): Move prototype to "nat/fork-inferior.h".
8273 (startup_inferior): Likewise.
8274 (gdb_startup_inferior): New prototype.
8275 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
8276 * nat/fork-inferior.h: New file.
8277 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
8278 instead of "startup_inferior". Call "add_thread_silent" after
8279 "fork_inferior".
8280 * target.h (target_terminal_init): Move prototype to
8281 "target/target.h".
8282 (target_terminal_inferior): Likewise.
8283 (target_terminal_ours): Likewise.
8284 * target/target.h (target_terminal_init): New prototype, moved
8285 from "target.h".
8286 (target_terminal_inferior): Likewise.
8287 (target_terminal_ours): Likewise.
8288 * utils.c (gdb_flush_out_err): New function.
8289
043a4934
SDJ
82902017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
8291
8292 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
8293 * common/common-gdbthread.h: New file, with parts from
8294 "gdb/gdbthread.h".
8295 * gdbthread.h: Include "common-gdbthread.h".
8296 (switch_to_thread): Moved to "common/common-gdbthread.h".
8297
15652511
SDJ
82982017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
8299
8300 * Makefile.in (SFILES): Add "common/job-control.c".
8301 (HFILES_NO_SRCDIR): Add "common/job-control.h".
8302 (COMMON_OBS): Add "job-control.o".
8303 * common/job-control.c: New file, with contents from
8304 "gdb/inflow.c".
8305 * common/job-control.h: New file, with contents from "terminal.h".
8306 * fork-child.c: Include "job-control.h".
8307 * inflow.c: Include "job-control.h".
8308 (gdb_setpgid): Move to "common/common-inflow.c".
8309 (_initialize_inflow): Move setting of "job_control" to
8310 "handle_job_control".
8311 * terminal.h (job_control): Moved to "common/common-terminal.h".
8312 (gdb_setpgid): Likewise.
8313 * top.c: Include "job_control.h".
8314 * utils.c: Likewise.
8315 (job_control): Moved to "job-control.c".
8316
2d7cc5c7
PA
83172017-06-07 Pedro Alves <palves@redhat.com>
8318
8319 * Makefile.in (SFILES): Add gdb_regex.c.
8320 (COMMON_OBS): Add gdb_regex.o.
8321 * ada-lang.c (ada_add_standard_exceptions)
8322 (ada_add_exceptions_from_frame, name_matches_regex)
8323 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
8324 parameter type to compiled_regex. Adjust.
8325 (ada_exceptions_list): Use compiled_regex.
8326 * break-catch-throw.c (exception_catchpoint::pattern): Now a
8327 std::unique_ptr<compiled_regex>.
8328 (exception_catchpoint::~exception_catchpoint): Remove regfree
8329 call.
8330 (check_status_exception_catchpoint): Adjust to use compiled_regex.
8331 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
8332 * breakpoint.c (solib_catchpoint::compiled): Now a
8333 std::unique_ptr<compiled_regex>.
8334 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
8335 (check_status_catch_solib): Adjust to use compiled_regex.
8336 (add_solib_catchpoint): Adjust to use compiled_regex.
8337 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
8338 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
8339 compiled_regex reference. Adjust to use it.
8340 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
8341 declaration. Include "gdb_regex.h".
8342 (apropos_cmd): Change regex parameter to compiled_regex reference.
8343 * gdb_regex.c: New file.
8344 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
8345 declarations.
8346 (class compiled_regex): New.
8347 * linux-tdep.c: Include "common/gdb_optional.h".
8348 (struct mapping_regexes): New, factored out from
8349 mapping_is_anonymous_p, and adjusted to use compiled_regex.
8350 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
8351 gdb::optional and remove cleanups. Adjust to compiled_regex.
8352 * probe.c: Include "common/gdb_optional.h".
8353 (collect_probes): Use compiled_regex and gdb::optional and remove
8354 cleanups.
8355 * skip.c: Include "common/gdb_optional.h".
8356 (skiplist_entry::compiled_function_regexp): Now a
8357 gdb::optional<compiled_regex>.
8358 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
8359 (free_skiplist_entry): Remove regfree call.
8360 (compile_skip_regexp, skip_rfunction_p): Adjust to use
8361 compiled_regex and gdb::optional.
8362 * symtab.c: Include "common/gdb_optional.h".
8363 (search_symbols): Use compiled_regex and gdb::optional.
8364 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
8365 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
8366 to gdb_regex.c.
8367
50d6adef
AH
83682017-06-07 Alan Hayward <alan.hayward@arm.com>
8369
8370 * regcache.c (regcache::save): Avoid buffer use.
8371 (regcache::dump): Likewise.
8372
4a8a33c8
AH
83732017-06-07 Alan Hayward <alan.hayward@arm.com>
8374
8375 * sh-tdep.c (sh_pseudo_register_read): Remove
8376 MAX_REGISTER_SIZE.
8377 (sh_pseudo_register_write): Likewise.
8378 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
8379 (sh64_pseudo_register_write): Likewise
8380
d1be909e
AH
83812017-06-07 Alan Hayward <alan.hayward@arm.com>
8382
8383 * aarch64-tdep.c (aarch64_store_return_value): Use
8384 V_REGISTER_SIZE.
8385 (aarch64_pseudo_read_value): Likewise.
8386 (aarch64_pseudo_write): Likewise.
8387
f4a65042
YQ
83882017-06-06 Yao Qi <yao.qi@linaro.org>
8389
8390 * regformats/regdef.h (set_register_cache): Remove the
8391 declaration.
8392
9f7fb0aa
AH
83932017-06-06 Alan Hayward <alan.hayward@arm.com>
8394
8395 * frame.c (frame_unwind_register_signed): Use
8396 frame_unwind_register_value.
8397
e1e01040
PA
83982017-06-06 Pedro Alves <palves@redhat.com>
8399
8400 PR breakpoints/21553
8401 * breakpoint.c (create_breakpoints_sal_default)
8402 (init_breakpoint_sal, create_breakpoint_sal): Use
8403 gdb::unique_xmalloc_ptr for string parameters.
8404 (create_breakpoint): Constify 'extra_string' and 'cond_string'
8405 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
8406 (base_breakpoint_create_breakpoints_sal)
8407 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
8408 (strace_marker_create_breakpoints_sal)
8409 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
8410 string parameters.
8411 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
8412 gdb::unique_xmalloc_ptr for string parameters.
8413 (create_breakpoint): Constify 'extra_string' and 'cond_string'
8414 parameters.
8415
fbe654c8
AH
84162017-06-06 Alan Hayward <alan.hayward@arm.com>
8417
8418 * alpha-tdep.c (alpha_register_to_value): Use
8419 get_frame_register_value.
8420 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
8421
ae0d01d6
AH
84222017-06-06 Alan Hayward <alan.hayward@arm.com>
8423
8424 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
8425 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
8426 (ia64_value_to_register): Likewise.
8427 (ia64_extract_return_value): Likewise.
8428 (ia64_store_return_value): Likewise.
8429 (ia64_push_dummy_call): Likewise.
8430
49cf576c
JB
84312017-06-04 Joel Brobecker <brobecker@adacore.com>
8432
8433 GDB 8.0 released.
8434
26b6a6ab
SM
84352017-06-03 Simon Marchi <simon.marchi@ericsson.com>
8436
8437 * x86-linux-nat.c (struct arch_lwp_info): Remove.
8438
22827c51
SM
84392017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
8440
8441 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
8442 parameter.
8443 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
8444
0e05cf3a
SM
84452017-06-02 Simon Marchi <simon.marchi@ericsson.com>
8446
8447 * event-loop.c (poll_timers): Unallocate timer using delete
8448 instead of xfree.
8449
c1fc2657
SM
84502017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
8451
8452 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
8453 (struct breakpoint) <~breakpoint>: New.
8454 (struct watchpoint): Inherit from breakpoint.
8455 <~watchpoint>: New.
8456 <base>: Remove.
8457 (struct tracepoint): Inherit from breakpoint.
8458 <base>: Remove.
8459 * breakpoint.c (longjmp_breakpoint_ops): Remove.
8460 (struct longjmp_breakpoint): Inherit from breakpoint.
8461 <~longjmp_breakpoint>: New.
8462 <base>: Remove.
8463 (new_breakpoint_from_type): Remove casts.
8464 (watchpoint_in_thread_scope): Remove reference to base field.
8465 (watchpoint_del_at_next_stop): Likewise.
8466 (update_watchpoint): Likewise.
8467 (watchpoint_check): Likewise.
8468 (bpstat_check_watchpoint): Likewise.
8469 (set_longjmp_breakpoint): Likewise.
8470 (struct fork_catchpoint): Inherit from breakpoint.
8471 <base>: Remove.
8472 (struct solib_catchpoint): Inherit from breakpoint.
8473 <~solib_catchpoint>: New.
8474 <base>: Remove.
8475 (dtor_catch_solib): Change to ...
8476 (solib_catchpoint::~solib_catchpoint): ... this.
8477 (breakpoint_hit_catch_solib): Remove reference to base field.
8478 (add_solib_catchpoint): Likewise.
8479 (create_fork_vfork_event_catchpoint): Likewise.
8480 (struct exec_catchpoint): Inherit from breakpoint.
8481 <~exec_catchpoint>: New.
8482 <base>: Remove.
8483 (dtor_catch_exec): Change to ...
8484 (exec_catchpoint::~exec_catchpoint): ... this.
8485 (dtor_watchpoint): Change to ...
8486 (watchpoint::~watchpoint): ... this.
8487 (watch_command_1): Remove reference to base field.
8488 (catch_exec_command_1): Likewise.
8489 (base_breakpoint_dtor): Change to ...
8490 (breakpoint::~breakpoint): ... this.
8491 (base_breakpoint_ops): Remove dtor field value.
8492 (longjmp_bkpt_dtor): Change to ...
8493 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
8494 (strace_marker_create_breakpoints_sal): Remove reference to base
8495 field.
8496 (delete_breakpoint): Don't manually call breakpoint destructor.
8497 (create_tracepoint_from_upload): Remove reference to base field.
8498 (trace_pass_set_count): Likewise.
8499 (initialize_breakpoint_ops): Don't initialize
8500 momentary_breakpoint_ops, don't set dtors.
8501 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
8502 <~ada_catchpoint>: New.
8503 <base>: Remove.
8504 (create_excep_cond_exprs): Remove reference to base field.
8505 (dtor_exception): Change to ...
8506 (ada_catchpoint::~ada_catchpoint): ... this.
8507 (dtor_catch_exception): Remove.
8508 (dtor_catch_exception_unhandled): Remove.
8509 (dtor_catch_assert): Remove.
8510 (create_ada_exception_catchpoint): Remove reference to base
8511 field.
8512 (initialize_ada_catchpoint_ops): Don't set dtors.
8513 * break-catch-sig.c (struct signal_catchpoint): Inherit from
8514 breakpoint.
8515 <~signal_catchpoint>: New.
8516 <base>: Remove.
8517 (signal_catchpoint_dtor): Change to ...
8518 (signal_catchpoint::~signal_catchpoint): ... this.
8519 (create_signal_catchpoint): Remove reference to base field.
8520 (initialize_signal_catchpoint_ops): Don't set dtor.
8521 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
8522 from breakpoint.
8523 <~syscall_catchpoint>: New.
8524 <base>: Remove.
8525 (dtor_catch_syscall): Change to ...
8526 (syscall_catchpoint::~syscall_catchpoint): ... this.
8527 (create_syscall_event_catchpoint): Remove reference to base
8528 field.
8529 (initialize_syscall_catchpoint_ops): Don't set dtor.
8530 * break-catch-throw.c (struct exception_catchpoint): Inherit
8531 from breakpoint.
8532 <~exception_catchpoint>: New.
8533 <base>: Remove.
8534 (dtor_exception_catchpoint): Change to ...
8535 (exception_catchpoint::~exception_catchpoint): ... this.
8536 (handle_gnu_v3_exceptions): Remove reference to base field.
8537 (initialize_throw_catchpoint_ops): Don't set dtor.
8538 * ctf.c (ctf_get_traceframe_address): Remove reference to base
8539 field.
8540 * remote.c (remote_get_tracepoint_status): Likewise.
8541 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
8542 * tracefile.c (tracefile_fetch_registers): Likewise.
8543 * tracepoint.c (actions_command): Likewise.
8544 (validate_actionline): Likewise.
8545 (tfind_1): Likewise.
8546 (get_traceframe_location): Likewise.
8547 (find_matching_tracepoint_location): Likewise.
8548 (parse_tracepoint_status): Likewise.
8549 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
8550
3b0871f4
SM
85512017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
8552
8553 * breakpoint.c (struct longjmp_breakpoint): New struct.
8554 (is_tracepoint_type): Change return type to bool.
8555 (is_longjmp_type): New function.
8556 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
8557 (set_raw_breakpoint_without_location): Use
8558 new_breakpoint_from_type.
8559 (set_raw_breakpoint): Likewise.
8560
a5e364af
SM
85612017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
8562
8563 * breakpoint.c (new_breakpoint_from_type): New function.
8564 (create_breakpoint_sal): Use new_breakpoint_from_type and
8565 unique_ptr.
8566 (create_breakpoint): Likewise.
8567
ae3b3f34
SM
85682017-05-31 Simon Marchi <simon.marchi@ericsson.com>
8569
8570 * memattr.c (mem_info_command): Rename to ...
8571 (info_mem_command): ... this.
8572 (mem_enable_command): Rename to ...
8573 (enable_mem_command): ... this.
8574 (mem_disable_command): Rename to ...
8575 (disable_mem_command): ... this.
8576 (mem_delete_command): Rename to ...
8577 (delete_mem_command): ... this.
8578 (_initialize_mem): Adjust function names.
8579
13ace077
MM
85802017-05-31 Markus Metzger <markus.t.metzger@intel.com>
8581
8582 * btrace.c (handle_pt_insn_events): New.
8583 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
8584 STATUS. Split into this and ...
8585 (handle_pt_insn_event_flags): ... this.
8586
c56ccc05
MM
85872017-05-31 Markus Metzger <markus.t.metzger@intel.com>
8588
8589 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
8590 and struct pt_insn.resynced.
8591 * configure: Regenerated.
8592 * config.in: Regenerated.
8593
08c3f6d2
TW
85942017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8595
8596 * btrace.c (ftrace_find_call_by_number): New function.
8597 (ftrace_new_function): Store objects, not pointers.
8598 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
8599 ftrace_new_gap, ftrace_update_function,
8600 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
8601 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
8602 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
8603 btrace_ends_with_single_insn, btrace_call_get): Account for
8604 btrace_thread_info::functions now storing objects.
8605 * btrace.h (struct btrace_thread_info): Add constructor.
8606 (struct btrace_thread_info) <functions>: Make std::vector.
8607 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
8608 Initialize with default values.
8609 * record-btrace.c (record_btrace_frame_sniffer): Account for
8610 btrace_thread_info::functions now storing objects.
8611
8ffd39f2
TW
86122017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8613
8614 * btrace.c: Remove typedef bfun_s.
8615 (ftrace_new_gap): Directly add gaps to the list of gaps.
8616 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
8617 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
8618 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
8619 instead of gdb VEC.
8620
4aeb0dfc
TW
86212017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8622
8623 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
8624 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
8625 with btrace_thread_info::next_segment and
8626 btrace_thread_info::prev_segment.
8627 * btrace.h: Remove struct btrace_func_link.
8628 (struct btrace_function): Replace pair of function segment pointers
8629 with pair of indices.
8630 * python/py-record-btrace.c (btpy_call_prev_sibling,
8631 btpy_call_next_sibling): Replace references to
8632 btrace_thread_info::segment with btrace_thread_info::next_segment and
8633 btrace_thread_info::prev_segment.
8634 * record-btrace.c (record_btrace_frame_this_id): Use
8635 btrace_find_call_by_number.
8636
eb8f2b9c
TW
86372017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8638
8639 * btrace.c (ftrace_new_function, ftrace_fixup_level,
8640 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
8641 btrace_insn_next, btrace_insn_prev): Remove references to
8642 btrace_thread_info::flow.
8643 * btrace.h (struct btrace_function): Remove FLOW.
8644
42bfe59e
TW
86452017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8646
8647 * btrace.c (ftrace_find_call_by_number): New function.
8648 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
8649 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
8650 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
8651 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
8652 index.
8653 * btrace.h (struct btrace_function): Turn UP into an index.
8654 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
8655 as an index.
8656 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
8657 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
8658 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
8659
b54b03bd
TW
86602017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8661
8662 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
8663 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
8664 ftrace_update_function, ftrace_compute_global_level_offset,
8665 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
8666 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
8667 btrace_insn_end, btrace_is_empty): Remove references to
8668 btrace_thread_info::begin and btrace_thread_info::end.
8669 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
8670 (struct btrace_thread_info) <functions>: Adjust comment.
8671 * record-btrace.c (record_btrace_start_replaying): Remove reference to
8672 btrace_thread_info::begin.
8673
8286623c
TW
86742017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8675
8676 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
8677 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
8678 ftrace_update_function): Remove arguments that implicitly were always
8679 BTINFO->END.
8680 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
8681 Don't pass BTINFO->END.
8682
a0f1b963
TW
86832017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8684
8685 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
8686 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
8687 btrace_find_insn_by_number): Replace function segment pointer with
8688 index.
8689 (btrace_insn_cmp): Simplify.
8690 * btrace.h: (struct btrace_insn_iterator) Rename index to
8691 insn_index. Replace function segment pointer with index into function
8692 segment vector.
8693 * record-btrace.c (record_btrace_call_history): Replace function
8694 segment pointer use with index.
8695 (record_btrace_frame_sniffer): Retrieve function call segment through
8696 vector.
8697 (record_btrace_set_replay): Remove defunc't safety check.
8698
f158f208
TW
86992017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8700
8701 * btrace.c (btrace_ends_with_single_insn): New function.
8702 (btrace_call_get, btrace_call_number, btrace_call_begin,
8703 btrace_call_end, btrace_call_next, btrace_call_prev,
8704 btrace_find_call_by_number): Use index into call segment vector
8705 instead of pointer.
8706 (btrace_call_cmp): Simplify.
8707 * btrace.h (struct btrace_call_iterator): Replace function call segment
8708 pointer with index into vector.
8709 * record-btrace.c (record_btrace_call_history): Use index instead of
8710 pointer.
8711
521103fd
TW
87122017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8713
8714 * btrace.c (btrace_insn_begin, btrace_insn_end,
8715 btrace_find_insn_by_number): Add btinfo to iterator.
8716 * btrace.h (struct btrace_insn_iterator): Add btinfo.
8717
17b89b34
TW
87182017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8719
8720 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
8721 and save pointers directly.
8722 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
8723 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
8724 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
8725 changed signature of functions.
8726 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
8727 (btrace_fetch): Remove code that adds btrace_function pointers to
8728 vector of btrace_functions.
8729 (btrace_clear): Simplify freeing vector of btrace_functions.
8730
2b51eddc
TW
87312017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8732
8733 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
8734 Replace VEC_* with std::vector functions.
8735 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
8736 (struct btrace_thread_info)<functions>: Change type to std::vector.
8737
db6be0d5
SM
87382017-05-30 Simon Marchi <simon.marchi@ericsson.com>
8739
8740 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
8741 "Removed targets and native configurations" up. Merge duplicate
8742 "New commands" sub-sections. Add "New options" sub-sections.
8743
b057297a
AH
87442017-05-26 Alan Hayward <alan.hayward@arm.com>
8745
8746 * defs.h (copy_integer_to_size): New declaration.
8747 * findvar.c (copy_integer_to_size): New function.
8748 (do_cint_test): New selftest function.
8749 (copy_integer_to_size_test): Likewise.
8750 (_initialize_findvar): Likewise.
8751 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
8752 (mips_fbsd_collect_reg): Use raw_collect_integer.
8753 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
8754 (mips64_fill_gregset): Use raw_collect_integer
8755 (mips64_fill_fpregset): Use raw_supply_integer.
8756 * regcache.c (regcache::raw_supply_integer): New function.
8757 (regcache::raw_collect_integer): Likewise.
8758 * regcache.h: (regcache::raw_supply_integer): New declaration.
8759 (regcache::raw_collect_integer): Likewise.
8760
b77b02a5
YQ
87612017-05-24 Yao Qi <yao.qi@linaro.org>
8762
8763 * Makefile.in (SFILES): Add gdbarch-selftests.c.
8764 (COMMON_OBS): Add gdbarch-selftests.o.
8765 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
8766 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
8767 * gdbarch-selftests.c: New file.
8768 * regcache.h (regcache) <~regcache>: Mark it virtual if
8769 GDB_SELF_TEST.
8770 <raw_write>: Likewise.
8771
e521e87e
YQ
87722017-05-24 Yao Qi <yao.qi@linaro.org>
8773
8774 * regcache.c (current_regcache): Change it to
8775 regcache::current_regcache.
8776 (regcache_observer_target_changed): Update.
8777 (regcache_thread_ptid_changed): Make it a regcache static
8778 method.
8779 (regcache_thread_ptid_changed): Update.
8780 (class regcache_access): New.
8781 (current_regcache_test): Update.
8782 (_initialize_regcache): Update.
8783 * regcache.h: Include forward_list.
8784 (regcache): Declare regcache_thread_ptid_changed and declare
8785 registers_changed_ptid as friend.
8786
d8e07dda
YQ
87872017-05-24 Yao Qi <yao.qi@linaro.org>
8788
8789 * i387-tdep.c (i387_register_to_value): Use register_size
8790 instead of TYPE_LENGTH.
8791 * m68k-tdep.c (m68k_register_to_value): Likewise.
8792
8c8f9122
YQ
87932017-05-24 Yao Qi <yao.qi@linaro.org>
8794
8795 * i387-tdep.c (i387_convert_register_p): Return false if type
8796 code isn't TYPE_CODE_FLT.
8797
68fce50f
YQ
87982017-05-24 Yao Qi <yao.qi@linaro.org>
8799
8800 * alpha-tdep.c (alpha_convert_register_p): Return true if type
8801 length is 4.
8802 (alpha_register_to_value): Remove type length check.
8803 (alpha_value_to_register): Likewise.
8804
88954b49
YQ
88052017-05-24 Yao Qi <yao.qi@linaro.org>
8806
8807 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
8808 TYPE_CODE_FLT.
8809
e3ec9b69
YQ
88102017-05-24 Yao Qi <yao.qi@linaro.org>
8811
8812 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
8813 TYPE_CODE_FLT or not.
8814
cdd238da
YQ
88152017-05-24 Yao Qi <yao.qi@linaro.org>
8816
8817 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
8818 * avr-tdep.c (avr_gdbarch_init): Likewise.
8819 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
8820 * cris-tdep.c (cris_gdbarch_init): Likewise.
8821 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
8822 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
8823 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
8824 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
8825 * mep-tdep.c (mep_gdbarch_init): Likewise.
8826 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
8827 * mips-tdep.c (mips_gdbarch_init): Likewise.
8828 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
8829 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
8830 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
8831 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
8832 * v850-tdep.c (v850_gdbarch_init): Likewise.
8833
7a3929c4
YQ
88342017-05-24 Yao Qi <yao.qi@linaro.org>
8835
8836 * selftest-arch.c (tests_with_arch): Call registers_changed
8837 and reinit_frame_cache.
8838 * selftest.c (run_self_tests): Likewise.
8839
f4985dba
YQ
88402017-05-24 Yao Qi <yao.qi@linaro.org>
8841
8842 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
8843 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
8844
ab20fa4a
YQ
88452017-05-24 Yao Qi <yao.qi@linaro.org>
8846
8847 * rl78-tdep.c (rl78_gdbarch_init): Don't call
8848 set_gdbarch_print_insn.
8849
f532ab94
YQ
88502017-05-24 Yao Qi <yao.qi@linaro.org>
8851
8852 * h8300-tdep.c (h8300_gdbarch_init): Don't call
8853 set_gdbarch_print_insn.
8854
39503f82
YQ
88552017-05-24 Yao Qi <yao.qi@linaro.org>
8856
8857 * alpha-tdep.c (alpha_gdbarch_init): Don't call
8858 set_gdbarch_print_insn.
8859 * arc-tdep.c (arc_gdbarch_init): Likewise.
8860 * arch-utils.c: include dis-asm.h.
8861 (default_print_insn): New function.
8862 * arch-utils.h (default_print_insn): Declare.
8863 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
8864 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
8865 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
8866 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
8867 * frv-tdep.c (frv_gdbarch_init): Likewise.
8868 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
8869 * gdbarch.sh (print_insn): Use default_print_insn.
8870 * gdbarch.c: Regenerated.
8871 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
8872 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
8873 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
8874 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
8875 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
8876 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
8877 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
8878 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
8879 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
8880 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
8881 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
8882 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
8883 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
8884 * mt-tdep.c (mt_gdbarch_init): Likewise.
8885 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
8886 * nios2-tdep.c (nios2_print_insn): Remove.
8887 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
8888 * rx-tdep.c (rx_gdbarch_init): Likewise.
8889 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
8890 * score-tdep.c (score_print_insn): Remove.
8891 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
8892 * sh-tdep.c (sh_gdbarch_init): Likewise.
8893 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
8894 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
8895 * tic6x-tdep.c (tic6x_print_insn): Remove.
8896 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
8897 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
8898 * v850-tdep.c (v850_gdbarch_init): Likewise.
8899 * vax-tdep.c (vax_gdbarch_init): Likewise.
8900 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
8901 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
8902
f7241d4f
JB
89032017-05-23 John Baldwin <jhb@FreeBSD.org>
8904
8905 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
8906 (MIPS_FP0_REGNUM): Remove.
8907 (MIPS_FSR_REGNUM): Remove.
8908 (mips_fbsd_supply_fpregs): Use mips_regnum.
8909 (mips_fbsd_supply_gregs): Likewise.
8910 (mips_fbsd_collect_fpregs): Likewise.
8911 (mips_fbsd_collect_gregs): Likewise.
8912
d489d81d
JB
89132017-05-23 John Baldwin <jhb@FreeBSD.org>
8914
8915 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
8916 (getpfpregs_supplies): New function.
8917 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
8918 getfpregs_supplies.
8919 (mips_fbsd_store_inferior_registers): Likewise.
8920
e11b3cdc
PA
89212017-05-22 Pedro Alves <palves@redhat.com>
8922
8923 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
8924 maintainer.
8925
0f068fb5
AH
89262017-05-22 Alan Hayward <alan.hayward@arm.com>
8927
8928 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
8929 (store_register): Likewise.
8930 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
8931 (get_decimal_float_return_value): Likewise.
8932 (do_ppc_sysv_return_value): Likewise.
8933 (ppc64_sysv_abi_push_integer): Likewise.
8934 (ppc64_sysv_abi_push_freg): Likewise.
8935 (ppc64_sysv_abi_return_value_base): Likewise.
8936 (ppc64_sysv_abi_return_value): Likewise.
8937 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
8938 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
8939 * rs6000-nat.c: Likewise.
8940 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
8941 (rs6000_value_to_register): Likewise.
8942 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
8943
e6cf65f2
TT
89442017-05-21 Tom Tromey <tom@tromey.com>
8945
8946 PR rust/21466:
8947 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
8948 arrays as "[T]", not "[T; ]".
8949
43cc5389
TT
89502017-05-19 Tom Tromey <tom@tromey.com>
8951
8952 PR rust/21484:
8953 * rust-lang.c (exp_descriptor_rust): New function.
8954 (rust_language_defn): Use it.
8955 * p-lang.c (pascal_language_defn): Update.
8956 * opencl-lang.c (opencl_language_defn): Update.
8957 * objc-lang.c (objc_language_defn): Update.
8958 * m2-lang.c (m2_language_defn): Update.
8959 * language.h (struct language_defn)
8960 <la_watch_location_expression>: New member.
8961 * language.c (unknown_language_defn, auto_language_defn)
8962 (local_language_defn): Update.
8963 * go-lang.c (go_language_defn): Update.
8964 * f-lang.c (f_language_defn): Update.
8965 * d-lang.c (d_language_defn): Update.
8966 * c-lang.h (c_watch_location_expression): Declare.
8967 * c-lang.c (c_watch_location_expression): New function.
8968 (c_language_defn, cplus_language_defn, asm_language_defn)
8969 (minimal_language_defn): Use it.
8970 * breakpoint.c (watch_command_1): Call
8971 la_watch_location_expression.
8972 * ada-lang.c (ada_language_defn): Update.
8973
7a6e7fcc
RO
89742017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
8975
6e7e1744
RO
8976 PR tui/21482
8977 * gdb_curses.h (NOMACROS): Define.
8978 (NCURSES_NOMACROS): Define.
8979
89802017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
8981
8982 PR tui/21482
7a6e7fcc
RO
8983 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
8984 arg to char *.
8985 * tui/tui-wingeneral.c (box_win): Likewise.
8986 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
8987 (tui_show_source_line): Likewise.
8988 (tui_show_exec_info_content): Likewise.
8989
1933fd8e
VM
89902017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
8991
8992 * sparc-tdep.c (sparc_structure_return_p)
8993 (sparc_arg_on_registers_p): New functions.
8994 (sparc32_store_arguments): Use them.
8995 * sparc64-tdep.c (sparc64_16_byte_align_p)
8996 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
8997 Handle TYPE_CODE_ARRAY.
8998
21873064
YQ
89992017-05-17 Yao Qi <yao.qi@linaro.org>
9000
9001 * cli/cli-decode.c (add_alias_cmd): New function.
9002 * command.h (add_alias_cmd): Declare.
9003 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
9004 instead call add_alias_cmd.
9005
2b351b19
PA
90062017-05-17 Pedro Alves <palves@redhat.com>
9007
9008 * Makefile.in (nat_extra_makefile_frag): Rename to ...
9009 (nat_makefile_frag): ... this. All references updated.
9010 * configure.ac: Likewise.
9011 * configure.nat: Likewise. Enhance comments.
9012 * configure: Regenerate.
9013
5f2ad7a3
RO
90142017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
9015
9016 * procfs.c (procfs_create_inferior): Change prototype to match
9017 definition.
9018
adf3dde5
EZ
90192017-05-13 Eli Zaretskii <eliz@gnu.org>
9020
9021 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
9022 C++ compiler warning.
9023
6830f270
TT
90242017-05-12 Tom Tromey <tom@tromey.com>
9025
9026 PR rust/21483:
9027 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
9028 recurse, just call value_struct_elt directly.
9029
68f2f2e3
TT
90302017-05-12 Tom Tromey <tom@tromey.com>
9031
9032 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
9033 OP_RUST_ARRAY>: Fix.
9034
256afbc2
TT
90352017-05-12 Tom Tromey <tom@tromey.com>
9036
9037 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
9038
94bb8dfe
YQ
90392017-05-09 Yao Qi <yao.qi@linaro.org>
9040
9041 * regcache.c: Include <forward_list>.
9042 (struct regcache_list): Remove.
9043 (current_regcache): Update.
9044 (get_thread_arch_aspace_regcache): Update for std::forward_list.
9045 (regcache_thread_ptid_changed): Likewise.
9046 (registers_changed_ptid): Likewise.
9047 (current_regcache_size): Likewise.
9048
8248946c
YQ
90492017-05-09 Yao Qi <yao.qi@linaro.org>
9050
9051 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
9052 (current_regcache_size): New function.
9053 (current_regcache_test): New function.
9054 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
9055
313c5961
AH
90562017-05-08 Alan Hayward <alan.hayward@arm.com>
9057
9058 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
9059 (print_gp_register_row): Use get_frame_register_value.
9060
27bfc1d1
AH
90612017-05-08 Alan Hayward <alan.hayward@arm.com>
9062
9063 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
9064 (mips_supply_fpregset): Likewise.
9065 (mips64_supply_gregset): Likewise.
9066
146e6c5c
AH
90672017-05-08 Alan Hayward <alan.hayward@arm.com>
9068
9069 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
9070 regcache->raw_supply_zeroed.
9071
e50f25ec
SDJ
90722017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
9073
9074 * configure.nat: Rearrange 'case' statements to match
9075 host before cpu.
9076
21ea5acd
SDJ
90772017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
9078
9079 * Makefile.in: Remove "@host_makefile_frag@". Add variables
9080 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
9081 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
9082 "@nat_extra_makefile_frag@".
9083 (Makefile): Remove dependency on "@frags@".
9084 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
9085 (data-directory/Makefile): Likewise.
9086 * config/aarch64/linux.mh: Deleted; moved contents to
9087 "gdb/configure.nat".
9088 * config/alpha/alpha-linux.mh: Likewise.
9089 * config/alpha/nbsd.mh: Likewise.
9090 * config/arm/linux.mh: Likewise.
9091 * config/arm/nbsdelf.mh: Likewise.
9092 * config/i386/cygwin.mh: Likewise.
9093 * config/i386/cygwin64.mh: Likewise.
9094 * config/i386/darwin.mh: Likewise.
9095 * config/i386/fbsd.mh: Likewise.
9096 * config/i386/fbsd64.mh: Likewise.
9097 * config/i386/go32.mh: Likewise.
9098 * config/i386/i386gnu.mh: Likewise.
9099 * config/i386/i386sol2.mh: Likewise.
9100 * config/i386/linux.mh: Likewise.
9101 * config/i386/linux64.mh: Likewise.
9102 * config/i386/mingw.mh: Likewise.
9103 * config/i386/mingw64.mh: Likewise.
9104 * config/i386/nbsd64.mh: Likewise.
9105 * config/i386/nbsdelf.mh: Likewise.
9106 * config/i386/nto.mh: Likewise.
9107 * config/i386/obsd.mh: Likewise.
9108 * config/i386/obsd64.mh: Likewise.
9109 * config/i386/sol2-64.mh: Likewise.
9110 * config/ia64/linux.mh: Likewise.
9111 * config/m32r/linux.mh: Likewise.
9112 * config/m68k/linux.mh: Likewise.
9113 * config/m68k/nbsdelf.mh: Likewise.
9114 * config/m68k/obsd.mh: Likewise.
9115 * config/m88k/obsd.mh: Likewise.
9116 * config/mips/fbsd.mh: Likewise.
9117 * config/mips/linux.mh: Likewise.
9118 * config/mips/nbsd.mh: Likewise.
9119 * config/mips/obsd64.mh: Likewise.
9120 * config/pa/linux.mh: Likewise.
9121 * config/pa/nbsd.mh: Likewise.
9122 * config/pa/obsd.mh: Likewise.
9123 * config/powerpc/aix.mh: Likewise.
9124 * config/powerpc/fbsd.mh: Likewise.
9125 * config/powerpc/linux.mh: Likewise.
9126 * config/powerpc/nbsd.mh: Likewise.
9127 * config/powerpc/obsd.mh: Likewise.
9128 * config/powerpc/ppc64-linux.mh: Likewise.
9129 * config/powerpc/spu-linux.mh: Likewise.
9130 * config/s390/linux.mh: Likewise.
9131 * config/sh/nbsd.mh: Likewise.
9132 * config/sparc/fbsd.mh: Likewise.
9133 * config/sparc/linux.mh: Likewise.
9134 * config/sparc/linux64.mh: Likewise.
9135 * config/sparc/nbsd64.mh: Likewise.
9136 * config/sparc/nbsdelf.mh: Likewise.
9137 * config/sparc/obsd64.mh: Likewise.
9138 * config/sparc/sol2.mh: Likewise.
9139 * config/tilegx/linux.mh: Likewise.
9140 * config/vax/nbsdelf.mh: Likewise.
9141 * config/vax/obsd.mh: Likewise.
9142 * config/xtensa/linux.mh: Likewise.
9143 * config/i386/i386gnu.mn: New file, with excerpts from
9144 "config/i386/i386gnu.mh".
9145 * configure: Regenerate.
9146 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
9147 *.mh files under "gdb/config".
9148 * configure.nat: New file, with contents from the
9149 "gdb/config/*/*.mh" files.
9150
7ed1acaf
TW
91512017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
9152
9153 * btrace.c (btrace_clear): Free insn vector.
9154
e13cb306
PA
91552017-05-05 Pedro Alves <palves@redhat.com>
9156
9157 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
9158 * configure: Regenerate.
9159
5ed8105e
PA
91602017-05-04 Pedro Alves <palves@redhat.com>
9161
9162 * Makefile.in (SFILES): Add progspace-and-thread.c.
9163 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
9164 (COMMON_OBS): Add progspace-and-thread.o.
9165 * breakpoint.c: Include "progspace-and-thread.h".
9166 (update_inserted_breakpoint_locations)
9167 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
9168 Use scoped_restore_current_pspace_and_thread.
9169 (create_std_terminate_master_breakpoint): Use
9170 scoped_restore_current_program_space.
9171 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
9172 (print_breakpoint_location): Use
9173 scoped_restore_current_program_space.
9174 (bp_loc_is_permanent): Use
9175 scoped_restore_current_pspace_and_thread.
9176 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
9177 (download_tracepoint_locations): Use
9178 scoped_restore_current_pspace_and_thread.
9179 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
9180 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
9181 (enum step_over_calls_kind): Moved from inferior.h.
9182 (class scoped_restore_current_thread): New class.
9183 * gdbthread.h (make_cleanup_restore_current_thread): Delete
9184 declaration.
9185 (scoped_restore_current_thread): New class.
9186 * infcmd.c: Include "common/gdb_optional.h".
9187 (continue_1, proceed_after_attach): Use
9188 scoped_restore_current_thread.
9189 (notice_new_inferior): Use scoped_restore_current_thread.
9190 * inferior.c: Include "progspace-and-thread.h".
9191 (restore_inferior, save_current_inferior): Delete.
9192 (add_inferior_command, clone_inferior_command): Use
9193 scoped_restore_current_pspace_and_thread.
9194 * inferior.h (scoped_restore_current_inferior): New class.
9195 * infrun.c: Include "progspace-and-thread.h" and
9196 "common/gdb_optional.h".
9197 (follow_fork_inferior): Use
9198 scoped_restore_current_pspace_and_thread.
9199 (scoped_restore_exited_inferior): New class.
9200 (handle_vfork_child_exec_or_exit): Use
9201 scoped_restore_exited_inferior,
9202 scoped_restore_current_pspace_and_thread,
9203 scoped_restore_current_thread and scoped_restore.
9204 (fetch_inferior_event): Use scoped_restore_current_thread.
9205 * linespec.c (decode_line_full, decode_line_1): Use
9206 scoped_restore_current_program_space.
9207 * mi/mi-main.c: Include "progspace-and-thread.h".
9208 (exec_continue): Use scoped_restore_current_thread.
9209 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
9210 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
9211 * proc-service.c (ps_pglobal_lookup): Use
9212 scoped_restore_current_program_space.
9213 * progspace-and-thread.c: New file.
9214 * progspace-and-thread.h: New file.
9215 * progspace.c (release_program_space, clone_program_space): Use
9216 scoped_restore_current_program_space.
9217 (restore_program_space, save_current_program_space)
9218 (save_current_space_and_thread): Delete.
9219 (switch_to_program_space_and_thread): Moved to
9220 progspace-and-thread.c.
9221 * progspace.h (save_current_program_space)
9222 (save_current_space_and_thread): Delete declarations.
9223 (scoped_restore_current_program_space): New class.
9224 * remote.c (remote_btrace_maybe_reopen): Use
9225 scoped_restore_current_thread.
9226 * symtab.c: Include "progspace-and-thread.h".
9227 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
9228 * thread.c (print_thread_info_1): Use
9229 scoped_restore_current_thread.
9230 (struct current_thread_cleanup): Delete.
9231 (do_restore_current_thread_cleanup)
9232 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
9233 (scoped_restore_current_thread::~scoped_restore_current_thread):
9234 ... this new dtor.
9235 (make_cleanup_restore_current_thread): Rename/convert to ...
9236 (scoped_restore_current_thread::scoped_restore_current_thread):
9237 ... this new ctor.
9238 (thread_apply_all_command): Use scoped_restore_current_thread.
9239 (thread_apply_command): Use scoped_restore_current_thread.
9240 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
9241 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
9242
f6223dbb
PA
92432017-05-04 Pedro Alves <palves@redhat.com>
9244
9245 * thread.c (make_cleanup_restore_current_thread): Move
9246 find_thread_ptid call before the is_stopped call. Assert that the
9247 thread is found. Replace is_stopped call by checking the thread's
9248 state directly. Remove unnecessary NULL-thread check.
9249
3c3ae77e
PA
92502017-05-04 Pedro Alves <palves@redhat.com>
9251
9252 * corelow.c (thread_section_name): New class.
9253 (get_core_register_section, get_core_siginfo): Use it.
9254
45eba0ab
AA
92552017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
9256
9257 * corelow.c (sniff_core_bfd): Remove extra semicolon.
9258 (get_core_register_section): Remove xfree of NULL pointer.
9259
f81fdd35
AH
92602017-05-03 Alan Hayward <alan.hayward@arm.com>
9261
9262 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
9263 * regcache.c (regcache::raw_supply_zeroed): New function.
9264 * regcache.h (regcache::raw_supply_zeroed): New declaration.
9265
35837774
SM
92662017-05-03 Simon Marchi <simon.marchi@ericsson.com>
9267
9268 * gdbarch.sh: Remove commented out definition of
9269 TARGET_CHAR_BIT.
9270 * gdbarch.h: Re-generate.
9271
c94fee56
SDJ
92722017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
9273
9274 * configure: Regenerate.
9275
d17f7b36
SM
92762017-05-02 Simon Marchi <simon.marchi@ericsson.com>
9277
9278 * solib-target.c (solib_target_relocate_section_addresses):
9279 Remove num_section_bases, num_bases, segment_bases variables.
9280
b560ebd6
SM
92812017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
9282
9283 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
9284
f2f46dfc
SM
92852017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
9286
9287 * solib-target.c: Include <vector>
9288 (struct lm_info_target) <~lm_info_target>: Remove.
9289 <segment_bases, section_bases>: Change type to
9290 std::vector<CORE_ADDR>.
9291 (library_list_start_segment, library_list_start_section,
9292 library_list_end_library,
9293 solib_target_relocate_section_addresses): Adjust.
9294
a0ff9e1a
SM
92952017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
9296
9297 * gdbarch.sh (software_single_step): Change return type to
9298 std::vector<CORE_ADDR>.
9299 * gdbarch.c, gdbarch.h: Re-generate.
9300 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
9301 Adjust.
9302 (arm_deal_with_atomic_sequence_raw): Adjust.
9303 (thumb_get_next_pcs_raw): Adjust.
9304 (arm_get_next_pcs_raw): Adjust.
9305 (arm_get_next_pcs): Adjust.
9306 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
9307 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
9308 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
9309 (alpha_software_single_step): Adjust.
9310 * alpha-tdep.h (alpha_software_single_step): Adjust.
9311 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
9312 * arm-tdep.c (arm_software_single_step): Adjust.
9313 (arm_breakpoint_kind_from_current_state): Adjust.
9314 * arm-tdep.h (arm_software_single_step): Adjust.
9315 * breakpoint.c (insert_single_step_breakpoint): Adjust.
9316 * cris-tdep.c (cris_software_single_step): Adjust.
9317 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
9318 (micromips_deal_with_atomic_sequence): Adjust.
9319 (deal_with_atomic_sequence): Adjust.
9320 (mips_software_single_step): Adjust.
9321 * mips-tdep.h (mips_software_single_step): Adjust.
9322 * moxie-tdep.c (moxie_software_single_step): Adjust.
9323 * nios2-tdep.c (nios2_software_single_step): Adjust.
9324 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
9325 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
9326 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
9327 * s390-linux-tdep.c (s390_software_single_step): Adjust.
9328 * sparc-tdep.c (sparc_software_single_step): Adjust.
9329 * spu-tdep.c (spu_software_single_step): Adjust.
9330 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
9331
ea480a30
SM
93322017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
9333
9334 * gdbarch.sh: Use semi-colon as field separator instead of colon.
9335 * gdbarch.h: Re-generate.
9336
d050f7d7
TW
93372017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
9338
9339 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
9340 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
9341 * python/py-instruction.c, python/py-instruction.h: New file.
9342 * python/py-record.c: Add py-instruction.h include.
9343 (gdbpy_initialize_record): Make gdb.Instruction a super class of
9344 gdb.RecordInstruction.
9345 * python/python-internal.h: Add gdbpy_initialize_instruction
9346 declaration.
9347 * python/python.c (do_start_initialization): Add
9348 gdbpy_initialize_instruction.
9349
14f819c8
TW
93502017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
9351
9352 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
9353 Remove.
9354 (btrace_func_from_recpy_func): New function.
9355 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
9356 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
9357 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
9358 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
9359 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
9360 Also, use new helper functions.
9361 (btpy_list_item): Use new helper functions.
9362 (recpy_bt_function_call_history): Use new type name.
9363 (btpy_call_getset): Remove.
9364 (gdbpy_initialize_btrace): Remove code to initialize
9365 gdb.BtraceFunctionCall.
9366 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
9367 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
9368 recpy_bt_func_prev, recpy_bt_func_next): New export.
9369 * python/py-record.c (recpy_func_type): New static object.
9370 (recpy_func_new, recpy_func_level, recpy_func_symbol,
9371 recpy_func_instructions, recpy_func_up, recpy_func_prev,
9372 recpy_func_next): New function.
9373 (recpy_element_hash, recpy_element_richcompare): Updated comment.
9374 (recpy_func_getset): New static object.
9375 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
9376 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
9377
0ed5da75
TW
93782017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
9379
9380 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
9381 (btpy_object, btpy_insn_type, btpy_new): Remove.
9382 (btpy_list_object): Use gdb.RecordInstruction type instead of
9383 gdb.BtraceInstruction type.
9384 (btrace_insn_from_recpy_insn): New function.
9385 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
9386 btpy_new.
9387 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
9388 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
9389 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
9390 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
9391 instead of btpy_object.
9392 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
9393 btpy_insn_data, btpy_insn_decode): Rename to ...
9394 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
9395 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
9396 recpy_bt_insn_decode): This. Also, use new helper functions.
9397 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
9398 recpy_insn_type.
9399 (btpy_insn_getset): Remove.
9400 (gdbpy_initialize_btrace): Remove code to initialize
9401 gdb.BtraceInstruction. Use recpy_element_object.
9402 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
9403 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
9404 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
9405 * python/py-record.c (recpy_insn_type): New static object.
9406 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
9407 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
9408 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
9409 New function.
9410 (recpy_insn_getset): New static object.
9411 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
9412 * python/py-record.h (recpy_element_object): New typedef.
9413 (recpy_insn_type, recpy_insn_new): New export.
9414
913aeadd
TW
94152017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
9416
9417 * py-record-btrace.c (btpy_insn_new): Removed.
9418 (btpy_insn_or_gap_new): New function.
9419 (btpy_insn_error): Removed.
9420 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
9421 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
9422 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
9423 btpy_insn_or_gap_new instead of btpy_insn_new.
9424 (btpy_insn_getset): Remove btpy_insn_error.
9425 * py-record.c (recpy_gap_type): New static object.
9426 (recpy_gap_object): New typedef.
9427 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
9428 recpy_gap_reason_string): New function.
9429 (recpy_gap_getset): New static object.
9430 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
9431 * py-record.h (recpy_gap_new): New export.
9432
a3be24ad
TW
94332017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
9434
9435 * python/py-record.c (recpy_ptid): Remove.
9436 (recpy_record_getset): Remove recpy_ptid.
9437
ae20e79a
TW
94382017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
9439
9440 * btrace.c (btrace_fetch): Set inferior_ptid.
9441 * python/py-record-btrace.c: Add "py-record.h" include.
9442 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
9443 recpy_bt_end, recpy_bt_instruction_history,
9444 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
9445 in gdb.Record object instead of current ptid.
9446 * python/py-record.c: Include new "py-record.h" file.
9447 (recpy_record_object): Moved to py-record.h.
9448 * python/py-record.h: New file.
9449
8d0050ea
TW
94502017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
9451
9452 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
9453 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
9454 indentation.
9455
3f380b50
JB
94562017-05-01 Joel Brobecker <brobecker@adacore.com>
9457
9458 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
9459 the past maintainers section.
9460
07495424
YQ
94612017-04-28 Yao Qi <yao.qi@linaro.org>
9462
9463 * infcmd.c (get_return_value): Use regcache ctor, and remove
9464 cleanup.
9465
deb1fa3e
YQ
94662017-04-28 Yao Qi <yao.qi@linaro.org>
9467 Pedro Alves <palves@redhat.com>
9468
9469 * regcache.c (regcache::regcache): New tag dispatch ctor.
9470 (do_cooked_read): Moved above.
9471 (regcache_dup): Use the tag dispatch ctor..
9472 * regcache.h (regcache): Declare ctor, delete copy ctor and
9473 assignment operator, remove friend regcache_dup.
9474
b421c83c
YQ
94752017-04-28 Yao Qi <yao.qi@linaro.org>
9476
9477 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
9478 call method save instead of regcache_cpy.
9479 * regcache.h (struct regcache): Make regcache_dup a friend.
9480
ef79d9a3
YQ
94812017-04-28 Yao Qi <yao.qi@linaro.org>
9482
9483 * regcache.c (struct regcache): Move to regcache.h
9484 (regcache::arch): New method.
9485 (regcache_get_ptid): Update.
9486 (get_regcache_arch): Call arch method.
9487 (get_regcache_aspace): Call method aspace.
9488 (register_buffer): Change it to method.
9489 (regcache_save): Change it to regcache::save.
9490 (regcache_restore): Likewise.
9491 (regcache_cpy_no_passthrough): Remove the declaration.
9492 (regcache_cpy): Call methods restore and cpy_no_passthrough.
9493 (regcache_cpy_no_passthrough): Change it to method
9494 cpy_no_passthrough.
9495 (regcache_register_status): Change it to method
9496 get_register_status.
9497 (regcache_invalidate): Change it to method invalidate.
9498 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
9499 (regcache_raw_update): Change it to method raw_update.
9500 (regcache_raw_read): Likewise.
9501 (regcache_raw_read_signed): Likewise.
9502 (regcache_raw_read_unsigned): Likewise.
9503 (regcache_raw_write_signed): Likewise.
9504 (regcache_raw_write_unsigned): Likewise.
9505 (regcache_cooked_read): Likewise.
9506 (regcache_cooked_read_value): Likewise.
9507 (regcache_cooked_read_signed): Likewise.
9508 (regcache_cooked_read_unsigned): Likewise.
9509 (regcache_cooked_write_signed): Likewise.
9510 (regcache_cooked_write_unsigned): Likewise.
9511 (regcache_raw_set_cached_value): Likewise.
9512 (regcache_raw_write): Likewise.
9513 (regcache_cooked_write): Likewise.
9514 (regcache_xfer_part): Likewise.
9515 (regcache_raw_read_part): Likewise.
9516 (regcache_raw_write_part): Likewise.
9517 (regcache_cooked_read_part): Likewise.
9518 (regcache_cooked_write_part): Likewise.
9519 (regcache_raw_supply): Likewise.
9520 (regcache_raw_collect): Likewise.
9521 (regcache_transfer_regset): Likewise.
9522 (regcache_supply_regset): Likewise.
9523 (regcache_collect_regset): Likewise.
9524 (regcache_debug_print_register): Likewise.
9525 (enum regcache_dump_what): Move it to regcache.h.
9526 (regcache_dump): Change it to method dump.
9527 * regcache.h (enum regcache_dump_what): New.
9528 (class regcache): New.
9529 * target.c (target_fetch_registers): Call method
9530 debug_print_register.
9531 (target_store_registers): Likewise.
9532
f8fdb78e
SM
95332017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9534
9535 * windows-nat.c (struct lm_info_windows): Initialize field.
9536 (windows_make_so): Allocate lm_info_windows with new.
9537 (windows_free_so): Free lm_info_windows with delete.
9538
9ccbfd7b
SM
95392017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9540
9541 * solib-darwin.c (struct lm_info_darwin): Initialize field.
9542 (darwin_current_sos): Allocate lm_info_darwin with new, remove
9543 cleanup.
9544 (darwin_free_so): Free lm_info_darwin with delete.
9545
76e75227
SM
95462017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9547
9548 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
9549 <l_addr_p>: Change type to bool.
9550 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
9551 (svr4_free_so): Free lm_info_svr4 with delete.
9552 (svr4_copy_library_list): Replace memcpy with call to copy
9553 constructor.
9554 (library_list_start_library, svr4_default_sos): Allocate
9555 lm_info_svr4 with new.
9556
51046d9e
SM
95572017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9558
9559 * solib-target.c (struct lm_info_target): Add destructor,
9560 initialize fields.
9561 <name>: Change type to std::string.
9562 (library_list_start_library): Allocate lm_info_target with new.
9563 (solib_target_free_library_list): Free lm_info_target with
9564 delete.
9565 (solib_target_current_sos): Adapt to std::string.
9566 (solib_target_free_so): Free lm_info_target with delete.
9567
4023ae76
SM
95682017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9569
9570 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
9571 fields.
9572 (frv_current_sos): Allocate lm_info_frv with new.
9573 (frv_relocate_main_executable): Free lm_info_frv with delete,
9574 allocate with new.
9575 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
9576
af43057b
SM
95772017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9578
9579 * solib-frv.c (struct lm_info_frv): Fix indentation.
9580
b0911207
SM
95812017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9582
9583 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
9584 map field.
9585 (dsbt_current_sos): Allocate lm_info_dsbt with new.
9586 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
9587 and allocate with new.
9588 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
9589
6c401f72
SM
95902017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9591
9592 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
9593 <filename, member_name>: Change type to std::string.
9594 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
9595 (library_list_start_library): Allocate lm_info_aix with new.
9596 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
9597 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
9598 with copy constructor.
9599
d0e449a1
SM
96002017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9601
9602 * solist.h (struct lm_info): Remove.
9603 (struct lm_info_base): New class.
9604 (struct so_list) <lm_info>: Change type to lm_info_base *.
9605 * nto-tdep.c (struct lm_info): Remove.
9606 (lm_addr): Adjust.
9607 * solib-aix.c (struct lm_info): Rename to ...
9608 (struct lm_info_aix): ... this. Extend lm_info_base.
9609 (lm_info_p): Rename to ...
9610 (lm_info_aix_p): ... this, and adjust.
9611 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
9612 solib_aix_parse_libraries, library_list_start_library,
9613 solib_aix_free_library_list, solib_aix_parse_libraries,
9614 solib_aix_get_library_list,
9615 solib_aix_relocate_section_addresses, solib_aix_free_so,
9616 solib_aix_get_section_offsets,
9617 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
9618 Adjust.
9619 (struct solib_aix_inferior_data) <library_list>: Adjust.
9620 * solib-darwin.c (struct lm_info): Rename to ...
9621 (struct lm_info_darwin): ... this. Extend lm_info_base.
9622 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
9623 * solib-dsbt.c (struct lm_info): Rename to ...
9624 (struct lm_info_dsbt): ... this. Extend lm_info_base.
9625 (struct dsbt_info) <main_executable_lm_info): Adjust.
9626 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
9627 dsbt_relocate_section_addresses): Adjust.
9628 * solib-frv.c (struct lm_info): Rename to ...
9629 (struct lm_info_frv): ... this. Extend lm_info_base.
9630 (main_executable_lm_info): Adjust.
9631 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
9632 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
9633 find_canonical_descriptor_in_load_object,
9634 frv_fdpic_find_canonical_descriptor): Adjust.
9635 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
9636 to lm_info_svr4.
9637 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
9638 svr4_clear_so, svr4_copy_library_list,
9639 library_list_start_library, svr4_default_sos, svr4_read_so_list,
9640 svr4_current_sos, svr4_fetch_objfile_link_map,
9641 solist_update_incremental): Adjust.
9642 * solib-svr4.h (struct lm_info_svr4): Move here from
9643 solib-svr4.c.
9644 * solib-target.c (struct lm_info): Rename to ...
9645 (struct lm_info_target): ... this. Extend lm_info_base.
9646 (lm_info_p): Rename to ...
9647 (lm_info_target_p): ... this.
9648 (solib_target_parse_libraries, library_list_start_segment,
9649 library_list_start_section, library_list_start_library,
9650 library_list_end_library, solib_target_free_library_list,
9651 solib_target_current_sos, solib_target_free_so,
9652 solib_target_relocate_section_addresses): Adjust.
9653 * windows-nat.c (struct lm_info): Rename to ...
9654 (struct lm_info_windows): ... this. Extend lm_info_base.
9655 (windows_make_so, handle_load_dll, handle_unload_dll,
9656 windows_xfer_shared_libraries): Adjust.
9657
434a4023
SM
96582017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9659
9660 * solib-darwin.c (struct darwin_so_list): Remove.
9661 (darwin_current_sos): Allocate an so_list object instead of a
9662 darwin_so_list, separately allocate an lm_info object.
9663 (darwin_free_so): Free lm_info.
9664
428544e8
JB
96652017-04-28 John Baldwin <jhb@FreeBSD.org>
9666
9667 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
9668 with fprintf_filtered.
9669
4621115f
YQ
96702017-04-28 Yao Qi <yao.qi@linaro.org>
9671
9672 * regcache.c (regcache::regcache): New function.
9673 (regcache::~regcache): New function.
9674 (regcache_xmalloc_1): Remove.
9675 (regcache_xmalloc): Call new regcache.
9676 (regcache_xfree): Call delete regcache.
9677 (get_thread_arch_aspace_regcache): Call new regcache.
9678
339053c2
YQ
96792017-04-28 Yao Qi <yao.qi@linaro.org>
9680
9681 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
9682 lwp instead of ptid_get_lwp.
9683
7974a605
YQ
96842017-04-28 Yao Qi <yao.qi@linaro.org>
9685
9686 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
9687 lwp_info instead of getting from inferior_ptid.
9688
e15c3eb4
KS
96892017-04-27 Keith Seitz <keiths@redhat.com>
9690
9691 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
9692 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
9693 (CV_CONVERSION_BADNESS): Define.
9694 (rank_one_type): Remove overly restrictive rvalue reference
9695 rank checks.
9696 Add cv-qualifier checks and subranks for type equality.
9697 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
9698 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
9699 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
9700
72bc1d24
SM
97012017-04-27 Simon Marchi <simon.marchi@ericsson.com>
9702
9703 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
9704 count when creating the object.
9705
55bcecda
UW
97062017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
9707 Ulrich Weigand <uweigand@de.ibm.com>
9708
9709 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
9710 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
9711 is used in AIX.
9712 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
9713 (process_xcoff_symbol): Likewise.
9714 (scan_xcoff_symtab): Likewise.
9715
5c99fcf8
AH
97162017-04-26 Alan Hayward <alan.hayward@arm.com>
9717
9718 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
9719 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
9720 (ia64_access_reg): Use get_frame_register_unsigned.
9721 (ia64_access_rse_reg): Likewise.
9722 (ia64_libunwind_frame_prev_register): Likewise.
9723
b41c5a85
JW
97242017-04-26 Jiong Wang <jiong.wang@arm.com>
9725
9726 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
9727 * gdbarch.c: Regenerated.
9728 * gdbarch.h: Regenerated.
9729 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
9730 visibility external.
9731 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
9732 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
9733 (enum cfa_how_kind): Move to ...
9734 (struct dwarf2_frame_state_reg_info): Likewise.
9735 (struct dwarf2_frame_state): Likewise.
9736 * dwarf2-frame.h: ... here.
9737 (dwarf2_frame_state_alloc_regs): New declaration.
9738 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
9739 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
9740
c185f580
AH
97412017-04-26 Alan Hayward <alan.hayward@arm.com>
9742
9743 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
9744 regcache_raw_read_unsigned.
9745 (xtensa_pseudo_register_write): Likewise.
9746
19c45594
AH
97472017-04-26 Alan Hayward <alan.hayward@arm.com>
9748
9749 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
9750 (nds32_pseudo_register_write): Likewise.
9751
4658f12e
YQ
97522017-04-25 Yao Qi <yao.qi@linaro.org>
9753
9754 * regcache.c (struct regcache) <readonly_p>: Change its type
9755 to bool.
9756 (regcache_xmalloc_1): Update parameter type and callers update.
9757
d581dda8
YQ
97582017-04-25 Yao Qi <yao.qi@linaro.org>
9759
9760 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
9761 set_gdbarch_wchar_bit.
9762 * arm-tdep.c (arm_gdbarch_init): Likewise.
9763
debed3db
PA
97642017-04-25 Pedro Alves <palves@redhat.com>
9765
9766 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
9767 (BothAreRelocatable, memcopy, memmove): Don't define.
9768 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
9769 macros.
9770
b0b92aeb
PA
97712017-04-25 Pedro Alves <palves@redhat.com>
9772
9773 * common/common-defs.h: Include "common/poison.h".
9774 * common/function-view.h: (Not, Or, Requires): Move to traits.h
9775 and adjust.
9776 * common/poison.h: New file.
9777 * common/traits.h: Include <type_traits>.
9778 (Not, Or, Requires): New, moved from common/function-view.h.
9779
16c4d54a
PA
97802017-04-25 Pedro Alves <palves@redhat.com>
9781
9782 * breakpoint.h (struct breakpoint): In-class initialize all
9783 fields. Make boolean fields "bool".
9784 * breakpoint.c (init_raw_breakpoint_without_location): Remove
9785 memset call and initializations no longer necessary.
9786
b5c36682
PA
97872017-04-25 Pedro Alves <palves@redhat.com>
9788
9789 * btrace.c (pt_btrace_insn_flags): Change parameter type to
9790 reference.
9791 (pt_btrace_insn): New function.
9792 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
9793
5625a286
PA
97942017-04-25 Pedro Alves <palves@redhat.com>
9795
9796 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
9797 "base" field and inherit from "bp_location" instead. Add
9798 non-default ctor.
9799 (allocate_location_exception): Use new non-default ctor.
9800 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
9801 (init_bp_location): Convert to ...
9802 (bp_location::bp_location): ... this new ctor, and remove memset
9803 call.
9804 (base_breakpoint_allocate_location): Use the new non-default ctor.
9805 * breakpoint.h (bp_location): Now a class. Declare default and
9806 non-default ctors. In-class initialize all members.
9807 (init_bp_location): Remove declaration.
9808
23bcc18f
PA
98092017-04-25 Pedro Alves <palves@redhat.com>
9810
9811 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
9812 assignment operator.
9813
e1ba3053
YQ
98142017-04-24 Yao Qi <yao.qi@linaro.org>
9815
9816 * doublest.c (convert_doublest_to_floatformat): Call
9817 floatformat_totalsize_bytes.
9818
10f489e5
TT
98192017-04-22 Tom Tromey <tom@tromey.com>
9820
9821 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
9822 ui_out_emit_list.
9823 * stack.c (print_frame): Use ui_out_emit_list.
9824 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
9825 ui_out_emit_list.
9826 * mi/mi-main.c (print_one_inferior)
9827 (mi_cmd_data_list_register_names)
9828 (mi_cmd_data_list_register_values, mi_cmd_list_features)
9829 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
9830 ui_out_emit_list.
9831 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
9832 (mi_output_solib_attribs): Use ui_out_emit_list,
9833 ui_out_emit_tuple.
9834 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
9835 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
9836 (mi_cmd_stack_list_args, list_args_or_locals): Use
9837 ui_out_emit_list.
9838 * disasm.c (do_assembly_only): Use ui_out_emit_list.
9839 * breakpoint.c (print_solib_event, output_thread_groups): Use
9840 ui_out_emit_list.
9841
0092b74d
TT
98422017-04-22 Tom Tromey <tom@tromey.com>
9843
9844 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
9845 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
9846 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
9847
a14a62dd
TT
98482017-04-22 Tom Tromey <tom@tromey.com>
9849
9850 * tracepoint.c (tvariables_info_1)
9851 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
9852
46b9c129
TT
98532017-04-22 Tom Tromey <tom@tromey.com>
9854
9855 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
9856 annotate_arg_emitter.
9857 * breakpoint.c (print_mention_watchpoint)
9858 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
9859 * annotate.h (struct annotate_arg_emitter): New.
9860
2e783024
TT
98612017-04-22 Tom Tromey <tom@tromey.com>
9862
9863 * record-btrace.c (record_btrace_insn_history)
9864 (record_btrace_insn_history_range, record_btrace_call_history)
9865 (record_btrace_call_history_range): Use ui_out_emit_tuple.
9866 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
9867 ui_out_emit_tuple.
9868 * stack.c (print_frame_info): Use ui_out_emit_tuple.
9869 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
9870 * skip.c (skip_info): Use ui_out_emit_tuple.
9871 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
9872 * progspace.c (print_program_space): Use ui_out_emit_tuple.
9873 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
9874 * osdata.c (info_osdata): Use ui_out_emit_tuple.
9875 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
9876 ui_out_emit_tuple.
9877 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
9878 (output_register, mi_cmd_data_read_memory)
9879 (mi_cmd_data_read_memory_bytes, mi_load_progress)
9880 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
9881 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
9882 Use ui_out_emit_tuple.
9883 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
9884 ui_out_emit_tuple.
9885 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
9886 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
9887 * linux-thread-db.c (info_auto_load_libthread_db): Use
9888 ui_out_emit_tuple.
9889 * inferior.c (print_inferior): Use ui_out_emit_tuple.
9890 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
9891 * disasm.c (do_mixed_source_and_assembly_deprecated)
9892 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
9893 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
9894 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
9895 * breakpoint.c (print_one_breakpoint_location)
9896 (print_one_breakpoint): Use ui_out_emit_tuple.
9897 * auto-load.c (print_script, info_auto_load_cmd): Use
9898 ui_out_emit_tuple.
9899 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
9900
9be21bb4
SM
99012017-04-21 Simon Marchi <simon.marchi@ericsson.com>
9902
9903 * thread.c (print_thread_info_1): Remove dead code.
9904
0d4c07af
JK
99052017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
9906
9907 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
9908 GDB_SELF_TEST.
9909 * arm-tdep.c (selftests::arm_record_test): Likewise.
9910
4daf993d
YQ
99112017-04-21 Yao Qi <yao.qi@linaro.org>
9912
9913 * regcache.c (regcache_restore): Remove argument 2. Replace
9914 argument 3 with regcache. Get register status from
9915 src->register_status and get register contents from
9916 register_buffer (src, regnum).
9917 (regcache_cpy): Update.
9918
a6c21d4a
PA
99192017-04-19 Pedro Alves <palves@redhat.com>
9920
9921 * gdbthread.h (thread): Add missing closing parenthesis in
9922 comment.
9923
3a3fd0fd
PA
99242017-04-19 Pedro Alves <palves@redhat.com>
9925
9926 * common/refcounted-object.h: New file.
9927 * gdbthread.h: Include "common/refcounted-object.h".
9928 (thread_info): Inherit from refcounted_object and add comments.
9929 (thread_info::incref, thread_info::decref)
9930 (thread_info::m_refcount): Delete.
9931 (thread_info::deletable): Use the refcounted_object::refcount()
9932 method.
9933 * inferior.c (current_inferior_): Add comment.
9934 (set_current_inferior): Increment/decrement refcounts.
9935 (prune_inferiors, remove_inferior_command): Skip inferiors marked
9936 not-deletable instead of comparing with the current inferior.
9937 (initialize_inferiors): Increment the initial inferior's refcount.
9938 * inferior.h (struct inferior): Forward declare.
9939 Include "common/refcounted-object.h".
9940 (current_inferior, set_current_inferior): Move declaration to
9941 before struct inferior's definition, and fix comment.
9942 (inferior): Inherit from refcounted_object. Add comments.
9943 * thread.c (switch_to_thread_no_regs): Reference the thread's
9944 inferior pointer directly instead of doing a ptid lookup.
9945 (switch_to_no_thread): New function.
9946 (switch_to_thread(thread_info *)): New function, factored out
9947 from ...
9948 (switch_to_thread(ptid_t)): ... this.
9949 (restore_current_thread): Delete.
9950 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
9951 fields, and add 'inf' field.
9952 (do_restore_current_thread_cleanup): Check whether old->inf is
9953 alive instead of looking up an inferior by ptid. Use
9954 switch_to_thread and switch_to_no_thread.
9955 (restore_current_thread_cleanup_dtor): Use old->inf directly
9956 instead of lookup up an inferior by id. Decref the inferior.
9957 Don't restore 'removable'.
9958 (make_cleanup_restore_current_thread): Same the inferior pointer
9959 in old, instead of the inferior number. Incref the inferior.
9960 Don't save/clear 'removable'.
9961
9bcb1f16
PA
99622017-04-19 Pedro Alves <palves@redhat.com>
9963
9964 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9965 unittests/scoped_restore-selftests.c.
9966 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
9967 * common/scoped_restore.h (scoped_restore_base): Make "class".
9968 (scoped_restore_base::release): New public method.
9969 (scoped_restore_base::scoped_restore_base): New protected ctor.
9970 (scoped_restore_base::m_saved_var): New protected field.
9971 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
9972 scoped_restore_base base class instead of m_saved_var directly.
9973 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
9974 (scoped_restore_tmpl::scoped_restore_tmpl(const
9975 scoped_restore_tmpl<T>&)): Likewise.
9976 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
9977 method.
9978 (scoped_restore_tmpl::saved_var): New method.
9979 (scoped_restore_tmpl::m_saved_var): Delete.
9980 * inferior.h (inferior::detaching): Now a bool.
9981 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
9982 cleanup.
9983 * unittests/scoped_restore-selftests.c: New file.
9984
26fcd539
PA
99852017-04-19 Pedro Alves <palves@redhat.com>
9986
9987 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
9988 Re-sort in alphabetic order.
9989
fdd243b0
PA
99902017-04-18 Pedro Alves <palves@redhat.com>
9991
9992 * xml-support.c (obstack_xml_printf): Delete.
9993 * xml-support.h (obstack_xml_printf): Delete.
9994
4895cde2
PA
99952017-04-18 Pedro Alves <palves@redhat.com>
9996
9997 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
9998 vdebug, verror, body_text, start_element, end_element, name,
9999 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
10000 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
10001 is_xinclude>: Make private and add m_ prefix.
10002 (gdb_xml_parser::body_text): New method, based on ...
10003 (gdb_xml_body_text): ... this. Adjust.
10004 (gdb_xml_parser::vdebug): New method, based on ...
10005 (gdb_xml_debug): ... this. Adjust.
10006 (gdb_xml_parser::verror): New method, based on ...
10007 (gdb_xml_error): ... this. Adjust.
10008 (gdb_xml_parser::start_element): New method, based on ...
10009 (gdb_xml_start_element): ... this. Adjust.
10010 (gdb_xml_start_element_wrapper): Defer to
10011 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
10012 (gdb_xml_parser::end_element): New method, based on ...
10013 (gdb_xml_end_element_wrapper): ... this. Adjust.
10014 (gdb_xml_parser::~gdb_xml_parser): Adjust.
10015 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
10016 (gdb_xml_parser::use_dtd): New method, based on ...
10017 (gdb_xml_use_dtd): ... this. Adjust.
10018 (gdb_xml_parser::parse): New method, based on ...
10019 (gdb_xml_parse): ... this. Adjust.
10020 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
10021 (xinclude_start_include): Adjust to call the parser's name method.
10022 (xml_xinclude_default, xml_xinclude_start_doctype)
10023 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
10024 method.
10025 (xml_process_xincludes): Adjust to call parser methods.
10026 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
10027 declarations.
10028
bd8a901f
PA
100292017-04-18 Pedro Alves <palves@redhat.com>
10030
10031 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
10032 gdb::optional<std::string>.
10033 * xml-support.c: Include <string>.
10034 (scope_level::scope_level(scope_level &&))
10035 (scope_level::~scope_level): Delete.
10036 (scope_level::body): Now a std::string.
10037 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
10038 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
10039 parameter.
10040 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
10041 (xinclude_parsing_data::output): Now a std::string reference.
10042 (xinclude_start_include): Adjust.
10043 (xml_xinclude_default): Adjust.
10044 (xml_process_xincludes): Add 'output' parameter, and return bool.
10045 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
10046 and return bool.
10047 * xml-tdesc.c: Include <unordered_map> and <string>.
10048 (tdesc_xml_cache): Delete.
10049 (tdesc_xml_cache_s): Delete.
10050 (xml_cache): Now an std::unordered_map.
10051 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
10052 (target_fetch_description_xml): Change return type to
10053 gdb::optional<std::string>, and adjust.
10054 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
10055 (target_fetch_description_xml): Change return type to
10056 gdb::optional<std::string>.
10057
d35d1958
PA
100582017-04-18 Pedro Alves <palves@redhat.com>
10059
10060 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10061 unittests/optional-selftests.c.
10062 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
10063 * unittests/optional-selftests.c: New file.
10064 * unittests/optional/assignment/1.cc: New file.
10065 * unittests/optional/assignment/2.cc: New file.
10066 * unittests/optional/assignment/3.cc: New file.
10067 * unittests/optional/assignment/4.cc: New file.
10068 * unittests/optional/assignment/5.cc: New file.
10069 * unittests/optional/assignment/6.cc: New file.
10070 * unittests/optional/assignment/7.cc: New file.
10071 * unittests/optional/cons/copy.cc: New file.
10072 * unittests/optional/cons/default.cc: New file.
10073 * unittests/optional/cons/move.cc: New file.
10074 * unittests/optional/cons/value.cc: New file.
10075 * unittests/optional/in_place.cc: New file.
10076 * unittests/optional/observers/1.cc: New file.
10077 * unittests/optional/observers/2.cc: New file.
10078
22796e97
PA
100792017-04-18 Pedro Alves <palves@redhat.com>
10080
10081 * common/gdb_optional.h: Include common/traits.h.
10082 (in_place_t): New type.
10083 (in_place): New constexpr variable.
10084 (optional::optional): Remove member initialization of
10085 m_instantiated.
10086 (optional::optional(in_place_t...)): New constructor.
10087 (optional::~optional): Use reset.
10088 (optional::optional(const optional&)): New.
10089 (optional::optional(const optional&&)): New.
10090 (optional::optional(T &)): New.
10091 (optional::optional(T &&)): New.
10092 (operator::operator=(const optional &)): New.
10093 (operator::operator=(optional &&)): New.
10094 (operator::operator= (const T &))
10095 (operator::operator= (T &&))
10096 (operator::emplace (Args &&... args)): Return a T&. Use reset.
10097 (operator::reset): New.
10098 (operator::m_instantiated):: Add in-class initializer.
10099 * common/traits.h: Include <type_traits>.
10100 (struct And): New types.
10101
a7fc9b61
PA
101022017-04-18 Pedro Alves <palves@redhat.com>
10103
10104 * xml-support.c: Include <vector>.
10105 (scope_level::scope_level(const gdb_xml_element *))
10106 (scope_level::scope_level(scope_level&&)): New.
10107 (scope_level::~scope_level): New.
10108 (scope_level_s): Delete.
10109 (gdb_xml_parser::scopes): Now a std::vector.
10110 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
10111 Use std::vector.
10112 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
10113 scope cleanup code.
10114 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
10115 of the scopes member. Use std::vector::emplace_back.
10116
010151c9
PA
101172017-04-18 Pedro Alves <palves@redhat.com>
10118
10119 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
10120 a bool.
10121 (gdb_xml_end_element): Change type of first parameter.
10122 (gdb_xml_cleanup): Rename to ...
10123 (gdb_xml_parser::~gdb_xml_parser): ... this.
10124 (gdb_xml_create_parser_and_cleanup): Delete with ...
10125 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
10126 to this new ctor.
10127 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
10128 using gdb_xml_create_parser_and_cleanup.
10129 (xinclude_parsing_data): Add ctor/dtor.
10130 (xml_xinclude_cleanup): Delete.
10131 (xml_process_xincludes): Create a local xinclude_parsing_data
10132 instead of heap-allocating one. Create a local gdb_xml_parser
10133 instead of heap-allocating one with
10134 gdb_xml_create_parser_and_cleanup.
10135
d56060f0
JB
101362017-04-18 John Baldwin <jhb@FreeBSD.org>
10137
10138 PR threads/20743
10139 * fbsd-nat.c (resume_one_thread_cb): Remove.
10140 (resume_all_threads_cb): Remove.
10141 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
10142 iterate_over_threads.
10143
305d16a9
JB
101442017-04-17 Joel Brobecker <brobecker@adacore.com>
10145
10146 * NEWS: Create a new section for the next release branch.
10147 Rename the section of the current branch, now that it has
10148 been cut.
10149
8bb57231
JB
101502017-04-17 Joel Brobecker <brobecker@adacore.com>
10151
10152 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
10153 * version.in: Bump version to 8.0.50.DATE-git.
10154
096c92dd
SDJ
101552017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
10156
10157 PR gdb/21385
10158 * windows-nat.c (windows_create_inferior): Declare 'allargs'
10159 independently of the host, and fix build breakage on Cygwin.
10160
0550c955
PA
101612017-04-13 Pedro Alves <palves@redhat.com>
10162
10163 * inferior.c (free_inferior): Convert to ...
10164 (inferior::~inferior): ... this dtor.
10165 (inferior::inferior): New ctor, factored out from ...
10166 (add_inferior_silent): ... here. Allocate the inferior with a new
10167 expression.
10168 (delete_inferior): Call delete instead of free_inferior.
10169 * inferior.h (gdb_environ, continuation): Forward declare.
10170 (inferior): Now a class. Add in-class initialization to all
10171 members. Make boolean fields bool, except 'detaching'.
10172 (inferior::inferior): New explicit ctor.
10173 (inferior::~inferior): New.
10174
e3d60dfc
PA
101752017-04-13 Pedro Alves <palves@redhat.com>
10176
10177 * inferior.c (init_inferior_list): Delete.
10178 * inferior.h (init_inferior_list): Delete.
10179
5fd69d0a
PA
101802017-04-13 Pedro Alves <palves@redhat.com>
10181
10182 PR threads/13217
10183 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
10184 (top level): Call it twice, with different thread sets.
10185
c6609450
PA
101862017-04-13 Pedro Alves <palves@redhat.com>
10187
10188 * thread.c: Include <algorithm>.
10189 (thread_array_cleanup): Delete.
10190 (scoped_inc_dec_ref): New class.
10191 (live_threads_count): New function.
10192 (set_thread_refcount): Delete.
10193 (tp_array_compar_ascending): Now a bool.
10194 (tp_array_compar): Convert to a std::sort comparison function.
10195 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
10196 and live_threads_count.
10197
2a00d7ce
PA
101982017-04-13 Pedro Alves <palves@redhat.com>
10199
10200 * infrun.c (follow_fork_inferior): Also switch the current
10201 inferior.
10202
441d7c93
PA
102032017-04-13 Pedro Alves <palves@redhat.com>
10204
10205 * breakpoint.c (watch_command_1): Save watchpoint-frame info
10206 before calling create_internal_breakpoint.
10207
808480f6
PA
102082017-04-13 Pedro Alves <palves@redhat.com>
10209
10210 * fork-child.c (execv_argv): New class.
10211 (breakup_args): Refactored as ...
10212 (execv_argv::init_for_no_shell): .. this method of execv_argv.
10213 Copy arguments to storage and replace separators with NULL
10214 terminators in place.
10215 (escape_bang_in_quoted_argument): Adjust to return bool.
10216 (execv_argv::execv_argv): New ctor.
10217 (execv_argv::init_for_shell): New method, factored out from
10218 fork_inferior. Don't strdup strings into the vector.
10219 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
10220 Remove free_vector_argv call.
10221
ad3d022a
YQ
102222017-04-13 Yao Qi <yao.qi@linaro.org>
10223
10224 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
10225 tdep->rx_psw_type.
10226
e6ddc3bf
YQ
102272017-04-13 Yao Qi <yao.qi@linaro.org>
10228
10229 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
10230 * rx-tdep.c (rx_gdbarch_init): Likewise.
10231
bfb8cf90
PA
102322017-04-13 Pedro Alves <palves@redhat.com>
10233
10234 * breakpoint.h (struct breakpoint): Reindent.
10235
f5336ca5
PA
102362017-04-13 Pedro Alves <palves@redhat.com>
10237
10238 * breakpoint.c (bp_location): Rename to ...
10239 (bp_locations): ... this. All references updated.
10240 (bp_location_count): Rename to ...
10241 (bp_locations_count): ... this. All references updated.
10242 (bp_location_placed_address_before_address_max): Rename to ...
10243 (bp_locations_placed_address_before_address_max): ... this. All
10244 references updated.
10245 (bp_location_shadow_len_after_address_max): Rename to ...
10246 (bp_locations_shadow_len_after_address_max): ... this. All
10247 references updated.
10248 (bp_location_compare_addrs): Rename to ...
10249 (bp_locations_compare_addrs): ... this. All references updated.
10250 (bp_location_compare):Rename to ...
10251 (bp_locations_compare): ... this. All references updated.
10252 (bp_location_target_extensions_update): Rename to ...
10253 (bp_locations_target_extensions_update): ... this. All references
10254 updated.
10255
be628ab8
SDJ
102562017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
10257
10258 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
10259 * common/common.m4: Check headers 'termios.h', 'termio.h' and
10260 'sgtty.h'.
10261 * common/gdb_termios.h: New file, with parts of "terminal.h".
10262 * inflow.c: Include "gdb_termios.h".
10263 * ser-unix.c: Include "gdb_termios.h".
10264 * terminal.h: Move terminal-related defines to
10265 "common/gdb_termios.h".
10266
8e9e35b1
TT
102672017-04-12 Tom Tromey <tom@tromey.com>
10268
10269 * probe.c (parse_probes): Update.
10270 * location.h (delete_event_location): Don't declare.
10271 (event_location_deleter::operator()): Update.
10272 * location.c (event_location_deleter::operator()): Rename from
10273 delete_event_location.
10274 * linespec.h (linespec_result) <location>: Change type to
10275 event_location_up.
10276 * linespec.c (canonicalize_linespec, event_location_to_sals)
10277 (decode_objc): Update.
10278 (linespec_result): Don't call delete_event_location.
10279 * breakpoint.c (create_breakpoints_sal)
10280 (bkpt_probe_create_sals_from_location)
10281 (strace_marker_create_sals_from_location): Update.
10282
16e802b9
TT
102832017-04-12 Tom Tromey <tom@tromey.com>
10284
10285 * linespec.h (struct linespec_result): Add constructor and
10286 destructor.
10287 (init_linespec_result, destroy_linespec_result)
10288 (make_cleanup_destroy_linespec_result): Don't declare.
10289 * linespec.c (init_linespec_result): Remove.
10290 (linespec_result::~linespec_result): Rename from
10291 destroy_linespec_result. Update.
10292 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
10293 Remove.
10294 * breakpoint.c (create_breakpoint, break_range_command)
10295 (decode_location_default): Update.
10296 * ax-gdb.c (agent_command_1): Update.
10297
d28cd78a
TT
102982017-04-12 Tom Tromey <tom@tromey.com>
10299
10300 * remote.c (remote_download_tracepoint): Update.
10301 * python/py-breakpoint.c (bppy_get_location): Update.
10302 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
10303 (gdbscm_breakpoint_location): Update.
10304 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
10305 * breakpoint.h (struct breakpoint) <location, location_range_end>:
10306 Change type to event_location_up.
10307 * breakpoint.c (create_overlay_event_breakpoint)
10308 (create_longjmp_master_breakpoint)
10309 (create_std_terminate_master_breakpoint)
10310 (create_exception_master_breakpoint)
10311 (breakpoint_event_location_empty_p, print_breakpoint_location)
10312 (print_one_breakpoint_location, create_thread_event_breakpoint)
10313 (init_breakpoint_sal, create_breakpoint)
10314 (print_recreate_ranged_breakpoint, break_range_command)
10315 (init_ada_exception_breakpoint, say_where): Update.
10316 (base_breakpoint_dtor): Don't call delete_event_location.
10317 (bkpt_print_recreate, tracepoint_print_recreate)
10318 (dprintf_print_recreate, update_static_tracepoint)
10319 (breakpoint_re_set_default): Update.
10320
711799d5
TT
103212017-04-12 Tom Tromey <tom@tromey.com>
10322
10323 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
10324 type of "to_do". Update.
10325 (compute_stack_depth): Use std::vector.
10326
52d214d3
TT
103272017-04-12 Tom Tromey <tom@tromey.com>
10328
10329 * printcmd.c (find_instruction_backward): Use std::vector.
10330
4c404b8b
TT
103312017-04-12 Tom Tromey <tom@tromey.com>
10332
10333 * symfile.c (objfilep): Remove typedef.
10334 (reread_symbols): Use a std::vector.
10335
156d9eab
TT
103362017-04-12 Tom Tromey <tom@tromey.com>
10337
10338 * mi/mi-main.c (exec_direction_forward): Remove.
10339 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
10340 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
10341 scoped_restore.
10342 * guile/guile.c (guile_repl_command, guile_command)
10343 (gdbscm_execute_gdb_command): Use scoped_restore.
10344 * go-exp.y (go_parse): Use scoped_restore.
10345 * d-exp.y (d_parse): Use scoped_restore.
10346 * cli/cli-decode.c (cmd_func): Use scoped_restore.
10347 * c-exp.y (c_parse): Use scoped_restore.
10348
4d89769a
TT
103492017-04-12 Tom Tromey <tom@tromey.com>
10350
10351 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
10352 (mi_parse): Update return type.
10353 (mi_parse_free): Remove.
10354 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
10355 (mi_parse::~mi_parse): Rename from mi_parse_free.
10356 (mi_parse_cleanup): Remove.
10357 (mi_parse): Return a unique_ptr. Use new.
10358 * mi/mi-main.c (mi_execute_command): Update.
10359
4b217cc7
TT
103602017-04-12 Tom Tromey <tom@tromey.com>
10361
10362 * location.c (explicit_location_lex_one): Return a
10363 unique_xmalloc_ptr.
10364 (string_to_explicit_location): Update. Remove cleanups.
10365
59d3651b
TT
103662017-04-12 Tom Tromey <tom@tromey.com>
10367
10368 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
10369 (compare_value_and_voffset): Change type. Update.
10370 (compute_vtable_size): Change type of "offset_vec".
10371 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
10372 (gnuv3_get_typeid): Remove extraneous declaration.
10373
b24b0d6c
TT
103742017-04-12 Tom Tromey <tom@tromey.com>
10375
10376 * charset.h (wchar_iterator): Fix comment.
10377
80a3b8c5
TT
103782017-04-12 Tom Tromey <tom@tromey.com>
10379
10380 * charset.c (iconv_wrapper): New class.
10381 (cleanup_iconv): Remove.
10382 (convert_between_encodings): Use it.
10383
c83dd867
TT
103842017-04-12 Tom Tromey <tom@tromey.com>
10385
10386 * symfile.h (increment_reading_symtab): Update type.
10387 * symfile.c (decrement_reading_symtab): Remove.
10388 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
10389 * psymtab.c (psymtab_to_symtab): Update.
10390 * dwarf2read.c (dw2_instantiate_symtab): Update.
10391
0e8621a0
TT
103922017-04-12 Tom Tromey <tom@tromey.com>
10393
10394 * jit.c (struct jit_reader): Declare separately. Add constructor
10395 and destructor. Change type of "handle".
10396 (loaded_jit_reader): Define separately.
10397 (jit_reader_load): Update. New "new".
10398 (jit_reader_unload_command): Use "delete".
10399 * gdb-dlfcn.h (struct dlclose_deleter): New.
10400 (gdb_dlhandle_up): New typedef.
10401 (gdb_dlopen, gdb_dlsym): Update types.
10402 (gdb_dlclose): Remove.
10403 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
10404 (gdb_dlsym): Change type of "handle".
10405 (make_cleanup_dlclose): Remove.
10406 (dlclose_deleter::operator()): Rename from gdb_dlclose.
10407 * compile/compile-c-support.c (load_libcc): Update.
10408
67d89901
TT
104092017-04-12 Tom Tromey <tom@tromey.com>
10410
10411 * symtab.h (find_pcs_for_symtab_line): Change return type.
10412 * symtab.c (find_pcs_for_symtab_line): Change return type.
10413 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
10414 type of "vec". Update.
10415 (ltpy_get_pcs_for_line): Update.
10416 * linespec.c (decode_digits_ordinary): Update.
10417
93921405
TT
104182017-04-12 Tom Tromey <tom@tromey.com>
10419
10420 * tracepoint.c (actions_command): Update.
10421 * python/python.c (python_command, python_interactive_command):
10422 Update.
10423 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
10424 * guile/guile.c (guile_command): Update.
10425 * defs.h (read_command_lines, read_command_lines_1): Return
10426 command_line_up.
10427 (command_lines_deleter): New struct.
10428 (command_line_up): New typedef.
10429 * compile/compile.c (compile_code_command)
10430 (compile_print_command): Update.
10431 * cli/cli-script.h (get_command_line, copy_command_lines): Return
10432 command_line_up.
10433 (make_cleanup_free_command_lines): Remove.
10434 * cli/cli-script.c (get_command_line, read_command_lines_1)
10435 (copy_command_lines): Return command_line_up.
10436 (while_command, if_command, read_command_lines, define_command)
10437 (document_command): Update.
10438 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
10439 Remove.
10440 * breakpoint.h (breakpoint_set_commands): Change type of
10441 "commands".
10442 * breakpoint.c (breakpoint_set_commands): Change type of
10443 "commands". Update.
10444 (do_map_commands_command, update_dprintf_command_list)
10445 (create_tracepoint_from_upload): Update.
10446
ffc2605c
TT
104472017-04-12 Tom Tromey <tom@tromey.com>
10448
10449 * tracepoint.c (scope_info): Update.
10450 * spu-tdep.c (spu_catch_start): Update.
10451 * python/python.c (gdbpy_decode_line): Update.
10452 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
10453 * python/py-breakpoint.c (bppy_init): Update.
10454 * probe.c (parse_probes): Update.
10455 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
10456 * location.h (event_location_deleter): New struct.
10457 (event_location_up): New typedef.
10458 (new_linespec_location, new_address_location, new_probe_location)
10459 (new_explicit_location, copy_event_location)
10460 (string_to_event_location, string_to_event_location_basic)
10461 (string_to_explicit_location): Update return type.
10462 (make_cleanup_delete_event_location): Remove.
10463 * location.c (new_linespec_location, new_address_location)
10464 (new_probe_location, new_explicit_location, copy_event_location):
10465 Return event_location_up.
10466 (delete_event_location_cleanup)
10467 (make_cleanup_delete_event_location): Remove.
10468 (string_to_explicit_location, string_to_event_location_basic)
10469 (string_to_event_location): Return event_location_up.
10470 * linespec.c (canonicalize_linespec, event_location_to_sals)
10471 (decode_line_with_current_source)
10472 (decode_line_with_last_displayed, decode_objc): Update.
10473 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
10474 * completer.c (location_completer): Update.
10475 * cli/cli-cmds.c (edit_command, list_command): Update.
10476 * breakpoint.c (create_overlay_event_breakpoint)
10477 (create_longjmp_master_breakpoint)
10478 (create_std_terminate_master_breakpoint)
10479 (create_exception_master_breakpoint)
10480 (create_thread_event_breakpoint): Update.
10481 (init_breakpoint_sal): Update. Remove some dead code.
10482 (create_breakpoint_sal): Change type of "location". Update.
10483 (create_breakpoints_sal, create_breakpoint, break_command_1)
10484 (dprintf_command, break_range_command, until_break_command)
10485 (init_ada_exception_breakpoint)
10486 (strace_marker_create_sals_from_location)
10487 (update_static_tracepoint, trace_command, ftrace_command)
10488 (strace_command, create_tracepoint_from_upload): Update.
10489 * break-catch-throw.c (re_set_exception_catchpoint): Update.
10490 * ax-gdb.c (agent_command_1): Update.
10491
8f10c932
PA
104922017-04-12 Pedro Alves <palves@redhat.com>
10493
10494 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
10495 * configure.tgt: Handle i[34567]86-*-go32* and
10496 i[34567]86-*-msdosdjgpp*.
10497 * i386-tdep.c (i386_svr4_reg_to_regnum):
10498 Make extern.
10499 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
10500 i386-go32-tdep.c.
10501 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
10502 * i386-go32-tdep.c: New file.
10503 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
10504 declarations.
10505
0a31ccfb
SM
105062017-04-12 Simon Marchi <simon.marchi@ericsson.com>
10507
10508 * aix-thread.c (pd_status2str): Change return type to const char *.
10509
e9bb3fbb
PA
105102017-04-12 Pedro Alves <palves@redhat.com>
10511
10512 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
10513 calls to set_gdbarch_gnu_triplet_regexp.
10514
53375380
PA
105152017-04-12 Pedro Alves <palves@redhat.com>
10516
10517 PR gdb/21323
10518 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
10519 New enum value.
10520 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
10521 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
10522 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
10523 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
10524 * gdbarch.h, gdbarch.c: Regenerate.
10525 * aarch64-tdep.c (aarch64_gdbarch_init): Override
10526 gdbarch_wchar_bit and gdbarch_wchar_signed.
10527 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
10528 * arm-tdep.c (arm_gdbarch_init): Likewise.
10529 * avr-tdep.c (avr_gdbarch_init): Likewise.
10530 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
10531 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
10532 * i386-tdep.c (i386_go32_init_abi): Likewise.
10533 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
10534 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
10535 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
10536 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
10537 * sh-tdep.c (sh_gdbarch_init): Likewise.
10538 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
10539 * sparc64-tdep.c (sparc64_init_abi): Likewise.
10540 * windows-tdep.c (windows_init_abi): Likewise.
10541 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
10542
53e710ac
PA
105432017-04-12 Pedro Alves <palves@redhat.com>
10544
10545 PR c++/21323
10546 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
10547 cplus_primitive_type_char32_t>: New enum values.
10548 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
10549 and cplus_primitive_type_char32_t.
10550 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
10551 32, use the archtecture's built-in type for char16_t and char32_t,
10552 respectively. Otherwise, fallback to init_integer_type as before,
10553 but make the type unsigned, and issue a complaint.
10554 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
10555
ab0538b8
AH
105562017-04-12 Alan Hayward <alan.hayward@arm.com>
10557
5e0e0422 10558 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
ab0538b8
AH
10559 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
10560
5430098f
SDJ
105612017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
10562
10563 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
10564 'const char *'.
10565
7c5ded6a
SDJ
105662017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
10567
10568 * common/common-utils.c (free_vector_argv): New function.
10569 * common/common-utils.h: Include <vector>.
10570 (free_vector_argv): New prototype.
10571 * darwin-nat.c (darwin_create_inferior): Rewrite function
10572 prototype in order to constify "exec_file" and accept a
10573 "std::string" for "allargs".
10574 * fork-child.c: Include <vector>.
10575 (breakup_args): Rewrite function, using C++.
10576 (fork_inferior): Rewrite function header, constify "exec_file_arg"
10577 and accept "std::string" for "allargs". Update the code to
10578 calculate "argv" based on "allargs". Update calls to "exec_fun"
10579 and "execvp".
10580 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
10581 order to constify "exec_file" and accept a "std::string" for
10582 "allargs".
10583 * go32-nat.c (go32_create_inferior): Likewise.
10584 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
10585 * infcmd.c (run_command_1): Constify "exec_file". Use
10586 "std::string" for inferior arguments.
10587 * inferior.h (fork_inferior): Update prototype.
10588 * linux-nat.c (linux_nat_create_inferior): Rewrite function
10589 prototype in order to constify "exec_file" and accept a
10590 "std::string" for "allargs".
10591 * nto-procfs.c (procfs_create_inferior): Likewise.
10592 * procfs.c (procfs_create_inferior): Likewise.
10593 * remote-sim.c (gdbsim_create_inferior): Likewise.
10594 * remote.c (extended_remote_run): Update code to accept
10595 "std::string" as argument.
10596 (extended_remote_create_inferior): Rewrite function prototype in
10597 order to constify "exec_file" and accept a "std::string" for
10598 "allargs".
10599 * rs6000-nat.c (super_create_inferior): Likewise.
10600 (rs6000_create_inferior): Likewise.
10601 * target.h (struct target_ops) <to_create_inferior>: Likewise.
10602 * windows-nat.c (windows_create_inferior): Likewise.
10603
ae0eee42
PA
106042017-04-11 Pedro Alves <palves@redhat.com>
10605
10606 * thread.c: Fix whitespace throughout.
10607
a6acac06
PR
106082017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
10609
10610 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
10611
64403bd1
AH
106122017-04-11 Alan Hayward <alan.hayward@arm.com>
10613
10614 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
10615
a5bef50f
SDJ
106162017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
10617
10618 PR gdb/21364
10619 * osdata.c (info_osdata): Check if 'type' is an empty string
10620 instead of NULL.
10621
9295a5a9
PA
106222017-04-10 Pedro Alves <palves@redhat.com>
10623
10624 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
10625 (ptid_to_global_thread_id, in_thread_list)
10626 (do_captured_list_thread_ids, set_resumed, set_running)
10627 (set_executing, set_stop_requested, finish_thread_state)
10628 (validate_registers_access, can_access_registers_ptid)
10629 (print_thread_info_1, switch_to_thread)
10630 (do_restore_current_thread_cleanup)
10631 (make_cleanup_restore_current_thread, thread_command)
10632 (thread_name_command): Use operator== instead of ptid_equal.
10633
996812e3
PA
106342017-04-10 Pedro Alves <palves@redhat.com>
10635
10636 * thread.c (struct current_thread_cleanup) <next>: Delete field.
10637 (current_thread_cleanup_chain): Delete.
10638 (restore_current_thread_cleanup_dtor)
10639 (make_cleanup_restore_current_thread): Remove references to
10640 current_thread_cleanup_chain.
10641
845b344f
AH
106422017-04-10 Alan Hayward <alan.hayward@arm.com>
10643
10644 * msp430-tdep.c (msp430_pseudo_register_read): Never return
10645 REG_UNKNOWN.
10646
803bdfe4
YQ
106472017-04-10 Yao Qi <yao.qi@linaro.org>
10648
10649 PR gdb/19942
10650 * gdbthread.h (thread_info::deletable): New method.
10651 (thread_info::incref): New method.
10652 (thread_info::decref): New method.
10653 (thread_info::refcount): Move it to private.
10654 * infrun.c (save_stop_context): Call inc_refcount.
10655 (release_stop_context_cleanup): Likewise.
10656 * thread.c (set_thread_exited): New function.
10657 (init_thread_list): Delete "tp" only it is deletable, otherwise
10658 call set_thread_exited.
10659 (delete_thread_1): Call set_thread_exited.
10660 (current_thread_cleanup) <inferior_pid>: Remove.
10661 <thread>: New field.
10662 (restore_current_thread_ptid_changed): Removed.
10663 (do_restore_current_thread_cleanup): Adjust.
10664 (restore_current_thread_cleanup_dtor): Don't call
10665 find_thread_ptid.
10666 (set_thread_refcount): Use dec_refcount.
10667 (make_cleanup_restore_current_thread): Adjust.
10668 (thread_apply_all_command): Call inc_refcount.
10669 (_initialize_thread): Don't call
10670 observer_attach_thread_ptid_changed.
10671
8c25b497
YQ
106722017-04-10 Yao Qi <yao.qi@linaro.org>
10673
10674 * thread.c (delete_thread_1): Hoist code on marking thread as
10675 exited.
10676
8473b447
SM
106772017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10678
10679 * windows-nat.c (windows_detach): Initialize ptid with
10680 minus_one_ptid.
10681
6670ec13
SM
106822017-04-07 Simon Marchi <simon.marchi@ericsson.com>
10683
10684 * unittests/ptid-selftests.c: Fix erroneous assert messages.
10685
ba2f91bb
AH
106862017-04-07 Alan Hayward <alan.hayward@arm.com>
10687
10688 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
10689 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
10690 (bfin_pseudo_register_write): Likewise
10691
436252de
SM
106922017-04-06 Simon Marchi <simon.marchi@ericsson.com>
10693
10694 * common/ptid.h (struct ptid): Change to...
10695 (class ptid_t): ... this.
10696 <ptid_t>: New constructors.
10697 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
10698 matches>: New methods.
10699 <make_null, make_minus_one>: New static methods.
10700 <pid>: Rename to...
10701 <m_pid>: ...this.
10702 <lwp>: Rename to...
10703 <m_lwp>: ...this.
10704 <tid>: Rename to...
10705 <m_tid>: ...this.
10706 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
10707 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
10708 as references, move comment to class ptid_t.
10709 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
10710 ptid_t static methods.
10711 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
10712 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
10713 Take ptid arguments as references, implement using ptid_t methods.
10714 * unittests/ptid-selftests.c: New file.
10715 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10716 unittests/ptid-selftests.c.
10717 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
10718
0dedf377
TP
107192017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
10720
10721 * python/python.c (python_run_simple_file): Cast mode literal to
10722 non-const char pointer as expected by PyFile_FromString.
10723
4e9868d4
SM
107242017-04-05 Simon Marchi <simon.marchi@ericsson.com>
10725
10726 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
10727 minus_one_ptid and null_ptid.
10728
9bf2a700
PA
107292017-04-05 Pedro Alves <palves@redhat.com>
10730
10731 * warning.m4 (build_warnings): Remove -Wno-write-strings.
10732 * configure: Regenerate.
10733
a121b7c1
PA
107342017-04-05 Pedro Alves <palves@redhat.com>
10735
10736 * ada-exp.y (yyerror): Constify.
10737 * ada-lang.c (bound_name, get_selections)
10738 (ada_variant_discrim_type)
10739 (ada_variant_discrim_name, ada_value_struct_elt)
10740 (ada_lookup_struct_elt_type, is_unchecked_variant)
10741 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
10742 (catch_ada_exception_command_split)
10743 (catch_ada_assert_command_split, catch_assert_command)
10744 (ada_op_name): Constify.
10745 * ada-lang.h (ada_yyerror, get_selections)
10746 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
10747 * arc-tdep.c (arc_print_frame_cache): Constify.
10748 * arm-tdep.c (arm_skip_stub): Constify.
10749 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
10750 (gen_aggregate_elt_ref): Constify.
10751 * bcache.c (print_bcache_statistics): Constify.
10752 * bcache.h (print_bcache_statistics): Constify.
10753 * break-catch-throw.c (catch_exception_command_1):
10754 * breakpoint.c (struct ep_type_description::description):
10755 Constify.
10756 (add_solib_catchpoint): Constify.
10757 (catch_fork_command_1): Add cast.
10758 (add_catch_command): Constify.
10759 * breakpoint.h (add_catch_command, add_solib_catchpoint):
10760 Constify.
10761 * bsd-uthread.c (bsd_uthread_state): Constify.
10762 * buildsym.c (patch_subfile_names): Constify.
10763 * buildsym.h (next_symbol_text_func, patch_subfile_names):
10764 Constify.
10765 * c-exp.y (yyerror): Constify.
10766 (token::oper): Constify.
10767 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
10768 * c-varobj.c (cplus_describe_child): Constify.
10769 * charset.c (find_charset_names): Add cast.
10770 (find_charset_names): Constify array and add const_cast.
10771 * cli/cli-cmds.c (complete_command, cd_command): Constify.
10772 (edit_command): Constify.
10773 * cli/cli-decode.c (lookup_cmd): Constify.
10774 * cli/cli-dump.c (dump_memory_command, dump_value_command):
10775 Constify.
10776 (struct dump_context): Constify.
10777 (add_dump_command, restore_command): Constify.
10778 * cli/cli-script.c (get_command_line): Constify.
10779 * cli/cli-script.h (get_command_line): Constify.
10780 * cli/cli-utils.c (check_for_argument): Constify.
10781 * cli/cli-utils.h (check_for_argument): Constify.
10782 * coff-pe-read.c (struct read_pe_section_data): Constify.
10783 * command.h (lookup_cmd): Constify.
10784 * common/print-utils.c (decimal2str): Constify.
10785 * completer.c (gdb_print_filename): Constify.
10786 * corefile.c (set_gnutarget): Constify.
10787 * cp-name-parser.y (yyerror): Constify.
10788 * cp-valprint.c (cp_print_class_member): Constify.
10789 * cris-tdep.c (cris_register_name, crisv32_register_name):
10790 Constify.
10791 * d-exp.y (yyerror): Constify.
10792 (struct token::oper): Constify.
10793 * d-lang.h (d_yyerror): Constify.
10794 * dbxread.c (struct header_file_location::name): Constify.
10795 (add_old_header_file, add_new_header_file, last_function_name)
10796 (dbx_next_symbol_text, add_bincl_to_list)
10797 (find_corresponding_bincl_psymtab, set_namestring)
10798 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
10799 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
10800 * defs.h (command_line_input, print_address_symbolic)
10801 (deprecated_readline_begin_hook): Constify.
10802 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
10803 Constify.
10804 * event-top.c (handle_line_of_input): Constify and add cast.
10805 * exceptions.c (catch_errors): Constify.
10806 * exceptions.h (catch_errors): Constify.
10807 * expprint.c (print_subexp_standard, op_string, op_name)
10808 (op_name_standard, dump_raw_expression, dump_raw_expression):
10809 * expression.h (op_name, op_string, dump_raw_expression):
10810 Constify.
10811 * f-exp.y (yyerror): Constify.
10812 (struct token::oper): Constify.
10813 (struct f77_boolean_val::name): Constify.
10814 * f-lang.c (f_word_break_characters): Constify.
10815 * f-lang.h (f_yyerror): Constify.
10816 * fork-child.c (fork_inferior): Add cast.
10817 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
10818 (new_variant): Constify.
10819 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
10820 * gdbarch.c: Regenerate.
10821 * gdbcore.h (set_gnutarget): Constify.
10822 * go-exp.y (yyerror): Constify.
10823 (token::oper): Constify.
10824 * go-lang.h (go_yyerror): Constify.
10825 * go32-nat.c (go32_sysinfo): Constify.
10826 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
10827 * guile/scm-cmd.c (cmdscm_function): Constify.
10828 * guile/scm-param.c (pascm_param_value): Constify.
10829 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
10830 (h8300sx_register_name): Constify.
10831 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
10832 Constify.
10833 * ia64-tdep.c (ia64_register_names): Constify.
10834 * infcmd.c (construct_inferior_arguments): Constify.
10835 (path_command, attach_post_wait): Constify.
10836 * language.c (show_range_command, show_case_command)
10837 (unk_lang_error): Constify.
10838 * language.h (language_defn::la_error)
10839 (language_defn::la_name_of_this): Constify.
10840 * linespec.c (decode_line_2): Constify.
10841 * linux-thread-db.c (thread_db_err_str): Constify.
10842 * lm32-tdep.c (lm32_register_name): Constify.
10843 * m2-exp.y (yyerror): Constify.
10844 * m2-lang.h (m2_yyerror): Constify.
10845 * m32r-tdep.c (m32r_register_names): Constify and make static.
10846 * m68hc11-tdep.c (m68hc11_register_names): Constify.
10847 * m88k-tdep.c (m88k_register_name): Constify.
10848 * macroexp.c (appendmem): Constify.
10849 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
10850 (upgrade_type, parse_external, parse_partial_symbols)
10851 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
10852 (new_symbol): Constify.
10853 * memattr.c (mem_info_command): Constify.
10854 * mep-tdep.c (register_name_from_keyword): Constify.
10855 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
10856 Constify.
10857 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
10858 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
10859 * mi/mi-main.c (captured_mi_execute_command): Constify and add
10860 cast.
10861 (mi_execute_async_cli_command): Constify.
10862 * mips-tdep.c (mips_register_name): Constify.
10863 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
10864 (am33_register_name, am33_2_register_name)
10865 * moxie-tdep.c (moxie_register_names): Constify.
10866 * nat/linux-osdata.c (osdata_type): Constify fields.
10867 * nto-tdep.c (nto_parse_redirection): Constify.
10868 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
10869 (lookup_child_selector): Constify.
10870 (objc_methcall::name): Constify.
10871 * objc-lang.h (lookup_objc_class, lookup_child_selector)
10872 (lookup_struct_typedef): Constify.
10873 * objfiles.c (pc_in_section): Constify.
10874 * objfiles.h (pc_in_section): Constify.
10875 * p-exp.y (struct token::oper): Constify.
10876 (yyerror): Constify.
10877 * p-lang.h (pascal_yyerror): Constify.
10878 * parser-defs.h (op_name_standard): Constify.
10879 (op_print::string): Constify.
10880 (exp_descriptor::op_name): Constify.
10881 * printcmd.c (print_address_symbolic): Constify.
10882 * psymtab.c (print_partial_symbols): Constify.
10883 * python/py-breakpoint.c (stop_func): Constify.
10884 (bppy_get_expression): Constify.
10885 * python/py-cmd.c (cmdpy_completer::name): Constify.
10886 (cmdpy_function): Constify.
10887 * python/py-event.c (evpy_add_attribute)
10888 (gdbpy_initialize_event_generic): Constify.
10889 * python/py-event.h (evpy_add_attribute)
10890 (gdbpy_initialize_event_generic): Constify.
10891 * python/py-evts.c (add_new_registry): Constify.
10892 * python/py-finishbreakpoint.c (outofscope_func): Constify.
10893 * python/py-framefilter.c (get_py_iter_from_func): Constify.
10894 * python/py-inferior.c (get_buffer): Add cast.
10895 * python/py-param.c (parm_constant::name): Constify.
10896 * python/py-unwind.c (fprint_frame_id): Constify.
10897 * python/python.c (gdbpy_parameter_value): Constify.
10898 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
10899 * remote.c (memory_packet_config::name): Constify.
10900 (show_packet_config_cmd, remote_write_bytes)
10901 (remote_buffer_add_string):
10902 * reverse.c (exec_reverse_once): Constify.
10903 * rs6000-tdep.c (variant::name, variant::description): Constify.
10904 * rust-exp.y (rustyyerror): Constify.
10905 * rust-lang.c (rust_op_name): Constify.
10906 * rust-lang.h (rustyyerror): Constify.
10907 * serial.h (serial_ops::name): Constify.
10908 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
10909 (sh_sh3e_register_name, sh_sh2e_register_name)
10910 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
10911 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
10912 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
10913 (sh_sh4al_dsp_register_name): Constify.
10914 * sh64-tdep.c (sh64_register_name): Constify.
10915 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
10916 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
10917 * stabsread.c (patch_block_stabs, read_type_number)
10918 (ref_map::stabs, ref_add, process_reference)
10919 (symbol_reference_defined, define_symbol, define_symbol)
10920 (error_type, read_type, read_member_functions, read_cpp_abbrev)
10921 (read_one_struct_field, read_struct_fields, read_baseclasses)
10922 (read_tilde_fields, read_struct_type, read_array_type)
10923 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
10924 (read_huge_number, read_range_type, read_args, common_block_start)
10925 (find_name_end): Constify.
10926 * stabsread.h (common_block_start, define_symbol)
10927 (process_one_symbol, symbol_reference_defined, ref_add):
10928 * symfile.c (get_section_index, add_symbol_file_command):
10929 * symfile.h (get_section_index): Constify.
10930 * target-descriptions.c (tdesc_type::name): Constify.
10931 (tdesc_free_type): Add cast.
10932 * target.c (find_default_run_target):
10933 (add_deprecated_target_alias, find_default_run_target)
10934 (target_announce_detach): Constify.
10935 (do_option): Constify.
10936 * target.h (add_deprecated_target_alias): Constify.
10937 * thread.c (print_thread_info_1): Constify.
10938 * top.c (deprecated_readline_begin_hook, command_line_input):
10939 Constify.
10940 (init_main): Add casts.
10941 * top.h (handle_line_of_input): Constify.
10942 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
10943 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
10944 (tfind_command): Rename to ...
10945 (tfind_command_1): ... this and constify.
10946 (tfind_command): New function.
10947 (tfind_end_command, tfind_start_command): Adjust.
10948 (encode_source_string): Constify.
10949 * tracepoint.h (encode_source_string): Constify.
10950 * tui/tui-data.c (tui_partial_win_by_name): Constify.
10951 * tui/tui-data.h (tui_partial_win_by_name): Constify.
10952 * tui/tui-source.c (tui_set_source_content_nil): Constify.
10953 * tui/tui-source.h (tui_set_source_content_nil): Constify.
10954 * tui/tui-win.c (parse_scrolling_args): Constify.
10955 * tui/tui-windata.c (tui_erase_data_content): Constify.
10956 * tui/tui-windata.h (tui_erase_data_content): Constify.
10957 * tui/tui-winsource.c (tui_erase_source_content): Constify.
10958 * tui/tui.c (tui_enable): Add cast.
10959 * utils.c (defaulted_query): Constify.
10960 (init_page_info): Add cast.
10961 (puts_debug, subset_compare): Constify.
10962 * utils.h (subset_compare): Constify.
10963 * varobj.c (varobj_format_string): Constify.
10964 * varobj.h (varobj_format_string): Constify.
10965 * vax-tdep.c (vax_register_name): Constify.
10966 * windows-nat.c (windows_detach): Constify.
10967 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
10968 * xml-support.c (gdb_xml_end_element): Constify.
10969 * xml-tdesc.c (tdesc_start_reg): Constify.
10970 * xstormy16-tdep.c (xstormy16_register_name): Constify.
10971 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
10972 * xtensa-tdep.h (xtensa_register_t::name): Constify.
10973
995816ba
PA
109742017-04-05 Pedro Alves <palves@redhat.com>
10975
10976 * proc-api.c (struct trans): Constify.
10977 (procfs_note): Constify.
10978 * proc-events.c (struct trans, syscall_table):
10979 * proc-flags.c (struct trans): Constify.
10980 * proc-utils.h (procfs_note): Constify.
10981 * proc-why.c (struct trans): Constify.
10982 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
10983 (procfs_detach): Constify.
10984 * sol-thread.c (struct string_map): Constify.
10985 (td_err_string, td_state_string): Constify.
10986
3e83a920
PA
109872017-04-05 Pedro Alves <palves@redhat.com>
10988
10989 * proc-api.c (procfs_filename): Don't initialize
10990 procfs_filename.
10991 (prepare_to_trace): Assume procfs_filename is non-NULL.
10992 (_initialize_proc_api): Give procfs_filename a default value here.
10993
63160a43
PA
109942017-04-05 Pedro Alves <palves@redhat.com>
10995
10996 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
10997 'cond_string' parameter.
10998 (extract_exception_regexp): Constify 'string' parameter.
10999 (catch_exception_command_1): Constify.
11000 * breakpoint.c (init_catchpoint)
11001 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
11002 parameter.
11003 (ep_parse_optional_if_clause, catch_fork_command_1)
11004 (catch_exec_command_1): Constify.
11005 * breakpoint.h (init_catchpoint): Constify 'cond_string'
11006 parameter.
11007 (ep_parse_optional_if_clause): Constify.
11008 * cli/cli-utils.c (remove_trailing_whitespace)
11009 (check_for_argument): Constify.
11010 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
11011 non-const overload.
11012 (check_for_argument): Likewise.
11013
9b2eba3d
PA
110142017-04-05 Pedro Alves <palves@redhat.com>
11015
11016 * event-top.c (command_line_handler): Add cast to execute_command
11017 call.
11018 * record-btrace.c (cmd_record_btrace_bts_start)
11019 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
11020 (cmd_record_btrace_start): Add cast to execute_command call.
11021 * record-full.c (record_full_goto_insn):
11022 * record.c (record_start, record_stop): Add cast to
11023 execute_command_to_string calls.
11024 (cmd_record_start): Add cast to execute_command calls.
11025
2adadf51
PA
110262017-04-05 Pedro Alves <palves@redhat.com>
11027
11028 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
11029 static inline function.
11030 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
11031 array and use gdb_PyArg_ParseTupleAndKeywords.
11032 * python/py-cmd.c (cmdpy_init): Likewise.
11033 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
11034 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
11035 (infpy_search_memory): Likewise.
11036 * python/py-objfile.c (objfpy_add_separate_debug_file)
11037 (gdbpy_lookup_objfile): Likewise.
11038 * python/py-symbol.c (gdbpy_lookup_symbol)
11039 (gdbpy_lookup_global_symbol): Likewise.
11040 * python/py-type.c (gdbpy_lookup_type): Likewise.
11041 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
11042 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
11043 Likewise.
11044
0d1f4ceb
PA
110452017-04-05 Pedro Alves <palves@redhat.com>
11046
11047 * python/python-internal.h (gdb_PyGetSetDef): New type.
11048 * python/py-block.c (block_object_getset)
11049 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
11050 * python/py-event.c (event_object_getset)
11051 (finish_breakpoint_object_getset): Likewise.
11052 * python/py-inferior.c (inferior_object_getset): Likewise.
11053 * python/py-infthread.c (thread_object_getset): Likewise.
11054 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
11055 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
11056 * python/py-objfile.c (objfile_getset): Likewise.
11057 * python/py-progspace.c (pspace_getset): Likewise.
11058 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
11059 Likewise.
11060 * python/py-record.c (recpy_record_getset): Likewise.
11061 * python/py-symbol.c (symbol_object_getset): Likewise.
11062 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
11063 Likewise.
11064 * python/py-type.c (type_object_getset, field_object_getset):
11065 Likewise.
11066 * python/py-value.c (value_object_getset): Likewise.
11067
4d759979
PA
110682017-04-05 Pedro Alves <palves@redhat.com>
11069
11070 * python/python-internal.h (gdb_PyObject_CallMethod)
11071 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
11072 New functions.
11073 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
11074 (PySys_GetObject, PySys_SetPath): New macros.
11075
fdf9e36f
PA
110762017-04-05 Pedro Alves <palves@redhat.com>
11077
11078 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
11079 info_osdata_command.
11080 * osdata.c (info_osdata_command): Rename to ...
11081 (info_osdata): ... this. Constify 'type' parameter, and remove
11082 the 'from_tty' parameter. Accept NULL TYPE.
11083 (info_osdata_command): New function.
11084 * osdata.h (info_osdata_command): Remove declaration.
11085 (info_osdata): New declaration.
11086
9f33b8b7
PA
110872017-04-05 Pedro Alves <palves@redhat.com>
11088
11089 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
11090 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
11091 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
11092 parameter.
11093 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
11094 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
11095 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
11096 parameter.
11097 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
11098 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
11099 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
11100 (mi_cmd_file_list_exec_source_files)
11101 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
11102 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
11103 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
11104 parameter.
11105 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
11106 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
11107 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
11108 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
11109 (mi_cmd_stack_info_frame): Constify 'command' parameter.
11110 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
11111 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
11112 'command' parameter.
11113 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
11114 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
11115 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
11116 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
11117 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
11118 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
11119 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
11120 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
11121 (mi_cmd_var_set_update_range): Constify 'command' parameter.
11122 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
11123 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
11124 parameter.
11125 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
11126 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
11127 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
11128 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
11129 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
11130 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
11131 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
11132 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
11133 (mi_cmd_data_list_changed_registers)
11134 (mi_cmd_data_write_register_values)
11135 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
11136 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
11137 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
11138 (mi_cmd_list_features, mi_cmd_list_target_features)
11139 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
11140 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
11141 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
11142 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
11143 (mi_cmd_trace_frame_collected): Constify 'command'
11144 parameter.
11145 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
11146 'command' parameter.
11147
67cb5b2d
PA
111482017-04-05 Pedro Alves <palves@redhat.com>
11149
11150 * ada-lang.c (ada_completer_word_break_characters): Now a const
11151 array.
11152 (ada_get_gdb_completer_word_break_characters): Constify.
11153 * completer.c (gdb_completer_command_word_break_characters)
11154 (gdb_completer_file_name_break_characters)
11155 (gdb_completer_quote_characters): Now const arrays.
11156 (get_gdb_completer_quote_characters): Constify.
11157 (set_rl_completer_word_break_characters): New function.
11158 (set_gdb_completion_word_break_characters)
11159 (complete_line_internal): Use it.
11160 * completer.h (get_gdb_completer_quote_characters): Constify.
11161 (set_rl_completer_word_break_characters): Declare.
11162 * f-lang.c (f_word_break_characters): Constify.
11163 * language.c (default_word_break_characters): Constify.
11164 * language.h (language_defn::la_word_break_characters): Constify.
11165 (default_word_break_characters): Constify.
11166 * top.c (init_main): Use set_rl_completer_word_break_characters.
11167
7a114964
PA
111682017-04-05 Pedro Alves <palves@redhat.com>
11169
11170 * aix-thread.c (aix_thread_pid_to_str)
11171 (aix_thread_extra_thread_info): Constify.
11172 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
11173 * bsd-uthread.c (bsd_uthread_extra_thread_info)
11174 (bsd_uthread_pid_to_str): Constify.
11175 * corelow.c (core_pid_to_str): Constify.
11176 * darwin-nat.c (darwin_pid_to_str): Constify.
11177 * fbsd-nat.c (fbsd_pid_to_str): Constify.
11178 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
11179 Constify.
11180 * gnu-nat.c (gnu_pid_to_str): Constify.
11181 * go32-nat.c (go32_pid_to_str): Constify.
11182 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
11183 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
11184 * inferior.c (inferior_pid_to_str): Constify.
11185 * linux-nat.c (linux_nat_pid_to_str): Constify.
11186 * linux-tdep.c (linux_core_pid_to_str): Constify.
11187 * linux-thread-db.c (thread_db_pid_to_str)
11188 (thread_db_extra_thread_info): Constify.
11189 * nto-tdep.c (nto_extra_thread_info): Constify.
11190 * nto-tdep.h (nto_extra_thread_info): Constify.
11191 * obsd-nat.c (obsd_pid_to_str): Constify.
11192 * procfs.c (procfs_pid_to_str): Constify.
11193 * ravenscar-thread.c (ravenscar_extra_thread_info)
11194 (ravenscar_pid_to_str): Constify.
11195 * remote-sim.c (gdbsim_pid_to_str): Constify.
11196 * remote.c (remote_threads_extra_info, remote_pid_to_str):
11197 Constify.
11198 * sol-thread.c (solaris_pid_to_str): Constify.
11199 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
11200 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
11201 * target.c (default_pid_to_str, target_pid_to_str)
11202 (normal_pid_to_str, default_pid_to_str): Constify.
11203 * target.h (target_ops::to_pid_to_str)
11204 (target_ops::to_extra_thread_info): Constify.
11205 (target_pid_to_str, normal_pid_to_str): Constify.
11206 * windows-nat.c (windows_pid_to_str): Constify.
11207 * gdbarch.sh (core_pid_to_str): Constify.
11208 * target-delegates.c: Regenerate.
11209 * gdbarch.h, gdbarch.c: Regenerate.
11210
69bbf465
PA
112112017-04-05 Pedro Alves <palves@redhat.com>
11212
11213 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
11214 the memory of the temporary warning_pre_print override.
11215 * utils.c (warning_pre_print): Constify.
11216 * utils.h (warning_pre_print): Constify.
11217
be47f9e8
PA
112182017-04-05 Pedro Alves <palves@redhat.com>
11219
11220 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
11221 (shell_command): New function.
11222 (make_command): Use std::string.
11223 (init_cli_cmds): Register shell_command instead of shell_escape.
11224
bde6261a
PA
112252017-04-05 Pedro Alves <palves@redhat.com>
11226
11227 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
11228 * tracepoint.c (default_collect): Don't initialize.
11229
b38ef47f
PA
112302017-04-05 Pedro Alves <palves@redhat.com>
11231
11232 * macroexp.c (macro_buffer::shared): Now a bool.
11233 (init_buffer): Update.
11234 (init_shared_buffer): Constify 'addr' parameter.
11235 (substitute_args, expand, macro_expand, macro_expand_next): Remove
11236 casts.
11237
f995bbe8
PA
112382017-04-05 Pedro Alves <palves@redhat.com>
11239
11240 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
11241 * disasm.c (set_disassembler_options): Constify local.
11242 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
11243
4a596fe2
SDJ
112442017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
11245
11246 PR gdb/21352
11247 * tracefile.c (tsave_command): Fix argument parsing for '-r'
11248 option.
11249
2cad08ea
YQ
112502017-04-05 Yao Qi <yao.qi@linaro.org>
11251
11252 * frame.c (frame_unwind_register_unsigned): Call
11253 frame_unwind_register_value.
11254
55a98976
YQ
112552017-04-05 Yao Qi <yao.qi@linaro.org>
11256
11257 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
11258 Use gdb_test_multiple, and don't match anchor.
11259
4ac40124
PA
112602017-04-05 Pedro Alves <palves@redhat.com>
11261
11262 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
11263 (Write After Approval): Remove Simon Marchi.
11264
c053b654
PA
112652017-04-05 Pedro Alves <palves@redhat.com>
11266
11267 * common/gdb_optional.h (optional::optional): Make constexpr and
11268 initialize m_dummy.
11269
4c7bf4f9
JB
112702017-04-04 John Baldwin <jhb@FreeBSD.org>
11271
11272 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
11273 (amd64fbsd_jmp_buf_reg_offset): Remove.
11274 (amd64fbsd_supply_uthread): Remove function.
11275 (amd64fbsd_collect_uthread): Remove function.
11276 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
11277 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
11278 (x86_64-*-freebsd*): Remove bsd-uthread.o.
11279 (fbsd-nat.c): Update comment.
11280 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
11281 (i386fbsd_jmp_buf_reg_offset): Remove.
11282 (i386fbsd_supply_uthread): Remove function.
11283 (i386fbsd_collect_uthread): Remove function.
11284 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
11285
1e1a8bef
JB
112862017-04-04 John Baldwin <jhb@FreeBSD.org>
11287
11288 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
11289 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
11290 * NEWS: Mention that support for FreeBSD/alpha was removed.
11291 * alpha-fbsd-tdep.c: Delete file.
11292 * config/alpha/fbsd.mh: Delete file.
11293 * configure.host: Delete alpha*-*-freebsd* and
11294 alpha*-*-kfreebsd*-gnu.
11295 * configure.tgt: Delete alpha*-*-freebsd* and
11296 alpha*-*-kfreebsd*-gnu.
11297
49907934
JB
112982017-04-04 John Baldwin <jhb@FreeBSD.org>
11299
11300 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
11301 amd64bsd_store_inferior_registers): Use ptid from regcache.
11302
6f77053d
PA
113032017-04-04 Pedro Alves <palves@redhat.com>
11304
11305 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
11306 data fields, make them private and add "m_" prefixes.
11307 (lnp_state_machine::lnp_state_machine): New ctor.
11308 (record_line, check_line_address, handle_set_discriminator)
11309 (handle_set_address, handle_advance_pc, handle_special_opcode)
11310 (handle_advance_line, handle_set_file, handle_negate_stmt)
11311 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
11312 (end_sequence, advance_line): New methods.
11313 (m_gdbarch, m_record_lines_p): New fields.
11314 (lnp_reader_state): Delete.
11315 (dwarf_record_line): Rename to ...
11316 (lnp_state_machine::record_line): ... adjust.
11317 (init_lnp_state_machine): Delete.
11318 (lnp_state_machine::lnp_state_machine): New.
11319 (check_line_address): Rename to ...
11320 (lnp_state_machine::check_line_address): This.
11321 (dwarf_decode_lines_1): Remove reference to "reader_state".
11322 Adjust lnp_state_machine having a non-default ctor. Use bool.
11323 State machine internal state manipulation moved to
11324 lnp_state_machine methods.
11325
9c541725
PA
113262017-04-04 Pedro Alves <palves@redhat.com>
11327
11328 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11329 unittests/offset-type-selftests.c.
11330 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
11331 * common/offset-type.h: New file.
11332 * common/preprocessor.h: New file.
11333 * common/traits.h: New file.
11334 * common/valid-expr.h: New file.
11335 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
11336 sect_offset and cu_offset strong typedefs throughout.
11337 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
11338 typedefs throughout.
11339 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
11340 sect_offset and cu_offset strong typedefs throughout.
11341 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
11342 typedefs throughout.
11343 * gdbtypes.h: Include "common/offset-type.h".
11344 (cu_offset): Now an offset type (strong typedef) instead of a
11345 struct.
11346 (sect_offset): Likewise.
11347 (union call_site_parameter_u): Rename "param_offset" field to
11348 "param_cu_off".
11349 * unittests/offset-type-selftests.c: New file.
11350
ecfb656c
PA
113512017-04-04 Pedro Alves <palves@redhat.com>
11352
11353 * common/underlying.h: New file.
11354 * dwarf2read.c: Include "common/gdb_optional.h" and
11355 "common/underlying.h".
11356 (dir_index, file_name_index): New types.
11357 (file_entry): Use them.
11358 (file_entry::include): Use to_underlying.
11359 (line_header::add_file_name): Use dir_index.
11360 (read_formatted_entries): Use gdb::optional. Read form before
11361 writting to file_entry.
11362 (dwarf_decode_line_header): Use dir_index.
11363 (lnp_state_machine::current_file): Use to_underlying.
11364 (lnp_state_machine::file): Change type to file_name_index.
11365 (dwarf_record_line): Use to_underlying.
11366 (init_lnp_state_machine): Use file_name_index.
11367 (dwarf_decode_lines_1): Use dir_index and file_name_index.
11368
d194f1fe
PA
113692017-04-04 Pedro Alves <palves@redhat.com>
11370
11371 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
11372 operator bool, has_value and get methods.
11373
fff8551c
PA
113742017-04-04 Pedro Alves <palves@redhat.com>
11375
11376 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
11377 fields.
11378 (line_header): Initialize all data fields. Change type of
11379 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
11380 Change type of include_dirs to std::vector<const char *>. Remove
11381 num_include_dirs, include_dirs_size. Change type of file_names to
11382 std::vector<file_entry>. Remove num_file_names, file_names_size.
11383 (line_header::line_header): New.
11384 (line_header::add_include_dir, line_header::add_file_name): New
11385 methods.
11386 (line_header::include_dir_at): Remove NULL check.
11387 (line_header::file_name_at): Add const overload.
11388 (line_header_up): New unique_ptr typedef.
11389 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
11390 std::vector. Remove free_line_header call.
11391 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
11392 free_line_header call.
11393 (free_cu_line_header): Delete.
11394 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
11395 (setup_type_unit_groups): Use line_header_up instead of cleanups.
11396 Adjust to use std::vector.
11397 (free_line_header): Delete.
11398 (free_line_header_voidp): Use delete.
11399 (add_include_dir): Replace with ...
11400 (line_header::add_include_dir): ... this method. Use std::vector.
11401 (add_file_name): Replace with ...
11402 (line_header::add_file_name): ... this method. Use std::vector.
11403 (add_include_dir_stub): Delete.
11404 (read_formatted_entries): Remove memset.
11405 (dwarf_decode_line_header): Return a line_header_up instead of a
11406 raw pointer. Remove cleanup handling. Pass lambdas to
11407 read_formatted_entries. Adjust to use line_header methods.
11408 (dwarf_decode_lines_1): Adjust to use line_header methods.
11409 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
11410 use std::vector.
11411
d62a8ae2
SM
114122017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
11413
11414 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
11415 instead of struct ptid.
11416
db3a1dc7
AH
114172017-05-04 Alan Hayward <alan.hayward@arm.com>
11418
11419 * frame.c (get_frame_register_bytes): Unwind using value.
11420 (put_frame_register_bytes): Likewise.
11421
b1b45502
IB
114222017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
11423
11424 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
11425 aggregate-like.
11426
ec13808e
JK
114272017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
11428
11429 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
11430
12316564
YQ
114312017-03-29 Yao Qi <yao.qi@linaro.org>
11432
11433 * gdbthread.h (struct thread_info): Declare constructor and
11434 destructor. Add some in-class member initializers.
11435 * thread.c (free_thread): Remove.
11436 (init_thread_list): Call delete instead of free_thread.
11437 (new_thread): Call thread_info constructor.
11438 (thread_info::thread_info): New function.
11439 (thread_info::~thread_info): New function.
11440 (delete_thread_1): Call delete instead of free_thread.
11441 (make_cleanup_restore_current_thread): Move tp and frame to
11442 inner block.
11443
fe5f7374
AK
114442017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
11445
11446 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
11447 (arc_skip_prologue): Likewise.
11448 (arc_make_frame_cache): Likewise.
11449 (arc_pv_get_operand): New function.
11450 (arc_is_in_prologue): Likewise.
11451 (arc_analyze_prologue): Likewise.
11452 (arc_print_frame_cache): Likewise.
11453 (MAX_PROLOGUE_LENGTH): New constant.
11454
eea78757
AK
114552017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
11456
11457 * configure.tgt: Add arc-insn.o.
11458 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
11459 (dump_arc_instruction_command): New function.
11460 (arc_fprintf_disasm): Likewise.
11461 (arc_disassemble_info): Likewise.
11462 (arc_insn_get_operand_value): Likewise.
11463 (arc_insn_get_operand_value_signed): Likewise.
11464 (arc_insn_get_memory_base_reg): Likewise.
11465 (arc_insn_get_memory_offset): Likewise.
11466 (arc_insn_get_branch_target): Likewise.
11467 (arc_insn_dump): Likewise.
11468 (arc_insn_get_linear_next_pc): Likewise.
11469 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
11470 (arc_disassemble_info): Likewise.
11471 (arc_insn_get_branch_target): Likewise.
11472 (arc_insn_get_linear_next_pc): Likewise.
11473 * NEWS: Mention new "maint print arc arc-instruction".
11474
3be78afd
AK
114752017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
11476
11477 * arc-tdep (maintenance_print_arc_list): New variable.
11478 (maintenance_print_arc_command): New function.
11479
296ec4fa
AK
114802017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
11481
11482 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
11483 Add "limm" and "reserved".
11484 (arc_cannot_fetch_register, arc_cannot_store_register): Add
11485 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
11486 * arc-tdep.h (arc_regnum): Likewise.
11487
f74f865e
MF
114882017-03-27 Max Filippov <jcmvbkbc@gmail.com>
11489
11490 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
11491 for THREADPTR register.
11492 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
11493 register.
11494 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
11495 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
11496 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
11497
0d0bf81a
MF
114982017-03-27 Max Filippov <jcmvbkbc@gmail.com>
11499
11500 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
11501 registers above gdbarch_num_regs (gdbarch) as privileged in
11502 call0 ABI.
11503
0ce4291e
MF
115042017-03-27 Max Filippov <jcmvbkbc@gmail.com>
11505
11506 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
11507 for a single specified register or for all registers in
11508 a0_base..a0_base + C0_NREGS range.
11509 (supply_gregset_reg): Call regcache_raw_supply for a single
11510 specified register or for all registers in a0_base..a0_base +
11511 C0_NREGS range.
11512
c56054f9
MF
115132017-03-27 Max Filippov <jcmvbkbc@gmail.com>
11514
11515 * arch/xtensa.h (C0_NREGS): Add definition.
11516 * xtensa-tdep.c (C0_NREGS): Remove definition.
11517
a4398628
MF
115182017-03-27 Max Filippov <jcmvbkbc@gmail.com>
11519
11520 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
11521 Drop xtensa_default_isa initialization.
11522 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
11523
8c43009f
PA
115242017-03-27 Pedro Alves <palves@redhat.com>
11525
11526 * dwarf2read.c (file_entry) <dir_index>: Add comment.
11527 (file_entry::include_dir): New method.
11528 (line_header::include_dir_at, line_header::file_name_at): New
11529 methods.
11530 (setup_type_unit_groups, setup_type_unit_groups)
11531 (psymtab_include_file_name): Simplify using the new methods.
11532 (lnp_state_machine) <the_line_header>: New field.
11533 <file>: Add comment.
11534 (lnp_state_machine::current_file): New method.
11535 (dwarf_record_line): Simplify using the new methods.
11536 (init_lnp_state_machine): Initialize the "the_line_header" field.
11537 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
11538 Simplify using the new methods.
11539
a7e80b9e
PA
115402017-03-27 Pedro Alves <palves@redhat.com>
11541
11542 * cp-name-parser.y (make_empty): Delete.
11543 (demangler_special, nested_name, ptr_operator, array_indicator)
11544 (direct_declarator, declarator_1): Use fill_comp instead of
11545 make_empty.
11546
21047726
PA
115472017-03-27 Pedro Alves <palves@redhat.com>
11548
11549 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
11550 to ATTRIBUTE_PRINTF.
11551 * solib-target.c (library_list_start_list): Print "string" not
11552 "version".
11553 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
11554 gdb_xml_error call.
11555
d721ba37
PA
115562017-03-27 Pedro Alves <palves@redhat.com>
11557
11558 * dwarf2read.c (struct file_and_directory): New.
11559 (dwarf2_get_dwz_file): Adjust to use std::string.
11560 (dw2_get_file_names_reader): Adjust to use file_and_directory.
11561 (find_file_and_directory): Adjust to return a file_and_directory
11562 object.
11563 (read_file_scope): Adjust to use file_and_directory. Remove
11564 make_cleanup/do_cleanups calls.
11565 (open_and_init_dwp_file): Adjust to use std::string. Remove
11566 make_cleanup/do_cleanups calls.
11567 * python/python.c (do_start_initialization): Adjust to ldirname
11568 returning a std::string.
11569 * utils.c (ldirname): Now returns a std::string.
11570 * utils.h (ldirname): Change return type to std::string.
11571 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
11572 returning a std::string.
11573 * xml-tdesc.c (file_read_description_xml): Likewise.
11574
ed771251
AH
115752017-03-24 Alan Hayward <alan.hayward@arm.com>
11576
11577 * regcache.c (regcache_debug_print_register): New function.
11578 * regcache.h (regcache_debug_print_register): New declaration.
11579 * target.c (debug_print_register): Remove.
11580 (target_fetch_registers): Call regcache_debug_print_register.
11581 (target_store_registers): Likewise.
11582
568c1b9f
PB
115832017-03-24 Pádraig Brady <pbrady@fb.com>
11584
11585 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
11586 reference beyond the 'lh->include_dirs' array before accessing to
11587 it.
11588 (psymtab_include_file_name): Likewise.
11589 (dwarf_decode_lines_1): Likewise.
11590 (dwarf_decode_lines): Likewise.
11591 (file_file_name): Likewise.
11592
3e00d44f
SM
115932017-03-23 Simon Marchi <simon.marchi@ericsson.com>
11594
11595 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
11596 inferior_ptid.
11597 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
11598 ps_lsetfpregs): Likewise.
11599 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
11600 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
11601 ps_lsetfpregs): Likewise.
11602 * target.c (target_fetch_registers, target_store_registers):
11603 Remove asserts.
11604
077ae656
AH
116052017-03-23 Alan Hayward <alan.hayward@arm.com>
11606
11607 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
11608
1e2b521d
YQ
116092017-03-23 Yao Qi <yao.qi@linaro.org>
11610
11611 * aarch64-tdep.c (aarch64_process_record_test): Declare.
11612 (_initialize_aarch64_tdep): Register it.
11613 (aarch64_record_load_store): Handle PRFM instruction.
11614 (aarch64_process_record_test): New function.
11615
33877125
YQ
116162017-03-23 Yao Qi <yao.qi@linaro.org>
11617
11618 * aarch64-tdep.c (aarch64_record_load_store): Fix code
11619 indentation.
11620
a0eef940
YQ
116212017-03-23 Yao Qi <yao.qi@linaro.org>
11622
11623 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
11624
3f2a3564
PR
116252017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
11626
11627 python/python.c (do_start_initialization): Fix memory leak.
11628
b67aeab0
SM
116292017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
11630
11631 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
11632 using get_ptrace_pid.
11633 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
11634 inferior_ptid.
11635 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
11636 inferior_ptid instead of pid.
11637
ffdbe864
YQ
116382017-03-22 Yao Qi <yao.qi@linaro.org>
11639
11640 * aarch64-tdep.c: Wrap locally used classes in anonymous
11641 namespace.
11642 * arm-tdep.c: Likewise.
11643 * linespec.c: Likewise.
11644 * ui-out.c: Likewise.
11645
9d736fbf
JG
116462017-03-22 Jonah Graham <jonah@kichwacoders.com>
11647
11648 PR gdb/19637
11649 * python/lib/gdb/printer/bound_registers.py: Import sys.
11650
3de88e9a
SM
116512017-03-21 Simon Marchi <simon.marchi@ericsson.com>
11652
11653 * windows-nat.c (do_windows_fetch_inferior_registers): Add
11654 windows_thread_info parameter and use it instead of
11655 current_thread.
11656 (windows_fetch_inferior_registers): Don't set current_thread,
11657 pass the thread to do_windows_fetch_inferior_registers. Use
11658 ptid from regcache instead of inferior_ptid.
11659 (do_windows_store_inferior_registers): Add windows_thread_info
11660 parameter and use it instead of current_thread.
11661 (windows_store_inferior_registers): Don't set current_thread,
11662 pass the thread to do_windows_store_inferior_registers. Use
11663 ptid from regcache instead of inferior_ptid.
11664
0e7b8f61
SM
116652017-03-21 Simon Marchi <simon.marchi@ericsson.com>
11666
11667 * ser-mingw.c (ser_windows_raw): Remove reference to
11668 struct serial::current_timeout.
11669
5badf10a
IR
116702017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
11671
11672 PR tdep/20928
11673 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
11674 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
11675 (sparc64_fsr_type): Fix %fsr decoding.
11676
cee59b3f
TW
116772017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
11678
11679 * python/py-record-btrace.c (btpy_insn_data): Change return type
11680 for Python 2.
11681
639a9038
SM
116822017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
11683
11684 * spu-linux-nat.c (spu_fetch_inferior_registers,
11685 spu_store_inferior_registers): Use ptid from regcache, set and
11686 restore inferior_ptid.
11687 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
11688 Likewise.
11689
bcc0c096
SM
116902017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
11691
11692 * i386-linux-nat.c (fetch_register, store_register,
11693 i386_linux_fetch_inferior_registers,
11694 i386_linux_store_inferior_registers): Use ptid from regcache.
11695 * ia64-linux-nat.c (ia64_linux_fetch_register,
11696 ia64_linux_store_register): Likewise.
11697 * inf-ptrace.c (inf_ptrace_fetch_register,
11698 inf_ptrace_store_register): Likewise.
11699 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
11700 m32r_linux_store_inferior_registers): Likewise.
11701 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
11702 m68kbsd_store_inferior_registers): Likewise.
11703 * m68k-linux-nat.c (fetch_register, store_register,
11704 m68k_linux_fetch_inferior_registers,
11705 m68k_linux_store_inferior_registers): Likewise.
11706 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
11707 m88kbsd_store_inferior_registers): Likewise.
11708 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
11709 mips_fbsd_store_inferior_registers): Likewise.
11710 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
11711 mips64_linux_regsets_store_registers): Likewise.
11712 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
11713 mipsnbsd_store_inferior_registers): Likewise.
11714 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
11715 mips64obsd_store_inferior_registers): Likewise.
11716 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
11717 Likewise.
11718 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
11719 ppcfbsd_store_inferior_registers): Likewise.
11720 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
11721 ppc_linux_store_inferior_registers): Likewise.
11722 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
11723 ppcnbsd_store_inferior_registers): Likewise.
11724 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
11725 ppcobsd_store_registers): Likewise.
11726 * procfs.c (procfs_fetch_registers, procfs_store_registers):
11727 Likewise.
11728 * ravenscar-thread.c (ravenscar_fetch_registers,
11729 ravenscar_store_registers, ravenscar_prepare_to_store):
11730 Likewise.
11731 * record-btrace.c (record_btrace_fetch_registers,
11732 record_btrace_store_registers, record_btrace_prepare_to_store):
11733 Likewise.
11734 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
11735 Lookup inferior using ptid from regcache, instead of
11736 current_inferior.
11737 * remote.c (remote_fetch_registers, remote_store_registers): Use
11738 ptid from regcache.
11739 * rs6000-nat.c (fetch_register, store_register): Likewise.
11740 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
11741 s390_linux_store_inferior_registers): Likewise.
11742 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
11743 shnbsd_store_inferior_registers): Likewise.
11744 * sol-thread.c (sol_thread_fetch_registers,
11745 sol_thread_store_registers): Likewise.
11746 * sparc-nat.c (sparc_fetch_inferior_registers,
11747 sparc_store_inferior_registers): Likewise.
11748 * tilegx-linux-nat.c (fetch_inferior_registers,
11749 store_inferior_registers): Likewise.
11750 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
11751 vaxbsd_store_inferior_registers): Likewise.
11752 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
11753 store_xtregs): Likewise.
11754
c0f55cc6
AV
117552017-03-20 Artemiy Volkov <artemiyv@acm.org>
11756
11757 PR gdb/14441
11758 * NEWS: Mention support for rvalue references in GDB and python.
11759 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
11760 supports both lvalue and rvalue references.
11761
15c0a2a9
AV
117622017-03-20 Artemiy Volkov <artemiyv@acm.org>
11763
11764 PR gdb/14441
11765 * gdbtypes.c (rank_one_type): Implement overloading
11766 resolution rules regarding rvalue references.
11767
aa006118
AV
117682017-03-20 Artemiy Volkov <artemiyv@acm.org>
11769
11770 PR gdb/14441
11771 * aarch64-tdep.c (aarch64_type_align)
11772 (aarch64_extract_return_value, aarch64_store_return_value): Change
11773 lvalue reference type checks to general reference type checks.
11774 * amd64-tdep.c (amd64_classify): Likewise.
11775 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
11776 Likewise.
11777 * arm-tdep.c (arm_type_align, arm_extract_return_value)
11778 (arm_store_return_value): Likewise.
11779 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
11780 * c-typeprint.c (c_print_type): Likewise.
11781 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
11782 (cplus_number_of_children, cplus_describe_child): Likewise.
11783 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
11784 * completer.c (expression_completer): Likewise.
11785 * cp-support.c (make_symbol_overload_list_adl_namespace):
11786 Likewise.
11787 * darwin-nat-info.c (info_mach_region_command): Likewise.
11788 * dwarf2loc.c (entry_data_value_coerce_ref)
11789 (value_of_dwarf_reg_entry): Likewise.
11790 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
11791 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
11792 Likewise.
11793 * findvar.c (extract_typed_address, store_typed_address):
11794 Likewise.
11795 * gdbtypes.c (rank_one_type): Likewise.
11796 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
11797 * infcall.c (value_arg_coerce): Likewise.
11798 * language.c (pointer_type): Likewise.
11799 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
11800 Likewise.
11801 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
11802 * mn10300-tdep.c (mn10300_type_align): Likewise.
11803 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
11804 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
11805 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
11806 Likewise.
11807 * printcmd.c (print_formatted, x_command): Likewise.
11808 * python/py-type.c (typy_get_composite, typy_template_argument):
11809 Likewise.
11810 * python/py-value.c (valpy_referenced_value)
11811 (valpy_get_dynamic_type, value_has_field): Likewise.
11812 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
11813 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
11814 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
11815 * spu-tdep.c (spu_scalar_value_p): Likewise.
11816 * symtab.c (lookup_symbol_aux): Likewise.
11817 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
11818 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
11819 Likewise.
11820 * valops.c (value_cast_pointers, value_cast)
11821 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
11822 (value_struct_elt, value_struct_elt_bitpos)
11823 (value_find_oload_method_list, find_overload_match)
11824 (value_rtti_indirect_type): Likewise.
11825 * valprint.c (val_print_scalar_type_p, generic_val_print):
11826 Likewise.
11827 * value.c (value_actual_type, value_as_address, unpack_long)
11828 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
11829 (coerce_ref): Likewise.
11830 * varobj.c (varobj_get_value_type): Likewise.
11831
3fcf899d
AV
118322017-03-20 Artemiy Volkov <artemiyv@acm.org>
11833
11834 PR gdb/14441
11835 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
11836 table of constants.
11837 * python/lib/gdb/command/explore.py: Support exploring values
11838 of rvalue reference types.
11839 * python/lib/gdb/types.py: Implement get_basic_type() for
11840 rvalue reference types.
11841 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
11842 constant.
11843 * python/py-value.c (valpy_getitem): Add an rvalue reference
11844 check.
11845 (valpy_reference_value): Add new parameter "refcode".
11846 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
11847 New wrappers for valpy_reference_value().
11848 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
11849 (gdbpy_invoke_xmethod): Likewise.
11850
4297a3f0
AV
118512017-03-20 Artemiy Volkov <artemiyv@acm.org>
11852
11853 PR gdb/14441
11854 * dwarf2read.c (process_die, read_type_die_1): Handle the
11855 DW_TAG_rvalue_reference_type DIE.
11856 (read_tag_reference_type): Add new parameter "refcode".
11857
e1cb3213
AV
118582017-03-20 Artemiy Volkov <artemiyv@acm.org>
11859
11860 PR gdb/14441
11861 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
11862 (c_type_print_modifier, c_type_print_varspec_suffix)
11863 (c_type_print_base): Support printing rvalue reference types.
11864 * c-valprint.c (c_val_print, c_value_print): Support printing
11865 rvalue reference values.
11866
e4347c89
AV
118672017-03-20 Artemiy Volkov <artemiyv@acm.org>
11868
11869 PR gdb/14441
11870 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
11871 typename.
11872 * cp-support.c (replace_typedefs): Handle
11873 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
11874 * python/py-type.c (typy_lookup_type): Likewise.
11875
53cc15f5
AV
118762017-03-20 Artemiy Volkov <artemiyv@acm.org>
11877
11878 PR gdb/14441
11879 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
11880 * parse.c (insert_type): Change assert statement.
11881 (follow_types): Handle rvalue reference types.
11882 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
11883 constant.
11884
a65cfae5
AV
118852017-03-20 Artemiy Volkov <artemiyv@acm.org>
11886
11887 PR gdb/14441
11888 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
11889 value_ref() interface.
11890 * c-valprint.c (c_value_print): Likewise.
11891 * infcall.c (value_arg_coerce): Likewise.
11892 * python/py-value.c (valpy_reference_value): Likewise.
11893 * valops.c (value_cast, value_reinterpret_cast)
11894 (value_dynamic_cast, typecmp): Likewise.
11895 (value_ref): Parameterize by kind of return value reference type.
11896 * value.h (value_ref): Add new parameter "refcode".
11897
3b224330
AV
118982017-03-20 Artemiy Volkov <artemiyv@acm.org>
11899
11900 PR gdb/14441
11901 * dwarf2read.c (read_tag_reference_type): Use
11902 lookup_lvalue_reference_type() instead of lookup_reference_type().
11903 * eval.c (evaluate_subexp_standard): Likewise.
11904 * f-exp.y: Likewise.
11905 * gdbtypes.c (make_reference_type, lookup_reference_type):
11906 Generalize with rvalue reference types.
11907 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
11908 convenience wrappers for lookup_reference_type().
11909 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
11910 reference kind parameter.
11911 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
11912 wrappers for lookup_reference_type().
11913 * guile/scm-type.c (gdbscm_type_reference): Use
11914 lookup_lvalue_reference_type() instead of lookup_reference_type().
11915 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
11916 * parse.c (follow_types): Likewise.
11917 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
11918 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
11919 Likewise.
11920 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
11921 (gdbpy_invoke_xmethod): Likewise.
11922 * stabsread.c: Provide extra argument to make_reference_type()
11923 call.
11924 * valops.c (value_ref, value_rtti_indirect_type): Use
11925 lookup_lvalue_reference_type() instead of lookup_reference_type().
11926
f9aeb8d4
AV
119272017-03-20 Artemiy Volkov <artemiyv@acm.org>
11928
11929 PR gdb/14441
11930 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
11931 (TYPE_IS_REFERENCE): New macro.
11932 (struct type): Add rvalue_reference_type field.
11933 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
11934
51457a05
MAL
119352017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
11936
11937 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
11938 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
11939 New function definition.
11940 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
11941 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
11942 New function declaration.
11943 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
11944 * mi/mi-interp.h: New file.
11945 * solib.c (info_sharedlibrary_command): Replace for loop with
11946 ALL_SO_LIBS macro
11947 * solib.h (update_solib_list): New function declaration.
11948 (so_list_head): Move macro.
11949 * solist.h (ALL_SO_LIBS): New macro.
11950
e696b3ad
MAL
119512017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
11952
11953 * infcmd.c (post_create_inferior): Remove unused argument in
11954 call to solib_add.
11955 * remote.c (remote_start_remote): Likewise.
11956 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
11957 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
11958 (enable_break): Likewise.
11959 * solib.c (update_solib_list): Remove unused target argument
11960 and its documentation.
11961 (solib_add): Remove unused target argument. Remove unused
11962 argument in call to update_solib_list.
11963 (info_sharedlibrary_command): Remove unused argument in call
11964 to update_solib_list.
11965 (sharedlibrary_command): Remove unused argument in call to
11966 solib_add.
11967 (handle_solib_event): Likewise.
11968 (reload_shared_libraries): Likewise.
11969 * solib.h (solib_add): Remove unused target argument.
11970
dcb84eda
AA
119712017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
11972
11973 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
11974 (s390_displaced_step_fixup): Cover relative branches with the
11975 default fixup handling. This fixes lack of support for some
11976 relative branch instructions.
11977
d9cb6cdc
SM
119782017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11979
11980 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
11981 ptid from regcache.
11982
1afaf9f4
SM
119832017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11984
11985 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
11986 i386_darwin_store_inferior_registers): Use ptid from regcache.
11987
aac12e24
SM
119882017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11989
11990 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
11991 i386bsd_store_inferior_registers): Use ptid from regcache.
11992
bbe1eef1
SM
119932017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11994
11995 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
11996 hppaobsd_store_registers): Use ptid from regcache.
11997
10799020
SM
119982017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11999
12000 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
12001 hppanbsd_store_registers): Use ptid from regcache.
12002
00204cf7
SM
120032017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
12004
12005 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
12006 from regcache. Use get_ptrace_pid.
12007
11a33714
SM
120082017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
12009
12010 * corelow.c (get_core_register_section): Use ptid from regcache,
12011 update doc.
12012
317cd492
SM
120132017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
12014
12015 * bsd-uthread.c (bsd_uthread_fetch_registers,
12016 bsd_uthread_store_registers): Use ptid from regcache, set and
12017 restore inferior_ptid.
12018
9ac8a7c2
SM
120192017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
12020
12021 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
12022 fetch_fp_regs, store_register, store_regs, store_fp_register,
12023 store_fp_regs): Use ptid from regcache.
12024
4ac4bb6a
SM
120252017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
12026
12027 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
12028 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
12029 store_vfp_regs): Use ptid from regcache.
12030
9bcbdca8
PA
120312017-03-17 Pedro Alves <palves@redhat.com>
12032
12033 PR remote/21188
12034 * ser-base.c (ser_base_wait_for): Add comment.
12035 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
12036 version.
12037 * ser-unix.c (hardwire_raw): Remove reference to
12038 scb->current_timeout.
12039 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
12040 (hardwire_ops): Install ser_base_readchar instead of
12041 hardwire_readchar.
12042 * serial.h (struct serial) <current_timeout, timeout_remaining>:
12043 Remove fields.
12044
7503099f
JG
120452017-03-17 Jonah Graham <jonah@kichwacoders.com>
12046
12047 PR gdb/19637
12048 * python/lib/gdb/printer/bound_registers.py: Add support for
12049 Python 3.
12050
7942e96e
AA
120512017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
12052
12053 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
12054 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
12055 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
12056 byte_offset to subobj_byte_offset. Fix the handling of
12057 DWARF_VALUE_STACK on big-endian targets when coming via an
12058 implicit pointer.
12059 (dwarf2_evaluate_loc_desc): Adjust call to
12060 dwarf2_evaluate_loc_desc_full.
12061 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
12062 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
12063
ba14f379
YQ
120642017-03-16 Yao Qi <yao.qi@linaro.org>
12065
12066 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
12067 and REVSH instructions.
12068
b121eeb9
YQ
120692017-03-16 Yao Qi <yao.qi@linaro.org>
12070
12071 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
12072 (arm_record_test): Declare.
12073 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
12074 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
12075 align with the manual.
12076 (thumb_record_misc): Adjust the code order to align with the
12077 manual.
12078 (thumb2_record_decode_insn_handler): Fix instruction matching.
12079 (instruction_reader_thumb): New class.
12080 (arm_record_test): New function.
12081
728a7913
YQ
120822017-03-16 Yao Qi <yao.qi@linaro.org>
12083
12084 * arm-tdep.c (abstract_memory_reader): New class.
12085 (instruction_reader): New class.
12086 (extract_arm_insn): Add argument 'reader'. Callers updated.
12087 (decode_insn): Likewise.
12088
34b43320
DE
120892017-03-16 Doug Evans <dje@google.com>
12090
a7c0469f
DE
12091 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
12092 member. Change type of TYPE member to SCM. All uses updated.
12093 (lsscm_make_lazy_string_smob): Add assert.
12094 (lsscm_make_lazy_string): Flag bad length values.
12095 (lsscm_elt_type): New function.
12096 (gdbscm_lazy_string_to_value): Rewrite to use
12097 lsscm_safe_lazy_string_to_value.
12098 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
12099 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
12100 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
12101 in incoming type.
12102 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
12103 * guile/scm-type.c (tyscm_scm_to_type): New function.
12104
121052017-03-15 Doug Evans <dje@google.com>
12106
34b43320
DE
12107 PR python/17728, python/18439, python/18779
12108 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
12109 member. Change type of TYPE member to PyObject *. All uses updated.
12110 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
12111 (gdbpy_create_lazy_string_object): Flag bad length values.
12112 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
12113 Handle typedefs in incoming type.
12114 (stpy_lazy_string_elt_type): New function.
12115 (gdbpy_extract_lazy_string): Call it.
12116 * python/py-value.c (valpy_lazy_string): Flag bad length values.
12117 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
12118 typedefs in incoming type.
12119
a3a5fecc
DE
121202017-03-16 Doug Evans <dje@google.com>
12121
12122 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
12123 * guile/scm-type.c (tyscm_scm_to_type): New function.
12124
28f1c605
JW
121252017-03-16 Jiong Wang <jiong.wang@arm.com>
12126
12127 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
12128 "ULONGEST" for "skip".
12129
87c336f6
AA
121302017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
12131
12132 PR gdb/21220
12133 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
12134 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
12135 (inf_ptrace_peek_poke): ...here. New function. Now also loop
12136 over ptrace peek/poke until end of buffer or error.
12137
cf81cf60
SM
121382017-03-14 Simon Marchi <simon.marchi@ericsson.com>
12139
12140 * parse.c (length_of_subexp): Make static.
12141 * parser-defs.h (length_of_subexp): Remove.
12142
a379284a
AA
121432017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
12144
12145 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
12146 as well.
12147
8a6200ba
PA
121482017-03-14 Pedro Alves <palves@redhat.com>
12149
12150 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
12151 (main): Use std::unique_ptr. Remove calls to
12152 cp_demangled_name_parse_free.
12153
f79ec206
SM
121542017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
12155
12156 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
12157 alphabsd_store_inferior_registers): Use regcache->ptid instead
12158 of inferior_ptid.
12159
edb5fb00
SM
121602017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
12161
12162 * aix-thread.c (aix_thread_fetch_registers,
12163 aix_thread_store_registers): Use regcache->ptid instead of
12164 inferior_ptid.
12165
55119686
SM
121662017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
12167
12168 * aarch64-linux-nat.c (fetch_gregs_from_thread,
12169 store_gregs_to_thread, fetch_fpregs_from_thread,
12170 store_fpregs_to_thread): Use regcache->ptid instead of
12171 inferior_ptid.
12172
6a06fbb7
SM
121732017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
12174
12175 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
12176 amd64_linux_fetch_inferior_registers): Use regcache->ptid
12177 instead of inferior_ptid.
12178
c6386875
SM
121792017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
12180
12181 * target.c (target_fetch_registers, target_store_registers): Add
12182 assert.
12183
ddaaf0fb
SM
121842017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
12185
12186 * regcache.h (regcache_get_ptid): New function.
12187 * regcache.c (regcache_get_ptid): New function.
12188
b9da89d1 121892017-03-13 Mark Wielaard <mark@klomp.org>
12190
12191 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
12192
5f4d1085
KS
121932017-03-10 Keith Seitz <keiths@redhat.com>
12194
12195 PR c++/8218
12196 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
12197
c65d6b55
PA
121982017-03-08 Pedro Alves <palves@redhat.com>
12199
12200 PR gdb/18360
12201 * infrun.c (start_step_over, do_target_resume, resume)
12202 (restart_threads): Assert we're not resuming a thread that is
12203 meant to be stopped.
12204 (infrun_thread_stop_requested_callback): Delete.
12205 (infrun_thread_stop_requested): If the thread is internally
12206 stopped, queue a pending stop event and clear the thread's
12207 inline-frame state.
12208 (handle_stop_requested): New function.
12209 (handle_syscall_event, handle_inferior_event_1): Use
12210 handle_stop_requested.
12211 (handle_stop_requested): New function.
12212 (handle_signal_stop): Set the thread's stop_signal here instead of
12213 at caller.
12214 (finish_step_over): Clear step over info unconditionally.
12215 (handle_signal_stop): If the user had interrupted the event
12216 thread, consider the stop a random signal.
12217 (handle_signal_stop) <signal arrived while stepping over
12218 breakpoint>: Don't restart threads here.
12219 (stop_waiting): Don't clear step-over info here.
12220
15c22686
PA
122212017-03-08 Pedro Alves <palves@redhat.com>
12222
12223 PR 21206
12224 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
12225 goes to argument 2, not 1.
12226
6e5d74e7
PA
122272017-03-08 Pedro Alves <palves@redhat.com>
12228
12229 PR cli/21218
12230 * top.c (gdb_readline_wrapper): Avoid passing NULL to
12231 display_gdb_prompt.
12232 (command_line_input): Add comment.
12233
9753a2f6
PA
122342017-03-08 Pedro Alves <palves@redhat.com>
12235
12236 PR tui/21216
12237 * tui/tui-file.c (tui_file::write): New.
12238 * tui/tui-file.h (tui_file): Override "write".
12239 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
12240 factored out from ...
12241 (tui_puts): ... here.
12242 (tui_putc): Use them.
12243 (tui_write): New function.
12244 * tui/tui-io.h (tui_write): Declare.
12245
1672e0d9
SDJ
122462017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
12247
12248 * Makefile.in (SFILES): Replace "environ.c" with
12249 "common/environ.c".
12250 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
12251 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
12252 to...
12253 * common/environ.c: ... here.
12254 * environ.h: Moved to...
12255 * common/environ.h: ... here.
12256
f7bb4e3a
PB
122572017-03-07 Peter Bergner <bergner@vnet.ibm.com>
12258
12259 * gdbarch.sh (pstring_ptr): New static function.
12260 (gdbarch_disassembler_options): Use it.
12261 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
12262 not valid_disassembler_option->name.
12263 * gdbarch.c: Regenerate.
12264
e45ced6c
PB
122652017-03-07 Peter Bergner <bergner@vnet.ibm.com>
12266
12267 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
12268
5f6fd321
PA
122692017-03-07 Pedro Alves <palves@redhat.com>
12270
12271 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
12272
6dbb839a 122732017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
4a612d6f
WT
12274
12275 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
12276 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
12277 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
6dbb839a 12278 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
4a612d6f 12279
d274ecf4
SM
122802017-03-06 Simon Marchi <simon.marchi@ericsson.com>
12281
12282 * xtensa-linux-nat.c (fetch_gregs): Remove const.
12283
df97be55
SM
122842017-03-03 Simon Marchi <simon.marchi@ericsson.com>
12285
12286 * remote.c (remote_add_target_side_commands): Use range-based
12287 for loop.
12288
7d45f3df
YQ
122892017-03-03 Yao Qi <yao.qi@linaro.org>
12290
12291 PR gdb/21165
12292 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
12293 value is lazy.
12294 * valprint.c (common_val_print): Likewise.
12295
65b48a81
PB
122962017-02-28 Peter Bergner <bergner@vnet.ibm.com>
12297
12298 * NEWS: Mention new set/show disassembler-options commands.
12299 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
12300 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
12301 (prospective_options): New static variable.
12302 (gdb_disassembler::gdb_disassembler): Initialize
12303 m_di.disassembler_options.
12304 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
12305 (get_disassembler_options): New function.
12306 (set_disassembler_options): Likewise.
12307 (set_disassembler_options_sfunc): Likewise.
12308 (show_disassembler_options_sfunc): Likewise.
12309 (disassembler_options_completer): Likewise.
12310 (_initialize_disasm): Likewise.
12311 * disasm.h (get_disassembler_options): New prototype.
12312 (set_disassembler_options): Likewise.
12313 * gdbarch.sh (gdbarch_disassembler_options): New variable.
12314 (gdbarch_verify_disassembler_options): Likewise.
12315 * gdbarch.c: Regenerate.
12316 * gdbarch.h: Likewise.
12317 * arm-tdep.c (num_disassembly_options): Delete.
12318 (set_disassembly_style): Likewise.
12319 (arm_disassembler_options): New static variable.
12320 (set_disassembly_style_sfunc): Convert short style name into long
12321 option name. Call set_disassembler_options.
12322 (show_disassembly_style_sfunc): New function.
12323 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
12324 set_gdbarch_verify_disassembler_options.
12325 (_initialize_arm_tdep): Delete regnames variable and update callers.
12326 (arm_disassembler_options): Initialize.
12327 (disasm_options): New variable.
12328 (num_disassembly_options): Rename from this...
12329 (num_disassembly_styles): ...to this. Compute by scanning through
12330 disasm_options.
12331 (valid_disassembly_styles): Initialize using disasm_options.
12332 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
12333 set_arm_regname_option.
12334 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
12335 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
12336 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
12337 set_gdbarch_verify_disassembler_options.
12338 * s390-tdep.c (s390_disassembler_options): New static variable.
12339 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
12340 set_gdbarch_verify_disassembler_options.
12341
d538e36d
SM
123422017-02-27 Simon Marchi <simon.marchi@ericsson.com>
12343
12344 * remote.c (remote_add_target_side_condition): Remove "struct"
12345 keyword from range-based for loop.
12346
83621223
SM
123472017-02-27 Simon Marchi <simon.marchi@ericsson.com>
12348
12349 * remote.c (remote_add_target_side_condition): Use range-based
12350 for loop. Update comment.
12351
2123df0e
YQ
123522017-02-27 Yao Qi <yao.qi@linaro.org>
12353
12354 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
12355
8e368124
AH
123562017-02-26 Alan Hayward <alan.hayward@arm.com>
12357
12358 * regcache.c (regcache_raw_update): New function.
12359 (regcache_raw_read): Move code to regcache_raw_update.
12360 * regcache.h (regcache_raw_update): New declaration.
12361 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
12362
a49dd8dd
JK
123632017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
12364
12365 * dwarf2read.c (create_debug_type_hash_table): Initialize
12366 header.signature and header.type_offset_in_tu.
12367
34e4bae9
PA
123682017-02-24 Pedro Alves <palves@redhat.com>
12369
12370 * symtab.c (make_file_symbol_completion_list_1): Use
12371 add_symtab_completions.
12372
b0e4b369
AH
123732017-02-24 Alan Hayward <alan.hayward@arm.com>
12374
12375 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
12376
975c21ab
AH
123772017-02-24 Alan Hayward <alan.hayward@arm.com>
12378
12379 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
12380 I386_MAX_REGISTER_SIZE.
12381 (i386_pseudo_register_write): Likewise.
12382 (i386_process_record): Likewise.
12383 * i387-tdep.c (i387_supply_xsave): Likewise.
12384 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
12385 (store_register): Likewise.
12386
14bc53a8
PA
123872017-02-23 Pedro Alves <palves@redhat.com>
12388
12389 * ada-lang.c: Include "common/function-view.h".
12390 (ada_iterate_over_symbols): Adjust to use function_view as
12391 callback type.
12392 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
12393 (ada_make_symbol_completion_list): Use a lambda.
12394 (ada_exc_search_name_matches): Delete.
12395 (name_matches_regex): New.
12396 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
12397 * compile/compile-c-support.c: Include "common/function-view.h".
12398 (print_one_macro): Change prototype to accept a ui_file pointer.
12399 (write_macro_definitions): Use a lambda.
12400 * dwarf2read.c: Include "common/function-view.h".
12401 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
12402 (dw2_expand_symtabs_matching): Adjust to use function_view as
12403 callback type.
12404 * language.h: Include "common/function-view.h".
12405 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
12406 function_view as callback type.
12407 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
12408 * linespec.c: Include "common/function-view.h".
12409 (collect_info::add_symbol): New method.
12410 (struct symbol_and_data_callback, iterate_inline_only, struct
12411 symbol_matcher_data, iterate_name_matcher): Delete.
12412 (iterate_over_all_matching_symtabs): Adjust to use function_view
12413 as callback type and lambdas.
12414 (iterate_over_file_blocks): Adjust to use function_view as
12415 callback type.
12416 (decode_compound_collector): Now a class with private fields.
12417 (decode_compound_collector::release_symbols): New method.
12418 (collect_one_symbol): Rename to...
12419 (decode_compound_collector::operator()): ... this and adjust.
12420 (lookup_prefix_sym): decode_compound_collector construction bits
12421 move to decode_compound_collector ctor. Pass the
12422 decode_compound_collector object directly as callback. Remove
12423 cleanups and use decode_compound_collector::release_symbols
12424 instead.
12425 (symtab_collector): Now a class with private fields.
12426 (symtab_collector::release_symtabs): New method.
12427 (add_symtabs_to_list): Rename to...
12428 (symtab_collector::operator()): ... this and adjust.
12429 (collect_symtabs_from_filename): symtab_collector construction
12430 bits move to symtab_collector ctor. Pass the symtab_collector
12431 object directly as callback. Remove cleanups and use
12432 symtab_collector::release_symtabs instead.
12433 (collect_symbols): Delete.
12434 (add_matching_symbols_to_info): Use lambdas.
12435 * macrocmd.c (print_macro_callback): Delete.
12436 (info_macro_command): Use a lambda.
12437 (info_macros_command): Pass print_macro_definition as callable
12438 directly.
12439 (print_one_macro): Remove 'ignore' parameter.
12440 (macro_list_command): Adjust.
12441 * macrotab.c (macro_for_each_data::fn): Now a function_view.
12442 (macro_for_each_data::user_data): Delete field.
12443 (foreach_macro): Adjust to call the function_view.
12444 (macro_for_each): Adjust to use function_view as callback type.
12445 (foreach_macro_in_scope): Adjust to call the function_view.
12446 (macro_for_each_in_scope): Adjust to use function_view as callback
12447 type.
12448 * macrotab.h: Include "common/function-view.h".
12449 (macro_callback_fn): Declare a prototype instead of a pointer.
12450 Remove "user_data" parameter.
12451 (macro_for_each, macro_for_each_in_scope): Adjust to use
12452 function_view as callback type.
12453 * psymtab.c (partial_map_expand_apply)
12454 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
12455 Adjust to use function_view as callback type and to return bool.
12456 (psym_expand_symtabs_matching): Adjust to use function_view as
12457 callback types.
12458 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
12459 to use function_view as callback type and to return bool.
12460 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
12461 callback types.
12462 * symfile.c (expand_symtabs_matching): Adjust to use function_view
12463 as callback types.
12464 * symfile.h: Include "common/function-view.h".
12465 (expand_symtabs_file_matcher_ftype)
12466 (expand_symtabs_symbol_matcher_ftype)
12467 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
12468 return bool.
12469 (quick_symbol_functions::map_symtabs_matching_filename)
12470 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
12471 function_view as callback type and return bool.
12472 (expand_symtabs_matching): Adjust to use function_view as callback
12473 type.
12474 (maintenance_expand_name_matcher)
12475 (maintenance_expand_file_matcher): Delete.
12476 (maintenance_expand_symtabs): Use lambdas.
12477 * symtab.c (iterate_over_some_symtabs): Adjust to use
12478 function_view as callback types and return bool.
12479 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
12480 of a cleanup.
12481 (lookup_symtab_callback): Delete.
12482 (lookup_symtab): Use a lambda.
12483 (iterate_over_symbols): Adjust to use function_view as callback
12484 type.
12485 (struct search_symbols_data, search_symbols_file_matches)
12486 (search_symbols_name_matches): Delete.
12487 (search_symbols): Use a pair of lambdas.
12488 (struct add_name_data, add_macro_name, symbol_completion_matcher)
12489 (symtab_expansion_callback): Delete.
12490 (default_make_symbol_completion_list_break_on_1): Use lambdas.
12491 * symtab.h: Include "common/function-view.h".
12492 (iterate_over_some_symtabs): Adjust to use function_view as
12493 callback type and return bool.
12494 (iterate_over_symtabs): Adjust to use function_view as callback
12495 type.
12496 (symbol_found_callback_ftype): Remove 'data' parameter and return
12497 bool.
12498 (iterate_over_symbols): Adjust to use function_view as callback
12499 type.
12500
07e253aa
PA
125012017-02-23 Pedro Alves <palves@redhat.com>
12502
12503 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
12504 (%.o) <unittests/%.c>: New pattern.
12505 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
12506 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
12507 * common/function-view.h: New file.
12508 * unittests/function-view-selftests.c: New file.
12509 * configure: Regenerate.
12510
8eaf5320
SM
125112017-02-23 Simon Marchi <simon.marchi@ericsson.com>
12512
12513 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
12514 inferior_ptid.
12515 * go32-nat.c (go32_thread_alive): Likewise.
12516
38768751
YQ
125172017-02-23 Yao Qi <yao.qi@linaro.org>
12518
12519 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
12520 delete.
12521
0a8beaba
YQ
125222017-02-23 Yao Qi <yao.qi@linaro.org>
12523
12524 * varobj.c (varobj_clear_saved_item): Use delete instead of
12525 xfree.
12526 (update_dynamic_varobj_children): Likewise.
12527
58fdfd2c
JK
125282017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12529
12530 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
12531
1b90b139
SM
125322017-02-21 Simon Marchi <simon.marchi@ericsson.com>
12533
12534 * common/enum-flags.h (enum_flags::enum_flags): Initialize
12535 m_enum_value to 0 in default constructor.
12536
2039d74e
EBM
125372017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
12538
12539 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
12540 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
12541 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
12542 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
12543 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
12544 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
12545 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
12546 IS_STORE_CONDITIONAL_INSN.
12547
7814882a
JK
125482017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12549
12550 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
12551
0ae60b63
JK
125522017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12553
12554 * NEWS (Changes since GDB 7.12): Add DWARF-5.
12555
0224619f
JK
125562017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12557
12558 * dwarf2read.c (skip_one_die, read_attribute_value)
12559 (dwarf2_const_value_attr, dump_die_shallow)
12560 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
12561 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
12562
0af92d60
JK
125632017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12564
12565 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
12566 (dwarf_parse_macro_header): Accept DWARF version 5.
12567 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
12568
216f72a1
JK
125692017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12570
12571 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
12572 DW_AT_GNU_*.
12573 * common/common-exceptions.h (enum errors): Likewise.
12574 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
12575 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
12576 (dwarf_expr_context::execute_stack_op): Likewise.
12577 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
12578 Likewise.
12579 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
12580 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
12581 (show_entry_values_debug, call_site_to_target_addr)
12582 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
12583 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
12584 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
12585 (value_of_dwarf_block_entry, indirect_pieced_value)
12586 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
12587 (disassemble_dwarf_expression): Likewise.
12588 * dwarf2read.c (process_die, inherit_abstract_dies)
12589 (read_call_site_scope): Likewise.
12590 * gdbtypes.h (struct func_type, struct call_site_parameter)
12591 (struct call_site): Likewise.
12592 * stack.c (read_frame_arg): Likewise.
12593 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
12594
43988095
JK
125952017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12596
12597 * defs.h (read_unsigned_leb128): New declaration.
12598 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
12599 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
12600 (dwarf2_find_location_expression): Call also
12601 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
12602 * dwarf2loc.h (dwarf2_version): New declaration.
12603 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
12604 rnglists.
12605 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
12606 .debug_rnglists.
12607 (struct dwop_section_names): Add loclists_dwo.
12608 (dwop_section_names): Add .debug_loclists.dwo.
12609 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
12610 (struct dwarf2_per_cu_data): Add dwarf_version.
12611 (struct dwo_sections): Add loclists.
12612 (struct attr_abbrev): Add implicit_const.
12613 (read_indirect_line_string): New declaration.
12614 (read_unsigned_leb128): Delete declaration.
12615 (rcuh_kind): New definition.
12616 (read_and_check_comp_unit_head): Change parameter
12617 is_debug_types_section to section_kind.
12618 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
12619 (read_comp_unit_head): Change parameter abfd to section, add parameter
12620 section_kind. Handle DWARF-5.
12621 (error_check_comp_unit_head): Accept also DWARF version 5.
12622 (read_and_check_comp_unit_head): Change parameter
12623 is_debug_types_section to section_kind.
12624 (read_and_check_type_unit_head): Delete function.
12625 (read_abbrev_offset): Handle DWARF-5.
12626 (create_debug_type_hash_table): Add parameter section_kind. Process
12627 only DW_UT_type. Use signature and type_offset_in_tu from struct
12628 comp_unit_head.
12629 (create_debug_types_hash_table): Update create_debug_type_hash_table
12630 caller.
12631 (create_all_type_units): Call create_debug_type_hash_table.
12632 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
12633 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
12634 caller.
12635 (skip_one_die): Handle DW_FORM_implicit_const.
12636 (dwarf2_rnglists_process): New function.
12637 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
12638 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
12639 (read_attribute_value): Handle DW_FORM_implicit_const,
12640 DW_FORM_line_strp.
12641 (read_attribute): Handle DW_FORM_implicit_const.
12642 (read_indirect_string_at_offset_from): New function from
12643 read_indirect_string_at_offset.
12644 (read_indirect_string_at_offset): Call
12645 read_indirect_string_at_offset_from.
12646 (read_indirect_line_string_at_offset): New function.
12647 (read_indirect_string): New function comment.
12648 (read_indirect_line_string): New function.
12649 (read_unsigned_leb128): Make it global.
12650 (dwarf2_string_attr): Handle DWARF-5.
12651 (add_include_dir_stub, read_formatted_entries): New functions.
12652 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
12653 Handle DWARF-5.
12654 (per_cu_header_read_in): Update read_comp_unit_head caller.
12655 (dwarf2_version): New function.
12656 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
12657 rnglists.
12658 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
12659 fields.
12660
22d2f3ab
JK
126612017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12662
12663 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
12664
5f46c5a5
JK
126652017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12666
12667 * dwarf2read.c (dwarf2_ranges_process): New function from
12668 dwarf2_ranges_read.
12669 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
12670 dwarf2_ranges_process.
12671
78d4d2c5
JK
126722017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12673
12674 * dwarf2read.c (create_debug_type_hash_table): New function from
12675 create_debug_types_hash_table.
12676 (create_debug_types_hash_table): Call create_debug_type_hash_table.
12677 (create_all_type_units, open_and_init_dwo_file): Update
12678 create_debug_types_hash_table callers.
12679
1b076f25
SDJ
126802017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
12681
12682 PR gdb/16188
12683 * fork-child.c (trace_start_error): Fix thinko. va_end should
12684 refer to 'ap', not 'args'.
12685
0db8980c
SDJ
126862017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
12687 Pedro Alves <palves@redhat.com>
12688
12689 PR gdb/16188
12690 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
12691 calls succeeded.
12692 * fork-child.c (trace_start_error): New function.
12693 (trace_start_error_with_name): Likewise.
12694 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
12695 * inf-ptrace.c (inf_ptrace_me): Likewise.
12696 * inferior.h (trace_start_error): New prototype.
12697 (trace_start_error_with_name): Likewise.
12698
99e8a4f9
SDJ
126992017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
12700
12701 PR gdb/21164
12702 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
12703 NULL before using it.
12704 * symmisc.c (maintenance_print_symbols): Likewise.
12705 (maintenance_print_msymbols): Likewise.
12706
4e746bb6
TW
127072017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12708
12709 * NEWS: Add record Python bindings entry.
12710
127112017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12712
12713 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
12714 py-record-full.o.
12715 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
12716 * python/py-record-btrace.c, python/py-record-btrace.h,
12717 python/py-record-full.c, python/py-record-full.h: New file.
12718 * python/py-record.c: Add include for py-record-btrace.h and
12719 py-record-full.h.
12720 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
12721 recpy_instruction_history, recpy_function_call_history, recpy_begin,
12722 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
12723 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
12724 New definition.
12725 (gdbpy_initialize_btrace): New export.
12726 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
12727
127282017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12729
12730 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
12731 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
12732 * python/py-record.c: New file.
12733 * python/python-internal.h (gdbpy_start_recording,
12734 gdbpy_current_recording, gdpy_stop_recording,
12735 gdbpy_initialize_record): New export.
12736 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
12737 (python_GdbMethods): Add gdbpy_start_recording,
12738 gdbpy_current_recording and gdbpy_stop_recording.
12739
127402017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12741
12742 * record-btrace.c (record_btrace_record_method): New function.
12743 (init_record_btrace_ops): Initialize to_record_method.
12744 * record-full.c (record_full_record_method): New function.
12745 (init_record_full_ops, init_record_full_core_ops): Add
12746 record_full_record_method.
12747 * record.h (enum record_method): New enum.
12748 * target-debug.h (target_debug_print_enum_record_method: New define.
12749 * target-delegates.c: Regenerate.
12750 * target.c (target_record_method): New function.
12751 * target.h: Include record.h.
12752 (struct target_ops) <to_record_method>: New field.
12753 (target_record_method): New export.
12754
127552017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12756
12757 * record.h (record_start, record_stop): New export.
12758 * record.c (record_start, record_stop): New function.
12759
127602017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12761
12762 * btrace.c (btrace_fetch): Copy function call segments pointer
12763 into a vector.
12764 (btrace_clear): Clear the vector.
12765 (btrace_find_insn_by_number): Use binary search to find the correct
12766 function call segment.
12767 * btrace.h (brace_fun_p): New typedef.
12768 (struct btrace_thread_info) <functions>: New field.
12769
127702017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12771
12772 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
12773 * btrace.c (btrace_decode_error): ... here. New function.
12774 * btrace.h (btrace_decode_error): New export.
12775
127762017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12777
12778 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
12779 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
12780 btrace_find_insn_by_number): Remove special case for gaps.
12781 * btrace.h (btrace_insn_get_error): New export.
12782 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
12783 * record-btrace.c (btrace_insn_history): Print number for gaps.
12784 (record_btrace_info, record_btrace_goto): Handle gaps.
12785
3f77c769
TT
127862017-02-14 Tom Tromey <tom@tromey.com>
12787
12788 PR python/13598:
12789 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
12790 event.
12791 * python/py-evts.c (gdbpy_initialize_py_events): Add
12792 before_prompt registry.
12793 * python/py-events.h (events_object) <before_prompt>: New field.
12794
4c2c7ac6
MM
127952017-02-14 Markus Metzger <markus.t.metzger@intel.com>
12796
12797 * btrace.c (ftrace_new_switch): Preserve up link and flags.
12798
5cf30ebf
LM
127992017-02-13 Luis Machado <lgustavo@codesourcery.com>
12800
12801 * symfile (_initialize_symfile): Add usage text to the load command's
12802 help text.
12803
26a06916
SM
128042017-02-10 Simon Marchi <simon.marchi@ericsson.com>
12805
12806 * utils.c (defaulted_query): Don't query on secondary UIs.
12807
0b145e37
TT
128082017-02-10 Tom Tromey <tom@tromey.com>
12809
12810 * rust-lang.c (rust_get_disr_info): Remove unused variable.
12811
2d8365c4
TT
128122017-02-10 Tom Tromey <tom@tromey.com>
12813
12814 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
12815 "cleanup" local.
12816 * python/py-type.c (typy_legacy_template_argument): Remove
12817 unnecessary "cleanup" local.
12818
2bb8f231
TT
128192017-02-10 Tom Tromey <tom@tromey.com>
12820
12821 * python/python.c (do_start_initialization): New function, from
12822 _initialize_python.
12823 (_initialize_python): Call do_start_initialization.
12824 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
12825 goto.
12826
1bdfaf42
TT
128272017-02-10 Tom Tromey <tom@tromey.com>
12828
12829 * python/py-prettyprint.c (pretty_print_one_value): Use
12830 gdbpy_ref.
12831
88b6faea
TT
128322017-02-10 Tom Tromey <tom@tromey.com>
12833
12834 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
12835 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
12836 gdbpy_ref.
12837 * python/py-type.c (field_new): Use gdbpy_ref.
12838 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
12839 gdbpy_ref.
12840 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
12841 (py_free_pspace): Likewise.
12842 (pspace_to_pspace_object): Likewise.
12843 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
12844 (py_free_objfile): Likewise.
12845 (objfile_to_objfile_object): Likewise.
12846 * python/py-inferior.c (delete_thread_object): Use
12847 gdbpy_ref.
12848 (infpy_read_memory): Likewise.
12849 (py_free_inferior): Likewise.
12850 * python/py-evtregistry.c (create_eventregistry_object): Use
12851 gdbpy_ref.
12852 * python/py-event.c (create_event_object): Use gdbpy_ref.
12853
7780f186
TT
128542017-02-10 Tom Tromey <tom@tromey.com>
12855
12856 * python/py-ref.h (gdbpy_ref_policy): Now a template.
12857 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
12858 used.
12859 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
12860 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
12861 python/py-exitedevent.c, python/py-finishbreakpoint.c,
12862 python/py-framefilter.c, python/py-function.c,
12863 python/py-inferior.c, python/py-infevents.c,
12864 python/py-linetable.c, python/py-newobjfileevent.c,
12865 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
12866 python/py-signalevent.c, python/py-stopevent.c,
12867 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
12868 python/py-unwind.c, python/py-utils.c, python/py-value.c,
12869 python/py-varobj.c, python/py-xmethods.c, python/python.c,
12870 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
12871
d4b0bb18
TT
128722017-02-10 Tom Tromey <tom@tromey.com>
12873
12874 * ui-out.h (ui_out_emit_type): New class.
12875 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
12876 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
12877 and ui_out_emit_tuple.
12878 (enumerate_locals): Likewise.
12879 (py_mi_print_variables, py_print_locals, py_print_args): Use
12880 ui_out_emit_list.
12881 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
12882 ui_out_emit_list.
12883 * common/gdb_optional.h: New file.
12884
f67f945c
MG
128852017-02-10 Martin Galvan <martingalvan@sourceware.org>
12886
12887 * MAINTAINERS (Write After Approval): Update my e-mail address.
12888
18da0c51
MG
128892017-02-10 Martin Galvan <martingalvan@sourceware.org>
12890
12891 PR gdb/21122
12892 * breakpoint.c (_initialize_breakpoint): Update the help description
12893 of the 'commands' command to indicate that it takes a list argument.
12894
62c14536
SM
128952017-02-09 Simon Marchi <simon.marchi@ericsson.com>
12896
12897 * interps.c (current_interp_set_logging): Remove "return".
12898
ff6fa247
GB
128992017-02-09 Gary Benson <gbenson@redhat.com>
12900
12901 * symtab.c (add_symtab_completions): Prevent NULL pointer
12902 dereference.
12903
a474bd8e
PA
129042017-02-08 Pedro Alves <palves@redhat.com>
12905
12906 * interps.c (interp::interp): Remove reference to quiet_p.
12907 (interp_set): Make static. Remove dead "Switching to" output
12908 code.
12909 (interp_quiet_p, interp_set_quiet): Delete.
12910 (interpreter_exec_cmd): Don't set the interpreter quiet.
12911 * interps.h (interp_quiet_p): Make static.
12912 (class interp) <quiet_p>: Remove field
12913
3d7b173c
JG
129142017-02-08 Jerome Guitton <guitton@adacore.com>
12915
604c4576
JG
12916 * cli/cli-decode.c (find_command_name_length): Make it extern.
12917 * cli/cli-decode.h (find_command_name_length): Declare.
12918 * cli/cli-script.c (command_name_equals, line_first_arg):
12919 New functions.
12920 (process_next_line): Use cli-decode to parse command names.
12921 (build_command_line): Make args a constant pointer.
12922
129232017-02-08 Jerome Guitton <guitton@adacore.com>
6dbb839a 12924
3d7b173c
JG
12925 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
12926 Remove case-insensitive search.
12927
1291063d
JM
129282017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
12929
12930 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
12931 at the end of the line. Avoids an ARI warning.
12932
20b477a7
LM
129332017-02-06 Luis Machado <lgustavo@codesourcery.com>
12934
12935 * NEWS: Mention support for record/replay of Intel 64 rdrand and
12936 rdseed instructions.
12937 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
12938
3f7b46f2
IR
129392017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
12940
12941 PR tdep/20936
12942 Provide and use sparc32 and sparc64 target description XML files.
12943 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
12944 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
12945 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
12946 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
12947 * features/sparc/sparc32-solaris.xml: New file.
12948 * features/sparc/sparc64-solaris.xml: New file.
12949 * features/sparc/sparc32-solaris.c: Generated.
12950 * features/sparc/sparc64-solaris.c: Generated.
12951 * sparc-tdep.h: Account for differences in target descriptions.
12952 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
12953 (sparc32_register_type): Use target provided registers.
12954 (validate_tdesc_registers): New function.
12955 (sparc32_gdbarch_init): Use tdesc_has_registers.
12956 Set pseudoregister functions.
12957 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
12958 (sparc64_register_type): Use target provided registers.
12959 (sparc64_init_abi): Set pseudoregister functions.
12960
f0fd41c1
TT
129612017-02-03 Tom Tromey <tom@tromey.com>
12962
12963 PR rust/21097:
12964 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
12965 with a single member.
12966
d6f9b0fb
PA
129672017-02-03 Pedro Alves <palves@redhat.com>
12968
12969 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
12970 (cli_interp_base::~cli_interp_base): New.
12971 (cli_interp): New struct.
12972 (as_cli_interp): Cast the interp itself to cli_interp.
12973 (cli_interpreter_pre_command_loop): Rename to ...
12974 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
12975 parameter.
12976 (cli_interpreter_init): Rename to ...
12977 (cli_interp::init): ... this. Remove 'self' parameter. Use
12978 boolean. Make extern.
12979 (cli_interpreter_resume): Rename to ...
12980 (cli_interp::resume): ... this. Remove 'data' parameter. Make
12981 extern.
12982 (cli_interpreter_suspend): Rename to ...
12983 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
12984 extern.
12985 (cli_interpreter_exec): Rename to ...
12986 (cli_interp::exec): ... this. Remove 'data' parameter. Make
12987 extern.
12988 (cli_interpreter_supports_command_editing): Rename to ...
12989 (cli_interp_base::supports_command_editing): ... this. Remove
12990 'interp' parameter. Make extern.
12991 (cli_ui_out): Rename to ...
12992 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
12993 Make extern.
12994 (cli_set_logging): Rename to ...
12995 (cli_interp_base::set_logging): ... this. Remove 'interp'
12996 parameter. Make extern.
12997 (cli_interp_procs): Delete.
12998 (cli_interp_factory): Adjust to use "new".
12999 * cli/cli-interp.h: Include "interps.h".
13000 (struct cli_interp_base): New struct.
13001 * interps.c (struct interp): Delete. Fields moved to interps.h.
13002 (interp_new): Delete.
13003 (interp::interp, interp::~interp): New.
13004 (interp_set): Use bool, and return void. Assume the interpreter
13005 has suspend, init and resume methods, and that the all return
13006 void.
13007 (set_top_level_interpreter): interp_set returns void.
13008 (interp_ui_out): Adapt.
13009 (current_interp_set_logging): Adapt.
13010 (interp_data): Delete.
13011 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
13012 (interp_exec): Adapt.
13013 (top_level_interpreter_data): Delete.
13014 * interps.h (interp_init_ftype, interp_resume_ftype)
13015 (interp_suspend_ftype, interp_exec_ftype)
13016 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
13017 (class interp): New.
13018 (interp_new): Delete.
13019 (interp_set): Now returns void. Use bool.
13020 (interp_data, top_level_interpreter_data): Delete.
13021 * mi/mi-common.h: Include interps.h.
13022 (class mi_interp): Inherit from interp. Define a ctor. Declare
13023 init, resume, suspect, exec, interp_ui_out, set_logging and
13024 pre_command_loop methods.
13025 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
13026 (mi_interpreter_init): Rename to ...
13027 (mi_interp::init): ... this. Remove the 'interp' parameter, use
13028 bool, return void and make extern. Adjust.
13029 (mi_interpreter_resume): ... Rename to ...
13030 (mi_interp::resume): ... this. Remove the 'data' parameter,
13031 return void and make extern. Adjust.
13032 (mi_interpreter_suspend): ... Rename to ...
13033 (mi_interp::suspend): ... this. Remove the 'data' parameter,
13034 return void and make extern. Adjust.
13035 (mi_interpreter_exec): ... Rename to ...
13036 (mi_interp::exec): ... this. Remove the 'data' parameter and make
13037 extern. Adjust.
13038 (mi_interpreter_pre_command_loop): ... Rename to ...
13039 (mi_interp::pre_command_loop): ... this. Remove the 'self'
13040 parameter and make extern.
13041 (mi_on_normal_stop_1): Adjust.
13042 (mi_ui_out): Rename to ...
13043 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
13044 parameter and make extern. Adjust.
13045 (mi_set_logging): Rename to ...
13046 (mi_interp::set_logging): ... this. Remove the 'interp'
13047 parameter and make extern. Adjust.
13048 (mi_interp_procs): Delete.
13049 (mi_interp_factory): Adjust to use 'new'.
13050 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
13051 (mi_print_exception, mi_execute_command, mi_load_progress):
13052 Adjust.
13053 * tui/tui-interp.c (tui_interp): New class.
13054 (as_tui_interp): Return a tui_interp pointer.
13055 (tui_on_normal_stop, tui_on_signal_received)
13056 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
13057 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
13058 to use interp::interp_ui_out.
13059 (tui_init): Rename to ...
13060 (tui_interp::init): ... this. Remove the 'self' parameter, use
13061 bool, return void and make extern. Adjust.
13062 (tui_resume): Rename to ...
13063 (tui_interp::resume): ... this. Remove the 'data' parameter,
13064 return void and make extern. Adjust.
13065 (tui_suspend): Rename to ...
13066 (tui_interp::suspend): ... this. Remove the 'data' parameter,
13067 return void and make extern. Adjust.
13068 (tui_ui_out): Rename to ...
13069 (tui_interp::interp_ui_out): ... this. Remove the 'self'
13070 parameter, and make extern. Adjust.
13071 (tui_exec): Rename to ...
13072 (tui_interp::exec): ... this. Remove the 'data' parameter and
13073 make extern.
13074 (tui_interp_procs): Delete.
13075 (tui_interp_factory): Use "new".
13076
65c40c95
TT
130772017-02-02 Tom Tromey <tom@tromey.com>
13078
13079 * rust-exp.y (ends_raw_string, space_then_number)
13080 (rust_identifier_start_p): Return bool.
13081 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
13082 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
13083 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
13084 (rust_chartype_p): Return bool.
13085 (val_print_struct, rust_print_struct_def, rust_print_type):
13086 Update.
13087 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
13088 Return bool.
13089
b50f188d
TT
130902017-02-02 Tom Tromey <tom@tromey.com>
13091
13092 * rust-lang.c: Reindent.
13093
03c85b11
TT
130942017-02-02 Tom Tromey <tom@tromey.com>
13095
13096 * rust-lang.h (rust_crate_for_block): Update.
13097 * rust-lang.c (rust_crate_for_block): Return std::string.
13098 (rust_get_disr_info): Use std:;string, not
13099 gdb::unique_xmalloc_ptr.
13100 * rust-exp.y (crate_name): Update.
13101
9b6da501
PA
131022017-02-02 Pedro Alves <palves@redhat.com>
13103
13104 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
13105 field out of gdb_disassembler_test and make it static.
13106
ec4cb20b
PA
131072017-02-02 Pedro Alves <palves@redhat.com>
13108
13109 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
13110 mi1_interp and mi_interp fields.
13111
5be5dbf0
PA
131122017-02-02 Pedro Alves <palves@redhat.com>
13113
616268b6
PA
13114 * cli/cli-interp.c (struct saved_output_files, saved_output):
13115 Moved from cli/cli-logging.c.
13116 (cli_set_logging): New function.
13117 (cli_interp_procs): Install cli_set_logging.
13118 * cli/cli-interp.h (make_logging_output, cli_set_logging):
13119 Declare.
13120 * cli/cli-logging.c (struct saved_output_files, saved_output):
13121 Moved to cli/cli-interp.c.
13122 (pop_output_files): Don't save outputs here.
13123 (make_logging_output): New function.
13124 (handle_redirections): Don't build tee nor save previous outputs
13125 here.
13126 * interps.c (current_interp_set_logging): Change prototype.
13127 Assume there's always a set_logging_proc method installed.
13128 * interps.h (interp_set_logging_ftype): Change prototype.
13129 (current_interp_set_logging): Change prototype and adjust comment.
13130 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
13131 use make_logging_output.
13132 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
131332017-02-02 Pedro Alves <palves@redhat.com>
13134
5be5dbf0
PA
13135 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
13136 from ...
13137 (set_logging_overwrite): ... here.
13138 (logging_no_redirect_file): Delete.
13139 (set_logging_redirect): Don't handle redirection on the fly.
13140 Instead warn that "logging off" / "logging on" is necessary.
13141 (pop_output_files): Delete references to logging_no_redirect_file.
13142 (show_logging_command): Always speak in terms of what will happen
13143 once logging is reenabled.
13144
c99cc448
PA
131452017-02-02 Pedro Alves <palves@redhat.com>
13146
13147 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
13148
8b172ce7
PA
131492017-02-02 Pedro Alves <palves@redhat.com>
13150
13151 * disasm.c (gdb_pretty_print_insn): Rename to ...
13152 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
13153 Remove gdbarch parameter. Adapt to clear the object's buffers
13154 instead of allocating new buffers, and to print using the object's
13155 gdb_disassembler instead of calling gdb_print_insn.
13156 (dump_insns): Use gdb_pretty_print_disassembler.
13157 * disasm.h (gdb_pretty_print_insn): Delete declaration.
13158 (gdb_pretty_print_disassembler): New class.
13159 * record-btrace.c (btrace_insn_history): Use
13160 gdb_pretty_print_disassembler.
13161
d7e74731
PA
131622017-02-02 Pedro Alves <palves@redhat.com>
13163
13164 * ada-lang.c (type_as_string): Use string_file.
13165 * ada-valprint.c (ada_print_floating): Use string_file.
13166 * ada-varobj.c (ada_varobj_scalar_image)
13167 (ada_varobj_get_value_image): Use string_file.
13168 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
13169 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
13170 * breakpoint.c (update_inserted_breakpoint_locations)
13171 (insert_breakpoint_locations, reattach_breakpoints)
13172 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
13173 (print_it_watchpoint): Use string_file.
13174 (save_breakpoints): Use stdio_file.
13175 * c-exp.y (oper): Use string_file.
13176 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
13177 tee_file.
13178 (pop_output_files): Use delete.
13179 (handle_redirections): Use stdio_file and tee_file.
13180 * cli/cli-setshow.c (do_show_command): Use string_file.
13181 * compile/compile-c-support.c (c_compute_program): Use
13182 string_file.
13183 * compile/compile-c-symbols.c (generate_vla_size): Take a
13184 'string_file &' instead of a 'ui_file *'.
13185 (generate_c_for_for_one_variable): Take a 'string_file &' instead
13186 of a 'ui_file *'. Use string_file.
13187 (generate_c_for_variable_locations): Take a 'string_file &'
13188 instead of a 'ui_file *'.
13189 * compile/compile-internal.h (generate_c_for_for_one_variable):
13190 Take a 'string_file &' instead of a 'ui_file *'.
13191 * compile/compile-loc2c.c (push, pushf, unary, binary)
13192 (print_label, pushf_register_address, pushf_register)
13193 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
13194 'ui_file *'. Adjust.
13195 * compile/compile.c (compile_to_object): Use string_file.
13196 * compile/compile.h (compile_dwarf_expr_to_c)
13197 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
13198 'ui_file *'.
13199 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
13200 (replace_typedefs_qualified_name): Use string_file and
13201 obstack_copy0.
13202 * disasm.c (gdb_pretty_print_insn): Use string_file.
13203 (gdb_disassembly): Adjust reference the null_stream global.
13204 (do_ui_file_delete): Delete.
13205 (gdb_insn_length): Use null_stream.
13206 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
13207 * dwarf2loc.c (dwarf2_compile_property_to_c)
13208 (locexpr_generate_c_location, loclist_generate_c_location): Take a
13209 'string_file &' instead of a 'ui_file *'.
13210 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
13211 * dwarf2read.c (do_ui_file_peek_last): Delete.
13212 (dwarf2_compute_name): Use string_file.
13213 * event-top.c (gdb_setup_readline): Use stdio_file.
13214 * gdbarch.sh (verify_gdbarch): Use string_file.
13215 * gdbtypes.c (safe_parse_type): Use null_stream.
13216 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
13217 string_file.
13218 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
13219 'string_file *' instead of a 'ui_file *'.
13220 (gdbscm_arch_disassemble): Use string_file.
13221 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
13222 * guile/scm-ports.c (class ioscm_file_port): Now a class that
13223 inherits from ui_file.
13224 (ioscm_file_port_delete, ioscm_file_port_rewind)
13225 (ioscm_file_port_put): Delete.
13226 (ioscm_file_port_write): Rename to ...
13227 (ioscm_file_port::write): ... this. Remove file_port_magic
13228 checks.
13229 (ioscm_file_port_new): Delete.
13230 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
13231 ui_file_up.
13232 * guile/scm-type.c (tyscm_type_name): Use string_file.
13233 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
13234 Use string_file.
13235 * infcmd.c (print_return_value_1): Use string_file.
13236 * infrun.c (print_target_wait_results): Use string_file.
13237 * language.c (add_language): Use string_file.
13238 * location.c (explicit_to_string_internal): Use string_file.
13239 * main.c (captured_main_1): Use null_file.
13240 * maint.c (maintenance_print_architecture): Use stdio_file.
13241 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
13242 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
13243 event_channel>: Change type to mi_console_file pointer.
13244 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
13245 (mi_console_file_delete): Delete.
13246 (struct mi_console_file): Delete.
13247 (mi_console_file_magic): Delete.
13248 (mi_console_file_new): Delete.
13249 (mi_console_file::mi_console_file): New.
13250 (mi_console_file_delete): Delete.
13251 (mi_console_file_fputs): Delete.
13252 (mi_console_file::write): New.
13253 (mi_console_raw_packet): Delete.
13254 (mi_console_file::flush): New.
13255 (mi_console_file_flush): Delete.
13256 (mi_console_set_raw): Rename to ...
13257 (mi_console_file::set_raw): ... this.
13258 * mi/mi-console.h (class mi_console_file): New class.
13259 (mi_console_file_new, mi_console_set_raw): Delete.
13260 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
13261 (mi_set_logging): Use delete and tee_file. Adjust.
13262 * mi/mi-main.c (output_register): Use string_file.
13263 (mi_cmd_data_evaluate_expression): Use string_file.
13264 (mi_cmd_data_read_memory): Use string_file.
13265 (mi_cmd_execute, print_variable_or_computed): Use string_file.
13266 * mi/mi-out.c (mi_ui_out::main_stream): New.
13267 (mi_ui_out::rewind): Use main_stream and
13268 string_file.
13269 (mi_ui_out::put): Use main_stream and string_file.
13270 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
13271 Allocate a 'string_file' instead.
13272 (mi_out_new): Don't allocate a mem_fileopen stream here.
13273 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
13274 (mi_ui_out::main_stream): Declare method.
13275 * printcmd.c (eval_command): Use string_file.
13276 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
13277 * python/py-arch.c (archpy_disassemble): Use string_file.
13278 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
13279 * python/py-frame.c (frapy_str): Use string_file.
13280 * python/py-framefilter.c (py_print_type, py_print_single_arg):
13281 Use string_file.
13282 * python/py-type.c (typy_str): Use string_file.
13283 * python/py-unwind.c (unwind_infopy_str): Use string_file.
13284 * python/py-value.c (valpy_str): Use string_file.
13285 * record-btrace.c (btrace_insn_history): Use string_file.
13286 * regcache.c (regcache_print): Use stdio_file.
13287 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
13288 * remote.c (escape_buffer): Use string_file.
13289 * rust-lang.c (rust_get_disr_info): Use string_file.
13290 * serial.c (serial_open_ops_1): Use stdio_file.
13291 (do_serial_close): Use delete.
13292 * stack.c (print_frame_arg): Use string_file.
13293 (print_frame_args): Remove local mem_fileopen stream, not used.
13294 (print_frame): Use string_file.
13295 * symmisc.c (maintenance_print_symbols): Use stdio_file.
13296 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
13297 Take a 'string_file *' instead of a 'ui_file *'.
13298 * top.c (new_ui): Use stdio_file and stderr_file.
13299 (free_ui): Use delete.
13300 (execute_command_to_string): Use string_file.
13301 (quit_confirm): Use string_file.
13302 * tracepoint.c (collection_list::append_exp): Use string_file.
13303 * tui/tui-disasm.c (tui_disassemble): Use string_file.
13304 * tui/tui-file.c: Don't include "ui-file.h".
13305 (enum streamtype, struct tui_stream): Delete.
13306 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
13307 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
13308 (tui_file::tui_file): New method.
13309 (tui_file_fputs): Delete.
13310 (tui_file_get_strbuf): Delete.
13311 (tui_file::puts): New method.
13312 (tui_file_adjust_strbuf): Delete.
13313 (tui_file_flush): Delete.
13314 (tui_file::flush): New method.
13315 * tui/tui-file.h: Tweak intro comment.
13316 Include ui-file.h.
13317 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
13318 (tui_file_adjust_strbuf): Delete declarations.
13319 (class tui_file): New class.
13320 * tui/tui-io.c (tui_initialize_io): Use tui_file.
13321 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
13322 (tui_register_format): Use string_stream.
13323 * tui/tui-stack.c (tui_make_status_line): Use string_file.
13324 (tui_get_function_from_frame): Use string_file.
13325 * typeprint.c (type_to_string): Use string_file.
13326 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
13327 (null_stream): New global.
13328 (ui_file_delete): Delete.
13329 (ui_file::ui_file): New.
13330 (null_file_isatty): Delete.
13331 (ui_file::~ui_file): New.
13332 (null_file_rewind): Delete.
13333 (ui_file::printf): New.
13334 (null_file_put): Delete.
13335 (null_file_flush): Delete.
13336 (ui_file::putstr): New.
13337 (null_file_write): Delete.
13338 (ui_file::putstrn): New.
13339 (null_file_read): Delete.
13340 (ui_file::putc): New.
13341 (null_file_fputs): Delete.
13342 (null_file_write_async_safe): Delete.
13343 (ui_file::vprintf): New.
13344 (null_file_delete): Delete.
13345 (null_file::write): New.
13346 (null_file_fseek): Delete.
13347 (null_file::puts): New.
13348 (ui_file_data): Delete.
13349 (null_file::write_async_safe): New.
13350 (gdb_flush, ui_file_isatty): Adjust.
13351 (ui_file_put, ui_file_rewind): Delete.
13352 (ui_file_write): Adjust.
13353 (ui_file_write_for_put): Delete.
13354 (ui_file_write_async_safe, ui_file_read): Adjust.
13355 (ui_file_fseek): Delete.
13356 (fputs_unfiltered): Adjust.
13357 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
13358 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
13359 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
13360 (set_ui_file_data): Delete.
13361 (string_file::~string_file, string_file::write)
13362 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
13363 (do_ui_file_as_string, ui_file_as_string): Delete.
13364 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
13365 (struct mem_file): Delete.
13366 (mem_file_new): Delete.
13367 (stdio_file::stdio_file): New.
13368 (mem_file_delete): Delete.
13369 (stdio_file::stdio_file): New.
13370 (mem_fileopen): Delete.
13371 (stdio_file::~stdio_file): New.
13372 (mem_file_rewind): Delete.
13373 (stdio_file::set_stream): New.
13374 (mem_file_put): Delete.
13375 (stdio_file::open): New.
13376 (mem_file_write): Delete.
13377 (stdio_file_magic, struct stdio_file): Delete.
13378 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
13379 (stdio_file::flush): New.
13380 (stdio_file_read): Rename to ...
13381 (stdio_file::read): ... this. Adjust.
13382 (stdio_file_write): Rename to ...
13383 (stdio_file::write): ... this. Adjust.
13384 (stdio_file_write_async_safe): Rename to ...
13385 (stdio_file::write_async_safe) ... this. Adjust.
13386 (stdio_file_fputs): Rename to ...
13387 (stdio_file::puts) ... this. Adjust.
13388 (stdio_file_isatty): Delete.
13389 (stdio_file_fseek): Delete.
13390 (stdio_file::isatty): New.
13391 (stderr_file_write): Rename to ...
13392 (stderr_file::write) ... this. Adjust.
13393 (stderr_file_fputs): Rename to ...
13394 (stderr_file::puts) ... this. Adjust.
13395 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
13396 (stderr_file::stderr_file): New.
13397 (tee_file_magic): Delete.
13398 (struct tee_file): Delete.
13399 (tee_file::tee_file): New.
13400 (tee_file_new): Delete.
13401 (tee_file::~tee_file): New.
13402 (tee_file_delete): Delete.
13403 (tee_file_flush): Rename to ...
13404 (tee_file::flush): ... this. Adjust.
13405 (tee_file_write): Rename to ...
13406 (tee_file::write): ... this. Adjust.
13407 (tee_file::write_async_safe): New.
13408 (tee_file_fputs): Rename to ...
13409 (tee_file::puts): ... this. Adjust.
13410 (tee_file_isatty): Rename to ...
13411 (tee_file::isatty): ... this. Adjust.
13412 * ui-file.h (struct obstack, struct ui_file): Don't
13413 forward-declare.
13414 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
13415 (ui_file_write_ftype)
13416 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
13417 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
13418 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
13419 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
13420 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
13421 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
13422 (set_ui_file_fseek): Delete.
13423 (ui_file_data, ui_file_delete, ui_file_rewind)
13424 (struct ui_file): New.
13425 (ui_file_up): New.
13426 (class null_file): New.
13427 (null_stream): Declare.
13428 (ui_file_write_for_put, ui_file_put): Delete.
13429 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
13430 Delete.
13431 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
13432 (gdb_fopen, tee_file_new): Delete.
13433 (struct string_file): New.
13434 (struct stdio_file): New.
13435 (stdio_file_up): New.
13436 (struct stderr_file): New.
13437 (class tee_file): New.
13438 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
13439 of a 'ui_file *'. Adjust.
13440 * ui-out.h (class ui_out) <field_stream>: Likewise.
13441 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
13442 (null_stream): Delete.
13443 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
13444 Adjust.
13445 * utils.h (struct ui_file): Delete forward declaration..
13446 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
13447 (error_stream): Take a 'string_file &' instead of a
13448 'ui_file *'.
13449 * varobj.c (varobj_value_get_print_value): Use string_file.
13450 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
13451 * gdbarch.c: Regenerate.
13452
187808b0
PA
134532017-02-02 Pedro Alves <palves@redhat.com>
13454
13455 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
13456 (gdb_pretty_print_insn): ... this. Now a free function. Add back
13457 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
13458 Adjust to call gdb_print_insn instead of
13459 gdb_disassembler::print_insn.
13460 (dump_insns, do_mixed_source_and_assembly_deprecated)
13461 (do_mixed_source_and_assembly, do_assembly_only): Add back a
13462 'gdbarch' parameter. Remove gdb_disassembler parameter.
13463 (gdb_disassembly): Don't allocate a gdb_disassembler here.
13464 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
13465 declaration.
13466 (gdb_pretty_print_insn): Re-add declaration.
13467 * record-btrace.c (btrace_insn_history): Don't allocate a
13468 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
13469
7a8eb317
SM
134702017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
13471
13472 * disasm.h (gdb_disassembly): Remove file_string parameter.
13473 * disasm.c (gdb_disassembly): Likewise.
13474 * cli/cli-cmds.c (print_disassembly): Adapt.
13475 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
13476 * stack.c (do_gdb_disassembly): Likewise.
13477
7346ef59
AA
134782017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
13479
13480 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
13481 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
13482 targets. And if the implicit value is longer than needed, extract
13483 the first bytes instead of the "least significant" ones.
13484
cd4007e4
MM
134852017-02-01 Markus Metzger <markus.t.metzger@intel.com>
13486
13487 * btrace.c (btrace_enable): Do not call btrace_add_pc for
13488 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
13489 (btrace_fetch): Assert can_access_registers_ptid.
13490 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
13491 validate_registers_access.
13492
cf77c34e
MM
134932017-02-01 Markus Metzger <markus.t.metzger@intel.com>
13494
13495 * gdbthread.h (can_access_registers_ptid): New.
13496 * thread.c (can_access_registers_ptid): New.
13497
be85ce7d
PA
134982017-02-01 Pedro Alves <palves@redhat.com>
13499
13500 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
13501
29b0b251
PA
135022017-01-31 Pedro Alves <palves@redhat.com>
13503
13504 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
13505 Fix typos.
13506
289b5b24
PA
135072017-01-31 Pedro Alves <palves@redhat.com>
13508
13509 * stack.c (print_frame_args): Remove local mem_fileopen stream,
13510 not used.
13511
b47413b4
PA
135122017-01-31 Pedro Alves <palves@redhat.com>
13513
13514 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
13515
60adb36c
PA
135162017-01-31 Pedro Alves <palves@redhat.com>
13517
13518 * common/scoped_restore.h
13519 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
13520 change the value's parameter type to T2.
13521 (make_scoped_restore): Likewise.
13522
2735833d
WT
135232017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
13524 Richard Henderson <rth@redhat.com>
13525
13526 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
13527 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
13528 GS_BASE for older kernels.
13529 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
13530 GS_BASE for older kernels.
13531 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
13532 and GS_BASE to the offset table.
13533 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
13534 system register group.
13535 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
13536 for older kernels.
13537 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
13538 amd64 ABI.
13539 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
13540 AMD64_GSBASE_REGNUM.
13541 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
13542 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
13543 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
13544 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
13545 i386/64bit-segments.xml in those rules.
13546 * features/i386/64bit-segments.xml: New file.
13547 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
13548 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
13549 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
13550 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
13551 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
13552 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
13553 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
13554 * features/i386/amd64-avx-linux.c: Regenerated.
13555 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
13556 * features/i386/amd64-avx-mpx.c: Regenerated.
13557 * features/i386/amd64-avx512-linux.c: Regenerated.
13558 * features/i386/amd64-linux.c: Regenerated.
13559 * features/i386/amd64-mpx-linux.c: Regenerated.
13560 * features/i386/i386-avx-mpx-linux.c: Regenerated.
13561 * features/i386/i386-avx-mpx.c: Regenerated.
13562 * features/i386/x32-avx-linux.c: Regenerated.
13563 * features/i386/x32-avx512-linux.c: Regenerated.
13564 * regformats/i386/amd64-avx-linux.dat: Regenerated.
13565 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
13566 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
13567 * regformats/i386/amd64-linux.dat: Regenerated.
13568 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
13569 * regformats/i386/x32-avx-linux.dat: Regenerated.
13570 * regformats/i386/x32-avx512-linux.dat: Regenerated.
13571 * regformats/i386/x32-linux.dat: Regenerated.
13572
8884e97e
WT
135732017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
13574
13575 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
13576 Set to AMD64_NUM_REGS.
13577
7005d26a
WT
135782017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
13579
13580 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
13581 that checks validity of a register number.
13582
4bd2e1b2
KC
135832017-01-27 Kees Cook <keescook@google.com>
13584
13585 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
13586 fetch_fpregs if target has fpa registers.
13587 (arm_linux_store_inferior_registers): Call store_fpregs if target
13588 has fpa registers.
13589
7cf1de6c
AA
135902017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
13591
13592 * cris-tdep.c (cris_gdbarch_init): Remove check for
13593 info.byte_order and force it to BFD_ENDIAN_LITTLE.
13594
874a1c8c
AT
135952017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
13596
13597 * corelow.c (get_core_register_section): Check for regset
13598 existence before checking for REGSET_VARIABLE_SIZE.
13599
d8b49cf0
YQ
136002017-01-26 Yao Qi <yao.qi@linaro.org>
13601 Pedro Alves <palves@redhat.com>
13602
13603 PR gdb/20939
13604 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
13605 call memory_error, save memaddr instead.
13606 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
13607 negative, cal memory_error.
13608 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
13609
658ca58c
YQ
136102017-01-26 Yao Qi <yao.qi@linaro.org>
13611
13612 * disasm-selftests.c (memory_error_test): New function.
13613 (_initialize_disasm_selftests): Register memory_error_test.
13614
79843d45
YQ
136152017-01-26 Yao Qi <yao.qi@linaro.org>
13616
13617 * Makefile.in (SFILES): Add disasm-selftests.c and
13618 selftest-arch.c.
13619 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
13620 * disasm-selftests.c: New file.
13621 * selftest-arch.c: New file.
13622 * selftest-arch.h: New file.
13623
8cafda32
YQ
136242017-01-26 Yao Qi <yao.qi@linaro.org>
13625
13626 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
13627 to bfd_arch_mep. Don't return 0 if section is not
13628 found. Call print_insn_mep.
13629
e47ad6c0
YQ
136302017-01-26 Pedro Alves <palves@redhat.com>
13631 Yao Qi <yao.qi@linaro.org>
13632
13633 * arm-tdep.c: Include "disasm.h".
13634 (gdb_print_insn_arm): Update code to get gdbarch.
13635 * disasm.c (dis_asm_read_memory): Change it to
13636 gdb_disassembler::dis_asm_read_memory.
13637 (dis_asm_memory_error): Likewise.
13638 (dis_asm_print_address): Likewise.
13639 (gdb_pretty_print_insn): Change it to
13640 gdb_disassembler::pretty_print_insn.
13641 (dump_insns): Add one argument gdb_disassemlber. All
13642 callers updated.
13643 (do_mixed_source_and_assembly_deprecated): Likewise.
13644 (do_mixed_source_and_assembly): Likewise.
13645 (do_assembly_only): Likewise.
13646 (gdb_disassembler::gdb_disassembler): New.
13647 (gdb_disassembler::print_insn): New.
13648 * disasm.h (class gdb_disassembler): New.
13649 (gdb_pretty_print_insn): Remove declaration.
13650 (gdb_disassemble_info): Likewise.
13651 * guile/scm-disasm.c (class gdbscm_disassembler): New.
13652 (gdbscm_disasm_read_memory_worker): Update.
13653 (gdbscm_disasm_read_memory): Update.
13654 (gdbscm_disasm_memory_error): Remove.
13655 (gdbscm_disasm_print_address): Remove.
13656 (gdbscm_disassembler::gdbscm_disassembler): New.
13657 (gdbscm_print_insn_from_port): Update.
13658 * mips-tdep.c: Include disasm.h.
13659 (gdb_print_insn_mips): Update code to get gdbarch.
13660 * record-btrace.c (btrace_insn_history): Update.
13661 * spu-tdep.c: Include disasm.h.
13662 (struct spu_dis_asm_data): Remove.
13663 (struct spu_dis_asm_info): New.
13664 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
13665 SPU id.
13666 (gdb_print_insn_spu): Cast disassemble_info to
13667 spu_dis_asm_info.
13668
80d75874
YQ
136692017-01-26 Yao Qi <yao.qi@linaro.org>
13670
13671 * disasm.c (do_ui_file_delete): Delete.
13672 (gdb_insn_length): Move code creating stream to ...
13673 * utils.c (null_stream): ... here. New function.
13674 * utils.h (null_stream): Declare.
13675
60685cd0
SM
136762017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
13677
13678 * python/py-inferior.c (find_thread_object): Return directly
13679 from the loop. Remove "found" variable.
13680
eb1cdb62
JB
136812017-01-21 Joel Brobecker <brobecker@adacore.com>
13682
13683 GDB 7.12.1 released.
13684
b1ce6568
SM
136852017-01-20 Simon Marchi <simon.marchi@ericsson.com>
13686
13687 * python/py-function.c (fnpy_call): Reorder declarations to have
13688 the gdbpy_enter object declared first.
13689 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
13690
6f8b0407
SM
136912017-01-20 Simon Marchi <simon.marchi@ericsson.com>
13692
fec93fb1 13693 PR python/21068
6f8b0407
SM
13694 * python/python-internal.h (PyMem_RawMalloc): Define for
13695 Python < 3.4.
13696 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
13697 PyMem_RawMalloc instead of PyMem_Malloc.
13698
78cbbba8
LM
136992017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
13700 Luis Machado <lgustavo@codesourcery.com>
13701
13702 * NEWS (New commands): Mention flash-erase.
13703 (New MI commands): Mention target-flash-erase.
13704 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
13705 command.
13706 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
13707 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
13708 * target.c (flash_erase_command): New function.
13709 (initialize_targets): Add new flash-erase command.
13710 * target.h (flash_erase_command): New declaration.
13711
2132fe85
JB
137122017-01-20 Joel Brobecker <brobecker@adacore.com>
13713
13714 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
13715 HAVE_SYS_PROCFS_H is defined.
13716
d1dff226
AH
137172017-01-18 Alan Hayward <alan.hayward@arm.com>
13718
13719 * remote.c (struct cached_reg): Change data into a pointer.
13720 * (stop_reply_dtr): Free data pointers before deleting vector.
13721 (process_stop_reply): Likewise.
13722 (remote_parse_stop_reply): Allocate space for data
13723
9890e433
AH
137242017-01-18 Alan Hayward <alan.hayward@arm.com>
13725
13726 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
13727 MAX_REGISTER_SIZE.
13728 (amd64_pseudo_register_read_value): Likewise.
13729 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
13730 (store_register_using_P): Likewise.
13731 * regcache.c (regcache_xfer_part): Likewise.
13732
7a36499a
IR
137332017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
13734
13735 Split real and pseudo registers.
13736 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
13737 (sparc32_pseudo_regnum): New enum.
13738 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
13739 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
13740 (SPARC32_CP0_REGISTERS): New macro.
13741 (sparc32_pseudo_register_name): New function.
13742 (sparc32_register_name): Use sparc32_pseudo_register_name.
13743 (sparc32_pseudo_register_type): New function.
13744 (sparc32_register_type): Use sparc32_pseudo_register_type.
13745 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
13746 pseudo register numbers.
13747 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
13748 (SPARC64_CP0_REGISTERS): New macro.
13749 (sparc64_pseudo_register_name): New function.
13750 (sparc64_register_name): Use sparc64_pseudo_register_name.
13751 (sparc64_pseudo_register_type): New function.
13752 (sparc64_register_type): Use sparc64_pseudo_register_type.
13753 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
13754 pseudo register numbers.
13755 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
13756 sparc64_store_arguments): Handle pseudo register numbers.
13757
6f8976bf
YQ
137582017-01-13 Yao Qi <yao.qi@linaro.org>
13759
13760 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
13761 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
13762 output.
13763 (getpkt_or_notif_sane_1): Likewise.
13764
e4241ace
YQ
137652017-01-13 Yao Qi <yao.qi@linaro.org>
13766
13767 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
13768 of CC. Pass "-x c++-header" instead of "-x c".
13769
3015c064
SM
137702017-01-12 Simon Marchi <simon.marchi@ericsson.com>
13771
13772 * remote.c (remote_can_async_p): Update comment.
13773
fde1b17d
SM
137742017-01-12 Simon Marchi <simon.marchi@ericsson.com>
13775
13776 * linux-nat.c (linux_nat_can_async_p): Update comment.
13777
ca1ca08b
SM
137782017-01-12 Simon Marchi <simon.marchi@ericsson.com>
13779
13780 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
13781
4ad2da73
SM
137822017-01-11 Simon Marchi <simon.marchi@ericsson.com>
13783
13784 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
13785
c8b23b3f
TT
137862017-01-10 Tom Tromey <tom@tromey.com>
13787
13788 * python/py-type.c (typy_legacy_template_argument): Update.
13789 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
13790 ~demangle_parse_info): Declare new members.
13791 (cp_demangled_name_to_comp): Return unique_ptr.
13792 (cp_demangled_name_parse_free)
13793 (make_cleanup_cp_demangled_name_parse_free)
13794 (cp_new_demangle_parse_info): Remove.
13795 * cp-support.c (do_demangled_name_parse_free_cleanup)
13796 (make_cleanup_cp_demangled_name_parse_free): Remove.
13797 (inspect_type, cp_canonicalize_string_full)
13798 (cp_canonicalize_string): Update.
13799 (mangled_name_to_comp): Change return type.
13800 (cp_class_name_from_physname, method_name_from_physname)
13801 (cp_func_name, cp_remove_params): Update.
13802 * cp-name-parser.y (demangle_parse_info): New constructor, from
13803 cp_new_demangle_parse_info.
13804 (~demangle_parse_info): New destructor, from
13805 cp_demangled_name_parse_free.
13806 (cp_merge_demangle_parse_infos): Update.
13807 (cp_demangled_name_to_comp): Change return type.
13808
1ac32117
TT
138092017-01-10 Tom Tromey <tom@tromey.com>
13810
13811 * top.c (prevent_dont_repeat): Change return type.
13812 * python/python.c (execute_gdb_command): Use std::string.
13813 Update.
13814 * guile/guile.c (gdbscm_execute_gdb_command): Update.
13815 * command.h (prevent_dont_repeat): Change return type.
13816 * breakpoint.c (bpstat_do_actions_1): Update.
13817
0cf08227
TT
138182017-01-10 Tom Tromey <tom@tromey.com>
13819
13820 * value.h (scoped_value_mark::~scoped_value_mark): Call
13821 free_to_mark.
13822 (scoped_value_mark::free_to_mark): New method.
13823 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
13824 scoped_value_mark.
13825
eb115069
TT
138262017-01-10 Tom Tromey <tom@tromey.com>
13827
13828 * python/py-value.c (valpy_dereference, valpy_referenced_value)
13829 (valpy_reference_value, valpy_const_value, valpy_get_address)
13830 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
13831 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
13832 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
13833 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
13834 scoped_value_mark.
13835 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
13836 * value.h (scoped_value_mark): New class.
13837
906768f9
TT
138382017-01-10 Tom Tromey <tom@tromey.com>
13839
13840 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
13841 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
13842 * psymtab.c (discard_psymtabs_upto): Remove.
13843 (make_cleanup_discard_psymtabs): Remove.
13844 (struct psymtab_state): Remove.
13845
bef155c3
TT
138462017-01-10 Tom Tromey <tom@tromey.com>
13847
13848 * record-full.c (record_full_save_cleanups): Remove.
13849 (record_full_save): Use gdb::unlinker.
13850 * gcore.c (do_bfd_delete_cleanup): Remove.
13851 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
13852 cleanups.
13853 * dwarf2read.c (unlink_if_set): Remove.
13854 (write_psymtabs_to_index): Use gdb::unlinker.
13855 * common/gdb_unlinker.h: New file.
13856
192b62ce
TT
138572017-01-10 Tom Tromey <tom@tromey.com>
13858
13859 * windows-tdep.c (windows_xfer_shared_library): Update.
13860 * windows-nat.c (windows_make_so): Update.
13861 * utils.h (make_cleanup_bfd_unref): Remove.
13862 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
13863 * symfile.h (symfile_bfd_open)
13864 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
13865 * symfile.c (read_symbols, symbol_file_add)
13866 (separate_debug_file_exists): Update.
13867 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
13868 (generic_load, reread_symbols): Update.
13869 * symfile-mem.c (symbol_file_add_from_memory): Update.
13870 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
13871 (spu_symbol_file_add_from_memory): Update.
13872 * solist.h (struct target_so_ops) <bfd_open>: Return
13873 gdb_bfd_ref_ptr.
13874 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
13875 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
13876 gdb_bfd_ref_ptr.
13877 (solib_map_sections, reload_shared_libraries_1): Update.
13878 * solib-svr4.c (enable_break): Update.
13879 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
13880 * solib-frv.c (enable_break2): Update.
13881 * solib-dsbt.c (enable_break): Update.
13882 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
13883 gdb_bfd_ref_ptr.
13884 (darwin_solib_get_all_image_info_addr_at_init): Update.
13885 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
13886 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
13887 * record-full.c (record_full_save): Update.
13888 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
13889 * procfs.c (insert_dbx_link_bpt_in_file): Update.
13890 * minidebug.c (find_separate_debug_file_in_section): Return
13891 gdb_bfd_ref_ptr.
13892 * machoread.c (macho_add_oso_symfile): Change abfd to
13893 gdb_bfd_ref_ptr.
13894 (macho_symfile_read_all_oso): Update.
13895 (macho_check_dsym): Return gdb_bfd_ref_ptr.
13896 (macho_symfile_read): Update.
13897 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
13898 (jit_bfd_try_read_symtab): Update.
13899 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
13900 (gdb_bfd_openw, gdb_bfd_openr_iovec)
13901 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
13902 gdb_bfd_ref_ptr.
13903 (gdb_bfd_ref_policy): New struct.
13904 (gdb_bfd_ref_ptr): New typedef.
13905 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
13906 (gdb_bfd_openw, gdb_bfd_openr_iovec)
13907 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
13908 gdb_bfd_ref_ptr.
13909 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
13910 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
13911 (gcore_command): Update.
13912 * exec.c (exec_file_attach): Update.
13913 * elfread.c (elf_symfile_read): Update.
13914 * dwarf2read.c (dwarf2_get_dwz_file): Update.
13915 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
13916 (open_and_init_dwo_file): Update.
13917 (open_dwp_file): Return gdb_bfd_ref_ptr.
13918 (open_and_init_dwp_file): Update.
13919 * corelow.c (core_open): Update.
13920 * compile/compile-object-load.c (compile_object_load): Update.
13921 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
13922 * coffread.c (coff_symfile_read): Update.
13923 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
13924 gdb_bfd_ref_ptr. Rename.
13925 (dump_bfd_file, restore_command): Update.
13926 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
13927 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
13928 (find_separate_debug_file_by_buildid): Update.
13929
50315b21
TT
139302017-01-10 Tom Tromey <tom@tromey.com>
13931
13932 * common/gdb_ref_ptr.h: New file.
13933 * python/py-ref.h (struct gdbpy_ref_policy): New.
13934 (gdbpy_ref): Now a typedef.
13935
fc4007c9
TT
139362017-01-10 Tom Tromey <tom@tromey.com>
13937
13938 * utils.h (make_cleanup_htab_delete): Don't declare.
13939 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
13940 Remove.
13941 * linespec.c (decode_compound_collector): Add constructor,
13942 destructor.
13943 (lookup_prefix_sym): Remove cleanup.
13944 (symtab_collector): Add constructor, destructor.
13945 (collect_symtabs_from_filename): Remove cleanup.
13946 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
13947 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
13948 Use htab_up.
13949 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
13950 * dwarf2read.c (dw2_expand_symtabs_matching)
13951 (dw2_map_symbol_filenames, dwarf_decode_macros)
13952 (write_psymtabs_to_index): Use htab_up.
13953 * dwarf2loc.c (func_verify_no_selftailcall)
13954 (call_site_find_chain_1, func_verify_no_selftailcall)
13955 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
13956 std::vector, gdb::unique_xmalloc_ptr.
13957 (call_sitep): Remove typedef.
13958 (dwarf2_locexpr_baton_eval): Remove unused variable.
13959
8dbcee67
TT
139602017-01-10 Tom Tromey <tom@tromey.com>
13961
13962 * python/python-internal.h (make_cleanup_py_decref)
13963 (make_cleanup_py_xdecref): Don't declare.
13964 * python/py-utils.c (py_decref, make_cleanup_py_decref)
13965 (py_xdecref, make_cleanup_py_xdecref): Remove.
13966
13df46cc
TT
139672017-01-10 Tom Tromey <tom@tromey.com>
13968
13969 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
13970 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
13971
06fc9bf7
TT
139722017-01-10 Tom Tromey <tom@tromey.com>
13973
13974 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
13975
830a4934
TT
139762017-01-10 Tom Tromey <tom@tromey.com>
13977
13978 * python/py-utils.c (unicode_to_encoded_string)
13979 (python_string_to_target_string)
13980 (python_string_to_target_python_string)
13981 (python_string_to_host_string, gdbpy_obj_to_string)
13982 (get_addr_from_python): Use gdbpy_ref.
13983
4586d543
TT
139842017-01-10 Tom Tromey <tom@tromey.com>
13985
13986 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
13987 gdbpy_ref.
13988
59876f8f
TT
139892017-01-10 Tom Tromey <tom@tromey.com>
13990
13991 * python/python.c (eval_python_command, gdbpy_decode_line)
13992 (gdbpy_run_events, gdbpy_start_type_printers)
13993 (gdbpy_apply_type_printers): Use gdbpy_ref.
13994
97d83487
TT
139952017-01-10 Tom Tromey <tom@tromey.com>
13996
13997 * python/py-param.c (get_doc_string, compute_enum_values): Use
13998 gdbpy_ref.
13999
9205649a
TT
140002017-01-10 Tom Tromey <tom@tromey.com>
14001
14002 * python/py-inferior.c (find_thread_object, build_inferior_list):
14003 Use gdbpy_ref.
14004
74c49d45
TT
140052017-01-10 Tom Tromey <tom@tromey.com>
14006
14007 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
14008
16361ffb
TT
140092017-01-10 Tom Tromey <tom@tromey.com>
14010
14011 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
14012 gdbpy_ref.
14013
905f2cca
TT
140142017-01-10 Tom Tromey <tom@tromey.com>
14015
14016 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
14017 extra incref.
14018 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
14019 Use gdbpy_ref.
14020
64081434
TT
140212017-01-10 Tom Tromey <tom@tromey.com>
14022
14023 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
14024 gdbpy_ref.
14025
59e9e831
TT
140262017-01-10 Tom Tromey <tom@tromey.com>
14027
14028 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
14029 decref results of PyArg_ParseTupleAndKeywords.
14030
9de10f6d
TT
140312017-01-10 Tom Tromey <tom@tromey.com>
14032
14033 * python/python.c (python_run_simple_file): Use
14034 unique_xmalloc_ptr, gdbpy_ref.
14035
2bd5759d
TT
140362017-01-10 Tom Tromey <tom@tromey.com>
14037
14038 * python/py-prettyprint.c (print_stack_unless_memory_error)
14039 (print_string_repr, print_children): Use gdbpy_ref.
14040 (dummy_python_frame): New class.
14041 (dummy_python_frame::dummy_python_frame): Rename from
14042 push_dummy_python_frame.
14043 (py_restore_tstate): Remove.
14044
3b4e0e01
TT
140452017-01-10 Tom Tromey <tom@tromey.com>
14046
14047 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
14048
17a22718
TT
140492017-01-10 Tom Tromey <tom@tromey.com>
14050
14051 * python/python.c (ensure_python_env, restore_python_env):
14052 Remove.
14053 * python/python-internal.h (ensure_python_env): Don't declare.
14054 * varobj.h (varobj_ensure_python_env): Don't declare.
14055 * varobj.c (varobj_ensure_python_env): Remove.
14056
68cdc557
TT
140572017-01-10 Tom Tromey <tom@tromey.com>
14058
14059 * varobj.c (varobj_value_get_print_value): Use
14060 gdbpy_enter_varobj.
14061
1eba6383
TT
140622017-01-10 Tom Tromey <tom@tromey.com>
14063
14064 * python/py-prettyprint.c (print_string_repr, print_children):
14065 Update.
14066 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
14067 of "encoding".
14068 * varobj.c (varobj_value_get_print_value): Update.
14069 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
14070
bde7b3e3
TT
140712017-01-10 Tom Tromey <tom@tromey.com>
14072
14073 * varobj.c (varobj_get_display_hint)
14074 (dynamic_varobj_has_child_method, install_new_value_visualizer)
14075 (varobj_set_visualizer, free_variable): Use
14076 gdbpy_enter_varobj.
14077
a7785f8c
TT
140782017-01-10 Tom Tromey <tom@tromey.com>
14079
14080 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
14081 (do_finish_initialization): New function. Use gdbpy_ref.
14082 (gdbpy_finish_initialization): Use gdbpy_enter. Call
14083 do_finish_initialization.
14084
2865bfce
TT
140852017-01-10 Tom Tromey <tom@tromey.com>
14086
14087 * python/py-param.c (get_set_value, get_show_value): Use
14088 gdbpy_enter, gdbpy_ref.
14089
0e9dcc75
TT
140902017-01-10 Tom Tromey <tom@tromey.com>
14091
14092 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
14093
12a5cedd
TT
140942017-01-10 Tom Tromey <tom@tromey.com>
14095
14096 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
14097
788f2586
TT
140982017-01-10 Tom Tromey <tom@tromey.com>
14099
14100 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
14101 Use gdbpy_enter_varobj.
14102
6cd67bea
TT
141032017-01-10 Tom Tromey <tom@tromey.com>
14104
14105 * varobj.c (gdbpy_enter_varobj): New constructor.
14106 * python/python-internal.h (gdbpy_enter_varobj): New class.
14107 * python/py-varobj.c (py_varobj_get_iterator): Use
14108 gdbpy_enter_varobj.
14109
14b122bf
TT
141102017-01-10 Tom Tromey <tom@tromey.com>
14111
14112 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
14113 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
14114 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
14115 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
14116 unique_xmalloc_ptr.
14117 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
14118
bf1ca3b9
TT
141192017-01-10 Tom Tromey <tom@tromey.com>
14120
14121 * python/py-xmethods.c (invoke_match_method): Use
14122 gdbpy_ref.
14123
572a5524
TT
141242017-01-10 Tom Tromey <tom@tromey.com>
14125
14126 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
14127 gdbpy_enter, gdbpy_ref.
14128
396a78b6
TT
141292017-01-10 Tom Tromey <tom@tromey.com>
14130
14131 * python/python.c (python_interactive_command): Use gdbpy_enter.
14132
a88b13c7
TT
141332017-01-10 Tom Tromey <tom@tromey.com>
14134
14135 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
14136 gdbpy_ref.
14137
e9f0c363
TT
141382017-01-10 Tom Tromey <tom@tromey.com>
14139
14140 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
14141 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
14142
6349f452
TT
141432017-01-10 Tom Tromey <tom@tromey.com>
14144
14145 * utils.h (htab_deleter): New struct.
14146 (htab_up): New typedef.
14147 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
14148 gdbpy_enter, gdbpy_ref, htab_up.
14149
c0171de6
TT
141502017-01-10 Tom Tromey <tom@tromey.com>
14151
14152 * python/py-unwind.c (pending_frame_invalidate): Remove.
14153 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
14154
f18e226f
TT
141552017-01-10 Tom Tromey <tom@tromey.com>
14156
14157 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
14158 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
14159
c57af3f1
TT
141602017-01-10 Tom Tromey <tom@tromey.com>
14161
14162 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
14163
60e600ec
TT
141642017-01-10 Tom Tromey <tom@tromey.com>
14165
14166 * python/python.c (gdbpy_eval_from_control_command)
14167 (gdbpy_source_script, gdbpy_run_events)
14168 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
14169 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
14170 gdbpy_enter.
14171
bf7da5b0
TT
141722017-01-10 Tom Tromey <tom@tromey.com>
14173
14174 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
14175
2d38bced
TT
141762017-01-10 Tom Tromey <tom@tromey.com>
14177
14178 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
14179
07bc7329
TT
141802017-01-10 Tom Tromey <tom@tromey.com>
14181
14182 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
14183 (python_on_inferior_call_pre, python_on_inferior_call_post)
14184 (python_on_memory_change, python_on_register_change)
14185 (python_inferior_exit, python_new_objfile, add_thread_object)
14186 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
14187
6e7c365e
TT
141882017-01-10 Tom Tromey <tom@tromey.com>
14189
14190 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
14191 (bpfinishpy_handle_exit): Use gdbpy_enter.
14192
6ba0cd40
TT
141932017-01-10 Tom Tromey <tom@tromey.com>
14194
14195 * python/py-cmd.c (cmdpy_destroyer)
14196 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
14197 gdbpy_enter.
14198
de2dc875
TT
141992017-01-10 Tom Tromey <tom@tromey.com>
14200
14201 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
14202 gdbpy_enter.
14203 (gdbpy_breakpoint_has_cond): Likewise.
14204
4ecee2c4
TT
142052017-01-10 Tom Tromey <tom@tromey.com>
14206
14207 * python/python.c (gdbpy_enter): New constructor.
14208 (~gdbpy_enter): New destructor.
14209 (restore_python_env, ensure_python_env): Rewrite.
14210 * python/python-internal.h (gdbpy_enter): New class.
14211
37fce74f
TT
142122017-01-10 Tom Tromey <tom@tromey.com>
14213
14214 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
14215
53a0cca3
TT
142162017-01-10 Tom Tromey <tom@tromey.com>
14217
14218 * python/py-value.c (value_has_field, get_field_flag)
14219 (get_field_type, valpy_getitem, convert_value_from_python): Use
14220 gdbpy_ref.
14221
ff3724f5
TT
142222017-01-10 Tom Tromey <tom@tromey.com>
14223
14224 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
14225 gdbpy_ref.
14226
0700aea5
TT
142272017-01-10 Tom Tromey <tom@tromey.com>
14228
14229 * python/py-prettyprint.c (search_pp_list)
14230 (find_pretty_printer_from_objfiles)
14231 (find_pretty_printer_from_progspace)
14232 (find_pretty_printer_from_gdb, find_pretty_printer)
14233 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
14234 gdbpy_ref.
14235
1bb44c9f
TT
142362017-01-10 Tom Tromey <tom@tromey.com>
14237
14238 * python/py-param.c (call_doc_function): Use gdbpy_ref.
14239
87ce03fd
TT
142402017-01-10 Tom Tromey <tom@tromey.com>
14241
14242 * python/py-linetable.c (build_line_table_tuple_from_pcs)
14243 (ltpy_get_all_source_lines): Use gdbpy_ref.
14244
ee0a3fb8
TT
142452017-01-10 Tom Tromey <tom@tromey.com>
14246
14247 * python/py-framefilter.c (extract_sym, extract_value)
14248 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
14249 gdbpy_ref.
14250
bf2a52fa
TT
142512017-01-10 Tom Tromey <tom@tromey.com>
14252
14253 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
14254
f59fe7f8
TT
142552017-01-10 Tom Tromey <tom@tromey.com>
14256
14257 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
14258
80bd970a
TT
142592017-01-10 Tom Tromey <tom@tromey.com>
14260
14261 * python/py-function.c (convert_values_to_python, fnpy_init): Use
14262 gdbpy_ref.
14263
d1b3de2e
TT
142642017-01-10 Tom Tromey <tom@tromey.com>
14265
14266 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
14267
3bb43384
TT
142682017-01-10 Tom Tromey <tom@tromey.com>
14269
14270 * python/py-type.c (convert_field, make_fielditem, typy_fields)
14271 (typy_range): Use gdbpy_ref.
14272
abf5651e
TT
142732017-01-10 Tom Tromey <tom@tromey.com>
14274
14275 * python/py-threadevent.c (create_thread_event_object): Use
14276 gdbpy_ref.
14277 * python/py-stopevent.c (create_stop_event_object): Simplify.
14278 (emit_stop_event): Use gdbpy_ref.
14279 * python/py-signalevent.c (create_signal_event_object): Use
14280 gdbpy_ref.
14281 * python/py-newobjfileevent.c (create_new_objfile_event_object)
14282 (emit_new_objfile_event, create_clear_objfiles_event_object)
14283 (emit_clear_objfiles_event): Use gdbpy_ref.
14284 * python/py-infevents.c (create_inferior_call_event_object)
14285 (create_register_changed_event_object)
14286 (create_memory_changed_event_object, emit_inferior_call_event)
14287 (emit_memory_changed_event, emit_register_changed_event): Use
14288 gdbpy_ref.
14289 * python/py-exitedevent.c (create_exited_event_object)
14290 (emit_exited_event): Use gdbpy_ref.
14291 * python/py-event.h (evpy_emit_event): Remove
14292 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
14293 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
14294 * python/py-continueevent.c (emit_continue_event): Use
14295 gdbpy_ref.
14296 * python/py-breakpoint.c (gdbpy_breakpoint_created)
14297 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
14298 gdbpy_ref.
14299 * python/py-bpevent.c (create_breakpoint_event_object): Use
14300 gdbpy_ref.
14301
a68ff33e
TT
143022017-01-10 Tom Tromey <tom@tromey.com>
14303
14304 * python/py-ref.h: New file.
14305
7becfd03
SM
143062017-01-10 Simon Marchi <simon.marchi@ericsson.com>
14307
14308 * cli-out.c (cli_ui_out::do_redirect): Change return type to
14309 void.
14310 * cli-out.h (cli_ui_out::do_redirect): Likewise.
14311 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
14312 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
14313 * ui-out.c (ui_out::redirect): Likewise.
14314 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
14315 * cli/cli-logging.c (set_logging_redirect): Update call site of
14316 ui_out::redirect.
14317 (handle_redirections): Likewise.
14318 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
14319 * top.c (execute_command_to_string): Likewise.
14320 * utils.c (do_ui_out_redirect_pop): Likewise.
14321
df294654
SM
143222017-01-10 Simon Marchi <simon.marchi@ericsson.com>
14323
14324 * stack.c (_initialize_stack): Update "frame" command help message.
14325
f5e6296e
IB
143262017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
14327
14328 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
14329
0e2d6fa6
YQ
143302017-01-06 Yao Qi <yao.qi@linaro.org>
14331
14332 * x86-linux-nat.h: Include gdb_proc_service.h.
14333
44d6d3f9
YQ
143342017-01-06 Yao Qi <yao.qi@linaro.org>
14335
14336 * ser-base.h: Include serial.h.
14337
656731fe
YQ
143382017-01-06 Yao Qi <yao.qi@linaro.org>
14339
14340 * ppc-linux-tdep.h: Include ppc-tdep.h.
14341
1ca8f924
YQ
143422017-01-06 Yao Qi <yao.qi@linaro.org>
14343
14344 * nat/amd64-linux-siginfo.h: Include signal.h.
14345
bc3008c4
YQ
143462017-01-06 Yao Qi <yao.qi@linaro.org>
14347
14348 * nat/aarch64-linux-hw-point.h: Include break-common.h.
14349
66c80d03
YQ
143502017-01-06 Yao Qi <yao.qi@linaro.org>
14351
14352 * mi/mi-parse.h: Include mi-cmds.h.
14353
051d2dda
YQ
143542017-01-06 Yao Qi <yao.qi@linaro.org>
14355
14356 * inf-loop.c: Don't include "target.h".
14357 * inf-loop.h: Include it here.
14358
8018d34f
YQ
143592017-01-06 Yao Qi <yao.qi@linaro.org>
14360
14361 * dfp.h: Include "dboulest.h" and "expression.h".
14362
c0b8369c
YQ
143632017-01-06 Yao Qi <yao.qi@linaro.org>
14364
14365 * ax-gdb.h: Include "ax.h".
14366
ad5cba2a
YQ
143672017-01-06 Yao Qi <yao.qi@linaro.org>
14368
14369 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
14370 with nat/gdb_ptrace.h.
14371
1c33cd7f
YQ
143722017-01-05 Yao Qi <yao.qi@linaro.org>
14373
14374 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
14375 new line.
14376 (mips64_fbsd_sigframe_init): Likewise.
14377
c988ac1d
JB
143782017-01-04 John Baldwin <jhb@FreeBSD.org>
14379
14380 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
14381 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
14382
b268007c
JB
143832017-01-04 John Baldwin <jhb@FreeBSD.org>
14384
14385 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
14386 * NEWS: Mention new FreeBSD/mips native configuration.
14387 * config/mips/fbsd.mh: New file.
14388 * configure.host: Add mips*-*-freebsd*.
14389 * mips-fbsd-nat.c: New file.
14390
387360da
JB
143912017-01-04 John Baldwin <jhb@FreeBSD.org>
14392
14393 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
14394 (ALLDEPFILES): Add mips-fbsd-tdep.c.
14395 * NEWS: Mention new FreeBSD/mips target.
14396 * configure.tgt: Add mips*-*-freebsd*.
14397 * mips-fbsd-tdep.c: New file.
14398 * mips-fbsd-tdep.h: New file.
14399
2aaaf250
YQ
144002017-01-04 Yao Qi <yao.qi@linaro.org>
14401
14402 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
14403 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
14404
61baf725
JB
144052017-01-01 Joel Brobecker <brobecker@adacore.com>
14406
6dbb839a 14407 Update copyright year range in all GDB files.
61baf725 14408
c113e7ff 144092017-01-01 Joel Brobecker <brobecker@adacore.com>
ce0db137 14410
c113e7ff 14411 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
ce0db137 14412
c113e7ff 14413For older changes see ChangeLog-2016.
c906108c
SS
14414\f
14415Local Variables:
14416mode: change-log
14417left-margin: 8
14418fill-column: 74
14419version-control: never
57da7796 14420coding: utf-8
c906108c 14421End: