Automatic date update in version.in
[deliverable/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
4a27f119
KS
12017-10-27 Keith Seitz <keiths@redhat.com>
2
3 * breakpoint.c (print_breakpoint_location): Use the symbol saved
4 in the bp_location, falling back to find_pc_sect_function when
5 needed.
6 (add_location_to_breakpoint): Save sal->symbol.
7 * breakpoint.h (struct bp_location) <symbol>: New field.
8 * symtab.c (find_function_start_sal): Save the symbol into the SaL.
9 * symtab.h (struct symtab_and_line) <symbol>: New field.
10
a43f3893
PF
112017-10-26 Patrick Frants <osscontribute@gmail.com>
12
7453e6b2 13 PR gdb/13669
a43f3893
PF
14 * cp-valprint.c (cp_print_value_fields): Use obstack_blank_fast
15 to rewind obstack.
16
23cc4e1b
PA
172017-10-26 Pedro Alves <palves@redhat.com>
18
19 * remote.c (remote_async_terminal_ours_p): Delete.
20 (remote_open_1, remote_terminal_inferior, remote_terminal_ours):
21 Remove references to 'remote_async_terminal_ours_p'.
22
6abc18bb
YQ
232017-10-26 Yao Qi <yao.qi@linaro.org>
24
25 * breakpoint.h (regular_breakpoint_inserted_here_p): Remove.
26
bd522513
YQ
272017-10-26 Yao Qi <yao.qi@linaro.org>
28
29 * break-catch-sig.c (signal_catchpoint_breakpoint_hit): Make
30 aspace const.
31 * break-catch-syscall.c (breakpoint_hit_catch_syscall):
32 Likewise.
33 * breakpoint.c (bpstat_check_location): Remove cast.
34 (breakpoint_hit_catch_fork): Make aspce const.
35 (breakpoint_hit_catch_solib): Likewise.
36 (breakpoint_hit_catch_exec): Likewise.
37 (breakpoint_hit_ranged_breakpoint): Likewise.
38 (breakpoint_hit_watchpoint): Likewise.
39 (base_breakpoint_breakpoint_hit): Likewise.
40 (bkpt_breakpoint_hit): Likewise.
41 (dprintf_breakpoint_hit): Likewise.
42 (tracepoint_breakpoint_hit): Likewise.
43 * breakpoint.h (breakpoint_ops) <breakpoint_hit>: Likewise.
44
accd0bcd
YQ
452017-10-26 Yao Qi <yao.qi@linaro.org>
46
47 * breakpoint.c (breakpoint_location_address_match): Change
48 "struct address_space *" to "const address_space".
49 (breakpoint_location_address_range_overlap): Likewise.
50 (breakpoint_here_p): Likewise.
51 (breakpoint_in_range_p): Likewise.
52 (moribund_breakpoint_here_p): Likewise.
53 (bp_location_inserted_here_p): Likewise.
54 (software_breakpoint_inserted_here_p): Likewise.
55 (hardware_breakpoint_inserted_here_p): Likewise.
56 (hardware_watchpoint_inserted_in_range): Likewise.
57 (bpstat_check_location): Likewise.
58 (bpstat_stop_status): Likewise.
59 (breakpoint_address_match): Likewise.
60 (breakpoint_address_match_range): Likewise.
61 (breakpoint_location_address_match): Likewise.
62 (breakpoint_location_address_range_overlap): Likewise.
63 (insert_single_step_breakpoint): Likewise.
64 (breakpoint_has_location_inserted_here): Likewise.
65 (single_step_breakpoint_inserted_here_p): Likewise.
66 (pc_at_non_inline_function): Likewise.
67 * breakpoint.h (bpstat_stop_status): Update declaration.
68 (breakpoint_here_p): Likewise.
69 (breakpoint_in_range_p): Likewise.
70 (moribund_breakpoint_here_p): Likewise.
71 (breakpoint_inserted_here_p): Likewise.
72 (software_breakpoint_inserted_here_p): Likewise.
73 (hardware_breakpoint_inserted_here_p): Likewise.
74 (breakpoint_has_location_inserted_here): Likewise.
75 (single_step_breakpoint_inserted_here_p): Likewise.
76 (hardware_watchpoint_inserted_in_range): Likewise.
77 (breakpoint_address_match): Likewise.
78 (insert_single_step_breakpoint): Likewise.
79 (pc_at_non_inline_function): Likewise.
80 * gdbthread.h (thread_has_single_step_breakpoint_here): Likewise.
81 * record.c (record_check_stopped_by_breakpoint): Likewise.
82 * record.h (record_check_stopped_by_breakpoint): Likewise.
83 * thread.c (thread_has_single_step_breakpoint_here): Likewise.
84
ac7936df
YQ
852017-10-25 Yao Qi <yao.qi@linaro.org>
86
87 * aarch32-linux-nat.c (aarch32_gp_regcache_supply): Use
88 regcache->arch () instead get_regcache_arch.
89 * aarch64-fbsd-nat.c (aarch64_fbsd_fetch_inferior_registers):
90 Likewise.
91 (aarch64_fbsd_store_inferior_registers): Likewise.
92 * aarch64-linux-nat.c (fetch_gregs_from_thread): Likewise.
93 (store_gregs_to_thread): Likewise.
94 (fetch_fpregs_from_thread): Likewise.
95 (store_fpregs_to_thread): Likewise.
96 * aarch64-tdep.c (aarch64_extract_return_value): Likewise.
97 (aarch64_store_return_value): Likewise.
98 (aarch64_software_single_step): Likewise.
99 * aix-thread.c (aix_thread_wait): Likewise.
100 (supply_reg32): Likewise.
101 (supply_sprs64): Likewise.
102 (supply_sprs32): Likewise.
103 (fill_gprs64): Likewise.
104 (fill_gprs32): Likewise.
105 (fill_sprs64): Likewise.
106 (fill_sprs32): Likewise.
107 (store_regs_user_thread): Likewise.
108 (store_regs_kernel_thread): Likewise.
109 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers): Likewise.
110 (alphabsd_store_inferior_registers): Likewise.
111 * alpha-tdep.c (alpha_extract_return_value): Likewise.
112 (alpha_store_return_value): Likewise.
113 (alpha_deal_with_atomic_sequence): Likewise.
114 (alpha_next_pc): Likewise.
115 (alpha_software_single_step): Likewise.
116 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Likewise.
117 (amd64bsd_store_inferior_registers): Likewise.
118 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers):
119 Likewise.
120 (amd64_linux_store_inferior_registers): Likewise.
121 * amd64-nat.c (amd64_supply_native_gregset): Likewise.
122 (amd64_collect_native_gregset): Likewise.
123 * amd64-obsd-tdep.c (amd64obsd_supply_uthread): Likewise.
124 (amd64obsd_collect_uthread): Likewise.
125 * amd64-tdep.c (amd64_supply_fpregset): Likewise.
126 (amd64_collect_fpregset): Likewise.
127 (amd64_supply_fxsave): Likewise.
128 (amd64_supply_xsave): Likewise.
129 (amd64_collect_fxsave): Likewise.
130 (amd64_collect_xsave): Likewise.
131 * arc-tdep.c (arc_write_pc): Likewise.
132 * arch-utils.c (default_skip_permanent_breakpoint): Likewise.
133 * arm-fbsd-nat.c (arm_fbsd_fetch_inferior_registers): Likewise.
134 (arm_fbsd_store_inferior_registers): Likewise.
135 * arm-linux-nat.c (fetch_vfp_regs): Likewise.
136 (store_vfp_regs): Likewise.
137 (arm_linux_fetch_inferior_registers): Likewise.
138 (arm_linux_store_inferior_registers): Likewise.
139 * arm-linux-tdep.c (arm_linux_supply_gregset): Likewise.
140 (arm_linux_sigreturn_next_pc): Likewise.
141 (arm_linux_get_next_pcs_syscall_next_pc): Likewise.
142 * arm-nbsd-nat.c (arm_supply_gregset): Likewise.
143 (fetch_register): Likewise.
144 (store_register): Likewise.
145 * arm-tdep.c (arm_is_thumb): Likewise.
146 (displaced_in_arm_mode): Likewise.
147 (bx_write_pc): Likewise.
148 (arm_get_next_pcs_addr_bits_remove): Likewise.
149 (arm_software_single_step): Likewise.
150 (arm_extract_return_value): Likewise.
151 (arm_store_return_value): Likewise.
152 (arm_write_pc): Likewise.
153 * bfin-tdep.c (bfin_extract_return_value): Likewise.
154 * bsd-uthread.c (bsd_uthread_fetch_registers): Likewise.
155 (bsd_uthread_store_registers): Likewise.
156 * core-regset.c (fetch_core_registers): Likewise.
157 * corelow.c (get_core_registers): Likewise.
158 * cris-tdep.c (cris_store_return_value): Likewise.
159 (cris_extract_return_value): Likewise.
160 (find_step_target): Likewise.
161 (find_step_target): Likewise.
162 (cris_software_single_step): Likewise.
163 * ctf.c (ctf_fetch_registers): Likewise.
164 * darwin-nat.c (cancel_breakpoint): Likewise.
165 * fbsd-tdep.c (fbsd_collect_thread_registers): Likewise.
166 * frv-tdep.c (frv_extract_return_value): Likewise.
167 * ft32-tdep.c (ft32_store_return_value): Likewise.
168 (ft32_extract_return_value): Likewise.
169 * go32-nat.c (fetch_register): Likewise.
170 (go32_fetch_registers): Likewise.
171 (go32_store_registers): Likewise.
172 (store_register): Likewise.
173 * h8300-tdep.c (h8300_extract_return_value): Likewise.
174 (h8300_store_return_value): Likewise.
175 * hppa-linux-nat.c (fetch_register): Likewise.
176 (store_register): Likewise.
177 (hppa_linux_fetch_inferior_registers): Likewise.
178 (hppa_linux_store_inferior_registers): Likewise.
179 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers): Likewise.
180 (i386_darwin_store_inferior_registers): Likewise.
181 * i386-gnu-nat.c (gnu_fetch_registers): Likewise.
182 (gnu_store_registers): Likewise.
183 * i386-linux-nat.c (fetch_register): Likewise.
184 (store_register): Likewise.
185 (supply_gregset): Likewise.
186 (fill_gregset): Likewise.
187 (i386_linux_fetch_inferior_registers): Likewise.
188 (i386_linux_store_inferior_registers): Likewise.
189 (i386_linux_resume): Likewise.
190 * i386-linux-tdep.c (i386_linux_get_syscall_number_from_regcache):
191 Likewise.
192 * i386-nto-tdep.c (i386nto_supply_gregset): Likewise.
193 * i386-obsd-nat.c (i386obsd_supply_pcb): Likewise.
194 * i386-obsd-tdep.c (i386obsd_supply_uthread): Likewise.
195 (i386obsd_collect_uthread): Likewise.
196 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
197 (i386_supply_gregset): Likewise.
198 (i386_collect_gregset): Likewise.
199 (i386_supply_fpregset): Likewise.
200 (i386_collect_fpregset): Likewise.
201 (i386_mpx_bd_base): Likewise.
202 * i386-v4-nat.c (supply_fpregset): Likewise.
203 (fill_fpregset): Likewise.
204 * i387-tdep.c (i387_supply_fsave): Likewise.
205 (i387_collect_fsave): Likewise.
206 (i387_supply_fxsave): Likewise.
207 (i387_collect_fxsave): Likewise.
208 (i387_supply_xsave): Likewise.
209 (i387_collect_xsave): Likewise.
210 * ia64-linux-nat.c (ia64_linux_fetch_registers): Likewise.
211 (ia64_linux_store_registers): Likewise.
212 * ia64-tdep.c (ia64_access_rse_reg): Likewise.
213 (ia64_extract_return_value): Likewise.
214 (ia64_store_return_value): Likewise.
215 (find_func_descr): Likewise.
216 * inf-child.c (inf_child_fetch_inferior_registers): Likewise.
217 * inf-ptrace.c (inf_ptrace_fetch_registers): Likewise.
218 (inf_ptrace_store_registers): Likewise.
219 * infrun.c (use_displaced_stepping): Likewise.
220 (displaced_step_prepare_throw): Likewise.
221 (resume): Likewise.
222 (proceed): Likewise.
223 (do_target_wait): Likewise.
224 (adjust_pc_after_break): Likewise.
225 (handle_inferior_event_1): Likewise.
226 (handle_signal_stop): Likewise.
227 (save_infcall_suspend_state): Likewise.
228 (restore_infcall_suspend_state): Likewise.
229 * iq2000-tdep.c (iq2000_extract_return_value): Likewise.
230 * jit.c (jit_frame_prev_register): Likewise.
231 * linux-nat.c (save_stop_reason): Likewise.
232 (linux_nat_wait_1): Likewise.
233 (resume_stopped_resumed_lwps): Likewise.
234 * linux-record.c (record_linux_sockaddr): Likewise.
235 (record_linux_msghdr): Likewise.
236 (record_linux_system_call): Likewise.
237 * linux-tdep.c (linux_collect_thread_registers): Likewise.
238 * lm32-tdep.c (lm32_extract_return_value): Likewise.
239 (lm32_store_return_value): Likewise.
240 * m32c-tdep.c (m32c_read_flg): Likewise.
241 (m32c_pseudo_register_read): Likewise.
242 (m32c_pseudo_register_write): Likewise.
243 * m32r-linux-tdep.c (m32r_linux_supply_gregset): Likewise.
244 (m32r_linux_collect_gregset): Likewise.
245 * m32r-tdep.c (m32r_store_return_value): Likewise.
246 (m32r_extract_return_value): Likewise.
247 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
248 (m68kbsd_collect_fpregset): Likewise.
249 * m68k-bsd-tdep.c (m68kbsd_supply_fpregset): Likewise.
250 * m68k-linux-nat.c (fetch_register): Likewise.
251 (old_fetch_inferior_registers): Likewise.
252 (old_store_inferior_registers): Likewise.
253 (store_regs): Likewise.
254 * m68k-tdep.c (m68k_svr4_extract_return_value): Likewise.
255 (m68k_svr4_store_return_value): Likewise.
256 * m88k-tdep.c (m88k_store_arguments): Likewise.
257 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Likewise.
258 (mi_cmd_data_write_register_values): Likewise.
259 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers): Likewise.
260 (mips_fbsd_store_inferior_registers): Likewise.
261 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Likewise.
262 (mips_fbsd_supply_gregs): Likewise.
263 (mips_fbsd_collect_fpregs): Likewise.
264 (mips_fbsd_collect_gregs): Likewise.
265 (mips_fbsd_supply_fpregset): Likewise.
266 (mips_fbsd_collect_fpregset): Likewise.
267 (mips_fbsd_supply_gregset): Likewise.
268 (mips_fbsd_collect_gregset): Likewise.
269 * mips-linux-nat.c (supply_gregset): Likewise.
270 (fill_gregset): Likewise.
271 (supply_fpregset): Likewise.
272 (fill_fpregset): Likewise.
273 * mips-linux-tdep.c (mips_supply_gregset): Likewise.
274 (mips_fill_gregset): Likewise.
275 (mips_supply_fpregset): Likewise.
276 (mips_fill_fpregset): Likewise.
277 (mips64_supply_gregset): Likewise.
278 (micromips_linux_sigframe_validate): Likewise.
279 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers): Likewise.
280 (mipsnbsd_fetch_inferior_registers): Likewise.
281 (mipsnbsd_store_inferior_registers): Likewise.
282 * mips-nbsd-tdep.c (mipsnbsd_supply_fpregset): Likewise.
283 (mipsnbsd_supply_gregset): Likewise.
284 (mipsnbsd_iterate_over_regset_sections): Likewise.
285 (mipsnbsd_supply_reg): Likewise.
286 (mipsnbsd_supply_fpreg): Likewise.
287 * mips-tdep.c (mips_in_frame_stub): Likewise.
288 (mips_dummy_id): Likewise.
289 (is_octeon_bbit_op): Likewise.
290 (micromips_bc1_pc): Likewise.
291 (extended_mips16_next_pc): Likewise.
292 (mips16_next_pc): Likewise.
293 (deal_with_atomic_sequence): Likewise.
294 * moxie-tdep.c (moxie_process_readu): Likewise.
295 * nios2-tdep.c (nios2_get_next_pc): Likewise.
296 * nto-procfs.c (procfs_store_registers): Likewise.
297 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers): Likewise.
298 (ppcfbsd_store_inferior_registers): Likewise.
299 * ppc-linux-nat.c (fetch_vsx_register): Likewise.
300 (fetch_altivec_register): Likewise.
301 (get_spe_registers): Likewise.
302 (fetch_spe_register): Likewise.
303 (fetch_altivec_registers): Likewise.
304 (fetch_all_gp_regs): Likewise.
305 (fetch_all_fp_regs): Likewise.
306 (store_vsx_register): Likewise.
307 (store_altivec_register): Likewise.
308 (set_spe_registers): Likewise.
309 (store_spe_register): Likewise.
310 (store_altivec_registers): Likewise.
311 (store_all_gp_regs): Likewise.
312 (store_all_fp_regs): Likewise.
313 * ppc-linux-tdep.c (ppc_linux_supply_gregset): Likewise.
314 (ppc_linux_collect_gregset): Likewise.
315 (ppc_canonicalize_syscall): Likewise.
316 (ppc_linux_record_signal): Likewise.
317 (ppu2spu_prev_register): Likewise.
318 * ppc-nbsd-nat.c (ppcnbsd_supply_pcb): Likewise.
319 * ppc-obsd-nat.c (ppcobsd_fetch_registers): Likewise.
320 (ppcobsd_store_registers): Likewise.
321 * ppc-ravenscar-thread.c (ppc_ravenscar_generic_fetch_registers):
322 Likewise.
323 (ppc_ravenscar_generic_store_registers): Likewise.
324 * procfs.c (procfs_fetch_registers): Likewise.
325 (procfs_store_registers): Likewise.
326 * ravenscar-thread.c (ravenscar_fetch_registers): Likewise.
327 (ravenscar_store_registers): Likewise.
328 (ravenscar_prepare_to_store): Likewise.
329 * record-btrace.c (record_btrace_fetch_registers): Likewise.
330 * record-full.c (record_full_wait_1): Likewise.
331 (record_full_registers_change): Likewise.
332 (record_full_store_registers): Likewise.
333 (record_full_core_fetch_registers): Likewise.
334 (record_full_save): Likewise.
335 (record_full_goto_insn): Likewise.
336 * regcache.c (regcache_register_size): Likewise.
337 (get_regcache_arch): Remove.
338 (regcache_read_pc): Likewise.
339 * regcache.h (get_regcache_arch): Remove.
340 * remote-sim.c (gdbsim_fetch_register): Likewise.
341 (gdbsim_store_register): Likewise.
342 * remote.c (fetch_register_using_p): Likewise.
343 (send_g_packet): Likewise.
344 (remote_prepare_to_store): Likewise.
345 (store_registers_using_G): Likewise.
346 * reverse.c (save_bookmark_command): Likewise.
347 (goto_bookmark_command): Likewise.
348 * rs6000-aix-tdep.c (branch_dest): Likewise.
349 * rs6000-nat.c (rs6000_ptrace64): Likewise.
350 (fetch_register): Likewise.
351 * rs6000-tdep.c (ppc_supply_reg): Likewise.
352 (ppc_collect_reg): Likewise.
353 (ppc_collect_gregset): Likewise.
354 (ppc_collect_fpregset): Likewise.
355 (ppc_collect_vsxregset): Likewise.
356 (ppc_collect_vrregset): Likewise.
357 (ppc_displaced_step_hw_singlestep): Likewise.
358 (rs6000_pseudo_register_read): Likewise.
359 (rs6000_pseudo_register_write): Likewise.
360 * s390-linux-nat.c (supply_gregset): Likewise.
361 (fill_gregset): Likewise.
362 (s390_linux_fetch_inferior_registers): Likewise.
363 * s390-linux-tdep.c (s390_write_pc): Likewise.
364 (s390_software_single_step): Likewise.
365 (s390_all_but_pc_registers_record): Likewise.
366 (s390_linux_syscall_record): Likewise.
367 * sentinel-frame.c (sentinel_frame_prev_arch): Likewise.
368 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers): Likewise.
369 (shnbsd_store_inferior_registers): Likewise.
370 * sh-tdep.c (sh_extract_return_value_nofpu): Likewise.
371 (sh_extract_return_value_fpu): Likewise.
372 (sh_store_return_value_nofpu): Likewise.
373 (sh_corefile_supply_regset): Likewise.
374 (sh_corefile_collect_regset): Likewise.
375 * sh64-tdep.c (sh64_extract_return_value): Likewise.
376 (sh64_store_return_value): Likewise.
377 * sparc-linux-tdep.c (sparc32_linux_collect_core_fpregset): Likewise.
378 * sparc-nat.c (sparc_fetch_inferior_registers): Likewise.
379 (sparc_store_inferior_registers): Likewise.
380 * sparc-ravenscar-thread.c (register_in_thread_descriptor_p): Likewise.
381 (sparc_ravenscar_prepare_to_store): Likewise.
382 * sparc-tdep.c (sparc32_store_arguments): Likewise.
383 (sparc_analyze_control_transfer): Likewise.
384 (sparc_step_trap): Likewise.
385 (sparc_software_single_step): Likewise.
386 (sparc32_gdbarch_init): Likewise.
387 (sparc_supply_rwindow): Likewise.
388 (sparc_collect_rwindow): Likewise.
389 * sparc64-linux-tdep.c (sparc64_linux_collect_core_fpregset): Likewise.
390 * sparc64-nbsd-nat.c (sparc64nbsd_supply_gregset): Likewise.
391 (sparc64nbsd_collect_gregset): Likewise.
392 (sparc64nbsd_supply_fpregset): Likewise.
393 (sparc64nbsd_collect_fpregset): Likewise.
394 * sparc64-tdep.c (sparc64_store_arguments): Likewise.
395 (sparc64_supply_gregset): Likewise.
396 (sparc64_collect_gregset): Likewise.
397 (sparc64_supply_fpregset): Likewise.
398 (sparc64_collect_fpregset): Likewise.
399 * spu-linux-nat.c (spu_fetch_inferior_registers): Likewise.
400 * spu-tdep.c (spu_unwind_sp): Likewise.
401 (spu2ppu_prev_register): Likewise.
402 (spu_memory_remove_breakpoint): Likewise.
403 * stack.c (return_command): Likewise.
404 * tic6x-tdep.c (tic6x_extract_signed_field): Likewise.
405 * tracefile-tfile.c (tfile_fetch_registers): Likewise.
406 * tracefile.c (trace_save_ctf): Likewise.
407 * windows-nat.c (do_windows_fetch_inferior_registers): Likewise.
408 (do_windows_store_inferior_registers): Likewise.
409 (windows_resume): Likewise.
410 * xtensa-linux-nat.c (fill_gregset): Likewise.
411 (supply_gregset_reg): Likewise.
412 * xtensa-tdep.c (xtensa_register_write_masked): Likewise.
413 (xtensa_register_read_masked): Likewise.
414 (xtensa_supply_gregset): Likewise.
415 (xtensa_extract_return_value): Likewise.
416 (xtensa_store_return_value): Likewise.
417
edd079d9
UW
4182017-10-25 Ulrich Weigand <uweigand@de.ibm.com>
419
420 * doublest.c (floatformat_from_string): New function.
421 * doublest.h (floatformat_from_string): Add prototype.
422
423 * std-operator.def (OP_DOUBLE, OP_DECFLOAT): Remove, replace by ...
424 (OP_FLOAT): ... this.
425 * expression.h: Do not include "doublest.h".
426 (union exp_element): Replace doubleconst and decfloatconst by
427 new element floatconst.
428 * ada-lang.c (resolve_subexp): Handle OP_FLOAT instead of OP_DOUBLE.
429 (ada_evaluate_subexp): Likewise.
430 * eval.c (evaluate_subexp_standard): Handle OP_FLOAT instead of
431 OP_DOUBLE and OP_DECFLOAT.
432 * expprint.c (print_subexp_standard): Likewise.
433 (dump_subexp_body_standard): Likewise.
434 * breakpoint.c (watchpoint_exp_is_const): Likewise.
435
436 * parse.c: Include "dfp.h".
437 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
438 (write_exp_elt_floatcst): New function.
439 (operator_length_standard): Handle OP_FLOAT instead of OP_DOUBLE
440 and OP_DECFLOAT.
441 (operator_check_standard): Likewise.
442 (parse_float): Do not accept suffix. Take type as input. Return bool.
443 Return target format buffer instead of host DOUBLEST.
444 Use floatformat_from_string and decimal_from_string to parse
445 either binary or decimal floating-point types.
446 (parse_c_float): Remove.
447 * parser-defs.h: Do not include "doublest.h".
448 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
449 (write_exp_elt_floatcst): Add prototype.
450 (parse_float): Update prototype.
451 (parse_c_float): Remove.
452
453 * c-exp.y: Do not include "dfp.h".
454 (typed_val_float): Use byte buffer instead of DOUBLEST.
455 (typed_val_decfloat): Remove.
456 (DECFLOAT): Remove.
457 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
458 (parse_number): Update to new parse_float interface.
459 Parse suffixes and determine type before calling parse_float.
460 Handle decimal and binary FP types the same way.
461
462 * d-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
463 (FLOAT_LITERAL): Use OP_FLOAT and write_exp_elt_floatcst.
464 (parse_number): Update to new parse_float interface.
465 Parse suffixes and determine type before calling parse_float.
466
467 * f-exp.y: Replace dval by typed_val_float.
468 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
469 (parse_number): Use parse_float instead of atof.
470
471 * go-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
472 (parse_go_float): Remove.
473 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
474 (parse_number): Call parse_float instead of parse_go_float.
475 Parse suffixes and determine type before calling parse_float.
476
477 * p-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
478 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
479 (parse_number): Update to new parse_float interface.
480 Parse suffixes and determine type before calling parse_float.
481
482 * m2-exp.y: Replace dval by byte buffer val.
483 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
484 (parse_number): Call parse_float instead of atof.
485
486 * rust-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
487 (lex_number): Call parse_float instead of strtod.
488 (ast_dliteral): Use OP_FLOAT instead of OP_DOUBLE.
489 (convert_ast_to_expression): Handle OP_FLOAT instead of OP_DOUBLE.
490 Use write_exp_elt_floatcst.
491 (unit_testing): Remove static variable.
492 (rust_type): Do not check unit_testing.
493 (rust_lex_tests): Do not set uint_testing. Set up dummy rust_parser.
494
495 * ada-exp.y (type_float, type_double): Remove.
496 (typed_val_float): Use byte buffer instead of DOUBLEST.
497 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
498 * ada-lex.l (processReal): Use parse_float instead of sscanf.
499
cc628f3d
AH
5002017-10-25 Alan Hayward <alan.hayward@arm.com>
501
502 * aarch64-tdep.h (enum aarch64_regnum): Remove.
503 * arch/aarch64.h: New file.
504
09a7c6aa
UW
5052017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
506
507 * dfp.h (decimal_from_string): Use const reference for argument.
508 * dfp.c (decimal_from_string): Likewise.
509
8ba0dd51
UW
5102017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
511
512 * i387-tdep.c (print_i387_value): Use floatformat_to_string.
513 * sh64-tdep.c (sh64_do_fp_register): Likewise.
514 * mips-tdep.c (mips_print_fp_register): Likewise.
515
16e812b2
UW
5162017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
517
518 * common/format.h (enum argclass): Replace decfloat_arg by
519 dec32float_arg, dec64float_arg, and dec128float_arg.
520 * common/format.c (parse_format_string): Update to return
521 new decimal float argument classes.
522
523 * printcmd.c (printf_decfloat): Rename to ...
524 (printf_floating): ... this. Add argclass argument, and use it
525 instead of parsing the format string again. Add support for
526 binary floating-point values, using floatformat_to_string.
527 Convert value to the target format if it doesn't already match.
528 (ui_printf): Call printf_floating instead of printf_decfloat,
529 also for double_arg / long_double_arg. Pass argclass.
530
531 * dfp.c (decimal_to_string): Add format string argument.
532 * dfp.h (decimal_to_string): Likewise.
533
534 * doublest.c (floatformat_to_string): Add format string argument.
535 * doublest.h (floatformat_to_string): Likewise.
536
fdf0cbc2
UW
5372017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
538
539 * doublest.c (floatformat_precision): New routine.
540 (floatformat_to_string): Likewise.
541 * doublest.c (floatformat_to_string): Add prototype.
542
543 * printcmd.c (print_scalar_formatted): Only call print_floating
544 on floating-point types.
545 * valprint.c: Do not include "floatformat.h".
546 (generic_val_print_decfloat): Remove.
547 (generic_val_print): Call generic_val_print_float for both
548 TYPE_CODE_FLT and TYPE_CODE_DECFLOAT.
549 (print_floating): Use floatformat_to_string. Handle decimal float.
550 (print_decimal_floating): Remove, merge into floatformat_to_string.
551 * value.h (print_decimal_floating): Remove.
552
553 * Makefile.in: Do not build doublest.c with -Wformat-nonliteral.
554
5033013f
UW
5552017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
556
557 * buildsym.c (end_symtab_get_static_block): Use std::stable_sort.
558
a664f67e
SM
5592017-10-21 Simon Marchi <simon.marchi@ericsson.com>
560
561 * memattr.h: Don't include vec.h.
562 (struct mem_attrib): Initialize fields.
563 <unknown>: New static method.
564 (struct mem_region): Add constructors, operator<, initialize
565 fields.
566 * memattr.c: Include algorithm.
567 (default_mem_attrib, unknown_mem_attrib): Remove.
568 (user_mem_region_list): New global.
569 (target_mem_region_list, mem_region_list): Change type to
570 std::vector<mem_region>.
571 (mem_use_target): Now a function.
572 (target_mem_regions_valid): Change type to bool.
573 (mem_region_lessthan, mem_region_cmp, mem_region_init): Remove.
574 (require_user_regions): Adjust.
575 (require_target_regions): Adjust.
576 (create_mem_region): Adjust.
577 (lookup_mem_region): Adjust.
578 (invalidate_target_mem_regions): Adjust.
579 (mem_clear): Rename to...
580 (user_mem_clear): ... this, and adjust.
581 (mem_command): Adjust.
582 (info_mem_command): Adjust.
583 (mem_enable, enable_mem_command, mem_disable,
584 disable_mem_command): Adjust.
585 (mem_delete): Adjust.
586 (delete_mem_command): Adjust.
587 * memory-map.h (parse_memory_map): Return an std::vector.
588 * memory-map.c (parse_memory_map): Likewise.
589 (struct memory_map_parsing_data): Add constructor.
590 <memory_map>: Point to std::vector.
591 (memory_map_start_memory): Adjust.
592 (memory_map_end_memory): Adjust.
593 (memory_map_end_property): Adjust.
594 (clear_result): Remove.
595 * remote.c (remote_memory_map): Return an std::vector.
596 * target-debug.h (target_debug_print_VEC_mem_region_s__p):
597 Remove.
598 (target_debug_print_mem_region_vector): New.
599 * target-delegates.c: Regenerate.
600 * target.h (mem_region_vector): New typedef.
601 (to_memory_map): Return mem_region_vector.
602 (target_memory_map): Return an std::vector.
603 * target.c (target_memory_map): Return an std::vector.
604 (flash_erase_command): Adjust.
605
6e17c565
SM
6062017-10-21 Simon Marchi <simon.marchi@ericsson.com>
607
608 * memory-map.c (struct memory_map_parsing_data) <property_name>:
609 Change type to std::string.
610 (memory_map_start_property): Adjust.
611 (memory_map_end_property): Adjust.
612
cfba9872
SM
6132017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
614
615 * infrun.h: Include common/byte-vector.h.
616 (struct displaced_step_closure): New struct.
617 (struct buf_displaced_step_closure): New struct.
618 * infrun.c (displaced_step_closure::~displaced_step_closure):
619 Provide default implementation.
620 (displaced_step_clear): Deallocate step closure with delete.
621 * aarch64-tdep.c (displaced_step_closure): Rename to ...
622 (aarch64_displaced_step_closure): ... this, extend
623 displaced_step_closure.
624 (aarch64_displaced_step_data) <dsc>: Change type to
625 aarch64_displaced_step_closure.
626 (aarch64_displaced_step_copy_insn): Adjust to type change, use
627 unique_ptr.
628 (aarch64_displaced_step_fixup): Add cast for displaced step
629 closure.
630 * amd64-tdep.c (displaced_step_closure): Rename to ...
631 (amd64_displaced_step_closure): ... this, extend
632 displaced_step_closure.
633 <insn_buf>: Change type to std::vector<gdb_byte>.
634 <max_len>: Remove.
635 (fixup_riprel): Change type of DSC parameter, adjust to type
636 change of insn_buf.
637 (fixup_displaced_copy): Change type of DSC parameter.
638 (amd64_displaced_step_copy_insn): Instantiate
639 amd64_displaced_step_closure.
640 (amd64_displaced_step_fixup): Add cast for closure type, adjust
641 to type change of insn_buf.
642 * arm-linux-tdep.c (arm_linux_cleanup_svc): Change type of
643 parameter DSC.
644 (arm_linux_copy_svc): Likewise.
645 (cleanup_kernel_helper_return): Likewise.
646 (arm_catch_kernel_helper_return): Likewise.
647 (arm_linux_displaced_step_copy_insn): Instantiate
648 arm_displaced_step_closure.
649 * arm-tdep.c (arm_pc_is_thumb): Add cast for closure.
650 (displaced_read_reg): Change type of parameter DSC.
651 (branch_write_pc): Likewise.
652 (load_write_pc): Likewise.
653 (alu_write_pc): Likewise.
654 (displaced_write_reg): Likewise.
655 (arm_copy_unmodified): Likewise.
656 (thumb_copy_unmodified_32bit): Likewise.
657 (thumb_copy_unmodified_16bit): Likewise.
658 (cleanup_preload): Likewise.
659 (install_preload): Likewise.
660 (arm_copy_preload): Likewise.
661 (thumb2_copy_preload): Likewise.
662 (install_preload_reg): Likewise.
663 (arm_copy_preload_reg): Likewise.
664 (cleanup_copro_load_store): Likewise.
665 (install_copro_load_store): Likewise.
666 (arm_copy_copro_load_store) Likewise.
667 (thumb2_copy_copro_load_store): Likewise.
668 (cleanup_branch): Likewise.
669 (install_b_bl_blx): Likewise.
670 (arm_copy_b_bl_blx): Likewise.
671 (thumb2_copy_b_bl_blx): Likewise.
672 (thumb_copy_b): Likewise.
673 (install_bx_blx_reg): Likewise.
674 (arm_copy_bx_blx_reg): Likewise.
675 (thumb_copy_bx_blx_reg): Likewise.
676 (cleanup_alu_imm): Likewise.
677 (arm_copy_alu_imm): Likewise.
678 (thumb2_copy_alu_imm): Likewise.
679 (cleanup_alu_reg): Likewise.
680 (install_alu_reg): Likewise.
681 (arm_copy_alu_reg): Likewise.
682 (thumb_copy_alu_reg): Likewise.
683 (cleanup_alu_shifted_reg): Likewise.
684 (install_alu_shifted_reg): Likewise.
685 (arm_copy_alu_shifted_reg): Likewise.
686 (cleanup_load): Likewise.
687 (cleanup_store): Likewise.
688 (arm_copy_extra_ld_st): Likewise.
689 (install_load_store): Likewise.
690 (thumb2_copy_load_literal): Likewise.
691 (thumb2_copy_load_reg_imm): Likewise.
692 (arm_copy_ldr_str_ldrb_strb): Likewise.
693 (cleanup_block_load_all): Likewise.
694 (cleanup_block_store_pc): Likewise.
695 (cleanup_block_load_pc): Likewise.
696 (arm_copy_block_xfer): Likewise.
697 (thumb2_copy_block_xfer): Likewise.
698 (cleanup_svc): Likewise.
699 (install_svc): Likewise.
700 (arm_copy_svc): Likewise.
701 (thumb_copy_svc): Likewise.
702 (arm_copy_undef): Likewise.
703 (thumb_32bit_copy_undef): Likewise.
704 (arm_copy_unpred): Likewise.
705 (arm_decode_misc_memhint_neon): Likewise.
706 (arm_decode_unconditional): Likewise.
707 (arm_decode_miscellaneous): Likewise.
708 (arm_decode_dp_misc): Likewise.
709 (arm_decode_ld_st_word_ubyte): Likewise.
710 (arm_decode_media): Likewise.
711 (arm_decode_b_bl_ldmstm): Likewise.
712 (arm_decode_ext_reg_ld_st): Likewise.
713 (thumb2_decode_dp_shift_reg): Likewise.
714 (thumb2_decode_ext_reg_ld_st): Likewise.
715 (arm_decode_svc_copro): Likewise.
716 (thumb2_decode_svc_copro): Likewise.
717 (install_pc_relative): Likewise.
718 (thumb_copy_pc_relative_16bit): Likewise.
719 (thumb_decode_pc_relative_16bit): Likewise.
720 (thumb_copy_pc_relative_32bit): Likewise.
721 (thumb_copy_16bit_ldr_literal): Likewise.
722 (thumb_copy_cbnz_cbz): Likewise.
723 (thumb2_copy_table_branch): Likewise.
724 (cleanup_pop_pc_16bit_all): Likewise.
725 (thumb_copy_pop_pc_16bit): Likewise.
726 (thumb_process_displaced_16bit_insn): Likewise.
727 (decode_thumb_32bit_ld_mem_hints): Likewise.
728 (thumb_process_displaced_32bit_insn): Likewise.
729 (thumb_process_displaced_insn): Likewise.
730 (arm_process_displaced_insn): Likewise.
731 (arm_displaced_init_closure): Likewise.
732 (arm_displaced_step_fixup): Add cast for closure.
733 * arm-tdep.h: Include infrun.h.
734 (displaced_step_closure): Rename to ...
735 (arm_displaced_step_closure): ... this, extend
736 displaced_step_closure.
737 <u::svc::copy_svc_os>: Change type of parameter DSC.
738 <cleanup>: Likewise.
739 (arm_process_displaced_insn): Likewise.
740 (arm_displaced_init_closure): Likewise.
741 (displaced_read_reg): Likewise.
742 (displaced_write_reg): Likewise.
743 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
744 Adjust.
745 * i386-tdep.h: Include infrun.h.
746 (i386_displaced_step_closure): New typedef.
747 * i386-tdep.c (i386_displaced_step_copy_insn): Use
748 i386_displaced_step_closure.
749 (i386_displaced_step_fixup): Adjust.
750 * rs6000-tdep.c (ppc_displaced_step_closure): New typedef.
751 (ppc_displaced_step_copy_insn): Use ppc_displaced_step_closure
752 and unique_ptr.
753 (ppc_displaced_step_fixup): Adjust.
754 * s390-linux-tdep.c (s390_displaced_step_closure): New typedef.
755 (s390_displaced_step_copy_insn): Use s390_displaced_step_closure
756 and unique_ptr.
757 (s390_displaced_step_fixup): Adjust.
758
b392b304
SM
7592017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
760
761 * interps.h (interp_resume, interp_suspend, interp_set_temp):
762 Remove declarations.
763
d5833c62
TT
7642017-10-20 Tom Tromey <tom@tromey.com>
765
766 * gdb_bfd.c (struct gdb_bfd_data) <included_bfds>: Now a
767 std::vector.
768 (gdb_bfd_record_inclusion): Update.
769 (bfdp): Remove typedef.
770
06d5bbc8
TT
7712017-10-20 Tom Tromey <tom@tromey.com>
772
773 * gdb_bfd.c (gdb_bfd_ref): Use new.
774 (struct gdb_bfd_data): Add constructor, destructor, and member
775 initializers.
776 (gdb_bfd_unref): Use delete.
777
2712ce2e
TT
7782017-10-20 Tom Tromey <tom@tromey.com>
779
780 * exec.c (exec_file_attach): Use new_bfd_ref.
781 * symfile-mem.c (symbol_file_add_from_memory): Use new_bfd_ref.
782 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
783 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_fdopenr): Use
784 new_bfd_ref.
785 * gdb_bfd.h (new_bfd_ref): New function.
786
fcc8fb2f
PA
7872017-10-20 Pedro Alves <palves@redhat.com>
788
789 * main.c (captured_command_loop): Add attribute noinline.
790
4c2287b0
SM
7912017-10-19 Simon Marchi <simon.marchi@ericsson.com>
792
793 * interps.c (struct interp_factory): Add constructor.
794 (interp_factory_p): Remove typedef.
795 (DEF_VEC_P(interp_factory_p)): Remove.
796 (interpreter_factories): Change type to std::vector.
797 (interp_factory_register): Adjust.
798 (interp_lookup): Adjust.
799 (interpreter_completer): Adjust.
800
3d415c26
TT
8012017-10-19 Tom Tromey <tom@tromey.com>
802
803 * break-catch-syscall.c (catch_syscall_completer): Use
804 std::string, gdb::unique_xmalloc_ptr.
805
395423c4
TT
8062017-10-19 Tom Tromey <tom@tromey.com>
807
808 * infcall.c (call_function_by_hand_dummy): Use std::string.
809
54f70bc1
TT
8102017-10-19 Tom Tromey <tom@tromey.com>
811
812 * mi/mi-main.c (mi_cmd_execute): Update.
813 * top.h (prepare_execute_command): Return scoped_value_mark.
814 * value.h (class scoped_value_mark): Use DISABLE_COPY_AND_ASSIGN.
815 Add move constructor.
816 * top.c (prepare_execute_command): Return scoped_value_mark.
817 (execute_command): Update.
818
63929e84
PA
8192017-10-19 Pedro Alves <palves@redhat.com>
820
821 * xml-support.c (xml_fetch_content_from_file): Check fread's
822 return.
823
a75868f5
PA
8242017-10-19 Pedro Alves <palves@redhat.com>
825
826 * ser-base.c (ser_base_read_error_fd): Delete the file handler if
827 async.
828 (handle_error_fd): New function.
829 (ser_base_async): Add/delete an event loop file handler for
830 error_fd.
831
2edf834e
PA
8322017-10-19 Pedro Alves <palves@redhat.com>
833
834 * xml-support.c (xml_fetch_content_from_file): Don't read in
835 chunks. Instead use fseek to determine the file's size, and read
836 it in one go.
837
c8ba13ad
KS
8382017-11-18 Keith Seitz <keiths@redhat.com>
839
840 * c-exp.y (oper): Canonicalize conversion operators of user-defined
841 types.
842 Add whitespace to front of type name.
843
37534686
KS
8442017-10-18 Keith Seitz <keiths@redhat.com>
845
846 * dwarf2read.c (dwarf2_add_typedef): Issue a complaint on unhandled
847 DW_AT_accessibility.
848
28c7c158
YQ
8492017-10-18 Yao Qi <yao.qi@linaro.org>
850
851 * features/tic6x-c62x-linux.c: Remove.
852
30f0b101
TT
8532017-10-17 Tom Tromey <tom@tromey.com>
854
855 * disasm.c (do_mixed_source_and_assembly_deprecated): Use
856 gdb::optional, ui_out_emit_list, ui_out_emit_tuple.
857 (do_mixed_source_and_assembly): Likewise.
858
57e12da9
TT
8592017-10-17 Tom Tromey <tom@tromey.com>
860
861 * regcache.c (regcache::xfer_part): Remove assertion.
862
7b700999
PA
8632017-10-17 Pedro Alves <palves@redhat.com>
864
865 * xml-support.c (xml_fetch_content_from_file): Call
866 unique_ptr::release() instead unique_ptr::get() when passing
867 through xrealloc.
868
d3037ba6
YQ
8692017-10-17 Yao Qi <yao.qi@linaro.org>
870
871 * regcache.c (regcache::xfer_part): Remove parameters read and
872 write, add parameter is_raw. All callers are updated.
873
83d5a34d
KS
8742017-10-16 Keith Seitz <keiths@redhat.com>
875
876 * c-typeprint.c (enum access_specifier): Moved here from
877 c_type_print_base.
878 (output_access_specifier): New function.
879 (c_type_print_base): Consider typedefs when assessing
880 whether access labels are needed.
881 Use output_access_specifier as needed.
882 Output access specifier for typedefs, if needed.
883 * dwarf2read.c (dwarf2_add_typedef): Record DW_AT_accessibility.
884 * gdbtypes.h (struct typedef_field) <is_protected, is_private>: New
885 fields.
886 (TYPE_TYPEDEF_FIELD_PROTECTED, TYPE_TYPEDEF_FIELD_PRIVATE): New
887 accessor macros.
888
87028b87
TT
8892017-10-16 Tom Tromey <tom@tromey.com>
890
891 * linux-tdep.c (linux_info_proc, linux_find_memory_regions_full)
892 (linux_fill_prpsinfo, linux_vsyscall_range_raw): Update.
893 * target.c (target_fileio_read_stralloc): Update.
894 * sparc64-tdep.c (adi_is_addr_mapped): Update.
895 * target.h (target_fileio_read_stralloc): Return
896 unique_xmalloc_ptr.
897
b7b030ad
TT
8982017-10-16 Tom Tromey <tom@tromey.com>
899
900 * xml-syscall.c (xml_init_syscalls_info): Update.
901 * xml-support.c (xinclude_start_include): Update.
902 (xml_fetch_content_from_file): Return unique_xmalloc_ptr.
903 * xml-support.h (xml_fetch_another): Return unique_xmalloc_ptr.
904 (xml_fetch_content_from_file): Likewise.
905 * osdata.c (get_osdata): Update.
906 * target.h (target_read_stralloc, target_get_osdata): Return
907 unique_xmalloc_ptr.
908 * solib-aix.c (solib_aix_get_library_list): Update.
909 * solib-target.c (solib_target_current_sos): Update.
910 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Update.
911 * xml-tdesc.c (fetch_available_features_from_target): Update.
912 (target_fetch_description_xml): Update.
913 (file_read_description_xml): Update.
914 * remote.c (remote_get_threads_with_qxfer, remote_memory_map)
915 (remote_traceframe_info, btrace_read_config, remote_read_btrace)
916 (remote_pid_to_exec_file): Update.
917 * target.c (target_read_stralloc): Return unique_xmalloc_ptr.
918 (target_get_osdata): Likewise.
919
b80406ac
TT
9202017-10-16 Tom Tromey <tom@tromey.com>
921
922 * remote.c (remote_register_number_and_offset): Use std::vector.
923 (remote_set_syscall_catchpoint): Use gdb::unique_xmalloc_ptr.
924 (putpkt_binary): Use gdb::def_vector.
925 (compare_sections_command): Use gdb::byte_vector.
926
a90ecff8
TT
9272017-10-16 Tom Tromey <tom@tromey.com>
928
929 * ppc-linux-nat.c (hwdebug_insert_point): Use
930 gdb::unique_xmalloc_ptr, XDUP.
931
2dc0e219
TT
9322017-10-16 Tom Tromey <tom@tromey.com>
933
934 * probe.c (parse_probes): Use std::string.
935 (info_probes_for_ops, enable_probes_command)
936 (disable_probes_command): Remove cleanups.
937
b05628f0
TT
9382017-10-16 Tom Tromey <tom@tromey.com>
939
940 * buildsym.c (block_compar): Remove.
941 (end_symtab_get_static_block): Use std::vector.
942
a79b1bc6
SM
9432017-10-16 Simon Marchi <simon.marchi@ericsson.com>
944
945 * memrange.h (struct mem_range): Define operator< and operator==.
946 (mem_range_s): Remove.
947 (DEF_VEC_O (mem_range_s)): Remove.
948 (normalize_mem_ranges): Change parameter type to std::vector.
949 * memrange.c (compare_mem_ranges): Remove.
950 (normalize_mem_ranges): Change parameter type to std::vector,
951 adjust to vector change.
952 * exec.c (section_table_available_memory): Return vector, remove
953 parameter.
954 (section_table_read_available_memory): Adjust to std::vector
955 change.
956 * remote.c (remote_read_bytes): Adjust to std::vector
957 change.
958 * tracepoint.h (traceframe_available_memory): Change parameter
959 type to std::vector.
960 * tracepoint.c (traceframe_available_memory): Change parameter
961 type to std::vector, adjust.
962 * gdb/mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to
963 std::vector change.
964 * gdb/Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
965 unittests/memrange-selftests.c.
966 (SUBDIR_UNITTESTS_OBS): Add memrange-selftests.o.
967 * gdb/unittests/memrange-selftests.c: New file.
968
63f0e930
PA
9692017-10-16 Pedro Alves <palves@redhat.com>
970
971 * elfread.c (probe_key_free): Rename range-for variable.
972 * probe.c (parse_probes_in_pspace, find_probes_in_objfile)
973 (find_probe_by_pc, collect_probes): Rename range-for variable.
974
c40c7bfc
YQ
9752017-10-16 Yao Qi <yao.qi@linaro.org>
976
977 * features/Makefile (XMLTOC): Remove tic6x-*.xml.
978 * features/tic6x-c62x.c: Remove.
979 * features/tic6x-c64x-linux.c: Remove.
980 * features/tic6x-c64x.c: Remove.
981 * features/tic6x-c64xp-linux.c: Remove.
982 * features/tic6x-c64xp.c: Remove.
983 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Don't call
984 initialize_tdesc_tic6x_*_linux functions.
985 * tic6x-tdep.c (_initialize_tic6x_tdep): Don't call
986 initialize_tdesc_tic6x_* functions.
987
df27ae6a
YQ
9882017-10-16 Yao Qi <yao.qi@linaro.org>
989
990 * features/Makefile (WHICH): Remove tic6x-c64xp, tic6x-c64x
991 tic6x-c62x.
992 * regformats/tic6x-c62x.dat: Remove.
993 * regformats/tic6x-c64x.dat: Remove.
994 * regformats/tic6x-c64xp.dat: Remove.
995
86766165
SM
9962017-10-15 Simon Marchi <simon.marchi@ericsson.com>
997
998 * tracepoint.c (parse_traceframe_info): Return a unique_ptr
999 (the !HAVE_LIBEXPAT version).
1000
824dfcc3
SM
10012017-10-14 Simon Marchi <simon.marchi@ericsson.com>
1002
1003 * nat/linux-osdata.c (struct pid_pgid_entry) <operator<>: Make
1004 const.
1005
2098b393
SM
10062017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1007
1008 * target.h: Include tracepoint.h.
1009 (enum trace_find_type): Move to tracepoint.h.
1010 (struct target_ops) <to_traceframe_info>: Return a unique ptr.
1011 * tracepoint.h: Don't include target.h
1012 (enum trace_find_type): Move from target.h.
1013 (parse_traceframe_info): Return a unique ptr.
1014 * tracepoint.c (current_traceframe_info): Change type to unique
1015 ptr.
1016 (free_traceframe_info): Remove.
1017 (clear_traceframe_info): Don't manually free
1018 current_traceframe_info.
1019 (free_result): Remove.
1020 (parse_traceframe_info): Return a unique ptr.
1021 (get_traceframe_info): Adjust to unique ptr.
1022 * ctf.c (ctf_traceframe_info): Return a unique ptr.
1023 * remote.c (remote_traceframe_info): Return a unique ptr.
1024 * tracefile-tfile.c (tfile_traceframe_info): Return a unique
1025 ptr.
1026 * target-debug.h (target_debug_print_traceframe_info_up): New
1027 macro.
1028 * target-delegates.c: Regenerate.
1029
4cdd21a8
SM
10302017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1031
1032 * memrange.h (struct mem_range): Add constructors.
1033 * tracepoint.h (struct traceframe_info) <memory>: Change type to
1034 std::vector<mem_range>.
1035 * tracepoint.c (free_traceframe_info): Don't manually free
1036 vector.
1037 (traceframe_info_start_memory): Adjust to vector change.
1038 (traceframe_available_memory): Likewise.
1039 * tracefile-tfile.c (build_traceframe_info): Likewise.
1040 * ctf.c (ctf_traceframe_info): Likewise.
1041
d0d292a2
SM
10422017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1043
1044 * tracepoint.h (struct traceframe_info) <tvars>: Change type to
1045 std::vector<int>.
1046 * tracepoint.c (free_traceframe_info): Deallocate with delete.
1047 (traceframe_info_start_tvar): Adjust to vector change.
1048 (parse_traceframe_info): Allocate with new.
1049 * ctf.c (ctf_traceframe_info): Allocate with new, adjust to
1050 vector change.
1051 * tracefile-tfile.c (build_traceframe_info): Adjust to vector
1052 change.
1053 tfile_traceframe_info): Allocate with new.
1054 * mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to vector
1055 change.
1056
8d3c73ef
SM
10572017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1058
1059 * tracepoint.c (traceframe_info): Rename to...
1060 (current_traceframe_info): ...this.
1061 (clear_traceframe_info): Adjust.
1062 (get_traceframe_info): Adjust.
1063
b129dcac
SM
10642017-10-14 Simon Marchi <simon.marchi@ericsson.com>
1065
1066 * nat/linux-osdata.c: Include algorithm.
1067 (compare_processes): Remove.
1068 (struct pid_pgid_entry): New struct.
1069 (linux_xfer_osdata_processgroups): Use std::vector instead of
1070 XNEWVEC.
1071
af5bf4ad
SM
10722017-10-14 Simon Marchi <simon.marchi@ericsson.com>
1073
1074 * objfiles.h: Don't include symfile.h.
1075 (struct partial_symbol): Remove forward-declaration.
1076 (struct objfile) <global_psymbols, static_psymbols>: Change type
1077 to std::vector<partial_symbol *>.
1078 * objfiles.c (objfile::objfile): Don't memset those fields.
1079 (objfile::~objfile): Don't free those fields.
1080 * psympriv.h (struct psymbol_allocation_list): Remove
1081 forward-declaration.
1082 (add_psymbol_to_list): Change psymbol_allocation_list parameter
1083 to std::vector.
1084 (start_psymtab_common): Change parameters to std::vector.
1085 * psymtab.c: Include algorithm.
1086 (require_partial_symbols): Call shrink_to_fit.
1087 (find_pc_sect_psymbol): Adjust to vector change.
1088 (match_partial_symbol): Likewise.
1089 (lookup_partial_symbol): Likewise.
1090 (psym_relocate): Likewise.
1091 (dump_psymtab): Likewise.
1092 (recursively_search_psymtabs): Likewise.
1093 (compare_psymbols): Remove.
1094 (sort_pst_symbols): Adjust to vector change.
1095 (start_psymtab_common): Likewise.
1096 (end_psymtab_common): Likewise.
1097 (psymbol_bcache_full): De-constify return value.
1098 (add_psymbol_to_bcache): Likewise.
1099 (extend_psymbol_list): Remove.
1100 (append_psymbol_to_list): Adjust to vector change.
1101 (add_psymbol_to_list): Likewise.
1102 (init_psymbol_list): Likewise.
1103 (maintenance_info_psymtabs): Likewise.
1104 (maintenance_check_psymtabs): Likewise.
1105 * symfile.h (struct psymbol_allocation_list): Remove.
1106 * symfile.c (reread_symbols): Adjust to vector change.
1107 * dbxread.c (start_psymtab): Change type of parameters.
1108 (dbx_symfile_read): Adjust to vector change.
1109 (read_dbx_symtab): Likewise.
1110 (start_psymtab): Change type of parameters.
1111 * dwarf2read.c (dwarf2_build_psymtabs): Adjust to vector change.
1112 (create_partial_symtab): Likewise.
1113 (add_partial_symbol): Likewise.
1114 (write_one_signatured_type): Likewise.
1115 (recursively_write_psymbols): Likewise.
1116 * mdebugread.c (parse_partial_symbols): Likewise.
1117 * xcoffread.c (xcoff_start_psymtab): Change type of parameters.
1118 (scan_xcoff_symtab): Adjust to vector change.
1119 (xcoff_initial_scan): Likewise.
1120
3ec5942f
SM
11212017-10-13 Simon Marchi <simon.marchi@ericsson.com>
1122
1123 * ada-typeprint.c (print_dynamic_range_bound): Use std::string.
1124
2399fe6a
YQ
11252017-10-13 Yao Qi <yao.qi@linaro.org>
1126
1127 * features/Makefile: Remove tic6x-*-expedite, add tic6x-expedite.
1128 Remove s390x-*-expedite, add s390x-expedite.
1129
4bf3f4a8
YQ
11302017-10-13 Yao Qi <yao.qi@linaro.org>
1131
1132 * features/s390-gs-linux64.c: Regenerated.
1133 * features/s390x-gs-linux64.c: Regenerated.
1134
9e86da07
TT
11352017-10-13 Tom Tromey <tom@tromey.com>
1136
1137 * compile/compile-object-run.c (do_module_cleanup): Use delete.
1138 * solib.c (update_solib_list, reload_shared_libraries_1): Use
1139 delete.
1140 * symfile.c (symbol_file_add_with_addrs): Use new.
1141 (symbol_file_add_separate): Update comment.
1142 (syms_from_objfile_1, remove_symbol_file_command): Use delete.
1143 * jit.c (jit_object_close_impl): Use new.
1144 (jit_unregister_code): Use delete.
1145 * objfiles.c (objfile::objfile): Rename from allocate_objfile.
1146 (~objfile): Rename from free_objfile.
1147 (free_objfile_separate_debug, do_free_objfile_cleanup)
1148 (free_all_objfiles, objfile_purge_solibs): Use delete.
1149 * objfiles.h (struct objfile): Add constructor and destructor.
1150 Use DISABLE_COPY_AND_ASSIGN. Add initializers to data members.
1151 (allocate_objfile, free_objfile): Don't declare.
1152 (struct objstats): Add initializers.
1153
c2508e90
SM
11542017-10-12 Simon Marchi <simon.marchi@ericsson.com>
1155
1156 * arch-utils.h (simple_displaced_step_copy_insn): Remove.
1157 * arch-utils.c (simple_displaced_step_copy_insn): Remove.
1158 * gdbarch.sh (displaced_step_copy_insn): Adjust comment.
1159 * gdbarch.h: Regenerate.
1160 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
1161 Adjust comment.
1162 * i386-tdep.c (i386_displaced_step_copy_insn): Adjust comment.
1163 (i386_displaced_step_fixup): Adjust comment.
1164 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Adjust comment.
1165
a900ff72
TT
11662017-10-12 Tom Tromey <tom@tromey.com>
1167
1168 * prologue-value.h (pv_area::store_would_trash): Return bool.
1169 (pv_area::find_reg): Likewise.
1170 * prologue-value.c (pv_area::store_would_trash): Return bool.
1171 (pv_area::find_reg): Likewise.
1172
f7b7ed97
TT
11732017-10-12 Tom Tromey <tom@tromey.com>
1174
1175 * s390-linux-tdep.c (s390_store, s390_load)
1176 (s390_check_for_saved, s390_analyze_prologue): Update.
1177 * rx-tdep.c (check_for_saved, rx_analyze_prologue): Update.
1178 * rl78-tdep.c (rl78_analyze_prologue, check_for_saved): Update.
1179 * prologue-value.h (class pv_area): Move from prologue-value.c.
1180 Change names of members. Add constructor, destructor, member
1181 functions.
1182 (make_pv_area, free_pv_area, make_cleanup_free_pv_area)
1183 (pv_area_store, pv_area_fetch, pv_area_store_would_trash)
1184 (pv_area_fetch, pv_area_scan): Don't declare.
1185 * prologue-value.c (struct pv_area::area_entry): Now member of
1186 pv_area.
1187 (struct pv_area): Move to prologue-value.h.
1188 (pv_area::pv_area): Rename from make_pv_area.
1189 (pv_area::~pv_area): Rename from free_pv_area.
1190 (do_free_pv_area_cleanup, make_cleanup_free_pv_area): Remove.
1191 (clear_entries, find_entry, overlaps, store_would_trash, store)
1192 (fetch, find_reg, scan): Now member of pv_area.
1193 Remove "area" argument. Update.
1194 * msp430-tdep.c (check_for_saved, msp430_analyze_prologue):
1195 Update.
1196 * mn10300-tdep.c (push_reg, check_for_saved)
1197 (mn10300_analyze_prologue): Update.
1198 * mep-tdep.c (is_arg_spill, check_for_saved)
1199 (mep_analyze_prologue): Update.
1200 * m32c-tdep.c (m32c_pv_push, m32c_srcdest_fetch)
1201 (m32c_srcdest_store, m32c_pv_enter, m32c_is_arg_spill)
1202 (m32c_is_struct_return, m32c_analyze_prologue): Update.
1203 * arm-tdep.c (thumb_analyze_prologue, arm_analyze_prologue):
1204 Update.
1205 * arc-tdep.c (arc_is_in_prologue, arc_analyze_prologue): Update.
1206 * aarch64-tdep.c (aarch64_analyze_prologue): Update.
1207
466eecee
SM
12082017-10-12 Simon Marchi <simon.marchi@ericsson.com>
1209
1210 * linux-nat.h (linux_nat_set_delete_thread): New declaration.
1211 * linux-nat.c (linux_nat_delete_thread): New variable.
1212 (lwp_free): Invoke linux_nat_delete_thread if set.
1213 (linux_nat_set_delete_thread): New function.
1214 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Assign
1215 thread delete callback.
1216 * arm-linux-nat.c (arm_linux_delete_thread): New function.
1217 (_initialize_arm_linux_nat): Assign thread delete callback.
1218 * s390-linux-nat.c (s390_delete_thread): New function.
1219 (_initialize_s390_nat): Assign thread delete callback.
1220 * x86-linux-nat.c (x86_linux_add_target): Likewise.
1221 * nat/aarch64-linux.c (aarch64_linux_delete_thread): New
1222 function.
1223 * nat/aarch64-linux.h (aarch64_linux_delete_thread): New
1224 declaration.
1225 * nat/x86-linux.c (x86_linux_delete_thread): New function.
1226 * nat/x86-linux.h (x86_linux_delete_thread): New declaration.
1227
f71c8822
TT
12282017-10-09 Tom Tromey <tom@tromey.com>
1229
1230 * tui/tui-win.c (tui_set_win_height, parse_scrolling_args): Use
1231 std::string.
1232 * tui/tui-layout.c (enum tui_status): Use std::string.
1233
981a3fb3
TT
12342017-10-11 Tom Tromey <tom@tromey.com>
1235
1236 * gdbthread.h (thread_command): Constify.
1237 * inferior.h (detach_command): Constify.
1238 * top.h (set_history, show_history): Constify.
1239 * arm-tdep.c (set_arm_command, show_arm_command): Constify.
1240 * serial.c (serial_set_cmd, serial_show_cmd): Constify.
1241 * bsd-kvm.c (bsd_kvm_cmd): Constify.
1242 * printcmd.c (set_command): Constify.
1243 (non_const_set_command): New function.
1244 * dcache.c (set_dcache_command, show_dcache_command): Constify.
1245 * breakpoint.c (enable_command, disable_command, delete_command)
1246 (catch_command, tcatch_command, set_breakpoint_cmd)
1247 (show_breakpoint_cmd): Constify.
1248 * macrocmd.c (macro_command): Constify.
1249 * infcmd.c (unset_command, kill_command, detach_command)
1250 (info_proc_cmd): Constify.
1251 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Constify.
1252 * auto-load.c (show_auto_load_cmd, set_auto_load_cmd)
1253 (info_auto_load_cmd): Constify.
1254 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
1255 (unset_tdesc_cmd): Constify.
1256 * ada-lang.c (set_ada_command, show_ada_command)
1257 (maint_set_ada_cmd, maint_show_ada_cmd): Constify.
1258 * guile/guile.c (set_guile_command, show_guile_command)
1259 (info_guile_command): Constify.
1260 * tui/tui-win.c (tui_command, set_tui_cmd, show_tui_cmd):
1261 Constify.
1262 * skip.c (skip_command): Constify.
1263 * compile/compile.c (_initialize_compile): Constify.
1264 * dwarf2read.c (set_dwarf_cmd, show_dwarf_cmd): Constify.
1265 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
1266 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
1267 (maint_btrace_pt_show_cmd): Constify.
1268 * remote.c (set_remote_cmd, show_remote_cmd, remote_command):
1269 Constify.
1270 * python/python.c (user_show_python, user_set_python): Constify.
1271 * mips-tdep.c (set_mips_command, show_mips_command)
1272 (set_mipsfpu_command): Constify.
1273 * record-btrace.c (cmd_record_btrace_start)
1274 (cmd_set_record_btrace, cmd_show_record_btrace)
1275 (cmd_set_record_btrace_bts, cmd_show_record_btrace_bts)
1276 (cmd_set_record_btrace_pt, cmd_show_record_btrace_pt): Constify.
1277 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command):
1278 Constify.
1279 * symfile.c (overlay_command): Constify.
1280 * spu-tdep.c (set_spu_command, show_spu_command): Constify.
1281 * cli/cli-logging.c (set_logging_command, show_logging_command):
1282 Constify.
1283 * cli/cli-dump.c (dump_command, append_command)
1284 (srec_dump_command, ihex_dump_command, verilog_dump_command)
1285 (tekhex_dump_command, binary_dump_command)
1286 (binary_append_command): Constify.
1287 * cli/cli-decode.c (struct cmd_list_element): Change type of
1288 "fun".
1289 * cli/cli-cmds.c (info_command, show_command, set_debug)
1290 (show_debug): Constify.
1291 (show_command): Add non-const overload.
1292 * top.c (set_history, show_history): Constify.
1293 * sh-tdep.c (set_sh_command, show_sh_command): Constify.
1294 * command.h (add_prefix_cmd): Accept a cmd_const_cfunc_ftype.
1295 * target.c (target_command): Constify.
1296 * sparc64-tdep.c (info_adi_command): Constify.
1297 * record-full.c (cmd_record_full_start): Constify.
1298 (set_record_full_command): Constify. Fix typo.
1299 (show_record_full_command): Constify.
1300 * thread.c (thread_command, thread_apply_command): Constify.
1301 * memattr.c (dummy_cmd): Constify.
1302 * value.c (function_command): Constify.
1303 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Constify.
1304 * probe.c (info_probes_command): Constify.
1305 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Constify.
1306 * gnu-nat.c (set_task_cmd, show_task_cmd, set_thread_cmd)
1307 (show_thread_cmd, set_thread_default_cmd)
1308 (show_thread_default_cmd): Constify.
1309 (check_empty): Constify.
1310 * tracepoint.c (tfind_command): Constify.
1311 * cp-support.c (maint_cplus_command): Constify.
1312 * windows-tdep.c (info_w32_command): Constify.
1313 * record.c (cmd_record_start, set_record_command)
1314 (show_record_command, info_record_command, cmd_record_goto):
1315 Constify.
1316 * ravenscar-thread.c (set_ravenscar_command)
1317 (show_ravenscar_command): Constify.
1318 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
1319 Constify.
1320 (add_internal_problem_command): Remove casts.
1321 * arc-tdep.c (maintenance_print_arc_command): Constify.
1322 * valprint.c (set_print, show_print, set_print_raw)
1323 (show_print_raw): Constify.
1324 * maint.c (maintenance_command, maintenance_info_command)
1325 (maintenance_print_command, maintenance_set_cmd)
1326 (maintenance_show_cmd, set_per_command_cmd)
1327 (show_per_command_cmd, maintenance_check_command): Constify.
1328 * language.c (set_check, show_check): Constify.
1329 * typeprint.c (show_print_type, set_print_type): Constify.
1330 * go32-nat.c (go32_info_dos_command): Constify.
1331
fdf44873
TT
13322017-10-11 Tom Tromey <tom@tromey.com>
1333
1334 * breakpoint.c (prepare_re_set_context): Remove.
1335 (breakpoint_re_set_one): Update. Don't use cleanups.
1336 (breakpoint_re_set): Use scoped_restore, std::string, and
1337 scoped_restore_current_language.
1338
81b1e71c
TT
13392017-10-11 Tom Tromey <tom@tromey.com>
1340
1341 * breakpoint.c (commands_command_1): Use std::string.
1342 (cleanup_executing_breakpoints): Remove.
1343 (bpstat_do_actions_1): Use scoped_restore.
1344 (bpstat_check_watchpoint): Use std::string.
1345 (decode_static_tracepoint_spec): Likewise.
1346 (break_range_command): Likewise.
1347 (watch_command_1): Likewise.
1348 (compare_breakpoints): Change argument types.
1349 (clear_command): Use std::vector.
1350 (cleanup_executing_breakpoints): Remove.
1351 (update_global_location_list): Use unique_xmalloc_ptr.
1352 (strace_command): Remove unused declaration.
1353
4f9d9906
JB
13542017-10-11 John Baldwin <jhb@FreeBSD.org>
1355
1356 * Makefile.in (ALLDEPFILES): Add arm-fbsd-nat.c.
1357 * NEWS: Mention new FreeBSD/arm native configuration.
1358 * configure.host: Add arm*-*-freebsd*.
1359 * configure.nat: Likewise.
1360 * arm-fbsd-nat.c: New file.
1361
7176dfd2
JB
13622017-10-11 John Baldwin <jhb@FreeBSD.org>
1363
1364 * Makefile.in (ALL_TARGET_OBS): Add arm-fbsd-tdep.o.
1365 (ALLDEPFILES): Add arm-fbsd-tdep.c.
1366 * NEWS: Mention new FreeBSD/arm target.
1367 * configure.tgt: Add arm*-*-freebsd*.
1368 * arm-fbsd-tdep.c: New file.
1369 * arm-fbsd-tdep.h: New file.
1370
fe220226
MR
13712017-10-11 Maciej W. Rozycki <macro@imgtec.com>
1372
1373 * linux-tdep.c (linux_make_corefile_notes): Remove call to
1374 `gdbarch_elfcore_write_linux_prpsinfo'.
1375 * gdbarch.sh (elfcore_write_linux_prpsinfo): Remove architecture
1376 method.
1377 (elf_internal_linux_prpsinfo): Remove declaration.
1378 * gdbarch.h: Regenerate.
1379 * gdbarch.c: Regenerate.
1380
a2f63b2e
MR
13812017-10-11 Maciej W. Rozycki <macro@imgtec.com>
1382
1383 * ppc-linux-tdep.c (ppc_linux_init_abi): Remove call to
1384 `set_gdbarch_elfcore_write_linux_prpsinfo'.
1385
458ca1d0
PA
13862017-10-11 Pedro Alves <palves@redhat.com>
1387
1388 * breakpoint.c (reattach_breakpoints): Delete.
1389 * breakpoint.h (reattach_breakpoints): Delete.
1390
905014d7
SM
13912017-10-11 Simon Marchi <simon.marchi@ericsson.com>
1392
1393 * symfile.c (registered_sym_fns): Make struct, not typedef.
1394 (DEF_VEC_O (registered_sym_fns)): Remove.
1395 (symtab_fns): Change type to std::vector.
1396 (add_symtab_fns): Adjust.
1397 (find_sym_fns): Adjust.
1398
56d704da
AK
13992017-10-11 Anton Kolesov <Anton.Kolesov@synopsys.com>
1400
1401 * arc-tdep.c (arc_gdbarch_init): Pass proper cpu value to disassembler.
1402 * arc-tdep.h (arc_arch_is_em): New function.
1403 (arc_arch_is_hs): Likewise.
1404
7fa29be9
EB
14052017-10-11 Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
1406
1407 * macrotab.h (macro_lookup_inclusion): Remove unnecessary
1408 parentheses in the declaration.
1409 (macro_lookup_inclusion): Likewise.
1410 (macro_lookup_definition): Likewise.
1411 * p-lang.h (pascal_builtin_types): Likewise.
1412 * tui/tui-data.c (tui_win_list): Likewise.
1413 * tui/tui-data.h (tui_win_list): Likewise.
1414 * utils.h (make_cleanup_free_section_addr_info): Likewise.
1415
d9b477e3
KB
14162017-10-11 Mark Rages <markrages@gmail.com>
1417
1418 * target-memory.c (block_boundaries): Fix for block address not
1419 aligned on block size.
1420
65630365
PA
14212017-10-10 Pedro Alves <palves@redhat.com>
1422 Tom Tromey <tom@tromey.com>
1423
1424 * breakpoint.c (struct captured_breakpoint_query_args)
1425 (do_captured_breakpoint_query, gdb_breakpoint_query): Delete.
1426 (print_breakpoint): New.
1427 * breakpoint.h (print_breakpoint): Declare.
1428 * common/common-exceptions.h (enum return_reason): Remove
1429 references to catch_exceptions.
1430 * exceptions.c (catch_exceptions, catch_exceptions_with_msg):
1431 Delete.
1432 * exceptions.h (catch_exceptions_ftype, catch_exceptions)
1433 (catch_exception_ftype, catch_exceptions_with_msg): Delete.
1434 * gdb.h: Delete.
1435 * gdbthread.h (thread_select): Declare.
1436 * mi/mi-cmd-break.c: Don't include gdb.h.
1437 (breakpoint_notify): Use print_breakpoint.
1438 * mi/mi-cmd-catch.c: Don't include gdb.h.
1439 * mi/mi-interp.c: Don't include gdb.h.
1440 (mi_print_breakpoint_for_event): New.
1441 (mi_breakpoint_created, mi_breakpoint_modified): Use
1442 mi_print_breakpoint_for_event.
1443 * mi/mi-main.c: Don't include gdb.h.
1444 (mi_cmd_thread_select): Parse the global thread ID here. Use
1445 thread_select instead of gdb_thread_select.
1446 (mi_cmd_thread_list_ids): Output "thread-ids" tuple here instead
1447 of using gdb_list_thread_ids.
1448 * remote-fileio.c (do_remote_fileio_request): Change type. Reply
1449 FILEIO_ENOSYS here.
1450 (remote_fileio_request): Use TRY/CATCH instead of
1451 catch_exceptions.
1452 * symfile-mem.c (struct symbol_file_add_from_memory_args)
1453 (symbol_file_add_from_memory_wrapper): Delete.
1454 (add_vsyscall_page): Use TRY/CATCH instead of catch_exceptions.
1455 * thread.c: Don't include gdb.h.
1456 (do_captured_list_thread_ids, gdb_list_thread_ids): Delete.
1457 (thread_alive): Use thread_select.
1458 (do_captured_thread_select): Delete, parts salvaged as ...
1459 (thread_select): ... this new function.
1460 (gdb_thread_select): Delete.
1461
bf469271
PA
14622017-10-10 Pedro Alves <palves@redhat.com>
1463 Tom Tromey <tom@tromey.com>
1464
1465 * breakpoint.c (breakpoint_cond_eval): Change return type to bool
1466 and reverse logic.
1467 (WP_DELETED, WP_VALUE_CHANGED, WP_VALUE_NOT_CHANGED, WP_IGNORE):
1468 No longer macros. Instead ...
1469 (enum wp_check_result): They're now values of this new
1470 enumeration.
1471 (watchpoint_check): Change return type to wp_check_result and
1472 parameter type to bpstat.
1473 (bpstat_check_watchpoint): Use TRY/CATCH instead of catch_errors.
1474 (bpstat_check_breakpoint_conditions): Use TRY/CATCH instead of
1475 catch_errors. Reverse logic of watchpoint_check call.
1476 (breakpoint_re_set_one): Now returns void and takes a breakpoint
1477 pointer as parameter.
1478 (breakpoint_re_set): Use TRY/CATCH instead of catch_errors.
1479 * common/common-exceptions.c (throw_exception_sjlj): Update
1480 comments to avoid mentioning catch_errors.
1481 * exceptions.c (catch_errors): Delete.
1482 * exceptions.h: Update comments to avoid mentioning catch_errors.
1483 (catch_errors_ftype, catch_errors): Delete.
1484 * infrun.c (normal_stop): Use TRY/CATCH instead of catch_errors.
1485 (hook_stop_stub): Delete.
1486 (restore_selected_frame): Change return type to void, and
1487 parameter type to const frame_id &.
1488 (restore_infcall_control_state): Use TRY/CATCH instead of
1489 catch_errors.
1490 * main.c (captured_command_loop): Return void and remove
1491 parameter. Remove references to catch_errors.
1492 (captured_main): Use TRY/CATCH instead of catch_errors.
1493 * objc-lang.c (objc_submethod_helper_data)
1494 (find_objc_msgcall_submethod_helper): Delete.
1495 (find_objc_msgcall_submethod): Use TRY/CATCH instead of
1496 catch_errors.
1497 * record-full.c (record_full_message): Return void.
1498 (record_full_message_args, record_full_message_wrapper): Delete.
1499 (record_full_message_wrapper_safe): Return bool and use TRY/CATCH
1500 instead of catch_errors.
1501 * solib-aix.c (solib_aix_open_symbol_file_object): Change
1502 parameter type to int.
1503 * solib-darwin.c (open_symbol_file_object): Ditto.
1504 * solib-dsbt.c (open_symbol_file_object): Ditto.
1505 * solib-frv.c (open_symbol_file_object): Ditto.
1506 * solib-svr4.c (open_symbol_file_object): Ditto.
1507 * solib-target.c (solib_target_open_symbol_file_object): Ditto.
1508 * solib.c (update_solib_list): Use TRY/CATCH instead of
1509 catch_errors.
1510 * solist.h (struct target_so_ops) <open_symbol_file_object>:
1511 Change type.
1512 * symmisc.c (struct print_symbol_args): Remove.
1513 (dump_symtab_1): Use TRY/CATCH instead of catch_errors.
1514 (print_symbol): Change type.
1515 * windows-nat.c (handle_load_dll, handle_unload_dll): Return void
1516 and remove parameters.
1517 (catch_errors): New.
1518 (get_windows_debug_event): Adjust.
1519
1a56bfa5
TT
15202017-10-09 Tom Tromey <tom@tromey.com>
1521
1522 * mi/mi-main.c (free_splay_tree): Remove.
1523 (list_available_thread_groups): Use splay_tree_up.
1524 * common/gdb_splay_tree.h: New file.
1525
0c478e2d
TT
15262017-10-09 Tom Tromey <tom@tromey.com>
1527
1528 * mi/mi-main.c (do_nothing): Remove.
1529 (list_available_thread_groups): Update.
1530
cbd2b4e3
PA
15312017-10-09 Pedro Alves <palves@redhat.com>
1532
1533 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>: Skip
1534 reading registers when switching context.
1535
a181c0bf
JB
15362017-10-09 John Baldwin <jhb@FreeBSD.org>
1537
1538 * fbsd-nat.c (fbsd_siginfo_size): Use gdbarch_long_bit.
1539 (fbsd_convert_siginfo): Likewise.
1540 * fbsd-tdep.c (fbsd_core_xfer_siginfo): Likewise.
1541
6e66f753
SM
15422017-10-09 Simon Marchi <simon.marchi@polymtl.ca>
1543
1544 * configure.ac (try_guile_versions): Remove guile-2.2.
1545 * configure: Regenerate.
1546
890e9790
TT
15472017-10-09 Tom Tromey <tom@tromey.com>
1548
1549 * Makefile.in (COMPILE.post, POSTCOMPILE): Restore $(basename).
1550 (COMPILE.pre): Use $(CXX).
1551
109483d9
PA
15522017-10-09 Pedro Alves <palves@redhat.com>
1553
1554 * cp-support.c (cp_remove_params): Return a gdb::unique_xmalloc_ptr.
1555 Use bool.
1556 (overload_list_add_symbol): Adjust to use gdb::unique_xmalloc_ptr.
1557 * cp-support.h (cp_remove_params): Now returns a
1558 gdb::unique_xmalloc_ptr.
1559 * dwarf2read.c (find_slot_in_mapped_hash): Now returns bool.
1560 Adjust to cp_remove_params returning a gdb::unique_xmalloc_ptr.
1561 * psymtab.c (psymtab_search_name): Adjust to cp_remove_params
1562 returning a gdb::unique_xmalloc_ptr.
1563 (lookup_partial_symbol): Adjust to use gdb::unique_xmalloc_ptr.
1564 * stack.c (find_frame_funname): Adjust to cp_remove_params
1565 returning a gdb::unique_xmalloc_ptr.
1566
791afaa2
TT
15672017-10-08 Tom Tromey <tom@tromey.com>
1568
1569 * dwarf2read.c (dwarf2_get_dwz_file): Use
1570 gdb::unique_xmalloc_ptr.
1571 (find_slot_in_mapped_hash): Likewise.
1572 (dwarf2_physname): Likewise.
1573 (create_dwo_unit_in_dwp_v1): Use std::string.
1574 (create_dwo_unit_in_dwp_v2): Likewise.
1575 (lookup_dwo_cutu): Likewise.
1576 (inherit_abstract_dies): Use std::vector.
1577 (read_array_type): Likewise.
1578 (dwarf_decode_macros): Remove unused declaration.
1579 (unsigned_int_compar): Remove.
1580 (dwarf2_build_psymtabs_hard): Use scoped_restore.
1581 (psymtabs_addrmap_cleanup): Remove.
1582
30a9c02f
TT
15832017-10-08 Tom Tromey <tom@tromey.com>
1584
1585 * frame-unwind.c (frame_unwind_try_unwinder): Update.
1586 * frame.h (frame_cleanup_after_sniffer): Declare.
1587 (frame_prepare_for_sniffer): Return void.
1588 * frame.c (frame_cleanup_after_sniffer): No longer static. Change
1589 type of argument.
1590 (frame_prepare_for_sniffer): Return void.
1591
757325a3
TT
15922017-10-08 Tom Tromey <tom@tromey.com>
1593
1594 * utils.h (make_cleanup_value_free): Remove.
1595 * utils.c (do_value_free, struct cleanup): Remove.
1596 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full) <DWARF_VALUE_STACK>:
1597 Use gdb_value_up.
1598 * value.h (struct value_deleter): New.
1599 (gdb_value_up): New typedef.
1600
b9c04fb2
TT
16012017-10-08 Tom Tromey <tom@tromey.com>
1602
1603 * symtab.c (free_search_symbols, do_free_search_symbols_cleanup)
1604 (make_cleanup_free_search_symbols): Remove.
1605 (search_symbols): Return std::vector.
1606 (symbol_search::compare_search_syms): Now member of
1607 symbol_search. Change arguments.
1608 (sort_search_symbols_remove_dups): Change arguments. Rewrite.
1609 (symtab_symbol_info, rbreak_command): Update.
1610 * symtab.h (struct symbol_search) <next>: Remove.
1611 Add constructors.
1612 (symbol_search::operator<): New function.
1613 (symbol_search::operator==): New function.
1614 (search_symbols): Remove std::vector.
1615 (free_search_symbols, make_cleanup_free_search_symbols): Remove.
1616 (symbol_search::compare_search_syms): Declare.
1617
0d28b0a5
YQ
16182017-10-06 Yao Qi <yao.qi@linaro.org>
1619
1620 * Makefile.in (ALL_64_TARGET_OBS): Replace aarch64-insn.o with
1621 arch/aarch64-insn.o.
1622 Remove one rule.
1623 * configure.tgt: Replace aarch64-insn.o with arch/aarch64-insn.o.
1624
71917808
YQ
16252017-10-06 Yao Qi <yao.qi@linaro.org>
1626
1627 * Makefile.in (ALL_TARGET_OBS): Replace arm.o, arm-get-next-pcs.o,
1628 and arm-linux.o with arch/arm.o, arch/arm-get-next-pcs.o and
1629 arch/arm-linux.o respectively.
1630 * configure.tgt: Likewise.
1631
2081b2b2
YQ
16322017-10-06 Yao Qi <yao.qi@linaro.org>
1633
1634 * Makefile.in (ALL_TARGET_OBS): Rename i386.o to arch/i386.o.
1635 * configure.tgt (i386_tobjs): Replace i386.o with arch/i386.o.
1636
a1b85d28
PA
16372017-10-06 Pedro Alves <palves@redhat.com>
1638
1639 * windows-nat.c: Include <algorithm>.
1640
d97987e2
YQ
16412017-10-06 Yao Qi <yao.qi@linaro.org>
1642
1643 * configure.tgt (i386_tobjs): New variable.
1644 (amd64_tobjs): New variable.
1645 Set $cpu_obs and $os_obs.
1646
f38307f5
YQ
16472017-10-06 Yao Qi <yao.qi@linaro.org>
1648
1649 * Makefile.in (CONFIG_SRC_SUBDIR): New.
1650 (ALL_64_TARGET_OBS): Replace amd64.o with arch/amd64.o.
1651 (clean): Remove object files and dependency files.
1652 (distclean): Remove the directory.
1653 * configure.ac: Invoke AC_CONFIG_COMMANDS.
1654 * configure: Re-generated.
1655 * configure.tgt: Replace amd64.o with arch/amd64.o.
1656
2f924de6
JM
16572017-10-05 Jose E. Marchesi <jose.marchesi@oracle.com>
1658
1659 PR build/22188
1660 * arm-tdep.c (arm_decode_misc_memhint_neon): Fix decoding of CPS
1661 and SETEND.
1662
2fd9d7ca
PA
16632017-10-05 Pedro Alves <palves@redhat.com>
1664
1665 * linux-nat.c (linux_child_follow_fork): When following the parent
1666 and detaching the child, consult the parent thread's architecture
1667 instead of the child's.
1668
d13b8493
UW
16692017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
1670
1671 * ax.h: Do not include "doublest.h".
1672 (union agent_val): Remove.
1673
3b4b2f16
UW
16742017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
1675
1676 * dfp.h (MAX_DECIMAL_STRING): Move to dfp.c.
1677 (decimal_to_string): Return std::string object.
1678 (decimal_from_string): Accept std::string object. Return bool.
1679 (decimal_from_integral, decimal_from_doublest): Remove.
1680 (decimal_from_longest): Add prototype.
1681 (decimal_from_ulongest): Likewise.
1682 (decimal_to_longest): Likewise.
1683 (decimal_from_doublest): Likewise.
1684 * dfp.c: Do not include "gdbtypes.h" or "value.h".
1685 (MAX_DECIMAL_STRING): Move here.
1686 (decimal_to_string): Return std::string object.
1687 (decimal_from_string): Accept std::string object. Return bool.
1688 (decimal_from_integral): Remove, replace by ...
1689 (decimal_from_longest, decimal_from_ulongest): ... these new functions.
1690 (decimal_to_longest): New function.
1691 (decimal_from_floating): Remove, replace by ...
1692 (decimal_from_doublest): ... this new function.
1693 (decimal_to_doublest): Update to new decimal_to_string interface.
1694
1695 * value.c (unpack_long): Use decimal_to_longest.
1696 * valops.c (value_cast): Use decimal_from_doublest instead of
1697 decimal_from_floating. Use decimal_from_[u]longest isntead of
1698 decimal_from_integral.
1699 * valarith.c (value_args_as_decimal): Likewise.
1700 * valprint.c (print_decimal_floating): Update to new
1701 decimal_to_string interface.
1702 * printcmd.c (printf_decfloat): Likewise.
1703 * c-exp.y (parse_number): Update to new decimal_from_string interface.
1704
1841ee5d
UW
17052017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
1706
1707 * doublest.h: Do not include "floatformat.h". Remove stale comments.
1708 * gdbtypes.c: Include "floatformat.h".
1709 * value.c: Likewise.
1710 * m68k-tdep.c: Likewise.
1711
1712 * findvar.c: Do not include "floatformat.h".
1713 * amd64-darwin-tdep.c: Likewise.
1714 * arm-linux-tdep.c: Likewise.
1715 * i386-darwin-tdep.c: Likewise.
1716 * i387-tdep.c: Likewise.
1717 * m68k-linux-tdep.c: Likewise.
1718 * mep-tdep.c: Likewise.
1719 * mips-tdep.c: Likewise.
1720 * nios2-tdep.c: Likewise.
1721 * s390-linux-tdep.c: Likewise.
1722 * sparc-obsd-tdep.c: Likewise.
1723 * sparc-tdep.c: Likewise.
1724 * sparc64-tdep.c: Likewise.
1725 * spu-tdep.c: Likewise.
1726 * tic6x-tdep.c: Likewise.
1727 * tilegx-tdep.c: Likewise.
1728 * vax-tdep.c: Likewise.
1729 * xstormy16-tdep.c: Likewise.
1730 * xtensa-tdep.c: Likewise.
1731
1732 * top.c: Do not include "doublest.h".
1733 * aarch64-tdep.c: Likewise.
1734 * alpha-tdep.c: Likewise.
1735 * arm-linux-tdep.c: Likewise.
1736 * m68k-linux-tdep.c: Likewise.
1737 * tilegx-tdep.c: Likewise.
1738 * xstormy16-tdep.c: Likewise.
1739
a80a6471
JB
17402017-10-05 John Baldwin <jhb@FreeBSD.org>
1741
1742 * mips-fbsd-tdep.c (MIPS_INST_ADDIU_A0_SP_N32): Define.
1743 (mipsn32_fbsd_sigframe): Define.
1744 (mips_fbsd_init_abi): Install mipsn32_fbsd_sigframe unwinder
1745 for FreeBSD/mipsn32.
1746
12c4bd7f
JB
17472017-10-05 John Baldwin <jhb@FreeBSD.org>
1748
1749 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_EHDRFLAGS and
1750 AT_HWCAP.
1751
c91933e9
TG
17522017-10-05 Tristan Gingold <tgingold@free.fr>
1753
1754 * MAINTAINERS (Misc): Update my email address.
1755
5cd63fda
PA
17562017-10-04 Pedro Alves <palves@redhat.com>
1757
1758 * remote.c (get_remote_arch_state): New 'gdbarch' parameter. Use
1759 it instead of target_gdbarch.
1760 (get_remote_state, get_remote_packet_size): Adjust
1761 get_remote_arch_state calls, passing down target_gdbarch
1762 explicitly.
1763 (packet_reg_from_regnum, packet_reg_from_pnum): New parameter
1764 'gdbarch' and use it instead of target_gdbarch.
1765 (get_memory_packet_size): Adjust get_remote_arch_state calls,
1766 passing down target_gdbarch explicitly.
1767 (struct stop_reply) <arch>: New field.
1768 (remote_parse_stop_reply): Use the stopped thread's architecture,
1769 not the current inferior's. Save the architecture in the
1770 stop_reply.
1771 (process_stop_reply): Use the stop reply's architecture.
1772 (process_g_packet, remote_fetch_registers)
1773 (remote_prepare_to_store, store_registers_using_G)
1774 (remote_store_registers): Adjust get_remote_arch_state calls,
1775 using the regcache's architecture.
1776 (remote_get_trace_status): Adjust get_remote_arch_state calls,
1777 passing down target_gdbarch explicitly.
1778 * spu-multiarch.c (spu_thread_architecture): Defer to the target
1779 beneath instead of calling target_gdbarch.
1780 * target.c (default_thread_architecture): Use the specified
1781 inferior's architecture, instead of the current inferior's
1782 architecture (via target_gdbarch).
1783
ed4227b7
PA
17842017-10-04 Pedro Alves <palves@redhat.com>
1785
1786 * regcache.c (get_thread_arch_regcache): Remove null_ptid special
1787 case.
1788 (regcache_print): Handle !target_has_registers here instead.
1789
55b11ddf
PA
17902017-10-04 Pedro Alves <palves@redhat.com>
1791
1792 * frame.c (create_test_frame): Delete.
1793 * frame.h (create_test_frame): Delete.
1794 * gdbarch-selftests.c: Include gdbthread.h and target.h.
1795 (class regcache_test): Delete.
1796 (test_target_has_registers, test_target_has_stack)
1797 (test_target_has_memory, test_target_prepare_to_store)
1798 (test_target_store_registers): New functions.
1799 (test_target_ops): New class.
1800 (register_to_value_test): Error out if there's already a
1801 process_stratum (or higher) target pushed. Create a fuller mock
1802 environment, with mock target_ops, inferior, address space, thread
1803 and inferior_ptid.
1804 * progspace.c (struct address_space): Move to ...
1805 * progspace.h (struct address_space): ... here.
1806 * regcache.h (regcache::~regcache, regcache::raw_write)
1807 [GDB_SELF_TEST]: No longer virtual.
1808
4c71c105
SM
18092017-10-04 Simon Marchi <simon.marchi@ericsson.com>
1810
1811 * mi/mi-main.c (list_available_thread_groups): Reverse filter logic.
1812
73dcd72d
PA
18132017-10-04 Pedro Alves <palves@redhat.com>
1814
1815 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Move code
1816 out of 'between TRY and CATCH'.
1817
44704526
PA
18182017-10-04 Pedro Alves <palves@redhat.com>
1819
1820 * cli/cli-cmds.c (complete_command): Add missing END_CATCH.
1821 * common/common-exceptions.h (TRY): Open an outermost scope.
1822 Expand intro comment.
1823 (CATCH): Reindent.
1824 (END_CATCH): Close the outermost scope.
1825 * completer.c (complete_line_internal): Add missing END_CATCH.
1826
bc3b087d
SDJ
18272017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
1828
1829 * NEWS (Changes since GDB 8.0): Add entry about new
1830 'set-cwd-on-gdbserver' feature.
1831 (New remote packets): Add entry for QSetWorkingDir.
1832 * common/common-inferior.h (set_inferior_cwd): New prototype.
1833 * infcmd.c (set_inferior_cwd): Remove "static".
1834 (show_cwd_command): Expand text to include remote debugging.
1835 * remote.c: Add PACKET_QSetWorkingDir.
1836 (remote_protocol_features) <QSetWorkingDir>: New entry for
1837 PACKET_QSetWorkingDir.
1838 (extended_remote_set_inferior_cwd): New function.
1839 (extended_remote_create_inferior): Call
1840 "extended_remote_set_inferior_cwd".
1841 (_initialize_remote): Call "add_packet_config_cmd" for
1842 QSetWorkingDir.
1843
d092c5a2
SDJ
18442017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
1845
1846 * NEWS (New commands): Mention "set/show cwd".
1847 * cli/cli-cmds.c (_initialize_cli_cmds): Mention "set cwd" on
1848 "cd" command's help text.
1849 * common/common-inferior.h (get_inferior_cwd): New prototype.
1850 * infcmd.c (inferior_cwd_scratch): New global variable.
1851 (set_inferior_cwd): New function.
1852 (get_inferior_cwd): Likewise.
1853 (set_cwd_command): Likewise.
1854 (show_cwd_command): Likewise.
1855 (_initialize_infcmd): Add "set/show cwd" commands.
1856 * inferior.h (class inferior) <cwd>: New field.
1857 * nat/fork-inferior.c: Include "gdb_tilde_expand.h".
1858 (fork_inferior): Change inferior's cwd before its execution.
1859 * windows-nat.c (windows_create_inferior): Pass inferior's cwd
1860 to CreateProcess.
1861
7da0a886
SDJ
18622017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
1863
1864 * Makefile.in (SFILES): Add gdb_tilde_expand.c.
1865 (HFILES_NO_SRCDIR): Add gdb_tilde_expand.h.
1866 (COMMON_OBS): Add gdb_tilde_expand.o.
1867 * common/gdb_tilde_expand.c: New file.
1868 * common/gdb_tilde_expand.h: Likewise.
1869
db8dd160
MR
18702017-10-03 Maciej W. Rozycki <macro@imgtec.com>
1871
1872 * gdbarch.sh (objfile): Remove duplicate declaration.
1873 * gdbarch.h: Regenerate.
1874
f8bfbf22
TT
18752017-10-03 Tom Tromey <tom@tromey.com>
1876
1877 * utils.c (internal_vproblem): Use string_vprintf.
1878
5178ed48
TT
18792017-10-03 Tom Tromey <tom@tromey.com>
1880
1881 * printcmd.c (info_symbol_command): Use std::string.
1882
8cff8730
TT
18832017-10-03 Tom Tromey <tom@tromey.com>
1884
1885 * top.c (gdb_safe_append_history): Use std::string.
1886
895b8f30
TT
18872017-10-03 Tom Tromey <tom@tromey.com>
1888
1889 * event-top.c (stdin_event_handler): Update.
1890 * main.c (captured_main_1): Update.
1891 * top.h (make_delete_ui_cleanup): Remove.
1892 (struct ui): Add constructor and destructor.
1893 (new_ui, delete_ui): Remove.
1894 * top.c (make_delete_ui_cleanup): Remove.
1895 (new_ui_command): Use std::unique_ptr.
1896 (delete_ui_cleanup): Remove.
1897 (ui::ui): Rename from new_ui. Update.
1898 (free_ui): Remove.
1899 (ui::~ui): Rename from delete_ui. Update.
1900
0efef640
TT
19012017-10-03 Tom Tromey <tom@tromey.com>
1902
1903 * symfile.c (load_progress): Use gdb::byte_vector.
1904
245ad7d3
TT
19052017-10-03 Tom Tromey <tom@tromey.com>
1906
1907 * mi/mi-main.c (mi_cmd_trace_frame_collected): Remove unused
1908 declaration.
1909 * printcmd.c (x_command): Remove unused declaration.
1910 * symfile.c (symbol_file_command): Remove unused declaration.
1911
e05550d7
TT
19122017-10-03 Tom Tromey <tom@tromey.com>
1913
1914 * utils.c (internal_vproblem): Use std::string.
1915 (defaulted_query): Likewise.
1916
b95de2b7
TT
19172017-10-03 Tom Tromey <tom@tromey.com>
1918
1919 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Update.
1920 * top.c (execute_command_to_string): Update.
1921 * utils.c (make_cleanup_restore_page_info): Remove.
1922 (do_restore_page_info_cleanup): Remove.
1923 (set_batch_flag_and_restore_page_info):
1924 New.
1925 (make_cleanup_restore_page_info): Remove.
1926 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
1927 (~set_batch_flag_and_restore_page_info): New
1928 (make_cleanup_restore_uinteger): Remove.
1929 (make_cleanup_restore_integer): Remove.
1930 (struct restore_integer_closure): Remove.
1931 (restore_integer): Remove.
1932 * utils.h (struct set_batch_flag_and_restore_page_info): New
1933 class.
1934 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
1935 (make_cleanup_restore_page_info): Remove.
1936 (make_cleanup_restore_uinteger) Remove.
1937 (make_cleanup_restore_integer) Remove.
1938
07036511
TT
19392017-10-03 Tom Tromey <tom@tromey.com>
1940
1941 * record-full.h (record_full_gdb_operation_disable_set): Return
1942 scoped_restore_tmpl<int>.
1943 * infrun.c (adjust_pc_after_break): Update.
1944 (handle_signal_stop): Update.
1945 * record-full.c (record_full_gdb_operation_disable_set): Return
1946 scoped_restore_tmpl<int>.
1947 (record_full_wait_1, record_full_insert_breakpoint)
1948 (record_full_remove_breakpoint, record_full_save)
1949 (record_full_goto_insn): Update.
1950
45320ffa
TT
19512017-10-02 Tom Tromey <tom@tromey.com>
1952
1953 PR rust/22236:
1954 * rust-lang.c (rust_val_print_str): New function.
1955 (val_print_struct): Call it.
1956 (rust_subscript): Preserve name of slice type.
1957
b3e3859b
TT
19582017-10-02 Tom Tromey <tom@tromey.com>
1959
1960 * rust-lang.c (rust_subscript): Handle slices in
1961 EVAL_AVOID_SIDE_EFFECTS case.
1962
01af5e0d
TT
19632017-10-02 Tom Tromey <tom@tromey.com>
1964
1965 * rust-lang.c (rust_slice_type_p): Recognize &str as a slice type.
1966
888e3ddb
TT
19672017-10-02 Tom Tromey <tom@tromey.com>
1968
1969 * rust-lang.h (rust_slice_type): Add "extern".
1970
cc536b21
PA
19712017-10-02 Tom Tromey <tom@tromey.com>
1972 Pedro Alves <palves@redhat.com>
1973
1974 * ada-lang.h (ada_exc_info::operator<): Make const.
1975 (ada_exc_info::operator==): Make const.
1976 * ada-lang.c (ada_exc_info::operator<, ada_exc_info::operator==):
1977 Make const.
1978
386c8614
TT
19792017-09-29 Tom Tromey <tom@tromey.com>
1980
1981 * target.c (read_whatever_is_readable): Change type of "result".
1982 Update.
1983 (free_memory_read_result_vector): Remove.
1984 (read_memory_robust): Change return type. Update.
1985 * mi/mi-main.c (mi_cmd_data_read_memory_bytes): Update. Use
1986 bin2hex, std::string.
1987 * target.h (memory_read_result_s): Remove typedef.
1988 (free_memory_read_result_vector): Remove.
1989 (read_memory_robust): Return std::vector.
1990
789c4b5e
TT
19912017-09-29 Tom Tromey <tom@tromey.com>
1992
1993 * mi/mi-main.c (captured_mi_execute_command): Use scope_restore.
1994
ab816a27
TT
19952017-09-29 Tom Tromey <tom@tromey.com>
1996
1997 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Update.
1998 * ada-lang.h (struct ada_exc_info): Remove typedef. Declare
1999 operator< and operator==.
2000 (ada_exceptions_list): Return a std::vector.
2001 * ada-lang.c (ada_exc_info::operator<): Rename from
2002 compare_ada_exception_info.
2003 (ada_exc_info::operator==): New.
2004 (sort_remove_dups_ada_exceptions_list): Change type of
2005 "exceptions".
2006 (ada_add_standard_exceptions, ada_add_exceptions_from_frame)
2007 (ada_add_global_exceptions): Likewise.
2008 (ada_exceptions_list_1): Return a std::vector.
2009 (ada_exceptions_list): Likewise.
2010
52f9abe4
TT
20112017-09-29 Tom Tromey <tom@tromey.com>
2012
2013 * mi/mi-main.c (struct print_one_inferior_data) <inferiors>: Now a
2014 'std::set *'.
2015 (print_one_inferior): Update.
2016 (free_vector_of_ints): Remove.
2017 (list_available_thread_groups): Change "ids" to std::set.
2018 (mi_cmd_list_thread_groups): Update.
2019 (struct collect_cores_data) <core>: Now a std::set.
2020 (collect_cores): Update.
2021 (unique): Remove.
2022 (print_one_inferior): Update.
2023
dcd5ddcc
TT
20242017-09-29 Tom Tromey <tom@tromey.com>
2025
2026 * mi/mi-main.c (mi_execute_cli_command): Use std::string.
2027 (mi_execute_async_cli_command): Likewise.
2028 (mi_cmd_trace_frame_collected): Use field_fmt.
2029
45d288cc
TT
20302017-09-29 Tom Tromey <tom@tromey.com>
2031
2032 * mi/mi-main.c (mi_cmd_data_write_memory_bytes): Use
2033 gdb::byte_vector.
2034
6afe2f4a
TT
20352017-09-29 Tom Tromey <tom@tromey.com>
2036
2037 * mi/mi-parse.c (mi_parse): Remove unused declaration.
2038
9813429a
TT
20392017-09-29 Tom Tromey <tom@tromey.com>
2040
2041 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Don't copy "oarg".
2042
2d6960b4
TT
20432017-09-29 Tom Tromey <tom@tromey.com>
2044
2045 * varobj.h (varobj_gen_name): Return std::string.
2046 * varobj.c (varobj_gen_name): Return std::string.
2047 * mi/mi-cmd-var.c (mi_cmd_var_create): Use std::string.
2048 (mi_cmd_var_delete): Don't copy "name".
2049
784c453a
TT
20502017-09-29 Tom Tromey <tom@tromey.com>
2051
2052 * mi/mi-cmd-break.c (mi_argv_to_format): Return std::string.
2053 (mi_cmd_break_insert_1): Update.
2054
a9bc57b9
TT
20552017-09-29 Tom Tromey <tom@tromey.com>
2056
2057 * target.h (make_scoped_defer_target_commit_resume): Update.
2058 * target.c (make_scoped_defer_target_commit_resume): Rename from
2059 make_cleanup_defer_target_commit_resume. Return a
2060 scoped_restore.
2061 * infrun.c (proceed): Use make_scoped_defer_target_commit_resume.
2062
9754d8c4
TT
20632017-09-29 Tom Tromey <tom@tromey.com>
2064
2065 * main.c (captured_main_1): Remove unused declaration.
2066 * spu-multiarch.c (parse_spufs_run): Remove unused declaration.
2067
99ef965c
TT
20682017-09-29 Tom Tromey <tom@tromey.com>
2069
2070 * symtab.c (search_symbols): Remove unused outer cleanup.
2071 (make_source_files_completion_list): Remove unused declaration.
2072
42518ba7
TT
20732017-09-29 Tom Tromey <tom@tromey.com>
2074
2075 * mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.
2076
726b2169
TT
20772017-09-29 Tom Tromey <tom@tromey.com>
2078
2079 * xstormy16-tdep.c (xstormy16_push_dummy_call): Use
2080 gdb::byte_vector.
2081
55b06432
TT
20822017-09-29 Tom Tromey <tom@tromey.com>
2083
2084 * complaints.c (vcomplaint): Use std::string.
2085
8abcee91
TT
20862017-09-29 Tom Tromey <tom@tromey.com>
2087
2088 * tracepoint.c (trace_variable_command): Use std::string.
2089 (encode_actions_1): Remove unused declarations.
2090 (create_tsv_from_upload): Use std::string.
2091
6ad94bc7
TT
20922017-09-29 Tom Tromey <tom@tromey.com>
2093
2094 * cp-support.c (gdb_demangle): Use std::string.
2095
2003f3d8
TT
20962017-09-29 Tom Tromey <tom@tromey.com>
2097
2098 * stack.c (parse_frame_specification): Use std::string
2099 (info_frame_command): Use gdb::unique_xmalloc_ptr.
2100
8f8accb5
TT
21012017-09-29 Tom Tromey <tom@tromey.com>
2102
2103 * tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.
2104
200aa7b1
TT
21052017-09-29 Tom Tromey <tom@tromey.com>
2106
2107 * utils.c (vfprintf_maybe_filtered): Use std::string.
2108 (vfprintf_unfiltered): Likewise.
2109
606aae8a
TT
21102017-09-29 Tom Tromey <tom@tromey.com>
2111
2112 * event-top.c (top_level_prompt): Return std::string.
2113 (display_gdb_prompt): Update.
2114
bd413795
TT
21152017-09-29 Tom Tromey <tom@tromey.com>
2116
2117 * unittests/common-utils-selftests.c (format): New function.
2118 (string_vprintf_tests): New function.
2119 (_initialize_common_utils_selftests): Register new tests.
2120 * common/common-utils.c (string_vprintf): New function.
2121 * common/common-utils.h (string_vprintf): Declare.
2122
256642e8
PA
21232017-09-29 Pedro Alves <palves@redhat.com>
2124
2125 * common/rsp-low.c (unpack_varlen_hex): Constify.
2126 * common/rsp-low.h (unpack_varlen_hex): Constify.
2127 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
2128 Constify.
2129 * remote.c (remote_set_permissions, read_ptid)
2130 (remote_current_thread, remote_get_threads_with_qthreadinfo)
2131 (remote_static_tracepoint_marker_at)
2132 (remote_static_tracepoint_markers_by_strid)
2133 (stop_reply_extract_thread, remote_parse_stop_reply): Constify.
2134 * tracepoint.c (parse_trace_status, parse_tracepoint_status)
2135 (parse_tracepoint_definition, parse_tsv_definition)
2136 (parse_static_tracepoint_marker_definition): Constify.
2137 * tracepoint.h (parse_static_tracepoint_marker_definition)
2138 (parse_trace_status, parse_tracepoint_status)
2139 (parse_tracepoint_definition, parse_tsv_definition): Constify.
2140
b6bb3468
PA
21412017-09-29 Pedro Alves <palves@redhat.com>
2142
2143 * remote.c (target_buf, target_buf_size): Delete.
2144 (remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
2145 Use the connection's packet buffer instead.
2146 All callers adjusted.
2147 (_initialize_remote): Remove references to target_buf and
2148 target_buf_size.
2149
b2f8eb7a
PA
21502017-09-28 Pedro Alves <palves@redhat.com>
2151
2152 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2153 unittests/common-utils-selftests.c.
2154 (SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
2155 (COMMON_OBS): Remove utils-selftests.o.
2156 * utils-selftests.c: Move to ...
2157 * unittests/common-utils-selftests.c: ... here and rename self
2158 test to "string_printf".
2159
08302ed2
DE
21602017-09-28 Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com> (tiny patch)
2161
2162 * dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
2163 having NULL cus or tus.
2164
96a5a1d3
UW
21652017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
2166
2167 * arm-tdep.c: (convert_from_extended): Remove.
2168 (convert_to_extended): Likewise.
2169 (arm_extract_return_value): Use convert_typed_floating.
2170 (arm_store_return_value): Likewise.
2171
2172 * sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
2173 * sh-tdep.c: Do not include "floatformat.h".
2174 (sh_littlebyte_bigword_type): New function.
2175 (sh_register_convert_to_virtual): Use convert_typed_floating.
2176 (sh_register_convert_to_raw): Likewise.
2177 * sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
2178 (sh64_littlebyte_bigword_type): New function.
2179 (sh64_extract_return_value): Use convert_typed_floating.
2180 (sh64_register_convert_to_virtual): Likewise.
2181 (sh64_register_convert_to_raw): Likewise.
2182
0db7851f
UW
21832017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
2184
2185 * doublest.h (floatformat_from_type): Move to gdbtypes.h.
2186 * doublest.c (floatformat_from_type): Move to gdbtypes.c.
2187
2188 * gdbtypes.h (union type_specific): Make field floatformat hold
2189 just a single struct floatformat, not an array.
2190 (floatformat_from_type): Move here.
2191 * gdbtypes.c (floatformat_from_type): Move here. Update to
2192 changed TYPE_FLOATFORMAT definition.
2193 (verify_floatformat): Update to changed TYPE_FLOATFORMAT.
2194 (recursive_dump_type): Likewise.
2195 (init_float_type): Install correct floatformat for byte order.
2196 (arch_float_type): Likewise.
2197
77b7c781
UW
21982017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
2199
2200 * gdbtypes.c (init_type): Change incoming argument from
2201 length-in-bytes to length-in-bits. Assert length is a
2202 multiple of TARGET_CHAR_BITS.
2203 (arch_type, arch_flags_type): Likewise.
2204 (init_integer_type): Update call to init_type.
2205 (init_character_type): Likewise.
2206 (init_boolean_type): Likewise.
2207 (init_float_type): Likewise.
2208 (init_decfloat_type): Likewise.
2209 (init_complex_type): Likewise.
2210 (init_pointer_type): Likewise.
2211 (objfile_type): Likewise.
2212 (arch_integer_type): Update call to arch_type.
2213 (arch_character_type): Likewise.
2214 (arch_boolean_type): Likewise.
2215 (arch_float_type): Likewise.
2216 (arch_decfloat_type): Likewise.
2217 (arch_complex_type): Likewise.
2218 (arch_pointer_type): Likewise.
2219 (gdbtypes_post_init): Likewise.
2220
2221 * dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
2222 (read_base_type): Likewise.
2223 * mdebugread.c (basic_type): Likewise.
2224 * stabsread.c (dbx_init_float_type): Likewise.
2225 (rs6000_builtin_type): Likewise.
2226 (read_range_type): Likewise. Also, fix call to init_integer_type
2227 with erroneous length argument.
2228
2229 * ada-lang.c (ada_language_arch_info): Update call to arch_type.
2230 * d-lang.c (build_d_types): Likewise.
2231 * f-lang.c (build_fortran_types): Likewise.
2232 * go-lang.c (build_go_types): Likewise.
2233 * opencl-lang.c (build_opencl_types): Likewise.
2234 * jit.c (finalize_symtab): Likewise.
2235 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
2236 (build_std_type_info_type): Likewise.
2237 * target-descriptions.c (tdesc_gdb_type): Likewise. Also,
2238 update call to arch_flags_type.
2239
2240 * linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
2241 arch_type.
2242 * fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
2243 * windows-tdep.c (windows_get_tlb_type): Likewise.
2244
2245 * avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
2246 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
2247 * m32c-tdep.c (make_types): Likewise.
2248 * rl78-tdep.c (rl78_gdbarch_init): Likewise.
2249 (rl78_psw_type): Update call to arch_flags_type.
2250 * m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
2251 * rx-tdep.c (rx_psw_type): Likewise.
2252 (rx_fpsw_type): Likewise.
2253 * sparc-tdep.c (sparc_psr_type): Likewise.
2254 (sparc_fsr_type): Likewise.
2255 * sparc64-tdep.c (sparc64_pstate_type): Likewise.
2256 (sparc64_ccr_type): Likewise.
2257 (sparc64_fsr_type): Likewise.
2258 (sparc64_fprs_type): Likewise.
2259
f21b4d5c
TT
22602017-09-27 Tom Tromey <tom@tromey.com>
2261
2262 * findcmd.c (find_command): Constify.
2263
643c2ffa
TT
22642017-09-27 Tom Tromey <tom@tromey.com>
2265
2266 * ada-tasks.c (task_command_1, task_command): Constify.
2267
510e5e56
TT
22682017-09-27 Tom Tromey <tom@tromey.com>
2269
2270 * symtab.c (maintenance_print_symbol_cache)
2271 (maintenance_flush_symbol_cache)
2272 (maintenance_print_symbol_cache_statistics): Constify.
2273
e503b191
TT
22742017-09-27 Tom Tromey <tom@tromey.com>
2275
2276 * inferior.c (detach_inferior_command, kill_inferior_command)
2277 (inferior_command): Constify.
2278
4e001312
TT
22792017-09-27 Tom Tromey <tom@tromey.com>
2280
2281 * regcache.c (regcache_print, maintenance_print_registers)
2282 (maintenance_print_raw_registers)
2283 (maintenance_print_cooked_registers)
2284 (maintenance_print_register_groups)
2285 (maintenance_print_remote_registers): Constify.
2286
77763700
TT
22872017-09-27 Tom Tromey <tom@tromey.com>
2288
2289 * printcmd.c (map_display_numbers, undisplay_command)
2290 (enable_disable_display_command, enable_display_command)
2291 (disable_display_command): Constify.
2292
4495129a
TT
22932017-09-27 Tom Tromey <tom@tromey.com>
2294
2295 * breakpoint.h (delete_command): Don't declare.
2296 * breakpoint.c (delete_command, enable_once_command)
2297 (enable_count_command, enable_delete_command, breakpoint_1)
2298 (maintenance_info_breakpoints, stopin_command, stopat_command)
2299 (delete_command, delete_trace_command, save_breakpoints)
2300 (save_breakpoints_command, save_tracepoints_command): Constify.
2301
3088cf40
TT
23022017-09-27 Tom Tromey <tom@tromey.com>
2303
2304 * macrocmd.c (macro_expand_command, macro_expand_once_command)
2305 (skip_ws, extract_identifier, macro_define_command)
2306 (macro_undef_command, macro_list_command): Constify.
2307
69f476a3
TT
23082017-09-27 Tom Tromey <tom@tromey.com>
2309
2310 * infcmd.c (environment_info, set_environment_command)
2311 (unset_environment_command, path_info, info_proc_cmd_1)
2312 (info_proc_cmd_mappings, info_proc_cmd_stat)
2313 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
2314 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
2315
c4a3e68e
TT
23162017-09-27 Tom Tromey <tom@tromey.com>
2317
2318 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
2319 Constify.
2320
c9d31bd6
TT
23212017-09-27 Tom Tromey <tom@tromey.com>
2322
2323 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
2324
1f3f85eb
TT
23252017-09-27 Tom Tromey <tom@tromey.com>
2326
2327 * demangle.c (demangle_command): Constify.
2328
9c504b5d
TT
23292017-09-27 Tom Tromey <tom@tromey.com>
2330
2331 * progspace.c (maintenance_info_program_spaces_command):
2332 Constify.
2333
6663cf91
TT
23342017-09-27 Tom Tromey <tom@tromey.com>
2335
2336 * compile/compile.c (check_raw_argument, compile_file_command)
2337 (compile_code_command, compile_print_command): Constify.
2338
34e5fa26
TT
23392017-09-27 Tom Tromey <tom@tromey.com>
2340
2341 * reggroups.c (maintenance_print_reggroups): Constify.
2342
8384c356
TT
23432017-09-27 Tom Tromey <tom@tromey.com>
2344
2345 * dwarf2read.c (save_gdb_index_command): Constify.
2346
884beb0c
TT
23472017-09-27 Tom Tromey <tom@tromey.com>
2348
2349 * stap-probe.c (info_probes_stap_command): Constify.
2350
e0b2930c
TT
23512017-09-27 Tom Tromey <tom@tromey.com>
2352
2353 * fork-child.c (unset_exec_wrapper_command): Constify.
2354
f938677d
TT
23552017-09-27 Tom Tromey <tom@tromey.com>
2356
2357 * btrace.c (get_uint, get_context_size, no_chunk)
2358 (maint_btrace_packet_history_cmd)
2359 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
2360 (maint_info_btrace_cmd): Constify.
2361
8949cb87
TT
23622017-09-27 Tom Tromey <tom@tromey.com>
2363
2364 * reverse.c (delete_bookmark_command): Constify.
2365
ac88e2de
TT
23662017-09-27 Tom Tromey <tom@tromey.com>
2367
2368 * remote.c (set_memory_packet_size)
2369 (set_memory_write_packet_size, show_memory_write_packet_size)
2370 (set_memory_read_packet_size, show_memory_read_packet_size)
2371 (compare_sections_command, packet_command, remote_put_command)
2372 (remote_get_command, remote_delete_command): Constify.
2373
bd4c9dfe
TT
23742017-09-27 Tom Tromey <tom@tromey.com>
2375
2376 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
2377 (set_mipsfpu_double_command, set_mipsfpu_none_command)
2378 (set_mipsfpu_auto_command): Constify.
2379
5e93d4c6
TT
23802017-09-27 Tom Tromey <tom@tromey.com>
2381
2382 * cli/cli-cmds.h (cd_command): Constify.
2383 * cli/cli-cmds.c (cd_command): Constify.
2384
fc41a75b
TT
23852017-09-27 Tom Tromey <tom@tromey.com>
2386
2387 * thread.c (thread_name_command, thread_find_command): Constify.
2388
67810076
TT
23892017-09-27 Tom Tromey <tom@tromey.com>
2390
2391 * probe.c (enable_probes_command, disable_probes_command):
2392 Constify.
2393
1d8b34a7
TT
23942017-09-27 Tom Tromey <tom@tromey.com>
2395
2396 * symfile.c (symbol_file_command): Constify.
2397 * gdbcore.h (deprecated_file_changed_hook): Constify.
2398 * exec.c (deprecated_file_changed_hook, exec_file_command)
2399 (file_command): Constify.
2400 * defs.h (symbol_file_command): Constify.
2401
442019e1
TT
24022017-09-27 Tom Tromey <tom@tromey.com>
2403
2404 * remote-fileio.c (set_system_call_allowed)
2405 (show_system_call_allowed): Constify.
2406
2983f7cb
TT
24072017-09-27 Tom Tromey <tom@tromey.com>
2408
2409 * tracepoint.c (delete_trace_variable_command)
2410 (tfind_end_command, tfind_start_command, tfind_pc_command)
2411 (tfind_tracepoint_command, tfind_line_command)
2412 (tfind_range_command, tfind_outside_command): Constify.
2413
4fd41b24
TT
24142017-09-27 Tom Tromey <tom@tromey.com>
2415
2416 * ax-gdb.c (maint_agent_printf_command, agent_command)
2417 (agent_eval_command): Constify.
2418
f2fc3015
TT
24192017-09-27 Tom Tromey <tom@tromey.com>
2420
2421 * tracepoint.c (info_scope_command): Constify.
2422 * python/python.c (gdbpy_decode_line): Constify.
2423 * python/py-breakpoint.c (bppy_init): Constify.
2424 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
2425 * location.h: (new_linespec_location)
2426 (string_to_event_location_basic, string_to_event_location):
2427 Constify.
2428 * location.c (new_linespec_location)
2429 (string_to_event_location_basic, string_to_event_location):
2430 Constify.
2431 * linespec.h (decode_line_with_current_source)
2432 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
2433 * linespec.c (linespec_lex_to_end)
2434 (decode_line_with_current_source)
2435 (decode_line_with_last_displayed): Constify.
2436 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
2437 Constify.
2438 * cli/cli-cmds.c (edit_command, list_command): Constify.
2439 * breakpoint.h (until_break_command, watch_command_wrapper)
2440 (awatch_command_wrapper, rwatch_command_wrapper)
2441 (init_ada_exception_breakpoint): Constify.
2442 * breakpoint.c (break_command_1, dprintf_command)
2443 (break_range_command, watch_command_wrapper)
2444 (rwatch_command_wrapper, awatch_command_wrapper)
2445 (until_break_command, init_ada_exception_breakpoint)
2446 (strace_marker_create_sals_from_location, trace_command)
2447 (ftrace_command, strace_command, struct tracepoint): Constify.
2448 * ax-gdb.c (agent_command_1): Constify.
2449 * ada-lang.c (ada_exception_sal): Constify.
2450
8c2f95f4
TT
24512017-09-27 Tom Tromey <tom@tromey.com>
2452
2453 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
2454 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
2455 (get_context_size, no_chunk, get_insn_history_modifiers)
2456 (cmd_record_insn_history, get_call_history_modifiers)
2457 (cmd_record_call_history): Constify.
2458
a0d65762
TT
24592017-09-27 Tom Tromey <tom@tromey.com>
2460
2461 * source.c (show_substitute_path_command)
2462 (unset_substitute_path_command, set_substitute_path_command):
2463 Constify.
2464
58971144
TT
24652017-09-27 Tom Tromey <tom@tromey.com>
2466
2467 * typeprint.c (maintenance_print_type): Constify.
2468 * maint.c (maintenance_dump_me, maintenance_demangle)
2469 (maintenance_time_display, maintenance_info_sections)
2470 (maintenance_print_statistics, maintenance_deprecate)
2471 (maintenance_undeprecate): Constify.
2472 (maintenance_do_deprecate): Constify. Use std::string.
2473 (maintenance_selftest): Constify.
2474 * gdbtypes.h (maintenance_print_type): Constify.
2475
c482f52c
TT
24762017-09-27 Tom Tromey <tom@tromey.com>
2477
2478 * hppa-tdep.c (unwind_command): Constify.
2479
e100df1a
TT
24802017-09-27 Tom Tromey <tom@tromey.com>
2481
2482 * target-descriptions.c (unset_tdesc_filename_cmd)
2483 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
2484 Constify.
2485
31d56ade
TT
24862017-09-27 Tom Tromey <tom@tromey.com>
2487
2488 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
2489
b961da0b
TT
24902017-09-27 Tom Tromey <tom@tromey.com>
2491
2492 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
2493
e2d8ae16
TT
24942017-09-27 Tom Tromey <tom@tromey.com>
2495
2496 * tui/tui-regs.c (tui_reg_command): Constify.
2497
863779b0
TT
24982017-09-27 Tom Tromey <tom@tromey.com>
2499
2500 * skip.c (skip_file_command, skip_function_command)
2501 (skip_enable_command, skip_disable_command, skip_delete_command):
2502 Constify.
2503
cdb34d4a
TT
25042017-09-27 Tom Tromey <tom@tromey.com>
2505
2506 * record-btrace.c (cmd_record_btrace_bts_start)
2507 (cmd_record_btrace_pt_start): Constify.
2508
e99c83e7
TT
25092017-09-27 Tom Tromey <tom@tromey.com>
2510
2511 * symmisc.c (maintenance_print_symbols)
2512 (maintenance_print_msymbols, maintenance_print_objfiles)
2513 (maintenance_info_symtabs, maintenance_check_symtabs)
2514 (maintenance_expand_symtabs, maintenance_info_line_tables):
2515 Constify.
2516
32faf971
TT
25172017-09-27 Tom Tromey <tom@tromey.com>
2518
2519 * top.c (new_ui_command): Constify.
2520
2cf311eb
TT
25212017-09-27 Tom Tromey <tom@tromey.com>
2522
2523 * symfile.c (add_symbol_file_command)
2524 (remove_symbol_file_command, list_overlays_command)
2525 (map_overlay_command, unmap_overlay_command)
2526 (overlay_auto_command, overlay_manual_command)
2527 (overlay_off_command, overlay_load_command): Constify.
2528
e6738699
TT
25292017-09-27 Tom Tromey <tom@tromey.com>
2530
2531 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
2532 (info_spu_mailbox_command, info_spu_dma_command)
2533 (info_spu_proxydma_command): Constify.
2534
aa360cd5
TT
25352017-09-27 Tom Tromey <tom@tromey.com>
2536
2537 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
2538
898241a5
TT
25392017-09-27 Tom Tromey <tom@tromey.com>
2540
2541 * cli/cli-script.c (user_defined_command): Constify.
2542
2d0ac106
TT
25432017-09-27 Tom Tromey <tom@tromey.com>
2544
2545 * cli/cli-dump.c (dump_memory_command, dump_value_command)
2546 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
2547 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
2548 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
2549 (dump_binary_value, append_binary_memory, append_binary_value):
2550 Constify.
2551 (struct dump_context) <func>: Constify.
2552 (add_dump_command): Update.
2553
dede02ce
TT
25542017-09-27 Tom Tromey <tom@tromey.com>
2555
2556 * cli/cli-cmds.c (show_version, show_configuration)
2557 (source_command, show_user): Constify.
2558
d3cb6b99
TT
25592017-09-27 Tom Tromey <tom@tromey.com>
2560
2561 * target.c (maintenance_print_target_stack): Constify.
2562
1970a12f
TT
25632017-09-27 Tom Tromey <tom@tromey.com>
2564
2565 * interps.c (interpreter_exec_cmd): Constify.
2566
41243651
TT
25672017-09-27 Tom Tromey <tom@tromey.com>
2568
2569 * record-full.c (cmd_record_full_restore): Constify.
2570
4465d9db
TT
25712017-09-27 Tom Tromey <tom@tromey.com>
2572
2573 * memattr.c (enable_mem_command, disable_mem_command)
2574 (delete_mem_command): Constify.
2575
ad25e423
TT
25762017-09-27 Tom Tromey <tom@tromey.com>
2577
2578 * value.c (show_convenience): Constify.
2579
d64097b1
TT
25802017-09-27 Tom Tromey <tom@tromey.com>
2581
2582 * gdbcore.h (core_file_command): Update.
2583 * corefile.c (core_file_command): Constify.
2584
4d4589ef
TT
25852017-09-27 Tom Tromey <tom@tromey.com>
2586
2587 * user-regs.c (maintenance_print_user_registers): Constify.
2588
32a7bf17
TT
25892017-09-27 Tom Tromey <tom@tromey.com>
2590
2591 * cp-namespace.c (maintenance_cplus_namespace): Constify.
2592
4a475551
TT
25932017-09-27 Tom Tromey <tom@tromey.com>
2594
2595 * cp-support.c (first_component_command): Constify.
2596
990b9f9f
TT
25972017-09-27 Tom Tromey <tom@tromey.com>
2598
2599 * psymtab.c (maintenance_print_psymbols)
2600 (maintenance_info_psymtabs, maintenance_check_psymtabs):
2601 Constify.
2602
c281872e
TT
26032017-09-27 Tom Tromey <tom@tromey.com>
2604
2605 * windows-tdep.c (display_tib): Constify.
2606
5b64bf74
TT
26072017-09-27 Tom Tromey <tom@tromey.com>
2608
2609 * linux-fork.c (delete_checkpoint_command)
2610 (detach_checkpoint_command): Constify.
2611
4ada038f
TT
26122017-09-27 Tom Tromey <tom@tromey.com>
2613
2614 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
2615
57f5a81b
TT
26162017-09-27 Tom Tromey <tom@tromey.com>
2617
2618 * arc-tdep.c (dump_arc_instruction_command): Constify.
2619
b0a8e6c4
TT
26202017-09-27 Tom Tromey <tom@tromey.com>
2621
2622 * valprint.c (set_radix, show_radix): Constify.
2623
8d97dc1c
TT
26242017-09-27 Tom Tromey <tom@tromey.com>
2625
2626 * dtrace-probe.c (info_probes_dtrace_command): Constify.
2627
eb7c454d
TT
26282017-09-27 Tom Tromey <tom@tromey.com>
2629
2630 * command.h (not_just_help_class_command): Update.
2631 * cli/cli-decode.h (not_just_help_class_command): Update.
2632 * cli/cli-decode.c (not_just_help_class_command): Constify.
2633
e4e33335
TT
26342017-09-27 Tom Tromey <tom@tromey.com>
2635
2636 * gdb_bfd.c (maintenance_info_bfds): Constify.
2637
0450cc4c
TT
26382017-09-27 Tom Tromey <tom@tromey.com>
2639
2640 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
2641 overloads.
2642 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
2643 (do_const_cfunc): New function.
2644 (cmd_cfunc_eq): New overload.
2645 (cli_user_command_p): Check do_const_cfunc.
2646 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
2647 const_cfunc.
2648 * command.h (add_cmd): Add const overload and no-function
2649 overload.
2650 (set_cmd_cfunc): Add const overload.
2651 (cmd_const_cfunc_ftype): Declare.
2652 (cmd_cfunc_eq): Add const overload.
2653 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
2654 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
2655 overload.
2656
a9bbfbd8
TT
26572017-09-27 Tom Tromey <tom@tromey.com>
2658
2659 * macroexp.c (get_next_token_for_substitution): New function.
2660 (substitute_args): Call it. Check for __VA_OPT__.
2661
5230b05a
WT
26622017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
2663 Pedro Alves <palves@redhat.com>
2664
2665 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
2666 producer_is_icc_lt_14.
2667 (producer_is_icc_lt_14): New function.
2668 (check_producer): Add code for checking version of ICC.
2669 (producer_is_icc): Move to producer.c.
2670 (read_structure_type): Restrict ICC workaround to ICC<14.
2671 * producer.c: Include selftest.h.
2672 (producer_is_icc, producer_parsing_tests, _initialize_producer):
2673 New functions.
2674 * producer.h (producer_is_icc): New declaration.
2675
b32b108a
WT
26762017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
2677
2678 * Makefile.in (SFILES): Add producer.c.
2679 (COMMON_OBS): Add producer.o
2680 * amd64-tdep.c (producer.h): Add new include.
2681 * dwarf2read.c (producer.h): Add new include.
2682 * producer.c: New file.
2683 * producer.h: New file.
2684 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
2685 producer.c.
2686 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
2687 producer.h.
2688
5007d765
MK
26892017-09-26 Matthias Klose <doko@ubuntu.com>
2690
2691 * configure.ac: Search ncursesw before ncurses.
2692 Check ncursesw/ncurses.h before ncurses/ncurses.h.
2693 * gdb_curses.h: Include <ncursesw/ncurses.h>
2694 * config.in, configure: Regenerate.
2695
281c4447
RO
26962017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2697
2698 PR gdb/22185
2699 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
2700 obsolete.
2701 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
2702 Remove i386sol2 support.
2703 * configure.nat <i386sol2>: Remove.
2704 <sol2-64>: Fold into ...
2705 <sol2>: ... this.
2706 Move common settings to default section.
2707 Add sol-thread.o.
2708 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
2709 x86_64-*-solaris2.1[0-9]*>: Rename to ...
2710 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
2711 <i[34567]86-*-solaris*>: Remove.
2712 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
2713
2714 * configure.ac: Remove wctype in libw check.
2715 (_MSE_INT_H): Don't define on Solaris 7-9.
2716 <solaris*>: Remove libthread_db.so.1 check.
2717 * configure: Regenerate.
2718 * config.in: Regenerate.
2719
2720 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
2721 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
2722 (gdb_ps_size_t): Remove.
2723 Use base types in users.
2724 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
2725
2726 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
2727
39b06c20
RO
27282017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2729
2730 PR build/22206
2731 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
2732 (adi_is_addr_mapped): Likewise.
2733 (PSR_ICC): Don't redefine.
2734 (PSR_IMPL): Likewise.
2735
6c3e20f1
TT
27362017-09-25 Tom Tromey <tom@tromey.com>
2737
2738 * regcache.c (regcache::dump): Use string_printf.
2739
b292235f
TT
27402017-09-25 Tom Tromey <tom@tromey.com>
2741
2742 * regcache.c (class regcache_invalidator): New.
2743 (struct register_to_invalidate): Remove.
2744 (make_cleanup_regcache_invalidate): Remove.
2745 (regcache::raw_write): Use regcache_invalidator.
2746
9ac86b52
TT
27472017-09-25 Tom Tromey <tom@tromey.com>
2748
2749 * spu-tdep.c (spu2ppu_sniffer): Update.
2750 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
2751 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
2752 Remove.
2753 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
2754 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
2755 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
2756 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
2757 (frame_pop): Update.
2758
c0e383c6
TT
27592017-09-25 Tom Tromey <tom@tromey.com>
2760
2761 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
2762 * regcache.h (regcache_xfree): Don't declare.
2763 * regcache.c (regcache_xfree): Remove.
2764 (do_regcache_xfree): Use delete.
2765 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
2766 * linux-fork.c (free_fork): Use delete.
2767 (fork_save_infrun_state): Likewise.
2768 * jit.c (jit_dealloc_cache): Use delete.
2769 * infrun.c (discard_infcall_suspend_state): Use delete.
2770
791199cc
TT
27712017-09-25 Tom Tromey <tom@tromey.com>
2772
2773 * regcache.h (regcache_xmalloc): Don't declare.
2774 (regcache_raw_set_cached_value): Update comment.
2775 * regcache.c (regcache_xmalloc): Remove.
2776 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
2777 * jit.c (jit_frame_sniffer): Use new.
2778 * frame.c (frame_save_as_regcache): Use new.
2779
289e23aa
AA
27802017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
2781
2782 * NEWS: Advertise support for guarded-storage registers on IBM z.
2783
1b63490c
AA
27842017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
2785
2786 * s390-linux-nat.c (have_regset_gs): New static variable.
2787 (s390_linux_fetch_inferior_registers): Handle guarded-storage
2788 control block and guarded-storage broadcast control regsets.
2789 (s390_read_description): Detect whether the target has
2790 guarded-storage support, return appropriate tdesc.
2791 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
2792 (features/s390x-gs-linux64.c): Likewise.
2793 (struct gdbarch_tdep) <have_gs>: New field.
2794 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
2795 (s390_gsbc_regset): New variables.
2796 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
2797 and s390_gsbc_regset, if applicable.
2798 (s390_core_read_description): Check whether core file was from a
2799 target with guarded-storage support; include appropriate regsets.
2800 (s390_gdbarch_init): Add registers for guarded-storage support.
2801 (_initialize_s390_tdep): Initialize new target descriptions that
2802 include registers for guarded-storage support.
2803 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
2804 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
2805 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
2806 (S390_NUM_REGS): Adjust macro definition.
2807 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
2808 (tdesc_s390x_gs_linux64): New declarations.
2809
96235dc1
AA
28102017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
2811
2812 * features/s390-gs-linux64.xml: New file.
2813 * features/s390-gs.xml: New file.
2814 * features/s390-gsbc.xml: New file.
2815 * features/s390x-gs-linux64.xml: New file.
2816 * features/Makefile (WHICH): Add s390-gs-linux64 and
2817 s390x-gs-linux64.
2818 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
2819 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
2820 * features/s390-gs-linux64.c: New generated file.
2821 * features/s390x-gs-linux64.c: New file.
2822 * regformats/s390-gs-linux64.dat: New file.
2823 * regformats/s390x-gs-linux64.dat: New file.
2824
b4a7c699
TT
28252017-09-23 Tom Tromey <tom@tromey.com>
2826
2827 * defs.h (make_cleanup_override_quit_handler): Don't declare.
2828
c2f97536
TT
28292017-09-22 Tom Tromey <tom@tromey.com>
2830
2831 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
2832 type to scoped_restore_tmpl.
2833 <scoped_input_handler>: Initialize m_quit_handler directly.
2834
43573013
SDJ
28352017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
2836
2837 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
2838 (cd_command): Likewise. Free "current_directory" before
2839 assigning to it.
2840 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
2841 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
2842 * top.c (gdb_dirbuf): Remove global declaration.
2843 * top.h (gdb_dirbuf): Likewise.
2844
6ec2e0f5
SDJ
28452017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
2846
2847 * gnulib/aclocal.m4: Regenerate.
2848 * gnulib/config.in: Regenerate.
2849 * gnulib/configure: Regenerate.
2850 * gnulib/import/Makefile.am: Regenerate.
2851 * gnulib/import/Makefile.in: Regenerate.
2852 * gnulib/import/assure.h: New file.
2853 * gnulib/import/at-func.c: Likewise
2854 * gnulib/import/chdir-long.c: New file.
2855 * gnulib/import/chdir-long.h: New file.
2856 * gnulib/import/cloexec.c: New file.
2857 * gnulib/import/cloexec.h: New file.
2858 * gnulib/import/close.c: New file.
2859 * gnulib/import/closedir.c: New file.
2860 * gnulib/import/dirent-private.h: New file.
2861 * gnulib/import/dup-safer.c: New file.
2862 * gnulib/import/dup.c: New file.
2863 * gnulib/import/dup2.c: New file.
2864 * gnulib/import/error.c: New file.
2865 * gnulib/import/error.h: New file.
2866 * gnulib/import/exitfail.c: New file.
2867 * gnulib/import/exitfail.h: New file.
2868 * gnulib/import/fchdir.c: New file.
2869 * gnulib/import/fcntl.c: New file.
2870 * gnulib/import/fcntl.in.h: New file.
2871 * gnulib/import/fd-hook.c: New file.
2872 * gnulib/import/fd-hook.h: New file.
2873 * gnulib/import/fd-safer.c: New file.
2874 * gnulib/import/fdopendir.c: New file.
2875 * gnulib/import/filename.h: New file.
2876 * gnulib/import/filenamecat-lgpl.c: New file.
2877 * gnulib/import/filenamecat.h: New file.
2878 * gnulib/import/fstat.c: New file.
2879 * gnulib/import/fstatat.c: New file.
2880 * gnulib/import/getcwd-lgpl.c: New file.
2881 * gnulib/import/getcwd.c: New file.
2882 * gnulib/import/getdtablesize.c: New file.
2883 * gnulib/import/getlogin_r.c: New file.
2884 * gnulib/import/getprogname.c: New file.
2885 * gnulib/import/getprogname.h: New file.
2886 * gnulib/import/gettext.h: New file.
2887 * gnulib/import/glob-libc.h: New file.
2888 * gnulib/import/glob.c: New file.
2889 * gnulib/import/glob.in.h: New file.
2890 * gnulib/import/intprops.h: New file.
2891 * gnulib/import/m4/chdir-long.m4: New file.
2892 * gnulib/import/m4/close.m4: New file.
2893 * gnulib/import/m4/closedir.m4: New file.
2894 * gnulib/import/m4/d-ino.m4: New file.
2895 * gnulib/import/m4/d-type.m4: New file.
2896 * gnulib/import/m4/dup.m4: New file.
2897 * gnulib/import/m4/dup2.m4: New file.
2898 * gnulib/import/m4/error.m4: New file.
2899 * gnulib/import/m4/fchdir.m4: New file.
2900 * gnulib/import/m4/fcntl.m4: New file.
2901 * gnulib/import/m4/fcntl_h.m4: New file.
2902 * gnulib/import/m4/fdopendir.m4: New file.
2903 * gnulib/import/m4/filenamecat.m4: New file.
2904 * gnulib/import/m4/fstat.m4: New file.
2905 * gnulib/import/m4/fstatat.m4: New file.
2906 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
2907 * gnulib/import/m4/getcwd-path-max.m4: New file.
2908 * gnulib/import/m4/getcwd.m4: New file.
2909 * gnulib/import/m4/getdtablesize.m4: New file.
2910 * gnulib/import/m4/getlogin_r.m4: New file.
2911 * gnulib/import/m4/getprogname.m4: New file.
2912 * gnulib/import/m4/glob.m4: New file.
2913 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
2914 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
2915 * gnulib/import/m4/mempcpy.m4: New file.
2916 * gnulib/import/m4/memrchr.m4: New file.
2917 * gnulib/import/m4/mode_t.m4: New file.
2918 * gnulib/import/m4/msvc-inval.m4: New file.
2919 * gnulib/import/m4/msvc-nothrow.m4: New file.
2920 * gnulib/import/m4/open.m4: New file.
2921 * gnulib/import/m4/openat.m4: New file.
2922 * gnulib/import/m4/opendir.m4: New file.
2923 * gnulib/import/m4/readdir.m4: New file.
2924 * gnulib/import/m4/realloc.m4: New file.
2925 * gnulib/import/m4/rewinddir.m4: New file.
2926 * gnulib/import/m4/save-cwd.m4: New file.
2927 * gnulib/import/m4/strdup.m4: New file.
2928 * gnulib/import/m4/strerror.m4: New file.
2929 * gnulib/import/m4/unistd-safer.m4: New file.
2930 * gnulib/import/mempcpy.c: New file.
2931 * gnulib/import/memrchr.c: New file.
2932 * gnulib/import/msvc-inval.c: New file.
2933 * gnulib/import/msvc-inval.h: New file.
2934 * gnulib/import/msvc-nothrow.c: New file.
2935 * gnulib/import/msvc-nothrow.h: New file.
2936 * gnulib/import/open.c: New file.
2937 * gnulib/import/openat-die.c: New file.
2938 * gnulib/import/openat-priv.h: New file.
2939 * gnulib/import/openat-proc.c: New file.
2940 * gnulib/import/openat.c: New file.
2941 * gnulib/import/openat.h: New file.
2942 * gnulib/import/opendir.c: New file.
2943 * gnulib/import/pipe-safer.c: New file.
2944 * gnulib/import/readdir.c: New file.
2945 * gnulib/import/realloc.c: New file.
2946 * gnulib/import/rewinddir.c: New file.
2947 * gnulib/import/save-cwd.c: New file.
2948 * gnulib/import/save-cwd.h: New file.
2949 * gnulib/import/strdup.c: New file.
2950 * gnulib/import/strerror-override.c: New file.
2951 * gnulib/import/strerror-override.h: New file.
2952 * gnulib/import/strerror.c: New file.
2953 * gnulib/import/unistd--.h: New file.
2954 * gnulib/import/unistd-safer.h: New file.
2955 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
2956 "getcwd" and "glob".
2957 * ser-tcp.c: Undefine "close" before redefining it.
2958
432ae719
SM
29592017-09-21 Simon Marchi <simon.marchi@ericsson.com>
2960
2961 * guile/scm-value.c (gdbscm_value_address): Initialize address,
2962 get rid of res_val.
2963
4fa7574e
RO
29642017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2965
2966 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
2967 <sol2,sparc>: Likewise.
2968 <sol2-64,i386>: Likewise.
2969
2970 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
2971 -Wdeprecated-declarations on *-*-solaris*.
2972 * configure: Regenerate.
2973
2974 * procfs.c: Include "nat/inferior.h".
2975 (procfs_info_proc): Fix typo.
2976
f6327dcb
KB
29772017-09-21 Kevin Buettner <kevinb@redhat.com>
2978
2979 * remote.c (vector): Include.
2980 (struct private_thread_info): Add field, thread_handle.
2981 (free_private_thread_info): Deallocate storage associated with
2982 thread handle.
2983 (get_private_info_thread): Initialize `thread_handle' field.
2984 (struct thread_item): Add field, thread_handle.
2985 (clear_threads_listing_context): Deallocate storage associated
2986 with thread handle.
2987 (start_thread): Add support for "handle" attribute.
2988 (thread_attributes): Add "handle".
2989 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
2990 field.
2991 (remote_update_thread_list): Update thread_handle.
2992 (remote_thread_handle_to_thread_info): New function.
2993 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
2994
fbbe5337
KB
29952017-09-21 Kevin Buettner <kevinb@redhat.com>
2996
2997 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
2998 function.
2999 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
3000 * python/python-internal.h (thread_object_type): Declare.
3001
e04ee09e
KB
30022017-09-21 Kevin Buettner <kevinb@redhat.com>
3003
3004 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
3005 (target_thread_handle_to_thread_info): Declare.
3006 * target.c (target_thread_handle_to_thread_info): New function.
3007 * target-delegates.c: Regenerate.
3008 * gdbthread.h (find_thread_by_handle): Declare.
3009 * thread.c (find_thread_by_handle): New function.
3010 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
3011 function.
3012 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
3013
1e5b66ed
SM
30142017-09-21 Simon Marchi <simon.marchi@ericsson.com>
3015
3016 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
3017
ebe48ba0
SM
30182017-09-21 Simon Marchi <simon.marchi@ericsson.com>
3019
3020 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
3021
0a0bf5dc
YQ
30222017-09-21 Yao Qi <yao.qi@linaro.org>
3023
3024 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
3025 to gdb_target_obs.
3026
d1b0a7bf
TT
30272017-09-20 Tom Tromey <tom@tromey.com>
3028
3029 * breakpoint.c (struct counted_command_line): Remove.
3030 (breakpoint_commands): Update.
3031 (alloc_counted_command_line, incref_counted_command_line)
3032 (decref_counted_command_line, do_cleanup_counted_command_line)
3033 (make_cleanup_decref_counted_command_line): Remove.
3034 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
3035 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
3036 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
3037 (save_breakpoints): Update.
3038 * breakpoint.h (counted_command_line): Now a typedef to
3039 shared_ptr.
3040 (struct breakpoint) <commands>: Now a counted_command_line.
3041 (struct bpstats) <command>: Likewise.
3042
48649e1b
TT
30432017-09-20 Tom Tromey <tom@tromey.com>
3044
3045 * breakpoint.c (struct commands_info, do_map_commands_command):
3046 Remove.
3047 (commands_command_1): Update.
3048 (iterate_over_related_breakpoints): Take a function_view.
3049 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
3050 (delete_command): Update.
3051 (map_breakpoint_numbers): Take a function_view.
3052 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
3053 (disable_command): Update.
3054 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
3055 (enable_command): Update.
3056 (struct disp_data, do_enable_breakpoint_disp)
3057 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
3058 (do_map_enable_delete_breakpoint): Remove.
3059 (enable_once_command, enable_count_command, enable_delete_command)
3060 (delete_trace_variable_command): Update.
3061
04afa70c
TT
30622017-09-20 Tom Tromey <tom@tromey.com>
3063
3064 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
3065 (bpstat_clear): Use delete.
3066 (bpstats): New constructors.
3067 (bpstat_copy, bpstat_stop_status): Use new.
3068 (dprintf_after_condition_true): Update.
3069 * breakpoint.h (bpstats::bpstats): Add constructors.
3070 (bpstats::~bpstats): Add destructor.
3071
c83833f4
PA
30722017-09-20 Pedro Alves <palves@redhat.com>
3073
3074 * eval.c (make_params): Delete, refactored as ...
3075 (class fake_method): ... this new type's ctor.
3076 (fake_method::~fake_method): New.
3077 (evaluate_subexp_standard): Use 'fake_method'.
3078
223ffa71
TT
30792017-09-20 Tom Tromey <tom@tromey.com>
3080
3081 * windows-nat.c (get_windows_debug_event, windows_wait)
3082 (do_initial_windows_stuff, windows_attach): Update.
3083 * utils.c (vwarning, internal_vproblem): Update.
3084 (ui_unregister_input_event_handler_cleanup)
3085 (prepare_to_handle_input): Remove.
3086 (class scoped_input_handler): New.
3087 (defaulted_query, prompt_for_continue): Update.
3088 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
3089 Update.
3090 * top.c (undo_terminal_modifications_before_exit): Update.
3091 * target/target.h (target_terminal_init, target_terminal_inferior)
3092 (target_terminal_ours): Don't declare.
3093 (class target_terminal): New.
3094 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
3095 (target_terminal_ours_for_output)
3096 (make_cleanup_restore_target_terminal): Don't declare.
3097 (target_terminal_info): Remove.
3098 * target.c (enum terminal_state, terminal_state): Remove.
3099 (target_terminal::terminal_state): Define.
3100 (target_terminal::init): Rename from target_terminal_init.
3101 (target_terminal::inferior): Rename from
3102 target_terminal_inferior.
3103 (target_terminal::ours): Rename from target_terminal_ours.
3104 (target_terminal::ours_for_output): Rename from
3105 target_terminal_ours_for_output.
3106 (target_terminal::info): New method.
3107 (cleanup_restore_target_terminal)
3108 (make_cleanup_restore_target_terminal): Remove.
3109 * solib.c (handle_solib_event): Update.
3110 * remote.c (remote_serial_quit_handler): Update.
3111 (remote_terminal_inferior, remote_wait_as): Update.
3112 * record-full.c (record_full_wait_1): Update.
3113 * nto-procfs.c (procfs_create_inferior): Update.
3114 * nat/fork-inferior.c (startup_inferior): Update.
3115 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
3116 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
3117 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
3118 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
3119 (mi_breakpoint_created, mi_breakpoint_deleted)
3120 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
3121 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
3122 (mi_user_selected_context_changed, report_initial_inferior):
3123 Update.
3124 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
3125 (linux_nat_terminal_inferior): Update.
3126 * infrun.c (follow_fork_inferior)
3127 (handle_vfork_child_exec_or_exit, do_target_resume)
3128 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
3129 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
3130 Update.
3131 * inflow.c (child_terminal_init, info_terminal_command): Update.
3132 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
3133 (attach_command): Update.
3134 * infcall.c (call_thread_fsm_should_stop): Update.
3135 * gnu-nat.c (gnu_attach): Update.
3136 * extension.c (struct active_ext_lang_state)
3137 (restore_active_ext_lang): Update.
3138 * exceptions.c (print_flush): Update.
3139 * event-top.c (async_enable_stdin, default_quit_handler): Update.
3140 (struct quit_handler_cleanup_data, restore_quit_handler)
3141 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
3142 Remove.
3143 * cp-support.c (gdb_demangle): Update.
3144 * breakpoint.c (update_inserted_breakpoint_locations)
3145 (insert_breakpoint_locations, handle_jit_event)
3146 (disable_breakpoints_in_unloaded_shlib): Update.
3147 * annotate.c (annotate_breakpoints_invalid)
3148 (annotate_frames_invalid): Update.
3149
013af3fc
TT
31502017-09-20 Tom Tromey <tom@tromey.com>
3151
3152 * main.c (catch_command_errors): Rename from
3153 catch_command_errors_const.
3154 (captured_main_1): Update.
3155
06871ae8
PA
31562017-09-20 Pedro Alves <palves@redhat.com>
3157
3158 * cli/cli-cmds.c (list_command): Use print_sal_location.
3159 (print_sal_location): New function.
3160 (ambiguous_line_spec): Use print_sal_location.
3161 * linespec.c (symbol_to_sal): Record the symbol in the sal.
3162 * symtab.c (find_function_start_sal): Likewise.
3163 * symtab.h (symtab_and_line::symbol): New field.
3164
e5f25bc5
PA
31652017-09-20 Pedro Alves <palves@redhat.com>
3166
3167 * linespec.c (minsym_found): Handle non-text minsyms.
3168 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
3169
1b7fa39e
WT
31702017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
3171
3172 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
3173 backslash.
3174
37dd0825
WT
31752017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
3176
3177 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
3178 vmovups instead vmovaps.
3179 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
3180
4e5a4f58
JB
31812017-09-19 John Baldwin <jhb@FreeBSD.org>
3182
3183 * NEWS (Changes since GDB 8.0): Add starti.
3184 * infcmd.c (enum run_break): New.
3185 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
3186 case.
3187 (run_command): Use enum run_how.
3188 (start_command): Likewise.
3189 (starti_command): New function.
3190 (RUN_ARGS_HELP): New macro.
3191 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
3192 commands. Add starti command.
3193
aa70c9f1
YQ
31942017-09-19 Yao Qi <yao.qi@linaro.org>
3195
3196 * Makefile.in (monitor.o): Remove the rule.
3197
d6541620
YQ
31982017-09-19 Yao Qi <yao.qi@linaro.org>
3199
3200 * annotate.h (struct annotate_arg_emitter): Use
3201 DISABLE_COPY_AND_ASSIGN.
3202 * common/refcounted-object.h (refcounted_object): Likewise.
3203 * completer.h (struct completion_result): Likewise.
3204 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
3205 * filename-seen-cache.h (filename_seen_cache): Likewise.
3206 * gdbcore.h (thread_section_name): Likewise.
3207 * gdb_regex.h (compiled_regex): Likewise.
3208 * gdbthread.h (scoped_restore_current_thread): Likewise.
3209 * inferior.h (scoped_restore_current_inferior): Likewise.
3210 * jit.c (jit_reader): Likewise.
3211 * linespec.h (struct linespec_result): Likewise.
3212 * mi/mi-parse.h (struct mi_parse): Likewise.
3213 * nat/fork-inferior.c (execv_argv): Likewise.
3214 * progspace.h (scoped_restore_current_program_space): Likewise.
3215 * python/python-internal.h (class gdbpy_enter): Likewise.
3216 * regcache.h (regcache): Likewise.
3217 * target-descriptions.c (struct tdesc_reg): Likewise.
3218 (struct tdesc_type): Likewise.
3219 (struct tdesc_feature): Likewise.
3220 * ui-out.h (ui_out_emit_type): Likewise.
3221
0615127c
SM
32222017-09-18 Simon Marchi <simon.marchi@ericsson.com>
3223
3224 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
3225 label abort_expression.
3226
5e187554
SM
32272017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3228
3229 * common/buffer.c (buffer_xml_printf): Adjust.
3230 * common/xml-utils.c (xml_escape_text): Change return type to
3231 std::string, update code accordingly.
3232 * common/xml-utils.h (xml_escape_text): Change return type to
3233 std::string.
3234 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
3235 * windows-tdep.c (windows_xfer_shared_library): Adjust.
3236 * unittests/xml-utils-selftests.c (test_xml_escape_text):
3237 Adjust.
3238
c3d7b541
SM
32392017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3240
3241 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
3242 (SUBDIR_UNITTESTS_OBS): Add new object file.
3243 * unittests/xml-utils-selftests.c: New file.
3244
1526853e
SM
32452017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3246
3247 * common/selftest.h (selftest): New struct/interface.
3248 (register_test): Add name parameter, add new overload.
3249 (run_tests): Add filter parameter.
3250 (for_each_selftest_ftype): New typedef.
3251 (for_each_selftest): New declaration.
3252 * common/selftest.c (tests): Change type to
3253 map<string, unique_ptr<selftest>>.
3254 (simple_selftest): New struct.
3255 (register_test): New function.
3256 (register_test): Add name parameter and use it.
3257 (run_tests): Add filter parameter and use it. Add prints.
3258 Adjust to vector -> map change.
3259 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
3260 registering selftests.
3261 * arm-tdep.c (_initialize_arm_tdep): Likewise.
3262 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
3263 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
3264 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
3265 * findvar.c (_initialize_findvar): Likewise.
3266 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
3267 * maint.c (maintenance_selftest): Update call to run_tests.
3268 (maintenance_info_selftests): New function.
3269 (_initialize_maint_cmds): Register "maintenance info selftests"
3270 command. Update "maintenance selftest" doc.
3271 * regcache.c (_initialize_regcache): Add names when registering
3272 selftests.
3273 * rust-exp.y (_initialize_rust_exp): Likewise.
3274 * selftest-arch.c (gdbarch_selftest): New struct.
3275 (gdbarch_tests): Remove.
3276 (register_test_foreach_arch): Add name parameter. Call
3277 register_test.
3278 (tests_with_arch): Remove, move most content to
3279 gdbarch_selftest::operator().
3280 (_initialize_selftests_foreach_arch): Remove.
3281 * selftest-arch.h (register_test_foreach_arch): Add name
3282 parameter.
3283 (run_tests_with_arch): New declaration.
3284 * utils-selftests.c (_initialize_utils_selftests): Add names
3285 when registering selftests.
3286 * utils.c (_initialize_utils): Likewise.
3287 * unittests/array-view-selftests.c
3288 (_initialize_array_view_selftests): Likewise.
3289 * unittests/environ-selftests.c (_initialize_environ_selftests):
3290 Likewise.
3291 * unittests/function-view-selftests.c
3292 (_initialize_function_view_selftests): Likewise.
3293 * unittests/offset-type-selftests.c
3294 (_initialize_offset_type_selftests): Likewise.
3295 * unittests/optional-selftests.c
3296 (_initialize_optional_selftests): Likewise.
3297 * unittests/scoped_restore-selftests.c
3298 (_initialize_scoped_restore_selftests): Likewise.
3299 * NEWS: Document "maintenance selftest" and "maint info
3300 selftests".
3301
5846367a
SM
33022017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3303
3304 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
3305 scoped_restore.
3306
bd77e8ff
SM
33072017-09-16 Simon Marchi <simon.marchi@ericsson.com>
3308
3309 * mi/mi-main.c (mi_load_progress): Make uiout variable
3310 a unique_ptr.
3311
26a67918
PA
33122017-09-15 Pedro Alves <palves@redhat.com>
3313
3314 * compile/compile-c-types.c (convert_enum, convert_int)
3315 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
3316
3f8a7804
SM
33172017-09-15 Simon Marchi <simon.marchi@ericsson.com>
3318
3319 * dwarf2read.c (copy_string): Remove.
3320 (parse_macro_definition): Replace copy_string with savestring.
3321
8d200706
YQ
33222017-09-15 Yao Qi <yao.qi@linaro.org>
3323
3324 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
3325 gdb_target_obs.
3326 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
3327 Likewise.
3328 (i[34567]86-*-linux*): Likewise.
3329
d185219d
SM
33302017-09-14 Simon Marchi <simon.marchi@ericsson.com>
3331
3332 * dwarf2expr.h (dwarf_stack_value): Add constructor.
3333 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
3334 <stack>: Change type to std::vector.
3335 <stack_len, stack_allocated>: Remove.
3336 <grow_stack>: Remove.
3337 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
3338 (dwarf_expr_context::~dwarf_expr_context): Remove.
3339 (dwarf_expr_context::grow_stack): Remove.
3340 (dwarf_expr_context::push): Adjust.
3341 (dwarf_expr_context::pop): Adjust.
3342 (dwarf_expr_context::fetch): Adjust.
3343 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
3344 (dwarf_expr_context::stack_empty_p): Adjust.
3345 (dwarf_expr_context::execute_stack_op): Adjust.
3346
eccd80d6
SM
33472017-09-14 Simon Marchi <simon.marchi@ericsson.com>
3348
3349 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
3350 return type to bool.
3351 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
3352
69009882
SM
33532017-09-14 Simon Marchi <simon.marchi@ericsson.com>
3354
3355 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
3356 Change type to bool.
3357 (dwarf_stack_value) <in_stack_memory>: Likewise.
3358 (dwarf_expr_context) <push_address>: Change parameter type to
3359 bool.
3360 <fetch_in_stack_memory>: Change return type to bool.
3361 <push>: Change parameter type to bool.
3362 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
3363 to bool.
3364 (dwarf_expr_context::push_address): Likewise.
3365 (dwarf_expr_context::fetch_in_stack_memory): Change return type
3366 to bool.
3367 (dwarf_expr_context::execute_stack_op): Adjust.
3368 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
3369
1e467161
SM
33702017-09-14 Simon Marchi <simon.marchi@ericsson.com>
3371
3372 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
3373 (struct dwarf_expr_context) <n_pieces>: Remove.
3374 <pieces>: Change type to std::vector.
3375 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
3376 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
3377 pieces.
3378 (dwarf_expr_context::add_piece): Adjust.
3379 * dwarf2loc.c (struct piece_closure): Initialize fields.
3380 <n_pieces>: Remove.
3381 <pieces>: Change type to std::vector.
3382 (allocate_piece_closure): Adjust, change parameter to
3383 std::vector rvalue and std::move it to piece_closure.
3384 (rw_pieced_value): Adjust.
3385 (check_pieced_synthetic_pointer): Adjust.
3386 (indirect_synthetic_pointer): Adjust.
3387 (coerce_pieced_ref): Adjust.
3388 (free_pieced_value_closure): Adjust. Use delete to free
3389 piece_closure.
3390 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
3391 to allocate_piece_closure.
3392 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
3393
0782db84
SM
33942017-09-12 Simon Marchi <simon.marchi@ericsson.com>
3395
3396 * probe.h (probe_ops_cp): Remove typedef.
3397 (DEF_VEC_P (probe_ops_cp)): Remove.
3398 (all_probe_ops): Change type to std::vector.
3399 * probe.c (info_probes_for_ops): Adjust to vector change.
3400 (probe_linespec_to_ops): Likewise.
3401 (all_probe_ops): Change type to std::vector.
3402 (_initialize_probe): Adjust to vector change.
3403 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
3404 * elfread.c (elf_get_probes): Likewise.
3405 * stap-probe.c (_initialize_stap_probe): Likewise.
3406
1eac6bea
SM
34072017-09-12 Simon Marchi <simon.marchi@ericsson.com>
3408
3409 * probe.h (struct bound_probe): Define constructors.
3410 * probe.c (bound_probe_s): Remove typedef.
3411 (DEF_VEC_O (bound_probe_s)): Remove VEC.
3412 (collect_probes): Change return type to std::vector, remove
3413 cleanup.
3414 (compare_probes): Return bool, change parameter type. Change
3415 semantic to "less than".
3416 (gen_ui_out_table_header_info): Change parameter to std::vector
3417 and update.
3418 (exists_probe_with_pops): Likewise.
3419 (info_probes_for_ops): Update to std::vector change.
3420 (enable_probes_command): Likewise.
3421 (disable_probes_command): Likewise.
3422
aaa63a31
SM
34232017-09-12 Simon Marchi <simon.marchi@ericsson.com>
3424
3425 * probe.h (struct probe_ops) <get_probes>: Change parameter from
3426 vec to std::vector.
3427 * probe.c (parse_probes_in_pspace): Update.
3428 (find_probes_in_objfile): Update.
3429 (find_probe_by_pc): Update.
3430 (collect_probes): Update.
3431 (probe_any_get_probes): Update.
3432 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
3433 return type to reference to std::vector.
3434 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
3435 std::vector and update.
3436 (dtrace_process_dof): Likewise.
3437 (dtrace_get_probes): Likewise.
3438 * elfread.c (elf_get_probes): Change return type to std::vector,
3439 store an std::vector in bfd_data.
3440 (probe_key_free): Update to std::vector.
3441 * stap-probe.c (handle_stap_probe): Change parameter to
3442 std::vector and update.
3443 (stap_get_probes): Likewise.
3444 * symfile-debug.c (debug_sym_get_probes): Change return type to
3445 std::vector and update.
3446
cb85b21b
TT
34472017-09-11 Tom Tromey <tom@tromey.com>
3448
3449 * breakpoint.c (program_breakpoint_here_p): Update.
3450 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
3451 from make_show_memory_breakpoints_cleanup. Return a
3452 scoped_restore_tmpl<int>.
3453 (restore_show_memory_breakpoints): Remove.
3454 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
3455 * mem-break.c (memory_validate_breakpoint): Update.
3456 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
3457 (ia64_memory_remove_breakpoint): Update.
3458 (ia64_breakpoint_from_pc): Update.
3459 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
3460 from make_show_memory_breakpoints_cleanup.
3461
8fbc99ef
TT
34622017-09-11 Tom Tromey <tom@tromey.com>
3463
3464 * d-namespace.c (d_lookup_symbol): Use std::string.
3465 (find_symbol_in_baseclass): Likewise.
3466
50feb4bd
TT
34672017-09-11 Tom Tromey <tom@tromey.com>
3468
3469 * ctf.c (ctf_start): Use std::string.
3470
c6dc63a1
TT
34712017-09-11 Tom Tromey <tom@tromey.com>
3472
3473 * ada-lang.c (is_known_support_routine): Update.
3474 (ada_unhandled_exception_name_addr_from_raise): Update.
3475 * guile/scm-frame.c (gdbscm_frame_name): Update.
3476 * python/py-frame.c (frapy_name): Update.
3477 (frapy_function): Update.
3478 * stack.h (find_frame_funname): Update.
3479 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
3480 (print_frame): Update.
3481
d6b9b80f
TT
34822017-09-11 Tom Tromey <tom@tromey.com>
3483
3484 * findcmd.c (put_bits): Take a gdb::byte_vector.
3485 (parse_find_args): Return gdb::byte_vector. "args" now const.
3486 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
3487 cleanups.
3488 (find_command): Update.
3489
a9921622
TT
34902017-09-11 Tom Tromey <tom@tromey.com>
3491
3492 * cli/cli-script.c (class scoped_restore_hook_in): New.
3493 (clear_hook_in_cleanup): Remove.
3494 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
3495 scoped_restore_hook_in.
3496
be0d7abb
TT
34972017-09-11 Tom Tromey <tom@tromey.com>
3498
3499 * cli/cli-script.c (restore_interp): Remove.
3500 (read_command_lines): Use scoped_restore_interp.
3501 * interps.c (scoped_restore_interp::set_temp): Rename from
3502 interp_set_temp.
3503 * interps.h (class scoped_restore_interp): New.
3504 (interp_set_temp): Remove.
3505
00f675ff
TT
35062017-09-11 Tom Tromey <tom@tromey.com>
3507
3508 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
3509 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
3510 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
3511 scoped_restore.
3512 (mi_cmd_break_insert_1): Update.
3513 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
3514 scoped_restore.
3515
cb791d59
TT
35162017-09-11 Tom Tromey <tom@tromey.com>
3517
3518 * demangle.c (demangle_command): Update.
3519 * breakpoint.c (disable_command): Update.
3520 (enable_command): Update.
3521 (find_location_by_number): Make "number" const. Use
3522 get_number_trailer.
3523 * cli/cli-utils.c (extract_arg): Return std::string.
3524 * probe.c (parse_probe_linespec): Update. Change types.
3525 (collect_probes): Take string arguments.
3526 (parse_probe_linespec): Likewise.
3527 (info_probes_for_ops): Update.
3528 (enable_probes_command): Update.
3529 (disable_probes_command): Update.
3530 * break-catch-sig.c (catch_signal_split_args): Update.
3531 * mi/mi-parse.c (mi_parse): Update.
3532
2039bd9f
TT
35332017-09-11 Tom Tromey <tom@tromey.com>
3534
3535 * language.h (language_enum): Make argument const.
3536 * language.c (language_enum): Make argument const.
3537
f1735a53
TT
35382017-09-11 Tom Tromey <tom@tromey.com>
3539
3540 * common/common-utils.h (skip_to_space): Remove macro, redeclare
3541 as function.
3542 (skip_to_space): Rename from skip_to_space_const.
3543 * common/common-utils.c (skip_to_space): New function.
3544 (skip_to_space): Rename from skip_to_space_const.
3545 * cli/cli-utils.h (get_number): Rename from get_number_const.
3546 (extract_arg): Rename from extract_arg_const.
3547 * cli/cli-utils.c (get_number): Rename from get_number_const.
3548 (extract_arg): Rename from extract_arg_const.
3549 (number_or_range_parser::get_number): Use ::get_number.
3550 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
3551 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
3552 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
3553 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
3554 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
3555 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
3556 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
3557 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
3558
7d221d74
TT
35592017-09-11 Tom Tromey <tom@tromey.com>
3560
3561 * python/python.c (do_start_initialization): Use
3562 py-event-types.def to initialize types.
3563 Define all object type structures.
3564 * python/python-internal.h: Don't declare event initialization
3565 functions.
3566 * python/py-threadevent.c (thread_event_object_type): Don't
3567 define.
3568 * python/py-stopevent.c (stop_event_object_type): Don't define.
3569 * python/py-signalevent.c (signal_event_object_type): Don't
3570 declare or define.
3571 * python/py-newobjfileevent.c (new_objfile_event_object_type)
3572 (clear_objfiles_event_object_type): Don't declare or define.
3573 * python/py-infevents.c (inferior_call_pre_event_object_type)
3574 (inferior_call_post_event_object_type)
3575 (register_changed_event_object_type)
3576 (memory_changed_event_object_type): Don't declare or define.
3577 * python/py-inferior.c (new_thread_event_object_type)
3578 (new_inferior_event_object_type)
3579 (inferior_deleted_event_object_type): Don't declare or define.
3580 * python/py-exitedevent.c (exited_event_object_type): Don't
3581 declare or define.
3582 * python/py-evts.c (gdbpy_initialize_py_events): Use
3583 py-all-events.def.
3584 * python/py-events.h (thread_event_object_type): Don't declare.
3585 (events_object): Use py-all-events.def.
3586 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
3587 py-event-types.def.
3588 * python/py-event-types.def: New file.
3589 * python/py-continueevent.c (create_continue_event_object): Don't
3590 declare or define.
3591 * python/py-bpevent.c (breakpoint_event_object_type): Don't
3592 declare or define.
3593 * python/py-all-events.def: New file.
3594
35c61a1d
TT
35952017-09-11 Tom Tromey <tom@tromey.com>
3596
3597 * python/py-threadevent.c (create_thread_event_object): Return
3598 gdbpy_ref.
3599 * python/py-stopevent.h (create_stop_event_object)
3600 (create_breakpoint_event_object, create_signal_event_object):
3601 Update.
3602 * python/py-stopevent.c (create_stop_event_object): Return
3603 gdbpy_ref.
3604 (emit_stop_event): Update.
3605 * python/py-signalevent.c (create_signal_event_object): Return
3606 gdbpy_ref.
3607 * python/py-infevents.c (create_inferior_call_event_object):
3608 Update.
3609 * python/py-event.h (create_event_object)
3610 (create_thread_event_object): Update.
3611 * python/py-event.c (create_event_object): Return gdbpy_ref.
3612 * python/py-continueevent.c: Return gdbpy_ref.
3613 * python/py-bpevent.c (create_breakpoint_event_object): Return
3614 gdbpy_ref.
3615
7c96f8c1
TT
36162017-09-11 Tom Tromey <tom@tromey.com>
3617
3618 PR python/15622:
3619 * NEWS: Add entry.
3620 * python/python.c (do_start_initialization): Initialize new event
3621 types.
3622 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
3623 (gdbpy_initialize_inferior_deleted_event)
3624 (gdbpy_initialize_new_thread_event): Declare.
3625 * python/py-threadevent.c (create_thread_event_object): Add option
3626 "thread" parameter.
3627 * python/py-inferior.c (new_thread_event_object_type)
3628 (new_inferior_event_object_type)
3629 (inferior_deleted_event_object_type): Declare.
3630 (python_new_inferior, python_inferior_deleted): New functions.
3631 (add_thread_object): Emit new_thread event.
3632 (gdbpy_initialize_inferior): Attach new functions to corresponding
3633 observers.
3634 (new_thread, new_inferior, inferior_deleted): Define new event
3635 types.
3636 * python/py-evts.c (gdbpy_initialize_py_events): Add new
3637 registries.
3638 * python/py-events.h (events_object) <new_inferior,
3639 inferior_deleted, new_thread>: New fields.
3640 * python/py-event.h (create_thread_event_breakpoint): Add optional
3641 "thread" parameter.
3642
72542b8e
AB
36432017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
3644
3645 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
3646 check current_ui instead.
3647 (internal_vproblem): Likewise.
3648
0d64823e
SM
36492017-09-09 Simon Marchi <simon.marchi@ericsson.com>
3650
3651 * thread.c (print_thread_info_1): Remove unnecessary calls to
3652 uiout->is_mi_like_p.
3653
eb1e02fd
TT
36542017-09-09 Tom Tromey <tom@tromey.com>
3655
3656 * namespace.h (add_using_directive): Update.
3657 * namespace.c (add_using_directive): Change type of excludes to
3658 std::vector.
3659 * dwarf2read.c (read_import_statement): Use std::vector.
3660 (read_namespace): Update.
3661 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
3662
0fc21fd8
TT
36632017-09-09 Tom Tromey <tom@tromey.com>
3664
3665 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
3666
49663d05
TT
36672017-09-09 Tom Tromey <tom@tromey.com>
3668
3669 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
3670
0b868b60
TT
36712017-09-09 Tom Tromey <tom@tromey.com>
3672
3673 * stack.c (func_command): Use gdb::def_vector.
3674
c0470d48
TT
36752017-09-09 Tom Tromey <tom@tromey.com>
3676
3677 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
3678 ui_out_emit_list, ui_out_emit_tuple.
3679 (mi_cmd_var_update): Likewise.
3680
ca5909c7
TT
36812017-09-09 Tom Tromey <tom@tromey.com>
3682
3683 * mi/mi-interp.c (mi_user_selected_context_changed): Use
3684 ui_out_redirect_pop.
3685 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
3686 ui_out_redirect_pop.
3687 * utils.c (do_ui_out_redirect_pop)
3688 (make_cleanup_ui_out_redirect_pop): Remove.
3689 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
3690 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
3691 * ui-out.h (ui_out_redirect_pop): New class.
3692
e6a2252a
TT
36932017-09-09 Tom Tromey <tom@tromey.com>
3694
3695 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
3696 (list_available_thread_groups, mi_cmd_list_thread_groups)
3697 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
3698 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
3699 Likewise.
3700
393702cd
TT
37012017-09-09 Tom Tromey <tom@tromey.com>
3702
3703 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
3704 ui_out_emit_tuple.
3705
76f9c9cf
TT
37062017-09-09 Tom Tromey <tom@tromey.com>
3707
3708 * target.c (flash_erase_command): Use ui_out_emit_tuple.
3709 * stack.c (print_frame): Use ui_out_emit_tuple.
3710 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
3711 (info_spu_mailbox_command, info_spu_dma_command)
3712 (info_spu_proxydma_command): Likewise.
3713 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
3714 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
3715 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
3716 ui_out_emit_tuple.
3717 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
3718
dc9fe180
TT
37192017-09-09 Tom Tromey <tom@tromey.com>
3720
3721 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
3722 (class ui_out_emit_table): Update comment.
3723 * ui-out.c (do_cleanup_table_end)
3724 (make_cleanup_ui_out_table_begin_end): Remove.
3725 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
3726 (info_spu_dma_cmdlist): Likewise.
3727 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
3728 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
3729 ui_out_emit_table.
3730
f8cc3da6
TT
37312017-09-09 Tom Tromey <tom@tromey.com>
3732
3733 * thread.c (print_thread_info_1): Use ui_out_emit_table,
3734 ui_out_emit_list, gdb::optional.
3735
481695ed
JB
37362017-09-09 John Baldwin <jhb@FreeBSD.org>
3737
3738 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
3739 prototype.
3740 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
3741 prototype.
3742 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
3743 prototype.
3744 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
3745 * ada-exp.y: Remove _initialize_ada_exp prototype.
3746 * ada-lang.c: Remove _initialize_ada_language prototype.
3747 * ada-tasks.c: Remove _initialize_tasks prototype.
3748 * addrmap.c: Remove _initialize_addrmap prototype.
3749 * agent.c: Remove _initialize_agent prototype.
3750 * aix-thread.c: Remove _initialize_aix_thread prototype.
3751 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
3752 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
3753 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
3754 prototype.
3755 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
3756 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
3757 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
3758 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
3759 prototype.
3760 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
3761 prototype.
3762 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
3763 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
3764 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
3765 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
3766 prototype.
3767 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
3768 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
3769 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
3770 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
3771 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
3772 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
3773 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
3774 prototype.
3775 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
3776 prototype.
3777 * annotate.c: Remove _initialize_annotate prototype.
3778 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
3779 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
3780 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
3781 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
3782 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
3783 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
3784 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
3785 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
3786 prototype.
3787 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
3788 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
3789 * auto-load.c: Remove _initialize_auto_load prototype.
3790 * auxv.c: Remove _initialize_auxv prototype.
3791 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
3792 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
3793 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
3794 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
3795 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
3796 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
3797 prototype.
3798 * break-catch-throw.c: Remove _initialize_break_catch_throw
3799 prototype.
3800 * breakpoint.c: Remove _initialize_breakpoint prototype.
3801 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
3802 * btrace.c: Remove _initialize_btrace prototype.
3803 * charset.c: Remove _initialize_charset prototype.
3804 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
3805 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
3806 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
3807 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
3808 * cli/cli-script.c: Remove _initialize_cli_script prototype.
3809 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
3810 * coffread.c: Remove _initialize_coffread prototype.
3811 * compile/compile.c: Remove _initialize_compile prototype.
3812 * complaints.c: Remove _initialize_complaints prototype.
3813 * completer.c: Remove _initialize_completer prototype.
3814 * copying.awk: Remove _initialize_copying prototype.
3815 * copying.c: Regenerate.
3816 * core-regset.c: Remove _initialize_core_regset prototype.
3817 * corefile.c: Remove _initialize_core prototype.
3818 * corelow.c: Remove _initialize_corelow prototype.
3819 * cp-abi.c: Remove _initialize_cp_abi prototype.
3820 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
3821 * cp-support.c: Remove _initialize_cp_support prototype.
3822 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
3823 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
3824 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
3825 * ctf.c: Remove _initialize_ctf prototype.
3826 * d-lang.c: Remove _initialize_d_language prototype.
3827 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
3828 prototype.
3829 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
3830 * dbxread.c: Remove _initialize_dbxread prototype.
3831 * dcache.c: Remove _initialize_dcache prototype.
3832 * demangle.c: Remove _initialize_demangler prototype.
3833 * disasm-selftests.c: Remove _initialize_disasm_selftests
3834 prototype.
3835 * disasm.c: Remove _initialize_disasm prototype.
3836 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
3837 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
3838 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
3839 prototype.
3840 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
3841 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
3842 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
3843 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
3844 * elfread.c: Remove _initialize_elfread prototype.
3845 * exec.c: Remove _initialize_exec prototype.
3846 * extension.c: Remove _initialize_extension prototype.
3847 * f-lang.c: Remove _initialize_f_language prototype.
3848 * f-valprint.c: Remove _initialize_f_valprint prototype.
3849 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
3850 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
3851 * filesystem.c: Remove _initialize_filesystem prototype.
3852 * findcmd.c: Remove _initialize_mem_search prototype.
3853 * fork-child.c: Remove _initialize_fork_child prototype.
3854 * frame-base.c: Remove _initialize_frame_base prototype.
3855 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
3856 * frame.c: Remove _initialize_frame prototype.
3857 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
3858 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
3859 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
3860 * gcore.c: Remove _initialize_gcore prototype.
3861 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
3862 * gdbarch.c: Regenerate.
3863 * gdbarch.sh: Remove _initialize_gdbarch prototype.
3864 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
3865 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
3866 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
3867 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
3868 * go-lang.c: Remove _initialize_go_language prototype.
3869 * go32-nat.c: Remove _initialize_go32_nat prototype.
3870 * guile/guile.c: Remove _initialize_guile prototype.
3871 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
3872 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
3873 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
3874 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
3875 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
3876 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
3877 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
3878 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
3879 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
3880 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
3881 prototype.
3882 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
3883 prototype.
3884 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
3885 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
3886 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
3887 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
3888 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
3889 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
3890 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
3891 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
3892 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
3893 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
3894 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
3895 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
3896 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
3897 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
3898 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
3899 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
3900 prototype.
3901 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
3902 prototype.
3903 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
3904 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
3905 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
3906 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
3907 * infcall.c: Remove _initialize_infcall prototype.
3908 * infcmd.c: Remove _initialize_infcmd prototype.
3909 * inferior.c: Remove _initialize_inferiors prototype.
3910 * inflow.c: Remove _initialize_inflow prototype.
3911 * infrun.c: Remove _initialize_infrun prototype.
3912 * interps.c: Remove _initialize_interpreter prototype.
3913 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
3914 * jit.c: Remove _initialize_jit prototype.
3915 * language.c: Remove _initialize_language prototype.
3916 * linux-fork.c: Remove _initialize_linux_fork prototype.
3917 * linux-nat.c: Remove _initialize_linux_nat prototype.
3918 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
3919 * linux-thread-db.c: Remove _initialize_thread_db prototype.
3920 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
3921 * m2-lang.c: Remove _initialize_m2_language prototype.
3922 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
3923 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
3924 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
3925 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
3926 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
3927 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
3928 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
3929 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
3930 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
3931 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
3932 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
3933 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
3934 * machoread.c: Remove _initialize_machoread prototype.
3935 * macrocmd.c: Remove _initialize_macrocmd prototype.
3936 * macroscope.c: Remove _initialize_macroscope prototype.
3937 * maint.c: Remove _initialize_maint_cmds prototype.
3938 * mdebugread.c: Remove _initialize_mdebugread prototype.
3939 * memattr.c: Remove _initialize_mem prototype.
3940 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
3941 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
3942 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
3943 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
3944 * mi/mi-main.c: Remove _initialize_mi_main prototype.
3945 * microblaze-linux-tdep.c: Remove
3946 _initialize_microblaze_linux_tdep prototype.
3947 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
3948 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
3949 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
3950 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
3951 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
3952 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
3953 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
3954 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
3955 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
3956 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
3957 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
3958 prototype.
3959 * mipsread.c: Remove _initialize_mipsread prototype.
3960 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
3961 prototype.
3962 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
3963 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
3964 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
3965 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
3966 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
3967 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
3968 prototype.
3969 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
3970 * nto-procfs.c: Remove _initialize_procfs prototype.
3971 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
3972 * objc-lang.c: Remove _initialize_objc_language prototype.
3973 * objfiles.c: Remove _initialize_objfiles prototype.
3974 * observer.c: Remove observer_test_first_notification_function,
3975 observer_test_second_notification_function,
3976 observer_test_third_notification_function, and
3977 _initialize_observer prototypes.
3978 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
3979 * osabi.c: Remove _initialize_gdb_osabi prototype.
3980 * osdata.c: Remove _initialize_osdata prototype.
3981 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
3982 * parse.c: Remove _initialize_parse prototype.
3983 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
3984 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
3985 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
3986 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
3987 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
3988 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
3989 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
3990 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
3991 * printcmd.c: Remove _initialize_printcmd prototype.
3992 * probe.c: Remove _initialize_probe prototype.
3993 * proc-api.c: Remove _initialize_proc_api prototype.
3994 * proc-events.c: Remove _initialize_proc_events prototype.
3995 * proc-service.c: Remove _initialize_proc_service prototype.
3996 * procfs.c: Remove _initialize_procfs prototype.
3997 * psymtab.c: Remove _initialize_psymtab prototype.
3998 * python/python.c: Remove _initialize_python prototype.
3999 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
4000 * record-btrace.c: Remove _initialize_record_btrace prototype.
4001 * record-full.c: Remove _initialize_record_full prototype.
4002 * record.c: Remove _initialize_record prototype.
4003 * regcache.c: Remove _initialize_regcache prototype.
4004 * reggroups.c: Remove _initialize_reggroup prototype.
4005 * remote-notif.c: Remove _initialize_notif prototype.
4006 * remote-sim.c: Remove _initialize_remote_sim prototype.
4007 * remote.c: Remove _initialize_remote prototype.
4008 * reverse.c: Remove _initialize_reverse prototype.
4009 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
4010 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
4011 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
4012 prototype.
4013 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
4014 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
4015 * rust-exp.y: Remove _initialize_rust_exp prototype.
4016 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
4017 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
4018 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
4019 * score-tdep.c: Remove _initialize_score_tdep prototype.
4020 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
4021 prototype.
4022 * ser-go32.c: Remove _initialize_ser_dos prototype.
4023 * ser-mingw.c: Remove _initialize_ser_windows prototype.
4024 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
4025 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
4026 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
4027 * serial.c: Remove _initialize_serial prototype.
4028 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
4029 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
4030 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
4031 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
4032 * skip.c: Remove _initialize_step_skip prototype.
4033 * sol-thread.c: Remove _initialize_sol_thread prototype.
4034 * solib-aix.c: Remove _initialize_solib_aix prototype.
4035 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
4036 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
4037 * solib-frv.c: Remove _initialize_frv_solib prototype.
4038 * solib-spu.c: Remove _initialize_spu_solib prototype.
4039 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
4040 * solib-target.c: Remove _initialize_solib_target prototype.
4041 * solib.c: Remove _initialize_solib prototype.
4042 * source.c: Remove _initialize_source prototype.
4043 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
4044 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
4045 prototype.
4046 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
4047 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
4048 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
4049 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
4050 prototype.
4051 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
4052 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
4053 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
4054 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
4055 prototype.
4056 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
4057 prototype.
4058 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
4059 prototype.
4060 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
4061 prototype.
4062 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
4063 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
4064 prototype.
4065 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
4066 prototype.
4067 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
4068 prototype.
4069 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
4070 prototype.
4071 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
4072 prototype.
4073 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
4074 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
4075 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
4076 * stabsread.c: Remove _initialize_stabsread prototype.
4077 * stack.c: Remove _initialize_stack prototype.
4078 * stap-probe.c: Remove _initialize_stap_probe prototype.
4079 * std-regs.c: Remove _initialize_frame_reg prototype.
4080 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
4081 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
4082 * symfile.c: Remove _initialize_symfile prototype.
4083 * symmisc.c: Remove _initialize_symmisc prototype.
4084 * symtab.c: Remove _initialize_symtab prototype.
4085 * target-dcache.c: Remove _initialize_target_dcache prototype.
4086 * target-descriptions.c: Remove _initialize_target_descriptions
4087 prototype.
4088 * thread.c: Remove _initialize_thread prototype.
4089 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
4090 prototype.
4091 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
4092 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
4093 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
4094 prototype.
4095 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
4096 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
4097 * tracefile.c: Remove _initialize_tracefile prototype.
4098 * tracepoint.c: Remove _initialize_tracepoint prototype.
4099 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
4100 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
4101 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
4102 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
4103 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
4104 * tui/tui-win.c: Remove _initialize_tui_win prototype.
4105 * tui/tui.c: Remove _initialize_tui prototype.
4106 * typeprint.c: Remove _initialize_typeprint prototype.
4107 * user-regs.c: Remove _initialize_user_regs prototype.
4108 * utils.c: Remove _initialize_utils prototype.
4109 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
4110 * valarith.c: Remove _initialize_valarith prototype.
4111 * valops.c: Remove _initialize_valops prototype.
4112 * valprint.c: Remove _initialize_valprint prototype.
4113 * value.c: Remove _initialize_values prototype.
4114 * varobj.c: Remove _initialize_varobj prototype.
4115 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
4116 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
4117 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
4118 * windows-nat.c: Remove _initialize_windows_nat,
4119 _initialize_check_for_gdb_ini, and _initialize_loadable
4120 prototypes.
4121 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
4122 * xcoffread.c: Remove _initialize_xcoffread prototype.
4123 * xml-support.c: Remove _initialize_xml_support prototype.
4124 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
4125 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
4126 prototype.
4127 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
4128 prototype.
4129 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
4130
a611b5cb
KS
41312017-09-08 Keith Seitz <keiths@redhat.com>
4132
4133 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
4134 field.
4135
469412dd
CW
41362017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
4137
4138 * f-valprint.c (f_val_print): Remove check for one byte
4139 sized integers. Remove printing of character type.
4140
a5ad232b
FP
41412017-09-08 Frank Penczek <frank.penczek@intel.com>
4142 Christoph Weinmann <christoph.t.weinmann@intel.com>
4143 Bernhard Heckel <bernhard.heckel@intel.com>
4144
4145 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
4146 to maintain proper indentation when printing pointers/refs.
4147
e5014227
JB
41482017-09-07 Joel Brobecker <brobecker@adacore.com>
4149
4150 GDB 8.0.1 released.
4151
63c99141
JB
41522017-09-07 Joel Brobecker <brobecker@adacore.com>
4153
4154 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
4155
69c1e056
TT
41562017-09-05 Tom Tromey <tom@tromey.com>
4157
4158 * parse.c (funcall_chain): Now a std::vector.
4159 (start_arglist, end_arglist): Simplify.
4160 (free_funcalls): Remove.
4161 (parse_exp_in_context_1): Remove cleanup.
4162
fef704bf
TT
41632017-09-05 Tom Tromey <tom@tromey.com>
4164
4165 * go-exp.y (go_parse): Don't create a cleanup.
4166
5613c585
TT
41672017-09-05 Tom Tromey <tom@tromey.com>
4168
4169 * d-exp.y (PrimaryExpression): Use std::string.
4170 (d_parse): Don't create a cleanup.
4171
eae49211
TT
41722017-09-05 Tom Tromey <tom@tromey.com>
4173
4174 * utils.c (do_clear_parser_state): Remove.
4175 (make_cleanup_clear_parser_state): Remove.
4176 * p-exp.y (pascal_parse): Use scoped_restore.
4177 * m2-exp.y (m2_parse): Use scoped_restore.
4178 * f-exp.y (f_parse): Use scoped_restore.
4179 * d-exp.y (d_parse): Use scoped_restore.
4180 * c-exp.y (c_parse): Use scoped_restore.
4181 * ada-exp.y (ada_parse): Use scoped_restore.
4182 * utils.h (make_cleanup_clear_parser_state): Remove.
4183
73b9be8b
KS
41842017-09-06 Keith Seitz <keiths@redhat.com>
4185
4186 * dwarf2read.c (dw2_linkage_name_attr): New function.
4187 (dw2_linkage_name): New function.
4188 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
4189 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
4190 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
4191
a102602b
KR
41922017-09-06 Kamil Rytarowski <n54@gmx.com>
4193
4194 * config/djgpp/djconfig.sh: Correct shell portability issue.
4195
28ad437d
KR
41962017-09-06 Kamil Rytarowski <n54@gmx.com>
4197
4198 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
4199
351787dd
JB
42002017-09-06 John Baldwin <jhb@FreeBSD.org>
4201
4202 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
4203 * NEWS: Mention new FreeBSD/mips native configuration.
4204 * configure.host: Add aarch64*-*-freebsd*.
4205 * configure.nat: Likewise.
4206 * aarch64-fbsd-nat.c: New file.
4207
c0f84956
JB
42082017-09-06 John Baldwin <jhb@FreeBSD.org>
4209
4210 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
4211 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
4212 * NEWS: Mention new FreeBSD/aarch64 target.
4213 * configure.tgt: Add aarch64*-*-freebsd*.
4214 * aarch64-fbsd-tdep.c: New file.
4215 * aarch64-fbsd-tdep.h: New file.
4216
7610297a
KR
42172017-09-06 Kamil Rytarowski <n54@gmx.com>
4218
4219 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
4220
fbd1b771
JK
42212017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
4222
4223 * parse.c (find_minsym_type_and_address): Don't relocate addresses
4224 of TLS symbols.
4225
5ca79eae
PW
42262017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4227
4228 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
4229 call.
4230
bf93d7ba
SM
42312017-09-05 Simon Marchi <simon.marchi@ericsson.com>
4232
4233 * infrun.c (follow_exec): Call add_thread after
4234 target_find_description.
4235
1bb7c059
SM
42362017-09-05 Simon Marchi <simon.marchi@ericsson.com>
4237
4238 * infrun.c (handle_inferior_event_1): When exec'ing, read
4239 stop_pc after follow_exec.
4240
fc809827
SM
42412017-09-05 Simon Marchi <simon.marchi@ericsson.com>
4242
4243 * remote.c (process_g_packet): Update error message.
4244
d2fcdd85
YQ
42452017-09-05 Yao Qi <yao.qi@linaro.org>
4246
4247 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
4248 targets.
4249
e69570ee
PA
42502017-09-05 Pedro Alves <palves@redhat.com>
4251
4252 * eval.c (eval_call, evaluate_funcall): New functions, factored
4253 out from ...
4254 (evaluate_subexp_standard): ... this.
4255
22916b07
YQ
42562017-09-05 Yao Qi <yao.qi@linaro.org>
4257
4258 * amd64-tdep.c (amd64_target_description): Create target
4259 descriptions.
4260 (_initialize_amd64_tdep): Don't call functions
4261 initialize_tdesc_amd64_*. Add self tests.
4262 * arch/amd64.c (amd64_create_target_description): Add parameter
4263 is_linux. Call set_tdesc_osabi if is_linux is true.
4264 * arch/amd64.h (amd64_create_target_description): Update the
4265 declaration.
4266 * arch/i386.c (i386_create_target_description): Add parameter
4267 is_linux. Call set_tdesc_osabi if is_linux is true.
4268 * arch/i386.h (i386_create_target_description): Update
4269 declaration.
4270 * configure.tgt: Add i386.o to gdb_target_obs.
4271 * features/Makefile (XMLTOC): Remove i386/*.xml.
4272 * features/i386/amd64-avx-avx512.c: Remove.
4273 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
4274 * features/i386/amd64-avx-mpx.c: Remove.
4275 * features/i386/amd64-avx.c: Remove.
4276 * features/i386/amd64-mpx.c: Remove.
4277 * features/i386/amd64.c: Remove.
4278 * features/i386/i386-avx-avx512.c: Remove.
4279 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
4280 * features/i386/i386-avx-mpx.c: Remove.
4281 * features/i386/i386-avx.c: Remove.
4282 * features/i386/i386-mmx.c: Remove.
4283 * features/i386/i386-mpx.c: Remove.
4284 * features/i386/i386.c: Remove.
4285 * i386-tdep.c: Don't include features/i386/i386*.c., include
4286 target-descriptions.h and arch/i386.h.
4287 (i386_target_description): Create target descriptions.
4288 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
4289 functions. Do self tests.
4290
0854b7b1
YQ
42912017-09-05 Yao Qi <yao.qi@linaro.org>
4292
4293 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
4294 * features/i386/amd64-avx-avx512-linux.c: Removed.
4295 * features/i386/amd64-avx-linux.c: Removed.
4296 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
4297 * features/i386/amd64-avx-mpx-linux.c: Removed.
4298 * features/i386/amd64-linux.c: Removed.
4299 * features/i386/amd64-mpx-linux.c: Removed.
4300 * features/i386/x32-avx-avx512-linux.c: Removed.
4301 * features/i386/x32-avx-linux.c: Removed.
4302 * features/i386/x32-linux.c: Removed.
4303
b4570e4b
YQ
43042017-09-05 Yao Qi <yao.qi@linaro.org>
4305
4306 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
4307 features/i386/*.c.
4308 (amd64_linux_read_description): Call
4309 amd64_create_target_description.
4310 * arch/amd64.c: New file.
4311 * arch/amd64.h: New file.
4312 * configure.tgt (x86_64-*-linux*): Append amd64.o.
4313 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
4314
6c73f67f
YQ
43152017-09-05 Yao Qi <yao.qi@linaro.org>
4316
4317 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
4318 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
4319 (amd64_linux_read_description): Create target descriptions.
4320 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
4321 functions. Add unit tests.
4322 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
4323 x32-core.xml.
4324 * features/i386/64bit-avx.c: Generated.
4325 * features/i386/64bit-avx512.c: Generated.
4326 * features/i386/64bit-core.c: Generated.
4327 * features/i386/64bit-linux.c: Generated.
4328 * features/i386/64bit-mpx.c: Generated.
4329 * features/i386/64bit-pkeys.c: Generated.
4330 * features/i386/64bit-segments.c: Generated.
4331 * features/i386/64bit-sse.c: Generated.
4332 * features/i386/x32-core.c: Generated.
4333 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
4334 c files for amd64-linux and x32-linux.
4335
9d3d478b
YQ
43362017-09-05 Yao Qi <yao.qi@linaro.org>
4337
4338 * amd64-linux-tdep.c (amd64_linux_read_description): New
4339 function.
4340 (amd64_linux_core_read_description): Call
4341 amd64_linux_read_description.
4342 (amd64_linux_init_abi): Likewise.
4343 (amd64_x32_linux_init_abi): Likewise.
4344 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
4345 * x86-linux-nat.c (x86_linux_read_description): Call
4346 amd64_linux_read_description.
4347
b9f1d50f
YQ
43482017-09-05 Yao Qi <yao.qi@linaro.org>
4349
4350 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
4351 comments.
4352
188c9e6d
YQ
43532017-09-05 Yao Qi <yao.qi@linaro.org>
4354
4355 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
4356 * features/i386/i386-avx-avx512-linux.c: Remove.
4357 * features/i386/i386-avx-linux.c: Remove.
4358 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
4359 * features/i386/i386-avx-mpx-linux.c: Remove.
4360 * features/i386/i386-linux.c: Remove.
4361 * features/i386/i386-mmx-linux.c: Remove.
4362 * features/i386/i386-mpx-linux.c: Remove.
4363
5f035c07
YQ
43642017-09-05 Yao Qi <yao.qi@linaro.org>
4365
4366 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
4367 (SFILES): Add arch/i386.c.
4368 (HFILES_NO_SRCDIR): Add arch/i386.h.
4369 * arch/i386.c: New file.
4370 * arch/i386.h: New file.
4371 * arch/tdesc.h (allocate_target_description): Declare.
4372 (set_tdesc_architecture): Declare.
4373 (set_tdesc_osabi): Declare.
4374 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
4375 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
4376 include arch/i386.h.
4377 (i386_linux_read_description): Remove code and call
4378 i386_create_target_description.
4379 (set_tdesc_architecture): New function.
4380 (set_tdesc_osabi): New function.
4381 * target-descriptions.h (allocate_target_description): Remove.
4382
0abe8a89
YQ
43832017-09-05 Yao Qi <yao.qi@linaro.org>
4384
4385 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
4386 * target-descriptions.c (tdesc_create_feature): Likewise, and
4387 adjust code.
4388 * features/i386/32bit-avx.c: Re-generated.
4389 * features/i386/32bit-avx512.c: Re-generated.
4390 * features/i386/32bit-core.c: Re-generated.
4391 * features/i386/32bit-linux.c: Re-generated.
4392 * features/i386/32bit-mpx.c: Re-generated.
4393 * features/i386/32bit-pkeys.c: Re-generated.
4394 * features/i386/32bit-sse.c: Re-generated.
4395
0a188386
YQ
43962017-09-05 Yao Qi <yao.qi@linaro.org>
4397
4398 * regformats/regdef.h (struct reg): Override operator == and !=.
4399
f49ff000
YQ
44002017-09-05 Yao Qi <yao.qi@linaro.org>
4401
4402 * arch/tdesc.h: New file.
4403 * regformats/regdat.sh: Generate code using tdesc_create_reg.
4404 * target-descriptions.c: Update comments.
4405 * target-descriptions.h: Include "arch/tdesc.h". Remove the
4406 declarations.
4407 * features/i386/32bit-avx.c: Re-generated.
4408 * features/i386/32bit-avx512.c: Re-generated.
4409 * features/i386/32bit-core.c: Re-generated.
4410 * features/i386/32bit-linux.c: Re-generated.
4411 * features/i386/32bit-mpx.c: Re-generated.
4412 * features/i386/32bit-pkeys.c: Re-generated.
4413 * features/i386/32bit-sse.c: Re-generated.
4414
f7000548
YQ
44152017-09-05 Yao Qi <yao.qi@linaro.org>
4416
4417 * regformats/regdat.sh: Update generated code.
4418
c9a5e2a5
YQ
44192017-09-05 Yao Qi <yao.qi@linaro.org>
4420
4421 * regformats/regdat.sh: Adjust code order.
4422
d6b687ac
SM
44232017-09-05 Simon Marchi <simon.marchi@ericsson.com>
4424
4425 * expprint.c (dump_subexp_body_standard): Use constant format
4426 string in fprintf_filtered call.
4427
a379bfd0
JB
44282017-09-04 John Baldwin <jhb@FreeBSD.org>
4429
4430 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
4431 NetBSD/i386.
4432 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
4433
f7efc967
JB
44342017-09-04 John Baldwin <jhb@FreeBSD.org>
4435
4436 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
4437
c49fbc6c
JB
44382017-09-04 John Baldwin <jhb@FreeBSD.org>
4439
4440 * bsd-kvm.o: Define _KMEMUSER.
4441 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
4442 * configure: Regenerate.
4443
26562e73
JB
44442017-09-04 John Baldwin <jhb@FreeBSD.org>
4445
4446 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
4447 * i386-fbsd-nat.c: Likewise.
4448
31cf1487
JB
44492017-09-04 John Baldwin <jhb@FreeBSD.org>
4450
4451 * unittests/array-view-selftests.c: Add include of <array>.
4452
5b9f8a7c
JB
44532017-09-04 John Baldwin <jhb@FreeBSD.org>
4454
4455 * spu-tdep.c (flush_ea_cache): Add missing argument to
4456 call_function_by_hand.
4457
d69cf9b2
PA
44582017-09-04 Pedro Alves <palves@redhat.com>
4459
4460 * NEWS (Safer support for debugging with no debug info): New.
4461
3693fdb3
PA
44622017-09-04 Pedro Alves <palves@redhat.com>
4463
4464 * c-exp.y (function_method, function_method_void): Add current
4465 instance flags to TYPE_INSTANCE.
4466 * dwarf2read.c (check_modifier): New.
4467 (compute_delayed_physnames): Assert that only C++ adds delayed
4468 physnames. Mark fn_fields as const/volatile depending on
4469 physname.
4470 * eval.c (make_params): New type_instance_flags parameter. Use
4471 it as the new type's instance flags.
4472 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
4473 flags element and pass it to make_params.
4474 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
4475 instance flags element.
4476 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
4477 * gdbtypes.h: Include "enum-flags.h".
4478 (type_instance_flags): New enum-flags type.
4479 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
4480 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
4481 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
4482 (follow_type_instance_flags): New function.
4483 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
4484 * parser-defs.h (follow_type_instance_flags): Declare.
4485 * valops.c (value_struct_elt_for_reference): const/volatile must
4486 match too.
4487
e68cb8e0
PA
44882017-09-04 Pedro Alves <palves@redhat.com>
4489
4490 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
4491 function/method scopes; lookup the nested name as a function local
4492 static variable.
4493
858be34c
PA
44942017-09-04 Pedro Alves <palves@redhat.com>
4495
4496 (%type <voidval>): Add function_method.
4497 * c-exp.y (exp): New production for calls with no arguments.
4498 (function_method, function_method_void_or_typelist): New
4499 productions.
4500 (exp): New production for "method()::static_var".
4501 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
4502 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
4503 Handle OP_FUNC_STATIC_VAR.
4504 * parse.c (operator_length_standard):
4505 Handle OP_FUNC_STATIC_VAR.
4506
dd5901a6
PA
45072017-09-04 Pedro Alves <palves@redhat.com>
4508
4509 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
4510 handling.
4511 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
4512 Ditto.
4513 * parse.c (operator_length_standard, operator_check_standard):
4514 Ditto.
4515 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
4516
46a4882b
PA
45172017-09-04 Pedro Alves <palves@redhat.com>
4518
4519 * ax-gdb.c: Include "typeprint.h".
4520 (gen_expr_for_cast): New function.
4521 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
4522 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
4523 type is unknown.
4524 * dwarf2read.c (new_symbol_full): Fallback to int instead of
4525 nodebug_data_symbol.
4526 * eval.c: Include "typeprint.h".
4527 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
4528 Error out if symbol has unknown type.
4529 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
4530 evaluate_subexp_for_cast.
4531 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
4532 OP_VAR_MSYM_VALUE.
4533 (evaluate_subexp_for_cast): New function.
4534 * gdbtypes.c (init_nodebug_var_type): New function.
4535 (objfile_type): Use it to initialize types of variables with no
4536 debug info.
4537 * typeprint.c (error_unknown_type): New.
4538 * typeprint.h (error_unknown_type): New declaration.
4539 * compile/compile-c-types.c (convert_type_basic): Handle
4540 TYPE_CODE_ERROR; warn and fallback to int for variables with
4541 unknown type.
4542
fe13dfec
PA
45432017-09-04 Pedro Alves <palves@redhat.com>
4544
4545 * eval.c (evaluate_var_value): New function, factored out from ...
4546 (evaluate_subexp_standard): ... here.
4547
d008ee21
PA
45482017-09-04 Pedro Alves <palves@redhat.com>
4549
4550 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
4551 Remove useless assignments to 'op'.
4552
827d0c51
PA
45532017-09-04 Pedro Alves <palves@redhat.com>
4554
4555 * eval.c (eval_skip_value): New function.
4556 (evaluate_subexp_standard): Use it.
4557
2c5a2be1
PA
45582017-09-04 Pedro Alves <palves@redhat.com>
4559
4560 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
4561 function name from symbol/minsym and pass it to
4562 error_call_unknown_return_type.
4563
74ea4be4
PA
45642017-09-04 Pedro Alves <palves@redhat.com>
4565
4566 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
4567 * ax-gdb.c (gen_msym_var_ref): New function.
4568 (gen_expr): Handle OP_VAR_MSYM_VALUE.
4569 * eval.c (evaluate_var_msym_value): New function.
4570 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
4571 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
4572 to call_function_by_hand.
4573 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
4574 Handle OP_VAR_MSYM_VALUE.
4575 (union exp_element) <msymbol>: New field.
4576 * minsyms.h (struct type): Forward declare.
4577 (find_minsym_type_and_address): Declare.
4578 * parse.c (write_exp_elt_msym): New function.
4579 (write_exp_msymbol): Delete, refactored as ...
4580 (find_minsym_type_and_address): ... this new function.
4581 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
4582 (operator_length_standard, operator_check_standard): Handle
4583 OP_VAR_MSYM_VALUE.
4584 * std-operator.def (OP_VAR_MSYM_VALUE): New.
4585
7022349d
PA
45862017-09-04 Pedro Alves <palves@redhat.com>
4587
4588 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
4589 TYPE_GNU_IFUNC specially here. Throw error if return type is
4590 unknown.
4591 * ada-typeprint.c (print_func_type): Handle functions with unknown
4592 return type.
4593 * c-typeprint.c (c_type_print_base): Handle functions and methods
4594 with unknown return type.
4595 * compile/compile-c-symbols.c (convert_symbol_bmsym)
4596 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
4597 * compile/compile-c-types.c: Include "objfiles.h".
4598 (convert_func): For functions with unknown return type, warn and
4599 default to int.
4600 * compile/compile-object-run.c (compile_object_run): Adjust call
4601 to call_function_by_hand_dummy.
4602 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
4603 call_function_by_hand.
4604 * eval.c (evaluate_subexp_standard): Adjust calls to
4605 call_function_by_hand. Handle functions and methods with unknown
4606 return type. Pass expect_type to call_function_by_hand.
4607 * f-typeprint.c (f_type_print_base): Handle functions with unknown
4608 return type.
4609 * gcore.c (call_target_sbrk): Adjust call to
4610 call_function_by_hand.
4611 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
4612 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
4613 an integer address type instead of nodebug.
4614 * guile/scm-value.c (gdbscm_value_call): Adjust call to
4615 call_function_by_hand.
4616 * infcall.c (error_call_unknown_return_type): New function.
4617 (call_function_by_hand): New "default_return_type" parameter.
4618 Pass it down.
4619 (call_function_by_hand_dummy): New "default_return_type"
4620 parameter. Use it instead of defaulting to int. If there's no
4621 default and the return type is unknown, throw an error. If
4622 there's a default return type, and the called function has no
4623 debug info, then assume the function is prototyped.
4624 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
4625 New "default_return_type" parameter.
4626 (error_call_unknown_return_type): New declaration.
4627 * linux-fork.c (call_lseek): Cast return type of lseek.
4628 (inferior_call_waitpid, checkpoint_command): Adjust calls to
4629 call_function_by_hand.
4630 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
4631 calls to call_function_by_hand.
4632 * m2-typeprint.c (m2_procedure): Handle functions with unknown
4633 return type.
4634 * objc-lang.c (lookup_objc_class, lookup_child_selector)
4635 (value_nsstring, print_object_command): Adjust calls to
4636 call_function_by_hand.
4637 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
4638 functions with unknown return type.
4639 (pascal_type_print_func_varspec_suffix): New function.
4640 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
4641 TYPE_CODE_METHOD>: Use it.
4642 * python/py-value.c (valpy_call): Adjust call to
4643 call_function_by_hand.
4644 * rust-lang.c (rust_evaluate_funcall): Adjust call to
4645 call_function_by_hand.
4646 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
4647 call_function_by_hand.
4648 * valops.c (value_allocate_space_in_inferior): Adjust call to
4649 call_function_by_hand.
4650 * typeprint.c (type_print_unknown_return_type): New function.
4651 * typeprint.h (type_print_unknown_return_type): New declaration.
4652
54990598
PA
46532017-09-04 Pedro Alves <palves@redhat.com>
4654
4655 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
4656 types with more than one parameter as prototyped.
4657
9a24775b
PA
46582017-09-04 Pedro Alves <palves@redhat.com>
4659
4660 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
4661 (disassemble_command): Use gdb_disassembly_flags instead of bare
4662 int.
4663 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
4664 (dump_insns, do_mixed_source_and_assembly_deprecated)
4665 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
4666 Use gdb_disassembly_flags instead of bare int.
4667 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
4668 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
4669 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
4670 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
4671 (enum gdb_disassembly_flag): ... values of this new enumeration.
4672 (gdb_disassembly_flags): Define.
4673 (gdb_disassembly)
4674 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
4675 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
4676 gdb_disassembly_flags instead of bare int.
4677 * record-btrace.c (btrace_insn_history)
4678 (record_btrace_insn_history, record_btrace_insn_history_range)
4679 (record_btrace_insn_history_from): Use gdb_disassembly_flags
4680 instead of bare int.
4681 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
4682 Use gdb_disassembly_flags instead of bare int.
4683 * target-debug.h (target_debug_print_gdb_disassembly_flags):
4684 Define.
4685 * target-delegates.c: Regenerate.
4686 * target.c (target_insn_history, target_insn_history_from)
4687 (target_insn_history_range): Use gdb_disassembly_flags instead of
4688 bare int.
4689 * target.h: Include "disasm.h".
4690 (struct target_ops) <to_insn_history, to_insn_history_from,
4691 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
4692 int.
4693 (target_insn_history, target_insn_history_from)
4694 (target_insn_history_range): Use gdb_disassembly_flags instead of
4695 bare int.
4696
80a65e9b
SM
46972017-09-04 Simon Marchi <simon.marchi@ericsson.com>
4698
4699 * cli/cli-script.c (build_command_line): For if/while commands,
4700 check whether args is empty.
4701
6b66338c
SM
47022017-09-04 Simon Marchi <simon.marchi@ericsson.com>
4703
4704 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
4705 (enum command_control_type): Likewise.
4706 (struct command_line): Likewise.
4707 (free_command_lines): Likewise.
4708 (struct command_lines_deleter): Likewise.
4709 (command_line_up): Likewise.
4710 (read_command_lines): Likewise.
4711 (read_command_lines_1): Likewise.
4712 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
4713 (enum command_control_type): Likewise.
4714 (struct command_line): Likewise.
4715 (free_command_lines): Likewise.
4716 (struct command_lines_deleter): Likewise.
4717 (command_line_up): Likewise.
4718 (read_command_lines): Likewise.
4719 (read_command_lines_1): Likewise.
4720 * breakpoint.h: Include cli/cli-script.h.
4721 * extension-priv.h: Likewise.
4722 * gdbcmd.h: Likewise.
4723
51abb421
PA
47242017-09-04 Pedro Alves <palves@redhat.com>
4725
4726 * ada-lang.c (is_known_support_routine): Move sal declaration to
4727 where it is initialized.
4728 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
4729 (parse_breakpoint_sals, decode_static_tracepoint_spec)
4730 (clear_command, update_static_tracepoint): Remove init_sal
4731 references. Move declarations closer to initializations.
4732 * cli/cli-cmds.c (list_command): Move sal declarations closer to
4733 initializations.
4734 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
4735 references. Move sal declarations closer to initializations.
4736 * frame.c (find_frame_sal): Return a symtab_and_line via function
4737 return instead of output parameter. Remove init_sal references.
4738 * frame.h (find_frame_sal): Return a symtab_and_line via function
4739 return instead of output parameter.
4740 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
4741 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
4742 instead of memset.
4743 (gdbscm_find_pc_line): Remove init_sal reference.
4744 * infcall.c (call_function_by_hand_dummy): Remove init_sal
4745 references. Move declarations closer to initializations.
4746 * infcmd.c (set_step_frame): Update. Move declarations closer to
4747 initializations.
4748 (finish_backward): Remove init_sal references. Move declarations
4749 closer to initializations.
4750 * infrun.c (process_event_stop_test, handle_step_into_function)
4751 (insert_hp_step_resume_breakpoint_at_frame)
4752 (insert_step_resume_breakpoint_at_caller): Likewise.
4753 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
4754 (symbol_to_sal): Likewise.
4755 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
4756 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
4757 to its initialization.
4758 * reverse.c (save_bookmark_command): Use new/delete. Remove
4759 init_sal references. Move declarations closer to initializations.
4760 * source.c (get_current_source_symtab_and_line): Remove brace
4761 initialization.
4762 (set_current_source_symtab_and_line): Now takes the sal by const
4763 reference. Remove brace initialization.
4764 (line_info): Remove init_sal reference.
4765 * source.h (set_current_source_symtab_and_line): Now takes a
4766 symtab_and_line via const reference.
4767 * stack.c (set_current_sal_from_frame): Adjust.
4768 (print_frame_info): Adjust.
4769 (get_last_displayed_sal): Return the sal via function return
4770 instead of via output parameter. Simplify.
4771 (frame_info): Adjust.
4772 * stack.h (get_last_displayed_sal): Return the sal via function
4773 return instead of via output parameter.
4774 * symtab.c (init_sal): Delete.
4775 (find_pc_sect_line): Remove init_sal references. Move
4776 declarations closer to initializations.
4777 (find_function_start_sal): Remove init_sal references. Move
4778 declarations closer to initializations.
4779 * symtab.h (struct symtab_and_line): In-class initialize all
4780 fields.
4781 * tracepoint.c (set_traceframe_context)
4782 (print_one_static_tracepoint_marker): Remove init_sal references.
4783 Move declarations closer to initializations.
4784 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
4785 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
4786 declarations closer to initializations.
4787 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
4788 init_sal references. Adjust.
4789
6c5b2ebe
PA
47902017-09-04 Pedro Alves <palves@redhat.com>
4791
4792 * ax-gdb.c (agent_command_1): Use range-for.
4793 * break-catch-throw.c (re_set_exception_catchpoint): Update.
4794 * breakpoint.c: Include "common/array-view.h".
4795 (init_breakpoint_sal, create_breakpoint_sal): Change sals
4796 parameter from struct symtabs_and_lines to
4797 array_view<symtab_and_line>. Adjust. Use range-for. Update.
4798 (breakpoint_sals_to_pc): Change sals parameter from struct
4799 symtabs_and_lines to std::vector reference.
4800 (check_fast_tracepoint_sals): Change sals parameter from struct
4801 symtabs_and_lines to std::array_view. Use range-for.
4802 (decode_static_tracepoint_spec): Return a std::vector instead of
4803 symtabs_and_lines. Update.
4804 (create_breakpoint): Update.
4805 (break_range_command, until_break_command, clear_command): Update.
4806 (base_breakpoint_decode_location, bkpt_decode_location)
4807 (bkpt_probe_create_sals_from_location)
4808 (bkpt_probe_decode_location, tracepoint_decode_location)
4809 (tracepoint_probe_decode_location)
4810 (strace_marker_create_sals_from_location): Return a std::vector
4811 instead of symtabs_and_lines.
4812 (strace_marker_create_breakpoints_sal): Update.
4813 (strace_marker_decode_location): Return a std::vector instead of
4814 symtabs_and_lines. Update.
4815 (update_breakpoint_locations): Change struct symtabs_and_lines
4816 parameters to gdb::array_view. Adjust.
4817 (location_to_sals): Return a std::vector instead of
4818 symtabs_and_lines. Update.
4819 (breakpoint_re_set_default): Use std::vector instead of struct
4820 symtabs_and_lines.
4821 (decode_location_default): Return a std::vector instead of
4822 symtabs_and_lines. Update.
4823 * breakpoint.h: Include "common/array-view.h".
4824 (struct breakpoint_ops) <decode_location>: Now returns a
4825 std::vector instead of returning a symtabs_and_lines via output
4826 parameter.
4827 (update_breakpoint_locations): Change sals parameters to use
4828 gdb::array_view.
4829 * cli/cli-cmds.c (edit_command, list_command): Update to use
4830 std::vector and gdb::array_view.
4831 (ambiguous_line_spec): Adjust to use gdb::array_view and
4832 range-for.
4833 (compare_symtabs): Rename to ...
4834 (cmp_symtabs): ... this. Change parameters to symtab_and_line
4835 const reference and adjust.
4836 (filter_sals): Rewrite using std::vector and standard algorithms.
4837 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
4838 (jump_command): Update to use std::vector.
4839 * linespec.c (struct linespec_state) <canonical_names>: Update
4840 comment.
4841 (add_sal_to_sals_basic): Delete.
4842 (add_sal_to_sals, filter_results, convert_results_to_lsals)
4843 (decode_line_2, create_sals_line_offset)
4844 (convert_address_location_to_sals, convert_linespec_to_sals)
4845 (convert_explicit_location_to_sals, parse_linespec)
4846 (event_location_to_sals, decode_line_full, decode_line_1)
4847 (decode_line_with_current_source)
4848 (decode_line_with_last_displayed, decode_objc)
4849 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
4850 (linespec_result::~linespec_result): Adjust to use std::vector
4851 instead of symtabs_and_lines.
4852 * linespec.h (linespec_sals::sals): Now a std::vector.
4853 (struct linespec_result): Use std::vector, bool, and in-class
4854 initialization.
4855 (decode_line_1, decode_line_with_current_source)
4856 (decode_line_with_last_displayed): Return std::vector.
4857 * macrocmd.c (info_macros_command): Use std::vector.
4858 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
4859 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
4860 std::vector.
4861 * probe.h (parse_probes): Return a std::vector.
4862 * python/python.c (gdbpy_decode_line): Use std::vector and
4863 gdb::array_view.
4864 * source.c (select_source_symtab, line_info): Use std::vector.
4865 * stack.c (func_command): Use std::vector.
4866 * symtab.h (struct symtabs_and_lines): Delete.
4867 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
4868
7c44b49c
PA
48692017-09-04 Pedro Alves <palves@redhat.com>
4870
4871 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4872 unittests/array-view-selftests.c.
4873 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
4874 * common/array-view.h: New file.
4875 * unittests/array-view-selftests.c: New file.
4876
e439fa14
PA
48772017-09-04 Pedro Alves <palves@redhat.com>
4878
4879 * cli/cli-cmds.c (edit_command): Pass message to
4880 ambiguous_line_spec.
4881 (list_command): Pass message to ambiguous_line_spec. Say
4882 "first"/"last" instead of "start" and "end" to be consistent with
4883 the manual.
4884 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
4885 them to print formatted message.
4886
7525b645
PA
48872017-09-04 Pedro Alves <palves@redhat.com>
4888
4889 * btrace.c (ftrace_add_pt): Pass btrace_insn to
4890 ftrace_update_insns by reference instead of pointer.
4891
badc0020
YQ
48922017-09-04 Yao Qi <yao.qi@linaro.org>
4893
4894 * i386-go32-tdep.c: Include x86-xstate.h.
4895 (i386_go32_init_abi): Call i386_target_description.
4896 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
4897 if xcr0 is X86_XSTATE_X87_MASK.
4898 * i386-tdep.h (tdesc_i386): Remove the declaration.
4899 (tdesc_i386_mmx): Likewise.
4900
d78bdb54
YQ
49012017-09-04 Yao Qi <yao.qi@linaro.org>
4902
4903 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
4904 X86_XSTATE_SSE_MASK instead of 0.
4905
ca1fa5ee
YQ
49062017-09-04 Yao Qi <yao.qi@linaro.org>
4907
4908 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
4909 i386_target_description.
4910 * i386-fbsd-nat.c (i386fbsd_read_description): Call
4911 i386_target_description.
4912 * i386-tdep.c (i386_gdbarch_init): Likewise.
4913
2434b019
YQ
49142017-09-04 Yao Qi <yao.qi@linaro.org>
4915
4916 * amd64-darwin-tdep.c: Include "x86-xstate.h".
4917 (x86_darwin_init_abi_64): Call amd64_target_description.
4918 * amd64-dicos-tdep.c: Likewise.
4919 * amd64-fbsd-nat.c: Likewise.
4920 * amd64-fbsd-tdep.c: Likewise.
4921 * amd64-nbsd-tdep.c: Likewise.
4922 * amd64-obsd-tdep.c: Likewise.
4923 * amd64-sol2-tdep.c: Likewise.
4924 * amd64-windows-tdep.c: Likewise.
4925 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
4926
0860c437
SM
49272017-09-04 Simon Marchi <simon.marchi@ericsson.com>
4928
4929 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
4930 (btrace_function) <insn>: Change type to use std::vector.
4931 * btrace.c (ftrace_debug, ftrace_call_num_insn,
4932 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
4933 ftrace_update_insns, ftrace_compute_global_level_offset,
4934 btrace_stitch_bts, btrace_clear, btrace_insn_get,
4935 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
4936 change to std::vector.
4937 (ftrace_update_insns): Adjust to change to std::vector, change
4938 type of INSN parameter.
4939 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
4940 * record-btrace.c (btrace_call_history_insn_range,
4941 btrace_compute_src_line_range,
4942 record_btrace_frame_prev_register): Adjust to change to
4943 std::vector.
4944 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
4945 to change to std::vector.
4946
0638b7f9
TT
49472017-09-03 Tom Tromey <tom@tromey.com>
4948
4949 * corefile.c (reopen_exec_file): Use std::string.
4950
8f84fb0e
TT
49512017-09-03 Tom Tromey <tom@tromey.com>
4952
4953 * compile/compile.c (compile_register_name_mangled): Return
4954 std::string.
4955 * compile/compile-loc2c.c (pushf_register_address): Update.
4956 (pushf_register): Update.
4957 * compile/compile-c-types.c (convert_array): Update.
4958 * compile/compile-c-symbols.c (generate_vla_size): Update.
4959 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
4960 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
4961 (convert_one_symbol): Update.
4962 (generate_c_for_for_one_variable): Update.
4963 * compile/compile-c-support.c (c_get_range_decl_name): Return a
4964 std::string.
4965 (generate_register_struct): Update.
4966 * compile/compile-internal.h (c_get_range_decl_name): Return a
4967 std::string.
4968 (compile_register_name_mangled): Return std::string.
4969
18e9961f
TT
49702017-09-03 Tom Tromey <tom@tromey.com>
4971
4972 * utils.c (perror_string): Return a std::string.
4973 (throw_perror_with_name, perror_warning_with_name): Update.
4974
45343786
TT
49752017-09-03 Tom Tromey <tom@tromey.com>
4976
4977 * demangle.c (demangle_command): Use std::string,
4978 unique_xmalloc_ptr.
4979
b57af503
TT
49802017-09-03 Tom Tromey <tom@tromey.com>
4981
4982 * cli/cli-setshow.c (do_set_command): Use std::string.
4983
6eecf35f
TT
49842017-09-03 Tom Tromey <tom@tromey.com>
4985
4986 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
4987
56496dd4
TT
49882017-09-03 Tom Tromey <tom@tromey.com>
4989
4990 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
4991
e91a1fa7
TT
49922017-09-03 Tom Tromey <tom@tromey.com>
4993
4994 * mi/mi-cmd-env.c (env_execute_cli_command): Use
4995 gdb::unique_xmalloc_ptr.
4996
7ffd83d7
TT
49972017-09-03 Tom Tromey <tom@tromey.com>
4998
4999 * thread.c (print_thread_info_1): Use string_printf.
5000 (thread_apply_command, thread_apply_all_command): Use
5001 std::string.
5002
1ccbe998
TT
50032017-09-03 Tom Tromey <tom@tromey.com>
5004
5005 * valprint.c (val_print_string): Update.
5006 * gdbcore.h (memory_error_message): Return std::string.
5007 * corefile.c (memory_error_message): Return std::string.
5008 (memory_error): Update.
5009 * breakpoint.c (insert_bp_location): Update.
5010
23fdd69e
SM
50112017-09-03 Simon Marchi <simon.marchi@ericsson.com>
5012
5013 * target/waitstatus.h (target_waitstatus_to_string): Change
5014 return type to std::string.
5015 * target/waitstatus.c (target_waitstatus_to_string): Return
5016 std::string.
5017 * target.h (target_waitstatus_to_string): Remove declaration.
5018 * infrun.c (resume, clear_proceed_status_thread,
5019 print_target_wait_results, do_target_wait, save_waitstatus,
5020 stop_all_threads): Adjust.
5021 * record-btrace.c (record_btrace_wait): Adjust.
5022 * target-debug.h
5023 (target_debug_print_struct_target_waitstatus_p): Adjust.
5024
5c811d30
JK
50252017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
5026
5027 PR gdb/22046
5028 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
5029 detection.
5030
0a2dde4a
SDJ
50312017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
5032
5033 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
5034 for setting/unsetting environment variables on the remote target.
5035 (New remote packets): Add entries for QEnvironmentHexEncoded,
5036 QEnvironmentUnset and QEnvironmentReset.
5037 * common/environ.c (gdb_environ::operator=): Extend method to
5038 handle m_user_set_env_list and m_user_unset_env_list.
5039 (gdb_environ::clear): Likewise.
5040 (match_var_in_string): Change type of first parameter from 'char
5041 *' to 'const char *'.
5042 (gdb_environ::set): Extend method to handle
5043 m_user_set_env_list and m_user_unset_env_list.
5044 (gdb_environ::unset): Likewise.
5045 (gdb_environ::clear_user_set_env): New method.
5046 (gdb_environ::user_set_envp): Likewise.
5047 (gdb_environ::user_unset_envp): Likewise.
5048 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
5049 m_user_unset_env_list on move constructor/assignment.
5050 (unset): Add new default parameter 'update_unset_list = true'.
5051 (clear_user_set_env): New method.
5052 (user_set_envp): Likewise.
5053 (user_unset_envp): Likewise.
5054 (m_user_set_env_list): New std::set.
5055 (m_user_unset_env_list): Likewise.
5056 * common/rsp-low.c (hex2str): New function.
5057 (bin2hex): New overload for bin2hex function.
5058 * common/rsp-low.c (hex2str): New prototype.
5059 (str2hex): New overload prototype.
5060 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
5061 QEnvironmentUnset and QEnvironmentReset.
5062 (remote_protocol_features): Add QEnvironmentHexEncoded,
5063 QEnvironmentUnset and QEnvironmentReset packets.
5064 (send_environment_packet): New function.
5065 (extended_remote_environment_support): Likewise.
5066 (extended_remote_create_inferior): Call
5067 extended_remote_environment_support.
5068 (_initialize_remote): Add QEnvironmentHexEncoded,
5069 QEnvironmentUnset and QEnvironmentReset packet configs.
5070 * unittests/environ-selftests.c (gdb_selftest_env_var):
5071 New variable.
5072 (test_vector_initialization): New function.
5073 (test_init_from_host_environ): Likewise.
5074 (test_reinit_from_host_environ): Likewise.
5075 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
5076 Likewise.
5077 (test_unset_set_empty_vector): Likewise.
5078 (test_vector_clear): Likewise.
5079 (test_std_move): Likewise.
5080 (test_move_constructor):
5081 (test_self_move): Likewise.
5082 (test_set_unset_reset): Likewise.
5083 (run_tests): Rewrite in terms of the functions above.
5084
654670a4
WP
50852017-08-31 Weimin Pan <weimin.pan@oracle.com>
5086
5087 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
5088 (adi_available): Use a temp variable of type CORE_ADDR as argument
5089 3 when calling target_auxv_search.
5090 (adi_normalize_address): Use masks and xor operators to calculate
5091 normalized address.
5092 (adi_read_versions, adi_write_versions, adi_print_versions)
5093 (do_examine, do_assign): Use paddress.
5094
7755ddb7
JB
50952017-08-29 John Baldwin <jhb@FreeBSD.org>
5096
5097 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
5098 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
5099 out of loop and add supply of FIR.
5100 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
5101 add collect of FIR.
5102
fd437cbc
SM
51032017-08-28 Simon Marchi <simon.marchi@ericsson.com>
5104
3804a343 5105 PR gdb/21827
fd437cbc
SM
5106 * cli/cli-script.c (define_command): Don't convert command name
5107 to lower case.
5108
988f6b3d
JB
51092017-08-25 Joel Brobecker <brobecker@adacore.com>
5110
5111 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
5112 Update all callers accordingly. Remove all code blocks handling
5113 the case where DISPP is not NULL.
5114
663c44ac
JK
51152017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
5116
5117 PR symtab/22003
5118 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
5119 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
5120 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
5121
f1902523
JK
51222017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
5123
5124 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
5125 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
5126 (read_comp_units_from_section): New parameter abbrev_section, use
5127 read_and_check_comp_unit_head, allocate signatured_type if needed.
5128 (create_all_comp_units): Update read_comp_units_from_section caller.
5129
87215ad1
SDJ
51302017-08-23 Pedro Alves <palves@redhat.com>
5131
5132 PR remote/21852
5133 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
5134 to null_ptid and switch to thread without reading the registers
5135 after adding the inferior.
5136
6e41ddec
JK
51372017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
5138
5139 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
5140 compile-gcc.
5141 * compile/compile.c (compile_gcc, show_compile_gcc): New.
5142 (compile_to_object): Implement compile_gcc.
5143 (_initialize_compile): Install "set compile-gcc". Initialize
5144 compile_gcc.
5145
e68c32d5
JK
51462017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
5147
5148 * compile/compile.c (compile_to_object): Conditionally call
5149 set_verbose. Conditionally call compile or compile_v0.
5150
58afddc6
WP
51512017-08-07 Weimin Pan <weimin.pan@oracle.com>
5152
5153 * sparc64-tdep.h: (adi_normalize_address): New export.
5154 * sparc-nat.h: (open_adi_tag_fd): New export.
5155 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
5156 * sparc64-linux-tdep.c:
5157 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
5158 (sparc64_linux_handle_segmentation_fault): New function.
5159 (sparc64_linux_init_abi): Register
5160 sparc64_linux_handle_segmentation_fault
5161 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
5162 (sparc64_addr_bits_remove): New function.
5163 (sparc64_init_abi): Register sparc64_addr_bits_remove.
5164 (MAX_PROC_NAME_SIZE): New macro.
5165 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
5166 (sparc64adilist): New variable.
5167 (adi_proc_list): New variable.
5168 (find_adi_info): New function.
5169 (add_adi_info): New function.
5170 (get_adi_info_proc): New function.
5171 (get_adi_info): New function.
5172 (info_adi_command): New function.
5173 (read_maps_entry): New function.
5174 (adi_available): New function.
5175 (adi_normalize_address): New function.
5176 (adi_align_address): New function.
5177 (adi_convert_byte_count): New function.
5178 (adi_tag_fd): New function.
5179 (adi_is_addr_mapped): New function.
5180 (adi_read_versions): New function.
5181 (adi_write_versions): New function.
5182 (adi_print_versions): New function.
5183 (do_examine): New function.
5184 (do_assign): New function.
5185 (adi_examine_command): New function.
5186 (adi_assign_command): New function.
5187 (_initialize_sparc64_adi_tdep): New function.
5188
11db9430
SM
51892017-08-22 Simon Marchi <simon.marchi@ericsson.com>
5190
5191 * breakpoint.c (breakpoints_info): Rename to ...
5192 (info_breakpoints_command): ... this.
5193 (watchpoints_info): Rename to ...
5194 (info_watchpoints_command): ... this.
5195 (tracepoints_info): Rename to ...
5196 (info_tracepoints_command): ... this.
5197 (_initialize_breakpoint): Adjust.
5198 * dcache.c (dcache_info): Rename to ...
5199 (info_display_command): ... this.
5200 (_initialize_dcache): Adjust.
5201 * frame.h (args_info): Rename to ...
5202 (info_args_command): ... this.
5203 (locals_info): Rename to ...
5204 (info_locals_command): ... this.
5205 * infcmd.c (nofp_registers_info): Rename to ...
5206 (info_registers_command): ... this.
5207 (float_info): Rename to ...
5208 (info_float_command): ... this.
5209 (program_info): Rename to ...
5210 (info_program_command): ... this.
5211 (all_registers_info): Rename to ...
5212 (info_all_registers_command): ... this.
5213 (vector_info): Rename to ...
5214 (info_vector_command): ... this.
5215 (float_info): Rename to ...
5216 (info_float_command): ... this.
5217 (_initialize_infcmd): Adjust.
5218 * inferior.h (term_info): Rename to ...
5219 (info_terminal_command): ... this.
5220 * inflow.c (term_info): Rename to ...
5221 (info_terminal_command): ... this.
5222 (_initialize_inflow): Adjust.
5223 * infrun.c (signals_info): Rename to ...
5224 (info_signals_command): ... this.
5225 (_initialize_infrun): Adjust.
5226 * objc-lang.c (classes_info): Rename to ...
5227 (info_classes_command): ... this.
5228 (selectors_info): Rename to ...
5229 (info_selectors_command): ... this.
5230 (_initialize_objc_language): Adjust.
5231 * printcmd.c (sym_info): Rename to ...
5232 (info_symbol_command): ... this.
5233 (address_info): Rename to ...
5234 (info_address_command): ... this.
5235 (display_info): Rename to ...
5236 (info_display_command): ... this.
5237 (_initialize_printcmd): Adjust.
5238 * reverse.c (bookmarks_info): Rename to ...
5239 (info_breakpoints_command): ... this.
5240 (_initialize_reverse): Adjust.
5241 * ser-go32.c (dos_info): Rename to ...
5242 (info_serial_command): ... this.
5243 (_initialize_ser_dos): Adjust.
5244 * skip.c (skip_info): Rename to ...
5245 (info_skip_command): ... this.
5246 (_initialize_step_skip): Adjust.
5247 * source.c (line_info): Rename to ...
5248 (info_line_command): ... this.
5249 (source_info): Rename to ...
5250 (info_source_command)
5251 * stack.c (frame_info): Rename to ...
5252 (info_frame_command): ... this.
5253 (locals_info): Rename to ...
5254 (info_locals_command): ... this.
5255 (args_info): Rename to ...
5256 (info_args_command): ... this.
5257 (_initialize_stack): Adjust.
5258 * symtab.c (sources_info): Rename to ...
5259 (info_sources_command): ... this.
5260 (variables_info): Rename to ...
5261 (info_variables_command): ... this.
5262 (functions_info): Rename to ...
5263 (info_functions_command): ... this.
5264 (types_info): Rename to ...
5265 (info_types_command): ... this.
5266 (_initialize_symtab): Adjust.
5267 * target.c (target_info): Rename to ...
5268 (info_target_command): ... this.
5269 (initialize_targets): Adjust.
5270 * tracepoint.c (tvariables_info): Rename to ...
5271 (info_tvariables_command): ... this.
5272 (scope_info): Rename to ...
5273 (info_scope_command): ... this.
5274 (trace_dump_actions): Adjust.
5275 (_initialize_tracepoint): Adjust.
5276
b270e6f9
TT
52772017-08-22 Tom Tromey <tom@tromey.com>
5278
5279 * breakpoint.h (install_breakpoint): Update.
5280 * breakpoint.c (add_solib_catchpoint): Update.
5281 (install_breakpoint): Change argument to a std::unique_ptr.
5282 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
5283 (create_breakpoint_sal, create_breakpoint): Update.
5284 (watch_command_1, catch_exec_command_1)
5285 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
5286 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
5287 Return the breakpoint.
5288 (set_raw_breakpoint_without_location, set_raw_breakpoint)
5289 (new_single_step_breakpoint): Update.
5290 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
5291 std::unique_ptr.
5292 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
5293 std::unique_ptr.
5294 * break-catch-sig.c (create_signal_catchpoint): Use
5295 std::unique_ptr.
5296 * ada-lang.c (create_ada_exception_catchpoint): Use
5297 std::unique_ptr.
5298
36bd8eaa
TT
52992017-08-22 Tom Tromey <tom@tromey.com>
5300
5301 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
5302
56f37645
TT
53032017-08-22 Tom Tromey <tom@tromey.com>
5304
5305 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
5306 (lookup_partial_symbol): Update.
5307
0b581c69
TT
53082017-08-22 Tom Tromey <tom@tromey.com>
5309
5310 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
5311 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
5312 (find_and_open_source, symtab_to_fullname): Update.
5313 * psymtab.c (psymtab_to_fullname): Update.
5314
14278e1f
TT
53152017-08-22 Tom Tromey <tom@tromey.com>
5316
5317 * exec.c (exec_file_attach): Update.
5318 * linux-thread-db.c (try_thread_db_load): Update.
5319 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
5320 * utils.c (gdb_realpath): Change return type.
5321 (gdb_realpath_keepfile): Update.
5322 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
5323 (_initialize_utils): Register the new self test.
5324 * source.c (openp): Update.
5325 (find_and_open_source): Update.
5326 * nto-tdep.c (nto_find_and_open_solib): Update.
5327 * main.c (set_gdb_data_directory): Update.
5328 (captured_main_1): Update.
5329 * dwarf2read.c (dwarf2_get_dwz_file): Update
5330 (dw2_map_symbol_filenames): Update.
5331 * auto-load.c (auto_load_safe_path_vec_update): Update.
5332 (filename_is_in_auto_load_safe_path_vec): Change type of
5333 "filename_realp".
5334 (auto_load_objfile_script): Update.
5335 (file_is_auto_load_safe): Update. Use std::string.
5336 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
5337
4971c9a7
TT
53382017-08-22 Tom Tromey <tom@tromey.com>
5339
5340 * utils.c (gdb_realpath_keepfile): Return a
5341 gdb::unique_xmalloc_ptr.
5342 * exec.c (exec_file_attach): Update.
5343 * utils.h (gdb_realpath_keepfile): Return a
5344 gdb::unique_xmalloc_ptr.
5345
e3e41d58
TT
53462017-08-22 Tom Tromey <tom@tromey.com>
5347
5348 * compile/compile.c (compile_file_command): Use
5349 gdb::unique_xmalloc_ptr, std::string.
5350 * utils.c (gdb_abspath): Change return type.
5351 * source.c (openp): Update.
5352 * objfiles.c (allocate_objfile): Update.
5353 * main.c (set_gdb_data_directory): Update.
5354 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
5355
0d999a6e
ZZ
53562017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
5357
5358 * cli-cmds.c (list_commands): List actual code around more than
5359 one location.
5360
329d5e7e
JB
53612017-08-21 John Baldwin <jhb@FreeBSD.org>
5362
5363 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
5364
bf223d3e
PA
53652017-08-21 Pedro Alves <palves@redhat.com>
5366
5367 PR gdb/19487
5368 * c-exp.y (variable production): Handle function aliases.
5369 * minsyms.c (msymbol_is_text): New function.
5370 * minsyms.h (msymbol_is_text): Declare.
5371 * symtab.c (find_function_alias_target): New function.
5372 * symtab.h (find_function_alias_target): Declare.
5373
c973d0aa
PA
53742017-08-21 Pedro Alves <palves@redhat.com>
5375
5376 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
5377 typedefs.
5378 * typeprint.c (whatis_exp): If handling "whatis", and expression
5379 is OP_TYPE, strip one typedef level. Otherwise don't strip
5380 typedefs here.
5381 * valops.c (value_cast): Save "to" type before resolving
5382 stubs/typedefs. Use that type as resulting value's type.
5383
2989a365
TT
53842017-08-18 Tom Tromey <tom@tromey.com>
5385 Pedro Alves <palves@redhat.com>
5386
5387 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
5388 * sol-thread.c (sol_thread_resume, sol_thread_wait)
5389 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
5390 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
5391 * proc-service.c (ps_xfer_memory): Use scoped_restore.
5392 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
5393 (linux_get_siginfo_data): Add "thread" argument. Use
5394 scoped_restore.
5395 * linux-nat.c (linux_child_follow_fork)
5396 (check_stopped_by_watchpoint): Use scoped_restore.
5397 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
5398 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
5399 (restore_inferior_ptid, save_inferior_ptid): Remove.
5400 * btrace.c (btrace_fetch): Use scoped_restore.
5401 * bsd-uthread.c (bsd_uthread_fetch_registers)
5402 (bsd_uthread_store_registers): Use scoped_restore.
5403 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
5404 scoped_restore.
5405 * aix-thread.c (aix_thread_resume, aix_thread_wait)
5406 (aix_thread_xfer_partial): Use scoped_restore.
5407 * inferior.h (save_inferior_ptid): Remove.
5408
e60eb288
YQ
54092017-08-18 Yao Qi <yao.qi@linaro.org>
5410
5411 PR tdep/21818
5412 * arm-tdep.c (gdb_print_insn_arm): Mark
5413 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
5414
6d580b63
YQ
54152017-08-18 Yao Qi <yao.qi@linaro.org>
5416
5417 * NEWS: Mention GDBserver's new option "--selftest".
5418 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
5419 * selftest.c: Move it to common/selftest.c.
5420 * selftest.h: Move it to common/selftest.h.
5421 * selftest-arch.c (reset): New function.
5422 (tests_with_arch): Call reset.
5423
86dcbf50
YQ
54242017-08-18 Yao Qi <yao.qi@linaro.org>
5425
5426 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
5427 instead of exception_fprintf and printf_filtered.
5428
7649770c
YQ
54292017-08-18 Yao Qi <yao.qi@linaro.org>
5430
5431 * selftest.c (register_self_test): Rename it to
5432 selftests::register_test.
5433 (run_self_tests): selftest::run_tests.
5434 * selftest.h: Update declarations.
5435 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
5436 selftests::register_test_foreach_arch.
5437 * selftest-arch.h: Update declaration.
5438 * aarch64-tdep.c: Update.
5439 * arm-tdep.c: Likewise.
5440 * disasm-selftests.c: Likewise.
5441 * dwarf2loc.c: Likewise.
5442 * dwarf2-frame.c: Likewise.
5443 * findvar.c: Likewise.
5444 * gdbarch-selftests.c: Likewise.
5445 * maint.c (maintenance_selftest): Likewise.
5446 * regcache.c: Likewise.
5447 * rust-exp.y: Likewise.
5448 * selftest-arch.c: Likewise.
5449 * unittests/environ-selftests.c: Likewise.
5450 * unittests/function-view-selftests.c: Likewise.
5451 * unittests/offset-type-selftests.c: Likewise.
5452 * unittests/optional-selftests.c: Likewise.
5453 * unittests/scoped_restore-selftests.c: Likewise.
5454 * utils-selftests.c: Likewise.
5455
b0cba12e
PA
54562017-08-17 Pedro Alves <palves@redhat.com>
5457
5458 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
5459 local.
5460
4c8aa72d
PA
54612017-08-17 Pedro Alves <palves@redhat.com>
5462
5463 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
5464 field.
5465 (reset_die_in_process): Delete, replaced by ...
5466 (process_die_scope): ... this new class. Make it responsible for
5467 freeing cu->line_header too.
5468 (process_die): Use process_die_scope.
5469 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
5470 cu->line_header_die_owner. Don't release the line header if it's
5471 owned by the CU.
5472 (setup_type_unit_groups): Make the CU/DIE own the line header.
5473 Don't release the line header here.
5474
ba713918
AL
54752017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
5476
5477 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
5478
44d0fb3a
RK
54792017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
5480
5481 * NEWS: Mention new shortcuts for nexti and stepi in TUI
5482 Single-Key mode
5483
a5afdb16
RK
54842017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
5485
5486 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
5487 mode command list.
5488
47613aeb
SH
54892017-08-15 Stafford Horne <shorne@gmail.com>
5490
5491 * MAINTAINERS (Write After Approval): Add Stafford Horne.
5492
9c3cc999
SH
54932017-08-15 Stafford Horne <shorne@gmail.com>
5494
5495 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
5496
206726fb
SDJ
54972017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
5498
5499 PR gdb/21954
5500 * infcmd.c (unset_environment_command): Use the 'clear' method on
5501 the environment instead of resetting it.
5502
0335ac6d
JB
55032017-08-15 John Baldwin <jhb@FreeBSD.org>
5504
5505 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
5506 platforms.
5507
d3abe1c8
TT
55082017-08-14 Tom Tromey <tom@tromey.com>
5509
5510 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
5511 (print_binary_chars): Likewise.
5512 (BITS_IN_BYTES): Remove.
5513
d6382fff
TT
55142017-08-14 Tom Tromey <tom@tromey.com>
5515
5516 PR gdb/21675
5517 * valprint.c (LOW_ZERO): Change value to 034.
5518 (print_octal_chars): Add static_asserts for octal constants.
5519 * printcmd.c (print_scalar_formatted): Add 'd' case.
5520
f978cb06
TT
55212017-08-11 Tom Tromey <tom@tromey.com>
5522
5523 * symfile.c (add_symbol_file_command): Use std::vector.
5524
2f5404b3
TT
55252017-08-14 Tom Tromey <tom@tromey.com>
5526
5527 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
5528 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
5529 std::move.
5530 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
5531
de7985c3
PA
55322017-08-11 Pedro Alves <palves@redhat.com>
5533
5534 * infrun.c (process_event_stop_test): Adjust
5535 function_name_is_marked_for_skip call.
5536 * skip.c: Include <list>.
5537 (skiplist_entry): Make it a class with private fields, and
5538 getters/setters.
5539 (skiplist_entry_chain): Delete.
5540 (skiplist_entries): New.
5541 (skiplist_entry_count): Delete.
5542 (highest_skiplist_entry_num): New.
5543 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
5544 (add_skiplist_entry): Delete.
5545 (skiplist_entry::skiplist_entry): New.
5546 (skiplist_entry::add_entry): New.
5547 (skip_file_command, skip_function): Adjust.
5548 (compile_skip_regexp): Delete.
5549 (skip_command): Don't compile regexp here. Adjust to use
5550 skiplist_entry::add_entry.
5551 (skip_info): Adjust to use range-for and getters.
5552 (skip_enable_command, skip_disable_command): Adjust to use
5553 range-for and setters.
5554 (skip_delete_command): Adjust to use std::list.
5555 (add_skiplist_entry): Delete.
5556 (skip_file_p): Delete, refactored as ...
5557 (skiplist_entry::do_skip_file_p): ... this new method.
5558 (skip_gfile_p): Delete, refactored as ...
5559 (skiplist_entry::do_gskip_file_p): ... this new method.
5560 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
5561 (skiplist_entry::skip_function_p): ... this new method.
5562 (function_name_is_marked_for_skip): Now returns bool, and takes
5563 the function sal by const reference. Adjust to use range-for and
5564 skiplist_entry methods.
5565 (_initialize_step_skip): Remove references to
5566 skiplist_entry_chain, skiplist_entry_count.
5567 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
5568 takes the function sal by const reference.
5569
be7d3cd5
YQ
55702017-08-11 Yao Qi <yao.qi@linaro.org>
5571
5572 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
5573 (dwarf2_frame_cache): Remove reset_cache_cleanup.
5574 (dwarf2_frame_cache):
5575 * frame-unwind.c (frame_unwind_try_unwinder): Catch
5576 RETURN_MASK_ALL and set *this_case to NULL.
5577 * frame-unwind.h: Update comments.
5578
1c90d9f0
YQ
55792017-08-11 Yao Qi <yao.qi@linaro.org>
5580
5581 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
5582 (dwarf2_frame_state_copy_regs): Remove.
5583 (dwarf2_frame_state_free_regs): Remove.
5584 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
5585 (dwarf2_restore_rule): Call method .alloc_regs instead of
5586 dwarf2_frame_state_alloc_regs.
5587 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
5588 constructor. Call std::move.
5589 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
5590 (dwarf2_frame_cache): Likewise.
5591
5592 [GDB_SELF_TEST]: Include selftest.h and
5593 selftest-arch.h.
5594 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
5595 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
5596 execute_cfa_program_test.
5597
5598 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
5599 copy ctor, assignment operator, move assignment.
5600 <alloc_regs>: New method.
5601 <swap>: New method.
5602 (struct dwarf2_frame_state): Delete dtor.
5603 (dwarf2_frame_state_alloc_regs): Remove declaration.
5604 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
5605 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
5606
afe37d6b
YQ
56072017-08-11 Yao Qi <yao.qi@linaro.org>
5608
5609 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
5610 (dwarf2_frame_state::dwarf2_frame_state): New.
5611 (dwarf2_frame_state::~dwarf2_frame_state): New.
5612 (dwarf2_fetch_cfa_info): Update.
5613 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
5614 rather than a pointer. Update code.
5615 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
5616 dtor.
5617 <data_align, code_align, retaddr_column>: Change them to const.
5618 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
5619 to bool.
5620
b348037f
YQ
56212017-08-11 Yao Qi <yao.qi@linaro.org>
5622
5623 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
5624 <loc.exp>: New field.
5625 * dwarf2-frame.c (execute_cfa_program): Update.
5626 (dwarf2_frame_prev_register): Update.
5627
e7c9de26
PA
56282017-08-10 Pedro Alves <palves@redhat.com>
5629
5630 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
5631
e8c6b620
JB
56322017-08-09 John Baldwin <jhb@FreeBSD.org>
5633
5634 * fbsd-nat.c (struct fbsd_fork_info): Remove.
5635 (fbsd_pending_children): Use std::list.
5636 (fbsd_remember_child): Likewise.
5637 (fbsd_is_child_pending): Likewise.
5638 (fbsd_pending_vfork_done): Use std::forward_list.
5639 (fbsd_add_vfork_done): Likewise.
5640 (fbsd_is_vfork_done_pending): Likewise.
5641 (fbsd_next_vfork_done): Likewise.
5642
e4a26669
JB
56432017-08-09 John Baldwin <jhb@FreeBSD.org>
5644
5645 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
5646 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
5647 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
5648 for `mapfilename'.
5649 (fbsd_xfer_partial): Use gdb::byte_vector.
af3881e6 5650 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
e4a26669 5651
142311d3
JB
56522017-08-09 John Baldwin <jhb@FreeBSD.org>
5653
5654 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
5655 "filestuff.h".
5656 (fbsd_find_memory_regions): Fix `mapfile' initialization.
5657
42fa2e0e
TT
56582017-08-09 Tom Tromey <tom@tromey.com>
5659
5660 * skip.c (skiplist_entry): New constructor.
5661 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
5662 (skiplist_entry::file_is_glob): Now bool.
5663 (skiplist_entry::file, skiplist_entry::function): Now
5664 std::string.
5665 (make_skip_entry): Return a unique_ptr. Use new.
5666 (free_skiplist_entry, free_skiplist_entry_cleanup)
5667 (make_free_skiplist_entry_cleanup): Remove.
5668 (skip_command, skip_disable_command, add_skiplist_entry)
5669 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
5670 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
5671 (function_name_is_marked_for_skip): Update.
5672 (skip_delete_command): Update. Use delete.
5673
cd3af38d
JW
56742017-08-09 Jiong Wang <jiong.wang@arm.com>
5675
5676 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
5677 (aarch64_linux_core_read_description): New function.
5678 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
5679
29592bde
PA
56802017-08-09 Pedro Alves <palves@redhat.com>
5681
5682 * cp-name-parser.y (cp_comp_to_string): Return a
5683 gdb::unique_xmalloc_ptr<char>.
5684 * cp-support.c (replace_typedefs_qualified_name)
5685 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
5686 (cp_canonicalize_string_full): Use op= instead of explicit
5687 convertion.
5688 (cp_class_name_from_physname, method_name_from_physname)
5689 (cp_func_name, cp_remove_params): Adjust to use
5690 gdb::unique_xmalloc_ptr<char>.
5691 * cp-support.h (cp_comp_to_string): Return a
5692 gdb::unique_xmalloc_ptr<char>.
5693 * python/py-type.c (typy_lookup_type): Adjust to use
5694 gdb::unique_xmalloc_ptr<char>.
5695
b3340438
L
56962017-08-09 H.J. Lu <hongjiu.lu@intel.com>
5697
5698 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
5699
e88e8651
YQ
57002017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
5701 Yao Qi <yao.qi@linaro.org>
5702
5703 * cp-support.c (cp_canonicalize_string_full): Use
5704 gdb::unique_xmalloc_ptr<char>.
5705 (cp_canonicalize_string): Likewise.
5706
f5a29eb0
YQ
57072017-08-09 Yao Qi <yao.qi@linaro.org>
5708
5709 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
5710 * regformats/i386/amd64-avx-avx512.dat: Remove.
5711 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
5712 * regformats/i386/amd64-avx-mpx.dat:Remove.
5713 * regformats/i386/amd64-avx.dat: Remove.
5714 * regformats/i386/amd64-mpx.dat: Remove.
5715 * regformats/i386/i386-avx-avx512.dat: Remove.
5716 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
5717 * regformats/i386/i386-avx-mpx.dat: Remove.
5718 * regformats/i386/i386-mmx.dat: Remove.
5719 * regformats/i386/i386-mpx.dat: Remove.
5720
57757c2f
YQ
57212017-08-09 Yao Qi <yao.qi@linaro.org>
5722
5723 * amd64-tdep.h (tdesc_x32): Remove the declaration.
5724 * amd64-tdep.c: Don't include features/i386/x32*.c.
5725 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
5726 functions.
5727 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
5728 and i386/x32-avx-avx512.
5729 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
5730 and i386/x32.xml.
5731 * features/i386/x32-avx-avx512.c: Removed.
5732 * features/i386/x32-avx-avx512.xml: Removed.
5733 * features/i386/x32-avx.c: Removed.
5734 * features/i386/x32-avx.xml: Removed.
5735 * features/i386/x32.c: Removed.
5736 * features/i386/x32.xml: Removed.
5737 * regformats/i386/x32-avx-avx512.dat: Removed.
5738 * regformats/i386/x32-avx.dat: Removed.
5739 * regformats/i386/x32.dat: Removed.
5740
ba7b109b
MR
57412017-08-07 Maciej W. Rozycki <macro@imgtec.com>
5742
5743 PR breakpoints/21886
5744 * mem-break.c (default_memory_insert_breakpoint): Use
5745 `->placed_address' rather than `->reqstd_address' for the
5746 breakpoint location.
5747
e347efc3
MR
57482017-08-07 Maciej W. Rozycki <macro@imgtec.com>
5749
5750 * arch-utils.c (default_print_insn): Remove arch/mach/endian
5751 assertions.
5752
0dba2a6c
MR
57532017-08-07 Maciej W. Rozycki <macro@imgtec.com>
5754
5755 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
5756 a union of `tdep_info', `tdesc_data' and `id'.
5757 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
5758 rather than `info.tdep_info'.
5759 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
5760 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
5761 * i386-tdep.c (i386_gdbarch_init): Likewise.
5762 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
5763 * mips-tdep.c (mips_gdbarch_init): Likewise.
5764 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
5765 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
5766 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
5767 `info.tdep_info'.
5768 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
5769 `info.tdep_info'.
5770 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
5771 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
5772 `info.tdep_info'.
5773 * spu-tdep.c (spu_gdbarch_init): Likewise.
5774 * gdbarch.h: Regenerate.
5775
16eb6b2d
LS
57762017-08-07 Leszek Swirski <leszeks@google.com>
5777
7b005726 5778 PR symtab/20899
16eb6b2d
LS
5779 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
5780
74cbb09e
SM
57812017-08-07 Simon Marchi <simon.marchi@ericsson.com>
5782
5783 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
5784 (gdbsim_open): Rename gdb_argv args object to argv.
5785
ee0c3293
TT
57862017-08-05 Tom Tromey <tom@tromey.com>
5787
5788 * compile/compile-object-load.c (compile_object_load): Use
5789 gdb::unique_xmalloc_ptr.
5790 * cli/cli-dump.c (scan_filename): Rename from
5791 scan_filename_with_cleanup. Change return type.
5792 (scan_expression): Rename from scan_expression_with_cleanup.
5793 Change return type.
5794 (dump_memory_to_file, dump_value_to_file, restore_command):
5795 Use gdb::unique_xmalloc_ptr. Update.
5796 * cli/cli-cmds.c (find_and_open_script): Use
5797 gdb::unique_xmalloc_ptr.
5798 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
5799 * symmisc.c (maintenance_print_symbols)
5800 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
5801 * symfile.c (symfile_bfd_open, generic_load)
5802 (add_symbol_file_command, remove_symbol_file_command): Use
5803 gdb::unique_xmalloc_ptr.
5804 * source.c (openp): Use gdb::unique_xmalloc_ptr.
5805 * psymtab.c (maintenance_print_psymbols): Use
5806 gdb::unique_xmalloc_ptr.
5807 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
5808 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
5809 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
5810 (reload_shared_libraries_1): Likewise.
5811
3232fabd
TT
58122017-08-05 Tom Tromey <tom@tromey.com>
5813
5814 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
5815 (rust_op_vector, rust_set_vector): New typedefs.
5816 (current_parser): New global.
5817 (work_obstack): Change to pointer type. Update all users.
5818 (rust_ast, pstate): Remove globals.
5819 (struct rust_parser): New.
5820 (%union) <params, field_inits>: Change type.
5821 (start, tuple_expr, unit_expr, struct_expr_list, literal)
5822 (field_expr, expr_list, maybe_expr_list, type_list): Update.
5823 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
5824 (convert_params_to_types, convert_params_to_expression): Change
5825 type of "params".
5826 (ast_string): Change type of "fields".
5827 (rust_parse): Make a rust_parser. Remove cleanups.
5828 (rust_lex_tests): Make and install an auto_obstack.
5829
f02fd774
YQ
58302017-08-04 Yao Qi <yao.qi@linaro.org>
5831
5832 * configure.srv (ipa_x32_linux_regobj): New.
5833 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
5834 instead of X86_TDESC_AVX512.
5835 (initialize_low_tracepoint): Call
5836 init_registers_x32_avx_avx512_linux.
5837
91975afd
YQ
58382017-08-04 Yao Qi <yao.qi@linaro.org>
5839
5840 * utils.h (gdb_argv): Add namespace std for nullptr_t.
5841
2331fa3a
RK
58422017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
5843
5844 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
5845
744e4fe1
TT
58462017-08-03 Tom Tromey <tom@tromey.com>
5847
5848 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
5849 Remove.
5850 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
5851
1c034b67
TT
58522017-08-03 Tom Tromey <tom@tromey.com>
5853
5854 * python/py-param.c (compute_enum_values): Use gdb_argv.
5855
773a1edc
TT
58562017-08-03 Tom Tromey <tom@tromey.com>
5857
5858 * utils.h (struct gdb_argv_deleter): New.
5859 (gdb_argv): New class.
5860 * utils.c (gdb_argv::reset): New method.
5861 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
5862 * tracefile.c (tsave_command): Use gdb_argv.
5863 * top.c (new_ui_command): Use gdb_argv.
5864 * symmisc.c (maintenance_print_symbols)
5865 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
5866 * symfile.c (symbol_file_command, generic_load)
5867 (remove_symbol_file_command): Use gdb_argv.
5868 * stack.c (backtrace_command): Use gdb_argv.
5869 * source.c (add_path, show_substitute_path_command)
5870 (unset_substitute_path_command, set_substitute_path_command):
5871 Use gdb_argv.
5872 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
5873 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
5874 * remote.c (extended_remote_run, remote_put_command)
5875 (remote_get_command, remote_delete_command): Use gdb_argv.
5876 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
5877 (gdbsim_open): Use gdb_argv.
5878 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
5879 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
5880 * procfs.c (procfs_info_proc): Use gdb_argv.
5881 * interps.c (interpreter_exec_cmd): Use gdb_argv.
5882 * infrun.c (handle_command): Use gdb_argv.
5883 * inferior.c (add_inferior_command, clone_inferior_command):
5884 Use gdb_argv.
5885 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
5886 * exec.c (exec_file_command): Use gdb_argv.
5887 * cli/cli-cmds.c (alias_command): Use gdb_argv.
5888 * compile/compile.c (build_argc_argv): Use gdb_argv.
5889
0d50bde3
TT
58902017-08-03 Tom Tromey <tom@tromey.com>
5891
5892 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
5893
7f968c89
TT
58942017-08-03 Tom Tromey <tom@tromey.com>
5895
5896 * python/python.c (compute_python_string): Return std::string.
5897 (gdbpy_eval_from_control_command): Update.
5898 (do_start_initialization): Use std::string.
5899 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
5900 xstrprintf.
5901 * python/py-breakpoint.c (local_setattro): Use string_printf, not
5902 xstrprintf.
5903
3c9ebddd
TT
59042017-08-03 Tom Tromey <tom@tromey.com>
5905
5906 * top.h (do_restore_instream_cleanup): Remove.
5907 * top.c (do_restore_instream_cleanup): Remove.
5908 (read_command_file): Use scoped_restore.
5909 * cli/cli-script.c (execute_user_command): Use scoped_restore.
5910
b51b225e
TT
59112017-08-03 Tom Tromey <tom@tromey.com>
5912
5913 * cli/cli-script.c (execute_user_command)
5914 (execute_control_command): Use scoped_restore.
5915
ac991630
TT
59162017-08-03 Tom Tromey <tom@tromey.com>
5917
5918 * cli/cli-script.c (do_restore_user_call_depth): Remove.
5919 (execute_user_command): Remove user_call_depth; use
5920 user_args_stack's size instead.
5921
898e0c8e
TT
59222017-08-03 Tom Tromey <tom@tromey.com>
5923
5924 * top.h (in_user_command): Remove.
5925 * top.c (in_user_command): Remove.
5926 * cli/cli-script.c (do_restore_user_call_depth)
5927 (execute_user_command): Update.
5928
26fcd5d7
TT
59292017-08-03 Tom Tromey <tom@tromey.com>
5930
5931 * valops.c (search_struct_method): Use gdb::byte_vector.
5932 * valarith.c (value_concat): Use std::vector.
5933 * target.c (memory_xfer_partial): Use gdb::byte_vector.
5934 (simple_search_memory): Likewise.
5935 * printcmd.c (find_string_backward): Use gdb::byte_vector.
5936 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
5937 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
5938 * elfread.c (elf_rel_plt_read): Use std::string.
5939 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
5940 * cli/cli-dump.c (restore_section_callback): Use
5941 gdb::byte_vector.
5942
7c218e6c
TT
59432017-08-03 Tom Tromey <tom@tromey.com>
5944
5945 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
5946
31b68d4a
TT
59472017-08-03 Tom Tromey <tom@tromey.com>
5948
5949 * tui/tui-regs.c (tui_restore_gdbout): Remove.
5950 (tui_register_format): Use scoped_restore.
5951
2ec845e7
TT
59522017-08-03 Tom Tromey <tom@tromey.com>
5953
5954 * reverse.c (exec_direction_default): Remove.
5955 (exec_reverse_once): Use scoped_restore.
5956 * remote.c (restore_remote_timeout): Remove.
5957 (remote_flash_erase, remote_flash_write, remote_flash_done)
5958 (readchar, remote_serial_write): Use scoped_restore.
5959 * cli/cli-script.c (struct source_cleanup_lines_args)
5960 (source_cleanup_lines): Remove.
5961 (script_from_file): Use scoped_restore.
5962 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
5963 (source_command): Use scoped_restore.
5964
b3bc8453
TT
59652017-08-03 Tom Tromey <tom@tromey.com>
5966
5967 * utils.h (make_cleanup_free_so): Remove.
5968 * utils.c (do_free_so, make_cleanup_free_so): Remove.
5969 * solist.h (struct so_deleter): New.
5970 (so_list_up): New typedef.
5971 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
5972
e3ad2841
TT
59732017-08-03 Tom Tromey <tom@tromey.com>
5974
5975 * utils.h (make_cleanup_restore_current_language): Remove.
5976 * utils.c (do_restore_current_language)
5977 (make_cleanup_restore_current_language): Remove.
5978 * parse.c (parse_exp_in_context_1)
5979 (parse_expression_with_language): Use
5980 scoped_restore_current_language.
5981 * mi/mi-main.c (mi_cmd_execute): Use
5982 scoped_restore_current_language.
5983 * language.h (scoped_restore_current_language): New class.
5984
b80cf838
TT
59852017-08-03 Tom Tromey <tom@tromey.com>
5986
5987 * compile/compile.c (cleanup_unlink_file): Remove.
5988 (compile_to_object): Use gdb::unlinker.
5989 (eval_compile_command): Likewise.
5990
fad0444a
TT
59912017-08-03 Tom Tromey <tom@tromey.com>
5992
5993 * utils.h (make_cleanup_fclose): Remove.
5994 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
5995
6e7bc05c
TT
59962017-08-03 Tom Tromey <tom@tromey.com>
5997
5998 * top.c (open_terminal_stream): Return gdb_file_up.
5999 (new_ui_command): Update.
6000
4a45905b
TT
60012017-08-03 Tom Tromey <tom@tromey.com>
6002
6003 * source.c (print_source_lines_base, forward_search_command)
6004 (reverse_search_command): Use gdb_file_up.
6005
7cd06d6e
TT
60062017-08-03 Tom Tromey <tom@tromey.com>
6007
6008 * fbsd-nat.c (fbsd_find_memory_regions): Update.
6009
ed166945
TT
60102017-08-03 Tom Tromey <tom@tromey.com>
6011
6012 * cli/cli-cmds.c (find_and_open_script): Change return type.
6013 Remove "streamp" and "full_path" parameters.
6014 (source_script_with_search): Update.
6015 * auto-load.c (source_script_file): Update.
6016 * cli/cli-cmds.h (find_and_open_script): Change type.
6017 (open_script): New struct.
6018
d419f42d
TT
60192017-08-03 Tom Tromey <tom@tromey.com>
6020
6021 * xml-support.c (xml_fetch_content_from_file): Update.
6022 * ui-file.c (stdio_file::open): Update.
6023 * tracefile-tfile.c (tfile_start): Update.
6024 * remote.c (remote_file_put, remote_file_get): Update.
6025 * nat/linux-procfs.c (linux_proc_get_int)
6026 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
6027 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
6028 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
6029 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
6030 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
6031 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
6032 * linux-nat.c (linux_proc_pending_signals): Update.
6033 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
6034 (file_closer): Remove.
6035 * compile/compile.c (compile_to_object): Update.
6036 * common/filestuff.h (struct gdb_file_deleter): New.
6037 (gdb_file_up): New typedef.
6038 (gdb_fopen_cloexec): Change return type.
6039 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
6040 * cli/cli-dump.c (fopen_with_cleanup): Remove.
6041 (dump_binary_file, restore_binary_file): Update.
6042 * auto-load.c (auto_load_objfile_script_1): Update.
6043
4a2b031d
TT
60442017-08-03 Tom Tromey <tom@tromey.com>
6045
6046 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
6047 (info_static_tracepoint_markers_command): Likewise.
6048 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
6049 * skip.c (skip_info): Use ui_out_emit_table.
6050 * progspace.c (print_program_space): Use ui_out_emit_table.
6051 * osdata.c (info_osdata): Use ui_out_emit_table.
6052 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
6053 ui_out_emit_table.
6054 * linux-thread-db.c (info_auto_load_libthread_db): Use
6055 ui_out_emit_table.
6056 * inferior.c (print_inferior): Use ui_out_emit_table.
6057 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
6058 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
6059 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
6060 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
6061 * ui-out.h (class ui_out_emit_table): New.
6062
a4f320fd
MR
60632017-08-02 Maciej W. Rozycki <macro@imgtec.com>
6064
6065 * mips-tdep.c (mips_fpu_type_str): New function.
6066 (mips_dump_tdep): Call it.
6067
a2f1f308
MR
60682017-08-01 Maciej W. Rozycki <macro@imgtec.com>
6069
6070 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
6071 `->mips_fpu_type'.
6072
7e5ed83b
XR
60732017-07-31 Xavier Roirand <roirand@adacore.com>
6074
6075 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
6076
4c9dc811
XR
60772017-07-27 Xavier Roirand <roirand@adacore.com>
6078
6079 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
6080
27d41eac
YQ
60812017-07-26 Yao Qi <yao.qi@linaro.org>
6082
6083 * cli/cli-cmds.c (maintenancechecklist): New variable.
6084 * gdbcmd.h (maintenancechecklist): Declare it.
6085 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
6086 Call i386_linux_read_description with different masks.
6087 * maint.c (maintenance_check_command): New function.
6088 (_initialize_maint_cmds): Call add_prefix_cmd.
6089 * target-descriptions.c (tdesc_reg): override operator != and ==.
6090 (tdesc_type): Likewise.
6091 (tdesc_feature): Likewise.
6092 (target_desc): Likewise.
6093 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
6094 (maintenance_check_xml_descriptions): New function.
6095 (_initialize_target_descriptions) Add command "xml-descriptions".
6096 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
6097
ea03d0d3
YQ
60982017-07-26 Yao Qi <yao.qi@linaro.org>
6099
6100 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
6101 Include features/i386/32bit-*.c.
6102 (i386_linux_read_description): Generate target description if it
6103 doesn't exist.
6104 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
6105 functions.
6106 * features/i386/32bit-linux.c: Re-generated.
6107 * features/i386/32bit-sse.c: Likewise.
6108 * target-descriptions.c (print_c_feature::visit): Print code to
6109 set register number if needed.
6110 (print_c_feature) <m_next_regnum>: New field.
6111
25aa13e5
YQ
61122017-07-26 Yao Qi <yao.qi@linaro.org>
6113
6114 * features/Makefile (CFILES): Rename with TDESC_CFILES.
6115 (FEATURE_XMLFILES): New.
6116 (FEATURE_CFILES): New.
6117 New rules.
6118 (clean-cfiles): Remove generated c files.
6119 * features/i386/32bit-avx.c: Generated.
6120 * features/i386/32bit-avx512.c: Generated.
6121 * features/i386/32bit-core.c: Generated.
6122 * features/i386/32bit-linux.c: Generated.
6123 * features/i386/32bit-mpx.c: Generated.
6124 * features/i386/32bit-pkeys.c: Generated.
6125 * features/i386/32bit-sse.c: Generated.
6126 * target-descriptions.c: Include algorithm.
6127 (tdesc_element_visitor): Add method visit_end.
6128 (print_c_tdesc): Implement visit_end.
6129 (print_c_tdesc:: m_filename_after_features): Move it to
6130 protected.
6131 (print_c_feature): New class.
6132 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
6133 name starts with "i386/32bit-".
6134
6eb1e6a8
YQ
61352017-07-26 Yao Qi <yao.qi@linaro.org>
6136
6137 * target-descriptions.c (tdesc_element_visitor): New class.
6138 (tdesc_element): New class.
6139 (tdesc_reg): Inherit from tdesc_element.
6140 (tdesc_reg::accept): New function.
6141 (tdesc_type): Inherit from tdesc_element.
6142 (tdesc_type::accept): New function.
6143 (tdesc_feature): Inherit from tdesc_element.
6144 (tdesc_feature::accept): New function.
6145 (target_desc): Inherit from tdesc_element.
6146 (target_desc::target_desc): New.
6147 (target_desc::~target_desc): New.
6148 (target_desc::accept): New.
6149 (allocate_target_description): Use new.
6150 (free_target_description): Use delete.
6151 (print_c_tdesc): New class.
6152 (maint_print_c_tdesc_cmd): Adjust.
6153
6154 * features/aarch64.c: Re-generated.
6155 * features/arc-arcompact.c: Re-generated.
6156 * features/arc-v2.c: Re-generated.
6157 * features/arm/arm-with-iwmmxt.c: Re-generated.
6158 * features/arm/arm-with-m.c: Re-generated.
6159 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
6160 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
6161 * features/arm/arm-with-neon.c: Re-generated.
6162 * features/arm/arm-with-vfpv2.c: Re-generated.
6163 * features/arm/arm-with-vfpv3.c: Re-generated.
6164 * features/i386/amd64-avx-avx512.c: Re-generated.
6165 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
6166 * features/i386/amd64-avx.c: Re-generated.
6167 * features/i386/amd64-avx-linux.c: Re-generated.
6168 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
6169 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
6170 * features/i386/amd64-avx-mpx.c: Re-generated.
6171 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
6172 * features/i386/amd64.c: Re-generated.
6173 * features/i386/amd64-linux.c: Re-generated.
6174 * features/i386/amd64-mpx.c: Re-generated.
6175 * features/i386/amd64-mpx-linux.c: Re-generated.
6176 * features/i386/i386-avx-avx512.c: Re-generated.
6177 * features/i386/i386-avx-avx512-linux.c: Re-generated.
6178 * features/i386/i386-avx.c: Re-generated.
6179 * features/i386/i386-avx-linux.c: Re-generated.
6180 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
6181 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
6182 * features/i386/i386-avx-mpx.c: Re-generated.
6183 * features/i386/i386-avx-mpx-linux.c: Re-generated.
6184 * features/i386/i386.c: Re-generated.
6185 * features/i386/i386-linux.c: Re-generated.
6186 * features/i386/i386-mmx.c: Re-generated.
6187 * features/i386/i386-mmx-linux.c: Re-generated.
6188 * features/i386/i386-mpx.c: Re-generated.
6189 * features/i386/i386-mpx-linux.c: Re-generated.
6190 * features/i386/x32-avx-avx512.c: Re-generated.
6191 * features/i386/x32-avx-avx512-linux.c: Re-generated.
6192 * features/i386/x32-avx.c: Re-generated.
6193 * features/i386/x32-avx-linux.c: Re-generated.
6194 * features/i386/x32.c: Re-generated.
6195 * features/i386/x32-linux.c: Re-generated.
6196 * features/microblaze.c: Re-generated.
6197 * features/microblaze-with-stack-protect.c: Re-generated.
6198 * features/mips64-dsp-linux.c: Re-generated.
6199 * features/mips64-linux.c: Re-generated.
6200 * features/mips-dsp-linux.c: Re-generated.
6201 * features/mips-linux.c: Re-generated.
6202 * features/nds32.c: Re-generated.
6203 * features/nios2.c: Re-generated.
6204 * features/nios2-linux.c: Re-generated.
6205 * features/rs6000/powerpc-32.c: Re-generated.
6206 * features/rs6000/powerpc-32l.c: Re-generated.
6207 * features/rs6000/powerpc-403.c: Re-generated.
6208 * features/rs6000/powerpc-403gc.c : Re-generated.
6209 * features/rs6000/powerpc-405.c: Re-generated.
6210 * features/rs6000/powerpc-505.c: Re-generated.
6211 * features/rs6000/powerpc-601.c: Re-generated.
6212 * features/rs6000/powerpc-602.c: Re-generated.
6213 * features/rs6000/powerpc-603.c: Re-generated.
6214 * features/rs6000/powerpc-604.c: Re-generated.
6215 * features/rs6000/powerpc-64.c: Re-generated.
6216 * features/rs6000/powerpc-64l.c: Re-generated.
6217 * features/rs6000/powerpc-7400.c: Re-generated.
6218 * features/rs6000/powerpc-750.c: Re-generated.
6219 * features/rs6000/powerpc-860.c: Re-generated.
6220 * features/rs6000/powerpc-altivec32.c: Re-generated.
6221 * features/rs6000/powerpc-altivec32l.c: Re-generated.
6222 * features/rs6000/powerpc-altivec64.c: Re-generated.
6223 * features/rs6000/powerpc-altivec64l.c: Re-generated.
6224 * features/rs6000/powerpc-cell32l.c: Re-generated.
6225 * features/rs6000/powerpc-cell64l.c: Re-generated.
6226 * features/rs6000/powerpc-e500.c: Re-generated.
6227 * features/rs6000/powerpc-e500l.c: Re-generated.
6228 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
6229 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
6230 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
6231 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
6232 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
6233 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
6234 * features/rs6000/powerpc-vsx32.c: Re-generated.
6235 * features/rs6000/powerpc-vsx32l.c: Re-generated.
6236 * features/rs6000/powerpc-vsx64.c: Re-generated.
6237 * features/rs6000/powerpc-vsx64l.c: Re-generated.
6238 * features/rs6000/rs6000.c: Re-generated.
6239 * features/s390-linux32.c: Re-generated.
6240 * features/s390-linux32v1.c: Re-generated.
6241 * features/s390-linux32v2.c: Re-generated.
6242 * features/s390-linux64.c: Re-generated.
6243 * features/s390-linux64v1.c: Re-generated.
6244 * features/s390-linux64v2.c: Re-generated.
6245 * features/s390-te-linux64.c: Re-generated.
6246 * features/s390-tevx-linux64.c: Re-generated.
6247 * features/s390-vx-linux64.c: Re-generated.
6248 * features/s390x-linux64.c: Re-generated.
6249 * features/s390x-linux64v1.c: Re-generated.
6250 * features/s390x-linux64v2.c: Re-generated.
6251 * features/s390x-te-linux64.c: Re-generated.
6252 * features/s390x-tevx-linux64.c: Re-generated.
6253 * features/s390x-vx-linux64.c: Re-generated.
6254 * features/sparc/sparc32-solaris.c: Re-generated.
6255 * features/sparc/sparc64-solaris.c: Re-generated.
6256 * features/tic6x-c62x.c: Re-generated.
6257 * features/tic6x-c62x-linux.c: Re-generated.
6258 * features/tic6x-c64x.c: Re-generated.
6259 * features/tic6x-c64x-linux.c: Re-generated.
6260 * features/tic6x-c64xp.c: Re-generated.
6261 * features/tic6x-c64xp-linux.c: Re-generated.
6262
35b4818d
YQ
62632017-07-26 Yao Qi <yao.qi@linaro.org>
6264
6265 * i386-linux-tdep.c (i386_linux_read_description): New function.
6266 (i386_linux_core_read_description): Call
6267 i386_linux_read_description.
6268 * i386-linux-tdep.h (i386_linux_read_description): Declare.
6269 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
6270 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
6271 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
6272 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
6273 * x86-linux-nat.c (x86_linux_read_description): Call
6274 i386_linux_read_description.
6275
8e2141c6
YQ
62762017-07-26 Yao Qi <yao.qi@linaro.org>
6277
6278 * NEWS: Mention it.
6279 * features/Makefile (%.c: %.xml): Pass the xml file name to
6280 command "maint print c-tdesc".
6281 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
6282 name from 'arg'.
6283
b468ff4c
YQ
62842017-07-26 Yao Qi <yao.qi@linaro.org>
6285
6286 * target-descriptions.c (target_desc): Add ctor and dtor. Do
6287 in-class initialization.
6288 (tdesc_create_feature): Call new instead of XCNEW.
6289 (free_target_description): Ue delete.
6290
b9c0e1b4
JB
62912017-07-25 John Baldwin <jhb@FreeBSD.org>
6292
6293 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
6294
a04b5337
YQ
62952017-07-25 Yao Qi <yao.qi@linaro.org>
6296
6297 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
6298 constant.
6299 (amd64_x32_init_abi): Likewise.
6300 * amd64-tdep.h (amd64_init_abi): Update declaration.
6301 (amd64_x32_init_abi): Likewise.
6302
02ad7fc2
YQ
63032017-07-25 Yao Qi <yao.qi@linaro.org>
6304
6305 PR tdep/21717
6306 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
6307 condition for FPSCR.
6308 (arm_linux_store_inferior_registers): Likewise.
6309
b6f48cb0
TT
63102017-07-22 Tom Tromey <tom@tromey.com>
6311
6312 * break-catch-syscall.c (struct catch_syscall_inferior_data)
6313 <syscalls_counts>: Now a std::vector.
6314 (get_catch_syscall_inferior_data): Use "new".
6315 (catch_syscall_inferior_data_cleanup): Use "delete".
6316 (insert_catch_syscall, remove_catch_syscall)
6317 (clear_syscall_counts): Update.
6318
e12c9b7a
TT
63192017-07-22 Tom Tromey <tom@tromey.com>
6320
6321 * break-catch-syscall.c (syscall_catchpoint)
6322 <syscalls_to_be_caught>: Now a std::vector<int>
6323 (~syscall_catchpoint): Remove.
6324 (insert_catch_syscall, remove_catch_syscall)
6325 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
6326 (print_mention_catch_syscall, print_recreate_catch_syscall):
6327 Update.
6328 (create_syscall_event_catchpoint): Change type of "filter"
6329 parameter.
6330 (catch_syscall_split_args): Return a std::vector.
6331 (catch_syscall_command_1, catching_syscall_number_1): Update.
6332
4fa8aeac
TT
63332017-07-22 Tom Tromey <tom@tromey.com>
6334
6335 * break-catch-throw.c (struct exception_catchpoint)
6336 <exception_rx>: Now a std::string.
6337 (~exception_catchpoint): Remove.
6338 (print_one_detail_exception_catchpoint): Update.
6339 (handle_gnu_v3_exceptions): Change type of except_rx.
6340 (extract_exception_regexp): Return a std::string.
6341 (catch_exception_command_1): Update.
6342
f746a154
TT
63432017-07-22 Tom Tromey <tom@tromey.com>
6344
6345 * break-catch-sig.c (gdb_signal_type): Remove typedef.
6346 (struct signal_catchpoint) <signals_to_be_caught>: Now a
6347 std::vector.
6348 <catch_all>: Now a bool.
6349 (~signal_catchpoint): Remove.
6350 (signal_catchpoint_insert_location)
6351 (signal_catchpoint_remove_location)
6352 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
6353 (signal_catchpoint_print_mention)
6354 (signal_catchpoint_print_recreate)
6355 (signal_catchpoint_explains_signal): Update.
6356 (create_signal_catchpoint): Change type of "filter" and
6357 "catch_all".
6358 (catch_signal_split_args): Return a std::vector. Change type of
6359 "catch_all".
6360 (catch_signal_command): Update.
6361
47e77640
PA
63622017-07-20 Pedro Alves <palves@redhat.com>
6363
6364 * ada-lang.c (ada_language_defn): Make extern.
6365 (_initialize_ada_language): Remove add_language call.
6366 * c-lang.c (c_language_defn, cplus_language_defn)
6367 (asm_language_defn, minimal_language_defn): Make extern.
6368 (_initialize_c_language): Delete.
6369 * completer.c (compare_cstrings): Delete, moved to utils.h.
6370 * d-lang.c (d_language_defn): Make extern.
6371 (_initialize_d_language): Remove add_language calls.
6372 * defs.h (enum language): Add comment.
6373 * f-lang.c (f_language_defn): Make extern.
6374 (_initialize_f_language): Remove add_language call.
6375 * go-lang.c (go_language_defn): Make extern.
6376 (_initialize_go_language): Remove add_language call.
6377 * language.c: Include <algorithm>.
6378 (languages): Redefine as const array.
6379 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
6380 (set_language_command): Handle "local". Use for-range loop.
6381 (set_language): Remove loop.
6382 (language_enum): Rewrite.
6383 (language_def, language_str): Remove loops.
6384 (add_language): Delete.
6385 (add_set_language_command): New, based on add_languages.
6386 (skip_language_trampoline): Adjust.
6387 (local_language_defn): Delete.
6388 (language_gdbarch_post_init): Adjust.
6389 (_initialize_language): Remove add_language calls. Call
6390 add_set_language_command.
6391 * language.h (add_language): Delete.
6392 (auto_language_defn)
6393 (unknown_language_defn, minimal_language_defn, ada_language_defn)
6394 (asm_language_defn, c_language_defn, cplus_language_defn)
6395 (d_language_defn, f_language_defn, go_language_defn)
6396 (m2_language_defn, objc_language_defn, opencl_language_defn)
6397 (pascal_language_defn, rust_language_defn): Declare.
6398 * m2-lang.c (m2_language_defn): Make extern.
6399 (_initialize_m2_language): Remove add_language call.
6400 * objc-lang.c (objc_language_defn): Make extern.
6401 (_initialize_objc_language): Remove add_language call.
6402 * opencl-lang.c (opencl_language_defn): Make extern.
6403 (_initialize_opencl_language): Remove add_language call.
6404 * p-lang.c (pascal_language_defn): Make extern.
6405 (_initialize_pascal_language): Delete.
6406 * rust-lang.c (rust_language_defn): Make extern.
6407 (_initialize_rust_language): Delete.
6408 * utils.h (compare_cstrings): New static inline function.
6409
edb0c9cb
PA
64102017-07-20 Pedro Alves <palves@redhat.com>
6411
6412 * ada-lang.c (ada_to_fixed_type_1): Adjust.
6413 (get_var_value): Constify parameters.
6414 (get_int_var_value): Change prototype.
6415 (to_fixed_range_type): Adjust.
6416 * ada-lang.h (get_int_var_value): Change prototype.
6417
a778f165
PA
64182017-07-20 Pedro Alves <palves@redhat.com>
6419
6420 * dwarf2read.c (dw2_lookup_symbol): Use
6421 SYMBOL_MATCHES_SEARCH_NAME.
6422 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
6423
42edd901
PA
64242017-07-20 Pedro Alves <palves@redhat.com>
6425
6426 * block.c (block_iter_name_step, block_iter_name_first)
6427 (block_iter_name_next): Delete.
6428 (block_lookup_symbol_primary): Adjust to use
6429 dict_iter_match_first/dict_iter_match_next.
6430 * block.h (block_iter_name_first, block_iter_name_next): Delete
6431 declarations.
6432 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
6433 dict_iter_match_first/dict_iter_match_next.
6434
cf325299
PA
64352017-07-20 Pedro Alves <palves@redhat.com>
6436
6437 * cp-support.c (cp_find_first_component_aux): Add missing case for
6438 end of string.
6439
c5ed0576
DB
64402017-07-18 David Blaikie <dblaikie@gmail.com>
6441
6442 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
6443 of dwo_cu's dwo_file.
6444
27841e76
YQ
64452017-07-18 Yao Qi <yao.qi@linaro.org>
6446
6447 * remote.c (store_registers_using_G): Remove one line comment.
6448
cfb7e58b
YQ
64492017-07-18 Yao Qi <yao.qi@linaro.org>
6450
6451 * regcache.c (regcache_cpy): Simplify it.
6452 (regcache::cpy_no_passthrough): Remove it.
6453 * regcache.h (cpy_no_passthrough): Remove it.
6454 (regcache_dup, regcache_cpy): Update comments.
6455
386535dd
PA
64562017-07-18 Pedro Alves <palves@redhat.com>
6457
6458 * remote-sim.c (sim_command_completer): Adjust to work with a
6459 completion_tracker instead of a VEC.
6460
c45ec17c
PA
64612017-07-17 Pedro Alves <palves@redhat.com>
6462
6463 * completer.c (complete_source_filenames): New function.
6464 (complete_address_and_linespec_locations): New function.
6465 (location_completer): Use complete_address_and_linespec_locations.
6466 (completion_tracker::build_completion_result): Honor the tracker's
6467 request to suppress append.
6468 * completer.h (completion_tracker::suppress_append_ws)
6469 (completion_tracker::set_suppress_append_ws): New methods.
6470 (completion_tracker::m_suppress_append_ws): New field.
6471 (complete_source_filenames): New declaration.
6472 * linespec.c (linespec_complete_what): New.
6473 (struct ls_parser) <complete_what, completion_word,
6474 completion_quote_char, completion_quote_end, completion_tracker>:
6475 New fields.
6476 (string_find_incomplete_keyword_at_end): New.
6477 (linespec_lexer_lex_string): Record quote char. If in completion
6478 mode, don't throw.
6479 (linespec_lexer_consume_token): Advance the completion word point.
6480 (linespec_lexer_peek_token): Save/restore completion info.
6481 (save_stream_and_consume_token): New.
6482 (set_completion_after_number): New.
6483 (linespec_parse_basic): Set what to complete next depending on
6484 token. Handle function and label completions specially.
6485 (parse_linespec): Disable objc shortcut in completion mode. Set
6486 what to complete next depending on token type. Skip keyword if in
6487 completion mode.
6488 (complete_linespec_component, linespec_complete): New.
6489 * linespec.h (linespec_complete): Declare.
6490
be966d42
PA
64912017-07-17 Pedro Alves <palves@redhat.com>
6492
6493 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
6494 Handle 'operator<' / 'operator<<'.
6495
a2459270
PA
64962017-07-17 Pedro Alves <palves@redhat.com>
6497
6498 * completer.c (collect_explicit_location_matches): Handle
6499 MATCH_LABEL.
6500 (convert_explicit_location_to_linespec): New, factored out from
6501 ...
6502 (convert_explicit_location_to_sals): ... this.
6503 (complete_label): New.
6504 (linespec_complete_label, find_label_symbols_in_block): New.
6505 (find_label_symbols): Add completion_mode parameter and adjust to
6506 call find_label_symbols_in_block.
6507 * linespec.h (linespec_complete_label): Declare.
6508
c6756f62
PA
65092017-07-17 Pedro Alves <palves@redhat.com>
6510
6511 * ada-lang.c (ada_collect_symbol_completion_matches): Add
6512 complete_symbol_mode parameter.
6513 * cli/cli-cmds.c (complete_command): Get the completion result out
6514 of the handle_brkchars tracker if used a custom word point.
6515 * completer.c: Include "linespec.h".
6516 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
6517 (advance_to_expression_complete_word_point): New.
6518 (completion_tracker::completes_to_completion_word): New.
6519 (complete_files_symbols): Pass down
6520 complete_symbol_mode::EXPRESSION.
6521 (explicit_options, probe_options): New.
6522 (collect_explicit_location_matches): Complete on the
6523 explictit_loc->foo instead of word. Use
6524 linespec_complete_function. Handle MATCH_LINE. Handle offering
6525 keyword and options completions.
6526 (backup_text_ptr): Delete.
6527 (skip_keyword): New.
6528 (complete_explicit_location): Remove 'word' parameter. Add
6529 language, quoted_arg_start and quoted_arg_end parameters.
6530 Rewrite, parsing left to right.
6531 (location_completer): Rewrite.
6532 (location_completer_handle_brkchars): New function.
6533 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
6534 (enum complete_line_internal_reason): Adjust comments.
6535 (completion_tracker::discard_completions): New.
6536 (completer_handle_brkchars_func_for_completer): Handle
6537 location_completer.
6538 (gdb_custom_word_point_brkchars)
6539 (gdb_org_rl_basic_quote_characters): New.
6540 (gdb_completion_word_break_characters_throw)
6541 (completion_find_completion_word): Handle trackers that use a
6542 custom word point.
6543 (completion_tracker::advance_custom_word_point_by): New.
6544 (completion_tracker::build_completion_result): Don't rely on
6545 readline appending the quote char.
6546 (gdb_rl_attempted_completion_function_throw): Handle trackers that
6547 use a custom word point.
6548 (gdb_rl_attempted_completion_function): Restore
6549 rl_basic_quote_characters.
6550 * completer.h (class completion_tracker): Extend intro comment.
6551 (completion_tracker::set_quote_char)
6552 (completion_tracker::quote_char)
6553 (completion_tracker::set_use_custom_word_point)
6554 (completion_tracker::use_custom_word_point)
6555 (completion_tracker::custom_word_point)
6556 (completion_tracker::set_custom_word_point)
6557 (completion_tracker::advance_custom_word_point_by)
6558 (completion_tracker::completes_to_completion_word)
6559 (completion_tracker::discard_completions): New methods.
6560 (completion_tracker::m_quote_char)
6561 (completion_tracker::m_use_custom_word_point)
6562 (completion_tracker::m_custom_word_point): New fields.
6563 (advance_to_expression_complete_word_point): Declare.
6564 * f-lang.c (f_collect_symbol_completion_matches): Add
6565 complete_symbol_mode parameter.
6566 * language.h (struct language_defn)
6567 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
6568 parameter.
6569 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
6570 (linespec_complete_function): New function.
6571 (linespec_lexer_lex_keyword): Adjust.
6572 * linespec.h (linespec_keywords, linespec_complete_function): New
6573 declarations.
6574 * location.c (find_end_quote): New function.
6575 (explicit_location_lex_one): Add explicit_completion_info
6576 parameter. Save quoting info. Don't throw if being called for
6577 completion. Don't handle Ada operators here.
6578 (is_cp_operator, skip_op_false_positives, first_of)
6579 (explicit_location_lex_one_function): New function.
6580 (string_to_explicit_location): Replace 'dont_throw' parameter with
6581 an explicit_completion_info pointer parameter. Handle it. Don't
6582 use explicit_location_lex_one to lex function names. Use
6583 explicit_location_lex_one_function instead.
6584 * location.h (struct explicit_completion_info): New.
6585 (string_to_explicit_location): Replace 'dont_throw' parameter with
6586 an explicit_completion_info pointer parameter.
6587 * symtab.c (default_collect_symbol_completion_matches_break_on):
6588 Add complete_symbol_mode parameter. Handle LINESPEC mode.
6589 (default_collect_symbol_completion_matches)
6590 (collect_symbol_completion_matches): Add complete_symbol_mode
6591 parameter.
6592 (collect_symbol_completion_matches_type): Pass down
6593 complete_symbol_mode::EXPRESSION.
6594 (collect_file_symbol_completion_matches): Add complete_symbol_mode
6595 parameter. Handle LINESPEC mode.
6596 * symtab.h (complete_symbol_mode): New.
6597 (default_collect_symbol_completion_matches_break_on)
6598 (default_collect_symbol_completion_matches)
6599 (collect_symbol_completion_matches)
6600 (collect_file_symbol_completion_matches): Add complete_symbol_mode
6601 parameter.
6602
1d550c82
PA
66032017-07-17 Pedro Alves <palves@redhat.com>
6604
6605 * utils.c (enum class strncmp_iw_mode): New.
6606 (strcmp_iw): Rename to ...
6607 (strncmp_iw_with_mode): ... this. Add string2_len and mode
6608 parameters. Handle them.
6609 (strncmp_iw): New.
6610 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
6611 * utils.h (strncmp_iw): Declare.
6612 (strcmp_iw): Move describing comments here.
6613
8090b426
PA
66142017-07-17 Pedro Alves <palves@redhat.com>
6615
6616 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
6617 CP_OPERATOR_STR.
6618 * c-typeprint.c (is_type_conversion_operator): Use
6619 CP_OPERATOR_STR.
6620 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
6621 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
6622 CP_OPERATOR_LEN.
6623 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
6624 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
6625 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
6626 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
6627 CP_OPERATOR_STR.
6628 * location.c: Include "cp-support.h".
6629 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
6630 CP_OPERATOR_STR.
6631 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
6632 CP_OPERATOR_LEN.
6633
6a2c1b87
PA
66342017-07-17 Pedro Alves <palves@redhat.com>
6635
6636 * cli/cli-cmds.c (complete_command): Use a completion tracker
6637 along with completion_find_completion_word for handle_brkchars
6638 phase.
6639 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
6640 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
6641 (struct gdb_rl_completion_word_info): New.
6642 (gdb_rl_find_completion_word): New.
6643 (completion_find_completion_word): New.
6644 * completer.h (completion_find_completion_word): Declare.
6645
eb3ff9a5
PA
66462017-07-17 Pedro Alves <palves@redhat.com>
6647
6648 * ada-lang.c (symbol_completion_match): Adjust comments.
6649 (symbol_completion_add): Replace vector parameter with
6650 completion_tracker parameter. Use it.
6651 (ada_make_symbol_completion_list): Rename to...
6652 (ada_collect_symbol_completion_matches): ... this. Add
6653 completion_tracker parameter and use it.
6654 (ada_language_defn): Adjust.
6655 * break-catch-syscall.c (catch_syscall_completer): Adjust
6656 prototype and work with completion_tracker instead of VEC.
6657 * breakpoint.c (condition_completer): Adjust prototype and work
6658 with completion_tracker instead of VEC.
6659 * c-lang.c (c_language_defn, cplus_language_defn)
6660 (asm_language_defn, minimal_language_defn): Adjust to renames.
6661 * cli/cli-cmds.c (complete_command): Rework using
6662 completion_tracker. Catch exceptions when completing.
6663 * cli/cli-decode.c (integer_unlimited_completer)
6664 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
6665 with completion_tracker instead of VEC.
6666 * command.h (struct completion_tracker): Forward declare.
6667 (completer_ftype, completer_handle_brkchars_ftype): Change
6668 types.
6669 (complete_on_cmdlist, complete_on_enum): Adjust.
6670 * completer.c: Include <algorithm>.
6671 (struct gdb_completer_state): New.
6672 (current_completion): New global.
6673 (readline_line_completion_function): Delete.
6674 (noop_completer, filename_completer)
6675 (filename_completer_handle_brkchars, complete_files_symbols)
6676 (linespec_location_completer): Adjust to work with a
6677 completion_tracker instead of a VEC.
6678 (string_or_empty): New.
6679 (collect_explicit_location_matches): Adjust to work with a
6680 completion_tracker instead of a VEC.
6681 (explicit_location_completer): Rename to ...
6682 (complete_explicit_location): ... this and adjust to work with a
6683 completion_tracker instead of a VEC.
6684 (location_completer): Adjust to work with a completion_tracker
6685 instead of a VEC.
6686 (add_struct_fields): Adjust to work with a completion_list instead
6687 of VEC.
6688 (expression_completer): Rename to ...
6689 (complete_expression): ... this and adjust to work with a
6690 completion_tracker instead of a VEC. Use complete_files_symbols.
6691 (expression_completer): Reimplement on top of complete_expression.
6692 (symbol_completer): Adjust to work with a completion_tracker
6693 instead of a VEC.
6694 (enum complete_line_internal_reason): Add describing comments.
6695 (complete_line_internal_normal_command): Adjust to work with a
6696 completion_tracker instead of a VEC.
6697 (complete_line_internal): Rename to ...
6698 (complete_line_internal_1): ... this and adjust to work with a
6699 completion_tracker instead of a VEC. Assert TEXT is NULL in the
6700 handle_brkchars phase.
6701 (new_completion_tracker): Delete.
6702 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
6703 complete_line_internal_1.
6704 (free_completion_tracker): Delete.
6705 (INITIAL_COMPLETION_HTAB_SIZE): New.
6706 (completion_tracker::completion_tracker)
6707 (completion_tracker::~completion_tracker): New.
6708 (maybe_add_completion): Delete.
6709 (completion_tracker::maybe_add_completion)
6710 (completion_tracker::add_completion)
6711 (completion_tracker::add_completions): New.
6712 (throw_max_completions_reached_error): Delete.
6713 (complete_line): Adjust to work with a completion_tracker instead
6714 of a VEC. Don't create a completion_tracker_t or check for max
6715 completions here.
6716 (command_completer, command_completer_handle_brkchars)
6717 (signal_completer, reg_or_group_completer_1)
6718 (reg_or_group_completer, default_completer_handle_brkchars):
6719 Adjust to work with a completion_tracker.
6720 (gdb_completion_word_break_characters_throw): New.
6721 (gdb_completion_word_break_characters): Reimplement.
6722 (line_completion_function): Delete.
6723 (completion_tracker::recompute_lowest_common_denominator)
6724 (expand_preserving_ws)
6725 (completion_tracker::build_completion_result)
6726 (completion_result::completion_result)
6727 (completion_result::completion_result)
6728 (completion_result::~completion_result)
6729 (completion_result::completion_result)
6730 (completion_result::release_match_list, compare_cstrings)
6731 (completion_result::sort_match_list)
6732 (completion_result::reset_match_list)
6733 (gdb_rl_attempted_completion_function_throw)
6734 (gdb_rl_attempted_completion_function): New.
6735 * completer.h (completion_list, struct completion_result)
6736 (class completion_tracker): New.
6737 (complete_line): Add completion_tracker parameter.
6738 (readline_line_completion_function): Delete.
6739 (gdb_rl_attempted_completion_function): New.
6740 (noop_completer, filename_completer, expression_completer)
6741 (location_completer, symbol_completer, command_completer)
6742 (signal_completer, reg_or_group_completer): Update prototypes.
6743 (completion_tracker_t, new_completion_tracker)
6744 (make_cleanup_free_completion_tracker): Delete.
6745 (enum maybe_add_completion_enum): Delete.
6746 (maybe_add_completion): Delete.
6747 (throw_max_completions_reached_error): Delete.
6748 * corefile.c (complete_set_gnutarget): Adjust to work with a
6749 completion_tracker instead of a VEC.
6750 * cp-abi.c (cp_abi_completer): Adjust to work with a
6751 completion_tracker instead of a VEC.
6752 * d-lang.c (d_language_defn): Adjust.
6753 * disasm.c (disassembler_options_completer): Adjust to work with a
6754 completion_tracker instead of a VEC.
6755 * f-lang.c (f_make_symbol_completion_list): Rename to ...
6756 (f_collect_symbol_completion_matches): ... this. Adjust to work
6757 with a completion_tracker instead of a VEC.
6758 (f_language_defn): Adjust.
6759 * go-lang.c (go_language_defn): Adjust.
6760 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
6761 Adjust to work with a completion_tracker instead of a VEC.
6762 * infrun.c (handle_completer): Likewise.
6763 * interps.c (interpreter_completer): Likewise.
6764 * interps.h (interpreter_completer): Likewise.
6765 * language.c (unknown_language_defn, auto_language_defn)
6766 (local_language_defn): Adjust.
6767 * language.h (language_defn::la_make_symbol_completion_list):
6768 Rename to ...
6769 (language_defn::la_collect_symbol_completion_matches): ... this
6770 and adjust to work with a completion_tracker instead of a VEC.
6771 * m2-lang.c (m2_language_defn): Adjust.
6772 * objc-lang.c (objc_language_defn): Adjust.
6773 * opencl-lang.c (opencl_language_defn): Adjust.
6774 * p-lang.c (pascal_language_defn): Adjust.
6775 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
6776 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
6777 with a completion_tracker.
6778 * rust-lang.c (rust_language_defn): Adjust.
6779 * symtab.c (free_completion_list, do_free_completion_list)
6780 (return_val, completion_tracker): Delete.
6781 (completion_list_add_name, completion_list_add_symbol)
6782 (completion_list_add_msymbol, completion_list_objc_symbol)
6783 (completion_list_add_fields, add_symtab_completions): Add
6784 completion_tracker parameter and use it.
6785 (default_make_symbol_completion_list_break_on_1): Rename to...
6786 (default_collect_symbol_completion_matches_break_on): ... this.
6787 Add completion_tracker parameter and use it instead of allocating
6788 a completion tracker here.
6789 (default_make_symbol_completion_list_break_on): Delete old
6790 implementation.
6791 (default_make_symbol_completion_list): Delete.
6792 (default_collect_symbol_completion_matches): New.
6793 (make_symbol_completion_list): Delete.
6794 (collect_symbol_completion_matches): New.
6795 (make_symbol_completion_type): Rename to ...
6796 (collect_symbol_completion_matches_type): ... this. Add
6797 completion_tracker parameter and use it instead of VEC.
6798 (make_file_symbol_completion_list_1): Rename to...
6799 (collect_file_symbol_completion_matches): ... this. Add
6800 completion_tracker parameter and use it instead of VEC.
6801 (make_file_symbol_completion_list): Delete.
6802 (add_filename_to_list): Use completion_list instead of a VEC.
6803 (add_partial_filename_data::list): Now a completion_list.
6804 (make_source_files_completion_list): Work with a completion_list
6805 instead of a VEC.
6806 * symtab.h: Include "completer.h".
6807 (default_make_symbol_completion_list_break_on)
6808 (default_make_symbol_completion_list, make_symbol_completion_list)
6809 (make_symbol_completion_type, make_file_symbol_completion_list)
6810 (make_source_files_completion_list): Delete.
6811 (default_collect_symbol_completion_matches_break_on)
6812 (default_collect_symbol_completion_matches)
6813 (collect_symbol_completion_matches)
6814 (collect_symbol_completion_matches_type)
6815 (collect_file_symbol_completion_matches)
6816 (make_source_files_completion_list): New.
6817 * top.c (init_main): Don't install a rl_completion_entry_function
6818 hook. Install a rl_attempted_completion_function hook instead.
6819 * tui/tui-layout.c (layout_completer): Adjust to work with a
6820 completion_tracker.
6821 * tui/tui-regs.c (tui_reggroup_completer):
6822 * tui/tui-win.c (window_name_completer, focus_completer)
6823 (winheight_completer): Adjust to work with a completion_tracker.
6824 * value.c: Include "completer.h".
6825 (complete_internalvar): Adjust to work with a completion_tracker.
6826 * value.h (complete_internalvar): Likewise.
6827
6e1dbf8c
PA
68282017-07-17 Pedro Alves <palves@redhat.com>
6829
6830 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
6831 renames.
6832 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
6833 comments to completer_ftype's declaration.
6834 <completer_handle_brkchars>: Change type to
6835 completer_handle_brkchars_ftype.
6836 * command.h (completer_ftype): Add describing comment and give
6837 names to parameters.
6838 (completer_ftype_void): Rename to ...
6839 (completer_handle_brkchars_ftype) ... this. Add describing comment.
6840 (set_cmd_completer_handle_brkchars): Adjust.
6841 * completer.c (filename_completer_handle_brkchars): New function.
6842 (complete_line_internal_normal_command): New function, factored
6843 out from ...
6844 (complete_line_internal): ... here.
6845 (command_completer_handle_brkchars)
6846 (default_completer_handle_brkchars)
6847 (completer_handle_brkchars_func_for_completer): New functions.
6848 * completer.h (set_gdb_completion_word_break_characters): Delete
6849 declaration.
6850 (completer_handle_brkchars_func_for_completer): New declaration.
6851 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
6852 completer_handle_brkchars_func_for_completer.
6853
78b13106
PA
68542017-07-17 Pedro Alves <palves@redhat.com>
6855
6856 * completer.c (symbol_completer): New function, based on
6857 make_symbol_completion_list_fn.
6858 * completer.h (symbol_completer): New declaration.
6859 * guile/scm-cmd.c (cmdscm_completers): Adjust.
6860 * python/py-cmd.c (completers): Adjust.
6861 * symtab.c (make_symbol_completion_list_fn): Delete.
6862 * symtab.h (make_symbol_completion_list_fn): Delete.
6863 * cli/cli-decode.c (add_cmd): Adjust.
6864
bbf2f4df
PA
68652017-07-17 Pedro Alves <palves@redhat.com>
6866
6867 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
6868 * dwarf2read.c: Include "filename-seen-cache.h".
6869 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
6870 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
6871 * filename-seen-cache.c: New file.
6872 * filename-seen-cache.h: New file.
6873 * symtab.c: Include "filename-seen-cache.h".
6874 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
6875 (create_filename_seen_cache, clear_filename_seen_cache)
6876 (delete_filename_seen_cache, filename_seen): Delete, parts moved
6877 to filename-seen-cache.h/filename-seen-cache.c.
6878 (output_source_filename, sources_info)
6879 (maybe_add_partial_symtab_filename)
6880 (make_source_files_completion_list): Adjust to use
6881 filename_seen_cache.
6882
330cdd98
PA
68832017-07-17 Pedro Alves <palves@redhat.com>
6884
6885 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
6886 fields.
6887 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
6888 dwarf2_debug_sections*)): New.
6889 (dwarf2_per_objfile::dwarf2_per_objfile(const
6890 dwarf2_per_objfile&)): Declare as deleted.
6891 (dwarf2_per_objfile::operator=): Declare as deleted.
6892 (dwarf2_per_objfile::dwarf2_per_objfile)
6893 (dwarf2_per_objfile::~dwarf2_per_objfile)
6894 (dwarf2_per_objfile::free_cached_comp_units): New.
6895 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
6896 ctor. Call dwarf2_per_objfile's ctor manually.
6897 (dwarf2_locate_sections): Deleted/refactored as ...
6898 (dwarf2_per_objfile::locate_sections): ... this new method.
6899 (free_cached_comp_units): Defer to
6900 dwarf2_per_objfile::free_cached_comp_units.
6901 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
6902
8880f2a9
TT
69032017-07-14 Tom Tromey <tom@tromey.com>
6904
6905 PR rust/21764:
6906 * rust-exp.y (convert_ast_to_expression): Add "want_type"
6907 parameter.
6908 <UNOP_SIZEOF>: Split into separate case.
6909 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
6910
65547233
TT
69112017-07-14 Tom Tromey <tom@tromey.com>
6912
6913 PR rust/21763:
6914 * symtab.c (symbol_matches_domain): Add language_rust to special
6915 case.
6916 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
6917 treat LOC_TYPEDEF symbols as variables.
6918
8f14146e
PA
69192017-07-14 Pedro Alves <palves@redhat.com>
6920
6921 * symtab.c (make_file_symbol_completion_list_1): Iterate over
6922 symtabs matching all symtabs with SRCFILE as file name instead of
6923 only considering the first hit, with lookup_symtab.
6924
2347965c
SM
69252017-07-14 Simon Marchi <simon.marchi@ericsson.com>
6926
6927 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
6928 operator_name parameters.
6929 (gen_expr): Update function call.
6930
40f4af28
SM
69312017-07-14 Simon Marchi <simon.marchi@ericsson.com>
6932
6933 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
6934 parameter.
6935 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
6936 Likewise.
6937 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
6938 parameter, use agent_expr::gdbarch instead, update function
6939 calls.
6940 (locexpr_tracepoint_var_ref): Likewise.
6941 (loclist_tracepoint_var_ref): Likewise.
6942 * ax-gdb.c (gen_trace_static_fields): Likewise.
6943 (gen_traced_pop): Likewise.
6944 (gen_frame_args_address): Likewise.
6945 (gen_frame_locals_address): Likewise.
6946 (gen_var_ref): Likewise.
6947 (gen_struct_ref_recursive): Likewise.
6948 (gen_static_field): Likewise.
6949 (gen_maybe_namespace_elt): Likewise.
6950 (gen_expr): Likewise.
6951 (gen_trace_for_var): Likewise.
6952 (gen_trace_for_expr): Likewise.
6953 (gen_trace_for_return_address): Likewise.
6954
053f8057
SM
69552017-07-14 Simon Marchi <simon.marchi@ericsson.com>
6956
6957 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
6958 parameter.
6959 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
6960
6661ad48
SM
69612017-07-14 Simon Marchi <simon.marchi@ericsson.com>
6962
6963 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
6964 from ax, update calls.
6965 (gen_usual_arithmetic): Likewise.
6966 (gen_integral_promotions): Likewise.
6967 (gen_bitfield_ref): Likewise.
6968 (gen_primitive_field): Likewise.
6969 (gen_struct_ref_recursive): Likewise.
6970 (gen_struct_ref): Likewise.
6971 (gen_maybe_namespace_elt): Likewise.
6972 (gen_struct_elt_for_reference): Likewise.
6973 (gen_namespace_elt): Likewise.
6974 (gen_aggregate_elt_ref): Likewise.
6975 (gen_expr): Get gdbarch from ax, update calls.
6976 (gen_expr_binop_rest): Likewise.
6977
c55a47e7
PA
69782017-07-13 Pedro Alves <palves@redhat.com>
6979
6980 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
6981 as default tdesc.
6982 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
6983 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
6984 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
6985 tdesc_amd64_linux as default tdesc. Get final tdesc from the
6986 tdep.
6987 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
6988 Get final tdesc from the tdep.
6989 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
6990 default tdesc.
6991 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
6992 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
6993 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
6994 Use it as default tdesc.
6995 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
6996 down to amd_init_abi. No longer handle fallback tdesc here.
6997 * amd64-tdep.h (tdesc_x32): Declare.
6998 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
6999 parameter.
7000 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
7001 as default tdesc.
7002
55efceab
AA
70032017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7004
7005 * s390-linux-tdep.c (s390_process_record): Add support for
7006 instructions new in arch12.
7007
0aa37b65
JB
70082017-07-11 John Baldwin <jhb@FreeBSD.org>
7009
7010 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
7011 PT_GETFSBASE and PT_GETGSBASE.
7012 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
7013 PT_SETGSBASE.
7014
48aeef91
JB
70152017-07-11 John Baldwin <jhb@FreeBSD.org>
7016
7017 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
7018 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
7019 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
7020 those rules.
7021 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
7022 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
7023 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
7024 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
7025 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
7026 * features/i386/amd64.xml: Add 64bit-segments.xml.
7027 * features/i386/amd64-avx-avx512.c: Regenerated.
7028 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
7029 * features/i386/amd64-avx-mpx.c: Regenerated.
7030 * features/i386/amd64-avx.c: Regenerated.
7031 * features/i386/amd64-mpx.c: Regenerated.
7032 * features/i386/amd64.c: Regenerated.
7033 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
7034 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
7035 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
7036 * regformats/i386/amd64-avx.dat: Regenerated.
7037 * regformats/i386/amd64-mpx.dat: Regenerated.
7038 * regformats/i386/amd64.dat: Regenerated.
7039
77c501bc
YQ
70402017-07-10 Yao Qi <yao.qi@linaro.org>
7041
7042 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
7043 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
7044
6dc8d757
AK
70452017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
7046
7047 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
7048 unsetenv.
7049 * gnulib/aclocal.m4: Regenerate.
7050 * gnulib/config.in: Regenerate.
7051 * gnulib/configure: Regenerate.
7052 * gnulib/import/Makefile.am: Regenerate.
7053 * gnulib/import/Makefile.in: Regenerate.
7054 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
7055 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
7056 * gnulib/import/m4/environ.m4: New file.
7057 * gnulib/import/m4/setenv.m4: New file.
7058 * gnulib/import/setenv.c: New file.
7059 * gnulib/import/unsetenv.c: New file.
7060
266934d1
SM
70612017-07-09 Simon Marchi <simon.marchi@ericsson.com>
7062
7063 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
7064 address when op is DW_OP_addr.
7065
03278692
TT
70662017-07-09 Tom Tromey <tom@tromey.com>
7067
7068 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
7069 check and apply to outer type.
7070
4b654465
JB
70712017-07-07 John Baldwin <jhb@FreeBSD.org>
7072
7073 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
7074 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
7075 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
7076 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
7077
2af9fc44
JB
70782017-07-07 John Baldwin <jhb@FreeBSD.org>
7079
7080 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
7081
382b69bb
JB
70822017-07-07 John Baldwin <jhb@FreeBSD.org>
7083
7084 * corelow.c (get_core_siginfo): Remove.
7085 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
7086 instead of get_core_siginfo.
7087 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
7088 * gdbarch.h: Re-generate.
7089 * gdbarch.c: Re-generate.
7090 * linux-tdep.c (linux_core_xfer_siginfo): New.
7091 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
7092
6e5eab33
JB
70932017-07-07 John Baldwin <jhb@FreeBSD.org>
7094
7095 * corelow.c (thread_section_name): Move to ...
7096 * gdbcore.h (thread_section_name): ... here.
7097
929edea9
JB
70982017-07-07 John Baldwin <jhb@FreeBSD.org>
7099
7100 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
7101 (struct siginfo32): New.
7102 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
7103 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
7104 via ptrace(PT_LWPINFO).
7105
762c974a
JB
71062017-07-07 John Baldwin <jhb@FreeBSD.org>
7107
7108 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
7109 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
7110 (fbsd_get_siginfo_type): New.
7111 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
7112 (_initialize_fbsd_tdep): New.
7113
33c5cd75
DB
71142017-07-06 David Blaikie <dblaikie@gmail.com>
7115
7116 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
7117 a singular dwo_unit*) to support multiple CUs in the same way that
7118 multiple TUs are supported.
7119 (create_cus_hash_table): Replace create_dwo_cu with a function for
7120 parsing multiple CUs from a DWO file.
7121 (open_and_init_dwo_file): Use create_cus_hash_table rather than
7122 create_dwo_cu.
7123 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
7124 htab_find, rather than comparing the signature to a singleton CU in
7125 the dwo_file.
7126
8455d262
PA
71272017-07-06 Pedro Alves <palves@redhat.com>
7128
7129 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
7130
4da3eb35
PA
71312017-07-04 Pedro Alves <palves@redhat.com>
7132
7133 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
7134 * gdbtypes.h (TYPE_STATIC): Delete.
7135 (struct fn_field) <is_public, is_abstract, is_static, is_final,
7136 is_synchronized, is_native>: Delete.
7137 <dummy>: Bump.
7138 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
7139 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
7140 (TYPE_FN_FIELD_ABSTRACT): Delete.
7141
5bfd255c
SM
71422017-07-03 Simon Marchi <simon.marchi@ericsson.com>
7143
7144 * buffer.h (buffer_finish): Fix spelling mistakes.
7145
25c54127
EZ
71462017-07-01 Eli Zaretskii <eliz@gnu.org>
7147
7148 * .dir-locals.el: Automatically switch to C-style comments in
7149 versions of Emacs that support the feature.
7150
dc4bde35
SDJ
71512017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
7152 Pedro Alves <palves@redhat.com>
7153
7154 PR cli/21688
7155 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
7156 (process_next_line): New variable 'inline_cmd'.
7157 Adjust 'if' clauses for "python", "compile" and "guile" to use
7158 'command_name_equals' and check for '!inline_cmd'.
7159
51ed89aa
SDJ
71602017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
7161
7162 PR cli/21688
7163 * cli/cli-script.c (command_name_equals_not_inline): New function.
7164 (process_next_line): Adjust 'if' clauses for "python", "compile"
7165 and "guile" to use command_name_equals_not_inline.
7166
eb17d413
PA
71672017-06-29 Pedro Alves <palves@redhat.com>
7168
7169 * completer.c (expression_completer): Call
7170 linespec_location_completer instead of location_completer.
7171
195bcdd5
PA
71722017-06-29 Pedro Alves <palves@redhat.com>
7173
7174 * completer.c (expression_completer): Remove code that recomputes
7175 'text' from 'word'.
7176
adc764e7
YQ
71772017-06-29 Yao Qi <yao.qi@linaro.org>
7178
7179 * regformats/regdat.sh: Generate code with
7180 "ifndef IN_PROCESS_AGENT".
7181
6e75794e
PA
71822017-06-28 Pedro Alves <palves@redhat.com>
7183
7184 * command.h: Include "common/scoped_restore.h".
7185
bc491f2e
YQ
71862017-06-28 Yao Qi <yao.qi@linaro.org>
7187
7188 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
7189 instead of obstack_grow.
7190
41664b45
DG
71912017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
7192
7193 PR gdb/21337
7194 * symfile.c (reread_symbols): Call objfiles_changed just before
7195 read_symbols.
7196
6da67eb1
PA
71972017-06-27 Pedro Alves <palves@redhat.com>
7198
7199 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
7200 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
7201 (completion_list_add_symbol, completion_list_add_msymbol):
7202 ... these new functions.
7203 (add_symtab_completions)
7204 (default_make_symbol_completion_list_break_on_1): Adjust.
7205
23732b1e
PA
72062017-06-27 Pedro Alves <palves@redhat.com>
7207
7208 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
7209 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
7210 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
7211 dtor.
7212 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
7213 'storage_obstack' field an auto_obstack. In-class initialize all
7214 non-bitfield fields. Make minsyms_read bool.
7215 * symfile.c (read_symbols): Adjust.
7216
a4d1e79a
AH
72172017-06-27 Alan Hayward <alan.hayward@arm.com>
7218
7219 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
7220 (gdbsim_store_register): Likewise.
7221
8268c778
PA
72222017-06-27 Pedro Alves <palves@redhat.com>
7223
7224 * c-exp.y (name_obstack): Now an auto_obstack.
7225 (yylex): Use auto_obstack::clear.
7226 (c_parse): Use auto_obstack::clear instead of reinitializing and
7227 freeing the obstack.
7228 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
7229 * d-exp.y (name_obstack): Now an auto_obstack.
7230 (yylex): Use auto_obstack::clear.
7231 (d_parse): Use auto_obstack::clear instead of reinitializing and
7232 freeing the obstack.
7233 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
7234 auto_obstack.
7235 * dwarf2read.c (create_addrmap_from_index)
7236 (dwarf2_build_psymtabs_hard)
7237 (update_enumeration_type_from_children): Likewise.
7238 * gdb_obstack.h (auto_obstack): New type.
7239 * go-exp.y (name_obstack): Now an auto_obstack.
7240 (build_packaged_name): Use auto_obstack::clear.
7241 (go_parse): Use auto_obstack::clear instead of reinitializing and
7242 freeing the obstack.
7243 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
7244 auto_obstack.
7245 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
7246 * rust-exp.y (work_obstack): Now an auto_obstack.
7247 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
7248 reinitializing and freeing the obstack.
7249 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
7250 (host_char_to_target): Use auto_obstack.
7251 * utils.h (make_cleanup_obstack_free): Delete declaration.
7252 * valprint.c (generic_emit_char, generic_printstr): Use
7253 auto_obstack.
7254
db665f42
SM
72552017-06-27 Simon Marchi <simon.marchi@ericsson.com>
7256
7257 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
7258 thread.
7259 (darwin_init_thread_list): Don't update dummy thread.
7260 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
7261
873c0814
SM
72622017-06-26 Simon Marchi <simon.marchi@ericsson.com>
7263
7264 * record-full.c (netorder16): Remove.
7265
8b5a7a6e
SM
72662017-06-26 Simon Marchi <simon.marchi@ericsson.com>
7267
7268 * common/diagnostics.h: Define macros for GCC.
7269 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
7270 * common/vec.h: Include diagnostics.h.
7271 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
7272 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
7273 warning.
7274
d1435379
SM
72752017-06-26 Simon Marchi <simon.marchi@ericsson.com>
7276
7277 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
7278 New macro.
7279 * ada-lex.l: Ignore deprecated register warnings.
7280
cc75e0fd
SM
72812017-06-25 Simon Marchi <simon.marchi@ericsson.com>
7282
7283 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
7284 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
7285
07809eaf
SM
72862017-06-25 Simon Marchi <simon.marchi@ericsson.com>
7287
7288 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
7289 its own line.
7290
f076f034
SM
72912017-06-25 Simon Marchi <simon.marchi@ericsson.com>
7292
7293 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
7294
0dd5cbc5
AH
72952017-06-23 Alan Hayward <alan.hayward@arm.com>
7296
7297 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
7298 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
7299 (xtensa_register_read_masked): Likewise.
7300
d4c6ce5b
SDJ
73012017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
7302
7303 * common/environ.c (gdb_environ::unset): Update comment.
7304
16892a03
AH
73052017-06-22 Alan Hayward <alan.hayward@arm.com>
7306
7307 * python/py-unwind.c (pyuw_sniffer): Allocate space for
7308 registers.
7309
d7dcbefc
AH
73102017-06-22 Alan Hayward <alan.hayward@arm.com>
7311
7312 * record-full.c (record_full_exec_insn): Use byte_vector.
7313
b30ff123
YQ
73142017-06-22 Yao Qi <yao.qi@linaro.org>
7315
7316 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
7317 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
7318
4fa847d7
AH
73192017-06-22 Alan Hayward <alan.hayward@arm.com>
7320
7321 * remote.c (cached_reg): Move from here...
7322 * regcache.h (cached_reg): ...to here.
7323 * python/py-unwind.c (struct reg_info): Remove.
7324 (cached_frame_info): Use cached_reg_t.
7325 (pyuw_prev_register): Likewise.
7326 (pyuw_sniffer): Use cached_reg_t and allocate registers.
7327 (pyuw_dealloc_cache): Free all registers.
7328
f4906a9a
PA
73292017-06-22 Pedro Alves <palves@redhat.com>
7330 Simon Marchi <simon.marchi@ericsson.com>
7331
7332 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
7333 warning.
7334 * common/diagnostics.h: New file.
7335
b45a1208
PA
73362017-06-22 Pedro Alves <palves@redhat.com>
7337
7338 * common/agent.h: Add include guards.
7339
e4da2c61
SM
73402017-06-21 Simon Marchi <simon.marchi@ericsson.com>
7341
7342 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
7343 talk about addressable units instead of bytes.
7344
96160d60
SDJ
73452017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
7346
7347 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
7348 of '::const_iterator'.
7349
9a6c7d9c
SDJ
73502017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
7351
7352 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7353 'unittests/environ-selftests.c'.
7354 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
7355 * charset.c (find_charset_names): Declare object 'iconv_env'.
7356 Update code to use 'iconv_env' object. Remove call to
7357 'free_environ'.
7358 * common/environ.c: Include <utility>.
7359 (make_environ): Delete function.
7360 (free_environ): Delete function.
7361 (gdb_environ::clear): New function.
7362 (gdb_environ::operator=): New function.
7363 (gdb_environ::get): Likewise.
7364 (environ_vector): Delete function.
7365 (set_in_environ): Delete function.
7366 (gdb_environ::set): New function.
7367 (unset_in_environ): Delete function.
7368 (gdb_environ::unset): New function.
7369 (gdb_environ::envp): Likewise.
7370 * common/environ.h: Include <vector>.
7371 (struct gdb_environ): Delete; transform into...
7372 (class gdb_environ): ... this class.
7373 (free_environ): Delete prototype.
7374 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
7375 environ_vector): Likewise.
7376 * infcmd.c (run_command_1): Update code to call
7377 'envp' from 'gdb_environ' class.
7378 (environment_info): Update code to call methods from 'gdb_environ'
7379 class.
7380 (unset_environment_command): Likewise.
7381 (path_info): Likewise.
7382 (path_command): Likewise.
7383 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
7384 (inferior::inferior): Initialize 'environment' using the host's
7385 information.
7386 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
7387 Include "environ.h".
7388 (class inferior) <environment>: Change type from 'struct
7389 gdb_environ' to 'gdb_environ'.
7390 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
7391 methods from 'gdb_environ' class.
7392 * solib.c (solib_find_1): Likewise
7393 * unittests/environ-selftests.c: New file.
7394
75c554cf
YQ
73952017-06-20 Yao Qi <yao.qi@linaro.org>
7396
7397 * features/i386/i386-linux.xml: Exchange the order of including
7398 32bit-linux.xml and 32bit-sse.xml.
7399 * features/i386/i386-linux.c: Regenerated.
7400
72ddacb7
YQ
74012017-06-20 Yao Qi <yao.qi@linaro.org>
7402
7403 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
7404 Delete copy ctor and assignment operator.
7405 (tdesc_type): Likewise.
7406 (tdesc_feature): Likewise.
7407 (tdesc_free_reg): Remove.
7408 (tdesc_create_reg): Use new.
7409 (tdesc_free_type): Remove.
7410 (tdesc_create_vector): Use new.
7411 (tdesc_create_union): Likewise.
7412 (tdesc_create_flags): Likewise.
7413 (tdesc_create_enum): Likewise.
7414 (tdesc_free_feature): Delete.
7415 (free_target_description): Use delete.
7416
325c9fd4
JB
74172017-06-19 John Baldwin <jhb@FreeBSD.org>
7418
7419 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
7420 registers.
7421
16b7a719
PA
74222017-06-19 Pedro Alves <palves@redhat.com>
7423
7424 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
7425 after gdb::unlinker.
7426
1c8e01c9
SDJ
74272017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
7428
7429 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
7430 gdb_environ to access an environment variable.
7431
ffce45d2
TP
74322017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
7433
7434 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
7435 gdb_byte*.
7436
1d4fbac9
SM
74372017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7438
7439 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
7440
8465943a
SM
74412017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7442
7443 * configure: Re-generate.
7444 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
7445
3e019bdc
SM
74462017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7447
7448 * configure: Re-generate.
7449 * warning.m4: Pass -Werror to compiler when checking for
7450 supported warning flags.
7451
cf0dd6f0
SM
74522017-06-17 Simon Marchi <simon.marchi@ericsson.com>
7453
7454 * Makefile.in (COMPILE.pre): Add "-x c++".
7455
6f98355c
YQ
74562017-06-16 Alan Hayward <alan.hayward@arm.com>
7457 Pedro Alves <palves@redhat.com>
7458 Yao Qi <yao.qi@linaro.org>
7459
7460 * defs.h (RequireLongest): New.
7461 (extract_integer): Declare function template.
7462 (extract_signed_integer): Remove the declaration, but define it
7463 static inline.
7464 (extract_unsigned_integer): Likewise.
7465 (store_integer): Declare function template.
7466 (store_signed_integer): Remove the declaration, but define it
7467 static inline.
7468 (store_unsigned_integer): Likewise.
7469 * findvar.c (extract_integer): New function template.
7470 (extract_signed_integer): Remove.
7471 (extract_unsigned_integer): Remove.
7472 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
7473 instantiations.
7474 (store_integer): New function template.
7475 (store_signed_integer): Remove.
7476 (store_unsigned_integer): Remove.
7477 (store_integer): Explicit instantiations.
7478 * regcache.c (regcache_raw_read_signed): Update.
7479 (regcache::raw_read): New function.
7480 (regcache::raw_read_signed): Remove.
7481 (regcache::raw_read_unsigned): Remove.
7482 (regcache_raw_read_unsigned): Update.
7483 (regcache_raw_write_unsigned): Update.
7484 (regcache::raw_write_signed): Remove.
7485 (regcache::raw_write): New function.
7486 (regcache_cooked_read_signed): Update.
7487 (regcache::raw_write_unsigned): Remove.
7488 (regcache::cooked_read_signed): Remove.
7489 (regcache_cooked_read_unsigned): Update.
7490 (regcache::cooked_read_unsigned): Remove.
7491 (regcache_cooked_write_signed): Update.
7492 (regcache_cooked_write_unsigned): Update.
7493 * regcache.h (regcache) <raw_read_signed>: Remove.
7494 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
7495 <raw_read, raw_write>: New.
7496 <cooked_read_signed, cooked_write_signed>: Remove.
7497 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
7498 <cooked_read, cooked_write>: New.
7499 * sh64-tdep.c (sh64_pseudo_register_read): Update.
7500 (sh64_pseudo_register_write): Update.
7501
a87dc45a
AK
75022017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
7503
7504 * arc-tdep.c (arc_disassembler_options): New variable.
7505 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
7506 of default_print_insn.
7507 (arc_delayed_print_insn): Set info->section when needed,
7508 use default_print_insn to retrieve a disassembler.
7509
45159d6a
SDJ
75102017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
7511
7512 PR gdb/21574
7513 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
7514 to mention $SHELL and startup-with-shell.
7515
b46c4cf0
MF
75162017-06-14 Max Filippov <jcmvbkbc@gmail.com>
7517
7518 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
7519
6394c606
YQ
75202017-06-14 Yao Qi <yao.qi@linaro.org>
7521
7522 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
7523 default_print_insn instead of print_insn_aarch64.
7524 * arm-tdep.c (gdb_print_insn_arm): Call
7525 default_print_insn instead of print_insn_big_arm
7526 and print_insn_little_arm.
7527 * i386-tdep.c (i386_print_insn): Call default_print_insn
7528 instead of print_insn_i386.
7529 * ia64-tdep.c (ia64_print_insn): Call
7530 default_print_insn instead of print_insn_ia64.
7531 * mips-tdep.c (gdb_print_insn_mips): Call
7532 default_print_insn instead of print_insn_big_mips
7533 and print_insn_little_mips.
7534 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
7535 instead of print_insn_spu.
7536
d5722aa2
PA
75372017-06-14 Pedro Alves <palves@redhat.com>
7538
7539 * ada-lang.c: Include "common/byte-vector.h".
7540 (ada_value_primitive_packed_val): Use gdb::byte_vector.
7541 * charset.c (wchar_iterator::iterate): Resize the vector instead
7542 of reserving it.
7543 * common/byte-vector.h: Include "common/def-vector.h".
7544 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
7545 * cli/cli-dump.c: Include "common/byte-vector.h".
7546 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
7547 * common/byte-vector.h: New file.
7548 * common/def-vector.h: New file.
7549 * common/default-init-alloc.h: New file.
7550 * dwarf2loc.c: Include "common/byte-vector.h".
7551 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
7552 instead of reserving it.
7553 * dwarf2read.c: Include "common/byte-vector.h".
7554 (data_buf::m_vec): Now a gdb::byte_vector.
7555 * gdb_regex.c: Include "common/def-vector.h".
7556 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
7557 * mi/mi-main.c: Include "common/byte-vector.h".
7558 (mi_cmd_data_read_memory): Use gdb::byte_vector.
7559 * printcmd.c: Include "common/byte-vector.h".
7560 (print_scalar_formatted): Use gdb::byte_vector.
7561 * valprint.c: Include "common/byte-vector.h".
7562 (maybe_negate_by_bytes, print_decimal_chars): Use
7563 gdb::byte_vector.
7564
01ec7a27
SM
75652017-06-13 Simon Marchi <simon.marchi@ericsson.com>
7566
7567 * darwin-nat.c: Include "nat/fork-inferior.h".
7568
848d9074
SM
75692017-06-13 Simon Marchi <simon.marchi@ericsson.com>
7570
7571 * configure.nat: Factor out Darwin bits that are not
7572 architecture-specific. Add fork-inferior.o.
7573
3b912944
SM
75742017-06-13 Simon Marchi <simon.marchi@ericsson.com>
7575
7576 * configure.nat: Factor out AIX bits that are not
7577 architecture-specific. Add fork-inferior.o.
7578
55acdf22
AA
75792017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7580
7581 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
7582 (read_pieced_value, write_pieced_value): ...here. Reduce to
7583 wrappers that just call rw_pieced_value.
7584
f65e2044
AA
75852017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7586
7587 * dwarf2loc.c (write_pieced_value): When writing the data for a
7588 memory piece, use write_memory_with_notification instead of
7589 write_memory.
7590
23f945bf
AA
75912017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7592
7593 * valops.c (read_value_memory): Change embedded_offset to
7594 represent a bit offset instead of a byte offset.
7595 * value.h (read_value_memory): Adjust comment.
7596
f236533e
AA
75972017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7598
7599 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
7600 dest_offset_bits and source_offset_bits.
7601 (write_pieced_value): Likewise.
7602
65d84b76
AA
76032017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7604
7605 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
7606 given by DW_OP_bit_piece.
7607 (write_pieced_value): Likewise.
7608
242d31ab
AA
76092017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7610
7611 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
7612 some other preparations to the places where sufficient information
7613 is available.
7614 (write_pieced_value): Likewise.
7615
03c8af18
AA
76162017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7617
7618 * dwarf2loc.c (bits_to_bytes): New function.
7619 (read_pieced_value): Fix offset calculations for register pieces
7620 on big-endian targets.
7621 (write_pieced_value): Likewise.
7622
840989c1
AA
76232017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7624
7625 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
7626 (write_pieced_value): Likewise.
7627
359b19bb
AA
76282017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7629
7630 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
7631 transfer the source value's least significant bits, instead of its
7632 lowest-addressed ones. Rename type_len to max_offset.
7633 (read_pieced_value): Mirror above changes to write_pieced_value as
7634 applicable.
7635
07c9ca3b
AA
76362017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7637
7638 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
7639 truncate full bytes from dest_offset_bits before using it as an
7640 offset into the buffer.
7641
f1cc9874
AA
76422017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7643
7644 * dwarf2loc.c (write_pieced_value): Include transfer size in
7645 byte-wise check.
7646
cdaac320
AA
76472017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7648
7649 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
7650 calculation of this_size.
7651
af547a96
AA
76522017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7653
7654 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
7655 when targeting a bit-field.
7656 (write_pieced_value): Likewise.
7657
ddd7882a
AA
76582017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7659
7660 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
7661 (allocate_piece_closure): Drop addr_size parameter.
7662 (dwarf2_evaluate_loc_desc_full): Adjust call to
7663 allocate_piece_closure.
7664
e9352324
AA
76652017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7666
7667 PR gdb/21226
7668 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
7669 the LSB end, independent of endianness.
7670
d5d1163e
AA
76712017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7672
7673 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
7674 size capping.
7675
032bb6ea
YQ
76762017-06-13 Yao Qi <yao.qi@linaro.org>
7677
7678 * mips-linux-nat.c: Move include features/mips*-linux.c to
7679 mips-linux-tdep.c.
7680 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
7681 to mips-linux-tdep.c.
7682 * mips-linux-tdep.c: Include features/mips*-linux.c
7683 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
7684 functions.
7685 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
7686 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
7687 (tdesc_mips64_dsp_linux): Declare.
7688
f12f6bad
TT
76892017-06-12 Tom Tromey <tom@tromey.com>
7690
7691 * valprint.h (val_print_type_code_int): Remove.
7692 * valprint.c (generic_val_print_int): Always call
7693 val_print_scalar_formatted.
7694 (val_print_type_code_int): Remove.
7695 * printcmd.c (print_scalar_formatted): Handle options->format==0.
7696 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
7697 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
7698 * ada-valprint.c (ada_val_print_num): Use
7699 val_print_scalar_formatted.
7700
d9109c80
TT
77012017-06-12 Tom Tromey <tom@tromey.com>
7702
7703 * printcmd.c (print_scalar_formatted): Unify the two switches.
7704 Don't convert scalars to LONGEST.
7705
4ac0cb1c
TT
77062017-06-12 Tom Tromey <tom@tromey.com>
7707
7708 PR exp/16225:
7709 * valprint.h (print_decimal_chars): Update.
7710 * valprint.c (maybe_negate_by_bytes): New function.
7711 (print_decimal_chars): Add "is_signed" argument.
7712 * printcmd.c (print_scalar_formatted): Update.
7713
30a25466
TT
77142017-06-12 Tom Tromey <tom@tromey.com>
7715
7716 PR exp/16225:
7717 * valprint.h (print_binary_chars, print_hex_chars): Update.
7718 * valprint.c (val_print_type_code_int): Update.
7719 (print_binary_chars): Add "zero_pad" argument.
7720 (emit_octal_digit): New function.
7721 (print_octal_chars): Don't zero-pad.
7722 (print_decimal_chars): Likewise.
7723 (print_hex_chars): Add "zero_pad" argument.
7724 * sh64-tdep.c (sh64_do_fp_register): Update.
7725 * regcache.c (regcache::dump): Update.
7726 * printcmd.c (print_scalar_formatted): Update.
7727 * infcmd.c (default_print_one_register_info): Update.
7728
b3464d03
PA
77292017-06-12 Pedro Alves <palves@redhat.com>
7730 Alan Hayward <alan.hayward@arm.com>
7731
7732 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
7733 (mips_eabi_push_dummy_call): Rename local 'regsize' to
7734 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
7735 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
7736 Assert that abi_regsize bytes fit in 'ref_valbuf'.
7737
4b76cda9
PA
77382017-06-12 Pedro Alves <palves@redhat.com>
7739
7740 * dwarf2read.c (mapped_symtab::data): Now a vector of
7741 symtab_index_entry instead of vector of
7742 std::unique_ptr<symtab_index_entry>. All users adjusted to check
7743 whether an element's name is NULL instead of checking whether the
7744 element itself is NULL.
7745 (find_slot): Change return type. Adjust.
7746 (hash_expand, , add_index_entry, uniquify_cu_indices)
7747 (write_hash_table): Adjust.
7748
e8f8bcb3
PA
77492017-06-12 Pedro Alves <palves@redhat.com>
7750
7751 * dwarf2read.c (recursively_count_psymbols): New function.
7752 (write_psymtabs_to_index): Call it to compute number of psyms and
7753 pass estimate size of psyms_seen to unordered_set's ctor.
7754
70a1152b
PA
77552017-06-12 Pedro Alves <palves@redhat.com>
7756
7757 * dwarf2read.c (write_hash_table): Check if key already exists
7758 before emplacing.
7759
c2f134ac
PA
77602017-06-12 Pedro Alves <palves@redhat.com>
7761
7762 * dwarf2read.c (data_buf::append_space): Rename to...
7763 (data_buf::grow): ... this, and make private. Adjust all callers.
7764 (data_buf::append_uint): New method.
7765 (add_address_entry, write_one_signatured_type)
7766 (write_psymtabs_to_index): Use it.
7767
a81e6d4d
PA
77682017-06-12 Pedro Alves <palves@redhat.com>
7769
7770 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
7771 (file_write (FILE *, const std::vector<Elem>&)): Delete.
7772 (data_buf::file_write): Call ::fwrite directly.
7773
6fd931f2
PA
77742017-06-12 Pedro Alves <palves@redhat.com>
7775
7776 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
7777 std::vector::erase.
7778
bc8f2430
JK
77792017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
7780
7781 Code cleanup: C++ify .gdb_index producer.
7782 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
7783 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
7784 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
7785 (create_strtab, add_string): Remove.
7786 (file_write, data_buf): New.
7787 (struct symtab_index_entry): Use std::vector for cu_indices.
7788 (struct mapped_symtab): Use std::vector for data.
7789 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
7790 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
7791 Remove.
7792 (find_slot): Change return type. Update it to the new data structures.
7793 (hash_expand, add_index_entry): Update it to the new data structures.
7794 (offset_type_compare): Remove.
7795 (uniquify_cu_indices): Update it to the new data structures.
7796 (c_str_view, c_str_view_hasher, vector_hasher): New.
7797 (add_indices_to_cpool): Remove.
7798 (write_hash_table): Update it to the new data structures.
7799 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
7800 (eq_psymtab_cu_index): Remove.
7801 (psym_index_map): New typedef.
7802 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
7803 reference and std::unordered_map for cu_index_htab.
7804 (add_address_entry, add_address_entry_worker, write_address_map)
7805 (write_psymbols): Update it to the new data structures.
7806 (write_obstack): Remove.
7807 (struct signatured_type_index_data): Change types_list to a data_buf
7808 reference and psyms_seen to a std::unordered_set reference.
7809 (write_one_signatured_type, recursively_write_psymbols)
7810 (write_psymtabs_to_index): Update it to the new data structures.
7811
c4dcb155
SM
78122017-06-11 Simon Marchi <simon.marchi@ericsson.com>
7813
7814 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
7815 separate-debug-file commands.
7816 * symfile.h (separate_debug_file_debug): New global.
7817 * symfile.c (separate_debug_file_debug): New global.
7818 (separate_debug_file_exists, find_separate_debug_file): Add
7819 debug output.
7820 (_initialize_symfile): Add "set debug separate-debug-file"
7821 command.
7822 * build-id.c (build_id_to_debug_bfd,
7823 find_separate_debug_file_by_buildid): Add debug output.
7824
6d45d4b4
SM
78252017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
7826
7827 * gdbarch.sh (displaced_step_free_closure): Remove.
7828 * gdbarch.h, gdbarch.c: Re-generate.
7829 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
7830 displaced_step_free_closure.
7831 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
7832 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
7833 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
7834 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
7835 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
7836 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
7837 * arch-utils.h (simple_displaced_step_free_closure): Remove.
7838 * arch-utils.c (simple_displaced_step_free_closure): Remove.
7839 * infrun.c (displaced_step_clear): Call xfree instead of
7840 gdbarch_displaced_step_free_closure.
7841
2f91880f
SDJ
78422017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
7843
7844 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
7845 NULL".
7846
b8b6e72f
AH
78472017-06-08 Alan Hayward <alan.hayward@arm.com>
7848
7849 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
7850 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
7851 (mn10300_push_dummy_call): Likewise.
7852
5369082e
AH
78532017-06-08 Alan Hayward <alan.hayward@arm.com>
7854
7855 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
7856
ff4ca5ac
AH
78572017-06-08 Alan Hayward <alan.hayward@arm.com>
7858
7859 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
7860
aefd8b33
SDJ
78612017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7862
7863 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
7864 able to start inferiors using a shell.
7865 (New remote packets): Announce new packet "QStartupWithShell".
7866 * remote.c: Add PACKET_QStartupWithShell.
7867 (extended_remote_create_inferior): Handle new
7868 PACKET_QStartupWithShell.
7869 (remote_protocol_features) <QStartupWithShell>: New entry for
7870 PACKET_QStartupWithShell.
7871 (_initialize_remote): Call "add_packet_config_cmd" for
7872 QStartupShell.
7873
2090129c
SDJ
78742017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7875 Pedro Alves <palves@redhat.com>
7876
7877 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
7878 and "nat/fork-inferior.h".
7879 * common/common-inferior.h: New file, with contents from
7880 "gdb/inferior.h".
7881 * commom/common-utils.c: Include "common-utils.h".
7882 (stringify_argv): New function.
7883 * common/common-utils.h (stringify_argv): New prototype.
7884 * configure.nat: Add "fork-inferior.o" as a dependency for
7885 "*linux*", "fbsd*" and "nbsd*" hosts.
7886 * corefile.c (get_exec_file): Update comment.
7887 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
7888 instead of "startup_inferior".
7889 (darwin_create_inferior): Call "add_thread_silent" after
7890 "fork_inferior".
7891 * fork-child.c: Cleanup unnecessary includes.
7892 (SHELL_FILE): Move to "common/common-fork-child.c".
7893 (environ): Likewise.
7894 (exec_wrapper): Initialize.
7895 (get_exec_wrapper): New function.
7896 (breakup_args): Move to "common/common-fork-child.c"; rename to
7897 "breakup_args_for_exec".
7898 (escape_bang_in_quoted_argument): Move to
7899 "common/common-fork-child.c".
7900 (saved_ui): New variable.
7901 (prefork_hook): New function.
7902 (postfork_hook): Likewise.
7903 (postfork_child_hook): Likewise.
7904 (gdb_startup_inferior): Likewise.
7905 (fork_inferior): Move to "common/common-fork-child.c". Update
7906 function to support gdbserver.
7907 (startup_inferior): Likewise.
7908 * gdbcore.h (get_exec_file): Remove declaration.
7909 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
7910 instead of "startup_inferior". Call "add_thread_silent" after
7911 "fork_inferior".
7912 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
7913 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
7914 instead of "startup_inferior". Call "add_thread_silent" after
7915 "fork_inferior".
7916 * inferior.h: Include "common-inferior.h".
7917 (trace_start_error): Move to "common/common-utils.h".
7918 (trace_start_error_with_name): Likewise.
7919 (fork_inferior): Move prototype to "nat/fork-inferior.h".
7920 (startup_inferior): Likewise.
7921 (gdb_startup_inferior): New prototype.
7922 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
7923 * nat/fork-inferior.h: New file.
7924 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
7925 instead of "startup_inferior". Call "add_thread_silent" after
7926 "fork_inferior".
7927 * target.h (target_terminal_init): Move prototype to
7928 "target/target.h".
7929 (target_terminal_inferior): Likewise.
7930 (target_terminal_ours): Likewise.
7931 * target/target.h (target_terminal_init): New prototype, moved
7932 from "target.h".
7933 (target_terminal_inferior): Likewise.
7934 (target_terminal_ours): Likewise.
7935 * utils.c (gdb_flush_out_err): New function.
7936
043a4934
SDJ
79372017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7938
7939 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
7940 * common/common-gdbthread.h: New file, with parts from
7941 "gdb/gdbthread.h".
7942 * gdbthread.h: Include "common-gdbthread.h".
7943 (switch_to_thread): Moved to "common/common-gdbthread.h".
7944
15652511
SDJ
79452017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
7946
7947 * Makefile.in (SFILES): Add "common/job-control.c".
7948 (HFILES_NO_SRCDIR): Add "common/job-control.h".
7949 (COMMON_OBS): Add "job-control.o".
7950 * common/job-control.c: New file, with contents from
7951 "gdb/inflow.c".
7952 * common/job-control.h: New file, with contents from "terminal.h".
7953 * fork-child.c: Include "job-control.h".
7954 * inflow.c: Include "job-control.h".
7955 (gdb_setpgid): Move to "common/common-inflow.c".
7956 (_initialize_inflow): Move setting of "job_control" to
7957 "handle_job_control".
7958 * terminal.h (job_control): Moved to "common/common-terminal.h".
7959 (gdb_setpgid): Likewise.
7960 * top.c: Include "job_control.h".
7961 * utils.c: Likewise.
7962 (job_control): Moved to "job-control.c".
7963
2d7cc5c7
PA
79642017-06-07 Pedro Alves <palves@redhat.com>
7965
7966 * Makefile.in (SFILES): Add gdb_regex.c.
7967 (COMMON_OBS): Add gdb_regex.o.
7968 * ada-lang.c (ada_add_standard_exceptions)
7969 (ada_add_exceptions_from_frame, name_matches_regex)
7970 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
7971 parameter type to compiled_regex. Adjust.
7972 (ada_exceptions_list): Use compiled_regex.
7973 * break-catch-throw.c (exception_catchpoint::pattern): Now a
7974 std::unique_ptr<compiled_regex>.
7975 (exception_catchpoint::~exception_catchpoint): Remove regfree
7976 call.
7977 (check_status_exception_catchpoint): Adjust to use compiled_regex.
7978 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
7979 * breakpoint.c (solib_catchpoint::compiled): Now a
7980 std::unique_ptr<compiled_regex>.
7981 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
7982 (check_status_catch_solib): Adjust to use compiled_regex.
7983 (add_solib_catchpoint): Adjust to use compiled_regex.
7984 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
7985 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
7986 compiled_regex reference. Adjust to use it.
7987 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
7988 declaration. Include "gdb_regex.h".
7989 (apropos_cmd): Change regex parameter to compiled_regex reference.
7990 * gdb_regex.c: New file.
7991 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
7992 declarations.
7993 (class compiled_regex): New.
7994 * linux-tdep.c: Include "common/gdb_optional.h".
7995 (struct mapping_regexes): New, factored out from
7996 mapping_is_anonymous_p, and adjusted to use compiled_regex.
7997 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
7998 gdb::optional and remove cleanups. Adjust to compiled_regex.
7999 * probe.c: Include "common/gdb_optional.h".
8000 (collect_probes): Use compiled_regex and gdb::optional and remove
8001 cleanups.
8002 * skip.c: Include "common/gdb_optional.h".
8003 (skiplist_entry::compiled_function_regexp): Now a
8004 gdb::optional<compiled_regex>.
8005 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
8006 (free_skiplist_entry): Remove regfree call.
8007 (compile_skip_regexp, skip_rfunction_p): Adjust to use
8008 compiled_regex and gdb::optional.
8009 * symtab.c: Include "common/gdb_optional.h".
8010 (search_symbols): Use compiled_regex and gdb::optional.
8011 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
8012 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
8013 to gdb_regex.c.
8014
50d6adef
AH
80152017-06-07 Alan Hayward <alan.hayward@arm.com>
8016
8017 * regcache.c (regcache::save): Avoid buffer use.
8018 (regcache::dump): Likewise.
8019
4a8a33c8
AH
80202017-06-07 Alan Hayward <alan.hayward@arm.com>
8021
8022 * sh-tdep.c (sh_pseudo_register_read): Remove
8023 MAX_REGISTER_SIZE.
8024 (sh_pseudo_register_write): Likewise.
8025 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
8026 (sh64_pseudo_register_write): Likewise
8027
d1be909e
AH
80282017-06-07 Alan Hayward <alan.hayward@arm.com>
8029
8030 * aarch64-tdep.c (aarch64_store_return_value): Use
8031 V_REGISTER_SIZE.
8032 (aarch64_pseudo_read_value): Likewise.
8033 (aarch64_pseudo_write): Likewise.
8034
f4a65042
YQ
80352017-06-06 Yao Qi <yao.qi@linaro.org>
8036
8037 * regformats/regdef.h (set_register_cache): Remove the
8038 declaration.
8039
9f7fb0aa
AH
80402017-06-06 Alan Hayward <alan.hayward@arm.com>
8041
8042 * frame.c (frame_unwind_register_signed): Use
8043 frame_unwind_register_value.
8044
e1e01040
PA
80452017-06-06 Pedro Alves <palves@redhat.com>
8046
8047 PR breakpoints/21553
8048 * breakpoint.c (create_breakpoints_sal_default)
8049 (init_breakpoint_sal, create_breakpoint_sal): Use
8050 gdb::unique_xmalloc_ptr for string parameters.
8051 (create_breakpoint): Constify 'extra_string' and 'cond_string'
8052 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
8053 (base_breakpoint_create_breakpoints_sal)
8054 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
8055 (strace_marker_create_breakpoints_sal)
8056 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
8057 string parameters.
8058 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
8059 gdb::unique_xmalloc_ptr for string parameters.
8060 (create_breakpoint): Constify 'extra_string' and 'cond_string'
8061 parameters.
8062
fbe654c8
AH
80632017-06-06 Alan Hayward <alan.hayward@arm.com>
8064
8065 * alpha-tdep.c (alpha_register_to_value): Use
8066 get_frame_register_value.
8067 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
8068
ae0d01d6
AH
80692017-06-06 Alan Hayward <alan.hayward@arm.com>
8070
8071 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
8072 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
8073 (ia64_value_to_register): Likewise.
8074 (ia64_extract_return_value): Likewise.
8075 (ia64_store_return_value): Likewise.
8076 (ia64_push_dummy_call): Likewise.
8077
49cf576c
JB
80782017-06-04 Joel Brobecker <brobecker@adacore.com>
8079
8080 GDB 8.0 released.
8081
26b6a6ab
SM
80822017-06-03 Simon Marchi <simon.marchi@ericsson.com>
8083
8084 * x86-linux-nat.c (struct arch_lwp_info): Remove.
8085
22827c51
SM
80862017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
8087
8088 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
8089 parameter.
8090 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
8091
0e05cf3a
SM
80922017-06-02 Simon Marchi <simon.marchi@ericsson.com>
8093
8094 * event-loop.c (poll_timers): Unallocate timer using delete
8095 instead of xfree.
8096
c1fc2657
SM
80972017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
8098
8099 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
8100 (struct breakpoint) <~breakpoint>: New.
8101 (struct watchpoint): Inherit from breakpoint.
8102 <~watchpoint>: New.
8103 <base>: Remove.
8104 (struct tracepoint): Inherit from breakpoint.
8105 <base>: Remove.
8106 * breakpoint.c (longjmp_breakpoint_ops): Remove.
8107 (struct longjmp_breakpoint): Inherit from breakpoint.
8108 <~longjmp_breakpoint>: New.
8109 <base>: Remove.
8110 (new_breakpoint_from_type): Remove casts.
8111 (watchpoint_in_thread_scope): Remove reference to base field.
8112 (watchpoint_del_at_next_stop): Likewise.
8113 (update_watchpoint): Likewise.
8114 (watchpoint_check): Likewise.
8115 (bpstat_check_watchpoint): Likewise.
8116 (set_longjmp_breakpoint): Likewise.
8117 (struct fork_catchpoint): Inherit from breakpoint.
8118 <base>: Remove.
8119 (struct solib_catchpoint): Inherit from breakpoint.
8120 <~solib_catchpoint>: New.
8121 <base>: Remove.
8122 (dtor_catch_solib): Change to ...
8123 (solib_catchpoint::~solib_catchpoint): ... this.
8124 (breakpoint_hit_catch_solib): Remove reference to base field.
8125 (add_solib_catchpoint): Likewise.
8126 (create_fork_vfork_event_catchpoint): Likewise.
8127 (struct exec_catchpoint): Inherit from breakpoint.
8128 <~exec_catchpoint>: New.
8129 <base>: Remove.
8130 (dtor_catch_exec): Change to ...
8131 (exec_catchpoint::~exec_catchpoint): ... this.
8132 (dtor_watchpoint): Change to ...
8133 (watchpoint::~watchpoint): ... this.
8134 (watch_command_1): Remove reference to base field.
8135 (catch_exec_command_1): Likewise.
8136 (base_breakpoint_dtor): Change to ...
8137 (breakpoint::~breakpoint): ... this.
8138 (base_breakpoint_ops): Remove dtor field value.
8139 (longjmp_bkpt_dtor): Change to ...
8140 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
8141 (strace_marker_create_breakpoints_sal): Remove reference to base
8142 field.
8143 (delete_breakpoint): Don't manually call breakpoint destructor.
8144 (create_tracepoint_from_upload): Remove reference to base field.
8145 (trace_pass_set_count): Likewise.
8146 (initialize_breakpoint_ops): Don't initialize
8147 momentary_breakpoint_ops, don't set dtors.
8148 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
8149 <~ada_catchpoint>: New.
8150 <base>: Remove.
8151 (create_excep_cond_exprs): Remove reference to base field.
8152 (dtor_exception): Change to ...
8153 (ada_catchpoint::~ada_catchpoint): ... this.
8154 (dtor_catch_exception): Remove.
8155 (dtor_catch_exception_unhandled): Remove.
8156 (dtor_catch_assert): Remove.
8157 (create_ada_exception_catchpoint): Remove reference to base
8158 field.
8159 (initialize_ada_catchpoint_ops): Don't set dtors.
8160 * break-catch-sig.c (struct signal_catchpoint): Inherit from
8161 breakpoint.
8162 <~signal_catchpoint>: New.
8163 <base>: Remove.
8164 (signal_catchpoint_dtor): Change to ...
8165 (signal_catchpoint::~signal_catchpoint): ... this.
8166 (create_signal_catchpoint): Remove reference to base field.
8167 (initialize_signal_catchpoint_ops): Don't set dtor.
8168 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
8169 from breakpoint.
8170 <~syscall_catchpoint>: New.
8171 <base>: Remove.
8172 (dtor_catch_syscall): Change to ...
8173 (syscall_catchpoint::~syscall_catchpoint): ... this.
8174 (create_syscall_event_catchpoint): Remove reference to base
8175 field.
8176 (initialize_syscall_catchpoint_ops): Don't set dtor.
8177 * break-catch-throw.c (struct exception_catchpoint): Inherit
8178 from breakpoint.
8179 <~exception_catchpoint>: New.
8180 <base>: Remove.
8181 (dtor_exception_catchpoint): Change to ...
8182 (exception_catchpoint::~exception_catchpoint): ... this.
8183 (handle_gnu_v3_exceptions): Remove reference to base field.
8184 (initialize_throw_catchpoint_ops): Don't set dtor.
8185 * ctf.c (ctf_get_traceframe_address): Remove reference to base
8186 field.
8187 * remote.c (remote_get_tracepoint_status): Likewise.
8188 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
8189 * tracefile.c (tracefile_fetch_registers): Likewise.
8190 * tracepoint.c (actions_command): Likewise.
8191 (validate_actionline): Likewise.
8192 (tfind_1): Likewise.
8193 (get_traceframe_location): Likewise.
8194 (find_matching_tracepoint_location): Likewise.
8195 (parse_tracepoint_status): Likewise.
8196 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
8197
3b0871f4
SM
81982017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
8199
8200 * breakpoint.c (struct longjmp_breakpoint): New struct.
8201 (is_tracepoint_type): Change return type to bool.
8202 (is_longjmp_type): New function.
8203 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
8204 (set_raw_breakpoint_without_location): Use
8205 new_breakpoint_from_type.
8206 (set_raw_breakpoint): Likewise.
8207
a5e364af
SM
82082017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
8209
8210 * breakpoint.c (new_breakpoint_from_type): New function.
8211 (create_breakpoint_sal): Use new_breakpoint_from_type and
8212 unique_ptr.
8213 (create_breakpoint): Likewise.
8214
ae3b3f34
SM
82152017-05-31 Simon Marchi <simon.marchi@ericsson.com>
8216
8217 * memattr.c (mem_info_command): Rename to ...
8218 (info_mem_command): ... this.
8219 (mem_enable_command): Rename to ...
8220 (enable_mem_command): ... this.
8221 (mem_disable_command): Rename to ...
8222 (disable_mem_command): ... this.
8223 (mem_delete_command): Rename to ...
8224 (delete_mem_command): ... this.
8225 (_initialize_mem): Adjust function names.
8226
13ace077
MM
82272017-05-31 Markus Metzger <markus.t.metzger@intel.com>
8228
8229 * btrace.c (handle_pt_insn_events): New.
8230 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
8231 STATUS. Split into this and ...
8232 (handle_pt_insn_event_flags): ... this.
8233
c56ccc05
MM
82342017-05-31 Markus Metzger <markus.t.metzger@intel.com>
8235
8236 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
8237 and struct pt_insn.resynced.
8238 * configure: Regenerated.
8239 * config.in: Regenerated.
8240
08c3f6d2
TW
82412017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8242
8243 * btrace.c (ftrace_find_call_by_number): New function.
8244 (ftrace_new_function): Store objects, not pointers.
8245 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
8246 ftrace_new_gap, ftrace_update_function,
8247 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
8248 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
8249 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
8250 btrace_ends_with_single_insn, btrace_call_get): Account for
8251 btrace_thread_info::functions now storing objects.
8252 * btrace.h (struct btrace_thread_info): Add constructor.
8253 (struct btrace_thread_info) <functions>: Make std::vector.
8254 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
8255 Initialize with default values.
8256 * record-btrace.c (record_btrace_frame_sniffer): Account for
8257 btrace_thread_info::functions now storing objects.
8258
8ffd39f2
TW
82592017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8260
8261 * btrace.c: Remove typedef bfun_s.
8262 (ftrace_new_gap): Directly add gaps to the list of gaps.
8263 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
8264 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
8265 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
8266 instead of gdb VEC.
8267
4aeb0dfc
TW
82682017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8269
8270 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
8271 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
8272 with btrace_thread_info::next_segment and
8273 btrace_thread_info::prev_segment.
8274 * btrace.h: Remove struct btrace_func_link.
8275 (struct btrace_function): Replace pair of function segment pointers
8276 with pair of indices.
8277 * python/py-record-btrace.c (btpy_call_prev_sibling,
8278 btpy_call_next_sibling): Replace references to
8279 btrace_thread_info::segment with btrace_thread_info::next_segment and
8280 btrace_thread_info::prev_segment.
8281 * record-btrace.c (record_btrace_frame_this_id): Use
8282 btrace_find_call_by_number.
8283
eb8f2b9c
TW
82842017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8285
8286 * btrace.c (ftrace_new_function, ftrace_fixup_level,
8287 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
8288 btrace_insn_next, btrace_insn_prev): Remove references to
8289 btrace_thread_info::flow.
8290 * btrace.h (struct btrace_function): Remove FLOW.
8291
42bfe59e
TW
82922017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8293
8294 * btrace.c (ftrace_find_call_by_number): New function.
8295 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
8296 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
8297 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
8298 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
8299 index.
8300 * btrace.h (struct btrace_function): Turn UP into an index.
8301 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
8302 as an index.
8303 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
8304 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
8305 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
8306
b54b03bd
TW
83072017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8308
8309 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
8310 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
8311 ftrace_update_function, ftrace_compute_global_level_offset,
8312 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
8313 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
8314 btrace_insn_end, btrace_is_empty): Remove references to
8315 btrace_thread_info::begin and btrace_thread_info::end.
8316 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
8317 (struct btrace_thread_info) <functions>: Adjust comment.
8318 * record-btrace.c (record_btrace_start_replaying): Remove reference to
8319 btrace_thread_info::begin.
8320
8286623c
TW
83212017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8322
8323 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
8324 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
8325 ftrace_update_function): Remove arguments that implicitly were always
8326 BTINFO->END.
8327 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
8328 Don't pass BTINFO->END.
8329
a0f1b963
TW
83302017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8331
8332 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
8333 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
8334 btrace_find_insn_by_number): Replace function segment pointer with
8335 index.
8336 (btrace_insn_cmp): Simplify.
8337 * btrace.h: (struct btrace_insn_iterator) Rename index to
8338 insn_index. Replace function segment pointer with index into function
8339 segment vector.
8340 * record-btrace.c (record_btrace_call_history): Replace function
8341 segment pointer use with index.
8342 (record_btrace_frame_sniffer): Retrieve function call segment through
8343 vector.
8344 (record_btrace_set_replay): Remove defunc't safety check.
8345
f158f208
TW
83462017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8347
8348 * btrace.c (btrace_ends_with_single_insn): New function.
8349 (btrace_call_get, btrace_call_number, btrace_call_begin,
8350 btrace_call_end, btrace_call_next, btrace_call_prev,
8351 btrace_find_call_by_number): Use index into call segment vector
8352 instead of pointer.
8353 (btrace_call_cmp): Simplify.
8354 * btrace.h (struct btrace_call_iterator): Replace function call segment
8355 pointer with index into vector.
8356 * record-btrace.c (record_btrace_call_history): Use index instead of
8357 pointer.
8358
521103fd
TW
83592017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8360
8361 * btrace.c (btrace_insn_begin, btrace_insn_end,
8362 btrace_find_insn_by_number): Add btinfo to iterator.
8363 * btrace.h (struct btrace_insn_iterator): Add btinfo.
8364
17b89b34
TW
83652017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8366
8367 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
8368 and save pointers directly.
8369 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
8370 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
8371 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
8372 changed signature of functions.
8373 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
8374 (btrace_fetch): Remove code that adds btrace_function pointers to
8375 vector of btrace_functions.
8376 (btrace_clear): Simplify freeing vector of btrace_functions.
8377
2b51eddc
TW
83782017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
8379
8380 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
8381 Replace VEC_* with std::vector functions.
8382 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
8383 (struct btrace_thread_info)<functions>: Change type to std::vector.
8384
db6be0d5
SM
83852017-05-30 Simon Marchi <simon.marchi@ericsson.com>
8386
8387 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
8388 "Removed targets and native configurations" up. Merge duplicate
8389 "New commands" sub-sections. Add "New options" sub-sections.
8390
b057297a
AH
83912017-05-26 Alan Hayward <alan.hayward@arm.com>
8392
8393 * defs.h (copy_integer_to_size): New declaration.
8394 * findvar.c (copy_integer_to_size): New function.
8395 (do_cint_test): New selftest function.
8396 (copy_integer_to_size_test): Likewise.
8397 (_initialize_findvar): Likewise.
8398 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
8399 (mips_fbsd_collect_reg): Use raw_collect_integer.
8400 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
8401 (mips64_fill_gregset): Use raw_collect_integer
8402 (mips64_fill_fpregset): Use raw_supply_integer.
8403 * regcache.c (regcache::raw_supply_integer): New function.
8404 (regcache::raw_collect_integer): Likewise.
8405 * regcache.h: (regcache::raw_supply_integer): New declaration.
8406 (regcache::raw_collect_integer): Likewise.
8407
b77b02a5
YQ
84082017-05-24 Yao Qi <yao.qi@linaro.org>
8409
8410 * Makefile.in (SFILES): Add gdbarch-selftests.c.
8411 (COMMON_OBS): Add gdbarch-selftests.o.
8412 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
8413 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
8414 * gdbarch-selftests.c: New file.
8415 * regcache.h (regcache) <~regcache>: Mark it virtual if
8416 GDB_SELF_TEST.
8417 <raw_write>: Likewise.
8418
e521e87e
YQ
84192017-05-24 Yao Qi <yao.qi@linaro.org>
8420
8421 * regcache.c (current_regcache): Change it to
8422 regcache::current_regcache.
8423 (regcache_observer_target_changed): Update.
8424 (regcache_thread_ptid_changed): Make it a regcache static
8425 method.
8426 (regcache_thread_ptid_changed): Update.
8427 (class regcache_access): New.
8428 (current_regcache_test): Update.
8429 (_initialize_regcache): Update.
8430 * regcache.h: Include forward_list.
8431 (regcache): Declare regcache_thread_ptid_changed and declare
8432 registers_changed_ptid as friend.
8433
d8e07dda
YQ
84342017-05-24 Yao Qi <yao.qi@linaro.org>
8435
8436 * i387-tdep.c (i387_register_to_value): Use register_size
8437 instead of TYPE_LENGTH.
8438 * m68k-tdep.c (m68k_register_to_value): Likewise.
8439
8c8f9122
YQ
84402017-05-24 Yao Qi <yao.qi@linaro.org>
8441
8442 * i387-tdep.c (i387_convert_register_p): Return false if type
8443 code isn't TYPE_CODE_FLT.
8444
68fce50f
YQ
84452017-05-24 Yao Qi <yao.qi@linaro.org>
8446
8447 * alpha-tdep.c (alpha_convert_register_p): Return true if type
8448 length is 4.
8449 (alpha_register_to_value): Remove type length check.
8450 (alpha_value_to_register): Likewise.
8451
88954b49
YQ
84522017-05-24 Yao Qi <yao.qi@linaro.org>
8453
8454 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
8455 TYPE_CODE_FLT.
8456
e3ec9b69
YQ
84572017-05-24 Yao Qi <yao.qi@linaro.org>
8458
8459 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
8460 TYPE_CODE_FLT or not.
8461
cdd238da
YQ
84622017-05-24 Yao Qi <yao.qi@linaro.org>
8463
8464 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
8465 * avr-tdep.c (avr_gdbarch_init): Likewise.
8466 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
8467 * cris-tdep.c (cris_gdbarch_init): Likewise.
8468 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
8469 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
8470 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
8471 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
8472 * mep-tdep.c (mep_gdbarch_init): Likewise.
8473 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
8474 * mips-tdep.c (mips_gdbarch_init): Likewise.
8475 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
8476 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
8477 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
8478 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
8479 * v850-tdep.c (v850_gdbarch_init): Likewise.
8480
7a3929c4
YQ
84812017-05-24 Yao Qi <yao.qi@linaro.org>
8482
8483 * selftest-arch.c (tests_with_arch): Call registers_changed
8484 and reinit_frame_cache.
8485 * selftest.c (run_self_tests): Likewise.
8486
f4985dba
YQ
84872017-05-24 Yao Qi <yao.qi@linaro.org>
8488
8489 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
8490 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
8491
ab20fa4a
YQ
84922017-05-24 Yao Qi <yao.qi@linaro.org>
8493
8494 * rl78-tdep.c (rl78_gdbarch_init): Don't call
8495 set_gdbarch_print_insn.
8496
f532ab94
YQ
84972017-05-24 Yao Qi <yao.qi@linaro.org>
8498
8499 * h8300-tdep.c (h8300_gdbarch_init): Don't call
8500 set_gdbarch_print_insn.
8501
39503f82
YQ
85022017-05-24 Yao Qi <yao.qi@linaro.org>
8503
8504 * alpha-tdep.c (alpha_gdbarch_init): Don't call
8505 set_gdbarch_print_insn.
8506 * arc-tdep.c (arc_gdbarch_init): Likewise.
8507 * arch-utils.c: include dis-asm.h.
8508 (default_print_insn): New function.
8509 * arch-utils.h (default_print_insn): Declare.
8510 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
8511 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
8512 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
8513 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
8514 * frv-tdep.c (frv_gdbarch_init): Likewise.
8515 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
8516 * gdbarch.sh (print_insn): Use default_print_insn.
8517 * gdbarch.c: Regenerated.
8518 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
8519 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
8520 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
8521 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
8522 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
8523 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
8524 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
8525 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
8526 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
8527 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
8528 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
8529 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
8530 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
8531 * mt-tdep.c (mt_gdbarch_init): Likewise.
8532 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
8533 * nios2-tdep.c (nios2_print_insn): Remove.
8534 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
8535 * rx-tdep.c (rx_gdbarch_init): Likewise.
8536 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
8537 * score-tdep.c (score_print_insn): Remove.
8538 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
8539 * sh-tdep.c (sh_gdbarch_init): Likewise.
8540 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
8541 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
8542 * tic6x-tdep.c (tic6x_print_insn): Remove.
8543 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
8544 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
8545 * v850-tdep.c (v850_gdbarch_init): Likewise.
8546 * vax-tdep.c (vax_gdbarch_init): Likewise.
8547 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
8548 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
8549
f7241d4f
JB
85502017-05-23 John Baldwin <jhb@FreeBSD.org>
8551
8552 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
8553 (MIPS_FP0_REGNUM): Remove.
8554 (MIPS_FSR_REGNUM): Remove.
8555 (mips_fbsd_supply_fpregs): Use mips_regnum.
8556 (mips_fbsd_supply_gregs): Likewise.
8557 (mips_fbsd_collect_fpregs): Likewise.
8558 (mips_fbsd_collect_gregs): Likewise.
8559
d489d81d
JB
85602017-05-23 John Baldwin <jhb@FreeBSD.org>
8561
8562 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
8563 (getpfpregs_supplies): New function.
8564 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
8565 getfpregs_supplies.
8566 (mips_fbsd_store_inferior_registers): Likewise.
8567
e11b3cdc
PA
85682017-05-22 Pedro Alves <palves@redhat.com>
8569
8570 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
8571 maintainer.
8572
0f068fb5
AH
85732017-05-22 Alan Hayward <alan.hayward@arm.com>
8574
8575 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
8576 (store_register): Likewise.
8577 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
8578 (get_decimal_float_return_value): Likewise.
8579 (do_ppc_sysv_return_value): Likewise.
8580 (ppc64_sysv_abi_push_integer): Likewise.
8581 (ppc64_sysv_abi_push_freg): Likewise.
8582 (ppc64_sysv_abi_return_value_base): Likewise.
8583 (ppc64_sysv_abi_return_value): Likewise.
8584 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
8585 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
8586 * rs6000-nat.c: Likewise.
8587 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
8588 (rs6000_value_to_register): Likewise.
8589 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
8590
e6cf65f2
TT
85912017-05-21 Tom Tromey <tom@tromey.com>
8592
8593 PR rust/21466:
8594 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
8595 arrays as "[T]", not "[T; ]".
8596
43cc5389
TT
85972017-05-19 Tom Tromey <tom@tromey.com>
8598
8599 PR rust/21484:
8600 * rust-lang.c (exp_descriptor_rust): New function.
8601 (rust_language_defn): Use it.
8602 * p-lang.c (pascal_language_defn): Update.
8603 * opencl-lang.c (opencl_language_defn): Update.
8604 * objc-lang.c (objc_language_defn): Update.
8605 * m2-lang.c (m2_language_defn): Update.
8606 * language.h (struct language_defn)
8607 <la_watch_location_expression>: New member.
8608 * language.c (unknown_language_defn, auto_language_defn)
8609 (local_language_defn): Update.
8610 * go-lang.c (go_language_defn): Update.
8611 * f-lang.c (f_language_defn): Update.
8612 * d-lang.c (d_language_defn): Update.
8613 * c-lang.h (c_watch_location_expression): Declare.
8614 * c-lang.c (c_watch_location_expression): New function.
8615 (c_language_defn, cplus_language_defn, asm_language_defn)
8616 (minimal_language_defn): Use it.
8617 * breakpoint.c (watch_command_1): Call
8618 la_watch_location_expression.
8619 * ada-lang.c (ada_language_defn): Update.
8620
7a6e7fcc
RO
86212017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
8622
6e7e1744
RO
8623 PR tui/21482
8624 * gdb_curses.h (NOMACROS): Define.
8625 (NCURSES_NOMACROS): Define.
8626
86272017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
8628
8629 PR tui/21482
7a6e7fcc
RO
8630 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
8631 arg to char *.
8632 * tui/tui-wingeneral.c (box_win): Likewise.
8633 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
8634 (tui_show_source_line): Likewise.
8635 (tui_show_exec_info_content): Likewise.
8636
1933fd8e
VM
86372017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
8638
8639 * sparc-tdep.c (sparc_structure_return_p)
8640 (sparc_arg_on_registers_p): New functions.
8641 (sparc32_store_arguments): Use them.
8642 * sparc64-tdep.c (sparc64_16_byte_align_p)
8643 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
8644 Handle TYPE_CODE_ARRAY.
8645
21873064
YQ
86462017-05-17 Yao Qi <yao.qi@linaro.org>
8647
8648 * cli/cli-decode.c (add_alias_cmd): New function.
8649 * command.h (add_alias_cmd): Declare.
8650 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
8651 instead call add_alias_cmd.
8652
2b351b19
PA
86532017-05-17 Pedro Alves <palves@redhat.com>
8654
8655 * Makefile.in (nat_extra_makefile_frag): Rename to ...
8656 (nat_makefile_frag): ... this. All references updated.
8657 * configure.ac: Likewise.
8658 * configure.nat: Likewise. Enhance comments.
8659 * configure: Regenerate.
8660
5f2ad7a3
RO
86612017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
8662
8663 * procfs.c (procfs_create_inferior): Change prototype to match
8664 definition.
8665
adf3dde5
EZ
86662017-05-13 Eli Zaretskii <eliz@gnu.org>
8667
8668 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
8669 C++ compiler warning.
8670
6830f270
TT
86712017-05-12 Tom Tromey <tom@tromey.com>
8672
8673 PR rust/21483:
8674 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
8675 recurse, just call value_struct_elt directly.
8676
68f2f2e3
TT
86772017-05-12 Tom Tromey <tom@tromey.com>
8678
8679 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
8680 OP_RUST_ARRAY>: Fix.
8681
256afbc2
TT
86822017-05-12 Tom Tromey <tom@tromey.com>
8683
8684 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
8685
94bb8dfe
YQ
86862017-05-09 Yao Qi <yao.qi@linaro.org>
8687
8688 * regcache.c: Include <forward_list>.
8689 (struct regcache_list): Remove.
8690 (current_regcache): Update.
8691 (get_thread_arch_aspace_regcache): Update for std::forward_list.
8692 (regcache_thread_ptid_changed): Likewise.
8693 (registers_changed_ptid): Likewise.
8694 (current_regcache_size): Likewise.
8695
8248946c
YQ
86962017-05-09 Yao Qi <yao.qi@linaro.org>
8697
8698 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
8699 (current_regcache_size): New function.
8700 (current_regcache_test): New function.
8701 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
8702
313c5961
AH
87032017-05-08 Alan Hayward <alan.hayward@arm.com>
8704
8705 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
8706 (print_gp_register_row): Use get_frame_register_value.
8707
27bfc1d1
AH
87082017-05-08 Alan Hayward <alan.hayward@arm.com>
8709
8710 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
8711 (mips_supply_fpregset): Likewise.
8712 (mips64_supply_gregset): Likewise.
8713
146e6c5c
AH
87142017-05-08 Alan Hayward <alan.hayward@arm.com>
8715
8716 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
8717 regcache->raw_supply_zeroed.
8718
e50f25ec
SDJ
87192017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
8720
8721 * configure.nat: Rearrange 'case' statements to match
8722 host before cpu.
8723
21ea5acd
SDJ
87242017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
8725
8726 * Makefile.in: Remove "@host_makefile_frag@". Add variables
8727 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
8728 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
8729 "@nat_extra_makefile_frag@".
8730 (Makefile): Remove dependency on "@frags@".
8731 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
8732 (data-directory/Makefile): Likewise.
8733 * config/aarch64/linux.mh: Deleted; moved contents to
8734 "gdb/configure.nat".
8735 * config/alpha/alpha-linux.mh: Likewise.
8736 * config/alpha/nbsd.mh: Likewise.
8737 * config/arm/linux.mh: Likewise.
8738 * config/arm/nbsdelf.mh: Likewise.
8739 * config/i386/cygwin.mh: Likewise.
8740 * config/i386/cygwin64.mh: Likewise.
8741 * config/i386/darwin.mh: Likewise.
8742 * config/i386/fbsd.mh: Likewise.
8743 * config/i386/fbsd64.mh: Likewise.
8744 * config/i386/go32.mh: Likewise.
8745 * config/i386/i386gnu.mh: Likewise.
8746 * config/i386/i386sol2.mh: Likewise.
8747 * config/i386/linux.mh: Likewise.
8748 * config/i386/linux64.mh: Likewise.
8749 * config/i386/mingw.mh: Likewise.
8750 * config/i386/mingw64.mh: Likewise.
8751 * config/i386/nbsd64.mh: Likewise.
8752 * config/i386/nbsdelf.mh: Likewise.
8753 * config/i386/nto.mh: Likewise.
8754 * config/i386/obsd.mh: Likewise.
8755 * config/i386/obsd64.mh: Likewise.
8756 * config/i386/sol2-64.mh: Likewise.
8757 * config/ia64/linux.mh: Likewise.
8758 * config/m32r/linux.mh: Likewise.
8759 * config/m68k/linux.mh: Likewise.
8760 * config/m68k/nbsdelf.mh: Likewise.
8761 * config/m68k/obsd.mh: Likewise.
8762 * config/m88k/obsd.mh: Likewise.
8763 * config/mips/fbsd.mh: Likewise.
8764 * config/mips/linux.mh: Likewise.
8765 * config/mips/nbsd.mh: Likewise.
8766 * config/mips/obsd64.mh: Likewise.
8767 * config/pa/linux.mh: Likewise.
8768 * config/pa/nbsd.mh: Likewise.
8769 * config/pa/obsd.mh: Likewise.
8770 * config/powerpc/aix.mh: Likewise.
8771 * config/powerpc/fbsd.mh: Likewise.
8772 * config/powerpc/linux.mh: Likewise.
8773 * config/powerpc/nbsd.mh: Likewise.
8774 * config/powerpc/obsd.mh: Likewise.
8775 * config/powerpc/ppc64-linux.mh: Likewise.
8776 * config/powerpc/spu-linux.mh: Likewise.
8777 * config/s390/linux.mh: Likewise.
8778 * config/sh/nbsd.mh: Likewise.
8779 * config/sparc/fbsd.mh: Likewise.
8780 * config/sparc/linux.mh: Likewise.
8781 * config/sparc/linux64.mh: Likewise.
8782 * config/sparc/nbsd64.mh: Likewise.
8783 * config/sparc/nbsdelf.mh: Likewise.
8784 * config/sparc/obsd64.mh: Likewise.
8785 * config/sparc/sol2.mh: Likewise.
8786 * config/tilegx/linux.mh: Likewise.
8787 * config/vax/nbsdelf.mh: Likewise.
8788 * config/vax/obsd.mh: Likewise.
8789 * config/xtensa/linux.mh: Likewise.
8790 * config/i386/i386gnu.mn: New file, with excerpts from
8791 "config/i386/i386gnu.mh".
8792 * configure: Regenerate.
8793 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
8794 *.mh files under "gdb/config".
8795 * configure.nat: New file, with contents from the
8796 "gdb/config/*/*.mh" files.
8797
7ed1acaf
TW
87982017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
8799
8800 * btrace.c (btrace_clear): Free insn vector.
8801
e13cb306
PA
88022017-05-05 Pedro Alves <palves@redhat.com>
8803
8804 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
8805 * configure: Regenerate.
8806
5ed8105e
PA
88072017-05-04 Pedro Alves <palves@redhat.com>
8808
8809 * Makefile.in (SFILES): Add progspace-and-thread.c.
8810 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
8811 (COMMON_OBS): Add progspace-and-thread.o.
8812 * breakpoint.c: Include "progspace-and-thread.h".
8813 (update_inserted_breakpoint_locations)
8814 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
8815 Use scoped_restore_current_pspace_and_thread.
8816 (create_std_terminate_master_breakpoint): Use
8817 scoped_restore_current_program_space.
8818 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
8819 (print_breakpoint_location): Use
8820 scoped_restore_current_program_space.
8821 (bp_loc_is_permanent): Use
8822 scoped_restore_current_pspace_and_thread.
8823 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
8824 (download_tracepoint_locations): Use
8825 scoped_restore_current_pspace_and_thread.
8826 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
8827 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
8828 (enum step_over_calls_kind): Moved from inferior.h.
8829 (class scoped_restore_current_thread): New class.
8830 * gdbthread.h (make_cleanup_restore_current_thread): Delete
8831 declaration.
8832 (scoped_restore_current_thread): New class.
8833 * infcmd.c: Include "common/gdb_optional.h".
8834 (continue_1, proceed_after_attach): Use
8835 scoped_restore_current_thread.
8836 (notice_new_inferior): Use scoped_restore_current_thread.
8837 * inferior.c: Include "progspace-and-thread.h".
8838 (restore_inferior, save_current_inferior): Delete.
8839 (add_inferior_command, clone_inferior_command): Use
8840 scoped_restore_current_pspace_and_thread.
8841 * inferior.h (scoped_restore_current_inferior): New class.
8842 * infrun.c: Include "progspace-and-thread.h" and
8843 "common/gdb_optional.h".
8844 (follow_fork_inferior): Use
8845 scoped_restore_current_pspace_and_thread.
8846 (scoped_restore_exited_inferior): New class.
8847 (handle_vfork_child_exec_or_exit): Use
8848 scoped_restore_exited_inferior,
8849 scoped_restore_current_pspace_and_thread,
8850 scoped_restore_current_thread and scoped_restore.
8851 (fetch_inferior_event): Use scoped_restore_current_thread.
8852 * linespec.c (decode_line_full, decode_line_1): Use
8853 scoped_restore_current_program_space.
8854 * mi/mi-main.c: Include "progspace-and-thread.h".
8855 (exec_continue): Use scoped_restore_current_thread.
8856 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
8857 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
8858 * proc-service.c (ps_pglobal_lookup): Use
8859 scoped_restore_current_program_space.
8860 * progspace-and-thread.c: New file.
8861 * progspace-and-thread.h: New file.
8862 * progspace.c (release_program_space, clone_program_space): Use
8863 scoped_restore_current_program_space.
8864 (restore_program_space, save_current_program_space)
8865 (save_current_space_and_thread): Delete.
8866 (switch_to_program_space_and_thread): Moved to
8867 progspace-and-thread.c.
8868 * progspace.h (save_current_program_space)
8869 (save_current_space_and_thread): Delete declarations.
8870 (scoped_restore_current_program_space): New class.
8871 * remote.c (remote_btrace_maybe_reopen): Use
8872 scoped_restore_current_thread.
8873 * symtab.c: Include "progspace-and-thread.h".
8874 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
8875 * thread.c (print_thread_info_1): Use
8876 scoped_restore_current_thread.
8877 (struct current_thread_cleanup): Delete.
8878 (do_restore_current_thread_cleanup)
8879 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
8880 (scoped_restore_current_thread::~scoped_restore_current_thread):
8881 ... this new dtor.
8882 (make_cleanup_restore_current_thread): Rename/convert to ...
8883 (scoped_restore_current_thread::scoped_restore_current_thread):
8884 ... this new ctor.
8885 (thread_apply_all_command): Use scoped_restore_current_thread.
8886 (thread_apply_command): Use scoped_restore_current_thread.
8887 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
8888 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
8889
f6223dbb
PA
88902017-05-04 Pedro Alves <palves@redhat.com>
8891
8892 * thread.c (make_cleanup_restore_current_thread): Move
8893 find_thread_ptid call before the is_stopped call. Assert that the
8894 thread is found. Replace is_stopped call by checking the thread's
8895 state directly. Remove unnecessary NULL-thread check.
8896
3c3ae77e
PA
88972017-05-04 Pedro Alves <palves@redhat.com>
8898
8899 * corelow.c (thread_section_name): New class.
8900 (get_core_register_section, get_core_siginfo): Use it.
8901
45eba0ab
AA
89022017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
8903
8904 * corelow.c (sniff_core_bfd): Remove extra semicolon.
8905 (get_core_register_section): Remove xfree of NULL pointer.
8906
f81fdd35
AH
89072017-05-03 Alan Hayward <alan.hayward@arm.com>
8908
8909 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
8910 * regcache.c (regcache::raw_supply_zeroed): New function.
8911 * regcache.h (regcache::raw_supply_zeroed): New declaration.
8912
35837774
SM
89132017-05-03 Simon Marchi <simon.marchi@ericsson.com>
8914
8915 * gdbarch.sh: Remove commented out definition of
8916 TARGET_CHAR_BIT.
8917 * gdbarch.h: Re-generate.
8918
c94fee56
SDJ
89192017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
8920
8921 * configure: Regenerate.
8922
d17f7b36
SM
89232017-05-02 Simon Marchi <simon.marchi@ericsson.com>
8924
8925 * solib-target.c (solib_target_relocate_section_addresses):
8926 Remove num_section_bases, num_bases, segment_bases variables.
8927
b560ebd6
SM
89282017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
8929
8930 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
8931
f2f46dfc
SM
89322017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
8933
8934 * solib-target.c: Include <vector>
8935 (struct lm_info_target) <~lm_info_target>: Remove.
8936 <segment_bases, section_bases>: Change type to
8937 std::vector<CORE_ADDR>.
8938 (library_list_start_segment, library_list_start_section,
8939 library_list_end_library,
8940 solib_target_relocate_section_addresses): Adjust.
8941
a0ff9e1a
SM
89422017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
8943
8944 * gdbarch.sh (software_single_step): Change return type to
8945 std::vector<CORE_ADDR>.
8946 * gdbarch.c, gdbarch.h: Re-generate.
8947 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
8948 Adjust.
8949 (arm_deal_with_atomic_sequence_raw): Adjust.
8950 (thumb_get_next_pcs_raw): Adjust.
8951 (arm_get_next_pcs_raw): Adjust.
8952 (arm_get_next_pcs): Adjust.
8953 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
8954 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
8955 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
8956 (alpha_software_single_step): Adjust.
8957 * alpha-tdep.h (alpha_software_single_step): Adjust.
8958 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
8959 * arm-tdep.c (arm_software_single_step): Adjust.
8960 (arm_breakpoint_kind_from_current_state): Adjust.
8961 * arm-tdep.h (arm_software_single_step): Adjust.
8962 * breakpoint.c (insert_single_step_breakpoint): Adjust.
8963 * cris-tdep.c (cris_software_single_step): Adjust.
8964 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
8965 (micromips_deal_with_atomic_sequence): Adjust.
8966 (deal_with_atomic_sequence): Adjust.
8967 (mips_software_single_step): Adjust.
8968 * mips-tdep.h (mips_software_single_step): Adjust.
8969 * moxie-tdep.c (moxie_software_single_step): Adjust.
8970 * nios2-tdep.c (nios2_software_single_step): Adjust.
8971 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
8972 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
8973 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
8974 * s390-linux-tdep.c (s390_software_single_step): Adjust.
8975 * sparc-tdep.c (sparc_software_single_step): Adjust.
8976 * spu-tdep.c (spu_software_single_step): Adjust.
8977 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
8978
ea480a30
SM
89792017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
8980
8981 * gdbarch.sh: Use semi-colon as field separator instead of colon.
8982 * gdbarch.h: Re-generate.
8983
d050f7d7
TW
89842017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
8985
8986 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
8987 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
8988 * python/py-instruction.c, python/py-instruction.h: New file.
8989 * python/py-record.c: Add py-instruction.h include.
8990 (gdbpy_initialize_record): Make gdb.Instruction a super class of
8991 gdb.RecordInstruction.
8992 * python/python-internal.h: Add gdbpy_initialize_instruction
8993 declaration.
8994 * python/python.c (do_start_initialization): Add
8995 gdbpy_initialize_instruction.
8996
14f819c8
TW
89972017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
8998
8999 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
9000 Remove.
9001 (btrace_func_from_recpy_func): New function.
9002 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
9003 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
9004 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
9005 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
9006 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
9007 Also, use new helper functions.
9008 (btpy_list_item): Use new helper functions.
9009 (recpy_bt_function_call_history): Use new type name.
9010 (btpy_call_getset): Remove.
9011 (gdbpy_initialize_btrace): Remove code to initialize
9012 gdb.BtraceFunctionCall.
9013 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
9014 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
9015 recpy_bt_func_prev, recpy_bt_func_next): New export.
9016 * python/py-record.c (recpy_func_type): New static object.
9017 (recpy_func_new, recpy_func_level, recpy_func_symbol,
9018 recpy_func_instructions, recpy_func_up, recpy_func_prev,
9019 recpy_func_next): New function.
9020 (recpy_element_hash, recpy_element_richcompare): Updated comment.
9021 (recpy_func_getset): New static object.
9022 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
9023 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
9024
0ed5da75
TW
90252017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
9026
9027 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
9028 (btpy_object, btpy_insn_type, btpy_new): Remove.
9029 (btpy_list_object): Use gdb.RecordInstruction type instead of
9030 gdb.BtraceInstruction type.
9031 (btrace_insn_from_recpy_insn): New function.
9032 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
9033 btpy_new.
9034 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
9035 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
9036 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
9037 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
9038 instead of btpy_object.
9039 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
9040 btpy_insn_data, btpy_insn_decode): Rename to ...
9041 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
9042 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
9043 recpy_bt_insn_decode): This. Also, use new helper functions.
9044 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
9045 recpy_insn_type.
9046 (btpy_insn_getset): Remove.
9047 (gdbpy_initialize_btrace): Remove code to initialize
9048 gdb.BtraceInstruction. Use recpy_element_object.
9049 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
9050 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
9051 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
9052 * python/py-record.c (recpy_insn_type): New static object.
9053 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
9054 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
9055 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
9056 New function.
9057 (recpy_insn_getset): New static object.
9058 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
9059 * python/py-record.h (recpy_element_object): New typedef.
9060 (recpy_insn_type, recpy_insn_new): New export.
9061
913aeadd
TW
90622017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
9063
9064 * py-record-btrace.c (btpy_insn_new): Removed.
9065 (btpy_insn_or_gap_new): New function.
9066 (btpy_insn_error): Removed.
9067 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
9068 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
9069 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
9070 btpy_insn_or_gap_new instead of btpy_insn_new.
9071 (btpy_insn_getset): Remove btpy_insn_error.
9072 * py-record.c (recpy_gap_type): New static object.
9073 (recpy_gap_object): New typedef.
9074 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
9075 recpy_gap_reason_string): New function.
9076 (recpy_gap_getset): New static object.
9077 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
9078 * py-record.h (recpy_gap_new): New export.
9079
a3be24ad
TW
90802017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
9081
9082 * python/py-record.c (recpy_ptid): Remove.
9083 (recpy_record_getset): Remove recpy_ptid.
9084
ae20e79a
TW
90852017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
9086
9087 * btrace.c (btrace_fetch): Set inferior_ptid.
9088 * python/py-record-btrace.c: Add "py-record.h" include.
9089 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
9090 recpy_bt_end, recpy_bt_instruction_history,
9091 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
9092 in gdb.Record object instead of current ptid.
9093 * python/py-record.c: Include new "py-record.h" file.
9094 (recpy_record_object): Moved to py-record.h.
9095 * python/py-record.h: New file.
9096
8d0050ea
TW
90972017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
9098
9099 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
9100 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
9101 indentation.
9102
3f380b50
JB
91032017-05-01 Joel Brobecker <brobecker@adacore.com>
9104
9105 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
9106 the past maintainers section.
9107
07495424
YQ
91082017-04-28 Yao Qi <yao.qi@linaro.org>
9109
9110 * infcmd.c (get_return_value): Use regcache ctor, and remove
9111 cleanup.
9112
deb1fa3e
YQ
91132017-04-28 Yao Qi <yao.qi@linaro.org>
9114 Pedro Alves <palves@redhat.com>
9115
9116 * regcache.c (regcache::regcache): New tag dispatch ctor.
9117 (do_cooked_read): Moved above.
9118 (regcache_dup): Use the tag dispatch ctor..
9119 * regcache.h (regcache): Declare ctor, delete copy ctor and
9120 assignment operator, remove friend regcache_dup.
9121
b421c83c
YQ
91222017-04-28 Yao Qi <yao.qi@linaro.org>
9123
9124 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
9125 call method save instead of regcache_cpy.
9126 * regcache.h (struct regcache): Make regcache_dup a friend.
9127
ef79d9a3
YQ
91282017-04-28 Yao Qi <yao.qi@linaro.org>
9129
9130 * regcache.c (struct regcache): Move to regcache.h
9131 (regcache::arch): New method.
9132 (regcache_get_ptid): Update.
9133 (get_regcache_arch): Call arch method.
9134 (get_regcache_aspace): Call method aspace.
9135 (register_buffer): Change it to method.
9136 (regcache_save): Change it to regcache::save.
9137 (regcache_restore): Likewise.
9138 (regcache_cpy_no_passthrough): Remove the declaration.
9139 (regcache_cpy): Call methods restore and cpy_no_passthrough.
9140 (regcache_cpy_no_passthrough): Change it to method
9141 cpy_no_passthrough.
9142 (regcache_register_status): Change it to method
9143 get_register_status.
9144 (regcache_invalidate): Change it to method invalidate.
9145 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
9146 (regcache_raw_update): Change it to method raw_update.
9147 (regcache_raw_read): Likewise.
9148 (regcache_raw_read_signed): Likewise.
9149 (regcache_raw_read_unsigned): Likewise.
9150 (regcache_raw_write_signed): Likewise.
9151 (regcache_raw_write_unsigned): Likewise.
9152 (regcache_cooked_read): Likewise.
9153 (regcache_cooked_read_value): Likewise.
9154 (regcache_cooked_read_signed): Likewise.
9155 (regcache_cooked_read_unsigned): Likewise.
9156 (regcache_cooked_write_signed): Likewise.
9157 (regcache_cooked_write_unsigned): Likewise.
9158 (regcache_raw_set_cached_value): Likewise.
9159 (regcache_raw_write): Likewise.
9160 (regcache_cooked_write): Likewise.
9161 (regcache_xfer_part): Likewise.
9162 (regcache_raw_read_part): Likewise.
9163 (regcache_raw_write_part): Likewise.
9164 (regcache_cooked_read_part): Likewise.
9165 (regcache_cooked_write_part): Likewise.
9166 (regcache_raw_supply): Likewise.
9167 (regcache_raw_collect): Likewise.
9168 (regcache_transfer_regset): Likewise.
9169 (regcache_supply_regset): Likewise.
9170 (regcache_collect_regset): Likewise.
9171 (regcache_debug_print_register): Likewise.
9172 (enum regcache_dump_what): Move it to regcache.h.
9173 (regcache_dump): Change it to method dump.
9174 * regcache.h (enum regcache_dump_what): New.
9175 (class regcache): New.
9176 * target.c (target_fetch_registers): Call method
9177 debug_print_register.
9178 (target_store_registers): Likewise.
9179
f8fdb78e
SM
91802017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9181
9182 * windows-nat.c (struct lm_info_windows): Initialize field.
9183 (windows_make_so): Allocate lm_info_windows with new.
9184 (windows_free_so): Free lm_info_windows with delete.
9185
9ccbfd7b
SM
91862017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9187
9188 * solib-darwin.c (struct lm_info_darwin): Initialize field.
9189 (darwin_current_sos): Allocate lm_info_darwin with new, remove
9190 cleanup.
9191 (darwin_free_so): Free lm_info_darwin with delete.
9192
76e75227
SM
91932017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9194
9195 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
9196 <l_addr_p>: Change type to bool.
9197 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
9198 (svr4_free_so): Free lm_info_svr4 with delete.
9199 (svr4_copy_library_list): Replace memcpy with call to copy
9200 constructor.
9201 (library_list_start_library, svr4_default_sos): Allocate
9202 lm_info_svr4 with new.
9203
51046d9e
SM
92042017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9205
9206 * solib-target.c (struct lm_info_target): Add destructor,
9207 initialize fields.
9208 <name>: Change type to std::string.
9209 (library_list_start_library): Allocate lm_info_target with new.
9210 (solib_target_free_library_list): Free lm_info_target with
9211 delete.
9212 (solib_target_current_sos): Adapt to std::string.
9213 (solib_target_free_so): Free lm_info_target with delete.
9214
4023ae76
SM
92152017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9216
9217 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
9218 fields.
9219 (frv_current_sos): Allocate lm_info_frv with new.
9220 (frv_relocate_main_executable): Free lm_info_frv with delete,
9221 allocate with new.
9222 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
9223
af43057b
SM
92242017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9225
9226 * solib-frv.c (struct lm_info_frv): Fix indentation.
9227
b0911207
SM
92282017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9229
9230 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
9231 map field.
9232 (dsbt_current_sos): Allocate lm_info_dsbt with new.
9233 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
9234 and allocate with new.
9235 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
9236
6c401f72
SM
92372017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9238
9239 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
9240 <filename, member_name>: Change type to std::string.
9241 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
9242 (library_list_start_library): Allocate lm_info_aix with new.
9243 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
9244 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
9245 with copy constructor.
9246
d0e449a1
SM
92472017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9248
9249 * solist.h (struct lm_info): Remove.
9250 (struct lm_info_base): New class.
9251 (struct so_list) <lm_info>: Change type to lm_info_base *.
9252 * nto-tdep.c (struct lm_info): Remove.
9253 (lm_addr): Adjust.
9254 * solib-aix.c (struct lm_info): Rename to ...
9255 (struct lm_info_aix): ... this. Extend lm_info_base.
9256 (lm_info_p): Rename to ...
9257 (lm_info_aix_p): ... this, and adjust.
9258 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
9259 solib_aix_parse_libraries, library_list_start_library,
9260 solib_aix_free_library_list, solib_aix_parse_libraries,
9261 solib_aix_get_library_list,
9262 solib_aix_relocate_section_addresses, solib_aix_free_so,
9263 solib_aix_get_section_offsets,
9264 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
9265 Adjust.
9266 (struct solib_aix_inferior_data) <library_list>: Adjust.
9267 * solib-darwin.c (struct lm_info): Rename to ...
9268 (struct lm_info_darwin): ... this. Extend lm_info_base.
9269 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
9270 * solib-dsbt.c (struct lm_info): Rename to ...
9271 (struct lm_info_dsbt): ... this. Extend lm_info_base.
9272 (struct dsbt_info) <main_executable_lm_info): Adjust.
9273 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
9274 dsbt_relocate_section_addresses): Adjust.
9275 * solib-frv.c (struct lm_info): Rename to ...
9276 (struct lm_info_frv): ... this. Extend lm_info_base.
9277 (main_executable_lm_info): Adjust.
9278 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
9279 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
9280 find_canonical_descriptor_in_load_object,
9281 frv_fdpic_find_canonical_descriptor): Adjust.
9282 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
9283 to lm_info_svr4.
9284 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
9285 svr4_clear_so, svr4_copy_library_list,
9286 library_list_start_library, svr4_default_sos, svr4_read_so_list,
9287 svr4_current_sos, svr4_fetch_objfile_link_map,
9288 solist_update_incremental): Adjust.
9289 * solib-svr4.h (struct lm_info_svr4): Move here from
9290 solib-svr4.c.
9291 * solib-target.c (struct lm_info): Rename to ...
9292 (struct lm_info_target): ... this. Extend lm_info_base.
9293 (lm_info_p): Rename to ...
9294 (lm_info_target_p): ... this.
9295 (solib_target_parse_libraries, library_list_start_segment,
9296 library_list_start_section, library_list_start_library,
9297 library_list_end_library, solib_target_free_library_list,
9298 solib_target_current_sos, solib_target_free_so,
9299 solib_target_relocate_section_addresses): Adjust.
9300 * windows-nat.c (struct lm_info): Rename to ...
9301 (struct lm_info_windows): ... this. Extend lm_info_base.
9302 (windows_make_so, handle_load_dll, handle_unload_dll,
9303 windows_xfer_shared_libraries): Adjust.
9304
434a4023
SM
93052017-04-28 Simon Marchi <simon.marchi@ericsson.com>
9306
9307 * solib-darwin.c (struct darwin_so_list): Remove.
9308 (darwin_current_sos): Allocate an so_list object instead of a
9309 darwin_so_list, separately allocate an lm_info object.
9310 (darwin_free_so): Free lm_info.
9311
428544e8
JB
93122017-04-28 John Baldwin <jhb@FreeBSD.org>
9313
9314 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
9315 with fprintf_filtered.
9316
4621115f
YQ
93172017-04-28 Yao Qi <yao.qi@linaro.org>
9318
9319 * regcache.c (regcache::regcache): New function.
9320 (regcache::~regcache): New function.
9321 (regcache_xmalloc_1): Remove.
9322 (regcache_xmalloc): Call new regcache.
9323 (regcache_xfree): Call delete regcache.
9324 (get_thread_arch_aspace_regcache): Call new regcache.
9325
339053c2
YQ
93262017-04-28 Yao Qi <yao.qi@linaro.org>
9327
9328 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
9329 lwp instead of ptid_get_lwp.
9330
7974a605
YQ
93312017-04-28 Yao Qi <yao.qi@linaro.org>
9332
9333 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
9334 lwp_info instead of getting from inferior_ptid.
9335
e15c3eb4
KS
93362017-04-27 Keith Seitz <keiths@redhat.com>
9337
9338 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
9339 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
9340 (CV_CONVERSION_BADNESS): Define.
9341 (rank_one_type): Remove overly restrictive rvalue reference
9342 rank checks.
9343 Add cv-qualifier checks and subranks for type equality.
9344 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
9345 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
9346 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
9347
72bc1d24
SM
93482017-04-27 Simon Marchi <simon.marchi@ericsson.com>
9349
9350 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
9351 count when creating the object.
9352
55bcecda
UW
93532017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
9354 Ulrich Weigand <uweigand@de.ibm.com>
9355
9356 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
9357 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
9358 is used in AIX.
9359 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
9360 (process_xcoff_symbol): Likewise.
9361 (scan_xcoff_symtab): Likewise.
9362
5c99fcf8
AH
93632017-04-26 Alan Hayward <alan.hayward@arm.com>
9364
9365 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
9366 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
9367 (ia64_access_reg): Use get_frame_register_unsigned.
9368 (ia64_access_rse_reg): Likewise.
9369 (ia64_libunwind_frame_prev_register): Likewise.
9370
b41c5a85
JW
93712017-04-26 Jiong Wang <jiong.wang@arm.com>
9372
9373 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
9374 * gdbarch.c: Regenerated.
9375 * gdbarch.h: Regenerated.
9376 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
9377 visibility external.
9378 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
9379 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
9380 (enum cfa_how_kind): Move to ...
9381 (struct dwarf2_frame_state_reg_info): Likewise.
9382 (struct dwarf2_frame_state): Likewise.
9383 * dwarf2-frame.h: ... here.
9384 (dwarf2_frame_state_alloc_regs): New declaration.
9385 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
9386 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
9387
c185f580
AH
93882017-04-26 Alan Hayward <alan.hayward@arm.com>
9389
9390 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
9391 regcache_raw_read_unsigned.
9392 (xtensa_pseudo_register_write): Likewise.
9393
19c45594
AH
93942017-04-26 Alan Hayward <alan.hayward@arm.com>
9395
9396 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
9397 (nds32_pseudo_register_write): Likewise.
9398
4658f12e
YQ
93992017-04-25 Yao Qi <yao.qi@linaro.org>
9400
9401 * regcache.c (struct regcache) <readonly_p>: Change its type
9402 to bool.
9403 (regcache_xmalloc_1): Update parameter type and callers update.
9404
d581dda8
YQ
94052017-04-25 Yao Qi <yao.qi@linaro.org>
9406
9407 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
9408 set_gdbarch_wchar_bit.
9409 * arm-tdep.c (arm_gdbarch_init): Likewise.
9410
debed3db
PA
94112017-04-25 Pedro Alves <palves@redhat.com>
9412
9413 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
9414 (BothAreRelocatable, memcopy, memmove): Don't define.
9415 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
9416 macros.
9417
b0b92aeb
PA
94182017-04-25 Pedro Alves <palves@redhat.com>
9419
9420 * common/common-defs.h: Include "common/poison.h".
9421 * common/function-view.h: (Not, Or, Requires): Move to traits.h
9422 and adjust.
9423 * common/poison.h: New file.
9424 * common/traits.h: Include <type_traits>.
9425 (Not, Or, Requires): New, moved from common/function-view.h.
9426
16c4d54a
PA
94272017-04-25 Pedro Alves <palves@redhat.com>
9428
9429 * breakpoint.h (struct breakpoint): In-class initialize all
9430 fields. Make boolean fields "bool".
9431 * breakpoint.c (init_raw_breakpoint_without_location): Remove
9432 memset call and initializations no longer necessary.
9433
b5c36682
PA
94342017-04-25 Pedro Alves <palves@redhat.com>
9435
9436 * btrace.c (pt_btrace_insn_flags): Change parameter type to
9437 reference.
9438 (pt_btrace_insn): New function.
9439 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
9440
5625a286
PA
94412017-04-25 Pedro Alves <palves@redhat.com>
9442
9443 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
9444 "base" field and inherit from "bp_location" instead. Add
9445 non-default ctor.
9446 (allocate_location_exception): Use new non-default ctor.
9447 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
9448 (init_bp_location): Convert to ...
9449 (bp_location::bp_location): ... this new ctor, and remove memset
9450 call.
9451 (base_breakpoint_allocate_location): Use the new non-default ctor.
9452 * breakpoint.h (bp_location): Now a class. Declare default and
9453 non-default ctors. In-class initialize all members.
9454 (init_bp_location): Remove declaration.
9455
23bcc18f
PA
94562017-04-25 Pedro Alves <palves@redhat.com>
9457
9458 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
9459 assignment operator.
9460
e1ba3053
YQ
94612017-04-24 Yao Qi <yao.qi@linaro.org>
9462
9463 * doublest.c (convert_doublest_to_floatformat): Call
9464 floatformat_totalsize_bytes.
9465
10f489e5
TT
94662017-04-22 Tom Tromey <tom@tromey.com>
9467
9468 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
9469 ui_out_emit_list.
9470 * stack.c (print_frame): Use ui_out_emit_list.
9471 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
9472 ui_out_emit_list.
9473 * mi/mi-main.c (print_one_inferior)
9474 (mi_cmd_data_list_register_names)
9475 (mi_cmd_data_list_register_values, mi_cmd_list_features)
9476 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
9477 ui_out_emit_list.
9478 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
9479 (mi_output_solib_attribs): Use ui_out_emit_list,
9480 ui_out_emit_tuple.
9481 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
9482 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
9483 (mi_cmd_stack_list_args, list_args_or_locals): Use
9484 ui_out_emit_list.
9485 * disasm.c (do_assembly_only): Use ui_out_emit_list.
9486 * breakpoint.c (print_solib_event, output_thread_groups): Use
9487 ui_out_emit_list.
9488
0092b74d
TT
94892017-04-22 Tom Tromey <tom@tromey.com>
9490
9491 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
9492 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
9493 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
9494
a14a62dd
TT
94952017-04-22 Tom Tromey <tom@tromey.com>
9496
9497 * tracepoint.c (tvariables_info_1)
9498 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
9499
46b9c129
TT
95002017-04-22 Tom Tromey <tom@tromey.com>
9501
9502 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
9503 annotate_arg_emitter.
9504 * breakpoint.c (print_mention_watchpoint)
9505 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
9506 * annotate.h (struct annotate_arg_emitter): New.
9507
2e783024
TT
95082017-04-22 Tom Tromey <tom@tromey.com>
9509
9510 * record-btrace.c (record_btrace_insn_history)
9511 (record_btrace_insn_history_range, record_btrace_call_history)
9512 (record_btrace_call_history_range): Use ui_out_emit_tuple.
9513 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
9514 ui_out_emit_tuple.
9515 * stack.c (print_frame_info): Use ui_out_emit_tuple.
9516 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
9517 * skip.c (skip_info): Use ui_out_emit_tuple.
9518 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
9519 * progspace.c (print_program_space): Use ui_out_emit_tuple.
9520 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
9521 * osdata.c (info_osdata): Use ui_out_emit_tuple.
9522 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
9523 ui_out_emit_tuple.
9524 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
9525 (output_register, mi_cmd_data_read_memory)
9526 (mi_cmd_data_read_memory_bytes, mi_load_progress)
9527 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
9528 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
9529 Use ui_out_emit_tuple.
9530 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
9531 ui_out_emit_tuple.
9532 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
9533 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
9534 * linux-thread-db.c (info_auto_load_libthread_db): Use
9535 ui_out_emit_tuple.
9536 * inferior.c (print_inferior): Use ui_out_emit_tuple.
9537 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
9538 * disasm.c (do_mixed_source_and_assembly_deprecated)
9539 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
9540 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
9541 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
9542 * breakpoint.c (print_one_breakpoint_location)
9543 (print_one_breakpoint): Use ui_out_emit_tuple.
9544 * auto-load.c (print_script, info_auto_load_cmd): Use
9545 ui_out_emit_tuple.
9546 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
9547
9be21bb4
SM
95482017-04-21 Simon Marchi <simon.marchi@ericsson.com>
9549
9550 * thread.c (print_thread_info_1): Remove dead code.
9551
0d4c07af
JK
95522017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
9553
9554 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
9555 GDB_SELF_TEST.
9556 * arm-tdep.c (selftests::arm_record_test): Likewise.
9557
4daf993d
YQ
95582017-04-21 Yao Qi <yao.qi@linaro.org>
9559
9560 * regcache.c (regcache_restore): Remove argument 2. Replace
9561 argument 3 with regcache. Get register status from
9562 src->register_status and get register contents from
9563 register_buffer (src, regnum).
9564 (regcache_cpy): Update.
9565
a6c21d4a
PA
95662017-04-19 Pedro Alves <palves@redhat.com>
9567
9568 * gdbthread.h (thread): Add missing closing parenthesis in
9569 comment.
9570
3a3fd0fd
PA
95712017-04-19 Pedro Alves <palves@redhat.com>
9572
9573 * common/refcounted-object.h: New file.
9574 * gdbthread.h: Include "common/refcounted-object.h".
9575 (thread_info): Inherit from refcounted_object and add comments.
9576 (thread_info::incref, thread_info::decref)
9577 (thread_info::m_refcount): Delete.
9578 (thread_info::deletable): Use the refcounted_object::refcount()
9579 method.
9580 * inferior.c (current_inferior_): Add comment.
9581 (set_current_inferior): Increment/decrement refcounts.
9582 (prune_inferiors, remove_inferior_command): Skip inferiors marked
9583 not-deletable instead of comparing with the current inferior.
9584 (initialize_inferiors): Increment the initial inferior's refcount.
9585 * inferior.h (struct inferior): Forward declare.
9586 Include "common/refcounted-object.h".
9587 (current_inferior, set_current_inferior): Move declaration to
9588 before struct inferior's definition, and fix comment.
9589 (inferior): Inherit from refcounted_object. Add comments.
9590 * thread.c (switch_to_thread_no_regs): Reference the thread's
9591 inferior pointer directly instead of doing a ptid lookup.
9592 (switch_to_no_thread): New function.
9593 (switch_to_thread(thread_info *)): New function, factored out
9594 from ...
9595 (switch_to_thread(ptid_t)): ... this.
9596 (restore_current_thread): Delete.
9597 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
9598 fields, and add 'inf' field.
9599 (do_restore_current_thread_cleanup): Check whether old->inf is
9600 alive instead of looking up an inferior by ptid. Use
9601 switch_to_thread and switch_to_no_thread.
9602 (restore_current_thread_cleanup_dtor): Use old->inf directly
9603 instead of lookup up an inferior by id. Decref the inferior.
9604 Don't restore 'removable'.
9605 (make_cleanup_restore_current_thread): Same the inferior pointer
9606 in old, instead of the inferior number. Incref the inferior.
9607 Don't save/clear 'removable'.
9608
9bcb1f16
PA
96092017-04-19 Pedro Alves <palves@redhat.com>
9610
9611 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9612 unittests/scoped_restore-selftests.c.
9613 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
9614 * common/scoped_restore.h (scoped_restore_base): Make "class".
9615 (scoped_restore_base::release): New public method.
9616 (scoped_restore_base::scoped_restore_base): New protected ctor.
9617 (scoped_restore_base::m_saved_var): New protected field.
9618 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
9619 scoped_restore_base base class instead of m_saved_var directly.
9620 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
9621 (scoped_restore_tmpl::scoped_restore_tmpl(const
9622 scoped_restore_tmpl<T>&)): Likewise.
9623 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
9624 method.
9625 (scoped_restore_tmpl::saved_var): New method.
9626 (scoped_restore_tmpl::m_saved_var): Delete.
9627 * inferior.h (inferior::detaching): Now a bool.
9628 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
9629 cleanup.
9630 * unittests/scoped_restore-selftests.c: New file.
9631
26fcd539
PA
96322017-04-19 Pedro Alves <palves@redhat.com>
9633
9634 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
9635 Re-sort in alphabetic order.
9636
fdd243b0
PA
96372017-04-18 Pedro Alves <palves@redhat.com>
9638
9639 * xml-support.c (obstack_xml_printf): Delete.
9640 * xml-support.h (obstack_xml_printf): Delete.
9641
4895cde2
PA
96422017-04-18 Pedro Alves <palves@redhat.com>
9643
9644 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
9645 vdebug, verror, body_text, start_element, end_element, name,
9646 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
9647 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
9648 is_xinclude>: Make private and add m_ prefix.
9649 (gdb_xml_parser::body_text): New method, based on ...
9650 (gdb_xml_body_text): ... this. Adjust.
9651 (gdb_xml_parser::vdebug): New method, based on ...
9652 (gdb_xml_debug): ... this. Adjust.
9653 (gdb_xml_parser::verror): New method, based on ...
9654 (gdb_xml_error): ... this. Adjust.
9655 (gdb_xml_parser::start_element): New method, based on ...
9656 (gdb_xml_start_element): ... this. Adjust.
9657 (gdb_xml_start_element_wrapper): Defer to
9658 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
9659 (gdb_xml_parser::end_element): New method, based on ...
9660 (gdb_xml_end_element_wrapper): ... this. Adjust.
9661 (gdb_xml_parser::~gdb_xml_parser): Adjust.
9662 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
9663 (gdb_xml_parser::use_dtd): New method, based on ...
9664 (gdb_xml_use_dtd): ... this. Adjust.
9665 (gdb_xml_parser::parse): New method, based on ...
9666 (gdb_xml_parse): ... this. Adjust.
9667 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
9668 (xinclude_start_include): Adjust to call the parser's name method.
9669 (xml_xinclude_default, xml_xinclude_start_doctype)
9670 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
9671 method.
9672 (xml_process_xincludes): Adjust to call parser methods.
9673 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
9674 declarations.
9675
bd8a901f
PA
96762017-04-18 Pedro Alves <palves@redhat.com>
9677
9678 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
9679 gdb::optional<std::string>.
9680 * xml-support.c: Include <string>.
9681 (scope_level::scope_level(scope_level &&))
9682 (scope_level::~scope_level): Delete.
9683 (scope_level::body): Now a std::string.
9684 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
9685 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
9686 parameter.
9687 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
9688 (xinclude_parsing_data::output): Now a std::string reference.
9689 (xinclude_start_include): Adjust.
9690 (xml_xinclude_default): Adjust.
9691 (xml_process_xincludes): Add 'output' parameter, and return bool.
9692 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
9693 and return bool.
9694 * xml-tdesc.c: Include <unordered_map> and <string>.
9695 (tdesc_xml_cache): Delete.
9696 (tdesc_xml_cache_s): Delete.
9697 (xml_cache): Now an std::unordered_map.
9698 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
9699 (target_fetch_description_xml): Change return type to
9700 gdb::optional<std::string>, and adjust.
9701 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
9702 (target_fetch_description_xml): Change return type to
9703 gdb::optional<std::string>.
9704
d35d1958
PA
97052017-04-18 Pedro Alves <palves@redhat.com>
9706
9707 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9708 unittests/optional-selftests.c.
9709 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
9710 * unittests/optional-selftests.c: New file.
9711 * unittests/optional/assignment/1.cc: New file.
9712 * unittests/optional/assignment/2.cc: New file.
9713 * unittests/optional/assignment/3.cc: New file.
9714 * unittests/optional/assignment/4.cc: New file.
9715 * unittests/optional/assignment/5.cc: New file.
9716 * unittests/optional/assignment/6.cc: New file.
9717 * unittests/optional/assignment/7.cc: New file.
9718 * unittests/optional/cons/copy.cc: New file.
9719 * unittests/optional/cons/default.cc: New file.
9720 * unittests/optional/cons/move.cc: New file.
9721 * unittests/optional/cons/value.cc: New file.
9722 * unittests/optional/in_place.cc: New file.
9723 * unittests/optional/observers/1.cc: New file.
9724 * unittests/optional/observers/2.cc: New file.
9725
22796e97
PA
97262017-04-18 Pedro Alves <palves@redhat.com>
9727
9728 * common/gdb_optional.h: Include common/traits.h.
9729 (in_place_t): New type.
9730 (in_place): New constexpr variable.
9731 (optional::optional): Remove member initialization of
9732 m_instantiated.
9733 (optional::optional(in_place_t...)): New constructor.
9734 (optional::~optional): Use reset.
9735 (optional::optional(const optional&)): New.
9736 (optional::optional(const optional&&)): New.
9737 (optional::optional(T &)): New.
9738 (optional::optional(T &&)): New.
9739 (operator::operator=(const optional &)): New.
9740 (operator::operator=(optional &&)): New.
9741 (operator::operator= (const T &))
9742 (operator::operator= (T &&))
9743 (operator::emplace (Args &&... args)): Return a T&. Use reset.
9744 (operator::reset): New.
9745 (operator::m_instantiated):: Add in-class initializer.
9746 * common/traits.h: Include <type_traits>.
9747 (struct And): New types.
9748
a7fc9b61
PA
97492017-04-18 Pedro Alves <palves@redhat.com>
9750
9751 * xml-support.c: Include <vector>.
9752 (scope_level::scope_level(const gdb_xml_element *))
9753 (scope_level::scope_level(scope_level&&)): New.
9754 (scope_level::~scope_level): New.
9755 (scope_level_s): Delete.
9756 (gdb_xml_parser::scopes): Now a std::vector.
9757 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
9758 Use std::vector.
9759 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
9760 scope cleanup code.
9761 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
9762 of the scopes member. Use std::vector::emplace_back.
9763
010151c9
PA
97642017-04-18 Pedro Alves <palves@redhat.com>
9765
9766 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
9767 a bool.
9768 (gdb_xml_end_element): Change type of first parameter.
9769 (gdb_xml_cleanup): Rename to ...
9770 (gdb_xml_parser::~gdb_xml_parser): ... this.
9771 (gdb_xml_create_parser_and_cleanup): Delete with ...
9772 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
9773 to this new ctor.
9774 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
9775 using gdb_xml_create_parser_and_cleanup.
9776 (xinclude_parsing_data): Add ctor/dtor.
9777 (xml_xinclude_cleanup): Delete.
9778 (xml_process_xincludes): Create a local xinclude_parsing_data
9779 instead of heap-allocating one. Create a local gdb_xml_parser
9780 instead of heap-allocating one with
9781 gdb_xml_create_parser_and_cleanup.
9782
d56060f0
JB
97832017-04-18 John Baldwin <jhb@FreeBSD.org>
9784
9785 PR threads/20743
9786 * fbsd-nat.c (resume_one_thread_cb): Remove.
9787 (resume_all_threads_cb): Remove.
9788 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
9789 iterate_over_threads.
9790
305d16a9
JB
97912017-04-17 Joel Brobecker <brobecker@adacore.com>
9792
9793 * NEWS: Create a new section for the next release branch.
9794 Rename the section of the current branch, now that it has
9795 been cut.
9796
8bb57231
JB
97972017-04-17 Joel Brobecker <brobecker@adacore.com>
9798
9799 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
9800 * version.in: Bump version to 8.0.50.DATE-git.
9801
096c92dd
SDJ
98022017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
9803
9804 PR gdb/21385
9805 * windows-nat.c (windows_create_inferior): Declare 'allargs'
9806 independently of the host, and fix build breakage on Cygwin.
9807
0550c955
PA
98082017-04-13 Pedro Alves <palves@redhat.com>
9809
9810 * inferior.c (free_inferior): Convert to ...
9811 (inferior::~inferior): ... this dtor.
9812 (inferior::inferior): New ctor, factored out from ...
9813 (add_inferior_silent): ... here. Allocate the inferior with a new
9814 expression.
9815 (delete_inferior): Call delete instead of free_inferior.
9816 * inferior.h (gdb_environ, continuation): Forward declare.
9817 (inferior): Now a class. Add in-class initialization to all
9818 members. Make boolean fields bool, except 'detaching'.
9819 (inferior::inferior): New explicit ctor.
9820 (inferior::~inferior): New.
9821
e3d60dfc
PA
98222017-04-13 Pedro Alves <palves@redhat.com>
9823
9824 * inferior.c (init_inferior_list): Delete.
9825 * inferior.h (init_inferior_list): Delete.
9826
5fd69d0a
PA
98272017-04-13 Pedro Alves <palves@redhat.com>
9828
9829 PR threads/13217
9830 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
9831 (top level): Call it twice, with different thread sets.
9832
c6609450
PA
98332017-04-13 Pedro Alves <palves@redhat.com>
9834
9835 * thread.c: Include <algorithm>.
9836 (thread_array_cleanup): Delete.
9837 (scoped_inc_dec_ref): New class.
9838 (live_threads_count): New function.
9839 (set_thread_refcount): Delete.
9840 (tp_array_compar_ascending): Now a bool.
9841 (tp_array_compar): Convert to a std::sort comparison function.
9842 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
9843 and live_threads_count.
9844
2a00d7ce
PA
98452017-04-13 Pedro Alves <palves@redhat.com>
9846
9847 * infrun.c (follow_fork_inferior): Also switch the current
9848 inferior.
9849
441d7c93
PA
98502017-04-13 Pedro Alves <palves@redhat.com>
9851
9852 * breakpoint.c (watch_command_1): Save watchpoint-frame info
9853 before calling create_internal_breakpoint.
9854
808480f6
PA
98552017-04-13 Pedro Alves <palves@redhat.com>
9856
9857 * fork-child.c (execv_argv): New class.
9858 (breakup_args): Refactored as ...
9859 (execv_argv::init_for_no_shell): .. this method of execv_argv.
9860 Copy arguments to storage and replace separators with NULL
9861 terminators in place.
9862 (escape_bang_in_quoted_argument): Adjust to return bool.
9863 (execv_argv::execv_argv): New ctor.
9864 (execv_argv::init_for_shell): New method, factored out from
9865 fork_inferior. Don't strdup strings into the vector.
9866 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
9867 Remove free_vector_argv call.
9868
ad3d022a
YQ
98692017-04-13 Yao Qi <yao.qi@linaro.org>
9870
9871 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
9872 tdep->rx_psw_type.
9873
e6ddc3bf
YQ
98742017-04-13 Yao Qi <yao.qi@linaro.org>
9875
9876 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
9877 * rx-tdep.c (rx_gdbarch_init): Likewise.
9878
bfb8cf90
PA
98792017-04-13 Pedro Alves <palves@redhat.com>
9880
9881 * breakpoint.h (struct breakpoint): Reindent.
9882
f5336ca5
PA
98832017-04-13 Pedro Alves <palves@redhat.com>
9884
9885 * breakpoint.c (bp_location): Rename to ...
9886 (bp_locations): ... this. All references updated.
9887 (bp_location_count): Rename to ...
9888 (bp_locations_count): ... this. All references updated.
9889 (bp_location_placed_address_before_address_max): Rename to ...
9890 (bp_locations_placed_address_before_address_max): ... this. All
9891 references updated.
9892 (bp_location_shadow_len_after_address_max): Rename to ...
9893 (bp_locations_shadow_len_after_address_max): ... this. All
9894 references updated.
9895 (bp_location_compare_addrs): Rename to ...
9896 (bp_locations_compare_addrs): ... this. All references updated.
9897 (bp_location_compare):Rename to ...
9898 (bp_locations_compare): ... this. All references updated.
9899 (bp_location_target_extensions_update): Rename to ...
9900 (bp_locations_target_extensions_update): ... this. All references
9901 updated.
9902
be628ab8
SDJ
99032017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
9904
9905 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
9906 * common/common.m4: Check headers 'termios.h', 'termio.h' and
9907 'sgtty.h'.
9908 * common/gdb_termios.h: New file, with parts of "terminal.h".
9909 * inflow.c: Include "gdb_termios.h".
9910 * ser-unix.c: Include "gdb_termios.h".
9911 * terminal.h: Move terminal-related defines to
9912 "common/gdb_termios.h".
9913
8e9e35b1
TT
99142017-04-12 Tom Tromey <tom@tromey.com>
9915
9916 * probe.c (parse_probes): Update.
9917 * location.h (delete_event_location): Don't declare.
9918 (event_location_deleter::operator()): Update.
9919 * location.c (event_location_deleter::operator()): Rename from
9920 delete_event_location.
9921 * linespec.h (linespec_result) <location>: Change type to
9922 event_location_up.
9923 * linespec.c (canonicalize_linespec, event_location_to_sals)
9924 (decode_objc): Update.
9925 (linespec_result): Don't call delete_event_location.
9926 * breakpoint.c (create_breakpoints_sal)
9927 (bkpt_probe_create_sals_from_location)
9928 (strace_marker_create_sals_from_location): Update.
9929
16e802b9
TT
99302017-04-12 Tom Tromey <tom@tromey.com>
9931
9932 * linespec.h (struct linespec_result): Add constructor and
9933 destructor.
9934 (init_linespec_result, destroy_linespec_result)
9935 (make_cleanup_destroy_linespec_result): Don't declare.
9936 * linespec.c (init_linespec_result): Remove.
9937 (linespec_result::~linespec_result): Rename from
9938 destroy_linespec_result. Update.
9939 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
9940 Remove.
9941 * breakpoint.c (create_breakpoint, break_range_command)
9942 (decode_location_default): Update.
9943 * ax-gdb.c (agent_command_1): Update.
9944
d28cd78a
TT
99452017-04-12 Tom Tromey <tom@tromey.com>
9946
9947 * remote.c (remote_download_tracepoint): Update.
9948 * python/py-breakpoint.c (bppy_get_location): Update.
9949 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
9950 (gdbscm_breakpoint_location): Update.
9951 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
9952 * breakpoint.h (struct breakpoint) <location, location_range_end>:
9953 Change type to event_location_up.
9954 * breakpoint.c (create_overlay_event_breakpoint)
9955 (create_longjmp_master_breakpoint)
9956 (create_std_terminate_master_breakpoint)
9957 (create_exception_master_breakpoint)
9958 (breakpoint_event_location_empty_p, print_breakpoint_location)
9959 (print_one_breakpoint_location, create_thread_event_breakpoint)
9960 (init_breakpoint_sal, create_breakpoint)
9961 (print_recreate_ranged_breakpoint, break_range_command)
9962 (init_ada_exception_breakpoint, say_where): Update.
9963 (base_breakpoint_dtor): Don't call delete_event_location.
9964 (bkpt_print_recreate, tracepoint_print_recreate)
9965 (dprintf_print_recreate, update_static_tracepoint)
9966 (breakpoint_re_set_default): Update.
9967
711799d5
TT
99682017-04-12 Tom Tromey <tom@tromey.com>
9969
9970 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
9971 type of "to_do". Update.
9972 (compute_stack_depth): Use std::vector.
9973
52d214d3
TT
99742017-04-12 Tom Tromey <tom@tromey.com>
9975
9976 * printcmd.c (find_instruction_backward): Use std::vector.
9977
4c404b8b
TT
99782017-04-12 Tom Tromey <tom@tromey.com>
9979
9980 * symfile.c (objfilep): Remove typedef.
9981 (reread_symbols): Use a std::vector.
9982
156d9eab
TT
99832017-04-12 Tom Tromey <tom@tromey.com>
9984
9985 * mi/mi-main.c (exec_direction_forward): Remove.
9986 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
9987 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
9988 scoped_restore.
9989 * guile/guile.c (guile_repl_command, guile_command)
9990 (gdbscm_execute_gdb_command): Use scoped_restore.
9991 * go-exp.y (go_parse): Use scoped_restore.
9992 * d-exp.y (d_parse): Use scoped_restore.
9993 * cli/cli-decode.c (cmd_func): Use scoped_restore.
9994 * c-exp.y (c_parse): Use scoped_restore.
9995
4d89769a
TT
99962017-04-12 Tom Tromey <tom@tromey.com>
9997
9998 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
9999 (mi_parse): Update return type.
10000 (mi_parse_free): Remove.
10001 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
10002 (mi_parse::~mi_parse): Rename from mi_parse_free.
10003 (mi_parse_cleanup): Remove.
10004 (mi_parse): Return a unique_ptr. Use new.
10005 * mi/mi-main.c (mi_execute_command): Update.
10006
4b217cc7
TT
100072017-04-12 Tom Tromey <tom@tromey.com>
10008
10009 * location.c (explicit_location_lex_one): Return a
10010 unique_xmalloc_ptr.
10011 (string_to_explicit_location): Update. Remove cleanups.
10012
59d3651b
TT
100132017-04-12 Tom Tromey <tom@tromey.com>
10014
10015 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
10016 (compare_value_and_voffset): Change type. Update.
10017 (compute_vtable_size): Change type of "offset_vec".
10018 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
10019 (gnuv3_get_typeid): Remove extraneous declaration.
10020
b24b0d6c
TT
100212017-04-12 Tom Tromey <tom@tromey.com>
10022
10023 * charset.h (wchar_iterator): Fix comment.
10024
80a3b8c5
TT
100252017-04-12 Tom Tromey <tom@tromey.com>
10026
10027 * charset.c (iconv_wrapper): New class.
10028 (cleanup_iconv): Remove.
10029 (convert_between_encodings): Use it.
10030
c83dd867
TT
100312017-04-12 Tom Tromey <tom@tromey.com>
10032
10033 * symfile.h (increment_reading_symtab): Update type.
10034 * symfile.c (decrement_reading_symtab): Remove.
10035 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
10036 * psymtab.c (psymtab_to_symtab): Update.
10037 * dwarf2read.c (dw2_instantiate_symtab): Update.
10038
0e8621a0
TT
100392017-04-12 Tom Tromey <tom@tromey.com>
10040
10041 * jit.c (struct jit_reader): Declare separately. Add constructor
10042 and destructor. Change type of "handle".
10043 (loaded_jit_reader): Define separately.
10044 (jit_reader_load): Update. New "new".
10045 (jit_reader_unload_command): Use "delete".
10046 * gdb-dlfcn.h (struct dlclose_deleter): New.
10047 (gdb_dlhandle_up): New typedef.
10048 (gdb_dlopen, gdb_dlsym): Update types.
10049 (gdb_dlclose): Remove.
10050 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
10051 (gdb_dlsym): Change type of "handle".
10052 (make_cleanup_dlclose): Remove.
10053 (dlclose_deleter::operator()): Rename from gdb_dlclose.
10054 * compile/compile-c-support.c (load_libcc): Update.
10055
67d89901
TT
100562017-04-12 Tom Tromey <tom@tromey.com>
10057
10058 * symtab.h (find_pcs_for_symtab_line): Change return type.
10059 * symtab.c (find_pcs_for_symtab_line): Change return type.
10060 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
10061 type of "vec". Update.
10062 (ltpy_get_pcs_for_line): Update.
10063 * linespec.c (decode_digits_ordinary): Update.
10064
93921405
TT
100652017-04-12 Tom Tromey <tom@tromey.com>
10066
10067 * tracepoint.c (actions_command): Update.
10068 * python/python.c (python_command, python_interactive_command):
10069 Update.
10070 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
10071 * guile/guile.c (guile_command): Update.
10072 * defs.h (read_command_lines, read_command_lines_1): Return
10073 command_line_up.
10074 (command_lines_deleter): New struct.
10075 (command_line_up): New typedef.
10076 * compile/compile.c (compile_code_command)
10077 (compile_print_command): Update.
10078 * cli/cli-script.h (get_command_line, copy_command_lines): Return
10079 command_line_up.
10080 (make_cleanup_free_command_lines): Remove.
10081 * cli/cli-script.c (get_command_line, read_command_lines_1)
10082 (copy_command_lines): Return command_line_up.
10083 (while_command, if_command, read_command_lines, define_command)
10084 (document_command): Update.
10085 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
10086 Remove.
10087 * breakpoint.h (breakpoint_set_commands): Change type of
10088 "commands".
10089 * breakpoint.c (breakpoint_set_commands): Change type of
10090 "commands". Update.
10091 (do_map_commands_command, update_dprintf_command_list)
10092 (create_tracepoint_from_upload): Update.
10093
ffc2605c
TT
100942017-04-12 Tom Tromey <tom@tromey.com>
10095
10096 * tracepoint.c (scope_info): Update.
10097 * spu-tdep.c (spu_catch_start): Update.
10098 * python/python.c (gdbpy_decode_line): Update.
10099 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
10100 * python/py-breakpoint.c (bppy_init): Update.
10101 * probe.c (parse_probes): Update.
10102 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
10103 * location.h (event_location_deleter): New struct.
10104 (event_location_up): New typedef.
10105 (new_linespec_location, new_address_location, new_probe_location)
10106 (new_explicit_location, copy_event_location)
10107 (string_to_event_location, string_to_event_location_basic)
10108 (string_to_explicit_location): Update return type.
10109 (make_cleanup_delete_event_location): Remove.
10110 * location.c (new_linespec_location, new_address_location)
10111 (new_probe_location, new_explicit_location, copy_event_location):
10112 Return event_location_up.
10113 (delete_event_location_cleanup)
10114 (make_cleanup_delete_event_location): Remove.
10115 (string_to_explicit_location, string_to_event_location_basic)
10116 (string_to_event_location): Return event_location_up.
10117 * linespec.c (canonicalize_linespec, event_location_to_sals)
10118 (decode_line_with_current_source)
10119 (decode_line_with_last_displayed, decode_objc): Update.
10120 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
10121 * completer.c (location_completer): Update.
10122 * cli/cli-cmds.c (edit_command, list_command): Update.
10123 * breakpoint.c (create_overlay_event_breakpoint)
10124 (create_longjmp_master_breakpoint)
10125 (create_std_terminate_master_breakpoint)
10126 (create_exception_master_breakpoint)
10127 (create_thread_event_breakpoint): Update.
10128 (init_breakpoint_sal): Update. Remove some dead code.
10129 (create_breakpoint_sal): Change type of "location". Update.
10130 (create_breakpoints_sal, create_breakpoint, break_command_1)
10131 (dprintf_command, break_range_command, until_break_command)
10132 (init_ada_exception_breakpoint)
10133 (strace_marker_create_sals_from_location)
10134 (update_static_tracepoint, trace_command, ftrace_command)
10135 (strace_command, create_tracepoint_from_upload): Update.
10136 * break-catch-throw.c (re_set_exception_catchpoint): Update.
10137 * ax-gdb.c (agent_command_1): Update.
10138
8f10c932
PA
101392017-04-12 Pedro Alves <palves@redhat.com>
10140
10141 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
10142 * configure.tgt: Handle i[34567]86-*-go32* and
10143 i[34567]86-*-msdosdjgpp*.
10144 * i386-tdep.c (i386_svr4_reg_to_regnum):
10145 Make extern.
10146 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
10147 i386-go32-tdep.c.
10148 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
10149 * i386-go32-tdep.c: New file.
10150 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
10151 declarations.
10152
0a31ccfb
SM
101532017-04-12 Simon Marchi <simon.marchi@ericsson.com>
10154
10155 * aix-thread.c (pd_status2str): Change return type to const char *.
10156
e9bb3fbb
PA
101572017-04-12 Pedro Alves <palves@redhat.com>
10158
10159 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
10160 calls to set_gdbarch_gnu_triplet_regexp.
10161
53375380
PA
101622017-04-12 Pedro Alves <palves@redhat.com>
10163
10164 PR gdb/21323
10165 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
10166 New enum value.
10167 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
10168 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
10169 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
10170 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
10171 * gdbarch.h, gdbarch.c: Regenerate.
10172 * aarch64-tdep.c (aarch64_gdbarch_init): Override
10173 gdbarch_wchar_bit and gdbarch_wchar_signed.
10174 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
10175 * arm-tdep.c (arm_gdbarch_init): Likewise.
10176 * avr-tdep.c (avr_gdbarch_init): Likewise.
10177 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
10178 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
10179 * i386-tdep.c (i386_go32_init_abi): Likewise.
10180 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
10181 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
10182 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
10183 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
10184 * sh-tdep.c (sh_gdbarch_init): Likewise.
10185 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
10186 * sparc64-tdep.c (sparc64_init_abi): Likewise.
10187 * windows-tdep.c (windows_init_abi): Likewise.
10188 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
10189
53e710ac
PA
101902017-04-12 Pedro Alves <palves@redhat.com>
10191
10192 PR c++/21323
10193 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
10194 cplus_primitive_type_char32_t>: New enum values.
10195 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
10196 and cplus_primitive_type_char32_t.
10197 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
10198 32, use the archtecture's built-in type for char16_t and char32_t,
10199 respectively. Otherwise, fallback to init_integer_type as before,
10200 but make the type unsigned, and issue a complaint.
10201 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
10202
ab0538b8
AH
102032017-04-12 Alan Hayward <alan.hayward@arm.com>
10204
5e0e0422 10205 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
ab0538b8
AH
10206 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
10207
5430098f
SDJ
102082017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
10209
10210 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
10211 'const char *'.
10212
7c5ded6a
SDJ
102132017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
10214
10215 * common/common-utils.c (free_vector_argv): New function.
10216 * common/common-utils.h: Include <vector>.
10217 (free_vector_argv): New prototype.
10218 * darwin-nat.c (darwin_create_inferior): Rewrite function
10219 prototype in order to constify "exec_file" and accept a
10220 "std::string" for "allargs".
10221 * fork-child.c: Include <vector>.
10222 (breakup_args): Rewrite function, using C++.
10223 (fork_inferior): Rewrite function header, constify "exec_file_arg"
10224 and accept "std::string" for "allargs". Update the code to
10225 calculate "argv" based on "allargs". Update calls to "exec_fun"
10226 and "execvp".
10227 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
10228 order to constify "exec_file" and accept a "std::string" for
10229 "allargs".
10230 * go32-nat.c (go32_create_inferior): Likewise.
10231 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
10232 * infcmd.c (run_command_1): Constify "exec_file". Use
10233 "std::string" for inferior arguments.
10234 * inferior.h (fork_inferior): Update prototype.
10235 * linux-nat.c (linux_nat_create_inferior): Rewrite function
10236 prototype in order to constify "exec_file" and accept a
10237 "std::string" for "allargs".
10238 * nto-procfs.c (procfs_create_inferior): Likewise.
10239 * procfs.c (procfs_create_inferior): Likewise.
10240 * remote-sim.c (gdbsim_create_inferior): Likewise.
10241 * remote.c (extended_remote_run): Update code to accept
10242 "std::string" as argument.
10243 (extended_remote_create_inferior): Rewrite function prototype in
10244 order to constify "exec_file" and accept a "std::string" for
10245 "allargs".
10246 * rs6000-nat.c (super_create_inferior): Likewise.
10247 (rs6000_create_inferior): Likewise.
10248 * target.h (struct target_ops) <to_create_inferior>: Likewise.
10249 * windows-nat.c (windows_create_inferior): Likewise.
10250
ae0eee42
PA
102512017-04-11 Pedro Alves <palves@redhat.com>
10252
10253 * thread.c: Fix whitespace throughout.
10254
a6acac06
PR
102552017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
10256
10257 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
10258
64403bd1
AH
102592017-04-11 Alan Hayward <alan.hayward@arm.com>
10260
10261 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
10262
a5bef50f
SDJ
102632017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
10264
10265 PR gdb/21364
10266 * osdata.c (info_osdata): Check if 'type' is an empty string
10267 instead of NULL.
10268
9295a5a9
PA
102692017-04-10 Pedro Alves <palves@redhat.com>
10270
10271 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
10272 (ptid_to_global_thread_id, in_thread_list)
10273 (do_captured_list_thread_ids, set_resumed, set_running)
10274 (set_executing, set_stop_requested, finish_thread_state)
10275 (validate_registers_access, can_access_registers_ptid)
10276 (print_thread_info_1, switch_to_thread)
10277 (do_restore_current_thread_cleanup)
10278 (make_cleanup_restore_current_thread, thread_command)
10279 (thread_name_command): Use operator== instead of ptid_equal.
10280
996812e3
PA
102812017-04-10 Pedro Alves <palves@redhat.com>
10282
10283 * thread.c (struct current_thread_cleanup) <next>: Delete field.
10284 (current_thread_cleanup_chain): Delete.
10285 (restore_current_thread_cleanup_dtor)
10286 (make_cleanup_restore_current_thread): Remove references to
10287 current_thread_cleanup_chain.
10288
845b344f
AH
102892017-04-10 Alan Hayward <alan.hayward@arm.com>
10290
10291 * msp430-tdep.c (msp430_pseudo_register_read): Never return
10292 REG_UNKNOWN.
10293
803bdfe4
YQ
102942017-04-10 Yao Qi <yao.qi@linaro.org>
10295
10296 PR gdb/19942
10297 * gdbthread.h (thread_info::deletable): New method.
10298 (thread_info::incref): New method.
10299 (thread_info::decref): New method.
10300 (thread_info::refcount): Move it to private.
10301 * infrun.c (save_stop_context): Call inc_refcount.
10302 (release_stop_context_cleanup): Likewise.
10303 * thread.c (set_thread_exited): New function.
10304 (init_thread_list): Delete "tp" only it is deletable, otherwise
10305 call set_thread_exited.
10306 (delete_thread_1): Call set_thread_exited.
10307 (current_thread_cleanup) <inferior_pid>: Remove.
10308 <thread>: New field.
10309 (restore_current_thread_ptid_changed): Removed.
10310 (do_restore_current_thread_cleanup): Adjust.
10311 (restore_current_thread_cleanup_dtor): Don't call
10312 find_thread_ptid.
10313 (set_thread_refcount): Use dec_refcount.
10314 (make_cleanup_restore_current_thread): Adjust.
10315 (thread_apply_all_command): Call inc_refcount.
10316 (_initialize_thread): Don't call
10317 observer_attach_thread_ptid_changed.
10318
8c25b497
YQ
103192017-04-10 Yao Qi <yao.qi@linaro.org>
10320
10321 * thread.c (delete_thread_1): Hoist code on marking thread as
10322 exited.
10323
8473b447
SM
103242017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10325
10326 * windows-nat.c (windows_detach): Initialize ptid with
10327 minus_one_ptid.
10328
6670ec13
SM
103292017-04-07 Simon Marchi <simon.marchi@ericsson.com>
10330
10331 * unittests/ptid-selftests.c: Fix erroneous assert messages.
10332
ba2f91bb
AH
103332017-04-07 Alan Hayward <alan.hayward@arm.com>
10334
10335 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
10336 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
10337 (bfin_pseudo_register_write): Likewise
10338
436252de
SM
103392017-04-06 Simon Marchi <simon.marchi@ericsson.com>
10340
10341 * common/ptid.h (struct ptid): Change to...
10342 (class ptid_t): ... this.
10343 <ptid_t>: New constructors.
10344 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
10345 matches>: New methods.
10346 <make_null, make_minus_one>: New static methods.
10347 <pid>: Rename to...
10348 <m_pid>: ...this.
10349 <lwp>: Rename to...
10350 <m_lwp>: ...this.
10351 <tid>: Rename to...
10352 <m_tid>: ...this.
10353 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
10354 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
10355 as references, move comment to class ptid_t.
10356 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
10357 ptid_t static methods.
10358 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
10359 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
10360 Take ptid arguments as references, implement using ptid_t methods.
10361 * unittests/ptid-selftests.c: New file.
10362 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10363 unittests/ptid-selftests.c.
10364 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
10365
0dedf377
TP
103662017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
10367
10368 * python/python.c (python_run_simple_file): Cast mode literal to
10369 non-const char pointer as expected by PyFile_FromString.
10370
4e9868d4
SM
103712017-04-05 Simon Marchi <simon.marchi@ericsson.com>
10372
10373 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
10374 minus_one_ptid and null_ptid.
10375
9bf2a700
PA
103762017-04-05 Pedro Alves <palves@redhat.com>
10377
10378 * warning.m4 (build_warnings): Remove -Wno-write-strings.
10379 * configure: Regenerate.
10380
a121b7c1
PA
103812017-04-05 Pedro Alves <palves@redhat.com>
10382
10383 * ada-exp.y (yyerror): Constify.
10384 * ada-lang.c (bound_name, get_selections)
10385 (ada_variant_discrim_type)
10386 (ada_variant_discrim_name, ada_value_struct_elt)
10387 (ada_lookup_struct_elt_type, is_unchecked_variant)
10388 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
10389 (catch_ada_exception_command_split)
10390 (catch_ada_assert_command_split, catch_assert_command)
10391 (ada_op_name): Constify.
10392 * ada-lang.h (ada_yyerror, get_selections)
10393 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
10394 * arc-tdep.c (arc_print_frame_cache): Constify.
10395 * arm-tdep.c (arm_skip_stub): Constify.
10396 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
10397 (gen_aggregate_elt_ref): Constify.
10398 * bcache.c (print_bcache_statistics): Constify.
10399 * bcache.h (print_bcache_statistics): Constify.
10400 * break-catch-throw.c (catch_exception_command_1):
10401 * breakpoint.c (struct ep_type_description::description):
10402 Constify.
10403 (add_solib_catchpoint): Constify.
10404 (catch_fork_command_1): Add cast.
10405 (add_catch_command): Constify.
10406 * breakpoint.h (add_catch_command, add_solib_catchpoint):
10407 Constify.
10408 * bsd-uthread.c (bsd_uthread_state): Constify.
10409 * buildsym.c (patch_subfile_names): Constify.
10410 * buildsym.h (next_symbol_text_func, patch_subfile_names):
10411 Constify.
10412 * c-exp.y (yyerror): Constify.
10413 (token::oper): Constify.
10414 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
10415 * c-varobj.c (cplus_describe_child): Constify.
10416 * charset.c (find_charset_names): Add cast.
10417 (find_charset_names): Constify array and add const_cast.
10418 * cli/cli-cmds.c (complete_command, cd_command): Constify.
10419 (edit_command): Constify.
10420 * cli/cli-decode.c (lookup_cmd): Constify.
10421 * cli/cli-dump.c (dump_memory_command, dump_value_command):
10422 Constify.
10423 (struct dump_context): Constify.
10424 (add_dump_command, restore_command): Constify.
10425 * cli/cli-script.c (get_command_line): Constify.
10426 * cli/cli-script.h (get_command_line): Constify.
10427 * cli/cli-utils.c (check_for_argument): Constify.
10428 * cli/cli-utils.h (check_for_argument): Constify.
10429 * coff-pe-read.c (struct read_pe_section_data): Constify.
10430 * command.h (lookup_cmd): Constify.
10431 * common/print-utils.c (decimal2str): Constify.
10432 * completer.c (gdb_print_filename): Constify.
10433 * corefile.c (set_gnutarget): Constify.
10434 * cp-name-parser.y (yyerror): Constify.
10435 * cp-valprint.c (cp_print_class_member): Constify.
10436 * cris-tdep.c (cris_register_name, crisv32_register_name):
10437 Constify.
10438 * d-exp.y (yyerror): Constify.
10439 (struct token::oper): Constify.
10440 * d-lang.h (d_yyerror): Constify.
10441 * dbxread.c (struct header_file_location::name): Constify.
10442 (add_old_header_file, add_new_header_file, last_function_name)
10443 (dbx_next_symbol_text, add_bincl_to_list)
10444 (find_corresponding_bincl_psymtab, set_namestring)
10445 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
10446 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
10447 * defs.h (command_line_input, print_address_symbolic)
10448 (deprecated_readline_begin_hook): Constify.
10449 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
10450 Constify.
10451 * event-top.c (handle_line_of_input): Constify and add cast.
10452 * exceptions.c (catch_errors): Constify.
10453 * exceptions.h (catch_errors): Constify.
10454 * expprint.c (print_subexp_standard, op_string, op_name)
10455 (op_name_standard, dump_raw_expression, dump_raw_expression):
10456 * expression.h (op_name, op_string, dump_raw_expression):
10457 Constify.
10458 * f-exp.y (yyerror): Constify.
10459 (struct token::oper): Constify.
10460 (struct f77_boolean_val::name): Constify.
10461 * f-lang.c (f_word_break_characters): Constify.
10462 * f-lang.h (f_yyerror): Constify.
10463 * fork-child.c (fork_inferior): Add cast.
10464 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
10465 (new_variant): Constify.
10466 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
10467 * gdbarch.c: Regenerate.
10468 * gdbcore.h (set_gnutarget): Constify.
10469 * go-exp.y (yyerror): Constify.
10470 (token::oper): Constify.
10471 * go-lang.h (go_yyerror): Constify.
10472 * go32-nat.c (go32_sysinfo): Constify.
10473 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
10474 * guile/scm-cmd.c (cmdscm_function): Constify.
10475 * guile/scm-param.c (pascm_param_value): Constify.
10476 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
10477 (h8300sx_register_name): Constify.
10478 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
10479 Constify.
10480 * ia64-tdep.c (ia64_register_names): Constify.
10481 * infcmd.c (construct_inferior_arguments): Constify.
10482 (path_command, attach_post_wait): Constify.
10483 * language.c (show_range_command, show_case_command)
10484 (unk_lang_error): Constify.
10485 * language.h (language_defn::la_error)
10486 (language_defn::la_name_of_this): Constify.
10487 * linespec.c (decode_line_2): Constify.
10488 * linux-thread-db.c (thread_db_err_str): Constify.
10489 * lm32-tdep.c (lm32_register_name): Constify.
10490 * m2-exp.y (yyerror): Constify.
10491 * m2-lang.h (m2_yyerror): Constify.
10492 * m32r-tdep.c (m32r_register_names): Constify and make static.
10493 * m68hc11-tdep.c (m68hc11_register_names): Constify.
10494 * m88k-tdep.c (m88k_register_name): Constify.
10495 * macroexp.c (appendmem): Constify.
10496 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
10497 (upgrade_type, parse_external, parse_partial_symbols)
10498 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
10499 (new_symbol): Constify.
10500 * memattr.c (mem_info_command): Constify.
10501 * mep-tdep.c (register_name_from_keyword): Constify.
10502 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
10503 Constify.
10504 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
10505 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
10506 * mi/mi-main.c (captured_mi_execute_command): Constify and add
10507 cast.
10508 (mi_execute_async_cli_command): Constify.
10509 * mips-tdep.c (mips_register_name): Constify.
10510 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
10511 (am33_register_name, am33_2_register_name)
10512 * moxie-tdep.c (moxie_register_names): Constify.
10513 * nat/linux-osdata.c (osdata_type): Constify fields.
10514 * nto-tdep.c (nto_parse_redirection): Constify.
10515 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
10516 (lookup_child_selector): Constify.
10517 (objc_methcall::name): Constify.
10518 * objc-lang.h (lookup_objc_class, lookup_child_selector)
10519 (lookup_struct_typedef): Constify.
10520 * objfiles.c (pc_in_section): Constify.
10521 * objfiles.h (pc_in_section): Constify.
10522 * p-exp.y (struct token::oper): Constify.
10523 (yyerror): Constify.
10524 * p-lang.h (pascal_yyerror): Constify.
10525 * parser-defs.h (op_name_standard): Constify.
10526 (op_print::string): Constify.
10527 (exp_descriptor::op_name): Constify.
10528 * printcmd.c (print_address_symbolic): Constify.
10529 * psymtab.c (print_partial_symbols): Constify.
10530 * python/py-breakpoint.c (stop_func): Constify.
10531 (bppy_get_expression): Constify.
10532 * python/py-cmd.c (cmdpy_completer::name): Constify.
10533 (cmdpy_function): Constify.
10534 * python/py-event.c (evpy_add_attribute)
10535 (gdbpy_initialize_event_generic): Constify.
10536 * python/py-event.h (evpy_add_attribute)
10537 (gdbpy_initialize_event_generic): Constify.
10538 * python/py-evts.c (add_new_registry): Constify.
10539 * python/py-finishbreakpoint.c (outofscope_func): Constify.
10540 * python/py-framefilter.c (get_py_iter_from_func): Constify.
10541 * python/py-inferior.c (get_buffer): Add cast.
10542 * python/py-param.c (parm_constant::name): Constify.
10543 * python/py-unwind.c (fprint_frame_id): Constify.
10544 * python/python.c (gdbpy_parameter_value): Constify.
10545 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
10546 * remote.c (memory_packet_config::name): Constify.
10547 (show_packet_config_cmd, remote_write_bytes)
10548 (remote_buffer_add_string):
10549 * reverse.c (exec_reverse_once): Constify.
10550 * rs6000-tdep.c (variant::name, variant::description): Constify.
10551 * rust-exp.y (rustyyerror): Constify.
10552 * rust-lang.c (rust_op_name): Constify.
10553 * rust-lang.h (rustyyerror): Constify.
10554 * serial.h (serial_ops::name): Constify.
10555 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
10556 (sh_sh3e_register_name, sh_sh2e_register_name)
10557 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
10558 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
10559 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
10560 (sh_sh4al_dsp_register_name): Constify.
10561 * sh64-tdep.c (sh64_register_name): Constify.
10562 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
10563 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
10564 * stabsread.c (patch_block_stabs, read_type_number)
10565 (ref_map::stabs, ref_add, process_reference)
10566 (symbol_reference_defined, define_symbol, define_symbol)
10567 (error_type, read_type, read_member_functions, read_cpp_abbrev)
10568 (read_one_struct_field, read_struct_fields, read_baseclasses)
10569 (read_tilde_fields, read_struct_type, read_array_type)
10570 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
10571 (read_huge_number, read_range_type, read_args, common_block_start)
10572 (find_name_end): Constify.
10573 * stabsread.h (common_block_start, define_symbol)
10574 (process_one_symbol, symbol_reference_defined, ref_add):
10575 * symfile.c (get_section_index, add_symbol_file_command):
10576 * symfile.h (get_section_index): Constify.
10577 * target-descriptions.c (tdesc_type::name): Constify.
10578 (tdesc_free_type): Add cast.
10579 * target.c (find_default_run_target):
10580 (add_deprecated_target_alias, find_default_run_target)
10581 (target_announce_detach): Constify.
10582 (do_option): Constify.
10583 * target.h (add_deprecated_target_alias): Constify.
10584 * thread.c (print_thread_info_1): Constify.
10585 * top.c (deprecated_readline_begin_hook, command_line_input):
10586 Constify.
10587 (init_main): Add casts.
10588 * top.h (handle_line_of_input): Constify.
10589 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
10590 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
10591 (tfind_command): Rename to ...
10592 (tfind_command_1): ... this and constify.
10593 (tfind_command): New function.
10594 (tfind_end_command, tfind_start_command): Adjust.
10595 (encode_source_string): Constify.
10596 * tracepoint.h (encode_source_string): Constify.
10597 * tui/tui-data.c (tui_partial_win_by_name): Constify.
10598 * tui/tui-data.h (tui_partial_win_by_name): Constify.
10599 * tui/tui-source.c (tui_set_source_content_nil): Constify.
10600 * tui/tui-source.h (tui_set_source_content_nil): Constify.
10601 * tui/tui-win.c (parse_scrolling_args): Constify.
10602 * tui/tui-windata.c (tui_erase_data_content): Constify.
10603 * tui/tui-windata.h (tui_erase_data_content): Constify.
10604 * tui/tui-winsource.c (tui_erase_source_content): Constify.
10605 * tui/tui.c (tui_enable): Add cast.
10606 * utils.c (defaulted_query): Constify.
10607 (init_page_info): Add cast.
10608 (puts_debug, subset_compare): Constify.
10609 * utils.h (subset_compare): Constify.
10610 * varobj.c (varobj_format_string): Constify.
10611 * varobj.h (varobj_format_string): Constify.
10612 * vax-tdep.c (vax_register_name): Constify.
10613 * windows-nat.c (windows_detach): Constify.
10614 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
10615 * xml-support.c (gdb_xml_end_element): Constify.
10616 * xml-tdesc.c (tdesc_start_reg): Constify.
10617 * xstormy16-tdep.c (xstormy16_register_name): Constify.
10618 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
10619 * xtensa-tdep.h (xtensa_register_t::name): Constify.
10620
995816ba
PA
106212017-04-05 Pedro Alves <palves@redhat.com>
10622
10623 * proc-api.c (struct trans): Constify.
10624 (procfs_note): Constify.
10625 * proc-events.c (struct trans, syscall_table):
10626 * proc-flags.c (struct trans): Constify.
10627 * proc-utils.h (procfs_note): Constify.
10628 * proc-why.c (struct trans): Constify.
10629 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
10630 (procfs_detach): Constify.
10631 * sol-thread.c (struct string_map): Constify.
10632 (td_err_string, td_state_string): Constify.
10633
3e83a920
PA
106342017-04-05 Pedro Alves <palves@redhat.com>
10635
10636 * proc-api.c (procfs_filename): Don't initialize
10637 procfs_filename.
10638 (prepare_to_trace): Assume procfs_filename is non-NULL.
10639 (_initialize_proc_api): Give procfs_filename a default value here.
10640
63160a43
PA
106412017-04-05 Pedro Alves <palves@redhat.com>
10642
10643 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
10644 'cond_string' parameter.
10645 (extract_exception_regexp): Constify 'string' parameter.
10646 (catch_exception_command_1): Constify.
10647 * breakpoint.c (init_catchpoint)
10648 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
10649 parameter.
10650 (ep_parse_optional_if_clause, catch_fork_command_1)
10651 (catch_exec_command_1): Constify.
10652 * breakpoint.h (init_catchpoint): Constify 'cond_string'
10653 parameter.
10654 (ep_parse_optional_if_clause): Constify.
10655 * cli/cli-utils.c (remove_trailing_whitespace)
10656 (check_for_argument): Constify.
10657 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
10658 non-const overload.
10659 (check_for_argument): Likewise.
10660
9b2eba3d
PA
106612017-04-05 Pedro Alves <palves@redhat.com>
10662
10663 * event-top.c (command_line_handler): Add cast to execute_command
10664 call.
10665 * record-btrace.c (cmd_record_btrace_bts_start)
10666 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
10667 (cmd_record_btrace_start): Add cast to execute_command call.
10668 * record-full.c (record_full_goto_insn):
10669 * record.c (record_start, record_stop): Add cast to
10670 execute_command_to_string calls.
10671 (cmd_record_start): Add cast to execute_command calls.
10672
2adadf51
PA
106732017-04-05 Pedro Alves <palves@redhat.com>
10674
10675 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
10676 static inline function.
10677 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
10678 array and use gdb_PyArg_ParseTupleAndKeywords.
10679 * python/py-cmd.c (cmdpy_init): Likewise.
10680 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
10681 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
10682 (infpy_search_memory): Likewise.
10683 * python/py-objfile.c (objfpy_add_separate_debug_file)
10684 (gdbpy_lookup_objfile): Likewise.
10685 * python/py-symbol.c (gdbpy_lookup_symbol)
10686 (gdbpy_lookup_global_symbol): Likewise.
10687 * python/py-type.c (gdbpy_lookup_type): Likewise.
10688 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
10689 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
10690 Likewise.
10691
0d1f4ceb
PA
106922017-04-05 Pedro Alves <palves@redhat.com>
10693
10694 * python/python-internal.h (gdb_PyGetSetDef): New type.
10695 * python/py-block.c (block_object_getset)
10696 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
10697 * python/py-event.c (event_object_getset)
10698 (finish_breakpoint_object_getset): Likewise.
10699 * python/py-inferior.c (inferior_object_getset): Likewise.
10700 * python/py-infthread.c (thread_object_getset): Likewise.
10701 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
10702 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
10703 * python/py-objfile.c (objfile_getset): Likewise.
10704 * python/py-progspace.c (pspace_getset): Likewise.
10705 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
10706 Likewise.
10707 * python/py-record.c (recpy_record_getset): Likewise.
10708 * python/py-symbol.c (symbol_object_getset): Likewise.
10709 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
10710 Likewise.
10711 * python/py-type.c (type_object_getset, field_object_getset):
10712 Likewise.
10713 * python/py-value.c (value_object_getset): Likewise.
10714
4d759979
PA
107152017-04-05 Pedro Alves <palves@redhat.com>
10716
10717 * python/python-internal.h (gdb_PyObject_CallMethod)
10718 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
10719 New functions.
10720 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
10721 (PySys_GetObject, PySys_SetPath): New macros.
10722
fdf9e36f
PA
107232017-04-05 Pedro Alves <palves@redhat.com>
10724
10725 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
10726 info_osdata_command.
10727 * osdata.c (info_osdata_command): Rename to ...
10728 (info_osdata): ... this. Constify 'type' parameter, and remove
10729 the 'from_tty' parameter. Accept NULL TYPE.
10730 (info_osdata_command): New function.
10731 * osdata.h (info_osdata_command): Remove declaration.
10732 (info_osdata): New declaration.
10733
9f33b8b7
PA
107342017-04-05 Pedro Alves <palves@redhat.com>
10735
10736 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
10737 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
10738 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
10739 parameter.
10740 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
10741 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
10742 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
10743 parameter.
10744 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
10745 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
10746 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
10747 (mi_cmd_file_list_exec_source_files)
10748 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
10749 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
10750 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
10751 parameter.
10752 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
10753 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
10754 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
10755 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
10756 (mi_cmd_stack_info_frame): Constify 'command' parameter.
10757 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
10758 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
10759 'command' parameter.
10760 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
10761 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
10762 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
10763 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
10764 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
10765 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
10766 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
10767 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
10768 (mi_cmd_var_set_update_range): Constify 'command' parameter.
10769 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
10770 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
10771 parameter.
10772 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
10773 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
10774 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
10775 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
10776 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
10777 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
10778 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
10779 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
10780 (mi_cmd_data_list_changed_registers)
10781 (mi_cmd_data_write_register_values)
10782 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
10783 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
10784 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
10785 (mi_cmd_list_features, mi_cmd_list_target_features)
10786 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
10787 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
10788 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
10789 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
10790 (mi_cmd_trace_frame_collected): Constify 'command'
10791 parameter.
10792 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
10793 'command' parameter.
10794
67cb5b2d
PA
107952017-04-05 Pedro Alves <palves@redhat.com>
10796
10797 * ada-lang.c (ada_completer_word_break_characters): Now a const
10798 array.
10799 (ada_get_gdb_completer_word_break_characters): Constify.
10800 * completer.c (gdb_completer_command_word_break_characters)
10801 (gdb_completer_file_name_break_characters)
10802 (gdb_completer_quote_characters): Now const arrays.
10803 (get_gdb_completer_quote_characters): Constify.
10804 (set_rl_completer_word_break_characters): New function.
10805 (set_gdb_completion_word_break_characters)
10806 (complete_line_internal): Use it.
10807 * completer.h (get_gdb_completer_quote_characters): Constify.
10808 (set_rl_completer_word_break_characters): Declare.
10809 * f-lang.c (f_word_break_characters): Constify.
10810 * language.c (default_word_break_characters): Constify.
10811 * language.h (language_defn::la_word_break_characters): Constify.
10812 (default_word_break_characters): Constify.
10813 * top.c (init_main): Use set_rl_completer_word_break_characters.
10814
7a114964
PA
108152017-04-05 Pedro Alves <palves@redhat.com>
10816
10817 * aix-thread.c (aix_thread_pid_to_str)
10818 (aix_thread_extra_thread_info): Constify.
10819 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
10820 * bsd-uthread.c (bsd_uthread_extra_thread_info)
10821 (bsd_uthread_pid_to_str): Constify.
10822 * corelow.c (core_pid_to_str): Constify.
10823 * darwin-nat.c (darwin_pid_to_str): Constify.
10824 * fbsd-nat.c (fbsd_pid_to_str): Constify.
10825 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
10826 Constify.
10827 * gnu-nat.c (gnu_pid_to_str): Constify.
10828 * go32-nat.c (go32_pid_to_str): Constify.
10829 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
10830 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
10831 * inferior.c (inferior_pid_to_str): Constify.
10832 * linux-nat.c (linux_nat_pid_to_str): Constify.
10833 * linux-tdep.c (linux_core_pid_to_str): Constify.
10834 * linux-thread-db.c (thread_db_pid_to_str)
10835 (thread_db_extra_thread_info): Constify.
10836 * nto-tdep.c (nto_extra_thread_info): Constify.
10837 * nto-tdep.h (nto_extra_thread_info): Constify.
10838 * obsd-nat.c (obsd_pid_to_str): Constify.
10839 * procfs.c (procfs_pid_to_str): Constify.
10840 * ravenscar-thread.c (ravenscar_extra_thread_info)
10841 (ravenscar_pid_to_str): Constify.
10842 * remote-sim.c (gdbsim_pid_to_str): Constify.
10843 * remote.c (remote_threads_extra_info, remote_pid_to_str):
10844 Constify.
10845 * sol-thread.c (solaris_pid_to_str): Constify.
10846 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
10847 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
10848 * target.c (default_pid_to_str, target_pid_to_str)
10849 (normal_pid_to_str, default_pid_to_str): Constify.
10850 * target.h (target_ops::to_pid_to_str)
10851 (target_ops::to_extra_thread_info): Constify.
10852 (target_pid_to_str, normal_pid_to_str): Constify.
10853 * windows-nat.c (windows_pid_to_str): Constify.
10854 * gdbarch.sh (core_pid_to_str): Constify.
10855 * target-delegates.c: Regenerate.
10856 * gdbarch.h, gdbarch.c: Regenerate.
10857
69bbf465
PA
108582017-04-05 Pedro Alves <palves@redhat.com>
10859
10860 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
10861 the memory of the temporary warning_pre_print override.
10862 * utils.c (warning_pre_print): Constify.
10863 * utils.h (warning_pre_print): Constify.
10864
be47f9e8
PA
108652017-04-05 Pedro Alves <palves@redhat.com>
10866
10867 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
10868 (shell_command): New function.
10869 (make_command): Use std::string.
10870 (init_cli_cmds): Register shell_command instead of shell_escape.
10871
bde6261a
PA
108722017-04-05 Pedro Alves <palves@redhat.com>
10873
10874 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
10875 * tracepoint.c (default_collect): Don't initialize.
10876
b38ef47f
PA
108772017-04-05 Pedro Alves <palves@redhat.com>
10878
10879 * macroexp.c (macro_buffer::shared): Now a bool.
10880 (init_buffer): Update.
10881 (init_shared_buffer): Constify 'addr' parameter.
10882 (substitute_args, expand, macro_expand, macro_expand_next): Remove
10883 casts.
10884
f995bbe8
PA
108852017-04-05 Pedro Alves <palves@redhat.com>
10886
10887 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
10888 * disasm.c (set_disassembler_options): Constify local.
10889 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
10890
4a596fe2
SDJ
108912017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
10892
10893 PR gdb/21352
10894 * tracefile.c (tsave_command): Fix argument parsing for '-r'
10895 option.
10896
2cad08ea
YQ
108972017-04-05 Yao Qi <yao.qi@linaro.org>
10898
10899 * frame.c (frame_unwind_register_unsigned): Call
10900 frame_unwind_register_value.
10901
55a98976
YQ
109022017-04-05 Yao Qi <yao.qi@linaro.org>
10903
10904 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
10905 Use gdb_test_multiple, and don't match anchor.
10906
4ac40124
PA
109072017-04-05 Pedro Alves <palves@redhat.com>
10908
10909 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
10910 (Write After Approval): Remove Simon Marchi.
10911
c053b654
PA
109122017-04-05 Pedro Alves <palves@redhat.com>
10913
10914 * common/gdb_optional.h (optional::optional): Make constexpr and
10915 initialize m_dummy.
10916
4c7bf4f9
JB
109172017-04-04 John Baldwin <jhb@FreeBSD.org>
10918
10919 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
10920 (amd64fbsd_jmp_buf_reg_offset): Remove.
10921 (amd64fbsd_supply_uthread): Remove function.
10922 (amd64fbsd_collect_uthread): Remove function.
10923 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
10924 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
10925 (x86_64-*-freebsd*): Remove bsd-uthread.o.
10926 (fbsd-nat.c): Update comment.
10927 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
10928 (i386fbsd_jmp_buf_reg_offset): Remove.
10929 (i386fbsd_supply_uthread): Remove function.
10930 (i386fbsd_collect_uthread): Remove function.
10931 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
10932
1e1a8bef
JB
109332017-04-04 John Baldwin <jhb@FreeBSD.org>
10934
10935 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
10936 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
10937 * NEWS: Mention that support for FreeBSD/alpha was removed.
10938 * alpha-fbsd-tdep.c: Delete file.
10939 * config/alpha/fbsd.mh: Delete file.
10940 * configure.host: Delete alpha*-*-freebsd* and
10941 alpha*-*-kfreebsd*-gnu.
10942 * configure.tgt: Delete alpha*-*-freebsd* and
10943 alpha*-*-kfreebsd*-gnu.
10944
49907934
JB
109452017-04-04 John Baldwin <jhb@FreeBSD.org>
10946
10947 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
10948 amd64bsd_store_inferior_registers): Use ptid from regcache.
10949
6f77053d
PA
109502017-04-04 Pedro Alves <palves@redhat.com>
10951
10952 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
10953 data fields, make them private and add "m_" prefixes.
10954 (lnp_state_machine::lnp_state_machine): New ctor.
10955 (record_line, check_line_address, handle_set_discriminator)
10956 (handle_set_address, handle_advance_pc, handle_special_opcode)
10957 (handle_advance_line, handle_set_file, handle_negate_stmt)
10958 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
10959 (end_sequence, advance_line): New methods.
10960 (m_gdbarch, m_record_lines_p): New fields.
10961 (lnp_reader_state): Delete.
10962 (dwarf_record_line): Rename to ...
10963 (lnp_state_machine::record_line): ... adjust.
10964 (init_lnp_state_machine): Delete.
10965 (lnp_state_machine::lnp_state_machine): New.
10966 (check_line_address): Rename to ...
10967 (lnp_state_machine::check_line_address): This.
10968 (dwarf_decode_lines_1): Remove reference to "reader_state".
10969 Adjust lnp_state_machine having a non-default ctor. Use bool.
10970 State machine internal state manipulation moved to
10971 lnp_state_machine methods.
10972
9c541725
PA
109732017-04-04 Pedro Alves <palves@redhat.com>
10974
10975 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10976 unittests/offset-type-selftests.c.
10977 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
10978 * common/offset-type.h: New file.
10979 * common/preprocessor.h: New file.
10980 * common/traits.h: New file.
10981 * common/valid-expr.h: New file.
10982 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
10983 sect_offset and cu_offset strong typedefs throughout.
10984 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
10985 typedefs throughout.
10986 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
10987 sect_offset and cu_offset strong typedefs throughout.
10988 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
10989 typedefs throughout.
10990 * gdbtypes.h: Include "common/offset-type.h".
10991 (cu_offset): Now an offset type (strong typedef) instead of a
10992 struct.
10993 (sect_offset): Likewise.
10994 (union call_site_parameter_u): Rename "param_offset" field to
10995 "param_cu_off".
10996 * unittests/offset-type-selftests.c: New file.
10997
ecfb656c
PA
109982017-04-04 Pedro Alves <palves@redhat.com>
10999
11000 * common/underlying.h: New file.
11001 * dwarf2read.c: Include "common/gdb_optional.h" and
11002 "common/underlying.h".
11003 (dir_index, file_name_index): New types.
11004 (file_entry): Use them.
11005 (file_entry::include): Use to_underlying.
11006 (line_header::add_file_name): Use dir_index.
11007 (read_formatted_entries): Use gdb::optional. Read form before
11008 writting to file_entry.
11009 (dwarf_decode_line_header): Use dir_index.
11010 (lnp_state_machine::current_file): Use to_underlying.
11011 (lnp_state_machine::file): Change type to file_name_index.
11012 (dwarf_record_line): Use to_underlying.
11013 (init_lnp_state_machine): Use file_name_index.
11014 (dwarf_decode_lines_1): Use dir_index and file_name_index.
11015
d194f1fe
PA
110162017-04-04 Pedro Alves <palves@redhat.com>
11017
11018 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
11019 operator bool, has_value and get methods.
11020
fff8551c
PA
110212017-04-04 Pedro Alves <palves@redhat.com>
11022
11023 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
11024 fields.
11025 (line_header): Initialize all data fields. Change type of
11026 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
11027 Change type of include_dirs to std::vector<const char *>. Remove
11028 num_include_dirs, include_dirs_size. Change type of file_names to
11029 std::vector<file_entry>. Remove num_file_names, file_names_size.
11030 (line_header::line_header): New.
11031 (line_header::add_include_dir, line_header::add_file_name): New
11032 methods.
11033 (line_header::include_dir_at): Remove NULL check.
11034 (line_header::file_name_at): Add const overload.
11035 (line_header_up): New unique_ptr typedef.
11036 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
11037 std::vector. Remove free_line_header call.
11038 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
11039 free_line_header call.
11040 (free_cu_line_header): Delete.
11041 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
11042 (setup_type_unit_groups): Use line_header_up instead of cleanups.
11043 Adjust to use std::vector.
11044 (free_line_header): Delete.
11045 (free_line_header_voidp): Use delete.
11046 (add_include_dir): Replace with ...
11047 (line_header::add_include_dir): ... this method. Use std::vector.
11048 (add_file_name): Replace with ...
11049 (line_header::add_file_name): ... this method. Use std::vector.
11050 (add_include_dir_stub): Delete.
11051 (read_formatted_entries): Remove memset.
11052 (dwarf_decode_line_header): Return a line_header_up instead of a
11053 raw pointer. Remove cleanup handling. Pass lambdas to
11054 read_formatted_entries. Adjust to use line_header methods.
11055 (dwarf_decode_lines_1): Adjust to use line_header methods.
11056 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
11057 use std::vector.
11058
d62a8ae2
SM
110592017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
11060
11061 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
11062 instead of struct ptid.
11063
db3a1dc7
AH
110642017-05-04 Alan Hayward <alan.hayward@arm.com>
11065
11066 * frame.c (get_frame_register_bytes): Unwind using value.
11067 (put_frame_register_bytes): Likewise.
11068
b1b45502
IB
110692017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
11070
11071 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
11072 aggregate-like.
11073
ec13808e
JK
110742017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
11075
11076 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
11077
12316564
YQ
110782017-03-29 Yao Qi <yao.qi@linaro.org>
11079
11080 * gdbthread.h (struct thread_info): Declare constructor and
11081 destructor. Add some in-class member initializers.
11082 * thread.c (free_thread): Remove.
11083 (init_thread_list): Call delete instead of free_thread.
11084 (new_thread): Call thread_info constructor.
11085 (thread_info::thread_info): New function.
11086 (thread_info::~thread_info): New function.
11087 (delete_thread_1): Call delete instead of free_thread.
11088 (make_cleanup_restore_current_thread): Move tp and frame to
11089 inner block.
11090
fe5f7374
AK
110912017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
11092
11093 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
11094 (arc_skip_prologue): Likewise.
11095 (arc_make_frame_cache): Likewise.
11096 (arc_pv_get_operand): New function.
11097 (arc_is_in_prologue): Likewise.
11098 (arc_analyze_prologue): Likewise.
11099 (arc_print_frame_cache): Likewise.
11100 (MAX_PROLOGUE_LENGTH): New constant.
11101
eea78757
AK
111022017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
11103
11104 * configure.tgt: Add arc-insn.o.
11105 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
11106 (dump_arc_instruction_command): New function.
11107 (arc_fprintf_disasm): Likewise.
11108 (arc_disassemble_info): Likewise.
11109 (arc_insn_get_operand_value): Likewise.
11110 (arc_insn_get_operand_value_signed): Likewise.
11111 (arc_insn_get_memory_base_reg): Likewise.
11112 (arc_insn_get_memory_offset): Likewise.
11113 (arc_insn_get_branch_target): Likewise.
11114 (arc_insn_dump): Likewise.
11115 (arc_insn_get_linear_next_pc): Likewise.
11116 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
11117 (arc_disassemble_info): Likewise.
11118 (arc_insn_get_branch_target): Likewise.
11119 (arc_insn_get_linear_next_pc): Likewise.
11120 * NEWS: Mention new "maint print arc arc-instruction".
11121
3be78afd
AK
111222017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
11123
11124 * arc-tdep (maintenance_print_arc_list): New variable.
11125 (maintenance_print_arc_command): New function.
11126
296ec4fa
AK
111272017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
11128
11129 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
11130 Add "limm" and "reserved".
11131 (arc_cannot_fetch_register, arc_cannot_store_register): Add
11132 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
11133 * arc-tdep.h (arc_regnum): Likewise.
11134
f74f865e
MF
111352017-03-27 Max Filippov <jcmvbkbc@gmail.com>
11136
11137 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
11138 for THREADPTR register.
11139 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
11140 register.
11141 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
11142 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
11143 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
11144
0d0bf81a
MF
111452017-03-27 Max Filippov <jcmvbkbc@gmail.com>
11146
11147 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
11148 registers above gdbarch_num_regs (gdbarch) as privileged in
11149 call0 ABI.
11150
0ce4291e
MF
111512017-03-27 Max Filippov <jcmvbkbc@gmail.com>
11152
11153 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
11154 for a single specified register or for all registers in
11155 a0_base..a0_base + C0_NREGS range.
11156 (supply_gregset_reg): Call regcache_raw_supply for a single
11157 specified register or for all registers in a0_base..a0_base +
11158 C0_NREGS range.
11159
c56054f9
MF
111602017-03-27 Max Filippov <jcmvbkbc@gmail.com>
11161
11162 * arch/xtensa.h (C0_NREGS): Add definition.
11163 * xtensa-tdep.c (C0_NREGS): Remove definition.
11164
a4398628
MF
111652017-03-27 Max Filippov <jcmvbkbc@gmail.com>
11166
11167 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
11168 Drop xtensa_default_isa initialization.
11169 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
11170
8c43009f
PA
111712017-03-27 Pedro Alves <palves@redhat.com>
11172
11173 * dwarf2read.c (file_entry) <dir_index>: Add comment.
11174 (file_entry::include_dir): New method.
11175 (line_header::include_dir_at, line_header::file_name_at): New
11176 methods.
11177 (setup_type_unit_groups, setup_type_unit_groups)
11178 (psymtab_include_file_name): Simplify using the new methods.
11179 (lnp_state_machine) <the_line_header>: New field.
11180 <file>: Add comment.
11181 (lnp_state_machine::current_file): New method.
11182 (dwarf_record_line): Simplify using the new methods.
11183 (init_lnp_state_machine): Initialize the "the_line_header" field.
11184 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
11185 Simplify using the new methods.
11186
a7e80b9e
PA
111872017-03-27 Pedro Alves <palves@redhat.com>
11188
11189 * cp-name-parser.y (make_empty): Delete.
11190 (demangler_special, nested_name, ptr_operator, array_indicator)
11191 (direct_declarator, declarator_1): Use fill_comp instead of
11192 make_empty.
11193
21047726
PA
111942017-03-27 Pedro Alves <palves@redhat.com>
11195
11196 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
11197 to ATTRIBUTE_PRINTF.
11198 * solib-target.c (library_list_start_list): Print "string" not
11199 "version".
11200 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
11201 gdb_xml_error call.
11202
d721ba37
PA
112032017-03-27 Pedro Alves <palves@redhat.com>
11204
11205 * dwarf2read.c (struct file_and_directory): New.
11206 (dwarf2_get_dwz_file): Adjust to use std::string.
11207 (dw2_get_file_names_reader): Adjust to use file_and_directory.
11208 (find_file_and_directory): Adjust to return a file_and_directory
11209 object.
11210 (read_file_scope): Adjust to use file_and_directory. Remove
11211 make_cleanup/do_cleanups calls.
11212 (open_and_init_dwp_file): Adjust to use std::string. Remove
11213 make_cleanup/do_cleanups calls.
11214 * python/python.c (do_start_initialization): Adjust to ldirname
11215 returning a std::string.
11216 * utils.c (ldirname): Now returns a std::string.
11217 * utils.h (ldirname): Change return type to std::string.
11218 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
11219 returning a std::string.
11220 * xml-tdesc.c (file_read_description_xml): Likewise.
11221
ed771251
AH
112222017-03-24 Alan Hayward <alan.hayward@arm.com>
11223
11224 * regcache.c (regcache_debug_print_register): New function.
11225 * regcache.h (regcache_debug_print_register): New declaration.
11226 * target.c (debug_print_register): Remove.
11227 (target_fetch_registers): Call regcache_debug_print_register.
11228 (target_store_registers): Likewise.
11229
568c1b9f
PB
112302017-03-24 Pádraig Brady <pbrady@fb.com>
11231
11232 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
11233 reference beyond the 'lh->include_dirs' array before accessing to
11234 it.
11235 (psymtab_include_file_name): Likewise.
11236 (dwarf_decode_lines_1): Likewise.
11237 (dwarf_decode_lines): Likewise.
11238 (file_file_name): Likewise.
11239
3e00d44f
SM
112402017-03-23 Simon Marchi <simon.marchi@ericsson.com>
11241
11242 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
11243 inferior_ptid.
11244 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
11245 ps_lsetfpregs): Likewise.
11246 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
11247 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
11248 ps_lsetfpregs): Likewise.
11249 * target.c (target_fetch_registers, target_store_registers):
11250 Remove asserts.
11251
077ae656
AH
112522017-03-23 Alan Hayward <alan.hayward@arm.com>
11253
11254 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
11255
1e2b521d
YQ
112562017-03-23 Yao Qi <yao.qi@linaro.org>
11257
11258 * aarch64-tdep.c (aarch64_process_record_test): Declare.
11259 (_initialize_aarch64_tdep): Register it.
11260 (aarch64_record_load_store): Handle PRFM instruction.
11261 (aarch64_process_record_test): New function.
11262
33877125
YQ
112632017-03-23 Yao Qi <yao.qi@linaro.org>
11264
11265 * aarch64-tdep.c (aarch64_record_load_store): Fix code
11266 indentation.
11267
a0eef940
YQ
112682017-03-23 Yao Qi <yao.qi@linaro.org>
11269
11270 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
11271
3f2a3564
PR
112722017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
11273
11274 python/python.c (do_start_initialization): Fix memory leak.
11275
b67aeab0
SM
112762017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
11277
11278 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
11279 using get_ptrace_pid.
11280 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
11281 inferior_ptid.
11282 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
11283 inferior_ptid instead of pid.
11284
ffdbe864
YQ
112852017-03-22 Yao Qi <yao.qi@linaro.org>
11286
11287 * aarch64-tdep.c: Wrap locally used classes in anonymous
11288 namespace.
11289 * arm-tdep.c: Likewise.
11290 * linespec.c: Likewise.
11291 * ui-out.c: Likewise.
11292
9d736fbf
JG
112932017-03-22 Jonah Graham <jonah@kichwacoders.com>
11294
11295 PR gdb/19637
11296 * python/lib/gdb/printer/bound_registers.py: Import sys.
11297
3de88e9a
SM
112982017-03-21 Simon Marchi <simon.marchi@ericsson.com>
11299
11300 * windows-nat.c (do_windows_fetch_inferior_registers): Add
11301 windows_thread_info parameter and use it instead of
11302 current_thread.
11303 (windows_fetch_inferior_registers): Don't set current_thread,
11304 pass the thread to do_windows_fetch_inferior_registers. Use
11305 ptid from regcache instead of inferior_ptid.
11306 (do_windows_store_inferior_registers): Add windows_thread_info
11307 parameter and use it instead of current_thread.
11308 (windows_store_inferior_registers): Don't set current_thread,
11309 pass the thread to do_windows_store_inferior_registers. Use
11310 ptid from regcache instead of inferior_ptid.
11311
0e7b8f61
SM
113122017-03-21 Simon Marchi <simon.marchi@ericsson.com>
11313
11314 * ser-mingw.c (ser_windows_raw): Remove reference to
11315 struct serial::current_timeout.
11316
5badf10a
IR
113172017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
11318
11319 PR tdep/20928
11320 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
11321 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
11322 (sparc64_fsr_type): Fix %fsr decoding.
11323
cee59b3f
TW
113242017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
11325
11326 * python/py-record-btrace.c (btpy_insn_data): Change return type
11327 for Python 2.
11328
639a9038
SM
113292017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
11330
11331 * spu-linux-nat.c (spu_fetch_inferior_registers,
11332 spu_store_inferior_registers): Use ptid from regcache, set and
11333 restore inferior_ptid.
11334 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
11335 Likewise.
11336
bcc0c096
SM
113372017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
11338
11339 * i386-linux-nat.c (fetch_register, store_register,
11340 i386_linux_fetch_inferior_registers,
11341 i386_linux_store_inferior_registers): Use ptid from regcache.
11342 * ia64-linux-nat.c (ia64_linux_fetch_register,
11343 ia64_linux_store_register): Likewise.
11344 * inf-ptrace.c (inf_ptrace_fetch_register,
11345 inf_ptrace_store_register): Likewise.
11346 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
11347 m32r_linux_store_inferior_registers): Likewise.
11348 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
11349 m68kbsd_store_inferior_registers): Likewise.
11350 * m68k-linux-nat.c (fetch_register, store_register,
11351 m68k_linux_fetch_inferior_registers,
11352 m68k_linux_store_inferior_registers): Likewise.
11353 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
11354 m88kbsd_store_inferior_registers): Likewise.
11355 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
11356 mips_fbsd_store_inferior_registers): Likewise.
11357 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
11358 mips64_linux_regsets_store_registers): Likewise.
11359 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
11360 mipsnbsd_store_inferior_registers): Likewise.
11361 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
11362 mips64obsd_store_inferior_registers): Likewise.
11363 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
11364 Likewise.
11365 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
11366 ppcfbsd_store_inferior_registers): Likewise.
11367 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
11368 ppc_linux_store_inferior_registers): Likewise.
11369 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
11370 ppcnbsd_store_inferior_registers): Likewise.
11371 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
11372 ppcobsd_store_registers): Likewise.
11373 * procfs.c (procfs_fetch_registers, procfs_store_registers):
11374 Likewise.
11375 * ravenscar-thread.c (ravenscar_fetch_registers,
11376 ravenscar_store_registers, ravenscar_prepare_to_store):
11377 Likewise.
11378 * record-btrace.c (record_btrace_fetch_registers,
11379 record_btrace_store_registers, record_btrace_prepare_to_store):
11380 Likewise.
11381 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
11382 Lookup inferior using ptid from regcache, instead of
11383 current_inferior.
11384 * remote.c (remote_fetch_registers, remote_store_registers): Use
11385 ptid from regcache.
11386 * rs6000-nat.c (fetch_register, store_register): Likewise.
11387 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
11388 s390_linux_store_inferior_registers): Likewise.
11389 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
11390 shnbsd_store_inferior_registers): Likewise.
11391 * sol-thread.c (sol_thread_fetch_registers,
11392 sol_thread_store_registers): Likewise.
11393 * sparc-nat.c (sparc_fetch_inferior_registers,
11394 sparc_store_inferior_registers): Likewise.
11395 * tilegx-linux-nat.c (fetch_inferior_registers,
11396 store_inferior_registers): Likewise.
11397 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
11398 vaxbsd_store_inferior_registers): Likewise.
11399 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
11400 store_xtregs): Likewise.
11401
c0f55cc6
AV
114022017-03-20 Artemiy Volkov <artemiyv@acm.org>
11403
11404 PR gdb/14441
11405 * NEWS: Mention support for rvalue references in GDB and python.
11406 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
11407 supports both lvalue and rvalue references.
11408
15c0a2a9
AV
114092017-03-20 Artemiy Volkov <artemiyv@acm.org>
11410
11411 PR gdb/14441
11412 * gdbtypes.c (rank_one_type): Implement overloading
11413 resolution rules regarding rvalue references.
11414
aa006118
AV
114152017-03-20 Artemiy Volkov <artemiyv@acm.org>
11416
11417 PR gdb/14441
11418 * aarch64-tdep.c (aarch64_type_align)
11419 (aarch64_extract_return_value, aarch64_store_return_value): Change
11420 lvalue reference type checks to general reference type checks.
11421 * amd64-tdep.c (amd64_classify): Likewise.
11422 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
11423 Likewise.
11424 * arm-tdep.c (arm_type_align, arm_extract_return_value)
11425 (arm_store_return_value): Likewise.
11426 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
11427 * c-typeprint.c (c_print_type): Likewise.
11428 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
11429 (cplus_number_of_children, cplus_describe_child): Likewise.
11430 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
11431 * completer.c (expression_completer): Likewise.
11432 * cp-support.c (make_symbol_overload_list_adl_namespace):
11433 Likewise.
11434 * darwin-nat-info.c (info_mach_region_command): Likewise.
11435 * dwarf2loc.c (entry_data_value_coerce_ref)
11436 (value_of_dwarf_reg_entry): Likewise.
11437 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
11438 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
11439 Likewise.
11440 * findvar.c (extract_typed_address, store_typed_address):
11441 Likewise.
11442 * gdbtypes.c (rank_one_type): Likewise.
11443 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
11444 * infcall.c (value_arg_coerce): Likewise.
11445 * language.c (pointer_type): Likewise.
11446 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
11447 Likewise.
11448 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
11449 * mn10300-tdep.c (mn10300_type_align): Likewise.
11450 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
11451 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
11452 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
11453 Likewise.
11454 * printcmd.c (print_formatted, x_command): Likewise.
11455 * python/py-type.c (typy_get_composite, typy_template_argument):
11456 Likewise.
11457 * python/py-value.c (valpy_referenced_value)
11458 (valpy_get_dynamic_type, value_has_field): Likewise.
11459 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
11460 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
11461 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
11462 * spu-tdep.c (spu_scalar_value_p): Likewise.
11463 * symtab.c (lookup_symbol_aux): Likewise.
11464 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
11465 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
11466 Likewise.
11467 * valops.c (value_cast_pointers, value_cast)
11468 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
11469 (value_struct_elt, value_struct_elt_bitpos)
11470 (value_find_oload_method_list, find_overload_match)
11471 (value_rtti_indirect_type): Likewise.
11472 * valprint.c (val_print_scalar_type_p, generic_val_print):
11473 Likewise.
11474 * value.c (value_actual_type, value_as_address, unpack_long)
11475 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
11476 (coerce_ref): Likewise.
11477 * varobj.c (varobj_get_value_type): Likewise.
11478
3fcf899d
AV
114792017-03-20 Artemiy Volkov <artemiyv@acm.org>
11480
11481 PR gdb/14441
11482 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
11483 table of constants.
11484 * python/lib/gdb/command/explore.py: Support exploring values
11485 of rvalue reference types.
11486 * python/lib/gdb/types.py: Implement get_basic_type() for
11487 rvalue reference types.
11488 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
11489 constant.
11490 * python/py-value.c (valpy_getitem): Add an rvalue reference
11491 check.
11492 (valpy_reference_value): Add new parameter "refcode".
11493 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
11494 New wrappers for valpy_reference_value().
11495 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
11496 (gdbpy_invoke_xmethod): Likewise.
11497
4297a3f0
AV
114982017-03-20 Artemiy Volkov <artemiyv@acm.org>
11499
11500 PR gdb/14441
11501 * dwarf2read.c (process_die, read_type_die_1): Handle the
11502 DW_TAG_rvalue_reference_type DIE.
11503 (read_tag_reference_type): Add new parameter "refcode".
11504
e1cb3213
AV
115052017-03-20 Artemiy Volkov <artemiyv@acm.org>
11506
11507 PR gdb/14441
11508 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
11509 (c_type_print_modifier, c_type_print_varspec_suffix)
11510 (c_type_print_base): Support printing rvalue reference types.
11511 * c-valprint.c (c_val_print, c_value_print): Support printing
11512 rvalue reference values.
11513
e4347c89
AV
115142017-03-20 Artemiy Volkov <artemiyv@acm.org>
11515
11516 PR gdb/14441
11517 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
11518 typename.
11519 * cp-support.c (replace_typedefs): Handle
11520 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
11521 * python/py-type.c (typy_lookup_type): Likewise.
11522
53cc15f5
AV
115232017-03-20 Artemiy Volkov <artemiyv@acm.org>
11524
11525 PR gdb/14441
11526 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
11527 * parse.c (insert_type): Change assert statement.
11528 (follow_types): Handle rvalue reference types.
11529 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
11530 constant.
11531
a65cfae5
AV
115322017-03-20 Artemiy Volkov <artemiyv@acm.org>
11533
11534 PR gdb/14441
11535 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
11536 value_ref() interface.
11537 * c-valprint.c (c_value_print): Likewise.
11538 * infcall.c (value_arg_coerce): Likewise.
11539 * python/py-value.c (valpy_reference_value): Likewise.
11540 * valops.c (value_cast, value_reinterpret_cast)
11541 (value_dynamic_cast, typecmp): Likewise.
11542 (value_ref): Parameterize by kind of return value reference type.
11543 * value.h (value_ref): Add new parameter "refcode".
11544
3b224330
AV
115452017-03-20 Artemiy Volkov <artemiyv@acm.org>
11546
11547 PR gdb/14441
11548 * dwarf2read.c (read_tag_reference_type): Use
11549 lookup_lvalue_reference_type() instead of lookup_reference_type().
11550 * eval.c (evaluate_subexp_standard): Likewise.
11551 * f-exp.y: Likewise.
11552 * gdbtypes.c (make_reference_type, lookup_reference_type):
11553 Generalize with rvalue reference types.
11554 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
11555 convenience wrappers for lookup_reference_type().
11556 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
11557 reference kind parameter.
11558 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
11559 wrappers for lookup_reference_type().
11560 * guile/scm-type.c (gdbscm_type_reference): Use
11561 lookup_lvalue_reference_type() instead of lookup_reference_type().
11562 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
11563 * parse.c (follow_types): Likewise.
11564 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
11565 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
11566 Likewise.
11567 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
11568 (gdbpy_invoke_xmethod): Likewise.
11569 * stabsread.c: Provide extra argument to make_reference_type()
11570 call.
11571 * valops.c (value_ref, value_rtti_indirect_type): Use
11572 lookup_lvalue_reference_type() instead of lookup_reference_type().
11573
f9aeb8d4
AV
115742017-03-20 Artemiy Volkov <artemiyv@acm.org>
11575
11576 PR gdb/14441
11577 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
11578 (TYPE_IS_REFERENCE): New macro.
11579 (struct type): Add rvalue_reference_type field.
11580 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
11581
51457a05
MAL
115822017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
11583
11584 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
11585 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
11586 New function definition.
11587 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
11588 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
11589 New function declaration.
11590 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
11591 * mi/mi-interp.h: New file.
11592 * solib.c (info_sharedlibrary_command): Replace for loop with
11593 ALL_SO_LIBS macro
11594 * solib.h (update_solib_list): New function declaration.
11595 (so_list_head): Move macro.
11596 * solist.h (ALL_SO_LIBS): New macro.
11597
e696b3ad
MAL
115982017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
11599
11600 * infcmd.c (post_create_inferior): Remove unused argument in
11601 call to solib_add.
11602 * remote.c (remote_start_remote): Likewise.
11603 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
11604 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
11605 (enable_break): Likewise.
11606 * solib.c (update_solib_list): Remove unused target argument
11607 and its documentation.
11608 (solib_add): Remove unused target argument. Remove unused
11609 argument in call to update_solib_list.
11610 (info_sharedlibrary_command): Remove unused argument in call
11611 to update_solib_list.
11612 (sharedlibrary_command): Remove unused argument in call to
11613 solib_add.
11614 (handle_solib_event): Likewise.
11615 (reload_shared_libraries): Likewise.
11616 * solib.h (solib_add): Remove unused target argument.
11617
dcb84eda
AA
116182017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
11619
11620 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
11621 (s390_displaced_step_fixup): Cover relative branches with the
11622 default fixup handling. This fixes lack of support for some
11623 relative branch instructions.
11624
d9cb6cdc
SM
116252017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11626
11627 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
11628 ptid from regcache.
11629
1afaf9f4
SM
116302017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11631
11632 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
11633 i386_darwin_store_inferior_registers): Use ptid from regcache.
11634
aac12e24
SM
116352017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11636
11637 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
11638 i386bsd_store_inferior_registers): Use ptid from regcache.
11639
bbe1eef1
SM
116402017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11641
11642 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
11643 hppaobsd_store_registers): Use ptid from regcache.
11644
10799020
SM
116452017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11646
11647 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
11648 hppanbsd_store_registers): Use ptid from regcache.
11649
00204cf7
SM
116502017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11651
11652 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
11653 from regcache. Use get_ptrace_pid.
11654
11a33714
SM
116552017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11656
11657 * corelow.c (get_core_register_section): Use ptid from regcache,
11658 update doc.
11659
317cd492
SM
116602017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11661
11662 * bsd-uthread.c (bsd_uthread_fetch_registers,
11663 bsd_uthread_store_registers): Use ptid from regcache, set and
11664 restore inferior_ptid.
11665
9ac8a7c2
SM
116662017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11667
11668 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
11669 fetch_fp_regs, store_register, store_regs, store_fp_register,
11670 store_fp_regs): Use ptid from regcache.
11671
4ac4bb6a
SM
116722017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
11673
11674 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
11675 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
11676 store_vfp_regs): Use ptid from regcache.
11677
9bcbdca8
PA
116782017-03-17 Pedro Alves <palves@redhat.com>
11679
11680 PR remote/21188
11681 * ser-base.c (ser_base_wait_for): Add comment.
11682 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
11683 version.
11684 * ser-unix.c (hardwire_raw): Remove reference to
11685 scb->current_timeout.
11686 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
11687 (hardwire_ops): Install ser_base_readchar instead of
11688 hardwire_readchar.
11689 * serial.h (struct serial) <current_timeout, timeout_remaining>:
11690 Remove fields.
11691
7503099f
JG
116922017-03-17 Jonah Graham <jonah@kichwacoders.com>
11693
11694 PR gdb/19637
11695 * python/lib/gdb/printer/bound_registers.py: Add support for
11696 Python 3.
11697
7942e96e
AA
116982017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
11699
11700 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
11701 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
11702 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
11703 byte_offset to subobj_byte_offset. Fix the handling of
11704 DWARF_VALUE_STACK on big-endian targets when coming via an
11705 implicit pointer.
11706 (dwarf2_evaluate_loc_desc): Adjust call to
11707 dwarf2_evaluate_loc_desc_full.
11708 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
11709 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
11710
ba14f379
YQ
117112017-03-16 Yao Qi <yao.qi@linaro.org>
11712
11713 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
11714 and REVSH instructions.
11715
b121eeb9
YQ
117162017-03-16 Yao Qi <yao.qi@linaro.org>
11717
11718 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
11719 (arm_record_test): Declare.
11720 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
11721 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
11722 align with the manual.
11723 (thumb_record_misc): Adjust the code order to align with the
11724 manual.
11725 (thumb2_record_decode_insn_handler): Fix instruction matching.
11726 (instruction_reader_thumb): New class.
11727 (arm_record_test): New function.
11728
728a7913
YQ
117292017-03-16 Yao Qi <yao.qi@linaro.org>
11730
11731 * arm-tdep.c (abstract_memory_reader): New class.
11732 (instruction_reader): New class.
11733 (extract_arm_insn): Add argument 'reader'. Callers updated.
11734 (decode_insn): Likewise.
11735
34b43320
DE
117362017-03-16 Doug Evans <dje@google.com>
11737
a7c0469f
DE
11738 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
11739 member. Change type of TYPE member to SCM. All uses updated.
11740 (lsscm_make_lazy_string_smob): Add assert.
11741 (lsscm_make_lazy_string): Flag bad length values.
11742 (lsscm_elt_type): New function.
11743 (gdbscm_lazy_string_to_value): Rewrite to use
11744 lsscm_safe_lazy_string_to_value.
11745 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
11746 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
11747 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
11748 in incoming type.
11749 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
11750 * guile/scm-type.c (tyscm_scm_to_type): New function.
11751
117522017-03-15 Doug Evans <dje@google.com>
11753
34b43320
DE
11754 PR python/17728, python/18439, python/18779
11755 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
11756 member. Change type of TYPE member to PyObject *. All uses updated.
11757 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
11758 (gdbpy_create_lazy_string_object): Flag bad length values.
11759 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
11760 Handle typedefs in incoming type.
11761 (stpy_lazy_string_elt_type): New function.
11762 (gdbpy_extract_lazy_string): Call it.
11763 * python/py-value.c (valpy_lazy_string): Flag bad length values.
11764 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
11765 typedefs in incoming type.
11766
a3a5fecc
DE
117672017-03-16 Doug Evans <dje@google.com>
11768
11769 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
11770 * guile/scm-type.c (tyscm_scm_to_type): New function.
11771
28f1c605
JW
117722017-03-16 Jiong Wang <jiong.wang@arm.com>
11773
11774 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
11775 "ULONGEST" for "skip".
11776
87c336f6
AA
117772017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
11778
11779 PR gdb/21220
11780 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
11781 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
11782 (inf_ptrace_peek_poke): ...here. New function. Now also loop
11783 over ptrace peek/poke until end of buffer or error.
11784
cf81cf60
SM
117852017-03-14 Simon Marchi <simon.marchi@ericsson.com>
11786
11787 * parse.c (length_of_subexp): Make static.
11788 * parser-defs.h (length_of_subexp): Remove.
11789
a379284a
AA
117902017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
11791
11792 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
11793 as well.
11794
8a6200ba
PA
117952017-03-14 Pedro Alves <palves@redhat.com>
11796
11797 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
11798 (main): Use std::unique_ptr. Remove calls to
11799 cp_demangled_name_parse_free.
11800
f79ec206
SM
118012017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
11802
11803 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
11804 alphabsd_store_inferior_registers): Use regcache->ptid instead
11805 of inferior_ptid.
11806
edb5fb00
SM
118072017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
11808
11809 * aix-thread.c (aix_thread_fetch_registers,
11810 aix_thread_store_registers): Use regcache->ptid instead of
11811 inferior_ptid.
11812
55119686
SM
118132017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
11814
11815 * aarch64-linux-nat.c (fetch_gregs_from_thread,
11816 store_gregs_to_thread, fetch_fpregs_from_thread,
11817 store_fpregs_to_thread): Use regcache->ptid instead of
11818 inferior_ptid.
11819
6a06fbb7
SM
118202017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
11821
11822 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
11823 amd64_linux_fetch_inferior_registers): Use regcache->ptid
11824 instead of inferior_ptid.
11825
c6386875
SM
118262017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
11827
11828 * target.c (target_fetch_registers, target_store_registers): Add
11829 assert.
11830
ddaaf0fb
SM
118312017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
11832
11833 * regcache.h (regcache_get_ptid): New function.
11834 * regcache.c (regcache_get_ptid): New function.
11835
b9da89d1 118362017-03-13 Mark Wielaard <mark@klomp.org>
11837
11838 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
11839
5f4d1085
KS
118402017-03-10 Keith Seitz <keiths@redhat.com>
11841
11842 PR c++/8218
11843 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
11844
c65d6b55
PA
118452017-03-08 Pedro Alves <palves@redhat.com>
11846
11847 PR gdb/18360
11848 * infrun.c (start_step_over, do_target_resume, resume)
11849 (restart_threads): Assert we're not resuming a thread that is
11850 meant to be stopped.
11851 (infrun_thread_stop_requested_callback): Delete.
11852 (infrun_thread_stop_requested): If the thread is internally
11853 stopped, queue a pending stop event and clear the thread's
11854 inline-frame state.
11855 (handle_stop_requested): New function.
11856 (handle_syscall_event, handle_inferior_event_1): Use
11857 handle_stop_requested.
11858 (handle_stop_requested): New function.
11859 (handle_signal_stop): Set the thread's stop_signal here instead of
11860 at caller.
11861 (finish_step_over): Clear step over info unconditionally.
11862 (handle_signal_stop): If the user had interrupted the event
11863 thread, consider the stop a random signal.
11864 (handle_signal_stop) <signal arrived while stepping over
11865 breakpoint>: Don't restart threads here.
11866 (stop_waiting): Don't clear step-over info here.
11867
15c22686
PA
118682017-03-08 Pedro Alves <palves@redhat.com>
11869
11870 PR 21206
11871 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
11872 goes to argument 2, not 1.
11873
6e5d74e7
PA
118742017-03-08 Pedro Alves <palves@redhat.com>
11875
11876 PR cli/21218
11877 * top.c (gdb_readline_wrapper): Avoid passing NULL to
11878 display_gdb_prompt.
11879 (command_line_input): Add comment.
11880
9753a2f6
PA
118812017-03-08 Pedro Alves <palves@redhat.com>
11882
11883 PR tui/21216
11884 * tui/tui-file.c (tui_file::write): New.
11885 * tui/tui-file.h (tui_file): Override "write".
11886 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
11887 factored out from ...
11888 (tui_puts): ... here.
11889 (tui_putc): Use them.
11890 (tui_write): New function.
11891 * tui/tui-io.h (tui_write): Declare.
11892
1672e0d9
SDJ
118932017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
11894
11895 * Makefile.in (SFILES): Replace "environ.c" with
11896 "common/environ.c".
11897 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
11898 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
11899 to...
11900 * common/environ.c: ... here.
11901 * environ.h: Moved to...
11902 * common/environ.h: ... here.
11903
f7bb4e3a
PB
119042017-03-07 Peter Bergner <bergner@vnet.ibm.com>
11905
11906 * gdbarch.sh (pstring_ptr): New static function.
11907 (gdbarch_disassembler_options): Use it.
11908 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
11909 not valid_disassembler_option->name.
11910 * gdbarch.c: Regenerate.
11911
e45ced6c
PB
119122017-03-07 Peter Bergner <bergner@vnet.ibm.com>
11913
11914 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
11915
5f6fd321
PA
119162017-03-07 Pedro Alves <palves@redhat.com>
11917
11918 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
11919
6dbb839a 119202017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
4a612d6f
WT
11921
11922 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
11923 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
11924 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
6dbb839a 11925 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
4a612d6f 11926
d274ecf4
SM
119272017-03-06 Simon Marchi <simon.marchi@ericsson.com>
11928
11929 * xtensa-linux-nat.c (fetch_gregs): Remove const.
11930
df97be55
SM
119312017-03-03 Simon Marchi <simon.marchi@ericsson.com>
11932
11933 * remote.c (remote_add_target_side_commands): Use range-based
11934 for loop.
11935
7d45f3df
YQ
119362017-03-03 Yao Qi <yao.qi@linaro.org>
11937
11938 PR gdb/21165
11939 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
11940 value is lazy.
11941 * valprint.c (common_val_print): Likewise.
11942
65b48a81
PB
119432017-02-28 Peter Bergner <bergner@vnet.ibm.com>
11944
11945 * NEWS: Mention new set/show disassembler-options commands.
11946 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
11947 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
11948 (prospective_options): New static variable.
11949 (gdb_disassembler::gdb_disassembler): Initialize
11950 m_di.disassembler_options.
11951 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
11952 (get_disassembler_options): New function.
11953 (set_disassembler_options): Likewise.
11954 (set_disassembler_options_sfunc): Likewise.
11955 (show_disassembler_options_sfunc): Likewise.
11956 (disassembler_options_completer): Likewise.
11957 (_initialize_disasm): Likewise.
11958 * disasm.h (get_disassembler_options): New prototype.
11959 (set_disassembler_options): Likewise.
11960 * gdbarch.sh (gdbarch_disassembler_options): New variable.
11961 (gdbarch_verify_disassembler_options): Likewise.
11962 * gdbarch.c: Regenerate.
11963 * gdbarch.h: Likewise.
11964 * arm-tdep.c (num_disassembly_options): Delete.
11965 (set_disassembly_style): Likewise.
11966 (arm_disassembler_options): New static variable.
11967 (set_disassembly_style_sfunc): Convert short style name into long
11968 option name. Call set_disassembler_options.
11969 (show_disassembly_style_sfunc): New function.
11970 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
11971 set_gdbarch_verify_disassembler_options.
11972 (_initialize_arm_tdep): Delete regnames variable and update callers.
11973 (arm_disassembler_options): Initialize.
11974 (disasm_options): New variable.
11975 (num_disassembly_options): Rename from this...
11976 (num_disassembly_styles): ...to this. Compute by scanning through
11977 disasm_options.
11978 (valid_disassembly_styles): Initialize using disasm_options.
11979 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
11980 set_arm_regname_option.
11981 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
11982 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
11983 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
11984 set_gdbarch_verify_disassembler_options.
11985 * s390-tdep.c (s390_disassembler_options): New static variable.
11986 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
11987 set_gdbarch_verify_disassembler_options.
11988
d538e36d
SM
119892017-02-27 Simon Marchi <simon.marchi@ericsson.com>
11990
11991 * remote.c (remote_add_target_side_condition): Remove "struct"
11992 keyword from range-based for loop.
11993
83621223
SM
119942017-02-27 Simon Marchi <simon.marchi@ericsson.com>
11995
11996 * remote.c (remote_add_target_side_condition): Use range-based
11997 for loop. Update comment.
11998
2123df0e
YQ
119992017-02-27 Yao Qi <yao.qi@linaro.org>
12000
12001 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
12002
8e368124
AH
120032017-02-26 Alan Hayward <alan.hayward@arm.com>
12004
12005 * regcache.c (regcache_raw_update): New function.
12006 (regcache_raw_read): Move code to regcache_raw_update.
12007 * regcache.h (regcache_raw_update): New declaration.
12008 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
12009
a49dd8dd
JK
120102017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
12011
12012 * dwarf2read.c (create_debug_type_hash_table): Initialize
12013 header.signature and header.type_offset_in_tu.
12014
34e4bae9
PA
120152017-02-24 Pedro Alves <palves@redhat.com>
12016
12017 * symtab.c (make_file_symbol_completion_list_1): Use
12018 add_symtab_completions.
12019
b0e4b369
AH
120202017-02-24 Alan Hayward <alan.hayward@arm.com>
12021
12022 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
12023
975c21ab
AH
120242017-02-24 Alan Hayward <alan.hayward@arm.com>
12025
12026 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
12027 I386_MAX_REGISTER_SIZE.
12028 (i386_pseudo_register_write): Likewise.
12029 (i386_process_record): Likewise.
12030 * i387-tdep.c (i387_supply_xsave): Likewise.
12031 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
12032 (store_register): Likewise.
12033
14bc53a8
PA
120342017-02-23 Pedro Alves <palves@redhat.com>
12035
12036 * ada-lang.c: Include "common/function-view.h".
12037 (ada_iterate_over_symbols): Adjust to use function_view as
12038 callback type.
12039 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
12040 (ada_make_symbol_completion_list): Use a lambda.
12041 (ada_exc_search_name_matches): Delete.
12042 (name_matches_regex): New.
12043 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
12044 * compile/compile-c-support.c: Include "common/function-view.h".
12045 (print_one_macro): Change prototype to accept a ui_file pointer.
12046 (write_macro_definitions): Use a lambda.
12047 * dwarf2read.c: Include "common/function-view.h".
12048 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
12049 (dw2_expand_symtabs_matching): Adjust to use function_view as
12050 callback type.
12051 * language.h: Include "common/function-view.h".
12052 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
12053 function_view as callback type.
12054 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
12055 * linespec.c: Include "common/function-view.h".
12056 (collect_info::add_symbol): New method.
12057 (struct symbol_and_data_callback, iterate_inline_only, struct
12058 symbol_matcher_data, iterate_name_matcher): Delete.
12059 (iterate_over_all_matching_symtabs): Adjust to use function_view
12060 as callback type and lambdas.
12061 (iterate_over_file_blocks): Adjust to use function_view as
12062 callback type.
12063 (decode_compound_collector): Now a class with private fields.
12064 (decode_compound_collector::release_symbols): New method.
12065 (collect_one_symbol): Rename to...
12066 (decode_compound_collector::operator()): ... this and adjust.
12067 (lookup_prefix_sym): decode_compound_collector construction bits
12068 move to decode_compound_collector ctor. Pass the
12069 decode_compound_collector object directly as callback. Remove
12070 cleanups and use decode_compound_collector::release_symbols
12071 instead.
12072 (symtab_collector): Now a class with private fields.
12073 (symtab_collector::release_symtabs): New method.
12074 (add_symtabs_to_list): Rename to...
12075 (symtab_collector::operator()): ... this and adjust.
12076 (collect_symtabs_from_filename): symtab_collector construction
12077 bits move to symtab_collector ctor. Pass the symtab_collector
12078 object directly as callback. Remove cleanups and use
12079 symtab_collector::release_symtabs instead.
12080 (collect_symbols): Delete.
12081 (add_matching_symbols_to_info): Use lambdas.
12082 * macrocmd.c (print_macro_callback): Delete.
12083 (info_macro_command): Use a lambda.
12084 (info_macros_command): Pass print_macro_definition as callable
12085 directly.
12086 (print_one_macro): Remove 'ignore' parameter.
12087 (macro_list_command): Adjust.
12088 * macrotab.c (macro_for_each_data::fn): Now a function_view.
12089 (macro_for_each_data::user_data): Delete field.
12090 (foreach_macro): Adjust to call the function_view.
12091 (macro_for_each): Adjust to use function_view as callback type.
12092 (foreach_macro_in_scope): Adjust to call the function_view.
12093 (macro_for_each_in_scope): Adjust to use function_view as callback
12094 type.
12095 * macrotab.h: Include "common/function-view.h".
12096 (macro_callback_fn): Declare a prototype instead of a pointer.
12097 Remove "user_data" parameter.
12098 (macro_for_each, macro_for_each_in_scope): Adjust to use
12099 function_view as callback type.
12100 * psymtab.c (partial_map_expand_apply)
12101 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
12102 Adjust to use function_view as callback type and to return bool.
12103 (psym_expand_symtabs_matching): Adjust to use function_view as
12104 callback types.
12105 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
12106 to use function_view as callback type and to return bool.
12107 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
12108 callback types.
12109 * symfile.c (expand_symtabs_matching): Adjust to use function_view
12110 as callback types.
12111 * symfile.h: Include "common/function-view.h".
12112 (expand_symtabs_file_matcher_ftype)
12113 (expand_symtabs_symbol_matcher_ftype)
12114 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
12115 return bool.
12116 (quick_symbol_functions::map_symtabs_matching_filename)
12117 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
12118 function_view as callback type and return bool.
12119 (expand_symtabs_matching): Adjust to use function_view as callback
12120 type.
12121 (maintenance_expand_name_matcher)
12122 (maintenance_expand_file_matcher): Delete.
12123 (maintenance_expand_symtabs): Use lambdas.
12124 * symtab.c (iterate_over_some_symtabs): Adjust to use
12125 function_view as callback types and return bool.
12126 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
12127 of a cleanup.
12128 (lookup_symtab_callback): Delete.
12129 (lookup_symtab): Use a lambda.
12130 (iterate_over_symbols): Adjust to use function_view as callback
12131 type.
12132 (struct search_symbols_data, search_symbols_file_matches)
12133 (search_symbols_name_matches): Delete.
12134 (search_symbols): Use a pair of lambdas.
12135 (struct add_name_data, add_macro_name, symbol_completion_matcher)
12136 (symtab_expansion_callback): Delete.
12137 (default_make_symbol_completion_list_break_on_1): Use lambdas.
12138 * symtab.h: Include "common/function-view.h".
12139 (iterate_over_some_symtabs): Adjust to use function_view as
12140 callback type and return bool.
12141 (iterate_over_symtabs): Adjust to use function_view as callback
12142 type.
12143 (symbol_found_callback_ftype): Remove 'data' parameter and return
12144 bool.
12145 (iterate_over_symbols): Adjust to use function_view as callback
12146 type.
12147
07e253aa
PA
121482017-02-23 Pedro Alves <palves@redhat.com>
12149
12150 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
12151 (%.o) <unittests/%.c>: New pattern.
12152 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
12153 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
12154 * common/function-view.h: New file.
12155 * unittests/function-view-selftests.c: New file.
12156 * configure: Regenerate.
12157
8eaf5320
SM
121582017-02-23 Simon Marchi <simon.marchi@ericsson.com>
12159
12160 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
12161 inferior_ptid.
12162 * go32-nat.c (go32_thread_alive): Likewise.
12163
38768751
YQ
121642017-02-23 Yao Qi <yao.qi@linaro.org>
12165
12166 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
12167 delete.
12168
0a8beaba
YQ
121692017-02-23 Yao Qi <yao.qi@linaro.org>
12170
12171 * varobj.c (varobj_clear_saved_item): Use delete instead of
12172 xfree.
12173 (update_dynamic_varobj_children): Likewise.
12174
58fdfd2c
JK
121752017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12176
12177 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
12178
1b90b139
SM
121792017-02-21 Simon Marchi <simon.marchi@ericsson.com>
12180
12181 * common/enum-flags.h (enum_flags::enum_flags): Initialize
12182 m_enum_value to 0 in default constructor.
12183
2039d74e
EBM
121842017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
12185
12186 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
12187 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
12188 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
12189 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
12190 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
12191 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
12192 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
12193 IS_STORE_CONDITIONAL_INSN.
12194
7814882a
JK
121952017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12196
12197 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
12198
0ae60b63
JK
121992017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12200
12201 * NEWS (Changes since GDB 7.12): Add DWARF-5.
12202
0224619f
JK
122032017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12204
12205 * dwarf2read.c (skip_one_die, read_attribute_value)
12206 (dwarf2_const_value_attr, dump_die_shallow)
12207 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
12208 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
12209
0af92d60
JK
122102017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12211
12212 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
12213 (dwarf_parse_macro_header): Accept DWARF version 5.
12214 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
12215
216f72a1
JK
122162017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12217
12218 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
12219 DW_AT_GNU_*.
12220 * common/common-exceptions.h (enum errors): Likewise.
12221 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
12222 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
12223 (dwarf_expr_context::execute_stack_op): Likewise.
12224 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
12225 Likewise.
12226 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
12227 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
12228 (show_entry_values_debug, call_site_to_target_addr)
12229 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
12230 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
12231 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
12232 (value_of_dwarf_block_entry, indirect_pieced_value)
12233 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
12234 (disassemble_dwarf_expression): Likewise.
12235 * dwarf2read.c (process_die, inherit_abstract_dies)
12236 (read_call_site_scope): Likewise.
12237 * gdbtypes.h (struct func_type, struct call_site_parameter)
12238 (struct call_site): Likewise.
12239 * stack.c (read_frame_arg): Likewise.
12240 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
12241
43988095
JK
122422017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12243
12244 * defs.h (read_unsigned_leb128): New declaration.
12245 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
12246 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
12247 (dwarf2_find_location_expression): Call also
12248 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
12249 * dwarf2loc.h (dwarf2_version): New declaration.
12250 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
12251 rnglists.
12252 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
12253 .debug_rnglists.
12254 (struct dwop_section_names): Add loclists_dwo.
12255 (dwop_section_names): Add .debug_loclists.dwo.
12256 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
12257 (struct dwarf2_per_cu_data): Add dwarf_version.
12258 (struct dwo_sections): Add loclists.
12259 (struct attr_abbrev): Add implicit_const.
12260 (read_indirect_line_string): New declaration.
12261 (read_unsigned_leb128): Delete declaration.
12262 (rcuh_kind): New definition.
12263 (read_and_check_comp_unit_head): Change parameter
12264 is_debug_types_section to section_kind.
12265 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
12266 (read_comp_unit_head): Change parameter abfd to section, add parameter
12267 section_kind. Handle DWARF-5.
12268 (error_check_comp_unit_head): Accept also DWARF version 5.
12269 (read_and_check_comp_unit_head): Change parameter
12270 is_debug_types_section to section_kind.
12271 (read_and_check_type_unit_head): Delete function.
12272 (read_abbrev_offset): Handle DWARF-5.
12273 (create_debug_type_hash_table): Add parameter section_kind. Process
12274 only DW_UT_type. Use signature and type_offset_in_tu from struct
12275 comp_unit_head.
12276 (create_debug_types_hash_table): Update create_debug_type_hash_table
12277 caller.
12278 (create_all_type_units): Call create_debug_type_hash_table.
12279 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
12280 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
12281 caller.
12282 (skip_one_die): Handle DW_FORM_implicit_const.
12283 (dwarf2_rnglists_process): New function.
12284 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
12285 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
12286 (read_attribute_value): Handle DW_FORM_implicit_const,
12287 DW_FORM_line_strp.
12288 (read_attribute): Handle DW_FORM_implicit_const.
12289 (read_indirect_string_at_offset_from): New function from
12290 read_indirect_string_at_offset.
12291 (read_indirect_string_at_offset): Call
12292 read_indirect_string_at_offset_from.
12293 (read_indirect_line_string_at_offset): New function.
12294 (read_indirect_string): New function comment.
12295 (read_indirect_line_string): New function.
12296 (read_unsigned_leb128): Make it global.
12297 (dwarf2_string_attr): Handle DWARF-5.
12298 (add_include_dir_stub, read_formatted_entries): New functions.
12299 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
12300 Handle DWARF-5.
12301 (per_cu_header_read_in): Update read_comp_unit_head caller.
12302 (dwarf2_version): New function.
12303 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
12304 rnglists.
12305 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
12306 fields.
12307
22d2f3ab
JK
123082017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12309
12310 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
12311
5f46c5a5
JK
123122017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12313
12314 * dwarf2read.c (dwarf2_ranges_process): New function from
12315 dwarf2_ranges_read.
12316 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
12317 dwarf2_ranges_process.
12318
78d4d2c5
JK
123192017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
12320
12321 * dwarf2read.c (create_debug_type_hash_table): New function from
12322 create_debug_types_hash_table.
12323 (create_debug_types_hash_table): Call create_debug_type_hash_table.
12324 (create_all_type_units, open_and_init_dwo_file): Update
12325 create_debug_types_hash_table callers.
12326
1b076f25
SDJ
123272017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
12328
12329 PR gdb/16188
12330 * fork-child.c (trace_start_error): Fix thinko. va_end should
12331 refer to 'ap', not 'args'.
12332
0db8980c
SDJ
123332017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
12334 Pedro Alves <palves@redhat.com>
12335
12336 PR gdb/16188
12337 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
12338 calls succeeded.
12339 * fork-child.c (trace_start_error): New function.
12340 (trace_start_error_with_name): Likewise.
12341 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
12342 * inf-ptrace.c (inf_ptrace_me): Likewise.
12343 * inferior.h (trace_start_error): New prototype.
12344 (trace_start_error_with_name): Likewise.
12345
99e8a4f9
SDJ
123462017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
12347
12348 PR gdb/21164
12349 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
12350 NULL before using it.
12351 * symmisc.c (maintenance_print_symbols): Likewise.
12352 (maintenance_print_msymbols): Likewise.
12353
4e746bb6
TW
123542017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12355
12356 * NEWS: Add record Python bindings entry.
12357
123582017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12359
12360 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
12361 py-record-full.o.
12362 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
12363 * python/py-record-btrace.c, python/py-record-btrace.h,
12364 python/py-record-full.c, python/py-record-full.h: New file.
12365 * python/py-record.c: Add include for py-record-btrace.h and
12366 py-record-full.h.
12367 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
12368 recpy_instruction_history, recpy_function_call_history, recpy_begin,
12369 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
12370 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
12371 New definition.
12372 (gdbpy_initialize_btrace): New export.
12373 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
12374
123752017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12376
12377 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
12378 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
12379 * python/py-record.c: New file.
12380 * python/python-internal.h (gdbpy_start_recording,
12381 gdbpy_current_recording, gdpy_stop_recording,
12382 gdbpy_initialize_record): New export.
12383 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
12384 (python_GdbMethods): Add gdbpy_start_recording,
12385 gdbpy_current_recording and gdbpy_stop_recording.
12386
123872017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12388
12389 * record-btrace.c (record_btrace_record_method): New function.
12390 (init_record_btrace_ops): Initialize to_record_method.
12391 * record-full.c (record_full_record_method): New function.
12392 (init_record_full_ops, init_record_full_core_ops): Add
12393 record_full_record_method.
12394 * record.h (enum record_method): New enum.
12395 * target-debug.h (target_debug_print_enum_record_method: New define.
12396 * target-delegates.c: Regenerate.
12397 * target.c (target_record_method): New function.
12398 * target.h: Include record.h.
12399 (struct target_ops) <to_record_method>: New field.
12400 (target_record_method): New export.
12401
124022017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12403
12404 * record.h (record_start, record_stop): New export.
12405 * record.c (record_start, record_stop): New function.
12406
124072017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12408
12409 * btrace.c (btrace_fetch): Copy function call segments pointer
12410 into a vector.
12411 (btrace_clear): Clear the vector.
12412 (btrace_find_insn_by_number): Use binary search to find the correct
12413 function call segment.
12414 * btrace.h (brace_fun_p): New typedef.
12415 (struct btrace_thread_info) <functions>: New field.
12416
124172017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12418
12419 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
12420 * btrace.c (btrace_decode_error): ... here. New function.
12421 * btrace.h (btrace_decode_error): New export.
12422
124232017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
12424
12425 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
12426 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
12427 btrace_find_insn_by_number): Remove special case for gaps.
12428 * btrace.h (btrace_insn_get_error): New export.
12429 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
12430 * record-btrace.c (btrace_insn_history): Print number for gaps.
12431 (record_btrace_info, record_btrace_goto): Handle gaps.
12432
3f77c769
TT
124332017-02-14 Tom Tromey <tom@tromey.com>
12434
12435 PR python/13598:
12436 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
12437 event.
12438 * python/py-evts.c (gdbpy_initialize_py_events): Add
12439 before_prompt registry.
12440 * python/py-events.h (events_object) <before_prompt>: New field.
12441
4c2c7ac6
MM
124422017-02-14 Markus Metzger <markus.t.metzger@intel.com>
12443
12444 * btrace.c (ftrace_new_switch): Preserve up link and flags.
12445
5cf30ebf
LM
124462017-02-13 Luis Machado <lgustavo@codesourcery.com>
12447
12448 * symfile (_initialize_symfile): Add usage text to the load command's
12449 help text.
12450
26a06916
SM
124512017-02-10 Simon Marchi <simon.marchi@ericsson.com>
12452
12453 * utils.c (defaulted_query): Don't query on secondary UIs.
12454
0b145e37
TT
124552017-02-10 Tom Tromey <tom@tromey.com>
12456
12457 * rust-lang.c (rust_get_disr_info): Remove unused variable.
12458
2d8365c4
TT
124592017-02-10 Tom Tromey <tom@tromey.com>
12460
12461 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
12462 "cleanup" local.
12463 * python/py-type.c (typy_legacy_template_argument): Remove
12464 unnecessary "cleanup" local.
12465
2bb8f231
TT
124662017-02-10 Tom Tromey <tom@tromey.com>
12467
12468 * python/python.c (do_start_initialization): New function, from
12469 _initialize_python.
12470 (_initialize_python): Call do_start_initialization.
12471 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
12472 goto.
12473
1bdfaf42
TT
124742017-02-10 Tom Tromey <tom@tromey.com>
12475
12476 * python/py-prettyprint.c (pretty_print_one_value): Use
12477 gdbpy_ref.
12478
88b6faea
TT
124792017-02-10 Tom Tromey <tom@tromey.com>
12480
12481 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
12482 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
12483 gdbpy_ref.
12484 * python/py-type.c (field_new): Use gdbpy_ref.
12485 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
12486 gdbpy_ref.
12487 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
12488 (py_free_pspace): Likewise.
12489 (pspace_to_pspace_object): Likewise.
12490 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
12491 (py_free_objfile): Likewise.
12492 (objfile_to_objfile_object): Likewise.
12493 * python/py-inferior.c (delete_thread_object): Use
12494 gdbpy_ref.
12495 (infpy_read_memory): Likewise.
12496 (py_free_inferior): Likewise.
12497 * python/py-evtregistry.c (create_eventregistry_object): Use
12498 gdbpy_ref.
12499 * python/py-event.c (create_event_object): Use gdbpy_ref.
12500
7780f186
TT
125012017-02-10 Tom Tromey <tom@tromey.com>
12502
12503 * python/py-ref.h (gdbpy_ref_policy): Now a template.
12504 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
12505 used.
12506 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
12507 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
12508 python/py-exitedevent.c, python/py-finishbreakpoint.c,
12509 python/py-framefilter.c, python/py-function.c,
12510 python/py-inferior.c, python/py-infevents.c,
12511 python/py-linetable.c, python/py-newobjfileevent.c,
12512 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
12513 python/py-signalevent.c, python/py-stopevent.c,
12514 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
12515 python/py-unwind.c, python/py-utils.c, python/py-value.c,
12516 python/py-varobj.c, python/py-xmethods.c, python/python.c,
12517 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
12518
d4b0bb18
TT
125192017-02-10 Tom Tromey <tom@tromey.com>
12520
12521 * ui-out.h (ui_out_emit_type): New class.
12522 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
12523 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
12524 and ui_out_emit_tuple.
12525 (enumerate_locals): Likewise.
12526 (py_mi_print_variables, py_print_locals, py_print_args): Use
12527 ui_out_emit_list.
12528 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
12529 ui_out_emit_list.
12530 * common/gdb_optional.h: New file.
12531
f67f945c
MG
125322017-02-10 Martin Galvan <martingalvan@sourceware.org>
12533
12534 * MAINTAINERS (Write After Approval): Update my e-mail address.
12535
18da0c51
MG
125362017-02-10 Martin Galvan <martingalvan@sourceware.org>
12537
12538 PR gdb/21122
12539 * breakpoint.c (_initialize_breakpoint): Update the help description
12540 of the 'commands' command to indicate that it takes a list argument.
12541
62c14536
SM
125422017-02-09 Simon Marchi <simon.marchi@ericsson.com>
12543
12544 * interps.c (current_interp_set_logging): Remove "return".
12545
ff6fa247
GB
125462017-02-09 Gary Benson <gbenson@redhat.com>
12547
12548 * symtab.c (add_symtab_completions): Prevent NULL pointer
12549 dereference.
12550
a474bd8e
PA
125512017-02-08 Pedro Alves <palves@redhat.com>
12552
12553 * interps.c (interp::interp): Remove reference to quiet_p.
12554 (interp_set): Make static. Remove dead "Switching to" output
12555 code.
12556 (interp_quiet_p, interp_set_quiet): Delete.
12557 (interpreter_exec_cmd): Don't set the interpreter quiet.
12558 * interps.h (interp_quiet_p): Make static.
12559 (class interp) <quiet_p>: Remove field
12560
3d7b173c
JG
125612017-02-08 Jerome Guitton <guitton@adacore.com>
12562
604c4576
JG
12563 * cli/cli-decode.c (find_command_name_length): Make it extern.
12564 * cli/cli-decode.h (find_command_name_length): Declare.
12565 * cli/cli-script.c (command_name_equals, line_first_arg):
12566 New functions.
12567 (process_next_line): Use cli-decode to parse command names.
12568 (build_command_line): Make args a constant pointer.
12569
125702017-02-08 Jerome Guitton <guitton@adacore.com>
6dbb839a 12571
3d7b173c
JG
12572 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
12573 Remove case-insensitive search.
12574
1291063d
JM
125752017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
12576
12577 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
12578 at the end of the line. Avoids an ARI warning.
12579
20b477a7
LM
125802017-02-06 Luis Machado <lgustavo@codesourcery.com>
12581
12582 * NEWS: Mention support for record/replay of Intel 64 rdrand and
12583 rdseed instructions.
12584 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
12585
3f7b46f2
IR
125862017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
12587
12588 PR tdep/20936
12589 Provide and use sparc32 and sparc64 target description XML files.
12590 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
12591 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
12592 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
12593 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
12594 * features/sparc/sparc32-solaris.xml: New file.
12595 * features/sparc/sparc64-solaris.xml: New file.
12596 * features/sparc/sparc32-solaris.c: Generated.
12597 * features/sparc/sparc64-solaris.c: Generated.
12598 * sparc-tdep.h: Account for differences in target descriptions.
12599 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
12600 (sparc32_register_type): Use target provided registers.
12601 (validate_tdesc_registers): New function.
12602 (sparc32_gdbarch_init): Use tdesc_has_registers.
12603 Set pseudoregister functions.
12604 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
12605 (sparc64_register_type): Use target provided registers.
12606 (sparc64_init_abi): Set pseudoregister functions.
12607
f0fd41c1
TT
126082017-02-03 Tom Tromey <tom@tromey.com>
12609
12610 PR rust/21097:
12611 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
12612 with a single member.
12613
d6f9b0fb
PA
126142017-02-03 Pedro Alves <palves@redhat.com>
12615
12616 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
12617 (cli_interp_base::~cli_interp_base): New.
12618 (cli_interp): New struct.
12619 (as_cli_interp): Cast the interp itself to cli_interp.
12620 (cli_interpreter_pre_command_loop): Rename to ...
12621 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
12622 parameter.
12623 (cli_interpreter_init): Rename to ...
12624 (cli_interp::init): ... this. Remove 'self' parameter. Use
12625 boolean. Make extern.
12626 (cli_interpreter_resume): Rename to ...
12627 (cli_interp::resume): ... this. Remove 'data' parameter. Make
12628 extern.
12629 (cli_interpreter_suspend): Rename to ...
12630 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
12631 extern.
12632 (cli_interpreter_exec): Rename to ...
12633 (cli_interp::exec): ... this. Remove 'data' parameter. Make
12634 extern.
12635 (cli_interpreter_supports_command_editing): Rename to ...
12636 (cli_interp_base::supports_command_editing): ... this. Remove
12637 'interp' parameter. Make extern.
12638 (cli_ui_out): Rename to ...
12639 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
12640 Make extern.
12641 (cli_set_logging): Rename to ...
12642 (cli_interp_base::set_logging): ... this. Remove 'interp'
12643 parameter. Make extern.
12644 (cli_interp_procs): Delete.
12645 (cli_interp_factory): Adjust to use "new".
12646 * cli/cli-interp.h: Include "interps.h".
12647 (struct cli_interp_base): New struct.
12648 * interps.c (struct interp): Delete. Fields moved to interps.h.
12649 (interp_new): Delete.
12650 (interp::interp, interp::~interp): New.
12651 (interp_set): Use bool, and return void. Assume the interpreter
12652 has suspend, init and resume methods, and that the all return
12653 void.
12654 (set_top_level_interpreter): interp_set returns void.
12655 (interp_ui_out): Adapt.
12656 (current_interp_set_logging): Adapt.
12657 (interp_data): Delete.
12658 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
12659 (interp_exec): Adapt.
12660 (top_level_interpreter_data): Delete.
12661 * interps.h (interp_init_ftype, interp_resume_ftype)
12662 (interp_suspend_ftype, interp_exec_ftype)
12663 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
12664 (class interp): New.
12665 (interp_new): Delete.
12666 (interp_set): Now returns void. Use bool.
12667 (interp_data, top_level_interpreter_data): Delete.
12668 * mi/mi-common.h: Include interps.h.
12669 (class mi_interp): Inherit from interp. Define a ctor. Declare
12670 init, resume, suspect, exec, interp_ui_out, set_logging and
12671 pre_command_loop methods.
12672 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
12673 (mi_interpreter_init): Rename to ...
12674 (mi_interp::init): ... this. Remove the 'interp' parameter, use
12675 bool, return void and make extern. Adjust.
12676 (mi_interpreter_resume): ... Rename to ...
12677 (mi_interp::resume): ... this. Remove the 'data' parameter,
12678 return void and make extern. Adjust.
12679 (mi_interpreter_suspend): ... Rename to ...
12680 (mi_interp::suspend): ... this. Remove the 'data' parameter,
12681 return void and make extern. Adjust.
12682 (mi_interpreter_exec): ... Rename to ...
12683 (mi_interp::exec): ... this. Remove the 'data' parameter and make
12684 extern. Adjust.
12685 (mi_interpreter_pre_command_loop): ... Rename to ...
12686 (mi_interp::pre_command_loop): ... this. Remove the 'self'
12687 parameter and make extern.
12688 (mi_on_normal_stop_1): Adjust.
12689 (mi_ui_out): Rename to ...
12690 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
12691 parameter and make extern. Adjust.
12692 (mi_set_logging): Rename to ...
12693 (mi_interp::set_logging): ... this. Remove the 'interp'
12694 parameter and make extern. Adjust.
12695 (mi_interp_procs): Delete.
12696 (mi_interp_factory): Adjust to use 'new'.
12697 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
12698 (mi_print_exception, mi_execute_command, mi_load_progress):
12699 Adjust.
12700 * tui/tui-interp.c (tui_interp): New class.
12701 (as_tui_interp): Return a tui_interp pointer.
12702 (tui_on_normal_stop, tui_on_signal_received)
12703 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
12704 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
12705 to use interp::interp_ui_out.
12706 (tui_init): Rename to ...
12707 (tui_interp::init): ... this. Remove the 'self' parameter, use
12708 bool, return void and make extern. Adjust.
12709 (tui_resume): Rename to ...
12710 (tui_interp::resume): ... this. Remove the 'data' parameter,
12711 return void and make extern. Adjust.
12712 (tui_suspend): Rename to ...
12713 (tui_interp::suspend): ... this. Remove the 'data' parameter,
12714 return void and make extern. Adjust.
12715 (tui_ui_out): Rename to ...
12716 (tui_interp::interp_ui_out): ... this. Remove the 'self'
12717 parameter, and make extern. Adjust.
12718 (tui_exec): Rename to ...
12719 (tui_interp::exec): ... this. Remove the 'data' parameter and
12720 make extern.
12721 (tui_interp_procs): Delete.
12722 (tui_interp_factory): Use "new".
12723
65c40c95
TT
127242017-02-02 Tom Tromey <tom@tromey.com>
12725
12726 * rust-exp.y (ends_raw_string, space_then_number)
12727 (rust_identifier_start_p): Return bool.
12728 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
12729 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
12730 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
12731 (rust_chartype_p): Return bool.
12732 (val_print_struct, rust_print_struct_def, rust_print_type):
12733 Update.
12734 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
12735 Return bool.
12736
b50f188d
TT
127372017-02-02 Tom Tromey <tom@tromey.com>
12738
12739 * rust-lang.c: Reindent.
12740
03c85b11
TT
127412017-02-02 Tom Tromey <tom@tromey.com>
12742
12743 * rust-lang.h (rust_crate_for_block): Update.
12744 * rust-lang.c (rust_crate_for_block): Return std::string.
12745 (rust_get_disr_info): Use std:;string, not
12746 gdb::unique_xmalloc_ptr.
12747 * rust-exp.y (crate_name): Update.
12748
9b6da501
PA
127492017-02-02 Pedro Alves <palves@redhat.com>
12750
12751 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
12752 field out of gdb_disassembler_test and make it static.
12753
ec4cb20b
PA
127542017-02-02 Pedro Alves <palves@redhat.com>
12755
12756 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
12757 mi1_interp and mi_interp fields.
12758
5be5dbf0
PA
127592017-02-02 Pedro Alves <palves@redhat.com>
12760
616268b6
PA
12761 * cli/cli-interp.c (struct saved_output_files, saved_output):
12762 Moved from cli/cli-logging.c.
12763 (cli_set_logging): New function.
12764 (cli_interp_procs): Install cli_set_logging.
12765 * cli/cli-interp.h (make_logging_output, cli_set_logging):
12766 Declare.
12767 * cli/cli-logging.c (struct saved_output_files, saved_output):
12768 Moved to cli/cli-interp.c.
12769 (pop_output_files): Don't save outputs here.
12770 (make_logging_output): New function.
12771 (handle_redirections): Don't build tee nor save previous outputs
12772 here.
12773 * interps.c (current_interp_set_logging): Change prototype.
12774 Assume there's always a set_logging_proc method installed.
12775 * interps.h (interp_set_logging_ftype): Change prototype.
12776 (current_interp_set_logging): Change prototype and adjust comment.
12777 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
12778 use make_logging_output.
12779 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
127802017-02-02 Pedro Alves <palves@redhat.com>
12781
5be5dbf0
PA
12782 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
12783 from ...
12784 (set_logging_overwrite): ... here.
12785 (logging_no_redirect_file): Delete.
12786 (set_logging_redirect): Don't handle redirection on the fly.
12787 Instead warn that "logging off" / "logging on" is necessary.
12788 (pop_output_files): Delete references to logging_no_redirect_file.
12789 (show_logging_command): Always speak in terms of what will happen
12790 once logging is reenabled.
12791
c99cc448
PA
127922017-02-02 Pedro Alves <palves@redhat.com>
12793
12794 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
12795
8b172ce7
PA
127962017-02-02 Pedro Alves <palves@redhat.com>
12797
12798 * disasm.c (gdb_pretty_print_insn): Rename to ...
12799 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
12800 Remove gdbarch parameter. Adapt to clear the object's buffers
12801 instead of allocating new buffers, and to print using the object's
12802 gdb_disassembler instead of calling gdb_print_insn.
12803 (dump_insns): Use gdb_pretty_print_disassembler.
12804 * disasm.h (gdb_pretty_print_insn): Delete declaration.
12805 (gdb_pretty_print_disassembler): New class.
12806 * record-btrace.c (btrace_insn_history): Use
12807 gdb_pretty_print_disassembler.
12808
d7e74731
PA
128092017-02-02 Pedro Alves <palves@redhat.com>
12810
12811 * ada-lang.c (type_as_string): Use string_file.
12812 * ada-valprint.c (ada_print_floating): Use string_file.
12813 * ada-varobj.c (ada_varobj_scalar_image)
12814 (ada_varobj_get_value_image): Use string_file.
12815 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
12816 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
12817 * breakpoint.c (update_inserted_breakpoint_locations)
12818 (insert_breakpoint_locations, reattach_breakpoints)
12819 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
12820 (print_it_watchpoint): Use string_file.
12821 (save_breakpoints): Use stdio_file.
12822 * c-exp.y (oper): Use string_file.
12823 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
12824 tee_file.
12825 (pop_output_files): Use delete.
12826 (handle_redirections): Use stdio_file and tee_file.
12827 * cli/cli-setshow.c (do_show_command): Use string_file.
12828 * compile/compile-c-support.c (c_compute_program): Use
12829 string_file.
12830 * compile/compile-c-symbols.c (generate_vla_size): Take a
12831 'string_file &' instead of a 'ui_file *'.
12832 (generate_c_for_for_one_variable): Take a 'string_file &' instead
12833 of a 'ui_file *'. Use string_file.
12834 (generate_c_for_variable_locations): Take a 'string_file &'
12835 instead of a 'ui_file *'.
12836 * compile/compile-internal.h (generate_c_for_for_one_variable):
12837 Take a 'string_file &' instead of a 'ui_file *'.
12838 * compile/compile-loc2c.c (push, pushf, unary, binary)
12839 (print_label, pushf_register_address, pushf_register)
12840 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
12841 'ui_file *'. Adjust.
12842 * compile/compile.c (compile_to_object): Use string_file.
12843 * compile/compile.h (compile_dwarf_expr_to_c)
12844 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
12845 'ui_file *'.
12846 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
12847 (replace_typedefs_qualified_name): Use string_file and
12848 obstack_copy0.
12849 * disasm.c (gdb_pretty_print_insn): Use string_file.
12850 (gdb_disassembly): Adjust reference the null_stream global.
12851 (do_ui_file_delete): Delete.
12852 (gdb_insn_length): Use null_stream.
12853 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
12854 * dwarf2loc.c (dwarf2_compile_property_to_c)
12855 (locexpr_generate_c_location, loclist_generate_c_location): Take a
12856 'string_file &' instead of a 'ui_file *'.
12857 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
12858 * dwarf2read.c (do_ui_file_peek_last): Delete.
12859 (dwarf2_compute_name): Use string_file.
12860 * event-top.c (gdb_setup_readline): Use stdio_file.
12861 * gdbarch.sh (verify_gdbarch): Use string_file.
12862 * gdbtypes.c (safe_parse_type): Use null_stream.
12863 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
12864 string_file.
12865 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
12866 'string_file *' instead of a 'ui_file *'.
12867 (gdbscm_arch_disassemble): Use string_file.
12868 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
12869 * guile/scm-ports.c (class ioscm_file_port): Now a class that
12870 inherits from ui_file.
12871 (ioscm_file_port_delete, ioscm_file_port_rewind)
12872 (ioscm_file_port_put): Delete.
12873 (ioscm_file_port_write): Rename to ...
12874 (ioscm_file_port::write): ... this. Remove file_port_magic
12875 checks.
12876 (ioscm_file_port_new): Delete.
12877 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
12878 ui_file_up.
12879 * guile/scm-type.c (tyscm_type_name): Use string_file.
12880 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
12881 Use string_file.
12882 * infcmd.c (print_return_value_1): Use string_file.
12883 * infrun.c (print_target_wait_results): Use string_file.
12884 * language.c (add_language): Use string_file.
12885 * location.c (explicit_to_string_internal): Use string_file.
12886 * main.c (captured_main_1): Use null_file.
12887 * maint.c (maintenance_print_architecture): Use stdio_file.
12888 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
12889 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
12890 event_channel>: Change type to mi_console_file pointer.
12891 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
12892 (mi_console_file_delete): Delete.
12893 (struct mi_console_file): Delete.
12894 (mi_console_file_magic): Delete.
12895 (mi_console_file_new): Delete.
12896 (mi_console_file::mi_console_file): New.
12897 (mi_console_file_delete): Delete.
12898 (mi_console_file_fputs): Delete.
12899 (mi_console_file::write): New.
12900 (mi_console_raw_packet): Delete.
12901 (mi_console_file::flush): New.
12902 (mi_console_file_flush): Delete.
12903 (mi_console_set_raw): Rename to ...
12904 (mi_console_file::set_raw): ... this.
12905 * mi/mi-console.h (class mi_console_file): New class.
12906 (mi_console_file_new, mi_console_set_raw): Delete.
12907 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
12908 (mi_set_logging): Use delete and tee_file. Adjust.
12909 * mi/mi-main.c (output_register): Use string_file.
12910 (mi_cmd_data_evaluate_expression): Use string_file.
12911 (mi_cmd_data_read_memory): Use string_file.
12912 (mi_cmd_execute, print_variable_or_computed): Use string_file.
12913 * mi/mi-out.c (mi_ui_out::main_stream): New.
12914 (mi_ui_out::rewind): Use main_stream and
12915 string_file.
12916 (mi_ui_out::put): Use main_stream and string_file.
12917 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
12918 Allocate a 'string_file' instead.
12919 (mi_out_new): Don't allocate a mem_fileopen stream here.
12920 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
12921 (mi_ui_out::main_stream): Declare method.
12922 * printcmd.c (eval_command): Use string_file.
12923 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
12924 * python/py-arch.c (archpy_disassemble): Use string_file.
12925 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
12926 * python/py-frame.c (frapy_str): Use string_file.
12927 * python/py-framefilter.c (py_print_type, py_print_single_arg):
12928 Use string_file.
12929 * python/py-type.c (typy_str): Use string_file.
12930 * python/py-unwind.c (unwind_infopy_str): Use string_file.
12931 * python/py-value.c (valpy_str): Use string_file.
12932 * record-btrace.c (btrace_insn_history): Use string_file.
12933 * regcache.c (regcache_print): Use stdio_file.
12934 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
12935 * remote.c (escape_buffer): Use string_file.
12936 * rust-lang.c (rust_get_disr_info): Use string_file.
12937 * serial.c (serial_open_ops_1): Use stdio_file.
12938 (do_serial_close): Use delete.
12939 * stack.c (print_frame_arg): Use string_file.
12940 (print_frame_args): Remove local mem_fileopen stream, not used.
12941 (print_frame): Use string_file.
12942 * symmisc.c (maintenance_print_symbols): Use stdio_file.
12943 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
12944 Take a 'string_file *' instead of a 'ui_file *'.
12945 * top.c (new_ui): Use stdio_file and stderr_file.
12946 (free_ui): Use delete.
12947 (execute_command_to_string): Use string_file.
12948 (quit_confirm): Use string_file.
12949 * tracepoint.c (collection_list::append_exp): Use string_file.
12950 * tui/tui-disasm.c (tui_disassemble): Use string_file.
12951 * tui/tui-file.c: Don't include "ui-file.h".
12952 (enum streamtype, struct tui_stream): Delete.
12953 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
12954 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
12955 (tui_file::tui_file): New method.
12956 (tui_file_fputs): Delete.
12957 (tui_file_get_strbuf): Delete.
12958 (tui_file::puts): New method.
12959 (tui_file_adjust_strbuf): Delete.
12960 (tui_file_flush): Delete.
12961 (tui_file::flush): New method.
12962 * tui/tui-file.h: Tweak intro comment.
12963 Include ui-file.h.
12964 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
12965 (tui_file_adjust_strbuf): Delete declarations.
12966 (class tui_file): New class.
12967 * tui/tui-io.c (tui_initialize_io): Use tui_file.
12968 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
12969 (tui_register_format): Use string_stream.
12970 * tui/tui-stack.c (tui_make_status_line): Use string_file.
12971 (tui_get_function_from_frame): Use string_file.
12972 * typeprint.c (type_to_string): Use string_file.
12973 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
12974 (null_stream): New global.
12975 (ui_file_delete): Delete.
12976 (ui_file::ui_file): New.
12977 (null_file_isatty): Delete.
12978 (ui_file::~ui_file): New.
12979 (null_file_rewind): Delete.
12980 (ui_file::printf): New.
12981 (null_file_put): Delete.
12982 (null_file_flush): Delete.
12983 (ui_file::putstr): New.
12984 (null_file_write): Delete.
12985 (ui_file::putstrn): New.
12986 (null_file_read): Delete.
12987 (ui_file::putc): New.
12988 (null_file_fputs): Delete.
12989 (null_file_write_async_safe): Delete.
12990 (ui_file::vprintf): New.
12991 (null_file_delete): Delete.
12992 (null_file::write): New.
12993 (null_file_fseek): Delete.
12994 (null_file::puts): New.
12995 (ui_file_data): Delete.
12996 (null_file::write_async_safe): New.
12997 (gdb_flush, ui_file_isatty): Adjust.
12998 (ui_file_put, ui_file_rewind): Delete.
12999 (ui_file_write): Adjust.
13000 (ui_file_write_for_put): Delete.
13001 (ui_file_write_async_safe, ui_file_read): Adjust.
13002 (ui_file_fseek): Delete.
13003 (fputs_unfiltered): Adjust.
13004 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
13005 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
13006 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
13007 (set_ui_file_data): Delete.
13008 (string_file::~string_file, string_file::write)
13009 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
13010 (do_ui_file_as_string, ui_file_as_string): Delete.
13011 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
13012 (struct mem_file): Delete.
13013 (mem_file_new): Delete.
13014 (stdio_file::stdio_file): New.
13015 (mem_file_delete): Delete.
13016 (stdio_file::stdio_file): New.
13017 (mem_fileopen): Delete.
13018 (stdio_file::~stdio_file): New.
13019 (mem_file_rewind): Delete.
13020 (stdio_file::set_stream): New.
13021 (mem_file_put): Delete.
13022 (stdio_file::open): New.
13023 (mem_file_write): Delete.
13024 (stdio_file_magic, struct stdio_file): Delete.
13025 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
13026 (stdio_file::flush): New.
13027 (stdio_file_read): Rename to ...
13028 (stdio_file::read): ... this. Adjust.
13029 (stdio_file_write): Rename to ...
13030 (stdio_file::write): ... this. Adjust.
13031 (stdio_file_write_async_safe): Rename to ...
13032 (stdio_file::write_async_safe) ... this. Adjust.
13033 (stdio_file_fputs): Rename to ...
13034 (stdio_file::puts) ... this. Adjust.
13035 (stdio_file_isatty): Delete.
13036 (stdio_file_fseek): Delete.
13037 (stdio_file::isatty): New.
13038 (stderr_file_write): Rename to ...
13039 (stderr_file::write) ... this. Adjust.
13040 (stderr_file_fputs): Rename to ...
13041 (stderr_file::puts) ... this. Adjust.
13042 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
13043 (stderr_file::stderr_file): New.
13044 (tee_file_magic): Delete.
13045 (struct tee_file): Delete.
13046 (tee_file::tee_file): New.
13047 (tee_file_new): Delete.
13048 (tee_file::~tee_file): New.
13049 (tee_file_delete): Delete.
13050 (tee_file_flush): Rename to ...
13051 (tee_file::flush): ... this. Adjust.
13052 (tee_file_write): Rename to ...
13053 (tee_file::write): ... this. Adjust.
13054 (tee_file::write_async_safe): New.
13055 (tee_file_fputs): Rename to ...
13056 (tee_file::puts): ... this. Adjust.
13057 (tee_file_isatty): Rename to ...
13058 (tee_file::isatty): ... this. Adjust.
13059 * ui-file.h (struct obstack, struct ui_file): Don't
13060 forward-declare.
13061 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
13062 (ui_file_write_ftype)
13063 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
13064 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
13065 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
13066 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
13067 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
13068 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
13069 (set_ui_file_fseek): Delete.
13070 (ui_file_data, ui_file_delete, ui_file_rewind)
13071 (struct ui_file): New.
13072 (ui_file_up): New.
13073 (class null_file): New.
13074 (null_stream): Declare.
13075 (ui_file_write_for_put, ui_file_put): Delete.
13076 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
13077 Delete.
13078 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
13079 (gdb_fopen, tee_file_new): Delete.
13080 (struct string_file): New.
13081 (struct stdio_file): New.
13082 (stdio_file_up): New.
13083 (struct stderr_file): New.
13084 (class tee_file): New.
13085 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
13086 of a 'ui_file *'. Adjust.
13087 * ui-out.h (class ui_out) <field_stream>: Likewise.
13088 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
13089 (null_stream): Delete.
13090 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
13091 Adjust.
13092 * utils.h (struct ui_file): Delete forward declaration..
13093 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
13094 (error_stream): Take a 'string_file &' instead of a
13095 'ui_file *'.
13096 * varobj.c (varobj_value_get_print_value): Use string_file.
13097 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
13098 * gdbarch.c: Regenerate.
13099
187808b0
PA
131002017-02-02 Pedro Alves <palves@redhat.com>
13101
13102 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
13103 (gdb_pretty_print_insn): ... this. Now a free function. Add back
13104 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
13105 Adjust to call gdb_print_insn instead of
13106 gdb_disassembler::print_insn.
13107 (dump_insns, do_mixed_source_and_assembly_deprecated)
13108 (do_mixed_source_and_assembly, do_assembly_only): Add back a
13109 'gdbarch' parameter. Remove gdb_disassembler parameter.
13110 (gdb_disassembly): Don't allocate a gdb_disassembler here.
13111 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
13112 declaration.
13113 (gdb_pretty_print_insn): Re-add declaration.
13114 * record-btrace.c (btrace_insn_history): Don't allocate a
13115 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
13116
7a8eb317
SM
131172017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
13118
13119 * disasm.h (gdb_disassembly): Remove file_string parameter.
13120 * disasm.c (gdb_disassembly): Likewise.
13121 * cli/cli-cmds.c (print_disassembly): Adapt.
13122 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
13123 * stack.c (do_gdb_disassembly): Likewise.
13124
7346ef59
AA
131252017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
13126
13127 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
13128 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
13129 targets. And if the implicit value is longer than needed, extract
13130 the first bytes instead of the "least significant" ones.
13131
cd4007e4
MM
131322017-02-01 Markus Metzger <markus.t.metzger@intel.com>
13133
13134 * btrace.c (btrace_enable): Do not call btrace_add_pc for
13135 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
13136 (btrace_fetch): Assert can_access_registers_ptid.
13137 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
13138 validate_registers_access.
13139
cf77c34e
MM
131402017-02-01 Markus Metzger <markus.t.metzger@intel.com>
13141
13142 * gdbthread.h (can_access_registers_ptid): New.
13143 * thread.c (can_access_registers_ptid): New.
13144
be85ce7d
PA
131452017-02-01 Pedro Alves <palves@redhat.com>
13146
13147 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
13148
29b0b251
PA
131492017-01-31 Pedro Alves <palves@redhat.com>
13150
13151 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
13152 Fix typos.
13153
289b5b24
PA
131542017-01-31 Pedro Alves <palves@redhat.com>
13155
13156 * stack.c (print_frame_args): Remove local mem_fileopen stream,
13157 not used.
13158
b47413b4
PA
131592017-01-31 Pedro Alves <palves@redhat.com>
13160
13161 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
13162
60adb36c
PA
131632017-01-31 Pedro Alves <palves@redhat.com>
13164
13165 * common/scoped_restore.h
13166 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
13167 change the value's parameter type to T2.
13168 (make_scoped_restore): Likewise.
13169
2735833d
WT
131702017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
13171 Richard Henderson <rth@redhat.com>
13172
13173 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
13174 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
13175 GS_BASE for older kernels.
13176 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
13177 GS_BASE for older kernels.
13178 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
13179 and GS_BASE to the offset table.
13180 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
13181 system register group.
13182 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
13183 for older kernels.
13184 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
13185 amd64 ABI.
13186 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
13187 AMD64_GSBASE_REGNUM.
13188 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
13189 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
13190 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
13191 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
13192 i386/64bit-segments.xml in those rules.
13193 * features/i386/64bit-segments.xml: New file.
13194 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
13195 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
13196 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
13197 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
13198 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
13199 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
13200 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
13201 * features/i386/amd64-avx-linux.c: Regenerated.
13202 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
13203 * features/i386/amd64-avx-mpx.c: Regenerated.
13204 * features/i386/amd64-avx512-linux.c: Regenerated.
13205 * features/i386/amd64-linux.c: Regenerated.
13206 * features/i386/amd64-mpx-linux.c: Regenerated.
13207 * features/i386/i386-avx-mpx-linux.c: Regenerated.
13208 * features/i386/i386-avx-mpx.c: Regenerated.
13209 * features/i386/x32-avx-linux.c: Regenerated.
13210 * features/i386/x32-avx512-linux.c: Regenerated.
13211 * regformats/i386/amd64-avx-linux.dat: Regenerated.
13212 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
13213 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
13214 * regformats/i386/amd64-linux.dat: Regenerated.
13215 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
13216 * regformats/i386/x32-avx-linux.dat: Regenerated.
13217 * regformats/i386/x32-avx512-linux.dat: Regenerated.
13218 * regformats/i386/x32-linux.dat: Regenerated.
13219
8884e97e
WT
132202017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
13221
13222 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
13223 Set to AMD64_NUM_REGS.
13224
7005d26a
WT
132252017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
13226
13227 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
13228 that checks validity of a register number.
13229
4bd2e1b2
KC
132302017-01-27 Kees Cook <keescook@google.com>
13231
13232 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
13233 fetch_fpregs if target has fpa registers.
13234 (arm_linux_store_inferior_registers): Call store_fpregs if target
13235 has fpa registers.
13236
7cf1de6c
AA
132372017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
13238
13239 * cris-tdep.c (cris_gdbarch_init): Remove check for
13240 info.byte_order and force it to BFD_ENDIAN_LITTLE.
13241
874a1c8c
AT
132422017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
13243
13244 * corelow.c (get_core_register_section): Check for regset
13245 existence before checking for REGSET_VARIABLE_SIZE.
13246
d8b49cf0
YQ
132472017-01-26 Yao Qi <yao.qi@linaro.org>
13248 Pedro Alves <palves@redhat.com>
13249
13250 PR gdb/20939
13251 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
13252 call memory_error, save memaddr instead.
13253 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
13254 negative, cal memory_error.
13255 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
13256
658ca58c
YQ
132572017-01-26 Yao Qi <yao.qi@linaro.org>
13258
13259 * disasm-selftests.c (memory_error_test): New function.
13260 (_initialize_disasm_selftests): Register memory_error_test.
13261
79843d45
YQ
132622017-01-26 Yao Qi <yao.qi@linaro.org>
13263
13264 * Makefile.in (SFILES): Add disasm-selftests.c and
13265 selftest-arch.c.
13266 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
13267 * disasm-selftests.c: New file.
13268 * selftest-arch.c: New file.
13269 * selftest-arch.h: New file.
13270
8cafda32
YQ
132712017-01-26 Yao Qi <yao.qi@linaro.org>
13272
13273 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
13274 to bfd_arch_mep. Don't return 0 if section is not
13275 found. Call print_insn_mep.
13276
e47ad6c0
YQ
132772017-01-26 Pedro Alves <palves@redhat.com>
13278 Yao Qi <yao.qi@linaro.org>
13279
13280 * arm-tdep.c: Include "disasm.h".
13281 (gdb_print_insn_arm): Update code to get gdbarch.
13282 * disasm.c (dis_asm_read_memory): Change it to
13283 gdb_disassembler::dis_asm_read_memory.
13284 (dis_asm_memory_error): Likewise.
13285 (dis_asm_print_address): Likewise.
13286 (gdb_pretty_print_insn): Change it to
13287 gdb_disassembler::pretty_print_insn.
13288 (dump_insns): Add one argument gdb_disassemlber. All
13289 callers updated.
13290 (do_mixed_source_and_assembly_deprecated): Likewise.
13291 (do_mixed_source_and_assembly): Likewise.
13292 (do_assembly_only): Likewise.
13293 (gdb_disassembler::gdb_disassembler): New.
13294 (gdb_disassembler::print_insn): New.
13295 * disasm.h (class gdb_disassembler): New.
13296 (gdb_pretty_print_insn): Remove declaration.
13297 (gdb_disassemble_info): Likewise.
13298 * guile/scm-disasm.c (class gdbscm_disassembler): New.
13299 (gdbscm_disasm_read_memory_worker): Update.
13300 (gdbscm_disasm_read_memory): Update.
13301 (gdbscm_disasm_memory_error): Remove.
13302 (gdbscm_disasm_print_address): Remove.
13303 (gdbscm_disassembler::gdbscm_disassembler): New.
13304 (gdbscm_print_insn_from_port): Update.
13305 * mips-tdep.c: Include disasm.h.
13306 (gdb_print_insn_mips): Update code to get gdbarch.
13307 * record-btrace.c (btrace_insn_history): Update.
13308 * spu-tdep.c: Include disasm.h.
13309 (struct spu_dis_asm_data): Remove.
13310 (struct spu_dis_asm_info): New.
13311 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
13312 SPU id.
13313 (gdb_print_insn_spu): Cast disassemble_info to
13314 spu_dis_asm_info.
13315
80d75874
YQ
133162017-01-26 Yao Qi <yao.qi@linaro.org>
13317
13318 * disasm.c (do_ui_file_delete): Delete.
13319 (gdb_insn_length): Move code creating stream to ...
13320 * utils.c (null_stream): ... here. New function.
13321 * utils.h (null_stream): Declare.
13322
60685cd0
SM
133232017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
13324
13325 * python/py-inferior.c (find_thread_object): Return directly
13326 from the loop. Remove "found" variable.
13327
eb1cdb62
JB
133282017-01-21 Joel Brobecker <brobecker@adacore.com>
13329
13330 GDB 7.12.1 released.
13331
b1ce6568
SM
133322017-01-20 Simon Marchi <simon.marchi@ericsson.com>
13333
13334 * python/py-function.c (fnpy_call): Reorder declarations to have
13335 the gdbpy_enter object declared first.
13336 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
13337
6f8b0407
SM
133382017-01-20 Simon Marchi <simon.marchi@ericsson.com>
13339
fec93fb1 13340 PR python/21068
6f8b0407
SM
13341 * python/python-internal.h (PyMem_RawMalloc): Define for
13342 Python < 3.4.
13343 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
13344 PyMem_RawMalloc instead of PyMem_Malloc.
13345
78cbbba8
LM
133462017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
13347 Luis Machado <lgustavo@codesourcery.com>
13348
13349 * NEWS (New commands): Mention flash-erase.
13350 (New MI commands): Mention target-flash-erase.
13351 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
13352 command.
13353 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
13354 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
13355 * target.c (flash_erase_command): New function.
13356 (initialize_targets): Add new flash-erase command.
13357 * target.h (flash_erase_command): New declaration.
13358
2132fe85
JB
133592017-01-20 Joel Brobecker <brobecker@adacore.com>
13360
13361 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
13362 HAVE_SYS_PROCFS_H is defined.
13363
d1dff226
AH
133642017-01-18 Alan Hayward <alan.hayward@arm.com>
13365
13366 * remote.c (struct cached_reg): Change data into a pointer.
13367 * (stop_reply_dtr): Free data pointers before deleting vector.
13368 (process_stop_reply): Likewise.
13369 (remote_parse_stop_reply): Allocate space for data
13370
9890e433
AH
133712017-01-18 Alan Hayward <alan.hayward@arm.com>
13372
13373 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
13374 MAX_REGISTER_SIZE.
13375 (amd64_pseudo_register_read_value): Likewise.
13376 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
13377 (store_register_using_P): Likewise.
13378 * regcache.c (regcache_xfer_part): Likewise.
13379
7a36499a
IR
133802017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
13381
13382 Split real and pseudo registers.
13383 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
13384 (sparc32_pseudo_regnum): New enum.
13385 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
13386 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
13387 (SPARC32_CP0_REGISTERS): New macro.
13388 (sparc32_pseudo_register_name): New function.
13389 (sparc32_register_name): Use sparc32_pseudo_register_name.
13390 (sparc32_pseudo_register_type): New function.
13391 (sparc32_register_type): Use sparc32_pseudo_register_type.
13392 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
13393 pseudo register numbers.
13394 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
13395 (SPARC64_CP0_REGISTERS): New macro.
13396 (sparc64_pseudo_register_name): New function.
13397 (sparc64_register_name): Use sparc64_pseudo_register_name.
13398 (sparc64_pseudo_register_type): New function.
13399 (sparc64_register_type): Use sparc64_pseudo_register_type.
13400 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
13401 pseudo register numbers.
13402 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
13403 sparc64_store_arguments): Handle pseudo register numbers.
13404
6f8976bf
YQ
134052017-01-13 Yao Qi <yao.qi@linaro.org>
13406
13407 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
13408 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
13409 output.
13410 (getpkt_or_notif_sane_1): Likewise.
13411
e4241ace
YQ
134122017-01-13 Yao Qi <yao.qi@linaro.org>
13413
13414 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
13415 of CC. Pass "-x c++-header" instead of "-x c".
13416
3015c064
SM
134172017-01-12 Simon Marchi <simon.marchi@ericsson.com>
13418
13419 * remote.c (remote_can_async_p): Update comment.
13420
fde1b17d
SM
134212017-01-12 Simon Marchi <simon.marchi@ericsson.com>
13422
13423 * linux-nat.c (linux_nat_can_async_p): Update comment.
13424
ca1ca08b
SM
134252017-01-12 Simon Marchi <simon.marchi@ericsson.com>
13426
13427 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
13428
4ad2da73
SM
134292017-01-11 Simon Marchi <simon.marchi@ericsson.com>
13430
13431 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
13432
c8b23b3f
TT
134332017-01-10 Tom Tromey <tom@tromey.com>
13434
13435 * python/py-type.c (typy_legacy_template_argument): Update.
13436 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
13437 ~demangle_parse_info): Declare new members.
13438 (cp_demangled_name_to_comp): Return unique_ptr.
13439 (cp_demangled_name_parse_free)
13440 (make_cleanup_cp_demangled_name_parse_free)
13441 (cp_new_demangle_parse_info): Remove.
13442 * cp-support.c (do_demangled_name_parse_free_cleanup)
13443 (make_cleanup_cp_demangled_name_parse_free): Remove.
13444 (inspect_type, cp_canonicalize_string_full)
13445 (cp_canonicalize_string): Update.
13446 (mangled_name_to_comp): Change return type.
13447 (cp_class_name_from_physname, method_name_from_physname)
13448 (cp_func_name, cp_remove_params): Update.
13449 * cp-name-parser.y (demangle_parse_info): New constructor, from
13450 cp_new_demangle_parse_info.
13451 (~demangle_parse_info): New destructor, from
13452 cp_demangled_name_parse_free.
13453 (cp_merge_demangle_parse_infos): Update.
13454 (cp_demangled_name_to_comp): Change return type.
13455
1ac32117
TT
134562017-01-10 Tom Tromey <tom@tromey.com>
13457
13458 * top.c (prevent_dont_repeat): Change return type.
13459 * python/python.c (execute_gdb_command): Use std::string.
13460 Update.
13461 * guile/guile.c (gdbscm_execute_gdb_command): Update.
13462 * command.h (prevent_dont_repeat): Change return type.
13463 * breakpoint.c (bpstat_do_actions_1): Update.
13464
0cf08227
TT
134652017-01-10 Tom Tromey <tom@tromey.com>
13466
13467 * value.h (scoped_value_mark::~scoped_value_mark): Call
13468 free_to_mark.
13469 (scoped_value_mark::free_to_mark): New method.
13470 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
13471 scoped_value_mark.
13472
eb115069
TT
134732017-01-10 Tom Tromey <tom@tromey.com>
13474
13475 * python/py-value.c (valpy_dereference, valpy_referenced_value)
13476 (valpy_reference_value, valpy_const_value, valpy_get_address)
13477 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
13478 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
13479 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
13480 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
13481 scoped_value_mark.
13482 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
13483 * value.h (scoped_value_mark): New class.
13484
906768f9
TT
134852017-01-10 Tom Tromey <tom@tromey.com>
13486
13487 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
13488 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
13489 * psymtab.c (discard_psymtabs_upto): Remove.
13490 (make_cleanup_discard_psymtabs): Remove.
13491 (struct psymtab_state): Remove.
13492
bef155c3
TT
134932017-01-10 Tom Tromey <tom@tromey.com>
13494
13495 * record-full.c (record_full_save_cleanups): Remove.
13496 (record_full_save): Use gdb::unlinker.
13497 * gcore.c (do_bfd_delete_cleanup): Remove.
13498 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
13499 cleanups.
13500 * dwarf2read.c (unlink_if_set): Remove.
13501 (write_psymtabs_to_index): Use gdb::unlinker.
13502 * common/gdb_unlinker.h: New file.
13503
192b62ce
TT
135042017-01-10 Tom Tromey <tom@tromey.com>
13505
13506 * windows-tdep.c (windows_xfer_shared_library): Update.
13507 * windows-nat.c (windows_make_so): Update.
13508 * utils.h (make_cleanup_bfd_unref): Remove.
13509 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
13510 * symfile.h (symfile_bfd_open)
13511 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
13512 * symfile.c (read_symbols, symbol_file_add)
13513 (separate_debug_file_exists): Update.
13514 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
13515 (generic_load, reread_symbols): Update.
13516 * symfile-mem.c (symbol_file_add_from_memory): Update.
13517 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
13518 (spu_symbol_file_add_from_memory): Update.
13519 * solist.h (struct target_so_ops) <bfd_open>: Return
13520 gdb_bfd_ref_ptr.
13521 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
13522 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
13523 gdb_bfd_ref_ptr.
13524 (solib_map_sections, reload_shared_libraries_1): Update.
13525 * solib-svr4.c (enable_break): Update.
13526 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
13527 * solib-frv.c (enable_break2): Update.
13528 * solib-dsbt.c (enable_break): Update.
13529 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
13530 gdb_bfd_ref_ptr.
13531 (darwin_solib_get_all_image_info_addr_at_init): Update.
13532 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
13533 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
13534 * record-full.c (record_full_save): Update.
13535 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
13536 * procfs.c (insert_dbx_link_bpt_in_file): Update.
13537 * minidebug.c (find_separate_debug_file_in_section): Return
13538 gdb_bfd_ref_ptr.
13539 * machoread.c (macho_add_oso_symfile): Change abfd to
13540 gdb_bfd_ref_ptr.
13541 (macho_symfile_read_all_oso): Update.
13542 (macho_check_dsym): Return gdb_bfd_ref_ptr.
13543 (macho_symfile_read): Update.
13544 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
13545 (jit_bfd_try_read_symtab): Update.
13546 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
13547 (gdb_bfd_openw, gdb_bfd_openr_iovec)
13548 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
13549 gdb_bfd_ref_ptr.
13550 (gdb_bfd_ref_policy): New struct.
13551 (gdb_bfd_ref_ptr): New typedef.
13552 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
13553 (gdb_bfd_openw, gdb_bfd_openr_iovec)
13554 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
13555 gdb_bfd_ref_ptr.
13556 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
13557 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
13558 (gcore_command): Update.
13559 * exec.c (exec_file_attach): Update.
13560 * elfread.c (elf_symfile_read): Update.
13561 * dwarf2read.c (dwarf2_get_dwz_file): Update.
13562 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
13563 (open_and_init_dwo_file): Update.
13564 (open_dwp_file): Return gdb_bfd_ref_ptr.
13565 (open_and_init_dwp_file): Update.
13566 * corelow.c (core_open): Update.
13567 * compile/compile-object-load.c (compile_object_load): Update.
13568 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
13569 * coffread.c (coff_symfile_read): Update.
13570 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
13571 gdb_bfd_ref_ptr. Rename.
13572 (dump_bfd_file, restore_command): Update.
13573 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
13574 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
13575 (find_separate_debug_file_by_buildid): Update.
13576
50315b21
TT
135772017-01-10 Tom Tromey <tom@tromey.com>
13578
13579 * common/gdb_ref_ptr.h: New file.
13580 * python/py-ref.h (struct gdbpy_ref_policy): New.
13581 (gdbpy_ref): Now a typedef.
13582
fc4007c9
TT
135832017-01-10 Tom Tromey <tom@tromey.com>
13584
13585 * utils.h (make_cleanup_htab_delete): Don't declare.
13586 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
13587 Remove.
13588 * linespec.c (decode_compound_collector): Add constructor,
13589 destructor.
13590 (lookup_prefix_sym): Remove cleanup.
13591 (symtab_collector): Add constructor, destructor.
13592 (collect_symtabs_from_filename): Remove cleanup.
13593 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
13594 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
13595 Use htab_up.
13596 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
13597 * dwarf2read.c (dw2_expand_symtabs_matching)
13598 (dw2_map_symbol_filenames, dwarf_decode_macros)
13599 (write_psymtabs_to_index): Use htab_up.
13600 * dwarf2loc.c (func_verify_no_selftailcall)
13601 (call_site_find_chain_1, func_verify_no_selftailcall)
13602 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
13603 std::vector, gdb::unique_xmalloc_ptr.
13604 (call_sitep): Remove typedef.
13605 (dwarf2_locexpr_baton_eval): Remove unused variable.
13606
8dbcee67
TT
136072017-01-10 Tom Tromey <tom@tromey.com>
13608
13609 * python/python-internal.h (make_cleanup_py_decref)
13610 (make_cleanup_py_xdecref): Don't declare.
13611 * python/py-utils.c (py_decref, make_cleanup_py_decref)
13612 (py_xdecref, make_cleanup_py_xdecref): Remove.
13613
13df46cc
TT
136142017-01-10 Tom Tromey <tom@tromey.com>
13615
13616 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
13617 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
13618
06fc9bf7
TT
136192017-01-10 Tom Tromey <tom@tromey.com>
13620
13621 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
13622
830a4934
TT
136232017-01-10 Tom Tromey <tom@tromey.com>
13624
13625 * python/py-utils.c (unicode_to_encoded_string)
13626 (python_string_to_target_string)
13627 (python_string_to_target_python_string)
13628 (python_string_to_host_string, gdbpy_obj_to_string)
13629 (get_addr_from_python): Use gdbpy_ref.
13630
4586d543
TT
136312017-01-10 Tom Tromey <tom@tromey.com>
13632
13633 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
13634 gdbpy_ref.
13635
59876f8f
TT
136362017-01-10 Tom Tromey <tom@tromey.com>
13637
13638 * python/python.c (eval_python_command, gdbpy_decode_line)
13639 (gdbpy_run_events, gdbpy_start_type_printers)
13640 (gdbpy_apply_type_printers): Use gdbpy_ref.
13641
97d83487
TT
136422017-01-10 Tom Tromey <tom@tromey.com>
13643
13644 * python/py-param.c (get_doc_string, compute_enum_values): Use
13645 gdbpy_ref.
13646
9205649a
TT
136472017-01-10 Tom Tromey <tom@tromey.com>
13648
13649 * python/py-inferior.c (find_thread_object, build_inferior_list):
13650 Use gdbpy_ref.
13651
74c49d45
TT
136522017-01-10 Tom Tromey <tom@tromey.com>
13653
13654 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
13655
16361ffb
TT
136562017-01-10 Tom Tromey <tom@tromey.com>
13657
13658 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
13659 gdbpy_ref.
13660
905f2cca
TT
136612017-01-10 Tom Tromey <tom@tromey.com>
13662
13663 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
13664 extra incref.
13665 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
13666 Use gdbpy_ref.
13667
64081434
TT
136682017-01-10 Tom Tromey <tom@tromey.com>
13669
13670 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
13671 gdbpy_ref.
13672
59e9e831
TT
136732017-01-10 Tom Tromey <tom@tromey.com>
13674
13675 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
13676 decref results of PyArg_ParseTupleAndKeywords.
13677
9de10f6d
TT
136782017-01-10 Tom Tromey <tom@tromey.com>
13679
13680 * python/python.c (python_run_simple_file): Use
13681 unique_xmalloc_ptr, gdbpy_ref.
13682
2bd5759d
TT
136832017-01-10 Tom Tromey <tom@tromey.com>
13684
13685 * python/py-prettyprint.c (print_stack_unless_memory_error)
13686 (print_string_repr, print_children): Use gdbpy_ref.
13687 (dummy_python_frame): New class.
13688 (dummy_python_frame::dummy_python_frame): Rename from
13689 push_dummy_python_frame.
13690 (py_restore_tstate): Remove.
13691
3b4e0e01
TT
136922017-01-10 Tom Tromey <tom@tromey.com>
13693
13694 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
13695
17a22718
TT
136962017-01-10 Tom Tromey <tom@tromey.com>
13697
13698 * python/python.c (ensure_python_env, restore_python_env):
13699 Remove.
13700 * python/python-internal.h (ensure_python_env): Don't declare.
13701 * varobj.h (varobj_ensure_python_env): Don't declare.
13702 * varobj.c (varobj_ensure_python_env): Remove.
13703
68cdc557
TT
137042017-01-10 Tom Tromey <tom@tromey.com>
13705
13706 * varobj.c (varobj_value_get_print_value): Use
13707 gdbpy_enter_varobj.
13708
1eba6383
TT
137092017-01-10 Tom Tromey <tom@tromey.com>
13710
13711 * python/py-prettyprint.c (print_string_repr, print_children):
13712 Update.
13713 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
13714 of "encoding".
13715 * varobj.c (varobj_value_get_print_value): Update.
13716 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
13717
bde7b3e3
TT
137182017-01-10 Tom Tromey <tom@tromey.com>
13719
13720 * varobj.c (varobj_get_display_hint)
13721 (dynamic_varobj_has_child_method, install_new_value_visualizer)
13722 (varobj_set_visualizer, free_variable): Use
13723 gdbpy_enter_varobj.
13724
a7785f8c
TT
137252017-01-10 Tom Tromey <tom@tromey.com>
13726
13727 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
13728 (do_finish_initialization): New function. Use gdbpy_ref.
13729 (gdbpy_finish_initialization): Use gdbpy_enter. Call
13730 do_finish_initialization.
13731
2865bfce
TT
137322017-01-10 Tom Tromey <tom@tromey.com>
13733
13734 * python/py-param.c (get_set_value, get_show_value): Use
13735 gdbpy_enter, gdbpy_ref.
13736
0e9dcc75
TT
137372017-01-10 Tom Tromey <tom@tromey.com>
13738
13739 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
13740
12a5cedd
TT
137412017-01-10 Tom Tromey <tom@tromey.com>
13742
13743 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
13744
788f2586
TT
137452017-01-10 Tom Tromey <tom@tromey.com>
13746
13747 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
13748 Use gdbpy_enter_varobj.
13749
6cd67bea
TT
137502017-01-10 Tom Tromey <tom@tromey.com>
13751
13752 * varobj.c (gdbpy_enter_varobj): New constructor.
13753 * python/python-internal.h (gdbpy_enter_varobj): New class.
13754 * python/py-varobj.c (py_varobj_get_iterator): Use
13755 gdbpy_enter_varobj.
13756
14b122bf
TT
137572017-01-10 Tom Tromey <tom@tromey.com>
13758
13759 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
13760 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
13761 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
13762 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
13763 unique_xmalloc_ptr.
13764 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
13765
bf1ca3b9
TT
137662017-01-10 Tom Tromey <tom@tromey.com>
13767
13768 * python/py-xmethods.c (invoke_match_method): Use
13769 gdbpy_ref.
13770
572a5524
TT
137712017-01-10 Tom Tromey <tom@tromey.com>
13772
13773 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
13774 gdbpy_enter, gdbpy_ref.
13775
396a78b6
TT
137762017-01-10 Tom Tromey <tom@tromey.com>
13777
13778 * python/python.c (python_interactive_command): Use gdbpy_enter.
13779
a88b13c7
TT
137802017-01-10 Tom Tromey <tom@tromey.com>
13781
13782 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
13783 gdbpy_ref.
13784
e9f0c363
TT
137852017-01-10 Tom Tromey <tom@tromey.com>
13786
13787 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
13788 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
13789
6349f452
TT
137902017-01-10 Tom Tromey <tom@tromey.com>
13791
13792 * utils.h (htab_deleter): New struct.
13793 (htab_up): New typedef.
13794 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
13795 gdbpy_enter, gdbpy_ref, htab_up.
13796
c0171de6
TT
137972017-01-10 Tom Tromey <tom@tromey.com>
13798
13799 * python/py-unwind.c (pending_frame_invalidate): Remove.
13800 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
13801
f18e226f
TT
138022017-01-10 Tom Tromey <tom@tromey.com>
13803
13804 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
13805 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
13806
c57af3f1
TT
138072017-01-10 Tom Tromey <tom@tromey.com>
13808
13809 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
13810
60e600ec
TT
138112017-01-10 Tom Tromey <tom@tromey.com>
13812
13813 * python/python.c (gdbpy_eval_from_control_command)
13814 (gdbpy_source_script, gdbpy_run_events)
13815 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
13816 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
13817 gdbpy_enter.
13818
bf7da5b0
TT
138192017-01-10 Tom Tromey <tom@tromey.com>
13820
13821 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
13822
2d38bced
TT
138232017-01-10 Tom Tromey <tom@tromey.com>
13824
13825 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
13826
07bc7329
TT
138272017-01-10 Tom Tromey <tom@tromey.com>
13828
13829 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
13830 (python_on_inferior_call_pre, python_on_inferior_call_post)
13831 (python_on_memory_change, python_on_register_change)
13832 (python_inferior_exit, python_new_objfile, add_thread_object)
13833 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
13834
6e7c365e
TT
138352017-01-10 Tom Tromey <tom@tromey.com>
13836
13837 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
13838 (bpfinishpy_handle_exit): Use gdbpy_enter.
13839
6ba0cd40
TT
138402017-01-10 Tom Tromey <tom@tromey.com>
13841
13842 * python/py-cmd.c (cmdpy_destroyer)
13843 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
13844 gdbpy_enter.
13845
de2dc875
TT
138462017-01-10 Tom Tromey <tom@tromey.com>
13847
13848 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
13849 gdbpy_enter.
13850 (gdbpy_breakpoint_has_cond): Likewise.
13851
4ecee2c4
TT
138522017-01-10 Tom Tromey <tom@tromey.com>
13853
13854 * python/python.c (gdbpy_enter): New constructor.
13855 (~gdbpy_enter): New destructor.
13856 (restore_python_env, ensure_python_env): Rewrite.
13857 * python/python-internal.h (gdbpy_enter): New class.
13858
37fce74f
TT
138592017-01-10 Tom Tromey <tom@tromey.com>
13860
13861 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
13862
53a0cca3
TT
138632017-01-10 Tom Tromey <tom@tromey.com>
13864
13865 * python/py-value.c (value_has_field, get_field_flag)
13866 (get_field_type, valpy_getitem, convert_value_from_python): Use
13867 gdbpy_ref.
13868
ff3724f5
TT
138692017-01-10 Tom Tromey <tom@tromey.com>
13870
13871 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
13872 gdbpy_ref.
13873
0700aea5
TT
138742017-01-10 Tom Tromey <tom@tromey.com>
13875
13876 * python/py-prettyprint.c (search_pp_list)
13877 (find_pretty_printer_from_objfiles)
13878 (find_pretty_printer_from_progspace)
13879 (find_pretty_printer_from_gdb, find_pretty_printer)
13880 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
13881 gdbpy_ref.
13882
1bb44c9f
TT
138832017-01-10 Tom Tromey <tom@tromey.com>
13884
13885 * python/py-param.c (call_doc_function): Use gdbpy_ref.
13886
87ce03fd
TT
138872017-01-10 Tom Tromey <tom@tromey.com>
13888
13889 * python/py-linetable.c (build_line_table_tuple_from_pcs)
13890 (ltpy_get_all_source_lines): Use gdbpy_ref.
13891
ee0a3fb8
TT
138922017-01-10 Tom Tromey <tom@tromey.com>
13893
13894 * python/py-framefilter.c (extract_sym, extract_value)
13895 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
13896 gdbpy_ref.
13897
bf2a52fa
TT
138982017-01-10 Tom Tromey <tom@tromey.com>
13899
13900 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
13901
f59fe7f8
TT
139022017-01-10 Tom Tromey <tom@tromey.com>
13903
13904 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
13905
80bd970a
TT
139062017-01-10 Tom Tromey <tom@tromey.com>
13907
13908 * python/py-function.c (convert_values_to_python, fnpy_init): Use
13909 gdbpy_ref.
13910
d1b3de2e
TT
139112017-01-10 Tom Tromey <tom@tromey.com>
13912
13913 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
13914
3bb43384
TT
139152017-01-10 Tom Tromey <tom@tromey.com>
13916
13917 * python/py-type.c (convert_field, make_fielditem, typy_fields)
13918 (typy_range): Use gdbpy_ref.
13919
abf5651e
TT
139202017-01-10 Tom Tromey <tom@tromey.com>
13921
13922 * python/py-threadevent.c (create_thread_event_object): Use
13923 gdbpy_ref.
13924 * python/py-stopevent.c (create_stop_event_object): Simplify.
13925 (emit_stop_event): Use gdbpy_ref.
13926 * python/py-signalevent.c (create_signal_event_object): Use
13927 gdbpy_ref.
13928 * python/py-newobjfileevent.c (create_new_objfile_event_object)
13929 (emit_new_objfile_event, create_clear_objfiles_event_object)
13930 (emit_clear_objfiles_event): Use gdbpy_ref.
13931 * python/py-infevents.c (create_inferior_call_event_object)
13932 (create_register_changed_event_object)
13933 (create_memory_changed_event_object, emit_inferior_call_event)
13934 (emit_memory_changed_event, emit_register_changed_event): Use
13935 gdbpy_ref.
13936 * python/py-exitedevent.c (create_exited_event_object)
13937 (emit_exited_event): Use gdbpy_ref.
13938 * python/py-event.h (evpy_emit_event): Remove
13939 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
13940 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
13941 * python/py-continueevent.c (emit_continue_event): Use
13942 gdbpy_ref.
13943 * python/py-breakpoint.c (gdbpy_breakpoint_created)
13944 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
13945 gdbpy_ref.
13946 * python/py-bpevent.c (create_breakpoint_event_object): Use
13947 gdbpy_ref.
13948
a68ff33e
TT
139492017-01-10 Tom Tromey <tom@tromey.com>
13950
13951 * python/py-ref.h: New file.
13952
7becfd03
SM
139532017-01-10 Simon Marchi <simon.marchi@ericsson.com>
13954
13955 * cli-out.c (cli_ui_out::do_redirect): Change return type to
13956 void.
13957 * cli-out.h (cli_ui_out::do_redirect): Likewise.
13958 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
13959 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
13960 * ui-out.c (ui_out::redirect): Likewise.
13961 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
13962 * cli/cli-logging.c (set_logging_redirect): Update call site of
13963 ui_out::redirect.
13964 (handle_redirections): Likewise.
13965 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
13966 * top.c (execute_command_to_string): Likewise.
13967 * utils.c (do_ui_out_redirect_pop): Likewise.
13968
df294654
SM
139692017-01-10 Simon Marchi <simon.marchi@ericsson.com>
13970
13971 * stack.c (_initialize_stack): Update "frame" command help message.
13972
f5e6296e
IB
139732017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
13974
13975 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
13976
0e2d6fa6
YQ
139772017-01-06 Yao Qi <yao.qi@linaro.org>
13978
13979 * x86-linux-nat.h: Include gdb_proc_service.h.
13980
44d6d3f9
YQ
139812017-01-06 Yao Qi <yao.qi@linaro.org>
13982
13983 * ser-base.h: Include serial.h.
13984
656731fe
YQ
139852017-01-06 Yao Qi <yao.qi@linaro.org>
13986
13987 * ppc-linux-tdep.h: Include ppc-tdep.h.
13988
1ca8f924
YQ
139892017-01-06 Yao Qi <yao.qi@linaro.org>
13990
13991 * nat/amd64-linux-siginfo.h: Include signal.h.
13992
bc3008c4
YQ
139932017-01-06 Yao Qi <yao.qi@linaro.org>
13994
13995 * nat/aarch64-linux-hw-point.h: Include break-common.h.
13996
66c80d03
YQ
139972017-01-06 Yao Qi <yao.qi@linaro.org>
13998
13999 * mi/mi-parse.h: Include mi-cmds.h.
14000
051d2dda
YQ
140012017-01-06 Yao Qi <yao.qi@linaro.org>
14002
14003 * inf-loop.c: Don't include "target.h".
14004 * inf-loop.h: Include it here.
14005
8018d34f
YQ
140062017-01-06 Yao Qi <yao.qi@linaro.org>
14007
14008 * dfp.h: Include "dboulest.h" and "expression.h".
14009
c0b8369c
YQ
140102017-01-06 Yao Qi <yao.qi@linaro.org>
14011
14012 * ax-gdb.h: Include "ax.h".
14013
ad5cba2a
YQ
140142017-01-06 Yao Qi <yao.qi@linaro.org>
14015
14016 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
14017 with nat/gdb_ptrace.h.
14018
1c33cd7f
YQ
140192017-01-05 Yao Qi <yao.qi@linaro.org>
14020
14021 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
14022 new line.
14023 (mips64_fbsd_sigframe_init): Likewise.
14024
c988ac1d
JB
140252017-01-04 John Baldwin <jhb@FreeBSD.org>
14026
14027 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
14028 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
14029
b268007c
JB
140302017-01-04 John Baldwin <jhb@FreeBSD.org>
14031
14032 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
14033 * NEWS: Mention new FreeBSD/mips native configuration.
14034 * config/mips/fbsd.mh: New file.
14035 * configure.host: Add mips*-*-freebsd*.
14036 * mips-fbsd-nat.c: New file.
14037
387360da
JB
140382017-01-04 John Baldwin <jhb@FreeBSD.org>
14039
14040 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
14041 (ALLDEPFILES): Add mips-fbsd-tdep.c.
14042 * NEWS: Mention new FreeBSD/mips target.
14043 * configure.tgt: Add mips*-*-freebsd*.
14044 * mips-fbsd-tdep.c: New file.
14045 * mips-fbsd-tdep.h: New file.
14046
2aaaf250
YQ
140472017-01-04 Yao Qi <yao.qi@linaro.org>
14048
14049 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
14050 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
14051
61baf725
JB
140522017-01-01 Joel Brobecker <brobecker@adacore.com>
14053
6dbb839a 14054 Update copyright year range in all GDB files.
61baf725 14055
c113e7ff 140562017-01-01 Joel Brobecker <brobecker@adacore.com>
ce0db137 14057
c113e7ff 14058 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
ce0db137 14059
c113e7ff 14060For older changes see ChangeLog-2016.
c906108c
SS
14061\f
14062Local Variables:
14063mode: change-log
14064left-margin: 8
14065fill-column: 74
14066version-control: never
57da7796 14067coding: utf-8
c906108c 14068End:
This page took 2.679709 seconds and 4 git commands to generate.