1 2018-06-21 Pedro Alves <palves@redhat.com>
3 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
4 instead of a ptid_t. All callers adjusted.
5 * ada-tasks.c (ada_get_task_number): Likewise. All callers
7 (print_ada_task_info, display_current_task_id, task_command_1):
9 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
11 (breakpoint_kind): Adjust.
12 (remove_breakpoints_pid): Rename to ...
13 (remove_breakpoints_inf): ... this. Adjust to take an inferior
14 pointer. All callers adjusted.
15 (bpstat_clear_actions): Use inferior_thread.
16 (get_bpstat_thread): New.
17 (bpstat_do_actions): Use it.
18 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
19 to take a thread_info pointer. All callers adjusted.
20 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
21 (breakpoint_re_set_thread): Use inferior_thread.
22 * breakpoint.h (struct inferior): Forward declare.
23 (bpstat_stop_status): Update.
24 (remove_breakpoints_pid): Delete.
25 (remove_breakpoints_inf): New.
26 * bsd-uthread.c (bsd_uthread_target::wait)
27 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
28 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
29 (maint_btrace_packet_history_cmd)
30 (maint_btrace_clear_packet_history_cmd): Adjust.
31 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
33 * cli/cli-interp.c: Include "inferior.h".
34 * common/refcounted-object.h (struct
35 refcounted_object_ref_policy): New.
36 * compile/compile-object-load.c: Include gdbthread.h.
37 (store_regs): Use inferior_thread.
38 * corelow.c (core_target::close): Use current_inferior.
39 (core_target_open): Adjust to use first_thread_of_inferior and use
41 * ctf.c (ctf_target::close): Adjust to use current_inferior.
42 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
43 <thread>: ... this new field. All references adjusted.
44 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
45 Take a thread_info pointer instead of a ptid_t.
46 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
47 (dummy_frame_discard, register_dummy_frame_dtor): Take a
48 thread_info pointer instead of a ptid_t.
49 * elfread.c: Include "inferior.h".
50 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
52 * eval.c (evaluate_subexp): Likewise.
53 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
55 * gdb_proc_service.h (struct thread_info): Forward declare.
56 (struct ps_prochandle) <ptid>: Delete, replaced by ...
57 <thread>: ... this new field. All references adjusted.
58 * gdbarch.h, gdbarch.c: Regenerate.
59 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
60 'thread' parameter. All implementations and callers adjusted.
61 * gdbthread.h (thread_info) <set_running>: New method.
62 (delete_thread, delete_thread_silent): Take a thread_info pointer
64 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
65 (first_thread_of_process): Delete, replaced by ...
66 (first_thread_of_inferior): ... this new function. All callers
68 (any_live_thread_of_process): Delete, replaced by ...
69 (any_live_thread_of_inferior): ... this new function. All callers
71 (switch_to_thread, switch_to_no_thread): Declare.
72 (is_executing): Delete.
73 (enable_thread_stack_temporaries): Update comment.
74 <enable_thread_stack_temporaries>: Take a thread_info pointer
75 instead of a ptid_t. Incref the thread.
76 <~enable_thread_stack_temporaries>: Decref the thread.
79 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
80 (get_last_thread_stack_temporary)
81 (value_in_thread_stack_temporaries, can_access_registers_thread):
82 Take a thread_info pointer instead of a ptid_t. All callers
84 * infcall.c (get_call_return_value): Use inferior_thread.
85 (run_inferior_call): Work with thread pointers instead of ptid_t.
86 (call_function_by_hand_dummy): Work with thread pointers instead
87 of ptid_t. Use thread_info_ref.
88 * infcmd.c (proceed_thread_callback): Access thread's state
90 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
91 access thread's state directly.
92 (continue_command): Use inferior_thread.
93 (info_program_command): Use find_thread_ptid and access thread
95 (proceed_after_attach_callback): Use thread state directly.
96 (notice_new_inferior): Take a thread_info pointer instead of a
97 ptid_t. All callers adjusted.
98 (exit_inferior): Take an inferior pointer instead of a pid. All
100 (exit_inferior_silent): New.
101 (detach_inferior): Delete.
102 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
103 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
104 (detach_inferior_command, kill_inferior_command): Use
105 find_inferior_id instead of valid_gdb_inferior_id and
106 gdb_inferior_id_to_pid.
107 (inferior_command): Use inferior and thread pointers.
108 * inferior.h (struct thread_info): Forward declare.
109 (notice_new_inferior): Take a thread_info pointer instead of a
110 ptid_t. All callers adjusted.
111 (detach_inferior): Delete declaration.
112 (exit_inferior, exit_inferior_silent): Take an inferior pointer
113 instead of a pid. All callers adjusted.
114 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
115 (valid_gdb_inferior_id): Delete.
116 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
117 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
118 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
120 <inf>: ... this new field.
121 <step_ptid>: Delete, replaced by ...
122 <step_thread>: ... this new field.
123 (get_displaced_stepping_state): Take an inferior pointer instead
124 of a pid. All callers adjusted.
125 (displaced_step_in_progress_any_inferior): Adjust.
126 (displaced_step_in_progress_thread): Take a thread pointer instead
127 of a ptid_t. All callers adjusted.
128 (displaced_step_in_progress, add_displaced_stepping_state): Take
129 an inferior pointer instead of a pid. All callers adjusted.
130 (get_displaced_step_closure_by_addr): Adjust.
131 (remove_displaced_stepping_state): Take an inferior pointer
132 instead of a pid. All callers adjusted.
133 (displaced_step_prepare_throw, displaced_step_prepare)
134 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
135 All callers adjusted.
136 (start_step_over): Adjust.
137 (infrun_thread_ptid_changed): Remove bit updating ptids in the
138 displaced step queue.
139 (do_target_resume): Adjust.
140 (fetch_inferior_event): Use inferior_thread.
141 (context_switch, get_inferior_stop_soon): Take an
142 execution_control_state pointer instead of a ptid_t. All callers
144 (switch_to_thread_cleanup): Delete.
145 (stop_all_threads): Use scoped_restore_current_thread.
146 * inline-frame.c: Include "gdbthread.h".
147 (inline_state) <inline_state>: Take a thread pointer instead of a
148 ptid_t. All callers adjusted.
149 <ptid>: Delete, replaced by ...
150 <thread>: ... this new field.
151 (find_inline_frame_state): Take a thread pointer instead of a
152 ptid_t. All callers adjusted.
153 (skip_inline_frames, step_into_inline_frame)
154 (inline_skipped_frames, inline_skipped_symbol): Take a thread
155 pointer instead of a ptid_t. All callers adjusted.
156 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
157 (inline_skipped_frames, inline_skipped_symbol): Likewise.
158 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
160 * linux-nat.c (get_detach_signal): Likewise.
161 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
162 (thread_db_notice_clone): Adjust.
163 (thread_db_find_new_threads_silently)
164 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
165 a thread pointer instead of a ptid_t. All callers adjusted.
166 * mi/mi-cmd-var.c: Include "inferior.h".
167 (mi_cmd_var_update_iter): Update to use thread pointers.
168 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
170 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
172 (mi_output_running): ... this new function.
173 (mi_on_resume_1): Adjust to use it.
174 (mi_user_selected_context_changed): Adjust to use inferior_thread.
175 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
177 (interrupt_thread_callback): : Adjust to use thread and inferior
179 * proc-service.c: Include "gdbthread.h".
180 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
181 * progspace-and-thread.c: Include "inferior.h".
182 * progspace.c: Include "inferior.h".
183 * python/py-exitedevent.c (create_exited_event_object): Adjust to
184 hold a reference to an inferior_object.
185 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
187 * python/py-inferior.c (struct inferior_object): Give the type a
188 tag name instead of a typedef.
189 (python_on_normal_stop): No need to check if the current thread is
191 (inferior_to_inferior_object): Change return type to
192 inferior_object. All callers adjusted.
193 (find_thread_object): Delete, bits factored out to ...
194 (thread_to_thread_object): ... this new function.
195 * python/py-infthread.c (create_thread_object): Use
196 inferior_to_inferior_object.
197 (thpy_is_stopped): Use thread pointer directly.
198 (gdbpy_selected_thread): Use inferior_thread.
199 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
200 field, replaced with ...
201 <thread>: ... this new field. All users adjusted.
202 (btpy_insn_or_gap_new): Drop const.
203 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
205 * python/py-record.c: Include "gdbthread.h".
206 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
207 a ptid_t. All callers adjusted.
208 (gdbpy_current_recording): Use inferior_thread.
209 * python/py-record.h (recpy_record_object) <ptid>: Delete
210 field, replaced with ...
211 <thread>: ... this new field. All users adjusted.
212 (recpy_element_object) <ptid>: Delete
213 field, replaced with ...
214 <thread>: ... this new field. All users adjusted.
215 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
216 a ptid_t. All callers adjusted.
217 * python/py-threadevent.c: Include "gdbthread.h".
218 (get_event_thread): Use thread_to_thread_object.
219 * python/python-internal.h (struct inferior_object): Forward
221 (find_thread_object, find_inferior_object): Delete declarations.
222 (thread_to_thread_object, inferior_to_inferior_object): New
224 * record-btrace.c: Include "inferior.h".
225 (require_btrace_thread): Use inferior_thread.
226 (record_btrace_frame_sniffer)
227 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
228 (get_thread_current_frame): Use scoped_restore_current_thread and
230 (get_thread_current_frame): Use thread pointer directly.
231 (record_btrace_replay_at_breakpoint): Use thread's inferior
233 * record-full.c: Include "inferior.h".
234 * regcache.c: Include "gdbthread.h".
235 (get_thread_arch_regcache): Use the inferior's address space
237 (get_thread_regcache, registers_changed_thread): New.
238 * regcache.h (get_thread_regcache(thread_info *thread)): New
240 (registers_changed_thread): New.
241 (remote_target) <remote_detach_1>: Swap order of parameters.
242 (remote_add_thread): <remote_add_thread>: Return the new thread.
243 (get_remote_thread_info(ptid_t)): New overload.
244 (remote_target::remote_notice_new_inferior): Use thread pointers
246 (remote_target::process_initial_stop_replies): Use
247 thread_info::set_running.
248 (remote_target::remote_detach_1, remote_target::detach)
249 (extended_remote_target::detach): Adjust.
250 * stack.c (frame_show_address): Use inferior_thread.
251 * target-debug.h (target_debug_print_thread_info_pp): New.
252 * target-delegates.c: Regenerate.
253 * target.c (default_thread_address_space): Delete.
254 (memory_xfer_partial_1): Use current_inferior.
255 (target_detach): Use current_inferior.
256 (target_thread_address_space): Delete.
257 (generic_mourn_inferior): Use current_inferior.
258 * target.h (struct target_ops) <thread_address_space>: Delete.
259 (target_thread_address_space): Delete.
260 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
262 (delete_thread_1, delete_thread, delete_thread_silent): Take a
263 thread pointer instead of a ptid_t. Adjust all callers.
264 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
265 (first_thread_of_process): Delete, replaced by ...
266 (first_thread_of_inferior): ... this new function. All callers
268 (any_thread_of_process): Rename to ...
269 (any_thread_of_inferior): ... this, and take an inferior pointer.
270 (any_live_thread_of_process): Rename to ...
271 (any_live_thread_of_inferior): ... this, and take an inferior
273 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
274 (value_in_thread_stack_temporaries)
275 (get_last_thread_stack_temporary): Take a thread pointer instead
276 of a ptid_t. Adjust all callers.
277 (thread_info::set_running): New.
278 (validate_registers_access): Use inferior_thread.
279 (can_access_registers_ptid): Rename to ...
280 (can_access_registers_thread): ... this, and take a thread
282 (print_thread_info_1): Adjust to compare thread pointers instead
284 (switch_to_no_thread, switch_to_thread): Make extern.
285 (scoped_restore_current_thread::~scoped_restore_current_thread):
286 Use m_thread pointer directly.
287 (scoped_restore_current_thread::scoped_restore_current_thread):
289 (thread_command): Use thread pointer directly.
290 (thread_num_make_value_helper): Use inferior_thread.
291 * top.c (execute_command): Use inferior_thread.
292 * tui/tui-interp.c: Include "inferior.h".
293 * varobj.c (varobj_create): Use inferior_thread.
294 (value_of_root_1): Use find_thread_global_id instead of
295 global_thread_id_to_ptid.
297 2018-06-21 Alan Hayward <alan.hayward@arm.com>
299 * regcache.c (readable_regcache::read_part): Avoid memcpy when
301 (regcache::write_part): Likewise.
302 (readable_regcache::cooked_read_part): Update comment.
303 (readable_regcache::cooked_write_part): Likewise.
304 * regcache.h: (readable_regcache::read_part): Likewise.
305 (regcache::write_part): Likewise.
307 2018-06-21 Richard Bunt <richard.bunt@arm.com>
308 Dirk Schubert <dirk.schubert@arm.com>
310 * aarch64-linux-nat.c (post_attach): New.
311 (aarch64_linux_nat_target::post_attach): Override post_attach to
312 record the number of hardware debug registers.
314 2018-06-20 Tom Tromey <tom@tromey.com>
316 * python/py-param.c (add_setshow_generic): Make parameters const.
317 (parmpy_init): Update.
319 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
321 * regcache.h (regcache_cooked_read_ftype): Rename to...
322 (register_read_ftype): ...this, change type to function_view.
323 (class reg_buffer) <save>: Remove src parameter.
324 (readonly_detached_regcache) <readonly_detached_regcache>: Make
325 parameter non-const in first overload. Remove src parameter in
327 * regcache.c (do_cooked_read): Remove.
328 (readonly_detached_regcache::readonly_detached_regcache): Make
329 parameter non-const, adjust call to other constructor.
330 (reg_buffer::save): Remove src parameter.
331 * frame.c (do_frame_register_read): Remove.
332 (frame_save_as_regcache): Use lambda function.
333 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
334 parameter to ppu2spu_data *.
335 (ppu2spu_sniffer): Use lambda function.
337 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
339 * record-full.c (record_full_target::insert_breakpoint): Remove
340 "struct" keyword, add const.
342 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
344 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
345 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
346 * configure.ac: Remove AC_PREREQ, add missing quoting.
347 * gnulib/configure.ac: Modernize usage of
348 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
349 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
350 (AUTOMAKE_VERSION): Bump to 1.15.1.
351 * configure: Re-generate.
352 * config.in: Re-generate.
353 * aclocal.m4: Re-generate.
354 * gnulib/aclocal.m4: Re-generate.
355 * gnulib/config.in: Re-generate.
356 * gnulib/configure: Re-generate.
357 * gnulib/import/Makefile.in: Re-generate.
359 2018-06-19 Pedro Alves <palves@redhat.com>
361 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
362 (lookup_minimal_symbol_by_pc_section): ... here with
363 gdb_assert_not_reached added.
365 2018-06-19 Pedro Alves <palves@redhat.com>
367 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
368 parameter with a block parameter. Compare location's block symbol
369 with the frame's block instead of addresses.
370 (skip_inline_frames): Pass the current block instead of the
371 frame's address. Break out as soon as we determine the frame
372 should not be skipped.
374 2018-06-18 Tom Tromey <tom@tromey.com>
376 * solib-aix.c (solib_aix_get_section_offsets): Return
378 (solib_aix_solib_create_inferior_hook): Update.
380 2018-06-18 Tom Tromey <tom@tromey.com>
382 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
384 2018-06-18 Tom Tromey <tom@tromey.com>
386 * solib-frv.c (frv_relocate_main_executable): Use
388 * solib-dsbt.c (dsbt_relocate_main_executable): Use
391 2018-06-18 Tom Tromey <tom@tromey.com>
393 * objfiles.h (inhibit_section_map_updates): Update.
394 (resume_section_map_updates, resume_section_map_updates_cleanup):
396 * solib-svr4.c (svr4_handle_solib_event): Update.
397 * objfiles.c (inhibit_section_map_updates): Return
398 scoped_restore_tmpl<int>.
399 (resume_section_map_updates, resume_section_map_updates_cleanup):
402 2018-06-18 Tom Tromey <tom@tromey.com>
404 * valprint.h (read_string): Update.
405 * valprint.c (read_string): Change type of "buffer".
406 (val_print_string): Update.
407 * python/py-value.c (valpy_string): Update.
408 * language.h (struct language_defn) <la_get_string>: Change
410 (default_get_string, c_get_string): Update.
411 * language.c (default_get_string): Change type of "buffer".
412 * guile/scm-value.c (gdbscm_value_to_string): Update.
413 * c-lang.c (c_get_string): Change type of "buffer".
415 2018-06-18 Tom Tromey <tom@tromey.com>
417 * ser-mingw.c (struct pipe_state_destroyer): New.
418 (pipe_state_up): New typedef.
419 (cleanup_pipe_state): Remove.
420 (pipe_windows_open): Use pipe_state_up. Don't release argv.
422 2018-06-18 Tom Tromey <tom@tromey.com>
424 * rust-lang.h (rust_yyerror): Don't declare.
425 * rust-lang.c (rust_language_defn): Update.
426 * rust-exp.y (yyerror): Now static.
427 * parse.c (parse_exp_in_context_1): Update.
428 * p-lang.h (p_yyerror): Don't declare.
429 * p-lang.c (p_language_defn): Update.
430 * p-exp.y (yyerror): Now static.
431 * opencl-lang.c (opencl_language_defn): Update.
432 * objc-lang.c (objc_language_defn): Update.
433 * m2-lang.h (m2_yyerror): Don't declare.
434 * m2-lang.c (m2_language_defn): Update.
435 * m2-exp.y (yyerror): Now static.
436 * language.h (struct language_defn) <la_error>: Remove.
437 * language.c (unk_lang_error): Remove.
438 (unknown_language_defn, auto_language_defn): Remove.
439 * go-lang.h (go_yyerror): Don't declare.
440 * go-lang.c (go_language_defn): Update.
441 * go-exp.y (yyerror): Now static.
442 * f-lang.h (f_yyerror): Don't declare.
443 * f-lang.c (f_language_defn): Update.
444 * f-exp.y (yyerror): Now static.
445 * d-lang.h (d_yyerror): Don't declare.
446 * d-lang.c (d_language_defn): Update.
447 * d-exp.y (yyerror): Now static.
448 * c-lang.h (c_yyerror): Don't declare.
449 * c-lang.c (c_language_defn, cplus_language_defn)
450 (asm_language_defn, minimal_language_defn): Update.
451 * c-exp.y (yyerror): Now static.
452 * ada-lang.h (ada_yyerror): Don't declare.
453 * ada-lang.c (ada_language_defn): Update.
454 * ada-exp.y (yyerror): Now static.
456 2018-06-18 Alan Hayward <alan.hayward@arm.com>
458 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
459 (store_sveregs_to_thread): Likewise.
460 (aarch64_linux_fetch_inferior_registers): Check for SVE.
461 (aarch64_linux_store_inferior_registers): Likewise.
462 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
464 (aarch64_sve_regs_copy_to_regcache): Likewise.
465 (aarch64_sve_regs_copy_from_regcache): Likewise.
466 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
468 (aarch64_sve_regs_copy_to_regcache): Likewise.
469 (aarch64_sve_regs_copy_from_regcache): Likewise.
470 (sve_context): Structure from Linux headers.
471 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
472 (SVE_SIG_ZREG_SIZE): Likewise.
473 (SVE_SIG_PREG_SIZE): Likewise.
474 (SVE_SIG_FFR_SIZE): Likewise.
475 (SVE_SIG_REGS_OFFSET): Likewise.
476 (SVE_SIG_ZREGS_OFFSET): Likewise.
477 (SVE_SIG_ZREG_OFFSET): Likewise.
478 (SVE_SIG_ZREGS_SIZE): Likewise.
479 (SVE_SIG_PREGS_OFFSET): Likewise.
480 (SVE_SIG_PREG_OFFSET): Likewise.
481 (SVE_SIG_PREGS_SIZE): Likewise.
482 (SVE_SIG_FFR_OFFSET): Likewise.
483 (SVE_SIG_REGS_SIZE): Likewise.
484 (SVE_SIG_CONTEXT_SIZE): Likewise.
485 (SVE_PT_REGS_MASK): Likewise.
486 (SVE_PT_REGS_FPSIMD): Likewise.
487 (SVE_PT_REGS_SVE): Likewise.
488 (SVE_PT_VL_INHERIT): Likewise.
489 (SVE_PT_VL_ONEXEC): Likewise.
490 (SVE_PT_REGS_OFFSET): Likewise.
491 (SVE_PT_FPSIMD_OFFSET): Likewise.
492 (SVE_PT_FPSIMD_SIZE): Likewise.
493 (SVE_PT_SVE_ZREG_SIZE): Likewise.
494 (SVE_PT_SVE_PREG_SIZE): Likewise.
495 (SVE_PT_SVE_FFR_SIZE): Likewise.
496 (SVE_PT_SVE_FPSR_SIZE): Likewise.
497 (SVE_PT_SVE_FPCR_SIZE): Likewise.
498 (__SVE_SIG_TO_PT): Likewise.
499 (SVE_PT_SVE_OFFSET): Likewise.
500 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
501 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
502 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
503 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
504 (SVE_PT_SVE_PREG_OFFSET): Likewise.
505 (SVE_PT_SVE_PREGS_SIZE): Likewise.
506 (SVE_PT_SVE_FFR_OFFSET): Likewise.
507 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
508 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
509 (SVE_PT_SVE_SIZE): Likewise.
510 (SVE_PT_SIZE): Likewise.
511 (HAS_SVE_STATE): New define.
513 2018-06-18 Alan Hayward <alan.hayward@arm.com>
515 * nat/aarch64-sve-linux-sigcontext.h: New file.
516 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
518 (SVE_VQ_MIN): Likewise.
519 (SVE_VQ_MAX): Likewise.
520 (SVE_VL_MIN): Likewise.
521 (SVE_VL_MAX): Likewise.
522 (SVE_NUM_ZREGS): Likewise.
523 (SVE_NUM_PREGS): Likewise.
524 (sve_vl_valid): Likewise.
525 (struct user_sve_header): Likewise.
527 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
528 Richard Bunt <Richard.Bunt@arm.com>
530 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
531 was requested by GDB.
533 2018-06-15 Tom de Vries <tdevries@suse.de>
535 * MAINTAINERS (Write After Approval): Add Tom de Vries.
537 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
539 * gnulib/update-gnulib.sh: Print expected versions of
542 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
544 * arch-utils.c (default_type_align): Use type_length_units.
545 * gdbtypes.c (type_align): Use type_length_units.
547 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
549 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
552 2018-06-14 Tom de Vries <tdevries@suse.de>
555 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
556 get_no_prettyformat_print_options.
558 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
560 * sparc-nat.h: Include target.h.
561 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
562 <fetch_registers>: Remove this argument in function call.
563 <store_registers>: Remove this argument in function call, remove
565 <low_forget_process>: Call sparc64_forget_process instead of
566 sparc_forget_process.
568 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
570 * procfs.c (_initialize_procfs): Use add_inf_child_target.
571 (procfs_target::make_corefile_notes): Adjust to new
572 target_read_alloc return type.
574 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
575 Stephen Roberts <stephen.roberts@arm.com>
578 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
579 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
580 Move should_notify_stop local into more inner scope.
582 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
583 Stephen Roberts <stephen.roberts@arm.com>
586 * infrun.c (resume_1): Add call to mark_async_event_handler.
588 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
590 * infrun.c (do_target_wait): Change old version of $pc printed.
592 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
594 * dwarf2read.c (read_index_from_section): Rename to...
595 (read_gdb_index_from_section): ... this, update all callers.
596 (dwarf2_read_index): Rename to...
597 (dwarf2_read_gdb_index): ... this, update all callers.
599 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
601 * gdb/hppa-linux-nat.c
602 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
603 hppa_linux_nat_target::fetch_registers.
605 2018-06-11 Alan Hayward <alan.hayward@arm.com>
607 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
608 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
609 (AARCH64_DWARF_SVE_FFR): Likewise.
610 (AARCH64_DWARF_SVE_P0): Likewise.
611 (AARCH64_DWARF_SVE_Z0): Likewise.
613 2018-06-11 Alan Hayward <alan.hayward@arm.com>
615 * common/common-regcache.h (raw_compare): New function.
616 * regcache.c (regcache::raw_compare): Likewise.
617 * regcache.h (regcache::raw_compare): New declaration.
619 2018-06-11 Alan Hayward <alan.hayward@arm.com>
621 * common/common-regcache.h (reg_buffer_common): New structure.
622 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
623 (reg_buffer::raw_supply): Likewise.
624 (reg_buffer::raw_supply_integer): Likewise.
625 (reg_buffer::raw_supply_zeroed): Likewise.
626 (reg_buffer::raw_collect): Likewise.
627 (reg_buffer::raw_collect_integer): Likewise.
628 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
629 (reg_buffer::raw_supply): Likewise.
630 (reg_buffer::raw_supply_integer): Likewise.
631 (reg_buffer::raw_supply_zeroed): Likewise.
632 (reg_buffer::raw_collect): Likewise.
633 (reg_buffer::raw_collect_integer): Likewise.
635 2018-06-10 Tom Tromey <tom@tromey.com>
637 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
638 (class remote_state) <stop_reply_queue>: Now std::vector.
639 (remote_state::~remote_state)
640 (remote_target::stop_reply_queue_length): Update.
641 (struct queue_iter_param, remove_child_of_pending_fork)
642 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
643 (check_pending_event_prevents_wildcard_vcont_callback)
644 (remove_stop_reply_for_inferior)
645 (remove_stop_reply_of_remote_state)
646 (remote_notif_remove_once_on_match)
647 (stop_reply_match_ptid_and_ws)
648 (remote_kill_child_of_pending_fork): Remove.
649 (remote_target::remove_new_fork_children)
650 (remote_target::check_pending_events_prevent_wildcard_vcont)
651 (remote_target::discard_pending_stop_replies)
652 (remote_target::discard_pending_stop_replies_in_queue)
653 (remote_target::remote_notif_remove_queued_reply)
654 (remote_target::queued_stop_reply)
655 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
656 (remote_target::wait, remote_target::kill_new_fork_children)
657 (remote_target::async): Update.
659 2018-06-10 Tom Tromey <tom@tromey.com>
661 * record-full.c (record_full_arch_list_cleanups): Remove.
662 (record_full_message): Use try/catch.
663 (record_full_wait_cleanups): Remove.
664 (record_full_wait_1): Use try/catch.
665 (record_full_restore): Likewise.
667 2018-06-10 Tom Tromey <tom@tromey.com>
669 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
670 declare VEC. Add constructor.
671 <in_target_beneath>: Now bool.
672 (record_full_breakpoints): Now a std::vector, static.
673 (record_full_sync_record_breakpoints)
674 (record_full_init_record_breakpoints)
675 (record_full_target::insert_breakpoint)
676 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
678 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
680 * dwarf2read.c (process_cu_includes): Remove struct keyword.
681 * serial.c (serial_interface_lookup): Remove struct keyword.
683 2018-06-10 Tom Tromey <tom@tromey.com>
685 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
687 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
689 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
691 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
692 "beneath" as a method.
693 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
694 Use "beneath" as a method.
696 2018-06-10 Tom Tromey <tom@tromey.com>
698 * tracefile.c (struct trace_file_writer_deleter): New.
699 <operator()>: Rename from trace_file_writer_xfree.
700 (trace_file_writer_up): New typedef.
701 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
703 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
705 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
706 <m_registers, m_register_status>: Change type to
708 * regcache.c (reg_buffer::reg_buffer): Use new instead of
711 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
713 * common/common-regcache.h (enum register_status): Add
714 underlying type "signed char".
715 * regcache.h (reg_buffer) <m_register_status>: Change type to
717 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
718 register_status instead of signed char.
719 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
720 (reg_buffer::get_register_status): Remove cast.
721 (readable_regcache::raw_read): Remove cast.
722 (readable_regcache::cooked_read): Remove cast.
724 2018-06-09 Tom Tromey <tom@tromey.com>
726 * source.c (reverse_search_command, forward_search_command): Use
729 2018-06-09 Tom Tromey <tom@tromey.com>
731 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
732 (serial_ops_list): Now static, std::vector.
733 (serial_interface_lookup, serial_add_interface): Update.
735 2018-06-09 Tom Tromey <tom@tromey.com>
737 * dwarf2read.c (process_cu_includes): Update.
738 (process_full_comp_unit): Update.
739 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
742 2018-06-08 Paul Koning <paul_koning@dell.com>
746 * python/python.c (do_start_initialization):
747 Avoid call to internal Python API.
748 (init__gdb_module): New function.
750 2018-06-08 Gary Benson <gbenson@redhat.com>
752 * linux-thread-db.c (valprint.h): New include.
753 (struct check_thread_db_info): New structure.
754 (check_thread_db_on_load, tdb_testinfo): New static globals.
755 (check_thread_db, check_thread_db_callback): New functions.
756 (try_thread_db_load_1): Run integrity checks if requested.
757 (maintenance_check_libthread_db): New function.
758 (_initialize_thread_db): Register "maint check libthread-db"
759 and "maint set/show check-libthread-db".
760 * NEWS: Mention the above new commands.
762 2018-06-08 Tom Tromey <tom@tromey.com>
764 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
767 2018-06-08 Tom Tromey <tom@tromey.com>
769 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
771 2018-06-08 Tom Tromey <tom@tromey.com>
773 * common/btrace-common.h (struct btrace_data): Add constructor,
774 destructor, move assignment operator.
775 <empty, clear, fini>: New methods.
776 <format>: Initialize.
777 (btrace_data_init, btrace_data_fini, btrace_data_clear)
778 (btrace_data_empty): Don't declare.
779 * common/btrace-common.c (btrace_data_init): Remove.
780 (btrace_data::fini): Rename from btrace_data_fini.
781 (btrace_data::empty): Rename from btrace_data_empty.
782 (btrace_data::clear): Rename from btrace_data_clear. Return
784 * btrace.h (make_cleanup_btrace_data): Don't declare.
785 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
786 (parse_xml_btrace): Update.
787 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
788 (maint_btrace_clear_packet_history_cmd): Update.
790 2018-06-07 Pedro Alves <palves@redhat.com>
792 * target.h (target_ops) <beneath>: Now a method. All references
794 (class target_stack): New.
795 * target.c (g_target_stack): New.
796 (g_current_top_target): Delete.
797 (current_top_target): Get the top target out of g_target_stack.
798 (target_stack::push, target_stack::unpush): New.
799 (push_target, unpush_target): Reimplement.
800 (target_is_pushed): Reimplement in terms of g_target_stack.
801 (target_ops::beneath, target_stack::find_beneath): New.
803 2018-06-07 Pedro Alves <palves@redhat.com>
805 * target.h (find_target_beneath): Delete declaration.
806 * target.c (find_target_beneath): Delete definition.
807 * aix-thread.c: All callers of find_target_beneath adjusted to
808 call target_ops::beneath instead.
809 * bsd-uthread.c: Likewise.
810 * linux-thread-db.c: Likewise.
811 * ravenscar-thread.c: Likewise.
812 * sol-thread.c: Likewise.
813 * spu-multiarch.c: Likewise.
815 2018-06-07 Pedro Alves <palves@redhat.com>
817 * target.h (target_ops) <beneath>: Now a method. All references
819 (target_ops) <m_beneath>: New.
820 * target.c (target_ops::beneath): New.
821 * corelow.c: Adjust all references to target_ops::beneath.
822 * linux-thread-db.c: Likewise.
823 * make-target-delegates: Likewise.
824 * record-btrace.c: Likewise.
825 * record-full.c: Likewise.
826 * remote.c: Likewise.
827 * target.c: Likewise.
828 * target-delegates.c: Regenerate.
830 2018-06-07 Pedro Alves <palves@redhat.com>
832 * target.h (target_stack): Delete.
833 (current_top_target): Declare function.
834 * target.c (target_stack): Delete.
835 (g_current_top_target): New.
836 (current_top_target): New function.
837 * auxv.c: Use current_top_target instead of target_stack
839 * avr-tdep.c: Likewise.
840 * breakpoint.c: Likewise.
841 * corefile.c: Likewise.
842 * elfread.c: Likewise.
844 * exceptions.c: Likewise.
846 * gdbarch-selftests.c: Likewise.
847 * gnu-v3-abi.c: Likewise.
848 * ia64-tdep.c: Likewise.
849 * ia64-vms-tdep.c: Likewise.
850 * infcall.c: Likewise.
851 * infcmd.c: Likewise.
852 * infrun.c: Likewise.
853 * linespec.c: Likewise.
854 * linux-tdep.c: Likewise.
855 * minsyms.c: Likewise.
856 * ppc-linux-nat.c: Likewise.
857 * ppc-linux-tdep.c: Likewise.
858 * procfs.c: Likewise.
859 * regcache.c: Likewise.
860 * remote.c: Likewise.
861 * rs6000-tdep.c: Likewise.
862 * s390-linux-nat.c: Likewise.
863 * s390-tdep.c: Likewise.
864 * solib-aix.c: Likewise.
865 * solib-darwin.c: Likewise.
866 * solib-dsbt.c: Likewise.
867 * solib-spu.c: Likewise.
868 * solib-svr4.c: Likewise.
869 * solib-target.c: Likewise.
870 * sparc-tdep.c: Likewise.
871 * sparc64-tdep.c: Likewise.
872 * spu-tdep.c: Likewise.
873 * symfile.c: Likewise.
874 * symtab.c: Likewise.
875 * target-descriptions.c: Likewise.
876 * target-memory.c: Likewise.
877 * target.c: Likewise.
878 * target.h: Likewise.
879 * tracefile-tfile.c: Likewise.
880 * tracepoint.c: Likewise.
881 * valops.c: Likewise.
882 * valprint.c: Likewise.
884 * windows-tdep.c: Likewise.
885 * mi/mi-main.c: Likewise.
887 2018-06-07 Tom Tromey <tom@tromey.com>
889 * valprint.h (build_address_symbolic): Declare.
890 * printcmd.c (print_address_symbolic): Update.
891 (build_address_symbolic): Change "name" and "filename" to
893 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
895 * defs.h (build_address_symbolic): Remove declaration.
897 2018-06-07 Alan Hayward <alan.hayward@arm.com>
899 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
900 (aarch64_vnv_type): Add function.
901 (aarch64_pseudo_register_name): Add V regs for SVE.
902 (aarch64_pseudo_register_type): Likewise.
903 (aarch64_pseudo_register_reggroup_p): Likewise.
904 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
905 (aarch64_pseudo_read_value): Add V regs for SVE.
906 (aarch64_pseudo_write_2): Use V0 offset for SVE
907 (aarch64_pseudo_write): Add V regs for SVE.
908 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
910 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
912 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
913 (sve_vl_from_vq): Likewise.
915 2018-06-05 Tom Tromey <tom@tromey.com>
917 * cli/cli-cmds.c (show_version): Update.
918 * top.c (print_gdb_version): Add "interactive" parameter.
920 * main.c (captured_main_1): Update.
921 * top.h (print_gdb_version): Add "interactive" parameter and a
924 2018-06-05 David Malcolm <dmalcolm@redhat.com>
926 * common/enum-flags.h: Add trailing semicolon to example in
929 2018-06-05 Tom Tromey <tom@tromey.com>
932 * NEWS: Add entry about pager.
933 * utils.c (pagination_disabled_for_command): New global.
934 (prompt_for_continue): Allow "c" response to prompt.
935 (reinitialize_more_filter): Clear
936 pagination_disabled_for_command.
937 (fputs_maybe_filtered): Check pagination_disabled_for_command.
939 2018-06-04 Tom Tromey <tom@tromey.com>
941 * ada-lang.h (ada_lookup_symbol_list): Update.
942 * ada-lang.c (resolve_subexp): Update.
943 (symbols_are_identical_enums): Change type of syms. Remove nsyms
945 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
946 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
947 results parameter to std::vector.
948 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
950 * ada-exp.y (block_lookup): Update.
951 (select_possible_type_sym): Change type of syms. Remove nsyms
953 (write_var_or_type, write_name_assoc): Update.
955 2018-06-04 Joel Brobecker <brobecker@adacore.com>
957 * windows-nat.c (windows_nat_target::xfer_partial): Return
958 TARGET_XFER_E_IO if we need to delegate to the target beneath
961 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
963 * Makefile.in (config.status): Add configure.nat as a
966 2018-06-04 Tom Tromey <tom@tromey.com>
968 * cp-name-parser.y (cpname_state): Add method declarations.
969 (HANDLE_QUAL): Update.
970 (cpname_state::d_grab, cpname_state::fill_comp)
971 (cpname_state::make_operator, cpname_state::make_dtor)
972 (cpname_state::make_builtin_type, cpname_state::make_name)
973 (cpname_state::d_qualify, cpname_state::d_int_type)
974 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
975 (%union): Move earlier.
977 2018-06-04 Alan Hayward <alan.hayward@arm.com>
979 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
981 2018-06-04 Alan Hayward <alan.hayward@arm.com>
983 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
984 (aarch64_pseudo_write_1): Likewise.
985 (aarch64_pseudo_read_value): Use helper.
986 (aarch64_pseudo_write): Likewise.
988 2018-06-04 Pedro Alves <palves@redhat.com>
990 * darwin-nat.c (darwin_ops): Delete.
991 (darwin_attach_pid): Use get_native_target.
993 2018-06-04 Alan Hayward <alan.hayward@arm.com>
995 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
996 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
998 2018-06-04 Alan Hayward <alan.hayward@arm.com>
1000 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
1001 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
1002 (aarch64_gdbarch_init): Check for SVE.
1003 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
1005 2018-06-04 Alan Hayward <alan.hayward@arm.com>
1007 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
1008 * aarch64-tdep.h (aarch64_read_description): Likewise.
1009 * arch/aarch64.c (aarch64_create_target_description): Likewise.
1010 * arch/aarch64.h (aarch64_create_target_description): Likewise.
1011 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
1012 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
1013 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
1015 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
1017 * value.c (value_fetch_lazy_bitfield): New.
1018 (value_fetch_lazy_memory): New.
1019 (value_fetch_lazy_register): New.
1020 (value_fetch_lazy): Factor out to smaller functions.
1022 2018-06-01 Tom Tromey <tom@tromey.com>
1024 * cp-name-parser.y (backslashable, represented): Now const.
1026 2018-06-01 Tom Tromey <tom@tromey.com>
1028 * cp-name-parser.y: Include parser-defs.h.
1029 (parser_fprintf): Remove declaration.
1031 2018-06-01 Tom Tromey <tom@tromey.com>
1033 * cp-name-parser.y: Use %pure-parser, %lex-param, and
1035 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
1036 (global_result): Remove globals.
1037 (struct cpname_state): New.
1038 (yyparse): Don't declare.
1039 (yylex, yyerror): Move declarations after %union.
1040 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
1041 (make_name): Add state parameter.
1043 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
1045 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
1047 (yylex): Add lvalp, state parameters.
1048 (yyerror): Add state parameter.
1049 (cp_demangled_name_to_comp): Update.
1051 2018-06-01 Tom Tromey <tom@tromey.com>
1053 * cp-name-parser.y (parser_fprintf): Declare.
1054 (GDB_YY_REMAP_PREFIX): Define.
1055 Include yy-remap.h. Don't redefine yy* identifiers.
1057 2018-06-01 Tom Tromey <tom@tromey.com>
1059 * python/py-type.c (typy_legacy_template_argument): Update.
1060 * cp-support.h (cp_demangled_name_to_comp): Update.
1061 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
1062 parameter to be a "std::string *".
1065 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
1067 * ada-lex.l: Include "diagnostics.h" instead of
1068 "common/diagnostics.h".
1069 * unittests/environ-selftests.c: Likewise.
1070 * common/diagnostics.h: Moved to ../include.
1072 2018-06-01 Joel Brobecker <brobecker@adacore.com>
1074 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
1075 to language_mode_manual while calling breakpoint_re_set_one.
1077 2018-06-01 Tom Tromey <tom@tromey.com>
1079 * valops.c (value_cast_structs, destructor_name_p): Update.
1080 * symtab.c (gdb_mangle_name): Update.
1081 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
1083 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
1084 (pascal_object_print_value_fields, pascal_object_print_value):
1086 * p-typeprint.c (pascal_type_print_derivation_info): Update.
1087 * linespec.c (find_methods): Update.
1088 * gdbtypes.h (type_name_no_tag): Remove.
1089 (type_name_or_error): Rename from type_name_no_tag_or_error.
1090 * gdbtypes.c (type_name_no_tag): Remove.
1091 (type_name_or_error): Rename from type_name_no_tag_or_error.
1092 (lookup_struct_elt_type, check_typedef): Update.
1093 * expprint.c (print_subexp_standard): Update.
1094 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
1095 * d-namespace.c (d_lookup_nested_symbol): Update.
1096 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
1097 (cp_print_class_member): Update.
1098 * cp-namespace.c (cp_lookup_nested_symbol): Update.
1099 * completer.c (add_struct_fields): Update.
1100 * c-typeprint.c (cp_type_print_derivation_info)
1101 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
1103 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
1104 (ada_prefer_type, ada_is_exception_sym): Update.
1106 2018-06-01 Tom Tromey <tom@tromey.com>
1108 * valops.c (enum_constant_from_type, value_namespace_elt)
1109 (value_maybe_namespace_elt): Update.
1110 * valarith.c (find_size_for_pointer_math): Update.
1111 * target-descriptions.c (make_gdb_type): Update.
1112 * symmisc.c (print_symbol): Update.
1113 * stabsread.c (define_symbol, read_type)
1114 (complain_about_struct_wipeout, add_undefined_type)
1115 (cleanup_undefined_types_1): Update.
1116 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
1117 (rust_range_type_p, val_print_struct, rust_print_struct_def)
1118 (rust_internal_print_type, rust_composite_type)
1119 (rust_evaluate_funcall, rust_evaluate_subexp)
1120 (rust_inclusive_range_type_p): Update.
1121 * python/py-type.c (typy_get_tag): Update.
1122 * p-typeprint.c (pascal_type_print_base): Update.
1123 * mdebugread.c (parse_symbol, parse_type): Update.
1124 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
1126 * guile/scm-type.c (gdbscm_type_tag): Update.
1127 * go-lang.c (sixg_string_p): Update.
1128 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
1130 * gdbtypes.h (struct main_type) <tag_name>: Remove.
1131 (TYPE_TAG_NAME): Remove.
1132 * gdbtypes.c (type_name_no_tag): Simplify.
1133 (check_typedef, check_types_equal, recursive_dump_type)
1134 (copy_type_recursive, arch_composite_type): Update.
1135 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
1136 in summary mode when needed.
1137 * eval.c (evaluate_funcall): Update.
1138 * dwarf2read.c (fixup_go_packaging, read_structure_type)
1139 (process_structure_scope, read_enumeration_type)
1140 (read_namespace_type, read_module_type, determine_prefix): Update.
1141 * cp-support.c (inspect_type): Update.
1142 * coffread.c (process_coff_symbol, decode_base_type): Update.
1143 * c-varobj.c (c_is_path_expr_parent): Update.
1144 * c-typeprint.c (c_type_print_base_struct_union): Update.
1145 (c_type_print_base_1): Update. Print struct/class/union/enum in
1146 summary when using C language.
1147 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
1148 (gen_maybe_namespace_elt): Update.
1149 * ada-lang.c (ada_type_name): Simplify.
1150 (empty_record, ada_template_to_fixed_record_type_1)
1151 (template_to_static_fixed_type)
1152 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
1154 2018-06-01 Tom Tromey <tom@tromey.com>
1156 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
1158 * c-typeprint.c (c_print_type_1): Add "language" parameter.
1159 (c_print_type): Update.
1160 (c_print_type): New overload.
1161 (c_type_print_varspec_prefix, c_type_print_args)
1162 (c_type_print_varspec_suffix, c_print_type_no_offsets)
1163 (c_type_print_base_struct_union, c_type_print_base_1)
1164 (cp_type_print_method_args): Add "language" parameter.
1165 (c_type_print_base): Update.
1166 * c-lang.h (c_print_type): Add new overload.
1168 2018-06-01 Tom Tromey <tom@tromey.com>
1170 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
1171 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
1173 2018-06-01 Alan Hayward <alan.hayward@arm.com>
1175 * aarch64-tdep.c (aarch64_sve_register_names): New const
1177 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
1178 (AARCH64_SVE_Z_REGS_NUM): New define.
1179 (AARCH64_SVE_P_REGS_NUM): Likewise.
1180 (AARCH64_SVE_NUM_REGS): Likewise.
1182 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
1184 * nat/linux-ptrace.h [__alpha__]
1185 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
1188 2018-05-31 Maciej W. Rozycki <macro@mips.com>
1190 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
1191 the endianness selected.
1192 * NEWS: Document `set endian auto' mode operation update.
1194 2018-05-31 Alan Hayward <alan.hayward@arm.com>
1196 * Makefile.in: Add new header.
1197 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
1198 (sve_vl_from_vg): Likewise.
1199 (sve_vq_from_vl): Likewise.
1200 (sve_vl_from_vq): Likewise.
1201 (sve_vq_from_vg): Likewise.
1202 (sve_vg_from_vq): Likewise.
1203 * configure.nat: Add new c file.
1204 * nat/aarch64-sve-linux-ptrace.c: New file.
1205 * nat/aarch64-sve-linux-ptrace.h: New file.
1207 2018-05-31 Alan Hayward <alan.hayward@arm.com>
1209 * aarch64-linux-nat.c (aarch64_linux_read_description):
1211 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
1213 * aarch64-tdep.c (tdesc_aarch64_list): Add.
1214 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
1215 (aarch64_gdbarch_init): Add parmeter zero.
1216 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
1217 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
1218 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
1220 * doc/gdb.texinfo: Describe SVE feature
1221 * features/aarch64-sve.c: New file.
1223 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
1226 * gdbarch.sh (significant_addr_bit): Default to zero when
1227 not set by target architecture.
1228 * gdbarch.c: Re-generated.
1229 * utils.c (address_significant): Update.
1231 2018-05-30 Joel Brobecker <brobecker@adacore.com>
1233 * stack.c (func_command): Remove trailing newline in call to error.
1235 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1237 * regcache.h (regcache_raw_collect): Remove, update callers to
1238 use regcache::raw_collect.
1239 * regcache.c (regcache_raw_collect): Remove.
1241 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1243 * regcache.h (regcache_raw_supply): Remove, update callers to
1244 use detached_regcache::raw_supply.
1245 * regcache.c (regcache_raw_supply): Remove.
1247 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1249 * regcache.h (regcache_cooked_write_part): Remove, update
1250 callers to use regcache::cooked_write_part.
1251 * regcache.c (regcache_cooked_write_part): Remove.
1253 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1255 * regcache.h (regcache_cooked_read_part): Remove, update callers
1256 to use readable_regcache::cooked_read_part.
1257 * regcache.c (regcache_cooked_read_part): Remove.
1259 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1261 * regcache.h (regcache_cooked_read_value): Remove, update
1262 callers to use readable_regcache::cooked_read_value.
1263 * regcache.c (regcache_cooked_read_value): Remove.
1265 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1267 * regcache.h (regcache_cooked_write): Remove, update callers to
1268 use regcache::cooked_write.
1269 * regcache.c (regcache_cooked_write): Remove.
1271 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1273 * regcache.h (regcache_invalidate): Remove, update callers to
1274 use detached_regcache::invalidate instead.
1275 * regcache.c (regcache_invalidate): Remove.
1277 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1279 * regcache.h (regcache_raw_write_part): Remove, update callers
1280 to use regcache::raw_write_part instead.
1281 * regcache.c (regcache_raw_write_part): Remove.
1283 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1285 * regcache.h (regcache_raw_read_part): Remove, update callers to
1286 use readable_regcache::raw_read_part instead.
1287 * regcache.c (regcache_raw_read_part): Remove.
1289 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1291 * regcache.h (regcache_cooked_read): Remove, update callers to
1292 use readable_regcache::cooked_read instead.
1293 * regcache.c (regcache_cooked_read): Remove.
1295 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1297 * regcache.h (regcache_raw_write): Remove, update callers to use
1298 regcache::raw_write instead.
1299 * regcache.c (regcache_raw_write): Remove.
1301 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1303 * regcache.h (regcache_raw_read): Remove, update callers to use
1304 readable_regcache::raw_read instead.
1305 * regcache.c (regcache_raw_read): Remove.
1307 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1309 * regcache.h (regcache_raw_update): Remove, update callers to
1310 use readable_regcache::raw_update instead.
1311 * regcache.c (regcache_raw_update): Remove.
1313 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1315 * regcache.h (regcache_register_status): Remove, update callers
1316 to use reg_buffer::get_register_status directly instead.
1317 * regcache.c (regcache_register_status): Remove.
1319 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1321 * regcache.h (regcache_get_ptid): Remove, update all callers to
1322 call regcache::ptid instead.
1323 * regcache.c (regcache_get_ptid): Remove.
1325 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1327 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
1329 2018-05-30 Pedro Alves <palves@redhat.com>
1331 * common/common-exceptions.h (exception_rethrow): Use
1334 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
1336 * breakpoint.c (print_solib_event, check_status_catch_solib):
1337 Remove struct keyword in range-based for loops.
1338 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
1339 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
1341 * linespec.c (find_superclass_methods, search_minsyms_for_name):
1343 * symfile.c (addr_info_make_relative): Likewise.
1344 * thread.c (value_in_thread_stack_temporaries): Likewise.
1346 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
1349 * valops.c (value_struct_elt_for_reference): Call check_typedef on
1350 aggregate type to get its real type before accessing it.
1352 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
1354 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
1355 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
1356 * coff-pe-read.c (add_pe_forwarded_sym): Replace
1357 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
1358 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
1359 * jit.c (jit_breakpoint_re_set_internal): Likewise.
1360 * printcmd.c (info_address_command): Likewise.
1362 2018-05-29 Tom Tromey <tom@tromey.com>
1364 * windows-nat.c (handle_exception): Update fall-through comment.
1366 2018-05-29 Tom Tromey <tom@tromey.com>
1368 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
1369 (struct program_space) <added_solibs>: Now a std::vector.
1370 * breakpoint.c (print_solib_event): Update.
1371 (check_status_catch_solib): Update.
1372 * progspace.c (clear_program_space_solib_cache): Update.
1373 * solib.c (update_solib_list): Update.
1375 2018-05-29 Tom Tromey <tom@tromey.com>
1377 * python/py-type.c (typy_richcompare): Update.
1378 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
1379 * gdbtypes.h (types_deeply_equal): Return bool.
1380 (types_equal): Likewise.
1381 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
1383 (check_types_equal): Change worklist to std::vector. Return
1385 (struct type_equality_entry): Add constructor.
1386 (compare_maybe_null_strings): Return bool.
1387 (check_types_worklist): Return bool. Change worklist to
1389 (types_deeply_equal): Use std::vector.
1390 (types_equal): Return bool.
1391 (compare_maybe_null_strings): Simplify.
1393 2018-05-29 Tom Tromey <tom@tromey.com>
1395 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
1397 2018-05-29 Tom Tromey <tom@tromey.com>
1399 * objc-lang.h: Don't include cp-support.h.
1400 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
1403 2018-05-27 Tom Tromey <tom@tromey.com>
1405 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
1407 2018-05-25 Tom Tromey <tom@tromey.com>
1409 * value.c (value::location): Initialize.
1411 2018-05-25 Tom Tromey <tom@tromey.com>
1413 * dbxread.c (init_bincl_list): Remove.
1414 (bincl_list): Now a std::vector.
1415 (bincls_allocated, next_bincl): Remove.
1416 (free_bincl_list, do_free_bincl_list_cleanup)
1417 (make_cleanup_free_bincl_list): Remove.
1418 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
1420 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
1421 (struct header_file_location): Add constructor.
1422 (add_bincl_to_list): Remove.
1424 2018-05-25 Tom Tromey <tom@tromey.com>
1426 * tui/tui.c (tui_enable): Update.
1427 * mi/mi-interp.c (mi_interp::init): Update.
1428 * interps.h (class interp) <name>: New method.
1429 <m_name>: Rename from name.
1430 (~scoped_restore_interp): Update.
1431 * interps.c (interp::interp): Update.
1432 (interp_add, interp_set, interp_lookup_existing)
1433 (current_interp_named_p): Update.
1435 2018-05-25 Tom Tromey <tom@tromey.com>
1437 * interps.c (interp_name): Remove.
1438 * mi/mi-interp.c (mi_interp::init): Update.
1439 * interps.h (interp_name): Remove.
1440 (~scoped_restore_interp): Update.
1441 * tui/tui.c (tui_enable): Update.
1443 2018-05-25 Tom Tromey <tom@tromey.com>
1445 * utils.c (fputs_maybe_filtered): Update.
1446 * linespec.c (decode_line_full): Update.
1447 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
1448 (mi_print_breakpoint_for_event, mi_solib_loaded)
1449 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
1450 (mi_user_selected_context_changed): Update.
1451 * mi/mi-main.c (mi_execute_command): Update.
1452 * cli/cli-script.c (execute_control_command): Update.
1453 * python/python.c (execute_gdb_command): Update.
1454 * solib.c (info_sharedlibrary_command): Update.
1455 * interps.c (interp_ui_out): Remove.
1456 * interps.h (interp_ui_out): Remove.
1458 2018-05-25 Tom Tromey <tom@tromey.com>
1460 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
1461 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
1462 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
1464 2018-05-25 Tom Tromey <tom@tromey.com>
1466 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
1467 * interps.c (interp_exec): Use scoped_restore.
1469 2018-05-25 Tom Tromey <tom@tromey.com>
1471 * remote.c (remote_target::remote_file_get): Use
1473 (remote_target::remote_file_put): Likewise.
1475 2018-05-25 Tom Tromey <tom@tromey.com>
1477 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
1479 (get_pe_section_index, add_pe_exported_sym): Update.
1480 (read_pe_exported_syms): Use gdb::def_vector.
1482 2018-05-25 Tom Tromey <tom@tromey.com>
1484 * frame.c (remove_prev_frame): Remove.
1485 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
1487 2018-05-25 Maciej W. Rozycki <macro@mips.com>
1489 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
1491 * mips-linux-nat.c (supply_fpregset): Always call
1492 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
1493 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
1494 `mips_fill_fpregset'.
1495 * mips-linux-tdep.c (mips_supply_fpregset)
1496 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
1497 (mips_fill_fpregset_wrapper): Remove functions.
1498 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
1499 (mips_linux_fpregset): Remove variable.
1500 (mips_linux_iterate_over_regset_sections): Use
1501 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
1502 (mips_linux_o32_sigframe_init): Remove comment.
1504 2018-05-25 Pedro Alves <palves@redhat.com>
1506 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
1507 (struct readahead_cache, struct packet_reg, struct
1508 remote_arch_state, class remote_state): Move higher up in the
1510 (remote_target::m_remote_state): Now an object instead of a pointer.
1511 (remote_target::get_remote_state): Adjust.
1513 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
1515 * stack.c (select_and_print_frame): Delete.
1516 (struct function_bounds): Move struct within function.
1517 (func_command): Most content moved into new function
1518 find_frame_for_function, use new function, print result, add
1520 (find_frame_for_function): New function, now returns a result.
1522 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1524 * stack.c (iterate_over_block_arg_vars): Fix comment.
1525 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
1527 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
1531 (scoped_restore_selected_frame::scoped_restore_selected_frame):
1533 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
1535 * frame.h (class scoped_restore_selected_frame): New class.
1536 * stack.c (print_frame_local_vars): Remove catching and rethrowing
1537 of any exception, use scoped_restore_selected_frame to restore the
1540 2018-05-24 Pedro Alves <palves@redhat.com>
1542 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
1545 2018-05-23 Tom Tromey <tom@tromey.com>
1547 * complaints.c (struct complaints): Remove.
1548 (symfile_complaint_book): Remove.
1549 (series): New global.
1550 (complaint_internal): Update.
1551 (clear_complaints): Update.
1553 2018-05-23 Tom Tromey <tom@tromey.com>
1555 * complaints.c (counters): New global.
1556 (struct complain): Remove.
1557 (struct complaints) <root>: Remove.
1558 (complaint_sentinel): Remove.
1559 (symfile_complaint_book): Update.
1560 (find_complaint) Remove.
1561 (complaint_internal, clear_complaints): Update.
1563 2018-05-23 Tom Tromey <tom@tromey.com>
1565 * complaints.c (struct complain) <file, line>: Remove.
1566 (find_complaint): Remove file, line parameters.
1567 (complaint_internal): Update.
1569 2018-05-23 Tom Tromey <tom@tromey.com>
1571 * complaints.c (vcomplaint): Remove.
1572 (complaint_internal) Merge in contents of vcomplaint.
1574 2018-05-23 Tom Tromey <tom@tromey.com>
1576 * complaints.c (struct complaints) <explanation>: Remove.
1577 (symfile_explanations): Remove.
1578 (symfile_complaint_book): Update.
1579 (vcomplaint): Update.
1580 (struct explanation): Remove.
1582 2018-05-23 Tom Tromey <tom@tromey.com>
1584 * complaints.c (symfile_complaints): Remove.
1585 (complaint_internal): Remove "complaints" parameter.
1586 (clear_complaints, vcomplaint): Remove "c" parameter.
1587 (get_complaints): Remove.
1588 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
1589 (dwarf2_debug_line_missing_file_complaint)
1590 (dwarf2_debug_line_missing_end_sequence_complaint)
1591 (dwarf2_complex_location_expr_complaint)
1592 (dwarf2_const_value_length_mismatch_complaint)
1593 (dwarf2_section_buffer_overflow_complaint)
1594 (dwarf2_macro_malformed_definition_complaint)
1595 (dwarf2_invalid_attrib_class_complaint)
1596 (create_addrmap_from_index, dw2_symtab_iter_next)
1597 (dw2_expand_marked_cus)
1598 (dw2_debug_names_iterator::find_vec_in_debug_names)
1599 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
1600 (create_debug_type_hash_table, init_cutu_and_read_dies)
1601 (partial_die_parent_scope, add_partial_enumeration)
1602 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
1603 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
1604 (read_import_statement, read_file_scope, create_dwo_cu_reader)
1605 (create_cus_hash_table, create_dwp_hash_table)
1606 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
1607 (dwarf2_rnglists_process, dwarf2_ranges_process)
1608 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
1609 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
1610 (handle_struct_member_die, process_structure_scope)
1611 (read_array_type, read_common_block, read_module_type)
1612 (read_tag_pointer_type, read_typedef, read_base_type)
1613 (read_subrange_type, load_partial_dies, partial_die_info::read)
1614 (partial_die_info::read, partial_die_info::read)
1615 (partial_die_info::read, read_checked_initial_length_and_offset)
1616 (dwarf2_string_attr, read_formatted_entries)
1617 (dwarf_decode_line_header)
1618 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
1619 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
1620 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
1621 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
1622 (get_signatured_type, get_DW_AT_signature_type)
1623 (decode_locdesc, file_file_name, consume_improper_spaces)
1624 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
1625 (dwarf_decode_macro_bytes, dwarf_decode_macros)
1626 (dwarf2_symbol_mark_computed, set_die_type)
1627 (read_attribute_value): Update.
1628 * stap-probe.c (handle_stap_probe, get_stap_base_address):
1630 * dbxread.c (unknown_symtype_complaint)
1631 (lbrac_mismatch_complaint, repeated_header_complaint)
1632 (set_namestring, function_outside_compilation_unit_complaint)
1633 (read_dbx_symtab, process_one_symbol): Update.
1634 * gdbtypes.c (stub_noname_complaint): Update.
1635 * windows-nat.c (handle_unload_dll): Update.
1636 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
1637 (decode_base_type): Update.
1638 * xcoffread.c (bf_notfound_complaint, ef_complaint)
1639 (eb_complaint, record_include_begin, record_include_end)
1640 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
1641 (process_xcoff_symbol, read_symbol)
1642 (function_outside_compilation_unit_complaint)
1643 (scan_xcoff_symtab): Update.
1644 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
1645 * buildsym.c (finish_block_internal, make_blockvector)
1646 (end_symtab_get_static_block, augment_type_symtab): Update.
1647 * dtrace-probe.c (dtrace_process_dof)
1648 (dtrace_static_probe_ops::get_probes): Update.
1649 * complaints.h (struct complaint): Don't declare.
1650 (symfile_complaints): Remove.
1651 (complaint_internal): Remove "complaints" parameter.
1652 (complaint): Likewise.
1653 (clear_complaints): Likewise.
1654 * symfile.c (syms_from_objfile_1, finish_new_objfile)
1655 (reread_symbols): Update.
1656 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
1657 (dwarf2_frame_cache, decode_frame_entry): Update.
1658 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
1659 * objc-lang.c (lookup_objc_class, lookup_child_selector)
1660 (info_selectors_command): Update.
1661 * macrotab.c (macro_include, check_for_redefinition)
1662 (macro_undef): Update.
1663 * objfiles.c (filter_overlapping_sections): Update.
1664 * stabsread.c (invalid_cpp_abbrev_complaint)
1665 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
1666 (define_symbol, error_type, read_type, rs6000_builtin_type)
1667 (stabs_method_name_from_physname, read_member_functions)
1668 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
1669 (attach_fields_to_type, complain_about_struct_wipeout)
1670 (read_range_type, read_args, common_block_start)
1671 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
1673 * mdebugread.c (index_complaint, unknown_ext_complaint)
1674 (basic_type_complaint, bad_tag_guess_complaint)
1675 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
1676 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
1677 (parse_procedure, parse_lines)
1678 (function_outside_compilation_unit_complaint)
1679 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
1680 (bad_tag_guess_complaint, reg_value_complaint): Update.
1681 * cp-support.c (demangled_name_complaint): Update.
1682 * macroscope.c (sal_macro_scope): Update.
1683 * dwarf-index-write.c (class debug_names): Update.
1685 2018-05-23 Tom Tromey <tom@tromey.com>
1687 * complaints.c (clear_complaints): Remove "noisy" parameter.
1688 * complaints.h (clear_complaints): Update.
1689 * symfile.c (syms_from_objfile_1, finish_new_objfile)
1690 (reread_symbols): Update.
1692 2018-05-23 Tom Tromey <tom@tromey.com>
1694 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
1696 (vcomplaint, clear_complaints): Update.
1697 (symfile_explanations): Remove some messages.
1699 2018-05-23 Tom Tromey <tom@tromey.com>
1701 * complaints.c (internal_complaint): Remove.
1702 * complaints.h (internal_complaint): Remove.
1704 2018-05-22 Maciej W. Rozycki <macro@mips.com>
1706 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
1708 2018-05-22 Pedro Alves <palves@redhat.com>
1710 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
1711 (remote_fileio_badfd, remote_fileio_return_errno)
1712 (remote_fileio_return_success, remote_fileio_func_open)
1713 (remote_fileio_func_open, remote_fileio_func_close)
1714 (remote_fileio_func_read, remote_fileio_func_write)
1715 (remote_fileio_func_lseek, remote_fileio_func_rename)
1716 (remote_fileio_func_unlink, remote_fileio_func_stat)
1717 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
1718 (remote_fileio_func_isatty, remote_fileio_func_system): Add
1719 remote_target parameter.
1720 (remote_fio_func_map) <func>: Add remote_target parameter.
1721 (do_remote_fileio_request, remote_fileio_request):
1722 * remote-fileio.h (remote_fileio_request):
1723 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
1724 remote_target parameter.
1725 (remote_notif_process, handle_notification): Adjust to pass down
1727 (remote_notif_state_allocate): Add remote_target parameter. Save
1729 * remote-notif.h (struct remote_target): Forward declare.
1730 (struct notif_client) <parse, ack, can_get_pending_events>: Add
1731 remote_target parameter.
1732 (struct remote_notif_state) <remote>: New field.
1733 (remote_notif_ack, remote_notif_parse): Add remote_target
1735 (remote_notif_state_allocate, remote_notif_state_allocate): Add
1736 remote_target parameter.
1737 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
1738 (threads_listing_context, rmt_thread_action, protocol_feature)
1739 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
1740 (packet_result, struct threads_listing_context, remote_state):
1741 Move definitions and declarations higher up.
1742 (remote_target) <~remote_target>: Declare.
1743 (remote_download_command_source, remote_file_put, remote_file_get)
1744 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
1745 (remote_hostio_pread_vFile, remote_hostio_send_command)
1746 (remote_hostio_set_filesystem, remote_hostio_open)
1747 (remote_hostio_close, remote_hostio_unlink, remote_state)
1748 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
1749 (get_memory_write_packet_size, get_memory_read_packet_size)
1750 (append_pending_thread_resumptions, remote_detach_1)
1751 (append_resumption, remote_resume_with_vcont)
1752 (add_current_inferior_and_thread, wait_ns, wait_as)
1753 (process_stop_reply, remote_notice_new_inferior)
1754 (process_initial_stop_replies, remote_add_thread)
1755 (btrace_sync_conf, remote_btrace_maybe_reopen)
1756 (remove_new_fork_children, kill_new_fork_children)
1757 (discard_pending_stop_replies, stop_reply_queue_length)
1758 (check_pending_events_prevent_wildcard_vcont)
1759 (discard_pending_stop_replies_in_queue, stop_reply)
1760 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
1761 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
1762 (remote_interrupt_as, remote_interrupt_ns)
1763 (remote_get_noisy_reply, remote_query_attached)
1764 (remote_add_inferior, remote_current_thread, get_current_thread)
1765 (set_thread, set_general_thread, set_continue_thread)
1766 (set_general_process, write_ptid)
1767 (remote_unpack_thread_info_response, remote_get_threadinfo)
1768 (parse_threadlist_response, remote_get_threadlist)
1769 (remote_threadlist_iterator, remote_get_threads_with_ql)
1770 (remote_get_threads_with_qxfer)
1771 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
1772 (get_offsets, remote_check_symbols, remote_supported_packet)
1773 (remote_query_supported, remote_packet_size)
1774 (remote_serial_quit_handler, remote_detach_pid)
1775 (remote_vcont_probe, remote_resume_with_hc)
1776 (send_interrupt_sequence, interrupt_query)
1777 (remote_notif_get_pending_events, fetch_register_using_p)
1778 (send_g_packet, process_g_packet, fetch_registers_using_g)
1779 (store_register_using_P, store_registers_using_G)
1780 (set_remote_traceframe, check_binary_download)
1781 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
1782 (remote_xfer_live_readonly_partial, remote_read_bytes)
1783 (remote_send_printf, remote_flash_write, readchar)
1784 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
1785 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
1786 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
1787 (extended_remote_disable_randomization, extended_remote_run)
1788 (send_environment_packet, extended_remote_environment_support)
1789 (extended_remote_set_inferior_cwd, remote_write_qxfer)
1790 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
1791 (packet_command): Now methods of ...
1792 (remote_target): ... this class.
1793 (m_remote_state) <remote_target>: New field.
1794 (struct remote_state) <stop_reply_queue,
1795 remote_async_inferior_event_token, wait_forever_enabled_p>: New
1797 (remote_state::remote_state): Allocate stop_reply_queue.
1798 (remote_state): Delete global.
1799 (get_remote_state_raw): Delete.
1800 (remote_target::get_remote_state): Allocate m_remote_state on
1802 (get_current_remote_target): New.
1803 (remote_ops, extended_remote_ops): Delete.
1804 (wait_forever_enabled_p, remote_async_inferior_event_token):
1805 Delete, moved to struct remote_state.
1806 (remote_target::close): Delete self. Destruction bits split to
1808 (remote_target::~remote_target): ... this.
1809 (show_memory_packet_size): Adjust to use
1810 get_current_remote_target.
1811 (struct protocol_feature) <func>: Add remote_target parameter.
1812 All callers adjusted.
1813 (curr_quit_handler_target): New.
1814 (remote_serial_quit_handler): Reimplement.
1815 (remote_target::open_1): Adjust to use get_current_remote_target.
1816 Heap-allocate remote_target/extended_remote_target instances.
1817 (vcont_builder::vcont_builder): Add remote_target parameter, and
1818 save it in m_remote. All callers adjusted.
1819 (vcont_builder::m_remote): New field.
1820 (vcont_builder::restart, vcont_builder::flush)
1821 (vcont_builder::push_action): Use it.
1822 (remote_target::commit_resume): Use it.
1823 (struct queue_iter_param) <remote>: New field.
1824 (remote_target::remove_new_fork_children): Fill in 'remote' field.
1825 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
1826 (check_pending_event_prevents_wildcard_vcont_callback)
1827 (remote_target::check_pending_events_prevent_wildcard_vcont)
1828 (remote_target::discard_pending_stop_replies)
1829 (remote_target::discard_pending_stop_replies_in_queue)
1830 (remote_target::remote_notif_remove_queued_reply): Fill in
1832 (remote_notif_get_pending_events): New.
1833 (remote_target::readchar, remote_target::remote_serial_write):
1834 Save/restore curr_quit_handler_target.
1836 (kill_new_fork_children): Fill in 'remote' field.
1837 (packet_command): Use get_current_remote_target, defer to
1838 remote_target method of same name.
1839 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
1840 parameter, and save it in m_remote. All callers adjusted.
1841 (scoped_remote_fd::release): Use m_remote.
1842 (scoped_remote_fd::m_remote): New field.
1843 (remote_file_put, remote_file_get, remote_file_delete): Use
1844 get_current_remote_target, defer to remote_target method of same
1846 (remote_btrace_reset): Add remote_state paremeter. Update all
1848 (remote_async_inferior_event_handler). Pass down 'data'.
1849 (remote_new_objfile): Use get_current_remote_target.
1850 (remote_target::vcont_r_supported): New.
1851 (set_range_stepping): Use get_current_remote_target and
1852 remote_target::vcont_r_supported.
1853 (_initialize_remote): Don't allocate 'remote_state' and
1854 'stop_reply_queue' globals.
1855 * remote.h (struct remote_target): Forward declare.
1856 (getpkt, putpkt, remote_notif_get_pending_events): Add
1857 'remote_target' parameter.
1859 2018-05-22 Pedro Alves <palves@redhat.com>
1861 * remote.c (vcont_builder): Now a class. Make all data members
1863 (vcont_builder) <vcont_builder, restart, flush, push_action>:
1865 (vcont_builder_restart): Rename to ...
1866 (vcont_builder::restart): ... this.
1867 (vcont_builder_flush): Rename to ...
1868 (vcont_builder::flush): ... this.
1869 (vcont_builder_push_action): Rename to ...
1870 (vcont_builder::push_action): ... this.
1871 (remote_target::commit_resume): Adjust.
1873 2018-05-22 Pedro Alves <palves@redhat.com>
1875 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
1876 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
1877 (get_fixed_memory_packet_size): New.
1878 (get_memory_packet_size): Use it.
1879 (set_memory_packet_size): Don't override the config size with
1880 DEFAULT_MAX_MEMORY_PACKET_SIZE.
1881 (show_memory_packet_size): Use get_fixed_memory_packet_size.
1882 Don't refer to get_memory_packet_size if not connected to a remote
1883 target. Show "(default)" if configured size is 0.
1885 2018-05-22 Pedro Alves <palves@redhat.com>
1887 * remote.c (remote_target::mourn_inferior): Move
1888 discard_pending_stop_replies call here from ...
1889 (_initialize_remote): ... here.
1891 2018-05-22 Pedro Alves <palves@redhat.com>
1893 * remote.c (compare_section_command): Remove set_general_process
1896 2018-05-22 Pedro Alves <palves@redhat.com>
1898 * remote.c (struct packet_reg, struct remote_arch_state):
1899 Move higher up in the file.
1900 (remote_state) <m_arch_states>: Store remote_arch_state values
1901 instead of remote_arch_state pointers.
1902 (remote_state::get_remote_arch_state): Adjust.
1904 2018-05-22 Pedro Alves <palves@redhat.com>
1906 * remote.c: Include <unordered_map>.
1907 (remote_state): Now a class.
1908 (remote_state) <get_remote_arch_state>: Declare method.
1909 <get_remote_arch_state>: New field.
1910 (remote_arch_state) <remote_arch_state>: Declare ctor.
1911 <regs>: Now a unique_ptr.
1912 (remote_gdbarch_data_handle): Delete.
1913 (get_remote_arch_state): Delete.
1914 (remote_state::get_remote_arch_state): New.
1915 (get_remote_state): Adjust to call remote_state's
1916 get_remote_arch_state method.
1917 (init_remote_state): Delete, bits factored out to ...
1918 (remote_arch_state::remote_arch_state): ... this new method.
1919 (get_remote_packet_size, get_memory_packet_size)
1920 (process_g_packet, remote_target::fetch_registers)
1921 (remote_target::prepare_to_store, store_registers_using_G)
1922 (remote_target::store_registers, remote_target::get_trace_status):
1923 Adjust to call remote_state's method.
1924 (_initialize_remote): Remove reference to
1925 remote_gdbarch_data_handle.
1927 2018-05-22 Pedro Alves <palves@redhat.com>
1929 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
1930 pread>: New method declarations.
1931 (remote_target::open_1): Adjust.
1932 (readahead_cache_invalidate): Rename to ...
1933 (readahead_cache::invalidate): ... this, and adjust to be a class
1935 (readahead_cache_invalidate_fd): Rename to ...
1936 (readahead_cache::invalidate_fd): ... this, and adjust to be a
1938 (remote_hostio_pwrite): Adjust.
1939 (remote_hostio_pread_from_cache): Rename to ...
1940 (readahead_cache::pread): ... this, and adjust to be a class
1942 (remote_hostio_close): Adjust.
1944 2018-05-22 Pedro Alves <palves@redhat.com>
1946 * remote.c (remote_hostio_close_cleanup): Delete.
1947 (class scoped_remote_fd): New.
1948 (remote_file_put, remote_file_get): Use it.
1950 2018-05-22 Pedro Alves <palves@redhat.com>
1952 (struct vCont_action_support): Use bool and initialize all fields.
1953 (struct readahead_cache): Initialize all fields.
1954 (remote_state): Use bool and initialize all fields.
1955 (remote_state::remote_state, remote_state::~remote_state): New.
1956 (new_remote_state): Delete.
1957 (_initialize_remote): Use new to allocate remote_state.
1959 2018-05-22 Pedro Alves <palves@redhat.com>
1963 * c-exp.y: Include "c-support.h".
1964 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
1965 of tolower. Use c_ident_is_alpha to scan names.
1966 * c-lang.c: Include "c-support.h".
1967 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
1968 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
1969 * c-support.h: New file, with bits factored out from ...
1970 * cp-name-parser.y: ... this file.
1971 Include "c-support.h".
1972 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
1973 c-support.h and renamed.
1974 (symbol_end, yylex): Adjust.
1976 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1978 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
1979 parameter type to CORE_ADDR.
1980 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
1981 parameter type in declaration to CORE_ADDR.
1982 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
1983 target_auxv_search to get AT_HWCAP and use the result to get the
1985 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
1986 to CORE_ADDR. Remove the cast of the return value to unsigned
1987 long. Fix error predicate of target_auxv_search.
1988 (ppc_linux_nat_target::read_description): Change the type of the
1989 hwcap variable to CORE_ADDR.
1991 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1993 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
1994 if the size of fpscr is larger than 32 bits.
1996 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1998 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
1999 (ppc32_linux_vsxregmap): New global.
2000 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
2001 regcache_supply_regset, and regcache_collect_regset.
2002 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
2003 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
2004 (fetch_vsx_register, store_vsx_register): Remove.
2005 (fetch_vsx_registers): Add regno parameter. Get regset using
2006 ppc_linux_vsxregset. Use regset to supply registers.
2007 (store_vsx_registers): Add regno parameter. Get regset using
2008 ppc_linux_vsxregset. Use regset to collect registers.
2009 (fetch_register): Call fetch_vsx_registers instead of
2011 (store_register): Call store_vsx_registers instead of
2013 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
2014 new regno parameter.
2015 (store_ppc_registers): Call store_vsx_registers with -1 for the
2016 new regno parameter.
2017 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
2018 (ppc_collect_vsxregset): Remove.
2020 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2022 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
2024 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
2025 for vector register offset fields.
2026 (ppc64_fbsd_reg_offsets): Likewise.
2027 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
2028 to vector register offset fields.
2029 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
2030 to vector register offset fields.
2031 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
2032 vector register offset fields.
2033 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
2034 initializers for vector register offset fields.
2035 (rs6000_aix64_reg_offsets): Likewise.
2036 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
2037 (ppc_supply_vrregset): Remove.
2038 (ppc_collect_vrregset): Remove.
2039 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
2040 (ppc_linux_vrregset) : New function.
2041 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
2042 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
2043 (ppc32_linux_vrregset): Remove.
2044 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
2045 and use result instead of ppc32_linux_vrregset.
2046 (ppc32_linux_reg_offsets): Remove initializers for vector register
2048 (ppc64_linux_reg_offsets): Likewise.
2049 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
2050 * ppc-linux-nat.c: Include regset.h.
2051 (gdb_vrregset_t): Adjust comment to account for little-endian
2053 (supply_vrregset, fill_vrregset): Remove.
2054 (fetch_altivec_register, store_altivec_register): Remove.
2055 (fetch_altivec_registers): Add regno parameter. Get regset using
2056 ppc_linux_vrregset. Use regset to supply registers.
2057 (store_altivec_registers): Add regno parameter. Get regset using
2058 ppc_linux_vrregset. Use regset to collect registers.
2059 (fetch_register): Call fetch_altivec_registers instead of
2060 fetch_altivec_register.
2061 (store_register): Call store_altivec_registers instead of
2062 store_altivec_register.
2063 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
2064 the new regno parameter.
2065 (store_ppc_registers): Call store_altivec_registers with -1 for
2066 the new regno parameter.
2068 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2070 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
2071 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
2072 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
2073 (gdb_vrregset_t): Change array type size to
2074 PPC_LINUX_SIZEOF_VRREGSET.
2075 (gdb_vsxregset_t): Change array type size to
2076 PPC_LINUX_SIZEOF_VSXREGSET.
2077 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
2078 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
2079 PPC_LINUX_SIZEOF_VSXREGSET.
2081 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2083 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
2084 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
2086 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
2087 ppc_linux_target_wordsize with tid.
2088 (ppc_linux_nat_target::read_description): Call ppc_linux_target
2090 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
2091 (ppc64_64bit_inferior_p): Add static and inline specifiers.
2092 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
2093 tid parameter. Remove static specifier.
2094 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
2095 (ppc_linux_target_wordsize): New declaration.
2097 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2099 * arch/ppc-linux-common.c: New file.
2100 * arch/ppc-linux-common.h: New file.
2101 * arch/ppc-linux-tdesc.h: New file.
2102 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
2103 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
2104 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
2105 arch/ppc-linux-tdesc.h.
2106 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
2107 arch/ppc-linux-tdesc.h.
2108 (ppc_linux_nat_target::read_description): Remove target
2109 description matching code. Fill a ppc_linux_features struct and
2110 call ppc_linux_match_description with it. Move comment about ISA
2111 2.05 to ppc-linux-common.c.
2112 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
2113 arch/ppc-linux-tdesc.h.
2114 (ppc_linux_core_read_description): Remove target description
2115 matching code. Fill a ppc_linux_features struct and call
2116 ppc_linux_match_description with it.
2117 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
2118 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
2119 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
2120 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
2121 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
2122 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
2123 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
2124 (tdesc_powerpc_e500l): Remove.
2126 2018-05-22 Joel Brobecker <brobecker@adacore.com>
2128 * ada-lang.c (catch_assert_command): Pass empty string instead
2129 of NULL for excep_string argument.
2131 2018-05-22 Maciej W. Rozycki <macro@mips.com>
2133 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
2134 the width of the requested register exceeds the width of the
2137 2018-05-21 Tom Tromey <tom@tromey.com>
2139 * printcmd.c (output_command): Remove.
2140 (output_command_const): Rename to output_command.
2141 * valprint.h (output_command): Rename from output_command_const.
2142 * tracepoint.c (trace_dump_actions): Call output_command.
2144 2018-05-21 Tom Tromey <tom@tromey.com>
2146 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
2147 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
2148 * ada-lang.h (create_ada_exception_catchpoint): Update.
2149 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
2151 (create_excep_cond_exprs, ~ada_catchpoint)
2152 (should_stop_exception, print_one_exception)
2153 (print_mention_exception, print_recreate_exception): Update.
2154 (ada_get_next_arg): Remove.
2155 (catch_ada_exception_command_split): Use std::string. Change type
2156 of "excep_string", "cond_string".
2157 (catch_ada_exception_command): Update.
2158 (create_ada_exception_catchpoint): Change type of excep_string.
2159 (ada_exception_sal): Remove excep_string parameter.
2160 (~ada_catchpoint): Remove.
2162 2018-05-21 Tom Tromey <tom@tromey.com>
2164 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
2167 2018-05-21 Tom Tromey <tom@tromey.com>
2169 * ada-lang.c (ada_exception_message_1, ada_exception_message):
2170 Return unique_xmalloc_ptr.
2171 (print_it_exception): Update.
2173 2018-05-21 Tom Tromey <tom@tromey.com>
2175 * tracepoint.c (trace_dump_actions): Use std::string.
2177 2018-05-21 Tom Tromey <tom@tromey.com>
2179 * symfile.c (reread_symbols): Use std::string for original_name.
2181 2018-05-21 Tom Tromey <tom@tromey.com>
2183 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
2184 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
2187 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
2189 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
2191 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
2192 * objfiles.c (get_objfile_bfd_data): Allocate
2193 objfile_per_bfd_storage with obstack_new when allocating on
2196 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
2198 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
2200 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
2201 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
2202 * mdebugread.c (mdebug_build_psymtabs): Likewise.
2203 (add_pending): Likewise.
2204 (parse_symbol): Likewise.
2205 (parse_partial_symbols): Likewise.
2206 (psymtab_to_symtab_1): Likewise.
2207 (new_psymtab): Likewise.
2208 (elfmdebug_build_psymtabs): Likewise.
2209 * minsyms.c (terminate_minimal_symbol_table): Likewise.
2210 * objfiles.c (get_objfile_bfd_data): Likewise.
2211 (objfile_register_static_link): Likewise.
2212 * psymtab.c (allocate_psymtab): Likewise.
2213 * stabsread.c (read_member_functions): Likewise.
2214 * xcoffread.c (xcoff_end_psymtab): Likewise.
2216 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
2218 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
2219 compiler supports std::is_trivially_constructible.
2220 * common/poison.h: Include obstack.h.
2221 (IsMallocable): Define to is_trivially_constructible if the
2222 compiler supports it, define to true_type otherwise.
2226 (XOBNEWVEC): Redefine.
2227 * gdb_obstack.h (obstack_zalloc): New.
2228 (OBSTACK_ZALLOC): Redefine.
2229 (obstack_calloc): New.
2230 (OBSTACK_CALLOC): Redefine.
2232 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
2233 (gdbarch_obstack): New declaration in gdbarch.h, definition in
2235 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
2236 obstack_calloc/obstack_zalloc.
2237 (gdbarch_obstack_zalloc): Remove.
2238 * target-descriptions.c (tdesc_data_init): Use obstack_new.
2240 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2242 * stack.c (backtrace_command_1): Remove useless variable int i.
2244 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2246 * stack.c (print_frame_info): Fix comment.
2248 2018-05-18 Tom Tromey <tom@tromey.com>
2250 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
2251 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
2252 (~dwarf2_per_objfile): Update
2253 (dwarf2_get_dwz_file): Use new.
2254 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
2257 2018-05-18 Tom Tromey <tom@tromey.com>
2259 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
2261 * dwarf2read.c (struct dwp_file): Add constructor and
2263 (open_and_init_dwp_file): Return a unique_ptr.
2264 (dwarf2_per_objfile, create_dwp_hash_table)
2265 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
2266 (lookup_dwo_unit_in_dwp): Update.
2267 (open_and_init_dwp_file, get_dwp_file): Update.
2269 2018-05-18 Tom Tromey <tom@tromey.com>
2271 * dwarf2read.c (dwarf2_per_objfile): Update.
2272 (struct mapped_index): Add initializers.
2273 (dwarf2_read_index): Use new.
2274 (dw2_symtab_iter_init): Update.
2275 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
2278 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
2280 * dwarf2read.c (mapped_index) <total_size>: Remove.
2282 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
2284 * unittests/format_pieces-selftests.c (test_format_specifier):
2287 2018-05-18 Tom Tromey <tom@tromey.com>
2289 * c-typeprint.c (maybe_print_hole): New function.
2290 (c_print_type_struct_field_offset): Update.
2291 (c_type_print_base_struct_union): Call maybe_print_hole.
2293 2018-05-17 Keith Seitz <keiths@redhat.com>
2295 * breakpoint.c (build_bpstat_chain): New function, moved from
2297 (bpstat_stop_status): Add optional parameter, `stop_chain'.
2298 If no stop chain is passed, call build_bpstat_chain to build it.
2299 * breakpoint.h (build_bpstat_chain): Declare.
2300 (bpstat_stop_status): Move documentation here from breakpoint.c.
2301 * infrun.c (handle_signal_stop): Before eliding inlined frames,
2302 build the stop chain and pass it to skip_inline_frames.
2303 Pass this stop chain to bpstat_stop_status.
2304 * inline-frame.c: Include breakpoint.h.
2305 (stopped_by_user_bp_inline_frame): New function.
2306 (skip_inline_frames): Add parameter `stop_chain'.
2307 Move documention to inline-frame.h.
2308 If non-NULL, use stopped_by_user_bp_inline_frame to determine
2309 whether the frame should be elided.
2310 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
2311 Add moved documentation and update for new parameter.
2313 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
2316 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2317 unittests/format_pieces-selftests.c.
2318 * common/format.h (format_piece) <operator==>: New.
2319 (format_pieces) <operator[]>: Remove.
2320 * common/format.c (format_pieces::format_pieces): Handle \e.
2321 * unittests/format_pieces-selftests.c: New.
2323 2018-05-17 Tom Tromey <tom@tromey.com>
2326 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
2327 (dw2_instantiate_symtab): Add skip_partial parameter.
2328 (dw2_find_last_source_symtab, dw2_map_expand_apply)
2329 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
2330 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
2331 (dw2_expand_symtabs_matching_one)
2332 (dw2_find_pc_sect_compunit_symtab)
2333 (dw2_debug_names_lookup_symbol)
2334 (dw2_debug_names_expand_symtabs_for_function): Update.
2335 (init_cutu_and_read_dies): Add skip_partial parameter.
2336 (process_psymtab_comp_unit, build_type_psymtabs_1)
2337 (process_skeletonless_type_unit, load_partial_comp_unit)
2338 (psymtab_to_symtab_1): Update.
2339 (load_full_comp_unit): Add skip_partial parameter.
2340 (process_imported_unit_die, dwarf2_read_addr_index)
2341 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
2342 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
2343 (read_signatured_type): Update.
2345 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
2347 * value.c (release_value): Remove unused variable.
2348 (record_latest_value): Likewise.
2349 (access_value_history): Likewise.
2350 (preserve_values): Likewise.
2352 2018-05-17 Tom Tromey <tom@tromey.com>
2354 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
2357 2018-05-16 Maciej W. Rozycki <macro@mips.com>
2360 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
2361 Also handle registers whose width is not a multiple of
2363 (linux_nat_trad_target::store_register): Likewise.
2365 2018-05-16 Tom Tromey <tom@tromey.com>
2367 * gdbcore.h (core_bfd): Redefine.
2368 * corelow.c (core_target::close): Update.
2369 (core_target_open): Update.
2370 * progspace.h (struct program_space) <cbfd>: Now a
2373 2018-05-16 Tom Tromey <tom@tromey.com>
2376 * symfile-add-flags.h (enum symfile_add_flags)
2377 <SYMFILE_NOT_FILENAME>: New constant.
2378 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
2379 objfile name from BFD.
2380 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
2381 * minidebug.c (find_separate_debug_file_in_section): Put
2382 ".gnu_debugdata" into BFD's file name.
2384 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
2386 * regcache.c (regcache_read_ftype, regcache_write_ftype):
2389 2018-05-15 Tamar Christina <tamar.christina@arm.com>
2392 * aarch64-tdep.c (aarch64_analyze_prologue,
2393 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
2394 Indicate not interested in errors.
2396 2018-05-15 Maciej W. Rozycki <macro@mips.com>
2398 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
2399 Supply the MIPS_ZERO_REGNUM register.
2401 2018-05-15 Maciej W. Rozycki <macro@mips.com>
2403 * mips-tdep.c (mask_address_var): Make variable static.
2405 2018-05-14 Tom Tromey <tom@tromey.com>
2407 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
2409 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
2411 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
2412 FXSAVE_ADDR for the mxcsr register.
2414 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
2416 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
2418 2018-05-11 Pedro Alves <palves@redhat.com>
2420 * corelow.c (core_target) <core_target>: No longer inline.
2421 Initialize m_core_gdbarch, m_core_vec and build the section table
2423 <~core_target>: New.
2424 <core_gdbarch, get_core_register_section>: New methods.
2425 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
2426 factored out from ...
2427 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
2429 (sniff_core_bfd): Add gdbarch parameter.
2430 (core_close): Delete, merged into ...
2431 (core_target::close): ... here. Delete self.
2432 (core_close_cleanup): Delete.
2433 (core_target_open): Allocate a core_target on the heap. Use a
2434 unique_ptr instead of a cleanup. Bits moved into the core_target
2435 ctor. Adjust to use core_target methods instead of globals.
2436 (get_core_register_section): Rename to ...
2437 (core_target::get_core_register_section): ... this and adjust.
2438 (struct get_core_registers_cb_data): New.
2439 (get_core_registers_cb): Use it. Use bool.
2440 (core_target::fetch_registers, core_target::files_info)
2441 (core_target::xfer_partial, core_target::read_description)
2442 (core_target::pid_to, core_target::thread_name): Adjust to
2443 reference class fields instead of globals.
2444 * target.h (struct target_ops_deleter, target_ops_up): New.
2446 2018-05-11 Pedro Alves <palves@redhat.com>
2448 * corefile.c (core_file_command): Move to corelow.c.
2449 * corelow.c (the_core_target): Delete.
2450 (core_file_command): Moved from corefile.c. Check exec_bfd
2451 instead of the_core_target. Use target_detach instead of calling
2452 into the_core_target directly.
2453 (maybe_say_no_core_file_now): New.
2454 (core_target::detach): Use it.
2455 (_initialize_corelow): Remove references to the_core_target.
2456 * gdbcore.h (the_core_target): Delete.
2458 2018-05-11 Tom Tromey <tromey@redhat.com>
2459 Pedro Alves <palves@redhat.com>
2461 * corefile.c (core_bfd): Remove.
2462 * gdbcore.h (core_bfd): Now a macro.
2463 * progspace.h (struct program_space) <cbfd>: New field.
2465 2018-05-11 Tom Tromey <tom@tromey.com>
2467 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
2470 2018-05-10 Tom Tromey <tom@tromey.com>
2472 * configure: Rebuild.
2473 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
2475 2018-05-10 Joel Brobecker <brobecker@adacore.com>
2478 * regformats/regdat.sh: Adjust script, following the addition
2479 of the new expedite_regs parameter to init_target_desc.
2481 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
2484 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
2485 set_gdbarch_significant_addr_bit.
2486 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
2487 set_gdbarch_significant_addr_bit.
2488 * utils.c (address_significant): Update to sign extend addr.
2490 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
2492 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
2493 (xtensa_linux_init_abi): Limit tdep->num_regs by
2494 tdep->num_nopriv_regs.
2495 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
2496 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
2499 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
2501 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
2503 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
2505 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
2506 (I387_MXCSR_INIT_VAL): New constant.
2507 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
2508 buffer if it was supplied by the inferior.
2509 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
2510 (i387_xsave_get_clear_bv): New function.
2511 (i387_supply_xsave): Only read x87 control registers from the
2512 xsave buffer if the feature is enabled, and the state will have
2513 been written, otherwise, provide a suitable default.
2514 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
2515 including x87 control registers. Update control registers if they
2516 have changed from the default value, and mark features as enabled
2518 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
2520 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
2522 * spu-tdep.c (info_spu_event_command): Fix output formatting.
2524 2018-05-07 Tom Tromey <tom@tromey.com>
2526 * configure: Rebuild.
2527 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
2529 2018-05-07 Tom Tromey <tom@tromey.com>
2532 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
2533 bit. Use correct value for VDIV.
2535 2018-05-04 Tom Tromey <tom@tromey.com>
2537 * configure: Rebuild.
2538 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
2540 2018-05-04 Tom Tromey <tom@tromey.com>
2542 * linux-record.c (record_linux_system_call) <case
2543 RECORD_SYS_RECVFROM>: Add "break".
2545 2018-05-04 Tom Tromey <tom@tromey.com>
2547 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
2548 Add missing "break".
2549 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
2550 Add missing "break".
2552 2018-05-04 Tom Tromey <tom@tromey.com>
2554 * rs6000-tdep.c (ppc_process_record_op4)
2555 (ppc_process_record_op63): Add fall-through comment.
2557 2018-05-04 Tom Tromey <tom@tromey.com>
2559 * i386-tdep.c (i386_process_record): Add fall-through comment.
2561 2018-05-04 Tom Tromey <tom@tromey.com>
2563 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
2566 2018-05-04 Tom Tromey <tom@tromey.com>
2568 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
2569 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
2570 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
2572 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
2574 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
2577 2018-05-04 Tom Tromey <tom@tromey.com>
2579 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
2581 2018-05-04 Tom Tromey <tom@tromey.com>
2583 * s390-tdep.c (s390_process_record): Fix fall-through comments.
2584 * xcoffread.c (scan_xcoff_symtab): Move comment later.
2585 * symfile.c (section_is_mapped): Fix fall-through comment.
2586 * stabsread.c (define_symbol, read_member_functions): Fix
2587 fall-through comment.
2588 * s390-linux-tdep.c (s390_process_record): Fix fall-through
2590 * remote.c (remote_wait_as): Fix fall-through comment.
2591 * p-exp.y (yylex): Fix fall-through comment.
2592 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
2594 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
2595 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
2596 * jv-exp.y (yylex): Fix fall-through comment.
2597 * go-exp.y (lex_one_token): Fix fall-through comment.
2598 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
2599 fall-through comment.
2600 * f-exp.y (yylex): Fix fall-through comment.
2601 * dwarf2read.c (process_die): Fix fall-through comments.
2602 * dbxread.c (process_one_symbol): Fix fall-through comment.
2603 * d-exp.y (lex_one_token): Fix fall-through comment.
2604 * cp-name-parser.y (yylex): Fix fall-through comment.
2605 * coffread.c (coff_symtab_read): Fix fall-through comment.
2606 * c-exp.y (lex_one_token): Fix fall-through comment.
2607 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
2609 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
2612 2018-05-04 Tom Tromey <tom@tromey.com>
2615 * NEWS: Mention gdb.execute change.
2616 * gdbcmd.h (execute_control_command): Don't declare.
2617 * python/python.c (execute_gdb_command): Use read_command_lines_1,
2618 execute_control_commands, execute_control_commands_to_string.
2619 * cli/cli-script.h (execute_control_commands)
2620 (execute_control_commands_to_string): Declare.
2621 (execute_control_command): Add from_tty parameter.
2622 * cli/cli-script.c (execute_control_commands)
2623 (execute_control_commands_to_string): New functions.
2624 (execute_user_command): Use execute_control_commands.
2625 (execute_control_command_1): Add "from_tty" parameter. Update.
2626 (execute_control_command): Likewise.
2628 2018-05-04 Tom Tromey <tom@tromey.com>
2631 * NEWS: Mention that breakpoint commands are writable.
2632 * python/py-breakpoint.c (bppy_set_commands): New function.
2633 (breakpoint_object_getset) <"commands">: Use it.
2635 2018-05-04 Tom Tromey <tom@tromey.com>
2637 * tracepoint.c (actions_command): Update.
2638 * mi/mi-cmd-break.c (mi_command_line_array)
2639 (mi_command_line_array_cnt, mi_command_line_array_ptr)
2640 (mi_read_next_line): Remove.
2641 (mi_cmd_break_commands): Update.
2642 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
2644 * cli/cli-script.c (get_command_line): Update.
2645 (process_next_line): Use function_view. Constify.
2646 (recurse_read_control_structure, read_command_lines)
2647 (read_command_lines_1): Change argument types to function_view.
2648 (do_define_command, document_command): Update.
2649 * breakpoint.h (check_tracepoint_command): Don't declare.
2650 * breakpoint.c (check_tracepoint_command): Remove.
2651 (commands_command_1, create_tracepoint_from_upload): Update.
2653 2018-05-04 Tom Tromey <tom@tromey.com>
2656 * cli/cli-script.h (enum command_control_type) <define_control>:
2658 * cli/cli-script.c (multi_line_command_p): Handle define_control.
2659 (build_command_line, execute_control_command_1)
2660 (process_next_line): Likewise.
2661 (do_define_command): New function, extracted from define_command.
2662 (define_command): Use it.
2664 2018-05-04 Tom Tromey <tom@tromey.com>
2666 * tracepoint.c (actions_command): Update.
2667 * cli/cli-script.h (read_command_lines): Update.
2668 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
2669 (MAX_TMPBUF): Remove define.
2670 (define_command): Use string_printf.
2671 (document_command): Likewise.
2672 * breakpoint.c (commands_command_1): Update.
2674 2018-05-04 Tom Tromey <tom@tromey.com>
2676 * top.c (execute_command): Update.
2677 * cli/cli-script.h (print_command_lines): Now varargs.
2678 * cli/cli-script.c (print_command_lines): Now varargs.
2679 (execute_control_command_1) <case while_control, case if_control>:
2682 2018-05-04 Tom Tromey <tom@tromey.com>
2684 * tracepoint.c (all_tracepoint_actions): Rename from
2685 all_tracepoint_actions_and_cleanup. Change return type.
2686 (actions_command, encode_actions_1, encode_actions)
2687 (trace_dump_actions, tdump_command): Update.
2688 * remote.c (remote_download_command_source): Update.
2689 * python/python.c (gdbpy_eval_from_control_command)
2690 (python_command, python_interactive_command): Update.
2691 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
2692 * guile/guile.c (guile_command)
2693 (gdbscm_eval_from_control_command, guile_command): Update.
2694 * compile/compile.c (compile_code_command)
2695 (compile_print_command, compile_to_object): Update.
2696 * cli/cli-script.h (struct command_lines_deleter): New.
2697 (counted_command_line): New typedef.
2698 (struct command_line): Add constructor, destructor.
2699 <body_list>: Remove.
2700 <body_list_0, body_list_1>: New members.
2701 (command_line_up): Remove typedef.
2702 (read_command_lines, read_command_lines_1, get_command_line):
2704 (copy_command_lines): Don't declare.
2705 * cli/cli-script.c (build_command_line): Use "new".
2706 (get_command_line): Return counted_command_line.
2707 (print_command_lines, execute_user_command)
2708 (execute_control_command_1, while_command, if_command): Update.
2709 (realloc_body_list): Remove.
2710 (process_next_line, recurse_read_control_structure): Update.
2711 (read_command_lines, read_command_lines_1): Return counted_command_line.
2712 (free_command_lines): Use "delete".
2713 (copy_command_lines): Remove.
2714 (define_command, document_command, show_user_1): Update.
2715 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
2716 a counted_command_line.
2717 * breakpoint.h (counted_command_line): Remove typedef.
2718 (breakpoint_set_commands): Update.
2719 * breakpoint.c (check_no_tracepoint_commands)
2720 (validate_commands_for_breakpoint): Update.
2721 (breakpoint_set_commands): Change commands to be a
2722 counted_command_line.
2723 (commands_command_1, update_dprintf_command_list)
2724 (create_tracepoint_from_upload): Update.
2726 2018-05-04 Tom Tromey <tom@tromey.com>
2728 * cli/cli-decode.h (cmd_list_element): New constructor.
2729 (~cmd_list_element): New destructor.
2730 (struct cmd_list_element): Add initializers.
2731 * cli/cli-decode.c (do_add_cmd): Use "new".
2732 (delete_cmd): Use "delete".
2734 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
2735 Pedro Alves <palves@redhat.com>
2737 PR breakpoints/19806 and support for PR external/20207.
2738 * NEWS: Mention Aarch64 watchpoint improvements.
2739 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
2740 watchpoints and PR external/20207 watchpoints.
2741 * nat/aarch64-linux-hw-point.c
2742 (kernel_supports_any_contiguous_range): New.
2743 (aarch64_watchpoint_offset): New.
2744 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
2745 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
2746 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
2747 (aarch64_align_watchpoint): New parameters aligned_offset_p and
2748 next_addr_orig_p. Support PR external/20207 watchpoints.
2749 (aarch64_downgrade_regs): New.
2750 (aarch64_dr_state_insert_one_point): New parameters offset and
2752 (aarch64_dr_state_remove_one_point): Likewise.
2753 (aarch64_handle_breakpoint): Update caller.
2754 (aarch64_handle_aligned_watchpoint): Likewise.
2755 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
2757 (aarch64_linux_set_debug_regs): Remove const from state. Call
2758 aarch64_downgrade_regs.
2759 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
2760 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
2761 (DR_CONTROL_MASK): ... this.
2762 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
2763 (unsigned int aarch64_watchpoint_offset): New prototype.
2764 (aarch64_linux_set_debug_regs): Remove const from state.
2765 * utils.c (align_up, align_down): Move to ...
2766 * common/common-utils.c (align_up, align_down): ... here.
2767 * utils.h (align_up, align_down): Move to ...
2768 * common/common-utils.h (align_up, align_down): ... here.
2770 2018-05-04 Joel Brobecker <brobecker@adacore.com>
2772 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
2773 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
2774 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
2775 Re-implement to match the ABI as summarized in GCC's
2776 gcc/config/sparc/sparc.c. All callers updated.
2777 (sparc32_store_arguments): Remove assertion.
2779 2018-05-04 Tom Tromey <tom@tromey.com>
2781 * printcmd.c: Don't include tui.h.
2782 (decode_format): Use skip_spaces.
2784 2018-05-04 Tom Tromey <tom@tromey.com>
2787 * printcmd.c (last_count): New global.
2788 (x_command): Use saved count when repeating.
2790 2018-05-04 Tom Tromey <tom@tromey.com>
2792 * nto-procfs.c (do_closedir_cleanup): Remove.
2793 (procfs_pidlist): Use gdb_dir_up.
2794 * procfs.c (do_closedir_cleanup): Remove.
2795 (proc_update_threads): Use gdb_dir_up.
2796 * common/filestuff.h (struct gdb_dir_deleter): New.
2797 (gdb_dir_up): New typedef.
2799 2018-05-04 Tom Tromey <tom@tromey.com>
2801 * ada-lang.c (print_mention_exception): Use std::string.
2803 2018-05-04 Tom Tromey <tom@tromey.com>
2805 * ada-lang.c (create_excep_cond_exprs): Update.
2806 (ada_exception_catchpoint_cond_string): Use std::string.
2808 2018-05-04 Tom Tromey <tom@tromey.com>
2810 * ada-lang.c (xget_renaming_scope): Return std::string.
2811 (old_renaming_is_invisible): Update.
2813 2018-05-04 Tom Tromey <tom@tromey.com>
2815 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
2816 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
2818 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
2820 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
2822 2018-05-04 Tom Tromey <tom@tromey.com>
2824 * remote.c (remote_query_supported_append): Change type.
2825 (remote_check_symbols): Update.
2827 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
2830 * configure.ac: Prepend libpython.
2831 * python/python-config.py: Likewise.
2832 * configure: Regenerate.
2834 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
2836 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
2838 2018-05-03 Pedro Alves <palves@redhat.com>
2841 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
2842 override. Write 'true' instead of '1'.
2843 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
2846 2018-05-02 Pedro Alves <palves@redhat.com>
2848 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
2849 add_inf_child_target.
2850 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
2851 add_inf_child_target.
2852 * aix-thread.c (aix_thread_target_info): New.
2853 (aix_thread_target) <shortname, longname, doc>: Delete.
2855 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
2856 add_inf_child_target.
2857 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
2858 add_inf_child_target.
2859 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
2860 add_inf_child_target.
2861 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
2862 add_inf_child_target.
2863 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
2864 add_inf_child_target.
2865 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
2866 add_inf_child_target.
2867 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
2868 add_inf_child_target.
2869 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
2870 add_inf_child_target.
2871 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
2872 add_inf_child_target.
2873 * bfd-target.c (target_bfd_target_info): New.
2874 (target_bfd) <shortname, longname, doc>: Delete.
2876 * bsd-kvm.c (bsd_kvm_target_info): New.
2877 (bsd_kvm_target) <shortname, longname, doc>: Delete.
2879 (bsd_kvm_target::open): Rename to ...
2880 (bsd_kvm_target_open): ... this. Adjust.
2881 * bsd-uthread.c (bsd_uthread_target_info): New.
2882 (bsd_uthread_target) <shortname, longname, doc>: Delete.
2884 * corefile.c (core_file_command): Adjust.
2885 * corelow.c (core_target_info): New.
2886 (core_target) <shortname, longname, doc>: Delete.
2888 (core_target::open): Rename to ...
2889 (core_target_open): ... this. Adjust.
2890 * ctf.c (ctf_target_info): New.
2891 (ctf_target) <shortname, longname, doc>: Delete.
2893 (ctf_target::open): Rename to ...
2894 (ctf_target_open): ... this.
2895 (_initialize_ctf): Adjust.
2896 * exec.c (exec_target_info): New.
2897 (exec_target) <shortname, longname, doc>: Delete.
2899 (exec_target::open): Rename to ...
2900 (exec_target_open): ... this.
2901 * gdbcore.h (core_target_open): Declare.
2902 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
2903 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
2904 add_inf_child_target.
2905 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
2906 add_inf_child_target.
2907 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
2908 add_inf_child_target.
2909 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
2910 add_inf_child_target.
2911 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
2912 add_inf_child_target.
2913 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
2914 add_inf_child_target.
2915 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
2916 add_inf_child_target.
2917 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
2918 add_inf_child_target.
2919 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
2920 add_inf_child_target.
2921 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
2922 add_inf_child_target.
2923 * inf-child.c (inf_child_target_info): New.
2924 (inf_child_target::info): New.
2925 (inf_child_open_target): Remove 'target' parameter. Use
2926 get_native_target instead.
2927 (inf_child_target::open): Delete.
2928 (add_inf_child_target): New.
2929 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
2932 (add_inf_child_target): Declare.
2933 (inf_child_open_target): Declare.
2934 * linux-thread-db.c (thread_db_target_info): New.
2935 (thread_db_target) <shortname, longname, doc>: Delete.
2937 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
2938 add_inf_child_target.
2939 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
2940 add_inf_child_target.
2941 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
2942 add_inf_child_target.
2943 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
2944 add_inf_child_target.
2945 * make-target-delegates (print_class): Adjust.
2946 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
2947 add_inf_child_target.
2948 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
2949 add_inf_child_target.
2950 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
2951 add_inf_child_target.
2952 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
2953 add_inf_child_target.
2954 * nto-procfs.c (nto_native_target_info): New.
2955 (nto_procfs_target_native) <shortname, longname, doc>:
2958 (nto_procfs_target_info): New.
2959 (nto_procfs_target_procfs) <shortname, longname, doc>:
2962 (init_procfs_targets): Adjust.
2963 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
2964 add_inf_child_target.
2965 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
2966 add_inf_child_target.
2967 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
2968 add_inf_child_target.
2969 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
2970 add_inf_child_target.
2971 * ravenscar-thread.c (ravenscar_target_info): New.
2972 (ravenscar_thread_target) <shortname, longname, doc>:
2975 * record-btrace.c (record_btrace_target_info):
2976 (record_btrace_target) <shortname, longname, doc>: Delete.
2978 (record_btrace_target::open): Rename to ...
2979 (record_btrace_target_open): ... this. Adjust.
2980 * record-full.c (record_longname, record_doc): New.
2981 (record_full_base_target) <shortname, longname, doc>: Delete.
2983 (record_full_target_info): New.
2984 (record_full_target): <shortname>: Delete.
2986 (record_full_core_open_1, record_full_open_1): Update comments.
2987 (record_full_base_target::open): Rename to ...
2988 (record_full_open): ... this.
2989 (cmd_record_full_restore): Update.
2990 (_initialize_record_full): Update.
2991 * remote-sim.c (remote_sim_target_info): New.
2992 (gdbsim_target) <shortname, longname, doc>: Delete.
2994 (gdbsim_target::open): Rename to ...
2995 (gdbsim_target_open): ... this.
2996 (_initialize_remote_sim): Adjust.
2997 * remote.c (remote_doc): New.
2998 (remote_target_info): New.
2999 (remote_target) <shortname, longname, doc>: Delete.
3001 (extended_remote_target_info): New.
3002 (extended_remote_target) <shortname, longname, doc>: Delete.
3004 (remote_target::open_1): Make static. Adjust.
3005 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
3006 * s390-linux-nat.c (_initialize_s390_nat): Use
3007 add_inf_child_target.
3008 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
3009 add_inf_child_target.
3010 * sol-thread.c (thread_db_target_info): New.
3011 (sol_thread_target) <shortname, longname, doc>: Delete.
3013 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
3014 add_inf_child_target.
3015 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
3016 add_inf_child_target.
3017 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
3018 add_inf_child_target.
3019 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
3020 add_inf_child_target.
3021 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
3022 add_inf_child_target.
3023 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
3024 add_inf_child_target.
3025 * spu-linux-nat.c (_initialize_spu_nat): Use
3026 add_inf_child_target.
3027 * spu-multiarch.c (spu_multiarch_target_info): New.
3028 (spu_multiarch_target) <shortname, longname, doc>: Delete.
3030 * target-delegates.c: Regenerate.
3031 * target.c: Include <unordered_map>.
3032 (target_ops_p): Delete.
3033 (DEF_VEC_P(target_ops_p)): Delete.
3034 (target_factories): New.
3035 (test_target_info): New.
3036 (test_target_ops::info): New.
3037 (open_target): Adjust to use target_factories.
3038 (add_target_with_completer): Rename to ...
3039 (add_target): ... this. Change prototype. Register target_info
3040 and open callback in target_factories. Register target_info in
3041 command context instead of target_ops.
3042 (add_target): Delete old implementation.
3043 (add_deprecated_target_alias): Change prototype. Adjust.
3044 (the_native_target): New.
3045 (set_native_target, get_native_target): New.
3046 (find_default_run_target): Use the_native_target.
3047 (find_attach_target, find_run_target): Simplify.
3048 (target_ops::open): Delete.
3049 (dummy_target_info): New.
3050 (dummy_target::shortname, dummy_target::longname)
3051 (dummy_target::doc): Delete.
3052 (dummy_target::info): New.
3053 (debug_target::shortname, debug_target::longname)
3054 (debug_target::doc): Delete.
3055 (debug_target::info): New.
3056 * target.h (struct target_info): New.
3057 (target_ops::~target_ops): Add comment.
3058 (target_ops::info): New.
3059 (target_ops::shortname, target_ops::longname, target_ops::doc): No
3060 longer virtual. Implement in terms of target_info.
3061 (set_native_target, get_native_target): Declare.
3062 (target_open_ftype): New.
3063 (add_target, add_target_with_completer)
3064 (add_deprecated_target_alias): Change prototype.
3065 (test_target) <shortname, longname, doc>: Delete.
3067 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
3068 add_inf_child_target.
3069 * tracefile-tfile.c (tfile_target_info): New.
3070 (tfile_target) <shortname, longname, doc>: Delete.
3072 (tfile_target::open): Rename to ...
3073 (tfile_target_open): ... this.
3074 (_initialize_tracefile_tfile): Adjust.
3075 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
3076 add_inf_child_target.
3077 * windows-nat.c (_initialize_windows_nat): Use
3078 add_inf_child_target.
3079 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
3080 add_inf_child_target.
3082 2018-05-02 Pedro Alves <palves@redhat.com>
3084 * linux-nat.h (linux_nat_target) <low_new_thread,
3085 low_delete_thread, low_new_fork, low_forget_process,
3086 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
3087 New virtual methods.
3088 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
3089 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
3090 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
3091 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
3092 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
3094 * linux-fork.c (delete_fork): Adjust to call low method.
3095 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
3096 (linux_nat_new_fork, linux_nat_forget_process_hook)
3097 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
3098 (linux_nat_status_is_event):
3099 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
3100 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
3102 (sigtrap_is_event): Rename to ...
3103 (linux_nat_target::low_status_is_event): ... this.
3104 (linux_nat_set_status_is_event): Delete.
3105 (save_stop_reason, linux_nat_wait_1)
3106 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
3108 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
3109 (linux_nat_set_new_fork, linux_nat_set_forget_process)
3110 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
3111 (linux_nat_set_prepare_to_resume): Delete.
3112 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
3113 low virtual methods.
3114 * amd64-linux-nat.c: Likewise.
3115 * arm-linux-nat.c: Likewise.
3116 * i386-linux-nat.c: Likewise.
3117 * ia64-linux-nat.c: Likewise.
3118 * mips-linux-nat.c: Likewise.
3119 * ppc-linux-nat.c: Likewise.
3120 * s390-linux-nat.c: Likewise.
3121 * sparc64-linux-nat.c: Likewise.
3122 * x86-linux-nat.c: Likewise.
3123 * x86-linux-nat.h: Include "nat/x86-linux.h".
3124 (x86_linux_nat_target) <low_new_fork, low_forget_process,
3125 low_prepare_to_resume, low_new_thread, low_delete_thread>:
3128 2018-05-02 Pedro Alves <palves@redhat.com>
3130 * target.h (target_ops)
3131 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
3132 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
3133 stopped_by_watchpoint, have_continuable_watchpoint,
3134 stopped_data_address, watchpoint_addr_within_range,
3135 can_accel_watchpoint_condition, can_run, thread_alive,
3136 has_all_memory, has_memory, has_stack, has_registers,
3137 has_execution, can_async_p, is_async_p, supports_non_stop,
3138 always_non_stop_p, can_execute_reverse, supports_multi_process,
3139 supports_enable_disable_tracepoint,
3140 supports_disable_randomization, supports_string_tracing,
3141 supports_evaluation_of_breakpoint_conditions,
3142 can_run_breakpoint_commands, filesystem_is_local,
3143 can_download_tracepoint, get_trace_state_variable_value,
3144 set_trace_notes, get_tib_address, use_agent, can_use_agent,
3145 record_is_replaying, record_will_replay,
3146 augmented_libraries_svr4_read>: Adjust to return bool.
3147 * aarch64-linux-nat.c: All implementations adjusted.
3148 * aix-thread.c: All implementations adjusted.
3149 * arm-linux-nat.c: All implementations adjusted.
3150 * breakpoint.c: All implementations adjusted.
3151 * bsd-kvm.c: All implementations adjusted.
3152 * bsd-uthread.c: All implementations adjusted.
3153 * corelow.c: All implementations adjusted.
3154 * ctf.c: All implementations adjusted.
3155 * darwin-nat.c: All implementations adjusted.
3156 * darwin-nat.h: All implementations adjusted.
3157 * exec.c: All implementations adjusted.
3158 * fbsd-nat.c: All implementations adjusted.
3159 * fbsd-nat.h: All implementations adjusted.
3160 * gnu-nat.c: All implementations adjusted.
3161 * gnu-nat.h: All implementations adjusted.
3162 * go32-nat.c: All implementations adjusted.
3163 * ia64-linux-nat.c: All implementations adjusted.
3164 * inf-child.c: All implementations adjusted.
3165 * inf-child.h: All implementations adjusted.
3166 * inf-ptrace.c: All implementations adjusted.
3167 * inf-ptrace.h: All implementations adjusted.
3168 * linux-nat.c: All implementations adjusted.
3169 * linux-nat.h: All implementations adjusted.
3170 * mips-linux-nat.c: All implementations adjusted.
3171 * nto-procfs.c: All implementations adjusted.
3172 * ppc-linux-nat.c: All implementations adjusted.
3173 * procfs.c: All implementations adjusted.
3174 * ravenscar-thread.c: All implementations adjusted.
3175 * record-btrace.c: All implementations adjusted.
3176 * record-full.c: All implementations adjusted.
3177 * remote-sim.c: All implementations adjusted.
3178 * remote.c: All implementations adjusted.
3179 * s390-linux-nat.c: All implementations adjusted.
3180 * sol-thread.c: All implementations adjusted.
3181 * spu-multiarch.c: All implementations adjusted.
3182 * target-delegates.c: All implementations adjusted.
3183 * target.c: All implementations adjusted.
3184 * target.h: All implementations adjusted.
3185 * tracefile-tfile.c: All implementations adjusted.
3186 * tracefile.c: All implementations adjusted.
3187 * tracefile.h: All implementations adjusted.
3188 * windows-nat.c: All implementations adjusted.
3189 * x86-linux-nat.h: All implementations adjusted.
3190 * x86-nat.h: All implementations adjusted.
3192 2018-05-02 Pedro Alves <palves@redhat.com>
3194 * make-target-delegates (scan_target_h): Don't trim lines here.
3195 Replace sequences of tabs and/or whitespace with a single
3197 (top level, parsing methods): Trim each line before processing it
3200 2018-05-02 Pedro Alves <palves@redhat.com>
3201 John Baldwin <jhb@freebsd.org>
3203 * target.h (enum strata) <debug_stratum>: New.
3204 (struct target_ops) <all delegation methods>: Replace by C++
3205 virtual methods, and drop "to_" prefix. All references updated
3207 <to_shortname, to_longname, to_doc, to_data,
3208 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
3209 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
3210 virtual methods. All references updated throughout.
3211 <can_attach, supports_terminal_ours, can_create_inferior,
3212 get_thread_control_capabilities, attach_no_wait>: New
3214 <insert_breakpoint, remove_breakpoint>: Now
3215 TARGET_DEFAULT_NORETURN methods.
3216 <info_proc>: Now returns bool.
3218 (OPS_MAGIC): Delete.
3219 (current_target): Delete. All references replaced by references
3221 (target_stack): ... this. New.
3222 (target_shortname, target_longname): Adjust.
3223 (target_can_run): Now a function declaration.
3224 (default_child_has_all_memory, default_child_has_memory)
3225 (default_child_has_stack, default_child_has_registers)
3226 (default_child_has_execution): Remove target_ops parameter.
3227 (complete_target_initialization): Delete.
3228 (memory_breakpoint_target): New template class.
3229 (test_target_ops): Refactor as a C++ class with virtual methods.
3230 * make-target-delegates (NAME_PART): Tighten.
3231 (POINTER_PART, CP_SYMBOL): New.
3232 (SIMPLE_RETURN_PART): Reimplement.
3233 (VEC_RETURN_PART): Expect less.
3234 (RETURN_PART, VIRTUAL_PART): New.
3235 (METHOD): Adjust to C++ virtual methods.
3236 (scan_target_h): Remove reference to C99.
3237 (dname): Output "target_ops::" prefix.
3238 (write_function_header): Adjust to output a C++ class method.
3239 (write_declaration): New.
3240 (write_delegator): Adjust to output a C++ class method.
3241 (tdname): Output "dummy_target::" prefix.
3242 (write_tdefault, write_debugmethod): Adjust to output a C++ class
3244 (tdefault_names, debug_names): Delete.
3245 (return_types, tdefaults, styles, argtypes_array): New.
3246 (top level): All methods are delegators.
3248 (top level): Print dummy_target and debug_target classes.
3249 * target-delegates.c: Regenerate.
3250 * target-debug.h (target_debug_print_enum_info_proc_what)
3251 (target_debug_print_thread_control_capabilities)
3252 (target_debug_print_thread_info_p): New.
3253 * target.c (dummy_target): Delete.
3254 (the_dummy_target, the_debug_target): New.
3255 (target_stack): Now extern.
3256 (set_targetdebug): Push/unpush debug target.
3257 (default_child_has_all_memory, default_child_has_memory)
3258 (default_child_has_stack, default_child_has_registers)
3259 (default_child_has_execution): Remove target_ops parameter.
3260 (complete_target_initialization): Delete.
3261 (add_target_with_completer): No longer call
3262 complete_target_initialization.
3263 (target_supports_terminal_ours): Use regular delegation.
3264 (update_current_target): Delete.
3265 (push_target): No longer check magic number. Don't call
3266 update_current_target.
3267 (unpush_target): Don't call update_current_target.
3268 (target_is_pushed): No longer check magic number.
3269 (target_require_runnable): Skip for all stratums over
3271 (target_ops::info_proc): New.
3272 (target_info_proc): Use find_target_at and
3273 find_default_run_target.
3274 (target_supports_disable_randomization): Use regular delegation.
3275 (target_get_osdata): Use find_target_at.
3276 (target_ops::open, target_ops::close, target_ops::can_attach)
3277 (target_ops::attach, target_ops::can_create_inferior)
3278 (target_ops::create_inferior, target_ops::can_run)
3279 (target_can_run): New.
3280 (default_fileio_target): Use regular delegation.
3281 (target_ops::fileio_open, target_ops::fileio_pwrite)
3282 (target_ops::fileio_pread, target_ops::fileio_fstat)
3283 (target_ops::fileio_close, target_ops::fileio_unlink)
3284 (target_ops::fileio_readlink): New.
3285 (target_fileio_open_1, target_fileio_unlink)
3286 (target_fileio_readlink): Always call the target method. Handle
3288 (return_zero, return_zero_has_execution): Delete.
3289 (init_dummy_target): Delete.
3290 (dummy_target::dummy_target, dummy_target::shortname)
3291 (dummy_target::longname, dummy_target::doc)
3292 (debug_target::debug_target, debug_target::shortname)
3293 (debug_target::longname, debug_target::doc): New.
3294 (target_supports_delete_record): Use regular delegation.
3295 (setup_target_debug): Delete.
3296 (maintenance_print_target_stack): Skip debug_stratum.
3297 (initialize_targets): Instantiate the_dummy_target and
3299 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
3301 (target_auxv_search, fprint_target_auxv): Adjust.
3302 (info_auxv_command): Adjust to use target_stack.
3303 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
3304 * exceptions.c (print_flush): Handle a NULL target_stack.
3305 * regcache.c (target_ops_no_register): Refactor as class with
3308 * exec.c (exec_target): New class.
3309 (exec_ops): Now an exec_target.
3310 (exec_open, exec_close_1, exec_get_section_table)
3311 (exec_xfer_partial, exec_files_info, exec_has_memory)
3312 (exec_make_note_section): Refactor as exec_target methods.
3313 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
3315 (exec_target::find_memory_regions): New.
3316 (_initialize_exec): Don't call init_exec_ops.
3317 * gdbcore.h (exec_file_clear): Delete.
3319 * corefile.c (core_target): Delete.
3320 (core_file_command): Adjust.
3321 * corelow.c (core_target): New class.
3322 (the_core_target): New.
3323 (core_close): Remove target_ops parameter.
3324 (core_close_cleanup): Adjust.
3325 (core_target::close): New.
3326 (core_open, core_detach, get_core_registers, core_files_info)
3327 (core_xfer_partial, core_thread_alive, core_read_description)
3328 (core_pid_to_str, core_thread_name, core_has_memory)
3329 (core_has_stack, core_has_registers, core_info_proc): Rework as
3330 core_target methods.
3331 (ignore, core_remove_breakpoint, init_core_ops): Delete.
3332 (_initialize_corelow): Initialize the_core_target.
3333 * gdbcore.h (core_target): Delete.
3334 (the_core_target): New.
3336 * ctf.c: (ctf_target): New class.
3337 (ctf_ops): Now a ctf_target.
3338 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
3339 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
3340 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
3342 (init_ctf_ops): Delete.
3343 (_initialize_ctf): Don't call it.
3344 * tracefile-tfile.c (tfile_target): New class.
3345 (tfile_ops): Now a tfile_target.
3346 (tfile_open, tfile_close, tfile_files_info)
3347 (tfile_get_tracepoint_status, tfile_trace_find)
3348 (tfile_fetch_registers, tfile_xfer_partial)
3349 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
3350 Refactor as tfile_target methods.
3351 (tfile_xfer_partial_features): Remove target_ops parameter.
3352 (init_tfile_ops): Delete.
3353 (_initialize_tracefile_tfile): Don't call it.
3354 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
3355 (tracefile_has_stack, tracefile_has_registers)
3356 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
3357 tracefile_target methods.
3358 (init_tracefile_ops): Delete.
3359 (tracefile_target::tracefile_target): New.
3360 * tracefile.h: Include "target.h".
3361 (tracefile_target): New class.
3362 (init_tracefile_ops): Delete.
3364 * spu-multiarch.c (spu_multiarch_target): New class.
3365 (spu_ops): Now a spu_multiarch_target.
3366 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
3367 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
3368 (spu_search_memory, spu_mourn_inferior): Refactor as
3369 spu_multiarch_target methods.
3370 (init_spu_ops): Delete.
3371 (_initialize_spu_multiarch): Remove references to init_spu_ops,
3372 complete_target_initialization.
3374 * ravenscar-thread.c (ravenscar_thread_target): New class.
3375 (ravenscar_ops): Now a ravenscar_thread_target.
3376 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
3377 (ravenscar_thread_alive, ravenscar_pid_to_str)
3378 (ravenscar_fetch_registers, ravenscar_store_registers)
3379 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
3380 (ravenscar_stopped_by_hw_breakpoint)
3381 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
3382 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
3383 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
3385 (init_ravenscar_thread_ops): Delete.
3386 (_initialize_ravenscar): Remove references to
3387 init_ravenscar_thread_ops and complete_target_initialization.
3389 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
3390 (bsd_uthread_target): New class.
3391 (bsd_uthread_ops): Now a bsd_uthread_target.
3392 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
3393 (bsd_uthread_close, bsd_uthread_mourn_inferior)
3394 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
3395 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
3396 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
3397 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
3398 (bsd_uthread_target): Delete function.
3399 (_initialize_bsd_uthread): Remove reference to
3400 complete_target_initialization.
3402 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
3403 (target_bfd): ... this new class.
3404 (target_bfd_xfer_partial, target_bfd_get_section_table)
3405 (target_bfd_close): Refactor as target_bfd methods.
3406 (target_bfd::~target_bfd): New.
3407 (target_bfd_reopen): Adjust.
3408 (target_bfd::close): New.
3410 * record-btrace.c (record_btrace_target): New class.
3411 (record_btrace_ops): Now a record_btrace_target.
3412 (record_btrace_open, record_btrace_stop_recording)
3413 (record_btrace_disconnect, record_btrace_close)
3414 (record_btrace_async, record_btrace_info)
3415 (record_btrace_insn_history, record_btrace_insn_history_range)
3416 (record_btrace_insn_history_from, record_btrace_call_history)
3417 (record_btrace_call_history_range)
3418 (record_btrace_call_history_from, record_btrace_record_method)
3419 (record_btrace_is_replaying, record_btrace_will_replay)
3420 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
3421 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
3422 (record_btrace_store_registers, record_btrace_prepare_to_store)
3423 (record_btrace_to_get_unwinder)
3424 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
3425 (record_btrace_commit_resume, record_btrace_wait)
3426 (record_btrace_stop, record_btrace_can_execute_reverse)
3427 (record_btrace_stopped_by_sw_breakpoint)
3428 (record_btrace_supports_stopped_by_sw_breakpoint)
3429 (record_btrace_stopped_by_hw_breakpoint)
3430 (record_btrace_supports_stopped_by_hw_breakpoint)
3431 (record_btrace_update_thread_list, record_btrace_thread_alive)
3432 (record_btrace_goto_begin, record_btrace_goto_end)
3433 (record_btrace_goto, record_btrace_stop_replaying_all)
3434 (record_btrace_execution_direction)
3435 (record_btrace_prepare_to_generate_core)
3436 (record_btrace_done_generating_core): Refactor as
3437 record_btrace_target methods.
3438 (init_record_btrace_ops): Delete.
3439 (_initialize_record_btrace): Remove reference to
3440 init_record_btrace_ops.
3441 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
3442 the execution_direction global.
3443 (record_full_base_target, record_full_target)
3444 (record_full_core_target): New classes.
3445 (record_full_ops): Now a record_full_target.
3446 (record_full_core_ops): Now a record_full_core_target.
3447 (record_full_target::detach, record_full_target::disconnect)
3448 (record_full_core_target::disconnect)
3449 (record_full_target::mourn_inferior, record_full_target::kill):
3451 (record_full_open, record_full_close, record_full_async): Refactor
3452 as methods of the record_full_base_target class.
3453 (record_full_resume, record_full_commit_resume): Refactor
3454 as methods of the record_full_target class.
3455 (record_full_wait, record_full_stopped_by_watchpoint)
3456 (record_full_stopped_data_address)
3457 (record_full_stopped_by_sw_breakpoint)
3458 (record_full_supports_stopped_by_sw_breakpoint)
3459 (record_full_stopped_by_hw_breakpoint)
3460 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
3461 methods of the record_full_base_target class.
3462 (record_full_store_registers, record_full_xfer_partial)
3463 (record_full_insert_breakpoint, record_full_remove_breakpoint):
3464 Refactor as methods of the record_full_target class.
3465 (record_full_can_execute_reverse, record_full_get_bookmark)
3466 (record_full_goto_bookmark, record_full_execution_direction)
3467 (record_full_record_method, record_full_info, record_full_delete)
3468 (record_full_is_replaying, record_full_will_replay)
3469 (record_full_goto_begin, record_full_goto_end, record_full_goto)
3470 (record_full_stop_replaying): Refactor as methods of the
3471 record_full_base_target class.
3472 (record_full_core_resume, record_full_core_kill)
3473 (record_full_core_fetch_registers)
3474 (record_full_core_prepare_to_store)
3475 (record_full_core_store_registers, record_full_core_xfer_partial)
3476 (record_full_core_insert_breakpoint)
3477 (record_full_core_remove_breakpoint)
3478 (record_full_core_has_execution): Refactor
3479 as methods of the record_full_core_target class.
3480 (record_full_base_target::supports_delete_record): New.
3481 (init_record_full_ops): Delete.
3482 (init_record_full_core_ops): Delete.
3483 (record_full_save): Refactor as method of the
3484 record_full_base_target class.
3485 (_initialize_record_full): Remove references to
3486 init_record_full_ops and init_record_full_core_ops.
3488 * remote.c (remote_target, extended_remote_target): New classes.
3489 (remote_ops): Now a remote_target.
3490 (extended_remote_ops): Now an extended_remote_target.
3491 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
3492 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
3493 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
3494 (remote_pass_signals, remote_set_syscall_catchpoint)
3495 (remote_program_signals, )
3496 (remote_thread_always_alive): Remove target_ops parameter.
3497 (remote_thread_alive, remote_thread_name)
3498 (remote_update_thread_list, remote_threads_extra_info)
3499 (remote_static_tracepoint_marker_at)
3500 (remote_static_tracepoint_markers_by_strid)
3501 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
3502 (remote_open): Refactor as methods of remote_target.
3503 (extended_remote_open, extended_remote_detach)
3504 (extended_remote_attach, extended_remote_post_attach):
3505 (extended_remote_supports_disable_randomization)
3506 (extended_remote_create_inferior): : Refactor as method of
3507 extended_remote_target.
3508 (remote_set_permissions, remote_open_1, remote_detach)
3509 (remote_follow_fork, remote_follow_exec, remote_disconnect)
3510 (remote_resume, remote_commit_resume, remote_stop)
3511 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
3512 (remote_terminal_ours, remote_wait, remote_fetch_registers)
3513 (remote_prepare_to_store, remote_store_registers)
3514 (remote_flash_erase, remote_flash_done, remote_files_info)
3515 (remote_kill, remote_mourn, remote_insert_breakpoint)
3516 (remote_remove_breakpoint, remote_insert_watchpoint)
3517 (remote_watchpoint_addr_within_range)
3518 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
3519 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
3520 (remote_supports_stopped_by_sw_breakpoint)
3521 (remote_stopped_by_hw_breakpoint)
3522 (remote_supports_stopped_by_hw_breakpoint)
3523 (remote_stopped_by_watchpoint, remote_stopped_data_address)
3524 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
3525 (remote_verify_memory): Refactor as methods of remote_target.
3526 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
3528 (remote_xfer_partial, remote_get_memory_xfer_limit)
3529 (remote_search_memory, remote_rcmd, remote_memory_map)
3530 (remote_pid_to_str, remote_get_thread_local_address)
3531 (remote_get_tib_address, remote_read_description): Refactor as
3532 methods of remote_target.
3533 (remote_target::fileio_open, remote_target::fileio_pwrite)
3534 (remote_target::fileio_pread, remote_target::fileio_close): New.
3535 (remote_hostio_readlink, remote_hostio_fstat)
3536 (remote_filesystem_is_local, remote_can_execute_reverse)
3537 (remote_supports_non_stop, remote_supports_disable_randomization)
3538 (remote_supports_multi_process, remote_supports_cond_breakpoints)
3539 (remote_supports_enable_disable_tracepoint)
3540 (remote_supports_string_tracing)
3541 (remote_can_run_breakpoint_commands, remote_trace_init)
3542 (remote_download_tracepoint, remote_can_download_tracepoint)
3543 (remote_download_trace_state_variable, remote_enable_tracepoint)
3544 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
3545 (remote_trace_start, remote_get_trace_status)
3546 (remote_get_tracepoint_status, remote_trace_stop)
3547 (remote_trace_find, remote_get_trace_state_variable_value)
3548 (remote_save_trace_data, remote_get_raw_trace_data)
3549 (remote_set_disconnected_tracing, remote_core_of_thread)
3550 (remote_set_circular_trace_buffer, remote_traceframe_info)
3551 (remote_get_min_fast_tracepoint_insn_len)
3552 (remote_set_trace_buffer_size, remote_set_trace_notes)
3553 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
3554 (remote_disable_btrace, remote_teardown_btrace)
3555 (remote_read_btrace, remote_btrace_conf)
3556 (remote_augmented_libraries_svr4_read, remote_load)
3557 (remote_pid_to_exec_file, remote_can_do_single_step)
3558 (remote_execution_direction, remote_thread_handle_to_thread_info):
3559 Refactor as methods of remote_target.
3560 (init_remote_ops, init_extended_remote_ops): Delete.
3561 (remote_can_async_p, remote_is_async_p, remote_async)
3562 (remote_thread_events, remote_upload_tracepoints)
3563 (remote_upload_trace_state_variables): Refactor as methods of
3565 (_initialize_remote): Remove references to init_remote_ops and
3566 init_extended_remote_ops.
3568 * remote-sim.c (gdbsim_target): New class.
3569 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
3570 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
3571 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
3572 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
3573 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
3574 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
3575 Refactor as methods of gdbsim_target.
3576 (gdbsim_ops): Now a gdbsim_target.
3577 (init_gdbsim_ops): Delete.
3578 (gdbsim_cntrl_c): Adjust.
3579 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
3581 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
3582 (the_amd64_linux_nat_target): New.
3583 (amd64_linux_fetch_inferior_registers)
3584 (amd64_linux_store_inferior_registers): Refactor as methods of
3585 amd64_linux_nat_target.
3586 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
3587 * i386-linux-nat.c: Don't include "linux-nat.h".
3588 (i386_linux_nat_target): New class.
3589 (the_i386_linux_nat_target): New.
3590 (i386_linux_fetch_inferior_registers)
3591 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
3592 as methods of i386_linux_nat_target.
3593 (_initialize_i386_linux_nat): Adjust. Set linux_target.
3594 * inf-child.c (inf_child_ops): Delete.
3595 (inf_child_fetch_inferior_registers)
3596 (inf_child_store_inferior_registers): Delete.
3597 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
3598 methods of inf_child_target.
3599 (inf_child_target::supports_terminal_ours)
3600 (inf_child_target::terminal_init)
3601 (inf_child_target::terminal_inferior)
3602 (inf_child_target::terminal_ours_for_output)
3603 (inf_child_target::terminal_ours, inf_child_target::interrupt)
3604 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
3606 (inf_child_open, inf_child_disconnect, inf_child_close)
3607 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
3608 (inf_child_post_startup_inferior, inf_child_can_run)
3609 (inf_child_pid_to_exec_file): Refactor as methods of
3611 (inf_child_follow_fork): Delete.
3612 (inf_child_target::can_create_inferior)
3613 (inf_child_target::can_attach): New.
3614 (inf_child_target::has_all_memory, inf_child_target::has_memory)
3615 (inf_child_target::has_stack, inf_child_target::has_registers)
3616 (inf_child_target::has_execution): New.
3617 (inf_child_fileio_open, inf_child_fileio_pwrite)
3618 (inf_child_fileio_pread, inf_child_fileio_fstat)
3619 (inf_child_fileio_close, inf_child_fileio_unlink)
3620 (inf_child_fileio_readlink, inf_child_use_agent)
3621 (inf_child_can_use_agent): Refactor as methods of
3623 (return_zero, inf_child_target): Delete.
3624 (inf_child_target::inf_child_target): New.
3625 * inf-child.h: Include "target.h".
3626 (inf_child_target): Delete function prototype.
3627 (inf_child_target): New class.
3628 (inf_child_open_target, inf_child_mourn_inferior)
3629 (inf_child_maybe_unpush_target): Delete.
3630 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
3631 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
3632 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
3633 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
3634 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
3635 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
3636 (inf_ptrace_wait, inf_ptrace_xfer_partial)
3637 (inf_ptrace_thread_alive, inf_ptrace_files_info)
3638 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
3639 methods of inf_ptrace_target.
3640 (inf_ptrace_target): Delete function.
3641 * inf-ptrace.h: Include "inf-child.h".
3642 (inf_ptrace_target): Delete function declaration.
3643 (inf_ptrace_target): New class.
3644 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
3645 * linux-nat.c (linux_target): New.
3646 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
3647 (linux_nat_target::~linux_nat_target): New.
3648 (linux_child_post_attach, linux_child_post_startup_inferior)
3649 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
3650 (linux_child_remove_fork_catchpoint)
3651 (linux_child_insert_vfork_catchpoint)
3652 (linux_child_remove_vfork_catchpoint)
3653 (linux_child_insert_exec_catchpoint)
3654 (linux_child_remove_exec_catchpoint)
3655 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
3656 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
3657 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
3658 (linux_nat_stopped_data_address)
3659 (linux_nat_stopped_by_sw_breakpoint)
3660 (linux_nat_supports_stopped_by_sw_breakpoint)
3661 (linux_nat_stopped_by_hw_breakpoint)
3662 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
3663 (linux_nat_kill, linux_nat_mourn_inferior)
3664 (linux_nat_xfer_partial, linux_nat_thread_alive)
3665 (linux_nat_update_thread_list, linux_nat_pid_to_str)
3666 (linux_nat_thread_name, linux_child_pid_to_exec_file)
3667 (linux_child_static_tracepoint_markers_by_strid)
3668 (linux_nat_is_async_p, linux_nat_can_async_p)
3669 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
3670 (linux_nat_supports_multi_process)
3671 (linux_nat_supports_disable_randomization, linux_nat_async)
3672 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
3673 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
3674 (linux_nat_fileio_open, linux_nat_fileio_readlink)
3675 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
3676 methods of linux_nat_target.
3677 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
3678 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
3680 (check_stopped_by_watchpoint): Adjust.
3681 (linux_xfer_partial): Delete.
3682 (linux_target_install_ops, linux_target, linux_nat_add_target):
3684 (linux_nat_target::linux_nat_target): New.
3685 * linux-nat.h: Include "inf-ptrace.h".
3686 (linux_nat_target): New.
3687 (linux_target, linux_target_install_ops, linux_nat_add_target):
3688 Delete function declarations.
3689 (linux_target): Declare global.
3690 * linux-thread-db.c (thread_db_target): New.
3691 (thread_db_target::thread_db_target): New.
3692 (thread_db_ops): Delete.
3693 (the_thread_db_target): New.
3694 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
3695 (thread_db_update_thread_list, thread_db_pid_to_str)
3696 (thread_db_extra_thread_info)
3697 (thread_db_thread_handle_to_thread_info)
3698 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
3699 (thread_db_resume): Refactor as methods of thread_db_target.
3700 (init_thread_db_ops): Delete.
3701 (_initialize_thread_db): Remove reference to init_thread_db_ops.
3702 * x86-linux-nat.c: Don't include "linux-nat.h".
3703 (super_post_startup_inferior): Delete.
3704 (x86_linux_nat_target::~x86_linux_nat_target): New.
3705 (x86_linux_child_post_startup_inferior)
3706 (x86_linux_read_description, x86_linux_enable_btrace)
3707 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
3708 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
3709 methods of x86_linux_nat_target.
3710 (x86_linux_create_target): Delete. Bits folded ...
3711 (x86_linux_add_target): ... here. Now takes a linux_nat_target
3713 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
3714 (x86_linux_nat_target): New class.
3715 (x86_linux_create_target): Delete.
3716 (x86_linux_add_target): Now takes a linux_nat_target pointer.
3717 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
3718 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
3719 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
3720 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
3721 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
3723 (x86_use_watchpoints): Delete.
3724 * x86-nat.h: Include "breakpoint.h" and "target.h".
3725 (x86_use_watchpoints): Delete.
3726 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
3727 (x86_stopped_by_watchpoint, x86_stopped_data_address)
3728 (x86_insert_watchpoint, x86_remove_watchpoint)
3729 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
3730 (x86_stopped_by_hw_breakpoint): New declarations.
3731 (x86_nat_target): New template class.
3733 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
3734 (the_ppc_linux_nat_target): New.
3735 (ppc_linux_fetch_inferior_registers)
3736 (ppc_linux_can_use_hw_breakpoint)
3737 (ppc_linux_region_ok_for_hw_watchpoint)
3738 (ppc_linux_ranged_break_num_registers)
3739 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
3740 (ppc_linux_insert_mask_watchpoint)
3741 (ppc_linux_remove_mask_watchpoint)
3742 (ppc_linux_can_accel_watchpoint_condition)
3743 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
3744 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
3745 (ppc_linux_watchpoint_addr_within_range)
3746 (ppc_linux_masked_watch_num_registers)
3747 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
3748 (ppc_linux_read_description): Refactor as methods of
3749 ppc_linux_nat_target.
3750 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
3752 * procfs.c (procfs_xfer_partial): Delete forward declaration.
3753 (procfs_target): New class.
3754 (the_procfs_target): New.
3755 (procfs_target): Delete function.
3756 (procfs_auxv_parse, procfs_attach, procfs_detach)
3757 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
3758 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
3759 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
3760 (procfs_create_inferior, procfs_update_thread_list)
3761 (procfs_thread_alive, procfs_pid_to_str)
3762 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
3763 (procfs_stopped_data_address, procfs_insert_watchpoint)
3764 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
3765 (proc_find_memory_regions, procfs_info_proc)
3766 (procfs_make_note_section): Refactor as methods of procfs_target.
3767 (_initialize_procfs): Adjust.
3768 * sol-thread.c (sol_thread_target): New class.
3769 (sol_thread_ops): Now a sol_thread_target.
3770 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
3771 (sol_thread_fetch_registers, sol_thread_store_registers)
3772 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
3773 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
3774 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
3775 (init_sol_thread_ops): Delete.
3776 (_initialize_sol_thread): Adjust. Remove references to
3777 init_sol_thread_ops and complete_target_initialization.
3779 * windows-nat.c (windows_nat_target): New class.
3780 (windows_fetch_inferior_registers)
3781 (windows_store_inferior_registers, windows_resume, windows_wait)
3782 (windows_attach, windows_detach, windows_pid_to_exec_file)
3783 (windows_files_info, windows_create_inferior)
3784 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
3785 (windows_close, windows_pid_to_str, windows_xfer_partial)
3786 (windows_get_tib_address, windows_get_ada_task_ptid)
3787 (windows_thread_name, windows_thread_alive): Refactor as
3788 windows_nat_target methods.
3789 (do_initial_windows_stuff): Adjust.
3790 (windows_target): Delete function.
3791 (_initialize_windows_nat): Adjust.
3793 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
3794 (darwin_mourn_inferior, darwin_kill_inferior)
3795 (darwin_create_inferior, darwin_attach, darwin_detach)
3796 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
3797 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
3798 (darwin_supports_multi_process): Refactor as darwin_nat_target
3800 (darwin_resume_to, darwin_files_info): Delete.
3801 (_initialize_darwin_inferior): Rename to ...
3802 (_initialize_darwin_nat): ... this. Adjust to C++ification.
3803 * darwin-nat.h: Include "inf-child.h".
3804 (darwin_nat_target): New class.
3805 (darwin_complete_target): Delete.
3806 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
3807 (darwin_target): New.
3808 (i386_darwin_fetch_inferior_registers)
3809 (i386_darwin_store_inferior_registers): Refactor as methods of
3811 (darwin_complete_target): Delete, with ...
3812 (_initialize_i386_darwin_nat): ... bits factored out here.
3814 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
3815 (the_alpha_linux_nat_target): New.
3816 (alpha_linux_register_u_offset): Refactor as
3817 alpha_linux_nat_target method.
3818 (_initialize_alpha_linux_nat): Adjust.
3819 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
3820 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
3821 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
3822 methods of linux_nat_trad_target.
3823 (linux_trad_target): Delete.
3824 * linux-nat-trad.h (linux_trad_target): Delete function.
3825 (linux_nat_trad_target): New class.
3826 * mips-linux-nat.c (mips_linux_nat_target): New class.
3827 (super_fetch_registers, super_store_registers, super_close):
3829 (the_mips_linux_nat_target): New.
3830 (mips64_linux_regsets_fetch_registers)
3831 (mips64_linux_regsets_store_registers)
3832 (mips64_linux_fetch_registers, mips64_linux_store_registers)
3833 (mips_linux_register_u_offset, mips_linux_read_description)
3834 (mips_linux_can_use_hw_breakpoint)
3835 (mips_linux_stopped_by_watchpoint)
3836 (mips_linux_stopped_data_address)
3837 (mips_linux_region_ok_for_hw_watchpoint)
3838 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
3839 (mips_linux_close): Refactor as methods of mips_linux_nat.
3840 (_initialize_mips_linux_nat): Adjust to C++ification.
3842 * aix-thread.c (aix_thread_target): New class.
3843 (aix_thread_ops): Now an aix_thread_target.
3844 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
3845 (aix_thread_fetch_registers, aix_thread_store_registers)
3846 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
3847 (aix_thread_thread_alive, aix_thread_pid_to_str)
3848 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
3849 Refactor as methods of aix_thread_target.
3850 (init_aix_thread_ops): Delete.
3851 (_initialize_aix_thread): Remove references to init_aix_thread_ops
3852 and complete_target_initialization.
3853 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
3854 (rs6000_nat_target): New class.
3855 (the_rs6000_nat_target): New.
3856 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
3857 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
3858 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
3859 (super_create_inferior): Delete.
3860 (_initialize_rs6000_nat): Adjust to C++ification.
3862 * arm-linux-nat.c (arm_linux_nat_target): New class.
3863 (the_arm_linux_nat_target): New.
3864 (arm_linux_fetch_inferior_registers)
3865 (arm_linux_store_inferior_registers, arm_linux_read_description)
3866 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
3867 (arm_linux_remove_hw_breakpoint)
3868 (arm_linux_region_ok_for_hw_watchpoint)
3869 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
3870 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
3871 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
3872 arm_linux_nat_target.
3873 (_initialize_arm_linux_nat): Adjust to C++ification.
3875 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
3876 (the_aarch64_linux_nat_target): New.
3877 (aarch64_linux_fetch_inferior_registers)
3878 (aarch64_linux_store_inferior_registers)
3879 (aarch64_linux_child_post_startup_inferior)
3880 (aarch64_linux_read_description)
3881 (aarch64_linux_can_use_hw_breakpoint)
3882 (aarch64_linux_insert_hw_breakpoint)
3883 (aarch64_linux_remove_hw_breakpoint)
3884 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
3885 (aarch64_linux_region_ok_for_hw_watchpoint)
3886 (aarch64_linux_stopped_data_address)
3887 (aarch64_linux_stopped_by_watchpoint)
3888 (aarch64_linux_watchpoint_addr_within_range)
3889 (aarch64_linux_can_do_single_step): Refactor as methods of
3890 aarch64_linux_nat_target.
3891 (super_post_startup_inferior): Delete.
3892 (_initialize_aarch64_linux_nat): Adjust to C++ification.
3894 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
3895 (the_hppa_linux_nat_target): New.
3896 (hppa_linux_fetch_inferior_registers)
3897 (hppa_linux_store_inferior_registers): Refactor as methods of
3898 hppa_linux_nat_target.
3899 (_initialize_hppa_linux_nat): Adjust to C++ification.
3901 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
3902 (the_ia64_linux_nat_target): New.
3903 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
3904 (ia64_linux_stopped_data_address)
3905 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
3906 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
3907 ia64_linux_nat_target methods.
3908 (super_xfer_partial): Delete.
3909 (_initialize_ia64_linux_nat): Adjust to C++ification.
3911 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
3912 (the_m32r_linux_nat_target): New.
3913 (m32r_linux_fetch_inferior_registers)
3914 (m32r_linux_store_inferior_registers): Refactor as
3915 m32r_linux_nat_target methods.
3916 (_initialize_m32r_linux_nat): Adjust to C++ification.
3918 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
3919 (the_m68k_linux_nat_target): New.
3920 (m68k_linux_fetch_inferior_registers)
3921 (m68k_linux_store_inferior_registers): Refactor as
3922 m68k_linux_nat_target methods.
3923 (_initialize_m68k_linux_nat): Adjust to C++ification.
3925 * s390-linux-nat.c (s390_linux_nat_target): New class.
3926 (the_s390_linux_nat_target): New.
3927 (s390_linux_fetch_inferior_registers)
3928 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
3929 (s390_insert_watchpoint, s390_remove_watchpoint)
3930 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
3931 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
3932 (s390_auxv_parse, s390_read_description): Refactor as methods of
3933 s390_linux_nat_target.
3934 (_initialize_s390_nat): Adjust to C++ification.
3936 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
3937 (the_sparc_linux_nat_target): New.
3938 (_initialize_sparc_linux_nat): Adjust to C++ification.
3939 * sparc-nat.c (sparc_fetch_inferior_registers)
3940 (sparc_store_inferior_registers): Remove target_ops parameter.
3941 * sparc-nat.h (sparc_fetch_inferior_registers)
3942 (sparc_store_inferior_registers): Remove target_ops parameter.
3943 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
3944 (the_sparc64_linux_nat_target): New.
3945 (_initialize_sparc64_linux_nat): Adjust to C++ification.
3947 * spu-linux-nat.c (spu_linux_nat_target): New class.
3948 (the_spu_linux_nat_target): New.
3949 (spu_child_post_startup_inferior, spu_child_post_attach)
3950 (spu_child_wait, spu_fetch_inferior_registers)
3951 (spu_store_inferior_registers, spu_xfer_partial)
3952 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
3954 (_initialize_spu_nat): Adjust to C++ification.
3956 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
3957 (the_tilegx_linux_nat_target): New.
3958 (fetch_inferior_registers, store_inferior_registers):
3959 Refactor as methods.
3960 (_initialize_tile_linux_nat): Adjust to C++ification.
3962 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
3963 (the_xtensa_linux_nat_target): New.
3964 (xtensa_linux_fetch_inferior_registers)
3965 (xtensa_linux_store_inferior_registers): Refactor as
3966 xtensa_linux_nat_target methods.
3967 (_initialize_xtensa_linux_nat): Adjust to C++ification.
3969 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
3970 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
3971 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
3972 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
3973 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
3974 (fbsd_stopped_by_sw_breakpoint)
3975 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
3976 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
3977 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
3978 (fbsd_post_startup_inferior, fbsd_post_attach)
3979 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
3980 (fbsd_set_syscall_catchpoint)
3981 (super_xfer_partial, super_resume, super_wait)
3982 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
3983 (fbsd_handle_debug_trap): Remove target_ops parameter.
3984 (fbsd_nat_add_target): Delete.
3985 * fbsd-nat.h: Include "inf-ptrace.h".
3986 (fbsd_nat_add_target): Delete.
3987 (USE_SIGTRAP_SIGINFO): Define.
3988 (fbsd_nat_target): New class.
3990 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
3991 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
3992 (amd64bsd_target): Delete.
3993 * amd64-bsd-nat.h: New file.
3994 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
3996 (amd64_fbsd_nat_target): New class.
3997 (the_amd64_fbsd_nat_target): New.
3998 (amd64fbsd_read_description): Refactor as method of
3999 amd64_fbsd_nat_target.
4000 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
4001 (_initialize_amd64fbsd_nat): Adjust to C++ification.
4002 * amd64-nat.h (amd64bsd_target): Delete function declaration.
4003 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
4004 (i386bsd_store_inferior_registers): Remove target_ops parameter.
4005 (i386bsd_target): Delete.
4006 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
4007 (i386bsd_fetch_inferior_registers)
4008 (i386bsd_store_inferior_registers): Declare.
4009 (i386_bsd_nat_target): New class.
4010 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
4011 (the_i386_fbsd_nat_target): New.
4012 (i386fbsd_resume, i386fbsd_read_description): Refactor as
4013 i386_fbsd_nat_target methods.
4014 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
4015 (_initialize_i386fbsd_nat): Adjust to C++ification.
4016 * x86-bsd-nat.c (super_mourn_inferior): Delete.
4017 (x86bsd_mourn_inferior, x86bsd_target): Delete.
4018 (_initialize_x86_bsd_nat): Adjust to C++ification.
4019 * x86-bsd-nat.h: Include "x86-nat.h".
4020 (x86bsd_target): Delete declaration.
4021 (x86bsd_nat_target): New class.
4023 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
4024 (the_aarch64_fbsd_nat_target): New.
4025 (aarch64_fbsd_fetch_inferior_registers)
4026 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
4027 aarch64_fbsd_nat_target.
4028 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
4029 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
4030 (the_alpha_bsd_nat_target): New.
4031 (alphabsd_fetch_inferior_registers)
4032 (alphabsd_store_inferior_registers): Refactor as
4033 alpha_bsd_nat_target methods.
4034 (_initialize_alphabsd_nat): Refactor as methods of
4035 alpha_bsd_nat_target.
4036 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
4037 (the_amd64_nbsd_nat_target): New.
4038 (_initialize_amd64nbsd_nat): Adjust to C++ification.
4039 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
4040 (the_amd64_obsd_nat_target): New.
4041 (_initialize_amd64obsd_nat): Adjust to C++ification.
4042 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
4043 (the_arm_fbsd_nat_target): New.
4044 (arm_fbsd_fetch_inferior_registers)
4045 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
4046 (_initialize_arm_fbsd_nat): Refactor as methods of
4047 arm_fbsd_nat_target.
4048 (_initialize_arm_fbsd_nat): Adjust to C++ification.
4049 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
4050 (the_arm_netbsd_nat_target): New.
4051 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
4052 arm_netbsd_nat_target.
4053 (_initialize_arm_netbsd_nat): Adjust to C++ification.
4054 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
4055 (the_hppa_nbsd_nat_target): New.
4056 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
4057 hppa_nbsd_nat_target methods.
4058 (_initialize_hppanbsd_nat): Adjust to C++ification.
4059 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
4060 (the_hppa_obsd_nat_target): New.
4061 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
4062 methods of hppa_obsd_nat_target.
4063 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
4065 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
4066 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
4068 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
4069 (_initialize_i386obsd_nat): Use add_target.
4070 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
4071 (the_m68k_bsd_nat_target): New.
4072 (m68kbsd_fetch_inferior_registers)
4073 (m68kbsd_store_inferior_registers): Refactor as methods of
4074 m68k_bsd_nat_target.
4075 (_initialize_m68kbsd_nat): Adjust to C++ification.
4076 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
4077 (the_mips_fbsd_nat_target): New.
4078 (mips_fbsd_fetch_inferior_registers)
4079 (mips_fbsd_store_inferior_registers): Refactor as methods of
4080 mips_fbsd_nat_target.
4081 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
4083 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
4084 (the_mips_nbsd_nat_target): New.
4085 (mipsnbsd_fetch_inferior_registers)
4086 (mipsnbsd_store_inferior_registers): Refactor as methods of
4087 mips_nbsd_nat_target.
4088 (_initialize_mipsnbsd_nat): Adjust to C++ification.
4089 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
4090 (the_mips64_obsd_nat_target): New.
4091 (mips64obsd_fetch_inferior_registers)
4092 (mips64obsd_store_inferior_registers): Refactor as methods of
4093 mips64_obsd_nat_target.
4094 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
4096 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
4098 * nbsd-nat.h: Include "inf-ptrace.h".
4099 (nbsd_nat_target): New class.
4100 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
4101 (obsd_wait): Refactor as methods of obsd_nat_target.
4102 (obsd_add_target): Delete.
4103 * obsd-nat.h: Include "inf-ptrace.h".
4104 (obsd_nat_target): New class.
4105 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
4106 (the_ppc_fbsd_nat_target): New.
4107 (ppcfbsd_fetch_inferior_registers)
4108 (ppcfbsd_store_inferior_registers): Refactor as methods of
4109 ppc_fbsd_nat_target.
4110 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
4112 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
4113 (the_ppc_nbsd_nat_target): New.
4114 (ppcnbsd_fetch_inferior_registers)
4115 (ppcnbsd_store_inferior_registers): Refactor as methods of
4116 ppc_nbsd_nat_target.
4117 (_initialize_ppcnbsd_nat): Adjust to C++ification.
4118 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
4119 (the_ppc_obsd_nat_target): New.
4120 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
4121 methods of ppc_obsd_nat_target.
4122 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
4124 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
4125 (the_sh_nbsd_nat_target): New.
4126 (shnbsd_fetch_inferior_registers)
4127 (shnbsd_store_inferior_registers): Refactor as methods of
4129 (_initialize_shnbsd_nat): Adjust to C++ification.
4130 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
4131 (inf_ptrace_xfer_partial): Delete.
4132 (sparc_xfer_partial, sparc_target): Delete.
4133 * sparc-nat.h (sparc_fetch_inferior_registers)
4134 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
4135 (sparc_target): Delete function declaration.
4136 (sparc_target): New template class.
4137 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
4138 (_initialize_sparcnbsd_nat): Adjust to C++ification.
4139 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
4140 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
4142 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
4143 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
4144 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
4145 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
4147 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
4148 (the_vax_bsd_nat_target): New.
4149 (vaxbsd_fetch_inferior_registers)
4150 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
4152 (_initialize_vaxbsd_nat): Adjust to C++ification.
4154 * bsd-kvm.c (bsd_kvm_target): New class.
4155 (bsd_kvm_ops): Now a bsd_kvm_target.
4156 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
4157 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
4158 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
4160 (bsd_kvm_return_one): Delete.
4161 (bsd_kvm_add_target): Adjust to C++ification.
4163 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
4164 (nto_procfs_target_procfs): New classes.
4165 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
4166 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
4167 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
4168 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
4169 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
4170 (procfs_remove_hw_breakpoint, procfs_resume)
4171 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
4172 (procfs_kill_inferior, procfs_store_registers)
4173 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
4174 as methods of nto_procfs_target.
4175 (nto_procfs_ops): Now an nto_procfs_target_procfs.
4176 (nto_native_ops): Delete.
4177 (procfs_open, procfs_native_open): Delete.
4178 (nto_native_ops): Now an nto_procfs_target_native.
4179 (init_procfs_targets): Adjust to C++ification.
4180 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
4181 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
4182 Refactor as methods of nto_procfs_target.
4184 * go32-nat.c (go32_nat_target): New class.
4185 (the_go32_nat_target): New.
4186 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
4187 (go32_store_registers, go32_xfer_partial, go32_files_info)
4188 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
4189 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
4190 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
4191 (go32_pid_to_str): Refactor as methods of go32_nat_target.
4192 (go32_target): Delete.
4193 (_initialize_go32_nat): Adjust to C++ification.
4195 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
4196 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
4197 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
4198 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
4200 (gnu_target): Delete.
4201 * gnu-nat.h (gnu_target): Delete.
4202 (gnu_nat_target): New class.
4203 * i386-gnu-nat.c (gnu_base_target): New.
4204 (i386_gnu_nat_target): New class.
4205 (the_i386_gnu_nat_target): New.
4206 (_initialize_i386gnu_nat): Adjust to C++ification.
4208 2018-05-02 Pedro Alves <palves@redhat.com>
4210 * bfd-target.c (target_bfd_xclose): Rename to ...
4211 (target_bfd_close): ... this.
4212 (target_bfd_reopen): Adjust.
4213 * target.c (target_close): Remove references to to_xclose.
4214 * target.h (target_ops::to_xclose): Delete.
4215 (target_ops::to_close): Update comments.
4217 2018-05-02 Pedro Alves <palves@redhat.com>
4219 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
4221 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
4222 * inf-ptrace.c (inf_ptrace_register_u_offset)
4223 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
4224 (inf_ptrace_store_register, inf_ptrace_store_registers)
4225 (inf_ptrace_trad_target): Move to ...
4226 * linux-nat-trad.c: ... this new file.
4227 * linux-nat-trad.h: New file.
4228 * linux-nat.c (linux_target_install_ops): Make extern.
4229 (linux_trad_target): Delete.
4230 * linux-nat.h (linux_trad_target): Delete declaration.
4231 (linux_target_install_ops): Declare.
4232 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
4235 2018-05-02 Pedro Alves <palves@redhat.com>
4237 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
4238 procfs_target/add_target here.
4239 * procfs.c (procfs_target): Make static.
4240 (_initialize_procfs): Call add_target here.
4241 * procfs.h (struct target_ops): Remove forward declaration.
4242 (procfs_target): Remove declaration.
4243 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
4245 2018-05-02 Pedro Alves <palves@redhat.com>
4247 * procfs.c (procfs_stopped_by_watchpoint)
4248 (procfs_insert_watchpoint, procfs_remove_watchpoint)
4249 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
4251 (procfs_use_watchpoints): Delete, move contents...
4252 (procfs_target): ... here.
4253 * procfs.h (procfs_use_watchpoints): Delete declaration.
4254 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
4255 procfs_use_watchpoints.
4256 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
4257 procfs_use_watchpoints.
4259 2018-05-02 Tom Tromey <tom@tromey.com>
4262 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
4263 and var_zuinteger_unlimited.
4264 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
4265 and PARAM_ZUINTEGER_UNLIMITED.
4266 (set_parameter_value): Handle var_zuinteger and
4267 var_zuinteger_unlimited.
4268 (add_setshow_generic): Likewise.
4269 (parmpy_init): Likewise.
4271 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
4274 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
4275 pointer is not null before dereferencing it.
4277 2018-04-30 Tom Tromey <tom@tromey.com>
4279 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
4282 2018-04-30 Tom Tromey <tom@tromey.com>
4284 * breakpoint.c (mention): Remove use of is_mi_like_p.
4285 (print_mention_ranged_breakpoint): Likewise.
4286 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
4289 2018-04-30 Tom Tromey <tom@tromey.com>
4291 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
4293 2018-04-30 Tom Tromey <tom@tromey.com>
4295 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
4296 (info_spu_event_command): Remove some uses of is_mi_like_p.
4298 2018-04-30 Tom Tromey <tom@tromey.com>
4300 * python/py-framefilter.c (py_print_single_arg)
4301 (enumerate_locals, py_print_args, py_print_frame): Remove some
4302 uses of is_mi_like_p.
4304 2018-04-30 Tom Tromey <tom@tromey.com>
4307 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
4308 * ui-out.h (ui_out::is_mi_like_p): Now const.
4309 (ui_out::do_is_mi_like_p): Now const.
4310 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
4312 2018-04-30 Tom Tromey <tom@tromey.com>
4314 * varobj.c (varobj_set_visualizer): Use new_reference.
4315 * python/python.c (gdbpy_decode_line): Use new_reference.
4316 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
4319 2018-04-30 Tom Tromey <tom@tromey.com>
4321 * varobj.c (install_new_value): Use new_reference.
4322 * value.h (value_incref): Return void. Swap intro comment with
4324 * value.c (set_value_parent): Use new_reference.
4325 (value_incref): Return void. Update intro comment.
4326 (release_value): Use new_reference.
4327 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
4329 2018-04-30 Tom Tromey <tom@tromey.com>
4331 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
4332 * gdb_bfd.h (new_bfd_ref): Remove.
4333 (gdb_bfd_open): Update comment.
4334 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
4335 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
4336 (gdb_bfd_fdopenr): Use new_reference.
4337 * exec.c (exec_file_attach): Use new_reference.
4339 2018-04-30 Tom Tromey <tom@tromey.com>
4341 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
4344 2018-04-30 Tom Tromey <tom@tromey.com>
4346 * jit.c (jit_read_code_entry): Use type_align.
4347 * i386-tdep.c (i386_gdbarch_init): Don't call
4348 set_gdbarch_long_long_align_bit.
4349 * gdbarch.sh: Remove long_long_align_bit.
4350 * gdbarch.c, gdbarch.h: Rebuild.
4351 * arc-tdep.c (arc_type_align): New function.
4352 (arc_gdbarch_init): Use arc_type_align. Don't call
4353 set_gdbarch_long_long_align_bit.
4355 2018-04-30 Tom Tromey <tom@tromey.com>
4357 * rust-lang.c (rust_type_alignment): Remove.
4358 (rust_composite_type): Use type_align.
4360 2018-04-30 Tom Tromey <tom@tromey.com>
4362 * NEWS: Mention Type.align.
4363 * python/py-type.c (typy_get_alignof): New function.
4364 (type_object_getset): Add "alignof".
4366 2018-04-30 Tom Tromey <tom@tromey.com>
4370 * std-operator.def (UNOP_ALIGNOF): New operator.
4371 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
4373 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
4374 * c-lang.c (c_op_print_tab): Add alignof.
4375 * c-exp.y (ALIGNOF): New token.
4376 (exp): Add "ALIGNOF" production.
4377 (ident_tokens): Add _Alignof and alignof.
4379 2018-04-30 Tom Tromey <tom@tromey.com>
4381 * i386-tdep.c (i386_type_align): New function.
4382 (i386_gdbarch_init): Update.
4383 * gdbarch.sh (type_align): New method.
4384 * gdbarch.c, gdbarch.h: Rebuild.
4385 * arch-utils.h (default_type_align): Declare.
4386 * arch-utils.c (default_type_align): New function.
4387 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
4388 (struct type) <align_log2>: New field.
4389 <instance_flags>: Now a bitfield.
4390 (TYPE_RAW_ALIGN): New macro.
4391 (type_align, type_raw_align, set_type_align): Declare.
4392 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
4394 * dwarf2read.c (quirk_rust_enum): Set type alignment.
4395 (get_alignment, maybe_set_alignment): New functions.
4396 (read_structure_type, read_enumeration_type, read_array_type)
4397 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
4398 (read_subrange_type, read_base_type): Set type alignment.
4400 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
4402 * dwarf2read.c (read_index_from_section): Use bool.
4404 2018-04-29 Fabian Groffen <grobian@gentoo.org>
4407 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
4410 2018-04-29 John Reiser <jreiser@BitWagon.com>
4413 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
4414 last step, and do it atomically.
4416 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
4418 * compile/compile-c-types.c (convert_int, convert_float):
4421 2018-04-27 Tom Tromey <tom@tromey.com>
4424 * rust-lang.c (rust_inclusive_range_type_p): New function.
4425 (rust_range): Handle inclusive ranges.
4426 (rust_compute_range): Likewise.
4427 * rust-exp.y (struct rust_op) <inclusive>: New field.
4428 (DOTDOTEQ): New constant.
4429 (range_expr): Add "..=" productions.
4430 (operator_tokens): Add "..=" token.
4431 (ast_range): Add "inclusive" parameter.
4432 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
4434 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
4436 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
4437 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
4439 * expprint.c (print_subexp_standard): Handle new bounds values.
4440 (dump_subexp_body_standard): Likewise.
4442 2018-04-27 Tom Tromey <tom@tromey.com>
4444 * configure: Rebuild.
4445 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
4446 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
4448 (class symbol_needs_eval_context): Likewise.
4449 * dwarf2read.c (mock_mapped_index::symbol_name_count)
4450 (mock_mapped_index::symbol_name_at): Use "override". Remove
4452 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
4454 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
4455 * aarch64-tdep.c (instruction_reader::read): Use "override".
4456 (instruction_reader_test::read): Likewise.
4457 * arm-tdep.c (instruction_reader::read): Use "override".
4458 (instruction_reader_thumb::read): Likewise.
4460 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
4463 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
4464 instead of remote_send.
4465 (remote_send): Remove.
4467 2018-04-26 Pedro Alves <palves@redhat.com>
4469 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
4470 find_function_start_sal instead of find_pc_line.
4472 2018-04-26 Pedro Alves <palves@redhat.com>
4474 * breakpoint.c (set_breakpoint_location_function): Handle
4476 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
4477 * elfread.c (elf_symtab_read): Give data symbols with
4478 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
4479 (elf_rel_plt_read): Update comment.
4480 * linespec.c (convert_linespec_to_sals): Handle
4482 (minsym_found): Handle mst_data_gnu_ifunc.
4483 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
4484 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
4485 * parse.c (find_minsym_type_and_address): Handle
4487 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
4488 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
4489 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
4491 <mst_data_gnu_ifunc>: New enumerator.
4493 2018-04-26 Pedro Alves <palves@redhat.com>
4495 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
4496 (lookup_minimal_symbol_by_pc_section): ... this. Replace
4497 'want_trampoline' parameter by a lookup_msym_prefer parameter.
4499 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
4500 (lookup_minimal_symbol_by_pc): Adjust.
4501 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
4502 (lookup_solib_trampoline_symbol_by_pc): Adjust.
4503 * minsyms.h (lookup_msym_prefer): New enum.
4504 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
4505 parameter by a lookup_msym_prefer parameter.
4507 2018-04-26 Pedro Alves <palves@redhat.com>
4509 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
4510 ends in "@plt" instead of looking at the symbol's section.
4512 2018-04-26 Pedro Alves <palves@redhat.com>
4514 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
4516 (find_pc_partial_function_gnu_ifunc): Rename to ...
4517 (find_pc_partial_function): ... this, and remove references to
4519 (find_pc_partial_function): Delete old implementation.
4520 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
4522 2018-04-26 Pedro Alves <palves@redhat.com>
4524 * linespec.c (struct bound_minimal_symbol_search_key): New.
4525 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
4526 skip first line if we found a GNU ifunc minimal symbol by name.
4527 (compare_msymbols): Change parameters to work with a destructured
4529 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
4532 2018-04-26 Pedro Alves <palves@redhat.com>
4534 * breakpoint.c (set_breakpoint_location_function): Don't resolve
4535 ifunc targets here. Instead, if we have an ifunc minsym, use its
4537 (add_location_to_breakpoint): Store the minsym and the objfile in
4538 the breakpoint location.
4539 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
4540 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
4541 Record the minsym in the sal.
4542 * symtab.h (symtab_and_line) <msymbol>: New field.
4544 2018-04-26 Pedro Alves <palves@redhat.com>
4546 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
4547 unless we actually resolved the ifunc.
4549 2018-04-26 Pedro Alves <palves@redhat.com>
4551 * c-exp.y (variable production): Prefer ifunc minsyms over
4552 regular function symbols.
4553 * symtab.c (find_gnu_ifunc): New function.
4554 * minsyms.h (lookup_msym_prefer): New enum.
4555 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
4556 parameter by a lookup_msym_prefer parameter.
4557 * symtab.h (find_gnu_ifunc): New declaration.
4559 2018-04-26 Pedro Alves <palves@redhat.com>
4561 * blockframe.c (find_gnu_ifunc_target_type): New function.
4562 (find_function_type): New.
4563 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
4564 return a value with a memory address.
4565 (eval_call): For calls to GNU ifunc functions, try to find the
4566 type of the target function from the type that the resolver
4568 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
4570 * infcall.c (find_function_return_type): Delete.
4571 (find_function_addr): Add 'function_type' parameter. For calls to
4572 GNU ifunc functions, try to find the type of the target function
4573 from the type that the resolver returns, and return it via
4575 (call_function_by_hand_dummy): Adjust to use the function type
4576 returned by find_function_addr.
4577 (find_function_addr): Add 'function_type' parameter and move
4579 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
4582 2018-04-26 Pedro Alves <palves@redhat.com>
4584 * c-exp.y (variable production): Skip finding an alias for ifunc
4587 2018-04-26 Pedro Alves <palves@redhat.com>
4589 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
4591 2018-04-25 Pedro Alves <palves@redhat.com>
4593 * infcmd.c (kill_command): Print the pid as string, not the whole
4594 thread's ptid. Add comment. s/has been killed/killed/ in output
4596 * remote.c (remote_detach_1): Print the pid as string, not the
4597 whole thread's ptid.
4599 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
4600 Sergio Durigan Junior <sergiodj@redhat.com>
4601 Pedro Alves <palves@redhat.com>
4603 * infcmd.c (kill_command): Print message when inferior has
4605 * inferior.c (print_inferior_events): Remove 'static'. Set as
4607 (add_inferior): Improve message printed when
4608 'print_inferior_events' is on.
4609 (exit_inferior): Remove message printed when
4610 'print_inferior_events' is on.
4611 (detach_inferior): Improve message printed when
4612 'print_inferior_events' is on.
4613 (initialize_inferiors): Use 'add_inferior_silent' to set
4614 'current_inferior_'.
4615 * inferior.h (print_inferior_events): Declare here as
4617 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
4618 '[Detaching...]' messages when 'print_inferior_events' is on.
4619 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
4620 as prefix/suffix for messages. Remove periods. Fix erroneous
4621 'Detaching after fork from child...', replace it by '... from
4623 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
4624 prefix/suffix when printing 'Detaching...' messages. Print
4625 them when 'print_inferior_events' is on.
4626 * remote.c (remote_detach_1): Print message when detaching
4627 from inferior and '!is_fork_parent'.
4629 2018-04-24 Tom Tromey <tom@tromey.com>
4631 * cli-out.h: Reindent.
4633 2018-04-24 Tom Tromey <tom@tromey.com>
4635 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
4636 (cli_ui_out::do_field_string): Use fputs_filtered.
4637 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
4639 2018-04-23 Tom Tromey <tom@tromey.com>
4641 * guile/scm-frame.c (gdbscm_frame_read_var): Use
4642 gdb::unique_xmalloc_ptr.
4644 2018-04-23 Tom Tromey <tom@tromey.com>
4646 * configure: Rebuild.
4648 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
4651 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
4652 prepare_for_testing. Set normal_bp to r_debug_state if target
4655 2018-04-21 Pedro Alves <palves@redhat.com>
4656 Rajendra SY <rajendra.sy@gmail.com>
4658 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
4659 * remote.c (extended_remote_attach): In all-stop mode, mark the
4660 thread as executing.
4662 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4664 * thread.c (thread_apply_all_command): Fix comment.
4665 (thread_command): Fix comment.
4667 2018-04-10 Alan Hayward <alan.hayward@arm.com>
4669 * common/tdesc.h (tdesc_create_feature): Remove xml filename
4671 * features/aarch64-core.c (create_feature_aarch64_core):
4673 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
4675 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
4677 * features/i386/32bit-avx512.c
4678 (create_feature_i386_32bit_avx512): Likewise.
4679 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
4681 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
4683 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
4685 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
4687 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
4689 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
4691 * features/i386/64bit-avx512.c
4692 (create_feature_i386_64bit_avx512): Likewise.
4693 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
4695 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
4697 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
4699 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
4701 * features/i386/64bit-segments.c
4702 (create_feature_i386_64bit_segments): Likewise.
4703 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
4705 * features/i386/x32-core.c
4706 (create_feature_i386_x32_core): Likewise.
4707 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
4708 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
4709 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
4710 * target-descriptions.c: In generated code, don't pass xml
4713 2018-04-18 Alan Hayward <alan.hayward@arm.com>
4715 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
4716 (print_xml_feature::visit_post): Likewise.
4717 (print_xml_feature::visit): Likewise.
4718 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
4719 (print_xml_feature): Add new class.
4720 * regformats/regdat.sh: Null xmltarget on feature targets.
4721 * target-descriptions.c (struct target_desc): Add xmltarget.
4722 (maintenance_check_tdesc_xml_convert): Add unittest function.
4723 (tdesc_get_features_xml): Add function to get xml.
4724 (maintenance_check_xml_descriptions): Test xml generation.
4725 * xml-tdesc.c (string_read_description_xml): Add function.
4726 * xml-tdesc.h (string_read_description_xml): Add declaration.
4728 2018-04-18 Alan Hayward <alan.hayward@arm.com>
4730 * features/Makefile: Add feature marker to targets with new style
4731 target descriptions.
4732 * regformats/aarch64.dat: Regenerate.
4733 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
4734 * regformats/i386/amd64-avx-linux.dat: Likewise.
4735 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
4736 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
4737 * regformats/i386/amd64-linux.dat: Likewise.
4738 * regformats/i386/amd64-mpx-linux.dat: Likewise.
4739 * regformats/i386/amd64.dat: Likewise.
4740 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
4741 * regformats/i386/i386-avx-linux.dat: Likewise.
4742 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
4743 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
4744 * regformats/i386/i386-linux.dat: Likewise.
4745 * regformats/i386/i386-mmx-linux.dat: Likewise.
4746 * regformats/i386/i386-mpx-linux.dat: Likewise.
4747 * regformats/i386/i386.dat: Likewise.
4748 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
4749 * regformats/i386/x32-avx-linux.dat: Likewise.
4750 * regformats/i386/x32-linux.dat: Likewise.
4751 * regformats/tic6x-c62x-linux.dat: Likewise.
4752 * regformats/tic6x-c64x-linux.dat: Likewise.
4753 * regformats/tic6x-c64xp-linux.dat: Likewise.
4754 * regformats/regdat.sh: Parse feature marker.
4756 2018-04-18 Alan Hayward <alan.hayward@arm.com>
4758 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
4759 (tdesc_osabi_name): Likewise.
4760 * target-descriptions.c (tdesc_architecture_name): Add new
4762 (tdesc_osabi_name): Likewise.
4764 2018-04-18 Alan Hayward <alan.hayward@arm.com>
4766 * common/tdesc.c (tdesc_predefined_type): Move to here.
4767 (tdesc_named_type): Likewise.
4768 (tdesc_create_vector): Likewise.
4769 (tdesc_create_struct): Likewise.
4770 (tdesc_set_struct_size): Likewise.
4771 (tdesc_create_union): Likewise.
4772 (tdesc_create_flags): Likewise.
4773 (tdesc_create_enum): Likewise.
4774 (tdesc_add_field): Likewise.
4775 (tdesc_add_typed_bitfield): Likewise.
4776 (tdesc_add_bitfield): Likewise.
4777 (tdesc_add_flag): Likewise.
4778 (tdesc_add_enum_value): Likewise.
4779 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
4780 (struct tdesc_type_vector): Likewise.
4781 (struct tdesc_type_field): Likewise.
4782 (struct tdesc_type_with_fields): Likewise.
4783 (tdesc_create_enum): Add declaration.
4784 (tdesc_add_typed_bitfield): Likewise.
4785 (tdesc_add_enum_value): Likewise.
4786 * target-descriptions.c (tdesc_type_field): Move from here.
4787 (tdesc_type_builtin): Likewise.
4788 (tdesc_type_vector): Likewise.
4789 (tdesc_type_with_fields): Likewise.
4790 (tdesc_predefined_types): Likewise.
4791 (tdesc_named_type): Likewise.
4792 (tdesc_create_vector): Likewise.
4793 (tdesc_create_struct): Likewise.
4794 (tdesc_set_struct_size): Likewise.
4795 (tdesc_create_union): Likewise.
4796 (tdesc_create_flags): Likewise.
4797 (tdesc_create_enum): Likewise.
4798 (tdesc_add_field): Likewise.
4799 (tdesc_add_typed_bitfield): Likewise.
4800 (tdesc_add_bitfield): Likewise.
4801 (tdesc_add_flag): Likewise.
4802 (tdesc_add_enum_value): Likewise.
4803 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
4804 (tdesc_add_typed_bitfield): Likewise.
4805 (tdesc_add_enum_value): Likewise.
4807 2018-04-18 Alan Hayward <alan.hayward@arm.com>
4809 * common/tdesc.c (tdesc_feature::accept): Move to here.
4810 (tdesc_feature::operator==): Likewise.
4811 (tdesc_create_reg): Likewise.
4812 * common/tdesc.h (tdesc_type_kind): Likewise.
4813 (struct tdesc_type): Likewise.
4814 (struct tdesc_feature): Likewise.
4815 * regformats/regdat.sh: Create a feature.
4816 * target-descriptions.c (tdesc_type_kind): Move from here.
4817 (tdesc_type): Likewise.
4818 (tdesc_type_up): Likewise.
4819 (tdesc_feature): Likewise.
4820 (tdesc_create_reg): Likewise.
4822 2018-04-18 Alan Hayward <alan.hayward@arm.com>
4824 * Makefile.in: Add arch/tdesc.c
4825 * common/tdesc.c: New file.
4826 * common/tdesc.h (tdesc_element_visitor): Move to here.
4827 (tdesc_element): Likewise.
4828 (tdesc_reg): Likewise.
4829 (tdesc_reg_up): Likewise.
4830 * regformats/regdef.h (reg): Add offset to constructors.
4831 * target-descriptions.c (tdesc_element_visitor): Move from here.
4832 (tdesc_element): Likewise.
4833 (tdesc_reg): Likewise.
4834 (tdesc_reg_up): Likewise.
4836 2018-04-17 Tom Tromey <tom@tromey.com>
4838 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
4841 2018-04-17 Tom Tromey <tom@tromey.com>
4843 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
4845 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
4847 * symtab.c (print_symbol_info): Skip printing filename and line
4848 number when `last' is NULL.
4849 (symtab_symbol_info): Use empty string instead of NULL for first
4850 invocation of print_symbol_info.
4851 (rbreak_command): Pass NULL to `last' parameter of
4854 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
4856 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
4859 2018-04-16 Pedro Alves <palves@redhat.com>
4861 * MAINTAINERS (sh): Remove.
4862 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
4863 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
4864 (ALLDEPFILES): Remove sh64-tdep.c.
4865 * NEWS: Mentions that support for SH-5/SH64 is removed.
4866 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
4867 (sh*-*-openbsd*): Ditto.
4868 (sh64-*-elf*): Remove.
4870 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
4871 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
4872 * sh-tdep.c: No longer include "sh64-tdep.h".
4873 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
4874 * sh64-tdep.c, sh64-tdep.h: Remove files.
4876 2018-04-16 Pedro Alves <palves@redhat.com>
4878 * MAINTAINERS: Remove m88k.
4879 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
4880 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
4881 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
4882 * NEWS: Mention that support for m88k was removed.
4883 * configure.host (m88*-*-*): Remove support.
4884 * configure.nat (m88k-*-*): Remove support.
4885 * configure.tgt (m88*-*-openbsd*): Remove.
4886 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
4888 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
4890 * configure.tgt (x86_tobjs): New variable.
4891 (amd64_tobjs, i386_tobjs): Use it.
4893 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4895 * symtab.c (print_symbol_info): Precede the symbol definition by
4896 the line number when available.
4897 * NEWS: Advertise this enhancement.
4899 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
4901 * NEWS (New options): announce set/show record btrace cpu.
4902 * btrace.c: Include record-btrace.h.
4903 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
4904 the vendor is unknown.
4905 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
4906 Maybe overwrite the btrace configuration's cpu.
4907 (btrace_compute_ftrace): Add cpu parameter. Update callers.
4908 (btrace_fetch): Add cpu parameter. Update callers.
4909 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
4910 Maybe overwrite the btrace configuration's cpu. Skip enabling
4911 errata workarounds if the vendor is unknown.
4912 * python/py-record-btrace.c: Include record-btrace.h.
4913 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
4914 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
4915 * record-btrace.c (record_btrace_cpu_state_kind): New.
4916 (record_btrace_cpu): New.
4917 (set_record_btrace_cpu_cmdlist): New.
4918 (record_btrace_get_cpu): New.
4919 (require_btrace_thread, record_btrace_info)
4920 (record_btrace_resume_thread): Call record_btrace_get_cpu.
4921 (cmd_set_record_btrace_cpu_none): New.
4922 (cmd_set_record_btrace_cpu_auto): New.
4923 (cmd_set_record_btrace_cpu): New.
4924 (cmd_show_record_btrace_cpu): New.
4925 (_initialize_record_btrace): Initialize set/show record btrace cpu
4927 * record-btrace.h (record_btrace_get_cpu): New.
4929 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
4931 * record.c (set_record_command): Fix typo in message.
4933 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
4935 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
4937 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
4939 * infrun.c (process_event_stop_test): Call
4940 gdbarch_in_indirect_branch_thunk.
4941 * gdbarch.sh (in_indirect_branch_thunk): New.
4942 * gdbarch.c: Regenerated.
4943 * gdbarch.h: Regenerated.
4946 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
4947 (HFILES_NO_SRCDIR): Add x86-tdep.h.
4948 (ALLDEPFILES): Add x86-tdep.c.
4949 * arch-utils.h (default_in_indirect_branch_thunk): New.
4950 * arch-utils.c (default_in_indirect_branch_thunk): New.
4951 * i386-tdep: Include x86-tdep.h.
4952 (i386_in_indirect_branch_thunk): New.
4953 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
4955 * amd64-tdep: Include x86-tdep.h.
4956 (amd64_in_indirect_branch_thunk): New.
4957 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
4959 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
4962 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
4963 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
4964 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
4967 2018-04-12 Tom Tromey <tom@tromey.com>
4969 * rust-lang.c (rust_print_struct_def): Remove univariant code.
4970 (rust_evaluate_subexp): Likewise.
4972 2018-04-12 Pedro Alves <palves@redhat.com>
4974 * procfs.c (procfs_detach): Make forward declaration's prototype
4975 match definition's protototype.
4976 (proc_get_LDT_entry): Remove stale do_cleanups call.
4978 2018-04-12 Pedro Alves <palves@redhat.com>
4980 * target.h (target_ops::to_has_exited): Delete.
4981 (target_has_exited): Delete.
4982 * target-delegates.c: Regenerate.
4984 2018-04-11 Pedro Alves <palves@redhat.com>
4986 * target.c (fileio_fh_t::t): Add comment.
4987 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
4988 (target_fileio_close): Handle a NULL target.
4989 (invalidate_fileio_fh): New.
4990 (target_close): Call it.
4991 * remote.c (remote_hostio_send_command): No longer check whether
4992 remote_desc is open.
4994 2018-04-11 Pedro Alves <palves@redhat.com>
4996 * target.c (fileio_fh_t): Make it a named struct instead of a
4998 (fileio_fh_t::is_closed): New method.
4999 (DEF_VEC_O (fileio_fh_t)): Remove.
5000 (fileio_fhandles): Now a std::vector.
5001 (is_closed_fileio_fh): Delete.
5002 (acquire_fileio_fd): Adjust. Rename parameters.
5003 (release_fileio_fd): Adjust.
5004 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
5005 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
5006 (target_fileio_close): Adjust.
5008 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
5010 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
5013 2018-04-10 Pedro Alves <palves@redhat.com>
5015 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
5016 (scoped_finish_thread_state): New class.
5017 * infcmd.c (run_command_1): Use it instead of finish_thread_state
5019 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
5020 (fetch_inferior_event, normal_stop): Likewise.
5021 * thread.c (finish_thread_state_cleanup): Delete.
5023 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
5024 Pedro Alves <palves@redhat.com>
5026 * value.c: Include "selftest.h" and "common/array-view.h".
5027 (struct range) <operator ==>: New.
5028 (test_ranges_contain): New.
5029 (check_ranges_vector): New.
5030 (test_insert_into_bit_range_vector): New.
5031 (_initialize_values): Register selftests.
5032 * common/array-view.h (operator==, operator!=): New.
5034 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
5036 * common/gdb_vecs.h (unordered_remove): Add overload that takes
5038 * inline-frame.c: Include <algorithm>.
5039 (struct inline_state): Add constructor.
5040 (inline_state_s): Remove.
5041 (DEF_VEC_O(inline_state_s)): Remove.
5042 (inline_states): Change type to std::vector.
5043 (find_inline_frame_state): Adjust to std::vector.
5044 (allocate_inline_frame_state): Remove.
5045 (clear_inline_frame_state): Adjust to std::vector.
5046 (skip_inline_frames): Adjust to std::vector.
5048 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
5050 * tracepoint.h (struct trace_state_variable): Add constructor.
5051 <name>: Change type to std::string.
5052 * tracepoint.c (tsv_s): Remove.
5053 (DEF_VEC_O(tsv_s)): Remove.
5054 (tvariables): Change to std::vector.
5055 (create_trace_state_variable): Adjust to std::vector.
5056 (find_trace_state_variable): Likewise.
5057 (find_trace_state_variable_by_number): Likewise.
5058 (delete_trace_state_variable): Likewise.
5059 (trace_variable_command): Adjust to std::string.
5060 (delete_trace_variable_command): Likewise.
5061 (tvariables_info_1): Adjust to std::vector.
5062 (save_trace_state_variables): Likewise.
5063 (start_tracing): Likewise.
5064 (merge_uploaded_trace_state_variables): Adjust to std::vector
5066 * target.h (struct target_ops)
5067 <to_download_trace_state_variable>: Pass reference to
5068 trace_state_variable.
5069 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
5070 * target-delegates.c: Re-generate.
5071 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
5072 (mi_tsv_deleted): Likewise.
5073 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
5074 * remote.c (remote_download_trace_state_variable): Change
5075 pointer to reference and adjust.
5076 * make-target-delegates (parse_argtypes): Handle references.
5077 (write_function_header): Likewise.
5078 (munge_type): Likewise.
5080 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
5082 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5083 string_view-selftests.c.
5084 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
5086 * unittests/basic_string_view/cons/char/1.cc: Likewise.
5087 * unittests/basic_string_view/cons/char/2.cc: Likewise.
5088 * unittests/basic_string_view/cons/char/3.cc: Likewise.
5089 * unittests/basic_string_view/element_access/char/1.cc:
5091 * unittests/basic_string_view/element_access/char/empty.cc:
5093 * unittests/basic_string_view/element_access/char/front_back.cc:
5095 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
5096 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
5098 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
5100 * unittests/basic_string_view/modifiers/swap/char/1.cc:
5102 * unittests/basic_string_view/operations/compare/char/1.cc:
5104 * unittests/basic_string_view/operations/compare/char/13650.cc:
5106 * unittests/basic_string_view/operations/copy/char/1.cc:
5108 * unittests/basic_string_view/operations/data/char/1.cc:
5110 * unittests/basic_string_view/operations/find/char/1.cc:
5112 * unittests/basic_string_view/operations/find/char/2.cc:
5114 * unittests/basic_string_view/operations/find/char/3.cc:
5116 * unittests/basic_string_view/operations/find/char/4.cc:
5118 * unittests/basic_string_view/operations/rfind/char/1.cc:
5120 * unittests/basic_string_view/operations/rfind/char/2.cc:
5122 * unittests/basic_string_view/operations/rfind/char/3.cc:
5124 * unittests/basic_string_view/operations/substr/char/1.cc:
5126 * unittests/basic_string_view/operators/char/2.cc: Likewise.
5127 * unittests/string_view-selftests.c: New file.
5129 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
5131 * unittests/basic_string_view/capacity/1.cc: New file.
5132 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
5133 * unittests/basic_string_view/cons/char/1.cc: New file.
5134 * unittests/basic_string_view/cons/char/2.cc: New file.
5135 * unittests/basic_string_view/cons/char/3.cc: New file.
5136 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
5137 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
5138 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
5139 * unittests/basic_string_view/element_access/char/1.cc: New file.
5140 * unittests/basic_string_view/element_access/char/2.cc: New file.
5141 * unittests/basic_string_view/element_access/char/empty.cc: New file.
5142 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
5143 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
5144 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
5145 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
5146 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
5147 * unittests/basic_string_view/include.cc: New file.
5148 * unittests/basic_string_view/inserters/char/1.cc: New file.
5149 * unittests/basic_string_view/inserters/char/2.cc: New file.
5150 * unittests/basic_string_view/inserters/char/3.cc: New file.
5151 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
5152 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
5153 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
5154 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
5155 * unittests/basic_string_view/literals/types.cc: New file.
5156 * unittests/basic_string_view/literals/values.cc: New file.
5157 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
5158 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
5159 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
5160 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
5161 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
5162 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
5163 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
5164 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
5165 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
5166 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
5167 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
5168 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
5169 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
5170 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
5171 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
5172 * unittests/basic_string_view/operations/data/char/1.cc: New file.
5173 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
5174 * unittests/basic_string_view/operations/find/char/1.cc: New file.
5175 * unittests/basic_string_view/operations/find/char/2.cc: New file.
5176 * unittests/basic_string_view/operations/find/char/3.cc: New file.
5177 * unittests/basic_string_view/operations/find/char/4.cc: New file.
5178 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
5179 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
5180 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
5181 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
5182 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
5183 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
5184 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
5185 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
5186 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
5187 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
5188 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
5189 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
5190 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
5191 * unittests/basic_string_view/operators/char/2.cc: New file.
5192 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
5193 * unittests/basic_string_view/range_access/char/1.cc: New file.
5194 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
5195 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
5196 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
5197 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
5198 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
5199 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
5200 * unittests/basic_string_view/requirements/typedefs.cc: New file.
5201 * unittests/basic_string_view/typedefs.cc: New file.
5202 * unittests/basic_string_view/types/1.cc: New file.
5204 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
5206 * common/gdb_string_view.h: Remove libstdc++ implementation
5207 details, adjust to gdb reality.
5208 * common/gdb_string_view.tcc: Likewise.
5209 * cli/cli-script.c (struct string_view): Remove.
5210 (user_args) <m_args>: Change element type to gdb::string_view.
5211 (user_args::insert_args): Adjust.
5213 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
5215 * common/gdb_string_view.h: New file.
5216 * common/gdb_string_view.tcc: New file.
5218 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
5220 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
5221 * configure: Re-generate.
5223 2018-04-09 Pedro Alves <palves@redhat.com>
5225 * gdbarch.sh: Include "observable.h" instead of "observer.h".
5226 (set_target_gdbarch): Call
5227 gdb::observers::architecture_changed.notify instead of
5228 observer_notify_architecture_changed.
5230 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
5232 * tracepoint.c (struct current_traceframe_cleanup): Remove.
5233 (do_restore_current_traceframe_cleanup): Remove.
5234 (restore_current_traceframe_cleanup_dtor): Remove.
5235 (make_cleanup_restore_current_traceframe): Remove.
5236 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
5238 * tracepoint.h (struct scoped_restore_current_traceframe): New.
5239 * infrun.c (fetch_inferior_event): Use
5240 scoped_restore_current_traceframe.
5242 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
5244 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
5246 <n_allocated_type_units>: Remove.
5247 <all_type_units>: Change to std::vector.
5248 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
5249 to std::vector change.
5250 (dwarf2_per_objfile::get_cutu): Likewise.
5251 (dwarf2_per_objfile::get_tu): Likewise.
5252 (create_signatured_type_table_from_index): Likewise.
5253 (create_signatured_type_table_from_debug_names): Likewise.
5254 (dw2_symtab_iter_next): Likewise.
5255 (dw2_print_stats): Likewise.
5256 (dw2_expand_all_symtabs): Likewise.
5257 (dw2_expand_marked_cus): Likewise.
5258 (dw2_debug_names_iterator::next): Likewise.
5259 (dwarf2_initialize_objfile): Likewise.
5260 (add_signatured_type_cu_to_table): Likewise.
5261 (create_all_type_units): Likewise.
5262 (add_type_unit): Likewise.
5263 (struct tu_abbrev_offset): Add constructor.
5264 (build_type_psymtabs_1): Adjust to std::vector change.
5265 (print_tu_stats): Likewise.
5266 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
5267 (write_debug_names): Likewise.
5269 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
5271 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
5272 Make an std::vector.
5273 <n_comp_units>: Remove.
5274 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
5275 to std::vector change.
5276 (dwarf2_per_objfile::get_cutu): Likewise.
5277 (dwarf2_per_objfile::get_cu): Likewise.
5278 (create_cus_from_index): Likewise.
5279 (create_addrmap_from_index): Likewise.
5280 (create_addrmap_from_aranges): Likewise.
5281 (dwarf2_read_index): Likewise.
5282 (dw2_find_last_source_symtab): Likewise.
5283 (dw2_map_symtabs_matching_filename): Likewise.
5284 (dw2_symtab_iter_next): Likewise.
5285 (dw2_print_stats): Likewise.
5286 (dw2_expand_all_symtabs): Likewise.
5287 (dw2_expand_symtabs_with_fullname): Likewise.
5288 (dw2_expand_marked_cus): Likewise.
5289 (dw2_map_symbol_filenames): Likewise.
5290 (create_cus_from_debug_names): Likewise.
5291 (dwarf2_read_debug_names): Likewise.
5292 (dw2_debug_names_iterator::next): Likewise.
5293 (dwarf2_initialize_objfile): Likewise.
5294 (set_partial_user): Likewise.
5295 (dwarf2_build_psymtabs_hard): Likewise.
5296 (read_comp_units_from_section): Remove arguments, adjust to
5298 (create_all_comp_units): Adjust to std::vector and
5299 read_comp_units_from_section changes.
5300 (dwarf2_find_containing_comp_unit): Adjust to std::vector
5302 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
5303 (psyms_seen_size): Likewise.
5304 (write_gdbindex): Likewise.
5305 (write_debug_names): Likewise.
5307 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
5309 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
5310 with dwarf2_per_objfile.
5311 (create_cus_from_index): Likewise.
5312 (create_signatured_type_table_from_index): Likewise.
5313 (dwarf2_read_index): Likewise.
5314 (dwarf2_initialize_objfile): Likewise.
5315 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
5316 per_cu rather than get_dwarf2_per_objfile.
5318 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
5320 * dwarf2read.h (struct signatured_type): Forward declare.
5321 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
5323 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
5324 (dw2_get_cutu): ...this.
5325 (dwarf2_per_objfile::get_cu): Rename from...
5326 (dw2_get_cu): ...this.
5327 (dwarf2_per_objfile::get_tu): New.
5328 (create_addrmap_from_index): Adjust.
5329 (create_addrmap_from_aranges): Adjust.
5330 (dw2_find_last_source_symtab): Adjust.
5331 (dw2_map_symtabs_matching_filename): Adjust.
5332 (dw2_symtab_iter_next): Adjust.
5333 (dw2_print_stats): Adjust.
5334 (dw2_expand_all_symtabs): Adjust.
5335 (dw2_expand_symtabs_with_fullname): Adjust.
5336 (dw2_expand_marked_cus): Adjust.
5337 (dw_expand_symtabs_matching_file_matcher): Adjust.
5338 (dw2_map_symbol_filenames): Adjust.
5339 (dw2_debug_names_iterator::next): Adjust.
5340 (dwarf2_initialize_objfile): Adjust.
5341 (set_partial_user): Adjust.
5342 (dwarf2_build_psymtabs_hard): Adjust.
5344 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
5346 * dwarf2read.c (create_signatured_type_table_from_debug_names):
5347 Remove unused variables.
5348 (dw2_map_symtabs_matching_filename): Likewise.
5349 (dwarf2_record_block_ranges): Likewise.
5350 (dwarf2_read_addr_index): Likewise.
5351 (follow_die_offset): Likewise.
5353 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
5355 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
5356 to symbol_file_add_main.
5358 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
5361 * mi/mi-console.c (do_fputc_async_safe): New.
5362 (mi_console_file::write_async_safe): New.
5363 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
5364 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
5366 * ui-file.c (ui_file::putstrn): Adjust call to
5367 fputstrn_unfiltered.
5368 * utils.c (printchar): Replace do_fputs and do_fprintf
5369 parameters by do_fputc.
5370 (fputstr_filtered): Adjust call to printchar.
5371 (fputstr_unfiltered): Likewise.
5372 (fputstrn_filtered): Likewise.
5373 (fputstrn_unfiltered): Add do_fputc parameter, pass to
5375 * utils.h (do_fputc_ftype): New typedef.
5376 (fputstrn_unfiltered): Add do_fputc parameter.
5378 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
5380 * regformats/i386/i386-avx.dat: Remove.
5382 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
5385 * amd64-tdep.c (amd64_none_init_abi): New function.
5386 (amd64_x32_none_init_abi): New function.
5387 (_initialize_amd64_tdep): Register handlers for x86-64 and
5388 x64_32 with GDB_OSABI_NONE.
5389 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
5390 GDB_OSABI_NONE osabi.
5392 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
5395 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
5397 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
5398 * osabi.c (gdb_osabi_names): Add "unknown" entry.
5400 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
5402 * common/byte-vector.h (char_vector): New type.
5403 * target.h (target_read_alloc): Return
5404 gdb::optional<byte_vector>.
5405 (target_read_stralloc): Return gdb::optional<char_vector>.
5406 (target_get_osdata): Return gdb::optional<char_vector>.
5407 * target.c (target_read_alloc_1): Templatize. Replacement
5408 manual memory management with vector.
5409 (target_read_alloc): Change return type, adjust.
5410 (target_read_stralloc): Change return type, adjust.
5411 (target_get_osdata): Change return type, adjust.
5412 * auxv.c (struct auxv_info) <length>: Remove.
5413 <data>: Change type to gdb::optional<byte_vector>.
5414 (auxv_inferior_data_cleanup): Free auxv_info with delete.
5415 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
5416 (target_auxv_search): Adjust.
5417 (fprint_target_auxv): Adjust.
5418 * avr-tdep.c (avr_io_reg_read_command): Adjust.
5419 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
5420 (linux_make_corefile_notes): Adjust.
5421 * osdata.c (get_osdata): Adjust.
5422 * remote.c (remote_get_threads_with_qxfer): Adjust.
5423 (remote_memory_map): Adjust.
5424 (remote_traceframe_info): Adjust.
5425 (btrace_read_config): Adjust.
5426 (remote_read_btrace): Adjust.
5427 (remote_pid_to_exec_file): Adjust.
5428 * solib-aix.c (solib_aix_get_library_list): Adjust.
5429 * solib-dsbt.c (decode_loadmap): Don't free buf.
5430 (dsbt_get_initial_loadmaps): Adjust.
5431 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
5432 * solib-target.c (solib_target_current_sos): Adjust.
5433 * tracepoint.c (sdata_make_value): Adjust.
5434 * xml-support.c (xinclude_start_include): Adjust.
5435 (xml_fetch_content_from_file): Adjust.
5436 * xml-support.h (xml_fetch_another): Change return type.
5437 (xml_fetch_content_from_file): Change return type.
5438 * xml-syscall.c (xml_init_syscalls_info): Adjust.
5439 * xml-tdesc.c (file_read_description_xml): Adjust.
5440 (fetch_available_features_from_target): Change return type.
5441 (target_fetch_description_xml): Adjust.
5442 (target_read_description_xml): Adjust.
5444 2018-04-06 Tom Tromey <tom@tromey.com>
5446 * value.c (~value): Update.
5447 (struct value) <contents>: Now unique_xmalloc_ptr.
5448 (value_contents_bits_eq, allocate_value_contents)
5449 (value_contents_raw, value_contents_all_raw)
5450 (value_contents_for_printing, value_contents_for_printing_const)
5451 (set_value_enclosing_type): Update.
5453 2018-04-06 Tom Tromey <tom@tromey.com>
5455 * value.c (range_s): Remove typedef, VEC.
5456 (struct range): Add operator<.
5457 (range_lessthan): Remove.
5458 (ranges_contain): Change type.
5460 (struct value) <unavailable, optimized_out>: Now std::vector.
5461 (value_entirely_available)
5462 (value_entirely_covered_by_range_vector)
5463 (value_entirely_unavailable, value_entirely_optimized_out):
5465 (insert_into_bit_range_vector): Change argument type.
5466 (find_first_range_overlap): Likewise.
5467 (struct ranges_and_idx, value_contents_bits_eq)
5468 (require_not_optimized_out, require_available): Update.
5469 (ranges_copy_adjusted): Change argument types.
5470 (value_optimized_out, value_copy, value_fetch_lazy): Update.
5472 2018-04-06 Tom Tromey <tom@tromey.com>
5474 * value.c (~value): Update.
5475 (struct value) <parent>: Now a value_ref_ptr.
5476 (value_parent, set_value_parent, value_address, value_copy):
5479 2018-04-06 Tom Tromey <tom@tromey.com>
5481 * value.c (struct value): Add constructor, destructor, and member
5483 (allocate_value_lazy, value_decref): Update.
5485 2018-04-06 Tom Tromey <tom@tromey.com>
5487 * value.c (struct value) <released, next>: Remove.
5488 (all_values): Now a std::vector.
5489 (allocate_value_lazy): Update.
5490 (value_next): Remove.
5491 (value_mark, value_free_to_mark, release_value)
5492 (value_release_to_mark): Update.
5494 2018-04-06 Tom Tromey <tom@tromey.com>
5496 * value.h (fetch_subexp_value, value_release_to_mark): Update.
5497 (free_value_chain): Remove.
5498 * value.c (free_value_chain): Remove.
5499 (value_release_to_mark): Return a std::vector.
5500 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
5502 (check_condition): Update.
5503 * eval.c (fetch_subexp_value): Change "val_chain" to a
5505 * breakpoint.c (update_watchpoint): Update.
5506 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
5508 2018-04-06 Tom Tromey <tom@tromey.com>
5510 * value.h (free_all_values): Remove.
5511 * value.c (free_all_values): Remove.
5513 2018-04-06 Tom Tromey <tom@tromey.com>
5515 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
5516 (value_history_chain, value_history_count): Remove.
5517 (value_history): New global.
5518 (record_latest_value, access_value_history, show_values)
5519 (preserve_values): Update.
5521 2018-04-06 Tom Tromey <tom@tromey.com>
5523 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
5524 * varobj.c (varobj_set_display_format, varobj_set_value)
5525 (install_default_visualizer, construct_visualizer)
5526 (install_new_value, ~varobj, varobj_get_value_type)
5527 (my_value_of_variable, varobj_editable_p): Update.
5528 * c-varobj.c (c_describe_child, c_value_of_variable)
5529 (cplus_number_of_children, cplus_describe_child): Update.
5530 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
5531 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
5532 (ada_value_of_variable, ada_value_is_changeable_p): Update.
5534 2018-04-06 Tom Tromey <tom@tromey.com>
5536 * printcmd.c (last_examine_address): Change type to
5538 (do_examine, x_command): Update.
5540 2018-04-06 Tom Tromey <tom@tromey.com>
5542 * value.c (release_value): Update.
5543 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
5544 (struct bpstats) <val>: Now a value_ref_ptr.
5545 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
5546 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
5547 (~watchpoint, print_it_watchpoint, watch_command_1)
5548 (invalidate_bp_value_on_memory_change): Update.
5550 2018-04-06 Tom Tromey <tom@tromey.com>
5552 * varobj.c (varobj_clear_saved_item)
5553 (update_dynamic_varobj_children, install_new_value, ~varobj):
5555 * value.h (value_incref): Move declaration earlier.
5556 (value_decref): Rename from value_free.
5557 (struct value_ref_policy): New.
5558 (value_ref_ptr): New typedef.
5559 (struct value_deleter): Remove.
5560 (gdb_value_up): Remove typedef.
5561 (release_value): Change return type.
5562 (release_value_or_incref): Remove.
5563 * value.c (set_value_parent): Update.
5564 (value_incref): Change return type.
5565 (value_decref): Rename from value_free.
5566 (value_free_to_mark, free_all_values, free_value_chain): Update.
5567 (release_value): Return value_ref_ptr.
5568 (release_value_or_incref): Remove.
5569 (record_latest_value, set_internalvar, clear_internalvar):
5571 * stack.c (info_frame_command): Don't call value_free.
5572 * python/py-value.c (valpy_dealloc, valpy_new)
5573 (value_to_value_object): Update.
5574 * printcmd.c (do_examine): Update.
5575 * opencl-lang.c (lval_func_free_closure): Update.
5576 * mi/mi-main.c (register_changed_p): Don't call value_free.
5577 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
5578 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
5579 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
5581 * guile/scm-value.c (vlscm_free_value_smob)
5582 (vlscm_scm_from_value): Update.
5583 * frame.c (frame_register_unwind, frame_unwind_register_signed)
5584 (frame_unwind_register_unsigned, get_frame_register_bytes)
5585 (put_frame_register_bytes): Don't call value_free.
5586 * findvar.c (address_from_register): Don't call value_free.
5587 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
5588 * dwarf2loc.c (entry_data_value_free_closure)
5589 (value_of_dwarf_reg_entry, free_pieced_value_closure)
5590 (dwarf2_evaluate_loc_desc_full): Update.
5591 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
5592 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
5593 (~watchpoint, watch_command_1)
5594 (invalidate_bp_value_on_memory_change): Update.
5595 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
5597 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
5600 * warning.m4: Add -Wno-error=deprecated-register.
5601 * configure: Re-generate.
5603 2018-04-05 Tom Tromey <tom@tromey.com>
5605 * linespec.h: Remove include of "vec.h".
5607 2018-04-05 Tom Tromey <tom@tromey.com>
5609 * linespec.c (typep): Remove typedef.
5610 (find_methods, find_superclass_methods): Take a std::vector.
5611 (find_method): Use std::vector.
5613 2018-04-05 Tom Tromey <tom@tromey.com>
5615 * utils.c (compare_strings): Remove.
5616 * utils.h (compare_strings): Remove.
5617 * objc-lang.h (find_imps): Update.
5618 * objc-lang.c (find_methods): Take a std::vector.
5619 (uniquify_strings, find_imps): Likewise.
5620 * linespec.c (find_methods): Take a std::vector.
5621 (decode_objc): Use std::vector.
5622 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
5624 (find_method, find_function_symbols): Use std::vector.
5626 2018-04-05 Tom Tromey <tom@tromey.com>
5628 * completer.c (completion_tracker::completion_tracker): Remove
5630 (completion_tracker::discard_completions): Likewise.
5631 * breakpoint.c (ambiguous_names_p): Remove cast.
5632 * ada-lang.c (_initialize_ada_language): Remove cast.
5633 * utils.h (streq): Update.
5634 (streq_hash): Add new declaration.
5635 * utils.c (streq): Return bool.
5636 (streq_hash): New function.
5638 2018-04-05 Tom Tromey <tom@tromey.com>
5640 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
5641 Remove a string copy.
5643 2018-04-05 Tom Tromey <tom@tromey.com>
5645 * linespec.c (filter_results): Use std::vector.
5646 (decode_line_2, decode_line_full): Update.
5648 2018-04-05 Tom Tromey <tom@tromey.com>
5650 * linespec.c (canonical_to_fullform): Return std::string.
5651 (filter_results): Update.
5652 (struct decode_line_2_item): Add constructor.
5653 <fullform, displayform>: Now std::string.
5654 (decode_line_2_compare_items): Now a std::sort comparator.
5655 (decode_line_2): Update.
5657 2018-04-05 Tom Tromey <tom@tromey.com>
5659 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
5660 (unexpected_linespec_error): Update.
5661 (linespec_parse_basic, parse_linespec): Update.
5663 2018-04-05 Tom Tromey <tom@tromey.com>
5665 * linespec.c (linespec_parse_basic): Reindent.
5667 2018-04-05 Tom Tromey <tom@tromey.com>
5669 * minsyms.h (iterate_over_minimal_symbols): Update.
5670 * minsyms.c (iterate_over_minimal_symbols): Take a
5672 * linespec.c (struct collect_minsyms): Remove.
5673 (compare_msyms): Now a std::sort comparator.
5674 (add_minsym): Add parameters.
5675 (search_minsyms_for_name): Update. Use std::vector.
5677 2018-04-03 Tom Tromey <tom@tromey.com>
5679 * mipsread.c (read_alphacoff_dynamic_symtab): Use
5682 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
5684 * MAINTAINERS (Write After Approval): Add Weimin Pan.
5686 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
5689 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
5690 printing static type.
5692 2018-04-01 Tom Tromey <tom@tromey.com>
5694 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
5695 (rs6000_xfer_shared_libraries): Update.
5697 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
5699 * common/gdb_vecs.h (char_ptr): Remove.
5700 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
5702 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
5704 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
5706 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
5708 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
5710 * tracepoint.h (struct uploaded_tp): Initialize fields.
5711 <actions, step_actions, cmd_strings>: Change type to
5712 std::vector<char *>.
5713 * tracepoint.c (get_uploaded_tp): Allocate with new.
5714 (free_uploaded_tps): Free with delete.
5715 (parse_tracepoint_definition): Adjust to std::vector change.
5716 * breakpoint.c (read_uploaded_action): Likewise.
5717 (create_tracepoint_from_upload): Likewise.
5718 * ctf.c (ctf_write_uploaded_tp): Likewise.
5719 (SET_ARRAY_FIELD): Likewise.
5720 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
5722 2018-03-30 Tom Tromey <tom@tromey.com>
5724 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
5726 (svr4_keep_data_in_core): Update.
5727 (svr4_read_so_list): Update.
5729 2018-03-30 Tom Tromey <tom@tromey.com>
5731 * windows-nat.c (handle_output_debug_string, handle_exception):
5733 * target.h (target_read_string): Update.
5734 * target.c (target_read_string): Change "string" to
5736 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
5738 * solib-frv.c (frv_current_sos): Update.
5739 * solib-dsbt.c (dsbt_current_sos): Update.
5740 * solib-darwin.c (darwin_current_sos): Update.
5741 * linux-thread-db.c (inferior_has_bug): Update.
5742 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
5743 Update. Remove alloca.
5744 * ada-lang.c (ada_main_name): Update.
5746 2018-03-30 Tom Tromey <tom@tromey.com>
5748 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
5749 (struct dwo_file_deleter): New.
5750 (dwo_file_up): New typedef.
5751 (open_and_init_dwo_file): Use dwo_file_up.
5752 (free_dwo_file_cleanup): Remove.
5754 2018-03-30 Tom Tromey <tom@tromey.com>
5756 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
5757 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
5759 2018-03-30 Tom Tromey <tom@tromey.com>
5761 * dwarf2read.c (class free_cached_comp_units): New class.
5762 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
5763 (free_cached_comp_units): Remove function.
5765 2018-03-30 Tom Tromey <tom@tromey.com>
5767 * utils.h (make_cleanup_unpush_target): Remove.
5768 * inf-ptrace.c (struct target_unpusher): New.
5769 (target_unpush_up) New typedef.
5770 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
5772 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
5774 2018-03-27 Tom Tromey <tom@tromey.com>
5776 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
5778 2018-03-27 Pedro Alves <palves@redhat.com>
5779 Tom Tromey <tom@tromey.com>
5781 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
5782 destructor. Now a class.
5783 (gdb_readline_wrapper_cleanup): Remove function.
5784 (gdb_readline_wrapper): Remove cleanups.
5786 2018-03-27 Tom Tromey <tom@tromey.com>
5788 * typeprint.h (struct type_print_options) <local_typedefs,
5789 global_typedefs>: Remove "struct" keyword.
5790 (class typedef_hash_table): New class.
5791 (recursively_update_typedef_hash, add_template_parameters)
5792 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
5793 (find_typedef_in_hash): Don't declare.
5794 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
5795 (typedef_hash_table::recursively_update): Rename from
5796 recursively_update_typedef_hash. Now a member.
5797 (typedef_hash_table::add_template_parameters): Rename from
5798 add_template_parameters. Now a member.
5799 (typedef_hash_table::typedef_hash_table): Now a constructor;
5800 rename from create_typedef_hash.
5801 (typedef_hash_table::~typedef_hash_table): Now a destructor;
5802 rename from free_typedef_hash.
5803 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
5804 (do_free_global_table): Remove.
5805 (typedef_hash_table::typedef_hash_table): New constructor; renamed
5806 from copy_type_recursive.
5807 (create_global_typedef_table): Remove.
5808 (typedef_hash_table::find_global_typedef): Now a member of
5810 (typedef_hash_table::find_typedef): Rename from
5811 find_typedef_in_hash; now a member.
5812 (whatis_exp): Update.
5813 * extension.h (struct ext_lang_type_printers): Add constructor and
5815 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
5817 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
5818 Now a constructor; rename from start_ext_lang_type_printers.
5819 (ext_lang_type_printers): Now a destructor; rename from
5820 free_ext_lang_type_printers.
5821 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
5823 (c_type_print_base_struct_union): Update. Remove cleanups.
5825 2018-03-27 Tom Tromey <tom@tromey.com>
5827 * dwarf-index-write.c: Include <cmath>.
5829 2018-03-27 Joel Brobecker <brobecker@adacore.com>
5831 * NEWS: Add entry describing new "set|show varsize-limit" command.
5832 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
5834 * printcmd.c (_initialize_printcmd): Add "set var" alias of
5837 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
5839 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
5841 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
5842 * dwarf-index-common.c: New file.
5843 * dwarf-index-common.h: New file.
5844 * dwarf-index-write.c: New file.
5845 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
5846 (struct dwarf2_section_info): Move from here.
5847 (dwarf2_section_info_def): Likewise.
5848 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
5849 (offset_type): Likewise.
5850 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
5851 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
5852 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
5853 (byte_swap): Likewise.
5854 (MAYBE_SWAP): Likewise.
5855 (dwarf2_per_cu_ptr): Likewise.
5856 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
5857 (struct tu_stats): Likewise.
5858 (struct dwarf2_per_objfile): Likewise.
5859 (struct dwarf2_per_cu_data): Likewise.
5860 (struct signatured_type): Likewise.
5861 (sig_type_ptr): Likewise.
5862 (DEF_VEC_P (sig_type_ptr)): Likewise.
5863 (INDEX4_SUFFIX): Likewise.
5864 (INDEX5_SUFFIX): Likewise.
5865 (DEBUG_STR_SUFFIX): Likewise.
5866 (dwarf2_read_section): Make non-static.
5867 (mapped_index_string_hash): Move from here.
5868 (dwarf5_djb_hash): Likewise.
5869 (file_write): Likewise.
5870 (class data_buf): Likewise.
5871 (struct symtab_index_entry): Likewise.
5872 (struct mapped_symtab): Likewise.
5873 (find_slot): Likewise.
5874 (hash_expand): Likewise.
5875 (add_index_entry): Likewise.
5876 (uniquify_cu_indices): Likewise.
5877 (class c_str_view): Likewise.
5878 (class c_str_view_hasher): Likewise.
5879 (class vector_hasher): Likewise.
5880 (write_hash_table): Likewise.
5881 (psym_index_map): Likewise.
5882 (struct addrmap_index_data): Likewise.
5883 (add_address_entry): Likewise.
5884 (add_address_entry_worker): Likewise.
5885 (write_address_map): Likewise.
5886 (symbol_kind): Likewise.
5887 (write_psymbols): Likewise.
5888 (struct signatured_type_index_data): Likewise.
5889 (write_one_signatured_type): Likewise.
5890 (recursively_count_psymbols): Likewise.
5891 (recursively_write_psymbols): Likewise.
5892 (class debug_names): Likewise.
5893 (check_dwarf64_offsets): Likewise.
5894 (psyms_seen_size): Likewise.
5895 (write_gdbindex): Likewise.
5896 (write_debug_names): Likewise.
5897 (assert_file_size): Likewise.
5898 (write_psymtabs_to_index): Likewise.
5899 (save_gdb_index_command): Likewise.
5900 (_initialize_dwarf2_read): Don't register the "save gdb-index"
5902 * dwarf2read.h: New file.
5904 2018-03-27 Joel Brobecker <brobecker@adacore.com>
5907 * dwarf2read.c (dwarf2_physname): Do not return the demangled
5908 symbol name if the CU's language stores symbol names in linkage
5910 * language.h (struct language_defn)
5911 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
5912 all instances of this struct.
5914 2018-03-26 Tom Tromey <tom@tromey.com>
5916 * stack.c (backtrace_command_1): Remove verbose code.
5918 2018-03-26 Tom Tromey <tom@tromey.com>
5920 * python/py-framefilter.c (py_print_type): Don't catch
5921 exceptions. Return void.
5922 (py_print_value): Likewise.
5923 (py_print_single_arg): Likewise.
5924 (enumerate_args): Don't catch exceptions.
5925 (py_print_args): Likewise.
5926 (py_print_frame): Likewise.
5927 (gdbpy_apply_frame_filter): Catch exceptions here.
5929 2018-03-26 Tom Tromey <tom@tromey.com>
5931 * stack.c (_initialize_stack): Remove trailing newlines from help
5932 text. Add "Usage" line to "backtrace" help.
5934 2018-03-26 Tom Tromey <tom@tromey.com>
5937 * python/py-framefilter.c (py_print_args): Call wrap_hint.
5939 2018-03-26 Tom Tromey <tom@tromey.com>
5941 * python/py-framefilter.c (py_print_single_arg): Return
5942 EXT_LANG_BT_ERROR from catch.
5944 2018-03-26 Tom Tromey <tom@tromey.com>
5947 * stack.c (backtrace_command_1): Move some code into no-filters
5950 2018-03-26 Tom Tromey <tom@tromey.com>
5952 * python/py-framefilter.c (throw_quit_or_print_exception): New
5954 (gdbpy_apply_frame_filter): Use it.
5956 2018-03-26 Tom Tromey <tom@tromey.com>
5959 * python/py-framefilter.c (py_print_type, py_print_value)
5960 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
5963 2018-03-26 Tom Tromey <tom@tromey.com>
5965 * python/py-framefilter.c (enumerate_args): Use
5966 gdb::unique_xmalloc_ptr.
5968 2018-03-26 Tom Tromey <tom@tromey.com>
5970 * python/py-framefilter.c (py_print_frame): Return
5972 (gdbpy_apply_frame_filter): Update comment.
5973 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
5975 <EXT_LANG_BT_NO_FILTERS>: Change value.
5977 2018-03-26 Tom Tromey <tom@tromey.com>
5980 * stack.c (backtrace_command): Parse "hide" argument.
5981 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
5982 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
5985 2018-03-26 Tom Tromey <tom@tromey.com>
5987 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
5989 (backtrace_command): Remove "fulltrace", add "flags".
5991 2018-03-26 Tom Tromey <tom@tromey.com>
5993 * stack.c (backtrace_command): Rewrite command line parsing.
5995 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
5997 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
5999 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
6001 * filename-seen-cache.h: Add include guard.
6003 2018-03-26 Keith Seitz <keiths@redhat.com>
6005 * symfile.c (place_section): Remove "struct" from section_addr_info
6007 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
6008 "struct" keyword from section_addr_info.
6010 2018-03-26 Alan Hayward <alan.hayward@arm.com>
6012 * regformats/regdef.h (reg): Add constructors.
6014 2018-03-25 Pedro Alves <palves@redhat.com>
6016 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
6017 if then/else bodies in var_func_name extraction.
6019 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
6021 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
6022 lookup_minimal_symbol() to find symbol entry.
6023 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
6025 2018-03-23 Keith Seitz <keiths@redhat.com>
6028 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
6029 nested type definitions for C++, too.
6031 2018-03-23 Tom Tromey <tom@tromey.com>
6033 * machoread.c (struct oso_el): Add a constructor. Don't define as
6035 (macho_register_oso): Remove.
6036 (macho_symtab_read): Take a std::vector.
6037 (oso_el_compare_name): Now a std::sort comparator.
6038 (macho_symfile_read_all_oso): Take a std::vector.
6039 (macho_symfile_read): Use std::vector. Remove cleanups.
6041 2018-03-22 Tom Tromey <tom@tromey.com>
6043 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
6044 (record_full_goto_bookmark): Use std::string.
6046 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6049 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
6052 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6054 * rs6000-tdep.c (store_insn_p): New function.
6055 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
6056 and cr_reg to their unshifted values. Use store_insn_p to
6057 match LR saves using either R1 or fdata->alloca_reg. Use
6058 store_insn_p to match CR saves. Set alloca_reg_offset
6059 when alloca_reg and framep are set. Remove lr_reg shift
6060 when assigning to fdata->lr_register.
6062 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
6064 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
6065 command line args instead of emitting a warning.
6067 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
6069 * tracepoint.h (struct static_tracepoint_marker): Initialize
6070 fields, define default constructor, move constructor and move
6071 assignment, disable the rest.
6072 <str_id, extra>: Make std::string.
6073 (release_static_tracepoint_marker): Remove.
6074 (free_current_marker): Remove.
6075 * tracepoint.c (free_current_marker): Remove.
6076 (parse_static_tracepoint_marker_definition): Adjust to
6077 std::string, use new hex2str overload.
6078 (release_static_tracepoint_marker): Remove.
6079 (print_one_static_tracepoint_marker): Get marker by reference
6080 and adjust to std::string.
6081 (info_static_tracepoint_markers_command): Adjust to std::vector
6083 * target.h (static_tracepoint_marker_p): Remove typedef.
6084 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
6085 (struct target_ops) <to_static_tracepoint_marker_at>: Return
6087 <to_static_tracepoint_markers_by_strid>: Return std::vector.
6089 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
6090 (target_debug_print_std_vector_static_tracepoint_marker): New.
6091 (target_debug_print_struct_static_tracepoint_marker_p): Rename
6093 (target_debug_print_static_tracepoint_marker_p): ... this.
6094 * target-delegates.c: Re-generate.
6095 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
6097 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
6098 (decode_static_tracepoint_spec): Adjust to std::vector.
6099 (tracepoint_print_one_detail): Adjust to std::string.
6100 (strace_marker_decode_location): Adjust to std::string.
6101 (update_static_tracepoint): Adjust to std::string, remove call
6102 to release_static_tracepoint_marker.
6103 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
6104 Adjust to std::vector.
6105 * remote.c (remote_static_tracepoint_marker_at): Return bool.
6106 (remote_static_tracepoint_markers_by_strid): Adjust to
6108 * common/rsp-low.h (hex2str): New overload with explicit count
6110 * common/rsp-low.c (hex2str): New overload with explicit count
6112 * unittests/rsp-low-selftests.c (test_hex2str): New function.
6113 (_initialize_rsp_low_selftests): Add test_hex2str test.
6114 * unittests/tracepoint-selftests.c
6115 (test_parse_static_tracepoint_marker_definition): Adjust to
6118 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
6120 * tracepoint.c (parse_static_tracepoint_marker_definition):
6121 Consider case where the definition is followed by more
6123 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6124 tracepoint-selftests.c.
6125 * unittests/tracepoint-selftests.c: New.
6127 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6129 * MAINTAINERS (Write After Approval): Add Pedro Franco de
6132 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
6134 * symtab.c (find_pc_sect_line): fixed indentation.
6136 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
6138 * symtab.c (find_pc_sect_line): now uses binary search.
6140 2018-03-19 Tom Tromey <tom@tromey.com>
6142 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
6145 2018-03-19 Pedro Alves <palves@redhat.com>
6146 Tom Tromey <tom@tromey.com>
6148 * unittests/observable-selftests.c: New file.
6149 * common/observable.h: New file.
6150 * observable.h: New file.
6151 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
6152 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
6153 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
6154 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
6155 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
6156 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
6157 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
6158 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
6159 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
6160 python/py-breakpoint.c, python/py-finishbreakpoint.c,
6161 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
6162 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
6163 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
6164 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
6165 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
6166 tui/tui-interp.c, valops.c: Update all users.
6167 * tui/tui-hooks.c (tui_bp_created_observer)
6168 (tui_bp_deleted_observer, tui_bp_modified_observer)
6169 (tui_inferior_exit_observer, tui_before_prompt_observer)
6170 (tui_normal_stop_observer, tui_register_changed_observer):
6172 (tui_observers_token): New global.
6173 (attach_or_detach, tui_attach_detach_observers): New functions.
6174 (tui_install_hooks, tui_remove_hooks): Use
6175 tui_attach_detach_observers.
6176 * record-btrace.c (record_btrace_thread_observer): Remove.
6177 (record_btrace_thread_observer_token): New global.
6178 * observer.sh: Remove.
6179 * observer.c: Rename to observable.c.
6180 * observable.c (namespace gdb_observers): Define new objects.
6181 (observer_debug): Move into gdb_observers namespace.
6182 (struct observer, struct observer_list, xalloc_observer_list_node)
6183 (xfree_observer_list_node, generic_observer_attach)
6184 (generic_observer_detach, generic_observer_notify): Remove.
6185 (_initialize_observer): Update.
6186 Don't include observer.inc.
6187 * Makefile.in (generated_files): Remove observer.h, observer.inc.
6188 (clean mostlyclean): Likewise.
6189 (observer.h, observer.inc): Remove targets.
6190 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
6191 (COMMON_SFILES): Use observable.c, not observer.c.
6192 * .gitignore: Remove observer.h.
6194 2018-03-18 Tom Tromey <tom@tromey.com>
6196 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
6198 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
6200 2018-03-17 Tom Tromey <tom@tromey.com>
6202 * auto-load.c (auto_load_objfile_script_1): Use std::string.
6204 2018-03-17 Tom Tromey <tom@tromey.com>
6206 * target.c (class scoped_target_fd): New.
6207 (target_fileio_close_cleanup): Remove.
6208 (target_fileio_read_alloc_1): Use scoped_target_fd.
6210 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
6212 * silent-rules.mk: New.
6213 * Makefile.in: Include silent-rules.mk
6214 (srcdir, VPATH, top_srcdir): Move up.
6215 (COMPILE): Add ECHO_CXX.
6216 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
6217 (init.c): Add ECHO_INIT_C.
6218 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
6219 (version.c): Add ECHO_GEN.
6220 (printcmd.o): Add ECHO_CXX.
6221 (target-float.o): Add ECHO_CXX.
6222 (ada-exp.o): Add ECHO_CXX.
6223 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
6224 (insight$(EXEEXT)): Add ECHO_CXXLD.
6225 * gnulib/configure.ac: Add AM_SILENT_RULES.
6226 * gnulib/aclocal.m4: Re-generate.
6227 * gnulib/configure: Re-generate.
6228 * gnulib/import/Makefile.in: Re-generate.
6230 2018-03-16 Tom Tromey <tom@tromey.com>
6232 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
6233 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
6234 * utils.c (do_free_section_addr_info)
6235 (make_cleanup_free_section_addr_info): Remove.
6236 * symfile.h (struct other_sections): Add constructor.
6237 (struct section_addr_info): Remove.
6238 (section_addr_info): New typedef.
6239 (struct sym_fns) <sym_offsets>: Change type of parameter.
6240 (build_section_addr_info_from_objfile)
6241 (relative_addr_info_to_section_offsets, addr_info_make_relative)
6242 (default_symfile_offsets, symbol_file_add)
6243 (symbol_file_add_from_bfd)
6244 (build_section_addr_info_from_section_table): Update.
6245 (alloc_section_addr_info, free_section_addr_info): Don't declare.
6246 * symfile.c (alloc_section_addr_info): Remove.
6247 (build_section_addr_info_from_section_table): Change return type.
6249 (build_section_addr_info_from_bfd)
6250 (build_section_addr_info_from_objfile): Likewise.
6251 (free_section_addr_info): Remove.
6252 (relative_addr_info_to_section_offsets): Change type of "addrs".
6253 (addrs_section_compar): Now a std::sort comparator.
6254 (addrs_section_sort): Change return type.
6255 (addr_info_make_relative): Change type of "addrs". Update.
6256 (default_symfile_offsets, syms_from_objfile_1)
6257 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
6258 (symbol_file_add_separate): Update.
6259 (symbol_file_add): Change type of "addrs". Update.
6260 (add_symbol_file_command): Update. Remove cleanups.
6261 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
6263 * symfile-debug.c (debug_sym_offsets): Change type of "info".
6264 * solib.c (solib_read_symbols): Update.
6265 * objfiles.c (objfile_relocate): Update. Remove cleanups.
6266 * machoread.c (macho_symfile_offsets): Update.
6267 * jit.c (jit_bfd_try_read_symtab): Update.
6269 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
6271 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6272 unittests/utils-selftests.c.
6273 * unittests/utils-selftests.c: New file.
6275 2018-03-14 Tom Tromey <tom@tromey.com>
6278 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
6281 2018-03-14 Tom Tromey <tom@tromey.com>
6284 * printcmd.c (printf_pointer): Allow "-" in format.
6286 2018-03-14 Tom Tromey <tom@tromey.com>
6288 * printcmd.c (_initialize_printcmd): Add usage to printf.
6290 2018-03-14 Yao Qi <qiyao@sourceware.org>
6292 * MAINTAINERS: Update my email address.
6294 2018-03-13 Tom Tromey <tom@tromey.com>
6296 * machoread.c (macho_check_dsym): Change filenamep to a
6298 (macho_symfile_read): Update.
6299 * symfile.c (load_command): Use std::string.
6301 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
6303 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
6304 to error message string.
6305 (riscv_register_name): Use xsnprintf instead of sprintf.
6306 (riscv_insn::fetch_instruction): Use gdb_assert instead of
6308 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
6310 (riscv_push_dummy_call): Likewise.
6312 2018-03-12 Tom Tromey <tom@tromey.com>
6314 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
6315 Use gdb::byte_vector.
6316 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
6318 2018-03-12 Yao Qi <yao.qi@linaro.org>
6320 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
6321 parameter type to readable_regcache.
6322 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
6325 2018-03-11 Tom Tromey <tom@tromey.com>
6327 * dwarf2read.c (struct nextfield): Add initializers.
6328 (struct nextfnfield): Remove.
6329 (struct fnfieldlist): Add initializers. Remove "length" and
6330 "head", use std::vector.
6331 (struct decl_field_list): Remove.
6332 (struct field_info): Add initializers.
6333 <fields, baseclasses>: Now std::vector.
6334 <nbaseclasses, nfnfields, typedef_field_list_count,
6335 nested_types_list_count>: Remove.
6336 (dwarf2_add_field, dwarf2_add_type_defn)
6337 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
6338 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
6339 (process_structure_scope): Update.
6341 2018-03-11 Tom Tromey <tom@tromey.com>
6343 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
6344 for use by std::sort.
6345 (build_type_psymtabs_1): Use std::vector.
6347 2018-03-09 Eli Zaretskii <eliz@gnu.org>
6349 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
6350 and LIBMPFR in the printed configuration.
6352 2018-03-08 Tom Tromey <tom@tromey.com>
6354 * source.c (get_filename_and_charpos): Use scoped_fd.
6355 * nto-procfs.c (procfs_open_1): Use scoped_fd.
6356 (procfs_pidlist): Likewise.
6357 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
6358 (iterate_over_mappings): Likewise.
6360 2018-03-08 Tom Tromey <tom@tromey.com>
6362 * infcall.c (struct call_return_meta_info)
6363 <stack_temporaries_enabled>: Remove.
6364 (get_call_return_value, call_function_by_hand_dummy): Update.
6365 * thread.c (disable_thread_stack_temporaries): Remove.
6366 (enable_thread_stack_temporaries): Remove.
6367 (thread_stack_temporaries_enabled_p): Return bool.
6368 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
6369 (get_last_thread_stack_temporary): Update.
6370 * eval.c (evaluate_subexp): Update.
6371 * gdbthread.h (class enable_thread_stack_temporaries): Now a
6372 class, not a function.
6373 (value_ptr, value_vec): Remove typedefs.
6374 (class thread_info) <stack_temporaries_enabled>: Now bool.
6375 <stack_temporaries>: Now a std::vector.
6376 (thread_stack_temporaries_enabled_p)
6377 (value_in_thread_stack_temporaries): Return bool.
6379 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
6381 * remote.c (putpkt_binary): Fix omitted bytes reporting.
6382 (getpkt_or_notif_sane_1): Likewise.
6384 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
6386 * build-id.c (build_id_to_debug_bfd): Use std::string.
6388 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
6390 * build-id.c (find_separate_debug_file_by_buildid): Return
6392 * build-id.h (find_separate_debug_file_by_buildid): Return
6394 * coffread.c (coff_symfile_read): Adjust to std::string.
6395 * elfread.c (elf_symfile_read): Adjust to std::string.
6396 * symfile.c (separate_debug_file_exists): Change parameter to
6398 (find_separate_debug_file): Return std::string.
6399 (find_separate_debug_file_by_debuglink): Return std::string.
6400 * symfile.h (find_separate_debug_file_by_debuglink): Return
6403 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
6405 * common/xml-utils.c (xml_escape_text): Move code to...
6406 (xml_escape_text_append): ... this new function.
6407 * common/xml-utils.h (xml_escape_text_append): New declaration.
6408 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
6410 (_initialize_xml_utils): register test_xml_escape_text_append as
6413 2018-03-07 Alan Hayward <alan.hayward@arm.com>
6415 * defs.h: Remove MAX_REGISTER_SIZE.
6416 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
6418 * python/py-unwind.c (pyuw_sniffer): Likewise.
6420 2018-03-07 Tom Tromey <tom@tromey.com>
6422 * linux-tdep.c (linux_info_proc): Update.
6423 * target.h (struct target_ops) <to_fileio_readlink>: Return
6425 (target_fileio_readlink): Return optional<string>.
6426 * remote.c (remote_hostio_readlink): Return optional<string>.
6427 * inf-child.c (inf_child_fileio_readlink): Return
6429 * target.c (target_fileio_readlink): Return optional<string>.
6431 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
6433 * regcache.c (cooked_read_test): Add riscv to the list of
6434 architectures that have a save_reggroup.
6436 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
6438 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
6439 value is not a dynamic class object.
6441 2018-03-06 Tom Tromey <tom@tromey.com>
6443 * rust-exp.y: Formatting fixes.
6445 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
6447 * riscv-tdep.c (riscv_register_name): Remove target description
6449 (riscv_gdbarch_init): Remove target description check.
6451 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
6453 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
6455 * riscv-tdep.h: Likewise.
6457 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
6459 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
6460 (riscv_pseudo_register_write): Delete.
6461 (riscv_gdbarch_init): Remove all use of pseudo registers.
6463 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
6465 * record-btrace.c (btrace_print_lines): Replace cleanup
6466 parameter with RAII equivalents.
6467 (btrace_insn_history): Replace cleanup with RAII equivalents.
6468 * ui-out.h (make_cleanup_ui_out_list_begin_end,
6469 make_cleanup_ui_out_tuple_begin_end): Remove.
6470 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
6471 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
6472 make_cleanup_ui_out_list_begin_end): Remove.
6474 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
6476 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
6477 parameter types to std::vector. Use bool.
6478 (record_btrace_wait): Replace VEC(tp_t) with
6479 std::vector<thread_info *>.
6480 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
6482 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
6484 * record-btrace.c (record_btrace_disable_callback): Remove.
6485 (struct scoped_btrace_disable): New.
6486 (record_btrace_open): Use scoped_btrace_disable.
6488 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
6490 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
6491 reading values from registers.
6493 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
6495 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
6498 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
6500 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
6501 change parameter type. Use GDB's print functions, and use
6502 core_addr_to_string where appropriate.
6503 (riscv_push_dummy_call): Use core_addr_to_string where
6504 appropriate, update call to riscv_print_arg_location, and reindent
6506 (riscv_return_value): Update call to riscv_print_arg_location.
6508 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
6509 Tim Newsome <tim@sifive.com>
6510 Albert Ou <a0u@eecs.berkeley.edu>
6511 Darius Rad <darius@bluespec.com>
6513 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
6514 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
6515 (ALLDEPFILES): Add riscv-tdep.c
6516 * configure.tgt: Add riscv support.
6517 * riscv-tdep.c: New file.
6518 * riscv-tdep.h: New file.
6519 * NEWS: Mention new target.
6520 * MAINTAINERS: Add entry for riscv.
6522 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
6524 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
6525 fields within aggregates.
6527 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
6529 * record-btrace.c (btrace_print_lines): Change type of flags to
6530 gdb_disassembly_flags.
6532 2018-03-04 John Baldwin <jhb@FreeBSD.org>
6534 * fbsd-nat.c: Include "inf-ptrace.h".
6535 (USE_SIGTRAP_SIGINFO): Conditionally define.
6536 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
6537 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
6538 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
6540 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
6542 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
6544 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
6545 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
6546 "supports_stopped_by_hw_breakpoint" target methods.
6548 2018-03-04 John Baldwin <jhb@FreeBSD.org>
6550 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
6551 * fbsd-nat.c (debug_fbsd_nat): New variable.
6552 (show_fbsd_nat_debug): New function.
6553 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
6554 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
6556 2018-03-04 John Baldwin <jhb@FreeBSD.org>
6558 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
6559 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
6561 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
6562 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
6565 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
6567 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
6568 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
6570 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
6572 * charset.c (struct charset_vector): New.
6573 (charsets): Change type to charset_vector.
6574 (find_charset_names): Adjust.
6576 (_initialize_charset): Adjust.
6578 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
6580 * progspace.h (struct program_space) <deleted_solibs>: Change
6581 type to std::vector<std::string>.
6582 * progspace.c (clear_program_space_solib_cache): Adjust.
6583 * breakpoint.c (print_solib_event): Adjust.
6584 (check_status_catch_solib): Adjust.
6585 * solib.c (update_solib_list): Adjust.
6586 * ui-out.h (class ui_out) <field_string>: New overload.
6587 * ui-out.c (ui_out::field_string): New overload.
6589 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
6591 * progspace.h (struct program_space): Add constructor and
6592 destructor, initialize fields.
6593 (add_program_space): Remove.
6594 * progspace.c (add_program_space): Rename to...
6595 (program_space::program_space): ... this.
6596 (release_program_space): Rename to...
6597 (program_space::~program_space): ... this.
6598 (delete_program_space): Use delete to delete program_space.
6599 (initialize_progspace): Use new to allocate program_space.
6600 * inferior.c (add_inferior_with_spaces): Likewise.
6601 (clone_inferior_command): Likewise.
6602 * infrun.c (follow_fork_inferior): Likewise.
6603 (handle_vfork_child_exec_or_exit): Likewise.
6605 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
6607 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
6608 (delim_string_to_char_ptr_vec): Return std::vector of
6609 gdb::unique_xmalloc_ptr.
6610 (dirnames_to_char_ptr_vec_append): Take std::vector of
6611 gdb::unique_xmalloc_ptr.
6612 (dirnames_to_char_ptr_vec): Return std::vector of
6613 gdb::unique_xmalloc_ptr.
6614 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
6615 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
6616 (delim_string_to_char_ptr_vec): Return an std::vector of
6617 gdb::unique_xmalloc_ptr, adjust the code.
6618 (dirnames_to_char_ptr_vec_append): Take an std::vector of
6619 gdb::unique_xmalloc_ptr, adjust the code.
6620 (dirnames_to_char_ptr_vec): Return an std::vector of
6621 gdb::unique_xmalloc_ptr, adjust the code.
6622 * auto-load.c (auto_load_safe_path_vec): Change type to
6623 std::vector of gdb::unique_xmalloc_ptr.
6624 (auto_load_expand_dir_vars): Return an std::vector of
6625 gdb::unique_xmalloc_ptr, adjust the code.
6626 (auto_load_safe_path_vec_update): Adjust.
6627 (filename_is_in_auto_load_safe_path_vec): Adjust.
6628 (auto_load_objfile_script_1): Adjust.
6629 * build-id.c (build_id_to_debug_bfd): Adjust.
6630 * linux-thread-db.c (thread_db_load_search): Adjust.
6631 * source.c (add_path): Adjust.
6633 * symfile.c (find_separate_debug_file): Adjust.
6634 * utils.c (do_free_char_ptr_vec): Remove.
6635 (make_cleanup_free_char_ptr_vec): Remove.
6637 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
6640 * common/pathstuff.c: Conditionally include "<windows.h>".
6642 2018-03-01 Georg Sauthoff <mail@georg.so>
6645 * gcore.in: Quote variables and switch interpreter to bash.
6647 2018-03-01 Tom Tromey <tom@tromey.com>
6649 * dwarf2read.c (alloc_discriminant_info): Fix default_index
6650 assertion. Add assertion for discriminant_index.
6651 (quirk_rust_enum): Use correct base type name in univariant case.
6653 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
6655 * record.c (get_call_history_modifiers): Return a
6657 (cmd_record_call_history): Adjust.
6658 * record-btrace.c (record_btrace_call_history): Adjust.
6659 (record_btrace_call_history_range): Adjust.
6660 (record_btrace_call_history_from): Adjust.
6661 * target-debug.h (target_debug_print_record_print_flags): New.
6662 * target-delegates.c: Re-generate.
6663 * target.c (target_call_history): Change flags type.
6664 (target_call_history_from): Likewise.
6665 (target_call_history_range): Likewise.
6666 * target.h (struct target_ops) <target_call_history>: Likewise.
6667 (target_call_history_from): Likewise.
6668 (target_call_history_range): Likewise.
6670 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
6671 Simon Marchi <simon.marchi@polymtl.ca>
6673 * common/common-utils.c: Include "sys/stat.h".
6674 (is_regular_file): Move here from "source.c"; change return
6676 * common/common-utils.h (is_regular_file): New prototype.
6677 * common/pathstuff.c (contains_dir_separator): New function.
6678 * common/pathstuff.h (contains_dir_separator): New prototype.
6679 * source.c: Don't include "sys/stat.h".
6680 (is_regular_file): Move to "common/common-utils.c".
6682 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
6684 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
6685 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
6686 * auto-load.c: Include "common/pathstuff.h".
6687 * common/common-def.h (current_directory): Move here.
6688 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
6690 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
6692 * common/pathstuff.c: New file.
6693 * common/pathstuff.h: New file.
6694 * compile/compile.c: Include "common/pathstuff.h".
6695 * defs.h (current_directory): Move to "common/common-defs.h".
6696 * dwarf2read.c: Include "common/pathstuff.h".
6698 * guile/scm-safe-call.c: Likewise.
6699 * linux-thread-db.c: Likewise.
6701 * nto-tdep.c: Likewise.
6702 * objfiles.c: Likewise.
6703 * source.c: Likewise.
6704 * symtab.c: Likewise.
6705 * utils.c: Include "common/pathstuff.h".
6706 (gdb_realpath): Move to "common/pathstuff.c".
6707 (gdb_realpath_keepfile): Likewise.
6708 (gdb_abspath): Likewise.
6709 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
6710 (gdb_realpath_keepfile): Likewise.
6711 (gdb_abspath): Likewise.
6713 2018-02-28 John Baldwin <jhb@FreeBSD.org>
6715 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
6716 wildcard process pid for super_resume for kernels with a
6719 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
6721 * compile/compile.c (get_args): Add additional comments
6722 explaining function.
6724 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
6725 Tom Tromey <tom@tromey.com>
6727 * target.h (memory_write_request_s): Remove typedef. Don't define
6729 (target_write_memory_blocks): Change argument to std::vector.
6730 (struct memory_write_request): Add constructor.
6731 * target-memory.c (compare_block_starting_address): Return bool.
6732 Change argument types.
6733 (claim_memory): Change arguments to use std::vector.
6734 (split_regular_and_flash_blocks, blocks_to_erase)
6735 (compute_garbled_blocks): Likewise.
6736 (cleanup_request_data, cleanup_write_requests_vector): Remove.
6737 (target_write_memory_blocks): Change argument to std::vector.
6738 * symfile.c (struct load_section_data): Add constructor and
6739 destructor. Use std::vector for "requests".
6740 (struct load_progress_data): Add initializers.
6741 (load_section_callback): Update. Use "new".
6742 (clear_memory_write_data): Remove.
6743 (generic_load): Update.
6745 2018-02-27 Alan Hayward <alan.hayward@arm.com>
6747 * arch/aarch64.h: Use common/tdesc.h.
6749 2018-02-26 Maciej W. Rozycki <macro@mips.com>
6751 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
6752 architecture with a 64-bit ABI.
6754 2018-02-26 Maciej W. Rozycki <macro@mips.com>
6756 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
6757 ahead of target description loading.
6759 2018-02-26 Tom Tromey <tom@tromey.com>
6761 * stack.c (backtrace_command_1): Update.
6762 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
6764 * python/py-framefilter.c (py_print_frame)
6765 (gdbpy_apply_frame_filter): Change type of "flags".
6766 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
6768 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
6769 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
6770 * extension.h (enum frame_filter_flag): Rename from
6772 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
6773 (apply_ext_lang_frame_filter): Change type of "flags".
6774 * extension.c (apply_ext_lang_frame_filter): Change type of
6776 * extension-priv.h (struct extension_language_ops)
6777 <apply_frame_filter>: Change type of "flags".
6779 2018-02-26 Tom Tromey <tom@tromey.com>
6782 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
6783 off-by-one in py_end computation.
6784 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
6786 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
6789 2018-02-26 Tom Tromey <tom@tromey.com>
6791 * dwarf2read.c (struct variant_field): New.
6792 (struct nextfield) <variant>: New field.
6793 (dwarf2_add_field): Handle DW_TAG_variant_part.
6794 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
6795 discriminated union.
6796 (read_structure_type): Handle DW_TAG_variant_part.
6797 (handle_struct_member_die): New function, extracted from
6798 process_structure_scope. Handle DW_TAG_variant.
6799 (process_structure_scope): Handle discriminated unions. Call
6800 handle_struct_member_die.
6802 2018-02-26 Tom Tromey <tom@tromey.com>
6804 * rust-lang.h (rust_last_path_segment): Declare.
6805 * rust-lang.c (rust_last_path_segment): Now public. Change
6807 (struct disr_info): Remove.
6808 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
6809 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
6810 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
6811 (rust_enum_p, rust_enum_variant): New function.
6812 (rust_underscore_fields): Remove "offset" parameter.
6813 (rust_print_enum): New function.
6814 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
6815 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
6816 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
6818 (rust_internal_print_type): New function, from rust_print_type.
6820 (rust_print_type): Call rust_internal_print_type.
6821 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
6822 Update enum handling.
6823 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
6824 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
6825 (rust_union_quirks): New functions.
6826 (process_full_comp_unit, process_full_type_unit): Call
6828 (process_structure_scope): Update rust_unions if necessary.
6830 2018-02-26 Tom Tromey <tom@tromey.com>
6832 * value.h (value_union_variant): Declare.
6833 * valops.c (value_union_variant): New function.
6834 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
6835 (struct discriminant_info): New.
6836 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
6838 (struct main_type) <flag_discriminated_union>: New field.
6840 2018-02-26 Tom Tromey <tom@tromey.com>
6842 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6843 unittests/unpack-selftests.c.
6844 * unittests/unpack-selftests.c: New file.
6845 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
6847 2018-02-26 Yao Qi <yao.qi@linaro.org>
6849 * dwarf2read.c (struct partial_die_info) <read>: New method.
6850 (read_partial_die): Remove the declaration.
6851 (load_partial_dies): Update.
6852 (partial_die_info::partial_die_info):
6853 (read_partial_die): Change it to partial_die_info::read.
6855 2018-02-26 Yao Qi <yao.qi@linaro.org>
6857 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
6858 (fixup_partial_die): Remove declaration.
6859 (scan_partial_symbols): Update.
6860 (partial_die_parent_scope): Likewise.
6861 (partial_die_full_name): Likewise.
6862 (fixup_partial_die): Change it to partial_die_info::fixup.
6864 2018-02-26 Yao Qi <yao.qi@linaro.org>
6866 * dwarf2read.c (read_partial_die): Update the declaration.
6867 (load_partial_dies): Caller update.
6868 (read_partial_die): Remove one argument abbrev_len.
6870 2018-02-26 Yao Qi <yao.qi@linaro.org>
6872 * dwarf2read.c (struct partial_die_info): Add ctor, delete
6873 assignment operator.
6874 (load_partial_dies): Use ctor and copy ctor.
6875 (read_partial_die): Update.
6876 (dwarf2_cu::find_partial_die): Use ctor.
6878 2018-02-26 Yao Qi <yao.qi@linaro.org>
6880 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
6881 (find_partial_die_in_comp_unit): Change it to
6882 dwarf2_cu::find_partial_die.
6883 (find_partial_die): Update.
6885 2018-02-26 Yao Qi <yao.qi@linaro.org>
6887 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
6890 2018-02-26 Yao Qi <yao.qi@linaro.org>
6892 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
6894 2018-02-26 Alan Hayward <alan.hayward@arm.com>
6896 * arch/amd64.h: Use common/tdesc.h.
6897 * arch/i386.c: Likewise.
6898 * arch/i386.h: Likewise.
6899 * arch/tic6x.c: Likewise.
6900 * arch/tdesc.h: Move file from here...
6901 * common/tdesc.h: ...to here.
6902 * features/aarch64-core.c: Regenerate.
6903 * features/aarch64-fpu.c: Regenerate.
6904 * features/i386/32bit-avx.c: Regenerate.
6905 * features/i386/32bit-avx512.c: Regenerate.
6906 * features/i386/32bit-core.c: Regenerate.
6907 * features/i386/32bit-linux.c: Regenerate.
6908 * features/i386/32bit-mpx.c: Regenerate.
6909 * features/i386/32bit-pkeys.c: Regenerate.
6910 * features/i386/32bit-sse.c: Regenerate.
6911 * features/i386/64bit-avx.c: Regenerate.
6912 * features/i386/64bit-avx512.c: Regenerate.
6913 * features/i386/64bit-core.c: Regenerate.
6914 * features/i386/64bit-linux.c: Regenerate.
6915 * features/i386/64bit-mpx.c: Regenerate.
6916 * features/i386/64bit-pkeys.c: Regenerate.
6917 * features/i386/64bit-segments.c: Regenerate.
6918 * features/i386/64bit-sse.c: Regenerate.
6919 * features/i386/x32-core.c: Regenerate.
6920 * features/tic6x-c6xp.c: Regenerate.
6921 * features/tic6x-core.c: Regenerate.
6922 * features/tic6x-gp.c: Regenerate.
6923 * target-descriptions.c: Use common/tdesc.h.
6924 * target-descriptions.h: Likewise.
6926 2018-02-24 Tom Tromey <tom@tromey.com>
6928 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
6929 (try_thread_db_load_from_dir, thread_db_load_search): Use
6931 (info_auto_load_libthread_db_compare): Return bool. Change
6933 (info_auto_load_libthread_db): Use std::vector, std::string.
6936 2018-02-24 Tom Tromey <tom@tromey.com>
6938 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
6940 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
6942 * gdbarch.c: Rebuild.
6943 * gdbarch.h: Rebuild.
6944 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
6945 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
6946 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
6949 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
6951 * gdbtypes.h (sect_offset): Change type to uint64_t.
6952 (sect_offset_str): New function.
6953 * dwarf2read.c (create_addrmap_from_aranges): Use
6955 (error_check_comp_unit_head): Likewise.
6956 (create_debug_type_hash_table): Likewise.
6957 (read_cutu_die_from_dwo): Likewise.
6958 (init_cutu_and_read_dies): Likewise.
6959 (init_cutu_and_read_dies_no_follow): Likewise.
6960 (process_psymtab_comp_unit_reader): Likewise.
6961 (partial_die_parent_scope): Likewise.
6962 (peek_die_abbrev): Likewise.
6963 (process_queue): Likewise.
6964 (dwarf2_physname): Likewise.
6965 (read_namespace_alias): Likewise.
6966 (read_import_statement): Likewise.
6967 (create_dwo_cu_reader): Likewise.
6968 (create_cus_hash_table): Likewise.
6969 (lookup_dwo_cutu): Likewise.
6970 (inherit_abstract_dies): Likewise.
6971 (read_func_scope): Likewise.
6972 (read_call_site_scope): Likewise.
6973 (dwarf2_add_member_fn): Likewise.
6974 (read_common_block): Likewise.
6975 (read_module_type): Likewise.
6976 (read_typedef): Likewise.
6977 (read_subrange_type): Likewise.
6978 (load_partial_dies): Likewise.
6979 (read_partial_die): Likewise.
6980 (find_partial_die): Likewise.
6981 (read_str_index): Likewise.
6982 (dwarf2_string_attr): Likewise.
6983 (build_error_marker_type): Likewise.
6984 (lookup_die_type): Likewise.
6985 (dump_die_shallow): Likewise.
6986 (follow_die_ref): Likewise.
6987 (dwarf2_fetch_die_loc_sect_off): Likewise.
6988 (dwarf2_fetch_constant_bytes): Likewise.
6989 (follow_die_sig): Likewise.
6990 (get_signatured_type): Likewise.
6991 (get_DW_AT_signature_type): Likewise.
6992 (dwarf2_find_containing_comp_unit): Likewise.
6993 (set_die_type): Likewise.
6995 2018-02-21 John Baldwin <jhb@FreeBSD.org>
6997 * arch/aarch64.c: Include "common-defs.h".
6998 * arch/amd64.c: Likewise.
6999 * arch/i386.c: Likewise.
7001 2018-02-21 Tom Tromey <tom@tromey.com>
7003 * value.h: (extract_field_op): Update.
7004 * eval.c (extract_field_op): Return a const char *.
7005 * expression.h (parse_expression_for_completion): Update.
7006 * completer.c (complete_expression): Update.
7007 (add_struct_fields): Make fieldname const.
7008 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
7009 (mark_completion_tag, parse_exp_in_context_1): Update.
7010 (parse_expression_for_completion): Change "name" to
7011 unique_xmalloc_ptr*.
7013 2018-02-21 Tom Tromey <tom@tromey.com>
7015 * infcall.c (call_function_by_hand_dummy): Use std::vector.
7017 2018-02-21 Yao Qi <yao.qi@linaro.org>
7019 * avr-tdep.c (avr_read_pc): Change parameter type to
7021 * gdbarch.sh (read_pc): Likewise.
7022 * gdbarch.c: Re-generated.
7023 * gdbarch.h: Re-generated.
7024 * hppa-tdep.c (hppa_read_pc): Change parameter type to
7026 * ia64-tdep.c (ia64_read_pc): Likewise.
7027 * mips-tdep.c (mips_read_pc): Likewise.
7028 * spu-tdep.c (spu_read_pc): Likewise.
7030 2018-02-21 Yao Qi <yao.qi@linaro.org>
7032 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
7033 * regcache-dump.c: New file.
7034 * regcache.c: Move register_dump to regcache-dump.c.
7035 (maintenance_print_registers): Likewise.
7036 (maintenance_print_raw_registers): Likewise.
7037 (maintenance_print_cooked_registers): Likewise.
7038 (maintenance_print_register_groups): Likewise.
7039 (maintenance_print_remote_registers): Likewise.
7040 (_initialize_regcache): Likewise.
7041 * regcache.h (register_dump): Moved from regcache.c.
7043 2018-02-21 Yao Qi <yao.qi@linaro.org>
7045 * regcache.c (regcache::regcache): Update.
7046 (regcache::invalidate): Move it to detached_regcache::invalidate.
7047 (get_thread_arch_aspace_regcache): Update.
7048 (regcache::raw_update): Update.
7049 (regcache::cooked_read): Remove some code.
7050 (regcache::cooked_read_value): Likewise.
7051 (regcache::raw_write): Remove assert on m_readonly_p.
7052 (regcache::raw_supply_integer): Move it to
7053 detached_regcache::raw_supply_integer.
7054 (regcache::raw_supply_zeroed): Likewise.
7055 * regcache.h (detached_regcache) <raw_supply_integer>: New
7057 <raw_supply_zeroed, invalidate>: Likewise.
7058 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
7059 <invalidate>: Likewise.
7060 <m_readonly_p>: Removed.
7062 2018-02-21 Yao Qi <yao.qi@linaro.org>
7064 * infcmd.c (get_return_value): Let stop_regs point to
7065 get_current_regcache.
7066 * regcache.c (regcache::regcache): Remove.
7067 (register_dump_reg_buffer): New class.
7068 (regcache_print): Adjust.
7069 * regcache.h (regcache): Remove constructors.
7071 2018-02-21 Yao Qi <yao.qi@linaro.org>
7073 * regcache.c (class register_dump): New class.
7074 (register_dump_regcache, register_dump_none): New class.
7075 (register_dump_remote, register_dump_groups): New class.
7076 (regcache_print): Update.
7077 * regcache.h (regcache_dump_what): Move it to regcache.c.
7078 (regcache) <dump>: Remove.
7080 2018-02-21 Yao Qi <yao.qi@linaro.org>
7082 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
7084 (jit_unwind_reg_set_impl): Call raw_supply.
7085 (jit_frame_sniffer): Use reg_buffer_rw.
7086 * record-full.c (record_full_core_regbuf): Change its type.
7087 (record_full_core_open_1): Use reg_buffer_rw.
7088 (record_full_close): Likewise.
7089 (record_full_core_fetch_registers): Use regcache->raw_supply.
7090 (record_full_core_store_registers): Likewise.
7091 * regcache.c (regcache::get_register_status): Move it to
7093 (regcache_raw_set_cached_value): Remove.
7094 (regcache::raw_set_cached_value): Remove.
7095 (regcache::raw_write): Call raw_supply.
7096 (regcache::raw_supply): Move it to reg_buffer_rw.
7097 * regcache.h (regcache_raw_set_cached_value): Remove.
7098 (reg_buffer_rw): New class.
7100 2018-02-21 Yao Qi <yao.qi@linaro.org>
7102 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
7103 readonly_detached_regcache.
7104 (dummy_frame_prev_register): Use regcache->cooked_read.
7105 * frame.c (frame_save_as_regcache): Change return type.
7106 (frame_pop): Update.
7107 * frame.h (frame_save_as_regcache): Update declaration.
7108 * inferior.h (get_infcall_suspend_state_regcache): Update
7110 * infrun.c (infcall_suspend_state) <registers>: use
7111 readonly_detached_regcache.
7112 (save_infcall_suspend_state): Don't use regcache_dup.
7113 (get_infcall_suspend_state_regcache): Change return type.
7114 * linux-fork.c (struct fork_info) <savedregs>: Change to
7115 readonly_detached_regcache.
7117 (fork_save_infrun_state): Don't use regcache_dup.
7118 (info_checkpoints_command): Adjust.
7119 * mi/mi-main.c (register_changed_p): Update declaration.
7120 (mi_cmd_data_list_changed_registers): Use
7121 readonly_detached_regcache.
7122 (register_changed_p): Change parameter type to
7123 readonly_detached_regcache.
7124 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
7125 readonly_detached_regcache.
7126 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
7127 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
7129 (regcache::save): Move it to reg_buffer.
7130 (regcache::restore): Change parameter type.
7131 (regcache_dup): Remove.
7132 * regcache.h (reg_buffer) <save>: New method.
7133 (readonly_detached_regcache): New class.
7134 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
7135 readonly_detached_regcache.
7136 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
7138 2018-02-21 Yao Qi <yao.qi@linaro.org>
7140 * frame.c (frame_save_as_regcache): Use regcache method save.
7141 (frame_pop): Use regcache method restore.
7142 * infrun.c (restore_infcall_suspend_state): Likewise.
7143 * linux-fork.c (fork_load_infrun_state): Likewise.
7144 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
7146 * regcache.c (regcache_save): Remove.
7147 (regcache::restore): More asserts.
7148 (regcache_cpy): Remove.
7149 * regcache.h (regcache_save): Remove the declaration.
7150 (regcache::restore): Move from private to public.
7151 Remove the friend declaration of regcache_cpy.
7152 (regcache_cpy): Remove declaration.
7154 2018-02-21 Yao Qi <yao.qi@linaro.org>
7156 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
7157 parameter type to 'readable_regcache *'.
7158 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
7159 * arm-tdep.c (arm_neon_quad_read): Likewise.
7160 (arm_pseudo_read): Likewise.
7161 * avr-tdep.c (avr_pseudo_register_read): Likewise.
7162 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
7163 * frv-tdep.c (frv_pseudo_register_read): Likewise.
7164 * gdbarch.c: Re-generated.
7165 * gdbarch.h: Re-generated.
7166 * gdbarch.sh (pseudo_register_read): Change parameter type to
7167 'readable_regcache *'.
7168 (pseudo_register_read_value): Likewise.
7169 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
7170 (h8300_pseudo_register_read): Likewise.
7171 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
7172 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
7173 (i386_pseudo_register_read_into_value): Likewise.
7174 (i386_pseudo_register_read_value): Likewise.
7175 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
7177 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
7178 * m32c-tdep.c (m32c_raw_read): Likewise.
7179 (m32c_read_flg): Likewise.
7180 (m32c_banked_register): Likewise.
7181 (m32c_banked_read): Likewise.
7182 (m32c_sb_read): Likewise.
7183 (m32c_part_read): Likewise.
7184 (m32c_cat_read): Likewise.
7185 (m32c_r3r2r1r0_read): Likewise.
7186 (m32c_pseudo_register_read): Likewise.
7187 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
7188 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
7189 (mep_pseudo_cr64_read): Likewise.
7190 (mep_pseudo_register_read): Likewise.
7191 * mips-tdep.c (mips_pseudo_register_read): Likewise.
7192 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
7193 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
7194 * regcache.c (regcache::raw_read): Move it to readable_regcache.
7195 (regcache::cooked_read): Likewise.
7196 (regcache::cooked_read_value): Likewise.
7197 (regcache_cooked_read_signed):
7198 (regcache::cooked_read): Likewise.
7199 * regcache.h (readable_regcache): New class.
7200 (regcache): Inherit readable_regcache. Move some methods to
7202 * rl78-tdep.c (rl78_pseudo_register_read): Change
7203 parameter type to 'readable_regcache *'.
7204 * rs6000-tdep.c (do_regcache_raw_read): Remove.
7205 (e500_pseudo_register_read): Change parameter type to
7206 'readable_regcache *'.
7207 (dfp_pseudo_register_read): Likewise.
7208 (vsx_pseudo_register_read): Likewise.
7209 (efpr_pseudo_register_read): Likewise.
7210 * s390-tdep.c (s390_pseudo_register_read): Likewise.
7211 * sh-tdep.c (sh_pseudo_register_read): Likewise.
7212 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
7213 (sh64_pseudo_register_read): Likewise.
7214 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
7215 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
7216 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
7217 (spu_pseudo_register_read): Likewise.
7218 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
7219 (xtensa_pseudo_register_read): Likewise.
7221 2018-02-21 Yao Qi <yao.qi@linaro.org>
7223 * regcache.c (regcache::regcache): Call reg_buffer ctor.
7224 (regcache::arch): Move it to reg_buffer::arch.
7225 (regcache::register_buffer): Likewise.
7226 (regcache::assert_regnum): Likewise.
7227 (regcache::num_raw_registers): Likewise.
7228 * regcache.h (reg_buffer): New class.
7229 (regcache): Inherit reg_buffer.
7231 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
7233 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
7234 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
7236 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
7238 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
7240 2018-02-19 Alan Hayward <alan.hayward@arm.com>
7242 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
7243 (SFILES): Remove common/*.c files.
7244 (COMMON_OBS): Remove some *.o files built from common/*.c files.
7245 * common/common.host: Add common reference.
7246 * configure.ac: Likewise.
7247 * configure: Regenerate.
7249 2018-02-16 Yao Qi <yao.qi@linaro.org>
7251 * block.c (block_namespace_info): Inherit allocate_on_obstack.
7252 (block_initialize_namespace): Use new.
7253 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
7254 (dwarf2_free_objfile): Use delete.
7255 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
7256 (copy_type_recursive): Use new.
7257 * gdb_obstack.h (allocate_on_obstack): New.
7259 2018-02-15 Yao Qi <yao.qi@linaro.org>
7262 * inferior.c (exit_inferior_1): Reset inf->control.
7264 2018-02-15 Joel Brobecker <brobecker@adacore.com>
7266 * ada-lang.c (ada_to_fixed_value_create): Delete advance
7269 2018-02-14 Pedro Alves <palves@redhat.com>
7271 * frame-unwind.c (frame_unwind_try_unwinder): Always call
7272 frame_cleanup_after_sniffer on exception.
7274 2018-02-14 Tom Tromey <tom@tromey.com>
7276 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
7278 (solib_bfd_open): Make pathname const.
7279 * solib.c (solib_bfd_open): Make pathname const.
7280 * solib-spu.c (spu_bfd_fopen): Make name const.
7281 (spu_bfd_open): Make pathname const.
7282 * solib-darwin.c (darwin_bfd_open): Make pathname const.
7283 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
7285 2018-02-14 Tom Tromey <tom@tromey.com>
7287 * symfile.c (symfile_bfd_open): Update.
7288 * source.h (openp, source_full_path_of, find_and_open_source):
7289 Change argument type to unique_xmalloc_ptr.
7290 * source.c (openp): Take a unique_xmalloc_ptr.
7291 (source_full_path_of, find_and_open_source): Likewise.
7292 (open_source_file, symtab_to_fullname): Update.
7293 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
7295 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
7296 (exec_file_find): Update.
7297 * psymtab.c (psymtab_to_fullname): Update.
7298 * nto-tdep.h (nto_find_and_open_solib): Update.
7299 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
7301 * exec.c (exec_file_attach): Update.
7302 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
7303 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
7305 2018-02-14 Tom Tromey <tom@tromey.com>
7307 * solib.c: Include source.h.
7308 * nto-tdep.c: Include source.h.
7309 * mi/mi-cmd-env.c: Include source.h.
7310 * infcmd.c: Include source.h.
7311 * exec.c: Include source.h.
7312 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
7313 (add_path, directory_switch, source_path, init_source_path): Move
7315 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
7316 (add_path, directory_switch, source_path, init_source_path):
7319 2018-02-14 Tom Tromey <tom@tromey.com>
7321 * solist.h (exec_file_find, solib_find): Return
7323 (solib_bfd_fopen): Take a const char *.
7324 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
7325 (exec_file_find, solib_find): Likewise.
7326 (solib_bfd_fopen): Do not take ownership of "pathname".
7327 (solib_bfd_open): Use unique_xmalloc_ptr.
7328 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
7329 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
7330 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
7331 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
7333 2018-02-14 Joel Brobecker <brobecker@adacore.com>
7335 * ada-lang.c (name_match_type_from_name): Remove reference to
7336 ada_name_for_lookup in function's documentation.
7337 * ada-lang.h (ada_name_for_lookup): Delete declaration.
7339 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
7341 * defs.h (enum openp_flags): New enum.
7342 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
7343 Move to enum openp_flags.
7344 (openp_flags): New enum flags.
7345 (openp): Change parameter type to openp_flags.
7346 * source.c (openp): Change parameter type to openp_flags.
7347 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
7348 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
7350 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
7352 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
7355 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
7357 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
7359 (class dwarf2_queue_guard): ...the destructor of this new class.
7360 (dw2_do_instantiate_symtab): Create instance of the new class
7361 dwarf2_queue_guard, remove cleanup.
7363 2018-02-09 Tom Tromey <tom@tromey.com>
7365 * source.c (find_source_lines): Don't reference past the end of
7368 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
7370 * remote.c (remote_btrace_maybe_reopen): Change error message.
7371 * btrace.c (btrace_enable): Likewise.
7372 (parse_xml_btrace): Likewise.
7373 (parse_xml_btrace_conf): Likewise.
7375 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
7377 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
7378 (linux_enable_pt, linux_enable_bts): Call
7379 diagnose_perf_event_open_fail.
7381 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
7383 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
7384 Remove parameter and change return type. Update callers. Move it.
7385 (linux_enable_bts, linux_enable_pt): Improve error message.
7386 (linux_enable_pt): Remove zero buffer size check.
7387 (linux_enable_btrace): Improve error messages. Remove NULL return
7390 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
7392 * btrace.c (btrace_enable): Remove target_supports_btrace call.
7393 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
7394 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
7395 (linux_supports_pt, linux_supports_btrace): Remove.
7396 (linux_enable_bts): Call cpu_supports_bts.
7397 * nat/linux-btrace.h (linux_supports_btrace): Remove.
7398 * remote.c (remote_supports_btrace): Remove.
7399 (init_remote_ops): Remove remote_supports_btrace.
7400 * target-delegates.c: Regenerated.
7401 * target.c (target_supports_btrace): Remove.
7402 * target.h (target_ops) <to_supports_btrace>: Remove
7403 (target_supports_btrace): Remove.
7404 * x86-linux-nat.c (x86_linux_create_target): Remove
7405 linux_supports_btrace.
7407 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
7409 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
7411 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
7412 exception and use message in own exception.
7414 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
7416 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
7417 (perf_event_pt_event_type): Use gdb_file_up.
7418 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
7419 scoped_fd, and scoped_mmap.
7421 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
7423 * common/scoped_mmap.h: New.
7424 * unittests/scoped_mmap-selftest.c: New.
7425 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7426 unittests/scoped_mmap-selftest.c.
7428 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
7430 * common/scoped_fd.h: New.
7431 * unittests/scoped_fd-selftest.c: New.
7432 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7433 unittests/scoped_fd-selftest.c.
7435 2018-02-09 Tom Tromey <tom@tromey.com>
7437 * auto-load.c (auto_load_section_scripts): Use
7438 gdb::unique_xmalloc_ptr.
7440 2018-02-09 Tom Tromey <tom@tromey.com>
7442 * auto-load.c (execute_script_contents): Use std::string.
7444 2018-02-09 Joel Brobecker <brobecker@adacore.com>
7446 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
7447 Python function, rather than a new command.
7449 2018-02-08 Tom Tromey <tom@tromey.com>
7451 * solib.c (solib_find_1): Use std::string.
7452 (solib_bfd_fopen): Use unique_xmalloc_ptr.
7454 2018-02-08 Tom Tromey <tom@tromey.com>
7456 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
7458 2018-02-08 Tom Tromey <tom@tromey.com>
7460 * source.c (find_source_lines): Use gdb::def_vector.
7462 2018-02-08 Tom Tromey <tom@tromey.com>
7464 * macrocmd.c (struct temporary_macro_definition): New.
7465 (macro_define_command): Use temporary_macro_definition. Remove
7467 (free_macro_definition_ptr): Remove.
7469 2018-02-08 Tom Tromey <tom@tromey.com>
7471 * macroexp.c (maybe_expand): Use std::string.
7473 2018-02-08 Tom Tromey <tom@tromey.com>
7475 * macroexp.c (struct macro_buffer): Add initializers for some
7477 (init_buffer, init_shared_buffer, free_buffer)
7478 (free_buffer_return_text): Remove.
7479 (macro_buffer): New constructors.
7480 (~macro_buffer): New destructor.
7481 (macro_buffer::set_shared): New method.
7482 (macro_buffer::resize_buffer, macro_buffer::appendc)
7483 (macro_buffer::appendmem): Now methods, not free functions.
7484 (set_token, append_tokens_without_splicing, stringify)
7485 (macro_stringify): Update.
7486 (gather_arguments): Change return type. Remove argc_p argument,
7487 add args_ptr argument. Use std::vector.
7488 (substitute_args): Remove argc argument. Accept std::vector.
7489 (expand): Update. Use std::vector.
7490 (scan, macro_expand, macro_expand_next): Update.
7492 2018-02-08 Tom Tromey <tom@tromey.com>
7494 * symtab.c (default_collect_symbol_completion_matches_break_on):
7495 Use unique_xmalloc_ptr.
7496 * macroscope.h: (sal_macro_scope, user_macro_scope)
7497 (default_macro_scope): Return unique_xmalloc_ptr.
7498 * macroscope.c (sal_macro_scope, user_macro_scope)
7499 (default_macro_scope): Return unique_xmalloc_ptr.
7500 * macroexp.h (macro_expand, macro_expand_once): Return
7502 * macroexp.c (macro_expand, macro_expand_once): Return
7504 * macrocmd.c (macro_expand_command, macro_expand_once_command)
7505 (info_macro_command, info_macros_command): Use
7507 * compile/compile-c-support.c (write_macro_definitions): Use
7509 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
7511 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
7513 * value.c (value_static_field): Assign field type instead of
7514 containing type when returning an optimized out value.
7516 2018-02-06 Yao Qi <yao.qi@linaro.org>
7518 * ft32-tdep.c (ft32_read_pc): Remove.
7519 (ft32_write_pc): Remove.
7520 (ft32_gdbarch_init): Update.
7521 * m32r-tdep.c (m32r_read_pc): Remove.
7522 (m32r_gdbarch_init): Update.
7523 * mep-tdep.c (mep_read_pc): Remove.
7524 (mep_gdbarch_init): Update.
7525 * microblaze-tdep.c (microblaze_write_pc): Remove.
7526 (microblaze_gdbarch_init): Update.
7527 * mn10300-tdep.c (mn10300_read_pc): Remove.
7528 (mn10300_write_pc): Remove.
7529 (mn10300_gdbarch_init): Update.
7530 * moxie-tdep.c (moxie_read_pc): Remove.
7531 (moxie_write_pc): Remove.
7532 (moxie_gdbarch_init): Update.
7534 2018-02-06 Yao Qi <yao.qi@linaro.org>
7536 * expprint.c (print_subexp_standard): Handle
7537 OP_F77_UNDETERMINED_ARGLIST.
7538 (dump_subexp_body_standard): Likewise.
7540 2018-02-05 Alan Hayward <alan.hayward@arm.com>
7542 * target-descriptions.c (tdesc_element_visitor) Add empty
7544 (tdesc_type): Move make_gdb_type from here.
7545 (tdesc_type_builtin): Likewise.
7546 (tdesc_type_vector): Likewise.
7547 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
7548 (make_gdb_type_struct): Move from tdesc_type_with_fields.
7549 (make_gdb_type_union): Likewise.
7550 (make_gdb_type_flags): Likewise.
7551 (make_gdb_type_enum): Likewise.
7552 (make_gdb_type): New function.
7553 (tdesc_register_type): Use static make_gdb_type.
7555 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
7557 * infcmd.c (default_print_one_register_info): Align natural-format
7558 column values consistently one under another.
7559 (pad_to_column): New function.
7561 2018-02-05 Joel Brobecker <brobecker@adacore.com>
7563 * dwarf2read.c (dwarf2_physname): Move commment.
7565 2018-02-01 Leszek Swirski <leszeks@google.com>
7567 * varobj.c (varobj_formatted_print_options): Allow recursive
7568 pretty printing if pretty printing is enabled.
7570 2018-02-01 Leszek Swirski <leszeks@google.com>
7572 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
7573 names after a structop as a filename.
7575 2018-02-01 Yao Qi <yao.qi@linaro.org>
7577 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
7578 (arm_record_coproc_data_proc): Likewise.
7580 2018-02-01 Yao Qi <yao.qi@linaro.org>
7582 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
7584 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
7586 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
7587 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
7589 2018-01-31 Pedro Alves <palves@redhat.com>
7591 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
7592 * inflow.c (child_terminal_save_inferior): Wrap reference to
7593 tcgetpgrp in HAVE_TERMIOS_H.
7594 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
7596 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
7597 always iterate over all inferiors.
7598 (gdbsim_cntrl_c): Adjust.
7599 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
7601 2018-01-31 Joel Brobecker <brobecker@adacore.com>
7603 * gdbtypes.c (lookup_array_range_type): Make sure the array's
7604 index type is objfile-owned if the element type is as well.
7606 2018-01-31 Joel Brobecker <brobecker@adacore.com>
7610 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
7612 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
7613 "features/s390x-linux64.c".
7614 (_initialize_s390_linux_tdep): Remove initialization of tdescs
7615 s390_linux32 and s390x_linux64.
7616 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
7618 * s390-tdep.c: Include "features/s390-linux32.c" and
7619 "features/s390x-linux64.c".
7620 (s390_tdesc_valid): Add check for tdesc_has_registers.
7621 (s390_gdbarch_init): Make sure there is always a valid tdesc.
7622 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
7623 tdesc_s390x_linux64.
7624 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
7625 tdesc_s390x_linux64 to...
7626 * s390-tdep.h: ...here.
7628 2018-01-30 Pedro Alves <palves@redhat.com>
7631 * config.in, configure: Regenerate.
7632 * configure.ac: Check for getpgid.
7633 * go32-nat.c (go32_pass_ctrlc): New.
7634 (go32_target): Install it.
7635 * inf-child.c (inf_child_target): Install
7636 child_terminal_save_inferior, child_pass_ctrlc and
7638 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
7639 (inf_ptrace_target): No longer install it.
7640 * infcmd.c (interrupt_target_1): Adjust.
7641 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
7642 (child_interrupt): Declare.
7643 (inferior::terminal_state): New.
7644 * inflow.c (struct terminal_info): Update comments.
7645 (inferior_process_group): Delete.
7646 (terminal_is_ours): Delete.
7647 (gdb_tty_state): New.
7648 (child_terminal_init): Adjust.
7649 (is_gdb_terminal, sharing_input_terminal_1)
7650 (sharing_input_terminal): New functions.
7651 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
7652 Set the process's actual process group in the foreground if
7653 possible. Handle is_ours_for_output/is_ours distinction. Don't
7654 mark terminal as the inferior's if not sharing GDB's terminal.
7655 Don't check attach_flag.
7656 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
7657 pass down a target_terminal_state.
7658 (child_terminal_save_inferior): New, factored out from ...
7659 (child_terminal_ours_1): ... this. Handle
7660 target_terminal_state::is_ours_for_output.
7661 (child_interrupt, child_pass_ctrlc): New.
7662 (inflow_inferior_exit): Clear the inferior's terminal_state.
7663 (copy_terminal_info): Copy the inferior's terminal state.
7664 (_initialize_inflow): Remove reference to terminal_is_ours.
7665 * inflow.h (inferior_process_group): Delete.
7666 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
7667 * procfs.c (procfs_target): Don't install procfs_interrupt.
7668 (procfs_interrupt): Delete.
7669 * remote.c (remote_serial_quit_handler): Adjust.
7670 (remote_interrupt): Remove ptid parameter. Adjust.
7671 * target-delegates.c: Regenerate.
7672 * target.c: Include "terminal.h".
7673 (target_terminal::terminal_state): Rename to ...
7674 (target_terminal::m_terminal_state): ... this.
7675 (target_terminal::init): Adjust.
7676 (target_terminal::inferior): Adjust to per-inferior
7678 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
7679 (target_terminal::ours, target_terminal::ours_for_output): Use
7680 target_terminal_is_ours_kind.
7681 (target_interrupt): Remove ptid parameter. Adjust.
7682 (default_target_pass_ctrlc): Adjust.
7683 * target.h (target_ops::to_terminal_save_inferior): New field.
7684 (target_ops::to_interrupt): Remove ptid_t parameter.
7685 (target_interrupt): Remove ptid_t parameter. Update comment.
7686 (target_pass_ctrlc): Update comment.
7687 * target/target.h (target_terminal_state): New scoped enum,
7689 (target_terminal::terminal_state): ... here.
7690 (target_terminal::inferior): Update comments.
7691 (target_terminal::restore_inferior): New.
7692 (target_terminal::is_inferior, target_terminal::is_ours)
7693 (target_terminal::is_ours_for_output): Adjust.
7694 (target_terminal::scoped_restore_terminal_state): Adjust to
7695 rename, and call restore_inferior() instead of inferior().
7696 (target_terminal::scoped_restore_terminal_state::m_state): Change
7698 (target_terminal::terminal_state): Rename to ...
7699 (target_terminal::m_terminal_state): ... this and change type.
7701 2018-01-30 Pedro Alves <palves@redhat.com>
7703 * linux-nat.c (wait_for_signal): New function.
7704 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
7706 (async_terminal_is_ours)
7707 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
7708 (linux_nat_add_target): Don't override
7709 to_terminal_inferior/to_terminal_ours.
7711 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
7713 * remote.c (remote_follow_fork): Don't call "detach_inferior".
7715 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
7717 * dwarf2read.c (free_dwo_files): Add forward-declaration.
7718 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
7719 dwarf2_per_objfile_free here.
7720 (dwarf2_per_objfile_free): Remove.
7721 (_initialize_dwarf2_read): Don't register
7722 dwarf2_per_objfile_free as a registry cleanup.
7724 2018-01-27 Eli Zaretskii <eliz@gnu.org>
7726 Avoid compilation errors in MinGW native builds
7728 The error is triggered by including python-internal.h, and the
7731 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
7732 from build-gnulib/import/math.h:27,
7733 from d:/usr/Python26/include/pyport.h:235,
7734 from d:/usr/Python26/include/Python.h:58,
7735 from python/python-internal.h:94,
7736 from python/py-arch.c:24:
7737 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
7741 This happens because Python headers define 'hypot' to expand t
7742 '_hypot' in the Windows builds.
7743 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
7744 'hypoth'. This avoids a compilation error.
7746 2018-01-26 Alan Hayward <alan.hayward@arm.com>
7748 * MAINTAINERS (Write After Approval): Fix ordering.
7750 2018-01-26 Alan Hayward <alan.hayward@arm.com>
7752 * MAINTAINERS (Write After Approval): Add Alan Hayward.
7754 2018-01-26 Alan Modra <amodra@gmail.com>
7756 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
7757 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
7758 Remove nop. Make const. Comment.
7759 (powerpc32_plt_stub_so_2): New.
7760 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
7761 Correct count. Update uses.
7762 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
7763 Move common code reading PLT entry word. Correct
7764 powerpc32_plt_stub PLT address calculation.
7765 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
7766 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
7767 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
7768 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
7769 (ppc64_standard_linkage8): Likewise.
7770 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
7771 Correct insns description.
7772 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
7774 2018-01-24 Pedro Alves <palves@redhat.com>
7776 GCC PR libstdc++/83906
7777 * gdbtypes.c (operator==(const dynamic_prop &,
7778 const dynamic_prop &)): New.
7779 (operator==(const range_bounds &, const range_bounds &)): New.
7780 (check_types_equal): Use them instead of memcmp.
7781 * gdbtypes.h (operator==(const dynamic_prop &,
7782 const dynamic_prop &)): Declare.
7783 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
7784 (operator==(const range_bounds &, const range_bounds &)): Declare.
7785 (operator!=(const range_bounds &, const range_bounds &)): Declare.
7787 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
7789 * s390-linux-tdep.c (s390_record_address_mask)
7790 (s390_record_calc_disp_common, s390_record_calc_disp)
7791 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
7792 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
7793 (s390_process_record): Move to s390-tdep.c.
7794 (s390_linux_init_abi_any): Adjust.
7795 * s390-tdep.c (s390_record_address_mask)
7796 (s390_record_calc_disp_common, s390_record_calc_disp)
7797 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
7798 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
7799 (s390_process_record): Moved from s390-linux-tdep.c
7800 (s390_gdbarch_init): Adjust.
7802 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
7804 * s390-linux-nat.c (s390-tdep.h): New include.
7805 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
7806 (HFILES_NO_SRCDIR): Add s390-tdep.h.
7807 (ALLDEPFILES): Add s390-tdep.c.
7808 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
7809 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
7810 * s390-tdep.h: ...this. New file.
7811 * s390-linux-tdep.c (s390-tdep.h): New include.
7812 (_initialize_s390_tdep): Rename to...
7813 (_initialize_s390_linux_tdep): ...this and adjust.
7814 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
7815 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
7817 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
7818 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
7819 (s390_is_partial_instruction, s390_software_single_step)
7820 (is_non_branch_ril, s390_displaced_step_copy_insn)
7821 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
7822 (s390_prologue_data, s390_addr, s390_store, s390_load)
7823 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
7824 (s390_register_call_saved, s390_guess_tracepoint_registers)
7825 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
7826 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
7827 (s390_pseudo_register_name, s390_pseudo_register_type)
7828 (s390_pseudo_register_read, s390_pseudo_register_write)
7829 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
7830 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
7831 (s390_addr_bits_remove, s390_address_class_type_flags)
7832 (s390_address_class_type_flags_to_name)
7833 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
7834 (s390_function_arg_float, s390_function_arg_vector)
7835 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
7836 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
7837 (s390_frame_align, s390_register_return_value, s390_return_value)
7838 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
7839 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
7840 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
7841 (s390_trad_frame_prev_register, s390_unwind_cache)
7842 (s390_prologue_frame_unwind_cache)
7843 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
7844 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
7845 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
7846 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
7847 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
7848 (s390_frame_base_address, s390_local_base_address)
7849 (s390_frame_base, s390_gcc_target_options)
7850 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
7851 (s390_validate_reg_range, s390_tdesc_valid)
7852 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
7853 * s390-tdep.c: ...this. New file.
7855 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
7857 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
7858 (s390_process_record, s390_gdbarch_tdep_alloc)
7859 (s390_linux_init_abi_any): Use/set new hook.
7861 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
7863 * s390-linux-tdep.c (osabi.h): New include.
7864 (s390_linux_init_abi_31, s390_linux_init_abi_64)
7865 (s390_linux_init_abi_any): New functions.
7866 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
7868 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
7870 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
7871 tdesc_has_registers check
7873 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
7875 * s390-linux-tdep.c (s390_tdesc_valid): New function.
7876 (s390_validate_reg_range): New macro.
7877 (s390_gdbarch_init): Adjust.
7879 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
7881 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
7882 (s390_gdbarch_tdep_alloc): Adjust.
7883 (s390_gdbarch_init): Adjust.
7885 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
7887 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
7888 <have_tdb>: Change type to bool.
7889 (s390_gdbarch_tdep_alloc): Adjust.
7890 (s390_gdbarch_init): Adjust.
7892 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
7894 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
7895 (gdbarch_tdep) <have_upper, have_vx>: New fields.
7896 (s390_gdbarch_tdep_alloc): New function.
7897 (s390_gdbarch_init): Allocate tdep at start and use its fields
7898 instead of separate variables.
7900 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
7902 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
7903 when looking for cached gdbarch and add comment for remaining.
7905 2018-01-22 Pedro Alves <palves@redhat.com>
7906 Sergio Durigan Junior <sergiodj@redhat.com>
7908 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
7911 2018-01-22 Maciej W. Rozycki <macro@mips.com>
7913 * MAINTAINERS: Update my company e-mail address.
7915 2018-01-22 Yao Qi <yao.qi@linaro.org>
7917 * regcache.c (cooked_write_test): New function.
7918 (_initialize_regcache): Register the test.
7920 2018-01-22 Yao Qi <yao.qi@linaro.org>
7922 * ia64-tdep.c (ia64_pseudo_register_read): Call
7923 regcache->cooked_read instead of regcache_cooked_read_unsigned.
7924 * m32c-tdep.c (m32c_cat_read): Likewise.
7925 (m32c_r3r2r1r0_read): Likewise.
7926 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
7927 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
7929 2018-01-22 Yao Qi <yao.qi@linaro.org>
7931 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
7932 method raw_read instead of regcache_raw_read.
7933 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
7934 * arm-tdep.c (arm_neon_quad_read): Likewise.
7935 * avr-tdep.c (avr_pseudo_register_read): Likewise.
7936 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
7937 * frv-tdep.c (frv_pseudo_register_read): Likewise.
7938 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
7939 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
7940 (i386_pseudo_register_read_into_value): Likewise.
7941 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
7942 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
7943 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
7944 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
7945 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
7946 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
7947 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
7948 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
7949 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
7951 2018-01-22 Yao Qi <yao.qi@linaro.org>
7953 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
7954 * configure.tgt: Remove target mt.
7955 * mt-tdep.c: Remove.
7956 * regcache.c (cooked_read_test): Remove the check for mt.
7958 2018-01-22 Yao Qi <yao.qi@linaro.org>
7960 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
7961 instead of gdbarch_pseudo_register_read_value.
7963 2018-01-22 Joel Brobecker <brobecker@adacore.com>
7965 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
7968 2018-01-22 Joel Brobecker <brobecker@adacore.com>
7970 * linespec.c (create_sals_line_offset): Remove code that preserved
7971 the symtab_and_line's line number.
7973 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
7975 * varobj.c (varobj_create): Don't set valid_block when creating a
7978 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
7980 * varobj.c (varobj_create): Remove out of date comment.
7982 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
7985 * ada-exp.y (write_var_from_sym): Pass extra parameter when
7986 updating innermost block.
7987 * parse.c (innermost_block_tracker::update): Take extra type
7988 parameter, and check types match before updating innermost block.
7989 (write_dollar_variable): Update innermost block for registers.
7990 * parser-defs.h (enum innermost_block_tracker_type): New enum.
7991 (innermost_block_tracker::innermost_block_tracker): Initialise
7993 (innermost_block_tracker::reset): Take type parameter.
7994 (innermost_block_tracker::update): Take type parameter, and pass
7995 type through as needed.
7996 (innermost_block_tracker::m_types): New member.
7997 * varobj.c (varobj_create): Pass type when reseting innermost
8000 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
8002 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
8003 * ada-lang.c (resolve_subexp): Likewise.
8004 * breakpoint.c (set_breakpoint_condition) Likewise.
8005 (watch_command_1) Likewise.
8006 * c-exp.y (variable): Likewise.
8007 * d-exp.y (PrimaryExpression): Likewise.
8008 * f-exp.y (variable): Likewise.
8009 * go-exp.y (variable): Likewise.
8010 * m2-exp.y (variable): Likewise.
8011 * objfiles.c (objfile::~objfile): Likewise.
8012 * p-exp.y (variable): Likewise.
8013 * parse.c (innermost_block): Change type.
8014 * parser-defs.h (class innermost_block_tracker): New.
8015 (innermost_block): Change to innermost_block_tracker.
8016 * printcmd.c (display_command): Switch to innermost_block API.
8017 (do_one_display): Likewise.
8018 * rust-exp.y (do_one_display): Likewise.
8019 * symfile.c (clear_symtab_users): Likewise.
8020 * varobj.c (varobj_create): Switch to innermost_block API, replace
8021 use of innermost_block with block stored on varobj object.
8023 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
8025 * expression.h (innermost_block): Remove declaration.
8026 * varobj.c: Add 'parser-defs.h' include.
8028 2018-01-19 Tom Tromey <tom@tromey.com>
8030 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
8031 symbols in the static and global blocks.
8033 2018-01-19 James Clarke <jrtc27@jrtc27.com>
8035 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
8036 gdb_ptrace.h, and move including gdb_wait.h ...
8037 * nat/linux-ptrace.h: ... to here.
8039 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
8041 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
8042 inf_ptrace_detach_success.
8043 (inf_ptrace_detach_success): Add inferior parameter, use it
8044 instead of inferior_ptid, pass it to detach_inferior.
8045 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
8047 * inferior.c (detach_inferior): Add overload that takes an
8049 * inferior.h (detach_inferior): Likewise.
8050 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
8051 use inferior_ptid, adjust call to inf_ptrace_detach_success.
8052 * linux-thread-db.c (thread_db_detach): Use inf parameter.
8054 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
8056 * target.h (struct target_ops) <to_detach>: Add inferior
8058 (target_detach): Likewise.
8059 * target.c (dispose_inferior): Pass inferior down.
8060 (target_detach): Pass inferior down. Assert that it is equal to
8061 the current inferior.
8062 * aix-thread.c (aix_thread_detach): Pass inferior down.
8063 * corefile.c (core_file_command): Pass current_inferior() down.
8064 * corelow.c (core_detach): Add inferior parameter.
8065 * darwin-nat.c (darwin_detach): Likewise.
8066 * gnu-nat.c (gnu_detach): Likewise.
8067 * inf-ptrace.c (inf_ptrace_detach): Likewise.
8068 * infcmd.c (detach_command): Pass current_inferior() down to
8070 * infrun.c (follow_fork_inferior): Pass parent_inf to
8072 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
8074 * linux-nat.c (linux_nat_detach): Add inferior parameter.
8075 * linux-thread-db.c (thread_db_detach): Likewise.
8076 * nto-procfs.c (procfs_detach): Likewise.
8077 * procfs.c (procfs_detach): Likewise.
8078 * record.c (record_detach): Likewise.
8079 * record.h (struct inferior): Forward-declare.
8080 (record_detach): Add inferior parameter.
8081 * remote-sim.c (gdbsim_detach): Likewise.
8082 * remote.c (remote_detach_1): Likewise.
8083 (remote_detach): Likewise.
8084 (extended_remote_detach): Likewise.
8085 * sol-thread.c (sol_thread_detach): Likewise.
8086 * target-debug.h (target_debug_print_inferior_p): New macro.
8087 * target-delegates.c: Re-generate.
8088 * top.c (kill_or_detach): Pass inferior down to target_detach.
8089 * windows-nat.c (windows_detach): Add inferior parameter.
8091 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
8093 * target.h (struct target_ops) <to_detach>: Remove args
8095 (target_detach): Likewise.
8096 * target.c (dispose_inferior): Adjust.
8097 (target_detach): Remove args parameter, adjust.
8098 * aix-thread.c (aix_thread_detach): Adjust.
8099 * corefile.c (core_file_command): Adjust.
8100 * corelow.c (core_detach): Adjust.
8101 * darwin-nat.c (darwin_detach): Adjust.
8102 * gnu-nat.c (gnu_detach): Adjust.
8103 * inf-ptrace.c (inf_ptrace_detach): Adjust.
8104 * infcmd.c (detach_command): Adjust
8105 * infrun.c (follow_fork_inferior): Adjust.
8106 (handle_vfork_child_exec_or_exit): Adjust.
8107 * linux-fork.c (linux_fork_detach): Remove args parameter.
8108 * linux-fork.h (linux_fork_detach): Likewise.
8109 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
8110 * linux-thread-db.c (thread_db_detach): Likewise.
8111 * nto-procfs.c (procfs_detach): Likewise.
8112 * procfs.c (procfs_detach): Likewise.
8113 (do_detach): Remove signo parameter.
8114 * record.c (record_detach): Remove args parameter.
8115 * record.h (record_detach): Likewise.
8116 * remote-sim.c (gdbsim_detach): Likewise.
8117 * remote.c (remote_detach_1): Likewise.
8118 (remote_detach): Likewise.
8119 (extended_remote_detach): Likewise.
8120 * sol-thread.c (sol_thread_detach): Likewise.
8121 * target-delegates.c: Re-generate.
8122 * top.c (struct qt_args) <args>: Remove field.
8123 (kill_or_detach): Don't pass args.
8124 (quit_force): Don't set args.
8125 * windows-nat.c (windows_detach): Remove args parameter.
8127 2018-01-19 Yao Qi <yao.qi@linaro.org>
8129 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
8130 (arm_linux_init_abi): Install it.
8132 2018-01-19 Yao Qi <yao.qi@linaro.org>
8134 * osabi.c (gdb_osabi_names): Extend the regexp for
8135 arm-linux-gnueabihf.
8137 2018-01-18 Yao Qi <yao.qi@linaro.org>
8139 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
8141 (abbrev_table::add_abbrev): Update.
8142 (abbrev_table::lookup_abbrev): Update.
8144 2018-01-18 Yao Qi <yao.qi@linaro.org>
8146 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
8148 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
8150 * compile/compile.c (compile_to_object): Convert "triplet_rx"
8153 2018-01-17 Tom Tromey <tom@tromey.com>
8155 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
8157 2018-01-17 Tom Tromey <tom@tromey.com>
8159 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
8160 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
8161 (create_array_type_with_stride): Update.
8162 * dwarf2read.c (set_die_type): Update.
8164 2018-01-17 Tom Tromey <tom@tromey.com>
8166 * dwarf2read.c (delayed_method_info): Remove typedef.
8167 (dwarf2_cu::method_info): Now a std::vector.
8168 (add_to_method_list): Update.
8169 (free_delayed_list): Remove.
8170 (compute_delayed_physnames): Update.
8171 (process_full_comp_unit, process_full_type_unit): Clear the method
8172 list. Remove cleanups.
8173 (psymtab_include_file_name): Add name_holder parameter. Use
8175 (dwarf_decode_lines): Update.
8177 2018-01-17 Tom Tromey <tom@tromey.com>
8178 Simon Marchi <simon.marchi@ericsson.com>
8180 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
8181 (dwarf2_per_objfile::free_cached_comp_units)
8182 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
8183 (init_cutu_and_read_dies_no_follow): Update.
8184 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
8185 (dwarf2_cu::~dwarf2_cu): New.
8186 (free_heap_comp_unit, free_stack_comp_unit): Remove.
8187 (age_cached_comp_units, free_one_cached_comp_unit): Update.
8189 2018-01-17 Tom Tromey <tom@tromey.com>
8190 Simon Marchi <simon.marchi@ericsson.com>
8192 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
8193 (struct die_reader_specs) <abbrev_table>: New member.
8194 (struct abbrev_table): Add constructor.
8195 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
8196 <abbrev_obstack>: Now an auto_obstack.
8197 (abbrev_table_up): New typedef.
8198 (init_cu_die_reader): Add abbrev_table parameter.
8199 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
8200 Add result_dwo_abbrev_table.
8201 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
8202 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
8204 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
8206 (skip_children): Update.
8207 (abbrev_table::alloc_abbrev): Rename from
8208 abbrev_table_alloc_abbrev.
8209 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
8210 (abbrev_table::lookup_abbrev): Rename from
8211 abbrev_table_lookup_abbrev.
8212 (abbrev_table_read_table): Return abbrev_table_up.
8213 (abbrev_table_free, abbrev_table_free_cleanup)
8214 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
8215 (load_partial_dies): Update.
8217 2018-01-17 Tom Tromey <tom@tromey.com>
8219 * dwarf2read.c (dwarf2_compute_name): Update comment.
8220 (read_func_scope, read_variable): Update.
8221 (new_symbol): Remove.
8222 (new_symbol_full): Rename to new_symbol.
8224 2018-01-17 Mike Gulick <mgulick@mathworks.com>
8227 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
8228 a warning instead of throwing an error, set section size to 0 and return
8230 * gdb_bfd.h (gdb_bfd_map_section): Update description.
8232 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
8234 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
8236 (linux_ptrace_attach_fail_reason_string): Likewise.
8237 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
8239 (linux_ptrace_attach_fail_reason_string): Likewise.
8240 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
8242 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
8244 * linux-nat.c (linux_nat_attach): Remove xstrdup.
8246 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
8249 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
8250 checking for fs_base/gs_base fields in struct user_regs_struct.
8251 * configure: Regenerate.
8253 2018-01-17 Yao Qi <yao.qi@linaro.org>
8255 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
8257 (aarch64_linux_init_abi): Install it to gdbarch hook
8260 2018-01-15 Pedro Alves <palves@redhat.com>
8262 * common/signals-state-save-restore.c
8263 (save_original_signals_state): Fix typos.
8265 2017-01-12 Tom Tromey <tom@tromey.com>
8266 Sergio Durigan Junior <sergiodj@redhat.com>
8268 * Makefile.in (install-only): Install gdb-add-index.
8270 2018-01-12 John Baldwin <jhb@FreeBSD.org>
8272 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
8274 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
8276 * infrun.c (keep_going_pass_signal): Clear step-over info when
8277 insert_breakpoints fails.
8279 2018-01-11 Pedro Alves <palves@redhat.com>
8282 * infrun.c (resume): Rename to ...
8283 (resume_1): ... this.
8284 (resume): Reimplement as wrapper around resume_1.
8286 2018-01-11 Pedro Alves <palves@redhat.com>
8289 * remote.c (remote_parse_stop_reply): Default to the last-set
8290 general thread instead of to 'magic_null_ptid'.
8292 2018-01-10 Pedro Alves <palves@redhat.com>
8294 * language.h (language_get_symbol_name_matcher): Rename ...
8295 (get_symbol_name_matcher): ... this.
8296 * language.c (language_get_symbol_name_matcher): Ditto.
8297 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
8300 2018-01-10 Pedro Alves <palves@redhat.com>
8304 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
8305 Adjust to use language_get_symbol_name_matcher instead of
8306 language_defn::la_get_symbol_name_matcher.
8307 * language.c (language_get_symbol_name_matcher): If in Ada mode
8308 and the lookup name is a verbatim match, return Ada's matcher.
8309 * language.h (language_get_symbol_name_matcher): Adjust comment.
8310 (ada_lookup_name_info::verbatim_p):: New method.
8312 2018-01-10 Pedro Alves <palves@redhat.com>
8315 * ada-lang.c (ada_collect_symbol_completion_matches): If the
8316 minsym's language is language_auto or language_cplus, pass down
8317 language_ada instead.
8318 * symtab.c (compare_symbol_name): Don't frob symbol language here.
8320 2018-01-10 Pedro Alves <palves@redhat.com>
8323 * minsyms.c (linkage_name_str): New function.
8324 (iterate_over_minimal_symbols): Use it.
8326 2018-01-09 John Baldwin <jhb@FreeBSD.org>
8328 * NEWS: Document that 'info proc' now works on FreeBSD.
8330 2018-01-09 John Baldwin <jhb@FreeBSD.org>
8332 * configure.ac: Check for kinfo_getfile in libutil.
8333 * configure: Regenerate.
8334 * config.in: Regenerate.
8335 * fbsd-nat.c: Include "fbsd-tdep.h".
8336 (fbsd_fetch_cmdline): New.
8337 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
8338 rather than calling error.
8339 (fbsd_info_proc): New.
8340 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
8341 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
8342 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
8344 2018-01-09 John Baldwin <jhb@FreeBSD.org>
8346 * fbsd-nat.c (struct free_deleter): Remove.
8347 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
8349 2018-01-09 John Baldwin <jhb@FreeBSD.org>
8351 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
8352 NULL for an empty pathname.
8354 2018-01-09 John Baldwin <jhb@FreeBSD.org>
8356 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
8357 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
8358 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
8359 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
8360 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
8361 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
8362 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
8363 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
8364 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
8365 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
8366 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
8367 (fbsd_core_fetch_timeval, fbsd_print_sigset)
8368 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
8369 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
8370 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
8372 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
8374 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
8375 (gnu_xfer_auxv): New function.
8376 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
8379 2018-01-08 Yao Qi <yao.qi@linaro.org>
8380 Simon Marchi <simon.marchi@ericsson.com>
8382 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
8384 (COMMON_OBS): Remove selftest.o.
8385 * configure.ac: Append selftest-arch.c and common/selftest.c to
8386 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
8387 * configure: Re-generated.
8388 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
8390 (maintenance_info_selftests): Likewise.
8392 2018-01-08 Xavier Roirand <roirand@adacore.com>
8394 * ada-valprint.c (val_print_packed_array_elements): Use
8395 proper number of elements when printing an array indexed
8396 by an enumeration type.
8398 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
8400 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
8401 (dw2_get_file_names_reader): Adjust.
8402 (lookup_dwo_signatured_type): Adjust.
8403 (lookup_dwp_signatured_type): Adjust.
8404 (lookup_signatured_type): Adjust.
8405 (create_type_unit_group): Adjust.
8406 (get_type_unit_group): Adjust.
8407 (process_psymtab_comp_unit_reader): Adjust.
8408 (build_type_psymtabs_reader): Adjust.
8409 (scan_partial_symbols): Adjust.
8410 (add_partial_symbol): Adjust.
8411 (add_partial_subprogram): Adjust.
8412 (peek_die_abbrev): Adjust.
8413 (fixup_go_packaging): Adjust.
8414 (process_imported_unit_die): Adjust.
8415 (dwarf2_compute_name): Adjust.
8416 (dwarf2_physname): Adjust.
8417 (read_import_statement): Adjust.
8418 (handle_DW_AT_stmt_list): Adjust.
8419 (read_file_scope): Adjust.
8420 (read_func_scope): Adjust.
8421 (read_lexical_block_scope): Adjust.
8422 (read_call_site_scope): Adjust.
8423 (read_variable): Adjust.
8424 (dwarf2_rnglists_process): Adjust.
8425 (dwarf2_ranges_process): Adjust.
8426 (dwarf2_ranges_read): Adjust.
8427 (dwarf2_get_pc_bounds): Adjust.
8428 (dwarf2_record_block_ranges): Adjust.
8429 (dwarf2_add_field): Adjust.
8430 (dwarf2_add_member_fn): Adjust.
8431 (read_structure_type): Adjust.
8432 (process_structure_scope): Adjust.
8433 (read_enumeration_type): Adjust.
8434 (read_array_type): Adjust.
8435 (mark_common_block_symbol_computed): Adjust.
8436 (read_common_block): Adjust.
8437 (read_namespace_type): Adjust.
8438 (read_namespace): Adjust.
8439 (read_module_type): Adjust.
8440 (read_tag_pointer_type): Adjust.
8441 (read_tag_ptr_to_member_type): Adjust.
8442 (read_tag_string_type): Adjust.
8443 (read_subroutine_type): Adjust.
8444 (read_typedef): Adjust.
8445 (read_base_type): Adjust.
8446 (attr_to_dynamic_prop): Adjust.
8447 (read_subrange_type): Adjust.
8448 (read_unspecified_type): Adjust.
8449 (dwarf2_read_abbrevs): Adjust.
8450 (load_partial_dies): Adjust.
8451 (read_partial_die): Adjust.
8452 (find_partial_die): Adjust.
8453 (guess_partial_die_structure_name): Adjust.
8454 (fixup_partial_die): Adjust.
8455 (read_attribute_value): Adjust.
8456 (read_addr_index): Adjust.
8457 (read_addr_index_from_leb128): Adjust.
8458 (read_str_index): Adjust.
8459 (dwarf2_string_attr): Adjust.
8460 (get_debug_line_section): Adjust.
8461 (dwarf_decode_line_header): Adjust.
8462 (lnp_state_machine::check_line_address): Adjust.
8463 (dwarf_decode_lines_1): Adjust.
8464 (dwarf_decode_lines): Adjust.
8465 (dwarf2_start_symtab): Adjust.
8466 (var_decode_location): Adjust.
8467 (new_symbol_full): Adjust.
8468 (dwarf2_const_value_data): Adjust.
8469 (dwarf2_const_value_attr): Adjust.
8470 (dwarf2_const_value): Adjust.
8472 (die_containing_type): Adjust.
8473 (build_error_marker_type): Adjust.
8474 (lookup_die_type): Adjust.
8475 (guess_full_die_structure_name): Adjust.
8476 (anonymous_struct_prefix): Adjust.
8477 (determine_prefix): Adjust.
8478 (dwarf2_name): Adjust.
8479 (follow_die_ref_or_sig): Adjust.
8480 (follow_die_offset): Adjust.
8481 (follow_die_ref): Adjust.
8482 (follow_die_sig_1): Adjust.
8483 (follow_die_sig): Adjust.
8484 (get_signatured_type): Adjust.
8485 (get_DW_AT_signature_type): Adjust.
8486 (decode_locdesc): Adjust.
8487 (dwarf_decode_macros): Adjust.
8488 (cu_debug_loc_section): Adjust.
8489 (fill_in_loclist_baton): Adjust.
8490 (dwarf2_symbol_mark_computed): Adjust.
8491 (init_one_comp_unit): Don't assign
8492 dwarf2_cu::dwarf2_per_objfile.
8493 (set_die_type): Adjust.
8495 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
8497 * dwarf2read.c (struct mapped_debug_names): Add constructor.
8498 <dwarf2_per_objfile>: New field.
8499 (dwarf2_per_objfile): Remove global.
8500 (get_dwarf2_per_objfile): New function.
8501 (set_dwarf2_per_objfile): New function.
8502 (dwarf2_build_psymtabs_hard): Change objfile parameter to
8504 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
8505 (read_abbrev_offset): Likewise.
8506 (read_indirect_string): Likewise.
8507 (read_indirect_line_string): Likewise.
8508 (read_indirect_string_at_offset): Likewise.
8509 (read_indirect_string_from_dwz): Likewise.
8510 (dwarf2_find_containing_comp_unit): Change objfile parameter to
8512 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
8513 (create_all_comp_units): Change objfile parameter to
8515 (create_all_type_units): Likewise.
8516 (process_queue): Add dwarf2_per_objfile parameter.
8517 (read_and_check_comp_unit_head): Likewise.
8518 (lookup_dwo_unit_in_dwp): Likewise.
8519 (get_dwp_file): Likewise.
8520 (process_cu_includes): Likewise.
8521 (struct free_dwo_file_cleanup_data): New struct.
8522 (dwarf2_has_info): Use get_dwarf2_per_objfile and
8523 set_dwarf2_per_objfile.
8524 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
8525 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
8526 context, adjust calls.
8527 (dw2_instantiate_symtab): Likewise.
8528 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
8529 (dw2_get_cu): Likewise.
8530 (create_cu_from_index_list): Change objfile parameter to
8532 (create_cus_from_index_list): Get dwarf2_per_objfile from
8533 context, adjust calls.
8534 (create_cus_from_index): Likewise.
8535 (create_signatured_type_table_from_index): Change objfile
8536 parameter to dwarf2_per_objfile.
8537 (create_signatured_type_table_from_debug_names): Change objfile
8538 parameter to dwarf2_per_objfile.
8539 (create_addrmap_from_index): Likewise.
8540 (create_addrmap_from_aranges): Likewise.
8541 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
8542 (dw2_setup): Remove.
8543 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
8545 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
8546 get_dwarf2_per_objfile.
8547 (dw2_forget_cached_source_info): Likewise.
8548 (dw2_map_symtabs_matching_filename): Likewise.
8549 (struct dw2_symtab_iterator) <index>: Remove.
8550 <dwarf2_per_objfile>: New field.
8551 (dw2_symtab_iter_init): Replace index parameter with
8553 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
8554 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
8555 (dw2_print_stats): Likewise.
8556 (dw2_dump): Likewise.
8557 (dw2_expand_symtabs_for_function): Likewise.
8558 (dw2_expand_all_symtabs): Likewise.
8559 (dw2_expand_symtabs_with_fullname): Likewise.
8560 (dw2_expand_marked_cus): Replace index and objfile parameters
8561 with dwarf2_per_objfile.
8562 (dw_expand_symtabs_matching_file_matcher): Add
8563 dwarf2_per_objfile parameter and adjust calls.
8564 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
8566 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
8567 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
8569 (create_cus_from_debug_names_list): Replace objfile parameter
8570 with dwarf2_per_objfile and adjust calls.
8571 (create_cus_from_debug_names): Likewise.
8572 (dwarf2_read_debug_names): Likewise.
8573 (mapped_debug_names::namei_to_name): Adjust call.
8574 (dw2_debug_names_iterator::next): Likewise.
8575 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
8576 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
8577 (dw2_debug_names_dump): Likewise.
8578 (dw2_debug_names_expand_symtabs_for_function): Likewise.
8579 (dw2_debug_names_expand_symtabs_matching): Likewise.
8580 (dwarf2_initialize_objfile): Likewise.
8581 (dwarf2_build_psymtabs): Likewise.
8582 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
8584 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
8585 (read_and_check_comp_unit_head): Likewise.
8586 (read_abbrev_offset): Likewise.
8587 (create_debug_type_hash_table): Likewise.
8588 (create_debug_types_hash_table): Likewise.
8589 (create_all_type_units): Replace objfile parameter with
8591 (add_type_unit): Add dwarf2_per_objfile parameter.
8592 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
8593 with dwarf2_per_objfile.
8594 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
8595 (lookup_dwp_signatured_type): Likewise.
8596 (lookup_signatured_type): Likewise.
8597 (read_cutu_die_from_dwo): Likewise.
8598 (init_tu_and_read_dwo_dies): Likewise.
8599 (init_cutu_and_read_dies): Likewise.
8600 (init_cutu_and_read_dies_no_follow): Likewise.
8601 (allocate_type_unit_groups_table): Add objfile parameter.
8602 (create_type_unit_group): Use dwarf2_per_objfile from cu.
8603 (get_type_unit_group): Likewise.
8604 (process_psymtab_comp_unit): Update call.
8605 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
8606 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
8607 (print_tu_stats): Likewise.
8608 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
8610 (build_type_psymtabs): Change objfile parameter to
8612 (process_skeletonless_type_unit): Use dwarf2_per_objfile
8613 passed in void* parameter.
8614 (process_skeletonless_type_units): Change objfile parameter to
8616 (set_partial_user): Likewise.
8617 (dwarf2_build_psymtabs_hard): Likewise.
8618 (read_comp_units_from_section): Likewise.
8619 (create_all_comp_units): Likewise.
8620 (scan_partial_symbols): Update calls.
8621 (add_partial_symbol): Likewise.
8622 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
8623 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
8624 (process_queue): Add dwarf2_per_objfile parameter.
8625 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
8626 (compute_compunit_symtab_includes): Likewise.
8627 (process_cu_includes): Add dwarf2_per_objfile parameter.
8628 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
8629 (process_full_type_unit): Likewise.
8630 (process_imported_unit_die): Update call.
8631 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
8632 (read_file_scope): Likewise.
8633 (allocate_dwo_file_hash_table): Add objfile parameter.
8634 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
8635 (create_cus_hash_table): Likewise.
8636 (create_dwp_hash_table): Likewise.
8637 (create_dwo_unit_in_dwp_v1): Likewise.
8638 (create_dwp_v2_section): Likewise.
8639 (create_dwo_unit_in_dwp_v2): Likewise.
8640 (lookup_dwo_unit_in_dwp): Likewise.
8641 (try_open_dwop_file): Likewise.
8642 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
8643 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
8644 cleanup to include a reference to dwarf2_per_objfile.
8645 (open_dwp_file): Add dwarf2_per_objfile parameter.
8646 (open_and_init_dwp_file): Likewise.
8647 (get_dwp_file): Likewise.
8648 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
8649 (queue_and_load_all_dwo_tus): Update call.
8650 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
8652 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
8653 (dwarf2_ranges_process): Likewise.
8654 (dwarf2_get_pc_bounds): Likewise.
8655 (mark_common_block_symbol_computed): Likewise.
8656 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
8657 (dwarf2_read_abbrevs): Update call.
8658 (read_partial_die): Use dwarf2_per_objfile from cu.
8659 (find_partial_die): Likewise.
8660 (fixup_partial_die): Likewise.
8661 (read_attribute_value): Likewise.
8662 (read_indirect_string_at_offset_from): Add objfile parameter.
8663 (read_indirect_string_at_offset): Add dwarf2_per_objfile
8665 (read_indirect_string_from_dwz): Add objfile parameter.
8666 (read_indirect_string): Add objfile parameter.
8667 (read_addr_index_1): Add dwarf2_per_objfile parameter.
8668 (read_addr_index): Use dwarf2_per_objfile from cu.
8669 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
8671 (read_str_index): Use dwarf2_per_objfile from cu.
8672 (get_debug_line_section): Likewise.
8673 (read_formatted_entries): Add dwarf2_per_objfile parameter.
8674 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
8675 (new_symbol_full): Use dwarf2_per_objfile from cu.
8676 (build_error_marker_type): Likewise.
8677 (lookup_die_type): Likewise.
8678 (determine_prefix): Likewise.
8679 (follow_die_offset): Likewise.
8680 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
8681 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
8682 (dwarf2_fetch_die_type_sect_off): Likewise.
8683 (dwarf2_get_die_type): Likewise.
8684 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
8685 (get_signatured_type): Likewise.
8686 (get_DW_AT_signature_type): Likewise.
8687 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
8688 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
8689 (cu_debug_loc_section): Likewise.
8690 (fill_in_loclist_baton): Likewise.
8691 (dwarf2_symbol_mark_computed): Likewise.
8692 (dwarf2_find_containing_comp_unit): Change objfile parameter to
8694 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
8696 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
8697 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
8698 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
8699 (set_die_type): Use dwarf2_free_objfile from cu.
8700 (get_die_type_at_offset): Likewise.
8701 (dwarf2_per_objfile_free): Don't assign global variable.
8702 (debug_names) <constructor>: Add dwarf2_per_objfile
8703 parameter, update m_debugstrlookup construction.
8704 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
8706 <m_dwarf2_per_objfile>: New field.
8707 <lookup>: Use m_dwarf2_per_objfile.
8708 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
8709 (psyms_seen_size): Likewise.
8710 (write_gdbindex): Replace objfile parameter with
8712 (write_debug_names): Likewise.
8713 (write_psymtabs_to_index): Likewise.
8714 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
8717 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
8719 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
8720 <dwarf2_per_objfile>: New field.
8721 (struct dwarf2_per_cu_data) <objfile>: Remove.
8722 <dwarf2_per_objfile>: New field.
8723 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
8725 (create_signatured_type_table_from_index): Likewise.
8726 (create_debug_type_hash_table): Likewise.
8727 (fill_in_sig_entry_from_dwo_entry): Likewise.
8728 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
8729 (create_type_unit_group): Assign dwarf2_per_objfile instead of
8731 (create_partial_symtab): Access objfile through
8733 (process_psymtab_comp_unit_reader): Likewise.
8734 (read_comp_units_from_section): Likewise.
8735 (scan_partial_symbols): Likewise.
8736 (add_partial_symbol): Likewise.
8737 (add_partial_subprogram): Likewise.
8738 (peek_die_abbrev): Likewise.
8739 (fixup_go_packaging): Likewise.
8740 (process_full_comp_unit): Likewise.
8741 (process_full_type_unit): Likewise.
8742 (process_imported_unit_die): Likewise.
8743 (dwarf2_compute_name): Likewise.
8744 (dwarf2_physname): Likewise.
8745 (read_import_statement): Likewise.
8746 (create_cus_hash_table): Assign dwarf2_physname instead of
8748 (read_func_scope): Access objfile through dwarf2_per_objfile.
8749 (read_lexical_block_scope): Likewise.
8750 (read_call_site_scope): Likewise.
8751 (read_variable): Likewise.
8752 (dwarf2_rnglists_process): Likewise.
8753 (dwarf2_ranges_process): Likewise.
8754 (dwarf2_ranges_read): Likewise.
8755 (dwarf2_record_block_ranges): Likewise.
8756 (dwarf2_add_field): Likewise.
8757 (dwarf2_add_member_fn): Likewise.
8758 (read_structure_type): Likewise.
8759 (process_structure_scope): Likewise.
8760 (read_enumeration_type): Likewise.
8761 (read_array_type): Likewise.
8762 (read_common_block): Likewise.
8763 (read_namespace_type): Likewise.
8764 (read_namespace): Likewise.
8765 (read_module_type): Likewise.
8766 (read_tag_pointer_type): Likewise.
8767 (read_tag_ptr_to_member_type): Likewise.
8768 (read_tag_string_type): Likewise.
8769 (read_subroutine_type): Likewise.
8770 (read_typedef): Likewise.
8771 (read_base_type): Likewise.
8772 (attr_to_dynamic_prop): Likewise.
8773 (read_subrange_type): Likewise.
8774 (read_unspecified_type): Likewise.
8775 (load_partial_dies): Likewise.
8776 (read_partial_die): Likewise.
8777 (find_partial_die): Likewise.
8778 (guess_partial_die_structure_name): Likewise.
8779 (fixup_partial_die): Likewise.
8780 (read_attribute_value): Likewise.
8781 (read_addr_index_from_leb128): Likewise.
8782 (dwarf2_read_addr_index): Likewise.
8783 (dwarf2_string_attr): Likewise.
8784 (lnp_state_machine::check_line_address): Likewise.
8785 (dwarf_decode_lines_1): Likewise.
8786 (dwarf_decode_lines): Likewise.
8787 (dwarf2_start_symtab): Likewise.
8788 (var_decode_location): Likewise.
8789 (new_symbol_full): Likewise.
8790 (dwarf2_const_value_data): Likewise.
8791 (dwarf2_const_value_attr): Likewise.
8792 (dwarf2_const_value): Likewise.
8793 (die_type): Likewise.
8794 (die_containing_type): Likewise.
8795 (lookup_die_type): Likewise.
8796 (guess_full_die_structure_name): Likewise.
8797 (anonymous_struct_prefix): Likewise.
8798 (dwarf2_name): Likewise.
8799 (follow_die_ref_or_sig): Likewise.
8800 (follow_die_offset): Likewise.
8801 (follow_die_ref): Likewise.
8802 (dwarf2_fetch_die_loc_sect_off): Likewise.
8803 (dwarf2_fetch_constant_bytes): Likewise.
8804 (dwarf2_fetch_die_type_sect_off): Likewise.
8805 (dwarf2_get_die_type): Likewise.
8806 (follow_die_sig): Likewise.
8807 (decode_locdesc): Likewise.
8808 (dwarf2_per_cu_objfile): Likewise.
8809 (dwarf2_per_cu_text_offset): Likewise.
8810 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
8812 (set_die_type): Access objfile through
8815 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
8817 * valprint.c (converted_character_d): Remove typedef.
8818 (DEF_VEC_O (converted_character_d)): Remove.
8819 (count_next_character): Use std::vector.
8820 (print_converted_chars_to_obstack): Likewise.
8821 (generic_printstr): Likewise.
8823 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
8825 * xml-support.h (struct gdb_xml_value): Add constructor.
8826 <value>: Change type to unique_xmalloc_ptr.
8827 (gdb_xml_value_s): Remove typedef.
8828 (DEF_VEC_O (gdb_xml_value_s)): Remove.
8829 (gdb_xml_element_start_handler): Change parameter type to
8831 (xml_find_attribute): Likewise.
8832 * xml-support.c (xml_find_attribute): Change parameter type to
8833 std::vector and adjust.
8834 (gdb_xml_values_cleanup): Remove.
8835 (gdb_xml_parser::start_element): Adjust to std::vector.
8836 (xinclude_start_include): Change paraeter type to std::vector
8838 * btrace.c (check_xml_btrace_version): Likewise.
8839 (parse_xml_btrace_block): Likewise.
8840 (parse_xml_btrace_pt_config_cpu): Likewise.
8841 (parse_xml_btrace_pt): Likewise.
8842 (parse_xml_btrace_conf_bts): Likewise.
8843 (parse_xml_btrace_conf_pt): Likewise.
8844 * memory-map.c (memory_map_start_memory): Likewise.
8845 (memory_map_start_property): Likewise.
8846 * osdata.c (osdata_start_osdata): Likewise.
8847 (osdata_start_item): Likewise.
8848 (osdata_start_column): Likewise.
8849 * remote.c (start_thread): Likewise.
8850 * solib-aix.c (library_list_start_library): Likewise.
8851 (library_list_start_list): Likewise.
8852 * solib-svr4.c (library_list_start_library): Likewise.
8853 (svr4_library_list_start_list): Likewise.
8854 * solib-target.c (library_list_start_segment): Likewise.
8855 (library_list_start_section): Likewise.
8856 (library_list_start_library): Likewise.
8857 (library_list_start_list): Likewise.
8858 * tracepoint.c (traceframe_info_start_memory): Likewise.
8859 (traceframe_info_start_tvar): Likewise.
8860 * xml-syscall.c (syscall_start_syscall): Likewise.
8861 * xml-tdesc.c (tdesc_start_target): Likewise.
8862 (tdesc_start_feature): Likewise.
8863 (tdesc_start_reg): Likewise.
8864 (tdesc_start_union): Likewise.
8865 (tdesc_start_struct): Likewise.
8866 (tdesc_start_flags): Likewise.
8867 (tdesc_start_enum): Likewise.
8868 (tdesc_start_field): Likewise.
8869 (tdesc_start_enum_value): Likewise.
8870 (tdesc_start_vector): Likewise.
8872 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
8874 * extension.h (struct xmethod_worker) <clone>: Remove.
8875 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
8877 (python_xmethod_worker::clone): Remove.
8878 * valops.c (find_overload_match): Use std::move instead of
8881 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
8883 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
8884 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
8885 <free_xmethod_worker_data>: Remove.
8886 <get_matching_xmethod_workers>: Chance VEC to std::vector.
8887 <get_xmethod_arg_types>: Remove.
8888 <get_xmethod_result_type>: Remove.
8889 <invoke_xmethod>: Remove.
8890 * extension.c (new_xmethod_worker): Remove.
8891 (clone_xmethod_worker): Remove.
8892 (get_matching_xmethod_workers): Return void, pass std::vector by
8894 (get_xmethod_arg_types): Rename to...
8895 (xmethod_worker::get_arg_types): ... this, and adjust.
8896 (get_xmethod_result_type): Rename to...
8897 (xmethod_worker::get_result_type): ... this, and adjust.
8898 (invoke_xmethod): Remove.
8899 (free_xmethod_worker): Remove.
8900 (free_xmethod_worker_vec): Remove.
8901 * extension.h (enum ext_lang_rc): Move here from
8903 (struct xmethod_worker): Add constructor and destructor.
8906 <invoke, clone, do_get_result_type, do_get_arg_types>: New
8907 virtual pure methods.
8908 <get_arg_types, get_result_type>: New methods.
8909 (xmethod_worker_ptr): Remove typedef.
8910 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
8911 (xmethod_worker_vec): Remove typedef.
8912 (xmethod_worker_up): New typedef.
8913 (invoke_xmethod): Remove.
8914 (clone_xmethod_worker): Remove.
8915 (free_xmethod_worker): Remove.
8916 (free_xmethod_worker_vec): Remove.
8917 (get_xmethod_arg_types): Remove.
8918 (get_xmethod_result_type): Remove.
8919 * valops.c (find_method_list): Use std::vector, don't use
8920 intermediate vector.
8921 (value_find_oload_method_list): Use std::vector.
8922 (find_overload_match): Use std::vector.
8923 (find_oload_champ): Use std::vector.
8924 * value.c (value_free): Use operator delete.
8925 (value_of_xmethod): Rename to...
8926 (value_from_xmethod): ... this. Don't assign
8927 xmethod_worker::value, take rvalue-reference.
8928 (result_type_of_xmethod): Adjust.
8929 (call_xmethod): Adjust.
8930 * value.h: Include extension.h.
8931 (struct xmethod_worker): Don't forward-declare.
8932 (value_of_xmethod): Rename to...
8933 (value_from_xmethod): ... this, take rvalue-reference.
8934 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
8935 (struct python_xmethod_worker): ... this, add constructor and
8937 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
8938 (gdbpy_free_xmethod_worker_data): Rename to...
8939 (python_xmethod_worker::~python_xmethod_worker): ... this and
8941 (gdbpy_clone_xmethod_worker_data): Rename to...
8942 (python_xmethod_worker::clone): ... this and adjust.
8943 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
8945 (gdbpy_get_xmethod_arg_types): Rename to...
8946 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
8947 (gdbpy_get_xmethod_result_type): Rename to...
8948 (python_xmethod_worker::do_get_result_type): ... this and
8950 (gdbpy_invoke_xmethod): Rename to...
8951 (python_xmethod_worker::invoke): ... this and adjust.
8952 (new_python_xmethod_worker): Rename to...
8953 (python_xmethod_worker::python_xmethod_worker): ... this and
8955 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
8957 (gdbpy_free_xmethod_worker_data): Remove.
8958 (gdbpy_get_matching_xmethod_workers): Use std::vector.
8959 (gdbpy_get_xmethod_arg_types): Remove.
8960 (gdbpy_get_xmethod_result_type): Remove.
8961 (gdbpy_invoke_xmethod): Remove.
8962 * python/python.c (python_extension_ops): Remove obsolete
8965 2018-01-05 Pedro Alves <palves@redhat.com>
8968 * common/signals-state-save-restore.c
8969 (save_original_signals_state): New parameter 'quiet'. Warn if we
8970 find a custom handler preinstalled, instead of internal erroring.
8971 But only warn if !quiet.
8972 * common/signals-state-save-restore.h
8973 (save_original_signals_state): New parameter 'quiet'.
8974 * main.c (captured_main_1): Move save_original_signals_state call
8975 after option handling, and pass QUIET.
8977 2018-01-05 Pedro Alves <palves@redhat.com>
8979 * spu-tdep.c (spu_catch_start): Pass
8980 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
8982 2018-01-05 Pedro Alves <palves@redhat.com>
8985 * ada-lang.c (literal_symbol_name_matcher): New function.
8986 (ada_get_symbol_name_matcher): Use it for
8987 symbol_name_match_type::SEARCH_NAME.
8988 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
8989 it down instead of assuming symbol_name_match_type::FULL.
8990 * block.h (block_lookup_symbol): New parameter 'match_type'.
8991 * c-valprint.c (print_unpacked_pointer): Use
8992 lookup_symbol_search_name instead of lookup_symbol.
8993 * compile/compile-object-load.c (get_out_value_type): Pass down
8994 symbol_name_match_type::SEARCH_NAME.
8995 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
8996 symbol_name_match_type::FULL.
8997 * cp-support.c (cp_get_symbol_name_matcher): Handle
8998 symbol_name_match_type::SEARCH_NAME.
8999 * infrun.c (insert_exception_resume_breakpoint): Use
9000 lookup_symbol_search_name.
9001 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
9002 * psymtab.c (maintenance_check_psymtabs): Use
9003 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
9004 * stack.c (print_frame_args): Use lookup_symbol_search_name and
9006 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
9007 if symbol_name_match_type::SEARCH_NAME.
9008 (lookup_symbol_in_language): Pass down
9009 symbol_name_match_type::FULL.
9010 (lookup_symbol_search_name): New.
9011 (lookup_language_this): Pass down
9012 symbol_name_match_type::SEARCH_NAME.
9013 (lookup_symbol_aux, lookup_local_symbol): New parameter
9014 'match_type'. Pass it down.
9015 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
9016 (lookup_symbol_search_name): New declaration.
9017 (lookup_symbol_in_block): New 'match_type' parameter.
9019 2018-01-05 Pedro Alves <palves@redhat.com>
9022 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
9024 (ada_lookup_symbol): Reimplement in terms of
9025 ada_lookup_symbol_list, bits factored out from
9026 ada_lookup_encoded_symbol.
9028 2018-01-05 Joel Brobecker <brobecker@adacore.com>
9030 * ada-exp.y (write_object_renaming): When subscripting an array
9031 using a symbol as the index, pass the block in call to
9032 ada_lookup_encoded_symbol when looking that symbol up.
9034 2018-01-05 Jerome Guitton <guitton@adacore.com>
9036 * ada-lang.c (ada_array_length): Use ada_index_type instead of
9039 2018-01-05 Joel Brobecker <brobecker@adacore.com>
9041 * ada-lang.c (ada_to_fixed_value_create): Add handling of
9042 the case where VALUE_LVAL (val0) is not lval_memory.
9044 2018-01-05 Xavier Roirand <roirand@adacore.com>
9046 * ada-valprint.c (print_optional_low_bound): Handle
9047 character-indexed array printing like boolean-indexed array
9050 2018-01-05 Joel Brobecker <brobecker@adacore.com>
9052 * NEWS: Create a new section for the next release branch.
9053 Rename the section of the current branch, now that it has
9056 2018-01-05 Joel Brobecker <brobecker@adacore.com>
9058 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
9059 * version.in: Bump version to 8.1.50.DATE-git.
9061 2018-01-03 Xavier Roirand <roirand@adacore.com>
9063 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
9065 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
9067 (default_exception_support_info) <catch_handlers_sym>: Add field.
9068 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
9069 (ada_exception_name_addr_1): Add "catch handlers" handling.
9070 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
9072 (create_excep_cond_exprs) <ex>: Add parameter.
9073 (re_set_exception): Update create_excep_cond_exprs call.
9074 (print_it_exception, print_one_exception, print_mention_exception)
9075 (print_recreate_exception): Add "catch handler" handling.
9076 (allocate_location_catch_handlers, re_set_catch_handlers)
9077 (check_status_catch_handlers, print_it_catch_handlers)
9078 (print_one_catch_handlers, print_mention_catch_handlers)
9079 (print_recreate_catch_handlers): New function.
9080 (catch_handlers_breakpoint_ops): New variable.
9081 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
9082 Add parameter. Add "catch handler" handling.
9083 (ada_exception_sym_name, ada_exception_breakpoint_ops):
9084 Add "catch handler" handling.
9085 (ada_exception_catchpoint_cond_string): Add "catch handler"
9087 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
9089 (catch_ada_handlers_command): New function.
9090 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
9091 operations structure.
9092 (_initialize_ada_language): Add "catch handlers" command entry.
9093 * NEWS: Document "catch handlers" feature.
9095 2018-01-02 Joel Brobecker <brobecker@adacore.com>
9097 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
9098 account when creating the array type of the slice.
9099 (ada_value_slice): Likewise.
9101 2018-01-02 Joel Brobecker <brobecker@adacore.com>
9103 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
9105 (create_array_type_with_stride): Add byte_stride_prop parameter.
9106 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
9107 New parameter. Update all callers in this file.
9108 (array_type_has_dynamic_stride): New function.
9109 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
9110 of arrays with dynamic byte strides.
9111 * dwarf2read.c (read_array_type): Add support for dynamic
9112 DW_AT_byte_stride attributes.
9114 2018-01-02 Joel Brobecker <brobecker@adacore.com>
9116 * dwarf2read.c (read_unspecified_type): Treat
9117 DW_TAG_enumeration_type DIEs from Ada units as stubs.
9119 2018-01-01 Joel Brobecker <brobecker@adacore.com>
9121 Update copyright year range in all GDB files.
9123 2018-01-01 Joel Brobecker <brobecker@adacore.com>
9125 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
9126 and gdb/testsuite/gdb.base/step-line.c.
9128 2018-01-01 Joel Brobecker <brobecker@adacore.com>
9130 * copyright.py (main): Dump the contents of
9131 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
9132 even if BY_HAND is empty.
9134 2018-01-01 Joel Brobecker <brobecker@adacore.com>
9136 * top.c (print_gdb_version): Update Copyright year in version
9139 2018-01-01 Joel Brobecker <brobecker@adacore.com>
9141 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
9143 For older changes see ChangeLog-2017.
9149 version-control: never