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