]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - gdb/ChangeLog
Make sure that sorting does not change section order
[thirdparty/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
d81a3eaf
PT
12018-06-28 Petr Tesarik <ptesarik@suse.cz>
2
3 * symfile.c (add_symbol_file_command): Make sure that sections
4 with the same name are sorted in the same order.
5
ed6dfe51
PT
62018-06-28 Petr Tesarik <ptesarik@suse.cz>
7
8 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
9 require the second argument. If omitted, load sections at the
10 addresses specified in the file.
11
d4d429d5
PT
122018-06-28 Petr Tesarik <ptesarik@suse.cz>
13
14 * symfile.c (symbol_file_command, symbol_file_add_main_1)
15 (_initialize_symfile): Add option "-o" to symbol-file to add an
16 offset to each section of the symbol file.
17
39b27ab6
PT
182018-06-28 Petr Tesarik <ptesarik@suse.cz>
19
20 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
21
41827fc3
TT
222018-06-27 Tom Tromey <tom@tromey.com>
23
24 * stack.c (_initialize_stack): Update "func" help text.
25
0c6aef22
TT
262018-06-27 Tom Tromey <tom@tromey.com>
27
28 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
29 std::vector.
30 (unwind_infopy_str, pyuw_create_unwind_info)
31 (unwind_infopy_add_saved_register, pyuw_sniffer)
32 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
33 Update.
34 (struct saved_reg): Add constructor.
35 <value>: Now a gdbpy_ref<>.
36
63177289
TT
372018-06-27 Tom Tromey <tom@tromey.com>
38
39 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
40
e76f78a0
SM
412018-06-27 Simon Marchi <simon.marchi@ericsson.com>
42
43 * gdb-gdb.py.in: Format using autopep8.
44
9a14af7b
SM
452018-06-27 Simon Marchi <simon.marchi@ericsson.com>
46
47 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
48 (type_lookup_function): Recognize CORE_ADDR values.
49
189366cd
SM
502018-06-27 Simon Marchi <simon.marchi@ericsson.com>
51
52 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
53 print tag_name.
54
68ad5fb9
SM
552018-06-27 Simon Marchi <simon.marchi@ericsson.com>
56
57 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
58 <__lt__>: Add.
59
141ec9f6
SM
602018-06-27 Simon Marchi <simon.marchi@ericsson.com>
61
62 * gdb-gdb.py: Move to...
63 * gdb-gdb.py.in: ... here.
64 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
65 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
66 dependencies.
67 (distclean): Remove gdb-gdb.py when cleaning.
68 (gdb-gdb.py, gdb-gdb.gdb): New rules.
69 * configure: Re-generate.
70
4c4e7ad4
PA
712018-06-27 Pedro Alves <palves@redhat.com>
72
73 * proc-service.c (get_ps_regcache): New.
74 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
75 (ps_lsetfpregs): Use it.
76
7ab6656f
OJ
772018-06-27 Omair Javaid <omair.javaid@linaro.org>
78
79 PR gdb/21695
80 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
81 (dwarf_decode_lines_1): Adjust.
82
bd583225
SM
832018-06-27 Simon Marchi <simon.marchi@ericsson.com>
84
85 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
86 override.
87 <info_proc>: Likewise.
88
9a325b7b
JB
892018-06-26 Joel Brobecker <brobecker@adacore.com>
90
91 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
92 to windows_fetch_one_register, and only handle the case of
93 fetching one register. Move the code that reloads the context
94 and iterates over all registers if R is negative to...
95 (windows_nat_target::fetch_registers): ... here.
96 (do_windows_store_inferior_registers): Rename to
97 windows_store_one_register, and only handle the case of storing
98 one register. Move the code that handles the case where r is
99 negative to...
100 (windows_nat_target::store_registers) ... here.
101
a33ccfc7
TT
1022018-06-26 Tom Tromey <tom@tromey.com>
103
104 PR rust/22574:
105 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
106 * rust-lang.c (rust_print_struct_def): Add podata parameter.
107 Update.
108 (rust_internal_print_type): Add podata parameter.
109 (rust_print_type): Update.
110
e0c547d1
TT
1112018-06-26 Tom Tromey <tom@tromey.com>
112
113 * typeprint.h (struct print_offset_data) <update, finish,
114 maybe_print_hole>: New methods.
115 <indentation>: New constant.
116 * typeprint.c (print_offset_data::indentation): Define.
117 (print_offset_data::maybe_print_hole, print_offset_data::update)
118 (print_offset_data::finish): Move from c-typeprint.c and rename.
119 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
120 (print_spaces_filtered_with_print_options): Update.
121 (c_print_type_union_field_offset, maybe_print_hole)
122 (c_print_type_struct_field_offset): Move to typeprint.c and
123 rename.
124 (c_type_print_base_struct_union): Update.
125
75cbc781
PA
1262018-06-25 Pedro Alves <palves@redhat.com>
127
128 * gdbthread.h (thread_info_ref, delete_thread)
129 (delete_thread_silent, first_thread_of_inferior)
130 (any_thread_of_inferior, switch_to_thread)
131 (enable_thread_stack_temporaries)
132 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
133 (get_last_thread_stack_temporary)
134 (value_in_thread_stack_temporaries, can_access_registers_thread):
135 Spell out "struct thread_info" instead of just "thread_info".
136 * inferior.h (notice_new_inferior): Likewise.
137
b7a08269
PA
1382018-06-25 Pedro Alves <palves@redhat.com>
139
140 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
141 pass thread_info pointer to delete_thread.
142 (windows_nat_target::detach): Pass inferior pointer to
143 detach_inferior.
144 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
145 delete_thread.
146 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
147 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
148 and pass a thread_info pointer to delete_thread.
149 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
150 pass thread_info pointer to delete_thread.
151 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
152 delete_thread_silent call.
153 * procfs.c (procfs_target::detach): Pass inferior pointer to
154 detach_inferior.
155 (procfs_target::wait): Pass thread_info pointer to delete_thread.
156 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
157 delete_thread_silent call.
158 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
159 pass thread_info pointer to delete_thread.
160 (windows_nat_target::detach): Pass inferior pointer to
161 delete_inferior.
162
8e7767e3
AH
1632018-06-22 Alan Hayward <alan.hayward@arm.com>
164
165 * regcache.c (readable_regcache::read_part): Fix asserts.
166 (reg_buffer::raw_collect_part): New function.
167 (regcache::write_part): Fix asserts.
168 (reg_buffer::raw_supply_part): New function.
169 (regcache::transfer_regset_register): New helper function.
170 (regcache::transfer_regset): Call new functions.
171 (regcache_supply_regset): Use gdb_byte*.
172 (regcache::supply_regset): Likewise.
173 (regcache_collect_regset): Likewise.
174 (regcache::collect_regset): Likewise.
175 * regcache.h (reg_buffer::raw_collect_part): New declaration.
176 (reg_buffer::raw_supply_part): Likewise.
177 (regcache::transfer_regset_register): Likewise.
178 (regcache::transfer_regset): Use gdb_byte*.
179
bfd60e34
AH
1802018-06-22 Alan Hayward <alan.hayward@arm.com>
181
182 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
183
00431a78
PA
1842018-06-21 Pedro Alves <palves@redhat.com>
185
186 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
187 instead of a ptid_t. All callers adjusted.
188 * ada-tasks.c (ada_get_task_number): Likewise. All callers
189 adjusted.
190 (print_ada_task_info, display_current_task_id, task_command_1):
191 Adjust.
192 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
193 inferior_thread.
194 (breakpoint_kind): Adjust.
195 (remove_breakpoints_pid): Rename to ...
196 (remove_breakpoints_inf): ... this. Adjust to take an inferior
197 pointer. All callers adjusted.
198 (bpstat_clear_actions): Use inferior_thread.
199 (get_bpstat_thread): New.
200 (bpstat_do_actions): Use it.
201 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
202 to take a thread_info pointer. All callers adjusted.
203 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
204 (breakpoint_re_set_thread): Use inferior_thread.
205 * breakpoint.h (struct inferior): Forward declare.
206 (bpstat_stop_status): Update.
207 (remove_breakpoints_pid): Delete.
208 (remove_breakpoints_inf): New.
209 * bsd-uthread.c (bsd_uthread_target::wait)
210 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
211 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
212 (maint_btrace_packet_history_cmd)
213 (maint_btrace_clear_packet_history_cmd): Adjust.
214 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
215 inferior_thread.
216 * cli/cli-interp.c: Include "inferior.h".
217 * common/refcounted-object.h (struct
218 refcounted_object_ref_policy): New.
219 * compile/compile-object-load.c: Include gdbthread.h.
220 (store_regs): Use inferior_thread.
221 * corelow.c (core_target::close): Use current_inferior.
222 (core_target_open): Adjust to use first_thread_of_inferior and use
223 the current inferior.
224 * ctf.c (ctf_target::close): Adjust to use current_inferior.
225 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
226 <thread>: ... this new field. All references adjusted.
227 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
228 Take a thread_info pointer instead of a ptid_t.
229 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
230 (dummy_frame_discard, register_dummy_frame_dtor): Take a
231 thread_info pointer instead of a ptid_t.
232 * elfread.c: Include "inferior.h".
233 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
234 Use inferior_thread.
235 * eval.c (evaluate_subexp): Likewise.
236 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
237 inferior_thread.
238 * gdb_proc_service.h (struct thread_info): Forward declare.
239 (struct ps_prochandle) <ptid>: Delete, replaced by ...
240 <thread>: ... this new field. All references adjusted.
241 * gdbarch.h, gdbarch.c: Regenerate.
242 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
243 'thread' parameter. All implementations and callers adjusted.
244 * gdbthread.h (thread_info) <set_running>: New method.
245 (delete_thread, delete_thread_silent): Take a thread_info pointer
246 instead of a ptid.
247 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
248 (first_thread_of_process): Delete, replaced by ...
249 (first_thread_of_inferior): ... this new function. All callers
250 adjusted.
251 (any_live_thread_of_process): Delete, replaced by ...
252 (any_live_thread_of_inferior): ... this new function. All callers
253 adjusted.
254 (switch_to_thread, switch_to_no_thread): Declare.
255 (is_executing): Delete.
256 (enable_thread_stack_temporaries): Update comment.
257 <enable_thread_stack_temporaries>: Take a thread_info pointer
258 instead of a ptid_t. Incref the thread.
259 <~enable_thread_stack_temporaries>: Decref the thread.
260 <m_ptid>: Delete
261 <m_thr>: New.
262 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
263 (get_last_thread_stack_temporary)
264 (value_in_thread_stack_temporaries, can_access_registers_thread):
265 Take a thread_info pointer instead of a ptid_t. All callers
266 adjusted.
267 * infcall.c (get_call_return_value): Use inferior_thread.
268 (run_inferior_call): Work with thread pointers instead of ptid_t.
269 (call_function_by_hand_dummy): Work with thread pointers instead
270 of ptid_t. Use thread_info_ref.
271 * infcmd.c (proceed_thread_callback): Access thread's state
272 directly.
273 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
274 access thread's state directly.
275 (continue_command): Use inferior_thread.
276 (info_program_command): Use find_thread_ptid and access thread
277 state directly.
278 (proceed_after_attach_callback): Use thread state directly.
279 (notice_new_inferior): Take a thread_info pointer instead of a
280 ptid_t. All callers adjusted.
281 (exit_inferior): Take an inferior pointer instead of a pid. All
282 callers adjusted.
283 (exit_inferior_silent): New.
284 (detach_inferior): Delete.
285 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
286 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
287 (detach_inferior_command, kill_inferior_command): Use
288 find_inferior_id instead of valid_gdb_inferior_id and
289 gdb_inferior_id_to_pid.
290 (inferior_command): Use inferior and thread pointers.
291 * inferior.h (struct thread_info): Forward declare.
292 (notice_new_inferior): Take a thread_info pointer instead of a
293 ptid_t. All callers adjusted.
294 (detach_inferior): Delete declaration.
295 (exit_inferior, exit_inferior_silent): Take an inferior pointer
296 instead of a pid. All callers adjusted.
297 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
298 (valid_gdb_inferior_id): Delete.
299 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
300 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
301 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
302 ...
303 <inf>: ... this new field.
304 <step_ptid>: Delete, replaced by ...
305 <step_thread>: ... this new field.
306 (get_displaced_stepping_state): Take an inferior pointer instead
307 of a pid. All callers adjusted.
308 (displaced_step_in_progress_any_inferior): Adjust.
309 (displaced_step_in_progress_thread): Take a thread pointer instead
310 of a ptid_t. All callers adjusted.
311 (displaced_step_in_progress, add_displaced_stepping_state): Take
312 an inferior pointer instead of a pid. All callers adjusted.
313 (get_displaced_step_closure_by_addr): Adjust.
314 (remove_displaced_stepping_state): Take an inferior pointer
315 instead of a pid. All callers adjusted.
316 (displaced_step_prepare_throw, displaced_step_prepare)
317 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
318 All callers adjusted.
319 (start_step_over): Adjust.
320 (infrun_thread_ptid_changed): Remove bit updating ptids in the
321 displaced step queue.
322 (do_target_resume): Adjust.
323 (fetch_inferior_event): Use inferior_thread.
324 (context_switch, get_inferior_stop_soon): Take an
325 execution_control_state pointer instead of a ptid_t. All callers
326 adjusted.
327 (switch_to_thread_cleanup): Delete.
328 (stop_all_threads): Use scoped_restore_current_thread.
329 * inline-frame.c: Include "gdbthread.h".
330 (inline_state) <inline_state>: Take a thread pointer instead of a
331 ptid_t. All callers adjusted.
332 <ptid>: Delete, replaced by ...
333 <thread>: ... this new field.
334 (find_inline_frame_state): Take a thread pointer instead of a
335 ptid_t. All callers adjusted.
336 (skip_inline_frames, step_into_inline_frame)
337 (inline_skipped_frames, inline_skipped_symbol): Take a thread
338 pointer instead of a ptid_t. All callers adjusted.
339 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
340 (inline_skipped_frames, inline_skipped_symbol): Likewise.
341 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
342 pointers directly.
343 * linux-nat.c (get_detach_signal): Likewise.
344 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
345 (thread_db_notice_clone): Adjust.
346 (thread_db_find_new_threads_silently)
347 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
348 a thread pointer instead of a ptid_t. All callers adjusted.
349 * mi/mi-cmd-var.c: Include "inferior.h".
350 (mi_cmd_var_update_iter): Update to use thread pointers.
351 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
352 inferior directly.
353 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
354 out to ...
355 (mi_output_running): ... this new function.
356 (mi_on_resume_1): Adjust to use it.
357 (mi_user_selected_context_changed): Adjust to use inferior_thread.
358 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
359 directly.
360 (interrupt_thread_callback): : Adjust to use thread and inferior
361 pointers.
362 * proc-service.c: Include "gdbthread.h".
363 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
364 * progspace-and-thread.c: Include "inferior.h".
365 * progspace.c: Include "inferior.h".
366 * python/py-exitedevent.c (create_exited_event_object): Adjust to
367 hold a reference to an inferior_object.
368 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
369 inferior_thread.
370 * python/py-inferior.c (struct inferior_object): Give the type a
371 tag name instead of a typedef.
372 (python_on_normal_stop): No need to check if the current thread is
373 listed.
374 (inferior_to_inferior_object): Change return type to
375 inferior_object. All callers adjusted.
376 (find_thread_object): Delete, bits factored out to ...
377 (thread_to_thread_object): ... this new function.
378 * python/py-infthread.c (create_thread_object): Use
379 inferior_to_inferior_object.
380 (thpy_is_stopped): Use thread pointer directly.
381 (gdbpy_selected_thread): Use inferior_thread.
382 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
383 field, replaced with ...
384 <thread>: ... this new field. All users adjusted.
385 (btpy_insn_or_gap_new): Drop const.
386 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
387 callers adjusted.
388 * python/py-record.c: Include "gdbthread.h".
389 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
390 a ptid_t. All callers adjusted.
391 (gdbpy_current_recording): Use inferior_thread.
392 * python/py-record.h (recpy_record_object) <ptid>: Delete
393 field, replaced with ...
394 <thread>: ... this new field. All users adjusted.
395 (recpy_element_object) <ptid>: Delete
396 field, replaced with ...
397 <thread>: ... this new field. All users adjusted.
398 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
399 a ptid_t. All callers adjusted.
400 * python/py-threadevent.c: Include "gdbthread.h".
401 (get_event_thread): Use thread_to_thread_object.
402 * python/python-internal.h (struct inferior_object): Forward
403 declare.
404 (find_thread_object, find_inferior_object): Delete declarations.
405 (thread_to_thread_object, inferior_to_inferior_object): New
406 declarations.
407 * record-btrace.c: Include "inferior.h".
408 (require_btrace_thread): Use inferior_thread.
409 (record_btrace_frame_sniffer)
410 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
411 (get_thread_current_frame): Use scoped_restore_current_thread and
412 switch_to_thread.
413 (get_thread_current_frame): Use thread pointer directly.
414 (record_btrace_replay_at_breakpoint): Use thread's inferior
415 pointer directly.
416 * record-full.c: Include "inferior.h".
417 * regcache.c: Include "gdbthread.h".
418 (get_thread_arch_regcache): Use the inferior's address space
419 directly.
420 (get_thread_regcache, registers_changed_thread): New.
421 * regcache.h (get_thread_regcache(thread_info *thread)): New
422 overload.
423 (registers_changed_thread): New.
424 (remote_target) <remote_detach_1>: Swap order of parameters.
425 (remote_add_thread): <remote_add_thread>: Return the new thread.
426 (get_remote_thread_info(ptid_t)): New overload.
427 (remote_target::remote_notice_new_inferior): Use thread pointers
428 directly.
429 (remote_target::process_initial_stop_replies): Use
430 thread_info::set_running.
431 (remote_target::remote_detach_1, remote_target::detach)
432 (extended_remote_target::detach): Adjust.
433 * stack.c (frame_show_address): Use inferior_thread.
434 * target-debug.h (target_debug_print_thread_info_pp): New.
435 * target-delegates.c: Regenerate.
436 * target.c (default_thread_address_space): Delete.
437 (memory_xfer_partial_1): Use current_inferior.
438 (target_detach): Use current_inferior.
439 (target_thread_address_space): Delete.
440 (generic_mourn_inferior): Use current_inferior.
441 * target.h (struct target_ops) <thread_address_space>: Delete.
442 (target_thread_address_space): Delete.
443 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
444 pointers directly.
445 (delete_thread_1, delete_thread, delete_thread_silent): Take a
446 thread pointer instead of a ptid_t. Adjust all callers.
447 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
448 (first_thread_of_process): Delete, replaced by ...
449 (first_thread_of_inferior): ... this new function. All callers
450 adjusted.
451 (any_thread_of_process): Rename to ...
452 (any_thread_of_inferior): ... this, and take an inferior pointer.
453 (any_live_thread_of_process): Rename to ...
454 (any_live_thread_of_inferior): ... this, and take an inferior
455 pointer.
456 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
457 (value_in_thread_stack_temporaries)
458 (get_last_thread_stack_temporary): Take a thread pointer instead
459 of a ptid_t. Adjust all callers.
460 (thread_info::set_running): New.
461 (validate_registers_access): Use inferior_thread.
462 (can_access_registers_ptid): Rename to ...
463 (can_access_registers_thread): ... this, and take a thread
464 pointer.
465 (print_thread_info_1): Adjust to compare thread pointers instead
466 of ptids.
467 (switch_to_no_thread, switch_to_thread): Make extern.
468 (scoped_restore_current_thread::~scoped_restore_current_thread):
469 Use m_thread pointer directly.
470 (scoped_restore_current_thread::scoped_restore_current_thread):
471 Use inferior_thread.
472 (thread_command): Use thread pointer directly.
473 (thread_num_make_value_helper): Use inferior_thread.
474 * top.c (execute_command): Use inferior_thread.
475 * tui/tui-interp.c: Include "inferior.h".
476 * varobj.c (varobj_create): Use inferior_thread.
477 (value_of_root_1): Use find_thread_global_id instead of
478 global_thread_id_to_ptid.
479
33bab475
AH
4802018-06-21 Alan Hayward <alan.hayward@arm.com>
481
482 * regcache.c (readable_regcache::read_part): Avoid memcpy when
483 possible.
484 (regcache::write_part): Likewise.
485 (readable_regcache::cooked_read_part): Update comment.
486 (readable_regcache::cooked_write_part): Likewise.
487 * regcache.h: (readable_regcache::read_part): Likewise.
488 (regcache::write_part): Likewise.
489
8363f9d5
RB
4902018-06-21 Richard Bunt <richard.bunt@arm.com>
491 Dirk Schubert <dirk.schubert@arm.com>
492
493 * aarch64-linux-nat.c (post_attach): New.
494 (aarch64_linux_nat_target::post_attach): Override post_attach to
495 record the number of hardware debug registers.
496
0d0b0ea2
TT
4972018-06-20 Tom Tromey <tom@tromey.com>
498
499 * python/py-param.c (add_setshow_generic): Make parameters const.
500 (parmpy_init): Update.
501
302abd6e
SM
5022018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
503
504 * regcache.h (regcache_cooked_read_ftype): Rename to...
505 (register_read_ftype): ...this, change type to function_view.
506 (class reg_buffer) <save>: Remove src parameter.
507 (readonly_detached_regcache) <readonly_detached_regcache>: Make
508 parameter non-const in first overload. Remove src parameter in
509 second overload.
510 * regcache.c (do_cooked_read): Remove.
511 (readonly_detached_regcache::readonly_detached_regcache): Make
512 parameter non-const, adjust call to other constructor.
513 (reg_buffer::save): Remove src parameter.
514 * frame.c (do_frame_register_read): Remove.
515 (frame_save_as_regcache): Use lambda function.
516 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
517 parameter to ppu2spu_data *.
518 (ppu2spu_sniffer): Use lambda function.
519
19f3f25f
SM
5202018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
521
522 * record-full.c (record_full_target::insert_breakpoint): Remove
523 "struct" keyword, add const.
524
d0ac1c44
SM
5252018-06-19 Simon Marchi <simon.marchi@ericsson.com>
526
527 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
528 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
529 * configure.ac: Remove AC_PREREQ, add missing quoting.
530 * gnulib/configure.ac: Modernize usage of
531 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
532 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
533 (AUTOMAKE_VERSION): Bump to 1.15.1.
534 * configure: Re-generate.
535 * config.in: Re-generate.
536 * aclocal.m4: Re-generate.
537 * gnulib/aclocal.m4: Re-generate.
538 * gnulib/config.in: Re-generate.
539 * gnulib/configure: Re-generate.
540 * gnulib/import/Makefile.in: Re-generate.
541
6ae50267
PA
5422018-06-19 Pedro Alves <palves@redhat.com>
543
544 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
545 (lookup_minimal_symbol_by_pc_section): ... here with
546 gdb_assert_not_reached added.
547
61b04dd0
PA
5482018-06-19 Pedro Alves <palves@redhat.com>
549
550 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
551 parameter with a block parameter. Compare location's block symbol
552 with the frame's block instead of addresses.
553 (skip_inline_frames): Pass the current block instead of the
554 frame's address. Break out as soon as we determine the frame
555 should not be skipped.
556
f709fabb
TT
5572018-06-18 Tom Tromey <tom@tromey.com>
558
559 * solib-aix.c (solib_aix_get_section_offsets): Return
560 unique_xmalloc_ptr.
561 (solib_aix_solib_create_inferior_hook): Update.
562
668eb2f0
TT
5632018-06-18 Tom Tromey <tom@tromey.com>
564
565 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
566
309822ca
TT
5672018-06-18 Tom Tromey <tom@tromey.com>
568
569 * solib-frv.c (frv_relocate_main_executable): Use
570 unique_xmalloc_ptr.
571 * solib-dsbt.c (dsbt_relocate_main_executable): Use
572 unique_xmalloc_ptr.
573
06424eac
TT
5742018-06-18 Tom Tromey <tom@tromey.com>
575
576 * objfiles.h (inhibit_section_map_updates): Update.
577 (resume_section_map_updates, resume_section_map_updates_cleanup):
578 Remove.
579 * solib-svr4.c (svr4_handle_solib_event): Update.
580 * objfiles.c (inhibit_section_map_updates): Return
581 scoped_restore_tmpl<int>.
582 (resume_section_map_updates, resume_section_map_updates_cleanup):
583 Remove.
584
b4be9fad
TT
5852018-06-18 Tom Tromey <tom@tromey.com>
586
587 * valprint.h (read_string): Update.
588 * valprint.c (read_string): Change type of "buffer".
589 (val_print_string): Update.
590 * python/py-value.c (valpy_string): Update.
591 * language.h (struct language_defn) <la_get_string>: Change
592 type of "buffer".
593 (default_get_string, c_get_string): Update.
594 * language.c (default_get_string): Change type of "buffer".
595 * guile/scm-value.c (gdbscm_value_to_string): Update.
596 * c-lang.c (c_get_string): Change type of "buffer".
597
3f0dbd67
TT
5982018-06-18 Tom Tromey <tom@tromey.com>
599
600 * ser-mingw.c (struct pipe_state_destroyer): New.
601 (pipe_state_up): New typedef.
602 (cleanup_pipe_state): Remove.
603 (pipe_windows_open): Use pipe_state_up. Don't release argv.
604
69d340c6
TT
6052018-06-18 Tom Tromey <tom@tromey.com>
606
607 * rust-lang.h (rust_yyerror): Don't declare.
608 * rust-lang.c (rust_language_defn): Update.
609 * rust-exp.y (yyerror): Now static.
610 * parse.c (parse_exp_in_context_1): Update.
611 * p-lang.h (p_yyerror): Don't declare.
612 * p-lang.c (p_language_defn): Update.
613 * p-exp.y (yyerror): Now static.
614 * opencl-lang.c (opencl_language_defn): Update.
615 * objc-lang.c (objc_language_defn): Update.
616 * m2-lang.h (m2_yyerror): Don't declare.
617 * m2-lang.c (m2_language_defn): Update.
618 * m2-exp.y (yyerror): Now static.
619 * language.h (struct language_defn) <la_error>: Remove.
620 * language.c (unk_lang_error): Remove.
621 (unknown_language_defn, auto_language_defn): Remove.
622 * go-lang.h (go_yyerror): Don't declare.
623 * go-lang.c (go_language_defn): Update.
624 * go-exp.y (yyerror): Now static.
625 * f-lang.h (f_yyerror): Don't declare.
626 * f-lang.c (f_language_defn): Update.
627 * f-exp.y (yyerror): Now static.
628 * d-lang.h (d_yyerror): Don't declare.
629 * d-lang.c (d_language_defn): Update.
630 * d-exp.y (yyerror): Now static.
631 * c-lang.h (c_yyerror): Don't declare.
632 * c-lang.c (c_language_defn, cplus_language_defn)
633 (asm_language_defn, minimal_language_defn): Update.
634 * c-exp.y (yyerror): Now static.
635 * ada-lang.h (ada_yyerror): Don't declare.
636 * ada-lang.c (ada_language_defn): Update.
637 * ada-exp.y (yyerror): Now static.
638
e9902bfc
AH
6392018-06-18 Alan Hayward <alan.hayward@arm.com>
640
641 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
642 (store_sveregs_to_thread): Likewise.
643 (aarch64_linux_fetch_inferior_registers): Check for SVE.
644 (aarch64_linux_store_inferior_registers): Likewise.
645 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
646 function.
647 (aarch64_sve_regs_copy_to_regcache): Likewise.
648 (aarch64_sve_regs_copy_from_regcache): Likewise.
649 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
650 declaration.
651 (aarch64_sve_regs_copy_to_regcache): Likewise.
652 (aarch64_sve_regs_copy_from_regcache): Likewise.
653 (sve_context): Structure from Linux headers.
654 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
655 (SVE_SIG_ZREG_SIZE): Likewise.
656 (SVE_SIG_PREG_SIZE): Likewise.
657 (SVE_SIG_FFR_SIZE): Likewise.
658 (SVE_SIG_REGS_OFFSET): Likewise.
659 (SVE_SIG_ZREGS_OFFSET): Likewise.
660 (SVE_SIG_ZREG_OFFSET): Likewise.
661 (SVE_SIG_ZREGS_SIZE): Likewise.
662 (SVE_SIG_PREGS_OFFSET): Likewise.
663 (SVE_SIG_PREG_OFFSET): Likewise.
664 (SVE_SIG_PREGS_SIZE): Likewise.
665 (SVE_SIG_FFR_OFFSET): Likewise.
666 (SVE_SIG_REGS_SIZE): Likewise.
667 (SVE_SIG_CONTEXT_SIZE): Likewise.
668 (SVE_PT_REGS_MASK): Likewise.
669 (SVE_PT_REGS_FPSIMD): Likewise.
670 (SVE_PT_REGS_SVE): Likewise.
671 (SVE_PT_VL_INHERIT): Likewise.
672 (SVE_PT_VL_ONEXEC): Likewise.
673 (SVE_PT_REGS_OFFSET): Likewise.
674 (SVE_PT_FPSIMD_OFFSET): Likewise.
675 (SVE_PT_FPSIMD_SIZE): Likewise.
676 (SVE_PT_SVE_ZREG_SIZE): Likewise.
677 (SVE_PT_SVE_PREG_SIZE): Likewise.
678 (SVE_PT_SVE_FFR_SIZE): Likewise.
679 (SVE_PT_SVE_FPSR_SIZE): Likewise.
680 (SVE_PT_SVE_FPCR_SIZE): Likewise.
681 (__SVE_SIG_TO_PT): Likewise.
682 (SVE_PT_SVE_OFFSET): Likewise.
683 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
684 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
685 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
686 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
687 (SVE_PT_SVE_PREG_OFFSET): Likewise.
688 (SVE_PT_SVE_PREGS_SIZE): Likewise.
689 (SVE_PT_SVE_FFR_OFFSET): Likewise.
690 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
691 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
692 (SVE_PT_SVE_SIZE): Likewise.
693 (SVE_PT_SIZE): Likewise.
694 (HAS_SVE_STATE): New define.
695
17a1cc89
AH
6962018-06-18 Alan Hayward <alan.hayward@arm.com>
697
698 * nat/aarch64-sve-linux-sigcontext.h: New file.
699 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
700 new files.
701 (SVE_VQ_MIN): Likewise.
702 (SVE_VQ_MAX): Likewise.
703 (SVE_VL_MIN): Likewise.
704 (SVE_VL_MAX): Likewise.
705 (SVE_NUM_ZREGS): Likewise.
706 (SVE_NUM_PREGS): Likewise.
707 (sve_vl_valid): Likewise.
708 (struct user_sve_header): Likewise.
709
7010835a
AB
7102018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
711 Richard Bunt <Richard.Bunt@arm.com>
712
713 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
714 was requested by GDB.
715
479b3ef4
TV
7162018-06-15 Tom de Vries <tdevries@suse.de>
717
718 * MAINTAINERS (Write After Approval): Add Tom de Vries.
719
8199b8f4
SM
7202018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
721
722 * gnulib/update-gnulib.sh: Print expected versions of
723 autoconf/aclocal.
724
55c748a1
SM
7252018-06-14 Simon Marchi <simon.marchi@ericsson.com>
726
727 * arch-utils.c (default_type_align): Use type_length_units.
728 * gdbtypes.c (type_align): Use type_length_units.
729
87a8eca7
PW
7302018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
731
732 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
733 of 'define' command.
734
5d9a0608
TV
7352018-06-14 Tom de Vries <tdevries@suse.de>
736
737 PR cli/22573
738 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
739 get_no_prettyformat_print_options.
740
ab89b5a5
SM
7412018-06-13 Simon Marchi <simon.marchi@ericsson.com>
742
743 * sparc-nat.h: Include target.h.
744 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
745 <fetch_registers>: Remove this argument in function call.
746 <store_registers>: Remove this argument in function call, remove
747 extra semicolon.
748 <low_forget_process>: Call sparc64_forget_process instead of
749 sparc_forget_process.
750
62c808ae
RO
7512018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
752
753 * procfs.c (_initialize_procfs): Use add_inf_child_target.
754 (procfs_target::make_corefile_notes): Adjust to new
755 target_read_alloc return type.
756
1840d81a
AB
7572018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
758 Stephen Roberts <stephen.roberts@arm.com>
759
760 PR gdb/22882
761 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
762 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
763 Move should_notify_stop local into more inner scope.
764
9516f85a
AB
7652018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
766 Stephen Roberts <stephen.roberts@arm.com>
767
768 PR gdb/22882
769 * infrun.c (resume_1): Add call to mark_async_event_handler.
770
defd2172
AB
7712018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
772
773 * infrun.c (do_target_wait): Change old version of $pc printed.
774
7b23e087
SM
7752018-06-11 Simon Marchi <simon.marchi@ericsson.com>
776
777 * dwarf2read.c (read_index_from_section): Rename to...
778 (read_gdb_index_from_section): ... this, update all callers.
779 (dwarf2_read_index): Rename to...
780 (dwarf2_read_gdb_index): ... this, update all callers.
781
69c67a0b
JDA
7822018-06-11 John David Anglin <danglin@gcc.gnu.org>
783
784 * gdb/hppa-linux-nat.c
785 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
786 hppa_linux_nat_target::fetch_registers.
787
65d4cada
AH
7882018-06-11 Alan Hayward <alan.hayward@arm.com>
789
790 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
791 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
792 (AARCH64_DWARF_SVE_FFR): Likewise.
793 (AARCH64_DWARF_SVE_P0): Likewise.
794 (AARCH64_DWARF_SVE_Z0): Likewise.
795
f868386e
AH
7962018-06-11 Alan Hayward <alan.hayward@arm.com>
797
798 * common/common-regcache.h (raw_compare): New function.
799 * regcache.c (regcache::raw_compare): Likewise.
800 * regcache.h (regcache::raw_compare): New declaration.
801
9c861883
AH
8022018-06-11 Alan Hayward <alan.hayward@arm.com>
803
804 * common/common-regcache.h (reg_buffer_common): New structure.
805 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
806 (reg_buffer::raw_supply): Likewise.
807 (reg_buffer::raw_supply_integer): Likewise.
808 (reg_buffer::raw_supply_zeroed): Likewise.
809 (reg_buffer::raw_collect): Likewise.
810 (reg_buffer::raw_collect_integer): Likewise.
811 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
812 (reg_buffer::raw_supply): Likewise.
813 (reg_buffer::raw_supply_integer): Likewise.
814 (reg_buffer::raw_supply_zeroed): Likewise.
815 (reg_buffer::raw_collect): Likewise.
816 (reg_buffer::raw_collect_integer): Likewise.
817
953edf2b
TT
8182018-06-10 Tom Tromey <tom@tromey.com>
819
820 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
821 (class remote_state) <stop_reply_queue>: Now std::vector.
822 (remote_state::~remote_state)
823 (remote_target::stop_reply_queue_length): Update.
824 (struct queue_iter_param, remove_child_of_pending_fork)
825 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
826 (check_pending_event_prevents_wildcard_vcont_callback)
827 (remove_stop_reply_for_inferior)
828 (remove_stop_reply_of_remote_state)
829 (remote_notif_remove_once_on_match)
830 (stop_reply_match_ptid_and_ws)
831 (remote_kill_child_of_pending_fork): Remove.
832 (remote_target::remove_new_fork_children)
833 (remote_target::check_pending_events_prevent_wildcard_vcont)
834 (remote_target::discard_pending_stop_replies)
835 (remote_target::discard_pending_stop_replies_in_queue)
836 (remote_target::remote_notif_remove_queued_reply)
837 (remote_target::queued_stop_reply)
838 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
839 (remote_target::wait, remote_target::kill_new_fork_children)
840 (remote_target::async): Update.
841
1ddbba9d
TT
8422018-06-10 Tom Tromey <tom@tromey.com>
843
844 * record-full.c (record_full_arch_list_cleanups): Remove.
845 (record_full_message): Use try/catch.
846 (record_full_wait_cleanups): Remove.
847 (record_full_wait_1): Use try/catch.
848 (record_full_restore): Likewise.
849
219605fd
TT
8502018-06-10 Tom Tromey <tom@tromey.com>
851
852 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
853 declare VEC. Add constructor.
854 <in_target_beneath>: Now bool.
855 (record_full_breakpoints): Now a std::vector, static.
856 (record_full_sync_record_breakpoints)
857 (record_full_init_record_breakpoints)
858 (record_full_target::insert_breakpoint)
859 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
860
71b73764
SM
8612018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
862
863 * dwarf2read.c (process_cu_includes): Remove struct keyword.
864 * serial.c (serial_interface_lookup): Remove struct keyword.
865
4360561f
TT
8662018-06-10 Tom Tromey <tom@tromey.com>
867
868 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
869 method.
870 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
871 a method.
872 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
873 method.
874 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
875 "beneath" as a method.
876 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
877 Use "beneath" as a method.
878
d14b92bf
TT
8792018-06-10 Tom Tromey <tom@tromey.com>
880
881 * tracefile.c (struct trace_file_writer_deleter): New.
882 <operator()>: Rename from trace_file_writer_xfree.
883 (trace_file_writer_up): New typedef.
884 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
885
835dcf92
SM
8862018-06-09 Simon Marchi <simon.marchi@ericsson.com>
887
888 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
889 <m_registers, m_register_status>: Change type to
890 std::unique_ptr.
891 * regcache.c (reg_buffer::reg_buffer): Use new instead of
892 XCNEWVEC.
893
aac0d564
SM
8942018-06-09 Simon Marchi <simon.marchi@ericsson.com>
895
896 * common/common-regcache.h (enum register_status): Add
897 underlying type "signed char".
898 * regcache.h (reg_buffer) <m_register_status>: Change type to
899 register_status *.
900 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
901 register_status instead of signed char.
902 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
903 (reg_buffer::get_register_status): Remove cast.
904 (readable_regcache::raw_read): Remove cast.
905 (readable_regcache::cooked_read): Remove cast.
906
77ad7394
TT
9072018-06-09 Tom Tromey <tom@tromey.com>
908
909 * source.c (reverse_search_command, forward_search_command): Use
910 scoped_fd.
911
191cca63
TT
9122018-06-09 Tom Tromey <tom@tromey.com>
913
914 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
915 (serial_ops_list): Now static, std::vector.
916 (serial_interface_lookup, serial_add_interface): Update.
917
c5d0225d
TT
9182018-06-09 Tom Tromey <tom@tromey.com>
919
920 * dwarf2read.c (process_cu_includes): Update.
921 (process_full_comp_unit): Update.
922 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
923 std::vector.
924
aeab5128
PK
9252018-06-08 Paul Koning <paul_koning@dell.com>
926
927 PR gdb/23252
928
929 * python/python.c (do_start_initialization):
930 Avoid call to internal Python API.
931 (init__gdb_module): New function.
932
5045b3d7
GB
9332018-06-08 Gary Benson <gbenson@redhat.com>
934
935 * linux-thread-db.c (valprint.h): New include.
936 (struct check_thread_db_info): New structure.
937 (check_thread_db_on_load, tdb_testinfo): New static globals.
938 (check_thread_db, check_thread_db_callback): New functions.
939 (try_thread_db_load_1): Run integrity checks if requested.
940 (maintenance_check_libthread_db): New function.
941 (_initialize_thread_db): Register "maint check libthread-db"
942 and "maint set/show check-libthread-db".
943 * NEWS: Mention the above new commands.
944
2f4f025f
TT
9452018-06-08 Tom Tromey <tom@tromey.com>
946
947 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
948 now a method.
949
343b0027
TT
9502018-06-08 Tom Tromey <tom@tromey.com>
951
952 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
953
8dcc53b3
TT
9542018-06-08 Tom Tromey <tom@tromey.com>
955
956 * common/btrace-common.h (struct btrace_data): Add constructor,
957 destructor, move assignment operator.
958 <empty, clear, fini>: New methods.
959 <format>: Initialize.
960 (btrace_data_init, btrace_data_fini, btrace_data_clear)
961 (btrace_data_empty): Don't declare.
962 * common/btrace-common.c (btrace_data_init): Remove.
963 (btrace_data::fini): Rename from btrace_data_fini.
964 (btrace_data::empty): Rename from btrace_data_empty.
965 (btrace_data::clear): Rename from btrace_data_clear. Return
966 bool.
967 * btrace.h (make_cleanup_btrace_data): Don't declare.
968 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
969 (parse_xml_btrace): Update.
970 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
971 (maint_btrace_clear_packet_history_cmd): Update.
972
a1740ee1
PA
9732018-06-07 Pedro Alves <palves@redhat.com>
974
975 * target.h (target_ops) <beneath>: Now a method. All references
976 updated.
977 (class target_stack): New.
978 * target.c (g_target_stack): New.
979 (g_current_top_target): Delete.
980 (current_top_target): Get the top target out of g_target_stack.
981 (target_stack::push, target_stack::unpush): New.
982 (push_target, unpush_target): Reimplement.
983 (target_is_pushed): Reimplement in terms of g_target_stack.
984 (target_ops::beneath, target_stack::find_beneath): New.
985
d6ca69cd
PA
9862018-06-07 Pedro Alves <palves@redhat.com>
987
988 * target.h (find_target_beneath): Delete declaration.
989 * target.c (find_target_beneath): Delete definition.
990 * aix-thread.c: All callers of find_target_beneath adjusted to
991 call target_ops::beneath instead.
992 * bsd-uthread.c: Likewise.
993 * linux-thread-db.c: Likewise.
994 * ravenscar-thread.c: Likewise.
995 * sol-thread.c: Likewise.
996 * spu-multiarch.c: Likewise.
997
b6a8c27b
PA
9982018-06-07 Pedro Alves <palves@redhat.com>
999
1000 * target.h (target_ops) <beneath>: Now a method. All references
1001 updated.
1002 (target_ops) <m_beneath>: New.
1003 * target.c (target_ops::beneath): New.
1004 * corelow.c: Adjust all references to target_ops::beneath.
1005 * linux-thread-db.c: Likewise.
1006 * make-target-delegates: Likewise.
1007 * record-btrace.c: Likewise.
1008 * record-full.c: Likewise.
1009 * remote.c: Likewise.
1010 * target.c: Likewise.
1011 * target-delegates.c: Regenerate.
1012
8b88a78e
PA
10132018-06-07 Pedro Alves <palves@redhat.com>
1014
1015 * target.h (target_stack): Delete.
1016 (current_top_target): Declare function.
1017 * target.c (target_stack): Delete.
1018 (g_current_top_target): New.
1019 (current_top_target): New function.
1020 * auxv.c: Use current_top_target instead of target_stack
1021 throughout.
1022 * avr-tdep.c: Likewise.
1023 * breakpoint.c: Likewise.
1024 * corefile.c: Likewise.
1025 * elfread.c: Likewise.
1026 * eval.c: Likewise.
1027 * exceptions.c: Likewise.
1028 * frame.c: Likewise.
1029 * gdbarch-selftests.c: Likewise.
1030 * gnu-v3-abi.c: Likewise.
1031 * ia64-tdep.c: Likewise.
1032 * ia64-vms-tdep.c: Likewise.
1033 * infcall.c: Likewise.
1034 * infcmd.c: Likewise.
1035 * infrun.c: Likewise.
1036 * linespec.c: Likewise.
1037 * linux-tdep.c: Likewise.
1038 * minsyms.c: Likewise.
1039 * ppc-linux-nat.c: Likewise.
1040 * ppc-linux-tdep.c: Likewise.
1041 * procfs.c: Likewise.
1042 * regcache.c: Likewise.
1043 * remote.c: Likewise.
1044 * rs6000-tdep.c: Likewise.
1045 * s390-linux-nat.c: Likewise.
1046 * s390-tdep.c: Likewise.
1047 * solib-aix.c: Likewise.
1048 * solib-darwin.c: Likewise.
1049 * solib-dsbt.c: Likewise.
1050 * solib-spu.c: Likewise.
1051 * solib-svr4.c: Likewise.
1052 * solib-target.c: Likewise.
1053 * sparc-tdep.c: Likewise.
1054 * sparc64-tdep.c: Likewise.
1055 * spu-tdep.c: Likewise.
1056 * symfile.c: Likewise.
1057 * symtab.c: Likewise.
1058 * target-descriptions.c: Likewise.
1059 * target-memory.c: Likewise.
1060 * target.c: Likewise.
1061 * target.h: Likewise.
1062 * tracefile-tfile.c: Likewise.
1063 * tracepoint.c: Likewise.
1064 * valops.c: Likewise.
1065 * valprint.c: Likewise.
1066 * value.c: Likewise.
1067 * windows-tdep.c: Likewise.
1068 * mi/mi-main.c: Likewise.
1069
c7110220
TT
10702018-06-07 Tom Tromey <tom@tromey.com>
1071
1072 * valprint.h (build_address_symbolic): Declare.
1073 * printcmd.c (print_address_symbolic): Update.
1074 (build_address_symbolic): Change "name" and "filename" to
1075 std::string.
1076 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
1077 Update.
1078 * defs.h (build_address_symbolic): Remove declaration.
1079
63bad7b6
AH
10802018-06-07 Alan Hayward <alan.hayward@arm.com>
1081
1082 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
1083 (aarch64_vnv_type): Add function.
1084 (aarch64_pseudo_register_name): Add V regs for SVE.
1085 (aarch64_pseudo_register_type): Likewise.
1086 (aarch64_pseudo_register_reggroup_p): Likewise.
1087 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
1088 (aarch64_pseudo_read_value): Add V regs for SVE.
1089 (aarch64_pseudo_write_2): Use V0 offset for SVE
1090 (aarch64_pseudo_write): Add V regs for SVE.
1091 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
1092
13e3c608
SDJ
10932018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
1094
1095 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
1096 (sve_vl_from_vq): Likewise.
1097
c61b06a1
TT
10982018-06-05 Tom Tromey <tom@tromey.com>
1099
1100 * cli/cli-cmds.c (show_version): Update.
1101 * top.c (print_gdb_version): Add "interactive" parameter.
1102 Update.
1103 * main.c (captured_main_1): Update.
1104 * top.h (print_gdb_version): Add "interactive" parameter and a
1105 comment.
1106
115f7325
DM
11072018-06-05 David Malcolm <dmalcolm@redhat.com>
1108
1109 * common/enum-flags.h: Add trailing semicolon to example in
1110 comment.
1111
eb6af809
TT
11122018-06-05 Tom Tromey <tom@tromey.com>
1113
1114 PR cli/12326:
1115 * NEWS: Add entry about pager.
1116 * utils.c (pagination_disabled_for_command): New global.
1117 (prompt_for_continue): Allow "c" response to prompt.
1118 (reinitialize_more_filter): Clear
1119 pagination_disabled_for_command.
1120 (fputs_maybe_filtered): Check pagination_disabled_for_command.
1121
54d343a2
TT
11222018-06-04 Tom Tromey <tom@tromey.com>
1123
1124 * ada-lang.h (ada_lookup_symbol_list): Update.
1125 * ada-lang.c (resolve_subexp): Update.
1126 (symbols_are_identical_enums): Change type of syms. Remove nsyms
1127 parameter.
1128 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
1129 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
1130 results parameter to std::vector.
1131 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
1132 Update.
1133 * ada-exp.y (block_lookup): Update.
1134 (select_possible_type_sym): Change type of syms. Remove nsyms
1135 parameter.
1136 (write_var_or_type, write_name_assoc): Update.
1137
178d6a63
JB
11382018-06-04 Joel Brobecker <brobecker@adacore.com>
1139
1140 * windows-nat.c (windows_nat_target::xfer_partial): Return
1141 TARGET_XFER_E_IO if we need to delegate to the target beneath
1142 but BENEATH is NULL.
1143
baf00c2d
SM
11442018-06-04 Simon Marchi <simon.marchi@ericsson.com>
1145
1146 * Makefile.in (config.status): Add configure.nat as a
1147 dependency.
1148
214b073c
TT
11492018-06-04 Tom Tromey <tom@tromey.com>
1150
1151 * cp-name-parser.y (cpname_state): Add method declarations.
1152 (HANDLE_QUAL): Update.
1153 (cpname_state::d_grab, cpname_state::fill_comp)
1154 (cpname_state::make_operator, cpname_state::make_dtor)
1155 (cpname_state::make_builtin_type, cpname_state::make_name)
1156 (cpname_state::d_qualify, cpname_state::d_int_type)
1157 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
1158 (%union): Move earlier.
1159
62b74cb8
AH
11602018-06-04 Alan Hayward <alan.hayward@arm.com>
1161
1162 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
1163
3c5cd5c3
AH
11642018-06-04 Alan Hayward <alan.hayward@arm.com>
1165
1166 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
1167 (aarch64_pseudo_write_1): Likewise.
1168 (aarch64_pseudo_read_value): Use helper.
1169 (aarch64_pseudo_write): Likewise.
1170
59f413d5
PA
11712018-06-04 Pedro Alves <palves@redhat.com>
1172
1173 * darwin-nat.c (darwin_ops): Delete.
1174 (darwin_attach_pid): Use get_native_target.
1175
1332a140
AH
11762018-06-04 Alan Hayward <alan.hayward@arm.com>
1177
1178 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
1179 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
1180
ba2d2bb2
AH
11812018-06-04 Alan Hayward <alan.hayward@arm.com>
1182
1183 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
1184 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
1185 (aarch64_gdbarch_init): Check for SVE.
1186 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
1187
11882018-06-04 Alan Hayward <alan.hayward@arm.com>
39bfb937
AH
1189
1190 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
1191 * aarch64-tdep.h (aarch64_read_description): Likewise.
1192 * arch/aarch64.c (aarch64_create_target_description): Likewise.
1193 * arch/aarch64.h (aarch64_create_target_description): Likewise.
1194 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
1195 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
1196 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
1197
41c60b4b
SM
11982018-06-02 Simon Marchi <simon.marchi@ericsson.com>
1199
1200 * value.c (value_fetch_lazy_bitfield): New.
1201 (value_fetch_lazy_memory): New.
1202 (value_fetch_lazy_register): New.
1203 (value_fetch_lazy): Factor out to smaller functions.
1204
7b640f72
TT
12052018-06-01 Tom Tromey <tom@tromey.com>
1206
1207 * cp-name-parser.y (backslashable, represented): Now const.
1208
98e69eb3
TT
12092018-06-01 Tom Tromey <tom@tromey.com>
1210
1211 * cp-name-parser.y: Include parser-defs.h.
1212 (parser_fprintf): Remove declaration.
1213
49265499
TT
12142018-06-01 Tom Tromey <tom@tromey.com>
1215
1216 * cp-name-parser.y: Use %pure-parser, %lex-param, and
1217 %parse-param.
1218 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
1219 (global_result): Remove globals.
1220 (struct cpname_state): New.
1221 (yyparse): Don't declare.
1222 (yylex, yyerror): Move declarations after %union.
1223 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
1224 (make_name): Add state parameter.
1225 Update all callers.
1226 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
1227 parameter.
1228 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
1229 Update.
1230 (yylex): Add lvalp, state parameters.
1231 (yyerror): Add state parameter.
1232 (cp_demangled_name_to_comp): Update.
1233
55b6c984
TT
12342018-06-01 Tom Tromey <tom@tromey.com>
1235
1236 * cp-name-parser.y (parser_fprintf): Declare.
1237 (GDB_YY_REMAP_PREFIX): Define.
1238 Include yy-remap.h. Don't redefine yy* identifiers.
1239
3513a6bb
TT
12402018-06-01 Tom Tromey <tom@tromey.com>
1241
1242 * python/py-type.c (typy_legacy_template_argument): Update.
1243 * cp-support.h (cp_demangled_name_to_comp): Update.
1244 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
1245 parameter to be a "std::string *".
1246 (main): Update.
1247
e9cb46ab
L
12482018-06-01 H.J. Lu <hongjiu.lu@intel.com>
1249
1250 * ada-lex.l: Include "diagnostics.h" instead of
1251 "common/diagnostics.h".
1252 * unittests/environ-selftests.c: Likewise.
1253 * common/diagnostics.h: Moved to ../include.
1254
8e817061
JB
12552018-06-01 Joel Brobecker <brobecker@adacore.com>
1256
1257 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
1258 to language_mode_manual while calling breakpoint_re_set_one.
1259
a737d952
TT
12602018-06-01 Tom Tromey <tom@tromey.com>
1261
1262 * valops.c (value_cast_structs, destructor_name_p): Update.
1263 * symtab.c (gdb_mangle_name): Update.
1264 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
1265 Update.
1266 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
1267 (pascal_object_print_value_fields, pascal_object_print_value):
1268 Update.
1269 * p-typeprint.c (pascal_type_print_derivation_info): Update.
1270 * linespec.c (find_methods): Update.
1271 * gdbtypes.h (type_name_no_tag): Remove.
1272 (type_name_or_error): Rename from type_name_no_tag_or_error.
1273 * gdbtypes.c (type_name_no_tag): Remove.
1274 (type_name_or_error): Rename from type_name_no_tag_or_error.
1275 (lookup_struct_elt_type, check_typedef): Update.
1276 * expprint.c (print_subexp_standard): Update.
1277 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
1278 * d-namespace.c (d_lookup_nested_symbol): Update.
1279 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
1280 (cp_print_class_member): Update.
1281 * cp-namespace.c (cp_lookup_nested_symbol): Update.
1282 * completer.c (add_struct_fields): Update.
1283 * c-typeprint.c (cp_type_print_derivation_info)
1284 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
1285 Update.
1286 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
1287 (ada_prefer_type, ada_is_exception_sym): Update.
1288
e86ca25f
TT
12892018-06-01 Tom Tromey <tom@tromey.com>
1290
1291 * valops.c (enum_constant_from_type, value_namespace_elt)
1292 (value_maybe_namespace_elt): Update.
1293 * valarith.c (find_size_for_pointer_math): Update.
1294 * target-descriptions.c (make_gdb_type): Update.
1295 * symmisc.c (print_symbol): Update.
1296 * stabsread.c (define_symbol, read_type)
1297 (complain_about_struct_wipeout, add_undefined_type)
1298 (cleanup_undefined_types_1): Update.
1299 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
1300 (rust_range_type_p, val_print_struct, rust_print_struct_def)
1301 (rust_internal_print_type, rust_composite_type)
1302 (rust_evaluate_funcall, rust_evaluate_subexp)
1303 (rust_inclusive_range_type_p): Update.
1304 * python/py-type.c (typy_get_tag): Update.
1305 * p-typeprint.c (pascal_type_print_base): Update.
1306 * mdebugread.c (parse_symbol, parse_type): Update.
1307 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
1308 Update.
1309 * guile/scm-type.c (gdbscm_type_tag): Update.
1310 * go-lang.c (sixg_string_p): Update.
1311 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
1312 Update.
1313 * gdbtypes.h (struct main_type) <tag_name>: Remove.
1314 (TYPE_TAG_NAME): Remove.
1315 * gdbtypes.c (type_name_no_tag): Simplify.
1316 (check_typedef, check_types_equal, recursive_dump_type)
1317 (copy_type_recursive, arch_composite_type): Update.
1318 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
1319 in summary mode when needed.
1320 * eval.c (evaluate_funcall): Update.
1321 * dwarf2read.c (fixup_go_packaging, read_structure_type)
1322 (process_structure_scope, read_enumeration_type)
1323 (read_namespace_type, read_module_type, determine_prefix): Update.
1324 * cp-support.c (inspect_type): Update.
1325 * coffread.c (process_coff_symbol, decode_base_type): Update.
1326 * c-varobj.c (c_is_path_expr_parent): Update.
1327 * c-typeprint.c (c_type_print_base_struct_union): Update.
1328 (c_type_print_base_1): Update. Print struct/class/union/enum in
1329 summary when using C language.
1330 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
1331 (gen_maybe_namespace_elt): Update.
1332 * ada-lang.c (ada_type_name): Simplify.
1333 (empty_record, ada_template_to_fixed_record_type_1)
1334 (template_to_static_fixed_type)
1335 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
1336
c1ec8cea
TT
13372018-06-01 Tom Tromey <tom@tromey.com>
1338
1339 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
1340 c_print_type.
1341 * c-typeprint.c (c_print_type_1): Add "language" parameter.
1342 (c_print_type): Update.
1343 (c_print_type): New overload.
1344 (c_type_print_varspec_prefix, c_type_print_args)
1345 (c_type_print_varspec_suffix, c_print_type_no_offsets)
1346 (c_type_print_base_struct_union, c_type_print_base_1)
1347 (cp_type_print_method_args): Add "language" parameter.
1348 (c_type_print_base): Update.
1349 * c-lang.h (c_print_type): Add new overload.
1350
bc8453a7
TT
13512018-06-01 Tom Tromey <tom@tromey.com>
1352
1353 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
1354 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
1355
739e8682
AH
13562018-06-01 Alan Hayward <alan.hayward@arm.com>
1357
1358 * aarch64-tdep.c (aarch64_sve_register_names): New const
1359 var.
1360 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
1361 (AARCH64_SVE_Z_REGS_NUM): New define.
1362 (AARCH64_SVE_P_REGS_NUM): Likewise.
1363 (AARCH64_SVE_NUM_REGS): Likewise.
1364
8a60efe7
UB
13652018-05-31 Uros Bizjak <ubizjak@gmail.com>
1366
1367 * nat/linux-ptrace.h [__alpha__]
1368 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
1369 definitions.
1370
4b2dfa9d
MR
13712018-05-31 Maciej W. Rozycki <macro@mips.com>
1372
1373 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
1374 the endianness selected.
1375 * NEWS: Document `set endian auto' mode operation update.
1376
122394f1
AH
13772018-05-31 Alan Hayward <alan.hayward@arm.com>
1378
1379 * Makefile.in: Add new header.
1380 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
1381 (sve_vl_from_vg): Likewise.
1382 (sve_vq_from_vl): Likewise.
1383 (sve_vl_from_vq): Likewise.
1384 (sve_vq_from_vg): Likewise.
1385 (sve_vg_from_vq): Likewise.
1386 * configure.nat: Add new c file.
1387 * nat/aarch64-sve-linux-ptrace.c: New file.
1388 * nat/aarch64-sve-linux-ptrace.h: New file.
1389
95228a0d
AH
13902018-05-31 Alan Hayward <alan.hayward@arm.com>
1391
1392 * aarch64-linux-nat.c (aarch64_linux_read_description):
1393 Add parmeter zero.
1394 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
1395 Likewise.
1396 * aarch64-tdep.c (tdesc_aarch64_list): Add.
1397 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
1398 (aarch64_gdbarch_init): Add parmeter zero.
1399 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
1400 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
1401 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
1402 parmeter.
1403 * doc/gdb.texinfo: Describe SVE feature
1404 * features/aarch64-sve.c: New file.
1405
5969f0db
OJ
14062018-05-31 Omair Javaid <omair.javaid@linaro.org>
1407
1408 PR gdb/23210
1409 * gdbarch.sh (significant_addr_bit): Default to zero when
1410 not set by target architecture.
1411 * gdbarch.c: Re-generated.
1412 * utils.c (address_significant): Update.
1413
61367c61
JB
14142018-05-30 Joel Brobecker <brobecker@adacore.com>
1415
1416 * stack.c (func_command): Remove trailing newline in call to error.
1417
34a79281
SM
14182018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1419
1420 * regcache.h (regcache_raw_collect): Remove, update callers to
1421 use regcache::raw_collect.
1422 * regcache.c (regcache_raw_collect): Remove.
1423
73e1c03f
SM
14242018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1425
1426 * regcache.h (regcache_raw_supply): Remove, update callers to
1427 use detached_regcache::raw_supply.
1428 * regcache.c (regcache_raw_supply): Remove.
1429
e4c4a59b
SM
14302018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1431
1432 * regcache.h (regcache_cooked_write_part): Remove, update
1433 callers to use regcache::cooked_write_part.
1434 * regcache.c (regcache_cooked_write_part): Remove.
1435
73bb0000
SM
14362018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1437
1438 * regcache.h (regcache_cooked_read_part): Remove, update callers
1439 to use readable_regcache::cooked_read_part.
1440 * regcache.c (regcache_cooked_read_part): Remove.
1441
46a45e9d
SM
14422018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1443
1444 * regcache.h (regcache_cooked_read_value): Remove, update
1445 callers to use readable_regcache::cooked_read_value.
1446 * regcache.c (regcache_cooked_read_value): Remove.
1447
b66f5587
SM
14482018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1449
1450 * regcache.h (regcache_cooked_write): Remove, update callers to
1451 use regcache::cooked_write.
1452 * regcache.c (regcache_cooked_write): Remove.
1453
6aa7d724
SM
14542018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1455
1456 * regcache.h (regcache_invalidate): Remove, update callers to
1457 use detached_regcache::invalidate instead.
1458 * regcache.c (regcache_invalidate): Remove.
1459
4f0420fd
SM
14602018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1461
1462 * regcache.h (regcache_raw_write_part): Remove, update callers
1463 to use regcache::raw_write_part instead.
1464 * regcache.c (regcache_raw_write_part): Remove.
1465
502fe83e
SM
14662018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1467
1468 * regcache.h (regcache_raw_read_part): Remove, update callers to
1469 use readable_regcache::raw_read_part instead.
1470 * regcache.c (regcache_raw_read_part): Remove.
1471
dca08e1f
SM
14722018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1473
1474 * regcache.h (regcache_cooked_read): Remove, update callers to
1475 use readable_regcache::cooked_read instead.
1476 * regcache.c (regcache_cooked_read): Remove.
1477
10eaee5f
SM
14782018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1479
1480 * regcache.h (regcache_raw_write): Remove, update callers to use
1481 regcache::raw_write instead.
1482 * regcache.c (regcache_raw_write): Remove.
1483
0b883586
SM
14842018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1485
1486 * regcache.h (regcache_raw_read): Remove, update callers to use
1487 readable_regcache::raw_read instead.
1488 * regcache.c (regcache_raw_read): Remove.
1489
0b47d985
SM
14902018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1491
1492 * regcache.h (regcache_raw_update): Remove, update callers to
1493 use readable_regcache::raw_update instead.
1494 * regcache.c (regcache_raw_update): Remove.
1495
0ec9f114
SM
14962018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1497
1498 * regcache.h (regcache_register_status): Remove, update callers
1499 to use reg_buffer::get_register_status directly instead.
1500 * regcache.c (regcache_register_status): Remove.
1501
222312d3
SM
15022018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1503
1504 * regcache.h (regcache_get_ptid): Remove, update all callers to
1505 call regcache::ptid instead.
1506 * regcache.c (regcache_get_ptid): Remove.
1507
fdbe37e3
SM
15082018-05-30 Simon Marchi <simon.marchi@ericsson.com>
1509
1510 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
1511
f7c6f423
PA
15122018-05-30 Pedro Alves <palves@redhat.com>
1513
1514 * common/common-exceptions.h (exception_rethrow): Use
1515 ATTRIBUTE_NORETURN.
1516
52941706
SM
15172018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
1518
1519 * breakpoint.c (print_solib_event, check_status_catch_solib):
1520 Remove struct keyword in range-based for loops.
1521 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
1522 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
1523 Likewise.
1524 * linespec.c (find_superclass_methods, search_minsyms_for_name):
1525 Likewise.
1526 * symfile.c (addr_info_make_relative): Likewise.
1527 * thread.c (value_in_thread_stack_temporaries): Likewise.
1528
bf2977b5
WP
15292018-06-12 Weimin Pan <weimin.pan@oracle.com>
1530
1531 PR gdb/16841
1532 * valops.c (value_struct_elt_for_reference): Call check_typedef on
1533 aggregate type to get its real type before accessing it.
1534
64cc34d8
WP
15352018-05-29 Weimin Pan <weimin.pan@oracle.com>
1536
1537 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
1538 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
1539 * coff-pe-read.c (add_pe_forwarded_sym): Replace
1540 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
1541 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
1542 * jit.c (jit_breakpoint_re_set_internal): Likewise.
1543 * printcmd.c (info_address_command): Likewise.
1544
e7ec8713
TT
15452018-05-29 Tom Tromey <tom@tromey.com>
1546
1547 * windows-nat.c (handle_exception): Update fall-through comment.
1548
bcb430e4
TT
15492018-05-29 Tom Tromey <tom@tromey.com>
1550
1551 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
1552 (struct program_space) <added_solibs>: Now a std::vector.
1553 * breakpoint.c (print_solib_event): Update.
1554 (check_status_catch_solib): Update.
1555 * progspace.c (clear_program_space_solib_cache): Update.
1556 * solib.c (update_solib_list): Update.
1557
894882e3
TT
15582018-05-29 Tom Tromey <tom@tromey.com>
1559
1560 * python/py-type.c (typy_richcompare): Update.
1561 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
1562 * gdbtypes.h (types_deeply_equal): Return bool.
1563 (types_equal): Likewise.
1564 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
1565 declare VEC.
1566 (check_types_equal): Change worklist to std::vector. Return
1567 bool.
1568 (struct type_equality_entry): Add constructor.
1569 (compare_maybe_null_strings): Return bool.
1570 (check_types_worklist): Return bool. Change worklist to
1571 std::vector.
1572 (types_deeply_equal): Use std::vector.
1573 (types_equal): Return bool.
1574 (compare_maybe_null_strings): Simplify.
1575
10b2ded4
TT
15762018-05-29 Tom Tromey <tom@tromey.com>
1577
1578 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
1579
4f7deebe
TT
15802018-05-29 Tom Tromey <tom@tromey.com>
1581
1582 * objc-lang.h: Don't include cp-support.h.
1583 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
1584 declare VEC.
1585
b8283aea
TT
15862018-05-27 Tom Tromey <tom@tromey.com>
1587
1588 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
1589
41a883c8
TT
15902018-05-25 Tom Tromey <tom@tromey.com>
1591
1592 * value.c (value::location): Initialize.
1593
bf259e25
TT
15942018-05-25 Tom Tromey <tom@tromey.com>
1595
1596 * dbxread.c (init_bincl_list): Remove.
1597 (bincl_list): Now a std::vector.
1598 (bincls_allocated, next_bincl): Remove.
1599 (free_bincl_list, do_free_bincl_list_cleanup)
1600 (make_cleanup_free_bincl_list): Remove.
1601 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
1602 unique_xmalloc_ptr.
1603 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
1604 (struct header_file_location): Add constructor.
1605 (add_bincl_to_list): Remove.
1606
d525a99b
TT
16072018-05-25 Tom Tromey <tom@tromey.com>
1608
1609 * tui/tui.c (tui_enable): Update.
1610 * mi/mi-interp.c (mi_interp::init): Update.
1611 * interps.h (class interp) <name>: New method.
1612 <m_name>: Rename from name.
1613 (~scoped_restore_interp): Update.
1614 * interps.c (interp::interp): Update.
1615 (interp_add, interp_set, interp_lookup_existing)
1616 (current_interp_named_p): Update.
1617
da505cff
TT
16182018-05-25 Tom Tromey <tom@tromey.com>
1619
1620 * interps.c (interp_name): Remove.
1621 * mi/mi-interp.c (mi_interp::init): Update.
1622 * interps.h (interp_name): Remove.
1623 (~scoped_restore_interp): Update.
1624 * tui/tui.c (tui_enable): Update.
1625
29f94340
TT
16262018-05-25 Tom Tromey <tom@tromey.com>
1627
1628 * utils.c (fputs_maybe_filtered): Update.
1629 * linespec.c (decode_line_full): Update.
1630 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
1631 (mi_print_breakpoint_for_event, mi_solib_loaded)
1632 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
1633 (mi_user_selected_context_changed): Update.
1634 * mi/mi-main.c (mi_execute_command): Update.
1635 * cli/cli-script.c (execute_control_command): Update.
1636 * python/python.c (execute_gdb_command): Update.
1637 * solib.c (info_sharedlibrary_command): Update.
1638 * interps.c (interp_ui_out): Remove.
1639 * interps.h (interp_ui_out): Remove.
1640
716b8bc5
TT
16412018-05-25 Tom Tromey <tom@tromey.com>
1642
1643 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
1644 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
1645 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
1646
753ff9bd
TT
16472018-05-25 Tom Tromey <tom@tromey.com>
1648
1649 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
1650 * interps.c (interp_exec): Use scoped_restore.
1651
5ca3b260
TT
16522018-05-25 Tom Tromey <tom@tromey.com>
1653
1654 * remote.c (remote_target::remote_file_get): Use
1655 gdb::byte_vector.
1656 (remote_target::remote_file_put): Likewise.
1657
3173aa2f
TT
16582018-05-25 Tom Tromey <tom@tromey.com>
1659
1660 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
1661 a std::string.
1662 (get_pe_section_index, add_pe_exported_sym): Update.
1663 (read_pe_exported_syms): Use gdb::def_vector.
1664
09a5e1b5
TT
16652018-05-25 Tom Tromey <tom@tromey.com>
1666
1667 * frame.c (remove_prev_frame): Remove.
1668 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
1669
d8dab6c3
MR
16702018-05-25 Maciej W. Rozycki <macro@mips.com>
1671
1672 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
1673 Remove prototypes.
1674 * mips-linux-nat.c (supply_fpregset): Always call
1675 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
1676 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
1677 `mips_fill_fpregset'.
1678 * mips-linux-tdep.c (mips_supply_fpregset)
1679 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
1680 (mips_fill_fpregset_wrapper): Remove functions.
1681 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
1682 (mips_linux_fpregset): Remove variable.
1683 (mips_linux_iterate_over_regset_sections): Use
1684 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
1685 (mips_linux_o32_sigframe_init): Remove comment.
1686
3c69da40
PA
16872018-05-25 Pedro Alves <palves@redhat.com>
1688
1689 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
1690 (struct readahead_cache, struct packet_reg, struct
1691 remote_arch_state, class remote_state): Move higher up in the
1692 file.
1693 (remote_target::m_remote_state): Now an object instead of a pointer.
1694 (remote_target::get_remote_state): Adjust.
1695
39f0c204
AB
16962018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
1697
1698 * stack.c (select_and_print_frame): Delete.
1699 (struct function_bounds): Move struct within function.
1700 (func_command): Most content moved into new function
1701 find_frame_for_function, use new function, print result, add
1702 function comment.
1703 (find_frame_for_function): New function, now returns a result.
1704
d392224a
PW
17052018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1706
1707 * stack.c (iterate_over_block_arg_vars): Fix comment.
1708 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
1709
45f25d6c
AB
17102018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
1711
1712 PR gdb/23203
1713 * frame.c
1714 (scoped_restore_selected_frame::scoped_restore_selected_frame):
1715 Define.
1716 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
1717 Define.
1718 * frame.h (class scoped_restore_selected_frame): New class.
1719 * stack.c (print_frame_local_vars): Remove catching and rethrowing
1720 of any exception, use scoped_restore_selected_frame to restore the
1721 frame instead.
1722
da05d921
PA
17232018-05-24 Pedro Alves <palves@redhat.com>
1724
1725 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
1726 override.
1727
a8be540e
TT
17282018-05-23 Tom Tromey <tom@tromey.com>
1729
1730 * complaints.c (struct complaints): Remove.
1731 (symfile_complaint_book): Remove.
1732 (series): New global.
1733 (complaint_internal): Update.
1734 (clear_complaints): Update.
1735
ff1cf532
TT
17362018-05-23 Tom Tromey <tom@tromey.com>
1737
1738 * complaints.c (counters): New global.
1739 (struct complain): Remove.
1740 (struct complaints) <root>: Remove.
1741 (complaint_sentinel): Remove.
1742 (symfile_complaint_book): Update.
1743 (find_complaint) Remove.
1744 (complaint_internal, clear_complaints): Update.
1745
7ff88174
TT
17462018-05-23 Tom Tromey <tom@tromey.com>
1747
1748 * complaints.c (struct complain) <file, line>: Remove.
1749 (find_complaint): Remove file, line parameters.
1750 (complaint_internal): Update.
1751
de54e1a5
TT
17522018-05-23 Tom Tromey <tom@tromey.com>
1753
1754 * complaints.c (vcomplaint): Remove.
1755 (complaint_internal) Merge in contents of vcomplaint.
1756
2ac237e5
TT
17572018-05-23 Tom Tromey <tom@tromey.com>
1758
1759 * complaints.c (struct complaints) <explanation>: Remove.
1760 (symfile_explanations): Remove.
1761 (symfile_complaint_book): Update.
1762 (vcomplaint): Update.
1763 (struct explanation): Remove.
1764
b98664d3
TT
17652018-05-23 Tom Tromey <tom@tromey.com>
1766
1767 * complaints.c (symfile_complaints): Remove.
1768 (complaint_internal): Remove "complaints" parameter.
1769 (clear_complaints, vcomplaint): Remove "c" parameter.
1770 (get_complaints): Remove.
1771 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
1772 (dwarf2_debug_line_missing_file_complaint)
1773 (dwarf2_debug_line_missing_end_sequence_complaint)
1774 (dwarf2_complex_location_expr_complaint)
1775 (dwarf2_const_value_length_mismatch_complaint)
1776 (dwarf2_section_buffer_overflow_complaint)
1777 (dwarf2_macro_malformed_definition_complaint)
1778 (dwarf2_invalid_attrib_class_complaint)
1779 (create_addrmap_from_index, dw2_symtab_iter_next)
1780 (dw2_expand_marked_cus)
1781 (dw2_debug_names_iterator::find_vec_in_debug_names)
1782 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
1783 (create_debug_type_hash_table, init_cutu_and_read_dies)
1784 (partial_die_parent_scope, add_partial_enumeration)
1785 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
1786 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
1787 (read_import_statement, read_file_scope, create_dwo_cu_reader)
1788 (create_cus_hash_table, create_dwp_hash_table)
1789 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
1790 (dwarf2_rnglists_process, dwarf2_ranges_process)
1791 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
1792 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
1793 (handle_struct_member_die, process_structure_scope)
1794 (read_array_type, read_common_block, read_module_type)
1795 (read_tag_pointer_type, read_typedef, read_base_type)
1796 (read_subrange_type, load_partial_dies, partial_die_info::read)
1797 (partial_die_info::read, partial_die_info::read)
1798 (partial_die_info::read, read_checked_initial_length_and_offset)
1799 (dwarf2_string_attr, read_formatted_entries)
1800 (dwarf_decode_line_header)
1801 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
1802 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
1803 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
1804 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
1805 (get_signatured_type, get_DW_AT_signature_type)
1806 (decode_locdesc, file_file_name, consume_improper_spaces)
1807 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
1808 (dwarf_decode_macro_bytes, dwarf_decode_macros)
1809 (dwarf2_symbol_mark_computed, set_die_type)
1810 (read_attribute_value): Update.
1811 * stap-probe.c (handle_stap_probe, get_stap_base_address):
1812 Update.
1813 * dbxread.c (unknown_symtype_complaint)
1814 (lbrac_mismatch_complaint, repeated_header_complaint)
1815 (set_namestring, function_outside_compilation_unit_complaint)
1816 (read_dbx_symtab, process_one_symbol): Update.
1817 * gdbtypes.c (stub_noname_complaint): Update.
1818 * windows-nat.c (handle_unload_dll): Update.
1819 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
1820 (decode_base_type): Update.
1821 * xcoffread.c (bf_notfound_complaint, ef_complaint)
1822 (eb_complaint, record_include_begin, record_include_end)
1823 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
1824 (process_xcoff_symbol, read_symbol)
1825 (function_outside_compilation_unit_complaint)
1826 (scan_xcoff_symtab): Update.
1827 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
1828 * buildsym.c (finish_block_internal, make_blockvector)
1829 (end_symtab_get_static_block, augment_type_symtab): Update.
1830 * dtrace-probe.c (dtrace_process_dof)
1831 (dtrace_static_probe_ops::get_probes): Update.
1832 * complaints.h (struct complaint): Don't declare.
1833 (symfile_complaints): Remove.
1834 (complaint_internal): Remove "complaints" parameter.
1835 (complaint): Likewise.
1836 (clear_complaints): Likewise.
1837 * symfile.c (syms_from_objfile_1, finish_new_objfile)
1838 (reread_symbols): Update.
1839 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
1840 (dwarf2_frame_cache, decode_frame_entry): Update.
1841 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
1842 * objc-lang.c (lookup_objc_class, lookup_child_selector)
1843 (info_selectors_command): Update.
1844 * macrotab.c (macro_include, check_for_redefinition)
1845 (macro_undef): Update.
1846 * objfiles.c (filter_overlapping_sections): Update.
1847 * stabsread.c (invalid_cpp_abbrev_complaint)
1848 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
1849 (define_symbol, error_type, read_type, rs6000_builtin_type)
1850 (stabs_method_name_from_physname, read_member_functions)
1851 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
1852 (attach_fields_to_type, complain_about_struct_wipeout)
1853 (read_range_type, read_args, common_block_start)
1854 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
1855 Update.
1856 * mdebugread.c (index_complaint, unknown_ext_complaint)
1857 (basic_type_complaint, bad_tag_guess_complaint)
1858 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
1859 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
1860 (parse_procedure, parse_lines)
1861 (function_outside_compilation_unit_complaint)
1862 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
1863 (bad_tag_guess_complaint, reg_value_complaint): Update.
1864 * cp-support.c (demangled_name_complaint): Update.
1865 * macroscope.c (sal_macro_scope): Update.
1866 * dwarf-index-write.c (class debug_names): Update.
1867
4e9668d0
TT
18682018-05-23 Tom Tromey <tom@tromey.com>
1869
1870 * complaints.c (clear_complaints): Remove "noisy" parameter.
1871 * complaints.h (clear_complaints): Update.
1872 * symfile.c (syms_from_objfile_1, finish_new_objfile)
1873 (reread_symbols): Update.
1874
43ba33c7
TT
18752018-05-23 Tom Tromey <tom@tromey.com>
1876
1877 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
1878 SUBSEQUENT_MESSAGE.
1879 (vcomplaint, clear_complaints): Update.
1880 (symfile_explanations): Remove some messages.
1881
2b9496b2
TT
18822018-05-23 Tom Tromey <tom@tromey.com>
1883
1884 * complaints.c (internal_complaint): Remove.
1885 * complaints.h (internal_complaint): Remove.
1886
35f1fea3
MR
18872018-05-22 Maciej W. Rozycki <macro@mips.com>
1888
1889 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
1890
6b8edb51
PA
18912018-05-22 Pedro Alves <palves@redhat.com>
1892
1893 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
1894 (remote_fileio_badfd, remote_fileio_return_errno)
1895 (remote_fileio_return_success, remote_fileio_func_open)
1896 (remote_fileio_func_open, remote_fileio_func_close)
1897 (remote_fileio_func_read, remote_fileio_func_write)
1898 (remote_fileio_func_lseek, remote_fileio_func_rename)
1899 (remote_fileio_func_unlink, remote_fileio_func_stat)
1900 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
1901 (remote_fileio_func_isatty, remote_fileio_func_system): Add
1902 remote_target parameter.
1903 (remote_fio_func_map) <func>: Add remote_target parameter.
1904 (do_remote_fileio_request, remote_fileio_request):
1905 * remote-fileio.h (remote_fileio_request):
1906 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
1907 remote_target parameter.
1908 (remote_notif_process, handle_notification): Adjust to pass down
1909 the remote.
1910 (remote_notif_state_allocate): Add remote_target parameter. Save
1911 it.
1912 * remote-notif.h (struct remote_target): Forward declare.
1913 (struct notif_client) <parse, ack, can_get_pending_events>: Add
1914 remote_target parameter.
1915 (struct remote_notif_state) <remote>: New field.
1916 (remote_notif_ack, remote_notif_parse): Add remote_target
1917 parameter.
1918 (remote_notif_state_allocate, remote_notif_state_allocate): Add
1919 remote_target parameter.
1920 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
1921 (threads_listing_context, rmt_thread_action, protocol_feature)
1922 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
1923 (packet_result, struct threads_listing_context, remote_state):
1924 Move definitions and declarations higher up.
1925 (remote_target) <~remote_target>: Declare.
1926 (remote_download_command_source, remote_file_put, remote_file_get)
1927 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
1928 (remote_hostio_pread_vFile, remote_hostio_send_command)
1929 (remote_hostio_set_filesystem, remote_hostio_open)
1930 (remote_hostio_close, remote_hostio_unlink, remote_state)
1931 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
1932 (get_memory_write_packet_size, get_memory_read_packet_size)
1933 (append_pending_thread_resumptions, remote_detach_1)
1934 (append_resumption, remote_resume_with_vcont)
1935 (add_current_inferior_and_thread, wait_ns, wait_as)
1936 (process_stop_reply, remote_notice_new_inferior)
1937 (process_initial_stop_replies, remote_add_thread)
1938 (btrace_sync_conf, remote_btrace_maybe_reopen)
1939 (remove_new_fork_children, kill_new_fork_children)
1940 (discard_pending_stop_replies, stop_reply_queue_length)
1941 (check_pending_events_prevent_wildcard_vcont)
1942 (discard_pending_stop_replies_in_queue, stop_reply)
1943 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
1944 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
1945 (remote_interrupt_as, remote_interrupt_ns)
1946 (remote_get_noisy_reply, remote_query_attached)
1947 (remote_add_inferior, remote_current_thread, get_current_thread)
1948 (set_thread, set_general_thread, set_continue_thread)
1949 (set_general_process, write_ptid)
1950 (remote_unpack_thread_info_response, remote_get_threadinfo)
1951 (parse_threadlist_response, remote_get_threadlist)
1952 (remote_threadlist_iterator, remote_get_threads_with_ql)
1953 (remote_get_threads_with_qxfer)
1954 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
1955 (get_offsets, remote_check_symbols, remote_supported_packet)
1956 (remote_query_supported, remote_packet_size)
1957 (remote_serial_quit_handler, remote_detach_pid)
1958 (remote_vcont_probe, remote_resume_with_hc)
1959 (send_interrupt_sequence, interrupt_query)
1960 (remote_notif_get_pending_events, fetch_register_using_p)
1961 (send_g_packet, process_g_packet, fetch_registers_using_g)
1962 (store_register_using_P, store_registers_using_G)
1963 (set_remote_traceframe, check_binary_download)
1964 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
1965 (remote_xfer_live_readonly_partial, remote_read_bytes)
1966 (remote_send_printf, remote_flash_write, readchar)
1967 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
1968 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
1969 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
1970 (extended_remote_disable_randomization, extended_remote_run)
1971 (send_environment_packet, extended_remote_environment_support)
1972 (extended_remote_set_inferior_cwd, remote_write_qxfer)
1973 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
1974 (packet_command): Now methods of ...
1975 (remote_target): ... this class.
1976 (m_remote_state) <remote_target>: New field.
1977 (struct remote_state) <stop_reply_queue,
1978 remote_async_inferior_event_token, wait_forever_enabled_p>: New
1979 fields.
1980 (remote_state::remote_state): Allocate stop_reply_queue.
1981 (remote_state): Delete global.
1982 (get_remote_state_raw): Delete.
1983 (remote_target::get_remote_state): Allocate m_remote_state on
1984 demand.
1985 (get_current_remote_target): New.
1986 (remote_ops, extended_remote_ops): Delete.
1987 (wait_forever_enabled_p, remote_async_inferior_event_token):
1988 Delete, moved to struct remote_state.
1989 (remote_target::close): Delete self. Destruction bits split to
1990 ...
1991 (remote_target::~remote_target): ... this.
1992 (show_memory_packet_size): Adjust to use
1993 get_current_remote_target.
1994 (struct protocol_feature) <func>: Add remote_target parameter.
1995 All callers adjusted.
1996 (curr_quit_handler_target): New.
1997 (remote_serial_quit_handler): Reimplement.
1998 (remote_target::open_1): Adjust to use get_current_remote_target.
1999 Heap-allocate remote_target/extended_remote_target instances.
2000 (vcont_builder::vcont_builder): Add remote_target parameter, and
2001 save it in m_remote. All callers adjusted.
2002 (vcont_builder::m_remote): New field.
2003 (vcont_builder::restart, vcont_builder::flush)
2004 (vcont_builder::push_action): Use it.
2005 (remote_target::commit_resume): Use it.
2006 (struct queue_iter_param) <remote>: New field.
2007 (remote_target::remove_new_fork_children): Fill in 'remote' field.
2008 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
2009 (check_pending_event_prevents_wildcard_vcont_callback)
2010 (remote_target::check_pending_events_prevent_wildcard_vcont)
2011 (remote_target::discard_pending_stop_replies)
2012 (remote_target::discard_pending_stop_replies_in_queue)
2013 (remote_target::remote_notif_remove_queued_reply): Fill in
2014 'remote' field.
2015 (remote_notif_get_pending_events): New.
2016 (remote_target::readchar, remote_target::remote_serial_write):
2017 Save/restore curr_quit_handler_target.
2018 (putpkt): New.
2019 (kill_new_fork_children): Fill in 'remote' field.
2020 (packet_command): Use get_current_remote_target, defer to
2021 remote_target method of same name.
2022 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
2023 parameter, and save it in m_remote. All callers adjusted.
2024 (scoped_remote_fd::release): Use m_remote.
2025 (scoped_remote_fd::m_remote): New field.
2026 (remote_file_put, remote_file_get, remote_file_delete): Use
2027 get_current_remote_target, defer to remote_target method of same
2028 name.
2029 (remote_btrace_reset): Add remote_state paremeter. Update all
2030 callers.
2031 (remote_async_inferior_event_handler). Pass down 'data'.
2032 (remote_new_objfile): Use get_current_remote_target.
2033 (remote_target::vcont_r_supported): New.
2034 (set_range_stepping): Use get_current_remote_target and
2035 remote_target::vcont_r_supported.
2036 (_initialize_remote): Don't allocate 'remote_state' and
2037 'stop_reply_queue' globals.
2038 * remote.h (struct remote_target): Forward declare.
2039 (getpkt, putpkt, remote_notif_get_pending_events): Add
2040 'remote_target' parameter.
2041
f5db4863
PA
20422018-05-22 Pedro Alves <palves@redhat.com>
2043
2044 * remote.c (vcont_builder): Now a class. Make all data members
2045 private.
2046 (vcont_builder) <vcont_builder, restart, flush, push_action>:
2047 Declare methods.
2048 (vcont_builder_restart): Rename to ...
2049 (vcont_builder::restart): ... this.
2050 (vcont_builder_flush): Rename to ...
2051 (vcont_builder::flush): ... this.
2052 (vcont_builder_push_action): Rename to ...
2053 (vcont_builder::push_action): ... this.
2054 (remote_target::commit_resume): Adjust.
2055
cc0be08f
PA
20562018-05-22 Pedro Alves <palves@redhat.com>
2057
2058 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
2059 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
2060 (get_fixed_memory_packet_size): New.
2061 (get_memory_packet_size): Use it.
2062 (set_memory_packet_size): Don't override the config size with
2063 DEFAULT_MAX_MEMORY_PACKET_SIZE.
2064 (show_memory_packet_size): Use get_fixed_memory_packet_size.
2065 Don't refer to get_memory_packet_size if not connected to a remote
2066 target. Show "(default)" if configured size is 0.
2067
9607784a
PA
20682018-05-22 Pedro Alves <palves@redhat.com>
2069
2070 * remote.c (remote_target::mourn_inferior): Move
2071 discard_pending_stop_replies call here from ...
2072 (_initialize_remote): ... here.
2073
0e9a6b2f
PA
20742018-05-22 Pedro Alves <palves@redhat.com>
2075
2076 * remote.c (compare_section_command): Remove set_general_process
2077 call.
2078
43c3a0e4
PA
20792018-05-22 Pedro Alves <palves@redhat.com>
2080
2081 * remote.c (struct packet_reg, struct remote_arch_state):
2082 Move higher up in the file.
2083 (remote_state) <m_arch_states>: Store remote_arch_state values
2084 instead of remote_arch_state pointers.
2085 (remote_state::get_remote_arch_state): Adjust.
2086
9d6eea31
PA
20872018-05-22 Pedro Alves <palves@redhat.com>
2088
2089 * remote.c: Include <unordered_map>.
2090 (remote_state): Now a class.
2091 (remote_state) <get_remote_arch_state>: Declare method.
2092 <get_remote_arch_state>: New field.
2093 (remote_arch_state) <remote_arch_state>: Declare ctor.
2094 <regs>: Now a unique_ptr.
2095 (remote_gdbarch_data_handle): Delete.
2096 (get_remote_arch_state): Delete.
2097 (remote_state::get_remote_arch_state): New.
2098 (get_remote_state): Adjust to call remote_state's
2099 get_remote_arch_state method.
2100 (init_remote_state): Delete, bits factored out to ...
2101 (remote_arch_state::remote_arch_state): ... this new method.
2102 (get_remote_packet_size, get_memory_packet_size)
2103 (process_g_packet, remote_target::fetch_registers)
2104 (remote_target::prepare_to_store, store_registers_using_G)
2105 (remote_target::store_registers, remote_target::get_trace_status):
2106 Adjust to call remote_state's method.
2107 (_initialize_remote): Remove reference to
2108 remote_gdbarch_data_handle.
2109
dd194f6b
PA
21102018-05-22 Pedro Alves <palves@redhat.com>
2111
2112 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
2113 pread>: New method declarations.
2114 (remote_target::open_1): Adjust.
2115 (readahead_cache_invalidate): Rename to ...
2116 (readahead_cache::invalidate): ... this, and adjust to be a class
2117 method.
2118 (readahead_cache_invalidate_fd): Rename to ...
2119 (readahead_cache::invalidate_fd): ... this, and adjust to be a
2120 class method.
2121 (remote_hostio_pwrite): Adjust.
2122 (remote_hostio_pread_from_cache): Rename to ...
2123 (readahead_cache::pread): ... this, and adjust to be a class
2124 method.
2125 (remote_hostio_close): Adjust.
2126
440b7aec
PA
21272018-05-22 Pedro Alves <palves@redhat.com>
2128
2129 * remote.c (remote_hostio_close_cleanup): Delete.
2130 (class scoped_remote_fd): New.
2131 (remote_file_put, remote_file_get): Use it.
2132
de44f5a7
PA
21332018-05-22 Pedro Alves <palves@redhat.com>
2134
2135 (struct vCont_action_support): Use bool and initialize all fields.
2136 (struct readahead_cache): Initialize all fields.
2137 (remote_state): Use bool and initialize all fields.
2138 (remote_state::remote_state, remote_state::~remote_state): New.
2139 (new_remote_state): Delete.
2140 (_initialize_remote): Use new to allocate remote_state.
2141
b1b60145
PA
21422018-05-22 Pedro Alves <palves@redhat.com>
2143 張俊芝 <zjz@zjz.name>
2144
2145 PR gdb/22973
2146 * c-exp.y: Include "c-support.h".
2147 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
2148 of tolower. Use c_ident_is_alpha to scan names.
2149 * c-lang.c: Include "c-support.h".
2150 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
2151 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
2152 * c-support.h: New file, with bits factored out from ...
2153 * cp-name-parser.y: ... this file.
2154 Include "c-support.h".
2155 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
2156 c-support.h and renamed.
2157 (symbol_end, yylex): Adjust.
2158
0ec848ad
PFC
21592018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2160
2161 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
2162 parameter type to CORE_ADDR.
2163 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
2164 parameter type in declaration to CORE_ADDR.
2165 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
2166 target_auxv_search to get AT_HWCAP and use the result to get the
2167 target description.
2168 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
2169 to CORE_ADDR. Remove the cast of the return value to unsigned
2170 long. Fix error predicate of target_auxv_search.
2171 (ppc_linux_nat_target::read_description): Change the type of the
2172 hwcap variable to CORE_ADDR.
2173
0fb2aaa1
PFC
21742018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2175
2176 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
2177 if the size of fpscr is larger than 32 bits.
2178
2c3305f6
PFC
21792018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2180
2181 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
2182 (ppc32_linux_vsxregmap): New global.
2183 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
2184 regcache_supply_regset, and regcache_collect_regset.
2185 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
2186 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
2187 (fetch_vsx_register, store_vsx_register): Remove.
2188 (fetch_vsx_registers): Add regno parameter. Get regset using
2189 ppc_linux_vsxregset. Use regset to supply registers.
2190 (store_vsx_registers): Add regno parameter. Get regset using
2191 ppc_linux_vsxregset. Use regset to collect registers.
2192 (fetch_register): Call fetch_vsx_registers instead of
2193 fetch_vsx_register.
2194 (store_register): Call store_vsx_registers instead of
2195 store_vsx_register.
2196 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
2197 new regno parameter.
2198 (store_ppc_registers): Call store_vsx_registers with -1 for the
2199 new regno parameter.
2200 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
2201 (ppc_collect_vsxregset): Remove.
2202
1d75a658
PFC
22032018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2204
2205 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
2206 offset fields.
2207 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
2208 for vector register offset fields.
2209 (ppc64_fbsd_reg_offsets): Likewise.
2210 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
2211 to vector register offset fields.
2212 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
2213 to vector register offset fields.
2214 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
2215 vector register offset fields.
2216 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
2217 initializers for vector register offset fields.
2218 (rs6000_aix64_reg_offsets): Likewise.
2219 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
2220 (ppc_supply_vrregset): Remove.
2221 (ppc_collect_vrregset): Remove.
2222 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
2223 (ppc_linux_vrregset) : New function.
2224 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
2225 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
2226 (ppc32_linux_vrregset): Remove.
2227 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
2228 and use result instead of ppc32_linux_vrregset.
2229 (ppc32_linux_reg_offsets): Remove initializers for vector register
2230 offset fields.
2231 (ppc64_linux_reg_offsets): Likewise.
2232 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
2233 * ppc-linux-nat.c: Include regset.h.
2234 (gdb_vrregset_t): Adjust comment to account for little-endian
2235 mode.
2236 (supply_vrregset, fill_vrregset): Remove.
2237 (fetch_altivec_register, store_altivec_register): Remove.
2238 (fetch_altivec_registers): Add regno parameter. Get regset using
2239 ppc_linux_vrregset. Use regset to supply registers.
2240 (store_altivec_registers): Add regno parameter. Get regset using
2241 ppc_linux_vrregset. Use regset to collect registers.
2242 (fetch_register): Call fetch_altivec_registers instead of
2243 fetch_altivec_register.
2244 (store_register): Call store_altivec_registers instead of
2245 store_altivec_register.
2246 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
2247 the new regno parameter.
2248 (store_ppc_registers): Call store_altivec_registers with -1 for
2249 the new regno parameter.
2250
d078308a
PFC
22512018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2252
2253 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
2254 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
2255 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
2256 (gdb_vrregset_t): Change array type size to
2257 PPC_LINUX_SIZEOF_VRREGSET.
2258 (gdb_vsxregset_t): Change array type size to
2259 PPC_LINUX_SIZEOF_VSXREGSET.
2260 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
2261 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
2262 PPC_LINUX_SIZEOF_VSXREGSET.
2263
2e077f5e
PFC
22642018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2265
2266 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
2267 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
2268 nat/ppc-linux.c.
2269 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
2270 ppc_linux_target_wordsize with tid.
2271 (ppc_linux_nat_target::read_description): Call ppc_linux_target
2272 wordsize with tid.
2273 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
2274 (ppc64_64bit_inferior_p): Add static and inline specifiers.
2275 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
2276 tid parameter. Remove static specifier.
2277 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
2278 (ppc_linux_target_wordsize): New declaration.
2279
bd64614e
PFC
22802018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
2281
2282 * arch/ppc-linux-common.c: New file.
2283 * arch/ppc-linux-common.h: New file.
2284 * arch/ppc-linux-tdesc.h: New file.
2285 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
2286 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
2287 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
2288 arch/ppc-linux-tdesc.h.
2289 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
2290 arch/ppc-linux-tdesc.h.
2291 (ppc_linux_nat_target::read_description): Remove target
2292 description matching code. Fill a ppc_linux_features struct and
2293 call ppc_linux_match_description with it. Move comment about ISA
2294 2.05 to ppc-linux-common.c.
2295 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
2296 arch/ppc-linux-tdesc.h.
2297 (ppc_linux_core_read_description): Remove target description
2298 matching code. Fill a ppc_linux_features struct and call
2299 ppc_linux_match_description with it.
2300 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
2301 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
2302 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
2303 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
2304 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
2305 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
2306 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
2307 (tdesc_powerpc_e500l): Remove.
2308
241db429
JB
23092018-05-22 Joel Brobecker <brobecker@adacore.com>
2310
2311 * ada-lang.c (catch_assert_command): Pass empty string instead
2312 of NULL for excep_string argument.
2313
75d74cca
MR
23142018-05-22 Maciej W. Rozycki <macro@mips.com>
2315
2316 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
2317 the width of the requested register exceeds the width of the
2318 `ptrace' data type.
2319
122b53ea
TT
23202018-05-21 Tom Tromey <tom@tromey.com>
2321
2322 * printcmd.c (output_command): Remove.
2323 (output_command_const): Rename to output_command.
2324 * valprint.h (output_command): Rename from output_command_const.
2325 * tracepoint.c (trace_dump_actions): Call output_command.
2326
bc18fbb5
TT
23272018-05-21 Tom Tromey <tom@tromey.com>
2328
2329 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
2330 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
2331 * ada-lang.h (create_ada_exception_catchpoint): Update.
2332 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
2333 std::string.
2334 (create_excep_cond_exprs, ~ada_catchpoint)
2335 (should_stop_exception, print_one_exception)
2336 (print_mention_exception, print_recreate_exception): Update.
2337 (ada_get_next_arg): Remove.
2338 (catch_ada_exception_command_split): Use std::string. Change type
2339 of "excep_string", "cond_string".
2340 (catch_ada_exception_command): Update.
2341 (create_ada_exception_catchpoint): Change type of excep_string.
2342 (ada_exception_sal): Remove excep_string parameter.
2343 (~ada_catchpoint): Remove.
2344
790217f6
TT
23452018-05-21 Tom Tromey <tom@tromey.com>
2346
2347 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
2348 cleanup.
2349
6f46ac85
TT
23502018-05-21 Tom Tromey <tom@tromey.com>
2351
2352 * ada-lang.c (ada_exception_message_1, ada_exception_message):
2353 Return unique_xmalloc_ptr.
2354 (print_it_exception): Update.
2355
15b6611c
TT
23562018-05-21 Tom Tromey <tom@tromey.com>
2357
2358 * tracepoint.c (trace_dump_actions): Use std::string.
2359
c0c9f665
TT
23602018-05-21 Tom Tromey <tom@tromey.com>
2361
2362 * symfile.c (reread_symbols): Use std::string for original_name.
2363
22ca247e
TT
23642018-05-21 Tom Tromey <tom@tromey.com>
2365
2366 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
2367 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
2368 constructor.
2369
184cde75
SM
23702018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
2371
2372 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
2373 instance to...
2374 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
2375 * objfiles.c (get_objfile_bfd_data): Allocate
2376 objfile_per_bfd_storage with obstack_new when allocating on
2377 obstack.
2378
e39db4db
SM
23792018-05-20 Simon Marchi <simon.marchi@ericsson.com>
2380
2381 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
2382 OBSTACK_ZALLOC.
2383 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
2384 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
2385 * mdebugread.c (mdebug_build_psymtabs): Likewise.
2386 (add_pending): Likewise.
2387 (parse_symbol): Likewise.
2388 (parse_partial_symbols): Likewise.
2389 (psymtab_to_symtab_1): Likewise.
2390 (new_psymtab): Likewise.
2391 (elfmdebug_build_psymtabs): Likewise.
2392 * minsyms.c (terminate_minimal_symbol_table): Likewise.
2393 * objfiles.c (get_objfile_bfd_data): Likewise.
2394 (objfile_register_static_link): Likewise.
2395 * psymtab.c (allocate_psymtab): Likewise.
2396 * stabsread.c (read_member_functions): Likewise.
2397 * xcoffread.c (xcoff_end_psymtab): Likewise.
2398
284a0e3c
SM
23992018-05-20 Simon Marchi <simon.marchi@ericsson.com>
2400
2401 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
2402 compiler supports std::is_trivially_constructible.
2403 * common/poison.h: Include obstack.h.
2404 (IsMallocable): Define to is_trivially_constructible if the
2405 compiler supports it, define to true_type otherwise.
2406 (xobnew): New.
2407 (XOBNEW): Redefine.
2408 (xobnewvec): New.
2409 (XOBNEWVEC): Redefine.
2410 * gdb_obstack.h (obstack_zalloc): New.
2411 (OBSTACK_ZALLOC): Redefine.
2412 (obstack_calloc): New.
2413 (OBSTACK_CALLOC): Redefine.
2414 (obstack_new): New.
2415 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
2416 (gdbarch_obstack): New declaration in gdbarch.h, definition in
2417 gdbarch.c.
2418 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
2419 obstack_calloc/obstack_zalloc.
2420 (gdbarch_obstack_zalloc): Remove.
2421 * target-descriptions.c (tdesc_data_init): Use obstack_new.
2422
59f66be3
PW
24232018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2424
2425 * stack.c (backtrace_command_1): Remove useless variable int i.
2426
50c65c2d
PW
24272018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2428
2429 * stack.c (print_frame_info): Fix comment.
2430
7ff8cb8c
TT
24312018-05-18 Tom Tromey <tom@tromey.com>
2432
2433 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
2434 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
2435 (~dwarf2_per_objfile): Update
2436 (dwarf2_get_dwz_file): Use new.
2437 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
2438 unique_ptr.
2439
400174b1
TT
24402018-05-18 Tom Tromey <tom@tromey.com>
2441
2442 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
2443 unique_ptr.
2444 * dwarf2read.c (struct dwp_file): Add constructor and
2445 initializers.
2446 (open_and_init_dwp_file): Return a unique_ptr.
2447 (dwarf2_per_objfile, create_dwp_hash_table)
2448 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
2449 (lookup_dwo_unit_in_dwp): Update.
2450 (open_and_init_dwp_file, get_dwp_file): Update.
2451
3063847f
TT
24522018-05-18 Tom Tromey <tom@tromey.com>
2453
2454 * dwarf2read.c (dwarf2_per_objfile): Update.
2455 (struct mapped_index): Add initializers.
2456 (dwarf2_read_index): Use new.
2457 (dw2_symtab_iter_init): Update.
2458 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
2459 unique_ptr.
2460
d3d02dee
SM
24612018-05-18 Simon Marchi <simon.marchi@ericsson.com>
2462
2463 * dwarf2read.c (mapped_index) <total_size>: Remove.
2464
1d143c36
SM
24652018-05-18 Simon Marchi <simon.marchi@ericsson.com>
2466
2467 * unittests/format_pieces-selftests.c (test_format_specifier):
2468 Add ARI comments.
2469
ce1e8424
TT
24702018-05-18 Tom Tromey <tom@tromey.com>
2471
2472 * c-typeprint.c (maybe_print_hole): New function.
2473 (c_print_type_struct_field_offset): Update.
2474 (c_type_print_base_struct_union): Call maybe_print_hole.
2475
ddfe970e
KS
24762018-05-17 Keith Seitz <keiths@redhat.com>
2477
2478 * breakpoint.c (build_bpstat_chain): New function, moved from
2479 bpstat_stop_status.
2480 (bpstat_stop_status): Add optional parameter, `stop_chain'.
2481 If no stop chain is passed, call build_bpstat_chain to build it.
2482 * breakpoint.h (build_bpstat_chain): Declare.
2483 (bpstat_stop_status): Move documentation here from breakpoint.c.
2484 * infrun.c (handle_signal_stop): Before eliding inlined frames,
2485 build the stop chain and pass it to skip_inline_frames.
2486 Pass this stop chain to bpstat_stop_status.
2487 * inline-frame.c: Include breakpoint.h.
2488 (stopped_by_user_bp_inline_frame): New function.
2489 (skip_inline_frames): Add parameter `stop_chain'.
2490 Move documention to inline-frame.h.
2491 If non-NULL, use stopped_by_user_bp_inline_frame to determine
2492 whether the frame should be elided.
2493 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
2494 Add moved documentation and update for new parameter.
2495
b17992c1
SM
24962018-05-17 Simon Marchi <simon.marchi@ericsson.com>
2497
2498 PR cli/14975
2499 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2500 unittests/format_pieces-selftests.c.
2501 * common/format.h (format_piece) <operator==>: New.
2502 (format_pieces) <operator[]>: Remove.
2503 * common/format.c (format_pieces::format_pieces): Handle \e.
2504 * unittests/format_pieces-selftests.c: New.
2505
58f0c718
TT
25062018-05-17 Tom Tromey <tom@tromey.com>
2507
2508 PR symtab/23010:
2509 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
2510 (dw2_instantiate_symtab): Add skip_partial parameter.
2511 (dw2_find_last_source_symtab, dw2_map_expand_apply)
2512 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
2513 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
2514 (dw2_expand_symtabs_matching_one)
2515 (dw2_find_pc_sect_compunit_symtab)
2516 (dw2_debug_names_lookup_symbol)
2517 (dw2_debug_names_expand_symtabs_for_function): Update.
2518 (init_cutu_and_read_dies): Add skip_partial parameter.
2519 (process_psymtab_comp_unit, build_type_psymtabs_1)
2520 (process_skeletonless_type_unit, load_partial_comp_unit)
2521 (psymtab_to_symtab_1): Update.
2522 (load_full_comp_unit): Add skip_partial parameter.
2523 (process_imported_unit_die, dwarf2_read_addr_index)
2524 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
2525 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
2526 (read_signatured_type): Update.
2527
3e618834
SM
25282018-05-17 Simon Marchi <simon.marchi@ericsson.com>
2529
2530 * value.c (release_value): Remove unused variable.
2531 (record_latest_value): Likewise.
2532 (access_value_history): Likewise.
2533 (preserve_values): Likewise.
2534
fe10fe31
TT
25352018-05-17 Tom Tromey <tom@tromey.com>
2536
2537 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
2538 Initialize.
2539
1d761124
MR
25402018-05-16 Maciej W. Rozycki <macro@mips.com>
2541
2542 PR gdb/22286
2543 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
2544 Also handle registers whose width is not a multiple of
2545 PTRACE_TYPE_RET.
2546 (linux_nat_trad_target::store_register): Likewise.
2547
06333fea
TT
25482018-05-16 Tom Tromey <tom@tromey.com>
2549
2550 * gdbcore.h (core_bfd): Redefine.
2551 * corelow.c (core_target::close): Update.
2552 (core_target_open): Update.
2553 * progspace.h (struct program_space) <cbfd>: Now a
2554 gdb_bfd_ref_ptr.
2555
921222e2
TT
25562018-05-16 Tom Tromey <tom@tromey.com>
2557
2558 PR cli/19551:
2559 * symfile-add-flags.h (enum symfile_add_flags)
2560 <SYMFILE_NOT_FILENAME>: New constant.
2561 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
2562 objfile name from BFD.
2563 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
2564 * minidebug.c (find_separate_debug_file_in_section): Put
2565 ".gnu_debugdata" into BFD's file name.
2566
3acb7083
SM
25672018-05-16 Simon Marchi <simon.marchi@ericsson.com>
2568
2569 * regcache.c (regcache_read_ftype, regcache_write_ftype):
2570 Remove.
2571
561a72d4
TC
25722018-05-15 Tamar Christina <tamar.christina@arm.com>
2573
2574 PR binutils/21446
2575 * aarch64-tdep.c (aarch64_analyze_prologue,
2576 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
2577 Indicate not interested in errors.
2578
4e6ff0e1
MR
25792018-05-15 Maciej W. Rozycki <macro@mips.com>
2580
2581 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
2582 Supply the MIPS_ZERO_REGNUM register.
2583
ea33cd92
MR
25842018-05-15 Maciej W. Rozycki <macro@mips.com>
2585
2586 * mips-tdep.c (mask_address_var): Make variable static.
2587
2d79090e
TT
25882018-05-14 Tom Tromey <tom@tromey.com>
2589
2590 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
2591
cf4912ae
AB
25922018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
2593
2594 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
2595 FXSAVE_ADDR for the mxcsr register.
2596
67e6f569
MF
25972018-05-11 Max Filippov <jcmvbkbc@gmail.com>
2598
2599 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
2600
15244507
PA
26012018-05-11 Pedro Alves <palves@redhat.com>
2602
2603 * corelow.c (core_target) <core_target>: No longer inline.
2604 Initialize m_core_gdbarch, m_core_vec and build the section table
2605 here.
2606 <~core_target>: New.
2607 <core_gdbarch, get_core_register_section>: New methods.
2608 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
2609 factored out from ...
2610 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
2611 (core_ops): Delete.
2612 (sniff_core_bfd): Add gdbarch parameter.
2613 (core_close): Delete, merged into ...
2614 (core_target::close): ... here. Delete self.
2615 (core_close_cleanup): Delete.
2616 (core_target_open): Allocate a core_target on the heap. Use a
2617 unique_ptr instead of a cleanup. Bits moved into the core_target
2618 ctor. Adjust to use core_target methods instead of globals.
2619 (get_core_register_section): Rename to ...
2620 (core_target::get_core_register_section): ... this and adjust.
2621 (struct get_core_registers_cb_data): New.
2622 (get_core_registers_cb): Use it. Use bool.
2623 (core_target::fetch_registers, core_target::files_info)
2624 (core_target::xfer_partial, core_target::read_description)
2625 (core_target::pid_to, core_target::thread_name): Adjust to
2626 reference class fields instead of globals.
2627 * target.h (struct target_ops_deleter, target_ops_up): New.
2628
451953fa
PA
26292018-05-11 Pedro Alves <palves@redhat.com>
2630
2631 * corefile.c (core_file_command): Move to corelow.c.
2632 * corelow.c (the_core_target): Delete.
2633 (core_file_command): Moved from corefile.c. Check exec_bfd
2634 instead of the_core_target. Use target_detach instead of calling
2635 into the_core_target directly.
2636 (maybe_say_no_core_file_now): New.
2637 (core_target::detach): Use it.
2638 (_initialize_corelow): Remove references to the_core_target.
2639 * gdbcore.h (the_core_target): Delete.
2640
e540a5a2 26412018-05-11 Tom Tromey <tromey@redhat.com>
3afc23a6 2642 Pedro Alves <palves@redhat.com>
e540a5a2
TT
2643
2644 * corefile.c (core_bfd): Remove.
2645 * gdbcore.h (core_bfd): Now a macro.
2646 * progspace.h (struct program_space) <cbfd>: New field.
2647
633cf254
TT
26482018-05-11 Tom Tromey <tom@tromey.com>
2649
2650 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
2651 gdb::def_vector.
2652
1a34f210
TT
26532018-05-10 Tom Tromey <tom@tromey.com>
2654
2655 * configure: Rebuild.
2656 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
2657
190852c8
JB
26582018-05-10 Joel Brobecker <brobecker@adacore.com>
2659
2660 PR server/23158:
2661 * regformats/regdat.sh: Adjust script, following the addition
2662 of the new expedite_regs parameter to init_target_desc.
2663
8727de56
OJ
26642018-05-10 Omair Javaid <omair.javaid@linaro.org>
2665
2666 PR gdb/23127
2667 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
2668 set_gdbarch_significant_addr_bit.
2669 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
2670 set_gdbarch_significant_addr_bit.
2671 * utils.c (address_significant): Update to sign extend addr.
2672
37d9e062
MF
26732018-05-09 Max Filippov <jcmvbkbc@gmail.com>
2674
2675 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
2676 (xtensa_linux_init_abi): Limit tdep->num_regs by
2677 tdep->num_nopriv_regs.
2678 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
2679 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
2680 not initialized.
2681
7402fbca
SM
26822018-05-08 Simon Marchi <simon.marchi@ericsson.com>
2683
2684 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
2685
8ee22052
AB
26862018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
2687
2688 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
2689 (I387_MXCSR_INIT_VAL): New constant.
2690 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
2691 buffer if it was supplied by the inferior.
2692 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
2693 (i387_xsave_get_clear_bv): New function.
2694 (i387_supply_xsave): Only read x87 control registers from the
2695 xsave buffer if the feature is enabled, and the state will have
2696 been written, otherwise, provide a suitable default.
2697 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
2698 including x87 control registers. Update control registers if they
2699 have changed from the default value, and mark features as enabled
2700 as required.
2701 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
2702
968ae51b
UW
27032018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
2704
2705 * spu-tdep.c (info_spu_event_command): Fix output formatting.
2706
aff689d3
TT
27072018-05-07 Tom Tromey <tom@tromey.com>
2708
2709 * configure: Rebuild.
2710 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
2711
ce887586
TT
27122018-05-07 Tom Tromey <tom@tromey.com>
2713
2714 PR tdep/20362:
2715 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
2716 bit. Use correct value for VDIV.
2717
85e26832
TT
27182018-05-04 Tom Tromey <tom@tromey.com>
2719
2720 * configure: Rebuild.
2721 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
2722
449b1ac7
TT
27232018-05-04 Tom Tromey <tom@tromey.com>
2724
2725 * linux-record.c (record_linux_system_call) <case
2726 RECORD_SYS_RECVFROM>: Add "break".
2727
15c9ffd6
TT
27282018-05-04 Tom Tromey <tom@tromey.com>
2729
2730 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
2731 Add missing "break".
2732 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
2733 Add missing "break".
2734
e3829d13
TT
27352018-05-04 Tom Tromey <tom@tromey.com>
2736
2737 * rs6000-tdep.c (ppc_process_record_op4)
2738 (ppc_process_record_op63): Add fall-through comment.
2739
da0e1563
TT
27402018-05-04 Tom Tromey <tom@tromey.com>
2741
2742 * i386-tdep.c (i386_process_record): Add fall-through comment.
2743
0019cd49
TT
27442018-05-04 Tom Tromey <tom@tromey.com>
2745
2746 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
2747 comment.
2748
565e0eda
TT
27492018-05-04 Tom Tromey <tom@tromey.com>
2750
2751 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
2752 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
2753 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
2754 comment.
2755 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
2756 comment.
2757 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
2758 comment.
2759
621846f4
TT
27602018-05-04 Tom Tromey <tom@tromey.com>
2761
2762 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
2763
86a73007
TT
27642018-05-04 Tom Tromey <tom@tromey.com>
2765
2766 * s390-tdep.c (s390_process_record): Fix fall-through comments.
2767 * xcoffread.c (scan_xcoff_symtab): Move comment later.
2768 * symfile.c (section_is_mapped): Fix fall-through comment.
2769 * stabsread.c (define_symbol, read_member_functions): Fix
2770 fall-through comment.
2771 * s390-linux-tdep.c (s390_process_record): Fix fall-through
2772 comment.
2773 * remote.c (remote_wait_as): Fix fall-through comment.
2774 * p-exp.y (yylex): Fix fall-through comment.
2775 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
2776 comment.
2777 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
2778 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
2779 * jv-exp.y (yylex): Fix fall-through comment.
2780 * go-exp.y (lex_one_token): Fix fall-through comment.
2781 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
2782 fall-through comment.
2783 * f-exp.y (yylex): Fix fall-through comment.
2784 * dwarf2read.c (process_die): Fix fall-through comments.
2785 * dbxread.c (process_one_symbol): Fix fall-through comment.
2786 * d-exp.y (lex_one_token): Fix fall-through comment.
2787 * cp-name-parser.y (yylex): Fix fall-through comment.
2788 * coffread.c (coff_symtab_read): Fix fall-through comment.
2789 * c-exp.y (lex_one_token): Fix fall-through comment.
2790 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
2791 comment.
2792 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
2793 comment.
2794
56bcdbea
TT
27952018-05-04 Tom Tromey <tom@tromey.com>
2796
2797 PR python/22730:
2798 * NEWS: Mention gdb.execute change.
2799 * gdbcmd.h (execute_control_command): Don't declare.
2800 * python/python.c (execute_gdb_command): Use read_command_lines_1,
2801 execute_control_commands, execute_control_commands_to_string.
2802 * cli/cli-script.h (execute_control_commands)
2803 (execute_control_commands_to_string): Declare.
2804 (execute_control_command): Add from_tty parameter.
2805 * cli/cli-script.c (execute_control_commands)
2806 (execute_control_commands_to_string): New functions.
2807 (execute_user_command): Use execute_control_commands.
2808 (execute_control_command_1): Add "from_tty" parameter. Update.
2809 (execute_control_command): Likewise.
2810
a913fffb
TT
28112018-05-04 Tom Tromey <tom@tromey.com>
2812
2813 PR python/22731:
2814 * NEWS: Mention that breakpoint commands are writable.
2815 * python/py-breakpoint.c (bppy_set_commands): New function.
2816 (breakpoint_object_getset) <"commands">: Use it.
2817
60b3cef2
TT
28182018-05-04 Tom Tromey <tom@tromey.com>
2819
2820 * tracepoint.c (actions_command): Update.
2821 * mi/mi-cmd-break.c (mi_command_line_array)
2822 (mi_command_line_array_cnt, mi_command_line_array_ptr)
2823 (mi_read_next_line): Remove.
2824 (mi_cmd_break_commands): Update.
2825 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
2826 function_view.
2827 * cli/cli-script.c (get_command_line): Update.
2828 (process_next_line): Use function_view. Constify.
2829 (recurse_read_control_structure, read_command_lines)
2830 (read_command_lines_1): Change argument types to function_view.
2831 (do_define_command, document_command): Update.
2832 * breakpoint.h (check_tracepoint_command): Don't declare.
2833 * breakpoint.c (check_tracepoint_command): Remove.
2834 (commands_command_1, create_tracepoint_from_upload): Update.
2835
7a2c85f2
TT
28362018-05-04 Tom Tromey <tom@tromey.com>
2837
2838 PR gdb/11750:
2839 * cli/cli-script.h (enum command_control_type) <define_control>:
2840 New constant.
2841 * cli/cli-script.c (multi_line_command_p): Handle define_control.
2842 (build_command_line, execute_control_command_1)
2843 (process_next_line): Likewise.
2844 (do_define_command): New function, extracted from define_command.
2845 (define_command): Use it.
2846
295dc222
TT
28472018-05-04 Tom Tromey <tom@tromey.com>
2848
2849 * tracepoint.c (actions_command): Update.
2850 * cli/cli-script.h (read_command_lines): Update.
2851 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
2852 (MAX_TMPBUF): Remove define.
2853 (define_command): Use string_printf.
2854 (document_command): Likewise.
2855 * breakpoint.c (commands_command_1): Update.
2856
1263a9d5
TT
28572018-05-04 Tom Tromey <tom@tromey.com>
2858
2859 * top.c (execute_command): Update.
2860 * cli/cli-script.h (print_command_lines): Now varargs.
2861 * cli/cli-script.c (print_command_lines): Now varargs.
2862 (execute_control_command_1) <case while_control, case if_control>:
2863 Update.
2864
12973681
TT
28652018-05-04 Tom Tromey <tom@tromey.com>
2866
2867 * tracepoint.c (all_tracepoint_actions): Rename from
2868 all_tracepoint_actions_and_cleanup. Change return type.
2869 (actions_command, encode_actions_1, encode_actions)
2870 (trace_dump_actions, tdump_command): Update.
2871 * remote.c (remote_download_command_source): Update.
2872 * python/python.c (gdbpy_eval_from_control_command)
2873 (python_command, python_interactive_command): Update.
2874 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
2875 * guile/guile.c (guile_command)
2876 (gdbscm_eval_from_control_command, guile_command): Update.
2877 * compile/compile.c (compile_code_command)
2878 (compile_print_command, compile_to_object): Update.
2879 * cli/cli-script.h (struct command_lines_deleter): New.
2880 (counted_command_line): New typedef.
2881 (struct command_line): Add constructor, destructor.
2882 <body_list>: Remove.
2883 <body_list_0, body_list_1>: New members.
2884 (command_line_up): Remove typedef.
2885 (read_command_lines, read_command_lines_1, get_command_line):
2886 Update.
2887 (copy_command_lines): Don't declare.
2888 * cli/cli-script.c (build_command_line): Use "new".
2889 (get_command_line): Return counted_command_line.
2890 (print_command_lines, execute_user_command)
2891 (execute_control_command_1, while_command, if_command): Update.
2892 (realloc_body_list): Remove.
2893 (process_next_line, recurse_read_control_structure): Update.
2894 (read_command_lines, read_command_lines_1): Return counted_command_line.
2895 (free_command_lines): Use "delete".
2896 (copy_command_lines): Remove.
2897 (define_command, document_command, show_user_1): Update.
2898 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
2899 a counted_command_line.
2900 * breakpoint.h (counted_command_line): Remove typedef.
2901 (breakpoint_set_commands): Update.
2902 * breakpoint.c (check_no_tracepoint_commands)
2903 (validate_commands_for_breakpoint): Update.
2904 (breakpoint_set_commands): Change commands to be a
2905 counted_command_line.
2906 (commands_command_1, update_dprintf_command_list)
2907 (create_tracepoint_from_upload): Update.
2908
e2fc72e2
TT
29092018-05-04 Tom Tromey <tom@tromey.com>
2910
2911 * cli/cli-decode.h (cmd_list_element): New constructor.
2912 (~cmd_list_element): New destructor.
2913 (struct cmd_list_element): Add initializers.
2914 * cli/cli-decode.c (do_add_cmd): Use "new".
2915 (delete_cmd): Use "delete".
2916
a3b60e45
JK
29172018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
2918 Pedro Alves <palves@redhat.com>
2919
2920 PR breakpoints/19806 and support for PR external/20207.
2921 * NEWS: Mention Aarch64 watchpoint improvements.
2922 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
2923 watchpoints and PR external/20207 watchpoints.
2924 * nat/aarch64-linux-hw-point.c
2925 (kernel_supports_any_contiguous_range): New.
2926 (aarch64_watchpoint_offset): New.
2927 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
2928 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
2929 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
2930 (aarch64_align_watchpoint): New parameters aligned_offset_p and
2931 next_addr_orig_p. Support PR external/20207 watchpoints.
2932 (aarch64_downgrade_regs): New.
2933 (aarch64_dr_state_insert_one_point): New parameters offset and
2934 addr_orig.
2935 (aarch64_dr_state_remove_one_point): Likewise.
2936 (aarch64_handle_breakpoint): Update caller.
2937 (aarch64_handle_aligned_watchpoint): Likewise.
2938 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
2939 aligned_offset.
2940 (aarch64_linux_set_debug_regs): Remove const from state. Call
2941 aarch64_downgrade_regs.
2942 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
2943 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
2944 (DR_CONTROL_MASK): ... this.
2945 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
2946 (unsigned int aarch64_watchpoint_offset): New prototype.
2947 (aarch64_linux_set_debug_regs): Remove const from state.
2948 * utils.c (align_up, align_down): Move to ...
2949 * common/common-utils.c (align_up, align_down): ... here.
2950 * utils.h (align_up, align_down): Move to ...
2951 * common/common-utils.h (align_up, align_down): ... here.
2952
05bc7456
JB
29532018-05-04 Joel Brobecker <brobecker@adacore.com>
2954
2955 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
2956 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
2957 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
2958 Re-implement to match the ABI as summarized in GCC's
2959 gcc/config/sparc/sparc.c. All callers updated.
2960 (sparc32_store_arguments): Remove assertion.
2961
2f433492
TT
29622018-05-04 Tom Tromey <tom@tromey.com>
2963
2964 * printcmd.c: Don't include tui.h.
2965 (decode_format): Use skip_spaces.
2966
9be2ae8f
TT
29672018-05-04 Tom Tromey <tom@tromey.com>
2968
2969 PR gdb/22619:
2970 * printcmd.c (last_count): New global.
2971 (x_command): Use saved count when repeating.
2972
f0b3976b
TT
29732018-05-04 Tom Tromey <tom@tromey.com>
2974
2975 * nto-procfs.c (do_closedir_cleanup): Remove.
2976 (procfs_pidlist): Use gdb_dir_up.
2977 * procfs.c (do_closedir_cleanup): Remove.
2978 (proc_update_threads): Use gdb_dir_up.
2979 * common/filestuff.h (struct gdb_dir_deleter): New.
2980 (gdb_dir_up): New typedef.
2981
862d101a
TT
29822018-05-04 Tom Tromey <tom@tromey.com>
2983
2984 * ada-lang.c (print_mention_exception): Use std::string.
2985
cb7de75e
TT
29862018-05-04 Tom Tromey <tom@tromey.com>
2987
2988 * ada-lang.c (create_excep_cond_exprs): Update.
2989 (ada_exception_catchpoint_cond_string): Use std::string.
2990
49d83361
TT
29912018-05-04 Tom Tromey <tom@tromey.com>
2992
2993 * ada-lang.c (xget_renaming_scope): Return std::string.
2994 (old_renaming_is_invisible): Update.
2995
ade72a34
TT
29962018-05-04 Tom Tromey <tom@tromey.com>
2997
2998 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
2999 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
3000
2be4d7f0
UW
30012018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
3002
3003 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
3004
69b6ecb0
TT
30052018-05-04 Tom Tromey <tom@tromey.com>
3006
3007 * remote.c (remote_query_supported_append): Change type.
3008 (remote_check_symbols): Update.
3009
bf27f0e2
PP
30102018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
3011
3012 PR gdb/11420
3013 * configure.ac: Prepend libpython.
3014 * python/python-config.py: Likewise.
3015 * configure: Regenerate.
3016
4ea17de8
SM
30172018-05-03 Simon Marchi <simon.marchi@ericsson.com>
3018
3019 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
3020
bd732259
PA
30212018-05-03 Pedro Alves <palves@redhat.com>
3022
3023 * s390-linux-nat.c
3024 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
3025 override. Write 'true' instead of '1'.
3026 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
3027 declaration.
3028
d9f719f1
PA
30292018-05-02 Pedro Alves <palves@redhat.com>
3030
3031 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
3032 add_inf_child_target.
3033 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
3034 add_inf_child_target.
3035 * aix-thread.c (aix_thread_target_info): New.
3036 (aix_thread_target) <shortname, longname, doc>: Delete.
3037 <info>: New.
3038 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
3039 add_inf_child_target.
3040 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
3041 add_inf_child_target.
3042 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
3043 add_inf_child_target.
3044 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
3045 add_inf_child_target.
3046 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
3047 add_inf_child_target.
3048 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
3049 add_inf_child_target.
3050 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
3051 add_inf_child_target.
3052 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
3053 add_inf_child_target.
3054 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
3055 add_inf_child_target.
3056 * bfd-target.c (target_bfd_target_info): New.
3057 (target_bfd) <shortname, longname, doc>: Delete.
3058 <info>: New.
3059 * bsd-kvm.c (bsd_kvm_target_info): New.
3060 (bsd_kvm_target) <shortname, longname, doc>: Delete.
3061 <info>: New.
3062 (bsd_kvm_target::open): Rename to ...
3063 (bsd_kvm_target_open): ... this. Adjust.
3064 * bsd-uthread.c (bsd_uthread_target_info): New.
3065 (bsd_uthread_target) <shortname, longname, doc>: Delete.
3066 <info>: New.
3067 * corefile.c (core_file_command): Adjust.
3068 * corelow.c (core_target_info): New.
3069 (core_target) <shortname, longname, doc>: Delete.
3070 <info>: New.
3071 (core_target::open): Rename to ...
3072 (core_target_open): ... this. Adjust.
3073 * ctf.c (ctf_target_info): New.
3074 (ctf_target) <shortname, longname, doc>: Delete.
3075 <info>: New.
3076 (ctf_target::open): Rename to ...
3077 (ctf_target_open): ... this.
3078 (_initialize_ctf): Adjust.
3079 * exec.c (exec_target_info): New.
3080 (exec_target) <shortname, longname, doc>: Delete.
3081 <info>: New.
3082 (exec_target::open): Rename to ...
3083 (exec_target_open): ... this.
3084 * gdbcore.h (core_target_open): Declare.
3085 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
3086 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
3087 add_inf_child_target.
3088 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
3089 add_inf_child_target.
3090 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
3091 add_inf_child_target.
3092 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
3093 add_inf_child_target.
3094 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
3095 add_inf_child_target.
3096 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
3097 add_inf_child_target.
3098 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
3099 add_inf_child_target.
3100 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
3101 add_inf_child_target.
3102 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
3103 add_inf_child_target.
3104 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
3105 add_inf_child_target.
3106 * inf-child.c (inf_child_target_info): New.
3107 (inf_child_target::info): New.
3108 (inf_child_open_target): Remove 'target' parameter. Use
3109 get_native_target instead.
3110 (inf_child_target::open): Delete.
3111 (add_inf_child_target): New.
3112 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
3113 Delete.
3114 <info>: New.
3115 (add_inf_child_target): Declare.
3116 (inf_child_open_target): Declare.
3117 * linux-thread-db.c (thread_db_target_info): New.
3118 (thread_db_target) <shortname, longname, doc>: Delete.
3119 <info>: New.
3120 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
3121 add_inf_child_target.
3122 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
3123 add_inf_child_target.
3124 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
3125 add_inf_child_target.
3126 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
3127 add_inf_child_target.
3128 * make-target-delegates (print_class): Adjust.
3129 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
3130 add_inf_child_target.
3131 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
3132 add_inf_child_target.
3133 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
3134 add_inf_child_target.
3135 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
3136 add_inf_child_target.
3137 * nto-procfs.c (nto_native_target_info): New.
3138 (nto_procfs_target_native) <shortname, longname, doc>:
3139 Delete.
3140 <info>: New.
3141 (nto_procfs_target_info): New.
3142 (nto_procfs_target_procfs) <shortname, longname, doc>:
3143 Delete.
3144 <info>: New.
3145 (init_procfs_targets): Adjust.
3146 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
3147 add_inf_child_target.
3148 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
3149 add_inf_child_target.
3150 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
3151 add_inf_child_target.
3152 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
3153 add_inf_child_target.
3154 * ravenscar-thread.c (ravenscar_target_info): New.
3155 (ravenscar_thread_target) <shortname, longname, doc>:
3156 Delete.
3157 <info>: New.
3158 * record-btrace.c (record_btrace_target_info):
3159 (record_btrace_target) <shortname, longname, doc>: Delete.
3160 <info>: New.
3161 (record_btrace_target::open): Rename to ...
3162 (record_btrace_target_open): ... this. Adjust.
3163 * record-full.c (record_longname, record_doc): New.
3164 (record_full_base_target) <shortname, longname, doc>: Delete.
3165 <info>: New.
3166 (record_full_target_info): New.
3167 (record_full_target): <shortname>: Delete.
3168 <info>: New.
3169 (record_full_core_open_1, record_full_open_1): Update comments.
3170 (record_full_base_target::open): Rename to ...
3171 (record_full_open): ... this.
3172 (cmd_record_full_restore): Update.
3173 (_initialize_record_full): Update.
3174 * remote-sim.c (remote_sim_target_info): New.
3175 (gdbsim_target) <shortname, longname, doc>: Delete.
3176 <info>: New.
3177 (gdbsim_target::open): Rename to ...
3178 (gdbsim_target_open): ... this.
3179 (_initialize_remote_sim): Adjust.
3180 * remote.c (remote_doc): New.
3181 (remote_target_info): New.
3182 (remote_target) <shortname, longname, doc>: Delete.
3183 <info>: New.
3184 (extended_remote_target_info): New.
3185 (extended_remote_target) <shortname, longname, doc>: Delete.
3186 <info>: New.
3187 (remote_target::open_1): Make static. Adjust.
3188 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
3189 * s390-linux-nat.c (_initialize_s390_nat): Use
3190 add_inf_child_target.
3191 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
3192 add_inf_child_target.
3193 * sol-thread.c (thread_db_target_info): New.
3194 (sol_thread_target) <shortname, longname, doc>: Delete.
3195 <info>: New.
3196 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
3197 add_inf_child_target.
3198 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
3199 add_inf_child_target.
3200 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
3201 add_inf_child_target.
3202 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
3203 add_inf_child_target.
3204 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
3205 add_inf_child_target.
3206 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
3207 add_inf_child_target.
3208 * spu-linux-nat.c (_initialize_spu_nat): Use
3209 add_inf_child_target.
3210 * spu-multiarch.c (spu_multiarch_target_info): New.
3211 (spu_multiarch_target) <shortname, longname, doc>: Delete.
3212 <info>: New.
3213 * target-delegates.c: Regenerate.
3214 * target.c: Include <unordered_map>.
3215 (target_ops_p): Delete.
3216 (DEF_VEC_P(target_ops_p)): Delete.
3217 (target_factories): New.
3218 (test_target_info): New.
3219 (test_target_ops::info): New.
3220 (open_target): Adjust to use target_factories.
3221 (add_target_with_completer): Rename to ...
3222 (add_target): ... this. Change prototype. Register target_info
3223 and open callback in target_factories. Register target_info in
3224 command context instead of target_ops.
3225 (add_target): Delete old implementation.
3226 (add_deprecated_target_alias): Change prototype. Adjust.
3227 (the_native_target): New.
3228 (set_native_target, get_native_target): New.
3229 (find_default_run_target): Use the_native_target.
3230 (find_attach_target, find_run_target): Simplify.
3231 (target_ops::open): Delete.
3232 (dummy_target_info): New.
3233 (dummy_target::shortname, dummy_target::longname)
3234 (dummy_target::doc): Delete.
3235 (dummy_target::info): New.
3236 (debug_target::shortname, debug_target::longname)
3237 (debug_target::doc): Delete.
3238 (debug_target::info): New.
3239 * target.h (struct target_info): New.
3240 (target_ops::~target_ops): Add comment.
3241 (target_ops::info): New.
3242 (target_ops::shortname, target_ops::longname, target_ops::doc): No
3243 longer virtual. Implement in terms of target_info.
3244 (set_native_target, get_native_target): Declare.
3245 (target_open_ftype): New.
3246 (add_target, add_target_with_completer)
3247 (add_deprecated_target_alias): Change prototype.
3248 (test_target) <shortname, longname, doc>: Delete.
3249 <info>: New.
3250 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
3251 add_inf_child_target.
3252 * tracefile-tfile.c (tfile_target_info): New.
3253 (tfile_target) <shortname, longname, doc>: Delete.
3254 <info>: New.
3255 (tfile_target::open): Rename to ...
3256 (tfile_target_open): ... this.
3257 (_initialize_tracefile_tfile): Adjust.
3258 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
3259 add_inf_child_target.
3260 * windows-nat.c (_initialize_windows_nat): Use
3261 add_inf_child_target.
3262 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
3263 add_inf_child_target.
3264
135340af
PA
32652018-05-02 Pedro Alves <palves@redhat.com>
3266
3267 * linux-nat.h (linux_nat_target) <low_new_thread,
3268 low_delete_thread, low_new_fork, low_forget_process,
3269 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
3270 New virtual methods.
3271 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
3272 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
3273 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
3274 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
3275 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
3276 Delete.
3277 * linux-fork.c (delete_fork): Adjust to call low method.
3278 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
3279 (linux_nat_new_fork, linux_nat_forget_process_hook)
3280 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
3281 (linux_nat_status_is_event):
3282 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
3283 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
3284 to call low method.
3285 (sigtrap_is_event): Rename to ...
3286 (linux_nat_target::low_status_is_event): ... this.
3287 (linux_nat_set_status_is_event): Delete.
3288 (save_stop_reason, linux_nat_wait_1)
3289 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
3290 low methods.
3291 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
3292 (linux_nat_set_new_fork, linux_nat_set_forget_process)
3293 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
3294 (linux_nat_set_prepare_to_resume): Delete.
3295 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
3296 low virtual methods.
3297 * amd64-linux-nat.c: Likewise.
3298 * arm-linux-nat.c: Likewise.
3299 * i386-linux-nat.c: Likewise.
3300 * ia64-linux-nat.c: Likewise.
3301 * mips-linux-nat.c: Likewise.
3302 * ppc-linux-nat.c: Likewise.
3303 * s390-linux-nat.c: Likewise.
3304 * sparc64-linux-nat.c: Likewise.
3305 * x86-linux-nat.c: Likewise.
3306 * x86-linux-nat.h: Include "nat/x86-linux.h".
3307 (x86_linux_nat_target) <low_new_fork, low_forget_process,
3308 low_prepare_to_resume, low_new_thread, low_delete_thread>:
3309 Override methods.
3310
57810aa7
PA
33112018-05-02 Pedro Alves <palves@redhat.com>
3312
3313 * target.h (target_ops)
3314 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
3315 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
3316 stopped_by_watchpoint, have_continuable_watchpoint,
3317 stopped_data_address, watchpoint_addr_within_range,
3318 can_accel_watchpoint_condition, can_run, thread_alive,
3319 has_all_memory, has_memory, has_stack, has_registers,
3320 has_execution, can_async_p, is_async_p, supports_non_stop,
3321 always_non_stop_p, can_execute_reverse, supports_multi_process,
3322 supports_enable_disable_tracepoint,
3323 supports_disable_randomization, supports_string_tracing,
3324 supports_evaluation_of_breakpoint_conditions,
3325 can_run_breakpoint_commands, filesystem_is_local,
3326 can_download_tracepoint, get_trace_state_variable_value,
3327 set_trace_notes, get_tib_address, use_agent, can_use_agent,
3328 record_is_replaying, record_will_replay,
3329 augmented_libraries_svr4_read>: Adjust to return bool.
3330 * aarch64-linux-nat.c: All implementations adjusted.
3331 * aix-thread.c: All implementations adjusted.
3332 * arm-linux-nat.c: All implementations adjusted.
3333 * breakpoint.c: All implementations adjusted.
3334 * bsd-kvm.c: All implementations adjusted.
3335 * bsd-uthread.c: All implementations adjusted.
3336 * corelow.c: All implementations adjusted.
3337 * ctf.c: All implementations adjusted.
3338 * darwin-nat.c: All implementations adjusted.
3339 * darwin-nat.h: All implementations adjusted.
3340 * exec.c: All implementations adjusted.
3341 * fbsd-nat.c: All implementations adjusted.
3342 * fbsd-nat.h: All implementations adjusted.
3343 * gnu-nat.c: All implementations adjusted.
3344 * gnu-nat.h: All implementations adjusted.
3345 * go32-nat.c: All implementations adjusted.
3346 * ia64-linux-nat.c: All implementations adjusted.
3347 * inf-child.c: All implementations adjusted.
3348 * inf-child.h: All implementations adjusted.
3349 * inf-ptrace.c: All implementations adjusted.
3350 * inf-ptrace.h: All implementations adjusted.
3351 * linux-nat.c: All implementations adjusted.
3352 * linux-nat.h: All implementations adjusted.
3353 * mips-linux-nat.c: All implementations adjusted.
3354 * nto-procfs.c: All implementations adjusted.
3355 * ppc-linux-nat.c: All implementations adjusted.
3356 * procfs.c: All implementations adjusted.
3357 * ravenscar-thread.c: All implementations adjusted.
3358 * record-btrace.c: All implementations adjusted.
3359 * record-full.c: All implementations adjusted.
3360 * remote-sim.c: All implementations adjusted.
3361 * remote.c: All implementations adjusted.
3362 * s390-linux-nat.c: All implementations adjusted.
3363 * sol-thread.c: All implementations adjusted.
3364 * spu-multiarch.c: All implementations adjusted.
3365 * target-delegates.c: All implementations adjusted.
3366 * target.c: All implementations adjusted.
3367 * target.h: All implementations adjusted.
3368 * tracefile-tfile.c: All implementations adjusted.
3369 * tracefile.c: All implementations adjusted.
3370 * tracefile.h: All implementations adjusted.
3371 * windows-nat.c: All implementations adjusted.
3372 * x86-linux-nat.h: All implementations adjusted.
3373 * x86-nat.h: All implementations adjusted.
3374
ad6a4e2d
PA
33752018-05-02 Pedro Alves <palves@redhat.com>
3376
3377 * make-target-delegates (scan_target_h): Don't trim lines here.
3378 Replace sequences of tabs and/or whitespace with a single
3379 whitespace.
3380 (top level, parsing methods): Trim each line before processing it
3381 here.
3382
f6ac5f3d
PA
33832018-05-02 Pedro Alves <palves@redhat.com>
3384 John Baldwin <jhb@freebsd.org>
3385
3386 * target.h (enum strata) <debug_stratum>: New.
3387 (struct target_ops) <all delegation methods>: Replace by C++
3388 virtual methods, and drop "to_" prefix. All references updated
3389 throughout.
3390 <to_shortname, to_longname, to_doc, to_data,
3391 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
3392 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
3393 virtual methods. All references updated throughout.
3394 <can_attach, supports_terminal_ours, can_create_inferior,
3395 get_thread_control_capabilities, attach_no_wait>: New
3396 virtual methods.
3397 <insert_breakpoint, remove_breakpoint>: Now
3398 TARGET_DEFAULT_NORETURN methods.
3399 <info_proc>: Now returns bool.
3400 <to_magic>: Delete.
3401 (OPS_MAGIC): Delete.
3402 (current_target): Delete. All references replaced by references
3403 to ...
3404 (target_stack): ... this. New.
3405 (target_shortname, target_longname): Adjust.
3406 (target_can_run): Now a function declaration.
3407 (default_child_has_all_memory, default_child_has_memory)
3408 (default_child_has_stack, default_child_has_registers)
3409 (default_child_has_execution): Remove target_ops parameter.
3410 (complete_target_initialization): Delete.
3411 (memory_breakpoint_target): New template class.
3412 (test_target_ops): Refactor as a C++ class with virtual methods.
3413 * make-target-delegates (NAME_PART): Tighten.
3414 (POINTER_PART, CP_SYMBOL): New.
3415 (SIMPLE_RETURN_PART): Reimplement.
3416 (VEC_RETURN_PART): Expect less.
3417 (RETURN_PART, VIRTUAL_PART): New.
3418 (METHOD): Adjust to C++ virtual methods.
3419 (scan_target_h): Remove reference to C99.
3420 (dname): Output "target_ops::" prefix.
3421 (write_function_header): Adjust to output a C++ class method.
3422 (write_declaration): New.
3423 (write_delegator): Adjust to output a C++ class method.
3424 (tdname): Output "dummy_target::" prefix.
3425 (write_tdefault, write_debugmethod): Adjust to output a C++ class
3426 method.
3427 (tdefault_names, debug_names): Delete.
3428 (return_types, tdefaults, styles, argtypes_array): New.
3429 (top level): All methods are delegators.
3430 (print_class): New.
3431 (top level): Print dummy_target and debug_target classes.
3432 * target-delegates.c: Regenerate.
3433 * target-debug.h (target_debug_print_enum_info_proc_what)
3434 (target_debug_print_thread_control_capabilities)
3435 (target_debug_print_thread_info_p): New.
3436 * target.c (dummy_target): Delete.
3437 (the_dummy_target, the_debug_target): New.
3438 (target_stack): Now extern.
3439 (set_targetdebug): Push/unpush debug target.
3440 (default_child_has_all_memory, default_child_has_memory)
3441 (default_child_has_stack, default_child_has_registers)
3442 (default_child_has_execution): Remove target_ops parameter.
3443 (complete_target_initialization): Delete.
3444 (add_target_with_completer): No longer call
3445 complete_target_initialization.
3446 (target_supports_terminal_ours): Use regular delegation.
3447 (update_current_target): Delete.
3448 (push_target): No longer check magic number. Don't call
3449 update_current_target.
3450 (unpush_target): Don't call update_current_target.
3451 (target_is_pushed): No longer check magic number.
3452 (target_require_runnable): Skip for all stratums over
3453 process_stratum.
3454 (target_ops::info_proc): New.
3455 (target_info_proc): Use find_target_at and
3456 find_default_run_target.
3457 (target_supports_disable_randomization): Use regular delegation.
3458 (target_get_osdata): Use find_target_at.
3459 (target_ops::open, target_ops::close, target_ops::can_attach)
3460 (target_ops::attach, target_ops::can_create_inferior)
3461 (target_ops::create_inferior, target_ops::can_run)
3462 (target_can_run): New.
3463 (default_fileio_target): Use regular delegation.
3464 (target_ops::fileio_open, target_ops::fileio_pwrite)
3465 (target_ops::fileio_pread, target_ops::fileio_fstat)
3466 (target_ops::fileio_close, target_ops::fileio_unlink)
3467 (target_ops::fileio_readlink): New.
3468 (target_fileio_open_1, target_fileio_unlink)
3469 (target_fileio_readlink): Always call the target method. Handle
3470 FILEIO_ENOSYS.
3471 (return_zero, return_zero_has_execution): Delete.
3472 (init_dummy_target): Delete.
3473 (dummy_target::dummy_target, dummy_target::shortname)
3474 (dummy_target::longname, dummy_target::doc)
3475 (debug_target::debug_target, debug_target::shortname)
3476 (debug_target::longname, debug_target::doc): New.
3477 (target_supports_delete_record): Use regular delegation.
3478 (setup_target_debug): Delete.
3479 (maintenance_print_target_stack): Skip debug_stratum.
3480 (initialize_targets): Instantiate the_dummy_target and
3481 the_debug_target.
3482 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
3483 use target_stack.
3484 (target_auxv_search, fprint_target_auxv): Adjust.
3485 (info_auxv_command): Adjust to use target_stack.
3486 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
3487 * exceptions.c (print_flush): Handle a NULL target_stack.
3488 * regcache.c (target_ops_no_register): Refactor as class with
3489 virtual methods.
3490
3491 * exec.c (exec_target): New class.
3492 (exec_ops): Now an exec_target.
3493 (exec_open, exec_close_1, exec_get_section_table)
3494 (exec_xfer_partial, exec_files_info, exec_has_memory)
3495 (exec_make_note_section): Refactor as exec_target methods.
3496 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
3497 Delete.
3498 (exec_target::find_memory_regions): New.
3499 (_initialize_exec): Don't call init_exec_ops.
3500 * gdbcore.h (exec_file_clear): Delete.
3501
3502 * corefile.c (core_target): Delete.
3503 (core_file_command): Adjust.
3504 * corelow.c (core_target): New class.
3505 (the_core_target): New.
3506 (core_close): Remove target_ops parameter.
3507 (core_close_cleanup): Adjust.
3508 (core_target::close): New.
3509 (core_open, core_detach, get_core_registers, core_files_info)
3510 (core_xfer_partial, core_thread_alive, core_read_description)
3511 (core_pid_to_str, core_thread_name, core_has_memory)
3512 (core_has_stack, core_has_registers, core_info_proc): Rework as
3513 core_target methods.
3514 (ignore, core_remove_breakpoint, init_core_ops): Delete.
3515 (_initialize_corelow): Initialize the_core_target.
3516 * gdbcore.h (core_target): Delete.
3517 (the_core_target): New.
3518
3519 * ctf.c: (ctf_target): New class.
3520 (ctf_ops): Now a ctf_target.
3521 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
3522 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
3523 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
3524 methods.
3525 (init_ctf_ops): Delete.
3526 (_initialize_ctf): Don't call it.
3527 * tracefile-tfile.c (tfile_target): New class.
3528 (tfile_ops): Now a tfile_target.
3529 (tfile_open, tfile_close, tfile_files_info)
3530 (tfile_get_tracepoint_status, tfile_trace_find)
3531 (tfile_fetch_registers, tfile_xfer_partial)
3532 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
3533 Refactor as tfile_target methods.
3534 (tfile_xfer_partial_features): Remove target_ops parameter.
3535 (init_tfile_ops): Delete.
3536 (_initialize_tracefile_tfile): Don't call it.
3537 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
3538 (tracefile_has_stack, tracefile_has_registers)
3539 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
3540 tracefile_target methods.
3541 (init_tracefile_ops): Delete.
3542 (tracefile_target::tracefile_target): New.
3543 * tracefile.h: Include "target.h".
3544 (tracefile_target): New class.
3545 (init_tracefile_ops): Delete.
3546
3547 * spu-multiarch.c (spu_multiarch_target): New class.
3548 (spu_ops): Now a spu_multiarch_target.
3549 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
3550 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
3551 (spu_search_memory, spu_mourn_inferior): Refactor as
3552 spu_multiarch_target methods.
3553 (init_spu_ops): Delete.
3554 (_initialize_spu_multiarch): Remove references to init_spu_ops,
3555 complete_target_initialization.
3556
3557 * ravenscar-thread.c (ravenscar_thread_target): New class.
3558 (ravenscar_ops): Now a ravenscar_thread_target.
3559 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
3560 (ravenscar_thread_alive, ravenscar_pid_to_str)
3561 (ravenscar_fetch_registers, ravenscar_store_registers)
3562 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
3563 (ravenscar_stopped_by_hw_breakpoint)
3564 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
3565 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
3566 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
3567 methods.
3568 (init_ravenscar_thread_ops): Delete.
3569 (_initialize_ravenscar): Remove references to
3570 init_ravenscar_thread_ops and complete_target_initialization.
3571
3572 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
3573 (bsd_uthread_target): New class.
3574 (bsd_uthread_ops): Now a bsd_uthread_target.
3575 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
3576 (bsd_uthread_close, bsd_uthread_mourn_inferior)
3577 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
3578 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
3579 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
3580 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
3581 (bsd_uthread_target): Delete function.
3582 (_initialize_bsd_uthread): Remove reference to
3583 complete_target_initialization.
3584
3585 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
3586 (target_bfd): ... this new class.
3587 (target_bfd_xfer_partial, target_bfd_get_section_table)
3588 (target_bfd_close): Refactor as target_bfd methods.
3589 (target_bfd::~target_bfd): New.
3590 (target_bfd_reopen): Adjust.
3591 (target_bfd::close): New.
3592
3593 * record-btrace.c (record_btrace_target): New class.
3594 (record_btrace_ops): Now a record_btrace_target.
3595 (record_btrace_open, record_btrace_stop_recording)
3596 (record_btrace_disconnect, record_btrace_close)
3597 (record_btrace_async, record_btrace_info)
3598 (record_btrace_insn_history, record_btrace_insn_history_range)
3599 (record_btrace_insn_history_from, record_btrace_call_history)
3600 (record_btrace_call_history_range)
3601 (record_btrace_call_history_from, record_btrace_record_method)
3602 (record_btrace_is_replaying, record_btrace_will_replay)
3603 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
3604 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
3605 (record_btrace_store_registers, record_btrace_prepare_to_store)
3606 (record_btrace_to_get_unwinder)
3607 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
3608 (record_btrace_commit_resume, record_btrace_wait)
3609 (record_btrace_stop, record_btrace_can_execute_reverse)
3610 (record_btrace_stopped_by_sw_breakpoint)
3611 (record_btrace_supports_stopped_by_sw_breakpoint)
3612 (record_btrace_stopped_by_hw_breakpoint)
3613 (record_btrace_supports_stopped_by_hw_breakpoint)
3614 (record_btrace_update_thread_list, record_btrace_thread_alive)
3615 (record_btrace_goto_begin, record_btrace_goto_end)
3616 (record_btrace_goto, record_btrace_stop_replaying_all)
3617 (record_btrace_execution_direction)
3618 (record_btrace_prepare_to_generate_core)
3619 (record_btrace_done_generating_core): Refactor as
3620 record_btrace_target methods.
3621 (init_record_btrace_ops): Delete.
3622 (_initialize_record_btrace): Remove reference to
3623 init_record_btrace_ops.
3624 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
3625 the execution_direction global.
3626 (record_full_base_target, record_full_target)
3627 (record_full_core_target): New classes.
3628 (record_full_ops): Now a record_full_target.
3629 (record_full_core_ops): Now a record_full_core_target.
3630 (record_full_target::detach, record_full_target::disconnect)
3631 (record_full_core_target::disconnect)
3632 (record_full_target::mourn_inferior, record_full_target::kill):
3633 New.
3634 (record_full_open, record_full_close, record_full_async): Refactor
3635 as methods of the record_full_base_target class.
3636 (record_full_resume, record_full_commit_resume): Refactor
3637 as methods of the record_full_target class.
3638 (record_full_wait, record_full_stopped_by_watchpoint)
3639 (record_full_stopped_data_address)
3640 (record_full_stopped_by_sw_breakpoint)
3641 (record_full_supports_stopped_by_sw_breakpoint)
3642 (record_full_stopped_by_hw_breakpoint)
3643 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
3644 methods of the record_full_base_target class.
3645 (record_full_store_registers, record_full_xfer_partial)
3646 (record_full_insert_breakpoint, record_full_remove_breakpoint):
3647 Refactor as methods of the record_full_target class.
3648 (record_full_can_execute_reverse, record_full_get_bookmark)
3649 (record_full_goto_bookmark, record_full_execution_direction)
3650 (record_full_record_method, record_full_info, record_full_delete)
3651 (record_full_is_replaying, record_full_will_replay)
3652 (record_full_goto_begin, record_full_goto_end, record_full_goto)
3653 (record_full_stop_replaying): Refactor as methods of the
3654 record_full_base_target class.
3655 (record_full_core_resume, record_full_core_kill)
3656 (record_full_core_fetch_registers)
3657 (record_full_core_prepare_to_store)
3658 (record_full_core_store_registers, record_full_core_xfer_partial)
3659 (record_full_core_insert_breakpoint)
3660 (record_full_core_remove_breakpoint)
3661 (record_full_core_has_execution): Refactor
3662 as methods of the record_full_core_target class.
3663 (record_full_base_target::supports_delete_record): New.
3664 (init_record_full_ops): Delete.
3665 (init_record_full_core_ops): Delete.
3666 (record_full_save): Refactor as method of the
3667 record_full_base_target class.
3668 (_initialize_record_full): Remove references to
3669 init_record_full_ops and init_record_full_core_ops.
3670
3671 * remote.c (remote_target, extended_remote_target): New classes.
3672 (remote_ops): Now a remote_target.
3673 (extended_remote_ops): Now an extended_remote_target.
3674 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
3675 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
3676 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
3677 (remote_pass_signals, remote_set_syscall_catchpoint)
3678 (remote_program_signals, )
3679 (remote_thread_always_alive): Remove target_ops parameter.
3680 (remote_thread_alive, remote_thread_name)
3681 (remote_update_thread_list, remote_threads_extra_info)
3682 (remote_static_tracepoint_marker_at)
3683 (remote_static_tracepoint_markers_by_strid)
3684 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
3685 (remote_open): Refactor as methods of remote_target.
3686 (extended_remote_open, extended_remote_detach)
3687 (extended_remote_attach, extended_remote_post_attach):
3688 (extended_remote_supports_disable_randomization)
3689 (extended_remote_create_inferior): : Refactor as method of
3690 extended_remote_target.
3691 (remote_set_permissions, remote_open_1, remote_detach)
3692 (remote_follow_fork, remote_follow_exec, remote_disconnect)
3693 (remote_resume, remote_commit_resume, remote_stop)
3694 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
3695 (remote_terminal_ours, remote_wait, remote_fetch_registers)
3696 (remote_prepare_to_store, remote_store_registers)
3697 (remote_flash_erase, remote_flash_done, remote_files_info)
3698 (remote_kill, remote_mourn, remote_insert_breakpoint)
3699 (remote_remove_breakpoint, remote_insert_watchpoint)
3700 (remote_watchpoint_addr_within_range)
3701 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
3702 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
3703 (remote_supports_stopped_by_sw_breakpoint)
3704 (remote_stopped_by_hw_breakpoint)
3705 (remote_supports_stopped_by_hw_breakpoint)
3706 (remote_stopped_by_watchpoint, remote_stopped_data_address)
3707 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
3708 (remote_verify_memory): Refactor as methods of remote_target.
3709 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
3710 parameter.
3711 (remote_xfer_partial, remote_get_memory_xfer_limit)
3712 (remote_search_memory, remote_rcmd, remote_memory_map)
3713 (remote_pid_to_str, remote_get_thread_local_address)
3714 (remote_get_tib_address, remote_read_description): Refactor as
3715 methods of remote_target.
3716 (remote_target::fileio_open, remote_target::fileio_pwrite)
3717 (remote_target::fileio_pread, remote_target::fileio_close): New.
3718 (remote_hostio_readlink, remote_hostio_fstat)
3719 (remote_filesystem_is_local, remote_can_execute_reverse)
3720 (remote_supports_non_stop, remote_supports_disable_randomization)
3721 (remote_supports_multi_process, remote_supports_cond_breakpoints)
3722 (remote_supports_enable_disable_tracepoint)
3723 (remote_supports_string_tracing)
3724 (remote_can_run_breakpoint_commands, remote_trace_init)
3725 (remote_download_tracepoint, remote_can_download_tracepoint)
3726 (remote_download_trace_state_variable, remote_enable_tracepoint)
3727 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
3728 (remote_trace_start, remote_get_trace_status)
3729 (remote_get_tracepoint_status, remote_trace_stop)
3730 (remote_trace_find, remote_get_trace_state_variable_value)
3731 (remote_save_trace_data, remote_get_raw_trace_data)
3732 (remote_set_disconnected_tracing, remote_core_of_thread)
3733 (remote_set_circular_trace_buffer, remote_traceframe_info)
3734 (remote_get_min_fast_tracepoint_insn_len)
3735 (remote_set_trace_buffer_size, remote_set_trace_notes)
3736 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
3737 (remote_disable_btrace, remote_teardown_btrace)
3738 (remote_read_btrace, remote_btrace_conf)
3739 (remote_augmented_libraries_svr4_read, remote_load)
3740 (remote_pid_to_exec_file, remote_can_do_single_step)
3741 (remote_execution_direction, remote_thread_handle_to_thread_info):
3742 Refactor as methods of remote_target.
3743 (init_remote_ops, init_extended_remote_ops): Delete.
3744 (remote_can_async_p, remote_is_async_p, remote_async)
3745 (remote_thread_events, remote_upload_tracepoints)
3746 (remote_upload_trace_state_variables): Refactor as methods of
3747 remote_target.
3748 (_initialize_remote): Remove references to init_remote_ops and
3749 init_extended_remote_ops.
3750
3751 * remote-sim.c (gdbsim_target): New class.
3752 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
3753 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
3754 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
3755 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
3756 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
3757 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
3758 Refactor as methods of gdbsim_target.
3759 (gdbsim_ops): Now a gdbsim_target.
3760 (init_gdbsim_ops): Delete.
3761 (gdbsim_cntrl_c): Adjust.
3762 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
3763
3764 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
3765 (the_amd64_linux_nat_target): New.
3766 (amd64_linux_fetch_inferior_registers)
3767 (amd64_linux_store_inferior_registers): Refactor as methods of
3768 amd64_linux_nat_target.
3769 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
3770 * i386-linux-nat.c: Don't include "linux-nat.h".
3771 (i386_linux_nat_target): New class.
3772 (the_i386_linux_nat_target): New.
3773 (i386_linux_fetch_inferior_registers)
3774 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
3775 as methods of i386_linux_nat_target.
3776 (_initialize_i386_linux_nat): Adjust. Set linux_target.
3777 * inf-child.c (inf_child_ops): Delete.
3778 (inf_child_fetch_inferior_registers)
3779 (inf_child_store_inferior_registers): Delete.
3780 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
3781 methods of inf_child_target.
3782 (inf_child_target::supports_terminal_ours)
3783 (inf_child_target::terminal_init)
3784 (inf_child_target::terminal_inferior)
3785 (inf_child_target::terminal_ours_for_output)
3786 (inf_child_target::terminal_ours, inf_child_target::interrupt)
3787 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
3788 New.
3789 (inf_child_open, inf_child_disconnect, inf_child_close)
3790 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
3791 (inf_child_post_startup_inferior, inf_child_can_run)
3792 (inf_child_pid_to_exec_file): Refactor as methods of
3793 inf_child_target.
3794 (inf_child_follow_fork): Delete.
3795 (inf_child_target::can_create_inferior)
3796 (inf_child_target::can_attach): New.
3797 (inf_child_target::has_all_memory, inf_child_target::has_memory)
3798 (inf_child_target::has_stack, inf_child_target::has_registers)
3799 (inf_child_target::has_execution): New.
3800 (inf_child_fileio_open, inf_child_fileio_pwrite)
3801 (inf_child_fileio_pread, inf_child_fileio_fstat)
3802 (inf_child_fileio_close, inf_child_fileio_unlink)
3803 (inf_child_fileio_readlink, inf_child_use_agent)
3804 (inf_child_can_use_agent): Refactor as methods of
3805 inf_child_target.
3806 (return_zero, inf_child_target): Delete.
3807 (inf_child_target::inf_child_target): New.
3808 * inf-child.h: Include "target.h".
3809 (inf_child_target): Delete function prototype.
3810 (inf_child_target): New class.
3811 (inf_child_open_target, inf_child_mourn_inferior)
3812 (inf_child_maybe_unpush_target): Delete.
3813 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
3814 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
3815 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
3816 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
3817 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
3818 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
3819 (inf_ptrace_wait, inf_ptrace_xfer_partial)
3820 (inf_ptrace_thread_alive, inf_ptrace_files_info)
3821 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
3822 methods of inf_ptrace_target.
3823 (inf_ptrace_target): Delete function.
3824 * inf-ptrace.h: Include "inf-child.h".
3825 (inf_ptrace_target): Delete function declaration.
3826 (inf_ptrace_target): New class.
3827 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
3828 * linux-nat.c (linux_target): New.
3829 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
3830 (linux_nat_target::~linux_nat_target): New.
3831 (linux_child_post_attach, linux_child_post_startup_inferior)
3832 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
3833 (linux_child_remove_fork_catchpoint)
3834 (linux_child_insert_vfork_catchpoint)
3835 (linux_child_remove_vfork_catchpoint)
3836 (linux_child_insert_exec_catchpoint)
3837 (linux_child_remove_exec_catchpoint)
3838 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
3839 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
3840 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
3841 (linux_nat_stopped_data_address)
3842 (linux_nat_stopped_by_sw_breakpoint)
3843 (linux_nat_supports_stopped_by_sw_breakpoint)
3844 (linux_nat_stopped_by_hw_breakpoint)
3845 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
3846 (linux_nat_kill, linux_nat_mourn_inferior)
3847 (linux_nat_xfer_partial, linux_nat_thread_alive)
3848 (linux_nat_update_thread_list, linux_nat_pid_to_str)
3849 (linux_nat_thread_name, linux_child_pid_to_exec_file)
3850 (linux_child_static_tracepoint_markers_by_strid)
3851 (linux_nat_is_async_p, linux_nat_can_async_p)
3852 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
3853 (linux_nat_supports_multi_process)
3854 (linux_nat_supports_disable_randomization, linux_nat_async)
3855 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
3856 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
3857 (linux_nat_fileio_open, linux_nat_fileio_readlink)
3858 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
3859 methods of linux_nat_target.
3860 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
3861 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
3862 parameter.
3863 (check_stopped_by_watchpoint): Adjust.
3864 (linux_xfer_partial): Delete.
3865 (linux_target_install_ops, linux_target, linux_nat_add_target):
3866 Delete.
3867 (linux_nat_target::linux_nat_target): New.
3868 * linux-nat.h: Include "inf-ptrace.h".
3869 (linux_nat_target): New.
3870 (linux_target, linux_target_install_ops, linux_nat_add_target):
3871 Delete function declarations.
3872 (linux_target): Declare global.
3873 * linux-thread-db.c (thread_db_target): New.
3874 (thread_db_target::thread_db_target): New.
3875 (thread_db_ops): Delete.
3876 (the_thread_db_target): New.
3877 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
3878 (thread_db_update_thread_list, thread_db_pid_to_str)
3879 (thread_db_extra_thread_info)
3880 (thread_db_thread_handle_to_thread_info)
3881 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
3882 (thread_db_resume): Refactor as methods of thread_db_target.
3883 (init_thread_db_ops): Delete.
3884 (_initialize_thread_db): Remove reference to init_thread_db_ops.
3885 * x86-linux-nat.c: Don't include "linux-nat.h".
3886 (super_post_startup_inferior): Delete.
3887 (x86_linux_nat_target::~x86_linux_nat_target): New.
3888 (x86_linux_child_post_startup_inferior)
3889 (x86_linux_read_description, x86_linux_enable_btrace)
3890 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
3891 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
3892 methods of x86_linux_nat_target.
3893 (x86_linux_create_target): Delete. Bits folded ...
3894 (x86_linux_add_target): ... here. Now takes a linux_nat_target
3895 pointer.
3896 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
3897 (x86_linux_nat_target): New class.
3898 (x86_linux_create_target): Delete.
3899 (x86_linux_add_target): Now takes a linux_nat_target pointer.
3900 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
3901 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
3902 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
3903 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
3904 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
3905 make extern.
3906 (x86_use_watchpoints): Delete.
3907 * x86-nat.h: Include "breakpoint.h" and "target.h".
3908 (x86_use_watchpoints): Delete.
3909 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
3910 (x86_stopped_by_watchpoint, x86_stopped_data_address)
3911 (x86_insert_watchpoint, x86_remove_watchpoint)
3912 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
3913 (x86_stopped_by_hw_breakpoint): New declarations.
3914 (x86_nat_target): New template class.
3915
3916 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
3917 (the_ppc_linux_nat_target): New.
3918 (ppc_linux_fetch_inferior_registers)
3919 (ppc_linux_can_use_hw_breakpoint)
3920 (ppc_linux_region_ok_for_hw_watchpoint)
3921 (ppc_linux_ranged_break_num_registers)
3922 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
3923 (ppc_linux_insert_mask_watchpoint)
3924 (ppc_linux_remove_mask_watchpoint)
3925 (ppc_linux_can_accel_watchpoint_condition)
3926 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
3927 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
3928 (ppc_linux_watchpoint_addr_within_range)
3929 (ppc_linux_masked_watch_num_registers)
3930 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
3931 (ppc_linux_read_description): Refactor as methods of
3932 ppc_linux_nat_target.
3933 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
3934
3935 * procfs.c (procfs_xfer_partial): Delete forward declaration.
3936 (procfs_target): New class.
3937 (the_procfs_target): New.
3938 (procfs_target): Delete function.
3939 (procfs_auxv_parse, procfs_attach, procfs_detach)
3940 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
3941 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
3942 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
3943 (procfs_create_inferior, procfs_update_thread_list)
3944 (procfs_thread_alive, procfs_pid_to_str)
3945 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
3946 (procfs_stopped_data_address, procfs_insert_watchpoint)
3947 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
3948 (proc_find_memory_regions, procfs_info_proc)
3949 (procfs_make_note_section): Refactor as methods of procfs_target.
3950 (_initialize_procfs): Adjust.
3951 * sol-thread.c (sol_thread_target): New class.
3952 (sol_thread_ops): Now a sol_thread_target.
3953 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
3954 (sol_thread_fetch_registers, sol_thread_store_registers)
3955 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
3956 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
3957 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
3958 (init_sol_thread_ops): Delete.
3959 (_initialize_sol_thread): Adjust. Remove references to
3960 init_sol_thread_ops and complete_target_initialization.
3961
3962 * windows-nat.c (windows_nat_target): New class.
3963 (windows_fetch_inferior_registers)
3964 (windows_store_inferior_registers, windows_resume, windows_wait)
3965 (windows_attach, windows_detach, windows_pid_to_exec_file)
3966 (windows_files_info, windows_create_inferior)
3967 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
3968 (windows_close, windows_pid_to_str, windows_xfer_partial)
3969 (windows_get_tib_address, windows_get_ada_task_ptid)
3970 (windows_thread_name, windows_thread_alive): Refactor as
3971 windows_nat_target methods.
3972 (do_initial_windows_stuff): Adjust.
3973 (windows_target): Delete function.
3974 (_initialize_windows_nat): Adjust.
3975
3976 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
3977 (darwin_mourn_inferior, darwin_kill_inferior)
3978 (darwin_create_inferior, darwin_attach, darwin_detach)
3979 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
3980 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
3981 (darwin_supports_multi_process): Refactor as darwin_nat_target
3982 methods.
3983 (darwin_resume_to, darwin_files_info): Delete.
3984 (_initialize_darwin_inferior): Rename to ...
3985 (_initialize_darwin_nat): ... this. Adjust to C++ification.
3986 * darwin-nat.h: Include "inf-child.h".
3987 (darwin_nat_target): New class.
3988 (darwin_complete_target): Delete.
3989 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
3990 (darwin_target): New.
3991 (i386_darwin_fetch_inferior_registers)
3992 (i386_darwin_store_inferior_registers): Refactor as methods of
3993 darwin_nat_target.
3994 (darwin_complete_target): Delete, with ...
3995 (_initialize_i386_darwin_nat): ... bits factored out here.
3996
3997 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
3998 (the_alpha_linux_nat_target): New.
3999 (alpha_linux_register_u_offset): Refactor as
4000 alpha_linux_nat_target method.
4001 (_initialize_alpha_linux_nat): Adjust.
4002 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
4003 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
4004 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
4005 methods of linux_nat_trad_target.
4006 (linux_trad_target): Delete.
4007 * linux-nat-trad.h (linux_trad_target): Delete function.
4008 (linux_nat_trad_target): New class.
4009 * mips-linux-nat.c (mips_linux_nat_target): New class.
4010 (super_fetch_registers, super_store_registers, super_close):
4011 Delete.
4012 (the_mips_linux_nat_target): New.
4013 (mips64_linux_regsets_fetch_registers)
4014 (mips64_linux_regsets_store_registers)
4015 (mips64_linux_fetch_registers, mips64_linux_store_registers)
4016 (mips_linux_register_u_offset, mips_linux_read_description)
4017 (mips_linux_can_use_hw_breakpoint)
4018 (mips_linux_stopped_by_watchpoint)
4019 (mips_linux_stopped_data_address)
4020 (mips_linux_region_ok_for_hw_watchpoint)
4021 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
4022 (mips_linux_close): Refactor as methods of mips_linux_nat.
4023 (_initialize_mips_linux_nat): Adjust to C++ification.
4024
4025 * aix-thread.c (aix_thread_target): New class.
4026 (aix_thread_ops): Now an aix_thread_target.
4027 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
4028 (aix_thread_fetch_registers, aix_thread_store_registers)
4029 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
4030 (aix_thread_thread_alive, aix_thread_pid_to_str)
4031 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
4032 Refactor as methods of aix_thread_target.
4033 (init_aix_thread_ops): Delete.
4034 (_initialize_aix_thread): Remove references to init_aix_thread_ops
4035 and complete_target_initialization.
4036 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
4037 (rs6000_nat_target): New class.
4038 (the_rs6000_nat_target): New.
4039 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
4040 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
4041 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
4042 (super_create_inferior): Delete.
4043 (_initialize_rs6000_nat): Adjust to C++ification.
4044
4045 * arm-linux-nat.c (arm_linux_nat_target): New class.
4046 (the_arm_linux_nat_target): New.
4047 (arm_linux_fetch_inferior_registers)
4048 (arm_linux_store_inferior_registers, arm_linux_read_description)
4049 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
4050 (arm_linux_remove_hw_breakpoint)
4051 (arm_linux_region_ok_for_hw_watchpoint)
4052 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
4053 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
4054 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
4055 arm_linux_nat_target.
4056 (_initialize_arm_linux_nat): Adjust to C++ification.
4057
4058 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
4059 (the_aarch64_linux_nat_target): New.
4060 (aarch64_linux_fetch_inferior_registers)
4061 (aarch64_linux_store_inferior_registers)
4062 (aarch64_linux_child_post_startup_inferior)
4063 (aarch64_linux_read_description)
4064 (aarch64_linux_can_use_hw_breakpoint)
4065 (aarch64_linux_insert_hw_breakpoint)
4066 (aarch64_linux_remove_hw_breakpoint)
4067 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
4068 (aarch64_linux_region_ok_for_hw_watchpoint)
4069 (aarch64_linux_stopped_data_address)
4070 (aarch64_linux_stopped_by_watchpoint)
4071 (aarch64_linux_watchpoint_addr_within_range)
4072 (aarch64_linux_can_do_single_step): Refactor as methods of
4073 aarch64_linux_nat_target.
4074 (super_post_startup_inferior): Delete.
4075 (_initialize_aarch64_linux_nat): Adjust to C++ification.
4076
4077 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
4078 (the_hppa_linux_nat_target): New.
4079 (hppa_linux_fetch_inferior_registers)
4080 (hppa_linux_store_inferior_registers): Refactor as methods of
4081 hppa_linux_nat_target.
4082 (_initialize_hppa_linux_nat): Adjust to C++ification.
4083
4084 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
4085 (the_ia64_linux_nat_target): New.
4086 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
4087 (ia64_linux_stopped_data_address)
4088 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
4089 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
4090 ia64_linux_nat_target methods.
4091 (super_xfer_partial): Delete.
4092 (_initialize_ia64_linux_nat): Adjust to C++ification.
4093
4094 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
4095 (the_m32r_linux_nat_target): New.
4096 (m32r_linux_fetch_inferior_registers)
4097 (m32r_linux_store_inferior_registers): Refactor as
4098 m32r_linux_nat_target methods.
4099 (_initialize_m32r_linux_nat): Adjust to C++ification.
4100
4101 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
4102 (the_m68k_linux_nat_target): New.
4103 (m68k_linux_fetch_inferior_registers)
4104 (m68k_linux_store_inferior_registers): Refactor as
4105 m68k_linux_nat_target methods.
4106 (_initialize_m68k_linux_nat): Adjust to C++ification.
4107
4108 * s390-linux-nat.c (s390_linux_nat_target): New class.
4109 (the_s390_linux_nat_target): New.
4110 (s390_linux_fetch_inferior_registers)
4111 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
4112 (s390_insert_watchpoint, s390_remove_watchpoint)
4113 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
4114 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
4115 (s390_auxv_parse, s390_read_description): Refactor as methods of
4116 s390_linux_nat_target.
4117 (_initialize_s390_nat): Adjust to C++ification.
4118
4119 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
4120 (the_sparc_linux_nat_target): New.
4121 (_initialize_sparc_linux_nat): Adjust to C++ification.
4122 * sparc-nat.c (sparc_fetch_inferior_registers)
4123 (sparc_store_inferior_registers): Remove target_ops parameter.
4124 * sparc-nat.h (sparc_fetch_inferior_registers)
4125 (sparc_store_inferior_registers): Remove target_ops parameter.
4126 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
4127 (the_sparc64_linux_nat_target): New.
4128 (_initialize_sparc64_linux_nat): Adjust to C++ification.
4129
4130 * spu-linux-nat.c (spu_linux_nat_target): New class.
4131 (the_spu_linux_nat_target): New.
4132 (spu_child_post_startup_inferior, spu_child_post_attach)
4133 (spu_child_wait, spu_fetch_inferior_registers)
4134 (spu_store_inferior_registers, spu_xfer_partial)
4135 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
4136 methods.
4137 (_initialize_spu_nat): Adjust to C++ification.
4138
4139 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
4140 (the_tilegx_linux_nat_target): New.
4141 (fetch_inferior_registers, store_inferior_registers):
4142 Refactor as methods.
4143 (_initialize_tile_linux_nat): Adjust to C++ification.
4144
4145 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
4146 (the_xtensa_linux_nat_target): New.
4147 (xtensa_linux_fetch_inferior_registers)
4148 (xtensa_linux_store_inferior_registers): Refactor as
4149 xtensa_linux_nat_target methods.
4150 (_initialize_xtensa_linux_nat): Adjust to C++ification.
4151
4152 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
4153 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
4154 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
4155 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
4156 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
4157 (fbsd_stopped_by_sw_breakpoint)
4158 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
4159 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
4160 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
4161 (fbsd_post_startup_inferior, fbsd_post_attach)
4162 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
4163 (fbsd_set_syscall_catchpoint)
4164 (super_xfer_partial, super_resume, super_wait)
4165 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
4166 (fbsd_handle_debug_trap): Remove target_ops parameter.
4167 (fbsd_nat_add_target): Delete.
4168 * fbsd-nat.h: Include "inf-ptrace.h".
4169 (fbsd_nat_add_target): Delete.
4170 (USE_SIGTRAP_SIGINFO): Define.
4171 (fbsd_nat_target): New class.
4172
4173 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
4174 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
4175 (amd64bsd_target): Delete.
4176 * amd64-bsd-nat.h: New file.
4177 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
4178 "x86-bsd-nat.h".
4179 (amd64_fbsd_nat_target): New class.
4180 (the_amd64_fbsd_nat_target): New.
4181 (amd64fbsd_read_description): Refactor as method of
4182 amd64_fbsd_nat_target.
4183 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
4184 (_initialize_amd64fbsd_nat): Adjust to C++ification.
4185 * amd64-nat.h (amd64bsd_target): Delete function declaration.
4186 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
4187 (i386bsd_store_inferior_registers): Remove target_ops parameter.
4188 (i386bsd_target): Delete.
4189 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
4190 (i386bsd_fetch_inferior_registers)
4191 (i386bsd_store_inferior_registers): Declare.
4192 (i386_bsd_nat_target): New class.
4193 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
4194 (the_i386_fbsd_nat_target): New.
4195 (i386fbsd_resume, i386fbsd_read_description): Refactor as
4196 i386_fbsd_nat_target methods.
4197 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
4198 (_initialize_i386fbsd_nat): Adjust to C++ification.
4199 * x86-bsd-nat.c (super_mourn_inferior): Delete.
4200 (x86bsd_mourn_inferior, x86bsd_target): Delete.
4201 (_initialize_x86_bsd_nat): Adjust to C++ification.
4202 * x86-bsd-nat.h: Include "x86-nat.h".
4203 (x86bsd_target): Delete declaration.
4204 (x86bsd_nat_target): New class.
4205
4206 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
4207 (the_aarch64_fbsd_nat_target): New.
4208 (aarch64_fbsd_fetch_inferior_registers)
4209 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
4210 aarch64_fbsd_nat_target.
4211 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
4212 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
4213 (the_alpha_bsd_nat_target): New.
4214 (alphabsd_fetch_inferior_registers)
4215 (alphabsd_store_inferior_registers): Refactor as
4216 alpha_bsd_nat_target methods.
4217 (_initialize_alphabsd_nat): Refactor as methods of
4218 alpha_bsd_nat_target.
4219 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
4220 (the_amd64_nbsd_nat_target): New.
4221 (_initialize_amd64nbsd_nat): Adjust to C++ification.
4222 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
4223 (the_amd64_obsd_nat_target): New.
4224 (_initialize_amd64obsd_nat): Adjust to C++ification.
4225 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
4226 (the_arm_fbsd_nat_target): New.
4227 (arm_fbsd_fetch_inferior_registers)
4228 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
4229 (_initialize_arm_fbsd_nat): Refactor as methods of
4230 arm_fbsd_nat_target.
4231 (_initialize_arm_fbsd_nat): Adjust to C++ification.
4232 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
4233 (the_arm_netbsd_nat_target): New.
4234 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
4235 arm_netbsd_nat_target.
4236 (_initialize_arm_netbsd_nat): Adjust to C++ification.
4237 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
4238 (the_hppa_nbsd_nat_target): New.
4239 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
4240 hppa_nbsd_nat_target methods.
4241 (_initialize_hppanbsd_nat): Adjust to C++ification.
4242 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
4243 (the_hppa_obsd_nat_target): New.
4244 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
4245 methods of hppa_obsd_nat_target.
4246 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
4247 add_target.
4248 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
4249 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
4250 add_target.
4251 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
4252 (_initialize_i386obsd_nat): Use add_target.
4253 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
4254 (the_m68k_bsd_nat_target): New.
4255 (m68kbsd_fetch_inferior_registers)
4256 (m68kbsd_store_inferior_registers): Refactor as methods of
4257 m68k_bsd_nat_target.
4258 (_initialize_m68kbsd_nat): Adjust to C++ification.
4259 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
4260 (the_mips_fbsd_nat_target): New.
4261 (mips_fbsd_fetch_inferior_registers)
4262 (mips_fbsd_store_inferior_registers): Refactor as methods of
4263 mips_fbsd_nat_target.
4264 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
4265 add_target.
4266 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
4267 (the_mips_nbsd_nat_target): New.
4268 (mipsnbsd_fetch_inferior_registers)
4269 (mipsnbsd_store_inferior_registers): Refactor as methods of
4270 mips_nbsd_nat_target.
4271 (_initialize_mipsnbsd_nat): Adjust to C++ification.
4272 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
4273 (the_mips64_obsd_nat_target): New.
4274 (mips64obsd_fetch_inferior_registers)
4275 (mips64obsd_store_inferior_registers): Refactor as methods of
4276 mips64_obsd_nat_target.
4277 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
4278 add_target.
4279 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
4280 nbsd_nat_target.
4281 * nbsd-nat.h: Include "inf-ptrace.h".
4282 (nbsd_nat_target): New class.
4283 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
4284 (obsd_wait): Refactor as methods of obsd_nat_target.
4285 (obsd_add_target): Delete.
4286 * obsd-nat.h: Include "inf-ptrace.h".
4287 (obsd_nat_target): New class.
4288 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
4289 (the_ppc_fbsd_nat_target): New.
4290 (ppcfbsd_fetch_inferior_registers)
4291 (ppcfbsd_store_inferior_registers): Refactor as methods of
4292 ppc_fbsd_nat_target.
4293 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
4294 add_target.
4295 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
4296 (the_ppc_nbsd_nat_target): New.
4297 (ppcnbsd_fetch_inferior_registers)
4298 (ppcnbsd_store_inferior_registers): Refactor as methods of
4299 ppc_nbsd_nat_target.
4300 (_initialize_ppcnbsd_nat): Adjust to C++ification.
4301 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
4302 (the_ppc_obsd_nat_target): New.
4303 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
4304 methods of ppc_obsd_nat_target.
4305 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
4306 add_target.
4307 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
4308 (the_sh_nbsd_nat_target): New.
4309 (shnbsd_fetch_inferior_registers)
4310 (shnbsd_store_inferior_registers): Refactor as methods of
4311 sh_nbsd_nat_target.
4312 (_initialize_shnbsd_nat): Adjust to C++ification.
4313 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
4314 (inf_ptrace_xfer_partial): Delete.
4315 (sparc_xfer_partial, sparc_target): Delete.
4316 * sparc-nat.h (sparc_fetch_inferior_registers)
4317 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
4318 (sparc_target): Delete function declaration.
4319 (sparc_target): New template class.
4320 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
4321 (_initialize_sparcnbsd_nat): Adjust to C++ification.
4322 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
4323 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
4324 add_target.
4325 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
4326 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
4327 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
4328 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
4329 add_target.
4330 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
4331 (the_vax_bsd_nat_target): New.
4332 (vaxbsd_fetch_inferior_registers)
4333 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
4334 methods.
4335 (_initialize_vaxbsd_nat): Adjust to C++ification.
4336
4337 * bsd-kvm.c (bsd_kvm_target): New class.
4338 (bsd_kvm_ops): Now a bsd_kvm_target.
4339 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
4340 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
4341 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
4342 bsd_kvm_target.
4343 (bsd_kvm_return_one): Delete.
4344 (bsd_kvm_add_target): Adjust to C++ification.
4345
4346 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
4347 (nto_procfs_target_procfs): New classes.
4348 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
4349 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
4350 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
4351 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
4352 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
4353 (procfs_remove_hw_breakpoint, procfs_resume)
4354 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
4355 (procfs_kill_inferior, procfs_store_registers)
4356 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
4357 as methods of nto_procfs_target.
4358 (nto_procfs_ops): Now an nto_procfs_target_procfs.
4359 (nto_native_ops): Delete.
4360 (procfs_open, procfs_native_open): Delete.
4361 (nto_native_ops): Now an nto_procfs_target_native.
4362 (init_procfs_targets): Adjust to C++ification.
4363 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
4364 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
4365 Refactor as methods of nto_procfs_target.
4366
4367 * go32-nat.c (go32_nat_target): New class.
4368 (the_go32_nat_target): New.
4369 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
4370 (go32_store_registers, go32_xfer_partial, go32_files_info)
4371 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
4372 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
4373 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
4374 (go32_pid_to_str): Refactor as methods of go32_nat_target.
4375 (go32_target): Delete.
4376 (_initialize_go32_nat): Adjust to C++ification.
4377
4378 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
4379 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
4380 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
4381 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
4382 gnu_nat_target.
4383 (gnu_target): Delete.
4384 * gnu-nat.h (gnu_target): Delete.
4385 (gnu_nat_target): New class.
4386 * i386-gnu-nat.c (gnu_base_target): New.
4387 (i386_gnu_nat_target): New class.
4388 (the_i386_gnu_nat_target): New.
4389 (_initialize_i386gnu_nat): Adjust to C++ification.
4390
3fffc070
PA
43912018-05-02 Pedro Alves <palves@redhat.com>
4392
4393 * bfd-target.c (target_bfd_xclose): Rename to ...
4394 (target_bfd_close): ... this.
4395 (target_bfd_reopen): Adjust.
4396 * target.c (target_close): Remove references to to_xclose.
4397 * target.h (target_ops::to_xclose): Delete.
4398 (target_ops::to_close): Update comments.
4399
6798487f
PA
44002018-05-02 Pedro Alves <palves@redhat.com>
4401
4402 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
4403 "linux-nat.h".
4404 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
4405 * inf-ptrace.c (inf_ptrace_register_u_offset)
4406 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
4407 (inf_ptrace_store_register, inf_ptrace_store_registers)
4408 (inf_ptrace_trad_target): Move to ...
4409 * linux-nat-trad.c: ... this new file.
4410 * linux-nat-trad.h: New file.
4411 * linux-nat.c (linux_target_install_ops): Make extern.
4412 (linux_trad_target): Delete.
4413 * linux-nat.h (linux_trad_target): Delete declaration.
4414 (linux_target_install_ops): Declare.
4415 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
4416 "linux-nat.h".
4417
c1955e17
PA
44182018-05-02 Pedro Alves <palves@redhat.com>
4419
4420 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
4421 procfs_target/add_target here.
4422 * procfs.c (procfs_target): Make static.
4423 (_initialize_procfs): Call add_target here.
4424 * procfs.h (struct target_ops): Remove forward declaration.
4425 (procfs_target): Remove declaration.
4426 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
4427
b5c8fcb1
PA
44282018-05-02 Pedro Alves <palves@redhat.com>
4429
4430 * procfs.c (procfs_stopped_by_watchpoint)
4431 (procfs_insert_watchpoint, procfs_remove_watchpoint)
4432 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
4433 Forward declare.
4434 (procfs_use_watchpoints): Delete, move contents...
4435 (procfs_target): ... here.
4436 * procfs.h (procfs_use_watchpoints): Delete declaration.
4437 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
4438 procfs_use_watchpoints.
4439 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
4440 procfs_use_watchpoints.
4441
0489430a
TT
44422018-05-02 Tom Tromey <tom@tromey.com>
4443
4444 PR python/20084:
4445 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
4446 and var_zuinteger_unlimited.
4447 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
4448 and PARAM_ZUINTEGER_UNLIMITED.
4449 (set_parameter_value): Handle var_zuinteger and
4450 var_zuinteger_unlimited.
4451 (add_setshow_generic): Likewise.
4452 (parmpy_init): Likewise.
4453
1632f8ba
DR
44542018-04-28 Dan Robertson <danlrobertson89@gmail.com>
4455
4456 PR rust/23124
4457 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
4458 pointer is not null before dereferencing it.
4459
76761936
TT
44602018-04-30 Tom Tromey <tom@tromey.com>
4461
4462 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
4463 is_mi_like_p.
4464
2d33446d
TT
44652018-04-30 Tom Tromey <tom@tromey.com>
4466
4467 * breakpoint.c (mention): Remove use of is_mi_like_p.
4468 (print_mention_ranged_breakpoint): Likewise.
4469 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
4470 of is_mi_like_p.
4471
f3c6abab
TT
44722018-04-30 Tom Tromey <tom@tromey.com>
4473
4474 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
4475
40c03530
TT
44762018-04-30 Tom Tromey <tom@tromey.com>
4477
4478 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
4479 (info_spu_event_command): Remove some uses of is_mi_like_p.
4480
2038b7fd
TT
44812018-04-30 Tom Tromey <tom@tromey.com>
4482
4483 * python/py-framefilter.c (py_print_single_arg)
4484 (enumerate_locals, py_print_args, py_print_frame): Remove some
4485 uses of is_mi_like_p.
4486
4904c3c6
TT
44872018-04-30 Tom Tromey <tom@tromey.com>
4488
4489 * ui-out.c: Update.
4490 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
4491 * ui-out.h (ui_out::is_mi_like_p): Now const.
4492 (ui_out::do_is_mi_like_p): Now const.
4493 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
4494
7c66fffc
TT
44952018-04-30 Tom Tromey <tom@tromey.com>
4496
4497 * varobj.c (varobj_set_visualizer): Use new_reference.
4498 * python/python.c (gdbpy_decode_line): Use new_reference.
4499 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
4500 new_reference.
4501
bbfa6f00
TT
45022018-04-30 Tom Tromey <tom@tromey.com>
4503
4504 * varobj.c (install_new_value): Use new_reference.
4505 * value.h (value_incref): Return void. Swap intro comment with
4506 value_decref.
4507 * value.c (set_value_parent): Use new_reference.
4508 (value_incref): Return void. Update intro comment.
4509 (release_value): Use new_reference.
4510 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
4511
1831a9f9
TT
45122018-04-30 Tom Tromey <tom@tromey.com>
4513
4514 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
4515 * gdb_bfd.h (new_bfd_ref): Remove.
4516 (gdb_bfd_open): Update comment.
4517 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
4518 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
4519 (gdb_bfd_fdopenr): Use new_reference.
4520 * exec.c (exec_file_attach): Use new_reference.
4521
7c1b5f3d
TT
45222018-04-30 Tom Tromey <tom@tromey.com>
4523
4524 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
4525 method.
4526
e11fb955
TT
45272018-04-30 Tom Tromey <tom@tromey.com>
4528
4529 * jit.c (jit_read_code_entry): Use type_align.
4530 * i386-tdep.c (i386_gdbarch_init): Don't call
4531 set_gdbarch_long_long_align_bit.
4532 * gdbarch.sh: Remove long_long_align_bit.
4533 * gdbarch.c, gdbarch.h: Rebuild.
4534 * arc-tdep.c (arc_type_align): New function.
4535 (arc_gdbarch_init): Use arc_type_align. Don't call
4536 set_gdbarch_long_long_align_bit.
4537
2fff16dd
TT
45382018-04-30 Tom Tromey <tom@tromey.com>
4539
4540 * rust-lang.c (rust_type_alignment): Remove.
4541 (rust_composite_type): Use type_align.
4542
6d7bb824
TT
45432018-04-30 Tom Tromey <tom@tromey.com>
4544
4545 * NEWS: Mention Type.align.
4546 * python/py-type.c (typy_get_alignof): New function.
4547 (type_object_getset): Add "alignof".
4548
007e1530
TT
45492018-04-30 Tom Tromey <tom@tromey.com>
4550
4551 PR exp/17095:
4552 * NEWS: Update.
4553 * std-operator.def (UNOP_ALIGNOF): New operator.
4554 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
4555 New.
4556 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
4557 * c-lang.c (c_op_print_tab): Add alignof.
4558 * c-exp.y (ALIGNOF): New token.
4559 (exp): Add "ALIGNOF" production.
4560 (ident_tokens): Add _Alignof and alignof.
4561
2b4424c3
TT
45622018-04-30 Tom Tromey <tom@tromey.com>
4563
4564 * i386-tdep.c (i386_type_align): New function.
4565 (i386_gdbarch_init): Update.
4566 * gdbarch.sh (type_align): New method.
4567 * gdbarch.c, gdbarch.h: Rebuild.
4568 * arch-utils.h (default_type_align): Declare.
4569 * arch-utils.c (default_type_align): New function.
4570 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
4571 (struct type) <align_log2>: New field.
4572 <instance_flags>: Now a bitfield.
4573 (TYPE_RAW_ALIGN): New macro.
4574 (type_align, type_raw_align, set_type_align): Declare.
4575 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
4576 functions.
4577 * dwarf2read.c (quirk_rust_enum): Set type alignment.
4578 (get_alignment, maybe_set_alignment): New functions.
4579 (read_structure_type, read_enumeration_type, read_array_type)
4580 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
4581 (read_subrange_type, read_base_type): Set type alignment.
4582
d33bc52e
SM
45832018-04-30 Simon Marchi <simon.marchi@ericsson.com>
4584
4585 * dwarf2read.c (read_index_from_section): Use bool.
4586
e28b63a9
FG
45872018-04-29 Fabian Groffen <grobian@gentoo.org>
4588
4589 PR gdb/22950
4590 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
4591 with #ifdef.
4592
cd8c76e4
JR
45932018-04-29 John Reiser <jreiser@BitWagon.com>
4594
4595 PR build/22873
4596 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
4597 last step, and do it atomically.
4598
476d250e
AO
45992018-04-27 Alexandre Oliva <aoliva@redhat.com>
4600
4601 * compile/compile-c-types.c (convert_int, convert_float):
4602 Update for C FE v1.
4603
6873858b
TT
46042018-04-27 Tom Tromey <tom@tromey.com>
4605
4606 PR rust/22545:
4607 * rust-lang.c (rust_inclusive_range_type_p): New function.
4608 (rust_range): Handle inclusive ranges.
4609 (rust_compute_range): Likewise.
4610 * rust-exp.y (struct rust_op) <inclusive>: New field.
4611 (DOTDOTEQ): New constant.
4612 (range_expr): Add "..=" productions.
4613 (operator_tokens): Add "..=" token.
4614 (ast_range): Add "inclusive" parameter.
4615 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
4616 ranges.
4617 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
4618 bounds values.
4619 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
4620 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
4621 Update comments.
4622 * expprint.c (print_subexp_standard): Handle new bounds values.
4623 (dump_subexp_body_standard): Likewise.
4624
632e107b
TT
46252018-04-27 Tom Tromey <tom@tromey.com>
4626
4627 * configure: Rebuild.
4628 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
4629 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
4630 "OVERRIDE".
4631 (class symbol_needs_eval_context): Likewise.
4632 * dwarf2read.c (mock_mapped_index::symbol_name_count)
4633 (mock_mapped_index::symbol_name_at): Use "override". Remove
4634 "virtual".
4635 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
4636 "override".
4637 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
4638 * aarch64-tdep.c (instruction_reader::read): Use "override".
4639 (instruction_reader_test::read): Likewise.
4640 * arm-tdep.c (instruction_reader::read): Use "override".
4641 (instruction_reader_thumb::read): Likewise.
4642
b75abf5b
AK
46432018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
4644
4645 PR remote/9665
4646 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
4647 instead of remote_send.
4648 (remote_send): Remove.
4649
79188d8d
PA
46502018-04-26 Pedro Alves <palves@redhat.com>
4651
4652 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
4653 find_function_start_sal instead of find_pc_line.
4654
f50776aa
PA
46552018-04-26 Pedro Alves <palves@redhat.com>
4656
4657 * breakpoint.c (set_breakpoint_location_function): Handle
4658 mst_data_gnu_ifunc.
4659 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
4660 * elfread.c (elf_symtab_read): Give data symbols with
4661 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
4662 (elf_rel_plt_read): Update comment.
4663 * linespec.c (convert_linespec_to_sals): Handle
4664 mst_data_gnu_ifunc.
4665 (minsym_found): Handle mst_data_gnu_ifunc.
4666 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
4667 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
4668 * parse.c (find_minsym_type_and_address): Handle
4669 mst_data_gnu_ifunc.
4670 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
4671 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
4672 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
4673 comment.
4674 <mst_data_gnu_ifunc>: New enumerator.
4675
20944a6e
PA
46762018-04-26 Pedro Alves <palves@redhat.com>
4677
4678 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
4679 (lookup_minimal_symbol_by_pc_section): ... this. Replace
4680 'want_trampoline' parameter by a lookup_msym_prefer parameter.
4681 Handle it.
4682 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
4683 (lookup_minimal_symbol_by_pc): Adjust.
4684 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
4685 (lookup_solib_trampoline_symbol_by_pc): Adjust.
4686 * minsyms.h (lookup_msym_prefer): New enum.
4687 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
4688 parameter by a lookup_msym_prefer parameter.
4689
1adeb822
PA
46902018-04-26 Pedro Alves <palves@redhat.com>
4691
4692 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
4693 ends in "@plt" instead of looking at the symbol's section.
4694
a0aca7b0
PA
46952018-04-26 Pedro Alves <palves@redhat.com>
4696
4697 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
4698 all references.
4699 (find_pc_partial_function_gnu_ifunc): Rename to ...
4700 (find_pc_partial_function): ... this, and remove references to
4701 'is_gnu_ifunc_p'.
4702 (find_pc_partial_function): Delete old implementation.
4703 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
4704
76af0f26
PA
47052018-04-26 Pedro Alves <palves@redhat.com>
4706
4707 * linespec.c (struct bound_minimal_symbol_search_key): New.
4708 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
4709 skip first line if we found a GNU ifunc minimal symbol by name.
4710 (compare_msymbols): Change parameters to work with a destructured
4711 lhs minsym.
4712 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
4713 functions.
4714
3467ec66
PA
47152018-04-26 Pedro Alves <palves@redhat.com>
4716
4717 * breakpoint.c (set_breakpoint_location_function): Don't resolve
4718 ifunc targets here. Instead, if we have an ifunc minsym, use its
4719 address/name.
4720 (add_location_to_breakpoint): Store the minsym and the objfile in
4721 the breakpoint location.
4722 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
4723 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
4724 Record the minsym in the sal.
4725 * symtab.h (symtab_and_line) <msymbol>: New field.
4726
28f4fa4d
PA
47272018-04-26 Pedro Alves <palves@redhat.com>
4728
4729 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
4730 unless we actually resolved the ifunc.
4731
ca31ab1d
PA
47322018-04-26 Pedro Alves <palves@redhat.com>
4733
4734 * c-exp.y (variable production): Prefer ifunc minsyms over
4735 regular function symbols.
4736 * symtab.c (find_gnu_ifunc): New function.
4737 * minsyms.h (lookup_msym_prefer): New enum.
4738 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
4739 parameter by a lookup_msym_prefer parameter.
4740 * symtab.h (find_gnu_ifunc): New declaration.
4741
8388016d
PA
47422018-04-26 Pedro Alves <palves@redhat.com>
4743
4744 * blockframe.c (find_gnu_ifunc_target_type): New function.
4745 (find_function_type): New.
4746 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
4747 return a value with a memory address.
4748 (eval_call): For calls to GNU ifunc functions, try to find the
4749 type of the target function from the type that the resolver
4750 returns.
4751 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
4752 symbols.
4753 * infcall.c (find_function_return_type): Delete.
4754 (find_function_addr): Add 'function_type' parameter. For calls to
4755 GNU ifunc functions, try to find the type of the target function
4756 from the type that the resolver returns, and return it via
4757 FUNCTION_TYPE.
4758 (call_function_by_hand_dummy): Adjust to use the function type
4759 returned by find_function_addr.
4760 (find_function_addr): Add 'function_type' parameter and move
4761 description here.
4762 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
4763 declarations.
4764
a376e11d
PA
47652018-04-26 Pedro Alves <palves@redhat.com>
4766
4767 * c-exp.y (variable production): Skip finding an alias for ifunc
4768 symbols.
4769
02e169e2
PA
47702018-04-26 Pedro Alves <palves@redhat.com>
4771
4772 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
4773
249b5733
PA
47742018-04-25 Pedro Alves <palves@redhat.com>
4775
4776 * infcmd.c (kill_command): Print the pid as string, not the whole
4777 thread's ptid. Add comment. s/has been killed/killed/ in output
4778 message.
4779 * remote.c (remote_detach_1): Print the pid as string, not the
4780 whole thread's ptid.
4781
f67c0c91
SDJ
47822018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
4783 Sergio Durigan Junior <sergiodj@redhat.com>
4784 Pedro Alves <palves@redhat.com>
4785
4786 * infcmd.c (kill_command): Print message when inferior has
4787 been killed.
4788 * inferior.c (print_inferior_events): Remove 'static'. Set as
4789 '1'.
4790 (add_inferior): Improve message printed when
4791 'print_inferior_events' is on.
4792 (exit_inferior): Remove message printed when
4793 'print_inferior_events' is on.
4794 (detach_inferior): Improve message printed when
4795 'print_inferior_events' is on.
4796 (initialize_inferiors): Use 'add_inferior_silent' to set
4797 'current_inferior_'.
4798 * inferior.h (print_inferior_events): Declare here as
4799 'extern'.
4800 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
4801 '[Detaching...]' messages when 'print_inferior_events' is on.
4802 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
4803 as prefix/suffix for messages. Remove periods. Fix erroneous
4804 'Detaching after fork from child...', replace it by '... from
4805 parent...'.
4806 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
4807 prefix/suffix when printing 'Detaching...' messages. Print
4808 them when 'print_inferior_events' is on.
4809 * remote.c (remote_detach_1): Print message when detaching
4810 from inferior and '!is_fork_parent'.
4811
e427af18
TT
48122018-04-24 Tom Tromey <tom@tromey.com>
4813
4814 * cli-out.h: Reindent.
4815
05b1d8d6
TT
48162018-04-24 Tom Tromey <tom@tromey.com>
4817
4818 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
4819 (cli_ui_out::do_field_string): Use fputs_filtered.
4820 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
4821
a95c7dab
TT
48222018-04-23 Tom Tromey <tom@tromey.com>
4823
4824 * guile/scm-frame.c (gdbscm_frame_read_var): Use
4825 gdb::unique_xmalloc_ptr.
4826
458412c3
TT
48272018-04-23 Tom Tromey <tom@tromey.com>
4828
4829 * configure: Rebuild.
4830
db86b02b
RS
48312018-04-22 Rajendra SY <rajendra.sy@gmail.com>
4832
4833 PR gdb/23095
4834 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
4835 prepare_for_testing. Set normal_bp to r_debug_state if target
4836 is bsd.
4837
00aecdcf
PA
48382018-04-21 Pedro Alves <palves@redhat.com>
4839 Rajendra SY <rajendra.sy@gmail.com>
4840
4841 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
4842 * remote.c (extended_remote_attach): In all-stop mode, mark the
4843 thread as executing.
4844
224608c3
PW
48452018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4846
4847 * thread.c (thread_apply_all_command): Fix comment.
4848 (thread_command): Fix comment.
4849
3b74854b
AH
48502018-04-10 Alan Hayward <alan.hayward@arm.com>
4851
4852 * common/tdesc.h (tdesc_create_feature): Remove xml filename
4853 parameter.
4854 * features/aarch64-core.c (create_feature_aarch64_core):
4855 Regenerate.
4856 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
4857 Likewise.
4858 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
4859 Likewise.
4860 * features/i386/32bit-avx512.c
4861 (create_feature_i386_32bit_avx512): Likewise.
4862 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
4863 Likewise.
4864 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
4865 Likewise.
4866 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
4867 Likewise.
4868 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
4869 Likewise.
4870 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
4871 Likewise.
4872 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
4873 Likewise.
4874 * features/i386/64bit-avx512.c
4875 (create_feature_i386_64bit_avx512): Likewise.
4876 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
4877 Likewise.
4878 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
4879 Likewise.
4880 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
4881 Likewise.
4882 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
4883 Likewise.
4884 * features/i386/64bit-segments.c
4885 (create_feature_i386_64bit_segments): Likewise.
4886 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
4887 Likewise.
4888 * features/i386/x32-core.c
4889 (create_feature_i386_x32_core): Likewise.
4890 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
4891 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
4892 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
4893 * target-descriptions.c: In generated code, don't pass xml
4894 filename.
4895
e98577a9
AH
48962018-04-18 Alan Hayward <alan.hayward@arm.com>
4897
4898 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
4899 (print_xml_feature::visit_post): Likewise.
4900 (print_xml_feature::visit): Likewise.
4901 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
4902 (print_xml_feature): Add new class.
4903 * regformats/regdat.sh: Null xmltarget on feature targets.
4904 * target-descriptions.c (struct target_desc): Add xmltarget.
4905 (maintenance_check_tdesc_xml_convert): Add unittest function.
4906 (tdesc_get_features_xml): Add function to get xml.
4907 (maintenance_check_xml_descriptions): Test xml generation.
4908 * xml-tdesc.c (string_read_description_xml): Add function.
4909 * xml-tdesc.h (string_read_description_xml): Add declaration.
4910
ad7fc756
AH
49112018-04-18 Alan Hayward <alan.hayward@arm.com>
4912
4913 * features/Makefile: Add feature marker to targets with new style
4914 target descriptions.
4915 * regformats/aarch64.dat: Regenerate.
4916 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
4917 * regformats/i386/amd64-avx-linux.dat: Likewise.
4918 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
4919 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
4920 * regformats/i386/amd64-linux.dat: Likewise.
4921 * regformats/i386/amd64-mpx-linux.dat: Likewise.
4922 * regformats/i386/amd64.dat: Likewise.
4923 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
4924 * regformats/i386/i386-avx-linux.dat: Likewise.
4925 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
4926 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
4927 * regformats/i386/i386-linux.dat: Likewise.
4928 * regformats/i386/i386-mmx-linux.dat: Likewise.
4929 * regformats/i386/i386-mpx-linux.dat: Likewise.
4930 * regformats/i386/i386.dat: Likewise.
4931 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
4932 * regformats/i386/x32-avx-linux.dat: Likewise.
4933 * regformats/i386/x32-linux.dat: Likewise.
4934 * regformats/tic6x-c62x-linux.dat: Likewise.
4935 * regformats/tic6x-c64x-linux.dat: Likewise.
4936 * regformats/tic6x-c64xp-linux.dat: Likewise.
4937 * regformats/regdat.sh: Parse feature marker.
4938
d278f585
AH
49392018-04-18 Alan Hayward <alan.hayward@arm.com>
4940
4941 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
4942 (tdesc_osabi_name): Likewise.
4943 * target-descriptions.c (tdesc_architecture_name): Add new
4944 function.
4945 (tdesc_osabi_name): Likewise.
4946
eee8a18d
AH
49472018-04-18 Alan Hayward <alan.hayward@arm.com>
4948
4949 * common/tdesc.c (tdesc_predefined_type): Move to here.
4950 (tdesc_named_type): Likewise.
4951 (tdesc_create_vector): Likewise.
4952 (tdesc_create_struct): Likewise.
4953 (tdesc_set_struct_size): Likewise.
4954 (tdesc_create_union): Likewise.
4955 (tdesc_create_flags): Likewise.
4956 (tdesc_create_enum): Likewise.
4957 (tdesc_add_field): Likewise.
4958 (tdesc_add_typed_bitfield): Likewise.
4959 (tdesc_add_bitfield): Likewise.
4960 (tdesc_add_flag): Likewise.
4961 (tdesc_add_enum_value): Likewise.
4962 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
4963 (struct tdesc_type_vector): Likewise.
4964 (struct tdesc_type_field): Likewise.
4965 (struct tdesc_type_with_fields): Likewise.
4966 (tdesc_create_enum): Add declaration.
4967 (tdesc_add_typed_bitfield): Likewise.
4968 (tdesc_add_enum_value): Likewise.
4969 * target-descriptions.c (tdesc_type_field): Move from here.
4970 (tdesc_type_builtin): Likewise.
4971 (tdesc_type_vector): Likewise.
4972 (tdesc_type_with_fields): Likewise.
4973 (tdesc_predefined_types): Likewise.
4974 (tdesc_named_type): Likewise.
4975 (tdesc_create_vector): Likewise.
4976 (tdesc_create_struct): Likewise.
4977 (tdesc_set_struct_size): Likewise.
4978 (tdesc_create_union): Likewise.
4979 (tdesc_create_flags): Likewise.
4980 (tdesc_create_enum): Likewise.
4981 (tdesc_add_field): Likewise.
4982 (tdesc_add_typed_bitfield): Likewise.
4983 (tdesc_add_bitfield): Likewise.
4984 (tdesc_add_flag): Likewise.
4985 (tdesc_add_enum_value): Likewise.
4986 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
4987 (tdesc_add_typed_bitfield): Likewise.
4988 (tdesc_add_enum_value): Likewise.
4989
82ec9bc7
AH
49902018-04-18 Alan Hayward <alan.hayward@arm.com>
4991
4992 * common/tdesc.c (tdesc_feature::accept): Move to here.
4993 (tdesc_feature::operator==): Likewise.
4994 (tdesc_create_reg): Likewise.
4995 * common/tdesc.h (tdesc_type_kind): Likewise.
4996 (struct tdesc_type): Likewise.
4997 (struct tdesc_feature): Likewise.
4998 * regformats/regdat.sh: Create a feature.
4999 * target-descriptions.c (tdesc_type_kind): Move from here.
5000 (tdesc_type): Likewise.
5001 (tdesc_type_up): Likewise.
5002 (tdesc_feature): Likewise.
5003 (tdesc_create_reg): Likewise.
5004
ea3e7d71
AH
50052018-04-18 Alan Hayward <alan.hayward@arm.com>
5006
5007 * Makefile.in: Add arch/tdesc.c
5008 * common/tdesc.c: New file.
5009 * common/tdesc.h (tdesc_element_visitor): Move to here.
5010 (tdesc_element): Likewise.
5011 (tdesc_reg): Likewise.
5012 (tdesc_reg_up): Likewise.
5013 * regformats/regdef.h (reg): Add offset to constructors.
5014 * target-descriptions.c (tdesc_element_visitor): Move from here.
5015 (tdesc_element): Likewise.
5016 (tdesc_reg): Likewise.
5017 (tdesc_reg_up): Likewise.
5018
bedda9ac
TT
50192018-04-17 Tom Tromey <tom@tromey.com>
5020
5021 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
5022 discriminant field.
5023
a037790e
TT
50242018-04-17 Tom Tromey <tom@tromey.com>
5025
5026 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
5027
c7dcbf88
AA
50282018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
5029
5030 * symtab.c (print_symbol_info): Skip printing filename and line
5031 number when `last' is NULL.
5032 (symtab_symbol_info): Use empty string instead of NULL for first
5033 invocation of print_symbol_info.
5034 (rbreak_command): Pass NULL to `last' parameter of
5035 print_symbol_info.
5036
07d28c77
SM
50372018-04-16 Simon Marchi <simon.marchi@ericsson.com>
5038
5039 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
5040 instead of nullptr.
5041
8a3de5e1
PA
50422018-04-16 Pedro Alves <palves@redhat.com>
5043
5044 * MAINTAINERS (sh): Remove.
5045 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
5046 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
5047 (ALLDEPFILES): Remove sh64-tdep.c.
5048 * NEWS: Mentions that support for SH-5/SH64 is removed.
5049 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
5050 (sh*-*-openbsd*): Ditto.
5051 (sh64-*-elf*): Remove.
5052 (sh*): Remove.
5053 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
5054 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
5055 * sh-tdep.c: No longer include "sh64-tdep.h".
5056 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
5057 * sh64-tdep.c, sh64-tdep.h: Remove files.
5058
a2a79012
PA
50592018-04-16 Pedro Alves <palves@redhat.com>
5060
5061 * MAINTAINERS: Remove m88k.
5062 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
5063 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
5064 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
5065 * NEWS: Mention that support for m88k was removed.
5066 * configure.host (m88*-*-*): Remove support.
5067 * configure.nat (m88k-*-*): Remove support.
5068 * configure.tgt (m88*-*-openbsd*): Remove.
5069 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
5070
eda4efb1
SM
50712018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
5072
5073 * configure.tgt (x86_tobjs): New variable.
5074 (amd64_tobjs, i386_tobjs): Use it.
5075
b744723f
AA
50762018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5077
5078 * symtab.c (print_symbol_info): Precede the symbol definition by
5079 the line number when available.
5080 * NEWS: Advertise this enhancement.
5081
4a4495d6
MM
50822018-04-13 Markus Metzger <markus.t.metzger@intel.com>
5083
5084 * NEWS (New options): announce set/show record btrace cpu.
5085 * btrace.c: Include record-btrace.h.
5086 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
5087 the vendor is unknown.
5088 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
5089 Maybe overwrite the btrace configuration's cpu.
5090 (btrace_compute_ftrace): Add cpu parameter. Update callers.
5091 (btrace_fetch): Add cpu parameter. Update callers.
5092 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
5093 Maybe overwrite the btrace configuration's cpu. Skip enabling
5094 errata workarounds if the vendor is unknown.
5095 * python/py-record-btrace.c: Include record-btrace.h.
5096 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
5097 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
5098 * record-btrace.c (record_btrace_cpu_state_kind): New.
5099 (record_btrace_cpu): New.
5100 (set_record_btrace_cpu_cmdlist): New.
5101 (record_btrace_get_cpu): New.
5102 (require_btrace_thread, record_btrace_info)
5103 (record_btrace_resume_thread): Call record_btrace_get_cpu.
5104 (cmd_set_record_btrace_cpu_none): New.
5105 (cmd_set_record_btrace_cpu_auto): New.
5106 (cmd_set_record_btrace_cpu): New.
5107 (cmd_show_record_btrace_cpu): New.
5108 (_initialize_record_btrace): Initialize set/show record btrace cpu
5109 commands.
5110 * record-btrace.h (record_btrace_get_cpu): New.
5111
69f90c75
MM
51122018-04-13 Markus Metzger <markus.t.metzger@intel.com>
5113
5114 * record.c (set_record_command): Fix typo in message.
5115
b85310e1
MM
51162018-04-13 Markus Metzger <markus.t.metzger@intel.com>
5117
5118 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
5119
1d509aa6
MM
51202018-04-13 Markus Metzger <markus.t.metzger@intel.com>
5121
5122 * infrun.c (process_event_stop_test): Call
5123 gdbarch_in_indirect_branch_thunk.
5124 * gdbarch.sh (in_indirect_branch_thunk): New.
5125 * gdbarch.c: Regenerated.
5126 * gdbarch.h: Regenerated.
5127 * x86-tdep.h: New.
5128 * x86-tdep.c: New.
5129 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
5130 (HFILES_NO_SRCDIR): Add x86-tdep.h.
5131 (ALLDEPFILES): Add x86-tdep.c.
5132 * arch-utils.h (default_in_indirect_branch_thunk): New.
5133 * arch-utils.c (default_in_indirect_branch_thunk): New.
5134 * i386-tdep: Include x86-tdep.h.
5135 (i386_in_indirect_branch_thunk): New.
5136 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
5137 function.
5138 * amd64-tdep: Include x86-tdep.h.
5139 (amd64_in_indirect_branch_thunk): New.
5140 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
5141
b4be9bfd
JK
51422018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
5143
5144 PR gdb/23053
5145 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
5146 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
5147 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
5148 regression.
5149
53d7df28
TT
51502018-04-12 Tom Tromey <tom@tromey.com>
5151
5152 * rust-lang.c (rust_print_struct_def): Remove univariant code.
5153 (rust_evaluate_subexp): Likewise.
5154
70b33f19
PA
51552018-04-12 Pedro Alves <palves@redhat.com>
5156
5157 * procfs.c (procfs_detach): Make forward declaration's prototype
5158 match definition's protototype.
5159 (proc_get_LDT_entry): Remove stale do_cleanups call.
5160
436411b1
PA
51612018-04-12 Pedro Alves <palves@redhat.com>
5162
5163 * target.h (target_ops::to_has_exited): Delete.
5164 (target_has_exited): Delete.
5165 * target-delegates.c: Regenerate.
5166
20db9c52
PA
51672018-04-11 Pedro Alves <palves@redhat.com>
5168
5169 * target.c (fileio_fh_t::t): Add comment.
5170 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
5171 (target_fileio_close): Handle a NULL target.
5172 (invalidate_fileio_fh): New.
5173 (target_close): Call it.
5174 * remote.c (remote_hostio_send_command): No longer check whether
5175 remote_desc is open.
5176
5ff79300
PA
51772018-04-11 Pedro Alves <palves@redhat.com>
5178
5179 * target.c (fileio_fh_t): Make it a named struct instead of a
5180 typedef.
5181 (fileio_fh_t::is_closed): New method.
5182 (DEF_VEC_O (fileio_fh_t)): Remove.
5183 (fileio_fhandles): Now a std::vector.
5184 (is_closed_fileio_fh): Delete.
5185 (acquire_fileio_fd): Adjust. Rename parameters.
5186 (release_fileio_fd): Adjust.
5187 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
5188 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
5189 (target_fileio_close): Adjust.
5190
6e22e10d
SM
51912018-04-10 Simon Marchi <simon.marchi@ericsson.com>
5192
5193 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
5194 index.
5195
731f534f
PA
51962018-04-10 Pedro Alves <palves@redhat.com>
5197
5198 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
5199 (scoped_finish_thread_state): New class.
5200 * infcmd.c (run_command_1): Use it instead of finish_thread_state
5201 cleanup.
5202 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
5203 (fetch_inferior_event, normal_stop): Likewise.
5204 * thread.c (finish_thread_state_cleanup): Delete.
5205
d5f4488f
SM
52062018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
5207 Pedro Alves <palves@redhat.com>
5208
5209 * value.c: Include "selftest.h" and "common/array-view.h".
5210 (struct range) <operator ==>: New.
5211 (test_ranges_contain): New.
5212 (check_ranges_vector): New.
5213 (test_insert_into_bit_range_vector): New.
5214 (_initialize_values): Register selftests.
5215 * common/array-view.h (operator==, operator!=): New.
5216
b24531ed
SM
52172018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
5218
5219 * common/gdb_vecs.h (unordered_remove): Add overload that takes
5220 an iterator.
5221 * inline-frame.c: Include <algorithm>.
5222 (struct inline_state): Add constructor.
5223 (inline_state_s): Remove.
5224 (DEF_VEC_O(inline_state_s)): Remove.
5225 (inline_states): Change type to std::vector.
5226 (find_inline_frame_state): Adjust to std::vector.
5227 (allocate_inline_frame_state): Remove.
5228 (clear_inline_frame_state): Adjust to std::vector.
5229 (skip_inline_frames): Adjust to std::vector.
5230
c252925c
SM
52312018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
5232
5233 * tracepoint.h (struct trace_state_variable): Add constructor.
5234 <name>: Change type to std::string.
5235 * tracepoint.c (tsv_s): Remove.
5236 (DEF_VEC_O(tsv_s)): Remove.
5237 (tvariables): Change to std::vector.
5238 (create_trace_state_variable): Adjust to std::vector.
5239 (find_trace_state_variable): Likewise.
5240 (find_trace_state_variable_by_number): Likewise.
5241 (delete_trace_state_variable): Likewise.
5242 (trace_variable_command): Adjust to std::string.
5243 (delete_trace_variable_command): Likewise.
5244 (tvariables_info_1): Adjust to std::vector.
5245 (save_trace_state_variables): Likewise.
5246 (start_tracing): Likewise.
5247 (merge_uploaded_trace_state_variables): Adjust to std::vector
5248 and std::string.
5249 * target.h (struct target_ops)
5250 <to_download_trace_state_variable>: Pass reference to
5251 trace_state_variable.
5252 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
5253 * target-delegates.c: Re-generate.
5254 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
5255 (mi_tsv_deleted): Likewise.
5256 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
5257 * remote.c (remote_download_trace_state_variable): Change
5258 pointer to reference and adjust.
5259 * make-target-delegates (parse_argtypes): Handle references.
5260 (write_function_header): Likewise.
5261 (munge_type): Likewise.
5262
c9638d26
SM
52632018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
5264
5265 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5266 string_view-selftests.c.
5267 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
5268 testsuite.
5269 * unittests/basic_string_view/cons/char/1.cc: Likewise.
5270 * unittests/basic_string_view/cons/char/2.cc: Likewise.
5271 * unittests/basic_string_view/cons/char/3.cc: Likewise.
5272 * unittests/basic_string_view/element_access/char/1.cc:
5273 Likewise.
5274 * unittests/basic_string_view/element_access/char/empty.cc:
5275 Likewise.
5276 * unittests/basic_string_view/element_access/char/front_back.cc:
5277 Likewise.
5278 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
5279 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
5280 Likewise.
5281 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
5282 Likewise.
5283 * unittests/basic_string_view/modifiers/swap/char/1.cc:
5284 Likewise.
5285 * unittests/basic_string_view/operations/compare/char/1.cc:
5286 Likewise.
5287 * unittests/basic_string_view/operations/compare/char/13650.cc:
5288 Likewise.
5289 * unittests/basic_string_view/operations/copy/char/1.cc:
5290 Likewise.
5291 * unittests/basic_string_view/operations/data/char/1.cc:
5292 Likewise.
5293 * unittests/basic_string_view/operations/find/char/1.cc:
5294 Likewise.
5295 * unittests/basic_string_view/operations/find/char/2.cc:
5296 Likewise.
5297 * unittests/basic_string_view/operations/find/char/3.cc:
5298 Likewise.
5299 * unittests/basic_string_view/operations/find/char/4.cc:
5300 Likewise.
5301 * unittests/basic_string_view/operations/rfind/char/1.cc:
5302 Likewise.
5303 * unittests/basic_string_view/operations/rfind/char/2.cc:
5304 Likewise.
5305 * unittests/basic_string_view/operations/rfind/char/3.cc:
5306 Likewise.
5307 * unittests/basic_string_view/operations/substr/char/1.cc:
5308 Likewise.
5309 * unittests/basic_string_view/operators/char/2.cc: Likewise.
5310 * unittests/string_view-selftests.c: New file.
5311
fdc11678
SM
53122018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
5313
5314 * unittests/basic_string_view/capacity/1.cc: New file.
5315 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
5316 * unittests/basic_string_view/cons/char/1.cc: New file.
5317 * unittests/basic_string_view/cons/char/2.cc: New file.
5318 * unittests/basic_string_view/cons/char/3.cc: New file.
5319 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
5320 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
5321 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
5322 * unittests/basic_string_view/element_access/char/1.cc: New file.
5323 * unittests/basic_string_view/element_access/char/2.cc: New file.
5324 * unittests/basic_string_view/element_access/char/empty.cc: New file.
5325 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
5326 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
5327 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
5328 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
5329 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
5330 * unittests/basic_string_view/include.cc: New file.
5331 * unittests/basic_string_view/inserters/char/1.cc: New file.
5332 * unittests/basic_string_view/inserters/char/2.cc: New file.
5333 * unittests/basic_string_view/inserters/char/3.cc: New file.
5334 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
5335 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
5336 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
5337 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
5338 * unittests/basic_string_view/literals/types.cc: New file.
5339 * unittests/basic_string_view/literals/values.cc: New file.
5340 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
5341 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
5342 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
5343 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
5344 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
5345 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
5346 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
5347 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
5348 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
5349 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
5350 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
5351 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
5352 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
5353 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
5354 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
5355 * unittests/basic_string_view/operations/data/char/1.cc: New file.
5356 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
5357 * unittests/basic_string_view/operations/find/char/1.cc: New file.
5358 * unittests/basic_string_view/operations/find/char/2.cc: New file.
5359 * unittests/basic_string_view/operations/find/char/3.cc: New file.
5360 * unittests/basic_string_view/operations/find/char/4.cc: New file.
5361 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
5362 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
5363 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
5364 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
5365 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
5366 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
5367 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
5368 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
5369 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
5370 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
5371 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
5372 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
5373 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
5374 * unittests/basic_string_view/operators/char/2.cc: New file.
5375 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
5376 * unittests/basic_string_view/range_access/char/1.cc: New file.
5377 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
5378 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
5379 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
5380 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
5381 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
5382 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
5383 * unittests/basic_string_view/requirements/typedefs.cc: New file.
5384 * unittests/basic_string_view/typedefs.cc: New file.
5385 * unittests/basic_string_view/types/1.cc: New file.
5386
8345c4a2
SM
53872018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
5388
5389 * common/gdb_string_view.h: Remove libstdc++ implementation
5390 details, adjust to gdb reality.
5391 * common/gdb_string_view.tcc: Likewise.
5392 * cli/cli-script.c (struct string_view): Remove.
5393 (user_args) <m_args>: Change element type to gdb::string_view.
5394 (user_args::insert_args): Adjust.
5395
7adcdf08
SM
53962018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
5397
5398 * common/gdb_string_view.h: New file.
5399 * common/gdb_string_view.tcc: New file.
5400
41260ac2
SM
54012018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
5402
5403 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
5404 * configure: Re-generate.
5405
0bee6dd4
PA
54062018-04-09 Pedro Alves <palves@redhat.com>
5407
5408 * gdbarch.sh: Include "observable.h" instead of "observer.h".
5409 (set_target_gdbarch): Call
5410 gdb::observers::architecture_changed.notify instead of
5411 observer_notify_architecture_changed.
5412
6f14adc5
SM
54132018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
5414
5415 * tracepoint.c (struct current_traceframe_cleanup): Remove.
5416 (do_restore_current_traceframe_cleanup): Remove.
5417 (restore_current_traceframe_cleanup_dtor): Remove.
5418 (make_cleanup_restore_current_traceframe): Remove.
5419 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
5420 New.
5421 * tracepoint.h (struct scoped_restore_current_traceframe): New.
5422 * infrun.c (fetch_inferior_event): Use
5423 scoped_restore_current_traceframe.
5424
b2bdb8cf
SM
54252018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
5426
5427 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
5428 Remove.
5429 <n_allocated_type_units>: Remove.
5430 <all_type_units>: Change to std::vector.
5431 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
5432 to std::vector change.
5433 (dwarf2_per_objfile::get_cutu): Likewise.
5434 (dwarf2_per_objfile::get_tu): Likewise.
5435 (create_signatured_type_table_from_index): Likewise.
5436 (create_signatured_type_table_from_debug_names): Likewise.
5437 (dw2_symtab_iter_next): Likewise.
5438 (dw2_print_stats): Likewise.
5439 (dw2_expand_all_symtabs): Likewise.
5440 (dw2_expand_marked_cus): Likewise.
5441 (dw2_debug_names_iterator::next): Likewise.
5442 (dwarf2_initialize_objfile): Likewise.
5443 (add_signatured_type_cu_to_table): Likewise.
5444 (create_all_type_units): Likewise.
5445 (add_type_unit): Likewise.
5446 (struct tu_abbrev_offset): Add constructor.
5447 (build_type_psymtabs_1): Adjust to std::vector change.
5448 (print_tu_stats): Likewise.
5449 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
5450 (write_debug_names): Likewise.
5451
b76e467d
SM
54522018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
5453
5454 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
5455 Make an std::vector.
5456 <n_comp_units>: Remove.
5457 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
5458 to std::vector change.
5459 (dwarf2_per_objfile::get_cutu): Likewise.
5460 (dwarf2_per_objfile::get_cu): Likewise.
5461 (create_cus_from_index): Likewise.
5462 (create_addrmap_from_index): Likewise.
5463 (create_addrmap_from_aranges): Likewise.
5464 (dwarf2_read_index): Likewise.
5465 (dw2_find_last_source_symtab): Likewise.
5466 (dw2_map_symtabs_matching_filename): Likewise.
5467 (dw2_symtab_iter_next): Likewise.
5468 (dw2_print_stats): Likewise.
5469 (dw2_expand_all_symtabs): Likewise.
5470 (dw2_expand_symtabs_with_fullname): Likewise.
5471 (dw2_expand_marked_cus): Likewise.
5472 (dw2_map_symbol_filenames): Likewise.
5473 (create_cus_from_debug_names): Likewise.
5474 (dwarf2_read_debug_names): Likewise.
5475 (dw2_debug_names_iterator::next): Likewise.
5476 (dwarf2_initialize_objfile): Likewise.
5477 (set_partial_user): Likewise.
5478 (dwarf2_build_psymtabs_hard): Likewise.
5479 (read_comp_units_from_section): Remove arguments, adjust to
5480 std::vector change.
5481 (create_all_comp_units): Adjust to std::vector and
5482 read_comp_units_from_section changes.
5483 (dwarf2_find_containing_comp_unit): Adjust to std::vector
5484 change.
5485 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
5486 (psyms_seen_size): Likewise.
5487 (write_gdbindex): Likewise.
5488 (write_debug_names): Likewise.
5489
12359b5e
SM
54902018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
5491
5492 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
5493 with dwarf2_per_objfile.
5494 (create_cus_from_index): Likewise.
5495 (create_signatured_type_table_from_index): Likewise.
5496 (dwarf2_read_index): Likewise.
5497 (dwarf2_initialize_objfile): Likewise.
5498 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
5499 per_cu rather than get_dwarf2_per_objfile.
5500
ff4c9fec
SM
55012018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
5502
5503 * dwarf2read.h (struct signatured_type): Forward declare.
5504 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
5505 New methods.
5506 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
5507 (dw2_get_cutu): ...this.
5508 (dwarf2_per_objfile::get_cu): Rename from...
5509 (dw2_get_cu): ...this.
5510 (dwarf2_per_objfile::get_tu): New.
5511 (create_addrmap_from_index): Adjust.
5512 (create_addrmap_from_aranges): Adjust.
5513 (dw2_find_last_source_symtab): Adjust.
5514 (dw2_map_symtabs_matching_filename): Adjust.
5515 (dw2_symtab_iter_next): Adjust.
5516 (dw2_print_stats): Adjust.
5517 (dw2_expand_all_symtabs): Adjust.
5518 (dw2_expand_symtabs_with_fullname): Adjust.
5519 (dw2_expand_marked_cus): Adjust.
5520 (dw_expand_symtabs_matching_file_matcher): Adjust.
5521 (dw2_map_symbol_filenames): Adjust.
5522 (dw2_debug_names_iterator::next): Adjust.
5523 (dwarf2_initialize_objfile): Adjust.
5524 (set_partial_user): Adjust.
5525 (dwarf2_build_psymtabs_hard): Adjust.
5526
5ca3fcb6
SM
55272018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
5528
5529 * dwarf2read.c (create_signatured_type_table_from_debug_names):
5530 Remove unused variables.
5531 (dw2_map_symtabs_matching_filename): Likewise.
5532 (dwarf2_record_block_ranges): Likewise.
5533 (dwarf2_read_addr_index): Likewise.
5534 (follow_die_offset): Likewise.
5535
b2e586e8
SM
55362018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
5537
5538 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
5539 to symbol_file_add_main.
5540
7c4e78cf
SM
55412018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
5542
5543 PR mi/22299
5544 * mi/mi-console.c (do_fputc_async_safe): New.
5545 (mi_console_file::write_async_safe): New.
5546 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
5547 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
5548 New.
5549 * ui-file.c (ui_file::putstrn): Adjust call to
5550 fputstrn_unfiltered.
5551 * utils.c (printchar): Replace do_fputs and do_fprintf
5552 parameters by do_fputc.
5553 (fputstr_filtered): Adjust call to printchar.
5554 (fputstr_unfiltered): Likewise.
5555 (fputstrn_filtered): Likewise.
5556 (fputstrn_unfiltered): Add do_fputc parameter, pass to
5557 printchar.
5558 * utils.h (do_fputc_ftype): New typedef.
5559 (fputstrn_unfiltered): Add do_fputc parameter.
5560
5dc026d3
SM
55612018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
5562
5563 * regformats/i386/i386-avx.dat: Remove.
5564
c912f608
SM
55652018-04-07 Simon Marchi <simon.marchi@ericsson.com>
5566
5567 PR gdb/22979
5568 * amd64-tdep.c (amd64_none_init_abi): New function.
5569 (amd64_x32_none_init_abi): New function.
5570 (_initialize_amd64_tdep): Register handlers for x86-64 and
5571 x64_32 with GDB_OSABI_NONE.
5572 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
5573 GDB_OSABI_NONE osabi.
5574
26540402
SM
55752018-04-07 Simon Marchi <simon.marchi@ericsson.com>
5576
5577 PR gdb/22980
5578 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
5579 GDB_OSABI_NONE.
5580 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
5581 * osabi.c (gdb_osabi_names): Add "unknown" entry.
5582
9018be22
SM
55832018-04-07 Simon Marchi <simon.marchi@ericsson.com>
5584
5585 * common/byte-vector.h (char_vector): New type.
5586 * target.h (target_read_alloc): Return
5587 gdb::optional<byte_vector>.
5588 (target_read_stralloc): Return gdb::optional<char_vector>.
5589 (target_get_osdata): Return gdb::optional<char_vector>.
5590 * target.c (target_read_alloc_1): Templatize. Replacement
5591 manual memory management with vector.
5592 (target_read_alloc): Change return type, adjust.
5593 (target_read_stralloc): Change return type, adjust.
5594 (target_get_osdata): Change return type, adjust.
5595 * auxv.c (struct auxv_info) <length>: Remove.
5596 <data>: Change type to gdb::optional<byte_vector>.
5597 (auxv_inferior_data_cleanup): Free auxv_info with delete.
5598 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
5599 (target_auxv_search): Adjust.
5600 (fprint_target_auxv): Adjust.
5601 * avr-tdep.c (avr_io_reg_read_command): Adjust.
5602 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
5603 (linux_make_corefile_notes): Adjust.
5604 * osdata.c (get_osdata): Adjust.
5605 * remote.c (remote_get_threads_with_qxfer): Adjust.
5606 (remote_memory_map): Adjust.
5607 (remote_traceframe_info): Adjust.
5608 (btrace_read_config): Adjust.
5609 (remote_read_btrace): Adjust.
5610 (remote_pid_to_exec_file): Adjust.
5611 * solib-aix.c (solib_aix_get_library_list): Adjust.
5612 * solib-dsbt.c (decode_loadmap): Don't free buf.
5613 (dsbt_get_initial_loadmaps): Adjust.
5614 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
5615 * solib-target.c (solib_target_current_sos): Adjust.
5616 * tracepoint.c (sdata_make_value): Adjust.
5617 * xml-support.c (xinclude_start_include): Adjust.
5618 (xml_fetch_content_from_file): Adjust.
5619 * xml-support.h (xml_fetch_another): Change return type.
5620 (xml_fetch_content_from_file): Change return type.
5621 * xml-syscall.c (xml_init_syscalls_info): Adjust.
5622 * xml-tdesc.c (file_read_description_xml): Adjust.
5623 (fetch_available_features_from_target): Change return type.
5624 (target_fetch_description_xml): Adjust.
5625 (target_read_description_xml): Adjust.
5626
14c88955
TT
56272018-04-06 Tom Tromey <tom@tromey.com>
5628
5629 * value.c (~value): Update.
5630 (struct value) <contents>: Now unique_xmalloc_ptr.
5631 (value_contents_bits_eq, allocate_value_contents)
5632 (value_contents_raw, value_contents_all_raw)
5633 (value_contents_for_printing, value_contents_for_printing_const)
5634 (set_value_enclosing_type): Update.
5635
0c7e6dd8
TT
56362018-04-06 Tom Tromey <tom@tromey.com>
5637
5638 * value.c (range_s): Remove typedef, VEC.
5639 (struct range): Add operator<.
5640 (range_lessthan): Remove.
5641 (ranges_contain): Change type.
5642 (~value): Update.
5643 (struct value) <unavailable, optimized_out>: Now std::vector.
5644 (value_entirely_available)
5645 (value_entirely_covered_by_range_vector)
5646 (value_entirely_unavailable, value_entirely_optimized_out):
5647 Update.
5648 (insert_into_bit_range_vector): Change argument type.
5649 (find_first_range_overlap): Likewise.
5650 (struct ranges_and_idx, value_contents_bits_eq)
5651 (require_not_optimized_out, require_available): Update.
5652 (ranges_copy_adjusted): Change argument types.
5653 (value_optimized_out, value_copy, value_fetch_lazy): Update.
5654
2c8331b9
TT
56552018-04-06 Tom Tromey <tom@tromey.com>
5656
5657 * value.c (~value): Update.
5658 (struct value) <parent>: Now a value_ref_ptr.
5659 (value_parent, set_value_parent, value_address, value_copy):
5660 Update.
5661
466ce3ae
TT
56622018-04-06 Tom Tromey <tom@tromey.com>
5663
5664 * value.c (struct value): Add constructor, destructor, and member
5665 initializers.
5666 (allocate_value_lazy, value_decref): Update.
5667
062d818d
TT
56682018-04-06 Tom Tromey <tom@tromey.com>
5669
5670 * value.c (struct value) <released, next>: Remove.
5671 (all_values): Now a std::vector.
5672 (allocate_value_lazy): Update.
5673 (value_next): Remove.
5674 (value_mark, value_free_to_mark, release_value)
5675 (value_release_to_mark): Update.
5676
a6535de1
TT
56772018-04-06 Tom Tromey <tom@tromey.com>
5678
5679 * value.h (fetch_subexp_value, value_release_to_mark): Update.
5680 (free_value_chain): Remove.
5681 * value.c (free_value_chain): Remove.
5682 (value_release_to_mark): Return a std::vector.
5683 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
5684 std::vector.
5685 (check_condition): Update.
5686 * eval.c (fetch_subexp_value): Change "val_chain" to a
5687 std::vector.
5688 * breakpoint.c (update_watchpoint): Update.
5689 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
5690
b5621201
TT
56912018-04-06 Tom Tromey <tom@tromey.com>
5692
5693 * value.h (free_all_values): Remove.
5694 * value.c (free_all_values): Remove.
5695
4d0266a0
TT
56962018-04-06 Tom Tromey <tom@tromey.com>
5697
5698 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
5699 (value_history_chain, value_history_count): Remove.
5700 (value_history): New global.
5701 (record_latest_value, access_value_history, show_values)
5702 (preserve_values): Update.
5703
b4d61099
TT
57042018-04-06 Tom Tromey <tom@tromey.com>
5705
5706 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
5707 * varobj.c (varobj_set_display_format, varobj_set_value)
5708 (install_default_visualizer, construct_visualizer)
5709 (install_new_value, ~varobj, varobj_get_value_type)
5710 (my_value_of_variable, varobj_editable_p): Update.
5711 * c-varobj.c (c_describe_child, c_value_of_variable)
5712 (cplus_number_of_children, cplus_describe_child): Update.
5713 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
5714 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
5715 (ada_value_of_variable, ada_value_is_changeable_p): Update.
5716
9b558729
TT
57172018-04-06 Tom Tromey <tom@tromey.com>
5718
5719 * printcmd.c (last_examine_address): Change type to
5720 value_ref_ptr.
5721 (do_examine, x_command): Update.
5722
850645cf
TT
57232018-04-06 Tom Tromey <tom@tromey.com>
5724
5725 * value.c (release_value): Update.
5726 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
5727 (struct bpstats) <val>: Now a value_ref_ptr.
5728 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
5729 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
5730 (~watchpoint, print_it_watchpoint, watch_command_1)
5731 (invalidate_bp_value_on_memory_change): Update.
5732
22bc8444
TT
57332018-04-06 Tom Tromey <tom@tromey.com>
5734
5735 * varobj.c (varobj_clear_saved_item)
5736 (update_dynamic_varobj_children, install_new_value, ~varobj):
5737 Update.
5738 * value.h (value_incref): Move declaration earlier.
5739 (value_decref): Rename from value_free.
5740 (struct value_ref_policy): New.
5741 (value_ref_ptr): New typedef.
5742 (struct value_deleter): Remove.
5743 (gdb_value_up): Remove typedef.
5744 (release_value): Change return type.
5745 (release_value_or_incref): Remove.
5746 * value.c (set_value_parent): Update.
5747 (value_incref): Change return type.
5748 (value_decref): Rename from value_free.
5749 (value_free_to_mark, free_all_values, free_value_chain): Update.
5750 (release_value): Return value_ref_ptr.
5751 (release_value_or_incref): Remove.
5752 (record_latest_value, set_internalvar, clear_internalvar):
5753 Update.
5754 * stack.c (info_frame_command): Don't call value_free.
5755 * python/py-value.c (valpy_dealloc, valpy_new)
5756 (value_to_value_object): Update.
5757 * printcmd.c (do_examine): Update.
5758 * opencl-lang.c (lval_func_free_closure): Update.
5759 * mi/mi-main.c (register_changed_p): Don't call value_free.
5760 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
5761 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
5762 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
5763 value_free.
5764 * guile/scm-value.c (vlscm_free_value_smob)
5765 (vlscm_scm_from_value): Update.
5766 * frame.c (frame_register_unwind, frame_unwind_register_signed)
5767 (frame_unwind_register_unsigned, get_frame_register_bytes)
5768 (put_frame_register_bytes): Don't call value_free.
5769 * findvar.c (address_from_register): Don't call value_free.
5770 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
5771 * dwarf2loc.c (entry_data_value_free_closure)
5772 (value_of_dwarf_reg_entry, free_pieced_value_closure)
5773 (dwarf2_evaluate_loc_desc_full): Update.
5774 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
5775 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
5776 (~watchpoint, watch_command_1)
5777 (invalidate_bp_value_on_memory_change): Update.
5778 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
5779
7f8a5d38
SM
57802018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
5781
5782 PR gdb/23022
5783 * warning.m4: Add -Wno-error=deprecated-register.
5784 * configure: Re-generate.
5785
8a76bd3b
TT
57862018-04-05 Tom Tromey <tom@tromey.com>
5787
5788 * linespec.h: Remove include of "vec.h".
5789
8e8d776e
TT
57902018-04-05 Tom Tromey <tom@tromey.com>
5791
5792 * linespec.c (typep): Remove typedef.
5793 (find_methods, find_superclass_methods): Take a std::vector.
5794 (find_method): Use std::vector.
5795
9b2f8581
TT
57962018-04-05 Tom Tromey <tom@tromey.com>
5797
5798 * utils.c (compare_strings): Remove.
5799 * utils.h (compare_strings): Remove.
5800 * objc-lang.h (find_imps): Update.
5801 * objc-lang.c (find_methods): Take a std::vector.
5802 (uniquify_strings, find_imps): Likewise.
5803 * linespec.c (find_methods): Take a std::vector.
5804 (decode_objc): Use std::vector.
5805 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
5806 a std::vector.
5807 (find_method, find_function_symbols): Use std::vector.
5808
459a2e4c
TT
58092018-04-05 Tom Tromey <tom@tromey.com>
5810
5811 * completer.c (completion_tracker::completion_tracker): Remove
5812 cast.
5813 (completion_tracker::discard_completions): Likewise.
5814 * breakpoint.c (ambiguous_names_p): Remove cast.
5815 * ada-lang.c (_initialize_ada_language): Remove cast.
5816 * utils.h (streq): Update.
5817 (streq_hash): Add new declaration.
5818 * utils.c (streq): Return bool.
5819 (streq_hash): New function.
5820
9be2c17a
TT
58212018-04-05 Tom Tromey <tom@tromey.com>
5822
5823 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
5824 Remove a string copy.
5825
f73c6ece
TT
58262018-04-05 Tom Tromey <tom@tromey.com>
5827
5828 * linespec.c (filter_results): Use std::vector.
5829 (decode_line_2, decode_line_full): Update.
5830
53a0f8a2
TT
58312018-04-05 Tom Tromey <tom@tromey.com>
5832
5833 * linespec.c (canonical_to_fullform): Return std::string.
5834 (filter_results): Update.
5835 (struct decode_line_2_item): Add constructor.
5836 <fullform, displayform>: Now std::string.
5837 (decode_line_2_compare_items): Now a std::sort comparator.
5838 (decode_line_2): Update.
5839
a5b5adf5
TT
58402018-04-05 Tom Tromey <tom@tromey.com>
5841
5842 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
5843 (unexpected_linespec_error): Update.
5844 (linespec_parse_basic, parse_linespec): Update.
5845
6a307fc5
TT
58462018-04-05 Tom Tromey <tom@tromey.com>
5847
5848 * linespec.c (linespec_parse_basic): Reindent.
5849
41c1efc6
TT
58502018-04-05 Tom Tromey <tom@tromey.com>
5851
5852 * minsyms.h (iterate_over_minimal_symbols): Update.
5853 * minsyms.c (iterate_over_minimal_symbols): Take a
5854 gdb::function_view.
5855 * linespec.c (struct collect_minsyms): Remove.
5856 (compare_msyms): Now a std::sort comparator.
5857 (add_minsym): Add parameters.
5858 (search_minsyms_for_name): Update. Use std::vector.
5859
c5edbf3d
TT
58602018-04-03 Tom Tromey <tom@tromey.com>
5861
5862 * mipsread.c (read_alphacoff_dynamic_symtab): Use
5863 gdb::byte_vector.
5864
b39efc48
WP
58652018-04-02 Weimin Pan <weimin.pan@oracle.com>
5866
5867 * MAINTAINERS (Write After Approval): Add Weimin Pan.
5868
121ad66c 58692018-04-02 Weimin Pan <weimin.pan@oracle.com>
79f18731
WP
5870
5871 PR gdb/16959
5872 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
5873 printing static type.
5874
09473be8
TT
58752018-04-01 Tom Tromey <tom@tromey.com>
5876
5877 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
5878 (rs6000_xfer_shared_libraries): Update.
5879
ec1f2d91
SM
58802018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
5881
5882 * common/gdb_vecs.h (char_ptr): Remove.
5883 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
5884
d8611974
SM
58852018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
5886
5887 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
5888 with std::vector.
5889 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
5890
a18ba4e4
SM
58912018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
5892
5893 * tracepoint.h (struct uploaded_tp): Initialize fields.
5894 <actions, step_actions, cmd_strings>: Change type to
5895 std::vector<char *>.
5896 * tracepoint.c (get_uploaded_tp): Allocate with new.
5897 (free_uploaded_tps): Free with delete.
5898 (parse_tracepoint_definition): Adjust to std::vector change.
5899 * breakpoint.c (read_uploaded_action): Likewise.
5900 (create_tracepoint_from_upload): Likewise.
5901 * ctf.c (ctf_write_uploaded_tp): Likewise.
5902 (SET_ARRAY_FIELD): Likewise.
5903 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
5904
a7961323
TT
59052018-03-30 Tom Tromey <tom@tromey.com>
5906
5907 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
5908 std::unique_ptr.
5909 (svr4_keep_data_in_core): Update.
5910 (svr4_read_so_list): Update.
5911
e83e4e24
TT
59122018-03-30 Tom Tromey <tom@tromey.com>
5913
5914 * windows-nat.c (handle_output_debug_string, handle_exception):
5915 Update.
5916 * target.h (target_read_string): Update.
5917 * target.c (target_read_string): Change "string" to
5918 unique_xmalloc_ptr.
5919 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
5920 Update.
5921 * solib-frv.c (frv_current_sos): Update.
5922 * solib-dsbt.c (dsbt_current_sos): Update.
5923 * solib-darwin.c (darwin_current_sos): Update.
5924 * linux-thread-db.c (inferior_has_bug): Update.
5925 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
5926 Update. Remove alloca.
5927 * ada-lang.c (ada_main_name): Update.
5928
263db9a1
TT
59292018-03-30 Tom Tromey <tom@tromey.com>
5930
5931 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
5932 (struct dwo_file_deleter): New.
5933 (dwo_file_up): New typedef.
5934 (open_and_init_dwo_file): Use dwo_file_up.
5935 (free_dwo_file_cleanup): Remove.
5936
5dafb3d1
TT
59372018-03-30 Tom Tromey <tom@tromey.com>
5938
5939 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
5940 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
5941
11ed8cad
TT
59422018-03-30 Tom Tromey <tom@tromey.com>
5943
5944 * dwarf2read.c (class free_cached_comp_units): New class.
5945 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
5946 (free_cached_comp_units): Remove function.
5947
9ae79dac
TT
59482018-03-30 Tom Tromey <tom@tromey.com>
5949
5950 * utils.h (make_cleanup_unpush_target): Remove.
5951 * inf-ptrace.c (struct target_unpusher): New.
5952 (target_unpush_up) New typedef.
5953 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
5954 target_unpush_up.
5955 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
5956
5aa89276
TT
59572018-03-27 Tom Tromey <tom@tromey.com>
5958
5959 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
5960
1dbeed45
TT
59612018-03-27 Pedro Alves <palves@redhat.com>
5962 Tom Tromey <tom@tromey.com>
5963
5964 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
5965 destructor. Now a class.
5966 (gdb_readline_wrapper_cleanup): Remove function.
5967 (gdb_readline_wrapper): Remove cleanups.
5968
c819b2c0
TT
59692018-03-27 Tom Tromey <tom@tromey.com>
5970
5971 * typeprint.h (struct type_print_options) <local_typedefs,
5972 global_typedefs>: Remove "struct" keyword.
5973 (class typedef_hash_table): New class.
5974 (recursively_update_typedef_hash, add_template_parameters)
5975 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
5976 (find_typedef_in_hash): Don't declare.
5977 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
5978 (typedef_hash_table::recursively_update): Rename from
5979 recursively_update_typedef_hash. Now a member.
5980 (typedef_hash_table::add_template_parameters): Rename from
5981 add_template_parameters. Now a member.
5982 (typedef_hash_table::typedef_hash_table): Now a constructor;
5983 rename from create_typedef_hash.
5984 (typedef_hash_table::~typedef_hash_table): Now a destructor;
5985 rename from free_typedef_hash.
5986 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
5987 (do_free_global_table): Remove.
5988 (typedef_hash_table::typedef_hash_table): New constructor; renamed
5989 from copy_type_recursive.
5990 (create_global_typedef_table): Remove.
5991 (typedef_hash_table::find_global_typedef): Now a member of
5992 typedef_hash_table.
5993 (typedef_hash_table::find_typedef): Rename from
5994 find_typedef_in_hash; now a member.
5995 (whatis_exp): Update.
5996 * extension.h (struct ext_lang_type_printers): Add constructor and
5997 destructor.
5998 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
5999 declare.
6000 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
6001 Now a constructor; rename from start_ext_lang_type_printers.
6002 (ext_lang_type_printers): Now a destructor; rename from
6003 free_ext_lang_type_printers.
6004 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
6005 Update.
6006 (c_type_print_base_struct_union): Update. Remove cleanups.
6007
608219fb
TT
60082018-03-27 Tom Tromey <tom@tromey.com>
6009
6010 * dwarf-index-write.c: Include <cmath>.
6011
3fcded8f
JB
60122018-03-27 Joel Brobecker <brobecker@adacore.com>
6013
6014 * NEWS: Add entry describing new "set|show varsize-limit" command.
6015 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
6016 command.
6017 * printcmd.c (_initialize_printcmd): Add "set var" alias of
6018 "set variable".
6019
cd4fb1b2
SM
60202018-03-27 Simon Marchi <simon.marchi@ericsson.com>
6021
6022 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
6023 dwarf-index-write.c
6024 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
6025 * dwarf-index-common.c: New file.
6026 * dwarf-index-common.h: New file.
6027 * dwarf-index-write.c: New file.
6028 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
6029 (struct dwarf2_section_info): Move from here.
6030 (dwarf2_section_info_def): Likewise.
6031 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
6032 (offset_type): Likewise.
6033 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
6034 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
6035 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
6036 (byte_swap): Likewise.
6037 (MAYBE_SWAP): Likewise.
6038 (dwarf2_per_cu_ptr): Likewise.
6039 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
6040 (struct tu_stats): Likewise.
6041 (struct dwarf2_per_objfile): Likewise.
6042 (struct dwarf2_per_cu_data): Likewise.
6043 (struct signatured_type): Likewise.
6044 (sig_type_ptr): Likewise.
6045 (DEF_VEC_P (sig_type_ptr)): Likewise.
6046 (INDEX4_SUFFIX): Likewise.
6047 (INDEX5_SUFFIX): Likewise.
6048 (DEBUG_STR_SUFFIX): Likewise.
6049 (dwarf2_read_section): Make non-static.
6050 (mapped_index_string_hash): Move from here.
6051 (dwarf5_djb_hash): Likewise.
6052 (file_write): Likewise.
6053 (class data_buf): Likewise.
6054 (struct symtab_index_entry): Likewise.
6055 (struct mapped_symtab): Likewise.
6056 (find_slot): Likewise.
6057 (hash_expand): Likewise.
6058 (add_index_entry): Likewise.
6059 (uniquify_cu_indices): Likewise.
6060 (class c_str_view): Likewise.
6061 (class c_str_view_hasher): Likewise.
6062 (class vector_hasher): Likewise.
6063 (write_hash_table): Likewise.
6064 (psym_index_map): Likewise.
6065 (struct addrmap_index_data): Likewise.
6066 (add_address_entry): Likewise.
6067 (add_address_entry_worker): Likewise.
6068 (write_address_map): Likewise.
6069 (symbol_kind): Likewise.
6070 (write_psymbols): Likewise.
6071 (struct signatured_type_index_data): Likewise.
6072 (write_one_signatured_type): Likewise.
6073 (recursively_count_psymbols): Likewise.
6074 (recursively_write_psymbols): Likewise.
6075 (class debug_names): Likewise.
6076 (check_dwarf64_offsets): Likewise.
6077 (psyms_seen_size): Likewise.
6078 (write_gdbindex): Likewise.
6079 (write_debug_names): Likewise.
6080 (assert_file_size): Likewise.
6081 (write_psymtabs_to_index): Likewise.
6082 (save_gdb_index_command): Likewise.
6083 (_initialize_dwarf2_read): Don't register the "save gdb-index"
6084 command.
6085 * dwarf2read.h: New file.
6086
59cc4834
JB
60872018-03-27 Joel Brobecker <brobecker@adacore.com>
6088
6089 PR gdb/22670
6090 * dwarf2read.c (dwarf2_physname): Do not return the demangled
6091 symbol name if the CU's language stores symbol names in linkage
6092 format.
6093 * language.h (struct language_defn)
6094 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
6095 all instances of this struct.
6096
67501539
TT
60972018-03-26 Tom Tromey <tom@tromey.com>
6098
6099 * stack.c (backtrace_command_1): Remove verbose code.
6100
76c939ac
TT
61012018-03-26 Tom Tromey <tom@tromey.com>
6102
6103 * python/py-framefilter.c (py_print_type): Don't catch
6104 exceptions. Return void.
6105 (py_print_value): Likewise.
6106 (py_print_single_arg): Likewise.
6107 (enumerate_args): Don't catch exceptions.
6108 (py_print_args): Likewise.
6109 (py_print_frame): Likewise.
6110 (gdbpy_apply_frame_filter): Catch exceptions here.
6111
9507b29c
TT
61122018-03-26 Tom Tromey <tom@tromey.com>
6113
6114 * stack.c (_initialize_stack): Remove trailing newlines from help
6115 text. Add "Usage" line to "backtrace" help.
6116
eb68e487
TT
61172018-03-26 Tom Tromey <tom@tromey.com>
6118
6119 PR python/16486:
6120 * python/py-framefilter.c (py_print_args): Call wrap_hint.
6121
1f111921
TT
61222018-03-26 Tom Tromey <tom@tromey.com>
6123
6124 * python/py-framefilter.c (py_print_single_arg): Return
6125 EXT_LANG_BT_ERROR from catch.
6126
fb7eb8b5
TT
61272018-03-26 Tom Tromey <tom@tromey.com>
6128
6129 PR backtrace/15584:
6130 * stack.c (backtrace_command_1): Move some code into no-filters
6131 "if".
6132
4ca59a9f
TT
61332018-03-26 Tom Tromey <tom@tromey.com>
6134
6135 * python/py-framefilter.c (throw_quit_or_print_exception): New
6136 function.
6137 (gdbpy_apply_frame_filter): Use it.
6138
92256134
TT
61392018-03-26 Tom Tromey <tom@tromey.com>
6140
6141 PR cli/17716:
6142 * python/py-framefilter.c (py_print_type, py_print_value)
6143 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
6144 RETURN_MASK_ERROR.
6145
7a630bc2
TT
61462018-03-26 Tom Tromey <tom@tromey.com>
6147
6148 * python/py-framefilter.c (enumerate_args): Use
6149 gdb::unique_xmalloc_ptr.
6150
63283d4a
TT
61512018-03-26 Tom Tromey <tom@tromey.com>
6152
6153 * python/py-framefilter.c (py_print_frame): Return
6154 EXT_LANG_BT_OK.
6155 (gdbpy_apply_frame_filter): Update comment.
6156 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
6157 Remove.
6158 <EXT_LANG_BT_NO_FILTERS>: Change value.
6159
978d6c75
TT
61602018-03-26 Tom Tromey <tom@tromey.com>
6161
6162 PR backtrace/15582:
6163 * stack.c (backtrace_command): Parse "hide" argument.
6164 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
6165 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
6166 constant.
6167
1cf7e640
TT
61682018-03-26 Tom Tromey <tom@tromey.com>
6169
6170 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
6171 add "flags".
6172 (backtrace_command): Remove "fulltrace", add "flags".
6173
ea3b0687
TT
61742018-03-26 Tom Tromey <tom@tromey.com>
6175
6176 * stack.c (backtrace_command): Rewrite command line parsing.
6177
9f034d75
SM
61782018-03-26 Simon Marchi <simon.marchi@ericsson.com>
6179
6180 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
6181
ce1459e5
SM
61822018-03-26 Simon Marchi <simon.marchi@ericsson.com>
6183
6184 * filename-seen-cache.h: Add include guard.
6185
4f7ae6f5
KS
61862018-03-26 Keith Seitz <keiths@redhat.com>
6187
6188 * symfile.c (place_section): Remove "struct" from section_addr_info
6189 in comment.
6190 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
6191 "struct" keyword from section_addr_info.
6192
5cd3e386
AH
61932018-03-26 Alan Hayward <alan.hayward@arm.com>
6194
6195 * regformats/regdef.h (reg): Add constructors.
6196
3e5ef9a4
PA
61972018-03-25 Pedro Alves <palves@redhat.com>
6198
6199 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
6200 if then/else bodies in var_func_name extraction.
6201
c88d2fcc 62022018-03-23 Weimin Pan <weimin.pan@oracle.com>
bce02d88
WP
6203
6204 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
6205 lookup_minimal_symbol() to find symbol entry.
6206 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
6207
b7fee5a3
KS
62082018-03-23 Keith Seitz <keiths@redhat.com>
6209
6210 PR c++/22968
6211 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
6212 nested type definitions for C++, too.
6213
2cc9b304
TT
62142018-03-23 Tom Tromey <tom@tromey.com>
6215
6216 * machoread.c (struct oso_el): Add a constructor. Don't define as
6217 a typedef.
6218 (macho_register_oso): Remove.
6219 (macho_symtab_read): Take a std::vector.
6220 (oso_el_compare_name): Now a std::sort comparator.
6221 (macho_symfile_read_all_oso): Take a std::vector.
6222 (macho_symfile_read): Use std::vector. Remove cleanups.
6223
a2b2bc12
TT
62242018-03-22 Tom Tromey <tom@tromey.com>
6225
6226 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
6227 (record_full_goto_bookmark): Use std::string.
6228
7a8f494c
PFC
62292018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6230
6231 PR tdep/18295
6232 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
6233 a single mask.
6234
dd6d677f
PFC
62352018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6236
6237 * rs6000-tdep.c (store_insn_p): New function.
6238 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
6239 and cr_reg to their unshifted values. Use store_insn_p to
6240 match LR saves using either R1 or fdata->alloca_reg. Use
6241 store_insn_p to match CR saves. Set alloca_reg_offset
6242 when alloca_reg and framep are set. Remove lr_reg shift
6243 when assigning to fdata->lr_register.
6244
26d6cec4
AA
62452018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
6246
6247 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
6248 command line args instead of emitting a warning.
6249
5d9310c4
SM
62502018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
6251
6252 * tracepoint.h (struct static_tracepoint_marker): Initialize
6253 fields, define default constructor, move constructor and move
6254 assignment, disable the rest.
6255 <str_id, extra>: Make std::string.
6256 (release_static_tracepoint_marker): Remove.
6257 (free_current_marker): Remove.
6258 * tracepoint.c (free_current_marker): Remove.
6259 (parse_static_tracepoint_marker_definition): Adjust to
6260 std::string, use new hex2str overload.
6261 (release_static_tracepoint_marker): Remove.
6262 (print_one_static_tracepoint_marker): Get marker by reference
6263 and adjust to std::string.
6264 (info_static_tracepoint_markers_command): Adjust to std::vector
6265 changes
6266 * target.h (static_tracepoint_marker_p): Remove typedef.
6267 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
6268 (struct target_ops) <to_static_tracepoint_marker_at>: Return
6269 bool.
6270 <to_static_tracepoint_markers_by_strid>: Return std::vector.
6271 * target-debug.h
6272 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
6273 (target_debug_print_std_vector_static_tracepoint_marker): New.
6274 (target_debug_print_struct_static_tracepoint_marker_p): Rename
6275 to...
6276 (target_debug_print_static_tracepoint_marker_p): ... this.
6277 * target-delegates.c: Re-generate.
6278 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
6279 Make std::string.
6280 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
6281 (decode_static_tracepoint_spec): Adjust to std::vector.
6282 (tracepoint_print_one_detail): Adjust to std::string.
6283 (strace_marker_decode_location): Adjust to std::string.
6284 (update_static_tracepoint): Adjust to std::string, remove call
6285 to release_static_tracepoint_marker.
6286 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
6287 Adjust to std::vector.
6288 * remote.c (remote_static_tracepoint_marker_at): Return bool.
6289 (remote_static_tracepoint_markers_by_strid): Adjust to
6290 std::vector.
6291 * common/rsp-low.h (hex2str): New overload with explicit count
6292 of bytes.
6293 * common/rsp-low.c (hex2str): New overload with explicit count
6294 of bytes.
6295 * unittests/rsp-low-selftests.c (test_hex2str): New function.
6296 (_initialize_rsp_low_selftests): Add test_hex2str test.
6297 * unittests/tracepoint-selftests.c
6298 (test_parse_static_tracepoint_marker_definition): Adjust to
6299 std::string.
6300
62c222b6
SM
63012018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
6302
6303 * tracepoint.c (parse_static_tracepoint_marker_definition):
6304 Consider case where the definition is followed by more
6305 definitions.
6306 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6307 tracepoint-selftests.c.
6308 * unittests/tracepoint-selftests.c: New.
6309
7eb2418f
PFC
63102018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
6311
6312 * MAINTAINERS (Write After Approval): Add Pedro Franco de
6313 Carvalho.
6314
7cbe16e9
SR
63152018-03-20 Stephen Roberts <stephen.roberts@arm.com>
6316
3d6b3b82 6317 * symtab.c (find_pc_sect_line): fixed indentation.
7cbe16e9 6318
4ee89e90
SR
63192018-03-20 Stephen Roberts <stephen.roberts@arm.com>
6320
3d6b3b82 6321 * symtab.c (find_pc_sect_line): now uses binary search.
4ee89e90 6322
92630041
TT
63232018-03-19 Tom Tromey <tom@tromey.com>
6324
6325 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
6326 "IDENT" production.
6327
76727919
TT
63282018-03-19 Pedro Alves <palves@redhat.com>
6329 Tom Tromey <tom@tromey.com>
6330
6331 * unittests/observable-selftests.c: New file.
6332 * common/observable.h: New file.
6333 * observable.h: New file.
6334 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
6335 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
6336 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
6337 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
6338 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
6339 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
6340 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
6341 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
6342 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
6343 python/py-breakpoint.c, python/py-finishbreakpoint.c,
6344 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
6345 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
6346 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
6347 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
6348 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
6349 tui/tui-interp.c, valops.c: Update all users.
6350 * tui/tui-hooks.c (tui_bp_created_observer)
6351 (tui_bp_deleted_observer, tui_bp_modified_observer)
6352 (tui_inferior_exit_observer, tui_before_prompt_observer)
6353 (tui_normal_stop_observer, tui_register_changed_observer):
6354 Remove.
6355 (tui_observers_token): New global.
6356 (attach_or_detach, tui_attach_detach_observers): New functions.
6357 (tui_install_hooks, tui_remove_hooks): Use
6358 tui_attach_detach_observers.
6359 * record-btrace.c (record_btrace_thread_observer): Remove.
6360 (record_btrace_thread_observer_token): New global.
6361 * observer.sh: Remove.
6362 * observer.c: Rename to observable.c.
6363 * observable.c (namespace gdb_observers): Define new objects.
6364 (observer_debug): Move into gdb_observers namespace.
6365 (struct observer, struct observer_list, xalloc_observer_list_node)
6366 (xfree_observer_list_node, generic_observer_attach)
6367 (generic_observer_detach, generic_observer_notify): Remove.
6368 (_initialize_observer): Update.
6369 Don't include observer.inc.
6370 * Makefile.in (generated_files): Remove observer.h, observer.inc.
6371 (clean mostlyclean): Likewise.
6372 (observer.h, observer.inc): Remove targets.
6373 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
6374 (COMMON_SFILES): Use observable.c, not observer.c.
6375 * .gitignore: Remove observer.h.
6376
1cb1f3da
TT
63772018-03-18 Tom Tromey <tom@tromey.com>
6378
6379 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
6380 gdb::def_vector.
6381 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
6382
a06ab151
TT
63832018-03-17 Tom Tromey <tom@tromey.com>
6384
6385 * auto-load.c (auto_load_objfile_script_1): Use std::string.
6386
770623f7
TT
63872018-03-17 Tom Tromey <tom@tromey.com>
6388
6389 * target.c (class scoped_target_fd): New.
6390 (target_fileio_close_cleanup): Remove.
6391 (target_fileio_read_alloc_1): Use scoped_target_fd.
6392
39be3c7e
SM
63932018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
6394
6395 * silent-rules.mk: New.
6396 * Makefile.in: Include silent-rules.mk
6397 (srcdir, VPATH, top_srcdir): Move up.
6398 (COMPILE): Add ECHO_CXX.
6399 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
6400 (init.c): Add ECHO_INIT_C.
6401 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
6402 (version.c): Add ECHO_GEN.
6403 (printcmd.o): Add ECHO_CXX.
6404 (target-float.o): Add ECHO_CXX.
6405 (ada-exp.o): Add ECHO_CXX.
6406 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
6407 (insight$(EXEEXT)): Add ECHO_CXXLD.
6408 * gnulib/configure.ac: Add AM_SILENT_RULES.
6409 * gnulib/aclocal.m4: Re-generate.
6410 * gnulib/configure: Re-generate.
6411 * gnulib/import/Makefile.in: Re-generate.
6412
37e136b1
TT
64132018-03-16 Tom Tromey <tom@tromey.com>
6414
6415 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
6416 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
6417 * utils.c (do_free_section_addr_info)
6418 (make_cleanup_free_section_addr_info): Remove.
6419 * symfile.h (struct other_sections): Add constructor.
6420 (struct section_addr_info): Remove.
6421 (section_addr_info): New typedef.
6422 (struct sym_fns) <sym_offsets>: Change type of parameter.
6423 (build_section_addr_info_from_objfile)
6424 (relative_addr_info_to_section_offsets, addr_info_make_relative)
6425 (default_symfile_offsets, symbol_file_add)
6426 (symbol_file_add_from_bfd)
6427 (build_section_addr_info_from_section_table): Update.
6428 (alloc_section_addr_info, free_section_addr_info): Don't declare.
6429 * symfile.c (alloc_section_addr_info): Remove.
6430 (build_section_addr_info_from_section_table): Change return type.
6431 Update.
6432 (build_section_addr_info_from_bfd)
6433 (build_section_addr_info_from_objfile): Likewise.
6434 (free_section_addr_info): Remove.
6435 (relative_addr_info_to_section_offsets): Change type of "addrs".
6436 (addrs_section_compar): Now a std::sort comparator.
6437 (addrs_section_sort): Change return type.
6438 (addr_info_make_relative): Change type of "addrs". Update.
6439 (default_symfile_offsets, syms_from_objfile_1)
6440 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
6441 (symbol_file_add_separate): Update.
6442 (symbol_file_add): Change type of "addrs". Update.
6443 (add_symbol_file_command): Update. Remove cleanups.
6444 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
6445 cleanups.
6446 * symfile-debug.c (debug_sym_offsets): Change type of "info".
6447 * solib.c (solib_read_symbols): Update.
6448 * objfiles.c (objfile_relocate): Update. Remove cleanups.
6449 * machoread.c (macho_symfile_offsets): Update.
6450 * jit.c (jit_bfd_try_read_symtab): Update.
6451
03afa6ef
SM
64522018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
6453
6454 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6455 unittests/utils-selftests.c.
6456 * unittests/utils-selftests.c: New file.
6457
3ae9ce5d
TT
64582018-03-14 Tom Tromey <tom@tromey.com>
6459
6460 PR cli/14977:
6461 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
6462 for NULL.
6463
b8c2339b
TT
64642018-03-14 Tom Tromey <tom@tromey.com>
6465
6466 PR cli/19918:
6467 * printcmd.c (printf_pointer): Allow "-" in format.
6468
80ae639d
TT
64692018-03-14 Tom Tromey <tom@tromey.com>
6470
6471 * printcmd.c (_initialize_printcmd): Add usage to printf.
6472
0d671d99
YQ
64732018-03-14 Yao Qi <qiyao@sourceware.org>
6474
6475 * MAINTAINERS: Update my email address.
6476
b577b6af
TT
64772018-03-13 Tom Tromey <tom@tromey.com>
6478
6479 * machoread.c (macho_check_dsym): Change filenamep to a
6480 std::string*.
6481 (macho_symfile_read): Update.
6482 * symfile.c (load_command): Use std::string.
6483
89a3b63e
AB
64842018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
6485
6486 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
6487 to error message string.
6488 (riscv_register_name): Use xsnprintf instead of sprintf.
6489 (riscv_insn::fetch_instruction): Use gdb_assert instead of
6490 internal_error.
6491 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
6492 error.
6493 (riscv_push_dummy_call): Likewise.
6494
984c7238
TT
64952018-03-12 Tom Tromey <tom@tromey.com>
6496
6497 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
6498 Use gdb::byte_vector.
6499 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
6500
933522d1
YQ
65012018-03-12 Yao Qi <yao.qi@linaro.org>
6502
6503 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
6504 parameter type to readable_regcache.
6505 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
6506 the declaration.
6507
be2daae6
TT
65082018-03-11 Tom Tromey <tom@tromey.com>
6509
6510 * dwarf2read.c (struct nextfield): Add initializers.
6511 (struct nextfnfield): Remove.
6512 (struct fnfieldlist): Add initializers. Remove "length" and
6513 "head", use std::vector.
6514 (struct decl_field_list): Remove.
6515 (struct field_info): Add initializers.
6516 <fields, baseclasses>: Now std::vector.
6517 <nbaseclasses, nfnfields, typedef_field_list_count,
6518 nested_types_list_count>: Remove.
6519 (dwarf2_add_field, dwarf2_add_type_defn)
6520 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
6521 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
6522 (process_structure_scope): Update.
6523
484cf504
TT
65242018-03-11 Tom Tromey <tom@tromey.com>
6525
6526 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
6527 for use by std::sort.
6528 (build_type_psymtabs_1): Use std::vector.
6529
9bd8e0b0
EZ
65302018-03-09 Eli Zaretskii <eliz@gnu.org>
6531
6532 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
6533 and LIBMPFR in the printed configuration.
6534
5dc1a704
TT
65352018-03-08 Tom Tromey <tom@tromey.com>
6536
6537 * source.c (get_filename_and_charpos): Use scoped_fd.
6538 * nto-procfs.c (procfs_open_1): Use scoped_fd.
6539 (procfs_pidlist): Likewise.
6540 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
6541 (iterate_over_mappings): Likewise.
6542
fdf07f3a
TT
65432018-03-08 Tom Tromey <tom@tromey.com>
6544
6545 * infcall.c (struct call_return_meta_info)
6546 <stack_temporaries_enabled>: Remove.
6547 (get_call_return_value, call_function_by_hand_dummy): Update.
6548 * thread.c (disable_thread_stack_temporaries): Remove.
6549 (enable_thread_stack_temporaries): Remove.
6550 (thread_stack_temporaries_enabled_p): Return bool.
6551 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
6552 (get_last_thread_stack_temporary): Update.
6553 * eval.c (evaluate_subexp): Update.
6554 * gdbthread.h (class enable_thread_stack_temporaries): Now a
6555 class, not a function.
6556 (value_ptr, value_vec): Remove typedefs.
6557 (class thread_info) <stack_temporaries_enabled>: Now bool.
6558 <stack_temporaries>: Now a std::vector.
6559 (thread_stack_temporaries_enabled_p)
6560 (value_in_thread_stack_temporaries): Return bool.
6561
567a3e54
SM
65622018-03-08 Simon Marchi <simon.marchi@ericsson.com>
6563
6564 * remote.c (putpkt_binary): Fix omitted bytes reporting.
6565 (getpkt_or_notif_sane_1): Likewise.
6566
00b40057
SM
65672018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
6568
6569 * build-id.c (build_id_to_debug_bfd): Use std::string.
6570
a8dbfd58
SM
65712018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
6572
6573 * build-id.c (find_separate_debug_file_by_buildid): Return
6574 std::string.
6575 * build-id.h (find_separate_debug_file_by_buildid): Return
6576 std::string.
6577 * coffread.c (coff_symfile_read): Adjust to std::string.
6578 * elfread.c (elf_symfile_read): Adjust to std::string.
6579 * symfile.c (separate_debug_file_exists): Change parameter to
6580 std::string.
6581 (find_separate_debug_file): Return std::string.
6582 (find_separate_debug_file_by_debuglink): Return std::string.
6583 * symfile.h (find_separate_debug_file_by_debuglink): Return
6584 std::string.
6585
e6a58aa8
SM
65862018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
6587
6588 * common/xml-utils.c (xml_escape_text): Move code to...
6589 (xml_escape_text_append): ... this new function.
6590 * common/xml-utils.h (xml_escape_text_append): New declaration.
6591 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
6592 New function.
6593 (_initialize_xml_utils): register test_xml_escape_text_append as
6594 a selftest.
6595
4ef0bef6
AH
65962018-03-07 Alan Hayward <alan.hayward@arm.com>
6597
6598 * defs.h: Remove MAX_REGISTER_SIZE.
6599 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
6600 asserts.
6601 * python/py-unwind.c (pyuw_sniffer): Likewise.
6602
e0d3522b
TT
66032018-03-07 Tom Tromey <tom@tromey.com>
6604
6605 * linux-tdep.c (linux_info_proc): Update.
6606 * target.h (struct target_ops) <to_fileio_readlink>: Return
6607 optional<string>.
6608 (target_fileio_readlink): Return optional<string>.
6609 * remote.c (remote_hostio_readlink): Return optional<string>.
6610 * inf-child.c (inf_child_fileio_readlink): Return
6611 optional<string>.
6612 * target.c (target_fileio_readlink): Return optional<string>.
6613
ea005f31
AB
66142018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
6615
6616 * regcache.c (cooked_read_test): Add riscv to the list of
6617 architectures that have a save_reggroup.
6618
e95a97d4
AA
66192018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
6620
6621 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
6622 value is not a dynamic class object.
6623
d8344f3d
TT
66242018-03-06 Tom Tromey <tom@tromey.com>
6625
6626 * rust-exp.y: Formatting fixes.
6627
9add17f2
AB
66282018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
6629
6630 * riscv-tdep.c (riscv_register_name): Remove target description
6631 support.
6632 (riscv_gdbarch_init): Remove target description check.
6633
c9486dfe
AB
66342018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
6635
6636 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
6637 comment.
6638 * riscv-tdep.h: Likewise.
6639
d74aff3d
AB
66402018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
6641
6642 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
6643 (riscv_pseudo_register_write): Delete.
6644 (riscv_gdbarch_init): Remove all use of pseudo registers.
6645
7ea78b59
SM
66462018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
6647
6648 * record-btrace.c (btrace_print_lines): Replace cleanup
6649 parameter with RAII equivalents.
6650 (btrace_insn_history): Replace cleanup with RAII equivalents.
6651 * ui-out.h (make_cleanup_ui_out_list_begin_end,
6652 make_cleanup_ui_out_tuple_begin_end): Remove.
6653 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
6654 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
6655 make_cleanup_ui_out_list_begin_end): Remove.
6656
53127008
SM
66572018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
6658
6659 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
6660 parameter types to std::vector. Use bool.
6661 (record_btrace_wait): Replace VEC(tp_t) with
6662 std::vector<thread_info *>.
6663 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
6664
228f1508
SM
66652018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
6666
6667 * record-btrace.c (record_btrace_disable_callback): Remove.
6668 (struct scoped_btrace_disable): New.
6669 (record_btrace_open): Use scoped_btrace_disable.
6670
b2970c23
AB
66712018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
6672
6673 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
6674 reading values from registers.
6675
fb294655
AB
66762018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
6677
6678 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
6679 where appropriate.
6680
cab5bb9d
AB
66812018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
6682
6683 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
6684 change parameter type. Use GDB's print functions, and use
6685 core_addr_to_string where appropriate.
6686 (riscv_push_dummy_call): Use core_addr_to_string where
6687 appropriate, update call to riscv_print_arg_location, and reindent
6688 a few lines.
6689 (riscv_return_value): Update call to riscv_print_arg_location.
6690
dbbb1059
AB
66912018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
6692 Tim Newsome <tim@sifive.com>
6693 Albert Ou <a0u@eecs.berkeley.edu>
6694 Darius Rad <darius@bluespec.com>
6695
6696 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
6697 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
6698 (ALLDEPFILES): Add riscv-tdep.c
6699 * configure.tgt: Add riscv support.
6700 * riscv-tdep.c: New file.
6701 * riscv-tdep.h: New file.
6702 * NEWS: Mention new target.
6703 * MAINTAINERS: Add entry for riscv.
6704
5dc43913
AB
67052018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
6706
6707 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
6708 fields within aggregates.
6709
3dea1ef7
SM
67102018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
6711
6712 * record-btrace.c (btrace_print_lines): Change type of flags to
6713 gdb_disassembly_flags.
6714
7efba073
JB
67152018-03-04 John Baldwin <jhb@FreeBSD.org>
6716
6717 * fbsd-nat.c: Include "inf-ptrace.h".
6718 (USE_SIGTRAP_SIGINFO): Conditionally define.
6719 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
6720 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
6721 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
6722 function.
6723 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
6724 Likewise.
6725 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
6726 Likewise.
6727 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
6728 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
6729 "supports_stopped_by_hw_breakpoint" target methods.
6730
386a8676
JB
67312018-03-04 John Baldwin <jhb@FreeBSD.org>
6732
6733 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
6734 * fbsd-nat.c (debug_fbsd_nat): New variable.
6735 (show_fbsd_nat_debug): New function.
6736 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
6737 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
6738
12279366
JB
67392018-03-04 John Baldwin <jhb@FreeBSD.org>
6740
6741 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
6742 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
6743 prototype.
6744 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
6745 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
6746 method.
6747
54693cf5
SM
67482018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
6749
6750 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
6751 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
6752
ccb2231c
SM
67532018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
6754
6755 * charset.c (struct charset_vector): New.
6756 (charsets): Change type to charset_vector.
6757 (find_charset_names): Adjust.
6758 (add_one): Adjust.
6759 (_initialize_charset): Adjust.
6760
6fb16ce6
SM
67612018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
6762
6763 * progspace.h (struct program_space) <deleted_solibs>: Change
6764 type to std::vector<std::string>.
6765 * progspace.c (clear_program_space_solib_cache): Adjust.
6766 * breakpoint.c (print_solib_event): Adjust.
6767 (check_status_catch_solib): Adjust.
6768 * solib.c (update_solib_list): Adjust.
6769 * ui-out.h (class ui_out) <field_string>: New overload.
6770 * ui-out.c (ui_out::field_string): New overload.
6771
564b1e3f
SM
67722018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
6773
6774 * progspace.h (struct program_space): Add constructor and
6775 destructor, initialize fields.
6776 (add_program_space): Remove.
6777 * progspace.c (add_program_space): Rename to...
6778 (program_space::program_space): ... this.
6779 (release_program_space): Rename to...
6780 (program_space::~program_space): ... this.
6781 (delete_program_space): Use delete to delete program_space.
6782 (initialize_progspace): Use new to allocate program_space.
6783 * inferior.c (add_inferior_with_spaces): Likewise.
6784 (clone_inferior_command): Likewise.
6785 * infrun.c (follow_fork_inferior): Likewise.
6786 (handle_vfork_child_exec_or_exit): Likewise.
6787
e80aaf61
SM
67882018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
6789
6790 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
6791 (delim_string_to_char_ptr_vec): Return std::vector of
6792 gdb::unique_xmalloc_ptr.
6793 (dirnames_to_char_ptr_vec_append): Take std::vector of
6794 gdb::unique_xmalloc_ptr.
6795 (dirnames_to_char_ptr_vec): Return std::vector of
6796 gdb::unique_xmalloc_ptr.
6797 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
6798 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
6799 (delim_string_to_char_ptr_vec): Return an std::vector of
6800 gdb::unique_xmalloc_ptr, adjust the code.
6801 (dirnames_to_char_ptr_vec_append): Take an std::vector of
6802 gdb::unique_xmalloc_ptr, adjust the code.
6803 (dirnames_to_char_ptr_vec): Return an std::vector of
6804 gdb::unique_xmalloc_ptr, adjust the code.
6805 * auto-load.c (auto_load_safe_path_vec): Change type to
6806 std::vector of gdb::unique_xmalloc_ptr.
6807 (auto_load_expand_dir_vars): Return an std::vector of
6808 gdb::unique_xmalloc_ptr, adjust the code.
6809 (auto_load_safe_path_vec_update): Adjust.
6810 (filename_is_in_auto_load_safe_path_vec): Adjust.
6811 (auto_load_objfile_script_1): Adjust.
6812 * build-id.c (build_id_to_debug_bfd): Adjust.
6813 * linux-thread-db.c (thread_db_load_search): Adjust.
6814 * source.c (add_path): Adjust.
6815 (openp): Adjust.
6816 * symfile.c (find_separate_debug_file): Adjust.
6817 * utils.c (do_free_char_ptr_vec): Remove.
6818 (make_cleanup_free_char_ptr_vec): Remove.
6819
ab818ade
SDJ
68202018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
6821
6822 PR gdb/22907
6823 * common/pathstuff.c: Conditionally include "<windows.h>".
6824
e1e6f073
GS
68252018-03-01 Georg Sauthoff <mail@georg.so>
6826
6827 PR gdb/22888
6828 * gcore.in: Quote variables and switch interpreter to bash.
6829
c7b15a66
TT
68302018-03-01 Tom Tromey <tom@tromey.com>
6831
6832 * dwarf2read.c (alloc_discriminant_info): Fix default_index
6833 assertion. Add assertion for discriminant_index.
6834 (quirk_rust_enum): Use correct base type name in univariant case.
6835
0cb7c7b0
SM
68362018-03-01 Simon Marchi <simon.marchi@ericsson.com>
6837
6838 * record.c (get_call_history_modifiers): Return a
6839 record_print_flags.
6840 (cmd_record_call_history): Adjust.
6841 * record-btrace.c (record_btrace_call_history): Adjust.
6842 (record_btrace_call_history_range): Adjust.
6843 (record_btrace_call_history_from): Adjust.
6844 * target-debug.h (target_debug_print_record_print_flags): New.
6845 * target-delegates.c: Re-generate.
6846 * target.c (target_call_history): Change flags type.
6847 (target_call_history_from): Likewise.
6848 (target_call_history_range): Likewise.
6849 * target.h (struct target_ops) <target_call_history>: Likewise.
6850 (target_call_history_from): Likewise.
6851 (target_call_history_range): Likewise.
6852
25e3c82c
SDJ
68532018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
6854 Simon Marchi <simon.marchi@polymtl.ca>
6855
6856 * common/common-utils.c: Include "sys/stat.h".
6857 (is_regular_file): Move here from "source.c"; change return
6858 type to "bool".
6859 * common/common-utils.h (is_regular_file): New prototype.
6860 * common/pathstuff.c (contains_dir_separator): New function.
6861 * common/pathstuff.h (contains_dir_separator): New prototype.
6862 * source.c: Don't include "sys/stat.h".
6863 (is_regular_file): Move to "common/common-utils.c".
6864
b4987c95
SDJ
68652018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
6866
6867 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
6868 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
6869 * auto-load.c: Include "common/pathstuff.h".
6870 * common/common-def.h (current_directory): Move here.
6871 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
6872 function.
6873 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
6874 prototype.
6875 * common/pathstuff.c: New file.
6876 * common/pathstuff.h: New file.
6877 * compile/compile.c: Include "common/pathstuff.h".
6878 * defs.h (current_directory): Move to "common/common-defs.h".
6879 * dwarf2read.c: Include "common/pathstuff.h".
6880 * exec.c: Likewise.
6881 * guile/scm-safe-call.c: Likewise.
6882 * linux-thread-db.c: Likewise.
6883 * main.c: Likewise.
6884 * nto-tdep.c: Likewise.
6885 * objfiles.c: Likewise.
6886 * source.c: Likewise.
6887 * symtab.c: Likewise.
6888 * utils.c: Include "common/pathstuff.h".
6889 (gdb_realpath): Move to "common/pathstuff.c".
6890 (gdb_realpath_keepfile): Likewise.
6891 (gdb_abspath): Likewise.
6892 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
6893 (gdb_realpath_keepfile): Likewise.
6894 (gdb_abspath): Likewise.
6895
f169cfdc
JB
68962018-02-28 John Baldwin <jhb@FreeBSD.org>
6897
6898 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
6899 wildcard process pid for super_resume for kernels with a
6900 specific bug.
6901
e05cac70
PM
69022018-02-27 Phil Muldoon <pmuldoon@redhat.com>
6903
6904 * compile/compile.c (get_args): Add additional comments
6905 explaining function.
6906
55089490
TT
69072018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
6908 Tom Tromey <tom@tromey.com>
6909
6910 * target.h (memory_write_request_s): Remove typedef. Don't define
6911 VEC.
6912 (target_write_memory_blocks): Change argument to std::vector.
6913 (struct memory_write_request): Add constructor.
6914 * target-memory.c (compare_block_starting_address): Return bool.
6915 Change argument types.
6916 (claim_memory): Change arguments to use std::vector.
6917 (split_regular_and_flash_blocks, blocks_to_erase)
6918 (compute_garbled_blocks): Likewise.
6919 (cleanup_request_data, cleanup_write_requests_vector): Remove.
6920 (target_write_memory_blocks): Change argument to std::vector.
6921 * symfile.c (struct load_section_data): Add constructor and
6922 destructor. Use std::vector for "requests".
6923 (struct load_progress_data): Add initializers.
6924 (load_section_callback): Update. Use "new".
6925 (clear_memory_write_data): Remove.
6926 (generic_load): Update.
6927
0c305b61
AH
69282018-02-27 Alan Hayward <alan.hayward@arm.com>
6929
6930 * arch/aarch64.h: Use common/tdesc.h.
6931
c5196c92
MR
69322018-02-26 Maciej W. Rozycki <macro@mips.com>
6933
6934 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
6935 architecture with a 64-bit ABI.
6936
37c33887
MR
69372018-02-26 Maciej W. Rozycki <macro@mips.com>
6938
6939 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
6940 ahead of target description loading.
6941
d4dd3282
TT
69422018-02-26 Tom Tromey <tom@tromey.com>
6943
6944 * stack.c (backtrace_command_1): Update.
6945 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
6946 of "flags".
6947 * python/py-framefilter.c (py_print_frame)
6948 (gdbpy_apply_frame_filter): Change type of "flags".
6949 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
6950 of "flags".
6951 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
6952 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
6953 * extension.h (enum frame_filter_flag): Rename from
6954 frame_filter_flags.
6955 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
6956 (apply_ext_lang_frame_filter): Change type of "flags".
6957 * extension.c (apply_ext_lang_frame_filter): Change type of
6958 "flags".
6959 * extension-priv.h (struct extension_language_ops)
6960 <apply_frame_filter>: Change type of "flags".
6961
6893c19a
TT
69622018-02-26 Tom Tromey <tom@tromey.com>
6963
6964 PR python/16497:
6965 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
6966 off-by-one in py_end computation.
6967 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
6968 PRINT_MORE_FRAMES.
6969 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
6970 constant.
6971
2ddeaf8a
TT
69722018-02-26 Tom Tromey <tom@tromey.com>
6973
6974 * dwarf2read.c (struct variant_field): New.
6975 (struct nextfield) <variant>: New field.
6976 (dwarf2_add_field): Handle DW_TAG_variant_part.
6977 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
6978 discriminated union.
6979 (read_structure_type): Handle DW_TAG_variant_part.
6980 (handle_struct_member_die): New function, extracted from
6981 process_structure_scope. Handle DW_TAG_variant.
6982 (process_structure_scope): Handle discriminated unions. Call
6983 handle_struct_member_die.
6984
c9317f21
TT
69852018-02-26 Tom Tromey <tom@tromey.com>
6986
6987 * rust-lang.h (rust_last_path_segment): Declare.
6988 * rust-lang.c (rust_last_path_segment): Now public. Change
6989 contract.
6990 (struct disr_info): Remove.
6991 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
6992 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
6993 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
6994 (rust_enum_p, rust_enum_variant): New function.
6995 (rust_underscore_fields): Remove "offset" parameter.
6996 (rust_print_enum): New function.
6997 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
6998 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
6999 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
7000 enums.
7001 (rust_internal_print_type): New function, from rust_print_type.
7002 Remove enum code.
7003 (rust_print_type): Call rust_internal_print_type.
7004 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
7005 Update enum handling.
7006 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
7007 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
7008 (rust_union_quirks): New functions.
7009 (process_full_comp_unit, process_full_type_unit): Call
7010 rust_union_quirks.
7011 (process_structure_scope): Update rust_unions if necessary.
7012
7c22600a
TT
70132018-02-26 Tom Tromey <tom@tromey.com>
7014
7015 * value.h (value_union_variant): Declare.
7016 * valops.c (value_union_variant): New function.
7017 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
7018 (struct discriminant_info): New.
7019 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
7020 enumerator.
7021 (struct main_type) <flag_discriminated_union>: New field.
7022
15ce8941
TT
70232018-02-26 Tom Tromey <tom@tromey.com>
7024
7025 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7026 unittests/unpack-selftests.c.
7027 * unittests/unpack-selftests.c: New file.
7028 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
7029
48fbe735
YQ
70302018-02-26 Yao Qi <yao.qi@linaro.org>
7031
7032 * dwarf2read.c (struct partial_die_info) <read>: New method.
7033 (read_partial_die): Remove the declaration.
7034 (load_partial_dies): Update.
7035 (partial_die_info::partial_die_info):
7036 (read_partial_die): Change it to partial_die_info::read.
7037
52356b79
YQ
70382018-02-26 Yao Qi <yao.qi@linaro.org>
7039
7040 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
7041 (fixup_partial_die): Remove declaration.
7042 (scan_partial_symbols): Update.
7043 (partial_die_parent_scope): Likewise.
7044 (partial_die_full_name): Likewise.
7045 (fixup_partial_die): Change it to partial_die_info::fixup.
7046
35cc7ed7
YQ
70472018-02-26 Yao Qi <yao.qi@linaro.org>
7048
7049 * dwarf2read.c (read_partial_die): Update the declaration.
7050 (load_partial_dies): Caller update.
7051 (read_partial_die): Remove one argument abbrev_len.
7052
6f06d47b
YQ
70532018-02-26 Yao Qi <yao.qi@linaro.org>
7054
7055 * dwarf2read.c (struct partial_die_info): Add ctor, delete
7056 assignment operator.
7057 (load_partial_dies): Use ctor and copy ctor.
7058 (read_partial_die): Update.
7059 (dwarf2_cu::find_partial_die): Use ctor.
7060
d590ff25
YQ
70612018-02-26 Yao Qi <yao.qi@linaro.org>
7062
7063 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
7064 (find_partial_die_in_comp_unit): Change it to
7065 dwarf2_cu::find_partial_die.
7066 (find_partial_die): Update.
7067
fd0a254f
YQ
70682018-02-26 Yao Qi <yao.qi@linaro.org>
7069
7070 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
7071 is NULL.
7072
cd9983dd
YQ
70732018-02-26 Yao Qi <yao.qi@linaro.org>
7074
7075 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
7076
f46cd62a
AH
70772018-02-26 Alan Hayward <alan.hayward@arm.com>
7078
7079 * arch/amd64.h: Use common/tdesc.h.
7080 * arch/i386.c: Likewise.
7081 * arch/i386.h: Likewise.
7082 * arch/tic6x.c: Likewise.
7083 * arch/tdesc.h: Move file from here...
7084 * common/tdesc.h: ...to here.
7085 * features/aarch64-core.c: Regenerate.
7086 * features/aarch64-fpu.c: Regenerate.
7087 * features/i386/32bit-avx.c: Regenerate.
7088 * features/i386/32bit-avx512.c: Regenerate.
7089 * features/i386/32bit-core.c: Regenerate.
7090 * features/i386/32bit-linux.c: Regenerate.
7091 * features/i386/32bit-mpx.c: Regenerate.
7092 * features/i386/32bit-pkeys.c: Regenerate.
7093 * features/i386/32bit-sse.c: Regenerate.
7094 * features/i386/64bit-avx.c: Regenerate.
7095 * features/i386/64bit-avx512.c: Regenerate.
7096 * features/i386/64bit-core.c: Regenerate.
7097 * features/i386/64bit-linux.c: Regenerate.
7098 * features/i386/64bit-mpx.c: Regenerate.
7099 * features/i386/64bit-pkeys.c: Regenerate.
7100 * features/i386/64bit-segments.c: Regenerate.
7101 * features/i386/64bit-sse.c: Regenerate.
7102 * features/i386/x32-core.c: Regenerate.
7103 * features/tic6x-c6xp.c: Regenerate.
7104 * features/tic6x-core.c: Regenerate.
7105 * features/tic6x-gp.c: Regenerate.
7106 * target-descriptions.c: Use common/tdesc.h.
7107 * target-descriptions.h: Likewise.
7108
9b292f68
TT
71092018-02-24 Tom Tromey <tom@tromey.com>
7110
7111 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
7112 (try_thread_db_load_from_dir, thread_db_load_search): Use
7113 std::string.
7114 (info_auto_load_libthread_db_compare): Return bool. Change
7115 argument types.
7116 (info_auto_load_libthread_db): Use std::vector, std::string.
7117 Remove cleanups.
7118
281d762b
TT
71192018-02-24 Tom Tromey <tom@tromey.com>
7120
7121 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
7122 std::string.
7123 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
7124 std::string*.
7125 * gdbarch.c: Rebuild.
7126 * gdbarch.h: Rebuild.
7127 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
7128 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
7129 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
7130 std::string*.
7131
9d8780f0
SM
71322018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
7133
7134 * gdbtypes.h (sect_offset): Change type to uint64_t.
7135 (sect_offset_str): New function.
7136 * dwarf2read.c (create_addrmap_from_aranges): Use
7137 sect_offset_str.
7138 (error_check_comp_unit_head): Likewise.
7139 (create_debug_type_hash_table): Likewise.
7140 (read_cutu_die_from_dwo): Likewise.
7141 (init_cutu_and_read_dies): Likewise.
7142 (init_cutu_and_read_dies_no_follow): Likewise.
7143 (process_psymtab_comp_unit_reader): Likewise.
7144 (partial_die_parent_scope): Likewise.
7145 (peek_die_abbrev): Likewise.
7146 (process_queue): Likewise.
7147 (dwarf2_physname): Likewise.
7148 (read_namespace_alias): Likewise.
7149 (read_import_statement): Likewise.
7150 (create_dwo_cu_reader): Likewise.
7151 (create_cus_hash_table): Likewise.
7152 (lookup_dwo_cutu): Likewise.
7153 (inherit_abstract_dies): Likewise.
7154 (read_func_scope): Likewise.
7155 (read_call_site_scope): Likewise.
7156 (dwarf2_add_member_fn): Likewise.
7157 (read_common_block): Likewise.
7158 (read_module_type): Likewise.
7159 (read_typedef): Likewise.
7160 (read_subrange_type): Likewise.
7161 (load_partial_dies): Likewise.
7162 (read_partial_die): Likewise.
7163 (find_partial_die): Likewise.
7164 (read_str_index): Likewise.
7165 (dwarf2_string_attr): Likewise.
7166 (build_error_marker_type): Likewise.
7167 (lookup_die_type): Likewise.
7168 (dump_die_shallow): Likewise.
7169 (follow_die_ref): Likewise.
7170 (dwarf2_fetch_die_loc_sect_off): Likewise.
7171 (dwarf2_fetch_constant_bytes): Likewise.
7172 (follow_die_sig): Likewise.
7173 (get_signatured_type): Likewise.
7174 (get_DW_AT_signature_type): Likewise.
7175 (dwarf2_find_containing_comp_unit): Likewise.
7176 (set_die_type): Likewise.
7177
8ec57239
JB
71782018-02-21 John Baldwin <jhb@FreeBSD.org>
7179
7180 * arch/aarch64.c: Include "common-defs.h".
7181 * arch/amd64.c: Likewise.
7182 * arch/i386.c: Likewise.
7183
3eac2b65
TT
71842018-02-21 Tom Tromey <tom@tromey.com>
7185
7186 * value.h: (extract_field_op): Update.
7187 * eval.c (extract_field_op): Return a const char *.
7188 * expression.h (parse_expression_for_completion): Update.
7189 * completer.c (complete_expression): Update.
7190 (add_struct_fields): Make fieldname const.
7191 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
7192 (mark_completion_tag, parse_exp_in_context_1): Update.
7193 (parse_expression_for_completion): Change "name" to
7194 unique_xmalloc_ptr*.
7195
6ccb583f
TT
71962018-02-21 Tom Tromey <tom@tromey.com>
7197
7198 * infcall.c (call_function_by_hand_dummy): Use std::vector.
7199
c113ed0c
YQ
72002018-02-21 Yao Qi <yao.qi@linaro.org>
7201
7202 * avr-tdep.c (avr_read_pc): Change parameter type to
7203 readable_regcache.
7204 * gdbarch.sh (read_pc): Likewise.
7205 * gdbarch.c: Re-generated.
7206 * gdbarch.h: Re-generated.
7207 * hppa-tdep.c (hppa_read_pc): Change parameter type to
7208 readable_regcache.
7209 * ia64-tdep.c (ia64_read_pc): Likewise.
7210 * mips-tdep.c (mips_read_pc): Likewise.
7211 * spu-tdep.c (spu_read_pc): Likewise.
7212
4c74fe6b
YQ
72132018-02-21 Yao Qi <yao.qi@linaro.org>
7214
7215 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
7216 * regcache-dump.c: New file.
7217 * regcache.c: Move register_dump to regcache-dump.c.
7218 (maintenance_print_registers): Likewise.
7219 (maintenance_print_raw_registers): Likewise.
7220 (maintenance_print_cooked_registers): Likewise.
7221 (maintenance_print_register_groups): Likewise.
7222 (maintenance_print_remote_registers): Likewise.
7223 (_initialize_regcache): Likewise.
7224 * regcache.h (register_dump): Moved from regcache.c.
7225
796bb026
YQ
72262018-02-21 Yao Qi <yao.qi@linaro.org>
7227
7228 * regcache.c (regcache::regcache): Update.
7229 (regcache::invalidate): Move it to detached_regcache::invalidate.
7230 (get_thread_arch_aspace_regcache): Update.
7231 (regcache::raw_update): Update.
7232 (regcache::cooked_read): Remove some code.
7233 (regcache::cooked_read_value): Likewise.
7234 (regcache::raw_write): Remove assert on m_readonly_p.
7235 (regcache::raw_supply_integer): Move it to
7236 detached_regcache::raw_supply_integer.
7237 (regcache::raw_supply_zeroed): Likewise.
7238 * regcache.h (detached_regcache) <raw_supply_integer>: New
7239 declaration.
7240 <raw_supply_zeroed, invalidate>: Likewise.
7241 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
7242 <invalidate>: Likewise.
7243 <m_readonly_p>: Removed.
7244
215c69dc
YQ
72452018-02-21 Yao Qi <yao.qi@linaro.org>
7246
7247 * infcmd.c (get_return_value): Let stop_regs point to
7248 get_current_regcache.
7249 * regcache.c (regcache::regcache): Remove.
7250 (register_dump_reg_buffer): New class.
7251 (regcache_print): Adjust.
7252 * regcache.h (regcache): Remove constructors.
7253
f3384e66
YQ
72542018-02-21 Yao Qi <yao.qi@linaro.org>
7255
7256 * regcache.c (class register_dump): New class.
7257 (register_dump_regcache, register_dump_none): New class.
7258 (register_dump_remote, register_dump_groups): New class.
7259 (regcache_print): Update.
7260 * regcache.h (regcache_dump_what): Move it to regcache.c.
7261 (regcache) <dump>: Remove.
7262
c8ec2f33
YQ
72632018-02-21 Yao Qi <yao.qi@linaro.org>
7264
7265 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
7266 reg_buffer_rw *.
7267 (jit_unwind_reg_set_impl): Call raw_supply.
7268 (jit_frame_sniffer): Use reg_buffer_rw.
7269 * record-full.c (record_full_core_regbuf): Change its type.
7270 (record_full_core_open_1): Use reg_buffer_rw.
7271 (record_full_close): Likewise.
7272 (record_full_core_fetch_registers): Use regcache->raw_supply.
7273 (record_full_core_store_registers): Likewise.
7274 * regcache.c (regcache::get_register_status): Move it to
7275 reg_buffer.
7276 (regcache_raw_set_cached_value): Remove.
7277 (regcache::raw_set_cached_value): Remove.
7278 (regcache::raw_write): Call raw_supply.
7279 (regcache::raw_supply): Move it to reg_buffer_rw.
7280 * regcache.h (regcache_raw_set_cached_value): Remove.
7281 (reg_buffer_rw): New class.
7282
daf6667d
YQ
72832018-02-21 Yao Qi <yao.qi@linaro.org>
7284
7285 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
7286 readonly_detached_regcache.
7287 (dummy_frame_prev_register): Use regcache->cooked_read.
7288 * frame.c (frame_save_as_regcache): Change return type.
7289 (frame_pop): Update.
7290 * frame.h (frame_save_as_regcache): Update declaration.
7291 * inferior.h (get_infcall_suspend_state_regcache): Update
7292 declaration.
7293 * infrun.c (infcall_suspend_state) <registers>: use
7294 readonly_detached_regcache.
7295 (save_infcall_suspend_state): Don't use regcache_dup.
7296 (get_infcall_suspend_state_regcache): Change return type.
7297 * linux-fork.c (struct fork_info) <savedregs>: Change to
7298 readonly_detached_regcache.
7299 <pc>: New field.
7300 (fork_save_infrun_state): Don't use regcache_dup.
7301 (info_checkpoints_command): Adjust.
7302 * mi/mi-main.c (register_changed_p): Update declaration.
7303 (mi_cmd_data_list_changed_registers): Use
7304 readonly_detached_regcache.
7305 (register_changed_p): Change parameter type to
7306 readonly_detached_regcache.
7307 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
7308 readonly_detached_regcache.
7309 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
7310 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
7311 New.
7312 (regcache::save): Move it to reg_buffer.
7313 (regcache::restore): Change parameter type.
7314 (regcache_dup): Remove.
7315 * regcache.h (reg_buffer) <save>: New method.
7316 (readonly_detached_regcache): New class.
7317 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
7318 readonly_detached_regcache.
7319 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
7320
fc5b8736
YQ
73212018-02-21 Yao Qi <yao.qi@linaro.org>
7322
7323 * frame.c (frame_save_as_regcache): Use regcache method save.
7324 (frame_pop): Use regcache method restore.
7325 * infrun.c (restore_infcall_suspend_state): Likewise.
7326 * linux-fork.c (fork_load_infrun_state): Likewise.
7327 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
7328 save.
7329 * regcache.c (regcache_save): Remove.
7330 (regcache::restore): More asserts.
7331 (regcache_cpy): Remove.
7332 * regcache.h (regcache_save): Remove the declaration.
7333 (regcache::restore): Move from private to public.
7334 Remove the friend declaration of regcache_cpy.
7335 (regcache_cpy): Remove declaration.
7336
849d0ba8
YQ
73372018-02-21 Yao Qi <yao.qi@linaro.org>
7338
7339 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
7340 parameter type to 'readable_regcache *'.
7341 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
7342 * arm-tdep.c (arm_neon_quad_read): Likewise.
7343 (arm_pseudo_read): Likewise.
7344 * avr-tdep.c (avr_pseudo_register_read): Likewise.
7345 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
7346 * frv-tdep.c (frv_pseudo_register_read): Likewise.
7347 * gdbarch.c: Re-generated.
7348 * gdbarch.h: Re-generated.
7349 * gdbarch.sh (pseudo_register_read): Change parameter type to
7350 'readable_regcache *'.
7351 (pseudo_register_read_value): Likewise.
7352 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
7353 (h8300_pseudo_register_read): Likewise.
7354 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
7355 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
7356 (i386_pseudo_register_read_into_value): Likewise.
7357 (i386_pseudo_register_read_value): Likewise.
7358 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
7359 declaration.
7360 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
7361 * m32c-tdep.c (m32c_raw_read): Likewise.
7362 (m32c_read_flg): Likewise.
7363 (m32c_banked_register): Likewise.
7364 (m32c_banked_read): Likewise.
7365 (m32c_sb_read): Likewise.
7366 (m32c_part_read): Likewise.
7367 (m32c_cat_read): Likewise.
7368 (m32c_r3r2r1r0_read): Likewise.
7369 (m32c_pseudo_register_read): Likewise.
7370 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
7371 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
7372 (mep_pseudo_cr64_read): Likewise.
7373 (mep_pseudo_register_read): Likewise.
7374 * mips-tdep.c (mips_pseudo_register_read): Likewise.
7375 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
7376 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
7377 * regcache.c (regcache::raw_read): Move it to readable_regcache.
7378 (regcache::cooked_read): Likewise.
7379 (regcache::cooked_read_value): Likewise.
7380 (regcache_cooked_read_signed):
7381 (regcache::cooked_read): Likewise.
7382 * regcache.h (readable_regcache): New class.
7383 (regcache): Inherit readable_regcache. Move some methods to
7384 readable_regcache.
7385 * rl78-tdep.c (rl78_pseudo_register_read): Change
7386 parameter type to 'readable_regcache *'.
7387 * rs6000-tdep.c (do_regcache_raw_read): Remove.
7388 (e500_pseudo_register_read): Change parameter type to
7389 'readable_regcache *'.
7390 (dfp_pseudo_register_read): Likewise.
7391 (vsx_pseudo_register_read): Likewise.
7392 (efpr_pseudo_register_read): Likewise.
7393 * s390-tdep.c (s390_pseudo_register_read): Likewise.
7394 * sh-tdep.c (sh_pseudo_register_read): Likewise.
7395 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
7396 (sh64_pseudo_register_read): Likewise.
7397 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
7398 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
7399 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
7400 (spu_pseudo_register_read): Likewise.
7401 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
7402 (xtensa_pseudo_register_read): Likewise.
7403
31716595
YQ
74042018-02-21 Yao Qi <yao.qi@linaro.org>
7405
7406 * regcache.c (regcache::regcache): Call reg_buffer ctor.
7407 (regcache::arch): Move it to reg_buffer::arch.
7408 (regcache::register_buffer): Likewise.
7409 (regcache::assert_regnum): Likewise.
7410 (regcache::num_raw_registers): Likewise.
7411 * regcache.h (reg_buffer): New class.
7412 (regcache): Inherit reg_buffer.
7413
7104e59b
SM
74142018-02-20 Simon Marchi <simon.marchi@ericsson.com>
7415
7416 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
7417 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
7418
2d8adcbd
MM
74192018-02-20 Markus Metzger <markus.t.metzger@intel.com>
7420
7421 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
7422
b5884fa7
AH
74232018-02-19 Alan Hayward <alan.hayward@arm.com>
7424
7425 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
7426 (SFILES): Remove common/*.c files.
7427 (COMMON_OBS): Remove some *.o files built from common/*.c files.
7428 * common/common.host: Add common reference.
7429 * configure.ac: Likewise.
7430 * configure: Regenerate.
7431
fd90ace4
YQ
74322018-02-16 Yao Qi <yao.qi@linaro.org>
7433
7434 * block.c (block_namespace_info): Inherit allocate_on_obstack.
7435 (block_initialize_namespace): Use new.
7436 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
7437 (dwarf2_free_objfile): Use delete.
7438 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
7439 (copy_type_recursive): Use new.
7440 * gdb_obstack.h (allocate_on_obstack): New.
7441
85046ae2
YQ
74422018-02-15 Yao Qi <yao.qi@linaro.org>
7443
7444 PR gdb/22849
7445 * inferior.c (exit_inferior_1): Reset inf->control.
7446
355c559b
JB
74472018-02-15 Joel Brobecker <brobecker@adacore.com>
7448
7449 * ada-lang.c (ada_to_fixed_value_create): Delete advance
7450 declaration.
7451
980548fd
PA
74522018-02-14 Pedro Alves <palves@redhat.com>
7453
7454 * frame-unwind.c (frame_unwind_try_unwinder): Always call
7455 frame_cleanup_after_sniffer on exception.
7456
692d6f97
TT
74572018-02-14 Tom Tromey <tom@tromey.com>
7458
7459 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
7460 const.
7461 (solib_bfd_open): Make pathname const.
7462 * solib.c (solib_bfd_open): Make pathname const.
7463 * solib-spu.c (spu_bfd_fopen): Make name const.
7464 (spu_bfd_open): Make pathname const.
7465 * solib-darwin.c (darwin_bfd_open): Make pathname const.
7466 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
7467
e0cc99a6
TT
74682018-02-14 Tom Tromey <tom@tromey.com>
7469
7470 * symfile.c (symfile_bfd_open): Update.
7471 * source.h (openp, source_full_path_of, find_and_open_source):
7472 Change argument type to unique_xmalloc_ptr.
7473 * source.c (openp): Take a unique_xmalloc_ptr.
7474 (source_full_path_of, find_and_open_source): Likewise.
7475 (open_source_file, symtab_to_fullname): Update.
7476 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
7477 unique_xmalloc_ptr.
7478 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
7479 (exec_file_find): Update.
7480 * psymtab.c (psymtab_to_fullname): Update.
7481 * nto-tdep.h (nto_find_and_open_solib): Update.
7482 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
7483 unique_xmalloc_ptr.
7484 * exec.c (exec_file_attach): Update.
7485 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
7486 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
7487
b46a8d7c
TT
74882018-02-14 Tom Tromey <tom@tromey.com>
7489
7490 * solib.c: Include source.h.
7491 * nto-tdep.c: Include source.h.
7492 * mi/mi-cmd-env.c: Include source.h.
7493 * infcmd.c: Include source.h.
7494 * exec.c: Include source.h.
7495 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
7496 (add_path, directory_switch, source_path, init_source_path): Move
7497 declarations...
7498 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
7499 (add_path, directory_switch, source_path, init_source_path):
7500 ...here.
7501
797bc1cb
TT
75022018-02-14 Tom Tromey <tom@tromey.com>
7503
7504 * solist.h (exec_file_find, solib_find): Return
7505 unique_xmalloc_ptr.
7506 (solib_bfd_fopen): Take a const char *.
7507 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
7508 (exec_file_find, solib_find): Likewise.
7509 (solib_bfd_fopen): Do not take ownership of "pathname".
7510 (solib_bfd_open): Use unique_xmalloc_ptr.
7511 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
7512 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
7513 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
7514 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
7515
f98b2e33
JB
75162018-02-14 Joel Brobecker <brobecker@adacore.com>
7517
7518 * ada-lang.c (name_match_type_from_name): Remove reference to
7519 ada_name_for_lookup in function's documentation.
7520 * ada-lang.h (ada_name_for_lookup): Delete declaration.
7521
24b9144d
SM
75222018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
7523
7524 * defs.h (enum openp_flags): New enum.
7525 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
7526 Move to enum openp_flags.
7527 (openp_flags): New enum flags.
7528 (openp): Change parameter type to openp_flags.
7529 * source.c (openp): Change parameter type to openp_flags.
7530 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
7531 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
7532
387cd15b
SM
75332018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
7534
7535 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
7536 per-command.
7537
b303c6f6
AB
75382018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
7539
7540 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
7541 into...
7542 (class dwarf2_queue_guard): ...the destructor of this new class.
7543 (dw2_do_instantiate_symtab): Create instance of the new class
7544 dwarf2_queue_guard, remove cleanup.
7545
9c3630e9
TT
75462018-02-09 Tom Tromey <tom@tromey.com>
7547
7548 * source.c (find_source_lines): Don't reference past the end of
7549 the vector.
7550
c4e12631
MM
75512018-02-09 Markus Metzger <markus.t.metzger@intel.com>
7552
7553 * remote.c (remote_btrace_maybe_reopen): Change error message.
7554 * btrace.c (btrace_enable): Likewise.
7555 (parse_xml_btrace): Likewise.
7556 (parse_xml_btrace_conf): Likewise.
7557
88711fbf
MM
75582018-02-09 Markus Metzger <markus.t.metzger@intel.com>
7559
7560 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
7561 (linux_enable_pt, linux_enable_bts): Call
7562 diagnose_perf_event_open_fail.
7563
17ad2a4f
MM
75642018-02-09 Markus Metzger <markus.t.metzger@intel.com>
7565
7566 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
7567 Remove parameter and change return type. Update callers. Move it.
7568 (linux_enable_bts, linux_enable_pt): Improve error message.
7569 (linux_enable_pt): Remove zero buffer size check.
7570 (linux_enable_btrace): Improve error messages. Remove NULL return
7571 check.
7572
de6242d3
MM
75732018-02-09 Markus Metzger <markus.t.metzger@intel.com>
7574
7575 * btrace.c (btrace_enable): Remove target_supports_btrace call.
7576 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
7577 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
7578 (linux_supports_pt, linux_supports_btrace): Remove.
7579 (linux_enable_bts): Call cpu_supports_bts.
7580 * nat/linux-btrace.h (linux_supports_btrace): Remove.
7581 * remote.c (remote_supports_btrace): Remove.
7582 (init_remote_ops): Remove remote_supports_btrace.
7583 * target-delegates.c: Regenerated.
7584 * target.c (target_supports_btrace): Remove.
7585 * target.h (target_ops) <to_supports_btrace>: Remove
7586 (target_supports_btrace): Remove.
7587 * x86-linux-nat.c (x86_linux_create_target): Remove
7588 linux_supports_btrace.
7589
9ee23a85
MM
75902018-02-09 Markus Metzger <markus.t.metzger@intel.com>
7591
7592 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
7593 btrace failed.
7594 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
7595 exception and use message in own exception.
7596
5c3284c1
MM
75972018-02-09 Markus Metzger <markus.t.metzger@intel.com>
7598
7599 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
7600 (perf_event_pt_event_type): Use gdb_file_up.
7601 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
7602 scoped_fd, and scoped_mmap.
7603
84696f37
MM
76042018-02-09 Markus Metzger <markus.t.metzger@intel.com>
7605
7606 * common/scoped_mmap.h: New.
7607 * unittests/scoped_mmap-selftest.c: New.
7608 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7609 unittests/scoped_mmap-selftest.c.
7610
ea4a0888
MM
76112018-02-09 Markus Metzger <markus.t.metzger@intel.com>
7612
7613 * common/scoped_fd.h: New.
7614 * unittests/scoped_fd-selftest.c: New.
7615 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7616 unittests/scoped_fd-selftest.c.
7617
869e8290
TT
76182018-02-09 Tom Tromey <tom@tromey.com>
7619
7620 * auto-load.c (auto_load_section_scripts): Use
7621 gdb::unique_xmalloc_ptr.
7622
a37a2ae7
TT
76232018-02-09 Tom Tromey <tom@tromey.com>
7624
7625 * auto-load.c (execute_script_contents): Use std::string.
7626
4e725347
JB
76272018-02-09 Joel Brobecker <brobecker@adacore.com>
7628
7629 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
7630 Python function, rather than a new command.
7631
9a897d43
TT
76322018-02-08 Tom Tromey <tom@tromey.com>
7633
7634 * solib.c (solib_find_1): Use std::string.
7635 (solib_bfd_fopen): Use unique_xmalloc_ptr.
7636
58ef3771
TT
76372018-02-08 Tom Tromey <tom@tromey.com>
7638
7639 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
7640
a9abc434
TT
76412018-02-08 Tom Tromey <tom@tromey.com>
7642
7643 * source.c (find_source_lines): Use gdb::def_vector.
7644
84f27c6f
TT
76452018-02-08 Tom Tromey <tom@tromey.com>
7646
7647 * macrocmd.c (struct temporary_macro_definition): New.
7648 (macro_define_command): Use temporary_macro_definition. Remove
7649 cleanups.
7650 (free_macro_definition_ptr): Remove.
7651
0354904b
TT
76522018-02-08 Tom Tromey <tom@tromey.com>
7653
7654 * macroexp.c (maybe_expand): Use std::string.
7655
1739cf24
TT
76562018-02-08 Tom Tromey <tom@tromey.com>
7657
7658 * macroexp.c (struct macro_buffer): Add initializers for some
7659 members.
7660 (init_buffer, init_shared_buffer, free_buffer)
7661 (free_buffer_return_text): Remove.
7662 (macro_buffer): New constructors.
7663 (~macro_buffer): New destructor.
7664 (macro_buffer::set_shared): New method.
7665 (macro_buffer::resize_buffer, macro_buffer::appendc)
7666 (macro_buffer::appendmem): Now methods, not free functions.
7667 (set_token, append_tokens_without_splicing, stringify)
7668 (macro_stringify): Update.
7669 (gather_arguments): Change return type. Remove argc_p argument,
7670 add args_ptr argument. Use std::vector.
7671 (substitute_args): Remove argc argument. Accept std::vector.
7672 (expand): Update. Use std::vector.
7673 (scan, macro_expand, macro_expand_next): Update.
7674
f6c2623e
TT
76752018-02-08 Tom Tromey <tom@tromey.com>
7676
7677 * symtab.c (default_collect_symbol_completion_matches_break_on):
7678 Use unique_xmalloc_ptr.
7679 * macroscope.h: (sal_macro_scope, user_macro_scope)
7680 (default_macro_scope): Return unique_xmalloc_ptr.
7681 * macroscope.c (sal_macro_scope, user_macro_scope)
7682 (default_macro_scope): Return unique_xmalloc_ptr.
7683 * macroexp.h (macro_expand, macro_expand_once): Return
7684 unique_xmalloc_ptr.
7685 * macroexp.c (macro_expand, macro_expand_once): Return
7686 unique_xmalloc_ptr.
7687 * macrocmd.c (macro_expand_command, macro_expand_once_command)
7688 (info_macro_command, info_macros_command): Use
7689 unique_xmalloc_ptr.
7690 * compile/compile-c-support.c (write_macro_definitions): Use
7691 unique_xmalloc_ptr.
7692 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
7693
c2e0e465
SM
76942018-02-07 Simon Marchi <simon.marchi@ericsson.com>
7695
7696 * value.c (value_static_field): Assign field type instead of
7697 containing type when returning an optimized out value.
7698
3f8c94b4
YQ
76992018-02-06 Yao Qi <yao.qi@linaro.org>
7700
7701 * ft32-tdep.c (ft32_read_pc): Remove.
7702 (ft32_write_pc): Remove.
7703 (ft32_gdbarch_init): Update.
7704 * m32r-tdep.c (m32r_read_pc): Remove.
7705 (m32r_gdbarch_init): Update.
7706 * mep-tdep.c (mep_read_pc): Remove.
7707 (mep_gdbarch_init): Update.
7708 * microblaze-tdep.c (microblaze_write_pc): Remove.
7709 (microblaze_gdbarch_init): Update.
7710 * mn10300-tdep.c (mn10300_read_pc): Remove.
7711 (mn10300_write_pc): Remove.
7712 (mn10300_gdbarch_init): Update.
7713 * moxie-tdep.c (moxie_read_pc): Remove.
7714 (moxie_write_pc): Remove.
7715 (moxie_gdbarch_init): Update.
7716
bca65a23
YQ
77172018-02-06 Yao Qi <yao.qi@linaro.org>
7718
7719 * expprint.c (print_subexp_standard): Handle
7720 OP_F77_UNDETERMINED_ARGLIST.
7721 (dump_subexp_body_standard): Likewise.
7722
583e3f90 77232018-02-05 Alan Hayward <alan.hayward@arm.com>
b8df6ca7 7724
583e3f90
YQ
7725 * target-descriptions.c (tdesc_element_visitor) Add empty
7726 implementations.
b8df6ca7
AH
7727 (tdesc_type): Move make_gdb_type from here.
7728 (tdesc_type_builtin): Likewise.
7729 (tdesc_type_vector): Likewise.
7730 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
7731 (make_gdb_type_struct): Move from tdesc_type_with_fields.
7732 (make_gdb_type_union): Likewise.
7733 (make_gdb_type_flags): Likewise.
7734 (make_gdb_type_enum): Likewise.
7735 (make_gdb_type): New function.
7736 (tdesc_register_type): Use static make_gdb_type.
7737
e813d34a
RK
77382018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
7739
7740 * infcmd.c (default_print_one_register_info): Align natural-format
7741 column values consistently one under another.
7742 (pad_to_column): New function.
7743
0eb876f5
JB
77442018-02-05 Joel Brobecker <brobecker@adacore.com>
7745
7746 * dwarf2read.c (dwarf2_physname): Move commment.
7747
0625771b
LS
77482018-02-01 Leszek Swirski <leszeks@google.com>
7749
7750 * varobj.c (varobj_formatted_print_options): Allow recursive
7751 pretty printing if pretty printing is enabled.
7752
59498c30
LS
77532018-02-01 Leszek Swirski <leszeks@google.com>
7754
7755 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
7756 names after a structop as a filename.
7757
2d9e6acb
YQ
77582018-02-01 Yao Qi <yao.qi@linaro.org>
7759
7760 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
7761 (arm_record_coproc_data_proc): Likewise.
7762
df95a9cf
YQ
77632018-02-01 Yao Qi <yao.qi@linaro.org>
7764
7765 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
7766
07e5f5cf
NP
77672018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
7768
7769 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
7770 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
7771
3045b475
PA
77722018-01-31 Pedro Alves <palves@redhat.com>
7773
7774 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
7775 * inflow.c (child_terminal_save_inferior): Wrap reference to
7776 tcgetpgrp in HAVE_TERMIOS_H.
7777 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
7778 _WIN32.
7779 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
7780 always iterate over all inferiors.
7781 (gdbsim_cntrl_c): Adjust.
7782 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
7783
929b5ad4
JB
77842018-01-31 Joel Brobecker <brobecker@adacore.com>
7785
7786 * gdbtypes.c (lookup_array_range_type): Make sure the array's
7787 index type is objfile-owned if the element type is as well.
7788
29236ca2
JB
77892018-01-31 Joel Brobecker <brobecker@adacore.com>
7790
7791 GDB 8.1 released.
7792
c81e8879
PR
77932018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
7794
7795 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
7796 "features/s390x-linux64.c".
7797 (_initialize_s390_linux_tdep): Remove initialization of tdescs
7798 s390_linux32 and s390x_linux64.
7799 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
7800 default tdesc.
7801 * s390-tdep.c: Include "features/s390-linux32.c" and
7802 "features/s390x-linux64.c".
7803 (s390_tdesc_valid): Add check for tdesc_has_registers.
7804 (s390_gdbarch_init): Make sure there is always a valid tdesc.
7805 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
7806 tdesc_s390x_linux64.
7807 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
7808 tdesc_s390x_linux64 to...
7809 * s390-tdep.h: ...here.
7810
e671cd59
PA
78112018-01-30 Pedro Alves <palves@redhat.com>
7812
7813 PR gdb/13211
7814 * config.in, configure: Regenerate.
7815 * configure.ac: Check for getpgid.
7816 * go32-nat.c (go32_pass_ctrlc): New.
7817 (go32_target): Install it.
7818 * inf-child.c (inf_child_target): Install
7819 child_terminal_save_inferior, child_pass_ctrlc and
7820 child_interrupt.
7821 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
7822 (inf_ptrace_target): No longer install it.
7823 * infcmd.c (interrupt_target_1): Adjust.
7824 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
7825 (child_interrupt): Declare.
7826 (inferior::terminal_state): New.
7827 * inflow.c (struct terminal_info): Update comments.
7828 (inferior_process_group): Delete.
7829 (terminal_is_ours): Delete.
7830 (gdb_tty_state): New.
7831 (child_terminal_init): Adjust.
7832 (is_gdb_terminal, sharing_input_terminal_1)
7833 (sharing_input_terminal): New functions.
7834 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
7835 Set the process's actual process group in the foreground if
7836 possible. Handle is_ours_for_output/is_ours distinction. Don't
7837 mark terminal as the inferior's if not sharing GDB's terminal.
7838 Don't check attach_flag.
7839 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
7840 pass down a target_terminal_state.
7841 (child_terminal_save_inferior): New, factored out from ...
7842 (child_terminal_ours_1): ... this. Handle
7843 target_terminal_state::is_ours_for_output.
7844 (child_interrupt, child_pass_ctrlc): New.
7845 (inflow_inferior_exit): Clear the inferior's terminal_state.
7846 (copy_terminal_info): Copy the inferior's terminal state.
7847 (_initialize_inflow): Remove reference to terminal_is_ours.
7848 * inflow.h (inferior_process_group): Delete.
7849 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
7850 * procfs.c (procfs_target): Don't install procfs_interrupt.
7851 (procfs_interrupt): Delete.
7852 * remote.c (remote_serial_quit_handler): Adjust.
7853 (remote_interrupt): Remove ptid parameter. Adjust.
7854 * target-delegates.c: Regenerate.
7855 * target.c: Include "terminal.h".
7856 (target_terminal::terminal_state): Rename to ...
7857 (target_terminal::m_terminal_state): ... this.
7858 (target_terminal::init): Adjust.
7859 (target_terminal::inferior): Adjust to per-inferior
7860 terminal_state.
7861 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
7862 (target_terminal::ours, target_terminal::ours_for_output): Use
7863 target_terminal_is_ours_kind.
7864 (target_interrupt): Remove ptid parameter. Adjust.
7865 (default_target_pass_ctrlc): Adjust.
7866 * target.h (target_ops::to_terminal_save_inferior): New field.
7867 (target_ops::to_interrupt): Remove ptid_t parameter.
7868 (target_interrupt): Remove ptid_t parameter. Update comment.
7869 (target_pass_ctrlc): Update comment.
7870 * target/target.h (target_terminal_state): New scoped enum,
7871 factored out of ...
7872 (target_terminal::terminal_state): ... here.
7873 (target_terminal::inferior): Update comments.
7874 (target_terminal::restore_inferior): New.
7875 (target_terminal::is_inferior, target_terminal::is_ours)
7876 (target_terminal::is_ours_for_output): Adjust.
7877 (target_terminal::scoped_restore_terminal_state): Adjust to
7878 rename, and call restore_inferior() instead of inferior().
7879 (target_terminal::scoped_restore_terminal_state::m_state): Change
7880 type.
7881 (target_terminal::terminal_state): Rename to ...
7882 (target_terminal::m_terminal_state): ... this and change type.
7883
9c3a5d93
PA
78842018-01-30 Pedro Alves <palves@redhat.com>
7885
7886 * linux-nat.c (wait_for_signal): New function.
7887 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
7888 directly.
7889 (async_terminal_is_ours)
7890 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
7891 (linux_nat_add_target): Don't override
7892 to_terminal_inferior/to_terminal_ours.
7893
69ab5edb
SDJ
78942018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
7895
7896 * remote.c (remote_follow_fork): Don't call "detach_inferior".
7897
fc8e7e75
SM
78982018-01-28 Simon Marchi <simon.marchi@ericsson.com>
7899
7900 * dwarf2read.c (free_dwo_files): Add forward-declaration.
7901 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
7902 dwarf2_per_objfile_free here.
7903 (dwarf2_per_objfile_free): Remove.
7904 (_initialize_dwarf2_read): Don't register
7905 dwarf2_per_objfile_free as a registry cleanup.
7906
b2a426e2
EZ
79072018-01-27 Eli Zaretskii <eliz@gnu.org>
7908
7909 Avoid compilation errors in MinGW native builds
7910
7911 The error is triggered by including python-internal.h, and the
7912 error message is:
7913
7914 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
7915 from build-gnulib/import/math.h:27,
7916 from d:/usr/Python26/include/pyport.h:235,
7917 from d:/usr/Python26/include/Python.h:58,
7918 from python/python-internal.h:94,
7919 from python/py-arch.c:24:
7920 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
7921 using ::hypot;
7922 ^~~~~
7923
7924 This happens because Python headers define 'hypot' to expand t
7925 '_hypot' in the Windows builds.
7926 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
7927 'hypoth'. This avoids a compilation error.
7928
0bdd8eac
AH
79292018-01-26 Alan Hayward <alan.hayward@arm.com>
7930
7931 * MAINTAINERS (Write After Approval): Fix ordering.
7932
56ae9dc3
AH
79332018-01-26 Alan Hayward <alan.hayward@arm.com>
7934
7935 * MAINTAINERS (Write After Approval): Add Alan Hayward.
7936
7433498b
AM
79372018-01-26 Alan Modra <amodra@gmail.com>
7938
7939 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
7940 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
7941 Remove nop. Make const. Comment.
7942 (powerpc32_plt_stub_so_2): New.
7943 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
7944 Correct count. Update uses.
7945 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
7946 Move common code reading PLT entry word. Correct
7947 powerpc32_plt_stub PLT address calculation.
7948 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
7949 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
7950 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
7951 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
7952 (ppc64_standard_linkage8): Likewise.
7953 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
7954 Correct insns description.
7955 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
7956
0f59d5fc
PA
79572018-01-24 Pedro Alves <palves@redhat.com>
7958
7959 GCC PR libstdc++/83906
7960 * gdbtypes.c (operator==(const dynamic_prop &,
7961 const dynamic_prop &)): New.
7962 (operator==(const range_bounds &, const range_bounds &)): New.
7963 (check_types_equal): Use them instead of memcmp.
7964 * gdbtypes.h (operator==(const dynamic_prop &,
7965 const dynamic_prop &)): Declare.
7966 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
7967 (operator==(const range_bounds &, const range_bounds &)): Declare.
7968 (operator!=(const range_bounds &, const range_bounds &)): Declare.
7969
ef8914a4
PR
79702018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
7971
7972 * s390-linux-tdep.c (s390_record_address_mask)
7973 (s390_record_calc_disp_common, s390_record_calc_disp)
7974 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
7975 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
7976 (s390_process_record): Move to s390-tdep.c.
7977 (s390_linux_init_abi_any): Adjust.
7978 * s390-tdep.c (s390_record_address_mask)
7979 (s390_record_calc_disp_common, s390_record_calc_disp)
7980 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
7981 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
7982 (s390_process_record): Moved from s390-linux-tdep.c
7983 (s390_gdbarch_init): Adjust.
7984
d6e58945
PR
79852018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
7986
7987 * s390-linux-nat.c (s390-tdep.h): New include.
7988 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
7989 (HFILES_NO_SRCDIR): Add s390-tdep.h.
7990 (ALLDEPFILES): Add s390-tdep.c.
7991 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
7992 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
7993 * s390-tdep.h: ...this. New file.
7994 * s390-linux-tdep.c (s390-tdep.h): New include.
7995 (_initialize_s390_tdep): Rename to...
7996 (_initialize_s390_linux_tdep): ...this and adjust.
7997 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
7998 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
7999 s390-tdep.h.
8000 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
8001 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
8002 (s390_is_partial_instruction, s390_software_single_step)
8003 (is_non_branch_ril, s390_displaced_step_copy_insn)
8004 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
8005 (s390_prologue_data, s390_addr, s390_store, s390_load)
8006 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
8007 (s390_register_call_saved, s390_guess_tracepoint_registers)
8008 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
8009 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
8010 (s390_pseudo_register_name, s390_pseudo_register_type)
8011 (s390_pseudo_register_read, s390_pseudo_register_write)
8012 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
8013 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
8014 (s390_addr_bits_remove, s390_address_class_type_flags)
8015 (s390_address_class_type_flags_to_name)
8016 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
8017 (s390_function_arg_float, s390_function_arg_vector)
8018 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
8019 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
8020 (s390_frame_align, s390_register_return_value, s390_return_value)
8021 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
8022 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
8023 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
8024 (s390_trad_frame_prev_register, s390_unwind_cache)
8025 (s390_prologue_frame_unwind_cache)
8026 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
8027 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
8028 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
8029 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
8030 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
8031 (s390_frame_base_address, s390_local_base_address)
8032 (s390_frame_base, s390_gcc_target_options)
8033 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
8034 (s390_validate_reg_range, s390_tdesc_valid)
8035 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
8036 * s390-tdep.c: ...this. New file.
8037
9c0b896e
PR
80382018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8039
8040 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
8041 (s390_process_record, s390_gdbarch_tdep_alloc)
8042 (s390_linux_init_abi_any): Use/set new hook.
8043
7042632b
PR
80442018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8045
8046 * s390-linux-tdep.c (osabi.h): New include.
8047 (s390_linux_init_abi_31, s390_linux_init_abi_64)
8048 (s390_linux_init_abi_any): New functions.
8049 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
8050
650f5e13
PR
80512018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8052
8053 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
8054 tdesc_has_registers check
8055
47c9317e
PR
80562018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8057
8058 * s390-linux-tdep.c (s390_tdesc_valid): New function.
8059 (s390_validate_reg_range): New macro.
8060 (s390_gdbarch_init): Adjust.
8061
095085d8
PR
80622018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8063
8064 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
8065 (s390_gdbarch_tdep_alloc): Adjust.
8066 (s390_gdbarch_init): Adjust.
8067
ab9bcc67
PR
80682018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8069
8070 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
8071 <have_tdb>: Change type to bool.
8072 (s390_gdbarch_tdep_alloc): Adjust.
8073 (s390_gdbarch_init): Adjust.
8074
21f6f5ff
PR
80752018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8076
8077 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
8078 (gdbarch_tdep) <have_upper, have_vx>: New fields.
8079 (s390_gdbarch_tdep_alloc): New function.
8080 (s390_gdbarch_init): Allocate tdep at start and use its fields
8081 instead of separate variables.
8082
0eb97953
PR
80832018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8084
8085 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
8086 when looking for cached gdbarch and add comment for remaining.
8087
5c319bb2
PA
80882018-01-22 Pedro Alves <palves@redhat.com>
8089 Sergio Durigan Junior <sergiodj@redhat.com>
8090
8091 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
8092 case.
8093
d65ce302
MR
80942018-01-22 Maciej W. Rozycki <macro@mips.com>
8095
8096 * MAINTAINERS: Update my company e-mail address.
8097
ec7a5fcb
YQ
80982018-01-22 Yao Qi <yao.qi@linaro.org>
8099
8100 * regcache.c (cooked_write_test): New function.
8101 (_initialize_regcache): Register the test.
8102
11f57cb6
YQ
81032018-01-22 Yao Qi <yao.qi@linaro.org>
8104
8105 * ia64-tdep.c (ia64_pseudo_register_read): Call
8106 regcache->cooked_read instead of regcache_cooked_read_unsigned.
8107 * m32c-tdep.c (m32c_cat_read): Likewise.
8108 (m32c_r3r2r1r0_read): Likewise.
8109 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
8110 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
8111
03f50fc8
YQ
81122018-01-22 Yao Qi <yao.qi@linaro.org>
8113
8114 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
8115 method raw_read instead of regcache_raw_read.
8116 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
8117 * arm-tdep.c (arm_neon_quad_read): Likewise.
8118 * avr-tdep.c (avr_pseudo_register_read): Likewise.
8119 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
8120 * frv-tdep.c (frv_pseudo_register_read): Likewise.
8121 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
8122 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
8123 (i386_pseudo_register_read_into_value): Likewise.
8124 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
8125 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
8126 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
8127 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
8128 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
8129 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
8130 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
8131 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
8132 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
8133
dc711524
YQ
81342018-01-22 Yao Qi <yao.qi@linaro.org>
8135
8136 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
8137 * configure.tgt: Remove target mt.
8138 * mt-tdep.c: Remove.
8139 * regcache.c (cooked_read_test): Remove the check for mt.
8140
3f5a868b
YQ
81412018-01-22 Yao Qi <yao.qi@linaro.org>
8142
8143 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
8144 instead of gdbarch_pseudo_register_read_value.
8145
de4cb04a
JB
81462018-01-22 Joel Brobecker <brobecker@adacore.com>
8147
8148 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
8149 language is Ada.
8150
a9e40818
JB
81512018-01-22 Joel Brobecker <brobecker@adacore.com>
8152
8153 * linespec.c (create_sals_line_offset): Remove code that preserved
8154 the symtab_and_line's line number.
8155
e707fc44
AB
81562018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
8157
8158 * varobj.c (varobj_create): Don't set valid_block when creating a
8159 floating varobj.
8160
03d0bf7b
AB
81612018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
8162
8163 * varobj.c (varobj_create): Remove out of date comment.
8164
ae451627
AB
81652018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
8166
8167 PR mi/20395
8168 * ada-exp.y (write_var_from_sym): Pass extra parameter when
8169 updating innermost block.
8170 * parse.c (innermost_block_tracker::update): Take extra type
8171 parameter, and check types match before updating innermost block.
8172 (write_dollar_variable): Update innermost block for registers.
8173 * parser-defs.h (enum innermost_block_tracker_type): New enum.
8174 (innermost_block_tracker::innermost_block_tracker): Initialise
8175 m_types member.
8176 (innermost_block_tracker::reset): Take type parameter.
8177 (innermost_block_tracker::update): Take type parameter, and pass
8178 type through as needed.
8179 (innermost_block_tracker::m_types): New member.
8180 * varobj.c (varobj_create): Pass type when reseting innermost
8181 block.
8182
aee1fcdf
AB
81832018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
8184
8185 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
8186 * ada-lang.c (resolve_subexp): Likewise.
8187 * breakpoint.c (set_breakpoint_condition) Likewise.
8188 (watch_command_1) Likewise.
8189 * c-exp.y (variable): Likewise.
8190 * d-exp.y (PrimaryExpression): Likewise.
8191 * f-exp.y (variable): Likewise.
8192 * go-exp.y (variable): Likewise.
8193 * m2-exp.y (variable): Likewise.
8194 * objfiles.c (objfile::~objfile): Likewise.
8195 * p-exp.y (variable): Likewise.
8196 * parse.c (innermost_block): Change type.
8197 * parser-defs.h (class innermost_block_tracker): New.
8198 (innermost_block): Change to innermost_block_tracker.
8199 * printcmd.c (display_command): Switch to innermost_block API.
8200 (do_one_display): Likewise.
8201 * rust-exp.y (do_one_display): Likewise.
8202 * symfile.c (clear_symtab_users): Likewise.
8203 * varobj.c (varobj_create): Switch to innermost_block API, replace
8204 use of innermost_block with block stored on varobj object.
8205
396af9a1
AB
82062018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
8207
8208 * expression.h (innermost_block): Remove declaration.
8209 * varobj.c: Add 'parser-defs.h' include.
8210
fcfcc376
TT
82112018-01-19 Tom Tromey <tom@tromey.com>
8212
8213 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
8214 symbols in the static and global blocks.
8215
5a6c3296
JC
82162018-01-19 James Clarke <jrtc27@jrtc27.com>
8217
8218 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
8219 gdb_ptrace.h, and move including gdb_wait.h ...
8220 * nat/linux-ptrace.h: ... to here.
8221
bc09b0c1
SM
82222018-01-19 Simon Marchi <simon.marchi@ericsson.com>
8223
8224 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
8225 inf_ptrace_detach_success.
8226 (inf_ptrace_detach_success): Add inferior parameter, use it
8227 instead of inferior_ptid, pass it to detach_inferior.
8228 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
8229 parameter.
8230 * inferior.c (detach_inferior): Add overload that takes an
8231 inferior object.
8232 * inferior.h (detach_inferior): Likewise.
8233 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
8234 use inferior_ptid, adjust call to inf_ptrace_detach_success.
8235 * linux-thread-db.c (thread_db_detach): Use inf parameter.
8236
6e1e1966
SM
82372018-01-19 Simon Marchi <simon.marchi@ericsson.com>
8238
8239 * target.h (struct target_ops) <to_detach>: Add inferior
8240 parameter.
8241 (target_detach): Likewise.
8242 * target.c (dispose_inferior): Pass inferior down.
8243 (target_detach): Pass inferior down. Assert that it is equal to
8244 the current inferior.
8245 * aix-thread.c (aix_thread_detach): Pass inferior down.
8246 * corefile.c (core_file_command): Pass current_inferior() down.
8247 * corelow.c (core_detach): Add inferior parameter.
8248 * darwin-nat.c (darwin_detach): Likewise.
8249 * gnu-nat.c (gnu_detach): Likewise.
8250 * inf-ptrace.c (inf_ptrace_detach): Likewise.
8251 * infcmd.c (detach_command): Pass current_inferior() down to
8252 target_detach.
8253 * infrun.c (follow_fork_inferior): Pass parent_inf to
8254 target_detach.
8255 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
8256 target_detach.
8257 * linux-nat.c (linux_nat_detach): Add inferior parameter.
8258 * linux-thread-db.c (thread_db_detach): Likewise.
8259 * nto-procfs.c (procfs_detach): Likewise.
8260 * procfs.c (procfs_detach): Likewise.
8261 * record.c (record_detach): Likewise.
8262 * record.h (struct inferior): Forward-declare.
8263 (record_detach): Add inferior parameter.
8264 * remote-sim.c (gdbsim_detach): Likewise.
8265 * remote.c (remote_detach_1): Likewise.
8266 (remote_detach): Likewise.
8267 (extended_remote_detach): Likewise.
8268 * sol-thread.c (sol_thread_detach): Likewise.
8269 * target-debug.h (target_debug_print_inferior_p): New macro.
8270 * target-delegates.c: Re-generate.
8271 * top.c (kill_or_detach): Pass inferior down to target_detach.
8272 * windows-nat.c (windows_detach): Add inferior parameter.
8273
6bd6f3b6
SM
82742018-01-19 Simon Marchi <simon.marchi@ericsson.com>
8275
8276 * target.h (struct target_ops) <to_detach>: Remove args
8277 parameter.
8278 (target_detach): Likewise.
8279 * target.c (dispose_inferior): Adjust.
8280 (target_detach): Remove args parameter, adjust.
8281 * aix-thread.c (aix_thread_detach): Adjust.
8282 * corefile.c (core_file_command): Adjust.
8283 * corelow.c (core_detach): Adjust.
8284 * darwin-nat.c (darwin_detach): Adjust.
8285 * gnu-nat.c (gnu_detach): Adjust.
8286 * inf-ptrace.c (inf_ptrace_detach): Adjust.
8287 * infcmd.c (detach_command): Adjust
8288 * infrun.c (follow_fork_inferior): Adjust.
8289 (handle_vfork_child_exec_or_exit): Adjust.
8290 * linux-fork.c (linux_fork_detach): Remove args parameter.
8291 * linux-fork.h (linux_fork_detach): Likewise.
8292 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
8293 * linux-thread-db.c (thread_db_detach): Likewise.
8294 * nto-procfs.c (procfs_detach): Likewise.
8295 * procfs.c (procfs_detach): Likewise.
8296 (do_detach): Remove signo parameter.
8297 * record.c (record_detach): Remove args parameter.
8298 * record.h (record_detach): Likewise.
8299 * remote-sim.c (gdbsim_detach): Likewise.
8300 * remote.c (remote_detach_1): Likewise.
8301 (remote_detach): Likewise.
8302 (extended_remote_detach): Likewise.
8303 * sol-thread.c (sol_thread_detach): Likewise.
8304 * target-delegates.c: Re-generate.
8305 * top.c (struct qt_args) <args>: Remove field.
8306 (kill_or_detach): Don't pass args.
8307 (quit_force): Don't set args.
8308 * windows-nat.c (windows_detach): Remove args parameter.
8309
88af8ea8
YQ
83102018-01-19 Yao Qi <yao.qi@linaro.org>
8311
8312 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
8313 (arm_linux_init_abi): Install it.
8314
dea445b9
YQ
83152018-01-19 Yao Qi <yao.qi@linaro.org>
8316
8317 * osabi.c (gdb_osabi_names): Extend the regexp for
8318 arm-linux-gnueabihf.
8319
4a17f768
YQ
83202018-01-18 Yao Qi <yao.qi@linaro.org>
8321
8322 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
8323 m_abbrevs.
8324 (abbrev_table::add_abbrev): Update.
8325 (abbrev_table::lookup_abbrev): Update.
8326
d679c21a
YQ
83272018-01-18 Yao Qi <yao.qi@linaro.org>
8328
8329 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
8330
7d937cad
SDJ
83312018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
8332
8333 * compile/compile.c (compile_to_object): Convert "triplet_rx"
8334 to "std::string".
8335
9e14690d
TT
83362018-01-17 Tom Tromey <tom@tromey.com>
8337
8338 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
8339
50a82047
TT
83402018-01-17 Tom Tromey <tom@tromey.com>
8341
8342 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
8343 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
8344 (create_array_type_with_stride): Update.
8345 * dwarf2read.c (set_die_type): Update.
8346
c89b44cd
TT
83472018-01-17 Tom Tromey <tom@tromey.com>
8348
8349 * dwarf2read.c (delayed_method_info): Remove typedef.
8350 (dwarf2_cu::method_info): Now a std::vector.
8351 (add_to_method_list): Update.
8352 (free_delayed_list): Remove.
8353 (compute_delayed_physnames): Update.
8354 (process_full_comp_unit, process_full_type_unit): Clear the method
8355 list. Remove cleanups.
8356 (psymtab_include_file_name): Add name_holder parameter. Use
8357 unique_xmalloc_ptr.
8358 (dwarf_decode_lines): Update.
8359
fcd3b13d
SM
83602018-01-17 Tom Tromey <tom@tromey.com>
8361 Simon Marchi <simon.marchi@ericsson.com>
8362
8363 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
8364 (dwarf2_per_objfile::free_cached_comp_units)
8365 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
8366 (init_cutu_and_read_dies_no_follow): Update.
8367 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
8368 (dwarf2_cu::~dwarf2_cu): New.
8369 (free_heap_comp_unit, free_stack_comp_unit): Remove.
8370 (age_cached_comp_units, free_one_cached_comp_unit): Update.
8371
685af9cd
TT
83722018-01-17 Tom Tromey <tom@tromey.com>
8373 Simon Marchi <simon.marchi@ericsson.com>
8374
8375 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
8376 (struct die_reader_specs) <abbrev_table>: New member.
8377 (struct abbrev_table): Add constructor.
8378 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
8379 <abbrev_obstack>: Now an auto_obstack.
8380 (abbrev_table_up): New typedef.
8381 (init_cu_die_reader): Add abbrev_table parameter.
8382 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
8383 Add result_dwo_abbrev_table.
8384 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
8385 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
8386 Update.
8387 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
8388 parameter.
8389 (skip_children): Update.
8390 (abbrev_table::alloc_abbrev): Rename from
8391 abbrev_table_alloc_abbrev.
8392 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
8393 (abbrev_table::lookup_abbrev): Rename from
8394 abbrev_table_lookup_abbrev.
8395 (abbrev_table_read_table): Return abbrev_table_up.
8396 (abbrev_table_free, abbrev_table_free_cleanup)
8397 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
8398 (load_partial_dies): Update.
8399
5e2db402
TT
84002018-01-17 Tom Tromey <tom@tromey.com>
8401
8402 * dwarf2read.c (dwarf2_compute_name): Update comment.
8403 (read_func_scope, read_variable): Update.
8404 (new_symbol): Remove.
8405 (new_symbol_full): Rename to new_symbol.
8406
ee7f689e 84072018-01-17 Mike Gulick <mgulick@mathworks.com>
41667530
MG
8408
8409 PR gdb/16577
8410 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
8411 a warning instead of throwing an error, set section size to 0 and return
8412 NULL.
8413 * gdb_bfd.h (gdb_bfd_map_section): Update description.
8414
4d9b86e1
SM
84152018-01-17 Simon Marchi <simon.marchi@ericsson.com>
8416
8417 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
8418 std::string.
8419 (linux_ptrace_attach_fail_reason_string): Likewise.
8420 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
8421 Likewise.
8422 (linux_ptrace_attach_fail_reason_string): Likewise.
8423 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
8424
a7b2d0fb
SM
84252018-01-17 Simon Marchi <simon.marchi@ericsson.com>
8426
8427 * linux-nat.c (linux_nat_attach): Remove xstrdup.
8428
f517c180
EA
84292018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
8430
8431 PR gdb/21559
8432 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
8433 checking for fs_base/gs_base fields in struct user_regs_struct.
8434 * configure: Regenerate.
8435
7045b1ca
YQ
84362018-01-17 Yao Qi <yao.qi@linaro.org>
8437
8438 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
8439 function.
8440 (aarch64_linux_init_abi): Install it to gdbarch hook
8441 gcc_target_options.
8442
db422fb2
PA
84432018-01-15 Pedro Alves <palves@redhat.com>
8444
8445 * common/signals-state-save-restore.c
8446 (save_original_signals_state): Fix typos.
8447
ba643918
SDJ
84482017-01-12 Tom Tromey <tom@tromey.com>
8449 Sergio Durigan Junior <sergiodj@redhat.com>
8450
8451 * Makefile.in (install-only): Install gdb-add-index.
8452
906b4aac
JB
84532018-01-12 John Baldwin <jhb@FreeBSD.org>
8454
8455 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
8456
bdf2a94a
AA
84572018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
8458
8459 * infrun.c (keep_going_pass_signal): Clear step-over info when
8460 insert_breakpoints fails.
8461
71d378ae
PA
84622018-01-11 Pedro Alves <palves@redhat.com>
8463
8464 PR gdb/22583
8465 * infrun.c (resume): Rename to ...
8466 (resume_1): ... this.
8467 (resume): Reimplement as wrapper around resume_1.
8468
3cada740
PA
84692018-01-11 Pedro Alves <palves@redhat.com>
8470
8471 PR remote/22597
8472 * remote.c (remote_parse_stop_reply): Default to the last-set
8473 general thread instead of to 'magic_null_ptid'.
8474
618daa93
PA
84752018-01-10 Pedro Alves <palves@redhat.com>
8476
8477 * language.h (language_get_symbol_name_matcher): Rename ...
8478 (get_symbol_name_matcher): ... this.
8479 * language.c (language_get_symbol_name_matcher): Ditto.
8480 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
8481 callers adjusted.
8482
c63d3e8d
PA
84832018-01-10 Pedro Alves <palves@redhat.com>
8484
8485 PR gdb/22670
8486 * dwarf2read.c
8487 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
8488 Adjust to use language_get_symbol_name_matcher instead of
8489 language_defn::la_get_symbol_name_matcher.
8490 * language.c (language_get_symbol_name_matcher): If in Ada mode
8491 and the lookup name is a verbatim match, return Ada's matcher.
8492 * language.h (language_get_symbol_name_matcher): Adjust comment.
8493 (ada_lookup_name_info::verbatim_p):: New method.
8494
d4c2a405
PA
84952018-01-10 Pedro Alves <palves@redhat.com>
8496
8497 PR gdb/22670
8498 * ada-lang.c (ada_collect_symbol_completion_matches): If the
8499 minsym's language is language_auto or language_cplus, pass down
8500 language_ada instead.
8501 * symtab.c (compare_symbol_name): Don't frob symbol language here.
8502
8825213e
PA
85032018-01-10 Pedro Alves <palves@redhat.com>
8504
8505 PR gdb/22670
8506 * minsyms.c (linkage_name_str): New function.
8507 (iterate_over_minimal_symbols): Use it.
8508
2d97a5d9
JB
85092018-01-09 John Baldwin <jhb@FreeBSD.org>
8510
8511 * NEWS: Document that 'info proc' now works on FreeBSD.
8512
92fce24d
JB
85132018-01-09 John Baldwin <jhb@FreeBSD.org>
8514
8515 * configure.ac: Check for kinfo_getfile in libutil.
8516 * configure: Regenerate.
8517 * config.in: Regenerate.
8518 * fbsd-nat.c: Include "fbsd-tdep.h".
8519 (fbsd_fetch_cmdline): New.
8520 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
8521 rather than calling error.
8522 (fbsd_info_proc): New.
8523 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
8524 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
8525 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
8526
262f62f5
JB
85272018-01-09 John Baldwin <jhb@FreeBSD.org>
8528
8529 * fbsd-nat.c (struct free_deleter): Remove.
8530 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
8531
b999e203
JB
85322018-01-09 John Baldwin <jhb@FreeBSD.org>
8533
8534 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
8535 NULL for an empty pathname.
8536
d2176225
JB
85372018-01-09 John Baldwin <jhb@FreeBSD.org>
8538
8539 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
8540 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
8541 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
8542 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
8543 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
8544 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
8545 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
8546 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
8547 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
8548 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
8549 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
8550 (fbsd_core_fetch_timeval, fbsd_print_sigset)
8551 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
8552 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
8553 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
8554
9c4ac400
ST
85552018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
8556
8557 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
8558 (gnu_xfer_auxv): New function.
8559 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
8560 TARGET_OBJECT_AUXV.
8561
1e5ded6c
YQ
85622018-01-08 Yao Qi <yao.qi@linaro.org>
8563 Simon Marchi <simon.marchi@ericsson.com>
8564
8565 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
8566 common/selftest.c.
8567 (COMMON_OBS): Remove selftest.o.
8568 * configure.ac: Append selftest-arch.c and common/selftest.c to
8569 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
8570 * configure: Re-generated.
8571 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
8572 GDB_SELF_TEST.
8573 (maintenance_info_selftests): Likewise.
8574
04bafb1e
XR
85752018-01-08 Xavier Roirand <roirand@adacore.com>
8576
8577 * ada-valprint.c (val_print_packed_array_elements): Use
8578 proper number of elements when printing an array indexed
8579 by an enumeration type.
8580
518817b3
SM
85812018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
8582
8583 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
8584 (dw2_get_file_names_reader): Adjust.
8585 (lookup_dwo_signatured_type): Adjust.
8586 (lookup_dwp_signatured_type): Adjust.
8587 (lookup_signatured_type): Adjust.
8588 (create_type_unit_group): Adjust.
8589 (get_type_unit_group): Adjust.
8590 (process_psymtab_comp_unit_reader): Adjust.
8591 (build_type_psymtabs_reader): Adjust.
8592 (scan_partial_symbols): Adjust.
8593 (add_partial_symbol): Adjust.
8594 (add_partial_subprogram): Adjust.
8595 (peek_die_abbrev): Adjust.
8596 (fixup_go_packaging): Adjust.
8597 (process_imported_unit_die): Adjust.
8598 (dwarf2_compute_name): Adjust.
8599 (dwarf2_physname): Adjust.
8600 (read_import_statement): Adjust.
8601 (handle_DW_AT_stmt_list): Adjust.
8602 (read_file_scope): Adjust.
8603 (read_func_scope): Adjust.
8604 (read_lexical_block_scope): Adjust.
8605 (read_call_site_scope): Adjust.
8606 (read_variable): Adjust.
8607 (dwarf2_rnglists_process): Adjust.
8608 (dwarf2_ranges_process): Adjust.
8609 (dwarf2_ranges_read): Adjust.
8610 (dwarf2_get_pc_bounds): Adjust.
8611 (dwarf2_record_block_ranges): Adjust.
8612 (dwarf2_add_field): Adjust.
8613 (dwarf2_add_member_fn): Adjust.
8614 (read_structure_type): Adjust.
8615 (process_structure_scope): Adjust.
8616 (read_enumeration_type): Adjust.
8617 (read_array_type): Adjust.
8618 (mark_common_block_symbol_computed): Adjust.
8619 (read_common_block): Adjust.
8620 (read_namespace_type): Adjust.
8621 (read_namespace): Adjust.
8622 (read_module_type): Adjust.
8623 (read_tag_pointer_type): Adjust.
8624 (read_tag_ptr_to_member_type): Adjust.
8625 (read_tag_string_type): Adjust.
8626 (read_subroutine_type): Adjust.
8627 (read_typedef): Adjust.
8628 (read_base_type): Adjust.
8629 (attr_to_dynamic_prop): Adjust.
8630 (read_subrange_type): Adjust.
8631 (read_unspecified_type): Adjust.
8632 (dwarf2_read_abbrevs): Adjust.
8633 (load_partial_dies): Adjust.
8634 (read_partial_die): Adjust.
8635 (find_partial_die): Adjust.
8636 (guess_partial_die_structure_name): Adjust.
8637 (fixup_partial_die): Adjust.
8638 (read_attribute_value): Adjust.
8639 (read_addr_index): Adjust.
8640 (read_addr_index_from_leb128): Adjust.
8641 (read_str_index): Adjust.
8642 (dwarf2_string_attr): Adjust.
8643 (get_debug_line_section): Adjust.
8644 (dwarf_decode_line_header): Adjust.
8645 (lnp_state_machine::check_line_address): Adjust.
8646 (dwarf_decode_lines_1): Adjust.
8647 (dwarf_decode_lines): Adjust.
8648 (dwarf2_start_symtab): Adjust.
8649 (var_decode_location): Adjust.
8650 (new_symbol_full): Adjust.
8651 (dwarf2_const_value_data): Adjust.
8652 (dwarf2_const_value_attr): Adjust.
8653 (dwarf2_const_value): Adjust.
8654 (die_type): Adjust.
8655 (die_containing_type): Adjust.
8656 (build_error_marker_type): Adjust.
8657 (lookup_die_type): Adjust.
8658 (guess_full_die_structure_name): Adjust.
8659 (anonymous_struct_prefix): Adjust.
8660 (determine_prefix): Adjust.
8661 (dwarf2_name): Adjust.
8662 (follow_die_ref_or_sig): Adjust.
8663 (follow_die_offset): Adjust.
8664 (follow_die_ref): Adjust.
8665 (follow_die_sig_1): Adjust.
8666 (follow_die_sig): Adjust.
8667 (get_signatured_type): Adjust.
8668 (get_DW_AT_signature_type): Adjust.
8669 (decode_locdesc): Adjust.
8670 (dwarf_decode_macros): Adjust.
8671 (cu_debug_loc_section): Adjust.
8672 (fill_in_loclist_baton): Adjust.
8673 (dwarf2_symbol_mark_computed): Adjust.
8674 (init_one_comp_unit): Don't assign
8675 dwarf2_cu::dwarf2_per_objfile.
8676 (set_die_type): Adjust.
8677
ed2dc618
SM
86782018-01-07 Simon Marchi <simon.marchi@ericsson.com>
8679
8680 * dwarf2read.c (struct mapped_debug_names): Add constructor.
8681 <dwarf2_per_objfile>: New field.
8682 (dwarf2_per_objfile): Remove global.
8683 (get_dwarf2_per_objfile): New function.
8684 (set_dwarf2_per_objfile): New function.
8685 (dwarf2_build_psymtabs_hard): Change objfile parameter to
8686 dwarf2_per_objfile.
8687 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
8688 (read_abbrev_offset): Likewise.
8689 (read_indirect_string): Likewise.
8690 (read_indirect_line_string): Likewise.
8691 (read_indirect_string_at_offset): Likewise.
8692 (read_indirect_string_from_dwz): Likewise.
8693 (dwarf2_find_containing_comp_unit): Change objfile parameter to
8694 dwarf2_per_objfile.
8695 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
8696 (create_all_comp_units): Change objfile parameter to
8697 dwarf2_per_objfile.
8698 (create_all_type_units): Likewise.
8699 (process_queue): Add dwarf2_per_objfile parameter.
8700 (read_and_check_comp_unit_head): Likewise.
8701 (lookup_dwo_unit_in_dwp): Likewise.
8702 (get_dwp_file): Likewise.
8703 (process_cu_includes): Likewise.
8704 (struct free_dwo_file_cleanup_data): New struct.
8705 (dwarf2_has_info): Use get_dwarf2_per_objfile and
8706 set_dwarf2_per_objfile.
8707 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
8708 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
8709 context, adjust calls.
8710 (dw2_instantiate_symtab): Likewise.
8711 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
8712 (dw2_get_cu): Likewise.
8713 (create_cu_from_index_list): Change objfile parameter to
8714 dwarf2_per_objfile.
8715 (create_cus_from_index_list): Get dwarf2_per_objfile from
8716 context, adjust calls.
8717 (create_cus_from_index): Likewise.
8718 (create_signatured_type_table_from_index): Change objfile
8719 parameter to dwarf2_per_objfile.
8720 (create_signatured_type_table_from_debug_names): Change objfile
8721 parameter to dwarf2_per_objfile.
8722 (create_addrmap_from_index): Likewise.
8723 (create_addrmap_from_aranges): Likewise.
8724 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
8725 (dw2_setup): Remove.
8726 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
8727 context.
8728 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
8729 get_dwarf2_per_objfile.
8730 (dw2_forget_cached_source_info): Likewise.
8731 (dw2_map_symtabs_matching_filename): Likewise.
8732 (struct dw2_symtab_iterator) <index>: Remove.
8733 <dwarf2_per_objfile>: New field.
8734 (dw2_symtab_iter_init): Replace index parameter with
8735 dwarf2_per_objfile.
8736 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
8737 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
8738 (dw2_print_stats): Likewise.
8739 (dw2_dump): Likewise.
8740 (dw2_expand_symtabs_for_function): Likewise.
8741 (dw2_expand_all_symtabs): Likewise.
8742 (dw2_expand_symtabs_with_fullname): Likewise.
8743 (dw2_expand_marked_cus): Replace index and objfile parameters
8744 with dwarf2_per_objfile.
8745 (dw_expand_symtabs_matching_file_matcher): Add
8746 dwarf2_per_objfile parameter and adjust calls.
8747 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
8748 adjust calls.
8749 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
8750 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
8751 adjust calls.
8752 (create_cus_from_debug_names_list): Replace objfile parameter
8753 with dwarf2_per_objfile and adjust calls.
8754 (create_cus_from_debug_names): Likewise.
8755 (dwarf2_read_debug_names): Likewise.
8756 (mapped_debug_names::namei_to_name): Adjust call.
8757 (dw2_debug_names_iterator::next): Likewise.
8758 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
8759 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
8760 (dw2_debug_names_dump): Likewise.
8761 (dw2_debug_names_expand_symtabs_for_function): Likewise.
8762 (dw2_debug_names_expand_symtabs_matching): Likewise.
8763 (dwarf2_initialize_objfile): Likewise.
8764 (dwarf2_build_psymtabs): Likewise.
8765 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
8766 this_cu.
8767 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
8768 (read_and_check_comp_unit_head): Likewise.
8769 (read_abbrev_offset): Likewise.
8770 (create_debug_type_hash_table): Likewise.
8771 (create_debug_types_hash_table): Likewise.
8772 (create_all_type_units): Replace objfile parameter with
8773 dwarf2_per_objfile.
8774 (add_type_unit): Add dwarf2_per_objfile parameter.
8775 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
8776 with dwarf2_per_objfile.
8777 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
8778 (lookup_dwp_signatured_type): Likewise.
8779 (lookup_signatured_type): Likewise.
8780 (read_cutu_die_from_dwo): Likewise.
8781 (init_tu_and_read_dwo_dies): Likewise.
8782 (init_cutu_and_read_dies): Likewise.
8783 (init_cutu_and_read_dies_no_follow): Likewise.
8784 (allocate_type_unit_groups_table): Add objfile parameter.
8785 (create_type_unit_group): Use dwarf2_per_objfile from cu.
8786 (get_type_unit_group): Likewise.
8787 (process_psymtab_comp_unit): Update call.
8788 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
8789 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
8790 (print_tu_stats): Likewise.
8791 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
8792 in void* parameter.
8793 (build_type_psymtabs): Change objfile parameter to
8794 dwarf2_per_objfile.
8795 (process_skeletonless_type_unit): Use dwarf2_per_objfile
8796 passed in void* parameter.
8797 (process_skeletonless_type_units): Change objfile parameter to
8798 dwarf2_per_objfile.
8799 (set_partial_user): Likewise.
8800 (dwarf2_build_psymtabs_hard): Likewise.
8801 (read_comp_units_from_section): Likewise.
8802 (create_all_comp_units): Likewise.
8803 (scan_partial_symbols): Update calls.
8804 (add_partial_symbol): Likewise.
8805 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
8806 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
8807 (process_queue): Add dwarf2_per_objfile parameter.
8808 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
8809 (compute_compunit_symtab_includes): Likewise.
8810 (process_cu_includes): Add dwarf2_per_objfile parameter.
8811 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
8812 (process_full_type_unit): Likewise.
8813 (process_imported_unit_die): Update call.
8814 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
8815 (read_file_scope): Likewise.
8816 (allocate_dwo_file_hash_table): Add objfile parameter.
8817 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
8818 (create_cus_hash_table): Likewise.
8819 (create_dwp_hash_table): Likewise.
8820 (create_dwo_unit_in_dwp_v1): Likewise.
8821 (create_dwp_v2_section): Likewise.
8822 (create_dwo_unit_in_dwp_v2): Likewise.
8823 (lookup_dwo_unit_in_dwp): Likewise.
8824 (try_open_dwop_file): Likewise.
8825 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
8826 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
8827 cleanup to include a reference to dwarf2_per_objfile.
8828 (open_dwp_file): Add dwarf2_per_objfile parameter.
8829 (open_and_init_dwp_file): Likewise.
8830 (get_dwp_file): Likewise.
8831 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
8832 (queue_and_load_all_dwo_tus): Update call.
8833 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
8834 data.
8835 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
8836 (dwarf2_ranges_process): Likewise.
8837 (dwarf2_get_pc_bounds): Likewise.
8838 (mark_common_block_symbol_computed): Likewise.
8839 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
8840 (dwarf2_read_abbrevs): Update call.
8841 (read_partial_die): Use dwarf2_per_objfile from cu.
8842 (find_partial_die): Likewise.
8843 (fixup_partial_die): Likewise.
8844 (read_attribute_value): Likewise.
8845 (read_indirect_string_at_offset_from): Add objfile parameter.
8846 (read_indirect_string_at_offset): Add dwarf2_per_objfile
8847 parameter.
8848 (read_indirect_string_from_dwz): Add objfile parameter.
8849 (read_indirect_string): Add objfile parameter.
8850 (read_addr_index_1): Add dwarf2_per_objfile parameter.
8851 (read_addr_index): Use dwarf2_per_objfile from cu.
8852 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
8853 call dw2_setup.
8854 (read_str_index): Use dwarf2_per_objfile from cu.
8855 (get_debug_line_section): Likewise.
8856 (read_formatted_entries): Add dwarf2_per_objfile parameter.
8857 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
8858 (new_symbol_full): Use dwarf2_per_objfile from cu.
8859 (build_error_marker_type): Likewise.
8860 (lookup_die_type): Likewise.
8861 (determine_prefix): Likewise.
8862 (follow_die_offset): Likewise.
8863 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
8864 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
8865 (dwarf2_fetch_die_type_sect_off): Likewise.
8866 (dwarf2_get_die_type): Likewise.
8867 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
8868 (get_signatured_type): Likewise.
8869 (get_DW_AT_signature_type): Likewise.
8870 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
8871 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
8872 (cu_debug_loc_section): Likewise.
8873 (fill_in_loclist_baton): Likewise.
8874 (dwarf2_symbol_mark_computed): Likewise.
8875 (dwarf2_find_containing_comp_unit): Change objfile parameter to
8876 dwarf2_per_objfile.
8877 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
8878 parameter.
8879 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
8880 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
8881 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
8882 (set_die_type): Use dwarf2_free_objfile from cu.
8883 (get_die_type_at_offset): Likewise.
8884 (dwarf2_per_objfile_free): Don't assign global variable.
8885 (debug_names) <constructor>: Add dwarf2_per_objfile
8886 parameter, update m_debugstrlookup construction.
8887 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
8888 parameter.
8889 <m_dwarf2_per_objfile>: New field.
8890 <lookup>: Use m_dwarf2_per_objfile.
8891 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
8892 (psyms_seen_size): Likewise.
8893 (write_gdbindex): Replace objfile parameter with
8894 dwarf2_per_objfile.
8895 (write_debug_names): Likewise.
8896 (write_psymtabs_to_index): Likewise.
8897 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
8898 calls.
8899
e3b94546
SM
89002018-01-07 Simon Marchi <simon.marchi@ericsson.com>
8901
8902 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
8903 <dwarf2_per_objfile>: New field.
8904 (struct dwarf2_per_cu_data) <objfile>: Remove.
8905 <dwarf2_per_objfile>: New field.
8906 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
8907 of objfile.
8908 (create_signatured_type_table_from_index): Likewise.
8909 (create_debug_type_hash_table): Likewise.
8910 (fill_in_sig_entry_from_dwo_entry): Likewise.
8911 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
8912 (create_type_unit_group): Assign dwarf2_per_objfile instead of
8913 objfile.
8914 (create_partial_symtab): Access objfile through
8915 dwarf2_per_objfile.
8916 (process_psymtab_comp_unit_reader): Likewise.
8917 (read_comp_units_from_section): Likewise.
8918 (scan_partial_symbols): Likewise.
8919 (add_partial_symbol): Likewise.
8920 (add_partial_subprogram): Likewise.
8921 (peek_die_abbrev): Likewise.
8922 (fixup_go_packaging): Likewise.
8923 (process_full_comp_unit): Likewise.
8924 (process_full_type_unit): Likewise.
8925 (process_imported_unit_die): Likewise.
8926 (dwarf2_compute_name): Likewise.
8927 (dwarf2_physname): Likewise.
8928 (read_import_statement): Likewise.
8929 (create_cus_hash_table): Assign dwarf2_physname instead of
8930 objfile.
8931 (read_func_scope): Access objfile through dwarf2_per_objfile.
8932 (read_lexical_block_scope): Likewise.
8933 (read_call_site_scope): Likewise.
8934 (read_variable): Likewise.
8935 (dwarf2_rnglists_process): Likewise.
8936 (dwarf2_ranges_process): Likewise.
8937 (dwarf2_ranges_read): Likewise.
8938 (dwarf2_record_block_ranges): Likewise.
8939 (dwarf2_add_field): Likewise.
8940 (dwarf2_add_member_fn): Likewise.
8941 (read_structure_type): Likewise.
8942 (process_structure_scope): Likewise.
8943 (read_enumeration_type): Likewise.
8944 (read_array_type): Likewise.
8945 (read_common_block): Likewise.
8946 (read_namespace_type): Likewise.
8947 (read_namespace): Likewise.
8948 (read_module_type): Likewise.
8949 (read_tag_pointer_type): Likewise.
8950 (read_tag_ptr_to_member_type): Likewise.
8951 (read_tag_string_type): Likewise.
8952 (read_subroutine_type): Likewise.
8953 (read_typedef): Likewise.
8954 (read_base_type): Likewise.
8955 (attr_to_dynamic_prop): Likewise.
8956 (read_subrange_type): Likewise.
8957 (read_unspecified_type): Likewise.
8958 (load_partial_dies): Likewise.
8959 (read_partial_die): Likewise.
8960 (find_partial_die): Likewise.
8961 (guess_partial_die_structure_name): Likewise.
8962 (fixup_partial_die): Likewise.
8963 (read_attribute_value): Likewise.
8964 (read_addr_index_from_leb128): Likewise.
8965 (dwarf2_read_addr_index): Likewise.
8966 (dwarf2_string_attr): Likewise.
8967 (lnp_state_machine::check_line_address): Likewise.
8968 (dwarf_decode_lines_1): Likewise.
8969 (dwarf_decode_lines): Likewise.
8970 (dwarf2_start_symtab): Likewise.
8971 (var_decode_location): Likewise.
8972 (new_symbol_full): Likewise.
8973 (dwarf2_const_value_data): Likewise.
8974 (dwarf2_const_value_attr): Likewise.
8975 (dwarf2_const_value): Likewise.
8976 (die_type): Likewise.
8977 (die_containing_type): Likewise.
8978 (lookup_die_type): Likewise.
8979 (guess_full_die_structure_name): Likewise.
8980 (anonymous_struct_prefix): Likewise.
8981 (dwarf2_name): Likewise.
8982 (follow_die_ref_or_sig): Likewise.
8983 (follow_die_offset): Likewise.
8984 (follow_die_ref): Likewise.
8985 (dwarf2_fetch_die_loc_sect_off): Likewise.
8986 (dwarf2_fetch_constant_bytes): Likewise.
8987 (dwarf2_fetch_die_type_sect_off): Likewise.
8988 (dwarf2_get_die_type): Likewise.
8989 (follow_die_sig): Likewise.
8990 (decode_locdesc): Likewise.
8991 (dwarf2_per_cu_objfile): Likewise.
8992 (dwarf2_per_cu_text_offset): Likewise.
8993 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
8994 objfile.
8995 (set_die_type): Access objfile through
8996 dwarf2_per_objfile.
8997
b01ba14d
SM
89982018-01-07 Simon Marchi <simon.marchi@ericsson.com>
8999
9000 * valprint.c (converted_character_d): Remove typedef.
9001 (DEF_VEC_O (converted_character_d)): Remove.
9002 (count_next_character): Use std::vector.
9003 (print_converted_chars_to_obstack): Likewise.
9004 (generic_printstr): Likewise.
9005
4d0fdd9b
SM
90062018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
9007
9008 * xml-support.h (struct gdb_xml_value): Add constructor.
9009 <value>: Change type to unique_xmalloc_ptr.
9010 (gdb_xml_value_s): Remove typedef.
9011 (DEF_VEC_O (gdb_xml_value_s)): Remove.
9012 (gdb_xml_element_start_handler): Change parameter type to
9013 std::vector.
9014 (xml_find_attribute): Likewise.
9015 * xml-support.c (xml_find_attribute): Change parameter type to
9016 std::vector and adjust.
9017 (gdb_xml_values_cleanup): Remove.
9018 (gdb_xml_parser::start_element): Adjust to std::vector.
9019 (xinclude_start_include): Change paraeter type to std::vector
9020 and adjust.
9021 * btrace.c (check_xml_btrace_version): Likewise.
9022 (parse_xml_btrace_block): Likewise.
9023 (parse_xml_btrace_pt_config_cpu): Likewise.
9024 (parse_xml_btrace_pt): Likewise.
9025 (parse_xml_btrace_conf_bts): Likewise.
9026 (parse_xml_btrace_conf_pt): Likewise.
9027 * memory-map.c (memory_map_start_memory): Likewise.
9028 (memory_map_start_property): Likewise.
9029 * osdata.c (osdata_start_osdata): Likewise.
9030 (osdata_start_item): Likewise.
9031 (osdata_start_column): Likewise.
9032 * remote.c (start_thread): Likewise.
9033 * solib-aix.c (library_list_start_library): Likewise.
9034 (library_list_start_list): Likewise.
9035 * solib-svr4.c (library_list_start_library): Likewise.
9036 (svr4_library_list_start_list): Likewise.
9037 * solib-target.c (library_list_start_segment): Likewise.
9038 (library_list_start_section): Likewise.
9039 (library_list_start_library): Likewise.
9040 (library_list_start_list): Likewise.
9041 * tracepoint.c (traceframe_info_start_memory): Likewise.
9042 (traceframe_info_start_tvar): Likewise.
9043 * xml-syscall.c (syscall_start_syscall): Likewise.
9044 * xml-tdesc.c (tdesc_start_target): Likewise.
9045 (tdesc_start_feature): Likewise.
9046 (tdesc_start_reg): Likewise.
9047 (tdesc_start_union): Likewise.
9048 (tdesc_start_struct): Likewise.
9049 (tdesc_start_flags): Likewise.
9050 (tdesc_start_enum): Likewise.
9051 (tdesc_start_field): Likewise.
9052 (tdesc_start_enum_value): Likewise.
9053 (tdesc_start_vector): Likewise.
9054
f979c73f
SM
90552018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
9056
9057 * extension.h (struct xmethod_worker) <clone>: Remove.
9058 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
9059 Remove.
9060 (python_xmethod_worker::clone): Remove.
9061 * valops.c (find_overload_match): Use std::move instead of
9062 clone.
9063
ba18742c
SM
90642018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
9065
9066 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
9067 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
9068 <free_xmethod_worker_data>: Remove.
9069 <get_matching_xmethod_workers>: Chance VEC to std::vector.
9070 <get_xmethod_arg_types>: Remove.
9071 <get_xmethod_result_type>: Remove.
9072 <invoke_xmethod>: Remove.
9073 * extension.c (new_xmethod_worker): Remove.
9074 (clone_xmethod_worker): Remove.
9075 (get_matching_xmethod_workers): Return void, pass std::vector by
9076 pointer.
9077 (get_xmethod_arg_types): Rename to...
9078 (xmethod_worker::get_arg_types): ... this, and adjust.
9079 (get_xmethod_result_type): Rename to...
9080 (xmethod_worker::get_result_type): ... this, and adjust.
9081 (invoke_xmethod): Remove.
9082 (free_xmethod_worker): Remove.
9083 (free_xmethod_worker_vec): Remove.
9084 * extension.h (enum ext_lang_rc): Move here from
9085 extension-priv.h.
9086 (struct xmethod_worker): Add constructor and destructor.
9087 <data>: Remove.
9088 <value>: Remove.
9089 <invoke, clone, do_get_result_type, do_get_arg_types>: New
9090 virtual pure methods.
9091 <get_arg_types, get_result_type>: New methods.
9092 (xmethod_worker_ptr): Remove typedef.
9093 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
9094 (xmethod_worker_vec): Remove typedef.
9095 (xmethod_worker_up): New typedef.
9096 (invoke_xmethod): Remove.
9097 (clone_xmethod_worker): Remove.
9098 (free_xmethod_worker): Remove.
9099 (free_xmethod_worker_vec): Remove.
9100 (get_xmethod_arg_types): Remove.
9101 (get_xmethod_result_type): Remove.
9102 * valops.c (find_method_list): Use std::vector, don't use
9103 intermediate vector.
9104 (value_find_oload_method_list): Use std::vector.
9105 (find_overload_match): Use std::vector.
9106 (find_oload_champ): Use std::vector.
9107 * value.c (value_free): Use operator delete.
9108 (value_of_xmethod): Rename to...
9109 (value_from_xmethod): ... this. Don't assign
9110 xmethod_worker::value, take rvalue-reference.
9111 (result_type_of_xmethod): Adjust.
9112 (call_xmethod): Adjust.
9113 * value.h: Include extension.h.
9114 (struct xmethod_worker): Don't forward-declare.
9115 (value_of_xmethod): Rename to...
9116 (value_from_xmethod): ... this, take rvalue-reference.
9117 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
9118 (struct python_xmethod_worker): ... this, add constructor and
9119 destructor.
9120 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
9121 (gdbpy_free_xmethod_worker_data): Rename to...
9122 (python_xmethod_worker::~python_xmethod_worker): ... this and
9123 adjust.
9124 (gdbpy_clone_xmethod_worker_data): Rename to...
9125 (python_xmethod_worker::clone): ... this and adjust.
9126 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
9127 temporary vector.
9128 (gdbpy_get_xmethod_arg_types): Rename to...
9129 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
9130 (gdbpy_get_xmethod_result_type): Rename to...
9131 (python_xmethod_worker::do_get_result_type): ... this and
9132 adjust.
9133 (gdbpy_invoke_xmethod): Rename to...
9134 (python_xmethod_worker::invoke): ... this and adjust.
9135 (new_python_xmethod_worker): Rename to...
9136 (python_xmethod_worker::python_xmethod_worker): ... this and
9137 adjust.
9138 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
9139 Remove.
9140 (gdbpy_free_xmethod_worker_data): Remove.
9141 (gdbpy_get_matching_xmethod_workers): Use std::vector.
9142 (gdbpy_get_xmethod_arg_types): Remove.
9143 (gdbpy_get_xmethod_result_type): Remove.
9144 (gdbpy_invoke_xmethod): Remove.
9145 * python/python.c (python_extension_ops): Remove obsolete
9146 callbacks.
9147
e379cee6
PA
91482018-01-05 Pedro Alves <palves@redhat.com>
9149
9150 PR gdb/18653
9151 * common/signals-state-save-restore.c
9152 (save_original_signals_state): New parameter 'quiet'. Warn if we
9153 find a custom handler preinstalled, instead of internal erroring.
9154 But only warn if !quiet.
9155 * common/signals-state-save-restore.h
9156 (save_original_signals_state): New parameter 'quiet'.
9157 * main.c (captured_main_1): Move save_original_signals_state call
9158 after option handling, and pass QUIET.
9159
a655456c
PA
91602018-01-05 Pedro Alves <palves@redhat.com>
9161
9162 * spu-tdep.c (spu_catch_start): Pass
9163 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
9164
de63c46b
PA
91652018-01-05 Pedro Alves <palves@redhat.com>
9166
9167 PR gdb/22670
9168 * ada-lang.c (literal_symbol_name_matcher): New function.
9169 (ada_get_symbol_name_matcher): Use it for
9170 symbol_name_match_type::SEARCH_NAME.
9171 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
9172 it down instead of assuming symbol_name_match_type::FULL.
9173 * block.h (block_lookup_symbol): New parameter 'match_type'.
9174 * c-valprint.c (print_unpacked_pointer): Use
9175 lookup_symbol_search_name instead of lookup_symbol.
9176 * compile/compile-object-load.c (get_out_value_type): Pass down
9177 symbol_name_match_type::SEARCH_NAME.
9178 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
9179 symbol_name_match_type::FULL.
9180 * cp-support.c (cp_get_symbol_name_matcher): Handle
9181 symbol_name_match_type::SEARCH_NAME.
9182 * infrun.c (insert_exception_resume_breakpoint): Use
9183 lookup_symbol_search_name.
9184 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
9185 * psymtab.c (maintenance_check_psymtabs): Use
9186 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
9187 * stack.c (print_frame_args): Use lookup_symbol_search_name and
9188 SYMBOL_SEARCH_NAME.
9189 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
9190 if symbol_name_match_type::SEARCH_NAME.
9191 (lookup_symbol_in_language): Pass down
9192 symbol_name_match_type::FULL.
9193 (lookup_symbol_search_name): New.
9194 (lookup_language_this): Pass down
9195 symbol_name_match_type::SEARCH_NAME.
9196 (lookup_symbol_aux, lookup_local_symbol): New parameter
9197 'match_type'. Pass it down.
9198 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
9199 (lookup_symbol_search_name): New declaration.
9200 (lookup_symbol_in_block): New 'match_type' parameter.
9201
f98fc17b
PA
92022018-01-05 Pedro Alves <palves@redhat.com>
9203
9204 PR gdb/22670
9205 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
9206 ada_lookup_symbol.
9207 (ada_lookup_symbol): Reimplement in terms of
9208 ada_lookup_symbol_list, bits factored out from
9209 ada_lookup_encoded_symbol.
9210
342f8240
JB
92112018-01-05 Joel Brobecker <brobecker@adacore.com>
9212
9213 * ada-exp.y (write_object_renaming): When subscripting an array
9214 using a symbol as the index, pass the block in call to
9215 ada_lookup_encoded_symbol when looking that symbol up.
9216
7150d33c
JG
92172018-01-05 Jerome Guitton <guitton@adacore.com>
9218
9219 * ada-lang.c (ada_array_length): Use ada_index_type instead of
9220 TYPE_INDEX_TYPE.
9221
cc0e770c
JB
92222018-01-05 Joel Brobecker <brobecker@adacore.com>
9223
9224 * ada-lang.c (ada_to_fixed_value_create): Add handling of
9225 the case where VALUE_LVAL (val0) is not lval_memory.
9226
f79da888 92272018-01-05 Xavier Roirand <roirand@adacore.com>
e3861a03
XR
9228
9229 * ada-valprint.c (print_optional_low_bound): Handle
9230 character-indexed array printing like boolean-indexed array
9231 printing.
9232
cd385f94
JB
92332018-01-05 Joel Brobecker <brobecker@adacore.com>
9234
9235 * NEWS: Create a new section for the next release branch.
9236 Rename the section of the current branch, now that it has
9237 been cut.
9238
09aca949
JB
92392018-01-05 Joel Brobecker <brobecker@adacore.com>
9240
9241 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
9242 * version.in: Bump version to 8.1.50.DATE-git.
9243
9f757bf7
XR
92442018-01-03 Xavier Roirand <roirand@adacore.com>
9245
9246 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
9247 Add field.
9248 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
9249 Add field.
9250 (default_exception_support_info) <catch_handlers_sym>: Add field.
9251 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
9252 (ada_exception_name_addr_1): Add "catch handlers" handling.
9253 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
9254 Update all callers.
9255 (create_excep_cond_exprs) <ex>: Add parameter.
9256 (re_set_exception): Update create_excep_cond_exprs call.
9257 (print_it_exception, print_one_exception, print_mention_exception)
9258 (print_recreate_exception): Add "catch handler" handling.
9259 (allocate_location_catch_handlers, re_set_catch_handlers)
9260 (check_status_catch_handlers, print_it_catch_handlers)
9261 (print_one_catch_handlers, print_mention_catch_handlers)
9262 (print_recreate_catch_handlers): New function.
9263 (catch_handlers_breakpoint_ops): New variable.
9264 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
9265 Add parameter. Add "catch handler" handling.
9266 (ada_exception_sym_name, ada_exception_breakpoint_ops):
9267 Add "catch handler" handling.
9268 (ada_exception_catchpoint_cond_string): Add "catch handler"
9269 handling.
9270 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
9271 call.
9272 (catch_ada_handlers_command): New function.
9273 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
9274 operations structure.
9275 (_initialize_ada_language): Add "catch handlers" command entry.
9276 * NEWS: Document "catch handlers" feature.
9277
9fe561ab
JB
92782018-01-02 Joel Brobecker <brobecker@adacore.com>
9279
9280 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
9281 account when creating the array type of the slice.
9282 (ada_value_slice): Likewise.
9283
a405673c
JB
92842018-01-02 Joel Brobecker <brobecker@adacore.com>
9285
9286 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
9287 New enum value.
9288 (create_array_type_with_stride): Add byte_stride_prop parameter.
9289 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
9290 New parameter. Update all callers in this file.
9291 (array_type_has_dynamic_stride): New function.
9292 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
9293 of arrays with dynamic byte strides.
9294 * dwarf2read.c (read_array_type): Add support for dynamic
9295 DW_AT_byte_stride attributes.
9296
74a2f8ff
JB
92972018-01-02 Joel Brobecker <brobecker@adacore.com>
9298
9299 * dwarf2read.c (read_unspecified_type): Treat
9300 DW_TAG_enumeration_type DIEs from Ada units as stubs.
9301
e2882c85
JB
93022018-01-01 Joel Brobecker <brobecker@adacore.com>
9303
9304 Update copyright year range in all GDB files.
9305
1690bb24
JB
93062018-01-01 Joel Brobecker <brobecker@adacore.com>
9307
9308 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
9309 and gdb/testsuite/gdb.base/step-line.c.
9310
0f0c98a8
JB
93112018-01-01 Joel Brobecker <brobecker@adacore.com>
9312
9313 * copyright.py (main): Dump the contents of
9314 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
9315 even if BY_HAND is empty.
9316
82e1e79a
JB
93172018-01-01 Joel Brobecker <brobecker@adacore.com>
9318
9319 * top.c (print_gdb_version): Update Copyright year in version
9320 message.
9321
053f54e5 93222018-01-01 Joel Brobecker <brobecker@adacore.com>
47fea877 9323
053f54e5 9324 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
47fea877 9325
053f54e5 9326For older changes see ChangeLog-2017.
c906108c
SS
9327\f
9328Local Variables:
9329mode: change-log
9330left-margin: 8
9331fill-column: 74
9332version-control: never
57da7796 9333coding: utf-8
c906108c 9334End: