Fix regression on ARM after Target FP patches
[deliverable/binutils-gdb.git] / gdb / ChangeLog
1 2017-11-03 Ulrich Weigand <uweigand@de.ibm.com>
2
3 * doublest.c (convert_doublest_to_floatformat): Fix uninitialized
4 output when converting a zero value to a special byteorder format.
5
6 2017-11-02 Yao Qi <yao.qi@linaro.org>
7
8 * frame.c (do_frame_register_read): Remove aspace.
9 * jit.c (jit_frame_sniffer): Likwise.
10 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
11 * regcache.c (regcache::regcache): Pass nullptr.
12 (regcache_print): Caller updated.
13 * regcache.h (regcache::regcache): Remove one constructor
14 parameter aspace.
15
16 2017-11-02 Yao Qi <yao.qi@linaro.org>
17
18 * regcache.h (regcache) <m_readonly_p>: Change it to const bool.
19
20 2017-11-02 Yao Qi <yao.qi@linaro.org>
21
22 * breakpoint.c (insert_single_step_breakpoints): Update.
23 * frame.c (struct frame_info) <aspace>: Add const.
24 (frame_save_as_regcache): Add const.
25 (get_frame_address_space): Return const address_space *.
26 * frame.h (get_frame_address_space): Update declaration.
27 * infrun.c (struct step_over_info) <aspace>: Add const.
28 (set_step_over_info): Make aspace const.
29 (displaced_step_prepare_throw): Change variable const.
30 (resume): Likewise.
31 (proceed): Likewise.
32 (adjust_pc_after_break): Likewise.
33 (save_waitstatus): Likewise.
34 (handle_signal_stop): Likewise.
35 (keep_going_pass_signal): Likewise.
36 * jit.c (jit_frame_sniffer): Add const.
37 * mips-tdep.c (mips_single_step_through_delay): Likewise.
38 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
39 * record-full.c (record_full_wait_1): Likewise.
40 * regcache.c (regcache::regcache): Change parameter to const.
41 * regcache.h (regcache::regcache): Likewise.
42 (regcache::aspace): Return const address_space *.
43 (regcache) <m_aspace>: Add const.
44
45 2017-11-02 Yao Qi <yao.qi@linaro.org>
46
47 * darwin-nat.c (cancel_breakpoint): Use regcache->aspace ().
48 * frame.c (create_sentinel_frame): Likewise.
49 * infrun.c (displaced_step_prepare_throw): Likewise.
50 (resume): Likewise.
51 (thread_still_needs_step_over_bp): Likewise.
52 (proceed): Likewise.
53 (do_target_wait): Likewise.
54 (adjust_pc_after_break): Likewise.
55 (handle_syscall_event): Likewise.
56 (save_waitstatus): Likewise.
57 (handle_inferior_event_1): Likewise.
58 (handle_signal_stop): Likewise.
59 (keep_going_pass_signal): Likewise.
60 * linux-nat.c (status_callback): Likewise.
61 (save_stop_reason): Likewise.
62 (resume_stopped_resumed_lwps): Likewise.
63 * record-full.c (record_full_exec_insn): Likewise.
64 (record_full_wait_1): Likewise.
65 * regcache.c (get_regcache_aspace): Remove.
66 * regcache.h (get_regcache_aspace): Remove.
67
68 2017-11-02 Yao Qi <yao.qi@linaro.org>
69
70 * regcache.c (struct regcache_descr) <nr_raw_registers>: Remove.
71 (init_regcache_descr): Use gdbarch_num_regs.
72 (regcache::regcache): Likewise.
73 (regcache::get_register_status): Likewise.
74 (regcache::assert_raw_regnum): Likewise.
75 (regcache::cooked_read): Likewise.
76 (regcache::cooked_read_value): Likewise.
77 (regcache::cooked_write): Likewise.
78 (regcache::dump): Likewise.
79 (regcache::num_raw_registers): New method.
80 * regcache.h (class regcache) <num_raw_registers>: New.
81
82 2017-11-02 Yao Qi <yao.qi@linaro.org>
83
84 * regcache.c (regcache::assert_regnum): New method.
85 (regcache::invalidate): Call assert_regnum.
86 (regcache::raw_update): Likewise.
87 (regcache::raw_write): Likewise.
88 (regcache::raw_read_part): Likewise.
89 (regcache::raw_write_part): Likewise.
90 (regcache::raw_supply): Likewise.
91 (regcache::raw_supply_integer): Likewise.
92 (regcache::raw_supply_zeroed): Likewise.
93 (regcache::raw_collect): Likewise.
94 (regcache::raw_collect_integer): Likewise.
95 * regcache.h (regcache::assert_regnum): Declare.
96
97 2017-11-02 Yao Qi <yao.qi@linaro.org>
98
99 * regcache.c (regcache::dump): Remove code.
100
101 2017-11-02 Yao Qi <yao.qi@linaro.org>
102
103 * regcache.c (struct regcache_descr) <sizeof_raw_register_status>:
104 Remove.
105 <sizeof_cooked_register_status>: Remove.
106 (init_regcache_descr): Update.
107 (regcache::regcache): Use nr_cooked_registers and nr_raw_registers.
108 (regcache::save): Likewise.
109 (regcache::dump): Likewise.
110
111 2017-11-01 James Bowman <james.bowman@ftdichip.com>
112
113 * ft32-tdep.c (ft32_fetch_instruction): New function.
114 (ft32_analyze_prologue): Use ft32_fetch_instruction().
115
116 2017-10-31 Simon Marchi <simon.marchi@polymtl.ca>
117
118 * cli/cli-script.c (execute_control_command): Rename to ...
119 (execute_control_command_1): ... this.
120 (execute_control_command): New function.
121
122 2017-10-31 Simon Marchi <simon.marchi@ericsson.com>
123
124 * tracepoint.c (tfind_command): Remove const_cast.
125
126 2017-10-30 Mike Gulick <mgulick@mathworks.com>
127
128 * Makefile.in (HFILES_NO_SRCDIR): Remove reference to gdb.h.
129
130 2017-10-30 Simon Marchi <simon.marchi@ericsson.com>
131
132 * common/common-utils.h (in_inclusive_range): New function.
133 * arm-tdep.c (arm_record_extension_space): Use
134 in_inclusive_range.
135 (thumb_record_ld_st_reg_offset): Use in_inclusive_range.
136 * cris-tdep.c (cris_spec_reg_applicable): Use
137 in_inclusive_range.
138
139 2017-10-30 Pedro Alves <palves@redhat.com>
140 Simon Marchi <simon.marchi@ericsson.com>
141
142 * remote.c (remote_set_syscall_catchpoint): Build a std::string
143 instead of a gdb::unique_xmalloc_ptr, using string_appendf.
144
145 2017-10-30 Pedro Alves <palves@redhat.com>
146
147 * common/common-utils.c (string_appendf, string_vappendf): New
148 functions.
149 * common/common-utils.h (string_appendf, string_vappendf): New
150 declarations.
151 * unittests/common-utils-selftests.c (string_appendf_func)
152 (test_appendf_func, string_vappendf_wrapper, string_appendf_tests)
153 (string_vappendf_tests): New functions.
154 (_initialize_common_utils_selftests): Register "string_appendf" and
155 "string_vappendf tests".
156
157 2017-10-30 Pedro Alves <palves@redhat.com>
158
159 * unittests/common-utils-selftests.c (format_func): New typedef.
160 (string_printf_tests, string_vprintf_tests): Tests factored out
161 and merged to ...
162 (test_format_func): ... this new function.
163 (string_printf_tests, string_vprintf_tests): Reimplement on top of
164 test_format_func.
165
166 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
167
168 * darwin-nat.c: Remove include of gdb.h.
169
170 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
171
172 * xtensa-xtregs.c: Fix formatting issues.
173
174 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
175
176 * xtensa-xtregs.c (xtensa_regtable_t) <name>: Constify.
177
178 2017-10-28 Maksim Dzabraev <dzabraew@gmail.com>
179
180 PR python/21213
181 * python/py-infthread.c (thpy_get_inferior): Increment reference
182 of inferior before returning it.
183
184 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
185
186 * unittests/common-utils-selftests.c (format): Add
187 ATTRIBUTE_PRINTF.
188
189 2017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
190
191 * xml-syscall.c (struct syscall_desc): Add constructor.
192 <name>: Change type to std::string.
193 (syscall_desc_up): New typedef.
194 (syscall_desc_p): Remove typeder.
195 (DEF_VEC_P(syscall_desc_p)): Remove.
196 (struct syscall_group_desc): Add constructor.
197 <name>: Change type to std::string.
198 <syscalls>: Change type to std::vector.
199 (syscall_group_desc_up): New typedef.
200 (syscall_group_desc_p): Remove typedef.
201 (DEF_VEC_P(syscall_group_desc_p)): Remove.
202 (struct syscalls_info) <syscalls>: Change type to std::vector of
203 unique_ptr.
204 <groups>: Likewise.
205 <my_gdb_datadir>: Change type to std::string.
206 (syscalls_info_up): New typedef.
207 (allocate_syscalls_info): Remove.
208 (syscalls_info_free_syscalls_desc): Remove.
209 (syscalls_info_free_syscall_group_desc): Remove.
210 (free_syscalls_info): Remove.
211 (make_cleanup_free_syscalls_info): Remove.
212 (syscall_group_create_syscall_group_desc): Adjust.
213 (syscall_group_add_syscall): Adjust.
214 (syscall_create_syscall_desc): Adjust.
215 (syscall_parse_xml): Adjust, use unique_ptr instead of cleanup.
216 (init_syscalls_info): Adjust.
217 (syscall_group_get_group_by_name): Adjust.
218 (xml_get_syscall_number): Adjust.
219 (xml_get_syscall_name): Adjust.
220 (xml_list_of_syscalls): Adjust.
221 (xml_list_syscalls_by_group): Adjust.
222 (xml_list_of_groups): Adjust.
223
224 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
225
226 * probe.h: Don't include gdb_vecs.h.
227 (DEF_VEC_P (probe_p)): Remove.
228 (find_probes_in_objfile): Return an std::vector.
229 * probe.c (find_probes_in_objfile): Likewise.
230 * breakpoint.c (breakpoint_objfile_data)
231 <longjmp_probes>: Change type to std::vector.
232 <exception_probes>: Likewise.
233 (free_breakpoint_probes): Don't manually free vectors.
234 (create_longjmp_master_breakpoint): Adjust.
235 (create_exception_master_breakpoint): Adjust.
236 * solib-svr4.c (svr4_create_probe_breakpoints): Change
237 parameter type, adjust.
238 (svr4_create_solib_event_breakpoints): Adjust.
239
240 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
241
242 * breakpoint.c (breakpoint_objfile_data): Initialize fields.
243 (get_breakpoint_objfile_data): Allocate breakpoint_objfile_data
244 with new.
245 (free_breakpoint_probes): Rename to ...
246 (free_breakpoint_objfile_data): ... this, and call delete on
247 bp_objfile_data..
248
249 2017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
250
251 * auto-load.c: Don't include gdb_vecs.h, include algorithm.
252 (loaded_script_ptr): Remove typedef.
253 (DEF_VEC_P (loaded_script_ptr)): Remove.
254 (struct collect_matching_scripts_data): Add constructor.
255 <scripts_p>: Change type to (pointer to) std::vector.
256 (collect_matching_scripts_data): Adjust.
257 (sort_scripts_by_name): Make suitable for std::sort.
258 (print_scripts): Don't sort vector, adjust to std::vector.
259 (auto_load_info_scripts): Sort vectors, adjust to std::vector.
260
261 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
262
263 * symfile.c (filename_language): Make struct, not typedef. Add
264 constructor.
265 <ext>: Change type to std::string.
266 (DEF_VEC_O (filename_language)): Remove.
267 (filename_language_table): Change type to std::vector.
268 (add_filename_language): Adjust.
269 (set_ext_lang_command): Adjust.
270 (info_ext_lang_command): Adjust.
271 (deduce_language_from_filename): Adjust.
272 (class scoped_restore_filename_language_table): Remove.
273 (test_filename_language): Use scoped_restore.
274 (test_set_ext_lang_command): Use scoped_restore, adjust to
275 std::vector change.
276
277 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
278
279 * symfile.c: Include selftest.h.
280 (class scoped_restore_filename_language_table): New.
281 (test_filename_language): New test.
282 (test_set_ext_lang_command): New test.
283 (_initialize_symfile): Register tests.
284
285 2017-10-27 Keith Seitz <keiths@redhat.com>
286
287 * breakpoint.c (print_breakpoint_location): Use the symbol saved
288 in the bp_location, falling back to find_pc_sect_function when
289 needed.
290 (add_location_to_breakpoint): Save sal->symbol.
291 * breakpoint.h (struct bp_location) <symbol>: New field.
292 * symtab.c (find_function_start_sal): Save the symbol into the SaL.
293 * symtab.h (struct symtab_and_line) <symbol>: New field.
294
295 2017-10-26 Patrick Frants <osscontribute@gmail.com>
296
297 PR gdb/13669
298 * cp-valprint.c (cp_print_value_fields): Use obstack_blank_fast
299 to rewind obstack.
300
301 2017-10-26 Pedro Alves <palves@redhat.com>
302
303 * remote.c (remote_async_terminal_ours_p): Delete.
304 (remote_open_1, remote_terminal_inferior, remote_terminal_ours):
305 Remove references to 'remote_async_terminal_ours_p'.
306
307 2017-10-26 Yao Qi <yao.qi@linaro.org>
308
309 * breakpoint.h (regular_breakpoint_inserted_here_p): Remove.
310
311 2017-10-26 Yao Qi <yao.qi@linaro.org>
312
313 * break-catch-sig.c (signal_catchpoint_breakpoint_hit): Make
314 aspace const.
315 * break-catch-syscall.c (breakpoint_hit_catch_syscall):
316 Likewise.
317 * breakpoint.c (bpstat_check_location): Remove cast.
318 (breakpoint_hit_catch_fork): Make aspce const.
319 (breakpoint_hit_catch_solib): Likewise.
320 (breakpoint_hit_catch_exec): Likewise.
321 (breakpoint_hit_ranged_breakpoint): Likewise.
322 (breakpoint_hit_watchpoint): Likewise.
323 (base_breakpoint_breakpoint_hit): Likewise.
324 (bkpt_breakpoint_hit): Likewise.
325 (dprintf_breakpoint_hit): Likewise.
326 (tracepoint_breakpoint_hit): Likewise.
327 * breakpoint.h (breakpoint_ops) <breakpoint_hit>: Likewise.
328
329 2017-10-26 Yao Qi <yao.qi@linaro.org>
330
331 * breakpoint.c (breakpoint_location_address_match): Change
332 "struct address_space *" to "const address_space".
333 (breakpoint_location_address_range_overlap): Likewise.
334 (breakpoint_here_p): Likewise.
335 (breakpoint_in_range_p): Likewise.
336 (moribund_breakpoint_here_p): Likewise.
337 (bp_location_inserted_here_p): Likewise.
338 (software_breakpoint_inserted_here_p): Likewise.
339 (hardware_breakpoint_inserted_here_p): Likewise.
340 (hardware_watchpoint_inserted_in_range): Likewise.
341 (bpstat_check_location): Likewise.
342 (bpstat_stop_status): Likewise.
343 (breakpoint_address_match): Likewise.
344 (breakpoint_address_match_range): Likewise.
345 (breakpoint_location_address_match): Likewise.
346 (breakpoint_location_address_range_overlap): Likewise.
347 (insert_single_step_breakpoint): Likewise.
348 (breakpoint_has_location_inserted_here): Likewise.
349 (single_step_breakpoint_inserted_here_p): Likewise.
350 (pc_at_non_inline_function): Likewise.
351 * breakpoint.h (bpstat_stop_status): Update declaration.
352 (breakpoint_here_p): Likewise.
353 (breakpoint_in_range_p): Likewise.
354 (moribund_breakpoint_here_p): Likewise.
355 (breakpoint_inserted_here_p): Likewise.
356 (software_breakpoint_inserted_here_p): Likewise.
357 (hardware_breakpoint_inserted_here_p): Likewise.
358 (breakpoint_has_location_inserted_here): Likewise.
359 (single_step_breakpoint_inserted_here_p): Likewise.
360 (hardware_watchpoint_inserted_in_range): Likewise.
361 (breakpoint_address_match): Likewise.
362 (insert_single_step_breakpoint): Likewise.
363 (pc_at_non_inline_function): Likewise.
364 * gdbthread.h (thread_has_single_step_breakpoint_here): Likewise.
365 * record.c (record_check_stopped_by_breakpoint): Likewise.
366 * record.h (record_check_stopped_by_breakpoint): Likewise.
367 * thread.c (thread_has_single_step_breakpoint_here): Likewise.
368
369 2017-10-25 Yao Qi <yao.qi@linaro.org>
370
371 * aarch32-linux-nat.c (aarch32_gp_regcache_supply): Use
372 regcache->arch () instead get_regcache_arch.
373 * aarch64-fbsd-nat.c (aarch64_fbsd_fetch_inferior_registers):
374 Likewise.
375 (aarch64_fbsd_store_inferior_registers): Likewise.
376 * aarch64-linux-nat.c (fetch_gregs_from_thread): Likewise.
377 (store_gregs_to_thread): Likewise.
378 (fetch_fpregs_from_thread): Likewise.
379 (store_fpregs_to_thread): Likewise.
380 * aarch64-tdep.c (aarch64_extract_return_value): Likewise.
381 (aarch64_store_return_value): Likewise.
382 (aarch64_software_single_step): Likewise.
383 * aix-thread.c (aix_thread_wait): Likewise.
384 (supply_reg32): Likewise.
385 (supply_sprs64): Likewise.
386 (supply_sprs32): Likewise.
387 (fill_gprs64): Likewise.
388 (fill_gprs32): Likewise.
389 (fill_sprs64): Likewise.
390 (fill_sprs32): Likewise.
391 (store_regs_user_thread): Likewise.
392 (store_regs_kernel_thread): Likewise.
393 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers): Likewise.
394 (alphabsd_store_inferior_registers): Likewise.
395 * alpha-tdep.c (alpha_extract_return_value): Likewise.
396 (alpha_store_return_value): Likewise.
397 (alpha_deal_with_atomic_sequence): Likewise.
398 (alpha_next_pc): Likewise.
399 (alpha_software_single_step): Likewise.
400 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Likewise.
401 (amd64bsd_store_inferior_registers): Likewise.
402 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers):
403 Likewise.
404 (amd64_linux_store_inferior_registers): Likewise.
405 * amd64-nat.c (amd64_supply_native_gregset): Likewise.
406 (amd64_collect_native_gregset): Likewise.
407 * amd64-obsd-tdep.c (amd64obsd_supply_uthread): Likewise.
408 (amd64obsd_collect_uthread): Likewise.
409 * amd64-tdep.c (amd64_supply_fpregset): Likewise.
410 (amd64_collect_fpregset): Likewise.
411 (amd64_supply_fxsave): Likewise.
412 (amd64_supply_xsave): Likewise.
413 (amd64_collect_fxsave): Likewise.
414 (amd64_collect_xsave): Likewise.
415 * arc-tdep.c (arc_write_pc): Likewise.
416 * arch-utils.c (default_skip_permanent_breakpoint): Likewise.
417 * arm-fbsd-nat.c (arm_fbsd_fetch_inferior_registers): Likewise.
418 (arm_fbsd_store_inferior_registers): Likewise.
419 * arm-linux-nat.c (fetch_vfp_regs): Likewise.
420 (store_vfp_regs): Likewise.
421 (arm_linux_fetch_inferior_registers): Likewise.
422 (arm_linux_store_inferior_registers): Likewise.
423 * arm-linux-tdep.c (arm_linux_supply_gregset): Likewise.
424 (arm_linux_sigreturn_next_pc): Likewise.
425 (arm_linux_get_next_pcs_syscall_next_pc): Likewise.
426 * arm-nbsd-nat.c (arm_supply_gregset): Likewise.
427 (fetch_register): Likewise.
428 (store_register): Likewise.
429 * arm-tdep.c (arm_is_thumb): Likewise.
430 (displaced_in_arm_mode): Likewise.
431 (bx_write_pc): Likewise.
432 (arm_get_next_pcs_addr_bits_remove): Likewise.
433 (arm_software_single_step): Likewise.
434 (arm_extract_return_value): Likewise.
435 (arm_store_return_value): Likewise.
436 (arm_write_pc): Likewise.
437 * bfin-tdep.c (bfin_extract_return_value): Likewise.
438 * bsd-uthread.c (bsd_uthread_fetch_registers): Likewise.
439 (bsd_uthread_store_registers): Likewise.
440 * core-regset.c (fetch_core_registers): Likewise.
441 * corelow.c (get_core_registers): Likewise.
442 * cris-tdep.c (cris_store_return_value): Likewise.
443 (cris_extract_return_value): Likewise.
444 (find_step_target): Likewise.
445 (find_step_target): Likewise.
446 (cris_software_single_step): Likewise.
447 * ctf.c (ctf_fetch_registers): Likewise.
448 * darwin-nat.c (cancel_breakpoint): Likewise.
449 * fbsd-tdep.c (fbsd_collect_thread_registers): Likewise.
450 * frv-tdep.c (frv_extract_return_value): Likewise.
451 * ft32-tdep.c (ft32_store_return_value): Likewise.
452 (ft32_extract_return_value): Likewise.
453 * go32-nat.c (fetch_register): Likewise.
454 (go32_fetch_registers): Likewise.
455 (go32_store_registers): Likewise.
456 (store_register): Likewise.
457 * h8300-tdep.c (h8300_extract_return_value): Likewise.
458 (h8300_store_return_value): Likewise.
459 * hppa-linux-nat.c (fetch_register): Likewise.
460 (store_register): Likewise.
461 (hppa_linux_fetch_inferior_registers): Likewise.
462 (hppa_linux_store_inferior_registers): Likewise.
463 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers): Likewise.
464 (i386_darwin_store_inferior_registers): Likewise.
465 * i386-gnu-nat.c (gnu_fetch_registers): Likewise.
466 (gnu_store_registers): Likewise.
467 * i386-linux-nat.c (fetch_register): Likewise.
468 (store_register): Likewise.
469 (supply_gregset): Likewise.
470 (fill_gregset): Likewise.
471 (i386_linux_fetch_inferior_registers): Likewise.
472 (i386_linux_store_inferior_registers): Likewise.
473 (i386_linux_resume): Likewise.
474 * i386-linux-tdep.c (i386_linux_get_syscall_number_from_regcache):
475 Likewise.
476 * i386-nto-tdep.c (i386nto_supply_gregset): Likewise.
477 * i386-obsd-nat.c (i386obsd_supply_pcb): Likewise.
478 * i386-obsd-tdep.c (i386obsd_supply_uthread): Likewise.
479 (i386obsd_collect_uthread): Likewise.
480 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
481 (i386_supply_gregset): Likewise.
482 (i386_collect_gregset): Likewise.
483 (i386_supply_fpregset): Likewise.
484 (i386_collect_fpregset): Likewise.
485 (i386_mpx_bd_base): Likewise.
486 * i386-v4-nat.c (supply_fpregset): Likewise.
487 (fill_fpregset): Likewise.
488 * i387-tdep.c (i387_supply_fsave): Likewise.
489 (i387_collect_fsave): Likewise.
490 (i387_supply_fxsave): Likewise.
491 (i387_collect_fxsave): Likewise.
492 (i387_supply_xsave): Likewise.
493 (i387_collect_xsave): Likewise.
494 * ia64-linux-nat.c (ia64_linux_fetch_registers): Likewise.
495 (ia64_linux_store_registers): Likewise.
496 * ia64-tdep.c (ia64_access_rse_reg): Likewise.
497 (ia64_extract_return_value): Likewise.
498 (ia64_store_return_value): Likewise.
499 (find_func_descr): Likewise.
500 * inf-child.c (inf_child_fetch_inferior_registers): Likewise.
501 * inf-ptrace.c (inf_ptrace_fetch_registers): Likewise.
502 (inf_ptrace_store_registers): Likewise.
503 * infrun.c (use_displaced_stepping): Likewise.
504 (displaced_step_prepare_throw): Likewise.
505 (resume): Likewise.
506 (proceed): Likewise.
507 (do_target_wait): Likewise.
508 (adjust_pc_after_break): Likewise.
509 (handle_inferior_event_1): Likewise.
510 (handle_signal_stop): Likewise.
511 (save_infcall_suspend_state): Likewise.
512 (restore_infcall_suspend_state): Likewise.
513 * iq2000-tdep.c (iq2000_extract_return_value): Likewise.
514 * jit.c (jit_frame_prev_register): Likewise.
515 * linux-nat.c (save_stop_reason): Likewise.
516 (linux_nat_wait_1): Likewise.
517 (resume_stopped_resumed_lwps): Likewise.
518 * linux-record.c (record_linux_sockaddr): Likewise.
519 (record_linux_msghdr): Likewise.
520 (record_linux_system_call): Likewise.
521 * linux-tdep.c (linux_collect_thread_registers): Likewise.
522 * lm32-tdep.c (lm32_extract_return_value): Likewise.
523 (lm32_store_return_value): Likewise.
524 * m32c-tdep.c (m32c_read_flg): Likewise.
525 (m32c_pseudo_register_read): Likewise.
526 (m32c_pseudo_register_write): Likewise.
527 * m32r-linux-tdep.c (m32r_linux_supply_gregset): Likewise.
528 (m32r_linux_collect_gregset): Likewise.
529 * m32r-tdep.c (m32r_store_return_value): Likewise.
530 (m32r_extract_return_value): Likewise.
531 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
532 (m68kbsd_collect_fpregset): Likewise.
533 * m68k-bsd-tdep.c (m68kbsd_supply_fpregset): Likewise.
534 * m68k-linux-nat.c (fetch_register): Likewise.
535 (old_fetch_inferior_registers): Likewise.
536 (old_store_inferior_registers): Likewise.
537 (store_regs): Likewise.
538 * m68k-tdep.c (m68k_svr4_extract_return_value): Likewise.
539 (m68k_svr4_store_return_value): Likewise.
540 * m88k-tdep.c (m88k_store_arguments): Likewise.
541 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Likewise.
542 (mi_cmd_data_write_register_values): Likewise.
543 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers): Likewise.
544 (mips_fbsd_store_inferior_registers): Likewise.
545 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Likewise.
546 (mips_fbsd_supply_gregs): Likewise.
547 (mips_fbsd_collect_fpregs): Likewise.
548 (mips_fbsd_collect_gregs): Likewise.
549 (mips_fbsd_supply_fpregset): Likewise.
550 (mips_fbsd_collect_fpregset): Likewise.
551 (mips_fbsd_supply_gregset): Likewise.
552 (mips_fbsd_collect_gregset): Likewise.
553 * mips-linux-nat.c (supply_gregset): Likewise.
554 (fill_gregset): Likewise.
555 (supply_fpregset): Likewise.
556 (fill_fpregset): Likewise.
557 * mips-linux-tdep.c (mips_supply_gregset): Likewise.
558 (mips_fill_gregset): Likewise.
559 (mips_supply_fpregset): Likewise.
560 (mips_fill_fpregset): Likewise.
561 (mips64_supply_gregset): Likewise.
562 (micromips_linux_sigframe_validate): Likewise.
563 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers): Likewise.
564 (mipsnbsd_fetch_inferior_registers): Likewise.
565 (mipsnbsd_store_inferior_registers): Likewise.
566 * mips-nbsd-tdep.c (mipsnbsd_supply_fpregset): Likewise.
567 (mipsnbsd_supply_gregset): Likewise.
568 (mipsnbsd_iterate_over_regset_sections): Likewise.
569 (mipsnbsd_supply_reg): Likewise.
570 (mipsnbsd_supply_fpreg): Likewise.
571 * mips-tdep.c (mips_in_frame_stub): Likewise.
572 (mips_dummy_id): Likewise.
573 (is_octeon_bbit_op): Likewise.
574 (micromips_bc1_pc): Likewise.
575 (extended_mips16_next_pc): Likewise.
576 (mips16_next_pc): Likewise.
577 (deal_with_atomic_sequence): Likewise.
578 * moxie-tdep.c (moxie_process_readu): Likewise.
579 * nios2-tdep.c (nios2_get_next_pc): Likewise.
580 * nto-procfs.c (procfs_store_registers): Likewise.
581 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers): Likewise.
582 (ppcfbsd_store_inferior_registers): Likewise.
583 * ppc-linux-nat.c (fetch_vsx_register): Likewise.
584 (fetch_altivec_register): Likewise.
585 (get_spe_registers): Likewise.
586 (fetch_spe_register): Likewise.
587 (fetch_altivec_registers): Likewise.
588 (fetch_all_gp_regs): Likewise.
589 (fetch_all_fp_regs): Likewise.
590 (store_vsx_register): Likewise.
591 (store_altivec_register): Likewise.
592 (set_spe_registers): Likewise.
593 (store_spe_register): Likewise.
594 (store_altivec_registers): Likewise.
595 (store_all_gp_regs): Likewise.
596 (store_all_fp_regs): Likewise.
597 * ppc-linux-tdep.c (ppc_linux_supply_gregset): Likewise.
598 (ppc_linux_collect_gregset): Likewise.
599 (ppc_canonicalize_syscall): Likewise.
600 (ppc_linux_record_signal): Likewise.
601 (ppu2spu_prev_register): Likewise.
602 * ppc-nbsd-nat.c (ppcnbsd_supply_pcb): Likewise.
603 * ppc-obsd-nat.c (ppcobsd_fetch_registers): Likewise.
604 (ppcobsd_store_registers): Likewise.
605 * ppc-ravenscar-thread.c (ppc_ravenscar_generic_fetch_registers):
606 Likewise.
607 (ppc_ravenscar_generic_store_registers): Likewise.
608 * procfs.c (procfs_fetch_registers): Likewise.
609 (procfs_store_registers): Likewise.
610 * ravenscar-thread.c (ravenscar_fetch_registers): Likewise.
611 (ravenscar_store_registers): Likewise.
612 (ravenscar_prepare_to_store): Likewise.
613 * record-btrace.c (record_btrace_fetch_registers): Likewise.
614 * record-full.c (record_full_wait_1): Likewise.
615 (record_full_registers_change): Likewise.
616 (record_full_store_registers): Likewise.
617 (record_full_core_fetch_registers): Likewise.
618 (record_full_save): Likewise.
619 (record_full_goto_insn): Likewise.
620 * regcache.c (regcache_register_size): Likewise.
621 (get_regcache_arch): Remove.
622 (regcache_read_pc): Likewise.
623 * regcache.h (get_regcache_arch): Remove.
624 * remote-sim.c (gdbsim_fetch_register): Likewise.
625 (gdbsim_store_register): Likewise.
626 * remote.c (fetch_register_using_p): Likewise.
627 (send_g_packet): Likewise.
628 (remote_prepare_to_store): Likewise.
629 (store_registers_using_G): Likewise.
630 * reverse.c (save_bookmark_command): Likewise.
631 (goto_bookmark_command): Likewise.
632 * rs6000-aix-tdep.c (branch_dest): Likewise.
633 * rs6000-nat.c (rs6000_ptrace64): Likewise.
634 (fetch_register): Likewise.
635 * rs6000-tdep.c (ppc_supply_reg): Likewise.
636 (ppc_collect_reg): Likewise.
637 (ppc_collect_gregset): Likewise.
638 (ppc_collect_fpregset): Likewise.
639 (ppc_collect_vsxregset): Likewise.
640 (ppc_collect_vrregset): Likewise.
641 (ppc_displaced_step_hw_singlestep): Likewise.
642 (rs6000_pseudo_register_read): Likewise.
643 (rs6000_pseudo_register_write): Likewise.
644 * s390-linux-nat.c (supply_gregset): Likewise.
645 (fill_gregset): Likewise.
646 (s390_linux_fetch_inferior_registers): Likewise.
647 * s390-linux-tdep.c (s390_write_pc): Likewise.
648 (s390_software_single_step): Likewise.
649 (s390_all_but_pc_registers_record): Likewise.
650 (s390_linux_syscall_record): Likewise.
651 * sentinel-frame.c (sentinel_frame_prev_arch): Likewise.
652 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers): Likewise.
653 (shnbsd_store_inferior_registers): Likewise.
654 * sh-tdep.c (sh_extract_return_value_nofpu): Likewise.
655 (sh_extract_return_value_fpu): Likewise.
656 (sh_store_return_value_nofpu): Likewise.
657 (sh_corefile_supply_regset): Likewise.
658 (sh_corefile_collect_regset): Likewise.
659 * sh64-tdep.c (sh64_extract_return_value): Likewise.
660 (sh64_store_return_value): Likewise.
661 * sparc-linux-tdep.c (sparc32_linux_collect_core_fpregset): Likewise.
662 * sparc-nat.c (sparc_fetch_inferior_registers): Likewise.
663 (sparc_store_inferior_registers): Likewise.
664 * sparc-ravenscar-thread.c (register_in_thread_descriptor_p): Likewise.
665 (sparc_ravenscar_prepare_to_store): Likewise.
666 * sparc-tdep.c (sparc32_store_arguments): Likewise.
667 (sparc_analyze_control_transfer): Likewise.
668 (sparc_step_trap): Likewise.
669 (sparc_software_single_step): Likewise.
670 (sparc32_gdbarch_init): Likewise.
671 (sparc_supply_rwindow): Likewise.
672 (sparc_collect_rwindow): Likewise.
673 * sparc64-linux-tdep.c (sparc64_linux_collect_core_fpregset): Likewise.
674 * sparc64-nbsd-nat.c (sparc64nbsd_supply_gregset): Likewise.
675 (sparc64nbsd_collect_gregset): Likewise.
676 (sparc64nbsd_supply_fpregset): Likewise.
677 (sparc64nbsd_collect_fpregset): Likewise.
678 * sparc64-tdep.c (sparc64_store_arguments): Likewise.
679 (sparc64_supply_gregset): Likewise.
680 (sparc64_collect_gregset): Likewise.
681 (sparc64_supply_fpregset): Likewise.
682 (sparc64_collect_fpregset): Likewise.
683 * spu-linux-nat.c (spu_fetch_inferior_registers): Likewise.
684 * spu-tdep.c (spu_unwind_sp): Likewise.
685 (spu2ppu_prev_register): Likewise.
686 (spu_memory_remove_breakpoint): Likewise.
687 * stack.c (return_command): Likewise.
688 * tic6x-tdep.c (tic6x_extract_signed_field): Likewise.
689 * tracefile-tfile.c (tfile_fetch_registers): Likewise.
690 * tracefile.c (trace_save_ctf): Likewise.
691 * windows-nat.c (do_windows_fetch_inferior_registers): Likewise.
692 (do_windows_store_inferior_registers): Likewise.
693 (windows_resume): Likewise.
694 * xtensa-linux-nat.c (fill_gregset): Likewise.
695 (supply_gregset_reg): Likewise.
696 * xtensa-tdep.c (xtensa_register_write_masked): Likewise.
697 (xtensa_register_read_masked): Likewise.
698 (xtensa_supply_gregset): Likewise.
699 (xtensa_extract_return_value): Likewise.
700 (xtensa_store_return_value): Likewise.
701
702 2017-10-25 Ulrich Weigand <uweigand@de.ibm.com>
703
704 * doublest.c (floatformat_from_string): New function.
705 * doublest.h (floatformat_from_string): Add prototype.
706
707 * std-operator.def (OP_DOUBLE, OP_DECFLOAT): Remove, replace by ...
708 (OP_FLOAT): ... this.
709 * expression.h: Do not include "doublest.h".
710 (union exp_element): Replace doubleconst and decfloatconst by
711 new element floatconst.
712 * ada-lang.c (resolve_subexp): Handle OP_FLOAT instead of OP_DOUBLE.
713 (ada_evaluate_subexp): Likewise.
714 * eval.c (evaluate_subexp_standard): Handle OP_FLOAT instead of
715 OP_DOUBLE and OP_DECFLOAT.
716 * expprint.c (print_subexp_standard): Likewise.
717 (dump_subexp_body_standard): Likewise.
718 * breakpoint.c (watchpoint_exp_is_const): Likewise.
719
720 * parse.c: Include "dfp.h".
721 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
722 (write_exp_elt_floatcst): New function.
723 (operator_length_standard): Handle OP_FLOAT instead of OP_DOUBLE
724 and OP_DECFLOAT.
725 (operator_check_standard): Likewise.
726 (parse_float): Do not accept suffix. Take type as input. Return bool.
727 Return target format buffer instead of host DOUBLEST.
728 Use floatformat_from_string and decimal_from_string to parse
729 either binary or decimal floating-point types.
730 (parse_c_float): Remove.
731 * parser-defs.h: Do not include "doublest.h".
732 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
733 (write_exp_elt_floatcst): Add prototype.
734 (parse_float): Update prototype.
735 (parse_c_float): Remove.
736
737 * c-exp.y: Do not include "dfp.h".
738 (typed_val_float): Use byte buffer instead of DOUBLEST.
739 (typed_val_decfloat): Remove.
740 (DECFLOAT): Remove.
741 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
742 (parse_number): Update to new parse_float interface.
743 Parse suffixes and determine type before calling parse_float.
744 Handle decimal and binary FP types the same way.
745
746 * d-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
747 (FLOAT_LITERAL): Use OP_FLOAT and write_exp_elt_floatcst.
748 (parse_number): Update to new parse_float interface.
749 Parse suffixes and determine type before calling parse_float.
750
751 * f-exp.y: Replace dval by typed_val_float.
752 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
753 (parse_number): Use parse_float instead of atof.
754
755 * go-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
756 (parse_go_float): Remove.
757 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
758 (parse_number): Call parse_float instead of parse_go_float.
759 Parse suffixes and determine type before calling parse_float.
760
761 * p-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
762 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
763 (parse_number): Update to new parse_float interface.
764 Parse suffixes and determine type before calling parse_float.
765
766 * m2-exp.y: Replace dval by byte buffer val.
767 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
768 (parse_number): Call parse_float instead of atof.
769
770 * rust-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
771 (lex_number): Call parse_float instead of strtod.
772 (ast_dliteral): Use OP_FLOAT instead of OP_DOUBLE.
773 (convert_ast_to_expression): Handle OP_FLOAT instead of OP_DOUBLE.
774 Use write_exp_elt_floatcst.
775 (unit_testing): Remove static variable.
776 (rust_type): Do not check unit_testing.
777 (rust_lex_tests): Do not set uint_testing. Set up dummy rust_parser.
778
779 * ada-exp.y (type_float, type_double): Remove.
780 (typed_val_float): Use byte buffer instead of DOUBLEST.
781 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
782 * ada-lex.l (processReal): Use parse_float instead of sscanf.
783
784 2017-10-25 Alan Hayward <alan.hayward@arm.com>
785
786 * aarch64-tdep.h (enum aarch64_regnum): Remove.
787 * arch/aarch64.h: New file.
788
789 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
790
791 * dfp.h (decimal_from_string): Use const reference for argument.
792 * dfp.c (decimal_from_string): Likewise.
793
794 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
795
796 * i387-tdep.c (print_i387_value): Use floatformat_to_string.
797 * sh64-tdep.c (sh64_do_fp_register): Likewise.
798 * mips-tdep.c (mips_print_fp_register): Likewise.
799
800 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
801
802 * common/format.h (enum argclass): Replace decfloat_arg by
803 dec32float_arg, dec64float_arg, and dec128float_arg.
804 * common/format.c (parse_format_string): Update to return
805 new decimal float argument classes.
806
807 * printcmd.c (printf_decfloat): Rename to ...
808 (printf_floating): ... this. Add argclass argument, and use it
809 instead of parsing the format string again. Add support for
810 binary floating-point values, using floatformat_to_string.
811 Convert value to the target format if it doesn't already match.
812 (ui_printf): Call printf_floating instead of printf_decfloat,
813 also for double_arg / long_double_arg. Pass argclass.
814
815 * dfp.c (decimal_to_string): Add format string argument.
816 * dfp.h (decimal_to_string): Likewise.
817
818 * doublest.c (floatformat_to_string): Add format string argument.
819 * doublest.h (floatformat_to_string): Likewise.
820
821 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
822
823 * doublest.c (floatformat_precision): New routine.
824 (floatformat_to_string): Likewise.
825 * doublest.c (floatformat_to_string): Add prototype.
826
827 * printcmd.c (print_scalar_formatted): Only call print_floating
828 on floating-point types.
829 * valprint.c: Do not include "floatformat.h".
830 (generic_val_print_decfloat): Remove.
831 (generic_val_print): Call generic_val_print_float for both
832 TYPE_CODE_FLT and TYPE_CODE_DECFLOAT.
833 (print_floating): Use floatformat_to_string. Handle decimal float.
834 (print_decimal_floating): Remove, merge into floatformat_to_string.
835 * value.h (print_decimal_floating): Remove.
836
837 * Makefile.in: Do not build doublest.c with -Wformat-nonliteral.
838
839 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
840
841 * buildsym.c (end_symtab_get_static_block): Use std::stable_sort.
842
843 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
844
845 * memattr.h: Don't include vec.h.
846 (struct mem_attrib): Initialize fields.
847 <unknown>: New static method.
848 (struct mem_region): Add constructors, operator<, initialize
849 fields.
850 * memattr.c: Include algorithm.
851 (default_mem_attrib, unknown_mem_attrib): Remove.
852 (user_mem_region_list): New global.
853 (target_mem_region_list, mem_region_list): Change type to
854 std::vector<mem_region>.
855 (mem_use_target): Now a function.
856 (target_mem_regions_valid): Change type to bool.
857 (mem_region_lessthan, mem_region_cmp, mem_region_init): Remove.
858 (require_user_regions): Adjust.
859 (require_target_regions): Adjust.
860 (create_mem_region): Adjust.
861 (lookup_mem_region): Adjust.
862 (invalidate_target_mem_regions): Adjust.
863 (mem_clear): Rename to...
864 (user_mem_clear): ... this, and adjust.
865 (mem_command): Adjust.
866 (info_mem_command): Adjust.
867 (mem_enable, enable_mem_command, mem_disable,
868 disable_mem_command): Adjust.
869 (mem_delete): Adjust.
870 (delete_mem_command): Adjust.
871 * memory-map.h (parse_memory_map): Return an std::vector.
872 * memory-map.c (parse_memory_map): Likewise.
873 (struct memory_map_parsing_data): Add constructor.
874 <memory_map>: Point to std::vector.
875 (memory_map_start_memory): Adjust.
876 (memory_map_end_memory): Adjust.
877 (memory_map_end_property): Adjust.
878 (clear_result): Remove.
879 * remote.c (remote_memory_map): Return an std::vector.
880 * target-debug.h (target_debug_print_VEC_mem_region_s__p):
881 Remove.
882 (target_debug_print_mem_region_vector): New.
883 * target-delegates.c: Regenerate.
884 * target.h (mem_region_vector): New typedef.
885 (to_memory_map): Return mem_region_vector.
886 (target_memory_map): Return an std::vector.
887 * target.c (target_memory_map): Return an std::vector.
888 (flash_erase_command): Adjust.
889
890 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
891
892 * memory-map.c (struct memory_map_parsing_data) <property_name>:
893 Change type to std::string.
894 (memory_map_start_property): Adjust.
895 (memory_map_end_property): Adjust.
896
897 2017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
898
899 * infrun.h: Include common/byte-vector.h.
900 (struct displaced_step_closure): New struct.
901 (struct buf_displaced_step_closure): New struct.
902 * infrun.c (displaced_step_closure::~displaced_step_closure):
903 Provide default implementation.
904 (displaced_step_clear): Deallocate step closure with delete.
905 * aarch64-tdep.c (displaced_step_closure): Rename to ...
906 (aarch64_displaced_step_closure): ... this, extend
907 displaced_step_closure.
908 (aarch64_displaced_step_data) <dsc>: Change type to
909 aarch64_displaced_step_closure.
910 (aarch64_displaced_step_copy_insn): Adjust to type change, use
911 unique_ptr.
912 (aarch64_displaced_step_fixup): Add cast for displaced step
913 closure.
914 * amd64-tdep.c (displaced_step_closure): Rename to ...
915 (amd64_displaced_step_closure): ... this, extend
916 displaced_step_closure.
917 <insn_buf>: Change type to std::vector<gdb_byte>.
918 <max_len>: Remove.
919 (fixup_riprel): Change type of DSC parameter, adjust to type
920 change of insn_buf.
921 (fixup_displaced_copy): Change type of DSC parameter.
922 (amd64_displaced_step_copy_insn): Instantiate
923 amd64_displaced_step_closure.
924 (amd64_displaced_step_fixup): Add cast for closure type, adjust
925 to type change of insn_buf.
926 * arm-linux-tdep.c (arm_linux_cleanup_svc): Change type of
927 parameter DSC.
928 (arm_linux_copy_svc): Likewise.
929 (cleanup_kernel_helper_return): Likewise.
930 (arm_catch_kernel_helper_return): Likewise.
931 (arm_linux_displaced_step_copy_insn): Instantiate
932 arm_displaced_step_closure.
933 * arm-tdep.c (arm_pc_is_thumb): Add cast for closure.
934 (displaced_read_reg): Change type of parameter DSC.
935 (branch_write_pc): Likewise.
936 (load_write_pc): Likewise.
937 (alu_write_pc): Likewise.
938 (displaced_write_reg): Likewise.
939 (arm_copy_unmodified): Likewise.
940 (thumb_copy_unmodified_32bit): Likewise.
941 (thumb_copy_unmodified_16bit): Likewise.
942 (cleanup_preload): Likewise.
943 (install_preload): Likewise.
944 (arm_copy_preload): Likewise.
945 (thumb2_copy_preload): Likewise.
946 (install_preload_reg): Likewise.
947 (arm_copy_preload_reg): Likewise.
948 (cleanup_copro_load_store): Likewise.
949 (install_copro_load_store): Likewise.
950 (arm_copy_copro_load_store) Likewise.
951 (thumb2_copy_copro_load_store): Likewise.
952 (cleanup_branch): Likewise.
953 (install_b_bl_blx): Likewise.
954 (arm_copy_b_bl_blx): Likewise.
955 (thumb2_copy_b_bl_blx): Likewise.
956 (thumb_copy_b): Likewise.
957 (install_bx_blx_reg): Likewise.
958 (arm_copy_bx_blx_reg): Likewise.
959 (thumb_copy_bx_blx_reg): Likewise.
960 (cleanup_alu_imm): Likewise.
961 (arm_copy_alu_imm): Likewise.
962 (thumb2_copy_alu_imm): Likewise.
963 (cleanup_alu_reg): Likewise.
964 (install_alu_reg): Likewise.
965 (arm_copy_alu_reg): Likewise.
966 (thumb_copy_alu_reg): Likewise.
967 (cleanup_alu_shifted_reg): Likewise.
968 (install_alu_shifted_reg): Likewise.
969 (arm_copy_alu_shifted_reg): Likewise.
970 (cleanup_load): Likewise.
971 (cleanup_store): Likewise.
972 (arm_copy_extra_ld_st): Likewise.
973 (install_load_store): Likewise.
974 (thumb2_copy_load_literal): Likewise.
975 (thumb2_copy_load_reg_imm): Likewise.
976 (arm_copy_ldr_str_ldrb_strb): Likewise.
977 (cleanup_block_load_all): Likewise.
978 (cleanup_block_store_pc): Likewise.
979 (cleanup_block_load_pc): Likewise.
980 (arm_copy_block_xfer): Likewise.
981 (thumb2_copy_block_xfer): Likewise.
982 (cleanup_svc): Likewise.
983 (install_svc): Likewise.
984 (arm_copy_svc): Likewise.
985 (thumb_copy_svc): Likewise.
986 (arm_copy_undef): Likewise.
987 (thumb_32bit_copy_undef): Likewise.
988 (arm_copy_unpred): Likewise.
989 (arm_decode_misc_memhint_neon): Likewise.
990 (arm_decode_unconditional): Likewise.
991 (arm_decode_miscellaneous): Likewise.
992 (arm_decode_dp_misc): Likewise.
993 (arm_decode_ld_st_word_ubyte): Likewise.
994 (arm_decode_media): Likewise.
995 (arm_decode_b_bl_ldmstm): Likewise.
996 (arm_decode_ext_reg_ld_st): Likewise.
997 (thumb2_decode_dp_shift_reg): Likewise.
998 (thumb2_decode_ext_reg_ld_st): Likewise.
999 (arm_decode_svc_copro): Likewise.
1000 (thumb2_decode_svc_copro): Likewise.
1001 (install_pc_relative): Likewise.
1002 (thumb_copy_pc_relative_16bit): Likewise.
1003 (thumb_decode_pc_relative_16bit): Likewise.
1004 (thumb_copy_pc_relative_32bit): Likewise.
1005 (thumb_copy_16bit_ldr_literal): Likewise.
1006 (thumb_copy_cbnz_cbz): Likewise.
1007 (thumb2_copy_table_branch): Likewise.
1008 (cleanup_pop_pc_16bit_all): Likewise.
1009 (thumb_copy_pop_pc_16bit): Likewise.
1010 (thumb_process_displaced_16bit_insn): Likewise.
1011 (decode_thumb_32bit_ld_mem_hints): Likewise.
1012 (thumb_process_displaced_32bit_insn): Likewise.
1013 (thumb_process_displaced_insn): Likewise.
1014 (arm_process_displaced_insn): Likewise.
1015 (arm_displaced_init_closure): Likewise.
1016 (arm_displaced_step_fixup): Add cast for closure.
1017 * arm-tdep.h: Include infrun.h.
1018 (displaced_step_closure): Rename to ...
1019 (arm_displaced_step_closure): ... this, extend
1020 displaced_step_closure.
1021 <u::svc::copy_svc_os>: Change type of parameter DSC.
1022 <cleanup>: Likewise.
1023 (arm_process_displaced_insn): Likewise.
1024 (arm_displaced_init_closure): Likewise.
1025 (displaced_read_reg): Likewise.
1026 (displaced_write_reg): Likewise.
1027 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
1028 Adjust.
1029 * i386-tdep.h: Include infrun.h.
1030 (i386_displaced_step_closure): New typedef.
1031 * i386-tdep.c (i386_displaced_step_copy_insn): Use
1032 i386_displaced_step_closure.
1033 (i386_displaced_step_fixup): Adjust.
1034 * rs6000-tdep.c (ppc_displaced_step_closure): New typedef.
1035 (ppc_displaced_step_copy_insn): Use ppc_displaced_step_closure
1036 and unique_ptr.
1037 (ppc_displaced_step_fixup): Adjust.
1038 * s390-linux-tdep.c (s390_displaced_step_closure): New typedef.
1039 (s390_displaced_step_copy_insn): Use s390_displaced_step_closure
1040 and unique_ptr.
1041 (s390_displaced_step_fixup): Adjust.
1042
1043 2017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
1044
1045 * interps.h (interp_resume, interp_suspend, interp_set_temp):
1046 Remove declarations.
1047
1048 2017-10-20 Tom Tromey <tom@tromey.com>
1049
1050 * gdb_bfd.c (struct gdb_bfd_data) <included_bfds>: Now a
1051 std::vector.
1052 (gdb_bfd_record_inclusion): Update.
1053 (bfdp): Remove typedef.
1054
1055 2017-10-20 Tom Tromey <tom@tromey.com>
1056
1057 * gdb_bfd.c (gdb_bfd_ref): Use new.
1058 (struct gdb_bfd_data): Add constructor, destructor, and member
1059 initializers.
1060 (gdb_bfd_unref): Use delete.
1061
1062 2017-10-20 Tom Tromey <tom@tromey.com>
1063
1064 * exec.c (exec_file_attach): Use new_bfd_ref.
1065 * symfile-mem.c (symbol_file_add_from_memory): Use new_bfd_ref.
1066 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
1067 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_fdopenr): Use
1068 new_bfd_ref.
1069 * gdb_bfd.h (new_bfd_ref): New function.
1070
1071 2017-10-20 Pedro Alves <palves@redhat.com>
1072
1073 * main.c (captured_command_loop): Add attribute noinline.
1074
1075 2017-10-19 Simon Marchi <simon.marchi@ericsson.com>
1076
1077 * interps.c (struct interp_factory): Add constructor.
1078 (interp_factory_p): Remove typedef.
1079 (DEF_VEC_P(interp_factory_p)): Remove.
1080 (interpreter_factories): Change type to std::vector.
1081 (interp_factory_register): Adjust.
1082 (interp_lookup): Adjust.
1083 (interpreter_completer): Adjust.
1084
1085 2017-10-19 Tom Tromey <tom@tromey.com>
1086
1087 * break-catch-syscall.c (catch_syscall_completer): Use
1088 std::string, gdb::unique_xmalloc_ptr.
1089
1090 2017-10-19 Tom Tromey <tom@tromey.com>
1091
1092 * infcall.c (call_function_by_hand_dummy): Use std::string.
1093
1094 2017-10-19 Tom Tromey <tom@tromey.com>
1095
1096 * mi/mi-main.c (mi_cmd_execute): Update.
1097 * top.h (prepare_execute_command): Return scoped_value_mark.
1098 * value.h (class scoped_value_mark): Use DISABLE_COPY_AND_ASSIGN.
1099 Add move constructor.
1100 * top.c (prepare_execute_command): Return scoped_value_mark.
1101 (execute_command): Update.
1102
1103 2017-10-19 Pedro Alves <palves@redhat.com>
1104
1105 * xml-support.c (xml_fetch_content_from_file): Check fread's
1106 return.
1107
1108 2017-10-19 Pedro Alves <palves@redhat.com>
1109
1110 * ser-base.c (ser_base_read_error_fd): Delete the file handler if
1111 async.
1112 (handle_error_fd): New function.
1113 (ser_base_async): Add/delete an event loop file handler for
1114 error_fd.
1115
1116 2017-10-19 Pedro Alves <palves@redhat.com>
1117
1118 * xml-support.c (xml_fetch_content_from_file): Don't read in
1119 chunks. Instead use fseek to determine the file's size, and read
1120 it in one go.
1121
1122 2017-11-18 Keith Seitz <keiths@redhat.com>
1123
1124 * c-exp.y (oper): Canonicalize conversion operators of user-defined
1125 types.
1126 Add whitespace to front of type name.
1127
1128 2017-10-18 Keith Seitz <keiths@redhat.com>
1129
1130 * dwarf2read.c (dwarf2_add_typedef): Issue a complaint on unhandled
1131 DW_AT_accessibility.
1132
1133 2017-10-18 Yao Qi <yao.qi@linaro.org>
1134
1135 * features/tic6x-c62x-linux.c: Remove.
1136
1137 2017-10-17 Tom Tromey <tom@tromey.com>
1138
1139 * disasm.c (do_mixed_source_and_assembly_deprecated): Use
1140 gdb::optional, ui_out_emit_list, ui_out_emit_tuple.
1141 (do_mixed_source_and_assembly): Likewise.
1142
1143 2017-10-17 Tom Tromey <tom@tromey.com>
1144
1145 * regcache.c (regcache::xfer_part): Remove assertion.
1146
1147 2017-10-17 Pedro Alves <palves@redhat.com>
1148
1149 * xml-support.c (xml_fetch_content_from_file): Call
1150 unique_ptr::release() instead unique_ptr::get() when passing
1151 through xrealloc.
1152
1153 2017-10-17 Yao Qi <yao.qi@linaro.org>
1154
1155 * regcache.c (regcache::xfer_part): Remove parameters read and
1156 write, add parameter is_raw. All callers are updated.
1157
1158 2017-10-16 Keith Seitz <keiths@redhat.com>
1159
1160 * c-typeprint.c (enum access_specifier): Moved here from
1161 c_type_print_base.
1162 (output_access_specifier): New function.
1163 (c_type_print_base): Consider typedefs when assessing
1164 whether access labels are needed.
1165 Use output_access_specifier as needed.
1166 Output access specifier for typedefs, if needed.
1167 * dwarf2read.c (dwarf2_add_typedef): Record DW_AT_accessibility.
1168 * gdbtypes.h (struct typedef_field) <is_protected, is_private>: New
1169 fields.
1170 (TYPE_TYPEDEF_FIELD_PROTECTED, TYPE_TYPEDEF_FIELD_PRIVATE): New
1171 accessor macros.
1172
1173 2017-10-16 Tom Tromey <tom@tromey.com>
1174
1175 * linux-tdep.c (linux_info_proc, linux_find_memory_regions_full)
1176 (linux_fill_prpsinfo, linux_vsyscall_range_raw): Update.
1177 * target.c (target_fileio_read_stralloc): Update.
1178 * sparc64-tdep.c (adi_is_addr_mapped): Update.
1179 * target.h (target_fileio_read_stralloc): Return
1180 unique_xmalloc_ptr.
1181
1182 2017-10-16 Tom Tromey <tom@tromey.com>
1183
1184 * xml-syscall.c (xml_init_syscalls_info): Update.
1185 * xml-support.c (xinclude_start_include): Update.
1186 (xml_fetch_content_from_file): Return unique_xmalloc_ptr.
1187 * xml-support.h (xml_fetch_another): Return unique_xmalloc_ptr.
1188 (xml_fetch_content_from_file): Likewise.
1189 * osdata.c (get_osdata): Update.
1190 * target.h (target_read_stralloc, target_get_osdata): Return
1191 unique_xmalloc_ptr.
1192 * solib-aix.c (solib_aix_get_library_list): Update.
1193 * solib-target.c (solib_target_current_sos): Update.
1194 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Update.
1195 * xml-tdesc.c (fetch_available_features_from_target): Update.
1196 (target_fetch_description_xml): Update.
1197 (file_read_description_xml): Update.
1198 * remote.c (remote_get_threads_with_qxfer, remote_memory_map)
1199 (remote_traceframe_info, btrace_read_config, remote_read_btrace)
1200 (remote_pid_to_exec_file): Update.
1201 * target.c (target_read_stralloc): Return unique_xmalloc_ptr.
1202 (target_get_osdata): Likewise.
1203
1204 2017-10-16 Tom Tromey <tom@tromey.com>
1205
1206 * remote.c (remote_register_number_and_offset): Use std::vector.
1207 (remote_set_syscall_catchpoint): Use gdb::unique_xmalloc_ptr.
1208 (putpkt_binary): Use gdb::def_vector.
1209 (compare_sections_command): Use gdb::byte_vector.
1210
1211 2017-10-16 Tom Tromey <tom@tromey.com>
1212
1213 * ppc-linux-nat.c (hwdebug_insert_point): Use
1214 gdb::unique_xmalloc_ptr, XDUP.
1215
1216 2017-10-16 Tom Tromey <tom@tromey.com>
1217
1218 * probe.c (parse_probes): Use std::string.
1219 (info_probes_for_ops, enable_probes_command)
1220 (disable_probes_command): Remove cleanups.
1221
1222 2017-10-16 Tom Tromey <tom@tromey.com>
1223
1224 * buildsym.c (block_compar): Remove.
1225 (end_symtab_get_static_block): Use std::vector.
1226
1227 2017-10-16 Simon Marchi <simon.marchi@ericsson.com>
1228
1229 * memrange.h (struct mem_range): Define operator< and operator==.
1230 (mem_range_s): Remove.
1231 (DEF_VEC_O (mem_range_s)): Remove.
1232 (normalize_mem_ranges): Change parameter type to std::vector.
1233 * memrange.c (compare_mem_ranges): Remove.
1234 (normalize_mem_ranges): Change parameter type to std::vector,
1235 adjust to vector change.
1236 * exec.c (section_table_available_memory): Return vector, remove
1237 parameter.
1238 (section_table_read_available_memory): Adjust to std::vector
1239 change.
1240 * remote.c (remote_read_bytes): Adjust to std::vector
1241 change.
1242 * tracepoint.h (traceframe_available_memory): Change parameter
1243 type to std::vector.
1244 * tracepoint.c (traceframe_available_memory): Change parameter
1245 type to std::vector, adjust.
1246 * gdb/mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to
1247 std::vector change.
1248 * gdb/Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1249 unittests/memrange-selftests.c.
1250 (SUBDIR_UNITTESTS_OBS): Add memrange-selftests.o.
1251 * gdb/unittests/memrange-selftests.c: New file.
1252
1253 2017-10-16 Pedro Alves <palves@redhat.com>
1254
1255 * elfread.c (probe_key_free): Rename range-for variable.
1256 * probe.c (parse_probes_in_pspace, find_probes_in_objfile)
1257 (find_probe_by_pc, collect_probes): Rename range-for variable.
1258
1259 2017-10-16 Yao Qi <yao.qi@linaro.org>
1260
1261 * features/Makefile (XMLTOC): Remove tic6x-*.xml.
1262 * features/tic6x-c62x.c: Remove.
1263 * features/tic6x-c64x-linux.c: Remove.
1264 * features/tic6x-c64x.c: Remove.
1265 * features/tic6x-c64xp-linux.c: Remove.
1266 * features/tic6x-c64xp.c: Remove.
1267 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Don't call
1268 initialize_tdesc_tic6x_*_linux functions.
1269 * tic6x-tdep.c (_initialize_tic6x_tdep): Don't call
1270 initialize_tdesc_tic6x_* functions.
1271
1272 2017-10-16 Yao Qi <yao.qi@linaro.org>
1273
1274 * features/Makefile (WHICH): Remove tic6x-c64xp, tic6x-c64x
1275 tic6x-c62x.
1276 * regformats/tic6x-c62x.dat: Remove.
1277 * regformats/tic6x-c64x.dat: Remove.
1278 * regformats/tic6x-c64xp.dat: Remove.
1279
1280 2017-10-15 Simon Marchi <simon.marchi@ericsson.com>
1281
1282 * tracepoint.c (parse_traceframe_info): Return a unique_ptr
1283 (the !HAVE_LIBEXPAT version).
1284
1285 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
1286
1287 * nat/linux-osdata.c (struct pid_pgid_entry) <operator<>: Make
1288 const.
1289
1290 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1291
1292 * target.h: Include tracepoint.h.
1293 (enum trace_find_type): Move to tracepoint.h.
1294 (struct target_ops) <to_traceframe_info>: Return a unique ptr.
1295 * tracepoint.h: Don't include target.h
1296 (enum trace_find_type): Move from target.h.
1297 (parse_traceframe_info): Return a unique ptr.
1298 * tracepoint.c (current_traceframe_info): Change type to unique
1299 ptr.
1300 (free_traceframe_info): Remove.
1301 (clear_traceframe_info): Don't manually free
1302 current_traceframe_info.
1303 (free_result): Remove.
1304 (parse_traceframe_info): Return a unique ptr.
1305 (get_traceframe_info): Adjust to unique ptr.
1306 * ctf.c (ctf_traceframe_info): Return a unique ptr.
1307 * remote.c (remote_traceframe_info): Return a unique ptr.
1308 * tracefile-tfile.c (tfile_traceframe_info): Return a unique
1309 ptr.
1310 * target-debug.h (target_debug_print_traceframe_info_up): New
1311 macro.
1312 * target-delegates.c: Regenerate.
1313
1314 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1315
1316 * memrange.h (struct mem_range): Add constructors.
1317 * tracepoint.h (struct traceframe_info) <memory>: Change type to
1318 std::vector<mem_range>.
1319 * tracepoint.c (free_traceframe_info): Don't manually free
1320 vector.
1321 (traceframe_info_start_memory): Adjust to vector change.
1322 (traceframe_available_memory): Likewise.
1323 * tracefile-tfile.c (build_traceframe_info): Likewise.
1324 * ctf.c (ctf_traceframe_info): Likewise.
1325
1326 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1327
1328 * tracepoint.h (struct traceframe_info) <tvars>: Change type to
1329 std::vector<int>.
1330 * tracepoint.c (free_traceframe_info): Deallocate with delete.
1331 (traceframe_info_start_tvar): Adjust to vector change.
1332 (parse_traceframe_info): Allocate with new.
1333 * ctf.c (ctf_traceframe_info): Allocate with new, adjust to
1334 vector change.
1335 * tracefile-tfile.c (build_traceframe_info): Adjust to vector
1336 change.
1337 tfile_traceframe_info): Allocate with new.
1338 * mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to vector
1339 change.
1340
1341 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1342
1343 * tracepoint.c (traceframe_info): Rename to...
1344 (current_traceframe_info): ...this.
1345 (clear_traceframe_info): Adjust.
1346 (get_traceframe_info): Adjust.
1347
1348 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
1349
1350 * nat/linux-osdata.c: Include algorithm.
1351 (compare_processes): Remove.
1352 (struct pid_pgid_entry): New struct.
1353 (linux_xfer_osdata_processgroups): Use std::vector instead of
1354 XNEWVEC.
1355
1356 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
1357
1358 * objfiles.h: Don't include symfile.h.
1359 (struct partial_symbol): Remove forward-declaration.
1360 (struct objfile) <global_psymbols, static_psymbols>: Change type
1361 to std::vector<partial_symbol *>.
1362 * objfiles.c (objfile::objfile): Don't memset those fields.
1363 (objfile::~objfile): Don't free those fields.
1364 * psympriv.h (struct psymbol_allocation_list): Remove
1365 forward-declaration.
1366 (add_psymbol_to_list): Change psymbol_allocation_list parameter
1367 to std::vector.
1368 (start_psymtab_common): Change parameters to std::vector.
1369 * psymtab.c: Include algorithm.
1370 (require_partial_symbols): Call shrink_to_fit.
1371 (find_pc_sect_psymbol): Adjust to vector change.
1372 (match_partial_symbol): Likewise.
1373 (lookup_partial_symbol): Likewise.
1374 (psym_relocate): Likewise.
1375 (dump_psymtab): Likewise.
1376 (recursively_search_psymtabs): Likewise.
1377 (compare_psymbols): Remove.
1378 (sort_pst_symbols): Adjust to vector change.
1379 (start_psymtab_common): Likewise.
1380 (end_psymtab_common): Likewise.
1381 (psymbol_bcache_full): De-constify return value.
1382 (add_psymbol_to_bcache): Likewise.
1383 (extend_psymbol_list): Remove.
1384 (append_psymbol_to_list): Adjust to vector change.
1385 (add_psymbol_to_list): Likewise.
1386 (init_psymbol_list): Likewise.
1387 (maintenance_info_psymtabs): Likewise.
1388 (maintenance_check_psymtabs): Likewise.
1389 * symfile.h (struct psymbol_allocation_list): Remove.
1390 * symfile.c (reread_symbols): Adjust to vector change.
1391 * dbxread.c (start_psymtab): Change type of parameters.
1392 (dbx_symfile_read): Adjust to vector change.
1393 (read_dbx_symtab): Likewise.
1394 (start_psymtab): Change type of parameters.
1395 * dwarf2read.c (dwarf2_build_psymtabs): Adjust to vector change.
1396 (create_partial_symtab): Likewise.
1397 (add_partial_symbol): Likewise.
1398 (write_one_signatured_type): Likewise.
1399 (recursively_write_psymbols): Likewise.
1400 * mdebugread.c (parse_partial_symbols): Likewise.
1401 * xcoffread.c (xcoff_start_psymtab): Change type of parameters.
1402 (scan_xcoff_symtab): Adjust to vector change.
1403 (xcoff_initial_scan): Likewise.
1404
1405 2017-10-13 Simon Marchi <simon.marchi@ericsson.com>
1406
1407 * ada-typeprint.c (print_dynamic_range_bound): Use std::string.
1408
1409 2017-10-13 Yao Qi <yao.qi@linaro.org>
1410
1411 * features/Makefile: Remove tic6x-*-expedite, add tic6x-expedite.
1412 Remove s390x-*-expedite, add s390x-expedite.
1413
1414 2017-10-13 Yao Qi <yao.qi@linaro.org>
1415
1416 * features/s390-gs-linux64.c: Regenerated.
1417 * features/s390x-gs-linux64.c: Regenerated.
1418
1419 2017-10-13 Tom Tromey <tom@tromey.com>
1420
1421 * compile/compile-object-run.c (do_module_cleanup): Use delete.
1422 * solib.c (update_solib_list, reload_shared_libraries_1): Use
1423 delete.
1424 * symfile.c (symbol_file_add_with_addrs): Use new.
1425 (symbol_file_add_separate): Update comment.
1426 (syms_from_objfile_1, remove_symbol_file_command): Use delete.
1427 * jit.c (jit_object_close_impl): Use new.
1428 (jit_unregister_code): Use delete.
1429 * objfiles.c (objfile::objfile): Rename from allocate_objfile.
1430 (~objfile): Rename from free_objfile.
1431 (free_objfile_separate_debug, do_free_objfile_cleanup)
1432 (free_all_objfiles, objfile_purge_solibs): Use delete.
1433 * objfiles.h (struct objfile): Add constructor and destructor.
1434 Use DISABLE_COPY_AND_ASSIGN. Add initializers to data members.
1435 (allocate_objfile, free_objfile): Don't declare.
1436 (struct objstats): Add initializers.
1437
1438 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
1439
1440 * arch-utils.h (simple_displaced_step_copy_insn): Remove.
1441 * arch-utils.c (simple_displaced_step_copy_insn): Remove.
1442 * gdbarch.sh (displaced_step_copy_insn): Adjust comment.
1443 * gdbarch.h: Regenerate.
1444 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
1445 Adjust comment.
1446 * i386-tdep.c (i386_displaced_step_copy_insn): Adjust comment.
1447 (i386_displaced_step_fixup): Adjust comment.
1448 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Adjust comment.
1449
1450 2017-10-12 Tom Tromey <tom@tromey.com>
1451
1452 * prologue-value.h (pv_area::store_would_trash): Return bool.
1453 (pv_area::find_reg): Likewise.
1454 * prologue-value.c (pv_area::store_would_trash): Return bool.
1455 (pv_area::find_reg): Likewise.
1456
1457 2017-10-12 Tom Tromey <tom@tromey.com>
1458
1459 * s390-linux-tdep.c (s390_store, s390_load)
1460 (s390_check_for_saved, s390_analyze_prologue): Update.
1461 * rx-tdep.c (check_for_saved, rx_analyze_prologue): Update.
1462 * rl78-tdep.c (rl78_analyze_prologue, check_for_saved): Update.
1463 * prologue-value.h (class pv_area): Move from prologue-value.c.
1464 Change names of members. Add constructor, destructor, member
1465 functions.
1466 (make_pv_area, free_pv_area, make_cleanup_free_pv_area)
1467 (pv_area_store, pv_area_fetch, pv_area_store_would_trash)
1468 (pv_area_fetch, pv_area_scan): Don't declare.
1469 * prologue-value.c (struct pv_area::area_entry): Now member of
1470 pv_area.
1471 (struct pv_area): Move to prologue-value.h.
1472 (pv_area::pv_area): Rename from make_pv_area.
1473 (pv_area::~pv_area): Rename from free_pv_area.
1474 (do_free_pv_area_cleanup, make_cleanup_free_pv_area): Remove.
1475 (clear_entries, find_entry, overlaps, store_would_trash, store)
1476 (fetch, find_reg, scan): Now member of pv_area.
1477 Remove "area" argument. Update.
1478 * msp430-tdep.c (check_for_saved, msp430_analyze_prologue):
1479 Update.
1480 * mn10300-tdep.c (push_reg, check_for_saved)
1481 (mn10300_analyze_prologue): Update.
1482 * mep-tdep.c (is_arg_spill, check_for_saved)
1483 (mep_analyze_prologue): Update.
1484 * m32c-tdep.c (m32c_pv_push, m32c_srcdest_fetch)
1485 (m32c_srcdest_store, m32c_pv_enter, m32c_is_arg_spill)
1486 (m32c_is_struct_return, m32c_analyze_prologue): Update.
1487 * arm-tdep.c (thumb_analyze_prologue, arm_analyze_prologue):
1488 Update.
1489 * arc-tdep.c (arc_is_in_prologue, arc_analyze_prologue): Update.
1490 * aarch64-tdep.c (aarch64_analyze_prologue): Update.
1491
1492 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
1493
1494 * linux-nat.h (linux_nat_set_delete_thread): New declaration.
1495 * linux-nat.c (linux_nat_delete_thread): New variable.
1496 (lwp_free): Invoke linux_nat_delete_thread if set.
1497 (linux_nat_set_delete_thread): New function.
1498 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Assign
1499 thread delete callback.
1500 * arm-linux-nat.c (arm_linux_delete_thread): New function.
1501 (_initialize_arm_linux_nat): Assign thread delete callback.
1502 * s390-linux-nat.c (s390_delete_thread): New function.
1503 (_initialize_s390_nat): Assign thread delete callback.
1504 * x86-linux-nat.c (x86_linux_add_target): Likewise.
1505 * nat/aarch64-linux.c (aarch64_linux_delete_thread): New
1506 function.
1507 * nat/aarch64-linux.h (aarch64_linux_delete_thread): New
1508 declaration.
1509 * nat/x86-linux.c (x86_linux_delete_thread): New function.
1510 * nat/x86-linux.h (x86_linux_delete_thread): New declaration.
1511
1512 2017-10-09 Tom Tromey <tom@tromey.com>
1513
1514 * tui/tui-win.c (tui_set_win_height, parse_scrolling_args): Use
1515 std::string.
1516 * tui/tui-layout.c (enum tui_status): Use std::string.
1517
1518 2017-10-11 Tom Tromey <tom@tromey.com>
1519
1520 * gdbthread.h (thread_command): Constify.
1521 * inferior.h (detach_command): Constify.
1522 * top.h (set_history, show_history): Constify.
1523 * arm-tdep.c (set_arm_command, show_arm_command): Constify.
1524 * serial.c (serial_set_cmd, serial_show_cmd): Constify.
1525 * bsd-kvm.c (bsd_kvm_cmd): Constify.
1526 * printcmd.c (set_command): Constify.
1527 (non_const_set_command): New function.
1528 * dcache.c (set_dcache_command, show_dcache_command): Constify.
1529 * breakpoint.c (enable_command, disable_command, delete_command)
1530 (catch_command, tcatch_command, set_breakpoint_cmd)
1531 (show_breakpoint_cmd): Constify.
1532 * macrocmd.c (macro_command): Constify.
1533 * infcmd.c (unset_command, kill_command, detach_command)
1534 (info_proc_cmd): Constify.
1535 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Constify.
1536 * auto-load.c (show_auto_load_cmd, set_auto_load_cmd)
1537 (info_auto_load_cmd): Constify.
1538 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
1539 (unset_tdesc_cmd): Constify.
1540 * ada-lang.c (set_ada_command, show_ada_command)
1541 (maint_set_ada_cmd, maint_show_ada_cmd): Constify.
1542 * guile/guile.c (set_guile_command, show_guile_command)
1543 (info_guile_command): Constify.
1544 * tui/tui-win.c (tui_command, set_tui_cmd, show_tui_cmd):
1545 Constify.
1546 * skip.c (skip_command): Constify.
1547 * compile/compile.c (_initialize_compile): Constify.
1548 * dwarf2read.c (set_dwarf_cmd, show_dwarf_cmd): Constify.
1549 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
1550 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
1551 (maint_btrace_pt_show_cmd): Constify.
1552 * remote.c (set_remote_cmd, show_remote_cmd, remote_command):
1553 Constify.
1554 * python/python.c (user_show_python, user_set_python): Constify.
1555 * mips-tdep.c (set_mips_command, show_mips_command)
1556 (set_mipsfpu_command): Constify.
1557 * record-btrace.c (cmd_record_btrace_start)
1558 (cmd_set_record_btrace, cmd_show_record_btrace)
1559 (cmd_set_record_btrace_bts, cmd_show_record_btrace_bts)
1560 (cmd_set_record_btrace_pt, cmd_show_record_btrace_pt): Constify.
1561 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command):
1562 Constify.
1563 * symfile.c (overlay_command): Constify.
1564 * spu-tdep.c (set_spu_command, show_spu_command): Constify.
1565 * cli/cli-logging.c (set_logging_command, show_logging_command):
1566 Constify.
1567 * cli/cli-dump.c (dump_command, append_command)
1568 (srec_dump_command, ihex_dump_command, verilog_dump_command)
1569 (tekhex_dump_command, binary_dump_command)
1570 (binary_append_command): Constify.
1571 * cli/cli-decode.c (struct cmd_list_element): Change type of
1572 "fun".
1573 * cli/cli-cmds.c (info_command, show_command, set_debug)
1574 (show_debug): Constify.
1575 (show_command): Add non-const overload.
1576 * top.c (set_history, show_history): Constify.
1577 * sh-tdep.c (set_sh_command, show_sh_command): Constify.
1578 * command.h (add_prefix_cmd): Accept a cmd_const_cfunc_ftype.
1579 * target.c (target_command): Constify.
1580 * sparc64-tdep.c (info_adi_command): Constify.
1581 * record-full.c (cmd_record_full_start): Constify.
1582 (set_record_full_command): Constify. Fix typo.
1583 (show_record_full_command): Constify.
1584 * thread.c (thread_command, thread_apply_command): Constify.
1585 * memattr.c (dummy_cmd): Constify.
1586 * value.c (function_command): Constify.
1587 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Constify.
1588 * probe.c (info_probes_command): Constify.
1589 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Constify.
1590 * gnu-nat.c (set_task_cmd, show_task_cmd, set_thread_cmd)
1591 (show_thread_cmd, set_thread_default_cmd)
1592 (show_thread_default_cmd): Constify.
1593 (check_empty): Constify.
1594 * tracepoint.c (tfind_command): Constify.
1595 * cp-support.c (maint_cplus_command): Constify.
1596 * windows-tdep.c (info_w32_command): Constify.
1597 * record.c (cmd_record_start, set_record_command)
1598 (show_record_command, info_record_command, cmd_record_goto):
1599 Constify.
1600 * ravenscar-thread.c (set_ravenscar_command)
1601 (show_ravenscar_command): Constify.
1602 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
1603 Constify.
1604 (add_internal_problem_command): Remove casts.
1605 * arc-tdep.c (maintenance_print_arc_command): Constify.
1606 * valprint.c (set_print, show_print, set_print_raw)
1607 (show_print_raw): Constify.
1608 * maint.c (maintenance_command, maintenance_info_command)
1609 (maintenance_print_command, maintenance_set_cmd)
1610 (maintenance_show_cmd, set_per_command_cmd)
1611 (show_per_command_cmd, maintenance_check_command): Constify.
1612 * language.c (set_check, show_check): Constify.
1613 * typeprint.c (show_print_type, set_print_type): Constify.
1614 * go32-nat.c (go32_info_dos_command): Constify.
1615
1616 2017-10-11 Tom Tromey <tom@tromey.com>
1617
1618 * breakpoint.c (prepare_re_set_context): Remove.
1619 (breakpoint_re_set_one): Update. Don't use cleanups.
1620 (breakpoint_re_set): Use scoped_restore, std::string, and
1621 scoped_restore_current_language.
1622
1623 2017-10-11 Tom Tromey <tom@tromey.com>
1624
1625 * breakpoint.c (commands_command_1): Use std::string.
1626 (cleanup_executing_breakpoints): Remove.
1627 (bpstat_do_actions_1): Use scoped_restore.
1628 (bpstat_check_watchpoint): Use std::string.
1629 (decode_static_tracepoint_spec): Likewise.
1630 (break_range_command): Likewise.
1631 (watch_command_1): Likewise.
1632 (compare_breakpoints): Change argument types.
1633 (clear_command): Use std::vector.
1634 (cleanup_executing_breakpoints): Remove.
1635 (update_global_location_list): Use unique_xmalloc_ptr.
1636 (strace_command): Remove unused declaration.
1637
1638 2017-10-11 John Baldwin <jhb@FreeBSD.org>
1639
1640 * Makefile.in (ALLDEPFILES): Add arm-fbsd-nat.c.
1641 * NEWS: Mention new FreeBSD/arm native configuration.
1642 * configure.host: Add arm*-*-freebsd*.
1643 * configure.nat: Likewise.
1644 * arm-fbsd-nat.c: New file.
1645
1646 2017-10-11 John Baldwin <jhb@FreeBSD.org>
1647
1648 * Makefile.in (ALL_TARGET_OBS): Add arm-fbsd-tdep.o.
1649 (ALLDEPFILES): Add arm-fbsd-tdep.c.
1650 * NEWS: Mention new FreeBSD/arm target.
1651 * configure.tgt: Add arm*-*-freebsd*.
1652 * arm-fbsd-tdep.c: New file.
1653 * arm-fbsd-tdep.h: New file.
1654
1655 2017-10-11 Maciej W. Rozycki <macro@imgtec.com>
1656
1657 * linux-tdep.c (linux_make_corefile_notes): Remove call to
1658 `gdbarch_elfcore_write_linux_prpsinfo'.
1659 * gdbarch.sh (elfcore_write_linux_prpsinfo): Remove architecture
1660 method.
1661 (elf_internal_linux_prpsinfo): Remove declaration.
1662 * gdbarch.h: Regenerate.
1663 * gdbarch.c: Regenerate.
1664
1665 2017-10-11 Maciej W. Rozycki <macro@imgtec.com>
1666
1667 * ppc-linux-tdep.c (ppc_linux_init_abi): Remove call to
1668 `set_gdbarch_elfcore_write_linux_prpsinfo'.
1669
1670 2017-10-11 Pedro Alves <palves@redhat.com>
1671
1672 * breakpoint.c (reattach_breakpoints): Delete.
1673 * breakpoint.h (reattach_breakpoints): Delete.
1674
1675 2017-10-11 Simon Marchi <simon.marchi@ericsson.com>
1676
1677 * symfile.c (registered_sym_fns): Make struct, not typedef.
1678 (DEF_VEC_O (registered_sym_fns)): Remove.
1679 (symtab_fns): Change type to std::vector.
1680 (add_symtab_fns): Adjust.
1681 (find_sym_fns): Adjust.
1682
1683 2017-10-11 Anton Kolesov <Anton.Kolesov@synopsys.com>
1684
1685 * arc-tdep.c (arc_gdbarch_init): Pass proper cpu value to disassembler.
1686 * arc-tdep.h (arc_arch_is_em): New function.
1687 (arc_arch_is_hs): Likewise.
1688
1689 2017-10-11 Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
1690
1691 * macrotab.h (macro_lookup_inclusion): Remove unnecessary
1692 parentheses in the declaration.
1693 (macro_lookup_inclusion): Likewise.
1694 (macro_lookup_definition): Likewise.
1695 * p-lang.h (pascal_builtin_types): Likewise.
1696 * tui/tui-data.c (tui_win_list): Likewise.
1697 * tui/tui-data.h (tui_win_list): Likewise.
1698 * utils.h (make_cleanup_free_section_addr_info): Likewise.
1699
1700 2017-10-11 Mark Rages <markrages@gmail.com>
1701
1702 * target-memory.c (block_boundaries): Fix for block address not
1703 aligned on block size.
1704
1705 2017-10-10 Pedro Alves <palves@redhat.com>
1706 Tom Tromey <tom@tromey.com>
1707
1708 * breakpoint.c (struct captured_breakpoint_query_args)
1709 (do_captured_breakpoint_query, gdb_breakpoint_query): Delete.
1710 (print_breakpoint): New.
1711 * breakpoint.h (print_breakpoint): Declare.
1712 * common/common-exceptions.h (enum return_reason): Remove
1713 references to catch_exceptions.
1714 * exceptions.c (catch_exceptions, catch_exceptions_with_msg):
1715 Delete.
1716 * exceptions.h (catch_exceptions_ftype, catch_exceptions)
1717 (catch_exception_ftype, catch_exceptions_with_msg): Delete.
1718 * gdb.h: Delete.
1719 * gdbthread.h (thread_select): Declare.
1720 * mi/mi-cmd-break.c: Don't include gdb.h.
1721 (breakpoint_notify): Use print_breakpoint.
1722 * mi/mi-cmd-catch.c: Don't include gdb.h.
1723 * mi/mi-interp.c: Don't include gdb.h.
1724 (mi_print_breakpoint_for_event): New.
1725 (mi_breakpoint_created, mi_breakpoint_modified): Use
1726 mi_print_breakpoint_for_event.
1727 * mi/mi-main.c: Don't include gdb.h.
1728 (mi_cmd_thread_select): Parse the global thread ID here. Use
1729 thread_select instead of gdb_thread_select.
1730 (mi_cmd_thread_list_ids): Output "thread-ids" tuple here instead
1731 of using gdb_list_thread_ids.
1732 * remote-fileio.c (do_remote_fileio_request): Change type. Reply
1733 FILEIO_ENOSYS here.
1734 (remote_fileio_request): Use TRY/CATCH instead of
1735 catch_exceptions.
1736 * symfile-mem.c (struct symbol_file_add_from_memory_args)
1737 (symbol_file_add_from_memory_wrapper): Delete.
1738 (add_vsyscall_page): Use TRY/CATCH instead of catch_exceptions.
1739 * thread.c: Don't include gdb.h.
1740 (do_captured_list_thread_ids, gdb_list_thread_ids): Delete.
1741 (thread_alive): Use thread_select.
1742 (do_captured_thread_select): Delete, parts salvaged as ...
1743 (thread_select): ... this new function.
1744 (gdb_thread_select): Delete.
1745
1746 2017-10-10 Pedro Alves <palves@redhat.com>
1747 Tom Tromey <tom@tromey.com>
1748
1749 * breakpoint.c (breakpoint_cond_eval): Change return type to bool
1750 and reverse logic.
1751 (WP_DELETED, WP_VALUE_CHANGED, WP_VALUE_NOT_CHANGED, WP_IGNORE):
1752 No longer macros. Instead ...
1753 (enum wp_check_result): They're now values of this new
1754 enumeration.
1755 (watchpoint_check): Change return type to wp_check_result and
1756 parameter type to bpstat.
1757 (bpstat_check_watchpoint): Use TRY/CATCH instead of catch_errors.
1758 (bpstat_check_breakpoint_conditions): Use TRY/CATCH instead of
1759 catch_errors. Reverse logic of watchpoint_check call.
1760 (breakpoint_re_set_one): Now returns void and takes a breakpoint
1761 pointer as parameter.
1762 (breakpoint_re_set): Use TRY/CATCH instead of catch_errors.
1763 * common/common-exceptions.c (throw_exception_sjlj): Update
1764 comments to avoid mentioning catch_errors.
1765 * exceptions.c (catch_errors): Delete.
1766 * exceptions.h: Update comments to avoid mentioning catch_errors.
1767 (catch_errors_ftype, catch_errors): Delete.
1768 * infrun.c (normal_stop): Use TRY/CATCH instead of catch_errors.
1769 (hook_stop_stub): Delete.
1770 (restore_selected_frame): Change return type to void, and
1771 parameter type to const frame_id &.
1772 (restore_infcall_control_state): Use TRY/CATCH instead of
1773 catch_errors.
1774 * main.c (captured_command_loop): Return void and remove
1775 parameter. Remove references to catch_errors.
1776 (captured_main): Use TRY/CATCH instead of catch_errors.
1777 * objc-lang.c (objc_submethod_helper_data)
1778 (find_objc_msgcall_submethod_helper): Delete.
1779 (find_objc_msgcall_submethod): Use TRY/CATCH instead of
1780 catch_errors.
1781 * record-full.c (record_full_message): Return void.
1782 (record_full_message_args, record_full_message_wrapper): Delete.
1783 (record_full_message_wrapper_safe): Return bool and use TRY/CATCH
1784 instead of catch_errors.
1785 * solib-aix.c (solib_aix_open_symbol_file_object): Change
1786 parameter type to int.
1787 * solib-darwin.c (open_symbol_file_object): Ditto.
1788 * solib-dsbt.c (open_symbol_file_object): Ditto.
1789 * solib-frv.c (open_symbol_file_object): Ditto.
1790 * solib-svr4.c (open_symbol_file_object): Ditto.
1791 * solib-target.c (solib_target_open_symbol_file_object): Ditto.
1792 * solib.c (update_solib_list): Use TRY/CATCH instead of
1793 catch_errors.
1794 * solist.h (struct target_so_ops) <open_symbol_file_object>:
1795 Change type.
1796 * symmisc.c (struct print_symbol_args): Remove.
1797 (dump_symtab_1): Use TRY/CATCH instead of catch_errors.
1798 (print_symbol): Change type.
1799 * windows-nat.c (handle_load_dll, handle_unload_dll): Return void
1800 and remove parameters.
1801 (catch_errors): New.
1802 (get_windows_debug_event): Adjust.
1803
1804 2017-10-09 Tom Tromey <tom@tromey.com>
1805
1806 * mi/mi-main.c (free_splay_tree): Remove.
1807 (list_available_thread_groups): Use splay_tree_up.
1808 * common/gdb_splay_tree.h: New file.
1809
1810 2017-10-09 Tom Tromey <tom@tromey.com>
1811
1812 * mi/mi-main.c (do_nothing): Remove.
1813 (list_available_thread_groups): Update.
1814
1815 2017-10-09 Pedro Alves <palves@redhat.com>
1816
1817 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>: Skip
1818 reading registers when switching context.
1819
1820 2017-10-09 John Baldwin <jhb@FreeBSD.org>
1821
1822 * fbsd-nat.c (fbsd_siginfo_size): Use gdbarch_long_bit.
1823 (fbsd_convert_siginfo): Likewise.
1824 * fbsd-tdep.c (fbsd_core_xfer_siginfo): Likewise.
1825
1826 2017-10-09 Simon Marchi <simon.marchi@polymtl.ca>
1827
1828 * configure.ac (try_guile_versions): Remove guile-2.2.
1829 * configure: Regenerate.
1830
1831 2017-10-09 Tom Tromey <tom@tromey.com>
1832
1833 * Makefile.in (COMPILE.post, POSTCOMPILE): Restore $(basename).
1834 (COMPILE.pre): Use $(CXX).
1835
1836 2017-10-09 Pedro Alves <palves@redhat.com>
1837
1838 * cp-support.c (cp_remove_params): Return a gdb::unique_xmalloc_ptr.
1839 Use bool.
1840 (overload_list_add_symbol): Adjust to use gdb::unique_xmalloc_ptr.
1841 * cp-support.h (cp_remove_params): Now returns a
1842 gdb::unique_xmalloc_ptr.
1843 * dwarf2read.c (find_slot_in_mapped_hash): Now returns bool.
1844 Adjust to cp_remove_params returning a gdb::unique_xmalloc_ptr.
1845 * psymtab.c (psymtab_search_name): Adjust to cp_remove_params
1846 returning a gdb::unique_xmalloc_ptr.
1847 (lookup_partial_symbol): Adjust to use gdb::unique_xmalloc_ptr.
1848 * stack.c (find_frame_funname): Adjust to cp_remove_params
1849 returning a gdb::unique_xmalloc_ptr.
1850
1851 2017-10-08 Tom Tromey <tom@tromey.com>
1852
1853 * dwarf2read.c (dwarf2_get_dwz_file): Use
1854 gdb::unique_xmalloc_ptr.
1855 (find_slot_in_mapped_hash): Likewise.
1856 (dwarf2_physname): Likewise.
1857 (create_dwo_unit_in_dwp_v1): Use std::string.
1858 (create_dwo_unit_in_dwp_v2): Likewise.
1859 (lookup_dwo_cutu): Likewise.
1860 (inherit_abstract_dies): Use std::vector.
1861 (read_array_type): Likewise.
1862 (dwarf_decode_macros): Remove unused declaration.
1863 (unsigned_int_compar): Remove.
1864 (dwarf2_build_psymtabs_hard): Use scoped_restore.
1865 (psymtabs_addrmap_cleanup): Remove.
1866
1867 2017-10-08 Tom Tromey <tom@tromey.com>
1868
1869 * frame-unwind.c (frame_unwind_try_unwinder): Update.
1870 * frame.h (frame_cleanup_after_sniffer): Declare.
1871 (frame_prepare_for_sniffer): Return void.
1872 * frame.c (frame_cleanup_after_sniffer): No longer static. Change
1873 type of argument.
1874 (frame_prepare_for_sniffer): Return void.
1875
1876 2017-10-08 Tom Tromey <tom@tromey.com>
1877
1878 * utils.h (make_cleanup_value_free): Remove.
1879 * utils.c (do_value_free, struct cleanup): Remove.
1880 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full) <DWARF_VALUE_STACK>:
1881 Use gdb_value_up.
1882 * value.h (struct value_deleter): New.
1883 (gdb_value_up): New typedef.
1884
1885 2017-10-08 Tom Tromey <tom@tromey.com>
1886
1887 * symtab.c (free_search_symbols, do_free_search_symbols_cleanup)
1888 (make_cleanup_free_search_symbols): Remove.
1889 (search_symbols): Return std::vector.
1890 (symbol_search::compare_search_syms): Now member of
1891 symbol_search. Change arguments.
1892 (sort_search_symbols_remove_dups): Change arguments. Rewrite.
1893 (symtab_symbol_info, rbreak_command): Update.
1894 * symtab.h (struct symbol_search) <next>: Remove.
1895 Add constructors.
1896 (symbol_search::operator<): New function.
1897 (symbol_search::operator==): New function.
1898 (search_symbols): Remove std::vector.
1899 (free_search_symbols, make_cleanup_free_search_symbols): Remove.
1900 (symbol_search::compare_search_syms): Declare.
1901
1902 2017-10-06 Yao Qi <yao.qi@linaro.org>
1903
1904 * Makefile.in (ALL_64_TARGET_OBS): Replace aarch64-insn.o with
1905 arch/aarch64-insn.o.
1906 Remove one rule.
1907 * configure.tgt: Replace aarch64-insn.o with arch/aarch64-insn.o.
1908
1909 2017-10-06 Yao Qi <yao.qi@linaro.org>
1910
1911 * Makefile.in (ALL_TARGET_OBS): Replace arm.o, arm-get-next-pcs.o,
1912 and arm-linux.o with arch/arm.o, arch/arm-get-next-pcs.o and
1913 arch/arm-linux.o respectively.
1914 * configure.tgt: Likewise.
1915
1916 2017-10-06 Yao Qi <yao.qi@linaro.org>
1917
1918 * Makefile.in (ALL_TARGET_OBS): Rename i386.o to arch/i386.o.
1919 * configure.tgt (i386_tobjs): Replace i386.o with arch/i386.o.
1920
1921 2017-10-06 Pedro Alves <palves@redhat.com>
1922
1923 * windows-nat.c: Include <algorithm>.
1924
1925 2017-10-06 Yao Qi <yao.qi@linaro.org>
1926
1927 * configure.tgt (i386_tobjs): New variable.
1928 (amd64_tobjs): New variable.
1929 Set $cpu_obs and $os_obs.
1930
1931 2017-10-06 Yao Qi <yao.qi@linaro.org>
1932
1933 * Makefile.in (CONFIG_SRC_SUBDIR): New.
1934 (ALL_64_TARGET_OBS): Replace amd64.o with arch/amd64.o.
1935 (clean): Remove object files and dependency files.
1936 (distclean): Remove the directory.
1937 * configure.ac: Invoke AC_CONFIG_COMMANDS.
1938 * configure: Re-generated.
1939 * configure.tgt: Replace amd64.o with arch/amd64.o.
1940
1941 2017-10-05 Jose E. Marchesi <jose.marchesi@oracle.com>
1942
1943 PR build/22188
1944 * arm-tdep.c (arm_decode_misc_memhint_neon): Fix decoding of CPS
1945 and SETEND.
1946
1947 2017-10-05 Pedro Alves <palves@redhat.com>
1948
1949 * linux-nat.c (linux_child_follow_fork): When following the parent
1950 and detaching the child, consult the parent thread's architecture
1951 instead of the child's.
1952
1953 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
1954
1955 * ax.h: Do not include "doublest.h".
1956 (union agent_val): Remove.
1957
1958 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
1959
1960 * dfp.h (MAX_DECIMAL_STRING): Move to dfp.c.
1961 (decimal_to_string): Return std::string object.
1962 (decimal_from_string): Accept std::string object. Return bool.
1963 (decimal_from_integral, decimal_from_doublest): Remove.
1964 (decimal_from_longest): Add prototype.
1965 (decimal_from_ulongest): Likewise.
1966 (decimal_to_longest): Likewise.
1967 (decimal_from_doublest): Likewise.
1968 * dfp.c: Do not include "gdbtypes.h" or "value.h".
1969 (MAX_DECIMAL_STRING): Move here.
1970 (decimal_to_string): Return std::string object.
1971 (decimal_from_string): Accept std::string object. Return bool.
1972 (decimal_from_integral): Remove, replace by ...
1973 (decimal_from_longest, decimal_from_ulongest): ... these new functions.
1974 (decimal_to_longest): New function.
1975 (decimal_from_floating): Remove, replace by ...
1976 (decimal_from_doublest): ... this new function.
1977 (decimal_to_doublest): Update to new decimal_to_string interface.
1978
1979 * value.c (unpack_long): Use decimal_to_longest.
1980 * valops.c (value_cast): Use decimal_from_doublest instead of
1981 decimal_from_floating. Use decimal_from_[u]longest isntead of
1982 decimal_from_integral.
1983 * valarith.c (value_args_as_decimal): Likewise.
1984 * valprint.c (print_decimal_floating): Update to new
1985 decimal_to_string interface.
1986 * printcmd.c (printf_decfloat): Likewise.
1987 * c-exp.y (parse_number): Update to new decimal_from_string interface.
1988
1989 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
1990
1991 * doublest.h: Do not include "floatformat.h". Remove stale comments.
1992 * gdbtypes.c: Include "floatformat.h".
1993 * value.c: Likewise.
1994 * m68k-tdep.c: Likewise.
1995
1996 * findvar.c: Do not include "floatformat.h".
1997 * amd64-darwin-tdep.c: Likewise.
1998 * arm-linux-tdep.c: Likewise.
1999 * i386-darwin-tdep.c: Likewise.
2000 * i387-tdep.c: Likewise.
2001 * m68k-linux-tdep.c: Likewise.
2002 * mep-tdep.c: Likewise.
2003 * mips-tdep.c: Likewise.
2004 * nios2-tdep.c: Likewise.
2005 * s390-linux-tdep.c: Likewise.
2006 * sparc-obsd-tdep.c: Likewise.
2007 * sparc-tdep.c: Likewise.
2008 * sparc64-tdep.c: Likewise.
2009 * spu-tdep.c: Likewise.
2010 * tic6x-tdep.c: Likewise.
2011 * tilegx-tdep.c: Likewise.
2012 * vax-tdep.c: Likewise.
2013 * xstormy16-tdep.c: Likewise.
2014 * xtensa-tdep.c: Likewise.
2015
2016 * top.c: Do not include "doublest.h".
2017 * aarch64-tdep.c: Likewise.
2018 * alpha-tdep.c: Likewise.
2019 * arm-linux-tdep.c: Likewise.
2020 * m68k-linux-tdep.c: Likewise.
2021 * tilegx-tdep.c: Likewise.
2022 * xstormy16-tdep.c: Likewise.
2023
2024 2017-10-05 John Baldwin <jhb@FreeBSD.org>
2025
2026 * mips-fbsd-tdep.c (MIPS_INST_ADDIU_A0_SP_N32): Define.
2027 (mipsn32_fbsd_sigframe): Define.
2028 (mips_fbsd_init_abi): Install mipsn32_fbsd_sigframe unwinder
2029 for FreeBSD/mipsn32.
2030
2031 2017-10-05 John Baldwin <jhb@FreeBSD.org>
2032
2033 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_EHDRFLAGS and
2034 AT_HWCAP.
2035
2036 2017-10-05 Tristan Gingold <tgingold@free.fr>
2037
2038 * MAINTAINERS (Misc): Update my email address.
2039
2040 2017-10-04 Pedro Alves <palves@redhat.com>
2041
2042 * remote.c (get_remote_arch_state): New 'gdbarch' parameter. Use
2043 it instead of target_gdbarch.
2044 (get_remote_state, get_remote_packet_size): Adjust
2045 get_remote_arch_state calls, passing down target_gdbarch
2046 explicitly.
2047 (packet_reg_from_regnum, packet_reg_from_pnum): New parameter
2048 'gdbarch' and use it instead of target_gdbarch.
2049 (get_memory_packet_size): Adjust get_remote_arch_state calls,
2050 passing down target_gdbarch explicitly.
2051 (struct stop_reply) <arch>: New field.
2052 (remote_parse_stop_reply): Use the stopped thread's architecture,
2053 not the current inferior's. Save the architecture in the
2054 stop_reply.
2055 (process_stop_reply): Use the stop reply's architecture.
2056 (process_g_packet, remote_fetch_registers)
2057 (remote_prepare_to_store, store_registers_using_G)
2058 (remote_store_registers): Adjust get_remote_arch_state calls,
2059 using the regcache's architecture.
2060 (remote_get_trace_status): Adjust get_remote_arch_state calls,
2061 passing down target_gdbarch explicitly.
2062 * spu-multiarch.c (spu_thread_architecture): Defer to the target
2063 beneath instead of calling target_gdbarch.
2064 * target.c (default_thread_architecture): Use the specified
2065 inferior's architecture, instead of the current inferior's
2066 architecture (via target_gdbarch).
2067
2068 2017-10-04 Pedro Alves <palves@redhat.com>
2069
2070 * regcache.c (get_thread_arch_regcache): Remove null_ptid special
2071 case.
2072 (regcache_print): Handle !target_has_registers here instead.
2073
2074 2017-10-04 Pedro Alves <palves@redhat.com>
2075
2076 * frame.c (create_test_frame): Delete.
2077 * frame.h (create_test_frame): Delete.
2078 * gdbarch-selftests.c: Include gdbthread.h and target.h.
2079 (class regcache_test): Delete.
2080 (test_target_has_registers, test_target_has_stack)
2081 (test_target_has_memory, test_target_prepare_to_store)
2082 (test_target_store_registers): New functions.
2083 (test_target_ops): New class.
2084 (register_to_value_test): Error out if there's already a
2085 process_stratum (or higher) target pushed. Create a fuller mock
2086 environment, with mock target_ops, inferior, address space, thread
2087 and inferior_ptid.
2088 * progspace.c (struct address_space): Move to ...
2089 * progspace.h (struct address_space): ... here.
2090 * regcache.h (regcache::~regcache, regcache::raw_write)
2091 [GDB_SELF_TEST]: No longer virtual.
2092
2093 2017-10-04 Simon Marchi <simon.marchi@ericsson.com>
2094
2095 * mi/mi-main.c (list_available_thread_groups): Reverse filter logic.
2096
2097 2017-10-04 Pedro Alves <palves@redhat.com>
2098
2099 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Move code
2100 out of 'between TRY and CATCH'.
2101
2102 2017-10-04 Pedro Alves <palves@redhat.com>
2103
2104 * cli/cli-cmds.c (complete_command): Add missing END_CATCH.
2105 * common/common-exceptions.h (TRY): Open an outermost scope.
2106 Expand intro comment.
2107 (CATCH): Reindent.
2108 (END_CATCH): Close the outermost scope.
2109 * completer.c (complete_line_internal): Add missing END_CATCH.
2110
2111 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2112
2113 * NEWS (Changes since GDB 8.0): Add entry about new
2114 'set-cwd-on-gdbserver' feature.
2115 (New remote packets): Add entry for QSetWorkingDir.
2116 * common/common-inferior.h (set_inferior_cwd): New prototype.
2117 * infcmd.c (set_inferior_cwd): Remove "static".
2118 (show_cwd_command): Expand text to include remote debugging.
2119 * remote.c: Add PACKET_QSetWorkingDir.
2120 (remote_protocol_features) <QSetWorkingDir>: New entry for
2121 PACKET_QSetWorkingDir.
2122 (extended_remote_set_inferior_cwd): New function.
2123 (extended_remote_create_inferior): Call
2124 "extended_remote_set_inferior_cwd".
2125 (_initialize_remote): Call "add_packet_config_cmd" for
2126 QSetWorkingDir.
2127
2128 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2129
2130 * NEWS (New commands): Mention "set/show cwd".
2131 * cli/cli-cmds.c (_initialize_cli_cmds): Mention "set cwd" on
2132 "cd" command's help text.
2133 * common/common-inferior.h (get_inferior_cwd): New prototype.
2134 * infcmd.c (inferior_cwd_scratch): New global variable.
2135 (set_inferior_cwd): New function.
2136 (get_inferior_cwd): Likewise.
2137 (set_cwd_command): Likewise.
2138 (show_cwd_command): Likewise.
2139 (_initialize_infcmd): Add "set/show cwd" commands.
2140 * inferior.h (class inferior) <cwd>: New field.
2141 * nat/fork-inferior.c: Include "gdb_tilde_expand.h".
2142 (fork_inferior): Change inferior's cwd before its execution.
2143 * windows-nat.c (windows_create_inferior): Pass inferior's cwd
2144 to CreateProcess.
2145
2146 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2147
2148 * Makefile.in (SFILES): Add gdb_tilde_expand.c.
2149 (HFILES_NO_SRCDIR): Add gdb_tilde_expand.h.
2150 (COMMON_OBS): Add gdb_tilde_expand.o.
2151 * common/gdb_tilde_expand.c: New file.
2152 * common/gdb_tilde_expand.h: Likewise.
2153
2154 2017-10-03 Maciej W. Rozycki <macro@imgtec.com>
2155
2156 * gdbarch.sh (objfile): Remove duplicate declaration.
2157 * gdbarch.h: Regenerate.
2158
2159 2017-10-03 Tom Tromey <tom@tromey.com>
2160
2161 * utils.c (internal_vproblem): Use string_vprintf.
2162
2163 2017-10-03 Tom Tromey <tom@tromey.com>
2164
2165 * printcmd.c (info_symbol_command): Use std::string.
2166
2167 2017-10-03 Tom Tromey <tom@tromey.com>
2168
2169 * top.c (gdb_safe_append_history): Use std::string.
2170
2171 2017-10-03 Tom Tromey <tom@tromey.com>
2172
2173 * event-top.c (stdin_event_handler): Update.
2174 * main.c (captured_main_1): Update.
2175 * top.h (make_delete_ui_cleanup): Remove.
2176 (struct ui): Add constructor and destructor.
2177 (new_ui, delete_ui): Remove.
2178 * top.c (make_delete_ui_cleanup): Remove.
2179 (new_ui_command): Use std::unique_ptr.
2180 (delete_ui_cleanup): Remove.
2181 (ui::ui): Rename from new_ui. Update.
2182 (free_ui): Remove.
2183 (ui::~ui): Rename from delete_ui. Update.
2184
2185 2017-10-03 Tom Tromey <tom@tromey.com>
2186
2187 * symfile.c (load_progress): Use gdb::byte_vector.
2188
2189 2017-10-03 Tom Tromey <tom@tromey.com>
2190
2191 * mi/mi-main.c (mi_cmd_trace_frame_collected): Remove unused
2192 declaration.
2193 * printcmd.c (x_command): Remove unused declaration.
2194 * symfile.c (symbol_file_command): Remove unused declaration.
2195
2196 2017-10-03 Tom Tromey <tom@tromey.com>
2197
2198 * utils.c (internal_vproblem): Use std::string.
2199 (defaulted_query): Likewise.
2200
2201 2017-10-03 Tom Tromey <tom@tromey.com>
2202
2203 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Update.
2204 * top.c (execute_command_to_string): Update.
2205 * utils.c (make_cleanup_restore_page_info): Remove.
2206 (do_restore_page_info_cleanup): Remove.
2207 (set_batch_flag_and_restore_page_info):
2208 New.
2209 (make_cleanup_restore_page_info): Remove.
2210 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
2211 (~set_batch_flag_and_restore_page_info): New
2212 (make_cleanup_restore_uinteger): Remove.
2213 (make_cleanup_restore_integer): Remove.
2214 (struct restore_integer_closure): Remove.
2215 (restore_integer): Remove.
2216 * utils.h (struct set_batch_flag_and_restore_page_info): New
2217 class.
2218 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
2219 (make_cleanup_restore_page_info): Remove.
2220 (make_cleanup_restore_uinteger) Remove.
2221 (make_cleanup_restore_integer) Remove.
2222
2223 2017-10-03 Tom Tromey <tom@tromey.com>
2224
2225 * record-full.h (record_full_gdb_operation_disable_set): Return
2226 scoped_restore_tmpl<int>.
2227 * infrun.c (adjust_pc_after_break): Update.
2228 (handle_signal_stop): Update.
2229 * record-full.c (record_full_gdb_operation_disable_set): Return
2230 scoped_restore_tmpl<int>.
2231 (record_full_wait_1, record_full_insert_breakpoint)
2232 (record_full_remove_breakpoint, record_full_save)
2233 (record_full_goto_insn): Update.
2234
2235 2017-10-02 Tom Tromey <tom@tromey.com>
2236
2237 PR rust/22236:
2238 * rust-lang.c (rust_val_print_str): New function.
2239 (val_print_struct): Call it.
2240 (rust_subscript): Preserve name of slice type.
2241
2242 2017-10-02 Tom Tromey <tom@tromey.com>
2243
2244 * rust-lang.c (rust_subscript): Handle slices in
2245 EVAL_AVOID_SIDE_EFFECTS case.
2246
2247 2017-10-02 Tom Tromey <tom@tromey.com>
2248
2249 * rust-lang.c (rust_slice_type_p): Recognize &str as a slice type.
2250
2251 2017-10-02 Tom Tromey <tom@tromey.com>
2252
2253 * rust-lang.h (rust_slice_type): Add "extern".
2254
2255 2017-10-02 Tom Tromey <tom@tromey.com>
2256 Pedro Alves <palves@redhat.com>
2257
2258 * ada-lang.h (ada_exc_info::operator<): Make const.
2259 (ada_exc_info::operator==): Make const.
2260 * ada-lang.c (ada_exc_info::operator<, ada_exc_info::operator==):
2261 Make const.
2262
2263 2017-09-29 Tom Tromey <tom@tromey.com>
2264
2265 * target.c (read_whatever_is_readable): Change type of "result".
2266 Update.
2267 (free_memory_read_result_vector): Remove.
2268 (read_memory_robust): Change return type. Update.
2269 * mi/mi-main.c (mi_cmd_data_read_memory_bytes): Update. Use
2270 bin2hex, std::string.
2271 * target.h (memory_read_result_s): Remove typedef.
2272 (free_memory_read_result_vector): Remove.
2273 (read_memory_robust): Return std::vector.
2274
2275 2017-09-29 Tom Tromey <tom@tromey.com>
2276
2277 * mi/mi-main.c (captured_mi_execute_command): Use scope_restore.
2278
2279 2017-09-29 Tom Tromey <tom@tromey.com>
2280
2281 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Update.
2282 * ada-lang.h (struct ada_exc_info): Remove typedef. Declare
2283 operator< and operator==.
2284 (ada_exceptions_list): Return a std::vector.
2285 * ada-lang.c (ada_exc_info::operator<): Rename from
2286 compare_ada_exception_info.
2287 (ada_exc_info::operator==): New.
2288 (sort_remove_dups_ada_exceptions_list): Change type of
2289 "exceptions".
2290 (ada_add_standard_exceptions, ada_add_exceptions_from_frame)
2291 (ada_add_global_exceptions): Likewise.
2292 (ada_exceptions_list_1): Return a std::vector.
2293 (ada_exceptions_list): Likewise.
2294
2295 2017-09-29 Tom Tromey <tom@tromey.com>
2296
2297 * mi/mi-main.c (struct print_one_inferior_data) <inferiors>: Now a
2298 'std::set *'.
2299 (print_one_inferior): Update.
2300 (free_vector_of_ints): Remove.
2301 (list_available_thread_groups): Change "ids" to std::set.
2302 (mi_cmd_list_thread_groups): Update.
2303 (struct collect_cores_data) <core>: Now a std::set.
2304 (collect_cores): Update.
2305 (unique): Remove.
2306 (print_one_inferior): Update.
2307
2308 2017-09-29 Tom Tromey <tom@tromey.com>
2309
2310 * mi/mi-main.c (mi_execute_cli_command): Use std::string.
2311 (mi_execute_async_cli_command): Likewise.
2312 (mi_cmd_trace_frame_collected): Use field_fmt.
2313
2314 2017-09-29 Tom Tromey <tom@tromey.com>
2315
2316 * mi/mi-main.c (mi_cmd_data_write_memory_bytes): Use
2317 gdb::byte_vector.
2318
2319 2017-09-29 Tom Tromey <tom@tromey.com>
2320
2321 * mi/mi-parse.c (mi_parse): Remove unused declaration.
2322
2323 2017-09-29 Tom Tromey <tom@tromey.com>
2324
2325 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Don't copy "oarg".
2326
2327 2017-09-29 Tom Tromey <tom@tromey.com>
2328
2329 * varobj.h (varobj_gen_name): Return std::string.
2330 * varobj.c (varobj_gen_name): Return std::string.
2331 * mi/mi-cmd-var.c (mi_cmd_var_create): Use std::string.
2332 (mi_cmd_var_delete): Don't copy "name".
2333
2334 2017-09-29 Tom Tromey <tom@tromey.com>
2335
2336 * mi/mi-cmd-break.c (mi_argv_to_format): Return std::string.
2337 (mi_cmd_break_insert_1): Update.
2338
2339 2017-09-29 Tom Tromey <tom@tromey.com>
2340
2341 * target.h (make_scoped_defer_target_commit_resume): Update.
2342 * target.c (make_scoped_defer_target_commit_resume): Rename from
2343 make_cleanup_defer_target_commit_resume. Return a
2344 scoped_restore.
2345 * infrun.c (proceed): Use make_scoped_defer_target_commit_resume.
2346
2347 2017-09-29 Tom Tromey <tom@tromey.com>
2348
2349 * main.c (captured_main_1): Remove unused declaration.
2350 * spu-multiarch.c (parse_spufs_run): Remove unused declaration.
2351
2352 2017-09-29 Tom Tromey <tom@tromey.com>
2353
2354 * symtab.c (search_symbols): Remove unused outer cleanup.
2355 (make_source_files_completion_list): Remove unused declaration.
2356
2357 2017-09-29 Tom Tromey <tom@tromey.com>
2358
2359 * mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.
2360
2361 2017-09-29 Tom Tromey <tom@tromey.com>
2362
2363 * xstormy16-tdep.c (xstormy16_push_dummy_call): Use
2364 gdb::byte_vector.
2365
2366 2017-09-29 Tom Tromey <tom@tromey.com>
2367
2368 * complaints.c (vcomplaint): Use std::string.
2369
2370 2017-09-29 Tom Tromey <tom@tromey.com>
2371
2372 * tracepoint.c (trace_variable_command): Use std::string.
2373 (encode_actions_1): Remove unused declarations.
2374 (create_tsv_from_upload): Use std::string.
2375
2376 2017-09-29 Tom Tromey <tom@tromey.com>
2377
2378 * cp-support.c (gdb_demangle): Use std::string.
2379
2380 2017-09-29 Tom Tromey <tom@tromey.com>
2381
2382 * stack.c (parse_frame_specification): Use std::string
2383 (info_frame_command): Use gdb::unique_xmalloc_ptr.
2384
2385 2017-09-29 Tom Tromey <tom@tromey.com>
2386
2387 * tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.
2388
2389 2017-09-29 Tom Tromey <tom@tromey.com>
2390
2391 * utils.c (vfprintf_maybe_filtered): Use std::string.
2392 (vfprintf_unfiltered): Likewise.
2393
2394 2017-09-29 Tom Tromey <tom@tromey.com>
2395
2396 * event-top.c (top_level_prompt): Return std::string.
2397 (display_gdb_prompt): Update.
2398
2399 2017-09-29 Tom Tromey <tom@tromey.com>
2400
2401 * unittests/common-utils-selftests.c (format): New function.
2402 (string_vprintf_tests): New function.
2403 (_initialize_common_utils_selftests): Register new tests.
2404 * common/common-utils.c (string_vprintf): New function.
2405 * common/common-utils.h (string_vprintf): Declare.
2406
2407 2017-09-29 Pedro Alves <palves@redhat.com>
2408
2409 * common/rsp-low.c (unpack_varlen_hex): Constify.
2410 * common/rsp-low.h (unpack_varlen_hex): Constify.
2411 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
2412 Constify.
2413 * remote.c (remote_set_permissions, read_ptid)
2414 (remote_current_thread, remote_get_threads_with_qthreadinfo)
2415 (remote_static_tracepoint_marker_at)
2416 (remote_static_tracepoint_markers_by_strid)
2417 (stop_reply_extract_thread, remote_parse_stop_reply): Constify.
2418 * tracepoint.c (parse_trace_status, parse_tracepoint_status)
2419 (parse_tracepoint_definition, parse_tsv_definition)
2420 (parse_static_tracepoint_marker_definition): Constify.
2421 * tracepoint.h (parse_static_tracepoint_marker_definition)
2422 (parse_trace_status, parse_tracepoint_status)
2423 (parse_tracepoint_definition, parse_tsv_definition): Constify.
2424
2425 2017-09-29 Pedro Alves <palves@redhat.com>
2426
2427 * remote.c (target_buf, target_buf_size): Delete.
2428 (remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
2429 Use the connection's packet buffer instead.
2430 All callers adjusted.
2431 (_initialize_remote): Remove references to target_buf and
2432 target_buf_size.
2433
2434 2017-09-28 Pedro Alves <palves@redhat.com>
2435
2436 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2437 unittests/common-utils-selftests.c.
2438 (SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
2439 (COMMON_OBS): Remove utils-selftests.o.
2440 * utils-selftests.c: Move to ...
2441 * unittests/common-utils-selftests.c: ... here and rename self
2442 test to "string_printf".
2443
2444 2017-09-28 Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com> (tiny patch)
2445
2446 * dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
2447 having NULL cus or tus.
2448
2449 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
2450
2451 * arm-tdep.c: (convert_from_extended): Remove.
2452 (convert_to_extended): Likewise.
2453 (arm_extract_return_value): Use convert_typed_floating.
2454 (arm_store_return_value): Likewise.
2455
2456 * sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
2457 * sh-tdep.c: Do not include "floatformat.h".
2458 (sh_littlebyte_bigword_type): New function.
2459 (sh_register_convert_to_virtual): Use convert_typed_floating.
2460 (sh_register_convert_to_raw): Likewise.
2461 * sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
2462 (sh64_littlebyte_bigword_type): New function.
2463 (sh64_extract_return_value): Use convert_typed_floating.
2464 (sh64_register_convert_to_virtual): Likewise.
2465 (sh64_register_convert_to_raw): Likewise.
2466
2467 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
2468
2469 * doublest.h (floatformat_from_type): Move to gdbtypes.h.
2470 * doublest.c (floatformat_from_type): Move to gdbtypes.c.
2471
2472 * gdbtypes.h (union type_specific): Make field floatformat hold
2473 just a single struct floatformat, not an array.
2474 (floatformat_from_type): Move here.
2475 * gdbtypes.c (floatformat_from_type): Move here. Update to
2476 changed TYPE_FLOATFORMAT definition.
2477 (verify_floatformat): Update to changed TYPE_FLOATFORMAT.
2478 (recursive_dump_type): Likewise.
2479 (init_float_type): Install correct floatformat for byte order.
2480 (arch_float_type): Likewise.
2481
2482 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
2483
2484 * gdbtypes.c (init_type): Change incoming argument from
2485 length-in-bytes to length-in-bits. Assert length is a
2486 multiple of TARGET_CHAR_BITS.
2487 (arch_type, arch_flags_type): Likewise.
2488 (init_integer_type): Update call to init_type.
2489 (init_character_type): Likewise.
2490 (init_boolean_type): Likewise.
2491 (init_float_type): Likewise.
2492 (init_decfloat_type): Likewise.
2493 (init_complex_type): Likewise.
2494 (init_pointer_type): Likewise.
2495 (objfile_type): Likewise.
2496 (arch_integer_type): Update call to arch_type.
2497 (arch_character_type): Likewise.
2498 (arch_boolean_type): Likewise.
2499 (arch_float_type): Likewise.
2500 (arch_decfloat_type): Likewise.
2501 (arch_complex_type): Likewise.
2502 (arch_pointer_type): Likewise.
2503 (gdbtypes_post_init): Likewise.
2504
2505 * dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
2506 (read_base_type): Likewise.
2507 * mdebugread.c (basic_type): Likewise.
2508 * stabsread.c (dbx_init_float_type): Likewise.
2509 (rs6000_builtin_type): Likewise.
2510 (read_range_type): Likewise. Also, fix call to init_integer_type
2511 with erroneous length argument.
2512
2513 * ada-lang.c (ada_language_arch_info): Update call to arch_type.
2514 * d-lang.c (build_d_types): Likewise.
2515 * f-lang.c (build_fortran_types): Likewise.
2516 * go-lang.c (build_go_types): Likewise.
2517 * opencl-lang.c (build_opencl_types): Likewise.
2518 * jit.c (finalize_symtab): Likewise.
2519 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
2520 (build_std_type_info_type): Likewise.
2521 * target-descriptions.c (tdesc_gdb_type): Likewise. Also,
2522 update call to arch_flags_type.
2523
2524 * linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
2525 arch_type.
2526 * fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
2527 * windows-tdep.c (windows_get_tlb_type): Likewise.
2528
2529 * avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
2530 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
2531 * m32c-tdep.c (make_types): Likewise.
2532 * rl78-tdep.c (rl78_gdbarch_init): Likewise.
2533 (rl78_psw_type): Update call to arch_flags_type.
2534 * m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
2535 * rx-tdep.c (rx_psw_type): Likewise.
2536 (rx_fpsw_type): Likewise.
2537 * sparc-tdep.c (sparc_psr_type): Likewise.
2538 (sparc_fsr_type): Likewise.
2539 * sparc64-tdep.c (sparc64_pstate_type): Likewise.
2540 (sparc64_ccr_type): Likewise.
2541 (sparc64_fsr_type): Likewise.
2542 (sparc64_fprs_type): Likewise.
2543
2544 2017-09-27 Tom Tromey <tom@tromey.com>
2545
2546 * findcmd.c (find_command): Constify.
2547
2548 2017-09-27 Tom Tromey <tom@tromey.com>
2549
2550 * ada-tasks.c (task_command_1, task_command): Constify.
2551
2552 2017-09-27 Tom Tromey <tom@tromey.com>
2553
2554 * symtab.c (maintenance_print_symbol_cache)
2555 (maintenance_flush_symbol_cache)
2556 (maintenance_print_symbol_cache_statistics): Constify.
2557
2558 2017-09-27 Tom Tromey <tom@tromey.com>
2559
2560 * inferior.c (detach_inferior_command, kill_inferior_command)
2561 (inferior_command): Constify.
2562
2563 2017-09-27 Tom Tromey <tom@tromey.com>
2564
2565 * regcache.c (regcache_print, maintenance_print_registers)
2566 (maintenance_print_raw_registers)
2567 (maintenance_print_cooked_registers)
2568 (maintenance_print_register_groups)
2569 (maintenance_print_remote_registers): Constify.
2570
2571 2017-09-27 Tom Tromey <tom@tromey.com>
2572
2573 * printcmd.c (map_display_numbers, undisplay_command)
2574 (enable_disable_display_command, enable_display_command)
2575 (disable_display_command): Constify.
2576
2577 2017-09-27 Tom Tromey <tom@tromey.com>
2578
2579 * breakpoint.h (delete_command): Don't declare.
2580 * breakpoint.c (delete_command, enable_once_command)
2581 (enable_count_command, enable_delete_command, breakpoint_1)
2582 (maintenance_info_breakpoints, stopin_command, stopat_command)
2583 (delete_command, delete_trace_command, save_breakpoints)
2584 (save_breakpoints_command, save_tracepoints_command): Constify.
2585
2586 2017-09-27 Tom Tromey <tom@tromey.com>
2587
2588 * macrocmd.c (macro_expand_command, macro_expand_once_command)
2589 (skip_ws, extract_identifier, macro_define_command)
2590 (macro_undef_command, macro_list_command): Constify.
2591
2592 2017-09-27 Tom Tromey <tom@tromey.com>
2593
2594 * infcmd.c (environment_info, set_environment_command)
2595 (unset_environment_command, path_info, info_proc_cmd_1)
2596 (info_proc_cmd_mappings, info_proc_cmd_stat)
2597 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
2598 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
2599
2600 2017-09-27 Tom Tromey <tom@tromey.com>
2601
2602 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
2603 Constify.
2604
2605 2017-09-27 Tom Tromey <tom@tromey.com>
2606
2607 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
2608
2609 2017-09-27 Tom Tromey <tom@tromey.com>
2610
2611 * demangle.c (demangle_command): Constify.
2612
2613 2017-09-27 Tom Tromey <tom@tromey.com>
2614
2615 * progspace.c (maintenance_info_program_spaces_command):
2616 Constify.
2617
2618 2017-09-27 Tom Tromey <tom@tromey.com>
2619
2620 * compile/compile.c (check_raw_argument, compile_file_command)
2621 (compile_code_command, compile_print_command): Constify.
2622
2623 2017-09-27 Tom Tromey <tom@tromey.com>
2624
2625 * reggroups.c (maintenance_print_reggroups): Constify.
2626
2627 2017-09-27 Tom Tromey <tom@tromey.com>
2628
2629 * dwarf2read.c (save_gdb_index_command): Constify.
2630
2631 2017-09-27 Tom Tromey <tom@tromey.com>
2632
2633 * stap-probe.c (info_probes_stap_command): Constify.
2634
2635 2017-09-27 Tom Tromey <tom@tromey.com>
2636
2637 * fork-child.c (unset_exec_wrapper_command): Constify.
2638
2639 2017-09-27 Tom Tromey <tom@tromey.com>
2640
2641 * btrace.c (get_uint, get_context_size, no_chunk)
2642 (maint_btrace_packet_history_cmd)
2643 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
2644 (maint_info_btrace_cmd): Constify.
2645
2646 2017-09-27 Tom Tromey <tom@tromey.com>
2647
2648 * reverse.c (delete_bookmark_command): Constify.
2649
2650 2017-09-27 Tom Tromey <tom@tromey.com>
2651
2652 * remote.c (set_memory_packet_size)
2653 (set_memory_write_packet_size, show_memory_write_packet_size)
2654 (set_memory_read_packet_size, show_memory_read_packet_size)
2655 (compare_sections_command, packet_command, remote_put_command)
2656 (remote_get_command, remote_delete_command): Constify.
2657
2658 2017-09-27 Tom Tromey <tom@tromey.com>
2659
2660 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
2661 (set_mipsfpu_double_command, set_mipsfpu_none_command)
2662 (set_mipsfpu_auto_command): Constify.
2663
2664 2017-09-27 Tom Tromey <tom@tromey.com>
2665
2666 * cli/cli-cmds.h (cd_command): Constify.
2667 * cli/cli-cmds.c (cd_command): Constify.
2668
2669 2017-09-27 Tom Tromey <tom@tromey.com>
2670
2671 * thread.c (thread_name_command, thread_find_command): Constify.
2672
2673 2017-09-27 Tom Tromey <tom@tromey.com>
2674
2675 * probe.c (enable_probes_command, disable_probes_command):
2676 Constify.
2677
2678 2017-09-27 Tom Tromey <tom@tromey.com>
2679
2680 * symfile.c (symbol_file_command): Constify.
2681 * gdbcore.h (deprecated_file_changed_hook): Constify.
2682 * exec.c (deprecated_file_changed_hook, exec_file_command)
2683 (file_command): Constify.
2684 * defs.h (symbol_file_command): Constify.
2685
2686 2017-09-27 Tom Tromey <tom@tromey.com>
2687
2688 * remote-fileio.c (set_system_call_allowed)
2689 (show_system_call_allowed): Constify.
2690
2691 2017-09-27 Tom Tromey <tom@tromey.com>
2692
2693 * tracepoint.c (delete_trace_variable_command)
2694 (tfind_end_command, tfind_start_command, tfind_pc_command)
2695 (tfind_tracepoint_command, tfind_line_command)
2696 (tfind_range_command, tfind_outside_command): Constify.
2697
2698 2017-09-27 Tom Tromey <tom@tromey.com>
2699
2700 * ax-gdb.c (maint_agent_printf_command, agent_command)
2701 (agent_eval_command): Constify.
2702
2703 2017-09-27 Tom Tromey <tom@tromey.com>
2704
2705 * tracepoint.c (info_scope_command): Constify.
2706 * python/python.c (gdbpy_decode_line): Constify.
2707 * python/py-breakpoint.c (bppy_init): Constify.
2708 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
2709 * location.h: (new_linespec_location)
2710 (string_to_event_location_basic, string_to_event_location):
2711 Constify.
2712 * location.c (new_linespec_location)
2713 (string_to_event_location_basic, string_to_event_location):
2714 Constify.
2715 * linespec.h (decode_line_with_current_source)
2716 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
2717 * linespec.c (linespec_lex_to_end)
2718 (decode_line_with_current_source)
2719 (decode_line_with_last_displayed): Constify.
2720 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
2721 Constify.
2722 * cli/cli-cmds.c (edit_command, list_command): Constify.
2723 * breakpoint.h (until_break_command, watch_command_wrapper)
2724 (awatch_command_wrapper, rwatch_command_wrapper)
2725 (init_ada_exception_breakpoint): Constify.
2726 * breakpoint.c (break_command_1, dprintf_command)
2727 (break_range_command, watch_command_wrapper)
2728 (rwatch_command_wrapper, awatch_command_wrapper)
2729 (until_break_command, init_ada_exception_breakpoint)
2730 (strace_marker_create_sals_from_location, trace_command)
2731 (ftrace_command, strace_command, struct tracepoint): Constify.
2732 * ax-gdb.c (agent_command_1): Constify.
2733 * ada-lang.c (ada_exception_sal): Constify.
2734
2735 2017-09-27 Tom Tromey <tom@tromey.com>
2736
2737 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
2738 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
2739 (get_context_size, no_chunk, get_insn_history_modifiers)
2740 (cmd_record_insn_history, get_call_history_modifiers)
2741 (cmd_record_call_history): Constify.
2742
2743 2017-09-27 Tom Tromey <tom@tromey.com>
2744
2745 * source.c (show_substitute_path_command)
2746 (unset_substitute_path_command, set_substitute_path_command):
2747 Constify.
2748
2749 2017-09-27 Tom Tromey <tom@tromey.com>
2750
2751 * typeprint.c (maintenance_print_type): Constify.
2752 * maint.c (maintenance_dump_me, maintenance_demangle)
2753 (maintenance_time_display, maintenance_info_sections)
2754 (maintenance_print_statistics, maintenance_deprecate)
2755 (maintenance_undeprecate): Constify.
2756 (maintenance_do_deprecate): Constify. Use std::string.
2757 (maintenance_selftest): Constify.
2758 * gdbtypes.h (maintenance_print_type): Constify.
2759
2760 2017-09-27 Tom Tromey <tom@tromey.com>
2761
2762 * hppa-tdep.c (unwind_command): Constify.
2763
2764 2017-09-27 Tom Tromey <tom@tromey.com>
2765
2766 * target-descriptions.c (unset_tdesc_filename_cmd)
2767 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
2768 Constify.
2769
2770 2017-09-27 Tom Tromey <tom@tromey.com>
2771
2772 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
2773
2774 2017-09-27 Tom Tromey <tom@tromey.com>
2775
2776 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
2777
2778 2017-09-27 Tom Tromey <tom@tromey.com>
2779
2780 * tui/tui-regs.c (tui_reg_command): Constify.
2781
2782 2017-09-27 Tom Tromey <tom@tromey.com>
2783
2784 * skip.c (skip_file_command, skip_function_command)
2785 (skip_enable_command, skip_disable_command, skip_delete_command):
2786 Constify.
2787
2788 2017-09-27 Tom Tromey <tom@tromey.com>
2789
2790 * record-btrace.c (cmd_record_btrace_bts_start)
2791 (cmd_record_btrace_pt_start): Constify.
2792
2793 2017-09-27 Tom Tromey <tom@tromey.com>
2794
2795 * symmisc.c (maintenance_print_symbols)
2796 (maintenance_print_msymbols, maintenance_print_objfiles)
2797 (maintenance_info_symtabs, maintenance_check_symtabs)
2798 (maintenance_expand_symtabs, maintenance_info_line_tables):
2799 Constify.
2800
2801 2017-09-27 Tom Tromey <tom@tromey.com>
2802
2803 * top.c (new_ui_command): Constify.
2804
2805 2017-09-27 Tom Tromey <tom@tromey.com>
2806
2807 * symfile.c (add_symbol_file_command)
2808 (remove_symbol_file_command, list_overlays_command)
2809 (map_overlay_command, unmap_overlay_command)
2810 (overlay_auto_command, overlay_manual_command)
2811 (overlay_off_command, overlay_load_command): Constify.
2812
2813 2017-09-27 Tom Tromey <tom@tromey.com>
2814
2815 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
2816 (info_spu_mailbox_command, info_spu_dma_command)
2817 (info_spu_proxydma_command): Constify.
2818
2819 2017-09-27 Tom Tromey <tom@tromey.com>
2820
2821 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
2822
2823 2017-09-27 Tom Tromey <tom@tromey.com>
2824
2825 * cli/cli-script.c (user_defined_command): Constify.
2826
2827 2017-09-27 Tom Tromey <tom@tromey.com>
2828
2829 * cli/cli-dump.c (dump_memory_command, dump_value_command)
2830 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
2831 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
2832 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
2833 (dump_binary_value, append_binary_memory, append_binary_value):
2834 Constify.
2835 (struct dump_context) <func>: Constify.
2836 (add_dump_command): Update.
2837
2838 2017-09-27 Tom Tromey <tom@tromey.com>
2839
2840 * cli/cli-cmds.c (show_version, show_configuration)
2841 (source_command, show_user): Constify.
2842
2843 2017-09-27 Tom Tromey <tom@tromey.com>
2844
2845 * target.c (maintenance_print_target_stack): Constify.
2846
2847 2017-09-27 Tom Tromey <tom@tromey.com>
2848
2849 * interps.c (interpreter_exec_cmd): Constify.
2850
2851 2017-09-27 Tom Tromey <tom@tromey.com>
2852
2853 * record-full.c (cmd_record_full_restore): Constify.
2854
2855 2017-09-27 Tom Tromey <tom@tromey.com>
2856
2857 * memattr.c (enable_mem_command, disable_mem_command)
2858 (delete_mem_command): Constify.
2859
2860 2017-09-27 Tom Tromey <tom@tromey.com>
2861
2862 * value.c (show_convenience): Constify.
2863
2864 2017-09-27 Tom Tromey <tom@tromey.com>
2865
2866 * gdbcore.h (core_file_command): Update.
2867 * corefile.c (core_file_command): Constify.
2868
2869 2017-09-27 Tom Tromey <tom@tromey.com>
2870
2871 * user-regs.c (maintenance_print_user_registers): Constify.
2872
2873 2017-09-27 Tom Tromey <tom@tromey.com>
2874
2875 * cp-namespace.c (maintenance_cplus_namespace): Constify.
2876
2877 2017-09-27 Tom Tromey <tom@tromey.com>
2878
2879 * cp-support.c (first_component_command): Constify.
2880
2881 2017-09-27 Tom Tromey <tom@tromey.com>
2882
2883 * psymtab.c (maintenance_print_psymbols)
2884 (maintenance_info_psymtabs, maintenance_check_psymtabs):
2885 Constify.
2886
2887 2017-09-27 Tom Tromey <tom@tromey.com>
2888
2889 * windows-tdep.c (display_tib): Constify.
2890
2891 2017-09-27 Tom Tromey <tom@tromey.com>
2892
2893 * linux-fork.c (delete_checkpoint_command)
2894 (detach_checkpoint_command): Constify.
2895
2896 2017-09-27 Tom Tromey <tom@tromey.com>
2897
2898 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
2899
2900 2017-09-27 Tom Tromey <tom@tromey.com>
2901
2902 * arc-tdep.c (dump_arc_instruction_command): Constify.
2903
2904 2017-09-27 Tom Tromey <tom@tromey.com>
2905
2906 * valprint.c (set_radix, show_radix): Constify.
2907
2908 2017-09-27 Tom Tromey <tom@tromey.com>
2909
2910 * dtrace-probe.c (info_probes_dtrace_command): Constify.
2911
2912 2017-09-27 Tom Tromey <tom@tromey.com>
2913
2914 * command.h (not_just_help_class_command): Update.
2915 * cli/cli-decode.h (not_just_help_class_command): Update.
2916 * cli/cli-decode.c (not_just_help_class_command): Constify.
2917
2918 2017-09-27 Tom Tromey <tom@tromey.com>
2919
2920 * gdb_bfd.c (maintenance_info_bfds): Constify.
2921
2922 2017-09-27 Tom Tromey <tom@tromey.com>
2923
2924 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
2925 overloads.
2926 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
2927 (do_const_cfunc): New function.
2928 (cmd_cfunc_eq): New overload.
2929 (cli_user_command_p): Check do_const_cfunc.
2930 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
2931 const_cfunc.
2932 * command.h (add_cmd): Add const overload and no-function
2933 overload.
2934 (set_cmd_cfunc): Add const overload.
2935 (cmd_const_cfunc_ftype): Declare.
2936 (cmd_cfunc_eq): Add const overload.
2937 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
2938 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
2939 overload.
2940
2941 2017-09-27 Tom Tromey <tom@tromey.com>
2942
2943 * macroexp.c (get_next_token_for_substitution): New function.
2944 (substitute_args): Call it. Check for __VA_OPT__.
2945
2946 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
2947 Pedro Alves <palves@redhat.com>
2948
2949 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
2950 producer_is_icc_lt_14.
2951 (producer_is_icc_lt_14): New function.
2952 (check_producer): Add code for checking version of ICC.
2953 (producer_is_icc): Move to producer.c.
2954 (read_structure_type): Restrict ICC workaround to ICC<14.
2955 * producer.c: Include selftest.h.
2956 (producer_is_icc, producer_parsing_tests, _initialize_producer):
2957 New functions.
2958 * producer.h (producer_is_icc): New declaration.
2959
2960 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
2961
2962 * Makefile.in (SFILES): Add producer.c.
2963 (COMMON_OBS): Add producer.o
2964 * amd64-tdep.c (producer.h): Add new include.
2965 * dwarf2read.c (producer.h): Add new include.
2966 * producer.c: New file.
2967 * producer.h: New file.
2968 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
2969 producer.c.
2970 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
2971 producer.h.
2972
2973 2017-09-26 Matthias Klose <doko@ubuntu.com>
2974
2975 * configure.ac: Search ncursesw before ncurses.
2976 Check ncursesw/ncurses.h before ncurses/ncurses.h.
2977 * gdb_curses.h: Include <ncursesw/ncurses.h>
2978 * config.in, configure: Regenerate.
2979
2980 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2981
2982 PR gdb/22185
2983 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
2984 obsolete.
2985 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
2986 Remove i386sol2 support.
2987 * configure.nat <i386sol2>: Remove.
2988 <sol2-64>: Fold into ...
2989 <sol2>: ... this.
2990 Move common settings to default section.
2991 Add sol-thread.o.
2992 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
2993 x86_64-*-solaris2.1[0-9]*>: Rename to ...
2994 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
2995 <i[34567]86-*-solaris*>: Remove.
2996 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
2997
2998 * configure.ac: Remove wctype in libw check.
2999 (_MSE_INT_H): Don't define on Solaris 7-9.
3000 <solaris*>: Remove libthread_db.so.1 check.
3001 * configure: Regenerate.
3002 * config.in: Regenerate.
3003
3004 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
3005 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
3006 (gdb_ps_size_t): Remove.
3007 Use base types in users.
3008 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
3009
3010 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
3011
3012 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3013
3014 PR build/22206
3015 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
3016 (adi_is_addr_mapped): Likewise.
3017 (PSR_ICC): Don't redefine.
3018 (PSR_IMPL): Likewise.
3019
3020 2017-09-25 Tom Tromey <tom@tromey.com>
3021
3022 * regcache.c (regcache::dump): Use string_printf.
3023
3024 2017-09-25 Tom Tromey <tom@tromey.com>
3025
3026 * regcache.c (class regcache_invalidator): New.
3027 (struct register_to_invalidate): Remove.
3028 (make_cleanup_regcache_invalidate): Remove.
3029 (regcache::raw_write): Use regcache_invalidator.
3030
3031 2017-09-25 Tom Tromey <tom@tromey.com>
3032
3033 * spu-tdep.c (spu2ppu_sniffer): Update.
3034 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
3035 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
3036 Remove.
3037 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
3038 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
3039 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
3040 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
3041 (frame_pop): Update.
3042
3043 2017-09-25 Tom Tromey <tom@tromey.com>
3044
3045 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
3046 * regcache.h (regcache_xfree): Don't declare.
3047 * regcache.c (regcache_xfree): Remove.
3048 (do_regcache_xfree): Use delete.
3049 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
3050 * linux-fork.c (free_fork): Use delete.
3051 (fork_save_infrun_state): Likewise.
3052 * jit.c (jit_dealloc_cache): Use delete.
3053 * infrun.c (discard_infcall_suspend_state): Use delete.
3054
3055 2017-09-25 Tom Tromey <tom@tromey.com>
3056
3057 * regcache.h (regcache_xmalloc): Don't declare.
3058 (regcache_raw_set_cached_value): Update comment.
3059 * regcache.c (regcache_xmalloc): Remove.
3060 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
3061 * jit.c (jit_frame_sniffer): Use new.
3062 * frame.c (frame_save_as_regcache): Use new.
3063
3064 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
3065
3066 * NEWS: Advertise support for guarded-storage registers on IBM z.
3067
3068 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
3069
3070 * s390-linux-nat.c (have_regset_gs): New static variable.
3071 (s390_linux_fetch_inferior_registers): Handle guarded-storage
3072 control block and guarded-storage broadcast control regsets.
3073 (s390_read_description): Detect whether the target has
3074 guarded-storage support, return appropriate tdesc.
3075 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
3076 (features/s390x-gs-linux64.c): Likewise.
3077 (struct gdbarch_tdep) <have_gs>: New field.
3078 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
3079 (s390_gsbc_regset): New variables.
3080 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
3081 and s390_gsbc_regset, if applicable.
3082 (s390_core_read_description): Check whether core file was from a
3083 target with guarded-storage support; include appropriate regsets.
3084 (s390_gdbarch_init): Add registers for guarded-storage support.
3085 (_initialize_s390_tdep): Initialize new target descriptions that
3086 include registers for guarded-storage support.
3087 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
3088 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
3089 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
3090 (S390_NUM_REGS): Adjust macro definition.
3091 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
3092 (tdesc_s390x_gs_linux64): New declarations.
3093
3094 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
3095
3096 * features/s390-gs-linux64.xml: New file.
3097 * features/s390-gs.xml: New file.
3098 * features/s390-gsbc.xml: New file.
3099 * features/s390x-gs-linux64.xml: New file.
3100 * features/Makefile (WHICH): Add s390-gs-linux64 and
3101 s390x-gs-linux64.
3102 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
3103 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
3104 * features/s390-gs-linux64.c: New generated file.
3105 * features/s390x-gs-linux64.c: New file.
3106 * regformats/s390-gs-linux64.dat: New file.
3107 * regformats/s390x-gs-linux64.dat: New file.
3108
3109 2017-09-23 Tom Tromey <tom@tromey.com>
3110
3111 * defs.h (make_cleanup_override_quit_handler): Don't declare.
3112
3113 2017-09-22 Tom Tromey <tom@tromey.com>
3114
3115 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
3116 type to scoped_restore_tmpl.
3117 <scoped_input_handler>: Initialize m_quit_handler directly.
3118
3119 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
3120
3121 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
3122 (cd_command): Likewise. Free "current_directory" before
3123 assigning to it.
3124 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
3125 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
3126 * top.c (gdb_dirbuf): Remove global declaration.
3127 * top.h (gdb_dirbuf): Likewise.
3128
3129 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
3130
3131 * gnulib/aclocal.m4: Regenerate.
3132 * gnulib/config.in: Regenerate.
3133 * gnulib/configure: Regenerate.
3134 * gnulib/import/Makefile.am: Regenerate.
3135 * gnulib/import/Makefile.in: Regenerate.
3136 * gnulib/import/assure.h: New file.
3137 * gnulib/import/at-func.c: Likewise
3138 * gnulib/import/chdir-long.c: New file.
3139 * gnulib/import/chdir-long.h: New file.
3140 * gnulib/import/cloexec.c: New file.
3141 * gnulib/import/cloexec.h: New file.
3142 * gnulib/import/close.c: New file.
3143 * gnulib/import/closedir.c: New file.
3144 * gnulib/import/dirent-private.h: New file.
3145 * gnulib/import/dup-safer.c: New file.
3146 * gnulib/import/dup.c: New file.
3147 * gnulib/import/dup2.c: New file.
3148 * gnulib/import/error.c: New file.
3149 * gnulib/import/error.h: New file.
3150 * gnulib/import/exitfail.c: New file.
3151 * gnulib/import/exitfail.h: New file.
3152 * gnulib/import/fchdir.c: New file.
3153 * gnulib/import/fcntl.c: New file.
3154 * gnulib/import/fcntl.in.h: New file.
3155 * gnulib/import/fd-hook.c: New file.
3156 * gnulib/import/fd-hook.h: New file.
3157 * gnulib/import/fd-safer.c: New file.
3158 * gnulib/import/fdopendir.c: New file.
3159 * gnulib/import/filename.h: New file.
3160 * gnulib/import/filenamecat-lgpl.c: New file.
3161 * gnulib/import/filenamecat.h: New file.
3162 * gnulib/import/fstat.c: New file.
3163 * gnulib/import/fstatat.c: New file.
3164 * gnulib/import/getcwd-lgpl.c: New file.
3165 * gnulib/import/getcwd.c: New file.
3166 * gnulib/import/getdtablesize.c: New file.
3167 * gnulib/import/getlogin_r.c: New file.
3168 * gnulib/import/getprogname.c: New file.
3169 * gnulib/import/getprogname.h: New file.
3170 * gnulib/import/gettext.h: New file.
3171 * gnulib/import/glob-libc.h: New file.
3172 * gnulib/import/glob.c: New file.
3173 * gnulib/import/glob.in.h: New file.
3174 * gnulib/import/intprops.h: New file.
3175 * gnulib/import/m4/chdir-long.m4: New file.
3176 * gnulib/import/m4/close.m4: New file.
3177 * gnulib/import/m4/closedir.m4: New file.
3178 * gnulib/import/m4/d-ino.m4: New file.
3179 * gnulib/import/m4/d-type.m4: New file.
3180 * gnulib/import/m4/dup.m4: New file.
3181 * gnulib/import/m4/dup2.m4: New file.
3182 * gnulib/import/m4/error.m4: New file.
3183 * gnulib/import/m4/fchdir.m4: New file.
3184 * gnulib/import/m4/fcntl.m4: New file.
3185 * gnulib/import/m4/fcntl_h.m4: New file.
3186 * gnulib/import/m4/fdopendir.m4: New file.
3187 * gnulib/import/m4/filenamecat.m4: New file.
3188 * gnulib/import/m4/fstat.m4: New file.
3189 * gnulib/import/m4/fstatat.m4: New file.
3190 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
3191 * gnulib/import/m4/getcwd-path-max.m4: New file.
3192 * gnulib/import/m4/getcwd.m4: New file.
3193 * gnulib/import/m4/getdtablesize.m4: New file.
3194 * gnulib/import/m4/getlogin_r.m4: New file.
3195 * gnulib/import/m4/getprogname.m4: New file.
3196 * gnulib/import/m4/glob.m4: New file.
3197 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
3198 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
3199 * gnulib/import/m4/mempcpy.m4: New file.
3200 * gnulib/import/m4/memrchr.m4: New file.
3201 * gnulib/import/m4/mode_t.m4: New file.
3202 * gnulib/import/m4/msvc-inval.m4: New file.
3203 * gnulib/import/m4/msvc-nothrow.m4: New file.
3204 * gnulib/import/m4/open.m4: New file.
3205 * gnulib/import/m4/openat.m4: New file.
3206 * gnulib/import/m4/opendir.m4: New file.
3207 * gnulib/import/m4/readdir.m4: New file.
3208 * gnulib/import/m4/realloc.m4: New file.
3209 * gnulib/import/m4/rewinddir.m4: New file.
3210 * gnulib/import/m4/save-cwd.m4: New file.
3211 * gnulib/import/m4/strdup.m4: New file.
3212 * gnulib/import/m4/strerror.m4: New file.
3213 * gnulib/import/m4/unistd-safer.m4: New file.
3214 * gnulib/import/mempcpy.c: New file.
3215 * gnulib/import/memrchr.c: New file.
3216 * gnulib/import/msvc-inval.c: New file.
3217 * gnulib/import/msvc-inval.h: New file.
3218 * gnulib/import/msvc-nothrow.c: New file.
3219 * gnulib/import/msvc-nothrow.h: New file.
3220 * gnulib/import/open.c: New file.
3221 * gnulib/import/openat-die.c: New file.
3222 * gnulib/import/openat-priv.h: New file.
3223 * gnulib/import/openat-proc.c: New file.
3224 * gnulib/import/openat.c: New file.
3225 * gnulib/import/openat.h: New file.
3226 * gnulib/import/opendir.c: New file.
3227 * gnulib/import/pipe-safer.c: New file.
3228 * gnulib/import/readdir.c: New file.
3229 * gnulib/import/realloc.c: New file.
3230 * gnulib/import/rewinddir.c: New file.
3231 * gnulib/import/save-cwd.c: New file.
3232 * gnulib/import/save-cwd.h: New file.
3233 * gnulib/import/strdup.c: New file.
3234 * gnulib/import/strerror-override.c: New file.
3235 * gnulib/import/strerror-override.h: New file.
3236 * gnulib/import/strerror.c: New file.
3237 * gnulib/import/unistd--.h: New file.
3238 * gnulib/import/unistd-safer.h: New file.
3239 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
3240 "getcwd" and "glob".
3241 * ser-tcp.c: Undefine "close" before redefining it.
3242
3243 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
3244
3245 * guile/scm-value.c (gdbscm_value_address): Initialize address,
3246 get rid of res_val.
3247
3248 2017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3249
3250 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
3251 <sol2,sparc>: Likewise.
3252 <sol2-64,i386>: Likewise.
3253
3254 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
3255 -Wdeprecated-declarations on *-*-solaris*.
3256 * configure: Regenerate.
3257
3258 * procfs.c: Include "nat/inferior.h".
3259 (procfs_info_proc): Fix typo.
3260
3261 2017-09-21 Kevin Buettner <kevinb@redhat.com>
3262
3263 * remote.c (vector): Include.
3264 (struct private_thread_info): Add field, thread_handle.
3265 (free_private_thread_info): Deallocate storage associated with
3266 thread handle.
3267 (get_private_info_thread): Initialize `thread_handle' field.
3268 (struct thread_item): Add field, thread_handle.
3269 (clear_threads_listing_context): Deallocate storage associated
3270 with thread handle.
3271 (start_thread): Add support for "handle" attribute.
3272 (thread_attributes): Add "handle".
3273 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
3274 field.
3275 (remote_update_thread_list): Update thread_handle.
3276 (remote_thread_handle_to_thread_info): New function.
3277 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
3278
3279 2017-09-21 Kevin Buettner <kevinb@redhat.com>
3280
3281 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
3282 function.
3283 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
3284 * python/python-internal.h (thread_object_type): Declare.
3285
3286 2017-09-21 Kevin Buettner <kevinb@redhat.com>
3287
3288 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
3289 (target_thread_handle_to_thread_info): Declare.
3290 * target.c (target_thread_handle_to_thread_info): New function.
3291 * target-delegates.c: Regenerate.
3292 * gdbthread.h (find_thread_by_handle): Declare.
3293 * thread.c (find_thread_by_handle): New function.
3294 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
3295 function.
3296 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
3297
3298 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
3299
3300 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
3301
3302 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
3303
3304 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
3305
3306 2017-09-21 Yao Qi <yao.qi@linaro.org>
3307
3308 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
3309 to gdb_target_obs.
3310
3311 2017-09-20 Tom Tromey <tom@tromey.com>
3312
3313 * breakpoint.c (struct counted_command_line): Remove.
3314 (breakpoint_commands): Update.
3315 (alloc_counted_command_line, incref_counted_command_line)
3316 (decref_counted_command_line, do_cleanup_counted_command_line)
3317 (make_cleanup_decref_counted_command_line): Remove.
3318 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
3319 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
3320 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
3321 (save_breakpoints): Update.
3322 * breakpoint.h (counted_command_line): Now a typedef to
3323 shared_ptr.
3324 (struct breakpoint) <commands>: Now a counted_command_line.
3325 (struct bpstats) <command>: Likewise.
3326
3327 2017-09-20 Tom Tromey <tom@tromey.com>
3328
3329 * breakpoint.c (struct commands_info, do_map_commands_command):
3330 Remove.
3331 (commands_command_1): Update.
3332 (iterate_over_related_breakpoints): Take a function_view.
3333 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
3334 (delete_command): Update.
3335 (map_breakpoint_numbers): Take a function_view.
3336 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
3337 (disable_command): Update.
3338 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
3339 (enable_command): Update.
3340 (struct disp_data, do_enable_breakpoint_disp)
3341 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
3342 (do_map_enable_delete_breakpoint): Remove.
3343 (enable_once_command, enable_count_command, enable_delete_command)
3344 (delete_trace_variable_command): Update.
3345
3346 2017-09-20 Tom Tromey <tom@tromey.com>
3347
3348 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
3349 (bpstat_clear): Use delete.
3350 (bpstats): New constructors.
3351 (bpstat_copy, bpstat_stop_status): Use new.
3352 (dprintf_after_condition_true): Update.
3353 * breakpoint.h (bpstats::bpstats): Add constructors.
3354 (bpstats::~bpstats): Add destructor.
3355
3356 2017-09-20 Pedro Alves <palves@redhat.com>
3357
3358 * eval.c (make_params): Delete, refactored as ...
3359 (class fake_method): ... this new type's ctor.
3360 (fake_method::~fake_method): New.
3361 (evaluate_subexp_standard): Use 'fake_method'.
3362
3363 2017-09-20 Tom Tromey <tom@tromey.com>
3364
3365 * windows-nat.c (get_windows_debug_event, windows_wait)
3366 (do_initial_windows_stuff, windows_attach): Update.
3367 * utils.c (vwarning, internal_vproblem): Update.
3368 (ui_unregister_input_event_handler_cleanup)
3369 (prepare_to_handle_input): Remove.
3370 (class scoped_input_handler): New.
3371 (defaulted_query, prompt_for_continue): Update.
3372 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
3373 Update.
3374 * top.c (undo_terminal_modifications_before_exit): Update.
3375 * target/target.h (target_terminal_init, target_terminal_inferior)
3376 (target_terminal_ours): Don't declare.
3377 (class target_terminal): New.
3378 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
3379 (target_terminal_ours_for_output)
3380 (make_cleanup_restore_target_terminal): Don't declare.
3381 (target_terminal_info): Remove.
3382 * target.c (enum terminal_state, terminal_state): Remove.
3383 (target_terminal::terminal_state): Define.
3384 (target_terminal::init): Rename from target_terminal_init.
3385 (target_terminal::inferior): Rename from
3386 target_terminal_inferior.
3387 (target_terminal::ours): Rename from target_terminal_ours.
3388 (target_terminal::ours_for_output): Rename from
3389 target_terminal_ours_for_output.
3390 (target_terminal::info): New method.
3391 (cleanup_restore_target_terminal)
3392 (make_cleanup_restore_target_terminal): Remove.
3393 * solib.c (handle_solib_event): Update.
3394 * remote.c (remote_serial_quit_handler): Update.
3395 (remote_terminal_inferior, remote_wait_as): Update.
3396 * record-full.c (record_full_wait_1): Update.
3397 * nto-procfs.c (procfs_create_inferior): Update.
3398 * nat/fork-inferior.c (startup_inferior): Update.
3399 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
3400 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
3401 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
3402 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
3403 (mi_breakpoint_created, mi_breakpoint_deleted)
3404 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
3405 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
3406 (mi_user_selected_context_changed, report_initial_inferior):
3407 Update.
3408 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
3409 (linux_nat_terminal_inferior): Update.
3410 * infrun.c (follow_fork_inferior)
3411 (handle_vfork_child_exec_or_exit, do_target_resume)
3412 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
3413 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
3414 Update.
3415 * inflow.c (child_terminal_init, info_terminal_command): Update.
3416 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
3417 (attach_command): Update.
3418 * infcall.c (call_thread_fsm_should_stop): Update.
3419 * gnu-nat.c (gnu_attach): Update.
3420 * extension.c (struct active_ext_lang_state)
3421 (restore_active_ext_lang): Update.
3422 * exceptions.c (print_flush): Update.
3423 * event-top.c (async_enable_stdin, default_quit_handler): Update.
3424 (struct quit_handler_cleanup_data, restore_quit_handler)
3425 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
3426 Remove.
3427 * cp-support.c (gdb_demangle): Update.
3428 * breakpoint.c (update_inserted_breakpoint_locations)
3429 (insert_breakpoint_locations, handle_jit_event)
3430 (disable_breakpoints_in_unloaded_shlib): Update.
3431 * annotate.c (annotate_breakpoints_invalid)
3432 (annotate_frames_invalid): Update.
3433
3434 2017-09-20 Tom Tromey <tom@tromey.com>
3435
3436 * main.c (catch_command_errors): Rename from
3437 catch_command_errors_const.
3438 (captured_main_1): Update.
3439
3440 2017-09-20 Pedro Alves <palves@redhat.com>
3441
3442 * cli/cli-cmds.c (list_command): Use print_sal_location.
3443 (print_sal_location): New function.
3444 (ambiguous_line_spec): Use print_sal_location.
3445 * linespec.c (symbol_to_sal): Record the symbol in the sal.
3446 * symtab.c (find_function_start_sal): Likewise.
3447 * symtab.h (symtab_and_line::symbol): New field.
3448
3449 2017-09-20 Pedro Alves <palves@redhat.com>
3450
3451 * linespec.c (minsym_found): Handle non-text minsyms.
3452 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
3453
3454 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
3455
3456 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
3457 backslash.
3458
3459 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
3460
3461 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
3462 vmovups instead vmovaps.
3463 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
3464
3465 2017-09-19 John Baldwin <jhb@FreeBSD.org>
3466
3467 * NEWS (Changes since GDB 8.0): Add starti.
3468 * infcmd.c (enum run_break): New.
3469 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
3470 case.
3471 (run_command): Use enum run_how.
3472 (start_command): Likewise.
3473 (starti_command): New function.
3474 (RUN_ARGS_HELP): New macro.
3475 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
3476 commands. Add starti command.
3477
3478 2017-09-19 Yao Qi <yao.qi@linaro.org>
3479
3480 * Makefile.in (monitor.o): Remove the rule.
3481
3482 2017-09-19 Yao Qi <yao.qi@linaro.org>
3483
3484 * annotate.h (struct annotate_arg_emitter): Use
3485 DISABLE_COPY_AND_ASSIGN.
3486 * common/refcounted-object.h (refcounted_object): Likewise.
3487 * completer.h (struct completion_result): Likewise.
3488 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
3489 * filename-seen-cache.h (filename_seen_cache): Likewise.
3490 * gdbcore.h (thread_section_name): Likewise.
3491 * gdb_regex.h (compiled_regex): Likewise.
3492 * gdbthread.h (scoped_restore_current_thread): Likewise.
3493 * inferior.h (scoped_restore_current_inferior): Likewise.
3494 * jit.c (jit_reader): Likewise.
3495 * linespec.h (struct linespec_result): Likewise.
3496 * mi/mi-parse.h (struct mi_parse): Likewise.
3497 * nat/fork-inferior.c (execv_argv): Likewise.
3498 * progspace.h (scoped_restore_current_program_space): Likewise.
3499 * python/python-internal.h (class gdbpy_enter): Likewise.
3500 * regcache.h (regcache): Likewise.
3501 * target-descriptions.c (struct tdesc_reg): Likewise.
3502 (struct tdesc_type): Likewise.
3503 (struct tdesc_feature): Likewise.
3504 * ui-out.h (ui_out_emit_type): Likewise.
3505
3506 2017-09-18 Simon Marchi <simon.marchi@ericsson.com>
3507
3508 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
3509 label abort_expression.
3510
3511 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3512
3513 * common/buffer.c (buffer_xml_printf): Adjust.
3514 * common/xml-utils.c (xml_escape_text): Change return type to
3515 std::string, update code accordingly.
3516 * common/xml-utils.h (xml_escape_text): Change return type to
3517 std::string.
3518 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
3519 * windows-tdep.c (windows_xfer_shared_library): Adjust.
3520 * unittests/xml-utils-selftests.c (test_xml_escape_text):
3521 Adjust.
3522
3523 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3524
3525 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
3526 (SUBDIR_UNITTESTS_OBS): Add new object file.
3527 * unittests/xml-utils-selftests.c: New file.
3528
3529 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3530
3531 * common/selftest.h (selftest): New struct/interface.
3532 (register_test): Add name parameter, add new overload.
3533 (run_tests): Add filter parameter.
3534 (for_each_selftest_ftype): New typedef.
3535 (for_each_selftest): New declaration.
3536 * common/selftest.c (tests): Change type to
3537 map<string, unique_ptr<selftest>>.
3538 (simple_selftest): New struct.
3539 (register_test): New function.
3540 (register_test): Add name parameter and use it.
3541 (run_tests): Add filter parameter and use it. Add prints.
3542 Adjust to vector -> map change.
3543 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
3544 registering selftests.
3545 * arm-tdep.c (_initialize_arm_tdep): Likewise.
3546 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
3547 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
3548 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
3549 * findvar.c (_initialize_findvar): Likewise.
3550 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
3551 * maint.c (maintenance_selftest): Update call to run_tests.
3552 (maintenance_info_selftests): New function.
3553 (_initialize_maint_cmds): Register "maintenance info selftests"
3554 command. Update "maintenance selftest" doc.
3555 * regcache.c (_initialize_regcache): Add names when registering
3556 selftests.
3557 * rust-exp.y (_initialize_rust_exp): Likewise.
3558 * selftest-arch.c (gdbarch_selftest): New struct.
3559 (gdbarch_tests): Remove.
3560 (register_test_foreach_arch): Add name parameter. Call
3561 register_test.
3562 (tests_with_arch): Remove, move most content to
3563 gdbarch_selftest::operator().
3564 (_initialize_selftests_foreach_arch): Remove.
3565 * selftest-arch.h (register_test_foreach_arch): Add name
3566 parameter.
3567 (run_tests_with_arch): New declaration.
3568 * utils-selftests.c (_initialize_utils_selftests): Add names
3569 when registering selftests.
3570 * utils.c (_initialize_utils): Likewise.
3571 * unittests/array-view-selftests.c
3572 (_initialize_array_view_selftests): Likewise.
3573 * unittests/environ-selftests.c (_initialize_environ_selftests):
3574 Likewise.
3575 * unittests/function-view-selftests.c
3576 (_initialize_function_view_selftests): Likewise.
3577 * unittests/offset-type-selftests.c
3578 (_initialize_offset_type_selftests): Likewise.
3579 * unittests/optional-selftests.c
3580 (_initialize_optional_selftests): Likewise.
3581 * unittests/scoped_restore-selftests.c
3582 (_initialize_scoped_restore_selftests): Likewise.
3583 * NEWS: Document "maintenance selftest" and "maint info
3584 selftests".
3585
3586 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3587
3588 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
3589 scoped_restore.
3590
3591 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3592
3593 * mi/mi-main.c (mi_load_progress): Make uiout variable
3594 a unique_ptr.
3595
3596 2017-09-15 Pedro Alves <palves@redhat.com>
3597
3598 * compile/compile-c-types.c (convert_enum, convert_int)
3599 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
3600
3601 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3602
3603 * dwarf2read.c (copy_string): Remove.
3604 (parse_macro_definition): Replace copy_string with savestring.
3605
3606 2017-09-15 Yao Qi <yao.qi@linaro.org>
3607
3608 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
3609 gdb_target_obs.
3610 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
3611 Likewise.
3612 (i[34567]86-*-linux*): Likewise.
3613
3614 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
3615
3616 * dwarf2expr.h (dwarf_stack_value): Add constructor.
3617 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
3618 <stack>: Change type to std::vector.
3619 <stack_len, stack_allocated>: Remove.
3620 <grow_stack>: Remove.
3621 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
3622 (dwarf_expr_context::~dwarf_expr_context): Remove.
3623 (dwarf_expr_context::grow_stack): Remove.
3624 (dwarf_expr_context::push): Adjust.
3625 (dwarf_expr_context::pop): Adjust.
3626 (dwarf_expr_context::fetch): Adjust.
3627 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
3628 (dwarf_expr_context::stack_empty_p): Adjust.
3629 (dwarf_expr_context::execute_stack_op): Adjust.
3630
3631 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
3632
3633 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
3634 return type to bool.
3635 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
3636
3637 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
3638
3639 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
3640 Change type to bool.
3641 (dwarf_stack_value) <in_stack_memory>: Likewise.
3642 (dwarf_expr_context) <push_address>: Change parameter type to
3643 bool.
3644 <fetch_in_stack_memory>: Change return type to bool.
3645 <push>: Change parameter type to bool.
3646 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
3647 to bool.
3648 (dwarf_expr_context::push_address): Likewise.
3649 (dwarf_expr_context::fetch_in_stack_memory): Change return type
3650 to bool.
3651 (dwarf_expr_context::execute_stack_op): Adjust.
3652 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
3653
3654 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
3655
3656 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
3657 (struct dwarf_expr_context) <n_pieces>: Remove.
3658 <pieces>: Change type to std::vector.
3659 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
3660 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
3661 pieces.
3662 (dwarf_expr_context::add_piece): Adjust.
3663 * dwarf2loc.c (struct piece_closure): Initialize fields.
3664 <n_pieces>: Remove.
3665 <pieces>: Change type to std::vector.
3666 (allocate_piece_closure): Adjust, change parameter to
3667 std::vector rvalue and std::move it to piece_closure.
3668 (rw_pieced_value): Adjust.
3669 (check_pieced_synthetic_pointer): Adjust.
3670 (indirect_synthetic_pointer): Adjust.
3671 (coerce_pieced_ref): Adjust.
3672 (free_pieced_value_closure): Adjust. Use delete to free
3673 piece_closure.
3674 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
3675 to allocate_piece_closure.
3676 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
3677
3678 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
3679
3680 * probe.h (probe_ops_cp): Remove typedef.
3681 (DEF_VEC_P (probe_ops_cp)): Remove.
3682 (all_probe_ops): Change type to std::vector.
3683 * probe.c (info_probes_for_ops): Adjust to vector change.
3684 (probe_linespec_to_ops): Likewise.
3685 (all_probe_ops): Change type to std::vector.
3686 (_initialize_probe): Adjust to vector change.
3687 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
3688 * elfread.c (elf_get_probes): Likewise.
3689 * stap-probe.c (_initialize_stap_probe): Likewise.
3690
3691 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
3692
3693 * probe.h (struct bound_probe): Define constructors.
3694 * probe.c (bound_probe_s): Remove typedef.
3695 (DEF_VEC_O (bound_probe_s)): Remove VEC.
3696 (collect_probes): Change return type to std::vector, remove
3697 cleanup.
3698 (compare_probes): Return bool, change parameter type. Change
3699 semantic to "less than".
3700 (gen_ui_out_table_header_info): Change parameter to std::vector
3701 and update.
3702 (exists_probe_with_pops): Likewise.
3703 (info_probes_for_ops): Update to std::vector change.
3704 (enable_probes_command): Likewise.
3705 (disable_probes_command): Likewise.
3706
3707 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
3708
3709 * probe.h (struct probe_ops) <get_probes>: Change parameter from
3710 vec to std::vector.
3711 * probe.c (parse_probes_in_pspace): Update.
3712 (find_probes_in_objfile): Update.
3713 (find_probe_by_pc): Update.
3714 (collect_probes): Update.
3715 (probe_any_get_probes): Update.
3716 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
3717 return type to reference to std::vector.
3718 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
3719 std::vector and update.
3720 (dtrace_process_dof): Likewise.
3721 (dtrace_get_probes): Likewise.
3722 * elfread.c (elf_get_probes): Change return type to std::vector,
3723 store an std::vector in bfd_data.
3724 (probe_key_free): Update to std::vector.
3725 * stap-probe.c (handle_stap_probe): Change parameter to
3726 std::vector and update.
3727 (stap_get_probes): Likewise.
3728 * symfile-debug.c (debug_sym_get_probes): Change return type to
3729 std::vector and update.
3730
3731 2017-09-11 Tom Tromey <tom@tromey.com>
3732
3733 * breakpoint.c (program_breakpoint_here_p): Update.
3734 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
3735 from make_show_memory_breakpoints_cleanup. Return a
3736 scoped_restore_tmpl<int>.
3737 (restore_show_memory_breakpoints): Remove.
3738 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
3739 * mem-break.c (memory_validate_breakpoint): Update.
3740 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
3741 (ia64_memory_remove_breakpoint): Update.
3742 (ia64_breakpoint_from_pc): Update.
3743 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
3744 from make_show_memory_breakpoints_cleanup.
3745
3746 2017-09-11 Tom Tromey <tom@tromey.com>
3747
3748 * d-namespace.c (d_lookup_symbol): Use std::string.
3749 (find_symbol_in_baseclass): Likewise.
3750
3751 2017-09-11 Tom Tromey <tom@tromey.com>
3752
3753 * ctf.c (ctf_start): Use std::string.
3754
3755 2017-09-11 Tom Tromey <tom@tromey.com>
3756
3757 * ada-lang.c (is_known_support_routine): Update.
3758 (ada_unhandled_exception_name_addr_from_raise): Update.
3759 * guile/scm-frame.c (gdbscm_frame_name): Update.
3760 * python/py-frame.c (frapy_name): Update.
3761 (frapy_function): Update.
3762 * stack.h (find_frame_funname): Update.
3763 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
3764 (print_frame): Update.
3765
3766 2017-09-11 Tom Tromey <tom@tromey.com>
3767
3768 * findcmd.c (put_bits): Take a gdb::byte_vector.
3769 (parse_find_args): Return gdb::byte_vector. "args" now const.
3770 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
3771 cleanups.
3772 (find_command): Update.
3773
3774 2017-09-11 Tom Tromey <tom@tromey.com>
3775
3776 * cli/cli-script.c (class scoped_restore_hook_in): New.
3777 (clear_hook_in_cleanup): Remove.
3778 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
3779 scoped_restore_hook_in.
3780
3781 2017-09-11 Tom Tromey <tom@tromey.com>
3782
3783 * cli/cli-script.c (restore_interp): Remove.
3784 (read_command_lines): Use scoped_restore_interp.
3785 * interps.c (scoped_restore_interp::set_temp): Rename from
3786 interp_set_temp.
3787 * interps.h (class scoped_restore_interp): New.
3788 (interp_set_temp): Remove.
3789
3790 2017-09-11 Tom Tromey <tom@tromey.com>
3791
3792 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
3793 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
3794 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
3795 scoped_restore.
3796 (mi_cmd_break_insert_1): Update.
3797 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
3798 scoped_restore.
3799
3800 2017-09-11 Tom Tromey <tom@tromey.com>
3801
3802 * demangle.c (demangle_command): Update.
3803 * breakpoint.c (disable_command): Update.
3804 (enable_command): Update.
3805 (find_location_by_number): Make "number" const. Use
3806 get_number_trailer.
3807 * cli/cli-utils.c (extract_arg): Return std::string.
3808 * probe.c (parse_probe_linespec): Update. Change types.
3809 (collect_probes): Take string arguments.
3810 (parse_probe_linespec): Likewise.
3811 (info_probes_for_ops): Update.
3812 (enable_probes_command): Update.
3813 (disable_probes_command): Update.
3814 * break-catch-sig.c (catch_signal_split_args): Update.
3815 * mi/mi-parse.c (mi_parse): Update.
3816
3817 2017-09-11 Tom Tromey <tom@tromey.com>
3818
3819 * language.h (language_enum): Make argument const.
3820 * language.c (language_enum): Make argument const.
3821
3822 2017-09-11 Tom Tromey <tom@tromey.com>
3823
3824 * common/common-utils.h (skip_to_space): Remove macro, redeclare
3825 as function.
3826 (skip_to_space): Rename from skip_to_space_const.
3827 * common/common-utils.c (skip_to_space): New function.
3828 (skip_to_space): Rename from skip_to_space_const.
3829 * cli/cli-utils.h (get_number): Rename from get_number_const.
3830 (extract_arg): Rename from extract_arg_const.
3831 * cli/cli-utils.c (get_number): Rename from get_number_const.
3832 (extract_arg): Rename from extract_arg_const.
3833 (number_or_range_parser::get_number): Use ::get_number.
3834 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
3835 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
3836 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
3837 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
3838 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
3839 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
3840 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
3841 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
3842
3843 2017-09-11 Tom Tromey <tom@tromey.com>
3844
3845 * python/python.c (do_start_initialization): Use
3846 py-event-types.def to initialize types.
3847 Define all object type structures.
3848 * python/python-internal.h: Don't declare event initialization
3849 functions.
3850 * python/py-threadevent.c (thread_event_object_type): Don't
3851 define.
3852 * python/py-stopevent.c (stop_event_object_type): Don't define.
3853 * python/py-signalevent.c (signal_event_object_type): Don't
3854 declare or define.
3855 * python/py-newobjfileevent.c (new_objfile_event_object_type)
3856 (clear_objfiles_event_object_type): Don't declare or define.
3857 * python/py-infevents.c (inferior_call_pre_event_object_type)
3858 (inferior_call_post_event_object_type)
3859 (register_changed_event_object_type)
3860 (memory_changed_event_object_type): Don't declare or define.
3861 * python/py-inferior.c (new_thread_event_object_type)
3862 (new_inferior_event_object_type)
3863 (inferior_deleted_event_object_type): Don't declare or define.
3864 * python/py-exitedevent.c (exited_event_object_type): Don't
3865 declare or define.
3866 * python/py-evts.c (gdbpy_initialize_py_events): Use
3867 py-all-events.def.
3868 * python/py-events.h (thread_event_object_type): Don't declare.
3869 (events_object): Use py-all-events.def.
3870 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
3871 py-event-types.def.
3872 * python/py-event-types.def: New file.
3873 * python/py-continueevent.c (create_continue_event_object): Don't
3874 declare or define.
3875 * python/py-bpevent.c (breakpoint_event_object_type): Don't
3876 declare or define.
3877 * python/py-all-events.def: New file.
3878
3879 2017-09-11 Tom Tromey <tom@tromey.com>
3880
3881 * python/py-threadevent.c (create_thread_event_object): Return
3882 gdbpy_ref.
3883 * python/py-stopevent.h (create_stop_event_object)
3884 (create_breakpoint_event_object, create_signal_event_object):
3885 Update.
3886 * python/py-stopevent.c (create_stop_event_object): Return
3887 gdbpy_ref.
3888 (emit_stop_event): Update.
3889 * python/py-signalevent.c (create_signal_event_object): Return
3890 gdbpy_ref.
3891 * python/py-infevents.c (create_inferior_call_event_object):
3892 Update.
3893 * python/py-event.h (create_event_object)
3894 (create_thread_event_object): Update.
3895 * python/py-event.c (create_event_object): Return gdbpy_ref.
3896 * python/py-continueevent.c: Return gdbpy_ref.
3897 * python/py-bpevent.c (create_breakpoint_event_object): Return
3898 gdbpy_ref.
3899
3900 2017-09-11 Tom Tromey <tom@tromey.com>
3901
3902 PR python/15622:
3903 * NEWS: Add entry.
3904 * python/python.c (do_start_initialization): Initialize new event
3905 types.
3906 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
3907 (gdbpy_initialize_inferior_deleted_event)
3908 (gdbpy_initialize_new_thread_event): Declare.
3909 * python/py-threadevent.c (create_thread_event_object): Add option
3910 "thread" parameter.
3911 * python/py-inferior.c (new_thread_event_object_type)
3912 (new_inferior_event_object_type)
3913 (inferior_deleted_event_object_type): Declare.
3914 (python_new_inferior, python_inferior_deleted): New functions.
3915 (add_thread_object): Emit new_thread event.
3916 (gdbpy_initialize_inferior): Attach new functions to corresponding
3917 observers.
3918 (new_thread, new_inferior, inferior_deleted): Define new event
3919 types.
3920 * python/py-evts.c (gdbpy_initialize_py_events): Add new
3921 registries.
3922 * python/py-events.h (events_object) <new_inferior,
3923 inferior_deleted, new_thread>: New fields.
3924 * python/py-event.h (create_thread_event_breakpoint): Add optional
3925 "thread" parameter.
3926
3927 2017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
3928
3929 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
3930 check current_ui instead.
3931 (internal_vproblem): Likewise.
3932
3933 2017-09-09 Simon Marchi <simon.marchi@ericsson.com>
3934
3935 * thread.c (print_thread_info_1): Remove unnecessary calls to
3936 uiout->is_mi_like_p.
3937
3938 2017-09-09 Tom Tromey <tom@tromey.com>
3939
3940 * namespace.h (add_using_directive): Update.
3941 * namespace.c (add_using_directive): Change type of excludes to
3942 std::vector.
3943 * dwarf2read.c (read_import_statement): Use std::vector.
3944 (read_namespace): Update.
3945 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
3946
3947 2017-09-09 Tom Tromey <tom@tromey.com>
3948
3949 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
3950
3951 2017-09-09 Tom Tromey <tom@tromey.com>
3952
3953 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
3954
3955 2017-09-09 Tom Tromey <tom@tromey.com>
3956
3957 * stack.c (func_command): Use gdb::def_vector.
3958
3959 2017-09-09 Tom Tromey <tom@tromey.com>
3960
3961 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
3962 ui_out_emit_list, ui_out_emit_tuple.
3963 (mi_cmd_var_update): Likewise.
3964
3965 2017-09-09 Tom Tromey <tom@tromey.com>
3966
3967 * mi/mi-interp.c (mi_user_selected_context_changed): Use
3968 ui_out_redirect_pop.
3969 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
3970 ui_out_redirect_pop.
3971 * utils.c (do_ui_out_redirect_pop)
3972 (make_cleanup_ui_out_redirect_pop): Remove.
3973 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
3974 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
3975 * ui-out.h (ui_out_redirect_pop): New class.
3976
3977 2017-09-09 Tom Tromey <tom@tromey.com>
3978
3979 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
3980 (list_available_thread_groups, mi_cmd_list_thread_groups)
3981 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
3982 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
3983 Likewise.
3984
3985 2017-09-09 Tom Tromey <tom@tromey.com>
3986
3987 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
3988 ui_out_emit_tuple.
3989
3990 2017-09-09 Tom Tromey <tom@tromey.com>
3991
3992 * target.c (flash_erase_command): Use ui_out_emit_tuple.
3993 * stack.c (print_frame): Use ui_out_emit_tuple.
3994 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
3995 (info_spu_mailbox_command, info_spu_dma_command)
3996 (info_spu_proxydma_command): Likewise.
3997 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
3998 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
3999 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
4000 ui_out_emit_tuple.
4001 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
4002
4003 2017-09-09 Tom Tromey <tom@tromey.com>
4004
4005 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
4006 (class ui_out_emit_table): Update comment.
4007 * ui-out.c (do_cleanup_table_end)
4008 (make_cleanup_ui_out_table_begin_end): Remove.
4009 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
4010 (info_spu_dma_cmdlist): Likewise.
4011 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
4012 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
4013 ui_out_emit_table.
4014
4015 2017-09-09 Tom Tromey <tom@tromey.com>
4016
4017 * thread.c (print_thread_info_1): Use ui_out_emit_table,
4018 ui_out_emit_list, gdb::optional.
4019
4020 2017-09-09 John Baldwin <jhb@FreeBSD.org>
4021
4022 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
4023 prototype.
4024 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
4025 prototype.
4026 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
4027 prototype.
4028 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
4029 * ada-exp.y: Remove _initialize_ada_exp prototype.
4030 * ada-lang.c: Remove _initialize_ada_language prototype.
4031 * ada-tasks.c: Remove _initialize_tasks prototype.
4032 * addrmap.c: Remove _initialize_addrmap prototype.
4033 * agent.c: Remove _initialize_agent prototype.
4034 * aix-thread.c: Remove _initialize_aix_thread prototype.
4035 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
4036 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
4037 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
4038 prototype.
4039 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
4040 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
4041 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
4042 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
4043 prototype.
4044 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
4045 prototype.
4046 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
4047 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
4048 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
4049 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
4050 prototype.
4051 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
4052 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
4053 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
4054 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
4055 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
4056 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
4057 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
4058 prototype.
4059 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
4060 prototype.
4061 * annotate.c: Remove _initialize_annotate prototype.
4062 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
4063 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
4064 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
4065 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
4066 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
4067 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
4068 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
4069 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
4070 prototype.
4071 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
4072 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
4073 * auto-load.c: Remove _initialize_auto_load prototype.
4074 * auxv.c: Remove _initialize_auxv prototype.
4075 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
4076 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
4077 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
4078 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
4079 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
4080 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
4081 prototype.
4082 * break-catch-throw.c: Remove _initialize_break_catch_throw
4083 prototype.
4084 * breakpoint.c: Remove _initialize_breakpoint prototype.
4085 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
4086 * btrace.c: Remove _initialize_btrace prototype.
4087 * charset.c: Remove _initialize_charset prototype.
4088 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
4089 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
4090 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
4091 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
4092 * cli/cli-script.c: Remove _initialize_cli_script prototype.
4093 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
4094 * coffread.c: Remove _initialize_coffread prototype.
4095 * compile/compile.c: Remove _initialize_compile prototype.
4096 * complaints.c: Remove _initialize_complaints prototype.
4097 * completer.c: Remove _initialize_completer prototype.
4098 * copying.awk: Remove _initialize_copying prototype.
4099 * copying.c: Regenerate.
4100 * core-regset.c: Remove _initialize_core_regset prototype.
4101 * corefile.c: Remove _initialize_core prototype.
4102 * corelow.c: Remove _initialize_corelow prototype.
4103 * cp-abi.c: Remove _initialize_cp_abi prototype.
4104 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
4105 * cp-support.c: Remove _initialize_cp_support prototype.
4106 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
4107 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
4108 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
4109 * ctf.c: Remove _initialize_ctf prototype.
4110 * d-lang.c: Remove _initialize_d_language prototype.
4111 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
4112 prototype.
4113 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
4114 * dbxread.c: Remove _initialize_dbxread prototype.
4115 * dcache.c: Remove _initialize_dcache prototype.
4116 * demangle.c: Remove _initialize_demangler prototype.
4117 * disasm-selftests.c: Remove _initialize_disasm_selftests
4118 prototype.
4119 * disasm.c: Remove _initialize_disasm prototype.
4120 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
4121 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
4122 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
4123 prototype.
4124 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
4125 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
4126 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
4127 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
4128 * elfread.c: Remove _initialize_elfread prototype.
4129 * exec.c: Remove _initialize_exec prototype.
4130 * extension.c: Remove _initialize_extension prototype.
4131 * f-lang.c: Remove _initialize_f_language prototype.
4132 * f-valprint.c: Remove _initialize_f_valprint prototype.
4133 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
4134 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
4135 * filesystem.c: Remove _initialize_filesystem prototype.
4136 * findcmd.c: Remove _initialize_mem_search prototype.
4137 * fork-child.c: Remove _initialize_fork_child prototype.
4138 * frame-base.c: Remove _initialize_frame_base prototype.
4139 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
4140 * frame.c: Remove _initialize_frame prototype.
4141 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
4142 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
4143 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
4144 * gcore.c: Remove _initialize_gcore prototype.
4145 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
4146 * gdbarch.c: Regenerate.
4147 * gdbarch.sh: Remove _initialize_gdbarch prototype.
4148 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
4149 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
4150 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
4151 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
4152 * go-lang.c: Remove _initialize_go_language prototype.
4153 * go32-nat.c: Remove _initialize_go32_nat prototype.
4154 * guile/guile.c: Remove _initialize_guile prototype.
4155 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
4156 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
4157 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
4158 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
4159 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
4160 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
4161 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
4162 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
4163 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
4164 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
4165 prototype.
4166 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
4167 prototype.
4168 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
4169 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
4170 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
4171 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
4172 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
4173 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
4174 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
4175 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
4176 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
4177 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
4178 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
4179 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
4180 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
4181 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
4182 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
4183 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
4184 prototype.
4185 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
4186 prototype.
4187 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
4188 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
4189 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
4190 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
4191 * infcall.c: Remove _initialize_infcall prototype.
4192 * infcmd.c: Remove _initialize_infcmd prototype.
4193 * inferior.c: Remove _initialize_inferiors prototype.
4194 * inflow.c: Remove _initialize_inflow prototype.
4195 * infrun.c: Remove _initialize_infrun prototype.
4196 * interps.c: Remove _initialize_interpreter prototype.
4197 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
4198 * jit.c: Remove _initialize_jit prototype.
4199 * language.c: Remove _initialize_language prototype.
4200 * linux-fork.c: Remove _initialize_linux_fork prototype.
4201 * linux-nat.c: Remove _initialize_linux_nat prototype.
4202 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
4203 * linux-thread-db.c: Remove _initialize_thread_db prototype.
4204 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
4205 * m2-lang.c: Remove _initialize_m2_language prototype.
4206 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
4207 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
4208 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
4209 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
4210 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
4211 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
4212 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
4213 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
4214 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
4215 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
4216 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
4217 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
4218 * machoread.c: Remove _initialize_machoread prototype.
4219 * macrocmd.c: Remove _initialize_macrocmd prototype.
4220 * macroscope.c: Remove _initialize_macroscope prototype.
4221 * maint.c: Remove _initialize_maint_cmds prototype.
4222 * mdebugread.c: Remove _initialize_mdebugread prototype.
4223 * memattr.c: Remove _initialize_mem prototype.
4224 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
4225 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
4226 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
4227 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
4228 * mi/mi-main.c: Remove _initialize_mi_main prototype.
4229 * microblaze-linux-tdep.c: Remove
4230 _initialize_microblaze_linux_tdep prototype.
4231 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
4232 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
4233 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
4234 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
4235 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
4236 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
4237 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
4238 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
4239 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
4240 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
4241 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
4242 prototype.
4243 * mipsread.c: Remove _initialize_mipsread prototype.
4244 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
4245 prototype.
4246 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
4247 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
4248 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
4249 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
4250 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
4251 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
4252 prototype.
4253 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
4254 * nto-procfs.c: Remove _initialize_procfs prototype.
4255 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
4256 * objc-lang.c: Remove _initialize_objc_language prototype.
4257 * objfiles.c: Remove _initialize_objfiles prototype.
4258 * observer.c: Remove observer_test_first_notification_function,
4259 observer_test_second_notification_function,
4260 observer_test_third_notification_function, and
4261 _initialize_observer prototypes.
4262 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
4263 * osabi.c: Remove _initialize_gdb_osabi prototype.
4264 * osdata.c: Remove _initialize_osdata prototype.
4265 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
4266 * parse.c: Remove _initialize_parse prototype.
4267 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
4268 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
4269 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
4270 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
4271 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
4272 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
4273 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
4274 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
4275 * printcmd.c: Remove _initialize_printcmd prototype.
4276 * probe.c: Remove _initialize_probe prototype.
4277 * proc-api.c: Remove _initialize_proc_api prototype.
4278 * proc-events.c: Remove _initialize_proc_events prototype.
4279 * proc-service.c: Remove _initialize_proc_service prototype.
4280 * procfs.c: Remove _initialize_procfs prototype.
4281 * psymtab.c: Remove _initialize_psymtab prototype.
4282 * python/python.c: Remove _initialize_python prototype.
4283 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
4284 * record-btrace.c: Remove _initialize_record_btrace prototype.
4285 * record-full.c: Remove _initialize_record_full prototype.
4286 * record.c: Remove _initialize_record prototype.
4287 * regcache.c: Remove _initialize_regcache prototype.
4288 * reggroups.c: Remove _initialize_reggroup prototype.
4289 * remote-notif.c: Remove _initialize_notif prototype.
4290 * remote-sim.c: Remove _initialize_remote_sim prototype.
4291 * remote.c: Remove _initialize_remote prototype.
4292 * reverse.c: Remove _initialize_reverse prototype.
4293 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
4294 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
4295 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
4296 prototype.
4297 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
4298 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
4299 * rust-exp.y: Remove _initialize_rust_exp prototype.
4300 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
4301 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
4302 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
4303 * score-tdep.c: Remove _initialize_score_tdep prototype.
4304 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
4305 prototype.
4306 * ser-go32.c: Remove _initialize_ser_dos prototype.
4307 * ser-mingw.c: Remove _initialize_ser_windows prototype.
4308 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
4309 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
4310 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
4311 * serial.c: Remove _initialize_serial prototype.
4312 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
4313 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
4314 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
4315 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
4316 * skip.c: Remove _initialize_step_skip prototype.
4317 * sol-thread.c: Remove _initialize_sol_thread prototype.
4318 * solib-aix.c: Remove _initialize_solib_aix prototype.
4319 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
4320 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
4321 * solib-frv.c: Remove _initialize_frv_solib prototype.
4322 * solib-spu.c: Remove _initialize_spu_solib prototype.
4323 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
4324 * solib-target.c: Remove _initialize_solib_target prototype.
4325 * solib.c: Remove _initialize_solib prototype.
4326 * source.c: Remove _initialize_source prototype.
4327 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
4328 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
4329 prototype.
4330 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
4331 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
4332 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
4333 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
4334 prototype.
4335 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
4336 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
4337 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
4338 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
4339 prototype.
4340 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
4341 prototype.
4342 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
4343 prototype.
4344 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
4345 prototype.
4346 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
4347 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
4348 prototype.
4349 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
4350 prototype.
4351 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
4352 prototype.
4353 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
4354 prototype.
4355 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
4356 prototype.
4357 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
4358 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
4359 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
4360 * stabsread.c: Remove _initialize_stabsread prototype.
4361 * stack.c: Remove _initialize_stack prototype.
4362 * stap-probe.c: Remove _initialize_stap_probe prototype.
4363 * std-regs.c: Remove _initialize_frame_reg prototype.
4364 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
4365 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
4366 * symfile.c: Remove _initialize_symfile prototype.
4367 * symmisc.c: Remove _initialize_symmisc prototype.
4368 * symtab.c: Remove _initialize_symtab prototype.
4369 * target-dcache.c: Remove _initialize_target_dcache prototype.
4370 * target-descriptions.c: Remove _initialize_target_descriptions
4371 prototype.
4372 * thread.c: Remove _initialize_thread prototype.
4373 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
4374 prototype.
4375 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
4376 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
4377 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
4378 prototype.
4379 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
4380 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
4381 * tracefile.c: Remove _initialize_tracefile prototype.
4382 * tracepoint.c: Remove _initialize_tracepoint prototype.
4383 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
4384 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
4385 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
4386 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
4387 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
4388 * tui/tui-win.c: Remove _initialize_tui_win prototype.
4389 * tui/tui.c: Remove _initialize_tui prototype.
4390 * typeprint.c: Remove _initialize_typeprint prototype.
4391 * user-regs.c: Remove _initialize_user_regs prototype.
4392 * utils.c: Remove _initialize_utils prototype.
4393 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
4394 * valarith.c: Remove _initialize_valarith prototype.
4395 * valops.c: Remove _initialize_valops prototype.
4396 * valprint.c: Remove _initialize_valprint prototype.
4397 * value.c: Remove _initialize_values prototype.
4398 * varobj.c: Remove _initialize_varobj prototype.
4399 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
4400 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
4401 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
4402 * windows-nat.c: Remove _initialize_windows_nat,
4403 _initialize_check_for_gdb_ini, and _initialize_loadable
4404 prototypes.
4405 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
4406 * xcoffread.c: Remove _initialize_xcoffread prototype.
4407 * xml-support.c: Remove _initialize_xml_support prototype.
4408 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
4409 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
4410 prototype.
4411 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
4412 prototype.
4413 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
4414
4415 2017-09-08 Keith Seitz <keiths@redhat.com>
4416
4417 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
4418 field.
4419
4420 2017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
4421
4422 * f-valprint.c (f_val_print): Remove check for one byte
4423 sized integers. Remove printing of character type.
4424
4425 2017-09-08 Frank Penczek <frank.penczek@intel.com>
4426 Christoph Weinmann <christoph.t.weinmann@intel.com>
4427 Bernhard Heckel <bernhard.heckel@intel.com>
4428
4429 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
4430 to maintain proper indentation when printing pointers/refs.
4431
4432 2017-09-07 Joel Brobecker <brobecker@adacore.com>
4433
4434 GDB 8.0.1 released.
4435
4436 2017-09-07 Joel Brobecker <brobecker@adacore.com>
4437
4438 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
4439
4440 2017-09-05 Tom Tromey <tom@tromey.com>
4441
4442 * parse.c (funcall_chain): Now a std::vector.
4443 (start_arglist, end_arglist): Simplify.
4444 (free_funcalls): Remove.
4445 (parse_exp_in_context_1): Remove cleanup.
4446
4447 2017-09-05 Tom Tromey <tom@tromey.com>
4448
4449 * go-exp.y (go_parse): Don't create a cleanup.
4450
4451 2017-09-05 Tom Tromey <tom@tromey.com>
4452
4453 * d-exp.y (PrimaryExpression): Use std::string.
4454 (d_parse): Don't create a cleanup.
4455
4456 2017-09-05 Tom Tromey <tom@tromey.com>
4457
4458 * utils.c (do_clear_parser_state): Remove.
4459 (make_cleanup_clear_parser_state): Remove.
4460 * p-exp.y (pascal_parse): Use scoped_restore.
4461 * m2-exp.y (m2_parse): Use scoped_restore.
4462 * f-exp.y (f_parse): Use scoped_restore.
4463 * d-exp.y (d_parse): Use scoped_restore.
4464 * c-exp.y (c_parse): Use scoped_restore.
4465 * ada-exp.y (ada_parse): Use scoped_restore.
4466 * utils.h (make_cleanup_clear_parser_state): Remove.
4467
4468 2017-09-06 Keith Seitz <keiths@redhat.com>
4469
4470 * dwarf2read.c (dw2_linkage_name_attr): New function.
4471 (dw2_linkage_name): New function.
4472 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
4473 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
4474 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
4475
4476 2017-09-06 Kamil Rytarowski <n54@gmx.com>
4477
4478 * config/djgpp/djconfig.sh: Correct shell portability issue.
4479
4480 2017-09-06 Kamil Rytarowski <n54@gmx.com>
4481
4482 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
4483
4484 2017-09-06 John Baldwin <jhb@FreeBSD.org>
4485
4486 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
4487 * NEWS: Mention new FreeBSD/mips native configuration.
4488 * configure.host: Add aarch64*-*-freebsd*.
4489 * configure.nat: Likewise.
4490 * aarch64-fbsd-nat.c: New file.
4491
4492 2017-09-06 John Baldwin <jhb@FreeBSD.org>
4493
4494 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
4495 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
4496 * NEWS: Mention new FreeBSD/aarch64 target.
4497 * configure.tgt: Add aarch64*-*-freebsd*.
4498 * aarch64-fbsd-tdep.c: New file.
4499 * aarch64-fbsd-tdep.h: New file.
4500
4501 2017-09-06 Kamil Rytarowski <n54@gmx.com>
4502
4503 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
4504
4505 2017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
4506
4507 * parse.c (find_minsym_type_and_address): Don't relocate addresses
4508 of TLS symbols.
4509
4510 2017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4511
4512 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
4513 call.
4514
4515 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
4516
4517 * infrun.c (follow_exec): Call add_thread after
4518 target_find_description.
4519
4520 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
4521
4522 * infrun.c (handle_inferior_event_1): When exec'ing, read
4523 stop_pc after follow_exec.
4524
4525 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
4526
4527 * remote.c (process_g_packet): Update error message.
4528
4529 2017-09-05 Yao Qi <yao.qi@linaro.org>
4530
4531 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
4532 targets.
4533
4534 2017-09-05 Pedro Alves <palves@redhat.com>
4535
4536 * eval.c (eval_call, evaluate_funcall): New functions, factored
4537 out from ...
4538 (evaluate_subexp_standard): ... this.
4539
4540 2017-09-05 Yao Qi <yao.qi@linaro.org>
4541
4542 * amd64-tdep.c (amd64_target_description): Create target
4543 descriptions.
4544 (_initialize_amd64_tdep): Don't call functions
4545 initialize_tdesc_amd64_*. Add self tests.
4546 * arch/amd64.c (amd64_create_target_description): Add parameter
4547 is_linux. Call set_tdesc_osabi if is_linux is true.
4548 * arch/amd64.h (amd64_create_target_description): Update the
4549 declaration.
4550 * arch/i386.c (i386_create_target_description): Add parameter
4551 is_linux. Call set_tdesc_osabi if is_linux is true.
4552 * arch/i386.h (i386_create_target_description): Update
4553 declaration.
4554 * configure.tgt: Add i386.o to gdb_target_obs.
4555 * features/Makefile (XMLTOC): Remove i386/*.xml.
4556 * features/i386/amd64-avx-avx512.c: Remove.
4557 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
4558 * features/i386/amd64-avx-mpx.c: Remove.
4559 * features/i386/amd64-avx.c: Remove.
4560 * features/i386/amd64-mpx.c: Remove.
4561 * features/i386/amd64.c: Remove.
4562 * features/i386/i386-avx-avx512.c: Remove.
4563 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
4564 * features/i386/i386-avx-mpx.c: Remove.
4565 * features/i386/i386-avx.c: Remove.
4566 * features/i386/i386-mmx.c: Remove.
4567 * features/i386/i386-mpx.c: Remove.
4568 * features/i386/i386.c: Remove.
4569 * i386-tdep.c: Don't include features/i386/i386*.c., include
4570 target-descriptions.h and arch/i386.h.
4571 (i386_target_description): Create target descriptions.
4572 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
4573 functions. Do self tests.
4574
4575 2017-09-05 Yao Qi <yao.qi@linaro.org>
4576
4577 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
4578 * features/i386/amd64-avx-avx512-linux.c: Removed.
4579 * features/i386/amd64-avx-linux.c: Removed.
4580 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
4581 * features/i386/amd64-avx-mpx-linux.c: Removed.
4582 * features/i386/amd64-linux.c: Removed.
4583 * features/i386/amd64-mpx-linux.c: Removed.
4584 * features/i386/x32-avx-avx512-linux.c: Removed.
4585 * features/i386/x32-avx-linux.c: Removed.
4586 * features/i386/x32-linux.c: Removed.
4587
4588 2017-09-05 Yao Qi <yao.qi@linaro.org>
4589
4590 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
4591 features/i386/*.c.
4592 (amd64_linux_read_description): Call
4593 amd64_create_target_description.
4594 * arch/amd64.c: New file.
4595 * arch/amd64.h: New file.
4596 * configure.tgt (x86_64-*-linux*): Append amd64.o.
4597 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
4598
4599 2017-09-05 Yao Qi <yao.qi@linaro.org>
4600
4601 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
4602 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
4603 (amd64_linux_read_description): Create target descriptions.
4604 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
4605 functions. Add unit tests.
4606 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
4607 x32-core.xml.
4608 * features/i386/64bit-avx.c: Generated.
4609 * features/i386/64bit-avx512.c: Generated.
4610 * features/i386/64bit-core.c: Generated.
4611 * features/i386/64bit-linux.c: Generated.
4612 * features/i386/64bit-mpx.c: Generated.
4613 * features/i386/64bit-pkeys.c: Generated.
4614 * features/i386/64bit-segments.c: Generated.
4615 * features/i386/64bit-sse.c: Generated.
4616 * features/i386/x32-core.c: Generated.
4617 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
4618 c files for amd64-linux and x32-linux.
4619
4620 2017-09-05 Yao Qi <yao.qi@linaro.org>
4621
4622 * amd64-linux-tdep.c (amd64_linux_read_description): New
4623 function.
4624 (amd64_linux_core_read_description): Call
4625 amd64_linux_read_description.
4626 (amd64_linux_init_abi): Likewise.
4627 (amd64_x32_linux_init_abi): Likewise.
4628 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
4629 * x86-linux-nat.c (x86_linux_read_description): Call
4630 amd64_linux_read_description.
4631
4632 2017-09-05 Yao Qi <yao.qi@linaro.org>
4633
4634 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
4635 comments.
4636
4637 2017-09-05 Yao Qi <yao.qi@linaro.org>
4638
4639 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
4640 * features/i386/i386-avx-avx512-linux.c: Remove.
4641 * features/i386/i386-avx-linux.c: Remove.
4642 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
4643 * features/i386/i386-avx-mpx-linux.c: Remove.
4644 * features/i386/i386-linux.c: Remove.
4645 * features/i386/i386-mmx-linux.c: Remove.
4646 * features/i386/i386-mpx-linux.c: Remove.
4647
4648 2017-09-05 Yao Qi <yao.qi@linaro.org>
4649
4650 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
4651 (SFILES): Add arch/i386.c.
4652 (HFILES_NO_SRCDIR): Add arch/i386.h.
4653 * arch/i386.c: New file.
4654 * arch/i386.h: New file.
4655 * arch/tdesc.h (allocate_target_description): Declare.
4656 (set_tdesc_architecture): Declare.
4657 (set_tdesc_osabi): Declare.
4658 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
4659 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
4660 include arch/i386.h.
4661 (i386_linux_read_description): Remove code and call
4662 i386_create_target_description.
4663 (set_tdesc_architecture): New function.
4664 (set_tdesc_osabi): New function.
4665 * target-descriptions.h (allocate_target_description): Remove.
4666
4667 2017-09-05 Yao Qi <yao.qi@linaro.org>
4668
4669 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
4670 * target-descriptions.c (tdesc_create_feature): Likewise, and
4671 adjust code.
4672 * features/i386/32bit-avx.c: Re-generated.
4673 * features/i386/32bit-avx512.c: Re-generated.
4674 * features/i386/32bit-core.c: Re-generated.
4675 * features/i386/32bit-linux.c: Re-generated.
4676 * features/i386/32bit-mpx.c: Re-generated.
4677 * features/i386/32bit-pkeys.c: Re-generated.
4678 * features/i386/32bit-sse.c: Re-generated.
4679
4680 2017-09-05 Yao Qi <yao.qi@linaro.org>
4681
4682 * regformats/regdef.h (struct reg): Override operator == and !=.
4683
4684 2017-09-05 Yao Qi <yao.qi@linaro.org>
4685
4686 * arch/tdesc.h: New file.
4687 * regformats/regdat.sh: Generate code using tdesc_create_reg.
4688 * target-descriptions.c: Update comments.
4689 * target-descriptions.h: Include "arch/tdesc.h". Remove the
4690 declarations.
4691 * features/i386/32bit-avx.c: Re-generated.
4692 * features/i386/32bit-avx512.c: Re-generated.
4693 * features/i386/32bit-core.c: Re-generated.
4694 * features/i386/32bit-linux.c: Re-generated.
4695 * features/i386/32bit-mpx.c: Re-generated.
4696 * features/i386/32bit-pkeys.c: Re-generated.
4697 * features/i386/32bit-sse.c: Re-generated.
4698
4699 2017-09-05 Yao Qi <yao.qi@linaro.org>
4700
4701 * regformats/regdat.sh: Update generated code.
4702
4703 2017-09-05 Yao Qi <yao.qi@linaro.org>
4704
4705 * regformats/regdat.sh: Adjust code order.
4706
4707 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
4708
4709 * expprint.c (dump_subexp_body_standard): Use constant format
4710 string in fprintf_filtered call.
4711
4712 2017-09-04 John Baldwin <jhb@FreeBSD.org>
4713
4714 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
4715 NetBSD/i386.
4716 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
4717
4718 2017-09-04 John Baldwin <jhb@FreeBSD.org>
4719
4720 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
4721
4722 2017-09-04 John Baldwin <jhb@FreeBSD.org>
4723
4724 * bsd-kvm.o: Define _KMEMUSER.
4725 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
4726 * configure: Regenerate.
4727
4728 2017-09-04 John Baldwin <jhb@FreeBSD.org>
4729
4730 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
4731 * i386-fbsd-nat.c: Likewise.
4732
4733 2017-09-04 John Baldwin <jhb@FreeBSD.org>
4734
4735 * unittests/array-view-selftests.c: Add include of <array>.
4736
4737 2017-09-04 John Baldwin <jhb@FreeBSD.org>
4738
4739 * spu-tdep.c (flush_ea_cache): Add missing argument to
4740 call_function_by_hand.
4741
4742 2017-09-04 Pedro Alves <palves@redhat.com>
4743
4744 * NEWS (Safer support for debugging with no debug info): New.
4745
4746 2017-09-04 Pedro Alves <palves@redhat.com>
4747
4748 * c-exp.y (function_method, function_method_void): Add current
4749 instance flags to TYPE_INSTANCE.
4750 * dwarf2read.c (check_modifier): New.
4751 (compute_delayed_physnames): Assert that only C++ adds delayed
4752 physnames. Mark fn_fields as const/volatile depending on
4753 physname.
4754 * eval.c (make_params): New type_instance_flags parameter. Use
4755 it as the new type's instance flags.
4756 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
4757 flags element and pass it to make_params.
4758 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
4759 instance flags element.
4760 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
4761 * gdbtypes.h: Include "enum-flags.h".
4762 (type_instance_flags): New enum-flags type.
4763 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
4764 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
4765 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
4766 (follow_type_instance_flags): New function.
4767 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
4768 * parser-defs.h (follow_type_instance_flags): Declare.
4769 * valops.c (value_struct_elt_for_reference): const/volatile must
4770 match too.
4771
4772 2017-09-04 Pedro Alves <palves@redhat.com>
4773
4774 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
4775 function/method scopes; lookup the nested name as a function local
4776 static variable.
4777
4778 2017-09-04 Pedro Alves <palves@redhat.com>
4779
4780 (%type <voidval>): Add function_method.
4781 * c-exp.y (exp): New production for calls with no arguments.
4782 (function_method, function_method_void_or_typelist): New
4783 productions.
4784 (exp): New production for "method()::static_var".
4785 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
4786 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
4787 Handle OP_FUNC_STATIC_VAR.
4788 * parse.c (operator_length_standard):
4789 Handle OP_FUNC_STATIC_VAR.
4790
4791 2017-09-04 Pedro Alves <palves@redhat.com>
4792
4793 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
4794 handling.
4795 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
4796 Ditto.
4797 * parse.c (operator_length_standard, operator_check_standard):
4798 Ditto.
4799 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
4800
4801 2017-09-04 Pedro Alves <palves@redhat.com>
4802
4803 * ax-gdb.c: Include "typeprint.h".
4804 (gen_expr_for_cast): New function.
4805 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
4806 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
4807 type is unknown.
4808 * dwarf2read.c (new_symbol_full): Fallback to int instead of
4809 nodebug_data_symbol.
4810 * eval.c: Include "typeprint.h".
4811 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
4812 Error out if symbol has unknown type.
4813 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
4814 evaluate_subexp_for_cast.
4815 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
4816 OP_VAR_MSYM_VALUE.
4817 (evaluate_subexp_for_cast): New function.
4818 * gdbtypes.c (init_nodebug_var_type): New function.
4819 (objfile_type): Use it to initialize types of variables with no
4820 debug info.
4821 * typeprint.c (error_unknown_type): New.
4822 * typeprint.h (error_unknown_type): New declaration.
4823 * compile/compile-c-types.c (convert_type_basic): Handle
4824 TYPE_CODE_ERROR; warn and fallback to int for variables with
4825 unknown type.
4826
4827 2017-09-04 Pedro Alves <palves@redhat.com>
4828
4829 * eval.c (evaluate_var_value): New function, factored out from ...
4830 (evaluate_subexp_standard): ... here.
4831
4832 2017-09-04 Pedro Alves <palves@redhat.com>
4833
4834 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
4835 Remove useless assignments to 'op'.
4836
4837 2017-09-04 Pedro Alves <palves@redhat.com>
4838
4839 * eval.c (eval_skip_value): New function.
4840 (evaluate_subexp_standard): Use it.
4841
4842 2017-09-04 Pedro Alves <palves@redhat.com>
4843
4844 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
4845 function name from symbol/minsym and pass it to
4846 error_call_unknown_return_type.
4847
4848 2017-09-04 Pedro Alves <palves@redhat.com>
4849
4850 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
4851 * ax-gdb.c (gen_msym_var_ref): New function.
4852 (gen_expr): Handle OP_VAR_MSYM_VALUE.
4853 * eval.c (evaluate_var_msym_value): New function.
4854 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
4855 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
4856 to call_function_by_hand.
4857 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
4858 Handle OP_VAR_MSYM_VALUE.
4859 (union exp_element) <msymbol>: New field.
4860 * minsyms.h (struct type): Forward declare.
4861 (find_minsym_type_and_address): Declare.
4862 * parse.c (write_exp_elt_msym): New function.
4863 (write_exp_msymbol): Delete, refactored as ...
4864 (find_minsym_type_and_address): ... this new function.
4865 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
4866 (operator_length_standard, operator_check_standard): Handle
4867 OP_VAR_MSYM_VALUE.
4868 * std-operator.def (OP_VAR_MSYM_VALUE): New.
4869
4870 2017-09-04 Pedro Alves <palves@redhat.com>
4871
4872 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
4873 TYPE_GNU_IFUNC specially here. Throw error if return type is
4874 unknown.
4875 * ada-typeprint.c (print_func_type): Handle functions with unknown
4876 return type.
4877 * c-typeprint.c (c_type_print_base): Handle functions and methods
4878 with unknown return type.
4879 * compile/compile-c-symbols.c (convert_symbol_bmsym)
4880 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
4881 * compile/compile-c-types.c: Include "objfiles.h".
4882 (convert_func): For functions with unknown return type, warn and
4883 default to int.
4884 * compile/compile-object-run.c (compile_object_run): Adjust call
4885 to call_function_by_hand_dummy.
4886 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
4887 call_function_by_hand.
4888 * eval.c (evaluate_subexp_standard): Adjust calls to
4889 call_function_by_hand. Handle functions and methods with unknown
4890 return type. Pass expect_type to call_function_by_hand.
4891 * f-typeprint.c (f_type_print_base): Handle functions with unknown
4892 return type.
4893 * gcore.c (call_target_sbrk): Adjust call to
4894 call_function_by_hand.
4895 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
4896 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
4897 an integer address type instead of nodebug.
4898 * guile/scm-value.c (gdbscm_value_call): Adjust call to
4899 call_function_by_hand.
4900 * infcall.c (error_call_unknown_return_type): New function.
4901 (call_function_by_hand): New "default_return_type" parameter.
4902 Pass it down.
4903 (call_function_by_hand_dummy): New "default_return_type"
4904 parameter. Use it instead of defaulting to int. If there's no
4905 default and the return type is unknown, throw an error. If
4906 there's a default return type, and the called function has no
4907 debug info, then assume the function is prototyped.
4908 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
4909 New "default_return_type" parameter.
4910 (error_call_unknown_return_type): New declaration.
4911 * linux-fork.c (call_lseek): Cast return type of lseek.
4912 (inferior_call_waitpid, checkpoint_command): Adjust calls to
4913 call_function_by_hand.
4914 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
4915 calls to call_function_by_hand.
4916 * m2-typeprint.c (m2_procedure): Handle functions with unknown
4917 return type.
4918 * objc-lang.c (lookup_objc_class, lookup_child_selector)
4919 (value_nsstring, print_object_command): Adjust calls to
4920 call_function_by_hand.
4921 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
4922 functions with unknown return type.
4923 (pascal_type_print_func_varspec_suffix): New function.
4924 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
4925 TYPE_CODE_METHOD>: Use it.
4926 * python/py-value.c (valpy_call): Adjust call to
4927 call_function_by_hand.
4928 * rust-lang.c (rust_evaluate_funcall): Adjust call to
4929 call_function_by_hand.
4930 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
4931 call_function_by_hand.
4932 * valops.c (value_allocate_space_in_inferior): Adjust call to
4933 call_function_by_hand.
4934 * typeprint.c (type_print_unknown_return_type): New function.
4935 * typeprint.h (type_print_unknown_return_type): New declaration.
4936
4937 2017-09-04 Pedro Alves <palves@redhat.com>
4938
4939 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
4940 types with more than one parameter as prototyped.
4941
4942 2017-09-04 Pedro Alves <palves@redhat.com>
4943
4944 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
4945 (disassemble_command): Use gdb_disassembly_flags instead of bare
4946 int.
4947 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
4948 (dump_insns, do_mixed_source_and_assembly_deprecated)
4949 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
4950 Use gdb_disassembly_flags instead of bare int.
4951 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
4952 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
4953 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
4954 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
4955 (enum gdb_disassembly_flag): ... values of this new enumeration.
4956 (gdb_disassembly_flags): Define.
4957 (gdb_disassembly)
4958 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
4959 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
4960 gdb_disassembly_flags instead of bare int.
4961 * record-btrace.c (btrace_insn_history)
4962 (record_btrace_insn_history, record_btrace_insn_history_range)
4963 (record_btrace_insn_history_from): Use gdb_disassembly_flags
4964 instead of bare int.
4965 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
4966 Use gdb_disassembly_flags instead of bare int.
4967 * target-debug.h (target_debug_print_gdb_disassembly_flags):
4968 Define.
4969 * target-delegates.c: Regenerate.
4970 * target.c (target_insn_history, target_insn_history_from)
4971 (target_insn_history_range): Use gdb_disassembly_flags instead of
4972 bare int.
4973 * target.h: Include "disasm.h".
4974 (struct target_ops) <to_insn_history, to_insn_history_from,
4975 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
4976 int.
4977 (target_insn_history, target_insn_history_from)
4978 (target_insn_history_range): Use gdb_disassembly_flags instead of
4979 bare int.
4980
4981 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
4982
4983 * cli/cli-script.c (build_command_line): For if/while commands,
4984 check whether args is empty.
4985
4986 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
4987
4988 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
4989 (enum command_control_type): Likewise.
4990 (struct command_line): Likewise.
4991 (free_command_lines): Likewise.
4992 (struct command_lines_deleter): Likewise.
4993 (command_line_up): Likewise.
4994 (read_command_lines): Likewise.
4995 (read_command_lines_1): Likewise.
4996 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
4997 (enum command_control_type): Likewise.
4998 (struct command_line): Likewise.
4999 (free_command_lines): Likewise.
5000 (struct command_lines_deleter): Likewise.
5001 (command_line_up): Likewise.
5002 (read_command_lines): Likewise.
5003 (read_command_lines_1): Likewise.
5004 * breakpoint.h: Include cli/cli-script.h.
5005 * extension-priv.h: Likewise.
5006 * gdbcmd.h: Likewise.
5007
5008 2017-09-04 Pedro Alves <palves@redhat.com>
5009
5010 * ada-lang.c (is_known_support_routine): Move sal declaration to
5011 where it is initialized.
5012 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
5013 (parse_breakpoint_sals, decode_static_tracepoint_spec)
5014 (clear_command, update_static_tracepoint): Remove init_sal
5015 references. Move declarations closer to initializations.
5016 * cli/cli-cmds.c (list_command): Move sal declarations closer to
5017 initializations.
5018 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
5019 references. Move sal declarations closer to initializations.
5020 * frame.c (find_frame_sal): Return a symtab_and_line via function
5021 return instead of output parameter. Remove init_sal references.
5022 * frame.h (find_frame_sal): Return a symtab_and_line via function
5023 return instead of output parameter.
5024 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
5025 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
5026 instead of memset.
5027 (gdbscm_find_pc_line): Remove init_sal reference.
5028 * infcall.c (call_function_by_hand_dummy): Remove init_sal
5029 references. Move declarations closer to initializations.
5030 * infcmd.c (set_step_frame): Update. Move declarations closer to
5031 initializations.
5032 (finish_backward): Remove init_sal references. Move declarations
5033 closer to initializations.
5034 * infrun.c (process_event_stop_test, handle_step_into_function)
5035 (insert_hp_step_resume_breakpoint_at_frame)
5036 (insert_step_resume_breakpoint_at_caller): Likewise.
5037 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
5038 (symbol_to_sal): Likewise.
5039 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
5040 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
5041 to its initialization.
5042 * reverse.c (save_bookmark_command): Use new/delete. Remove
5043 init_sal references. Move declarations closer to initializations.
5044 * source.c (get_current_source_symtab_and_line): Remove brace
5045 initialization.
5046 (set_current_source_symtab_and_line): Now takes the sal by const
5047 reference. Remove brace initialization.
5048 (line_info): Remove init_sal reference.
5049 * source.h (set_current_source_symtab_and_line): Now takes a
5050 symtab_and_line via const reference.
5051 * stack.c (set_current_sal_from_frame): Adjust.
5052 (print_frame_info): Adjust.
5053 (get_last_displayed_sal): Return the sal via function return
5054 instead of via output parameter. Simplify.
5055 (frame_info): Adjust.
5056 * stack.h (get_last_displayed_sal): Return the sal via function
5057 return instead of via output parameter.
5058 * symtab.c (init_sal): Delete.
5059 (find_pc_sect_line): Remove init_sal references. Move
5060 declarations closer to initializations.
5061 (find_function_start_sal): Remove init_sal references. Move
5062 declarations closer to initializations.
5063 * symtab.h (struct symtab_and_line): In-class initialize all
5064 fields.
5065 * tracepoint.c (set_traceframe_context)
5066 (print_one_static_tracepoint_marker): Remove init_sal references.
5067 Move declarations closer to initializations.
5068 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
5069 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
5070 declarations closer to initializations.
5071 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
5072 init_sal references. Adjust.
5073
5074 2017-09-04 Pedro Alves <palves@redhat.com>
5075
5076 * ax-gdb.c (agent_command_1): Use range-for.
5077 * break-catch-throw.c (re_set_exception_catchpoint): Update.
5078 * breakpoint.c: Include "common/array-view.h".
5079 (init_breakpoint_sal, create_breakpoint_sal): Change sals
5080 parameter from struct symtabs_and_lines to
5081 array_view<symtab_and_line>. Adjust. Use range-for. Update.
5082 (breakpoint_sals_to_pc): Change sals parameter from struct
5083 symtabs_and_lines to std::vector reference.
5084 (check_fast_tracepoint_sals): Change sals parameter from struct
5085 symtabs_and_lines to std::array_view. Use range-for.
5086 (decode_static_tracepoint_spec): Return a std::vector instead of
5087 symtabs_and_lines. Update.
5088 (create_breakpoint): Update.
5089 (break_range_command, until_break_command, clear_command): Update.
5090 (base_breakpoint_decode_location, bkpt_decode_location)
5091 (bkpt_probe_create_sals_from_location)
5092 (bkpt_probe_decode_location, tracepoint_decode_location)
5093 (tracepoint_probe_decode_location)
5094 (strace_marker_create_sals_from_location): Return a std::vector
5095 instead of symtabs_and_lines.
5096 (strace_marker_create_breakpoints_sal): Update.
5097 (strace_marker_decode_location): Return a std::vector instead of
5098 symtabs_and_lines. Update.
5099 (update_breakpoint_locations): Change struct symtabs_and_lines
5100 parameters to gdb::array_view. Adjust.
5101 (location_to_sals): Return a std::vector instead of
5102 symtabs_and_lines. Update.
5103 (breakpoint_re_set_default): Use std::vector instead of struct
5104 symtabs_and_lines.
5105 (decode_location_default): Return a std::vector instead of
5106 symtabs_and_lines. Update.
5107 * breakpoint.h: Include "common/array-view.h".
5108 (struct breakpoint_ops) <decode_location>: Now returns a
5109 std::vector instead of returning a symtabs_and_lines via output
5110 parameter.
5111 (update_breakpoint_locations): Change sals parameters to use
5112 gdb::array_view.
5113 * cli/cli-cmds.c (edit_command, list_command): Update to use
5114 std::vector and gdb::array_view.
5115 (ambiguous_line_spec): Adjust to use gdb::array_view and
5116 range-for.
5117 (compare_symtabs): Rename to ...
5118 (cmp_symtabs): ... this. Change parameters to symtab_and_line
5119 const reference and adjust.
5120 (filter_sals): Rewrite using std::vector and standard algorithms.
5121 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
5122 (jump_command): Update to use std::vector.
5123 * linespec.c (struct linespec_state) <canonical_names>: Update
5124 comment.
5125 (add_sal_to_sals_basic): Delete.
5126 (add_sal_to_sals, filter_results, convert_results_to_lsals)
5127 (decode_line_2, create_sals_line_offset)
5128 (convert_address_location_to_sals, convert_linespec_to_sals)
5129 (convert_explicit_location_to_sals, parse_linespec)
5130 (event_location_to_sals, decode_line_full, decode_line_1)
5131 (decode_line_with_current_source)
5132 (decode_line_with_last_displayed, decode_objc)
5133 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
5134 (linespec_result::~linespec_result): Adjust to use std::vector
5135 instead of symtabs_and_lines.
5136 * linespec.h (linespec_sals::sals): Now a std::vector.
5137 (struct linespec_result): Use std::vector, bool, and in-class
5138 initialization.
5139 (decode_line_1, decode_line_with_current_source)
5140 (decode_line_with_last_displayed): Return std::vector.
5141 * macrocmd.c (info_macros_command): Use std::vector.
5142 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
5143 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
5144 std::vector.
5145 * probe.h (parse_probes): Return a std::vector.
5146 * python/python.c (gdbpy_decode_line): Use std::vector and
5147 gdb::array_view.
5148 * source.c (select_source_symtab, line_info): Use std::vector.
5149 * stack.c (func_command): Use std::vector.
5150 * symtab.h (struct symtabs_and_lines): Delete.
5151 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
5152
5153 2017-09-04 Pedro Alves <palves@redhat.com>
5154
5155 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5156 unittests/array-view-selftests.c.
5157 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
5158 * common/array-view.h: New file.
5159 * unittests/array-view-selftests.c: New file.
5160
5161 2017-09-04 Pedro Alves <palves@redhat.com>
5162
5163 * cli/cli-cmds.c (edit_command): Pass message to
5164 ambiguous_line_spec.
5165 (list_command): Pass message to ambiguous_line_spec. Say
5166 "first"/"last" instead of "start" and "end" to be consistent with
5167 the manual.
5168 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
5169 them to print formatted message.
5170
5171 2017-09-04 Pedro Alves <palves@redhat.com>
5172
5173 * btrace.c (ftrace_add_pt): Pass btrace_insn to
5174 ftrace_update_insns by reference instead of pointer.
5175
5176 2017-09-04 Yao Qi <yao.qi@linaro.org>
5177
5178 * i386-go32-tdep.c: Include x86-xstate.h.
5179 (i386_go32_init_abi): Call i386_target_description.
5180 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
5181 if xcr0 is X86_XSTATE_X87_MASK.
5182 * i386-tdep.h (tdesc_i386): Remove the declaration.
5183 (tdesc_i386_mmx): Likewise.
5184
5185 2017-09-04 Yao Qi <yao.qi@linaro.org>
5186
5187 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
5188 X86_XSTATE_SSE_MASK instead of 0.
5189
5190 2017-09-04 Yao Qi <yao.qi@linaro.org>
5191
5192 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
5193 i386_target_description.
5194 * i386-fbsd-nat.c (i386fbsd_read_description): Call
5195 i386_target_description.
5196 * i386-tdep.c (i386_gdbarch_init): Likewise.
5197
5198 2017-09-04 Yao Qi <yao.qi@linaro.org>
5199
5200 * amd64-darwin-tdep.c: Include "x86-xstate.h".
5201 (x86_darwin_init_abi_64): Call amd64_target_description.
5202 * amd64-dicos-tdep.c: Likewise.
5203 * amd64-fbsd-nat.c: Likewise.
5204 * amd64-fbsd-tdep.c: Likewise.
5205 * amd64-nbsd-tdep.c: Likewise.
5206 * amd64-obsd-tdep.c: Likewise.
5207 * amd64-sol2-tdep.c: Likewise.
5208 * amd64-windows-tdep.c: Likewise.
5209 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
5210
5211 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
5212
5213 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
5214 (btrace_function) <insn>: Change type to use std::vector.
5215 * btrace.c (ftrace_debug, ftrace_call_num_insn,
5216 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
5217 ftrace_update_insns, ftrace_compute_global_level_offset,
5218 btrace_stitch_bts, btrace_clear, btrace_insn_get,
5219 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
5220 change to std::vector.
5221 (ftrace_update_insns): Adjust to change to std::vector, change
5222 type of INSN parameter.
5223 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
5224 * record-btrace.c (btrace_call_history_insn_range,
5225 btrace_compute_src_line_range,
5226 record_btrace_frame_prev_register): Adjust to change to
5227 std::vector.
5228 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
5229 to change to std::vector.
5230
5231 2017-09-03 Tom Tromey <tom@tromey.com>
5232
5233 * corefile.c (reopen_exec_file): Use std::string.
5234
5235 2017-09-03 Tom Tromey <tom@tromey.com>
5236
5237 * compile/compile.c (compile_register_name_mangled): Return
5238 std::string.
5239 * compile/compile-loc2c.c (pushf_register_address): Update.
5240 (pushf_register): Update.
5241 * compile/compile-c-types.c (convert_array): Update.
5242 * compile/compile-c-symbols.c (generate_vla_size): Update.
5243 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
5244 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
5245 (convert_one_symbol): Update.
5246 (generate_c_for_for_one_variable): Update.
5247 * compile/compile-c-support.c (c_get_range_decl_name): Return a
5248 std::string.
5249 (generate_register_struct): Update.
5250 * compile/compile-internal.h (c_get_range_decl_name): Return a
5251 std::string.
5252 (compile_register_name_mangled): Return std::string.
5253
5254 2017-09-03 Tom Tromey <tom@tromey.com>
5255
5256 * utils.c (perror_string): Return a std::string.
5257 (throw_perror_with_name, perror_warning_with_name): Update.
5258
5259 2017-09-03 Tom Tromey <tom@tromey.com>
5260
5261 * demangle.c (demangle_command): Use std::string,
5262 unique_xmalloc_ptr.
5263
5264 2017-09-03 Tom Tromey <tom@tromey.com>
5265
5266 * cli/cli-setshow.c (do_set_command): Use std::string.
5267
5268 2017-09-03 Tom Tromey <tom@tromey.com>
5269
5270 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
5271
5272 2017-09-03 Tom Tromey <tom@tromey.com>
5273
5274 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
5275
5276 2017-09-03 Tom Tromey <tom@tromey.com>
5277
5278 * mi/mi-cmd-env.c (env_execute_cli_command): Use
5279 gdb::unique_xmalloc_ptr.
5280
5281 2017-09-03 Tom Tromey <tom@tromey.com>
5282
5283 * thread.c (print_thread_info_1): Use string_printf.
5284 (thread_apply_command, thread_apply_all_command): Use
5285 std::string.
5286
5287 2017-09-03 Tom Tromey <tom@tromey.com>
5288
5289 * valprint.c (val_print_string): Update.
5290 * gdbcore.h (memory_error_message): Return std::string.
5291 * corefile.c (memory_error_message): Return std::string.
5292 (memory_error): Update.
5293 * breakpoint.c (insert_bp_location): Update.
5294
5295 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
5296
5297 * target/waitstatus.h (target_waitstatus_to_string): Change
5298 return type to std::string.
5299 * target/waitstatus.c (target_waitstatus_to_string): Return
5300 std::string.
5301 * target.h (target_waitstatus_to_string): Remove declaration.
5302 * infrun.c (resume, clear_proceed_status_thread,
5303 print_target_wait_results, do_target_wait, save_waitstatus,
5304 stop_all_threads): Adjust.
5305 * record-btrace.c (record_btrace_wait): Adjust.
5306 * target-debug.h
5307 (target_debug_print_struct_target_waitstatus_p): Adjust.
5308
5309 2017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
5310
5311 PR gdb/22046
5312 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
5313 detection.
5314
5315 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
5316
5317 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
5318 for setting/unsetting environment variables on the remote target.
5319 (New remote packets): Add entries for QEnvironmentHexEncoded,
5320 QEnvironmentUnset and QEnvironmentReset.
5321 * common/environ.c (gdb_environ::operator=): Extend method to
5322 handle m_user_set_env_list and m_user_unset_env_list.
5323 (gdb_environ::clear): Likewise.
5324 (match_var_in_string): Change type of first parameter from 'char
5325 *' to 'const char *'.
5326 (gdb_environ::set): Extend method to handle
5327 m_user_set_env_list and m_user_unset_env_list.
5328 (gdb_environ::unset): Likewise.
5329 (gdb_environ::clear_user_set_env): New method.
5330 (gdb_environ::user_set_envp): Likewise.
5331 (gdb_environ::user_unset_envp): Likewise.
5332 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
5333 m_user_unset_env_list on move constructor/assignment.
5334 (unset): Add new default parameter 'update_unset_list = true'.
5335 (clear_user_set_env): New method.
5336 (user_set_envp): Likewise.
5337 (user_unset_envp): Likewise.
5338 (m_user_set_env_list): New std::set.
5339 (m_user_unset_env_list): Likewise.
5340 * common/rsp-low.c (hex2str): New function.
5341 (bin2hex): New overload for bin2hex function.
5342 * common/rsp-low.c (hex2str): New prototype.
5343 (str2hex): New overload prototype.
5344 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
5345 QEnvironmentUnset and QEnvironmentReset.
5346 (remote_protocol_features): Add QEnvironmentHexEncoded,
5347 QEnvironmentUnset and QEnvironmentReset packets.
5348 (send_environment_packet): New function.
5349 (extended_remote_environment_support): Likewise.
5350 (extended_remote_create_inferior): Call
5351 extended_remote_environment_support.
5352 (_initialize_remote): Add QEnvironmentHexEncoded,
5353 QEnvironmentUnset and QEnvironmentReset packet configs.
5354 * unittests/environ-selftests.c (gdb_selftest_env_var):
5355 New variable.
5356 (test_vector_initialization): New function.
5357 (test_init_from_host_environ): Likewise.
5358 (test_reinit_from_host_environ): Likewise.
5359 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
5360 Likewise.
5361 (test_unset_set_empty_vector): Likewise.
5362 (test_vector_clear): Likewise.
5363 (test_std_move): Likewise.
5364 (test_move_constructor):
5365 (test_self_move): Likewise.
5366 (test_set_unset_reset): Likewise.
5367 (run_tests): Rewrite in terms of the functions above.
5368
5369 2017-08-31 Weimin Pan <weimin.pan@oracle.com>
5370
5371 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
5372 (adi_available): Use a temp variable of type CORE_ADDR as argument
5373 3 when calling target_auxv_search.
5374 (adi_normalize_address): Use masks and xor operators to calculate
5375 normalized address.
5376 (adi_read_versions, adi_write_versions, adi_print_versions)
5377 (do_examine, do_assign): Use paddress.
5378
5379 2017-08-29 John Baldwin <jhb@FreeBSD.org>
5380
5381 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
5382 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
5383 out of loop and add supply of FIR.
5384 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
5385 add collect of FIR.
5386
5387 2017-08-28 Simon Marchi <simon.marchi@ericsson.com>
5388
5389 PR gdb/21827
5390 * cli/cli-script.c (define_command): Don't convert command name
5391 to lower case.
5392
5393 2017-08-25 Joel Brobecker <brobecker@adacore.com>
5394
5395 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
5396 Update all callers accordingly. Remove all code blocks handling
5397 the case where DISPP is not NULL.
5398
5399 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
5400
5401 PR symtab/22003
5402 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
5403 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
5404 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
5405
5406 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
5407
5408 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
5409 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
5410 (read_comp_units_from_section): New parameter abbrev_section, use
5411 read_and_check_comp_unit_head, allocate signatured_type if needed.
5412 (create_all_comp_units): Update read_comp_units_from_section caller.
5413
5414 2017-08-23 Pedro Alves <palves@redhat.com>
5415
5416 PR remote/21852
5417 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
5418 to null_ptid and switch to thread without reading the registers
5419 after adding the inferior.
5420
5421 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
5422
5423 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
5424 compile-gcc.
5425 * compile/compile.c (compile_gcc, show_compile_gcc): New.
5426 (compile_to_object): Implement compile_gcc.
5427 (_initialize_compile): Install "set compile-gcc". Initialize
5428 compile_gcc.
5429
5430 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
5431
5432 * compile/compile.c (compile_to_object): Conditionally call
5433 set_verbose. Conditionally call compile or compile_v0.
5434
5435 2017-08-07 Weimin Pan <weimin.pan@oracle.com>
5436
5437 * sparc64-tdep.h: (adi_normalize_address): New export.
5438 * sparc-nat.h: (open_adi_tag_fd): New export.
5439 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
5440 * sparc64-linux-tdep.c:
5441 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
5442 (sparc64_linux_handle_segmentation_fault): New function.
5443 (sparc64_linux_init_abi): Register
5444 sparc64_linux_handle_segmentation_fault
5445 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
5446 (sparc64_addr_bits_remove): New function.
5447 (sparc64_init_abi): Register sparc64_addr_bits_remove.
5448 (MAX_PROC_NAME_SIZE): New macro.
5449 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
5450 (sparc64adilist): New variable.
5451 (adi_proc_list): New variable.
5452 (find_adi_info): New function.
5453 (add_adi_info): New function.
5454 (get_adi_info_proc): New function.
5455 (get_adi_info): New function.
5456 (info_adi_command): New function.
5457 (read_maps_entry): New function.
5458 (adi_available): New function.
5459 (adi_normalize_address): New function.
5460 (adi_align_address): New function.
5461 (adi_convert_byte_count): New function.
5462 (adi_tag_fd): New function.
5463 (adi_is_addr_mapped): New function.
5464 (adi_read_versions): New function.
5465 (adi_write_versions): New function.
5466 (adi_print_versions): New function.
5467 (do_examine): New function.
5468 (do_assign): New function.
5469 (adi_examine_command): New function.
5470 (adi_assign_command): New function.
5471 (_initialize_sparc64_adi_tdep): New function.
5472
5473 2017-08-22 Simon Marchi <simon.marchi@ericsson.com>
5474
5475 * breakpoint.c (breakpoints_info): Rename to ...
5476 (info_breakpoints_command): ... this.
5477 (watchpoints_info): Rename to ...
5478 (info_watchpoints_command): ... this.
5479 (tracepoints_info): Rename to ...
5480 (info_tracepoints_command): ... this.
5481 (_initialize_breakpoint): Adjust.
5482 * dcache.c (dcache_info): Rename to ...
5483 (info_display_command): ... this.
5484 (_initialize_dcache): Adjust.
5485 * frame.h (args_info): Rename to ...
5486 (info_args_command): ... this.
5487 (locals_info): Rename to ...
5488 (info_locals_command): ... this.
5489 * infcmd.c (nofp_registers_info): Rename to ...
5490 (info_registers_command): ... this.
5491 (float_info): Rename to ...
5492 (info_float_command): ... this.
5493 (program_info): Rename to ...
5494 (info_program_command): ... this.
5495 (all_registers_info): Rename to ...
5496 (info_all_registers_command): ... this.
5497 (vector_info): Rename to ...
5498 (info_vector_command): ... this.
5499 (float_info): Rename to ...
5500 (info_float_command): ... this.
5501 (_initialize_infcmd): Adjust.
5502 * inferior.h (term_info): Rename to ...
5503 (info_terminal_command): ... this.
5504 * inflow.c (term_info): Rename to ...
5505 (info_terminal_command): ... this.
5506 (_initialize_inflow): Adjust.
5507 * infrun.c (signals_info): Rename to ...
5508 (info_signals_command): ... this.
5509 (_initialize_infrun): Adjust.
5510 * objc-lang.c (classes_info): Rename to ...
5511 (info_classes_command): ... this.
5512 (selectors_info): Rename to ...
5513 (info_selectors_command): ... this.
5514 (_initialize_objc_language): Adjust.
5515 * printcmd.c (sym_info): Rename to ...
5516 (info_symbol_command): ... this.
5517 (address_info): Rename to ...
5518 (info_address_command): ... this.
5519 (display_info): Rename to ...
5520 (info_display_command): ... this.
5521 (_initialize_printcmd): Adjust.
5522 * reverse.c (bookmarks_info): Rename to ...
5523 (info_breakpoints_command): ... this.
5524 (_initialize_reverse): Adjust.
5525 * ser-go32.c (dos_info): Rename to ...
5526 (info_serial_command): ... this.
5527 (_initialize_ser_dos): Adjust.
5528 * skip.c (skip_info): Rename to ...
5529 (info_skip_command): ... this.
5530 (_initialize_step_skip): Adjust.
5531 * source.c (line_info): Rename to ...
5532 (info_line_command): ... this.
5533 (source_info): Rename to ...
5534 (info_source_command)
5535 * stack.c (frame_info): Rename to ...
5536 (info_frame_command): ... this.
5537 (locals_info): Rename to ...
5538 (info_locals_command): ... this.
5539 (args_info): Rename to ...
5540 (info_args_command): ... this.
5541 (_initialize_stack): Adjust.
5542 * symtab.c (sources_info): Rename to ...
5543 (info_sources_command): ... this.
5544 (variables_info): Rename to ...
5545 (info_variables_command): ... this.
5546 (functions_info): Rename to ...
5547 (info_functions_command): ... this.
5548 (types_info): Rename to ...
5549 (info_types_command): ... this.
5550 (_initialize_symtab): Adjust.
5551 * target.c (target_info): Rename to ...
5552 (info_target_command): ... this.
5553 (initialize_targets): Adjust.
5554 * tracepoint.c (tvariables_info): Rename to ...
5555 (info_tvariables_command): ... this.
5556 (scope_info): Rename to ...
5557 (info_scope_command): ... this.
5558 (trace_dump_actions): Adjust.
5559 (_initialize_tracepoint): Adjust.
5560
5561 2017-08-22 Tom Tromey <tom@tromey.com>
5562
5563 * breakpoint.h (install_breakpoint): Update.
5564 * breakpoint.c (add_solib_catchpoint): Update.
5565 (install_breakpoint): Change argument to a std::unique_ptr.
5566 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
5567 (create_breakpoint_sal, create_breakpoint): Update.
5568 (watch_command_1, catch_exec_command_1)
5569 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
5570 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
5571 Return the breakpoint.
5572 (set_raw_breakpoint_without_location, set_raw_breakpoint)
5573 (new_single_step_breakpoint): Update.
5574 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
5575 std::unique_ptr.
5576 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
5577 std::unique_ptr.
5578 * break-catch-sig.c (create_signal_catchpoint): Use
5579 std::unique_ptr.
5580 * ada-lang.c (create_ada_exception_catchpoint): Use
5581 std::unique_ptr.
5582
5583 2017-08-22 Tom Tromey <tom@tromey.com>
5584
5585 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
5586
5587 2017-08-22 Tom Tromey <tom@tromey.com>
5588
5589 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
5590 (lookup_partial_symbol): Update.
5591
5592 2017-08-22 Tom Tromey <tom@tromey.com>
5593
5594 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
5595 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
5596 (find_and_open_source, symtab_to_fullname): Update.
5597 * psymtab.c (psymtab_to_fullname): Update.
5598
5599 2017-08-22 Tom Tromey <tom@tromey.com>
5600
5601 * exec.c (exec_file_attach): Update.
5602 * linux-thread-db.c (try_thread_db_load): Update.
5603 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
5604 * utils.c (gdb_realpath): Change return type.
5605 (gdb_realpath_keepfile): Update.
5606 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
5607 (_initialize_utils): Register the new self test.
5608 * source.c (openp): Update.
5609 (find_and_open_source): Update.
5610 * nto-tdep.c (nto_find_and_open_solib): Update.
5611 * main.c (set_gdb_data_directory): Update.
5612 (captured_main_1): Update.
5613 * dwarf2read.c (dwarf2_get_dwz_file): Update
5614 (dw2_map_symbol_filenames): Update.
5615 * auto-load.c (auto_load_safe_path_vec_update): Update.
5616 (filename_is_in_auto_load_safe_path_vec): Change type of
5617 "filename_realp".
5618 (auto_load_objfile_script): Update.
5619 (file_is_auto_load_safe): Update. Use std::string.
5620 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
5621
5622 2017-08-22 Tom Tromey <tom@tromey.com>
5623
5624 * utils.c (gdb_realpath_keepfile): Return a
5625 gdb::unique_xmalloc_ptr.
5626 * exec.c (exec_file_attach): Update.
5627 * utils.h (gdb_realpath_keepfile): Return a
5628 gdb::unique_xmalloc_ptr.
5629
5630 2017-08-22 Tom Tromey <tom@tromey.com>
5631
5632 * compile/compile.c (compile_file_command): Use
5633 gdb::unique_xmalloc_ptr, std::string.
5634 * utils.c (gdb_abspath): Change return type.
5635 * source.c (openp): Update.
5636 * objfiles.c (allocate_objfile): Update.
5637 * main.c (set_gdb_data_directory): Update.
5638 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
5639
5640 2017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
5641
5642 * cli-cmds.c (list_commands): List actual code around more than
5643 one location.
5644
5645 2017-08-21 John Baldwin <jhb@FreeBSD.org>
5646
5647 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
5648
5649 2017-08-21 Pedro Alves <palves@redhat.com>
5650
5651 PR gdb/19487
5652 * c-exp.y (variable production): Handle function aliases.
5653 * minsyms.c (msymbol_is_text): New function.
5654 * minsyms.h (msymbol_is_text): Declare.
5655 * symtab.c (find_function_alias_target): New function.
5656 * symtab.h (find_function_alias_target): Declare.
5657
5658 2017-08-21 Pedro Alves <palves@redhat.com>
5659
5660 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
5661 typedefs.
5662 * typeprint.c (whatis_exp): If handling "whatis", and expression
5663 is OP_TYPE, strip one typedef level. Otherwise don't strip
5664 typedefs here.
5665 * valops.c (value_cast): Save "to" type before resolving
5666 stubs/typedefs. Use that type as resulting value's type.
5667
5668 2017-08-18 Tom Tromey <tom@tromey.com>
5669 Pedro Alves <palves@redhat.com>
5670
5671 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
5672 * sol-thread.c (sol_thread_resume, sol_thread_wait)
5673 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
5674 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
5675 * proc-service.c (ps_xfer_memory): Use scoped_restore.
5676 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
5677 (linux_get_siginfo_data): Add "thread" argument. Use
5678 scoped_restore.
5679 * linux-nat.c (linux_child_follow_fork)
5680 (check_stopped_by_watchpoint): Use scoped_restore.
5681 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
5682 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
5683 (restore_inferior_ptid, save_inferior_ptid): Remove.
5684 * btrace.c (btrace_fetch): Use scoped_restore.
5685 * bsd-uthread.c (bsd_uthread_fetch_registers)
5686 (bsd_uthread_store_registers): Use scoped_restore.
5687 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
5688 scoped_restore.
5689 * aix-thread.c (aix_thread_resume, aix_thread_wait)
5690 (aix_thread_xfer_partial): Use scoped_restore.
5691 * inferior.h (save_inferior_ptid): Remove.
5692
5693 2017-08-18 Yao Qi <yao.qi@linaro.org>
5694
5695 PR tdep/21818
5696 * arm-tdep.c (gdb_print_insn_arm): Mark
5697 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
5698
5699 2017-08-18 Yao Qi <yao.qi@linaro.org>
5700
5701 * NEWS: Mention GDBserver's new option "--selftest".
5702 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
5703 * selftest.c: Move it to common/selftest.c.
5704 * selftest.h: Move it to common/selftest.h.
5705 * selftest-arch.c (reset): New function.
5706 (tests_with_arch): Call reset.
5707
5708 2017-08-18 Yao Qi <yao.qi@linaro.org>
5709
5710 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
5711 instead of exception_fprintf and printf_filtered.
5712
5713 2017-08-18 Yao Qi <yao.qi@linaro.org>
5714
5715 * selftest.c (register_self_test): Rename it to
5716 selftests::register_test.
5717 (run_self_tests): selftest::run_tests.
5718 * selftest.h: Update declarations.
5719 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
5720 selftests::register_test_foreach_arch.
5721 * selftest-arch.h: Update declaration.
5722 * aarch64-tdep.c: Update.
5723 * arm-tdep.c: Likewise.
5724 * disasm-selftests.c: Likewise.
5725 * dwarf2loc.c: Likewise.
5726 * dwarf2-frame.c: Likewise.
5727 * findvar.c: Likewise.
5728 * gdbarch-selftests.c: Likewise.
5729 * maint.c (maintenance_selftest): Likewise.
5730 * regcache.c: Likewise.
5731 * rust-exp.y: Likewise.
5732 * selftest-arch.c: Likewise.
5733 * unittests/environ-selftests.c: Likewise.
5734 * unittests/function-view-selftests.c: Likewise.
5735 * unittests/offset-type-selftests.c: Likewise.
5736 * unittests/optional-selftests.c: Likewise.
5737 * unittests/scoped_restore-selftests.c: Likewise.
5738 * utils-selftests.c: Likewise.
5739
5740 2017-08-17 Pedro Alves <palves@redhat.com>
5741
5742 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
5743 local.
5744
5745 2017-08-17 Pedro Alves <palves@redhat.com>
5746
5747 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
5748 field.
5749 (reset_die_in_process): Delete, replaced by ...
5750 (process_die_scope): ... this new class. Make it responsible for
5751 freeing cu->line_header too.
5752 (process_die): Use process_die_scope.
5753 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
5754 cu->line_header_die_owner. Don't release the line header if it's
5755 owned by the CU.
5756 (setup_type_unit_groups): Make the CU/DIE own the line header.
5757 Don't release the line header here.
5758
5759 2017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
5760
5761 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
5762
5763 2017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
5764
5765 * NEWS: Mention new shortcuts for nexti and stepi in TUI
5766 Single-Key mode
5767
5768 2017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
5769
5770 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
5771 mode command list.
5772
5773 2017-08-15 Stafford Horne <shorne@gmail.com>
5774
5775 * MAINTAINERS (Write After Approval): Add Stafford Horne.
5776
5777 2017-08-15 Stafford Horne <shorne@gmail.com>
5778
5779 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
5780
5781 2017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
5782
5783 PR gdb/21954
5784 * infcmd.c (unset_environment_command): Use the 'clear' method on
5785 the environment instead of resetting it.
5786
5787 2017-08-15 John Baldwin <jhb@FreeBSD.org>
5788
5789 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
5790 platforms.
5791
5792 2017-08-14 Tom Tromey <tom@tromey.com>
5793
5794 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
5795 (print_binary_chars): Likewise.
5796 (BITS_IN_BYTES): Remove.
5797
5798 2017-08-14 Tom Tromey <tom@tromey.com>
5799
5800 PR gdb/21675
5801 * valprint.c (LOW_ZERO): Change value to 034.
5802 (print_octal_chars): Add static_asserts for octal constants.
5803 * printcmd.c (print_scalar_formatted): Add 'd' case.
5804
5805 2017-08-11 Tom Tromey <tom@tromey.com>
5806
5807 * symfile.c (add_symbol_file_command): Use std::vector.
5808
5809 2017-08-14 Tom Tromey <tom@tromey.com>
5810
5811 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
5812 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
5813 std::move.
5814 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
5815
5816 2017-08-11 Pedro Alves <palves@redhat.com>
5817
5818 * infrun.c (process_event_stop_test): Adjust
5819 function_name_is_marked_for_skip call.
5820 * skip.c: Include <list>.
5821 (skiplist_entry): Make it a class with private fields, and
5822 getters/setters.
5823 (skiplist_entry_chain): Delete.
5824 (skiplist_entries): New.
5825 (skiplist_entry_count): Delete.
5826 (highest_skiplist_entry_num): New.
5827 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
5828 (add_skiplist_entry): Delete.
5829 (skiplist_entry::skiplist_entry): New.
5830 (skiplist_entry::add_entry): New.
5831 (skip_file_command, skip_function): Adjust.
5832 (compile_skip_regexp): Delete.
5833 (skip_command): Don't compile regexp here. Adjust to use
5834 skiplist_entry::add_entry.
5835 (skip_info): Adjust to use range-for and getters.
5836 (skip_enable_command, skip_disable_command): Adjust to use
5837 range-for and setters.
5838 (skip_delete_command): Adjust to use std::list.
5839 (add_skiplist_entry): Delete.
5840 (skip_file_p): Delete, refactored as ...
5841 (skiplist_entry::do_skip_file_p): ... this new method.
5842 (skip_gfile_p): Delete, refactored as ...
5843 (skiplist_entry::do_gskip_file_p): ... this new method.
5844 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
5845 (skiplist_entry::skip_function_p): ... this new method.
5846 (function_name_is_marked_for_skip): Now returns bool, and takes
5847 the function sal by const reference. Adjust to use range-for and
5848 skiplist_entry methods.
5849 (_initialize_step_skip): Remove references to
5850 skiplist_entry_chain, skiplist_entry_count.
5851 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
5852 takes the function sal by const reference.
5853
5854 2017-08-11 Yao Qi <yao.qi@linaro.org>
5855
5856 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
5857 (dwarf2_frame_cache): Remove reset_cache_cleanup.
5858 (dwarf2_frame_cache):
5859 * frame-unwind.c (frame_unwind_try_unwinder): Catch
5860 RETURN_MASK_ALL and set *this_case to NULL.
5861 * frame-unwind.h: Update comments.
5862
5863 2017-08-11 Yao Qi <yao.qi@linaro.org>
5864
5865 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
5866 (dwarf2_frame_state_copy_regs): Remove.
5867 (dwarf2_frame_state_free_regs): Remove.
5868 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
5869 (dwarf2_restore_rule): Call method .alloc_regs instead of
5870 dwarf2_frame_state_alloc_regs.
5871 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
5872 constructor. Call std::move.
5873 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
5874 (dwarf2_frame_cache): Likewise.
5875
5876 [GDB_SELF_TEST]: Include selftest.h and
5877 selftest-arch.h.
5878 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
5879 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
5880 execute_cfa_program_test.
5881
5882 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
5883 copy ctor, assignment operator, move assignment.
5884 <alloc_regs>: New method.
5885 <swap>: New method.
5886 (struct dwarf2_frame_state): Delete dtor.
5887 (dwarf2_frame_state_alloc_regs): Remove declaration.
5888 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
5889 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
5890
5891 2017-08-11 Yao Qi <yao.qi@linaro.org>
5892
5893 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
5894 (dwarf2_frame_state::dwarf2_frame_state): New.
5895 (dwarf2_frame_state::~dwarf2_frame_state): New.
5896 (dwarf2_fetch_cfa_info): Update.
5897 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
5898 rather than a pointer. Update code.
5899 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
5900 dtor.
5901 <data_align, code_align, retaddr_column>: Change them to const.
5902 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
5903 to bool.
5904
5905 2017-08-11 Yao Qi <yao.qi@linaro.org>
5906
5907 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
5908 <loc.exp>: New field.
5909 * dwarf2-frame.c (execute_cfa_program): Update.
5910 (dwarf2_frame_prev_register): Update.
5911
5912 2017-08-10 Pedro Alves <palves@redhat.com>
5913
5914 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
5915
5916 2017-08-09 John Baldwin <jhb@FreeBSD.org>
5917
5918 * fbsd-nat.c (struct fbsd_fork_info): Remove.
5919 (fbsd_pending_children): Use std::list.
5920 (fbsd_remember_child): Likewise.
5921 (fbsd_is_child_pending): Likewise.
5922 (fbsd_pending_vfork_done): Use std::forward_list.
5923 (fbsd_add_vfork_done): Likewise.
5924 (fbsd_is_vfork_done_pending): Likewise.
5925 (fbsd_next_vfork_done): Likewise.
5926
5927 2017-08-09 John Baldwin <jhb@FreeBSD.org>
5928
5929 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
5930 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
5931 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
5932 for `mapfilename'.
5933 (fbsd_xfer_partial): Use gdb::byte_vector.
5934 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
5935
5936 2017-08-09 John Baldwin <jhb@FreeBSD.org>
5937
5938 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
5939 "filestuff.h".
5940 (fbsd_find_memory_regions): Fix `mapfile' initialization.
5941
5942 2017-08-09 Tom Tromey <tom@tromey.com>
5943
5944 * skip.c (skiplist_entry): New constructor.
5945 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
5946 (skiplist_entry::file_is_glob): Now bool.
5947 (skiplist_entry::file, skiplist_entry::function): Now
5948 std::string.
5949 (make_skip_entry): Return a unique_ptr. Use new.
5950 (free_skiplist_entry, free_skiplist_entry_cleanup)
5951 (make_free_skiplist_entry_cleanup): Remove.
5952 (skip_command, skip_disable_command, add_skiplist_entry)
5953 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
5954 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
5955 (function_name_is_marked_for_skip): Update.
5956 (skip_delete_command): Update. Use delete.
5957
5958 2017-08-09 Jiong Wang <jiong.wang@arm.com>
5959
5960 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
5961 (aarch64_linux_core_read_description): New function.
5962 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
5963
5964 2017-08-09 Pedro Alves <palves@redhat.com>
5965
5966 * cp-name-parser.y (cp_comp_to_string): Return a
5967 gdb::unique_xmalloc_ptr<char>.
5968 * cp-support.c (replace_typedefs_qualified_name)
5969 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
5970 (cp_canonicalize_string_full): Use op= instead of explicit
5971 convertion.
5972 (cp_class_name_from_physname, method_name_from_physname)
5973 (cp_func_name, cp_remove_params): Adjust to use
5974 gdb::unique_xmalloc_ptr<char>.
5975 * cp-support.h (cp_comp_to_string): Return a
5976 gdb::unique_xmalloc_ptr<char>.
5977 * python/py-type.c (typy_lookup_type): Adjust to use
5978 gdb::unique_xmalloc_ptr<char>.
5979
5980 2017-08-09 H.J. Lu <hongjiu.lu@intel.com>
5981
5982 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
5983
5984 2017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
5985 Yao Qi <yao.qi@linaro.org>
5986
5987 * cp-support.c (cp_canonicalize_string_full): Use
5988 gdb::unique_xmalloc_ptr<char>.
5989 (cp_canonicalize_string): Likewise.
5990
5991 2017-08-09 Yao Qi <yao.qi@linaro.org>
5992
5993 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
5994 * regformats/i386/amd64-avx-avx512.dat: Remove.
5995 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
5996 * regformats/i386/amd64-avx-mpx.dat:Remove.
5997 * regformats/i386/amd64-avx.dat: Remove.
5998 * regformats/i386/amd64-mpx.dat: Remove.
5999 * regformats/i386/i386-avx-avx512.dat: Remove.
6000 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
6001 * regformats/i386/i386-avx-mpx.dat: Remove.
6002 * regformats/i386/i386-mmx.dat: Remove.
6003 * regformats/i386/i386-mpx.dat: Remove.
6004
6005 2017-08-09 Yao Qi <yao.qi@linaro.org>
6006
6007 * amd64-tdep.h (tdesc_x32): Remove the declaration.
6008 * amd64-tdep.c: Don't include features/i386/x32*.c.
6009 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
6010 functions.
6011 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
6012 and i386/x32-avx-avx512.
6013 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
6014 and i386/x32.xml.
6015 * features/i386/x32-avx-avx512.c: Removed.
6016 * features/i386/x32-avx-avx512.xml: Removed.
6017 * features/i386/x32-avx.c: Removed.
6018 * features/i386/x32-avx.xml: Removed.
6019 * features/i386/x32.c: Removed.
6020 * features/i386/x32.xml: Removed.
6021 * regformats/i386/x32-avx-avx512.dat: Removed.
6022 * regformats/i386/x32-avx.dat: Removed.
6023 * regformats/i386/x32.dat: Removed.
6024
6025 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
6026
6027 PR breakpoints/21886
6028 * mem-break.c (default_memory_insert_breakpoint): Use
6029 `->placed_address' rather than `->reqstd_address' for the
6030 breakpoint location.
6031
6032 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
6033
6034 * arch-utils.c (default_print_insn): Remove arch/mach/endian
6035 assertions.
6036
6037 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
6038
6039 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
6040 a union of `tdep_info', `tdesc_data' and `id'.
6041 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
6042 rather than `info.tdep_info'.
6043 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
6044 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
6045 * i386-tdep.c (i386_gdbarch_init): Likewise.
6046 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
6047 * mips-tdep.c (mips_gdbarch_init): Likewise.
6048 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
6049 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
6050 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
6051 `info.tdep_info'.
6052 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
6053 `info.tdep_info'.
6054 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
6055 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
6056 `info.tdep_info'.
6057 * spu-tdep.c (spu_gdbarch_init): Likewise.
6058 * gdbarch.h: Regenerate.
6059
6060 2017-08-07 Leszek Swirski <leszeks@google.com>
6061
6062 PR symtab/20899
6063 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
6064
6065 2017-08-07 Simon Marchi <simon.marchi@ericsson.com>
6066
6067 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
6068 (gdbsim_open): Rename gdb_argv args object to argv.
6069
6070 2017-08-05 Tom Tromey <tom@tromey.com>
6071
6072 * compile/compile-object-load.c (compile_object_load): Use
6073 gdb::unique_xmalloc_ptr.
6074 * cli/cli-dump.c (scan_filename): Rename from
6075 scan_filename_with_cleanup. Change return type.
6076 (scan_expression): Rename from scan_expression_with_cleanup.
6077 Change return type.
6078 (dump_memory_to_file, dump_value_to_file, restore_command):
6079 Use gdb::unique_xmalloc_ptr. Update.
6080 * cli/cli-cmds.c (find_and_open_script): Use
6081 gdb::unique_xmalloc_ptr.
6082 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
6083 * symmisc.c (maintenance_print_symbols)
6084 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
6085 * symfile.c (symfile_bfd_open, generic_load)
6086 (add_symbol_file_command, remove_symbol_file_command): Use
6087 gdb::unique_xmalloc_ptr.
6088 * source.c (openp): Use gdb::unique_xmalloc_ptr.
6089 * psymtab.c (maintenance_print_psymbols): Use
6090 gdb::unique_xmalloc_ptr.
6091 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
6092 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
6093 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
6094 (reload_shared_libraries_1): Likewise.
6095
6096 2017-08-05 Tom Tromey <tom@tromey.com>
6097
6098 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
6099 (rust_op_vector, rust_set_vector): New typedefs.
6100 (current_parser): New global.
6101 (work_obstack): Change to pointer type. Update all users.
6102 (rust_ast, pstate): Remove globals.
6103 (struct rust_parser): New.
6104 (%union) <params, field_inits>: Change type.
6105 (start, tuple_expr, unit_expr, struct_expr_list, literal)
6106 (field_expr, expr_list, maybe_expr_list, type_list): Update.
6107 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
6108 (convert_params_to_types, convert_params_to_expression): Change
6109 type of "params".
6110 (ast_string): Change type of "fields".
6111 (rust_parse): Make a rust_parser. Remove cleanups.
6112 (rust_lex_tests): Make and install an auto_obstack.
6113
6114 2017-08-04 Yao Qi <yao.qi@linaro.org>
6115
6116 * configure.srv (ipa_x32_linux_regobj): New.
6117 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
6118 instead of X86_TDESC_AVX512.
6119 (initialize_low_tracepoint): Call
6120 init_registers_x32_avx_avx512_linux.
6121
6122 2017-08-04 Yao Qi <yao.qi@linaro.org>
6123
6124 * utils.h (gdb_argv): Add namespace std for nullptr_t.
6125
6126 2017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
6127
6128 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
6129
6130 2017-08-03 Tom Tromey <tom@tromey.com>
6131
6132 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
6133 Remove.
6134 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
6135
6136 2017-08-03 Tom Tromey <tom@tromey.com>
6137
6138 * python/py-param.c (compute_enum_values): Use gdb_argv.
6139
6140 2017-08-03 Tom Tromey <tom@tromey.com>
6141
6142 * utils.h (struct gdb_argv_deleter): New.
6143 (gdb_argv): New class.
6144 * utils.c (gdb_argv::reset): New method.
6145 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
6146 * tracefile.c (tsave_command): Use gdb_argv.
6147 * top.c (new_ui_command): Use gdb_argv.
6148 * symmisc.c (maintenance_print_symbols)
6149 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
6150 * symfile.c (symbol_file_command, generic_load)
6151 (remove_symbol_file_command): Use gdb_argv.
6152 * stack.c (backtrace_command): Use gdb_argv.
6153 * source.c (add_path, show_substitute_path_command)
6154 (unset_substitute_path_command, set_substitute_path_command):
6155 Use gdb_argv.
6156 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
6157 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
6158 * remote.c (extended_remote_run, remote_put_command)
6159 (remote_get_command, remote_delete_command): Use gdb_argv.
6160 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
6161 (gdbsim_open): Use gdb_argv.
6162 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
6163 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
6164 * procfs.c (procfs_info_proc): Use gdb_argv.
6165 * interps.c (interpreter_exec_cmd): Use gdb_argv.
6166 * infrun.c (handle_command): Use gdb_argv.
6167 * inferior.c (add_inferior_command, clone_inferior_command):
6168 Use gdb_argv.
6169 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
6170 * exec.c (exec_file_command): Use gdb_argv.
6171 * cli/cli-cmds.c (alias_command): Use gdb_argv.
6172 * compile/compile.c (build_argc_argv): Use gdb_argv.
6173
6174 2017-08-03 Tom Tromey <tom@tromey.com>
6175
6176 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
6177
6178 2017-08-03 Tom Tromey <tom@tromey.com>
6179
6180 * python/python.c (compute_python_string): Return std::string.
6181 (gdbpy_eval_from_control_command): Update.
6182 (do_start_initialization): Use std::string.
6183 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
6184 xstrprintf.
6185 * python/py-breakpoint.c (local_setattro): Use string_printf, not
6186 xstrprintf.
6187
6188 2017-08-03 Tom Tromey <tom@tromey.com>
6189
6190 * top.h (do_restore_instream_cleanup): Remove.
6191 * top.c (do_restore_instream_cleanup): Remove.
6192 (read_command_file): Use scoped_restore.
6193 * cli/cli-script.c (execute_user_command): Use scoped_restore.
6194
6195 2017-08-03 Tom Tromey <tom@tromey.com>
6196
6197 * cli/cli-script.c (execute_user_command)
6198 (execute_control_command): Use scoped_restore.
6199
6200 2017-08-03 Tom Tromey <tom@tromey.com>
6201
6202 * cli/cli-script.c (do_restore_user_call_depth): Remove.
6203 (execute_user_command): Remove user_call_depth; use
6204 user_args_stack's size instead.
6205
6206 2017-08-03 Tom Tromey <tom@tromey.com>
6207
6208 * top.h (in_user_command): Remove.
6209 * top.c (in_user_command): Remove.
6210 * cli/cli-script.c (do_restore_user_call_depth)
6211 (execute_user_command): Update.
6212
6213 2017-08-03 Tom Tromey <tom@tromey.com>
6214
6215 * valops.c (search_struct_method): Use gdb::byte_vector.
6216 * valarith.c (value_concat): Use std::vector.
6217 * target.c (memory_xfer_partial): Use gdb::byte_vector.
6218 (simple_search_memory): Likewise.
6219 * printcmd.c (find_string_backward): Use gdb::byte_vector.
6220 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
6221 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
6222 * elfread.c (elf_rel_plt_read): Use std::string.
6223 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
6224 * cli/cli-dump.c (restore_section_callback): Use
6225 gdb::byte_vector.
6226
6227 2017-08-03 Tom Tromey <tom@tromey.com>
6228
6229 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
6230
6231 2017-08-03 Tom Tromey <tom@tromey.com>
6232
6233 * tui/tui-regs.c (tui_restore_gdbout): Remove.
6234 (tui_register_format): Use scoped_restore.
6235
6236 2017-08-03 Tom Tromey <tom@tromey.com>
6237
6238 * reverse.c (exec_direction_default): Remove.
6239 (exec_reverse_once): Use scoped_restore.
6240 * remote.c (restore_remote_timeout): Remove.
6241 (remote_flash_erase, remote_flash_write, remote_flash_done)
6242 (readchar, remote_serial_write): Use scoped_restore.
6243 * cli/cli-script.c (struct source_cleanup_lines_args)
6244 (source_cleanup_lines): Remove.
6245 (script_from_file): Use scoped_restore.
6246 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
6247 (source_command): Use scoped_restore.
6248
6249 2017-08-03 Tom Tromey <tom@tromey.com>
6250
6251 * utils.h (make_cleanup_free_so): Remove.
6252 * utils.c (do_free_so, make_cleanup_free_so): Remove.
6253 * solist.h (struct so_deleter): New.
6254 (so_list_up): New typedef.
6255 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
6256
6257 2017-08-03 Tom Tromey <tom@tromey.com>
6258
6259 * utils.h (make_cleanup_restore_current_language): Remove.
6260 * utils.c (do_restore_current_language)
6261 (make_cleanup_restore_current_language): Remove.
6262 * parse.c (parse_exp_in_context_1)
6263 (parse_expression_with_language): Use
6264 scoped_restore_current_language.
6265 * mi/mi-main.c (mi_cmd_execute): Use
6266 scoped_restore_current_language.
6267 * language.h (scoped_restore_current_language): New class.
6268
6269 2017-08-03 Tom Tromey <tom@tromey.com>
6270
6271 * compile/compile.c (cleanup_unlink_file): Remove.
6272 (compile_to_object): Use gdb::unlinker.
6273 (eval_compile_command): Likewise.
6274
6275 2017-08-03 Tom Tromey <tom@tromey.com>
6276
6277 * utils.h (make_cleanup_fclose): Remove.
6278 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
6279
6280 2017-08-03 Tom Tromey <tom@tromey.com>
6281
6282 * top.c (open_terminal_stream): Return gdb_file_up.
6283 (new_ui_command): Update.
6284
6285 2017-08-03 Tom Tromey <tom@tromey.com>
6286
6287 * source.c (print_source_lines_base, forward_search_command)
6288 (reverse_search_command): Use gdb_file_up.
6289
6290 2017-08-03 Tom Tromey <tom@tromey.com>
6291
6292 * fbsd-nat.c (fbsd_find_memory_regions): Update.
6293
6294 2017-08-03 Tom Tromey <tom@tromey.com>
6295
6296 * cli/cli-cmds.c (find_and_open_script): Change return type.
6297 Remove "streamp" and "full_path" parameters.
6298 (source_script_with_search): Update.
6299 * auto-load.c (source_script_file): Update.
6300 * cli/cli-cmds.h (find_and_open_script): Change type.
6301 (open_script): New struct.
6302
6303 2017-08-03 Tom Tromey <tom@tromey.com>
6304
6305 * xml-support.c (xml_fetch_content_from_file): Update.
6306 * ui-file.c (stdio_file::open): Update.
6307 * tracefile-tfile.c (tfile_start): Update.
6308 * remote.c (remote_file_put, remote_file_get): Update.
6309 * nat/linux-procfs.c (linux_proc_get_int)
6310 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
6311 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
6312 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
6313 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
6314 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
6315 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
6316 * linux-nat.c (linux_proc_pending_signals): Update.
6317 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
6318 (file_closer): Remove.
6319 * compile/compile.c (compile_to_object): Update.
6320 * common/filestuff.h (struct gdb_file_deleter): New.
6321 (gdb_file_up): New typedef.
6322 (gdb_fopen_cloexec): Change return type.
6323 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
6324 * cli/cli-dump.c (fopen_with_cleanup): Remove.
6325 (dump_binary_file, restore_binary_file): Update.
6326 * auto-load.c (auto_load_objfile_script_1): Update.
6327
6328 2017-08-03 Tom Tromey <tom@tromey.com>
6329
6330 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
6331 (info_static_tracepoint_markers_command): Likewise.
6332 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
6333 * skip.c (skip_info): Use ui_out_emit_table.
6334 * progspace.c (print_program_space): Use ui_out_emit_table.
6335 * osdata.c (info_osdata): Use ui_out_emit_table.
6336 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
6337 ui_out_emit_table.
6338 * linux-thread-db.c (info_auto_load_libthread_db): Use
6339 ui_out_emit_table.
6340 * inferior.c (print_inferior): Use ui_out_emit_table.
6341 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
6342 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
6343 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
6344 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
6345 * ui-out.h (class ui_out_emit_table): New.
6346
6347 2017-08-02 Maciej W. Rozycki <macro@imgtec.com>
6348
6349 * mips-tdep.c (mips_fpu_type_str): New function.
6350 (mips_dump_tdep): Call it.
6351
6352 2017-08-01 Maciej W. Rozycki <macro@imgtec.com>
6353
6354 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
6355 `->mips_fpu_type'.
6356
6357 2017-07-31 Xavier Roirand <roirand@adacore.com>
6358
6359 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
6360
6361 2017-07-27 Xavier Roirand <roirand@adacore.com>
6362
6363 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
6364
6365 2017-07-26 Yao Qi <yao.qi@linaro.org>
6366
6367 * cli/cli-cmds.c (maintenancechecklist): New variable.
6368 * gdbcmd.h (maintenancechecklist): Declare it.
6369 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
6370 Call i386_linux_read_description with different masks.
6371 * maint.c (maintenance_check_command): New function.
6372 (_initialize_maint_cmds): Call add_prefix_cmd.
6373 * target-descriptions.c (tdesc_reg): override operator != and ==.
6374 (tdesc_type): Likewise.
6375 (tdesc_feature): Likewise.
6376 (target_desc): Likewise.
6377 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
6378 (maintenance_check_xml_descriptions): New function.
6379 (_initialize_target_descriptions) Add command "xml-descriptions".
6380 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
6381
6382 2017-07-26 Yao Qi <yao.qi@linaro.org>
6383
6384 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
6385 Include features/i386/32bit-*.c.
6386 (i386_linux_read_description): Generate target description if it
6387 doesn't exist.
6388 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
6389 functions.
6390 * features/i386/32bit-linux.c: Re-generated.
6391 * features/i386/32bit-sse.c: Likewise.
6392 * target-descriptions.c (print_c_feature::visit): Print code to
6393 set register number if needed.
6394 (print_c_feature) <m_next_regnum>: New field.
6395
6396 2017-07-26 Yao Qi <yao.qi@linaro.org>
6397
6398 * features/Makefile (CFILES): Rename with TDESC_CFILES.
6399 (FEATURE_XMLFILES): New.
6400 (FEATURE_CFILES): New.
6401 New rules.
6402 (clean-cfiles): Remove generated c files.
6403 * features/i386/32bit-avx.c: Generated.
6404 * features/i386/32bit-avx512.c: Generated.
6405 * features/i386/32bit-core.c: Generated.
6406 * features/i386/32bit-linux.c: Generated.
6407 * features/i386/32bit-mpx.c: Generated.
6408 * features/i386/32bit-pkeys.c: Generated.
6409 * features/i386/32bit-sse.c: Generated.
6410 * target-descriptions.c: Include algorithm.
6411 (tdesc_element_visitor): Add method visit_end.
6412 (print_c_tdesc): Implement visit_end.
6413 (print_c_tdesc:: m_filename_after_features): Move it to
6414 protected.
6415 (print_c_feature): New class.
6416 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
6417 name starts with "i386/32bit-".
6418
6419 2017-07-26 Yao Qi <yao.qi@linaro.org>
6420
6421 * target-descriptions.c (tdesc_element_visitor): New class.
6422 (tdesc_element): New class.
6423 (tdesc_reg): Inherit from tdesc_element.
6424 (tdesc_reg::accept): New function.
6425 (tdesc_type): Inherit from tdesc_element.
6426 (tdesc_type::accept): New function.
6427 (tdesc_feature): Inherit from tdesc_element.
6428 (tdesc_feature::accept): New function.
6429 (target_desc): Inherit from tdesc_element.
6430 (target_desc::target_desc): New.
6431 (target_desc::~target_desc): New.
6432 (target_desc::accept): New.
6433 (allocate_target_description): Use new.
6434 (free_target_description): Use delete.
6435 (print_c_tdesc): New class.
6436 (maint_print_c_tdesc_cmd): Adjust.
6437
6438 * features/aarch64.c: Re-generated.
6439 * features/arc-arcompact.c: Re-generated.
6440 * features/arc-v2.c: Re-generated.
6441 * features/arm/arm-with-iwmmxt.c: Re-generated.
6442 * features/arm/arm-with-m.c: Re-generated.
6443 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
6444 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
6445 * features/arm/arm-with-neon.c: Re-generated.
6446 * features/arm/arm-with-vfpv2.c: Re-generated.
6447 * features/arm/arm-with-vfpv3.c: Re-generated.
6448 * features/i386/amd64-avx-avx512.c: Re-generated.
6449 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
6450 * features/i386/amd64-avx.c: Re-generated.
6451 * features/i386/amd64-avx-linux.c: Re-generated.
6452 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
6453 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
6454 * features/i386/amd64-avx-mpx.c: Re-generated.
6455 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
6456 * features/i386/amd64.c: Re-generated.
6457 * features/i386/amd64-linux.c: Re-generated.
6458 * features/i386/amd64-mpx.c: Re-generated.
6459 * features/i386/amd64-mpx-linux.c: Re-generated.
6460 * features/i386/i386-avx-avx512.c: Re-generated.
6461 * features/i386/i386-avx-avx512-linux.c: Re-generated.
6462 * features/i386/i386-avx.c: Re-generated.
6463 * features/i386/i386-avx-linux.c: Re-generated.
6464 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
6465 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
6466 * features/i386/i386-avx-mpx.c: Re-generated.
6467 * features/i386/i386-avx-mpx-linux.c: Re-generated.
6468 * features/i386/i386.c: Re-generated.
6469 * features/i386/i386-linux.c: Re-generated.
6470 * features/i386/i386-mmx.c: Re-generated.
6471 * features/i386/i386-mmx-linux.c: Re-generated.
6472 * features/i386/i386-mpx.c: Re-generated.
6473 * features/i386/i386-mpx-linux.c: Re-generated.
6474 * features/i386/x32-avx-avx512.c: Re-generated.
6475 * features/i386/x32-avx-avx512-linux.c: Re-generated.
6476 * features/i386/x32-avx.c: Re-generated.
6477 * features/i386/x32-avx-linux.c: Re-generated.
6478 * features/i386/x32.c: Re-generated.
6479 * features/i386/x32-linux.c: Re-generated.
6480 * features/microblaze.c: Re-generated.
6481 * features/microblaze-with-stack-protect.c: Re-generated.
6482 * features/mips64-dsp-linux.c: Re-generated.
6483 * features/mips64-linux.c: Re-generated.
6484 * features/mips-dsp-linux.c: Re-generated.
6485 * features/mips-linux.c: Re-generated.
6486 * features/nds32.c: Re-generated.
6487 * features/nios2.c: Re-generated.
6488 * features/nios2-linux.c: Re-generated.
6489 * features/rs6000/powerpc-32.c: Re-generated.
6490 * features/rs6000/powerpc-32l.c: Re-generated.
6491 * features/rs6000/powerpc-403.c: Re-generated.
6492 * features/rs6000/powerpc-403gc.c : Re-generated.
6493 * features/rs6000/powerpc-405.c: Re-generated.
6494 * features/rs6000/powerpc-505.c: Re-generated.
6495 * features/rs6000/powerpc-601.c: Re-generated.
6496 * features/rs6000/powerpc-602.c: Re-generated.
6497 * features/rs6000/powerpc-603.c: Re-generated.
6498 * features/rs6000/powerpc-604.c: Re-generated.
6499 * features/rs6000/powerpc-64.c: Re-generated.
6500 * features/rs6000/powerpc-64l.c: Re-generated.
6501 * features/rs6000/powerpc-7400.c: Re-generated.
6502 * features/rs6000/powerpc-750.c: Re-generated.
6503 * features/rs6000/powerpc-860.c: Re-generated.
6504 * features/rs6000/powerpc-altivec32.c: Re-generated.
6505 * features/rs6000/powerpc-altivec32l.c: Re-generated.
6506 * features/rs6000/powerpc-altivec64.c: Re-generated.
6507 * features/rs6000/powerpc-altivec64l.c: Re-generated.
6508 * features/rs6000/powerpc-cell32l.c: Re-generated.
6509 * features/rs6000/powerpc-cell64l.c: Re-generated.
6510 * features/rs6000/powerpc-e500.c: Re-generated.
6511 * features/rs6000/powerpc-e500l.c: Re-generated.
6512 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
6513 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
6514 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
6515 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
6516 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
6517 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
6518 * features/rs6000/powerpc-vsx32.c: Re-generated.
6519 * features/rs6000/powerpc-vsx32l.c: Re-generated.
6520 * features/rs6000/powerpc-vsx64.c: Re-generated.
6521 * features/rs6000/powerpc-vsx64l.c: Re-generated.
6522 * features/rs6000/rs6000.c: Re-generated.
6523 * features/s390-linux32.c: Re-generated.
6524 * features/s390-linux32v1.c: Re-generated.
6525 * features/s390-linux32v2.c: Re-generated.
6526 * features/s390-linux64.c: Re-generated.
6527 * features/s390-linux64v1.c: Re-generated.
6528 * features/s390-linux64v2.c: Re-generated.
6529 * features/s390-te-linux64.c: Re-generated.
6530 * features/s390-tevx-linux64.c: Re-generated.
6531 * features/s390-vx-linux64.c: Re-generated.
6532 * features/s390x-linux64.c: Re-generated.
6533 * features/s390x-linux64v1.c: Re-generated.
6534 * features/s390x-linux64v2.c: Re-generated.
6535 * features/s390x-te-linux64.c: Re-generated.
6536 * features/s390x-tevx-linux64.c: Re-generated.
6537 * features/s390x-vx-linux64.c: Re-generated.
6538 * features/sparc/sparc32-solaris.c: Re-generated.
6539 * features/sparc/sparc64-solaris.c: Re-generated.
6540 * features/tic6x-c62x.c: Re-generated.
6541 * features/tic6x-c62x-linux.c: Re-generated.
6542 * features/tic6x-c64x.c: Re-generated.
6543 * features/tic6x-c64x-linux.c: Re-generated.
6544 * features/tic6x-c64xp.c: Re-generated.
6545 * features/tic6x-c64xp-linux.c: Re-generated.
6546
6547 2017-07-26 Yao Qi <yao.qi@linaro.org>
6548
6549 * i386-linux-tdep.c (i386_linux_read_description): New function.
6550 (i386_linux_core_read_description): Call
6551 i386_linux_read_description.
6552 * i386-linux-tdep.h (i386_linux_read_description): Declare.
6553 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
6554 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
6555 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
6556 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
6557 * x86-linux-nat.c (x86_linux_read_description): Call
6558 i386_linux_read_description.
6559
6560 2017-07-26 Yao Qi <yao.qi@linaro.org>
6561
6562 * NEWS: Mention it.
6563 * features/Makefile (%.c: %.xml): Pass the xml file name to
6564 command "maint print c-tdesc".
6565 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
6566 name from 'arg'.
6567
6568 2017-07-26 Yao Qi <yao.qi@linaro.org>
6569
6570 * target-descriptions.c (target_desc): Add ctor and dtor. Do
6571 in-class initialization.
6572 (tdesc_create_feature): Call new instead of XCNEW.
6573 (free_target_description): Ue delete.
6574
6575 2017-07-25 John Baldwin <jhb@FreeBSD.org>
6576
6577 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
6578
6579 2017-07-25 Yao Qi <yao.qi@linaro.org>
6580
6581 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
6582 constant.
6583 (amd64_x32_init_abi): Likewise.
6584 * amd64-tdep.h (amd64_init_abi): Update declaration.
6585 (amd64_x32_init_abi): Likewise.
6586
6587 2017-07-25 Yao Qi <yao.qi@linaro.org>
6588
6589 PR tdep/21717
6590 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
6591 condition for FPSCR.
6592 (arm_linux_store_inferior_registers): Likewise.
6593
6594 2017-07-22 Tom Tromey <tom@tromey.com>
6595
6596 * break-catch-syscall.c (struct catch_syscall_inferior_data)
6597 <syscalls_counts>: Now a std::vector.
6598 (get_catch_syscall_inferior_data): Use "new".
6599 (catch_syscall_inferior_data_cleanup): Use "delete".
6600 (insert_catch_syscall, remove_catch_syscall)
6601 (clear_syscall_counts): Update.
6602
6603 2017-07-22 Tom Tromey <tom@tromey.com>
6604
6605 * break-catch-syscall.c (syscall_catchpoint)
6606 <syscalls_to_be_caught>: Now a std::vector<int>
6607 (~syscall_catchpoint): Remove.
6608 (insert_catch_syscall, remove_catch_syscall)
6609 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
6610 (print_mention_catch_syscall, print_recreate_catch_syscall):
6611 Update.
6612 (create_syscall_event_catchpoint): Change type of "filter"
6613 parameter.
6614 (catch_syscall_split_args): Return a std::vector.
6615 (catch_syscall_command_1, catching_syscall_number_1): Update.
6616
6617 2017-07-22 Tom Tromey <tom@tromey.com>
6618
6619 * break-catch-throw.c (struct exception_catchpoint)
6620 <exception_rx>: Now a std::string.
6621 (~exception_catchpoint): Remove.
6622 (print_one_detail_exception_catchpoint): Update.
6623 (handle_gnu_v3_exceptions): Change type of except_rx.
6624 (extract_exception_regexp): Return a std::string.
6625 (catch_exception_command_1): Update.
6626
6627 2017-07-22 Tom Tromey <tom@tromey.com>
6628
6629 * break-catch-sig.c (gdb_signal_type): Remove typedef.
6630 (struct signal_catchpoint) <signals_to_be_caught>: Now a
6631 std::vector.
6632 <catch_all>: Now a bool.
6633 (~signal_catchpoint): Remove.
6634 (signal_catchpoint_insert_location)
6635 (signal_catchpoint_remove_location)
6636 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
6637 (signal_catchpoint_print_mention)
6638 (signal_catchpoint_print_recreate)
6639 (signal_catchpoint_explains_signal): Update.
6640 (create_signal_catchpoint): Change type of "filter" and
6641 "catch_all".
6642 (catch_signal_split_args): Return a std::vector. Change type of
6643 "catch_all".
6644 (catch_signal_command): Update.
6645
6646 2017-07-20 Pedro Alves <palves@redhat.com>
6647
6648 * ada-lang.c (ada_language_defn): Make extern.
6649 (_initialize_ada_language): Remove add_language call.
6650 * c-lang.c (c_language_defn, cplus_language_defn)
6651 (asm_language_defn, minimal_language_defn): Make extern.
6652 (_initialize_c_language): Delete.
6653 * completer.c (compare_cstrings): Delete, moved to utils.h.
6654 * d-lang.c (d_language_defn): Make extern.
6655 (_initialize_d_language): Remove add_language calls.
6656 * defs.h (enum language): Add comment.
6657 * f-lang.c (f_language_defn): Make extern.
6658 (_initialize_f_language): Remove add_language call.
6659 * go-lang.c (go_language_defn): Make extern.
6660 (_initialize_go_language): Remove add_language call.
6661 * language.c: Include <algorithm>.
6662 (languages): Redefine as const array.
6663 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
6664 (set_language_command): Handle "local". Use for-range loop.
6665 (set_language): Remove loop.
6666 (language_enum): Rewrite.
6667 (language_def, language_str): Remove loops.
6668 (add_language): Delete.
6669 (add_set_language_command): New, based on add_languages.
6670 (skip_language_trampoline): Adjust.
6671 (local_language_defn): Delete.
6672 (language_gdbarch_post_init): Adjust.
6673 (_initialize_language): Remove add_language calls. Call
6674 add_set_language_command.
6675 * language.h (add_language): Delete.
6676 (auto_language_defn)
6677 (unknown_language_defn, minimal_language_defn, ada_language_defn)
6678 (asm_language_defn, c_language_defn, cplus_language_defn)
6679 (d_language_defn, f_language_defn, go_language_defn)
6680 (m2_language_defn, objc_language_defn, opencl_language_defn)
6681 (pascal_language_defn, rust_language_defn): Declare.
6682 * m2-lang.c (m2_language_defn): Make extern.
6683 (_initialize_m2_language): Remove add_language call.
6684 * objc-lang.c (objc_language_defn): Make extern.
6685 (_initialize_objc_language): Remove add_language call.
6686 * opencl-lang.c (opencl_language_defn): Make extern.
6687 (_initialize_opencl_language): Remove add_language call.
6688 * p-lang.c (pascal_language_defn): Make extern.
6689 (_initialize_pascal_language): Delete.
6690 * rust-lang.c (rust_language_defn): Make extern.
6691 (_initialize_rust_language): Delete.
6692 * utils.h (compare_cstrings): New static inline function.
6693
6694 2017-07-20 Pedro Alves <palves@redhat.com>
6695
6696 * ada-lang.c (ada_to_fixed_type_1): Adjust.
6697 (get_var_value): Constify parameters.
6698 (get_int_var_value): Change prototype.
6699 (to_fixed_range_type): Adjust.
6700 * ada-lang.h (get_int_var_value): Change prototype.
6701
6702 2017-07-20 Pedro Alves <palves@redhat.com>
6703
6704 * dwarf2read.c (dw2_lookup_symbol): Use
6705 SYMBOL_MATCHES_SEARCH_NAME.
6706 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
6707
6708 2017-07-20 Pedro Alves <palves@redhat.com>
6709
6710 * block.c (block_iter_name_step, block_iter_name_first)
6711 (block_iter_name_next): Delete.
6712 (block_lookup_symbol_primary): Adjust to use
6713 dict_iter_match_first/dict_iter_match_next.
6714 * block.h (block_iter_name_first, block_iter_name_next): Delete
6715 declarations.
6716 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
6717 dict_iter_match_first/dict_iter_match_next.
6718
6719 2017-07-20 Pedro Alves <palves@redhat.com>
6720
6721 * cp-support.c (cp_find_first_component_aux): Add missing case for
6722 end of string.
6723
6724 2017-07-18 David Blaikie <dblaikie@gmail.com>
6725
6726 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
6727 of dwo_cu's dwo_file.
6728
6729 2017-07-18 Yao Qi <yao.qi@linaro.org>
6730
6731 * remote.c (store_registers_using_G): Remove one line comment.
6732
6733 2017-07-18 Yao Qi <yao.qi@linaro.org>
6734
6735 * regcache.c (regcache_cpy): Simplify it.
6736 (regcache::cpy_no_passthrough): Remove it.
6737 * regcache.h (cpy_no_passthrough): Remove it.
6738 (regcache_dup, regcache_cpy): Update comments.
6739
6740 2017-07-18 Pedro Alves <palves@redhat.com>
6741
6742 * remote-sim.c (sim_command_completer): Adjust to work with a
6743 completion_tracker instead of a VEC.
6744
6745 2017-07-17 Pedro Alves <palves@redhat.com>
6746
6747 * completer.c (complete_source_filenames): New function.
6748 (complete_address_and_linespec_locations): New function.
6749 (location_completer): Use complete_address_and_linespec_locations.
6750 (completion_tracker::build_completion_result): Honor the tracker's
6751 request to suppress append.
6752 * completer.h (completion_tracker::suppress_append_ws)
6753 (completion_tracker::set_suppress_append_ws): New methods.
6754 (completion_tracker::m_suppress_append_ws): New field.
6755 (complete_source_filenames): New declaration.
6756 * linespec.c (linespec_complete_what): New.
6757 (struct ls_parser) <complete_what, completion_word,
6758 completion_quote_char, completion_quote_end, completion_tracker>:
6759 New fields.
6760 (string_find_incomplete_keyword_at_end): New.
6761 (linespec_lexer_lex_string): Record quote char. If in completion
6762 mode, don't throw.
6763 (linespec_lexer_consume_token): Advance the completion word point.
6764 (linespec_lexer_peek_token): Save/restore completion info.
6765 (save_stream_and_consume_token): New.
6766 (set_completion_after_number): New.
6767 (linespec_parse_basic): Set what to complete next depending on
6768 token. Handle function and label completions specially.
6769 (parse_linespec): Disable objc shortcut in completion mode. Set
6770 what to complete next depending on token type. Skip keyword if in
6771 completion mode.
6772 (complete_linespec_component, linespec_complete): New.
6773 * linespec.h (linespec_complete): Declare.
6774
6775 2017-07-17 Pedro Alves <palves@redhat.com>
6776
6777 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
6778 Handle 'operator<' / 'operator<<'.
6779
6780 2017-07-17 Pedro Alves <palves@redhat.com>
6781
6782 * completer.c (collect_explicit_location_matches): Handle
6783 MATCH_LABEL.
6784 (convert_explicit_location_to_linespec): New, factored out from
6785 ...
6786 (convert_explicit_location_to_sals): ... this.
6787 (complete_label): New.
6788 (linespec_complete_label, find_label_symbols_in_block): New.
6789 (find_label_symbols): Add completion_mode parameter and adjust to
6790 call find_label_symbols_in_block.
6791 * linespec.h (linespec_complete_label): Declare.
6792
6793 2017-07-17 Pedro Alves <palves@redhat.com>
6794
6795 * ada-lang.c (ada_collect_symbol_completion_matches): Add
6796 complete_symbol_mode parameter.
6797 * cli/cli-cmds.c (complete_command): Get the completion result out
6798 of the handle_brkchars tracker if used a custom word point.
6799 * completer.c: Include "linespec.h".
6800 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
6801 (advance_to_expression_complete_word_point): New.
6802 (completion_tracker::completes_to_completion_word): New.
6803 (complete_files_symbols): Pass down
6804 complete_symbol_mode::EXPRESSION.
6805 (explicit_options, probe_options): New.
6806 (collect_explicit_location_matches): Complete on the
6807 explictit_loc->foo instead of word. Use
6808 linespec_complete_function. Handle MATCH_LINE. Handle offering
6809 keyword and options completions.
6810 (backup_text_ptr): Delete.
6811 (skip_keyword): New.
6812 (complete_explicit_location): Remove 'word' parameter. Add
6813 language, quoted_arg_start and quoted_arg_end parameters.
6814 Rewrite, parsing left to right.
6815 (location_completer): Rewrite.
6816 (location_completer_handle_brkchars): New function.
6817 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
6818 (enum complete_line_internal_reason): Adjust comments.
6819 (completion_tracker::discard_completions): New.
6820 (completer_handle_brkchars_func_for_completer): Handle
6821 location_completer.
6822 (gdb_custom_word_point_brkchars)
6823 (gdb_org_rl_basic_quote_characters): New.
6824 (gdb_completion_word_break_characters_throw)
6825 (completion_find_completion_word): Handle trackers that use a
6826 custom word point.
6827 (completion_tracker::advance_custom_word_point_by): New.
6828 (completion_tracker::build_completion_result): Don't rely on
6829 readline appending the quote char.
6830 (gdb_rl_attempted_completion_function_throw): Handle trackers that
6831 use a custom word point.
6832 (gdb_rl_attempted_completion_function): Restore
6833 rl_basic_quote_characters.
6834 * completer.h (class completion_tracker): Extend intro comment.
6835 (completion_tracker::set_quote_char)
6836 (completion_tracker::quote_char)
6837 (completion_tracker::set_use_custom_word_point)
6838 (completion_tracker::use_custom_word_point)
6839 (completion_tracker::custom_word_point)
6840 (completion_tracker::set_custom_word_point)
6841 (completion_tracker::advance_custom_word_point_by)
6842 (completion_tracker::completes_to_completion_word)
6843 (completion_tracker::discard_completions): New methods.
6844 (completion_tracker::m_quote_char)
6845 (completion_tracker::m_use_custom_word_point)
6846 (completion_tracker::m_custom_word_point): New fields.
6847 (advance_to_expression_complete_word_point): Declare.
6848 * f-lang.c (f_collect_symbol_completion_matches): Add
6849 complete_symbol_mode parameter.
6850 * language.h (struct language_defn)
6851 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
6852 parameter.
6853 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
6854 (linespec_complete_function): New function.
6855 (linespec_lexer_lex_keyword): Adjust.
6856 * linespec.h (linespec_keywords, linespec_complete_function): New
6857 declarations.
6858 * location.c (find_end_quote): New function.
6859 (explicit_location_lex_one): Add explicit_completion_info
6860 parameter. Save quoting info. Don't throw if being called for
6861 completion. Don't handle Ada operators here.
6862 (is_cp_operator, skip_op_false_positives, first_of)
6863 (explicit_location_lex_one_function): New function.
6864 (string_to_explicit_location): Replace 'dont_throw' parameter with
6865 an explicit_completion_info pointer parameter. Handle it. Don't
6866 use explicit_location_lex_one to lex function names. Use
6867 explicit_location_lex_one_function instead.
6868 * location.h (struct explicit_completion_info): New.
6869 (string_to_explicit_location): Replace 'dont_throw' parameter with
6870 an explicit_completion_info pointer parameter.
6871 * symtab.c (default_collect_symbol_completion_matches_break_on):
6872 Add complete_symbol_mode parameter. Handle LINESPEC mode.
6873 (default_collect_symbol_completion_matches)
6874 (collect_symbol_completion_matches): Add complete_symbol_mode
6875 parameter.
6876 (collect_symbol_completion_matches_type): Pass down
6877 complete_symbol_mode::EXPRESSION.
6878 (collect_file_symbol_completion_matches): Add complete_symbol_mode
6879 parameter. Handle LINESPEC mode.
6880 * symtab.h (complete_symbol_mode): New.
6881 (default_collect_symbol_completion_matches_break_on)
6882 (default_collect_symbol_completion_matches)
6883 (collect_symbol_completion_matches)
6884 (collect_file_symbol_completion_matches): Add complete_symbol_mode
6885 parameter.
6886
6887 2017-07-17 Pedro Alves <palves@redhat.com>
6888
6889 * utils.c (enum class strncmp_iw_mode): New.
6890 (strcmp_iw): Rename to ...
6891 (strncmp_iw_with_mode): ... this. Add string2_len and mode
6892 parameters. Handle them.
6893 (strncmp_iw): New.
6894 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
6895 * utils.h (strncmp_iw): Declare.
6896 (strcmp_iw): Move describing comments here.
6897
6898 2017-07-17 Pedro Alves <palves@redhat.com>
6899
6900 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
6901 CP_OPERATOR_STR.
6902 * c-typeprint.c (is_type_conversion_operator): Use
6903 CP_OPERATOR_STR.
6904 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
6905 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
6906 CP_OPERATOR_LEN.
6907 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
6908 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
6909 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
6910 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
6911 CP_OPERATOR_STR.
6912 * location.c: Include "cp-support.h".
6913 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
6914 CP_OPERATOR_STR.
6915 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
6916 CP_OPERATOR_LEN.
6917
6918 2017-07-17 Pedro Alves <palves@redhat.com>
6919
6920 * cli/cli-cmds.c (complete_command): Use a completion tracker
6921 along with completion_find_completion_word for handle_brkchars
6922 phase.
6923 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
6924 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
6925 (struct gdb_rl_completion_word_info): New.
6926 (gdb_rl_find_completion_word): New.
6927 (completion_find_completion_word): New.
6928 * completer.h (completion_find_completion_word): Declare.
6929
6930 2017-07-17 Pedro Alves <palves@redhat.com>
6931
6932 * ada-lang.c (symbol_completion_match): Adjust comments.
6933 (symbol_completion_add): Replace vector parameter with
6934 completion_tracker parameter. Use it.
6935 (ada_make_symbol_completion_list): Rename to...
6936 (ada_collect_symbol_completion_matches): ... this. Add
6937 completion_tracker parameter and use it.
6938 (ada_language_defn): Adjust.
6939 * break-catch-syscall.c (catch_syscall_completer): Adjust
6940 prototype and work with completion_tracker instead of VEC.
6941 * breakpoint.c (condition_completer): Adjust prototype and work
6942 with completion_tracker instead of VEC.
6943 * c-lang.c (c_language_defn, cplus_language_defn)
6944 (asm_language_defn, minimal_language_defn): Adjust to renames.
6945 * cli/cli-cmds.c (complete_command): Rework using
6946 completion_tracker. Catch exceptions when completing.
6947 * cli/cli-decode.c (integer_unlimited_completer)
6948 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
6949 with completion_tracker instead of VEC.
6950 * command.h (struct completion_tracker): Forward declare.
6951 (completer_ftype, completer_handle_brkchars_ftype): Change
6952 types.
6953 (complete_on_cmdlist, complete_on_enum): Adjust.
6954 * completer.c: Include <algorithm>.
6955 (struct gdb_completer_state): New.
6956 (current_completion): New global.
6957 (readline_line_completion_function): Delete.
6958 (noop_completer, filename_completer)
6959 (filename_completer_handle_brkchars, complete_files_symbols)
6960 (linespec_location_completer): Adjust to work with a
6961 completion_tracker instead of a VEC.
6962 (string_or_empty): New.
6963 (collect_explicit_location_matches): Adjust to work with a
6964 completion_tracker instead of a VEC.
6965 (explicit_location_completer): Rename to ...
6966 (complete_explicit_location): ... this and adjust to work with a
6967 completion_tracker instead of a VEC.
6968 (location_completer): Adjust to work with a completion_tracker
6969 instead of a VEC.
6970 (add_struct_fields): Adjust to work with a completion_list instead
6971 of VEC.
6972 (expression_completer): Rename to ...
6973 (complete_expression): ... this and adjust to work with a
6974 completion_tracker instead of a VEC. Use complete_files_symbols.
6975 (expression_completer): Reimplement on top of complete_expression.
6976 (symbol_completer): Adjust to work with a completion_tracker
6977 instead of a VEC.
6978 (enum complete_line_internal_reason): Add describing comments.
6979 (complete_line_internal_normal_command): Adjust to work with a
6980 completion_tracker instead of a VEC.
6981 (complete_line_internal): Rename to ...
6982 (complete_line_internal_1): ... this and adjust to work with a
6983 completion_tracker instead of a VEC. Assert TEXT is NULL in the
6984 handle_brkchars phase.
6985 (new_completion_tracker): Delete.
6986 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
6987 complete_line_internal_1.
6988 (free_completion_tracker): Delete.
6989 (INITIAL_COMPLETION_HTAB_SIZE): New.
6990 (completion_tracker::completion_tracker)
6991 (completion_tracker::~completion_tracker): New.
6992 (maybe_add_completion): Delete.
6993 (completion_tracker::maybe_add_completion)
6994 (completion_tracker::add_completion)
6995 (completion_tracker::add_completions): New.
6996 (throw_max_completions_reached_error): Delete.
6997 (complete_line): Adjust to work with a completion_tracker instead
6998 of a VEC. Don't create a completion_tracker_t or check for max
6999 completions here.
7000 (command_completer, command_completer_handle_brkchars)
7001 (signal_completer, reg_or_group_completer_1)
7002 (reg_or_group_completer, default_completer_handle_brkchars):
7003 Adjust to work with a completion_tracker.
7004 (gdb_completion_word_break_characters_throw): New.
7005 (gdb_completion_word_break_characters): Reimplement.
7006 (line_completion_function): Delete.
7007 (completion_tracker::recompute_lowest_common_denominator)
7008 (expand_preserving_ws)
7009 (completion_tracker::build_completion_result)
7010 (completion_result::completion_result)
7011 (completion_result::completion_result)
7012 (completion_result::~completion_result)
7013 (completion_result::completion_result)
7014 (completion_result::release_match_list, compare_cstrings)
7015 (completion_result::sort_match_list)
7016 (completion_result::reset_match_list)
7017 (gdb_rl_attempted_completion_function_throw)
7018 (gdb_rl_attempted_completion_function): New.
7019 * completer.h (completion_list, struct completion_result)
7020 (class completion_tracker): New.
7021 (complete_line): Add completion_tracker parameter.
7022 (readline_line_completion_function): Delete.
7023 (gdb_rl_attempted_completion_function): New.
7024 (noop_completer, filename_completer, expression_completer)
7025 (location_completer, symbol_completer, command_completer)
7026 (signal_completer, reg_or_group_completer): Update prototypes.
7027 (completion_tracker_t, new_completion_tracker)
7028 (make_cleanup_free_completion_tracker): Delete.
7029 (enum maybe_add_completion_enum): Delete.
7030 (maybe_add_completion): Delete.
7031 (throw_max_completions_reached_error): Delete.
7032 * corefile.c (complete_set_gnutarget): Adjust to work with a
7033 completion_tracker instead of a VEC.
7034 * cp-abi.c (cp_abi_completer): Adjust to work with a
7035 completion_tracker instead of a VEC.
7036 * d-lang.c (d_language_defn): Adjust.
7037 * disasm.c (disassembler_options_completer): Adjust to work with a
7038 completion_tracker instead of a VEC.
7039 * f-lang.c (f_make_symbol_completion_list): Rename to ...
7040 (f_collect_symbol_completion_matches): ... this. Adjust to work
7041 with a completion_tracker instead of a VEC.
7042 (f_language_defn): Adjust.
7043 * go-lang.c (go_language_defn): Adjust.
7044 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
7045 Adjust to work with a completion_tracker instead of a VEC.
7046 * infrun.c (handle_completer): Likewise.
7047 * interps.c (interpreter_completer): Likewise.
7048 * interps.h (interpreter_completer): Likewise.
7049 * language.c (unknown_language_defn, auto_language_defn)
7050 (local_language_defn): Adjust.
7051 * language.h (language_defn::la_make_symbol_completion_list):
7052 Rename to ...
7053 (language_defn::la_collect_symbol_completion_matches): ... this
7054 and adjust to work with a completion_tracker instead of a VEC.
7055 * m2-lang.c (m2_language_defn): Adjust.
7056 * objc-lang.c (objc_language_defn): Adjust.
7057 * opencl-lang.c (opencl_language_defn): Adjust.
7058 * p-lang.c (pascal_language_defn): Adjust.
7059 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
7060 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
7061 with a completion_tracker.
7062 * rust-lang.c (rust_language_defn): Adjust.
7063 * symtab.c (free_completion_list, do_free_completion_list)
7064 (return_val, completion_tracker): Delete.
7065 (completion_list_add_name, completion_list_add_symbol)
7066 (completion_list_add_msymbol, completion_list_objc_symbol)
7067 (completion_list_add_fields, add_symtab_completions): Add
7068 completion_tracker parameter and use it.
7069 (default_make_symbol_completion_list_break_on_1): Rename to...
7070 (default_collect_symbol_completion_matches_break_on): ... this.
7071 Add completion_tracker parameter and use it instead of allocating
7072 a completion tracker here.
7073 (default_make_symbol_completion_list_break_on): Delete old
7074 implementation.
7075 (default_make_symbol_completion_list): Delete.
7076 (default_collect_symbol_completion_matches): New.
7077 (make_symbol_completion_list): Delete.
7078 (collect_symbol_completion_matches): New.
7079 (make_symbol_completion_type): Rename to ...
7080 (collect_symbol_completion_matches_type): ... this. Add
7081 completion_tracker parameter and use it instead of VEC.
7082 (make_file_symbol_completion_list_1): Rename to...
7083 (collect_file_symbol_completion_matches): ... this. Add
7084 completion_tracker parameter and use it instead of VEC.
7085 (make_file_symbol_completion_list): Delete.
7086 (add_filename_to_list): Use completion_list instead of a VEC.
7087 (add_partial_filename_data::list): Now a completion_list.
7088 (make_source_files_completion_list): Work with a completion_list
7089 instead of a VEC.
7090 * symtab.h: Include "completer.h".
7091 (default_make_symbol_completion_list_break_on)
7092 (default_make_symbol_completion_list, make_symbol_completion_list)
7093 (make_symbol_completion_type, make_file_symbol_completion_list)
7094 (make_source_files_completion_list): Delete.
7095 (default_collect_symbol_completion_matches_break_on)
7096 (default_collect_symbol_completion_matches)
7097 (collect_symbol_completion_matches)
7098 (collect_symbol_completion_matches_type)
7099 (collect_file_symbol_completion_matches)
7100 (make_source_files_completion_list): New.
7101 * top.c (init_main): Don't install a rl_completion_entry_function
7102 hook. Install a rl_attempted_completion_function hook instead.
7103 * tui/tui-layout.c (layout_completer): Adjust to work with a
7104 completion_tracker.
7105 * tui/tui-regs.c (tui_reggroup_completer):
7106 * tui/tui-win.c (window_name_completer, focus_completer)
7107 (winheight_completer): Adjust to work with a completion_tracker.
7108 * value.c: Include "completer.h".
7109 (complete_internalvar): Adjust to work with a completion_tracker.
7110 * value.h (complete_internalvar): Likewise.
7111
7112 2017-07-17 Pedro Alves <palves@redhat.com>
7113
7114 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
7115 renames.
7116 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
7117 comments to completer_ftype's declaration.
7118 <completer_handle_brkchars>: Change type to
7119 completer_handle_brkchars_ftype.
7120 * command.h (completer_ftype): Add describing comment and give
7121 names to parameters.
7122 (completer_ftype_void): Rename to ...
7123 (completer_handle_brkchars_ftype) ... this. Add describing comment.
7124 (set_cmd_completer_handle_brkchars): Adjust.
7125 * completer.c (filename_completer_handle_brkchars): New function.
7126 (complete_line_internal_normal_command): New function, factored
7127 out from ...
7128 (complete_line_internal): ... here.
7129 (command_completer_handle_brkchars)
7130 (default_completer_handle_brkchars)
7131 (completer_handle_brkchars_func_for_completer): New functions.
7132 * completer.h (set_gdb_completion_word_break_characters): Delete
7133 declaration.
7134 (completer_handle_brkchars_func_for_completer): New declaration.
7135 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
7136 completer_handle_brkchars_func_for_completer.
7137
7138 2017-07-17 Pedro Alves <palves@redhat.com>
7139
7140 * completer.c (symbol_completer): New function, based on
7141 make_symbol_completion_list_fn.
7142 * completer.h (symbol_completer): New declaration.
7143 * guile/scm-cmd.c (cmdscm_completers): Adjust.
7144 * python/py-cmd.c (completers): Adjust.
7145 * symtab.c (make_symbol_completion_list_fn): Delete.
7146 * symtab.h (make_symbol_completion_list_fn): Delete.
7147 * cli/cli-decode.c (add_cmd): Adjust.
7148
7149 2017-07-17 Pedro Alves <palves@redhat.com>
7150
7151 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
7152 * dwarf2read.c: Include "filename-seen-cache.h".
7153 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
7154 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
7155 * filename-seen-cache.c: New file.
7156 * filename-seen-cache.h: New file.
7157 * symtab.c: Include "filename-seen-cache.h".
7158 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
7159 (create_filename_seen_cache, clear_filename_seen_cache)
7160 (delete_filename_seen_cache, filename_seen): Delete, parts moved
7161 to filename-seen-cache.h/filename-seen-cache.c.
7162 (output_source_filename, sources_info)
7163 (maybe_add_partial_symtab_filename)
7164 (make_source_files_completion_list): Adjust to use
7165 filename_seen_cache.
7166
7167 2017-07-17 Pedro Alves <palves@redhat.com>
7168
7169 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
7170 fields.
7171 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
7172 dwarf2_debug_sections*)): New.
7173 (dwarf2_per_objfile::dwarf2_per_objfile(const
7174 dwarf2_per_objfile&)): Declare as deleted.
7175 (dwarf2_per_objfile::operator=): Declare as deleted.
7176 (dwarf2_per_objfile::dwarf2_per_objfile)
7177 (dwarf2_per_objfile::~dwarf2_per_objfile)
7178 (dwarf2_per_objfile::free_cached_comp_units): New.
7179 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
7180 ctor. Call dwarf2_per_objfile's ctor manually.
7181 (dwarf2_locate_sections): Deleted/refactored as ...
7182 (dwarf2_per_objfile::locate_sections): ... this new method.
7183 (free_cached_comp_units): Defer to
7184 dwarf2_per_objfile::free_cached_comp_units.
7185 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
7186
7187 2017-07-14 Tom Tromey <tom@tromey.com>
7188
7189 PR rust/21764:
7190 * rust-exp.y (convert_ast_to_expression): Add "want_type"
7191 parameter.
7192 <UNOP_SIZEOF>: Split into separate case.
7193 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
7194
7195 2017-07-14 Tom Tromey <tom@tromey.com>
7196
7197 PR rust/21763:
7198 * symtab.c (symbol_matches_domain): Add language_rust to special
7199 case.
7200 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
7201 treat LOC_TYPEDEF symbols as variables.
7202
7203 2017-07-14 Pedro Alves <palves@redhat.com>
7204
7205 * symtab.c (make_file_symbol_completion_list_1): Iterate over
7206 symtabs matching all symtabs with SRCFILE as file name instead of
7207 only considering the first hit, with lookup_symtab.
7208
7209 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
7210
7211 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
7212 operator_name parameters.
7213 (gen_expr): Update function call.
7214
7215 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
7216
7217 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
7218 parameter.
7219 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
7220 Likewise.
7221 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
7222 parameter, use agent_expr::gdbarch instead, update function
7223 calls.
7224 (locexpr_tracepoint_var_ref): Likewise.
7225 (loclist_tracepoint_var_ref): Likewise.
7226 * ax-gdb.c (gen_trace_static_fields): Likewise.
7227 (gen_traced_pop): Likewise.
7228 (gen_frame_args_address): Likewise.
7229 (gen_frame_locals_address): Likewise.
7230 (gen_var_ref): Likewise.
7231 (gen_struct_ref_recursive): Likewise.
7232 (gen_static_field): Likewise.
7233 (gen_maybe_namespace_elt): Likewise.
7234 (gen_expr): Likewise.
7235 (gen_trace_for_var): Likewise.
7236 (gen_trace_for_expr): Likewise.
7237 (gen_trace_for_return_address): Likewise.
7238
7239 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
7240
7241 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
7242 parameter.
7243 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
7244
7245 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
7246
7247 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
7248 from ax, update calls.
7249 (gen_usual_arithmetic): Likewise.
7250 (gen_integral_promotions): Likewise.
7251 (gen_bitfield_ref): Likewise.
7252 (gen_primitive_field): Likewise.
7253 (gen_struct_ref_recursive): Likewise.
7254 (gen_struct_ref): Likewise.
7255 (gen_maybe_namespace_elt): Likewise.
7256 (gen_struct_elt_for_reference): Likewise.
7257 (gen_namespace_elt): Likewise.
7258 (gen_aggregate_elt_ref): Likewise.
7259 (gen_expr): Get gdbarch from ax, update calls.
7260 (gen_expr_binop_rest): Likewise.
7261
7262 2017-07-13 Pedro Alves <palves@redhat.com>
7263
7264 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
7265 as default tdesc.
7266 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
7267 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
7268 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
7269 tdesc_amd64_linux as default tdesc. Get final tdesc from the
7270 tdep.
7271 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
7272 Get final tdesc from the tdep.
7273 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
7274 default tdesc.
7275 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
7276 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
7277 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
7278 Use it as default tdesc.
7279 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
7280 down to amd_init_abi. No longer handle fallback tdesc here.
7281 * amd64-tdep.h (tdesc_x32): Declare.
7282 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
7283 parameter.
7284 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
7285 as default tdesc.
7286
7287 2017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7288
7289 * s390-linux-tdep.c (s390_process_record): Add support for
7290 instructions new in arch12.
7291
7292 2017-07-11 John Baldwin <jhb@FreeBSD.org>
7293
7294 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
7295 PT_GETFSBASE and PT_GETGSBASE.
7296 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
7297 PT_SETGSBASE.
7298
7299 2017-07-11 John Baldwin <jhb@FreeBSD.org>
7300
7301 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
7302 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
7303 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
7304 those rules.
7305 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
7306 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
7307 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
7308 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
7309 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
7310 * features/i386/amd64.xml: Add 64bit-segments.xml.
7311 * features/i386/amd64-avx-avx512.c: Regenerated.
7312 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
7313 * features/i386/amd64-avx-mpx.c: Regenerated.
7314 * features/i386/amd64-avx.c: Regenerated.
7315 * features/i386/amd64-mpx.c: Regenerated.
7316 * features/i386/amd64.c: Regenerated.
7317 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
7318 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
7319 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
7320 * regformats/i386/amd64-avx.dat: Regenerated.
7321 * regformats/i386/amd64-mpx.dat: Regenerated.
7322 * regformats/i386/amd64.dat: Regenerated.
7323
7324 2017-07-10 Yao Qi <yao.qi@linaro.org>
7325
7326 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
7327 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
7328
7329 2017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
7330
7331 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
7332 unsetenv.
7333 * gnulib/aclocal.m4: Regenerate.
7334 * gnulib/config.in: Regenerate.
7335 * gnulib/configure: Regenerate.
7336 * gnulib/import/Makefile.am: Regenerate.
7337 * gnulib/import/Makefile.in: Regenerate.
7338 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
7339 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
7340 * gnulib/import/m4/environ.m4: New file.
7341 * gnulib/import/m4/setenv.m4: New file.
7342 * gnulib/import/setenv.c: New file.
7343 * gnulib/import/unsetenv.c: New file.
7344
7345 2017-07-09 Simon Marchi <simon.marchi@ericsson.com>
7346
7347 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
7348 address when op is DW_OP_addr.
7349
7350 2017-07-09 Tom Tromey <tom@tromey.com>
7351
7352 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
7353 check and apply to outer type.
7354
7355 2017-07-07 John Baldwin <jhb@FreeBSD.org>
7356
7357 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
7358 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
7359 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
7360 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
7361
7362 2017-07-07 John Baldwin <jhb@FreeBSD.org>
7363
7364 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
7365
7366 2017-07-07 John Baldwin <jhb@FreeBSD.org>
7367
7368 * corelow.c (get_core_siginfo): Remove.
7369 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
7370 instead of get_core_siginfo.
7371 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
7372 * gdbarch.h: Re-generate.
7373 * gdbarch.c: Re-generate.
7374 * linux-tdep.c (linux_core_xfer_siginfo): New.
7375 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
7376
7377 2017-07-07 John Baldwin <jhb@FreeBSD.org>
7378
7379 * corelow.c (thread_section_name): Move to ...
7380 * gdbcore.h (thread_section_name): ... here.
7381
7382 2017-07-07 John Baldwin <jhb@FreeBSD.org>
7383
7384 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
7385 (struct siginfo32): New.
7386 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
7387 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
7388 via ptrace(PT_LWPINFO).
7389
7390 2017-07-07 John Baldwin <jhb@FreeBSD.org>
7391
7392 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
7393 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
7394 (fbsd_get_siginfo_type): New.
7395 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
7396 (_initialize_fbsd_tdep): New.
7397
7398 2017-07-06 David Blaikie <dblaikie@gmail.com>
7399
7400 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
7401 a singular dwo_unit*) to support multiple CUs in the same way that
7402 multiple TUs are supported.
7403 (create_cus_hash_table): Replace create_dwo_cu with a function for
7404 parsing multiple CUs from a DWO file.
7405 (open_and_init_dwo_file): Use create_cus_hash_table rather than
7406 create_dwo_cu.
7407 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
7408 htab_find, rather than comparing the signature to a singleton CU in
7409 the dwo_file.
7410
7411 2017-07-06 Pedro Alves <palves@redhat.com>
7412
7413 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
7414
7415 2017-07-04 Pedro Alves <palves@redhat.com>
7416
7417 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
7418 * gdbtypes.h (TYPE_STATIC): Delete.
7419 (struct fn_field) <is_public, is_abstract, is_static, is_final,
7420 is_synchronized, is_native>: Delete.
7421 <dummy>: Bump.
7422 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
7423 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
7424 (TYPE_FN_FIELD_ABSTRACT): Delete.
7425
7426 2017-07-03 Simon Marchi <simon.marchi@ericsson.com>
7427
7428 * buffer.h (buffer_finish): Fix spelling mistakes.
7429
7430 2017-07-01 Eli Zaretskii <eliz@gnu.org>
7431
7432 * .dir-locals.el: Automatically switch to C-style comments in
7433 versions of Emacs that support the feature.
7434
7435 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
7436 Pedro Alves <palves@redhat.com>
7437
7438 PR cli/21688
7439 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
7440 (process_next_line): New variable 'inline_cmd'.
7441 Adjust 'if' clauses for "python", "compile" and "guile" to use
7442 'command_name_equals' and check for '!inline_cmd'.
7443
7444 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
7445
7446 PR cli/21688
7447 * cli/cli-script.c (command_name_equals_not_inline): New function.
7448 (process_next_line): Adjust 'if' clauses for "python", "compile"
7449 and "guile" to use command_name_equals_not_inline.
7450
7451 2017-06-29 Pedro Alves <palves@redhat.com>
7452
7453 * completer.c (expression_completer): Call
7454 linespec_location_completer instead of location_completer.
7455
7456 2017-06-29 Pedro Alves <palves@redhat.com>
7457
7458 * completer.c (expression_completer): Remove code that recomputes
7459 'text' from 'word'.
7460
7461 2017-06-29 Yao Qi <yao.qi@linaro.org>
7462
7463 * regformats/regdat.sh: Generate code with
7464 "ifndef IN_PROCESS_AGENT".
7465
7466 2017-06-28 Pedro Alves <palves@redhat.com>
7467
7468 * command.h: Include "common/scoped_restore.h".
7469
7470 2017-06-28 Yao Qi <yao.qi@linaro.org>
7471
7472 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
7473 instead of obstack_grow.
7474
7475 2017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
7476
7477 PR gdb/21337
7478 * symfile.c (reread_symbols): Call objfiles_changed just before
7479 read_symbols.
7480
7481 2017-06-27 Pedro Alves <palves@redhat.com>
7482
7483 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
7484 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
7485 (completion_list_add_symbol, completion_list_add_msymbol):
7486 ... these new functions.
7487 (add_symtab_completions)
7488 (default_make_symbol_completion_list_break_on_1): Adjust.
7489
7490 2017-06-27 Pedro Alves <palves@redhat.com>
7491
7492 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
7493 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
7494 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
7495 dtor.
7496 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
7497 'storage_obstack' field an auto_obstack. In-class initialize all
7498 non-bitfield fields. Make minsyms_read bool.
7499 * symfile.c (read_symbols): Adjust.
7500
7501 2017-06-27 Alan Hayward <alan.hayward@arm.com>
7502
7503 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
7504 (gdbsim_store_register): Likewise.
7505
7506 2017-06-27 Pedro Alves <palves@redhat.com>
7507
7508 * c-exp.y (name_obstack): Now an auto_obstack.
7509 (yylex): Use auto_obstack::clear.
7510 (c_parse): Use auto_obstack::clear instead of reinitializing and
7511 freeing the obstack.
7512 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
7513 * d-exp.y (name_obstack): Now an auto_obstack.
7514 (yylex): Use auto_obstack::clear.
7515 (d_parse): Use auto_obstack::clear instead of reinitializing and
7516 freeing the obstack.
7517 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
7518 auto_obstack.
7519 * dwarf2read.c (create_addrmap_from_index)
7520 (dwarf2_build_psymtabs_hard)
7521 (update_enumeration_type_from_children): Likewise.
7522 * gdb_obstack.h (auto_obstack): New type.
7523 * go-exp.y (name_obstack): Now an auto_obstack.
7524 (build_packaged_name): Use auto_obstack::clear.
7525 (go_parse): Use auto_obstack::clear instead of reinitializing and
7526 freeing the obstack.
7527 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
7528 auto_obstack.
7529 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
7530 * rust-exp.y (work_obstack): Now an auto_obstack.
7531 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
7532 reinitializing and freeing the obstack.
7533 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
7534 (host_char_to_target): Use auto_obstack.
7535 * utils.h (make_cleanup_obstack_free): Delete declaration.
7536 * valprint.c (generic_emit_char, generic_printstr): Use
7537 auto_obstack.
7538
7539 2017-06-27 Simon Marchi <simon.marchi@ericsson.com>
7540
7541 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
7542 thread.
7543 (darwin_init_thread_list): Don't update dummy thread.
7544 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
7545
7546 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
7547
7548 * record-full.c (netorder16): Remove.
7549
7550 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
7551
7552 * common/diagnostics.h: Define macros for GCC.
7553 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
7554 * common/vec.h: Include diagnostics.h.
7555 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
7556 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
7557 warning.
7558
7559 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
7560
7561 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
7562 New macro.
7563 * ada-lex.l: Ignore deprecated register warnings.
7564
7565 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
7566
7567 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
7568 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
7569
7570 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
7571
7572 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
7573 its own line.
7574
7575 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
7576
7577 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
7578
7579 2017-06-23 Alan Hayward <alan.hayward@arm.com>
7580
7581 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
7582 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
7583 (xtensa_register_read_masked): Likewise.
7584
7585 2017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
7586
7587 * common/environ.c (gdb_environ::unset): Update comment.
7588
7589 2017-06-22 Alan Hayward <alan.hayward@arm.com>
7590
7591 * python/py-unwind.c (pyuw_sniffer): Allocate space for
7592 registers.
7593
7594 2017-06-22 Alan Hayward <alan.hayward@arm.com>
7595
7596 * record-full.c (record_full_exec_insn): Use byte_vector.
7597
7598 2017-06-22 Yao Qi <yao.qi@linaro.org>
7599
7600 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
7601 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
7602
7603 2017-06-22 Alan Hayward <alan.hayward@arm.com>
7604
7605 * remote.c (cached_reg): Move from here...
7606 * regcache.h (cached_reg): ...to here.
7607 * python/py-unwind.c (struct reg_info): Remove.
7608 (cached_frame_info): Use cached_reg_t.
7609 (pyuw_prev_register): Likewise.
7610 (pyuw_sniffer): Use cached_reg_t and allocate registers.
7611 (pyuw_dealloc_cache): Free all registers.
7612
7613 2017-06-22 Pedro Alves <palves@redhat.com>
7614 Simon Marchi <simon.marchi@ericsson.com>
7615
7616 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
7617 warning.
7618 * common/diagnostics.h: New file.
7619
7620 2017-06-22 Pedro Alves <palves@redhat.com>
7621
7622 * common/agent.h: Add include guards.
7623
7624 2017-06-21 Simon Marchi <simon.marchi@ericsson.com>
7625
7626 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
7627 talk about addressable units instead of bytes.
7628
7629 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
7630
7631 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
7632 of '::const_iterator'.
7633
7634 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
7635
7636 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7637 'unittests/environ-selftests.c'.
7638 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
7639 * charset.c (find_charset_names): Declare object 'iconv_env'.
7640 Update code to use 'iconv_env' object. Remove call to
7641 'free_environ'.
7642 * common/environ.c: Include <utility>.
7643 (make_environ): Delete function.
7644 (free_environ): Delete function.
7645 (gdb_environ::clear): New function.
7646 (gdb_environ::operator=): New function.
7647 (gdb_environ::get): Likewise.
7648 (environ_vector): Delete function.
7649 (set_in_environ): Delete function.
7650 (gdb_environ::set): New function.
7651 (unset_in_environ): Delete function.
7652 (gdb_environ::unset): New function.
7653 (gdb_environ::envp): Likewise.
7654 * common/environ.h: Include <vector>.
7655 (struct gdb_environ): Delete; transform into...
7656 (class gdb_environ): ... this class.
7657 (free_environ): Delete prototype.
7658 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
7659 environ_vector): Likewise.
7660 * infcmd.c (run_command_1): Update code to call
7661 'envp' from 'gdb_environ' class.
7662 (environment_info): Update code to call methods from 'gdb_environ'
7663 class.
7664 (unset_environment_command): Likewise.
7665 (path_info): Likewise.
7666 (path_command): Likewise.
7667 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
7668 (inferior::inferior): Initialize 'environment' using the host's
7669 information.
7670 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
7671 Include "environ.h".
7672 (class inferior) <environment>: Change type from 'struct
7673 gdb_environ' to 'gdb_environ'.
7674 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
7675 methods from 'gdb_environ' class.
7676 * solib.c (solib_find_1): Likewise
7677 * unittests/environ-selftests.c: New file.
7678
7679 2017-06-20 Yao Qi <yao.qi@linaro.org>
7680
7681 * features/i386/i386-linux.xml: Exchange the order of including
7682 32bit-linux.xml and 32bit-sse.xml.
7683 * features/i386/i386-linux.c: Regenerated.
7684
7685 2017-06-20 Yao Qi <yao.qi@linaro.org>
7686
7687 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
7688 Delete copy ctor and assignment operator.
7689 (tdesc_type): Likewise.
7690 (tdesc_feature): Likewise.
7691 (tdesc_free_reg): Remove.
7692 (tdesc_create_reg): Use new.
7693 (tdesc_free_type): Remove.
7694 (tdesc_create_vector): Use new.
7695 (tdesc_create_union): Likewise.
7696 (tdesc_create_flags): Likewise.
7697 (tdesc_create_enum): Likewise.
7698 (tdesc_free_feature): Delete.
7699 (free_target_description): Use delete.
7700
7701 2017-06-19 John Baldwin <jhb@FreeBSD.org>
7702
7703 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
7704 registers.
7705
7706 2017-06-19 Pedro Alves <palves@redhat.com>
7707
7708 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
7709 after gdb::unlinker.
7710
7711 2017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
7712
7713 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
7714 gdb_environ to access an environment variable.
7715
7716 2017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
7717
7718 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
7719 gdb_byte*.
7720
7721 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7722
7723 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
7724
7725 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7726
7727 * configure: Re-generate.
7728 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
7729
7730 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7731
7732 * configure: Re-generate.
7733 * warning.m4: Pass -Werror to compiler when checking for
7734 supported warning flags.
7735
7736 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7737
7738 * Makefile.in (COMPILE.pre): Add "-x c++".
7739
7740 2017-06-16 Alan Hayward <alan.hayward@arm.com>
7741 Pedro Alves <palves@redhat.com>
7742 Yao Qi <yao.qi@linaro.org>
7743
7744 * defs.h (RequireLongest): New.
7745 (extract_integer): Declare function template.
7746 (extract_signed_integer): Remove the declaration, but define it
7747 static inline.
7748 (extract_unsigned_integer): Likewise.
7749 (store_integer): Declare function template.
7750 (store_signed_integer): Remove the declaration, but define it
7751 static inline.
7752 (store_unsigned_integer): Likewise.
7753 * findvar.c (extract_integer): New function template.
7754 (extract_signed_integer): Remove.
7755 (extract_unsigned_integer): Remove.
7756 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
7757 instantiations.
7758 (store_integer): New function template.
7759 (store_signed_integer): Remove.
7760 (store_unsigned_integer): Remove.
7761 (store_integer): Explicit instantiations.
7762 * regcache.c (regcache_raw_read_signed): Update.
7763 (regcache::raw_read): New function.
7764 (regcache::raw_read_signed): Remove.
7765 (regcache::raw_read_unsigned): Remove.
7766 (regcache_raw_read_unsigned): Update.
7767 (regcache_raw_write_unsigned): Update.
7768 (regcache::raw_write_signed): Remove.
7769 (regcache::raw_write): New function.
7770 (regcache_cooked_read_signed): Update.
7771 (regcache::raw_write_unsigned): Remove.
7772 (regcache::cooked_read_signed): Remove.
7773 (regcache_cooked_read_unsigned): Update.
7774 (regcache::cooked_read_unsigned): Remove.
7775 (regcache_cooked_write_signed): Update.
7776 (regcache_cooked_write_unsigned): Update.
7777 * regcache.h (regcache) <raw_read_signed>: Remove.
7778 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
7779 <raw_read, raw_write>: New.
7780 <cooked_read_signed, cooked_write_signed>: Remove.
7781 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
7782 <cooked_read, cooked_write>: New.
7783 * sh64-tdep.c (sh64_pseudo_register_read): Update.
7784 (sh64_pseudo_register_write): Update.
7785
7786 2017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
7787
7788 * arc-tdep.c (arc_disassembler_options): New variable.
7789 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
7790 of default_print_insn.
7791 (arc_delayed_print_insn): Set info->section when needed,
7792 use default_print_insn to retrieve a disassembler.
7793
7794 2017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
7795
7796 PR gdb/21574
7797 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
7798 to mention $SHELL and startup-with-shell.
7799
7800 2017-06-14 Max Filippov <jcmvbkbc@gmail.com>
7801
7802 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
7803
7804 2017-06-14 Yao Qi <yao.qi@linaro.org>
7805
7806 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
7807 default_print_insn instead of print_insn_aarch64.
7808 * arm-tdep.c (gdb_print_insn_arm): Call
7809 default_print_insn instead of print_insn_big_arm
7810 and print_insn_little_arm.
7811 * i386-tdep.c (i386_print_insn): Call default_print_insn
7812 instead of print_insn_i386.
7813 * ia64-tdep.c (ia64_print_insn): Call
7814 default_print_insn instead of print_insn_ia64.
7815 * mips-tdep.c (gdb_print_insn_mips): Call
7816 default_print_insn instead of print_insn_big_mips
7817 and print_insn_little_mips.
7818 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
7819 instead of print_insn_spu.
7820
7821 2017-06-14 Pedro Alves <palves@redhat.com>
7822
7823 * ada-lang.c: Include "common/byte-vector.h".
7824 (ada_value_primitive_packed_val): Use gdb::byte_vector.
7825 * charset.c (wchar_iterator::iterate): Resize the vector instead
7826 of reserving it.
7827 * common/byte-vector.h: Include "common/def-vector.h".
7828 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
7829 * cli/cli-dump.c: Include "common/byte-vector.h".
7830 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
7831 * common/byte-vector.h: New file.
7832 * common/def-vector.h: New file.
7833 * common/default-init-alloc.h: New file.
7834 * dwarf2loc.c: Include "common/byte-vector.h".
7835 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
7836 instead of reserving it.
7837 * dwarf2read.c: Include "common/byte-vector.h".
7838 (data_buf::m_vec): Now a gdb::byte_vector.
7839 * gdb_regex.c: Include "common/def-vector.h".
7840 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
7841 * mi/mi-main.c: Include "common/byte-vector.h".
7842 (mi_cmd_data_read_memory): Use gdb::byte_vector.
7843 * printcmd.c: Include "common/byte-vector.h".
7844 (print_scalar_formatted): Use gdb::byte_vector.
7845 * valprint.c: Include "common/byte-vector.h".
7846 (maybe_negate_by_bytes, print_decimal_chars): Use
7847 gdb::byte_vector.
7848
7849 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
7850
7851 * darwin-nat.c: Include "nat/fork-inferior.h".
7852
7853 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
7854
7855 * configure.nat: Factor out Darwin bits that are not
7856 architecture-specific. Add fork-inferior.o.
7857
7858 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
7859
7860 * configure.nat: Factor out AIX bits that are not
7861 architecture-specific. Add fork-inferior.o.
7862
7863 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7864
7865 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
7866 (read_pieced_value, write_pieced_value): ...here. Reduce to
7867 wrappers that just call rw_pieced_value.
7868
7869 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7870
7871 * dwarf2loc.c (write_pieced_value): When writing the data for a
7872 memory piece, use write_memory_with_notification instead of
7873 write_memory.
7874
7875 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7876
7877 * valops.c (read_value_memory): Change embedded_offset to
7878 represent a bit offset instead of a byte offset.
7879 * value.h (read_value_memory): Adjust comment.
7880
7881 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7882
7883 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
7884 dest_offset_bits and source_offset_bits.
7885 (write_pieced_value): Likewise.
7886
7887 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7888
7889 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
7890 given by DW_OP_bit_piece.
7891 (write_pieced_value): Likewise.
7892
7893 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7894
7895 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
7896 some other preparations to the places where sufficient information
7897 is available.
7898 (write_pieced_value): Likewise.
7899
7900 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7901
7902 * dwarf2loc.c (bits_to_bytes): New function.
7903 (read_pieced_value): Fix offset calculations for register pieces
7904 on big-endian targets.
7905 (write_pieced_value): Likewise.
7906
7907 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7908
7909 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
7910 (write_pieced_value): Likewise.
7911
7912 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7913
7914 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
7915 transfer the source value's least significant bits, instead of its
7916 lowest-addressed ones. Rename type_len to max_offset.
7917 (read_pieced_value): Mirror above changes to write_pieced_value as
7918 applicable.
7919
7920 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7921
7922 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
7923 truncate full bytes from dest_offset_bits before using it as an
7924 offset into the buffer.
7925
7926 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7927
7928 * dwarf2loc.c (write_pieced_value): Include transfer size in
7929 byte-wise check.
7930
7931 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7932
7933 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
7934 calculation of this_size.
7935
7936 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7937
7938 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
7939 when targeting a bit-field.
7940 (write_pieced_value): Likewise.
7941
7942 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7943
7944 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
7945 (allocate_piece_closure): Drop addr_size parameter.
7946 (dwarf2_evaluate_loc_desc_full): Adjust call to
7947 allocate_piece_closure.
7948
7949 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7950
7951 PR gdb/21226
7952 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
7953 the LSB end, independent of endianness.
7954
7955 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7956
7957 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
7958 size capping.
7959
7960 2017-06-13 Yao Qi <yao.qi@linaro.org>
7961
7962 * mips-linux-nat.c: Move include features/mips*-linux.c to
7963 mips-linux-tdep.c.
7964 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
7965 to mips-linux-tdep.c.
7966 * mips-linux-tdep.c: Include features/mips*-linux.c
7967 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
7968 functions.
7969 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
7970 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
7971 (tdesc_mips64_dsp_linux): Declare.
7972
7973 2017-06-12 Tom Tromey <tom@tromey.com>
7974
7975 * valprint.h (val_print_type_code_int): Remove.
7976 * valprint.c (generic_val_print_int): Always call
7977 val_print_scalar_formatted.
7978 (val_print_type_code_int): Remove.
7979 * printcmd.c (print_scalar_formatted): Handle options->format==0.
7980 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
7981 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
7982 * ada-valprint.c (ada_val_print_num): Use
7983 val_print_scalar_formatted.
7984
7985 2017-06-12 Tom Tromey <tom@tromey.com>
7986
7987 * printcmd.c (print_scalar_formatted): Unify the two switches.
7988 Don't convert scalars to LONGEST.
7989
7990 2017-06-12 Tom Tromey <tom@tromey.com>
7991
7992 PR exp/16225:
7993 * valprint.h (print_decimal_chars): Update.
7994 * valprint.c (maybe_negate_by_bytes): New function.
7995 (print_decimal_chars): Add "is_signed" argument.
7996 * printcmd.c (print_scalar_formatted): Update.
7997
7998 2017-06-12 Tom Tromey <tom@tromey.com>
7999
8000 PR exp/16225:
8001 * valprint.h (print_binary_chars, print_hex_chars): Update.
8002 * valprint.c (val_print_type_code_int): Update.
8003 (print_binary_chars): Add "zero_pad" argument.
8004 (emit_octal_digit): New function.
8005 (print_octal_chars): Don't zero-pad.
8006 (print_decimal_chars): Likewise.
8007 (print_hex_chars): Add "zero_pad" argument.
8008 * sh64-tdep.c (sh64_do_fp_register): Update.
8009 * regcache.c (regcache::dump): Update.
8010 * printcmd.c (print_scalar_formatted): Update.
8011 * infcmd.c (default_print_one_register_info): Update.
8012
8013 2017-06-12 Pedro Alves <palves@redhat.com>
8014 Alan Hayward <alan.hayward@arm.com>
8015
8016 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
8017 (mips_eabi_push_dummy_call): Rename local 'regsize' to
8018 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
8019 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
8020 Assert that abi_regsize bytes fit in 'ref_valbuf'.
8021
8022 2017-06-12 Pedro Alves <palves@redhat.com>
8023
8024 * dwarf2read.c (mapped_symtab::data): Now a vector of
8025 symtab_index_entry instead of vector of
8026 std::unique_ptr<symtab_index_entry>. All users adjusted to check
8027 whether an element's name is NULL instead of checking whether the
8028 element itself is NULL.
8029 (find_slot): Change return type. Adjust.
8030 (hash_expand, , add_index_entry, uniquify_cu_indices)
8031 (write_hash_table): Adjust.
8032
8033 2017-06-12 Pedro Alves <palves@redhat.com>
8034
8035 * dwarf2read.c (recursively_count_psymbols): New function.
8036 (write_psymtabs_to_index): Call it to compute number of psyms and
8037 pass estimate size of psyms_seen to unordered_set's ctor.
8038
8039 2017-06-12 Pedro Alves <palves@redhat.com>
8040
8041 * dwarf2read.c (write_hash_table): Check if key already exists
8042 before emplacing.
8043
8044 2017-06-12 Pedro Alves <palves@redhat.com>
8045
8046 * dwarf2read.c (data_buf::append_space): Rename to...
8047 (data_buf::grow): ... this, and make private. Adjust all callers.
8048 (data_buf::append_uint): New method.
8049 (add_address_entry, write_one_signatured_type)
8050 (write_psymtabs_to_index): Use it.
8051
8052 2017-06-12 Pedro Alves <palves@redhat.com>
8053
8054 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
8055 (file_write (FILE *, const std::vector<Elem>&)): Delete.
8056 (data_buf::file_write): Call ::fwrite directly.
8057
8058 2017-06-12 Pedro Alves <palves@redhat.com>
8059
8060 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
8061 std::vector::erase.
8062
8063 2017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
8064
8065 Code cleanup: C++ify .gdb_index producer.
8066 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
8067 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
8068 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
8069 (create_strtab, add_string): Remove.
8070 (file_write, data_buf): New.
8071 (struct symtab_index_entry): Use std::vector for cu_indices.
8072 (struct mapped_symtab): Use std::vector for data.
8073 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
8074 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
8075 Remove.
8076 (find_slot): Change return type. Update it to the new data structures.
8077 (hash_expand, add_index_entry): Update it to the new data structures.
8078 (offset_type_compare): Remove.
8079 (uniquify_cu_indices): Update it to the new data structures.
8080 (c_str_view, c_str_view_hasher, vector_hasher): New.
8081 (add_indices_to_cpool): Remove.
8082 (write_hash_table): Update it to the new data structures.
8083 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
8084 (eq_psymtab_cu_index): Remove.
8085 (psym_index_map): New typedef.
8086 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
8087 reference and std::unordered_map for cu_index_htab.
8088 (add_address_entry, add_address_entry_worker, write_address_map)
8089 (write_psymbols): Update it to the new data structures.
8090 (write_obstack): Remove.
8091 (struct signatured_type_index_data): Change types_list to a data_buf
8092 reference and psyms_seen to a std::unordered_set reference.
8093 (write_one_signatured_type, recursively_write_psymbols)
8094 (write_psymtabs_to_index): Update it to the new data structures.
8095
8096 2017-06-11 Simon Marchi <simon.marchi@ericsson.com>
8097
8098 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
8099 separate-debug-file commands.
8100 * symfile.h (separate_debug_file_debug): New global.
8101 * symfile.c (separate_debug_file_debug): New global.
8102 (separate_debug_file_exists, find_separate_debug_file): Add
8103 debug output.
8104 (_initialize_symfile): Add "set debug separate-debug-file"
8105 command.
8106 * build-id.c (build_id_to_debug_bfd,
8107 find_separate_debug_file_by_buildid): Add debug output.
8108
8109 2017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
8110
8111 * gdbarch.sh (displaced_step_free_closure): Remove.
8112 * gdbarch.h, gdbarch.c: Re-generate.
8113 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
8114 displaced_step_free_closure.
8115 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
8116 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
8117 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
8118 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
8119 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
8120 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
8121 * arch-utils.h (simple_displaced_step_free_closure): Remove.
8122 * arch-utils.c (simple_displaced_step_free_closure): Remove.
8123 * infrun.c (displaced_step_clear): Call xfree instead of
8124 gdbarch_displaced_step_free_closure.
8125
8126 2017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
8127
8128 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
8129 NULL".
8130
8131 2017-06-08 Alan Hayward <alan.hayward@arm.com>
8132
8133 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
8134 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
8135 (mn10300_push_dummy_call): Likewise.
8136
8137 2017-06-08 Alan Hayward <alan.hayward@arm.com>
8138
8139 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
8140
8141 2017-06-08 Alan Hayward <alan.hayward@arm.com>
8142
8143 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
8144
8145 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
8146
8147 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
8148 able to start inferiors using a shell.
8149 (New remote packets): Announce new packet "QStartupWithShell".
8150 * remote.c: Add PACKET_QStartupWithShell.
8151 (extended_remote_create_inferior): Handle new
8152 PACKET_QStartupWithShell.
8153 (remote_protocol_features) <QStartupWithShell>: New entry for
8154 PACKET_QStartupWithShell.
8155 (_initialize_remote): Call "add_packet_config_cmd" for
8156 QStartupShell.
8157
8158 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
8159 Pedro Alves <palves@redhat.com>
8160
8161 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
8162 and "nat/fork-inferior.h".
8163 * common/common-inferior.h: New file, with contents from
8164 "gdb/inferior.h".
8165 * commom/common-utils.c: Include "common-utils.h".
8166 (stringify_argv): New function.
8167 * common/common-utils.h (stringify_argv): New prototype.
8168 * configure.nat: Add "fork-inferior.o" as a dependency for
8169 "*linux*", "fbsd*" and "nbsd*" hosts.
8170 * corefile.c (get_exec_file): Update comment.
8171 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
8172 instead of "startup_inferior".
8173 (darwin_create_inferior): Call "add_thread_silent" after
8174 "fork_inferior".
8175 * fork-child.c: Cleanup unnecessary includes.
8176 (SHELL_FILE): Move to "common/common-fork-child.c".
8177 (environ): Likewise.
8178 (exec_wrapper): Initialize.
8179 (get_exec_wrapper): New function.
8180 (breakup_args): Move to "common/common-fork-child.c"; rename to
8181 "breakup_args_for_exec".
8182 (escape_bang_in_quoted_argument): Move to
8183 "common/common-fork-child.c".
8184 (saved_ui): New variable.
8185 (prefork_hook): New function.
8186 (postfork_hook): Likewise.
8187 (postfork_child_hook): Likewise.
8188 (gdb_startup_inferior): Likewise.
8189 (fork_inferior): Move to "common/common-fork-child.c". Update
8190 function to support gdbserver.
8191 (startup_inferior): Likewise.
8192 * gdbcore.h (get_exec_file): Remove declaration.
8193 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
8194 instead of "startup_inferior". Call "add_thread_silent" after
8195 "fork_inferior".
8196 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
8197 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
8198 instead of "startup_inferior". Call "add_thread_silent" after
8199 "fork_inferior".
8200 * inferior.h: Include "common-inferior.h".
8201 (trace_start_error): Move to "common/common-utils.h".
8202 (trace_start_error_with_name): Likewise.
8203 (fork_inferior): Move prototype to "nat/fork-inferior.h".
8204 (startup_inferior): Likewise.
8205 (gdb_startup_inferior): New prototype.
8206 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
8207 * nat/fork-inferior.h: New file.
8208 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
8209 instead of "startup_inferior". Call "add_thread_silent" after
8210 "fork_inferior".
8211 * target.h (target_terminal_init): Move prototype to
8212 "target/target.h".
8213 (target_terminal_inferior): Likewise.
8214 (target_terminal_ours): Likewise.
8215 * target/target.h (target_terminal_init): New prototype, moved
8216 from "target.h".
8217 (target_terminal_inferior): Likewise.
8218 (target_terminal_ours): Likewise.
8219 * utils.c (gdb_flush_out_err): New function.
8220
8221 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
8222
8223 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
8224 * common/common-gdbthread.h: New file, with parts from
8225 "gdb/gdbthread.h".
8226 * gdbthread.h: Include "common-gdbthread.h".
8227 (switch_to_thread): Moved to "common/common-gdbthread.h".
8228
8229 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
8230
8231 * Makefile.in (SFILES): Add "common/job-control.c".
8232 (HFILES_NO_SRCDIR): Add "common/job-control.h".
8233 (COMMON_OBS): Add "job-control.o".
8234 * common/job-control.c: New file, with contents from
8235 "gdb/inflow.c".
8236 * common/job-control.h: New file, with contents from "terminal.h".
8237 * fork-child.c: Include "job-control.h".
8238 * inflow.c: Include "job-control.h".
8239 (gdb_setpgid): Move to "common/common-inflow.c".
8240 (_initialize_inflow): Move setting of "job_control" to
8241 "handle_job_control".
8242 * terminal.h (job_control): Moved to "common/common-terminal.h".
8243 (gdb_setpgid): Likewise.
8244 * top.c: Include "job_control.h".
8245 * utils.c: Likewise.
8246 (job_control): Moved to "job-control.c".
8247
8248 2017-06-07 Pedro Alves <palves@redhat.com>
8249
8250 * Makefile.in (SFILES): Add gdb_regex.c.
8251 (COMMON_OBS): Add gdb_regex.o.
8252 * ada-lang.c (ada_add_standard_exceptions)
8253 (ada_add_exceptions_from_frame, name_matches_regex)
8254 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
8255 parameter type to compiled_regex. Adjust.
8256 (ada_exceptions_list): Use compiled_regex.
8257 * break-catch-throw.c (exception_catchpoint::pattern): Now a
8258 std::unique_ptr<compiled_regex>.
8259 (exception_catchpoint::~exception_catchpoint): Remove regfree
8260 call.
8261 (check_status_exception_catchpoint): Adjust to use compiled_regex.
8262 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
8263 * breakpoint.c (solib_catchpoint::compiled): Now a
8264 std::unique_ptr<compiled_regex>.
8265 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
8266 (check_status_catch_solib): Adjust to use compiled_regex.
8267 (add_solib_catchpoint): Adjust to use compiled_regex.
8268 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
8269 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
8270 compiled_regex reference. Adjust to use it.
8271 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
8272 declaration. Include "gdb_regex.h".
8273 (apropos_cmd): Change regex parameter to compiled_regex reference.
8274 * gdb_regex.c: New file.
8275 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
8276 declarations.
8277 (class compiled_regex): New.
8278 * linux-tdep.c: Include "common/gdb_optional.h".
8279 (struct mapping_regexes): New, factored out from
8280 mapping_is_anonymous_p, and adjusted to use compiled_regex.
8281 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
8282 gdb::optional and remove cleanups. Adjust to compiled_regex.
8283 * probe.c: Include "common/gdb_optional.h".
8284 (collect_probes): Use compiled_regex and gdb::optional and remove
8285 cleanups.
8286 * skip.c: Include "common/gdb_optional.h".
8287 (skiplist_entry::compiled_function_regexp): Now a
8288 gdb::optional<compiled_regex>.
8289 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
8290 (free_skiplist_entry): Remove regfree call.
8291 (compile_skip_regexp, skip_rfunction_p): Adjust to use
8292 compiled_regex and gdb::optional.
8293 * symtab.c: Include "common/gdb_optional.h".
8294 (search_symbols): Use compiled_regex and gdb::optional.
8295 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
8296 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
8297 to gdb_regex.c.
8298
8299 2017-06-07 Alan Hayward <alan.hayward@arm.com>
8300
8301 * regcache.c (regcache::save): Avoid buffer use.
8302 (regcache::dump): Likewise.
8303
8304 2017-06-07 Alan Hayward <alan.hayward@arm.com>
8305
8306 * sh-tdep.c (sh_pseudo_register_read): Remove
8307 MAX_REGISTER_SIZE.
8308 (sh_pseudo_register_write): Likewise.
8309 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
8310 (sh64_pseudo_register_write): Likewise
8311
8312 2017-06-07 Alan Hayward <alan.hayward@arm.com>
8313
8314 * aarch64-tdep.c (aarch64_store_return_value): Use
8315 V_REGISTER_SIZE.
8316 (aarch64_pseudo_read_value): Likewise.
8317 (aarch64_pseudo_write): Likewise.
8318
8319 2017-06-06 Yao Qi <yao.qi@linaro.org>
8320
8321 * regformats/regdef.h (set_register_cache): Remove the
8322 declaration.
8323
8324 2017-06-06 Alan Hayward <alan.hayward@arm.com>
8325
8326 * frame.c (frame_unwind_register_signed): Use
8327 frame_unwind_register_value.
8328
8329 2017-06-06 Pedro Alves <palves@redhat.com>
8330
8331 PR breakpoints/21553
8332 * breakpoint.c (create_breakpoints_sal_default)
8333 (init_breakpoint_sal, create_breakpoint_sal): Use
8334 gdb::unique_xmalloc_ptr for string parameters.
8335 (create_breakpoint): Constify 'extra_string' and 'cond_string'
8336 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
8337 (base_breakpoint_create_breakpoints_sal)
8338 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
8339 (strace_marker_create_breakpoints_sal)
8340 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
8341 string parameters.
8342 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
8343 gdb::unique_xmalloc_ptr for string parameters.
8344 (create_breakpoint): Constify 'extra_string' and 'cond_string'
8345 parameters.
8346
8347 2017-06-06 Alan Hayward <alan.hayward@arm.com>
8348
8349 * alpha-tdep.c (alpha_register_to_value): Use
8350 get_frame_register_value.
8351 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
8352
8353 2017-06-06 Alan Hayward <alan.hayward@arm.com>
8354
8355 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
8356 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
8357 (ia64_value_to_register): Likewise.
8358 (ia64_extract_return_value): Likewise.
8359 (ia64_store_return_value): Likewise.
8360 (ia64_push_dummy_call): Likewise.
8361
8362 2017-06-04 Joel Brobecker <brobecker@adacore.com>
8363
8364 GDB 8.0 released.
8365
8366 2017-06-03 Simon Marchi <simon.marchi@ericsson.com>
8367
8368 * x86-linux-nat.c (struct arch_lwp_info): Remove.
8369
8370 2017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
8371
8372 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
8373 parameter.
8374 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
8375
8376 2017-06-02 Simon Marchi <simon.marchi@ericsson.com>
8377
8378 * event-loop.c (poll_timers): Unallocate timer using delete
8379 instead of xfree.
8380
8381 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
8382
8383 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
8384 (struct breakpoint) <~breakpoint>: New.
8385 (struct watchpoint): Inherit from breakpoint.
8386 <~watchpoint>: New.
8387 <base>: Remove.
8388 (struct tracepoint): Inherit from breakpoint.
8389 <base>: Remove.
8390 * breakpoint.c (longjmp_breakpoint_ops): Remove.
8391 (struct longjmp_breakpoint): Inherit from breakpoint.
8392 <~longjmp_breakpoint>: New.
8393 <base>: Remove.
8394 (new_breakpoint_from_type): Remove casts.
8395 (watchpoint_in_thread_scope): Remove reference to base field.
8396 (watchpoint_del_at_next_stop): Likewise.
8397 (update_watchpoint): Likewise.
8398 (watchpoint_check): Likewise.
8399 (bpstat_check_watchpoint): Likewise.
8400 (set_longjmp_breakpoint): Likewise.
8401 (struct fork_catchpoint): Inherit from breakpoint.
8402 <base>: Remove.
8403 (struct solib_catchpoint): Inherit from breakpoint.
8404 <~solib_catchpoint>: New.
8405 <base>: Remove.
8406 (dtor_catch_solib): Change to ...
8407 (solib_catchpoint::~solib_catchpoint): ... this.
8408 (breakpoint_hit_catch_solib): Remove reference to base field.
8409 (add_solib_catchpoint): Likewise.
8410 (create_fork_vfork_event_catchpoint): Likewise.
8411 (struct exec_catchpoint): Inherit from breakpoint.
8412 <~exec_catchpoint>: New.
8413 <base>: Remove.
8414 (dtor_catch_exec): Change to ...
8415 (exec_catchpoint::~exec_catchpoint): ... this.
8416 (dtor_watchpoint): Change to ...
8417 (watchpoint::~watchpoint): ... this.
8418 (watch_command_1): Remove reference to base field.
8419 (catch_exec_command_1): Likewise.
8420 (base_breakpoint_dtor): Change to ...
8421 (breakpoint::~breakpoint): ... this.
8422 (base_breakpoint_ops): Remove dtor field value.
8423 (longjmp_bkpt_dtor): Change to ...
8424 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
8425 (strace_marker_create_breakpoints_sal): Remove reference to base
8426 field.
8427 (delete_breakpoint): Don't manually call breakpoint destructor.
8428 (create_tracepoint_from_upload): Remove reference to base field.
8429 (trace_pass_set_count): Likewise.
8430 (initialize_breakpoint_ops): Don't initialize
8431 momentary_breakpoint_ops, don't set dtors.
8432 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
8433 <~ada_catchpoint>: New.
8434 <base>: Remove.
8435 (create_excep_cond_exprs): Remove reference to base field.
8436 (dtor_exception): Change to ...
8437 (ada_catchpoint::~ada_catchpoint): ... this.
8438 (dtor_catch_exception): Remove.
8439 (dtor_catch_exception_unhandled): Remove.
8440 (dtor_catch_assert): Remove.
8441 (create_ada_exception_catchpoint): Remove reference to base
8442 field.
8443 (initialize_ada_catchpoint_ops): Don't set dtors.
8444 * break-catch-sig.c (struct signal_catchpoint): Inherit from
8445 breakpoint.
8446 <~signal_catchpoint>: New.
8447 <base>: Remove.
8448 (signal_catchpoint_dtor): Change to ...
8449 (signal_catchpoint::~signal_catchpoint): ... this.
8450 (create_signal_catchpoint): Remove reference to base field.
8451 (initialize_signal_catchpoint_ops): Don't set dtor.
8452 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
8453 from breakpoint.
8454 <~syscall_catchpoint>: New.
8455 <base>: Remove.
8456 (dtor_catch_syscall): Change to ...
8457 (syscall_catchpoint::~syscall_catchpoint): ... this.
8458 (create_syscall_event_catchpoint): Remove reference to base
8459 field.
8460 (initialize_syscall_catchpoint_ops): Don't set dtor.
8461 * break-catch-throw.c (struct exception_catchpoint): Inherit
8462 from breakpoint.
8463 <~exception_catchpoint>: New.
8464 <base>: Remove.
8465 (dtor_exception_catchpoint): Change to ...
8466 (exception_catchpoint::~exception_catchpoint): ... this.
8467 (handle_gnu_v3_exceptions): Remove reference to base field.
8468 (initialize_throw_catchpoint_ops): Don't set dtor.
8469 * ctf.c (ctf_get_traceframe_address): Remove reference to base
8470 field.
8471 * remote.c (remote_get_tracepoint_status): Likewise.
8472 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
8473 * tracefile.c (tracefile_fetch_registers): Likewise.
8474 * tracepoint.c (actions_command): Likewise.
8475 (validate_actionline): Likewise.
8476 (tfind_1): Likewise.
8477 (get_traceframe_location): Likewise.
8478 (find_matching_tracepoint_location): Likewise.
8479 (parse_tracepoint_status): Likewise.
8480 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
8481
8482 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
8483
8484 * breakpoint.c (struct longjmp_breakpoint): New struct.
8485 (is_tracepoint_type): Change return type to bool.
8486 (is_longjmp_type): New function.
8487 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
8488 (set_raw_breakpoint_without_location): Use
8489 new_breakpoint_from_type.
8490 (set_raw_breakpoint): Likewise.
8491
8492 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
8493
8494 * breakpoint.c (new_breakpoint_from_type): New function.
8495 (create_breakpoint_sal): Use new_breakpoint_from_type and
8496 unique_ptr.
8497 (create_breakpoint): Likewise.
8498
8499 2017-05-31 Simon Marchi <simon.marchi@ericsson.com>
8500
8501 * memattr.c (mem_info_command): Rename to ...
8502 (info_mem_command): ... this.
8503 (mem_enable_command): Rename to ...
8504 (enable_mem_command): ... this.
8505 (mem_disable_command): Rename to ...
8506 (disable_mem_command): ... this.
8507 (mem_delete_command): Rename to ...
8508 (delete_mem_command): ... this.
8509 (_initialize_mem): Adjust function names.
8510
8511 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
8512
8513 * btrace.c (handle_pt_insn_events): New.
8514 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
8515 STATUS. Split into this and ...
8516 (handle_pt_insn_event_flags): ... this.
8517
8518 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
8519
8520 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
8521 and struct pt_insn.resynced.
8522 * configure: Regenerated.
8523 * config.in: Regenerated.
8524
8525 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8526
8527 * btrace.c (ftrace_find_call_by_number): New function.
8528 (ftrace_new_function): Store objects, not pointers.
8529 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
8530 ftrace_new_gap, ftrace_update_function,
8531 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
8532 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
8533 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
8534 btrace_ends_with_single_insn, btrace_call_get): Account for
8535 btrace_thread_info::functions now storing objects.
8536 * btrace.h (struct btrace_thread_info): Add constructor.
8537 (struct btrace_thread_info) <functions>: Make std::vector.
8538 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
8539 Initialize with default values.
8540 * record-btrace.c (record_btrace_frame_sniffer): Account for
8541 btrace_thread_info::functions now storing objects.
8542
8543 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8544
8545 * btrace.c: Remove typedef bfun_s.
8546 (ftrace_new_gap): Directly add gaps to the list of gaps.
8547 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
8548 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
8549 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
8550 instead of gdb VEC.
8551
8552 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8553
8554 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
8555 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
8556 with btrace_thread_info::next_segment and
8557 btrace_thread_info::prev_segment.
8558 * btrace.h: Remove struct btrace_func_link.
8559 (struct btrace_function): Replace pair of function segment pointers
8560 with pair of indices.
8561 * python/py-record-btrace.c (btpy_call_prev_sibling,
8562 btpy_call_next_sibling): Replace references to
8563 btrace_thread_info::segment with btrace_thread_info::next_segment and
8564 btrace_thread_info::prev_segment.
8565 * record-btrace.c (record_btrace_frame_this_id): Use
8566 btrace_find_call_by_number.
8567
8568 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8569
8570 * btrace.c (ftrace_new_function, ftrace_fixup_level,
8571 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
8572 btrace_insn_next, btrace_insn_prev): Remove references to
8573 btrace_thread_info::flow.
8574 * btrace.h (struct btrace_function): Remove FLOW.
8575
8576 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8577
8578 * btrace.c (ftrace_find_call_by_number): New function.
8579 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
8580 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
8581 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
8582 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
8583 index.
8584 * btrace.h (struct btrace_function): Turn UP into an index.
8585 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
8586 as an index.
8587 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
8588 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
8589 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
8590
8591 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8592
8593 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
8594 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
8595 ftrace_update_function, ftrace_compute_global_level_offset,
8596 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
8597 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
8598 btrace_insn_end, btrace_is_empty): Remove references to
8599 btrace_thread_info::begin and btrace_thread_info::end.
8600 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
8601 (struct btrace_thread_info) <functions>: Adjust comment.
8602 * record-btrace.c (record_btrace_start_replaying): Remove reference to
8603 btrace_thread_info::begin.
8604
8605 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8606
8607 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
8608 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
8609 ftrace_update_function): Remove arguments that implicitly were always
8610 BTINFO->END.
8611 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
8612 Don't pass BTINFO->END.
8613
8614 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8615
8616 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
8617 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
8618 btrace_find_insn_by_number): Replace function segment pointer with
8619 index.
8620 (btrace_insn_cmp): Simplify.
8621 * btrace.h: (struct btrace_insn_iterator) Rename index to
8622 insn_index. Replace function segment pointer with index into function
8623 segment vector.
8624 * record-btrace.c (record_btrace_call_history): Replace function
8625 segment pointer use with index.
8626 (record_btrace_frame_sniffer): Retrieve function call segment through
8627 vector.
8628 (record_btrace_set_replay): Remove defunc't safety check.
8629
8630 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8631
8632 * btrace.c (btrace_ends_with_single_insn): New function.
8633 (btrace_call_get, btrace_call_number, btrace_call_begin,
8634 btrace_call_end, btrace_call_next, btrace_call_prev,
8635 btrace_find_call_by_number): Use index into call segment vector
8636 instead of pointer.
8637 (btrace_call_cmp): Simplify.
8638 * btrace.h (struct btrace_call_iterator): Replace function call segment
8639 pointer with index into vector.
8640 * record-btrace.c (record_btrace_call_history): Use index instead of
8641 pointer.
8642
8643 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8644
8645 * btrace.c (btrace_insn_begin, btrace_insn_end,
8646 btrace_find_insn_by_number): Add btinfo to iterator.
8647 * btrace.h (struct btrace_insn_iterator): Add btinfo.
8648
8649 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8650
8651 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
8652 and save pointers directly.
8653 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
8654 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
8655 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
8656 changed signature of functions.
8657 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
8658 (btrace_fetch): Remove code that adds btrace_function pointers to
8659 vector of btrace_functions.
8660 (btrace_clear): Simplify freeing vector of btrace_functions.
8661
8662 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8663
8664 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
8665 Replace VEC_* with std::vector functions.
8666 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
8667 (struct btrace_thread_info)<functions>: Change type to std::vector.
8668
8669 2017-05-30 Simon Marchi <simon.marchi@ericsson.com>
8670
8671 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
8672 "Removed targets and native configurations" up. Merge duplicate
8673 "New commands" sub-sections. Add "New options" sub-sections.
8674
8675 2017-05-26 Alan Hayward <alan.hayward@arm.com>
8676
8677 * defs.h (copy_integer_to_size): New declaration.
8678 * findvar.c (copy_integer_to_size): New function.
8679 (do_cint_test): New selftest function.
8680 (copy_integer_to_size_test): Likewise.
8681 (_initialize_findvar): Likewise.
8682 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
8683 (mips_fbsd_collect_reg): Use raw_collect_integer.
8684 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
8685 (mips64_fill_gregset): Use raw_collect_integer
8686 (mips64_fill_fpregset): Use raw_supply_integer.
8687 * regcache.c (regcache::raw_supply_integer): New function.
8688 (regcache::raw_collect_integer): Likewise.
8689 * regcache.h: (regcache::raw_supply_integer): New declaration.
8690 (regcache::raw_collect_integer): Likewise.
8691
8692 2017-05-24 Yao Qi <yao.qi@linaro.org>
8693
8694 * Makefile.in (SFILES): Add gdbarch-selftests.c.
8695 (COMMON_OBS): Add gdbarch-selftests.o.
8696 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
8697 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
8698 * gdbarch-selftests.c: New file.
8699 * regcache.h (regcache) <~regcache>: Mark it virtual if
8700 GDB_SELF_TEST.
8701 <raw_write>: Likewise.
8702
8703 2017-05-24 Yao Qi <yao.qi@linaro.org>
8704
8705 * regcache.c (current_regcache): Change it to
8706 regcache::current_regcache.
8707 (regcache_observer_target_changed): Update.
8708 (regcache_thread_ptid_changed): Make it a regcache static
8709 method.
8710 (regcache_thread_ptid_changed): Update.
8711 (class regcache_access): New.
8712 (current_regcache_test): Update.
8713 (_initialize_regcache): Update.
8714 * regcache.h: Include forward_list.
8715 (regcache): Declare regcache_thread_ptid_changed and declare
8716 registers_changed_ptid as friend.
8717
8718 2017-05-24 Yao Qi <yao.qi@linaro.org>
8719
8720 * i387-tdep.c (i387_register_to_value): Use register_size
8721 instead of TYPE_LENGTH.
8722 * m68k-tdep.c (m68k_register_to_value): Likewise.
8723
8724 2017-05-24 Yao Qi <yao.qi@linaro.org>
8725
8726 * i387-tdep.c (i387_convert_register_p): Return false if type
8727 code isn't TYPE_CODE_FLT.
8728
8729 2017-05-24 Yao Qi <yao.qi@linaro.org>
8730
8731 * alpha-tdep.c (alpha_convert_register_p): Return true if type
8732 length is 4.
8733 (alpha_register_to_value): Remove type length check.
8734 (alpha_value_to_register): Likewise.
8735
8736 2017-05-24 Yao Qi <yao.qi@linaro.org>
8737
8738 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
8739 TYPE_CODE_FLT.
8740
8741 2017-05-24 Yao Qi <yao.qi@linaro.org>
8742
8743 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
8744 TYPE_CODE_FLT or not.
8745
8746 2017-05-24 Yao Qi <yao.qi@linaro.org>
8747
8748 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
8749 * avr-tdep.c (avr_gdbarch_init): Likewise.
8750 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
8751 * cris-tdep.c (cris_gdbarch_init): Likewise.
8752 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
8753 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
8754 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
8755 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
8756 * mep-tdep.c (mep_gdbarch_init): Likewise.
8757 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
8758 * mips-tdep.c (mips_gdbarch_init): Likewise.
8759 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
8760 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
8761 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
8762 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
8763 * v850-tdep.c (v850_gdbarch_init): Likewise.
8764
8765 2017-05-24 Yao Qi <yao.qi@linaro.org>
8766
8767 * selftest-arch.c (tests_with_arch): Call registers_changed
8768 and reinit_frame_cache.
8769 * selftest.c (run_self_tests): Likewise.
8770
8771 2017-05-24 Yao Qi <yao.qi@linaro.org>
8772
8773 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
8774 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
8775
8776 2017-05-24 Yao Qi <yao.qi@linaro.org>
8777
8778 * rl78-tdep.c (rl78_gdbarch_init): Don't call
8779 set_gdbarch_print_insn.
8780
8781 2017-05-24 Yao Qi <yao.qi@linaro.org>
8782
8783 * h8300-tdep.c (h8300_gdbarch_init): Don't call
8784 set_gdbarch_print_insn.
8785
8786 2017-05-24 Yao Qi <yao.qi@linaro.org>
8787
8788 * alpha-tdep.c (alpha_gdbarch_init): Don't call
8789 set_gdbarch_print_insn.
8790 * arc-tdep.c (arc_gdbarch_init): Likewise.
8791 * arch-utils.c: include dis-asm.h.
8792 (default_print_insn): New function.
8793 * arch-utils.h (default_print_insn): Declare.
8794 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
8795 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
8796 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
8797 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
8798 * frv-tdep.c (frv_gdbarch_init): Likewise.
8799 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
8800 * gdbarch.sh (print_insn): Use default_print_insn.
8801 * gdbarch.c: Regenerated.
8802 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
8803 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
8804 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
8805 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
8806 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
8807 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
8808 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
8809 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
8810 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
8811 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
8812 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
8813 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
8814 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
8815 * mt-tdep.c (mt_gdbarch_init): Likewise.
8816 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
8817 * nios2-tdep.c (nios2_print_insn): Remove.
8818 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
8819 * rx-tdep.c (rx_gdbarch_init): Likewise.
8820 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
8821 * score-tdep.c (score_print_insn): Remove.
8822 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
8823 * sh-tdep.c (sh_gdbarch_init): Likewise.
8824 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
8825 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
8826 * tic6x-tdep.c (tic6x_print_insn): Remove.
8827 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
8828 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
8829 * v850-tdep.c (v850_gdbarch_init): Likewise.
8830 * vax-tdep.c (vax_gdbarch_init): Likewise.
8831 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
8832 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
8833
8834 2017-05-23 John Baldwin <jhb@FreeBSD.org>
8835
8836 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
8837 (MIPS_FP0_REGNUM): Remove.
8838 (MIPS_FSR_REGNUM): Remove.
8839 (mips_fbsd_supply_fpregs): Use mips_regnum.
8840 (mips_fbsd_supply_gregs): Likewise.
8841 (mips_fbsd_collect_fpregs): Likewise.
8842 (mips_fbsd_collect_gregs): Likewise.
8843
8844 2017-05-23 John Baldwin <jhb@FreeBSD.org>
8845
8846 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
8847 (getpfpregs_supplies): New function.
8848 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
8849 getfpregs_supplies.
8850 (mips_fbsd_store_inferior_registers): Likewise.
8851
8852 2017-05-22 Pedro Alves <palves@redhat.com>
8853
8854 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
8855 maintainer.
8856
8857 2017-05-22 Alan Hayward <alan.hayward@arm.com>
8858
8859 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
8860 (store_register): Likewise.
8861 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
8862 (get_decimal_float_return_value): Likewise.
8863 (do_ppc_sysv_return_value): Likewise.
8864 (ppc64_sysv_abi_push_integer): Likewise.
8865 (ppc64_sysv_abi_push_freg): Likewise.
8866 (ppc64_sysv_abi_return_value_base): Likewise.
8867 (ppc64_sysv_abi_return_value): Likewise.
8868 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
8869 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
8870 * rs6000-nat.c: Likewise.
8871 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
8872 (rs6000_value_to_register): Likewise.
8873 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
8874
8875 2017-05-21 Tom Tromey <tom@tromey.com>
8876
8877 PR rust/21466:
8878 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
8879 arrays as "[T]", not "[T; ]".
8880
8881 2017-05-19 Tom Tromey <tom@tromey.com>
8882
8883 PR rust/21484:
8884 * rust-lang.c (exp_descriptor_rust): New function.
8885 (rust_language_defn): Use it.
8886 * p-lang.c (pascal_language_defn): Update.
8887 * opencl-lang.c (opencl_language_defn): Update.
8888 * objc-lang.c (objc_language_defn): Update.
8889 * m2-lang.c (m2_language_defn): Update.
8890 * language.h (struct language_defn)
8891 <la_watch_location_expression>: New member.
8892 * language.c (unknown_language_defn, auto_language_defn)
8893 (local_language_defn): Update.
8894 * go-lang.c (go_language_defn): Update.
8895 * f-lang.c (f_language_defn): Update.
8896 * d-lang.c (d_language_defn): Update.
8897 * c-lang.h (c_watch_location_expression): Declare.
8898 * c-lang.c (c_watch_location_expression): New function.
8899 (c_language_defn, cplus_language_defn, asm_language_defn)
8900 (minimal_language_defn): Use it.
8901 * breakpoint.c (watch_command_1): Call
8902 la_watch_location_expression.
8903 * ada-lang.c (ada_language_defn): Update.
8904
8905 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
8906
8907 PR tui/21482
8908 * gdb_curses.h (NOMACROS): Define.
8909 (NCURSES_NOMACROS): Define.
8910
8911 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
8912
8913 PR tui/21482
8914 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
8915 arg to char *.
8916 * tui/tui-wingeneral.c (box_win): Likewise.
8917 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
8918 (tui_show_source_line): Likewise.
8919 (tui_show_exec_info_content): Likewise.
8920
8921 2017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
8922
8923 * sparc-tdep.c (sparc_structure_return_p)
8924 (sparc_arg_on_registers_p): New functions.
8925 (sparc32_store_arguments): Use them.
8926 * sparc64-tdep.c (sparc64_16_byte_align_p)
8927 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
8928 Handle TYPE_CODE_ARRAY.
8929
8930 2017-05-17 Yao Qi <yao.qi@linaro.org>
8931
8932 * cli/cli-decode.c (add_alias_cmd): New function.
8933 * command.h (add_alias_cmd): Declare.
8934 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
8935 instead call add_alias_cmd.
8936
8937 2017-05-17 Pedro Alves <palves@redhat.com>
8938
8939 * Makefile.in (nat_extra_makefile_frag): Rename to ...
8940 (nat_makefile_frag): ... this. All references updated.
8941 * configure.ac: Likewise.
8942 * configure.nat: Likewise. Enhance comments.
8943 * configure: Regenerate.
8944
8945 2017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
8946
8947 * procfs.c (procfs_create_inferior): Change prototype to match
8948 definition.
8949
8950 2017-05-13 Eli Zaretskii <eliz@gnu.org>
8951
8952 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
8953 C++ compiler warning.
8954
8955 2017-05-12 Tom Tromey <tom@tromey.com>
8956
8957 PR rust/21483:
8958 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
8959 recurse, just call value_struct_elt directly.
8960
8961 2017-05-12 Tom Tromey <tom@tromey.com>
8962
8963 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
8964 OP_RUST_ARRAY>: Fix.
8965
8966 2017-05-12 Tom Tromey <tom@tromey.com>
8967
8968 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
8969
8970 2017-05-09 Yao Qi <yao.qi@linaro.org>
8971
8972 * regcache.c: Include <forward_list>.
8973 (struct regcache_list): Remove.
8974 (current_regcache): Update.
8975 (get_thread_arch_aspace_regcache): Update for std::forward_list.
8976 (regcache_thread_ptid_changed): Likewise.
8977 (registers_changed_ptid): Likewise.
8978 (current_regcache_size): Likewise.
8979
8980 2017-05-09 Yao Qi <yao.qi@linaro.org>
8981
8982 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
8983 (current_regcache_size): New function.
8984 (current_regcache_test): New function.
8985 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
8986
8987 2017-05-08 Alan Hayward <alan.hayward@arm.com>
8988
8989 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
8990 (print_gp_register_row): Use get_frame_register_value.
8991
8992 2017-05-08 Alan Hayward <alan.hayward@arm.com>
8993
8994 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
8995 (mips_supply_fpregset): Likewise.
8996 (mips64_supply_gregset): Likewise.
8997
8998 2017-05-08 Alan Hayward <alan.hayward@arm.com>
8999
9000 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
9001 regcache->raw_supply_zeroed.
9002
9003 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
9004
9005 * configure.nat: Rearrange 'case' statements to match
9006 host before cpu.
9007
9008 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
9009
9010 * Makefile.in: Remove "@host_makefile_frag@". Add variables
9011 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
9012 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
9013 "@nat_extra_makefile_frag@".
9014 (Makefile): Remove dependency on "@frags@".
9015 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
9016 (data-directory/Makefile): Likewise.
9017 * config/aarch64/linux.mh: Deleted; moved contents to
9018 "gdb/configure.nat".
9019 * config/alpha/alpha-linux.mh: Likewise.
9020 * config/alpha/nbsd.mh: Likewise.
9021 * config/arm/linux.mh: Likewise.
9022 * config/arm/nbsdelf.mh: Likewise.
9023 * config/i386/cygwin.mh: Likewise.
9024 * config/i386/cygwin64.mh: Likewise.
9025 * config/i386/darwin.mh: Likewise.
9026 * config/i386/fbsd.mh: Likewise.
9027 * config/i386/fbsd64.mh: Likewise.
9028 * config/i386/go32.mh: Likewise.
9029 * config/i386/i386gnu.mh: Likewise.
9030 * config/i386/i386sol2.mh: Likewise.
9031 * config/i386/linux.mh: Likewise.
9032 * config/i386/linux64.mh: Likewise.
9033 * config/i386/mingw.mh: Likewise.
9034 * config/i386/mingw64.mh: Likewise.
9035 * config/i386/nbsd64.mh: Likewise.
9036 * config/i386/nbsdelf.mh: Likewise.
9037 * config/i386/nto.mh: Likewise.
9038 * config/i386/obsd.mh: Likewise.
9039 * config/i386/obsd64.mh: Likewise.
9040 * config/i386/sol2-64.mh: Likewise.
9041 * config/ia64/linux.mh: Likewise.
9042 * config/m32r/linux.mh: Likewise.
9043 * config/m68k/linux.mh: Likewise.
9044 * config/m68k/nbsdelf.mh: Likewise.
9045 * config/m68k/obsd.mh: Likewise.
9046 * config/m88k/obsd.mh: Likewise.
9047 * config/mips/fbsd.mh: Likewise.
9048 * config/mips/linux.mh: Likewise.
9049 * config/mips/nbsd.mh: Likewise.
9050 * config/mips/obsd64.mh: Likewise.
9051 * config/pa/linux.mh: Likewise.
9052 * config/pa/nbsd.mh: Likewise.
9053 * config/pa/obsd.mh: Likewise.
9054 * config/powerpc/aix.mh: Likewise.
9055 * config/powerpc/fbsd.mh: Likewise.
9056 * config/powerpc/linux.mh: Likewise.
9057 * config/powerpc/nbsd.mh: Likewise.
9058 * config/powerpc/obsd.mh: Likewise.
9059 * config/powerpc/ppc64-linux.mh: Likewise.
9060 * config/powerpc/spu-linux.mh: Likewise.
9061 * config/s390/linux.mh: Likewise.
9062 * config/sh/nbsd.mh: Likewise.
9063 * config/sparc/fbsd.mh: Likewise.
9064 * config/sparc/linux.mh: Likewise.
9065 * config/sparc/linux64.mh: Likewise.
9066 * config/sparc/nbsd64.mh: Likewise.
9067 * config/sparc/nbsdelf.mh: Likewise.
9068 * config/sparc/obsd64.mh: Likewise.
9069 * config/sparc/sol2.mh: Likewise.
9070 * config/tilegx/linux.mh: Likewise.
9071 * config/vax/nbsdelf.mh: Likewise.
9072 * config/vax/obsd.mh: Likewise.
9073 * config/xtensa/linux.mh: Likewise.
9074 * config/i386/i386gnu.mn: New file, with excerpts from
9075 "config/i386/i386gnu.mh".
9076 * configure: Regenerate.
9077 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
9078 *.mh files under "gdb/config".
9079 * configure.nat: New file, with contents from the
9080 "gdb/config/*/*.mh" files.
9081
9082 2017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
9083
9084 * btrace.c (btrace_clear): Free insn vector.
9085
9086 2017-05-05 Pedro Alves <palves@redhat.com>
9087
9088 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
9089 * configure: Regenerate.
9090
9091 2017-05-04 Pedro Alves <palves@redhat.com>
9092
9093 * Makefile.in (SFILES): Add progspace-and-thread.c.
9094 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
9095 (COMMON_OBS): Add progspace-and-thread.o.
9096 * breakpoint.c: Include "progspace-and-thread.h".
9097 (update_inserted_breakpoint_locations)
9098 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
9099 Use scoped_restore_current_pspace_and_thread.
9100 (create_std_terminate_master_breakpoint): Use
9101 scoped_restore_current_program_space.
9102 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
9103 (print_breakpoint_location): Use
9104 scoped_restore_current_program_space.
9105 (bp_loc_is_permanent): Use
9106 scoped_restore_current_pspace_and_thread.
9107 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
9108 (download_tracepoint_locations): Use
9109 scoped_restore_current_pspace_and_thread.
9110 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
9111 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
9112 (enum step_over_calls_kind): Moved from inferior.h.
9113 (class scoped_restore_current_thread): New class.
9114 * gdbthread.h (make_cleanup_restore_current_thread): Delete
9115 declaration.
9116 (scoped_restore_current_thread): New class.
9117 * infcmd.c: Include "common/gdb_optional.h".
9118 (continue_1, proceed_after_attach): Use
9119 scoped_restore_current_thread.
9120 (notice_new_inferior): Use scoped_restore_current_thread.
9121 * inferior.c: Include "progspace-and-thread.h".
9122 (restore_inferior, save_current_inferior): Delete.
9123 (add_inferior_command, clone_inferior_command): Use
9124 scoped_restore_current_pspace_and_thread.
9125 * inferior.h (scoped_restore_current_inferior): New class.
9126 * infrun.c: Include "progspace-and-thread.h" and
9127 "common/gdb_optional.h".
9128 (follow_fork_inferior): Use
9129 scoped_restore_current_pspace_and_thread.
9130 (scoped_restore_exited_inferior): New class.
9131 (handle_vfork_child_exec_or_exit): Use
9132 scoped_restore_exited_inferior,
9133 scoped_restore_current_pspace_and_thread,
9134 scoped_restore_current_thread and scoped_restore.
9135 (fetch_inferior_event): Use scoped_restore_current_thread.
9136 * linespec.c (decode_line_full, decode_line_1): Use
9137 scoped_restore_current_program_space.
9138 * mi/mi-main.c: Include "progspace-and-thread.h".
9139 (exec_continue): Use scoped_restore_current_thread.
9140 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
9141 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
9142 * proc-service.c (ps_pglobal_lookup): Use
9143 scoped_restore_current_program_space.
9144 * progspace-and-thread.c: New file.
9145 * progspace-and-thread.h: New file.
9146 * progspace.c (release_program_space, clone_program_space): Use
9147 scoped_restore_current_program_space.
9148 (restore_program_space, save_current_program_space)
9149 (save_current_space_and_thread): Delete.
9150 (switch_to_program_space_and_thread): Moved to
9151 progspace-and-thread.c.
9152 * progspace.h (save_current_program_space)
9153 (save_current_space_and_thread): Delete declarations.
9154 (scoped_restore_current_program_space): New class.
9155 * remote.c (remote_btrace_maybe_reopen): Use
9156 scoped_restore_current_thread.
9157 * symtab.c: Include "progspace-and-thread.h".
9158 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
9159 * thread.c (print_thread_info_1): Use
9160 scoped_restore_current_thread.
9161 (struct current_thread_cleanup): Delete.
9162 (do_restore_current_thread_cleanup)
9163 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
9164 (scoped_restore_current_thread::~scoped_restore_current_thread):
9165 ... this new dtor.
9166 (make_cleanup_restore_current_thread): Rename/convert to ...
9167 (scoped_restore_current_thread::scoped_restore_current_thread):
9168 ... this new ctor.
9169 (thread_apply_all_command): Use scoped_restore_current_thread.
9170 (thread_apply_command): Use scoped_restore_current_thread.
9171 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
9172 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
9173
9174 2017-05-04 Pedro Alves <palves@redhat.com>
9175
9176 * thread.c (make_cleanup_restore_current_thread): Move
9177 find_thread_ptid call before the is_stopped call. Assert that the
9178 thread is found. Replace is_stopped call by checking the thread's
9179 state directly. Remove unnecessary NULL-thread check.
9180
9181 2017-05-04 Pedro Alves <palves@redhat.com>
9182
9183 * corelow.c (thread_section_name): New class.
9184 (get_core_register_section, get_core_siginfo): Use it.
9185
9186 2017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
9187
9188 * corelow.c (sniff_core_bfd): Remove extra semicolon.
9189 (get_core_register_section): Remove xfree of NULL pointer.
9190
9191 2017-05-03 Alan Hayward <alan.hayward@arm.com>
9192
9193 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
9194 * regcache.c (regcache::raw_supply_zeroed): New function.
9195 * regcache.h (regcache::raw_supply_zeroed): New declaration.
9196
9197 2017-05-03 Simon Marchi <simon.marchi@ericsson.com>
9198
9199 * gdbarch.sh: Remove commented out definition of
9200 TARGET_CHAR_BIT.
9201 * gdbarch.h: Re-generate.
9202
9203 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
9204
9205 * configure: Regenerate.
9206
9207 2017-05-02 Simon Marchi <simon.marchi@ericsson.com>
9208
9209 * solib-target.c (solib_target_relocate_section_addresses):
9210 Remove num_section_bases, num_bases, segment_bases variables.
9211
9212 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
9213
9214 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
9215
9216 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
9217
9218 * solib-target.c: Include <vector>
9219 (struct lm_info_target) <~lm_info_target>: Remove.
9220 <segment_bases, section_bases>: Change type to
9221 std::vector<CORE_ADDR>.
9222 (library_list_start_segment, library_list_start_section,
9223 library_list_end_library,
9224 solib_target_relocate_section_addresses): Adjust.
9225
9226 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
9227
9228 * gdbarch.sh (software_single_step): Change return type to
9229 std::vector<CORE_ADDR>.
9230 * gdbarch.c, gdbarch.h: Re-generate.
9231 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
9232 Adjust.
9233 (arm_deal_with_atomic_sequence_raw): Adjust.
9234 (thumb_get_next_pcs_raw): Adjust.
9235 (arm_get_next_pcs_raw): Adjust.
9236 (arm_get_next_pcs): Adjust.
9237 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
9238 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
9239 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
9240 (alpha_software_single_step): Adjust.
9241 * alpha-tdep.h (alpha_software_single_step): Adjust.
9242 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
9243 * arm-tdep.c (arm_software_single_step): Adjust.
9244 (arm_breakpoint_kind_from_current_state): Adjust.
9245 * arm-tdep.h (arm_software_single_step): Adjust.
9246 * breakpoint.c (insert_single_step_breakpoint): Adjust.
9247 * cris-tdep.c (cris_software_single_step): Adjust.
9248 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
9249 (micromips_deal_with_atomic_sequence): Adjust.
9250 (deal_with_atomic_sequence): Adjust.
9251 (mips_software_single_step): Adjust.
9252 * mips-tdep.h (mips_software_single_step): Adjust.
9253 * moxie-tdep.c (moxie_software_single_step): Adjust.
9254 * nios2-tdep.c (nios2_software_single_step): Adjust.
9255 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
9256 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
9257 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
9258 * s390-linux-tdep.c (s390_software_single_step): Adjust.
9259 * sparc-tdep.c (sparc_software_single_step): Adjust.
9260 * spu-tdep.c (spu_software_single_step): Adjust.
9261 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
9262
9263 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
9264
9265 * gdbarch.sh: Use semi-colon as field separator instead of colon.
9266 * gdbarch.h: Re-generate.
9267
9268 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
9269
9270 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
9271 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
9272 * python/py-instruction.c, python/py-instruction.h: New file.
9273 * python/py-record.c: Add py-instruction.h include.
9274 (gdbpy_initialize_record): Make gdb.Instruction a super class of
9275 gdb.RecordInstruction.
9276 * python/python-internal.h: Add gdbpy_initialize_instruction
9277 declaration.
9278 * python/python.c (do_start_initialization): Add
9279 gdbpy_initialize_instruction.
9280
9281 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
9282
9283 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
9284 Remove.
9285 (btrace_func_from_recpy_func): New function.
9286 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
9287 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
9288 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
9289 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
9290 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
9291 Also, use new helper functions.
9292 (btpy_list_item): Use new helper functions.
9293 (recpy_bt_function_call_history): Use new type name.
9294 (btpy_call_getset): Remove.
9295 (gdbpy_initialize_btrace): Remove code to initialize
9296 gdb.BtraceFunctionCall.
9297 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
9298 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
9299 recpy_bt_func_prev, recpy_bt_func_next): New export.
9300 * python/py-record.c (recpy_func_type): New static object.
9301 (recpy_func_new, recpy_func_level, recpy_func_symbol,
9302 recpy_func_instructions, recpy_func_up, recpy_func_prev,
9303 recpy_func_next): New function.
9304 (recpy_element_hash, recpy_element_richcompare): Updated comment.
9305 (recpy_func_getset): New static object.
9306 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
9307 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
9308
9309 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
9310
9311 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
9312 (btpy_object, btpy_insn_type, btpy_new): Remove.
9313 (btpy_list_object): Use gdb.RecordInstruction type instead of
9314 gdb.BtraceInstruction type.
9315 (btrace_insn_from_recpy_insn): New function.
9316 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
9317 btpy_new.
9318 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
9319 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
9320 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
9321 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
9322 instead of btpy_object.
9323 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
9324 btpy_insn_data, btpy_insn_decode): Rename to ...
9325 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
9326 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
9327 recpy_bt_insn_decode): This. Also, use new helper functions.
9328 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
9329 recpy_insn_type.
9330 (btpy_insn_getset): Remove.
9331 (gdbpy_initialize_btrace): Remove code to initialize
9332 gdb.BtraceInstruction. Use recpy_element_object.
9333 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
9334 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
9335 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
9336 * python/py-record.c (recpy_insn_type): New static object.
9337 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
9338 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
9339 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
9340 New function.
9341 (recpy_insn_getset): New static object.
9342 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
9343 * python/py-record.h (recpy_element_object): New typedef.
9344 (recpy_insn_type, recpy_insn_new): New export.
9345
9346 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
9347
9348 * py-record-btrace.c (btpy_insn_new): Removed.
9349 (btpy_insn_or_gap_new): New function.
9350 (btpy_insn_error): Removed.
9351 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
9352 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
9353 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
9354 btpy_insn_or_gap_new instead of btpy_insn_new.
9355 (btpy_insn_getset): Remove btpy_insn_error.
9356 * py-record.c (recpy_gap_type): New static object.
9357 (recpy_gap_object): New typedef.
9358 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
9359 recpy_gap_reason_string): New function.
9360 (recpy_gap_getset): New static object.
9361 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
9362 * py-record.h (recpy_gap_new): New export.
9363
9364 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
9365
9366 * python/py-record.c (recpy_ptid): Remove.
9367 (recpy_record_getset): Remove recpy_ptid.
9368
9369 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
9370
9371 * btrace.c (btrace_fetch): Set inferior_ptid.
9372 * python/py-record-btrace.c: Add "py-record.h" include.
9373 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
9374 recpy_bt_end, recpy_bt_instruction_history,
9375 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
9376 in gdb.Record object instead of current ptid.
9377 * python/py-record.c: Include new "py-record.h" file.
9378 (recpy_record_object): Moved to py-record.h.
9379 * python/py-record.h: New file.
9380
9381 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
9382
9383 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
9384 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
9385 indentation.
9386
9387 2017-05-01 Joel Brobecker <brobecker@adacore.com>
9388
9389 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
9390 the past maintainers section.
9391
9392 2017-04-28 Yao Qi <yao.qi@linaro.org>
9393
9394 * infcmd.c (get_return_value): Use regcache ctor, and remove
9395 cleanup.
9396
9397 2017-04-28 Yao Qi <yao.qi@linaro.org>
9398 Pedro Alves <palves@redhat.com>
9399
9400 * regcache.c (regcache::regcache): New tag dispatch ctor.
9401 (do_cooked_read): Moved above.
9402 (regcache_dup): Use the tag dispatch ctor..
9403 * regcache.h (regcache): Declare ctor, delete copy ctor and
9404 assignment operator, remove friend regcache_dup.
9405
9406 2017-04-28 Yao Qi <yao.qi@linaro.org>
9407
9408 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
9409 call method save instead of regcache_cpy.
9410 * regcache.h (struct regcache): Make regcache_dup a friend.
9411
9412 2017-04-28 Yao Qi <yao.qi@linaro.org>
9413
9414 * regcache.c (struct regcache): Move to regcache.h
9415 (regcache::arch): New method.
9416 (regcache_get_ptid): Update.
9417 (get_regcache_arch): Call arch method.
9418 (get_regcache_aspace): Call method aspace.
9419 (register_buffer): Change it to method.
9420 (regcache_save): Change it to regcache::save.
9421 (regcache_restore): Likewise.
9422 (regcache_cpy_no_passthrough): Remove the declaration.
9423 (regcache_cpy): Call methods restore and cpy_no_passthrough.
9424 (regcache_cpy_no_passthrough): Change it to method
9425 cpy_no_passthrough.
9426 (regcache_register_status): Change it to method
9427 get_register_status.
9428 (regcache_invalidate): Change it to method invalidate.
9429 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
9430 (regcache_raw_update): Change it to method raw_update.
9431 (regcache_raw_read): Likewise.
9432 (regcache_raw_read_signed): Likewise.
9433 (regcache_raw_read_unsigned): Likewise.
9434 (regcache_raw_write_signed): Likewise.
9435 (regcache_raw_write_unsigned): Likewise.
9436 (regcache_cooked_read): Likewise.
9437 (regcache_cooked_read_value): Likewise.
9438 (regcache_cooked_read_signed): Likewise.
9439 (regcache_cooked_read_unsigned): Likewise.
9440 (regcache_cooked_write_signed): Likewise.
9441 (regcache_cooked_write_unsigned): Likewise.
9442 (regcache_raw_set_cached_value): Likewise.
9443 (regcache_raw_write): Likewise.
9444 (regcache_cooked_write): Likewise.
9445 (regcache_xfer_part): Likewise.
9446 (regcache_raw_read_part): Likewise.
9447 (regcache_raw_write_part): Likewise.
9448 (regcache_cooked_read_part): Likewise.
9449 (regcache_cooked_write_part): Likewise.
9450 (regcache_raw_supply): Likewise.
9451 (regcache_raw_collect): Likewise.
9452 (regcache_transfer_regset): Likewise.
9453 (regcache_supply_regset): Likewise.
9454 (regcache_collect_regset): Likewise.
9455 (regcache_debug_print_register): Likewise.
9456 (enum regcache_dump_what): Move it to regcache.h.
9457 (regcache_dump): Change it to method dump.
9458 * regcache.h (enum regcache_dump_what): New.
9459 (class regcache): New.
9460 * target.c (target_fetch_registers): Call method
9461 debug_print_register.
9462 (target_store_registers): Likewise.
9463
9464 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9465
9466 * windows-nat.c (struct lm_info_windows): Initialize field.
9467 (windows_make_so): Allocate lm_info_windows with new.
9468 (windows_free_so): Free lm_info_windows with delete.
9469
9470 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9471
9472 * solib-darwin.c (struct lm_info_darwin): Initialize field.
9473 (darwin_current_sos): Allocate lm_info_darwin with new, remove
9474 cleanup.
9475 (darwin_free_so): Free lm_info_darwin with delete.
9476
9477 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9478
9479 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
9480 <l_addr_p>: Change type to bool.
9481 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
9482 (svr4_free_so): Free lm_info_svr4 with delete.
9483 (svr4_copy_library_list): Replace memcpy with call to copy
9484 constructor.
9485 (library_list_start_library, svr4_default_sos): Allocate
9486 lm_info_svr4 with new.
9487
9488 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9489
9490 * solib-target.c (struct lm_info_target): Add destructor,
9491 initialize fields.
9492 <name>: Change type to std::string.
9493 (library_list_start_library): Allocate lm_info_target with new.
9494 (solib_target_free_library_list): Free lm_info_target with
9495 delete.
9496 (solib_target_current_sos): Adapt to std::string.
9497 (solib_target_free_so): Free lm_info_target with delete.
9498
9499 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9500
9501 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
9502 fields.
9503 (frv_current_sos): Allocate lm_info_frv with new.
9504 (frv_relocate_main_executable): Free lm_info_frv with delete,
9505 allocate with new.
9506 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
9507
9508 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9509
9510 * solib-frv.c (struct lm_info_frv): Fix indentation.
9511
9512 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9513
9514 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
9515 map field.
9516 (dsbt_current_sos): Allocate lm_info_dsbt with new.
9517 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
9518 and allocate with new.
9519 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
9520
9521 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9522
9523 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
9524 <filename, member_name>: Change type to std::string.
9525 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
9526 (library_list_start_library): Allocate lm_info_aix with new.
9527 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
9528 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
9529 with copy constructor.
9530
9531 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9532
9533 * solist.h (struct lm_info): Remove.
9534 (struct lm_info_base): New class.
9535 (struct so_list) <lm_info>: Change type to lm_info_base *.
9536 * nto-tdep.c (struct lm_info): Remove.
9537 (lm_addr): Adjust.
9538 * solib-aix.c (struct lm_info): Rename to ...
9539 (struct lm_info_aix): ... this. Extend lm_info_base.
9540 (lm_info_p): Rename to ...
9541 (lm_info_aix_p): ... this, and adjust.
9542 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
9543 solib_aix_parse_libraries, library_list_start_library,
9544 solib_aix_free_library_list, solib_aix_parse_libraries,
9545 solib_aix_get_library_list,
9546 solib_aix_relocate_section_addresses, solib_aix_free_so,
9547 solib_aix_get_section_offsets,
9548 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
9549 Adjust.
9550 (struct solib_aix_inferior_data) <library_list>: Adjust.
9551 * solib-darwin.c (struct lm_info): Rename to ...
9552 (struct lm_info_darwin): ... this. Extend lm_info_base.
9553 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
9554 * solib-dsbt.c (struct lm_info): Rename to ...
9555 (struct lm_info_dsbt): ... this. Extend lm_info_base.
9556 (struct dsbt_info) <main_executable_lm_info): Adjust.
9557 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
9558 dsbt_relocate_section_addresses): Adjust.
9559 * solib-frv.c (struct lm_info): Rename to ...
9560 (struct lm_info_frv): ... this. Extend lm_info_base.
9561 (main_executable_lm_info): Adjust.
9562 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
9563 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
9564 find_canonical_descriptor_in_load_object,
9565 frv_fdpic_find_canonical_descriptor): Adjust.
9566 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
9567 to lm_info_svr4.
9568 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
9569 svr4_clear_so, svr4_copy_library_list,
9570 library_list_start_library, svr4_default_sos, svr4_read_so_list,
9571 svr4_current_sos, svr4_fetch_objfile_link_map,
9572 solist_update_incremental): Adjust.
9573 * solib-svr4.h (struct lm_info_svr4): Move here from
9574 solib-svr4.c.
9575 * solib-target.c (struct lm_info): Rename to ...
9576 (struct lm_info_target): ... this. Extend lm_info_base.
9577 (lm_info_p): Rename to ...
9578 (lm_info_target_p): ... this.
9579 (solib_target_parse_libraries, library_list_start_segment,
9580 library_list_start_section, library_list_start_library,
9581 library_list_end_library, solib_target_free_library_list,
9582 solib_target_current_sos, solib_target_free_so,
9583 solib_target_relocate_section_addresses): Adjust.
9584 * windows-nat.c (struct lm_info): Rename to ...
9585 (struct lm_info_windows): ... this. Extend lm_info_base.
9586 (windows_make_so, handle_load_dll, handle_unload_dll,
9587 windows_xfer_shared_libraries): Adjust.
9588
9589 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9590
9591 * solib-darwin.c (struct darwin_so_list): Remove.
9592 (darwin_current_sos): Allocate an so_list object instead of a
9593 darwin_so_list, separately allocate an lm_info object.
9594 (darwin_free_so): Free lm_info.
9595
9596 2017-04-28 John Baldwin <jhb@FreeBSD.org>
9597
9598 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
9599 with fprintf_filtered.
9600
9601 2017-04-28 Yao Qi <yao.qi@linaro.org>
9602
9603 * regcache.c (regcache::regcache): New function.
9604 (regcache::~regcache): New function.
9605 (regcache_xmalloc_1): Remove.
9606 (regcache_xmalloc): Call new regcache.
9607 (regcache_xfree): Call delete regcache.
9608 (get_thread_arch_aspace_regcache): Call new regcache.
9609
9610 2017-04-28 Yao Qi <yao.qi@linaro.org>
9611
9612 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
9613 lwp instead of ptid_get_lwp.
9614
9615 2017-04-28 Yao Qi <yao.qi@linaro.org>
9616
9617 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
9618 lwp_info instead of getting from inferior_ptid.
9619
9620 2017-04-27 Keith Seitz <keiths@redhat.com>
9621
9622 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
9623 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
9624 (CV_CONVERSION_BADNESS): Define.
9625 (rank_one_type): Remove overly restrictive rvalue reference
9626 rank checks.
9627 Add cv-qualifier checks and subranks for type equality.
9628 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
9629 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
9630 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
9631
9632 2017-04-27 Simon Marchi <simon.marchi@ericsson.com>
9633
9634 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
9635 count when creating the object.
9636
9637 2017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
9638 Ulrich Weigand <uweigand@de.ibm.com>
9639
9640 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
9641 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
9642 is used in AIX.
9643 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
9644 (process_xcoff_symbol): Likewise.
9645 (scan_xcoff_symtab): Likewise.
9646
9647 2017-04-26 Alan Hayward <alan.hayward@arm.com>
9648
9649 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
9650 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
9651 (ia64_access_reg): Use get_frame_register_unsigned.
9652 (ia64_access_rse_reg): Likewise.
9653 (ia64_libunwind_frame_prev_register): Likewise.
9654
9655 2017-04-26 Jiong Wang <jiong.wang@arm.com>
9656
9657 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
9658 * gdbarch.c: Regenerated.
9659 * gdbarch.h: Regenerated.
9660 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
9661 visibility external.
9662 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
9663 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
9664 (enum cfa_how_kind): Move to ...
9665 (struct dwarf2_frame_state_reg_info): Likewise.
9666 (struct dwarf2_frame_state): Likewise.
9667 * dwarf2-frame.h: ... here.
9668 (dwarf2_frame_state_alloc_regs): New declaration.
9669 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
9670 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
9671
9672 2017-04-26 Alan Hayward <alan.hayward@arm.com>
9673
9674 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
9675 regcache_raw_read_unsigned.
9676 (xtensa_pseudo_register_write): Likewise.
9677
9678 2017-04-26 Alan Hayward <alan.hayward@arm.com>
9679
9680 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
9681 (nds32_pseudo_register_write): Likewise.
9682
9683 2017-04-25 Yao Qi <yao.qi@linaro.org>
9684
9685 * regcache.c (struct regcache) <readonly_p>: Change its type
9686 to bool.
9687 (regcache_xmalloc_1): Update parameter type and callers update.
9688
9689 2017-04-25 Yao Qi <yao.qi@linaro.org>
9690
9691 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
9692 set_gdbarch_wchar_bit.
9693 * arm-tdep.c (arm_gdbarch_init): Likewise.
9694
9695 2017-04-25 Pedro Alves <palves@redhat.com>
9696
9697 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
9698 (BothAreRelocatable, memcopy, memmove): Don't define.
9699 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
9700 macros.
9701
9702 2017-04-25 Pedro Alves <palves@redhat.com>
9703
9704 * common/common-defs.h: Include "common/poison.h".
9705 * common/function-view.h: (Not, Or, Requires): Move to traits.h
9706 and adjust.
9707 * common/poison.h: New file.
9708 * common/traits.h: Include <type_traits>.
9709 (Not, Or, Requires): New, moved from common/function-view.h.
9710
9711 2017-04-25 Pedro Alves <palves@redhat.com>
9712
9713 * breakpoint.h (struct breakpoint): In-class initialize all
9714 fields. Make boolean fields "bool".
9715 * breakpoint.c (init_raw_breakpoint_without_location): Remove
9716 memset call and initializations no longer necessary.
9717
9718 2017-04-25 Pedro Alves <palves@redhat.com>
9719
9720 * btrace.c (pt_btrace_insn_flags): Change parameter type to
9721 reference.
9722 (pt_btrace_insn): New function.
9723 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
9724
9725 2017-04-25 Pedro Alves <palves@redhat.com>
9726
9727 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
9728 "base" field and inherit from "bp_location" instead. Add
9729 non-default ctor.
9730 (allocate_location_exception): Use new non-default ctor.
9731 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
9732 (init_bp_location): Convert to ...
9733 (bp_location::bp_location): ... this new ctor, and remove memset
9734 call.
9735 (base_breakpoint_allocate_location): Use the new non-default ctor.
9736 * breakpoint.h (bp_location): Now a class. Declare default and
9737 non-default ctors. In-class initialize all members.
9738 (init_bp_location): Remove declaration.
9739
9740 2017-04-25 Pedro Alves <palves@redhat.com>
9741
9742 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
9743 assignment operator.
9744
9745 2017-04-24 Yao Qi <yao.qi@linaro.org>
9746
9747 * doublest.c (convert_doublest_to_floatformat): Call
9748 floatformat_totalsize_bytes.
9749
9750 2017-04-22 Tom Tromey <tom@tromey.com>
9751
9752 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
9753 ui_out_emit_list.
9754 * stack.c (print_frame): Use ui_out_emit_list.
9755 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
9756 ui_out_emit_list.
9757 * mi/mi-main.c (print_one_inferior)
9758 (mi_cmd_data_list_register_names)
9759 (mi_cmd_data_list_register_values, mi_cmd_list_features)
9760 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
9761 ui_out_emit_list.
9762 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
9763 (mi_output_solib_attribs): Use ui_out_emit_list,
9764 ui_out_emit_tuple.
9765 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
9766 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
9767 (mi_cmd_stack_list_args, list_args_or_locals): Use
9768 ui_out_emit_list.
9769 * disasm.c (do_assembly_only): Use ui_out_emit_list.
9770 * breakpoint.c (print_solib_event, output_thread_groups): Use
9771 ui_out_emit_list.
9772
9773 2017-04-22 Tom Tromey <tom@tromey.com>
9774
9775 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
9776 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
9777 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
9778
9779 2017-04-22 Tom Tromey <tom@tromey.com>
9780
9781 * tracepoint.c (tvariables_info_1)
9782 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
9783
9784 2017-04-22 Tom Tromey <tom@tromey.com>
9785
9786 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
9787 annotate_arg_emitter.
9788 * breakpoint.c (print_mention_watchpoint)
9789 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
9790 * annotate.h (struct annotate_arg_emitter): New.
9791
9792 2017-04-22 Tom Tromey <tom@tromey.com>
9793
9794 * record-btrace.c (record_btrace_insn_history)
9795 (record_btrace_insn_history_range, record_btrace_call_history)
9796 (record_btrace_call_history_range): Use ui_out_emit_tuple.
9797 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
9798 ui_out_emit_tuple.
9799 * stack.c (print_frame_info): Use ui_out_emit_tuple.
9800 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
9801 * skip.c (skip_info): Use ui_out_emit_tuple.
9802 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
9803 * progspace.c (print_program_space): Use ui_out_emit_tuple.
9804 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
9805 * osdata.c (info_osdata): Use ui_out_emit_tuple.
9806 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
9807 ui_out_emit_tuple.
9808 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
9809 (output_register, mi_cmd_data_read_memory)
9810 (mi_cmd_data_read_memory_bytes, mi_load_progress)
9811 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
9812 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
9813 Use ui_out_emit_tuple.
9814 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
9815 ui_out_emit_tuple.
9816 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
9817 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
9818 * linux-thread-db.c (info_auto_load_libthread_db): Use
9819 ui_out_emit_tuple.
9820 * inferior.c (print_inferior): Use ui_out_emit_tuple.
9821 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
9822 * disasm.c (do_mixed_source_and_assembly_deprecated)
9823 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
9824 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
9825 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
9826 * breakpoint.c (print_one_breakpoint_location)
9827 (print_one_breakpoint): Use ui_out_emit_tuple.
9828 * auto-load.c (print_script, info_auto_load_cmd): Use
9829 ui_out_emit_tuple.
9830 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
9831
9832 2017-04-21 Simon Marchi <simon.marchi@ericsson.com>
9833
9834 * thread.c (print_thread_info_1): Remove dead code.
9835
9836 2017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
9837
9838 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
9839 GDB_SELF_TEST.
9840 * arm-tdep.c (selftests::arm_record_test): Likewise.
9841
9842 2017-04-21 Yao Qi <yao.qi@linaro.org>
9843
9844 * regcache.c (regcache_restore): Remove argument 2. Replace
9845 argument 3 with regcache. Get register status from
9846 src->register_status and get register contents from
9847 register_buffer (src, regnum).
9848 (regcache_cpy): Update.
9849
9850 2017-04-19 Pedro Alves <palves@redhat.com>
9851
9852 * gdbthread.h (thread): Add missing closing parenthesis in
9853 comment.
9854
9855 2017-04-19 Pedro Alves <palves@redhat.com>
9856
9857 * common/refcounted-object.h: New file.
9858 * gdbthread.h: Include "common/refcounted-object.h".
9859 (thread_info): Inherit from refcounted_object and add comments.
9860 (thread_info::incref, thread_info::decref)
9861 (thread_info::m_refcount): Delete.
9862 (thread_info::deletable): Use the refcounted_object::refcount()
9863 method.
9864 * inferior.c (current_inferior_): Add comment.
9865 (set_current_inferior): Increment/decrement refcounts.
9866 (prune_inferiors, remove_inferior_command): Skip inferiors marked
9867 not-deletable instead of comparing with the current inferior.
9868 (initialize_inferiors): Increment the initial inferior's refcount.
9869 * inferior.h (struct inferior): Forward declare.
9870 Include "common/refcounted-object.h".
9871 (current_inferior, set_current_inferior): Move declaration to
9872 before struct inferior's definition, and fix comment.
9873 (inferior): Inherit from refcounted_object. Add comments.
9874 * thread.c (switch_to_thread_no_regs): Reference the thread's
9875 inferior pointer directly instead of doing a ptid lookup.
9876 (switch_to_no_thread): New function.
9877 (switch_to_thread(thread_info *)): New function, factored out
9878 from ...
9879 (switch_to_thread(ptid_t)): ... this.
9880 (restore_current_thread): Delete.
9881 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
9882 fields, and add 'inf' field.
9883 (do_restore_current_thread_cleanup): Check whether old->inf is
9884 alive instead of looking up an inferior by ptid. Use
9885 switch_to_thread and switch_to_no_thread.
9886 (restore_current_thread_cleanup_dtor): Use old->inf directly
9887 instead of lookup up an inferior by id. Decref the inferior.
9888 Don't restore 'removable'.
9889 (make_cleanup_restore_current_thread): Same the inferior pointer
9890 in old, instead of the inferior number. Incref the inferior.
9891 Don't save/clear 'removable'.
9892
9893 2017-04-19 Pedro Alves <palves@redhat.com>
9894
9895 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9896 unittests/scoped_restore-selftests.c.
9897 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
9898 * common/scoped_restore.h (scoped_restore_base): Make "class".
9899 (scoped_restore_base::release): New public method.
9900 (scoped_restore_base::scoped_restore_base): New protected ctor.
9901 (scoped_restore_base::m_saved_var): New protected field.
9902 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
9903 scoped_restore_base base class instead of m_saved_var directly.
9904 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
9905 (scoped_restore_tmpl::scoped_restore_tmpl(const
9906 scoped_restore_tmpl<T>&)): Likewise.
9907 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
9908 method.
9909 (scoped_restore_tmpl::saved_var): New method.
9910 (scoped_restore_tmpl::m_saved_var): Delete.
9911 * inferior.h (inferior::detaching): Now a bool.
9912 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
9913 cleanup.
9914 * unittests/scoped_restore-selftests.c: New file.
9915
9916 2017-04-19 Pedro Alves <palves@redhat.com>
9917
9918 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
9919 Re-sort in alphabetic order.
9920
9921 2017-04-18 Pedro Alves <palves@redhat.com>
9922
9923 * xml-support.c (obstack_xml_printf): Delete.
9924 * xml-support.h (obstack_xml_printf): Delete.
9925
9926 2017-04-18 Pedro Alves <palves@redhat.com>
9927
9928 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
9929 vdebug, verror, body_text, start_element, end_element, name,
9930 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
9931 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
9932 is_xinclude>: Make private and add m_ prefix.
9933 (gdb_xml_parser::body_text): New method, based on ...
9934 (gdb_xml_body_text): ... this. Adjust.
9935 (gdb_xml_parser::vdebug): New method, based on ...
9936 (gdb_xml_debug): ... this. Adjust.
9937 (gdb_xml_parser::verror): New method, based on ...
9938 (gdb_xml_error): ... this. Adjust.
9939 (gdb_xml_parser::start_element): New method, based on ...
9940 (gdb_xml_start_element): ... this. Adjust.
9941 (gdb_xml_start_element_wrapper): Defer to
9942 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
9943 (gdb_xml_parser::end_element): New method, based on ...
9944 (gdb_xml_end_element_wrapper): ... this. Adjust.
9945 (gdb_xml_parser::~gdb_xml_parser): Adjust.
9946 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
9947 (gdb_xml_parser::use_dtd): New method, based on ...
9948 (gdb_xml_use_dtd): ... this. Adjust.
9949 (gdb_xml_parser::parse): New method, based on ...
9950 (gdb_xml_parse): ... this. Adjust.
9951 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
9952 (xinclude_start_include): Adjust to call the parser's name method.
9953 (xml_xinclude_default, xml_xinclude_start_doctype)
9954 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
9955 method.
9956 (xml_process_xincludes): Adjust to call parser methods.
9957 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
9958 declarations.
9959
9960 2017-04-18 Pedro Alves <palves@redhat.com>
9961
9962 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
9963 gdb::optional<std::string>.
9964 * xml-support.c: Include <string>.
9965 (scope_level::scope_level(scope_level &&))
9966 (scope_level::~scope_level): Delete.
9967 (scope_level::body): Now a std::string.
9968 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
9969 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
9970 parameter.
9971 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
9972 (xinclude_parsing_data::output): Now a std::string reference.
9973 (xinclude_start_include): Adjust.
9974 (xml_xinclude_default): Adjust.
9975 (xml_process_xincludes): Add 'output' parameter, and return bool.
9976 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
9977 and return bool.
9978 * xml-tdesc.c: Include <unordered_map> and <string>.
9979 (tdesc_xml_cache): Delete.
9980 (tdesc_xml_cache_s): Delete.
9981 (xml_cache): Now an std::unordered_map.
9982 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
9983 (target_fetch_description_xml): Change return type to
9984 gdb::optional<std::string>, and adjust.
9985 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
9986 (target_fetch_description_xml): Change return type to
9987 gdb::optional<std::string>.
9988
9989 2017-04-18 Pedro Alves <palves@redhat.com>
9990
9991 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9992 unittests/optional-selftests.c.
9993 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
9994 * unittests/optional-selftests.c: New file.
9995 * unittests/optional/assignment/1.cc: New file.
9996 * unittests/optional/assignment/2.cc: New file.
9997 * unittests/optional/assignment/3.cc: New file.
9998 * unittests/optional/assignment/4.cc: New file.
9999 * unittests/optional/assignment/5.cc: New file.
10000 * unittests/optional/assignment/6.cc: New file.
10001 * unittests/optional/assignment/7.cc: New file.
10002 * unittests/optional/cons/copy.cc: New file.
10003 * unittests/optional/cons/default.cc: New file.
10004 * unittests/optional/cons/move.cc: New file.
10005 * unittests/optional/cons/value.cc: New file.
10006 * unittests/optional/in_place.cc: New file.
10007 * unittests/optional/observers/1.cc: New file.
10008 * unittests/optional/observers/2.cc: New file.
10009
10010 2017-04-18 Pedro Alves <palves@redhat.com>
10011
10012 * common/gdb_optional.h: Include common/traits.h.
10013 (in_place_t): New type.
10014 (in_place): New constexpr variable.
10015 (optional::optional): Remove member initialization of
10016 m_instantiated.
10017 (optional::optional(in_place_t...)): New constructor.
10018 (optional::~optional): Use reset.
10019 (optional::optional(const optional&)): New.
10020 (optional::optional(const optional&&)): New.
10021 (optional::optional(T &)): New.
10022 (optional::optional(T &&)): New.
10023 (operator::operator=(const optional &)): New.
10024 (operator::operator=(optional &&)): New.
10025 (operator::operator= (const T &))
10026 (operator::operator= (T &&))
10027 (operator::emplace (Args &&... args)): Return a T&. Use reset.
10028 (operator::reset): New.
10029 (operator::m_instantiated):: Add in-class initializer.
10030 * common/traits.h: Include <type_traits>.
10031 (struct And): New types.
10032
10033 2017-04-18 Pedro Alves <palves@redhat.com>
10034
10035 * xml-support.c: Include <vector>.
10036 (scope_level::scope_level(const gdb_xml_element *))
10037 (scope_level::scope_level(scope_level&&)): New.
10038 (scope_level::~scope_level): New.
10039 (scope_level_s): Delete.
10040 (gdb_xml_parser::scopes): Now a std::vector.
10041 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
10042 Use std::vector.
10043 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
10044 scope cleanup code.
10045 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
10046 of the scopes member. Use std::vector::emplace_back.
10047
10048 2017-04-18 Pedro Alves <palves@redhat.com>
10049
10050 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
10051 a bool.
10052 (gdb_xml_end_element): Change type of first parameter.
10053 (gdb_xml_cleanup): Rename to ...
10054 (gdb_xml_parser::~gdb_xml_parser): ... this.
10055 (gdb_xml_create_parser_and_cleanup): Delete with ...
10056 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
10057 to this new ctor.
10058 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
10059 using gdb_xml_create_parser_and_cleanup.
10060 (xinclude_parsing_data): Add ctor/dtor.
10061 (xml_xinclude_cleanup): Delete.
10062 (xml_process_xincludes): Create a local xinclude_parsing_data
10063 instead of heap-allocating one. Create a local gdb_xml_parser
10064 instead of heap-allocating one with
10065 gdb_xml_create_parser_and_cleanup.
10066
10067 2017-04-18 John Baldwin <jhb@FreeBSD.org>
10068
10069 PR threads/20743
10070 * fbsd-nat.c (resume_one_thread_cb): Remove.
10071 (resume_all_threads_cb): Remove.
10072 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
10073 iterate_over_threads.
10074
10075 2017-04-17 Joel Brobecker <brobecker@adacore.com>
10076
10077 * NEWS: Create a new section for the next release branch.
10078 Rename the section of the current branch, now that it has
10079 been cut.
10080
10081 2017-04-17 Joel Brobecker <brobecker@adacore.com>
10082
10083 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
10084 * version.in: Bump version to 8.0.50.DATE-git.
10085
10086 2017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
10087
10088 PR gdb/21385
10089 * windows-nat.c (windows_create_inferior): Declare 'allargs'
10090 independently of the host, and fix build breakage on Cygwin.
10091
10092 2017-04-13 Pedro Alves <palves@redhat.com>
10093
10094 * inferior.c (free_inferior): Convert to ...
10095 (inferior::~inferior): ... this dtor.
10096 (inferior::inferior): New ctor, factored out from ...
10097 (add_inferior_silent): ... here. Allocate the inferior with a new
10098 expression.
10099 (delete_inferior): Call delete instead of free_inferior.
10100 * inferior.h (gdb_environ, continuation): Forward declare.
10101 (inferior): Now a class. Add in-class initialization to all
10102 members. Make boolean fields bool, except 'detaching'.
10103 (inferior::inferior): New explicit ctor.
10104 (inferior::~inferior): New.
10105
10106 2017-04-13 Pedro Alves <palves@redhat.com>
10107
10108 * inferior.c (init_inferior_list): Delete.
10109 * inferior.h (init_inferior_list): Delete.
10110
10111 2017-04-13 Pedro Alves <palves@redhat.com>
10112
10113 PR threads/13217
10114 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
10115 (top level): Call it twice, with different thread sets.
10116
10117 2017-04-13 Pedro Alves <palves@redhat.com>
10118
10119 * thread.c: Include <algorithm>.
10120 (thread_array_cleanup): Delete.
10121 (scoped_inc_dec_ref): New class.
10122 (live_threads_count): New function.
10123 (set_thread_refcount): Delete.
10124 (tp_array_compar_ascending): Now a bool.
10125 (tp_array_compar): Convert to a std::sort comparison function.
10126 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
10127 and live_threads_count.
10128
10129 2017-04-13 Pedro Alves <palves@redhat.com>
10130
10131 * infrun.c (follow_fork_inferior): Also switch the current
10132 inferior.
10133
10134 2017-04-13 Pedro Alves <palves@redhat.com>
10135
10136 * breakpoint.c (watch_command_1): Save watchpoint-frame info
10137 before calling create_internal_breakpoint.
10138
10139 2017-04-13 Pedro Alves <palves@redhat.com>
10140
10141 * fork-child.c (execv_argv): New class.
10142 (breakup_args): Refactored as ...
10143 (execv_argv::init_for_no_shell): .. this method of execv_argv.
10144 Copy arguments to storage and replace separators with NULL
10145 terminators in place.
10146 (escape_bang_in_quoted_argument): Adjust to return bool.
10147 (execv_argv::execv_argv): New ctor.
10148 (execv_argv::init_for_shell): New method, factored out from
10149 fork_inferior. Don't strdup strings into the vector.
10150 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
10151 Remove free_vector_argv call.
10152
10153 2017-04-13 Yao Qi <yao.qi@linaro.org>
10154
10155 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
10156 tdep->rx_psw_type.
10157
10158 2017-04-13 Yao Qi <yao.qi@linaro.org>
10159
10160 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
10161 * rx-tdep.c (rx_gdbarch_init): Likewise.
10162
10163 2017-04-13 Pedro Alves <palves@redhat.com>
10164
10165 * breakpoint.h (struct breakpoint): Reindent.
10166
10167 2017-04-13 Pedro Alves <palves@redhat.com>
10168
10169 * breakpoint.c (bp_location): Rename to ...
10170 (bp_locations): ... this. All references updated.
10171 (bp_location_count): Rename to ...
10172 (bp_locations_count): ... this. All references updated.
10173 (bp_location_placed_address_before_address_max): Rename to ...
10174 (bp_locations_placed_address_before_address_max): ... this. All
10175 references updated.
10176 (bp_location_shadow_len_after_address_max): Rename to ...
10177 (bp_locations_shadow_len_after_address_max): ... this. All
10178 references updated.
10179 (bp_location_compare_addrs): Rename to ...
10180 (bp_locations_compare_addrs): ... this. All references updated.
10181 (bp_location_compare):Rename to ...
10182 (bp_locations_compare): ... this. All references updated.
10183 (bp_location_target_extensions_update): Rename to ...
10184 (bp_locations_target_extensions_update): ... this. All references
10185 updated.
10186
10187 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
10188
10189 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
10190 * common/common.m4: Check headers 'termios.h', 'termio.h' and
10191 'sgtty.h'.
10192 * common/gdb_termios.h: New file, with parts of "terminal.h".
10193 * inflow.c: Include "gdb_termios.h".
10194 * ser-unix.c: Include "gdb_termios.h".
10195 * terminal.h: Move terminal-related defines to
10196 "common/gdb_termios.h".
10197
10198 2017-04-12 Tom Tromey <tom@tromey.com>
10199
10200 * probe.c (parse_probes): Update.
10201 * location.h (delete_event_location): Don't declare.
10202 (event_location_deleter::operator()): Update.
10203 * location.c (event_location_deleter::operator()): Rename from
10204 delete_event_location.
10205 * linespec.h (linespec_result) <location>: Change type to
10206 event_location_up.
10207 * linespec.c (canonicalize_linespec, event_location_to_sals)
10208 (decode_objc): Update.
10209 (linespec_result): Don't call delete_event_location.
10210 * breakpoint.c (create_breakpoints_sal)
10211 (bkpt_probe_create_sals_from_location)
10212 (strace_marker_create_sals_from_location): Update.
10213
10214 2017-04-12 Tom Tromey <tom@tromey.com>
10215
10216 * linespec.h (struct linespec_result): Add constructor and
10217 destructor.
10218 (init_linespec_result, destroy_linespec_result)
10219 (make_cleanup_destroy_linespec_result): Don't declare.
10220 * linespec.c (init_linespec_result): Remove.
10221 (linespec_result::~linespec_result): Rename from
10222 destroy_linespec_result. Update.
10223 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
10224 Remove.
10225 * breakpoint.c (create_breakpoint, break_range_command)
10226 (decode_location_default): Update.
10227 * ax-gdb.c (agent_command_1): Update.
10228
10229 2017-04-12 Tom Tromey <tom@tromey.com>
10230
10231 * remote.c (remote_download_tracepoint): Update.
10232 * python/py-breakpoint.c (bppy_get_location): Update.
10233 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
10234 (gdbscm_breakpoint_location): Update.
10235 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
10236 * breakpoint.h (struct breakpoint) <location, location_range_end>:
10237 Change type to event_location_up.
10238 * breakpoint.c (create_overlay_event_breakpoint)
10239 (create_longjmp_master_breakpoint)
10240 (create_std_terminate_master_breakpoint)
10241 (create_exception_master_breakpoint)
10242 (breakpoint_event_location_empty_p, print_breakpoint_location)
10243 (print_one_breakpoint_location, create_thread_event_breakpoint)
10244 (init_breakpoint_sal, create_breakpoint)
10245 (print_recreate_ranged_breakpoint, break_range_command)
10246 (init_ada_exception_breakpoint, say_where): Update.
10247 (base_breakpoint_dtor): Don't call delete_event_location.
10248 (bkpt_print_recreate, tracepoint_print_recreate)
10249 (dprintf_print_recreate, update_static_tracepoint)
10250 (breakpoint_re_set_default): Update.
10251
10252 2017-04-12 Tom Tromey <tom@tromey.com>
10253
10254 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
10255 type of "to_do". Update.
10256 (compute_stack_depth): Use std::vector.
10257
10258 2017-04-12 Tom Tromey <tom@tromey.com>
10259
10260 * printcmd.c (find_instruction_backward): Use std::vector.
10261
10262 2017-04-12 Tom Tromey <tom@tromey.com>
10263
10264 * symfile.c (objfilep): Remove typedef.
10265 (reread_symbols): Use a std::vector.
10266
10267 2017-04-12 Tom Tromey <tom@tromey.com>
10268
10269 * mi/mi-main.c (exec_direction_forward): Remove.
10270 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
10271 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
10272 scoped_restore.
10273 * guile/guile.c (guile_repl_command, guile_command)
10274 (gdbscm_execute_gdb_command): Use scoped_restore.
10275 * go-exp.y (go_parse): Use scoped_restore.
10276 * d-exp.y (d_parse): Use scoped_restore.
10277 * cli/cli-decode.c (cmd_func): Use scoped_restore.
10278 * c-exp.y (c_parse): Use scoped_restore.
10279
10280 2017-04-12 Tom Tromey <tom@tromey.com>
10281
10282 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
10283 (mi_parse): Update return type.
10284 (mi_parse_free): Remove.
10285 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
10286 (mi_parse::~mi_parse): Rename from mi_parse_free.
10287 (mi_parse_cleanup): Remove.
10288 (mi_parse): Return a unique_ptr. Use new.
10289 * mi/mi-main.c (mi_execute_command): Update.
10290
10291 2017-04-12 Tom Tromey <tom@tromey.com>
10292
10293 * location.c (explicit_location_lex_one): Return a
10294 unique_xmalloc_ptr.
10295 (string_to_explicit_location): Update. Remove cleanups.
10296
10297 2017-04-12 Tom Tromey <tom@tromey.com>
10298
10299 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
10300 (compare_value_and_voffset): Change type. Update.
10301 (compute_vtable_size): Change type of "offset_vec".
10302 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
10303 (gnuv3_get_typeid): Remove extraneous declaration.
10304
10305 2017-04-12 Tom Tromey <tom@tromey.com>
10306
10307 * charset.h (wchar_iterator): Fix comment.
10308
10309 2017-04-12 Tom Tromey <tom@tromey.com>
10310
10311 * charset.c (iconv_wrapper): New class.
10312 (cleanup_iconv): Remove.
10313 (convert_between_encodings): Use it.
10314
10315 2017-04-12 Tom Tromey <tom@tromey.com>
10316
10317 * symfile.h (increment_reading_symtab): Update type.
10318 * symfile.c (decrement_reading_symtab): Remove.
10319 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
10320 * psymtab.c (psymtab_to_symtab): Update.
10321 * dwarf2read.c (dw2_instantiate_symtab): Update.
10322
10323 2017-04-12 Tom Tromey <tom@tromey.com>
10324
10325 * jit.c (struct jit_reader): Declare separately. Add constructor
10326 and destructor. Change type of "handle".
10327 (loaded_jit_reader): Define separately.
10328 (jit_reader_load): Update. New "new".
10329 (jit_reader_unload_command): Use "delete".
10330 * gdb-dlfcn.h (struct dlclose_deleter): New.
10331 (gdb_dlhandle_up): New typedef.
10332 (gdb_dlopen, gdb_dlsym): Update types.
10333 (gdb_dlclose): Remove.
10334 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
10335 (gdb_dlsym): Change type of "handle".
10336 (make_cleanup_dlclose): Remove.
10337 (dlclose_deleter::operator()): Rename from gdb_dlclose.
10338 * compile/compile-c-support.c (load_libcc): Update.
10339
10340 2017-04-12 Tom Tromey <tom@tromey.com>
10341
10342 * symtab.h (find_pcs_for_symtab_line): Change return type.
10343 * symtab.c (find_pcs_for_symtab_line): Change return type.
10344 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
10345 type of "vec". Update.
10346 (ltpy_get_pcs_for_line): Update.
10347 * linespec.c (decode_digits_ordinary): Update.
10348
10349 2017-04-12 Tom Tromey <tom@tromey.com>
10350
10351 * tracepoint.c (actions_command): Update.
10352 * python/python.c (python_command, python_interactive_command):
10353 Update.
10354 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
10355 * guile/guile.c (guile_command): Update.
10356 * defs.h (read_command_lines, read_command_lines_1): Return
10357 command_line_up.
10358 (command_lines_deleter): New struct.
10359 (command_line_up): New typedef.
10360 * compile/compile.c (compile_code_command)
10361 (compile_print_command): Update.
10362 * cli/cli-script.h (get_command_line, copy_command_lines): Return
10363 command_line_up.
10364 (make_cleanup_free_command_lines): Remove.
10365 * cli/cli-script.c (get_command_line, read_command_lines_1)
10366 (copy_command_lines): Return command_line_up.
10367 (while_command, if_command, read_command_lines, define_command)
10368 (document_command): Update.
10369 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
10370 Remove.
10371 * breakpoint.h (breakpoint_set_commands): Change type of
10372 "commands".
10373 * breakpoint.c (breakpoint_set_commands): Change type of
10374 "commands". Update.
10375 (do_map_commands_command, update_dprintf_command_list)
10376 (create_tracepoint_from_upload): Update.
10377
10378 2017-04-12 Tom Tromey <tom@tromey.com>
10379
10380 * tracepoint.c (scope_info): Update.
10381 * spu-tdep.c (spu_catch_start): Update.
10382 * python/python.c (gdbpy_decode_line): Update.
10383 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
10384 * python/py-breakpoint.c (bppy_init): Update.
10385 * probe.c (parse_probes): Update.
10386 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
10387 * location.h (event_location_deleter): New struct.
10388 (event_location_up): New typedef.
10389 (new_linespec_location, new_address_location, new_probe_location)
10390 (new_explicit_location, copy_event_location)
10391 (string_to_event_location, string_to_event_location_basic)
10392 (string_to_explicit_location): Update return type.
10393 (make_cleanup_delete_event_location): Remove.
10394 * location.c (new_linespec_location, new_address_location)
10395 (new_probe_location, new_explicit_location, copy_event_location):
10396 Return event_location_up.
10397 (delete_event_location_cleanup)
10398 (make_cleanup_delete_event_location): Remove.
10399 (string_to_explicit_location, string_to_event_location_basic)
10400 (string_to_event_location): Return event_location_up.
10401 * linespec.c (canonicalize_linespec, event_location_to_sals)
10402 (decode_line_with_current_source)
10403 (decode_line_with_last_displayed, decode_objc): Update.
10404 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
10405 * completer.c (location_completer): Update.
10406 * cli/cli-cmds.c (edit_command, list_command): Update.
10407 * breakpoint.c (create_overlay_event_breakpoint)
10408 (create_longjmp_master_breakpoint)
10409 (create_std_terminate_master_breakpoint)
10410 (create_exception_master_breakpoint)
10411 (create_thread_event_breakpoint): Update.
10412 (init_breakpoint_sal): Update. Remove some dead code.
10413 (create_breakpoint_sal): Change type of "location". Update.
10414 (create_breakpoints_sal, create_breakpoint, break_command_1)
10415 (dprintf_command, break_range_command, until_break_command)
10416 (init_ada_exception_breakpoint)
10417 (strace_marker_create_sals_from_location)
10418 (update_static_tracepoint, trace_command, ftrace_command)
10419 (strace_command, create_tracepoint_from_upload): Update.
10420 * break-catch-throw.c (re_set_exception_catchpoint): Update.
10421 * ax-gdb.c (agent_command_1): Update.
10422
10423 2017-04-12 Pedro Alves <palves@redhat.com>
10424
10425 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
10426 * configure.tgt: Handle i[34567]86-*-go32* and
10427 i[34567]86-*-msdosdjgpp*.
10428 * i386-tdep.c (i386_svr4_reg_to_regnum):
10429 Make extern.
10430 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
10431 i386-go32-tdep.c.
10432 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
10433 * i386-go32-tdep.c: New file.
10434 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
10435 declarations.
10436
10437 2017-04-12 Simon Marchi <simon.marchi@ericsson.com>
10438
10439 * aix-thread.c (pd_status2str): Change return type to const char *.
10440
10441 2017-04-12 Pedro Alves <palves@redhat.com>
10442
10443 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
10444 calls to set_gdbarch_gnu_triplet_regexp.
10445
10446 2017-04-12 Pedro Alves <palves@redhat.com>
10447
10448 PR gdb/21323
10449 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
10450 New enum value.
10451 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
10452 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
10453 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
10454 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
10455 * gdbarch.h, gdbarch.c: Regenerate.
10456 * aarch64-tdep.c (aarch64_gdbarch_init): Override
10457 gdbarch_wchar_bit and gdbarch_wchar_signed.
10458 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
10459 * arm-tdep.c (arm_gdbarch_init): Likewise.
10460 * avr-tdep.c (avr_gdbarch_init): Likewise.
10461 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
10462 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
10463 * i386-tdep.c (i386_go32_init_abi): Likewise.
10464 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
10465 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
10466 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
10467 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
10468 * sh-tdep.c (sh_gdbarch_init): Likewise.
10469 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
10470 * sparc64-tdep.c (sparc64_init_abi): Likewise.
10471 * windows-tdep.c (windows_init_abi): Likewise.
10472 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
10473
10474 2017-04-12 Pedro Alves <palves@redhat.com>
10475
10476 PR c++/21323
10477 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
10478 cplus_primitive_type_char32_t>: New enum values.
10479 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
10480 and cplus_primitive_type_char32_t.
10481 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
10482 32, use the archtecture's built-in type for char16_t and char32_t,
10483 respectively. Otherwise, fallback to init_integer_type as before,
10484 but make the type unsigned, and issue a complaint.
10485 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
10486
10487 2017-04-12 Alan Hayward <alan.hayward@arm.com>
10488
10489 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
10490 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
10491
10492 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
10493
10494 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
10495 'const char *'.
10496
10497 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
10498
10499 * common/common-utils.c (free_vector_argv): New function.
10500 * common/common-utils.h: Include <vector>.
10501 (free_vector_argv): New prototype.
10502 * darwin-nat.c (darwin_create_inferior): Rewrite function
10503 prototype in order to constify "exec_file" and accept a
10504 "std::string" for "allargs".
10505 * fork-child.c: Include <vector>.
10506 (breakup_args): Rewrite function, using C++.
10507 (fork_inferior): Rewrite function header, constify "exec_file_arg"
10508 and accept "std::string" for "allargs". Update the code to
10509 calculate "argv" based on "allargs". Update calls to "exec_fun"
10510 and "execvp".
10511 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
10512 order to constify "exec_file" and accept a "std::string" for
10513 "allargs".
10514 * go32-nat.c (go32_create_inferior): Likewise.
10515 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
10516 * infcmd.c (run_command_1): Constify "exec_file". Use
10517 "std::string" for inferior arguments.
10518 * inferior.h (fork_inferior): Update prototype.
10519 * linux-nat.c (linux_nat_create_inferior): Rewrite function
10520 prototype in order to constify "exec_file" and accept a
10521 "std::string" for "allargs".
10522 * nto-procfs.c (procfs_create_inferior): Likewise.
10523 * procfs.c (procfs_create_inferior): Likewise.
10524 * remote-sim.c (gdbsim_create_inferior): Likewise.
10525 * remote.c (extended_remote_run): Update code to accept
10526 "std::string" as argument.
10527 (extended_remote_create_inferior): Rewrite function prototype in
10528 order to constify "exec_file" and accept a "std::string" for
10529 "allargs".
10530 * rs6000-nat.c (super_create_inferior): Likewise.
10531 (rs6000_create_inferior): Likewise.
10532 * target.h (struct target_ops) <to_create_inferior>: Likewise.
10533 * windows-nat.c (windows_create_inferior): Likewise.
10534
10535 2017-04-11 Pedro Alves <palves@redhat.com>
10536
10537 * thread.c: Fix whitespace throughout.
10538
10539 2017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
10540
10541 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
10542
10543 2017-04-11 Alan Hayward <alan.hayward@arm.com>
10544
10545 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
10546
10547 2017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
10548
10549 PR gdb/21364
10550 * osdata.c (info_osdata): Check if 'type' is an empty string
10551 instead of NULL.
10552
10553 2017-04-10 Pedro Alves <palves@redhat.com>
10554
10555 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
10556 (ptid_to_global_thread_id, in_thread_list)
10557 (do_captured_list_thread_ids, set_resumed, set_running)
10558 (set_executing, set_stop_requested, finish_thread_state)
10559 (validate_registers_access, can_access_registers_ptid)
10560 (print_thread_info_1, switch_to_thread)
10561 (do_restore_current_thread_cleanup)
10562 (make_cleanup_restore_current_thread, thread_command)
10563 (thread_name_command): Use operator== instead of ptid_equal.
10564
10565 2017-04-10 Pedro Alves <palves@redhat.com>
10566
10567 * thread.c (struct current_thread_cleanup) <next>: Delete field.
10568 (current_thread_cleanup_chain): Delete.
10569 (restore_current_thread_cleanup_dtor)
10570 (make_cleanup_restore_current_thread): Remove references to
10571 current_thread_cleanup_chain.
10572
10573 2017-04-10 Alan Hayward <alan.hayward@arm.com>
10574
10575 * msp430-tdep.c (msp430_pseudo_register_read): Never return
10576 REG_UNKNOWN.
10577
10578 2017-04-10 Yao Qi <yao.qi@linaro.org>
10579
10580 PR gdb/19942
10581 * gdbthread.h (thread_info::deletable): New method.
10582 (thread_info::incref): New method.
10583 (thread_info::decref): New method.
10584 (thread_info::refcount): Move it to private.
10585 * infrun.c (save_stop_context): Call inc_refcount.
10586 (release_stop_context_cleanup): Likewise.
10587 * thread.c (set_thread_exited): New function.
10588 (init_thread_list): Delete "tp" only it is deletable, otherwise
10589 call set_thread_exited.
10590 (delete_thread_1): Call set_thread_exited.
10591 (current_thread_cleanup) <inferior_pid>: Remove.
10592 <thread>: New field.
10593 (restore_current_thread_ptid_changed): Removed.
10594 (do_restore_current_thread_cleanup): Adjust.
10595 (restore_current_thread_cleanup_dtor): Don't call
10596 find_thread_ptid.
10597 (set_thread_refcount): Use dec_refcount.
10598 (make_cleanup_restore_current_thread): Adjust.
10599 (thread_apply_all_command): Call inc_refcount.
10600 (_initialize_thread): Don't call
10601 observer_attach_thread_ptid_changed.
10602
10603 2017-04-10 Yao Qi <yao.qi@linaro.org>
10604
10605 * thread.c (delete_thread_1): Hoist code on marking thread as
10606 exited.
10607
10608 2017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10609
10610 * windows-nat.c (windows_detach): Initialize ptid with
10611 minus_one_ptid.
10612
10613 2017-04-07 Simon Marchi <simon.marchi@ericsson.com>
10614
10615 * unittests/ptid-selftests.c: Fix erroneous assert messages.
10616
10617 2017-04-07 Alan Hayward <alan.hayward@arm.com>
10618
10619 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
10620 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
10621 (bfin_pseudo_register_write): Likewise
10622
10623 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
10624
10625 * common/ptid.h (struct ptid): Change to...
10626 (class ptid_t): ... this.
10627 <ptid_t>: New constructors.
10628 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
10629 matches>: New methods.
10630 <make_null, make_minus_one>: New static methods.
10631 <pid>: Rename to...
10632 <m_pid>: ...this.
10633 <lwp>: Rename to...
10634 <m_lwp>: ...this.
10635 <tid>: Rename to...
10636 <m_tid>: ...this.
10637 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
10638 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
10639 as references, move comment to class ptid_t.
10640 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
10641 ptid_t static methods.
10642 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
10643 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
10644 Take ptid arguments as references, implement using ptid_t methods.
10645 * unittests/ptid-selftests.c: New file.
10646 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10647 unittests/ptid-selftests.c.
10648 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
10649
10650 2017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
10651
10652 * python/python.c (python_run_simple_file): Cast mode literal to
10653 non-const char pointer as expected by PyFile_FromString.
10654
10655 2017-04-05 Simon Marchi <simon.marchi@ericsson.com>
10656
10657 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
10658 minus_one_ptid and null_ptid.
10659
10660 2017-04-05 Pedro Alves <palves@redhat.com>
10661
10662 * warning.m4 (build_warnings): Remove -Wno-write-strings.
10663 * configure: Regenerate.
10664
10665 2017-04-05 Pedro Alves <palves@redhat.com>
10666
10667 * ada-exp.y (yyerror): Constify.
10668 * ada-lang.c (bound_name, get_selections)
10669 (ada_variant_discrim_type)
10670 (ada_variant_discrim_name, ada_value_struct_elt)
10671 (ada_lookup_struct_elt_type, is_unchecked_variant)
10672 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
10673 (catch_ada_exception_command_split)
10674 (catch_ada_assert_command_split, catch_assert_command)
10675 (ada_op_name): Constify.
10676 * ada-lang.h (ada_yyerror, get_selections)
10677 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
10678 * arc-tdep.c (arc_print_frame_cache): Constify.
10679 * arm-tdep.c (arm_skip_stub): Constify.
10680 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
10681 (gen_aggregate_elt_ref): Constify.
10682 * bcache.c (print_bcache_statistics): Constify.
10683 * bcache.h (print_bcache_statistics): Constify.
10684 * break-catch-throw.c (catch_exception_command_1):
10685 * breakpoint.c (struct ep_type_description::description):
10686 Constify.
10687 (add_solib_catchpoint): Constify.
10688 (catch_fork_command_1): Add cast.
10689 (add_catch_command): Constify.
10690 * breakpoint.h (add_catch_command, add_solib_catchpoint):
10691 Constify.
10692 * bsd-uthread.c (bsd_uthread_state): Constify.
10693 * buildsym.c (patch_subfile_names): Constify.
10694 * buildsym.h (next_symbol_text_func, patch_subfile_names):
10695 Constify.
10696 * c-exp.y (yyerror): Constify.
10697 (token::oper): Constify.
10698 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
10699 * c-varobj.c (cplus_describe_child): Constify.
10700 * charset.c (find_charset_names): Add cast.
10701 (find_charset_names): Constify array and add const_cast.
10702 * cli/cli-cmds.c (complete_command, cd_command): Constify.
10703 (edit_command): Constify.
10704 * cli/cli-decode.c (lookup_cmd): Constify.
10705 * cli/cli-dump.c (dump_memory_command, dump_value_command):
10706 Constify.
10707 (struct dump_context): Constify.
10708 (add_dump_command, restore_command): Constify.
10709 * cli/cli-script.c (get_command_line): Constify.
10710 * cli/cli-script.h (get_command_line): Constify.
10711 * cli/cli-utils.c (check_for_argument): Constify.
10712 * cli/cli-utils.h (check_for_argument): Constify.
10713 * coff-pe-read.c (struct read_pe_section_data): Constify.
10714 * command.h (lookup_cmd): Constify.
10715 * common/print-utils.c (decimal2str): Constify.
10716 * completer.c (gdb_print_filename): Constify.
10717 * corefile.c (set_gnutarget): Constify.
10718 * cp-name-parser.y (yyerror): Constify.
10719 * cp-valprint.c (cp_print_class_member): Constify.
10720 * cris-tdep.c (cris_register_name, crisv32_register_name):
10721 Constify.
10722 * d-exp.y (yyerror): Constify.
10723 (struct token::oper): Constify.
10724 * d-lang.h (d_yyerror): Constify.
10725 * dbxread.c (struct header_file_location::name): Constify.
10726 (add_old_header_file, add_new_header_file, last_function_name)
10727 (dbx_next_symbol_text, add_bincl_to_list)
10728 (find_corresponding_bincl_psymtab, set_namestring)
10729 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
10730 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
10731 * defs.h (command_line_input, print_address_symbolic)
10732 (deprecated_readline_begin_hook): Constify.
10733 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
10734 Constify.
10735 * event-top.c (handle_line_of_input): Constify and add cast.
10736 * exceptions.c (catch_errors): Constify.
10737 * exceptions.h (catch_errors): Constify.
10738 * expprint.c (print_subexp_standard, op_string, op_name)
10739 (op_name_standard, dump_raw_expression, dump_raw_expression):
10740 * expression.h (op_name, op_string, dump_raw_expression):
10741 Constify.
10742 * f-exp.y (yyerror): Constify.
10743 (struct token::oper): Constify.
10744 (struct f77_boolean_val::name): Constify.
10745 * f-lang.c (f_word_break_characters): Constify.
10746 * f-lang.h (f_yyerror): Constify.
10747 * fork-child.c (fork_inferior): Add cast.
10748 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
10749 (new_variant): Constify.
10750 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
10751 * gdbarch.c: Regenerate.
10752 * gdbcore.h (set_gnutarget): Constify.
10753 * go-exp.y (yyerror): Constify.
10754 (token::oper): Constify.
10755 * go-lang.h (go_yyerror): Constify.
10756 * go32-nat.c (go32_sysinfo): Constify.
10757 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
10758 * guile/scm-cmd.c (cmdscm_function): Constify.
10759 * guile/scm-param.c (pascm_param_value): Constify.
10760 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
10761 (h8300sx_register_name): Constify.
10762 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
10763 Constify.
10764 * ia64-tdep.c (ia64_register_names): Constify.
10765 * infcmd.c (construct_inferior_arguments): Constify.
10766 (path_command, attach_post_wait): Constify.
10767 * language.c (show_range_command, show_case_command)
10768 (unk_lang_error): Constify.
10769 * language.h (language_defn::la_error)
10770 (language_defn::la_name_of_this): Constify.
10771 * linespec.c (decode_line_2): Constify.
10772 * linux-thread-db.c (thread_db_err_str): Constify.
10773 * lm32-tdep.c (lm32_register_name): Constify.
10774 * m2-exp.y (yyerror): Constify.
10775 * m2-lang.h (m2_yyerror): Constify.
10776 * m32r-tdep.c (m32r_register_names): Constify and make static.
10777 * m68hc11-tdep.c (m68hc11_register_names): Constify.
10778 * m88k-tdep.c (m88k_register_name): Constify.
10779 * macroexp.c (appendmem): Constify.
10780 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
10781 (upgrade_type, parse_external, parse_partial_symbols)
10782 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
10783 (new_symbol): Constify.
10784 * memattr.c (mem_info_command): Constify.
10785 * mep-tdep.c (register_name_from_keyword): Constify.
10786 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
10787 Constify.
10788 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
10789 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
10790 * mi/mi-main.c (captured_mi_execute_command): Constify and add
10791 cast.
10792 (mi_execute_async_cli_command): Constify.
10793 * mips-tdep.c (mips_register_name): Constify.
10794 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
10795 (am33_register_name, am33_2_register_name)
10796 * moxie-tdep.c (moxie_register_names): Constify.
10797 * nat/linux-osdata.c (osdata_type): Constify fields.
10798 * nto-tdep.c (nto_parse_redirection): Constify.
10799 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
10800 (lookup_child_selector): Constify.
10801 (objc_methcall::name): Constify.
10802 * objc-lang.h (lookup_objc_class, lookup_child_selector)
10803 (lookup_struct_typedef): Constify.
10804 * objfiles.c (pc_in_section): Constify.
10805 * objfiles.h (pc_in_section): Constify.
10806 * p-exp.y (struct token::oper): Constify.
10807 (yyerror): Constify.
10808 * p-lang.h (pascal_yyerror): Constify.
10809 * parser-defs.h (op_name_standard): Constify.
10810 (op_print::string): Constify.
10811 (exp_descriptor::op_name): Constify.
10812 * printcmd.c (print_address_symbolic): Constify.
10813 * psymtab.c (print_partial_symbols): Constify.
10814 * python/py-breakpoint.c (stop_func): Constify.
10815 (bppy_get_expression): Constify.
10816 * python/py-cmd.c (cmdpy_completer::name): Constify.
10817 (cmdpy_function): Constify.
10818 * python/py-event.c (evpy_add_attribute)
10819 (gdbpy_initialize_event_generic): Constify.
10820 * python/py-event.h (evpy_add_attribute)
10821 (gdbpy_initialize_event_generic): Constify.
10822 * python/py-evts.c (add_new_registry): Constify.
10823 * python/py-finishbreakpoint.c (outofscope_func): Constify.
10824 * python/py-framefilter.c (get_py_iter_from_func): Constify.
10825 * python/py-inferior.c (get_buffer): Add cast.
10826 * python/py-param.c (parm_constant::name): Constify.
10827 * python/py-unwind.c (fprint_frame_id): Constify.
10828 * python/python.c (gdbpy_parameter_value): Constify.
10829 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
10830 * remote.c (memory_packet_config::name): Constify.
10831 (show_packet_config_cmd, remote_write_bytes)
10832 (remote_buffer_add_string):
10833 * reverse.c (exec_reverse_once): Constify.
10834 * rs6000-tdep.c (variant::name, variant::description): Constify.
10835 * rust-exp.y (rustyyerror): Constify.
10836 * rust-lang.c (rust_op_name): Constify.
10837 * rust-lang.h (rustyyerror): Constify.
10838 * serial.h (serial_ops::name): Constify.
10839 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
10840 (sh_sh3e_register_name, sh_sh2e_register_name)
10841 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
10842 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
10843 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
10844 (sh_sh4al_dsp_register_name): Constify.
10845 * sh64-tdep.c (sh64_register_name): Constify.
10846 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
10847 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
10848 * stabsread.c (patch_block_stabs, read_type_number)
10849 (ref_map::stabs, ref_add, process_reference)
10850 (symbol_reference_defined, define_symbol, define_symbol)
10851 (error_type, read_type, read_member_functions, read_cpp_abbrev)
10852 (read_one_struct_field, read_struct_fields, read_baseclasses)
10853 (read_tilde_fields, read_struct_type, read_array_type)
10854 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
10855 (read_huge_number, read_range_type, read_args, common_block_start)
10856 (find_name_end): Constify.
10857 * stabsread.h (common_block_start, define_symbol)
10858 (process_one_symbol, symbol_reference_defined, ref_add):
10859 * symfile.c (get_section_index, add_symbol_file_command):
10860 * symfile.h (get_section_index): Constify.
10861 * target-descriptions.c (tdesc_type::name): Constify.
10862 (tdesc_free_type): Add cast.
10863 * target.c (find_default_run_target):
10864 (add_deprecated_target_alias, find_default_run_target)
10865 (target_announce_detach): Constify.
10866 (do_option): Constify.
10867 * target.h (add_deprecated_target_alias): Constify.
10868 * thread.c (print_thread_info_1): Constify.
10869 * top.c (deprecated_readline_begin_hook, command_line_input):
10870 Constify.
10871 (init_main): Add casts.
10872 * top.h (handle_line_of_input): Constify.
10873 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
10874 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
10875 (tfind_command): Rename to ...
10876 (tfind_command_1): ... this and constify.
10877 (tfind_command): New function.
10878 (tfind_end_command, tfind_start_command): Adjust.
10879 (encode_source_string): Constify.
10880 * tracepoint.h (encode_source_string): Constify.
10881 * tui/tui-data.c (tui_partial_win_by_name): Constify.
10882 * tui/tui-data.h (tui_partial_win_by_name): Constify.
10883 * tui/tui-source.c (tui_set_source_content_nil): Constify.
10884 * tui/tui-source.h (tui_set_source_content_nil): Constify.
10885 * tui/tui-win.c (parse_scrolling_args): Constify.
10886 * tui/tui-windata.c (tui_erase_data_content): Constify.
10887 * tui/tui-windata.h (tui_erase_data_content): Constify.
10888 * tui/tui-winsource.c (tui_erase_source_content): Constify.
10889 * tui/tui.c (tui_enable): Add cast.
10890 * utils.c (defaulted_query): Constify.
10891 (init_page_info): Add cast.
10892 (puts_debug, subset_compare): Constify.
10893 * utils.h (subset_compare): Constify.
10894 * varobj.c (varobj_format_string): Constify.
10895 * varobj.h (varobj_format_string): Constify.
10896 * vax-tdep.c (vax_register_name): Constify.
10897 * windows-nat.c (windows_detach): Constify.
10898 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
10899 * xml-support.c (gdb_xml_end_element): Constify.
10900 * xml-tdesc.c (tdesc_start_reg): Constify.
10901 * xstormy16-tdep.c (xstormy16_register_name): Constify.
10902 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
10903 * xtensa-tdep.h (xtensa_register_t::name): Constify.
10904
10905 2017-04-05 Pedro Alves <palves@redhat.com>
10906
10907 * proc-api.c (struct trans): Constify.
10908 (procfs_note): Constify.
10909 * proc-events.c (struct trans, syscall_table):
10910 * proc-flags.c (struct trans): Constify.
10911 * proc-utils.h (procfs_note): Constify.
10912 * proc-why.c (struct trans): Constify.
10913 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
10914 (procfs_detach): Constify.
10915 * sol-thread.c (struct string_map): Constify.
10916 (td_err_string, td_state_string): Constify.
10917
10918 2017-04-05 Pedro Alves <palves@redhat.com>
10919
10920 * proc-api.c (procfs_filename): Don't initialize
10921 procfs_filename.
10922 (prepare_to_trace): Assume procfs_filename is non-NULL.
10923 (_initialize_proc_api): Give procfs_filename a default value here.
10924
10925 2017-04-05 Pedro Alves <palves@redhat.com>
10926
10927 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
10928 'cond_string' parameter.
10929 (extract_exception_regexp): Constify 'string' parameter.
10930 (catch_exception_command_1): Constify.
10931 * breakpoint.c (init_catchpoint)
10932 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
10933 parameter.
10934 (ep_parse_optional_if_clause, catch_fork_command_1)
10935 (catch_exec_command_1): Constify.
10936 * breakpoint.h (init_catchpoint): Constify 'cond_string'
10937 parameter.
10938 (ep_parse_optional_if_clause): Constify.
10939 * cli/cli-utils.c (remove_trailing_whitespace)
10940 (check_for_argument): Constify.
10941 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
10942 non-const overload.
10943 (check_for_argument): Likewise.
10944
10945 2017-04-05 Pedro Alves <palves@redhat.com>
10946
10947 * event-top.c (command_line_handler): Add cast to execute_command
10948 call.
10949 * record-btrace.c (cmd_record_btrace_bts_start)
10950 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
10951 (cmd_record_btrace_start): Add cast to execute_command call.
10952 * record-full.c (record_full_goto_insn):
10953 * record.c (record_start, record_stop): Add cast to
10954 execute_command_to_string calls.
10955 (cmd_record_start): Add cast to execute_command calls.
10956
10957 2017-04-05 Pedro Alves <palves@redhat.com>
10958
10959 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
10960 static inline function.
10961 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
10962 array and use gdb_PyArg_ParseTupleAndKeywords.
10963 * python/py-cmd.c (cmdpy_init): Likewise.
10964 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
10965 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
10966 (infpy_search_memory): Likewise.
10967 * python/py-objfile.c (objfpy_add_separate_debug_file)
10968 (gdbpy_lookup_objfile): Likewise.
10969 * python/py-symbol.c (gdbpy_lookup_symbol)
10970 (gdbpy_lookup_global_symbol): Likewise.
10971 * python/py-type.c (gdbpy_lookup_type): Likewise.
10972 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
10973 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
10974 Likewise.
10975
10976 2017-04-05 Pedro Alves <palves@redhat.com>
10977
10978 * python/python-internal.h (gdb_PyGetSetDef): New type.
10979 * python/py-block.c (block_object_getset)
10980 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
10981 * python/py-event.c (event_object_getset)
10982 (finish_breakpoint_object_getset): Likewise.
10983 * python/py-inferior.c (inferior_object_getset): Likewise.
10984 * python/py-infthread.c (thread_object_getset): Likewise.
10985 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
10986 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
10987 * python/py-objfile.c (objfile_getset): Likewise.
10988 * python/py-progspace.c (pspace_getset): Likewise.
10989 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
10990 Likewise.
10991 * python/py-record.c (recpy_record_getset): Likewise.
10992 * python/py-symbol.c (symbol_object_getset): Likewise.
10993 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
10994 Likewise.
10995 * python/py-type.c (type_object_getset, field_object_getset):
10996 Likewise.
10997 * python/py-value.c (value_object_getset): Likewise.
10998
10999 2017-04-05 Pedro Alves <palves@redhat.com>
11000
11001 * python/python-internal.h (gdb_PyObject_CallMethod)
11002 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
11003 New functions.
11004 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
11005 (PySys_GetObject, PySys_SetPath): New macros.
11006
11007 2017-04-05 Pedro Alves <palves@redhat.com>
11008
11009 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
11010 info_osdata_command.
11011 * osdata.c (info_osdata_command): Rename to ...
11012 (info_osdata): ... this. Constify 'type' parameter, and remove
11013 the 'from_tty' parameter. Accept NULL TYPE.
11014 (info_osdata_command): New function.
11015 * osdata.h (info_osdata_command): Remove declaration.
11016 (info_osdata): New declaration.
11017
11018 2017-04-05 Pedro Alves <palves@redhat.com>
11019
11020 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
11021 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
11022 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
11023 parameter.
11024 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
11025 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
11026 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
11027 parameter.
11028 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
11029 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
11030 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
11031 (mi_cmd_file_list_exec_source_files)
11032 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
11033 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
11034 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
11035 parameter.
11036 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
11037 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
11038 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
11039 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
11040 (mi_cmd_stack_info_frame): Constify 'command' parameter.
11041 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
11042 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
11043 'command' parameter.
11044 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
11045 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
11046 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
11047 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
11048 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
11049 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
11050 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
11051 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
11052 (mi_cmd_var_set_update_range): Constify 'command' parameter.
11053 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
11054 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
11055 parameter.
11056 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
11057 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
11058 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
11059 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
11060 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
11061 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
11062 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
11063 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
11064 (mi_cmd_data_list_changed_registers)
11065 (mi_cmd_data_write_register_values)
11066 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
11067 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
11068 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
11069 (mi_cmd_list_features, mi_cmd_list_target_features)
11070 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
11071 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
11072 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
11073 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
11074 (mi_cmd_trace_frame_collected): Constify 'command'
11075 parameter.
11076 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
11077 'command' parameter.
11078
11079 2017-04-05 Pedro Alves <palves@redhat.com>
11080
11081 * ada-lang.c (ada_completer_word_break_characters): Now a const
11082 array.
11083 (ada_get_gdb_completer_word_break_characters): Constify.
11084 * completer.c (gdb_completer_command_word_break_characters)
11085 (gdb_completer_file_name_break_characters)
11086 (gdb_completer_quote_characters): Now const arrays.
11087 (get_gdb_completer_quote_characters): Constify.
11088 (set_rl_completer_word_break_characters): New function.
11089 (set_gdb_completion_word_break_characters)
11090 (complete_line_internal): Use it.
11091 * completer.h (get_gdb_completer_quote_characters): Constify.
11092 (set_rl_completer_word_break_characters): Declare.
11093 * f-lang.c (f_word_break_characters): Constify.
11094 * language.c (default_word_break_characters): Constify.
11095 * language.h (language_defn::la_word_break_characters): Constify.
11096 (default_word_break_characters): Constify.
11097 * top.c (init_main): Use set_rl_completer_word_break_characters.
11098
11099 2017-04-05 Pedro Alves <palves@redhat.com>
11100
11101 * aix-thread.c (aix_thread_pid_to_str)
11102 (aix_thread_extra_thread_info): Constify.
11103 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
11104 * bsd-uthread.c (bsd_uthread_extra_thread_info)
11105 (bsd_uthread_pid_to_str): Constify.
11106 * corelow.c (core_pid_to_str): Constify.
11107 * darwin-nat.c (darwin_pid_to_str): Constify.
11108 * fbsd-nat.c (fbsd_pid_to_str): Constify.
11109 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
11110 Constify.
11111 * gnu-nat.c (gnu_pid_to_str): Constify.
11112 * go32-nat.c (go32_pid_to_str): Constify.
11113 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
11114 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
11115 * inferior.c (inferior_pid_to_str): Constify.
11116 * linux-nat.c (linux_nat_pid_to_str): Constify.
11117 * linux-tdep.c (linux_core_pid_to_str): Constify.
11118 * linux-thread-db.c (thread_db_pid_to_str)
11119 (thread_db_extra_thread_info): Constify.
11120 * nto-tdep.c (nto_extra_thread_info): Constify.
11121 * nto-tdep.h (nto_extra_thread_info): Constify.
11122 * obsd-nat.c (obsd_pid_to_str): Constify.
11123 * procfs.c (procfs_pid_to_str): Constify.
11124 * ravenscar-thread.c (ravenscar_extra_thread_info)
11125 (ravenscar_pid_to_str): Constify.
11126 * remote-sim.c (gdbsim_pid_to_str): Constify.
11127 * remote.c (remote_threads_extra_info, remote_pid_to_str):
11128 Constify.
11129 * sol-thread.c (solaris_pid_to_str): Constify.
11130 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
11131 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
11132 * target.c (default_pid_to_str, target_pid_to_str)
11133 (normal_pid_to_str, default_pid_to_str): Constify.
11134 * target.h (target_ops::to_pid_to_str)
11135 (target_ops::to_extra_thread_info): Constify.
11136 (target_pid_to_str, normal_pid_to_str): Constify.
11137 * windows-nat.c (windows_pid_to_str): Constify.
11138 * gdbarch.sh (core_pid_to_str): Constify.
11139 * target-delegates.c: Regenerate.
11140 * gdbarch.h, gdbarch.c: Regenerate.
11141
11142 2017-04-05 Pedro Alves <palves@redhat.com>
11143
11144 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
11145 the memory of the temporary warning_pre_print override.
11146 * utils.c (warning_pre_print): Constify.
11147 * utils.h (warning_pre_print): Constify.
11148
11149 2017-04-05 Pedro Alves <palves@redhat.com>
11150
11151 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
11152 (shell_command): New function.
11153 (make_command): Use std::string.
11154 (init_cli_cmds): Register shell_command instead of shell_escape.
11155
11156 2017-04-05 Pedro Alves <palves@redhat.com>
11157
11158 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
11159 * tracepoint.c (default_collect): Don't initialize.
11160
11161 2017-04-05 Pedro Alves <palves@redhat.com>
11162
11163 * macroexp.c (macro_buffer::shared): Now a bool.
11164 (init_buffer): Update.
11165 (init_shared_buffer): Constify 'addr' parameter.
11166 (substitute_args, expand, macro_expand, macro_expand_next): Remove
11167 casts.
11168
11169 2017-04-05 Pedro Alves <palves@redhat.com>
11170
11171 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
11172 * disasm.c (set_disassembler_options): Constify local.
11173 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
11174
11175 2017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
11176
11177 PR gdb/21352
11178 * tracefile.c (tsave_command): Fix argument parsing for '-r'
11179 option.
11180
11181 2017-04-05 Yao Qi <yao.qi@linaro.org>
11182
11183 * frame.c (frame_unwind_register_unsigned): Call
11184 frame_unwind_register_value.
11185
11186 2017-04-05 Yao Qi <yao.qi@linaro.org>
11187
11188 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
11189 Use gdb_test_multiple, and don't match anchor.
11190
11191 2017-04-05 Pedro Alves <palves@redhat.com>
11192
11193 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
11194 (Write After Approval): Remove Simon Marchi.
11195
11196 2017-04-05 Pedro Alves <palves@redhat.com>
11197
11198 * common/gdb_optional.h (optional::optional): Make constexpr and
11199 initialize m_dummy.
11200
11201 2017-04-04 John Baldwin <jhb@FreeBSD.org>
11202
11203 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
11204 (amd64fbsd_jmp_buf_reg_offset): Remove.
11205 (amd64fbsd_supply_uthread): Remove function.
11206 (amd64fbsd_collect_uthread): Remove function.
11207 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
11208 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
11209 (x86_64-*-freebsd*): Remove bsd-uthread.o.
11210 (fbsd-nat.c): Update comment.
11211 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
11212 (i386fbsd_jmp_buf_reg_offset): Remove.
11213 (i386fbsd_supply_uthread): Remove function.
11214 (i386fbsd_collect_uthread): Remove function.
11215 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
11216
11217 2017-04-04 John Baldwin <jhb@FreeBSD.org>
11218
11219 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
11220 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
11221 * NEWS: Mention that support for FreeBSD/alpha was removed.
11222 * alpha-fbsd-tdep.c: Delete file.
11223 * config/alpha/fbsd.mh: Delete file.
11224 * configure.host: Delete alpha*-*-freebsd* and
11225 alpha*-*-kfreebsd*-gnu.
11226 * configure.tgt: Delete alpha*-*-freebsd* and
11227 alpha*-*-kfreebsd*-gnu.
11228
11229 2017-04-04 John Baldwin <jhb@FreeBSD.org>
11230
11231 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
11232 amd64bsd_store_inferior_registers): Use ptid from regcache.
11233
11234 2017-04-04 Pedro Alves <palves@redhat.com>
11235
11236 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
11237 data fields, make them private and add "m_" prefixes.
11238 (lnp_state_machine::lnp_state_machine): New ctor.
11239 (record_line, check_line_address, handle_set_discriminator)
11240 (handle_set_address, handle_advance_pc, handle_special_opcode)
11241 (handle_advance_line, handle_set_file, handle_negate_stmt)
11242 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
11243 (end_sequence, advance_line): New methods.
11244 (m_gdbarch, m_record_lines_p): New fields.
11245 (lnp_reader_state): Delete.
11246 (dwarf_record_line): Rename to ...
11247 (lnp_state_machine::record_line): ... adjust.
11248 (init_lnp_state_machine): Delete.
11249 (lnp_state_machine::lnp_state_machine): New.
11250 (check_line_address): Rename to ...
11251 (lnp_state_machine::check_line_address): This.
11252 (dwarf_decode_lines_1): Remove reference to "reader_state".
11253 Adjust lnp_state_machine having a non-default ctor. Use bool.
11254 State machine internal state manipulation moved to
11255 lnp_state_machine methods.
11256
11257 2017-04-04 Pedro Alves <palves@redhat.com>
11258
11259 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11260 unittests/offset-type-selftests.c.
11261 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
11262 * common/offset-type.h: New file.
11263 * common/preprocessor.h: New file.
11264 * common/traits.h: New file.
11265 * common/valid-expr.h: New file.
11266 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
11267 sect_offset and cu_offset strong typedefs throughout.
11268 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
11269 typedefs throughout.
11270 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
11271 sect_offset and cu_offset strong typedefs throughout.
11272 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
11273 typedefs throughout.
11274 * gdbtypes.h: Include "common/offset-type.h".
11275 (cu_offset): Now an offset type (strong typedef) instead of a
11276 struct.
11277 (sect_offset): Likewise.
11278 (union call_site_parameter_u): Rename "param_offset" field to
11279 "param_cu_off".
11280 * unittests/offset-type-selftests.c: New file.
11281
11282 2017-04-04 Pedro Alves <palves@redhat.com>
11283
11284 * common/underlying.h: New file.
11285 * dwarf2read.c: Include "common/gdb_optional.h" and
11286 "common/underlying.h".
11287 (dir_index, file_name_index): New types.
11288 (file_entry): Use them.
11289 (file_entry::include): Use to_underlying.
11290 (line_header::add_file_name): Use dir_index.
11291 (read_formatted_entries): Use gdb::optional. Read form before
11292 writting to file_entry.
11293 (dwarf_decode_line_header): Use dir_index.
11294 (lnp_state_machine::current_file): Use to_underlying.
11295 (lnp_state_machine::file): Change type to file_name_index.
11296 (dwarf_record_line): Use to_underlying.
11297 (init_lnp_state_machine): Use file_name_index.
11298 (dwarf_decode_lines_1): Use dir_index and file_name_index.
11299
11300 2017-04-04 Pedro Alves <palves@redhat.com>
11301
11302 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
11303 operator bool, has_value and get methods.
11304
11305 2017-04-04 Pedro Alves <palves@redhat.com>
11306
11307 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
11308 fields.
11309 (line_header): Initialize all data fields. Change type of
11310 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
11311 Change type of include_dirs to std::vector<const char *>. Remove
11312 num_include_dirs, include_dirs_size. Change type of file_names to
11313 std::vector<file_entry>. Remove num_file_names, file_names_size.
11314 (line_header::line_header): New.
11315 (line_header::add_include_dir, line_header::add_file_name): New
11316 methods.
11317 (line_header::include_dir_at): Remove NULL check.
11318 (line_header::file_name_at): Add const overload.
11319 (line_header_up): New unique_ptr typedef.
11320 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
11321 std::vector. Remove free_line_header call.
11322 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
11323 free_line_header call.
11324 (free_cu_line_header): Delete.
11325 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
11326 (setup_type_unit_groups): Use line_header_up instead of cleanups.
11327 Adjust to use std::vector.
11328 (free_line_header): Delete.
11329 (free_line_header_voidp): Use delete.
11330 (add_include_dir): Replace with ...
11331 (line_header::add_include_dir): ... this method. Use std::vector.
11332 (add_file_name): Replace with ...
11333 (line_header::add_file_name): ... this method. Use std::vector.
11334 (add_include_dir_stub): Delete.
11335 (read_formatted_entries): Remove memset.
11336 (dwarf_decode_line_header): Return a line_header_up instead of a
11337 raw pointer. Remove cleanup handling. Pass lambdas to
11338 read_formatted_entries. Adjust to use line_header methods.
11339 (dwarf_decode_lines_1): Adjust to use line_header methods.
11340 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
11341 use std::vector.
11342
11343 2017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
11344
11345 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
11346 instead of struct ptid.
11347
11348 2017-05-04 Alan Hayward <alan.hayward@arm.com>
11349
11350 * frame.c (get_frame_register_bytes): Unwind using value.
11351 (put_frame_register_bytes): Likewise.
11352
11353 2017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
11354
11355 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
11356 aggregate-like.
11357
11358 2017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
11359
11360 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
11361
11362 2017-03-29 Yao Qi <yao.qi@linaro.org>
11363
11364 * gdbthread.h (struct thread_info): Declare constructor and
11365 destructor. Add some in-class member initializers.
11366 * thread.c (free_thread): Remove.
11367 (init_thread_list): Call delete instead of free_thread.
11368 (new_thread): Call thread_info constructor.
11369 (thread_info::thread_info): New function.
11370 (thread_info::~thread_info): New function.
11371 (delete_thread_1): Call delete instead of free_thread.
11372 (make_cleanup_restore_current_thread): Move tp and frame to
11373 inner block.
11374
11375 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
11376
11377 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
11378 (arc_skip_prologue): Likewise.
11379 (arc_make_frame_cache): Likewise.
11380 (arc_pv_get_operand): New function.
11381 (arc_is_in_prologue): Likewise.
11382 (arc_analyze_prologue): Likewise.
11383 (arc_print_frame_cache): Likewise.
11384 (MAX_PROLOGUE_LENGTH): New constant.
11385
11386 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
11387
11388 * configure.tgt: Add arc-insn.o.
11389 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
11390 (dump_arc_instruction_command): New function.
11391 (arc_fprintf_disasm): Likewise.
11392 (arc_disassemble_info): Likewise.
11393 (arc_insn_get_operand_value): Likewise.
11394 (arc_insn_get_operand_value_signed): Likewise.
11395 (arc_insn_get_memory_base_reg): Likewise.
11396 (arc_insn_get_memory_offset): Likewise.
11397 (arc_insn_get_branch_target): Likewise.
11398 (arc_insn_dump): Likewise.
11399 (arc_insn_get_linear_next_pc): Likewise.
11400 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
11401 (arc_disassemble_info): Likewise.
11402 (arc_insn_get_branch_target): Likewise.
11403 (arc_insn_get_linear_next_pc): Likewise.
11404 * NEWS: Mention new "maint print arc arc-instruction".
11405
11406 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
11407
11408 * arc-tdep (maintenance_print_arc_list): New variable.
11409 (maintenance_print_arc_command): New function.
11410
11411 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
11412
11413 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
11414 Add "limm" and "reserved".
11415 (arc_cannot_fetch_register, arc_cannot_store_register): Add
11416 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
11417 * arc-tdep.h (arc_regnum): Likewise.
11418
11419 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
11420
11421 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
11422 for THREADPTR register.
11423 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
11424 register.
11425 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
11426 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
11427 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
11428
11429 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
11430
11431 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
11432 registers above gdbarch_num_regs (gdbarch) as privileged in
11433 call0 ABI.
11434
11435 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
11436
11437 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
11438 for a single specified register or for all registers in
11439 a0_base..a0_base + C0_NREGS range.
11440 (supply_gregset_reg): Call regcache_raw_supply for a single
11441 specified register or for all registers in a0_base..a0_base +
11442 C0_NREGS range.
11443
11444 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
11445
11446 * arch/xtensa.h (C0_NREGS): Add definition.
11447 * xtensa-tdep.c (C0_NREGS): Remove definition.
11448
11449 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
11450
11451 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
11452 Drop xtensa_default_isa initialization.
11453 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
11454
11455 2017-03-27 Pedro Alves <palves@redhat.com>
11456
11457 * dwarf2read.c (file_entry) <dir_index>: Add comment.
11458 (file_entry::include_dir): New method.
11459 (line_header::include_dir_at, line_header::file_name_at): New
11460 methods.
11461 (setup_type_unit_groups, setup_type_unit_groups)
11462 (psymtab_include_file_name): Simplify using the new methods.
11463 (lnp_state_machine) <the_line_header>: New field.
11464 <file>: Add comment.
11465 (lnp_state_machine::current_file): New method.
11466 (dwarf_record_line): Simplify using the new methods.
11467 (init_lnp_state_machine): Initialize the "the_line_header" field.
11468 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
11469 Simplify using the new methods.
11470
11471 2017-03-27 Pedro Alves <palves@redhat.com>
11472
11473 * cp-name-parser.y (make_empty): Delete.
11474 (demangler_special, nested_name, ptr_operator, array_indicator)
11475 (direct_declarator, declarator_1): Use fill_comp instead of
11476 make_empty.
11477
11478 2017-03-27 Pedro Alves <palves@redhat.com>
11479
11480 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
11481 to ATTRIBUTE_PRINTF.
11482 * solib-target.c (library_list_start_list): Print "string" not
11483 "version".
11484 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
11485 gdb_xml_error call.
11486
11487 2017-03-27 Pedro Alves <palves@redhat.com>
11488
11489 * dwarf2read.c (struct file_and_directory): New.
11490 (dwarf2_get_dwz_file): Adjust to use std::string.
11491 (dw2_get_file_names_reader): Adjust to use file_and_directory.
11492 (find_file_and_directory): Adjust to return a file_and_directory
11493 object.
11494 (read_file_scope): Adjust to use file_and_directory. Remove
11495 make_cleanup/do_cleanups calls.
11496 (open_and_init_dwp_file): Adjust to use std::string. Remove
11497 make_cleanup/do_cleanups calls.
11498 * python/python.c (do_start_initialization): Adjust to ldirname
11499 returning a std::string.
11500 * utils.c (ldirname): Now returns a std::string.
11501 * utils.h (ldirname): Change return type to std::string.
11502 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
11503 returning a std::string.
11504 * xml-tdesc.c (file_read_description_xml): Likewise.
11505
11506 2017-03-24 Alan Hayward <alan.hayward@arm.com>
11507
11508 * regcache.c (regcache_debug_print_register): New function.
11509 * regcache.h (regcache_debug_print_register): New declaration.
11510 * target.c (debug_print_register): Remove.
11511 (target_fetch_registers): Call regcache_debug_print_register.
11512 (target_store_registers): Likewise.
11513
11514 2017-03-24 Pádraig Brady <pbrady@fb.com>
11515
11516 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
11517 reference beyond the 'lh->include_dirs' array before accessing to
11518 it.
11519 (psymtab_include_file_name): Likewise.
11520 (dwarf_decode_lines_1): Likewise.
11521 (dwarf_decode_lines): Likewise.
11522 (file_file_name): Likewise.
11523
11524 2017-03-23 Simon Marchi <simon.marchi@ericsson.com>
11525
11526 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
11527 inferior_ptid.
11528 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
11529 ps_lsetfpregs): Likewise.
11530 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
11531 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
11532 ps_lsetfpregs): Likewise.
11533 * target.c (target_fetch_registers, target_store_registers):
11534 Remove asserts.
11535
11536 2017-03-23 Alan Hayward <alan.hayward@arm.com>
11537
11538 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
11539
11540 2017-03-23 Yao Qi <yao.qi@linaro.org>
11541
11542 * aarch64-tdep.c (aarch64_process_record_test): Declare.
11543 (_initialize_aarch64_tdep): Register it.
11544 (aarch64_record_load_store): Handle PRFM instruction.
11545 (aarch64_process_record_test): New function.
11546
11547 2017-03-23 Yao Qi <yao.qi@linaro.org>
11548
11549 * aarch64-tdep.c (aarch64_record_load_store): Fix code
11550 indentation.
11551
11552 2017-03-23 Yao Qi <yao.qi@linaro.org>
11553
11554 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
11555
11556 2017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
11557
11558 python/python.c (do_start_initialization): Fix memory leak.
11559
11560 2017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
11561
11562 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
11563 using get_ptrace_pid.
11564 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
11565 inferior_ptid.
11566 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
11567 inferior_ptid instead of pid.
11568
11569 2017-03-22 Yao Qi <yao.qi@linaro.org>
11570
11571 * aarch64-tdep.c: Wrap locally used classes in anonymous
11572 namespace.
11573 * arm-tdep.c: Likewise.
11574 * linespec.c: Likewise.
11575 * ui-out.c: Likewise.
11576
11577 2017-03-22 Jonah Graham <jonah@kichwacoders.com>
11578
11579 PR gdb/19637
11580 * python/lib/gdb/printer/bound_registers.py: Import sys.
11581
11582 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
11583
11584 * windows-nat.c (do_windows_fetch_inferior_registers): Add
11585 windows_thread_info parameter and use it instead of
11586 current_thread.
11587 (windows_fetch_inferior_registers): Don't set current_thread,
11588 pass the thread to do_windows_fetch_inferior_registers. Use
11589 ptid from regcache instead of inferior_ptid.
11590 (do_windows_store_inferior_registers): Add windows_thread_info
11591 parameter and use it instead of current_thread.
11592 (windows_store_inferior_registers): Don't set current_thread,
11593 pass the thread to do_windows_store_inferior_registers. Use
11594 ptid from regcache instead of inferior_ptid.
11595
11596 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
11597
11598 * ser-mingw.c (ser_windows_raw): Remove reference to
11599 struct serial::current_timeout.
11600
11601 2017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
11602
11603 PR tdep/20928
11604 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
11605 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
11606 (sparc64_fsr_type): Fix %fsr decoding.
11607
11608 2017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
11609
11610 * python/py-record-btrace.c (btpy_insn_data): Change return type
11611 for Python 2.
11612
11613 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
11614
11615 * spu-linux-nat.c (spu_fetch_inferior_registers,
11616 spu_store_inferior_registers): Use ptid from regcache, set and
11617 restore inferior_ptid.
11618 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
11619 Likewise.
11620
11621 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
11622
11623 * i386-linux-nat.c (fetch_register, store_register,
11624 i386_linux_fetch_inferior_registers,
11625 i386_linux_store_inferior_registers): Use ptid from regcache.
11626 * ia64-linux-nat.c (ia64_linux_fetch_register,
11627 ia64_linux_store_register): Likewise.
11628 * inf-ptrace.c (inf_ptrace_fetch_register,
11629 inf_ptrace_store_register): Likewise.
11630 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
11631 m32r_linux_store_inferior_registers): Likewise.
11632 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
11633 m68kbsd_store_inferior_registers): Likewise.
11634 * m68k-linux-nat.c (fetch_register, store_register,
11635 m68k_linux_fetch_inferior_registers,
11636 m68k_linux_store_inferior_registers): Likewise.
11637 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
11638 m88kbsd_store_inferior_registers): Likewise.
11639 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
11640 mips_fbsd_store_inferior_registers): Likewise.
11641 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
11642 mips64_linux_regsets_store_registers): Likewise.
11643 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
11644 mipsnbsd_store_inferior_registers): Likewise.
11645 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
11646 mips64obsd_store_inferior_registers): Likewise.
11647 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
11648 Likewise.
11649 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
11650 ppcfbsd_store_inferior_registers): Likewise.
11651 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
11652 ppc_linux_store_inferior_registers): Likewise.
11653 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
11654 ppcnbsd_store_inferior_registers): Likewise.
11655 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
11656 ppcobsd_store_registers): Likewise.
11657 * procfs.c (procfs_fetch_registers, procfs_store_registers):
11658 Likewise.
11659 * ravenscar-thread.c (ravenscar_fetch_registers,
11660 ravenscar_store_registers, ravenscar_prepare_to_store):
11661 Likewise.
11662 * record-btrace.c (record_btrace_fetch_registers,
11663 record_btrace_store_registers, record_btrace_prepare_to_store):
11664 Likewise.
11665 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
11666 Lookup inferior using ptid from regcache, instead of
11667 current_inferior.
11668 * remote.c (remote_fetch_registers, remote_store_registers): Use
11669 ptid from regcache.
11670 * rs6000-nat.c (fetch_register, store_register): Likewise.
11671 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
11672 s390_linux_store_inferior_registers): Likewise.
11673 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
11674 shnbsd_store_inferior_registers): Likewise.
11675 * sol-thread.c (sol_thread_fetch_registers,
11676 sol_thread_store_registers): Likewise.
11677 * sparc-nat.c (sparc_fetch_inferior_registers,
11678 sparc_store_inferior_registers): Likewise.
11679 * tilegx-linux-nat.c (fetch_inferior_registers,
11680 store_inferior_registers): Likewise.
11681 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
11682 vaxbsd_store_inferior_registers): Likewise.
11683 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
11684 store_xtregs): Likewise.
11685
11686 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
11687
11688 PR gdb/14441
11689 * NEWS: Mention support for rvalue references in GDB and python.
11690 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
11691 supports both lvalue and rvalue references.
11692
11693 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
11694
11695 PR gdb/14441
11696 * gdbtypes.c (rank_one_type): Implement overloading
11697 resolution rules regarding rvalue references.
11698
11699 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
11700
11701 PR gdb/14441
11702 * aarch64-tdep.c (aarch64_type_align)
11703 (aarch64_extract_return_value, aarch64_store_return_value): Change
11704 lvalue reference type checks to general reference type checks.
11705 * amd64-tdep.c (amd64_classify): Likewise.
11706 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
11707 Likewise.
11708 * arm-tdep.c (arm_type_align, arm_extract_return_value)
11709 (arm_store_return_value): Likewise.
11710 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
11711 * c-typeprint.c (c_print_type): Likewise.
11712 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
11713 (cplus_number_of_children, cplus_describe_child): Likewise.
11714 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
11715 * completer.c (expression_completer): Likewise.
11716 * cp-support.c (make_symbol_overload_list_adl_namespace):
11717 Likewise.
11718 * darwin-nat-info.c (info_mach_region_command): Likewise.
11719 * dwarf2loc.c (entry_data_value_coerce_ref)
11720 (value_of_dwarf_reg_entry): Likewise.
11721 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
11722 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
11723 Likewise.
11724 * findvar.c (extract_typed_address, store_typed_address):
11725 Likewise.
11726 * gdbtypes.c (rank_one_type): Likewise.
11727 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
11728 * infcall.c (value_arg_coerce): Likewise.
11729 * language.c (pointer_type): Likewise.
11730 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
11731 Likewise.
11732 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
11733 * mn10300-tdep.c (mn10300_type_align): Likewise.
11734 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
11735 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
11736 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
11737 Likewise.
11738 * printcmd.c (print_formatted, x_command): Likewise.
11739 * python/py-type.c (typy_get_composite, typy_template_argument):
11740 Likewise.
11741 * python/py-value.c (valpy_referenced_value)
11742 (valpy_get_dynamic_type, value_has_field): Likewise.
11743 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
11744 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
11745 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
11746 * spu-tdep.c (spu_scalar_value_p): Likewise.
11747 * symtab.c (lookup_symbol_aux): Likewise.
11748 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
11749 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
11750 Likewise.
11751 * valops.c (value_cast_pointers, value_cast)
11752 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
11753 (value_struct_elt, value_struct_elt_bitpos)
11754 (value_find_oload_method_list, find_overload_match)
11755 (value_rtti_indirect_type): Likewise.
11756 * valprint.c (val_print_scalar_type_p, generic_val_print):
11757 Likewise.
11758 * value.c (value_actual_type, value_as_address, unpack_long)
11759 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
11760 (coerce_ref): Likewise.
11761 * varobj.c (varobj_get_value_type): Likewise.
11762
11763 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
11764
11765 PR gdb/14441
11766 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
11767 table of constants.
11768 * python/lib/gdb/command/explore.py: Support exploring values
11769 of rvalue reference types.
11770 * python/lib/gdb/types.py: Implement get_basic_type() for
11771 rvalue reference types.
11772 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
11773 constant.
11774 * python/py-value.c (valpy_getitem): Add an rvalue reference
11775 check.
11776 (valpy_reference_value): Add new parameter "refcode".
11777 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
11778 New wrappers for valpy_reference_value().
11779 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
11780 (gdbpy_invoke_xmethod): Likewise.
11781
11782 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
11783
11784 PR gdb/14441
11785 * dwarf2read.c (process_die, read_type_die_1): Handle the
11786 DW_TAG_rvalue_reference_type DIE.
11787 (read_tag_reference_type): Add new parameter "refcode".
11788
11789 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
11790
11791 PR gdb/14441
11792 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
11793 (c_type_print_modifier, c_type_print_varspec_suffix)
11794 (c_type_print_base): Support printing rvalue reference types.
11795 * c-valprint.c (c_val_print, c_value_print): Support printing
11796 rvalue reference values.
11797
11798 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
11799
11800 PR gdb/14441
11801 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
11802 typename.
11803 * cp-support.c (replace_typedefs): Handle
11804 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
11805 * python/py-type.c (typy_lookup_type): Likewise.
11806
11807 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
11808
11809 PR gdb/14441
11810 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
11811 * parse.c (insert_type): Change assert statement.
11812 (follow_types): Handle rvalue reference types.
11813 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
11814 constant.
11815
11816 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
11817
11818 PR gdb/14441
11819 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
11820 value_ref() interface.
11821 * c-valprint.c (c_value_print): Likewise.
11822 * infcall.c (value_arg_coerce): Likewise.
11823 * python/py-value.c (valpy_reference_value): Likewise.
11824 * valops.c (value_cast, value_reinterpret_cast)
11825 (value_dynamic_cast, typecmp): Likewise.
11826 (value_ref): Parameterize by kind of return value reference type.
11827 * value.h (value_ref): Add new parameter "refcode".
11828
11829 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
11830
11831 PR gdb/14441
11832 * dwarf2read.c (read_tag_reference_type): Use
11833 lookup_lvalue_reference_type() instead of lookup_reference_type().
11834 * eval.c (evaluate_subexp_standard): Likewise.
11835 * f-exp.y: Likewise.
11836 * gdbtypes.c (make_reference_type, lookup_reference_type):
11837 Generalize with rvalue reference types.
11838 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
11839 convenience wrappers for lookup_reference_type().
11840 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
11841 reference kind parameter.
11842 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
11843 wrappers for lookup_reference_type().
11844 * guile/scm-type.c (gdbscm_type_reference): Use
11845 lookup_lvalue_reference_type() instead of lookup_reference_type().
11846 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
11847 * parse.c (follow_types): Likewise.
11848 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
11849 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
11850 Likewise.
11851 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
11852 (gdbpy_invoke_xmethod): Likewise.
11853 * stabsread.c: Provide extra argument to make_reference_type()
11854 call.
11855 * valops.c (value_ref, value_rtti_indirect_type): Use
11856 lookup_lvalue_reference_type() instead of lookup_reference_type().
11857
11858 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
11859
11860 PR gdb/14441
11861 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
11862 (TYPE_IS_REFERENCE): New macro.
11863 (struct type): Add rvalue_reference_type field.
11864 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
11865
11866 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
11867
11868 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
11869 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
11870 New function definition.
11871 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
11872 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
11873 New function declaration.
11874 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
11875 * mi/mi-interp.h: New file.
11876 * solib.c (info_sharedlibrary_command): Replace for loop with
11877 ALL_SO_LIBS macro
11878 * solib.h (update_solib_list): New function declaration.
11879 (so_list_head): Move macro.
11880 * solist.h (ALL_SO_LIBS): New macro.
11881
11882 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
11883
11884 * infcmd.c (post_create_inferior): Remove unused argument in
11885 call to solib_add.
11886 * remote.c (remote_start_remote): Likewise.
11887 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
11888 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
11889 (enable_break): Likewise.
11890 * solib.c (update_solib_list): Remove unused target argument
11891 and its documentation.
11892 (solib_add): Remove unused target argument. Remove unused
11893 argument in call to update_solib_list.
11894 (info_sharedlibrary_command): Remove unused argument in call
11895 to update_solib_list.
11896 (sharedlibrary_command): Remove unused argument in call to
11897 solib_add.
11898 (handle_solib_event): Likewise.
11899 (reload_shared_libraries): Likewise.
11900 * solib.h (solib_add): Remove unused target argument.
11901
11902 2017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
11903
11904 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
11905 (s390_displaced_step_fixup): Cover relative branches with the
11906 default fixup handling. This fixes lack of support for some
11907 relative branch instructions.
11908
11909 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11910
11911 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
11912 ptid from regcache.
11913
11914 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11915
11916 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
11917 i386_darwin_store_inferior_registers): Use ptid from regcache.
11918
11919 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11920
11921 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
11922 i386bsd_store_inferior_registers): Use ptid from regcache.
11923
11924 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11925
11926 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
11927 hppaobsd_store_registers): Use ptid from regcache.
11928
11929 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11930
11931 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
11932 hppanbsd_store_registers): Use ptid from regcache.
11933
11934 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11935
11936 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
11937 from regcache. Use get_ptrace_pid.
11938
11939 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11940
11941 * corelow.c (get_core_register_section): Use ptid from regcache,
11942 update doc.
11943
11944 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11945
11946 * bsd-uthread.c (bsd_uthread_fetch_registers,
11947 bsd_uthread_store_registers): Use ptid from regcache, set and
11948 restore inferior_ptid.
11949
11950 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11951
11952 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
11953 fetch_fp_regs, store_register, store_regs, store_fp_register,
11954 store_fp_regs): Use ptid from regcache.
11955
11956 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11957
11958 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
11959 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
11960 store_vfp_regs): Use ptid from regcache.
11961
11962 2017-03-17 Pedro Alves <palves@redhat.com>
11963
11964 PR remote/21188
11965 * ser-base.c (ser_base_wait_for): Add comment.
11966 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
11967 version.
11968 * ser-unix.c (hardwire_raw): Remove reference to
11969 scb->current_timeout.
11970 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
11971 (hardwire_ops): Install ser_base_readchar instead of
11972 hardwire_readchar.
11973 * serial.h (struct serial) <current_timeout, timeout_remaining>:
11974 Remove fields.
11975
11976 2017-03-17 Jonah Graham <jonah@kichwacoders.com>
11977
11978 PR gdb/19637
11979 * python/lib/gdb/printer/bound_registers.py: Add support for
11980 Python 3.
11981
11982 2017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
11983
11984 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
11985 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
11986 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
11987 byte_offset to subobj_byte_offset. Fix the handling of
11988 DWARF_VALUE_STACK on big-endian targets when coming via an
11989 implicit pointer.
11990 (dwarf2_evaluate_loc_desc): Adjust call to
11991 dwarf2_evaluate_loc_desc_full.
11992 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
11993 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
11994
11995 2017-03-16 Yao Qi <yao.qi@linaro.org>
11996
11997 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
11998 and REVSH instructions.
11999
12000 2017-03-16 Yao Qi <yao.qi@linaro.org>
12001
12002 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
12003 (arm_record_test): Declare.
12004 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
12005 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
12006 align with the manual.
12007 (thumb_record_misc): Adjust the code order to align with the
12008 manual.
12009 (thumb2_record_decode_insn_handler): Fix instruction matching.
12010 (instruction_reader_thumb): New class.
12011 (arm_record_test): New function.
12012
12013 2017-03-16 Yao Qi <yao.qi@linaro.org>
12014
12015 * arm-tdep.c (abstract_memory_reader): New class.
12016 (instruction_reader): New class.
12017 (extract_arm_insn): Add argument 'reader'. Callers updated.
12018 (decode_insn): Likewise.
12019
12020 2017-03-16 Doug Evans <dje@google.com>
12021
12022 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
12023 member. Change type of TYPE member to SCM. All uses updated.
12024 (lsscm_make_lazy_string_smob): Add assert.
12025 (lsscm_make_lazy_string): Flag bad length values.
12026 (lsscm_elt_type): New function.
12027 (gdbscm_lazy_string_to_value): Rewrite to use
12028 lsscm_safe_lazy_string_to_value.
12029 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
12030 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
12031 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
12032 in incoming type.
12033 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
12034 * guile/scm-type.c (tyscm_scm_to_type): New function.
12035
12036 2017-03-15 Doug Evans <dje@google.com>
12037
12038 PR python/17728, python/18439, python/18779
12039 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
12040 member. Change type of TYPE member to PyObject *. All uses updated.
12041 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
12042 (gdbpy_create_lazy_string_object): Flag bad length values.
12043 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
12044 Handle typedefs in incoming type.
12045 (stpy_lazy_string_elt_type): New function.
12046 (gdbpy_extract_lazy_string): Call it.
12047 * python/py-value.c (valpy_lazy_string): Flag bad length values.
12048 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
12049 typedefs in incoming type.
12050
12051 2017-03-16 Doug Evans <dje@google.com>
12052
12053 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
12054 * guile/scm-type.c (tyscm_scm_to_type): New function.
12055
12056 2017-03-16 Jiong Wang <jiong.wang@arm.com>
12057
12058 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
12059 "ULONGEST" for "skip".
12060
12061 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
12062
12063 PR gdb/21220
12064 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
12065 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
12066 (inf_ptrace_peek_poke): ...here. New function. Now also loop
12067 over ptrace peek/poke until end of buffer or error.
12068
12069 2017-03-14 Simon Marchi <simon.marchi@ericsson.com>
12070
12071 * parse.c (length_of_subexp): Make static.
12072 * parser-defs.h (length_of_subexp): Remove.
12073
12074 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
12075
12076 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
12077 as well.
12078
12079 2017-03-14 Pedro Alves <palves@redhat.com>
12080
12081 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
12082 (main): Use std::unique_ptr. Remove calls to
12083 cp_demangled_name_parse_free.
12084
12085 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
12086
12087 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
12088 alphabsd_store_inferior_registers): Use regcache->ptid instead
12089 of inferior_ptid.
12090
12091 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
12092
12093 * aix-thread.c (aix_thread_fetch_registers,
12094 aix_thread_store_registers): Use regcache->ptid instead of
12095 inferior_ptid.
12096
12097 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
12098
12099 * aarch64-linux-nat.c (fetch_gregs_from_thread,
12100 store_gregs_to_thread, fetch_fpregs_from_thread,
12101 store_fpregs_to_thread): Use regcache->ptid instead of
12102 inferior_ptid.
12103
12104 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
12105
12106 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
12107 amd64_linux_fetch_inferior_registers): Use regcache->ptid
12108 instead of inferior_ptid.
12109
12110 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
12111
12112 * target.c (target_fetch_registers, target_store_registers): Add
12113 assert.
12114
12115 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
12116
12117 * regcache.h (regcache_get_ptid): New function.
12118 * regcache.c (regcache_get_ptid): New function.
12119
12120 2017-03-13 Mark Wielaard <mark@klomp.org>
12121
12122 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
12123
12124 2017-03-10 Keith Seitz <keiths@redhat.com>
12125
12126 PR c++/8218
12127 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
12128
12129 2017-03-08 Pedro Alves <palves@redhat.com>
12130
12131 PR gdb/18360
12132 * infrun.c (start_step_over, do_target_resume, resume)
12133 (restart_threads): Assert we're not resuming a thread that is
12134 meant to be stopped.
12135 (infrun_thread_stop_requested_callback): Delete.
12136 (infrun_thread_stop_requested): If the thread is internally
12137 stopped, queue a pending stop event and clear the thread's
12138 inline-frame state.
12139 (handle_stop_requested): New function.
12140 (handle_syscall_event, handle_inferior_event_1): Use
12141 handle_stop_requested.
12142 (handle_stop_requested): New function.
12143 (handle_signal_stop): Set the thread's stop_signal here instead of
12144 at caller.
12145 (finish_step_over): Clear step over info unconditionally.
12146 (handle_signal_stop): If the user had interrupted the event
12147 thread, consider the stop a random signal.
12148 (handle_signal_stop) <signal arrived while stepping over
12149 breakpoint>: Don't restart threads here.
12150 (stop_waiting): Don't clear step-over info here.
12151
12152 2017-03-08 Pedro Alves <palves@redhat.com>
12153
12154 PR 21206
12155 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
12156 goes to argument 2, not 1.
12157
12158 2017-03-08 Pedro Alves <palves@redhat.com>
12159
12160 PR cli/21218
12161 * top.c (gdb_readline_wrapper): Avoid passing NULL to
12162 display_gdb_prompt.
12163 (command_line_input): Add comment.
12164
12165 2017-03-08 Pedro Alves <palves@redhat.com>
12166
12167 PR tui/21216
12168 * tui/tui-file.c (tui_file::write): New.
12169 * tui/tui-file.h (tui_file): Override "write".
12170 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
12171 factored out from ...
12172 (tui_puts): ... here.
12173 (tui_putc): Use them.
12174 (tui_write): New function.
12175 * tui/tui-io.h (tui_write): Declare.
12176
12177 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
12178
12179 * Makefile.in (SFILES): Replace "environ.c" with
12180 "common/environ.c".
12181 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
12182 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
12183 to...
12184 * common/environ.c: ... here.
12185 * environ.h: Moved to...
12186 * common/environ.h: ... here.
12187
12188 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
12189
12190 * gdbarch.sh (pstring_ptr): New static function.
12191 (gdbarch_disassembler_options): Use it.
12192 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
12193 not valid_disassembler_option->name.
12194 * gdbarch.c: Regenerate.
12195
12196 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
12197
12198 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
12199
12200 2017-03-07 Pedro Alves <palves@redhat.com>
12201
12202 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
12203
12204 2017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
12205
12206 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
12207 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
12208 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
12209 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
12210
12211 2017-03-06 Simon Marchi <simon.marchi@ericsson.com>
12212
12213 * xtensa-linux-nat.c (fetch_gregs): Remove const.
12214
12215 2017-03-03 Simon Marchi <simon.marchi@ericsson.com>
12216
12217 * remote.c (remote_add_target_side_commands): Use range-based
12218 for loop.
12219
12220 2017-03-03 Yao Qi <yao.qi@linaro.org>
12221
12222 PR gdb/21165
12223 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
12224 value is lazy.
12225 * valprint.c (common_val_print): Likewise.
12226
12227 2017-02-28 Peter Bergner <bergner@vnet.ibm.com>
12228
12229 * NEWS: Mention new set/show disassembler-options commands.
12230 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
12231 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
12232 (prospective_options): New static variable.
12233 (gdb_disassembler::gdb_disassembler): Initialize
12234 m_di.disassembler_options.
12235 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
12236 (get_disassembler_options): New function.
12237 (set_disassembler_options): Likewise.
12238 (set_disassembler_options_sfunc): Likewise.
12239 (show_disassembler_options_sfunc): Likewise.
12240 (disassembler_options_completer): Likewise.
12241 (_initialize_disasm): Likewise.
12242 * disasm.h (get_disassembler_options): New prototype.
12243 (set_disassembler_options): Likewise.
12244 * gdbarch.sh (gdbarch_disassembler_options): New variable.
12245 (gdbarch_verify_disassembler_options): Likewise.
12246 * gdbarch.c: Regenerate.
12247 * gdbarch.h: Likewise.
12248 * arm-tdep.c (num_disassembly_options): Delete.
12249 (set_disassembly_style): Likewise.
12250 (arm_disassembler_options): New static variable.
12251 (set_disassembly_style_sfunc): Convert short style name into long
12252 option name. Call set_disassembler_options.
12253 (show_disassembly_style_sfunc): New function.
12254 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
12255 set_gdbarch_verify_disassembler_options.
12256 (_initialize_arm_tdep): Delete regnames variable and update callers.
12257 (arm_disassembler_options): Initialize.
12258 (disasm_options): New variable.
12259 (num_disassembly_options): Rename from this...
12260 (num_disassembly_styles): ...to this. Compute by scanning through
12261 disasm_options.
12262 (valid_disassembly_styles): Initialize using disasm_options.
12263 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
12264 set_arm_regname_option.
12265 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
12266 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
12267 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
12268 set_gdbarch_verify_disassembler_options.
12269 * s390-tdep.c (s390_disassembler_options): New static variable.
12270 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
12271 set_gdbarch_verify_disassembler_options.
12272
12273 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
12274
12275 * remote.c (remote_add_target_side_condition): Remove "struct"
12276 keyword from range-based for loop.
12277
12278 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
12279
12280 * remote.c (remote_add_target_side_condition): Use range-based
12281 for loop. Update comment.
12282
12283 2017-02-27 Yao Qi <yao.qi@linaro.org>
12284
12285 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
12286
12287 2017-02-26 Alan Hayward <alan.hayward@arm.com>
12288
12289 * regcache.c (regcache_raw_update): New function.
12290 (regcache_raw_read): Move code to regcache_raw_update.
12291 * regcache.h (regcache_raw_update): New declaration.
12292 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
12293
12294 2017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
12295
12296 * dwarf2read.c (create_debug_type_hash_table): Initialize
12297 header.signature and header.type_offset_in_tu.
12298
12299 2017-02-24 Pedro Alves <palves@redhat.com>
12300
12301 * symtab.c (make_file_symbol_completion_list_1): Use
12302 add_symtab_completions.
12303
12304 2017-02-24 Alan Hayward <alan.hayward@arm.com>
12305
12306 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
12307
12308 2017-02-24 Alan Hayward <alan.hayward@arm.com>
12309
12310 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
12311 I386_MAX_REGISTER_SIZE.
12312 (i386_pseudo_register_write): Likewise.
12313 (i386_process_record): Likewise.
12314 * i387-tdep.c (i387_supply_xsave): Likewise.
12315 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
12316 (store_register): Likewise.
12317
12318 2017-02-23 Pedro Alves <palves@redhat.com>
12319
12320 * ada-lang.c: Include "common/function-view.h".
12321 (ada_iterate_over_symbols): Adjust to use function_view as
12322 callback type.
12323 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
12324 (ada_make_symbol_completion_list): Use a lambda.
12325 (ada_exc_search_name_matches): Delete.
12326 (name_matches_regex): New.
12327 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
12328 * compile/compile-c-support.c: Include "common/function-view.h".
12329 (print_one_macro): Change prototype to accept a ui_file pointer.
12330 (write_macro_definitions): Use a lambda.
12331 * dwarf2read.c: Include "common/function-view.h".
12332 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
12333 (dw2_expand_symtabs_matching): Adjust to use function_view as
12334 callback type.
12335 * language.h: Include "common/function-view.h".
12336 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
12337 function_view as callback type.
12338 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
12339 * linespec.c: Include "common/function-view.h".
12340 (collect_info::add_symbol): New method.
12341 (struct symbol_and_data_callback, iterate_inline_only, struct
12342 symbol_matcher_data, iterate_name_matcher): Delete.
12343 (iterate_over_all_matching_symtabs): Adjust to use function_view
12344 as callback type and lambdas.
12345 (iterate_over_file_blocks): Adjust to use function_view as
12346 callback type.
12347 (decode_compound_collector): Now a class with private fields.
12348 (decode_compound_collector::release_symbols): New method.
12349 (collect_one_symbol): Rename to...
12350 (decode_compound_collector::operator()): ... this and adjust.
12351 (lookup_prefix_sym): decode_compound_collector construction bits
12352 move to decode_compound_collector ctor. Pass the
12353 decode_compound_collector object directly as callback. Remove
12354 cleanups and use decode_compound_collector::release_symbols
12355 instead.
12356 (symtab_collector): Now a class with private fields.
12357 (symtab_collector::release_symtabs): New method.
12358 (add_symtabs_to_list): Rename to...
12359 (symtab_collector::operator()): ... this and adjust.
12360 (collect_symtabs_from_filename): symtab_collector construction
12361 bits move to symtab_collector ctor. Pass the symtab_collector
12362 object directly as callback. Remove cleanups and use
12363 symtab_collector::release_symtabs instead.
12364 (collect_symbols): Delete.
12365 (add_matching_symbols_to_info): Use lambdas.
12366 * macrocmd.c (print_macro_callback): Delete.
12367 (info_macro_command): Use a lambda.
12368 (info_macros_command): Pass print_macro_definition as callable
12369 directly.
12370 (print_one_macro): Remove 'ignore' parameter.
12371 (macro_list_command): Adjust.
12372 * macrotab.c (macro_for_each_data::fn): Now a function_view.
12373 (macro_for_each_data::user_data): Delete field.
12374 (foreach_macro): Adjust to call the function_view.
12375 (macro_for_each): Adjust to use function_view as callback type.
12376 (foreach_macro_in_scope): Adjust to call the function_view.
12377 (macro_for_each_in_scope): Adjust to use function_view as callback
12378 type.
12379 * macrotab.h: Include "common/function-view.h".
12380 (macro_callback_fn): Declare a prototype instead of a pointer.
12381 Remove "user_data" parameter.
12382 (macro_for_each, macro_for_each_in_scope): Adjust to use
12383 function_view as callback type.
12384 * psymtab.c (partial_map_expand_apply)
12385 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
12386 Adjust to use function_view as callback type and to return bool.
12387 (psym_expand_symtabs_matching): Adjust to use function_view as
12388 callback types.
12389 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
12390 to use function_view as callback type and to return bool.
12391 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
12392 callback types.
12393 * symfile.c (expand_symtabs_matching): Adjust to use function_view
12394 as callback types.
12395 * symfile.h: Include "common/function-view.h".
12396 (expand_symtabs_file_matcher_ftype)
12397 (expand_symtabs_symbol_matcher_ftype)
12398 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
12399 return bool.
12400 (quick_symbol_functions::map_symtabs_matching_filename)
12401 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
12402 function_view as callback type and return bool.
12403 (expand_symtabs_matching): Adjust to use function_view as callback
12404 type.
12405 (maintenance_expand_name_matcher)
12406 (maintenance_expand_file_matcher): Delete.
12407 (maintenance_expand_symtabs): Use lambdas.
12408 * symtab.c (iterate_over_some_symtabs): Adjust to use
12409 function_view as callback types and return bool.
12410 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
12411 of a cleanup.
12412 (lookup_symtab_callback): Delete.
12413 (lookup_symtab): Use a lambda.
12414 (iterate_over_symbols): Adjust to use function_view as callback
12415 type.
12416 (struct search_symbols_data, search_symbols_file_matches)
12417 (search_symbols_name_matches): Delete.
12418 (search_symbols): Use a pair of lambdas.
12419 (struct add_name_data, add_macro_name, symbol_completion_matcher)
12420 (symtab_expansion_callback): Delete.
12421 (default_make_symbol_completion_list_break_on_1): Use lambdas.
12422 * symtab.h: Include "common/function-view.h".
12423 (iterate_over_some_symtabs): Adjust to use function_view as
12424 callback type and return bool.
12425 (iterate_over_symtabs): Adjust to use function_view as callback
12426 type.
12427 (symbol_found_callback_ftype): Remove 'data' parameter and return
12428 bool.
12429 (iterate_over_symbols): Adjust to use function_view as callback
12430 type.
12431
12432 2017-02-23 Pedro Alves <palves@redhat.com>
12433
12434 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
12435 (%.o) <unittests/%.c>: New pattern.
12436 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
12437 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
12438 * common/function-view.h: New file.
12439 * unittests/function-view-selftests.c: New file.
12440 * configure: Regenerate.
12441
12442 2017-02-23 Simon Marchi <simon.marchi@ericsson.com>
12443
12444 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
12445 inferior_ptid.
12446 * go32-nat.c (go32_thread_alive): Likewise.
12447
12448 2017-02-23 Yao Qi <yao.qi@linaro.org>
12449
12450 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
12451 delete.
12452
12453 2017-02-23 Yao Qi <yao.qi@linaro.org>
12454
12455 * varobj.c (varobj_clear_saved_item): Use delete instead of
12456 xfree.
12457 (update_dynamic_varobj_children): Likewise.
12458
12459 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12460
12461 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
12462
12463 2017-02-21 Simon Marchi <simon.marchi@ericsson.com>
12464
12465 * common/enum-flags.h (enum_flags::enum_flags): Initialize
12466 m_enum_value to 0 in default constructor.
12467
12468 2017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
12469
12470 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
12471 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
12472 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
12473 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
12474 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
12475 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
12476 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
12477 IS_STORE_CONDITIONAL_INSN.
12478
12479 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12480
12481 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
12482
12483 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12484
12485 * NEWS (Changes since GDB 7.12): Add DWARF-5.
12486
12487 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12488
12489 * dwarf2read.c (skip_one_die, read_attribute_value)
12490 (dwarf2_const_value_attr, dump_die_shallow)
12491 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
12492 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
12493
12494 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12495
12496 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
12497 (dwarf_parse_macro_header): Accept DWARF version 5.
12498 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
12499
12500 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12501
12502 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
12503 DW_AT_GNU_*.
12504 * common/common-exceptions.h (enum errors): Likewise.
12505 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
12506 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
12507 (dwarf_expr_context::execute_stack_op): Likewise.
12508 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
12509 Likewise.
12510 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
12511 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
12512 (show_entry_values_debug, call_site_to_target_addr)
12513 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
12514 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
12515 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
12516 (value_of_dwarf_block_entry, indirect_pieced_value)
12517 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
12518 (disassemble_dwarf_expression): Likewise.
12519 * dwarf2read.c (process_die, inherit_abstract_dies)
12520 (read_call_site_scope): Likewise.
12521 * gdbtypes.h (struct func_type, struct call_site_parameter)
12522 (struct call_site): Likewise.
12523 * stack.c (read_frame_arg): Likewise.
12524 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
12525
12526 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12527
12528 * defs.h (read_unsigned_leb128): New declaration.
12529 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
12530 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
12531 (dwarf2_find_location_expression): Call also
12532 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
12533 * dwarf2loc.h (dwarf2_version): New declaration.
12534 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
12535 rnglists.
12536 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
12537 .debug_rnglists.
12538 (struct dwop_section_names): Add loclists_dwo.
12539 (dwop_section_names): Add .debug_loclists.dwo.
12540 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
12541 (struct dwarf2_per_cu_data): Add dwarf_version.
12542 (struct dwo_sections): Add loclists.
12543 (struct attr_abbrev): Add implicit_const.
12544 (read_indirect_line_string): New declaration.
12545 (read_unsigned_leb128): Delete declaration.
12546 (rcuh_kind): New definition.
12547 (read_and_check_comp_unit_head): Change parameter
12548 is_debug_types_section to section_kind.
12549 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
12550 (read_comp_unit_head): Change parameter abfd to section, add parameter
12551 section_kind. Handle DWARF-5.
12552 (error_check_comp_unit_head): Accept also DWARF version 5.
12553 (read_and_check_comp_unit_head): Change parameter
12554 is_debug_types_section to section_kind.
12555 (read_and_check_type_unit_head): Delete function.
12556 (read_abbrev_offset): Handle DWARF-5.
12557 (create_debug_type_hash_table): Add parameter section_kind. Process
12558 only DW_UT_type. Use signature and type_offset_in_tu from struct
12559 comp_unit_head.
12560 (create_debug_types_hash_table): Update create_debug_type_hash_table
12561 caller.
12562 (create_all_type_units): Call create_debug_type_hash_table.
12563 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
12564 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
12565 caller.
12566 (skip_one_die): Handle DW_FORM_implicit_const.
12567 (dwarf2_rnglists_process): New function.
12568 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
12569 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
12570 (read_attribute_value): Handle DW_FORM_implicit_const,
12571 DW_FORM_line_strp.
12572 (read_attribute): Handle DW_FORM_implicit_const.
12573 (read_indirect_string_at_offset_from): New function from
12574 read_indirect_string_at_offset.
12575 (read_indirect_string_at_offset): Call
12576 read_indirect_string_at_offset_from.
12577 (read_indirect_line_string_at_offset): New function.
12578 (read_indirect_string): New function comment.
12579 (read_indirect_line_string): New function.
12580 (read_unsigned_leb128): Make it global.
12581 (dwarf2_string_attr): Handle DWARF-5.
12582 (add_include_dir_stub, read_formatted_entries): New functions.
12583 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
12584 Handle DWARF-5.
12585 (per_cu_header_read_in): Update read_comp_unit_head caller.
12586 (dwarf2_version): New function.
12587 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
12588 rnglists.
12589 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
12590 fields.
12591
12592 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12593
12594 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
12595
12596 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12597
12598 * dwarf2read.c (dwarf2_ranges_process): New function from
12599 dwarf2_ranges_read.
12600 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
12601 dwarf2_ranges_process.
12602
12603 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12604
12605 * dwarf2read.c (create_debug_type_hash_table): New function from
12606 create_debug_types_hash_table.
12607 (create_debug_types_hash_table): Call create_debug_type_hash_table.
12608 (create_all_type_units, open_and_init_dwo_file): Update
12609 create_debug_types_hash_table callers.
12610
12611 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
12612
12613 PR gdb/16188
12614 * fork-child.c (trace_start_error): Fix thinko. va_end should
12615 refer to 'ap', not 'args'.
12616
12617 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
12618 Pedro Alves <palves@redhat.com>
12619
12620 PR gdb/16188
12621 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
12622 calls succeeded.
12623 * fork-child.c (trace_start_error): New function.
12624 (trace_start_error_with_name): Likewise.
12625 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
12626 * inf-ptrace.c (inf_ptrace_me): Likewise.
12627 * inferior.h (trace_start_error): New prototype.
12628 (trace_start_error_with_name): Likewise.
12629
12630 2017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
12631
12632 PR gdb/21164
12633 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
12634 NULL before using it.
12635 * symmisc.c (maintenance_print_symbols): Likewise.
12636 (maintenance_print_msymbols): Likewise.
12637
12638 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12639
12640 * NEWS: Add record Python bindings entry.
12641
12642 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12643
12644 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
12645 py-record-full.o.
12646 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
12647 * python/py-record-btrace.c, python/py-record-btrace.h,
12648 python/py-record-full.c, python/py-record-full.h: New file.
12649 * python/py-record.c: Add include for py-record-btrace.h and
12650 py-record-full.h.
12651 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
12652 recpy_instruction_history, recpy_function_call_history, recpy_begin,
12653 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
12654 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
12655 New definition.
12656 (gdbpy_initialize_btrace): New export.
12657 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
12658
12659 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12660
12661 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
12662 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
12663 * python/py-record.c: New file.
12664 * python/python-internal.h (gdbpy_start_recording,
12665 gdbpy_current_recording, gdpy_stop_recording,
12666 gdbpy_initialize_record): New export.
12667 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
12668 (python_GdbMethods): Add gdbpy_start_recording,
12669 gdbpy_current_recording and gdbpy_stop_recording.
12670
12671 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12672
12673 * record-btrace.c (record_btrace_record_method): New function.
12674 (init_record_btrace_ops): Initialize to_record_method.
12675 * record-full.c (record_full_record_method): New function.
12676 (init_record_full_ops, init_record_full_core_ops): Add
12677 record_full_record_method.
12678 * record.h (enum record_method): New enum.
12679 * target-debug.h (target_debug_print_enum_record_method: New define.
12680 * target-delegates.c: Regenerate.
12681 * target.c (target_record_method): New function.
12682 * target.h: Include record.h.
12683 (struct target_ops) <to_record_method>: New field.
12684 (target_record_method): New export.
12685
12686 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12687
12688 * record.h (record_start, record_stop): New export.
12689 * record.c (record_start, record_stop): New function.
12690
12691 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12692
12693 * btrace.c (btrace_fetch): Copy function call segments pointer
12694 into a vector.
12695 (btrace_clear): Clear the vector.
12696 (btrace_find_insn_by_number): Use binary search to find the correct
12697 function call segment.
12698 * btrace.h (brace_fun_p): New typedef.
12699 (struct btrace_thread_info) <functions>: New field.
12700
12701 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12702
12703 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
12704 * btrace.c (btrace_decode_error): ... here. New function.
12705 * btrace.h (btrace_decode_error): New export.
12706
12707 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12708
12709 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
12710 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
12711 btrace_find_insn_by_number): Remove special case for gaps.
12712 * btrace.h (btrace_insn_get_error): New export.
12713 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
12714 * record-btrace.c (btrace_insn_history): Print number for gaps.
12715 (record_btrace_info, record_btrace_goto): Handle gaps.
12716
12717 2017-02-14 Tom Tromey <tom@tromey.com>
12718
12719 PR python/13598:
12720 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
12721 event.
12722 * python/py-evts.c (gdbpy_initialize_py_events): Add
12723 before_prompt registry.
12724 * python/py-events.h (events_object) <before_prompt>: New field.
12725
12726 2017-02-14 Markus Metzger <markus.t.metzger@intel.com>
12727
12728 * btrace.c (ftrace_new_switch): Preserve up link and flags.
12729
12730 2017-02-13 Luis Machado <lgustavo@codesourcery.com>
12731
12732 * symfile (_initialize_symfile): Add usage text to the load command's
12733 help text.
12734
12735 2017-02-10 Simon Marchi <simon.marchi@ericsson.com>
12736
12737 * utils.c (defaulted_query): Don't query on secondary UIs.
12738
12739 2017-02-10 Tom Tromey <tom@tromey.com>
12740
12741 * rust-lang.c (rust_get_disr_info): Remove unused variable.
12742
12743 2017-02-10 Tom Tromey <tom@tromey.com>
12744
12745 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
12746 "cleanup" local.
12747 * python/py-type.c (typy_legacy_template_argument): Remove
12748 unnecessary "cleanup" local.
12749
12750 2017-02-10 Tom Tromey <tom@tromey.com>
12751
12752 * python/python.c (do_start_initialization): New function, from
12753 _initialize_python.
12754 (_initialize_python): Call do_start_initialization.
12755 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
12756 goto.
12757
12758 2017-02-10 Tom Tromey <tom@tromey.com>
12759
12760 * python/py-prettyprint.c (pretty_print_one_value): Use
12761 gdbpy_ref.
12762
12763 2017-02-10 Tom Tromey <tom@tromey.com>
12764
12765 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
12766 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
12767 gdbpy_ref.
12768 * python/py-type.c (field_new): Use gdbpy_ref.
12769 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
12770 gdbpy_ref.
12771 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
12772 (py_free_pspace): Likewise.
12773 (pspace_to_pspace_object): Likewise.
12774 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
12775 (py_free_objfile): Likewise.
12776 (objfile_to_objfile_object): Likewise.
12777 * python/py-inferior.c (delete_thread_object): Use
12778 gdbpy_ref.
12779 (infpy_read_memory): Likewise.
12780 (py_free_inferior): Likewise.
12781 * python/py-evtregistry.c (create_eventregistry_object): Use
12782 gdbpy_ref.
12783 * python/py-event.c (create_event_object): Use gdbpy_ref.
12784
12785 2017-02-10 Tom Tromey <tom@tromey.com>
12786
12787 * python/py-ref.h (gdbpy_ref_policy): Now a template.
12788 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
12789 used.
12790 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
12791 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
12792 python/py-exitedevent.c, python/py-finishbreakpoint.c,
12793 python/py-framefilter.c, python/py-function.c,
12794 python/py-inferior.c, python/py-infevents.c,
12795 python/py-linetable.c, python/py-newobjfileevent.c,
12796 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
12797 python/py-signalevent.c, python/py-stopevent.c,
12798 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
12799 python/py-unwind.c, python/py-utils.c, python/py-value.c,
12800 python/py-varobj.c, python/py-xmethods.c, python/python.c,
12801 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
12802
12803 2017-02-10 Tom Tromey <tom@tromey.com>
12804
12805 * ui-out.h (ui_out_emit_type): New class.
12806 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
12807 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
12808 and ui_out_emit_tuple.
12809 (enumerate_locals): Likewise.
12810 (py_mi_print_variables, py_print_locals, py_print_args): Use
12811 ui_out_emit_list.
12812 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
12813 ui_out_emit_list.
12814 * common/gdb_optional.h: New file.
12815
12816 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
12817
12818 * MAINTAINERS (Write After Approval): Update my e-mail address.
12819
12820 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
12821
12822 PR gdb/21122
12823 * breakpoint.c (_initialize_breakpoint): Update the help description
12824 of the 'commands' command to indicate that it takes a list argument.
12825
12826 2017-02-09 Simon Marchi <simon.marchi@ericsson.com>
12827
12828 * interps.c (current_interp_set_logging): Remove "return".
12829
12830 2017-02-09 Gary Benson <gbenson@redhat.com>
12831
12832 * symtab.c (add_symtab_completions): Prevent NULL pointer
12833 dereference.
12834
12835 2017-02-08 Pedro Alves <palves@redhat.com>
12836
12837 * interps.c (interp::interp): Remove reference to quiet_p.
12838 (interp_set): Make static. Remove dead "Switching to" output
12839 code.
12840 (interp_quiet_p, interp_set_quiet): Delete.
12841 (interpreter_exec_cmd): Don't set the interpreter quiet.
12842 * interps.h (interp_quiet_p): Make static.
12843 (class interp) <quiet_p>: Remove field
12844
12845 2017-02-08 Jerome Guitton <guitton@adacore.com>
12846
12847 * cli/cli-decode.c (find_command_name_length): Make it extern.
12848 * cli/cli-decode.h (find_command_name_length): Declare.
12849 * cli/cli-script.c (command_name_equals, line_first_arg):
12850 New functions.
12851 (process_next_line): Use cli-decode to parse command names.
12852 (build_command_line): Make args a constant pointer.
12853
12854 2017-02-08 Jerome Guitton <guitton@adacore.com>
12855
12856 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
12857 Remove case-insensitive search.
12858
12859 2017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
12860
12861 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
12862 at the end of the line. Avoids an ARI warning.
12863
12864 2017-02-06 Luis Machado <lgustavo@codesourcery.com>
12865
12866 * NEWS: Mention support for record/replay of Intel 64 rdrand and
12867 rdseed instructions.
12868 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
12869
12870 2017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
12871
12872 PR tdep/20936
12873 Provide and use sparc32 and sparc64 target description XML files.
12874 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
12875 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
12876 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
12877 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
12878 * features/sparc/sparc32-solaris.xml: New file.
12879 * features/sparc/sparc64-solaris.xml: New file.
12880 * features/sparc/sparc32-solaris.c: Generated.
12881 * features/sparc/sparc64-solaris.c: Generated.
12882 * sparc-tdep.h: Account for differences in target descriptions.
12883 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
12884 (sparc32_register_type): Use target provided registers.
12885 (validate_tdesc_registers): New function.
12886 (sparc32_gdbarch_init): Use tdesc_has_registers.
12887 Set pseudoregister functions.
12888 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
12889 (sparc64_register_type): Use target provided registers.
12890 (sparc64_init_abi): Set pseudoregister functions.
12891
12892 2017-02-03 Tom Tromey <tom@tromey.com>
12893
12894 PR rust/21097:
12895 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
12896 with a single member.
12897
12898 2017-02-03 Pedro Alves <palves@redhat.com>
12899
12900 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
12901 (cli_interp_base::~cli_interp_base): New.
12902 (cli_interp): New struct.
12903 (as_cli_interp): Cast the interp itself to cli_interp.
12904 (cli_interpreter_pre_command_loop): Rename to ...
12905 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
12906 parameter.
12907 (cli_interpreter_init): Rename to ...
12908 (cli_interp::init): ... this. Remove 'self' parameter. Use
12909 boolean. Make extern.
12910 (cli_interpreter_resume): Rename to ...
12911 (cli_interp::resume): ... this. Remove 'data' parameter. Make
12912 extern.
12913 (cli_interpreter_suspend): Rename to ...
12914 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
12915 extern.
12916 (cli_interpreter_exec): Rename to ...
12917 (cli_interp::exec): ... this. Remove 'data' parameter. Make
12918 extern.
12919 (cli_interpreter_supports_command_editing): Rename to ...
12920 (cli_interp_base::supports_command_editing): ... this. Remove
12921 'interp' parameter. Make extern.
12922 (cli_ui_out): Rename to ...
12923 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
12924 Make extern.
12925 (cli_set_logging): Rename to ...
12926 (cli_interp_base::set_logging): ... this. Remove 'interp'
12927 parameter. Make extern.
12928 (cli_interp_procs): Delete.
12929 (cli_interp_factory): Adjust to use "new".
12930 * cli/cli-interp.h: Include "interps.h".
12931 (struct cli_interp_base): New struct.
12932 * interps.c (struct interp): Delete. Fields moved to interps.h.
12933 (interp_new): Delete.
12934 (interp::interp, interp::~interp): New.
12935 (interp_set): Use bool, and return void. Assume the interpreter
12936 has suspend, init and resume methods, and that the all return
12937 void.
12938 (set_top_level_interpreter): interp_set returns void.
12939 (interp_ui_out): Adapt.
12940 (current_interp_set_logging): Adapt.
12941 (interp_data): Delete.
12942 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
12943 (interp_exec): Adapt.
12944 (top_level_interpreter_data): Delete.
12945 * interps.h (interp_init_ftype, interp_resume_ftype)
12946 (interp_suspend_ftype, interp_exec_ftype)
12947 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
12948 (class interp): New.
12949 (interp_new): Delete.
12950 (interp_set): Now returns void. Use bool.
12951 (interp_data, top_level_interpreter_data): Delete.
12952 * mi/mi-common.h: Include interps.h.
12953 (class mi_interp): Inherit from interp. Define a ctor. Declare
12954 init, resume, suspect, exec, interp_ui_out, set_logging and
12955 pre_command_loop methods.
12956 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
12957 (mi_interpreter_init): Rename to ...
12958 (mi_interp::init): ... this. Remove the 'interp' parameter, use
12959 bool, return void and make extern. Adjust.
12960 (mi_interpreter_resume): ... Rename to ...
12961 (mi_interp::resume): ... this. Remove the 'data' parameter,
12962 return void and make extern. Adjust.
12963 (mi_interpreter_suspend): ... Rename to ...
12964 (mi_interp::suspend): ... this. Remove the 'data' parameter,
12965 return void and make extern. Adjust.
12966 (mi_interpreter_exec): ... Rename to ...
12967 (mi_interp::exec): ... this. Remove the 'data' parameter and make
12968 extern. Adjust.
12969 (mi_interpreter_pre_command_loop): ... Rename to ...
12970 (mi_interp::pre_command_loop): ... this. Remove the 'self'
12971 parameter and make extern.
12972 (mi_on_normal_stop_1): Adjust.
12973 (mi_ui_out): Rename to ...
12974 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
12975 parameter and make extern. Adjust.
12976 (mi_set_logging): Rename to ...
12977 (mi_interp::set_logging): ... this. Remove the 'interp'
12978 parameter and make extern. Adjust.
12979 (mi_interp_procs): Delete.
12980 (mi_interp_factory): Adjust to use 'new'.
12981 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
12982 (mi_print_exception, mi_execute_command, mi_load_progress):
12983 Adjust.
12984 * tui/tui-interp.c (tui_interp): New class.
12985 (as_tui_interp): Return a tui_interp pointer.
12986 (tui_on_normal_stop, tui_on_signal_received)
12987 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
12988 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
12989 to use interp::interp_ui_out.
12990 (tui_init): Rename to ...
12991 (tui_interp::init): ... this. Remove the 'self' parameter, use
12992 bool, return void and make extern. Adjust.
12993 (tui_resume): Rename to ...
12994 (tui_interp::resume): ... this. Remove the 'data' parameter,
12995 return void and make extern. Adjust.
12996 (tui_suspend): Rename to ...
12997 (tui_interp::suspend): ... this. Remove the 'data' parameter,
12998 return void and make extern. Adjust.
12999 (tui_ui_out): Rename to ...
13000 (tui_interp::interp_ui_out): ... this. Remove the 'self'
13001 parameter, and make extern. Adjust.
13002 (tui_exec): Rename to ...
13003 (tui_interp::exec): ... this. Remove the 'data' parameter and
13004 make extern.
13005 (tui_interp_procs): Delete.
13006 (tui_interp_factory): Use "new".
13007
13008 2017-02-02 Tom Tromey <tom@tromey.com>
13009
13010 * rust-exp.y (ends_raw_string, space_then_number)
13011 (rust_identifier_start_p): Return bool.
13012 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
13013 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
13014 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
13015 (rust_chartype_p): Return bool.
13016 (val_print_struct, rust_print_struct_def, rust_print_type):
13017 Update.
13018 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
13019 Return bool.
13020
13021 2017-02-02 Tom Tromey <tom@tromey.com>
13022
13023 * rust-lang.c: Reindent.
13024
13025 2017-02-02 Tom Tromey <tom@tromey.com>
13026
13027 * rust-lang.h (rust_crate_for_block): Update.
13028 * rust-lang.c (rust_crate_for_block): Return std::string.
13029 (rust_get_disr_info): Use std:;string, not
13030 gdb::unique_xmalloc_ptr.
13031 * rust-exp.y (crate_name): Update.
13032
13033 2017-02-02 Pedro Alves <palves@redhat.com>
13034
13035 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
13036 field out of gdb_disassembler_test and make it static.
13037
13038 2017-02-02 Pedro Alves <palves@redhat.com>
13039
13040 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
13041 mi1_interp and mi_interp fields.
13042
13043 2017-02-02 Pedro Alves <palves@redhat.com>
13044
13045 * cli/cli-interp.c (struct saved_output_files, saved_output):
13046 Moved from cli/cli-logging.c.
13047 (cli_set_logging): New function.
13048 (cli_interp_procs): Install cli_set_logging.
13049 * cli/cli-interp.h (make_logging_output, cli_set_logging):
13050 Declare.
13051 * cli/cli-logging.c (struct saved_output_files, saved_output):
13052 Moved to cli/cli-interp.c.
13053 (pop_output_files): Don't save outputs here.
13054 (make_logging_output): New function.
13055 (handle_redirections): Don't build tee nor save previous outputs
13056 here.
13057 * interps.c (current_interp_set_logging): Change prototype.
13058 Assume there's always a set_logging_proc method installed.
13059 * interps.h (interp_set_logging_ftype): Change prototype.
13060 (current_interp_set_logging): Change prototype and adjust comment.
13061 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
13062 use make_logging_output.
13063 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
13064 2017-02-02 Pedro Alves <palves@redhat.com>
13065
13066 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
13067 from ...
13068 (set_logging_overwrite): ... here.
13069 (logging_no_redirect_file): Delete.
13070 (set_logging_redirect): Don't handle redirection on the fly.
13071 Instead warn that "logging off" / "logging on" is necessary.
13072 (pop_output_files): Delete references to logging_no_redirect_file.
13073 (show_logging_command): Always speak in terms of what will happen
13074 once logging is reenabled.
13075
13076 2017-02-02 Pedro Alves <palves@redhat.com>
13077
13078 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
13079
13080 2017-02-02 Pedro Alves <palves@redhat.com>
13081
13082 * disasm.c (gdb_pretty_print_insn): Rename to ...
13083 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
13084 Remove gdbarch parameter. Adapt to clear the object's buffers
13085 instead of allocating new buffers, and to print using the object's
13086 gdb_disassembler instead of calling gdb_print_insn.
13087 (dump_insns): Use gdb_pretty_print_disassembler.
13088 * disasm.h (gdb_pretty_print_insn): Delete declaration.
13089 (gdb_pretty_print_disassembler): New class.
13090 * record-btrace.c (btrace_insn_history): Use
13091 gdb_pretty_print_disassembler.
13092
13093 2017-02-02 Pedro Alves <palves@redhat.com>
13094
13095 * ada-lang.c (type_as_string): Use string_file.
13096 * ada-valprint.c (ada_print_floating): Use string_file.
13097 * ada-varobj.c (ada_varobj_scalar_image)
13098 (ada_varobj_get_value_image): Use string_file.
13099 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
13100 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
13101 * breakpoint.c (update_inserted_breakpoint_locations)
13102 (insert_breakpoint_locations, reattach_breakpoints)
13103 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
13104 (print_it_watchpoint): Use string_file.
13105 (save_breakpoints): Use stdio_file.
13106 * c-exp.y (oper): Use string_file.
13107 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
13108 tee_file.
13109 (pop_output_files): Use delete.
13110 (handle_redirections): Use stdio_file and tee_file.
13111 * cli/cli-setshow.c (do_show_command): Use string_file.
13112 * compile/compile-c-support.c (c_compute_program): Use
13113 string_file.
13114 * compile/compile-c-symbols.c (generate_vla_size): Take a
13115 'string_file &' instead of a 'ui_file *'.
13116 (generate_c_for_for_one_variable): Take a 'string_file &' instead
13117 of a 'ui_file *'. Use string_file.
13118 (generate_c_for_variable_locations): Take a 'string_file &'
13119 instead of a 'ui_file *'.
13120 * compile/compile-internal.h (generate_c_for_for_one_variable):
13121 Take a 'string_file &' instead of a 'ui_file *'.
13122 * compile/compile-loc2c.c (push, pushf, unary, binary)
13123 (print_label, pushf_register_address, pushf_register)
13124 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
13125 'ui_file *'. Adjust.
13126 * compile/compile.c (compile_to_object): Use string_file.
13127 * compile/compile.h (compile_dwarf_expr_to_c)
13128 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
13129 'ui_file *'.
13130 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
13131 (replace_typedefs_qualified_name): Use string_file and
13132 obstack_copy0.
13133 * disasm.c (gdb_pretty_print_insn): Use string_file.
13134 (gdb_disassembly): Adjust reference the null_stream global.
13135 (do_ui_file_delete): Delete.
13136 (gdb_insn_length): Use null_stream.
13137 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
13138 * dwarf2loc.c (dwarf2_compile_property_to_c)
13139 (locexpr_generate_c_location, loclist_generate_c_location): Take a
13140 'string_file &' instead of a 'ui_file *'.
13141 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
13142 * dwarf2read.c (do_ui_file_peek_last): Delete.
13143 (dwarf2_compute_name): Use string_file.
13144 * event-top.c (gdb_setup_readline): Use stdio_file.
13145 * gdbarch.sh (verify_gdbarch): Use string_file.
13146 * gdbtypes.c (safe_parse_type): Use null_stream.
13147 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
13148 string_file.
13149 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
13150 'string_file *' instead of a 'ui_file *'.
13151 (gdbscm_arch_disassemble): Use string_file.
13152 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
13153 * guile/scm-ports.c (class ioscm_file_port): Now a class that
13154 inherits from ui_file.
13155 (ioscm_file_port_delete, ioscm_file_port_rewind)
13156 (ioscm_file_port_put): Delete.
13157 (ioscm_file_port_write): Rename to ...
13158 (ioscm_file_port::write): ... this. Remove file_port_magic
13159 checks.
13160 (ioscm_file_port_new): Delete.
13161 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
13162 ui_file_up.
13163 * guile/scm-type.c (tyscm_type_name): Use string_file.
13164 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
13165 Use string_file.
13166 * infcmd.c (print_return_value_1): Use string_file.
13167 * infrun.c (print_target_wait_results): Use string_file.
13168 * language.c (add_language): Use string_file.
13169 * location.c (explicit_to_string_internal): Use string_file.
13170 * main.c (captured_main_1): Use null_file.
13171 * maint.c (maintenance_print_architecture): Use stdio_file.
13172 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
13173 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
13174 event_channel>: Change type to mi_console_file pointer.
13175 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
13176 (mi_console_file_delete): Delete.
13177 (struct mi_console_file): Delete.
13178 (mi_console_file_magic): Delete.
13179 (mi_console_file_new): Delete.
13180 (mi_console_file::mi_console_file): New.
13181 (mi_console_file_delete): Delete.
13182 (mi_console_file_fputs): Delete.
13183 (mi_console_file::write): New.
13184 (mi_console_raw_packet): Delete.
13185 (mi_console_file::flush): New.
13186 (mi_console_file_flush): Delete.
13187 (mi_console_set_raw): Rename to ...
13188 (mi_console_file::set_raw): ... this.
13189 * mi/mi-console.h (class mi_console_file): New class.
13190 (mi_console_file_new, mi_console_set_raw): Delete.
13191 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
13192 (mi_set_logging): Use delete and tee_file. Adjust.
13193 * mi/mi-main.c (output_register): Use string_file.
13194 (mi_cmd_data_evaluate_expression): Use string_file.
13195 (mi_cmd_data_read_memory): Use string_file.
13196 (mi_cmd_execute, print_variable_or_computed): Use string_file.
13197 * mi/mi-out.c (mi_ui_out::main_stream): New.
13198 (mi_ui_out::rewind): Use main_stream and
13199 string_file.
13200 (mi_ui_out::put): Use main_stream and string_file.
13201 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
13202 Allocate a 'string_file' instead.
13203 (mi_out_new): Don't allocate a mem_fileopen stream here.
13204 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
13205 (mi_ui_out::main_stream): Declare method.
13206 * printcmd.c (eval_command): Use string_file.
13207 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
13208 * python/py-arch.c (archpy_disassemble): Use string_file.
13209 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
13210 * python/py-frame.c (frapy_str): Use string_file.
13211 * python/py-framefilter.c (py_print_type, py_print_single_arg):
13212 Use string_file.
13213 * python/py-type.c (typy_str): Use string_file.
13214 * python/py-unwind.c (unwind_infopy_str): Use string_file.
13215 * python/py-value.c (valpy_str): Use string_file.
13216 * record-btrace.c (btrace_insn_history): Use string_file.
13217 * regcache.c (regcache_print): Use stdio_file.
13218 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
13219 * remote.c (escape_buffer): Use string_file.
13220 * rust-lang.c (rust_get_disr_info): Use string_file.
13221 * serial.c (serial_open_ops_1): Use stdio_file.
13222 (do_serial_close): Use delete.
13223 * stack.c (print_frame_arg): Use string_file.
13224 (print_frame_args): Remove local mem_fileopen stream, not used.
13225 (print_frame): Use string_file.
13226 * symmisc.c (maintenance_print_symbols): Use stdio_file.
13227 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
13228 Take a 'string_file *' instead of a 'ui_file *'.
13229 * top.c (new_ui): Use stdio_file and stderr_file.
13230 (free_ui): Use delete.
13231 (execute_command_to_string): Use string_file.
13232 (quit_confirm): Use string_file.
13233 * tracepoint.c (collection_list::append_exp): Use string_file.
13234 * tui/tui-disasm.c (tui_disassemble): Use string_file.
13235 * tui/tui-file.c: Don't include "ui-file.h".
13236 (enum streamtype, struct tui_stream): Delete.
13237 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
13238 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
13239 (tui_file::tui_file): New method.
13240 (tui_file_fputs): Delete.
13241 (tui_file_get_strbuf): Delete.
13242 (tui_file::puts): New method.
13243 (tui_file_adjust_strbuf): Delete.
13244 (tui_file_flush): Delete.
13245 (tui_file::flush): New method.
13246 * tui/tui-file.h: Tweak intro comment.
13247 Include ui-file.h.
13248 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
13249 (tui_file_adjust_strbuf): Delete declarations.
13250 (class tui_file): New class.
13251 * tui/tui-io.c (tui_initialize_io): Use tui_file.
13252 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
13253 (tui_register_format): Use string_stream.
13254 * tui/tui-stack.c (tui_make_status_line): Use string_file.
13255 (tui_get_function_from_frame): Use string_file.
13256 * typeprint.c (type_to_string): Use string_file.
13257 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
13258 (null_stream): New global.
13259 (ui_file_delete): Delete.
13260 (ui_file::ui_file): New.
13261 (null_file_isatty): Delete.
13262 (ui_file::~ui_file): New.
13263 (null_file_rewind): Delete.
13264 (ui_file::printf): New.
13265 (null_file_put): Delete.
13266 (null_file_flush): Delete.
13267 (ui_file::putstr): New.
13268 (null_file_write): Delete.
13269 (ui_file::putstrn): New.
13270 (null_file_read): Delete.
13271 (ui_file::putc): New.
13272 (null_file_fputs): Delete.
13273 (null_file_write_async_safe): Delete.
13274 (ui_file::vprintf): New.
13275 (null_file_delete): Delete.
13276 (null_file::write): New.
13277 (null_file_fseek): Delete.
13278 (null_file::puts): New.
13279 (ui_file_data): Delete.
13280 (null_file::write_async_safe): New.
13281 (gdb_flush, ui_file_isatty): Adjust.
13282 (ui_file_put, ui_file_rewind): Delete.
13283 (ui_file_write): Adjust.
13284 (ui_file_write_for_put): Delete.
13285 (ui_file_write_async_safe, ui_file_read): Adjust.
13286 (ui_file_fseek): Delete.
13287 (fputs_unfiltered): Adjust.
13288 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
13289 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
13290 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
13291 (set_ui_file_data): Delete.
13292 (string_file::~string_file, string_file::write)
13293 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
13294 (do_ui_file_as_string, ui_file_as_string): Delete.
13295 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
13296 (struct mem_file): Delete.
13297 (mem_file_new): Delete.
13298 (stdio_file::stdio_file): New.
13299 (mem_file_delete): Delete.
13300 (stdio_file::stdio_file): New.
13301 (mem_fileopen): Delete.
13302 (stdio_file::~stdio_file): New.
13303 (mem_file_rewind): Delete.
13304 (stdio_file::set_stream): New.
13305 (mem_file_put): Delete.
13306 (stdio_file::open): New.
13307 (mem_file_write): Delete.
13308 (stdio_file_magic, struct stdio_file): Delete.
13309 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
13310 (stdio_file::flush): New.
13311 (stdio_file_read): Rename to ...
13312 (stdio_file::read): ... this. Adjust.
13313 (stdio_file_write): Rename to ...
13314 (stdio_file::write): ... this. Adjust.
13315 (stdio_file_write_async_safe): Rename to ...
13316 (stdio_file::write_async_safe) ... this. Adjust.
13317 (stdio_file_fputs): Rename to ...
13318 (stdio_file::puts) ... this. Adjust.
13319 (stdio_file_isatty): Delete.
13320 (stdio_file_fseek): Delete.
13321 (stdio_file::isatty): New.
13322 (stderr_file_write): Rename to ...
13323 (stderr_file::write) ... this. Adjust.
13324 (stderr_file_fputs): Rename to ...
13325 (stderr_file::puts) ... this. Adjust.
13326 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
13327 (stderr_file::stderr_file): New.
13328 (tee_file_magic): Delete.
13329 (struct tee_file): Delete.
13330 (tee_file::tee_file): New.
13331 (tee_file_new): Delete.
13332 (tee_file::~tee_file): New.
13333 (tee_file_delete): Delete.
13334 (tee_file_flush): Rename to ...
13335 (tee_file::flush): ... this. Adjust.
13336 (tee_file_write): Rename to ...
13337 (tee_file::write): ... this. Adjust.
13338 (tee_file::write_async_safe): New.
13339 (tee_file_fputs): Rename to ...
13340 (tee_file::puts): ... this. Adjust.
13341 (tee_file_isatty): Rename to ...
13342 (tee_file::isatty): ... this. Adjust.
13343 * ui-file.h (struct obstack, struct ui_file): Don't
13344 forward-declare.
13345 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
13346 (ui_file_write_ftype)
13347 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
13348 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
13349 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
13350 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
13351 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
13352 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
13353 (set_ui_file_fseek): Delete.
13354 (ui_file_data, ui_file_delete, ui_file_rewind)
13355 (struct ui_file): New.
13356 (ui_file_up): New.
13357 (class null_file): New.
13358 (null_stream): Declare.
13359 (ui_file_write_for_put, ui_file_put): Delete.
13360 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
13361 Delete.
13362 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
13363 (gdb_fopen, tee_file_new): Delete.
13364 (struct string_file): New.
13365 (struct stdio_file): New.
13366 (stdio_file_up): New.
13367 (struct stderr_file): New.
13368 (class tee_file): New.
13369 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
13370 of a 'ui_file *'. Adjust.
13371 * ui-out.h (class ui_out) <field_stream>: Likewise.
13372 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
13373 (null_stream): Delete.
13374 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
13375 Adjust.
13376 * utils.h (struct ui_file): Delete forward declaration..
13377 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
13378 (error_stream): Take a 'string_file &' instead of a
13379 'ui_file *'.
13380 * varobj.c (varobj_value_get_print_value): Use string_file.
13381 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
13382 * gdbarch.c: Regenerate.
13383
13384 2017-02-02 Pedro Alves <palves@redhat.com>
13385
13386 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
13387 (gdb_pretty_print_insn): ... this. Now a free function. Add back
13388 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
13389 Adjust to call gdb_print_insn instead of
13390 gdb_disassembler::print_insn.
13391 (dump_insns, do_mixed_source_and_assembly_deprecated)
13392 (do_mixed_source_and_assembly, do_assembly_only): Add back a
13393 'gdbarch' parameter. Remove gdb_disassembler parameter.
13394 (gdb_disassembly): Don't allocate a gdb_disassembler here.
13395 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
13396 declaration.
13397 (gdb_pretty_print_insn): Re-add declaration.
13398 * record-btrace.c (btrace_insn_history): Don't allocate a
13399 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
13400
13401 2017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
13402
13403 * disasm.h (gdb_disassembly): Remove file_string parameter.
13404 * disasm.c (gdb_disassembly): Likewise.
13405 * cli/cli-cmds.c (print_disassembly): Adapt.
13406 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
13407 * stack.c (do_gdb_disassembly): Likewise.
13408
13409 2017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
13410
13411 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
13412 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
13413 targets. And if the implicit value is longer than needed, extract
13414 the first bytes instead of the "least significant" ones.
13415
13416 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
13417
13418 * btrace.c (btrace_enable): Do not call btrace_add_pc for
13419 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
13420 (btrace_fetch): Assert can_access_registers_ptid.
13421 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
13422 validate_registers_access.
13423
13424 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
13425
13426 * gdbthread.h (can_access_registers_ptid): New.
13427 * thread.c (can_access_registers_ptid): New.
13428
13429 2017-02-01 Pedro Alves <palves@redhat.com>
13430
13431 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
13432
13433 2017-01-31 Pedro Alves <palves@redhat.com>
13434
13435 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
13436 Fix typos.
13437
13438 2017-01-31 Pedro Alves <palves@redhat.com>
13439
13440 * stack.c (print_frame_args): Remove local mem_fileopen stream,
13441 not used.
13442
13443 2017-01-31 Pedro Alves <palves@redhat.com>
13444
13445 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
13446
13447 2017-01-31 Pedro Alves <palves@redhat.com>
13448
13449 * common/scoped_restore.h
13450 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
13451 change the value's parameter type to T2.
13452 (make_scoped_restore): Likewise.
13453
13454 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
13455 Richard Henderson <rth@redhat.com>
13456
13457 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
13458 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
13459 GS_BASE for older kernels.
13460 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
13461 GS_BASE for older kernels.
13462 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
13463 and GS_BASE to the offset table.
13464 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
13465 system register group.
13466 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
13467 for older kernels.
13468 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
13469 amd64 ABI.
13470 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
13471 AMD64_GSBASE_REGNUM.
13472 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
13473 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
13474 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
13475 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
13476 i386/64bit-segments.xml in those rules.
13477 * features/i386/64bit-segments.xml: New file.
13478 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
13479 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
13480 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
13481 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
13482 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
13483 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
13484 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
13485 * features/i386/amd64-avx-linux.c: Regenerated.
13486 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
13487 * features/i386/amd64-avx-mpx.c: Regenerated.
13488 * features/i386/amd64-avx512-linux.c: Regenerated.
13489 * features/i386/amd64-linux.c: Regenerated.
13490 * features/i386/amd64-mpx-linux.c: Regenerated.
13491 * features/i386/i386-avx-mpx-linux.c: Regenerated.
13492 * features/i386/i386-avx-mpx.c: Regenerated.
13493 * features/i386/x32-avx-linux.c: Regenerated.
13494 * features/i386/x32-avx512-linux.c: Regenerated.
13495 * regformats/i386/amd64-avx-linux.dat: Regenerated.
13496 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
13497 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
13498 * regformats/i386/amd64-linux.dat: Regenerated.
13499 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
13500 * regformats/i386/x32-avx-linux.dat: Regenerated.
13501 * regformats/i386/x32-avx512-linux.dat: Regenerated.
13502 * regformats/i386/x32-linux.dat: Regenerated.
13503
13504 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
13505
13506 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
13507 Set to AMD64_NUM_REGS.
13508
13509 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
13510
13511 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
13512 that checks validity of a register number.
13513
13514 2017-01-27 Kees Cook <keescook@google.com>
13515
13516 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
13517 fetch_fpregs if target has fpa registers.
13518 (arm_linux_store_inferior_registers): Call store_fpregs if target
13519 has fpa registers.
13520
13521 2017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
13522
13523 * cris-tdep.c (cris_gdbarch_init): Remove check for
13524 info.byte_order and force it to BFD_ENDIAN_LITTLE.
13525
13526 2017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
13527
13528 * corelow.c (get_core_register_section): Check for regset
13529 existence before checking for REGSET_VARIABLE_SIZE.
13530
13531 2017-01-26 Yao Qi <yao.qi@linaro.org>
13532 Pedro Alves <palves@redhat.com>
13533
13534 PR gdb/20939
13535 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
13536 call memory_error, save memaddr instead.
13537 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
13538 negative, cal memory_error.
13539 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
13540
13541 2017-01-26 Yao Qi <yao.qi@linaro.org>
13542
13543 * disasm-selftests.c (memory_error_test): New function.
13544 (_initialize_disasm_selftests): Register memory_error_test.
13545
13546 2017-01-26 Yao Qi <yao.qi@linaro.org>
13547
13548 * Makefile.in (SFILES): Add disasm-selftests.c and
13549 selftest-arch.c.
13550 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
13551 * disasm-selftests.c: New file.
13552 * selftest-arch.c: New file.
13553 * selftest-arch.h: New file.
13554
13555 2017-01-26 Yao Qi <yao.qi@linaro.org>
13556
13557 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
13558 to bfd_arch_mep. Don't return 0 if section is not
13559 found. Call print_insn_mep.
13560
13561 2017-01-26 Pedro Alves <palves@redhat.com>
13562 Yao Qi <yao.qi@linaro.org>
13563
13564 * arm-tdep.c: Include "disasm.h".
13565 (gdb_print_insn_arm): Update code to get gdbarch.
13566 * disasm.c (dis_asm_read_memory): Change it to
13567 gdb_disassembler::dis_asm_read_memory.
13568 (dis_asm_memory_error): Likewise.
13569 (dis_asm_print_address): Likewise.
13570 (gdb_pretty_print_insn): Change it to
13571 gdb_disassembler::pretty_print_insn.
13572 (dump_insns): Add one argument gdb_disassemlber. All
13573 callers updated.
13574 (do_mixed_source_and_assembly_deprecated): Likewise.
13575 (do_mixed_source_and_assembly): Likewise.
13576 (do_assembly_only): Likewise.
13577 (gdb_disassembler::gdb_disassembler): New.
13578 (gdb_disassembler::print_insn): New.
13579 * disasm.h (class gdb_disassembler): New.
13580 (gdb_pretty_print_insn): Remove declaration.
13581 (gdb_disassemble_info): Likewise.
13582 * guile/scm-disasm.c (class gdbscm_disassembler): New.
13583 (gdbscm_disasm_read_memory_worker): Update.
13584 (gdbscm_disasm_read_memory): Update.
13585 (gdbscm_disasm_memory_error): Remove.
13586 (gdbscm_disasm_print_address): Remove.
13587 (gdbscm_disassembler::gdbscm_disassembler): New.
13588 (gdbscm_print_insn_from_port): Update.
13589 * mips-tdep.c: Include disasm.h.
13590 (gdb_print_insn_mips): Update code to get gdbarch.
13591 * record-btrace.c (btrace_insn_history): Update.
13592 * spu-tdep.c: Include disasm.h.
13593 (struct spu_dis_asm_data): Remove.
13594 (struct spu_dis_asm_info): New.
13595 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
13596 SPU id.
13597 (gdb_print_insn_spu): Cast disassemble_info to
13598 spu_dis_asm_info.
13599
13600 2017-01-26 Yao Qi <yao.qi@linaro.org>
13601
13602 * disasm.c (do_ui_file_delete): Delete.
13603 (gdb_insn_length): Move code creating stream to ...
13604 * utils.c (null_stream): ... here. New function.
13605 * utils.h (null_stream): Declare.
13606
13607 2017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
13608
13609 * python/py-inferior.c (find_thread_object): Return directly
13610 from the loop. Remove "found" variable.
13611
13612 2017-01-21 Joel Brobecker <brobecker@adacore.com>
13613
13614 GDB 7.12.1 released.
13615
13616 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
13617
13618 * python/py-function.c (fnpy_call): Reorder declarations to have
13619 the gdbpy_enter object declared first.
13620 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
13621
13622 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
13623
13624 PR python/21068
13625 * python/python-internal.h (PyMem_RawMalloc): Define for
13626 Python < 3.4.
13627 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
13628 PyMem_RawMalloc instead of PyMem_Malloc.
13629
13630 2017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
13631 Luis Machado <lgustavo@codesourcery.com>
13632
13633 * NEWS (New commands): Mention flash-erase.
13634 (New MI commands): Mention target-flash-erase.
13635 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
13636 command.
13637 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
13638 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
13639 * target.c (flash_erase_command): New function.
13640 (initialize_targets): Add new flash-erase command.
13641 * target.h (flash_erase_command): New declaration.
13642
13643 2017-01-20 Joel Brobecker <brobecker@adacore.com>
13644
13645 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
13646 HAVE_SYS_PROCFS_H is defined.
13647
13648 2017-01-18 Alan Hayward <alan.hayward@arm.com>
13649
13650 * remote.c (struct cached_reg): Change data into a pointer.
13651 * (stop_reply_dtr): Free data pointers before deleting vector.
13652 (process_stop_reply): Likewise.
13653 (remote_parse_stop_reply): Allocate space for data
13654
13655 2017-01-18 Alan Hayward <alan.hayward@arm.com>
13656
13657 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
13658 MAX_REGISTER_SIZE.
13659 (amd64_pseudo_register_read_value): Likewise.
13660 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
13661 (store_register_using_P): Likewise.
13662 * regcache.c (regcache_xfer_part): Likewise.
13663
13664 2017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
13665
13666 Split real and pseudo registers.
13667 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
13668 (sparc32_pseudo_regnum): New enum.
13669 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
13670 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
13671 (SPARC32_CP0_REGISTERS): New macro.
13672 (sparc32_pseudo_register_name): New function.
13673 (sparc32_register_name): Use sparc32_pseudo_register_name.
13674 (sparc32_pseudo_register_type): New function.
13675 (sparc32_register_type): Use sparc32_pseudo_register_type.
13676 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
13677 pseudo register numbers.
13678 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
13679 (SPARC64_CP0_REGISTERS): New macro.
13680 (sparc64_pseudo_register_name): New function.
13681 (sparc64_register_name): Use sparc64_pseudo_register_name.
13682 (sparc64_pseudo_register_type): New function.
13683 (sparc64_register_type): Use sparc64_pseudo_register_type.
13684 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
13685 pseudo register numbers.
13686 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
13687 sparc64_store_arguments): Handle pseudo register numbers.
13688
13689 2017-01-13 Yao Qi <yao.qi@linaro.org>
13690
13691 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
13692 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
13693 output.
13694 (getpkt_or_notif_sane_1): Likewise.
13695
13696 2017-01-13 Yao Qi <yao.qi@linaro.org>
13697
13698 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
13699 of CC. Pass "-x c++-header" instead of "-x c".
13700
13701 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
13702
13703 * remote.c (remote_can_async_p): Update comment.
13704
13705 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
13706
13707 * linux-nat.c (linux_nat_can_async_p): Update comment.
13708
13709 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
13710
13711 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
13712
13713 2017-01-11 Simon Marchi <simon.marchi@ericsson.com>
13714
13715 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
13716
13717 2017-01-10 Tom Tromey <tom@tromey.com>
13718
13719 * python/py-type.c (typy_legacy_template_argument): Update.
13720 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
13721 ~demangle_parse_info): Declare new members.
13722 (cp_demangled_name_to_comp): Return unique_ptr.
13723 (cp_demangled_name_parse_free)
13724 (make_cleanup_cp_demangled_name_parse_free)
13725 (cp_new_demangle_parse_info): Remove.
13726 * cp-support.c (do_demangled_name_parse_free_cleanup)
13727 (make_cleanup_cp_demangled_name_parse_free): Remove.
13728 (inspect_type, cp_canonicalize_string_full)
13729 (cp_canonicalize_string): Update.
13730 (mangled_name_to_comp): Change return type.
13731 (cp_class_name_from_physname, method_name_from_physname)
13732 (cp_func_name, cp_remove_params): Update.
13733 * cp-name-parser.y (demangle_parse_info): New constructor, from
13734 cp_new_demangle_parse_info.
13735 (~demangle_parse_info): New destructor, from
13736 cp_demangled_name_parse_free.
13737 (cp_merge_demangle_parse_infos): Update.
13738 (cp_demangled_name_to_comp): Change return type.
13739
13740 2017-01-10 Tom Tromey <tom@tromey.com>
13741
13742 * top.c (prevent_dont_repeat): Change return type.
13743 * python/python.c (execute_gdb_command): Use std::string.
13744 Update.
13745 * guile/guile.c (gdbscm_execute_gdb_command): Update.
13746 * command.h (prevent_dont_repeat): Change return type.
13747 * breakpoint.c (bpstat_do_actions_1): Update.
13748
13749 2017-01-10 Tom Tromey <tom@tromey.com>
13750
13751 * value.h (scoped_value_mark::~scoped_value_mark): Call
13752 free_to_mark.
13753 (scoped_value_mark::free_to_mark): New method.
13754 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
13755 scoped_value_mark.
13756
13757 2017-01-10 Tom Tromey <tom@tromey.com>
13758
13759 * python/py-value.c (valpy_dereference, valpy_referenced_value)
13760 (valpy_reference_value, valpy_const_value, valpy_get_address)
13761 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
13762 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
13763 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
13764 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
13765 scoped_value_mark.
13766 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
13767 * value.h (scoped_value_mark): New class.
13768
13769 2017-01-10 Tom Tromey <tom@tromey.com>
13770
13771 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
13772 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
13773 * psymtab.c (discard_psymtabs_upto): Remove.
13774 (make_cleanup_discard_psymtabs): Remove.
13775 (struct psymtab_state): Remove.
13776
13777 2017-01-10 Tom Tromey <tom@tromey.com>
13778
13779 * record-full.c (record_full_save_cleanups): Remove.
13780 (record_full_save): Use gdb::unlinker.
13781 * gcore.c (do_bfd_delete_cleanup): Remove.
13782 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
13783 cleanups.
13784 * dwarf2read.c (unlink_if_set): Remove.
13785 (write_psymtabs_to_index): Use gdb::unlinker.
13786 * common/gdb_unlinker.h: New file.
13787
13788 2017-01-10 Tom Tromey <tom@tromey.com>
13789
13790 * windows-tdep.c (windows_xfer_shared_library): Update.
13791 * windows-nat.c (windows_make_so): Update.
13792 * utils.h (make_cleanup_bfd_unref): Remove.
13793 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
13794 * symfile.h (symfile_bfd_open)
13795 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
13796 * symfile.c (read_symbols, symbol_file_add)
13797 (separate_debug_file_exists): Update.
13798 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
13799 (generic_load, reread_symbols): Update.
13800 * symfile-mem.c (symbol_file_add_from_memory): Update.
13801 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
13802 (spu_symbol_file_add_from_memory): Update.
13803 * solist.h (struct target_so_ops) <bfd_open>: Return
13804 gdb_bfd_ref_ptr.
13805 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
13806 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
13807 gdb_bfd_ref_ptr.
13808 (solib_map_sections, reload_shared_libraries_1): Update.
13809 * solib-svr4.c (enable_break): Update.
13810 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
13811 * solib-frv.c (enable_break2): Update.
13812 * solib-dsbt.c (enable_break): Update.
13813 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
13814 gdb_bfd_ref_ptr.
13815 (darwin_solib_get_all_image_info_addr_at_init): Update.
13816 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
13817 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
13818 * record-full.c (record_full_save): Update.
13819 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
13820 * procfs.c (insert_dbx_link_bpt_in_file): Update.
13821 * minidebug.c (find_separate_debug_file_in_section): Return
13822 gdb_bfd_ref_ptr.
13823 * machoread.c (macho_add_oso_symfile): Change abfd to
13824 gdb_bfd_ref_ptr.
13825 (macho_symfile_read_all_oso): Update.
13826 (macho_check_dsym): Return gdb_bfd_ref_ptr.
13827 (macho_symfile_read): Update.
13828 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
13829 (jit_bfd_try_read_symtab): Update.
13830 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
13831 (gdb_bfd_openw, gdb_bfd_openr_iovec)
13832 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
13833 gdb_bfd_ref_ptr.
13834 (gdb_bfd_ref_policy): New struct.
13835 (gdb_bfd_ref_ptr): New typedef.
13836 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
13837 (gdb_bfd_openw, gdb_bfd_openr_iovec)
13838 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
13839 gdb_bfd_ref_ptr.
13840 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
13841 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
13842 (gcore_command): Update.
13843 * exec.c (exec_file_attach): Update.
13844 * elfread.c (elf_symfile_read): Update.
13845 * dwarf2read.c (dwarf2_get_dwz_file): Update.
13846 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
13847 (open_and_init_dwo_file): Update.
13848 (open_dwp_file): Return gdb_bfd_ref_ptr.
13849 (open_and_init_dwp_file): Update.
13850 * corelow.c (core_open): Update.
13851 * compile/compile-object-load.c (compile_object_load): Update.
13852 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
13853 * coffread.c (coff_symfile_read): Update.
13854 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
13855 gdb_bfd_ref_ptr. Rename.
13856 (dump_bfd_file, restore_command): Update.
13857 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
13858 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
13859 (find_separate_debug_file_by_buildid): Update.
13860
13861 2017-01-10 Tom Tromey <tom@tromey.com>
13862
13863 * common/gdb_ref_ptr.h: New file.
13864 * python/py-ref.h (struct gdbpy_ref_policy): New.
13865 (gdbpy_ref): Now a typedef.
13866
13867 2017-01-10 Tom Tromey <tom@tromey.com>
13868
13869 * utils.h (make_cleanup_htab_delete): Don't declare.
13870 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
13871 Remove.
13872 * linespec.c (decode_compound_collector): Add constructor,
13873 destructor.
13874 (lookup_prefix_sym): Remove cleanup.
13875 (symtab_collector): Add constructor, destructor.
13876 (collect_symtabs_from_filename): Remove cleanup.
13877 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
13878 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
13879 Use htab_up.
13880 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
13881 * dwarf2read.c (dw2_expand_symtabs_matching)
13882 (dw2_map_symbol_filenames, dwarf_decode_macros)
13883 (write_psymtabs_to_index): Use htab_up.
13884 * dwarf2loc.c (func_verify_no_selftailcall)
13885 (call_site_find_chain_1, func_verify_no_selftailcall)
13886 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
13887 std::vector, gdb::unique_xmalloc_ptr.
13888 (call_sitep): Remove typedef.
13889 (dwarf2_locexpr_baton_eval): Remove unused variable.
13890
13891 2017-01-10 Tom Tromey <tom@tromey.com>
13892
13893 * python/python-internal.h (make_cleanup_py_decref)
13894 (make_cleanup_py_xdecref): Don't declare.
13895 * python/py-utils.c (py_decref, make_cleanup_py_decref)
13896 (py_xdecref, make_cleanup_py_xdecref): Remove.
13897
13898 2017-01-10 Tom Tromey <tom@tromey.com>
13899
13900 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
13901 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
13902
13903 2017-01-10 Tom Tromey <tom@tromey.com>
13904
13905 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
13906
13907 2017-01-10 Tom Tromey <tom@tromey.com>
13908
13909 * python/py-utils.c (unicode_to_encoded_string)
13910 (python_string_to_target_string)
13911 (python_string_to_target_python_string)
13912 (python_string_to_host_string, gdbpy_obj_to_string)
13913 (get_addr_from_python): Use gdbpy_ref.
13914
13915 2017-01-10 Tom Tromey <tom@tromey.com>
13916
13917 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
13918 gdbpy_ref.
13919
13920 2017-01-10 Tom Tromey <tom@tromey.com>
13921
13922 * python/python.c (eval_python_command, gdbpy_decode_line)
13923 (gdbpy_run_events, gdbpy_start_type_printers)
13924 (gdbpy_apply_type_printers): Use gdbpy_ref.
13925
13926 2017-01-10 Tom Tromey <tom@tromey.com>
13927
13928 * python/py-param.c (get_doc_string, compute_enum_values): Use
13929 gdbpy_ref.
13930
13931 2017-01-10 Tom Tromey <tom@tromey.com>
13932
13933 * python/py-inferior.c (find_thread_object, build_inferior_list):
13934 Use gdbpy_ref.
13935
13936 2017-01-10 Tom Tromey <tom@tromey.com>
13937
13938 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
13939
13940 2017-01-10 Tom Tromey <tom@tromey.com>
13941
13942 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
13943 gdbpy_ref.
13944
13945 2017-01-10 Tom Tromey <tom@tromey.com>
13946
13947 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
13948 extra incref.
13949 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
13950 Use gdbpy_ref.
13951
13952 2017-01-10 Tom Tromey <tom@tromey.com>
13953
13954 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
13955 gdbpy_ref.
13956
13957 2017-01-10 Tom Tromey <tom@tromey.com>
13958
13959 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
13960 decref results of PyArg_ParseTupleAndKeywords.
13961
13962 2017-01-10 Tom Tromey <tom@tromey.com>
13963
13964 * python/python.c (python_run_simple_file): Use
13965 unique_xmalloc_ptr, gdbpy_ref.
13966
13967 2017-01-10 Tom Tromey <tom@tromey.com>
13968
13969 * python/py-prettyprint.c (print_stack_unless_memory_error)
13970 (print_string_repr, print_children): Use gdbpy_ref.
13971 (dummy_python_frame): New class.
13972 (dummy_python_frame::dummy_python_frame): Rename from
13973 push_dummy_python_frame.
13974 (py_restore_tstate): Remove.
13975
13976 2017-01-10 Tom Tromey <tom@tromey.com>
13977
13978 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
13979
13980 2017-01-10 Tom Tromey <tom@tromey.com>
13981
13982 * python/python.c (ensure_python_env, restore_python_env):
13983 Remove.
13984 * python/python-internal.h (ensure_python_env): Don't declare.
13985 * varobj.h (varobj_ensure_python_env): Don't declare.
13986 * varobj.c (varobj_ensure_python_env): Remove.
13987
13988 2017-01-10 Tom Tromey <tom@tromey.com>
13989
13990 * varobj.c (varobj_value_get_print_value): Use
13991 gdbpy_enter_varobj.
13992
13993 2017-01-10 Tom Tromey <tom@tromey.com>
13994
13995 * python/py-prettyprint.c (print_string_repr, print_children):
13996 Update.
13997 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
13998 of "encoding".
13999 * varobj.c (varobj_value_get_print_value): Update.
14000 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
14001
14002 2017-01-10 Tom Tromey <tom@tromey.com>
14003
14004 * varobj.c (varobj_get_display_hint)
14005 (dynamic_varobj_has_child_method, install_new_value_visualizer)
14006 (varobj_set_visualizer, free_variable): Use
14007 gdbpy_enter_varobj.
14008
14009 2017-01-10 Tom Tromey <tom@tromey.com>
14010
14011 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
14012 (do_finish_initialization): New function. Use gdbpy_ref.
14013 (gdbpy_finish_initialization): Use gdbpy_enter. Call
14014 do_finish_initialization.
14015
14016 2017-01-10 Tom Tromey <tom@tromey.com>
14017
14018 * python/py-param.c (get_set_value, get_show_value): Use
14019 gdbpy_enter, gdbpy_ref.
14020
14021 2017-01-10 Tom Tromey <tom@tromey.com>
14022
14023 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
14024
14025 2017-01-10 Tom Tromey <tom@tromey.com>
14026
14027 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
14028
14029 2017-01-10 Tom Tromey <tom@tromey.com>
14030
14031 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
14032 Use gdbpy_enter_varobj.
14033
14034 2017-01-10 Tom Tromey <tom@tromey.com>
14035
14036 * varobj.c (gdbpy_enter_varobj): New constructor.
14037 * python/python-internal.h (gdbpy_enter_varobj): New class.
14038 * python/py-varobj.c (py_varobj_get_iterator): Use
14039 gdbpy_enter_varobj.
14040
14041 2017-01-10 Tom Tromey <tom@tromey.com>
14042
14043 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
14044 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
14045 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
14046 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
14047 unique_xmalloc_ptr.
14048 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
14049
14050 2017-01-10 Tom Tromey <tom@tromey.com>
14051
14052 * python/py-xmethods.c (invoke_match_method): Use
14053 gdbpy_ref.
14054
14055 2017-01-10 Tom Tromey <tom@tromey.com>
14056
14057 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
14058 gdbpy_enter, gdbpy_ref.
14059
14060 2017-01-10 Tom Tromey <tom@tromey.com>
14061
14062 * python/python.c (python_interactive_command): Use gdbpy_enter.
14063
14064 2017-01-10 Tom Tromey <tom@tromey.com>
14065
14066 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
14067 gdbpy_ref.
14068
14069 2017-01-10 Tom Tromey <tom@tromey.com>
14070
14071 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
14072 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
14073
14074 2017-01-10 Tom Tromey <tom@tromey.com>
14075
14076 * utils.h (htab_deleter): New struct.
14077 (htab_up): New typedef.
14078 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
14079 gdbpy_enter, gdbpy_ref, htab_up.
14080
14081 2017-01-10 Tom Tromey <tom@tromey.com>
14082
14083 * python/py-unwind.c (pending_frame_invalidate): Remove.
14084 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
14085
14086 2017-01-10 Tom Tromey <tom@tromey.com>
14087
14088 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
14089 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
14090
14091 2017-01-10 Tom Tromey <tom@tromey.com>
14092
14093 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
14094
14095 2017-01-10 Tom Tromey <tom@tromey.com>
14096
14097 * python/python.c (gdbpy_eval_from_control_command)
14098 (gdbpy_source_script, gdbpy_run_events)
14099 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
14100 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
14101 gdbpy_enter.
14102
14103 2017-01-10 Tom Tromey <tom@tromey.com>
14104
14105 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
14106
14107 2017-01-10 Tom Tromey <tom@tromey.com>
14108
14109 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
14110
14111 2017-01-10 Tom Tromey <tom@tromey.com>
14112
14113 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
14114 (python_on_inferior_call_pre, python_on_inferior_call_post)
14115 (python_on_memory_change, python_on_register_change)
14116 (python_inferior_exit, python_new_objfile, add_thread_object)
14117 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
14118
14119 2017-01-10 Tom Tromey <tom@tromey.com>
14120
14121 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
14122 (bpfinishpy_handle_exit): Use gdbpy_enter.
14123
14124 2017-01-10 Tom Tromey <tom@tromey.com>
14125
14126 * python/py-cmd.c (cmdpy_destroyer)
14127 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
14128 gdbpy_enter.
14129
14130 2017-01-10 Tom Tromey <tom@tromey.com>
14131
14132 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
14133 gdbpy_enter.
14134 (gdbpy_breakpoint_has_cond): Likewise.
14135
14136 2017-01-10 Tom Tromey <tom@tromey.com>
14137
14138 * python/python.c (gdbpy_enter): New constructor.
14139 (~gdbpy_enter): New destructor.
14140 (restore_python_env, ensure_python_env): Rewrite.
14141 * python/python-internal.h (gdbpy_enter): New class.
14142
14143 2017-01-10 Tom Tromey <tom@tromey.com>
14144
14145 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
14146
14147 2017-01-10 Tom Tromey <tom@tromey.com>
14148
14149 * python/py-value.c (value_has_field, get_field_flag)
14150 (get_field_type, valpy_getitem, convert_value_from_python): Use
14151 gdbpy_ref.
14152
14153 2017-01-10 Tom Tromey <tom@tromey.com>
14154
14155 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
14156 gdbpy_ref.
14157
14158 2017-01-10 Tom Tromey <tom@tromey.com>
14159
14160 * python/py-prettyprint.c (search_pp_list)
14161 (find_pretty_printer_from_objfiles)
14162 (find_pretty_printer_from_progspace)
14163 (find_pretty_printer_from_gdb, find_pretty_printer)
14164 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
14165 gdbpy_ref.
14166
14167 2017-01-10 Tom Tromey <tom@tromey.com>
14168
14169 * python/py-param.c (call_doc_function): Use gdbpy_ref.
14170
14171 2017-01-10 Tom Tromey <tom@tromey.com>
14172
14173 * python/py-linetable.c (build_line_table_tuple_from_pcs)
14174 (ltpy_get_all_source_lines): Use gdbpy_ref.
14175
14176 2017-01-10 Tom Tromey <tom@tromey.com>
14177
14178 * python/py-framefilter.c (extract_sym, extract_value)
14179 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
14180 gdbpy_ref.
14181
14182 2017-01-10 Tom Tromey <tom@tromey.com>
14183
14184 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
14185
14186 2017-01-10 Tom Tromey <tom@tromey.com>
14187
14188 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
14189
14190 2017-01-10 Tom Tromey <tom@tromey.com>
14191
14192 * python/py-function.c (convert_values_to_python, fnpy_init): Use
14193 gdbpy_ref.
14194
14195 2017-01-10 Tom Tromey <tom@tromey.com>
14196
14197 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
14198
14199 2017-01-10 Tom Tromey <tom@tromey.com>
14200
14201 * python/py-type.c (convert_field, make_fielditem, typy_fields)
14202 (typy_range): Use gdbpy_ref.
14203
14204 2017-01-10 Tom Tromey <tom@tromey.com>
14205
14206 * python/py-threadevent.c (create_thread_event_object): Use
14207 gdbpy_ref.
14208 * python/py-stopevent.c (create_stop_event_object): Simplify.
14209 (emit_stop_event): Use gdbpy_ref.
14210 * python/py-signalevent.c (create_signal_event_object): Use
14211 gdbpy_ref.
14212 * python/py-newobjfileevent.c (create_new_objfile_event_object)
14213 (emit_new_objfile_event, create_clear_objfiles_event_object)
14214 (emit_clear_objfiles_event): Use gdbpy_ref.
14215 * python/py-infevents.c (create_inferior_call_event_object)
14216 (create_register_changed_event_object)
14217 (create_memory_changed_event_object, emit_inferior_call_event)
14218 (emit_memory_changed_event, emit_register_changed_event): Use
14219 gdbpy_ref.
14220 * python/py-exitedevent.c (create_exited_event_object)
14221 (emit_exited_event): Use gdbpy_ref.
14222 * python/py-event.h (evpy_emit_event): Remove
14223 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
14224 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
14225 * python/py-continueevent.c (emit_continue_event): Use
14226 gdbpy_ref.
14227 * python/py-breakpoint.c (gdbpy_breakpoint_created)
14228 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
14229 gdbpy_ref.
14230 * python/py-bpevent.c (create_breakpoint_event_object): Use
14231 gdbpy_ref.
14232
14233 2017-01-10 Tom Tromey <tom@tromey.com>
14234
14235 * python/py-ref.h: New file.
14236
14237 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
14238
14239 * cli-out.c (cli_ui_out::do_redirect): Change return type to
14240 void.
14241 * cli-out.h (cli_ui_out::do_redirect): Likewise.
14242 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
14243 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
14244 * ui-out.c (ui_out::redirect): Likewise.
14245 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
14246 * cli/cli-logging.c (set_logging_redirect): Update call site of
14247 ui_out::redirect.
14248 (handle_redirections): Likewise.
14249 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
14250 * top.c (execute_command_to_string): Likewise.
14251 * utils.c (do_ui_out_redirect_pop): Likewise.
14252
14253 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
14254
14255 * stack.c (_initialize_stack): Update "frame" command help message.
14256
14257 2017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
14258
14259 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
14260
14261 2017-01-06 Yao Qi <yao.qi@linaro.org>
14262
14263 * x86-linux-nat.h: Include gdb_proc_service.h.
14264
14265 2017-01-06 Yao Qi <yao.qi@linaro.org>
14266
14267 * ser-base.h: Include serial.h.
14268
14269 2017-01-06 Yao Qi <yao.qi@linaro.org>
14270
14271 * ppc-linux-tdep.h: Include ppc-tdep.h.
14272
14273 2017-01-06 Yao Qi <yao.qi@linaro.org>
14274
14275 * nat/amd64-linux-siginfo.h: Include signal.h.
14276
14277 2017-01-06 Yao Qi <yao.qi@linaro.org>
14278
14279 * nat/aarch64-linux-hw-point.h: Include break-common.h.
14280
14281 2017-01-06 Yao Qi <yao.qi@linaro.org>
14282
14283 * mi/mi-parse.h: Include mi-cmds.h.
14284
14285 2017-01-06 Yao Qi <yao.qi@linaro.org>
14286
14287 * inf-loop.c: Don't include "target.h".
14288 * inf-loop.h: Include it here.
14289
14290 2017-01-06 Yao Qi <yao.qi@linaro.org>
14291
14292 * dfp.h: Include "dboulest.h" and "expression.h".
14293
14294 2017-01-06 Yao Qi <yao.qi@linaro.org>
14295
14296 * ax-gdb.h: Include "ax.h".
14297
14298 2017-01-06 Yao Qi <yao.qi@linaro.org>
14299
14300 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
14301 with nat/gdb_ptrace.h.
14302
14303 2017-01-05 Yao Qi <yao.qi@linaro.org>
14304
14305 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
14306 new line.
14307 (mips64_fbsd_sigframe_init): Likewise.
14308
14309 2017-01-04 John Baldwin <jhb@FreeBSD.org>
14310
14311 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
14312 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
14313
14314 2017-01-04 John Baldwin <jhb@FreeBSD.org>
14315
14316 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
14317 * NEWS: Mention new FreeBSD/mips native configuration.
14318 * config/mips/fbsd.mh: New file.
14319 * configure.host: Add mips*-*-freebsd*.
14320 * mips-fbsd-nat.c: New file.
14321
14322 2017-01-04 John Baldwin <jhb@FreeBSD.org>
14323
14324 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
14325 (ALLDEPFILES): Add mips-fbsd-tdep.c.
14326 * NEWS: Mention new FreeBSD/mips target.
14327 * configure.tgt: Add mips*-*-freebsd*.
14328 * mips-fbsd-tdep.c: New file.
14329 * mips-fbsd-tdep.h: New file.
14330
14331 2017-01-04 Yao Qi <yao.qi@linaro.org>
14332
14333 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
14334 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
14335
14336 2017-01-01 Joel Brobecker <brobecker@adacore.com>
14337
14338 Update copyright year range in all GDB files.
14339
14340 2017-01-01 Joel Brobecker <brobecker@adacore.com>
14341
14342 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
14343
14344 For older changes see ChangeLog-2016.
14345 \f
14346 Local Variables:
14347 mode: change-log
14348 left-margin: 8
14349 fill-column: 74
14350 version-control: never
14351 coding: utf-8
14352 End:
This page took 0.32063 seconds and 5 git commands to generate.