gdb/riscv: Add read_description method for riscv_linux_nat_target
[deliverable/binutils-gdb.git] / gdb / ChangeLog
1 2018-11-30 Andrew Burgess <andrew.burgess@embecosm.com>
2
3 * riscv-linux-nat.c: Add 'inferior.h' and 'target-descriptions.h'
4 header files.
5 (riscv_linux_nat_target::read_description): New method.
6
7 2018-11-30 Andrew Burgess <andrew.burgess@embecosm.com>
8
9 * arch/riscv.h (riscv_gdbarch_features::hash): New method.
10 * arch/riscv.c (struct riscv_gdbarch_features_hasher): New.
11 (riscv_tdesc_cache): New global.
12 (riscv_create_target_description): Look in the cache before
13 creating a new target description.
14
15 2018-11-30 Andrew Burgess <andrew.burgess@embecosm.com>
16
17 * arch/riscv.h (riscv_gdb_features::operator==): New.
18 (riscv_gdb_features::operator!=): New.
19 * riscv-tdep.c (riscv_gdbarch_init): Make use of the inequality
20 operator.
21
22 2018-11-30 Andrew Burgess <andrew.burgess@embecosm.com>
23
24 * arch/riscv.h (riscv_create_target_description): Make return type
25 const.
26 * arch/riscv.c (riscv_create_target_description): Likewise.
27 * riscv-tdep.c (riscv_find_default_target_description): Likewise.
28
29 2018-11-30 Jan Kratochvil <jan.kratochvil@redhat.com>
30 Keith Seitz <keiths@redhat.com>
31 Tom Tromey <tom@tromey.com>
32 Sergio Durigan Junior <sergiodj@redhat.com>
33
34 https://bugzilla.redhat.com/show_bug.cgi?id=1613614
35 * dwarf2read.c (dwarf2_find_containing_comp_unit): Add
36 'mid_cu->length' to '*cu_off' when checking if 'sect_off' is
37 inside the CU.
38
39 2018-11-30 Pedro Alves <palves@redhat.com>
40
41 * aix-thread.c (aix_thread_target) <aix_thread_target>: Delete.
42 <stratum>: New override.
43 * bfd-target.c (aix_thread_target) <aix_thread_target>: Delete.
44 <stratum>: New override.
45 * bsd-uthread.c (bsd_uthread_target) <bsd_uthread_target>: Delete.
46 <stratum>: New override.
47 * exec.c (exec_target) <exec_target>: Delete.
48 <stratum>: New override.
49 * gdbarch-selftests.c (register_to_value_test): Adjust to use the
50 stratum method instead of the to_stratum field.
51 * linux-thread-db.c (thread_db_target) <thread_db_target>: Delete.
52 <stratum>: New override.
53 (thread_db_target::thread_db_target): Delete.
54 * make-target-delegates (print_class): Don't print a ctor
55 declaration. Print a stratum method override declaration.
56 * process-stratum-target.h (process_stratum_target)
57 <process_stratum_target>: Delete.
58 <stratum>: New override.
59 * ravenscar-thread.c (ravenscar_thread_target)
60 <ravenscar_thread_target>: Delete.
61 <stratum>: New override.
62 * record-btrace.c (record_btrace_target)
63 <record_btrace_target>: Delete.
64 <stratum>: New override.
65 * record-full.c (record_full_base_target)
66 <record_full_base_target>: Delete.
67 <stratum>: New override.
68 * record.c (record_disconnect, record_detach)
69 (record_mourn_inferior, record_kill): Adjust to use the stratum
70 method instead of the to_stratum field.
71 * regcache.c (cooked_read_test, cooked_write_test): Likewise.
72 * sol-thread.c (sol_thread_target)
73 <sol_thread_target>: Delete.
74 <stratum>: New override.
75 * spu-multiarch.c (spu_multiarch_target)
76 <spu_multiarch_target>: Delete.
77 <stratum>: New override.
78 * target-delegates.c: Regenerate.
79 * target.c (target_stack::push, target_stack::unpush)
80 (pop_all_targets_above, pop_all_targets_at_and_above)
81 (info_target_command, target_require_runnable)
82 (target_stack::find_beneath): Adjust to use the stratum method
83 instead of the to_stratum field.
84 (dummy_target::dummy_target): Delete.
85 (dummy_target::stratum): New.
86 (debug_target::debug_target): Delete.
87 (debug_target::stratum): New.
88 (maintenance_print_target_stack): Adjust to use the stratum method
89 instead of the to_stratum field.
90 * target.h (struct target_ops) <stratum>: New method.
91 <to_stratum>: Delete.
92 <is_pushed>: Adjust to use the stratum method
93 instead of the to_stratum field.
94
95 2018-11-30 Pedro Alves <palves@redhat.com>
96
97 * corelow.c (core_target) <has_all_memory, has_execution>: New
98 overrides.
99 * inf-child.c (inf_child_target::has_all_memory)
100 (inf_child_target::has_memory, inf_child_target::has_stack)
101 (inf_child_target::has_registers)
102 (inf_child_target::has_execution): Delete.
103 * inf-child.h (inf_child_target) <has_all_memory, has_memory,
104 has_stack, has_registers, has_execution>: Delete.
105 * process-stratum-target.c
106 (process_stratum_target::has_all_memory)
107 (process_stratum_target::has_memory)
108 (process_stratum_target::has_stack)
109 (process_stratum_target::has_registers)
110 (process_stratum_target::has_execution): New.
111 * process-stratum-target.h (process_stratum_target)
112 <has_all_memory, has_memory, has_stack, has_registers,
113 has_execution>: New method overrides.
114 * ravenscar-thread.c (ravenscar_thread_target) <has_all_memory,
115 has_memory, has_stack, has_registers, has_execution>: Delete.
116 * remote-sim.c (gdbsim_target) <has_stack, has_registers,
117 has_execution>: Delete.
118 * remote.c (remote_target) <has_all_memory, has_memory, has_stack,
119 has_registers, has_execution>: Delete.
120 * target.c (default_child_has_all_memory)
121 (default_child_has_memory, default_child_has_stack)
122 (default_child_has_registers, default_child_has_execution):
123 Delete.
124 * target.h (default_child_has_all_memory)
125 (default_child_has_memory, default_child_has_stack)
126 (default_child_has_registers, default_child_has_execution):
127 Delete.
128 * tracefile.h (tracefile_target) <has_execution>: New override.
129
130 2018-11-30 Pedro Alves <palves@redhat.com>
131
132 * Makefile.in (COMMON_SFILES): Add process-stratum-target.c.
133 * bsd-kvm.c: Include "process-stratum-target.h".
134 (bsd_kvm_target): Now inherits from process_stratum_target.
135 (bsd_kvm_target::bsd_kvm_target): Default it.
136 * corelow.c: Include "process-stratum-target.h".
137 (core_target): Now inherits from process_stratum_target.
138 (core_target::core_target): Don't set to_stratum here.
139 * inf-child.c (inf_child_target::inf_child_target): Delete.
140 * inf-child.h: Include "process-stratum-target.h".
141 (inf_child_target): Inherit from process_stratum_target.
142 (inf_child_target) <inf_child_target>: Default it.
143 <can_async_p, supports_non_stop, supports_disable_randomization>:
144 Delete overrides.
145 * process-stratum-target.c: New file.
146 * process-stratum-target.h: New file.
147 * remote-sim.c: Include "process-stratum-target.h".
148 (gdbsim_target): Inherit from process_stratum_target.
149 <gdbsim_target>: Default it.
150 * remote.c: Include "process-stratum-target.h".
151 (remote_target): Inherit from process_stratum_target.
152 <remote_target>: Default it.
153 * target.c (default_thread_address_space)
154 (default_thread_architecture): Delete.
155 * target.h (target_ops) <thread_architecture>: Now returns NULL by
156 default.
157 <thread_address_space>: Ditto.
158 * test-target.h: Include "process-stratum-target.h" instead of
159 "target.h".
160 (test_target_ops): Inherit from process_stratum_target.
161 <test_target_ops>: Default it.
162 * tracefile.c (tracefile_target::tracefile_target): Delete.
163 * tracefile.h: Include "process-stratum-target.h".
164 (tracefile_target): Inherit from process_stratum_target.
165 <tracefile_target>: Default it.
166 * target-delegates.c: Regenerate.
167
168 2018-11-30 Pedro Alves <palves@redhat.com>
169
170 * Makefile.in (COMMON_SFILES): Add test-target.c.
171 * gdbarch-selftests.c: Include "test-target.h".
172 * regcache.c: Include "test-target.h".
173 * target.c (test_target_info, test_target_ops::info): Move to ...
174 * test-target.c: ... this new file.
175 * target.h (test_target_ops): Move to ...
176 * test-target.h: ... this new file.
177
178 2018-11-29 Philippe Waroquiers <philippe.waroquiers@skynet.be>
179
180 * source.c (forward_search_command): Fix leak by using
181 xrealloc even for the first allocation in the loop, as buf
182 is static.
183
184 2018-11-29 Rajendra SY <rajendra.sy@gmail.com>
185
186 PR gdb/23093
187 * gdb/fbsd-tdep.c (fbsd_gdb_signal_from_target)
188 (fbsd_gdb_signal_to_target): New.
189 (fbsd_init_abi): Install gdbarch "signal_from_target" and
190 "signal_to_target" methods.
191
192 2018-11-29 Tom Tromey <tom@tromey.com>
193
194 * valarith.c (value_x_unop): Don't set argvec[3].
195
196 2018-11-26 Simon Marchi <simon.marchi@ericsson.com>
197
198 PR gdb/23917
199 * sparc-linux-nat.c (sparc_linux_nat_target): Remove extraneous
200 semicolon.
201
202 2018-11-26 Pedro Alves <palves@redhat.com>
203
204 * procfs.c (procfs_notice_thread): Replace uses of
205 in_thread_list/is_exited with find_thread_ptid/THREAD_EXITED.
206 * sol-thread.c (sol_thread_target::wait)
207 (sol_update_thread_list_callback): Likewise.
208
209 2018-11-25 Tom Tromey <tom@tromey.com>
210
211 * ui-out.c (ui_out::field_fmt): Remove comment.
212 * tui/tui-out.c (tui_ui_out::do_field_fmt): Remove comment.
213 * mi/mi-out.c (mi_ui_out::do_field_fmt): Remove comment.
214
215 2018-11-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
216
217 * source.c (open_source_file): Leak fixed in '8e6a5953e1d Fix 4K
218 leak in open_source_file' has been partially undone by '2179fbc36d23
219 Return scoped_fd from open_source_file'. Re-add the transfer of
220 current s->fullname to the unique_xmalloc_ptr fullname given
221 to find_and_open_source.
222
223 2018-11-23 Pedro Alves <palves@redhat.com>
224
225 * gdbthread.h (enum thread_state): Move comments here.
226 (is_running, is_stopped, is_exited): Remove declarations.
227
228 2018-11-22 Pedro Alves <palves@redhat.com>
229
230 * Makefile.in (COMMON_SFILES): Add thread-iter.c.
231 * breakpoint.c (breakpoints_should_be_inserted_now): Replace
232 ALL_NON_EXITED_THREADS with all_non_exited_threads.
233 (print_one_breakpoint_location): Replace ALL_INFERIORS with
234 all_inferiors.
235 * bsd-kvm.c: Include inferior.h.
236 * btrace.c (btrace_free_objfile): Replace ALL_NON_EXITED_THREADS
237 with all_non_exited_threads.
238 * common/filtered-iterator.h: New.
239 * common/safe-iterator.h: New.
240 * corelow.c (core_target_open): Don't call init_thread_list here.
241 * darwin-nat.c (thread_info_from_private_thread_info): Replace
242 ALL_THREADS with all_threads.
243 * fbsd-nat.c (fbsd_nat_target::resume): Replace
244 ALL_NON_EXITED_THREADS with inf->non_exited_threads.
245 * fbsd-tdep.c (fbsd_make_corefile_notes): Replace
246 ALL_NON_EXITED_THREADS with inf->non_exited_threads.
247 * fork-child.c (postfork_hook): Don't call init_thread_list here.
248 * gdbarch-selftests.c (register_to_value_test): Adjust.
249 * gdbthread.h: Don't include "inferior.h" here.
250 (struct inferior): Forward declare.
251 (enum step_over_calls_kind): Moved here from inferior.h.
252 (thread_info::deletable): Definition moved to thread.c.
253 (find_thread_ptid (inferior *, ptid_t)): Declare.
254 (ALL_THREADS, ALL_THREADS_BY_INFERIOR, ALL_THREADS_SAFE): Delete.
255 Include "thread-iter.h".
256 (all_threads, all_non_exited_threads, all_threads_safe): New.
257 (any_thread_p): Declare.
258 (thread_list): Delete.
259 * infcmd.c (signal_command): Replace ALL_NON_EXITED_THREADS with
260 all_non_exited_threads.
261 (proceed_after_attach_callback): Delete.
262 (proceed_after_attach): Take an inferior pointer instead of an
263 integer PID. Adjust to use range-for.
264 (attach_post_wait): Pass down inferior pointer instead of pid.
265 Use range-for instead of ALL_NON_EXITED_THREADS.
266 (detach_command): Remove init_thread_list call.
267 * inferior-iter.h: New.
268 * inferior.c (struct delete_thread_of_inferior_arg): Delete.
269 (delete_thread_of_inferior): Delete.
270 (delete_inferior, exit_inferior_1): Use range-for with
271 inf->threads_safe() instead of iterate_over_threads.
272 (inferior_appeared): Call init_thread_list here.
273 (discard_all_inferiors): Use all_non_exited_inferiors.
274 (find_inferior_id, find_inferior_pid): Use all_inferiors.
275 (iterate_over_inferiors): Use all_inferiors_safe.
276 (have_inferiors, number_of_live_inferiors): Use
277 all_non_exited_inferiors.
278 (number_of_inferiors): Use all_inferiors and std::distance.
279 (print_inferior): Use all_inferiors.
280 * inferior.h: Include gdbthread.h.
281 (enum step_over_calls_kind): Moved to gdbthread.h.
282 (struct inferior) <thread_list>: New field.
283 <threads, non_exited_threads, threads_safe>: New methods.
284 (ALL_INFERIORS): Delete.
285 Include "inferior-iter.h".
286 (ALL_NON_EXITED_INFERIORS): Delete.
287 (all_inferiors_safe, all_inferiors, all_non_exited_inferiors): New
288 functions.
289 * inflow.c (child_interrupt, child_pass_ctrlc): Replace
290 ALL_NON_EXITED_THREADS with all_non_exited_threads.
291 * infrun.c (follow_exec): Use all_threads_safe.
292 (clear_proceed_status, proceed): Use all_non_exited_threads.
293 (init_wait_for_inferior): Don't clear inline frame state here.
294 (infrun_thread_stop_requested, for_each_just_stopped_thread): Use
295 all_threads instead of ALL_NON_EXITED_THREADS.
296 (random_pending_event_thread): Use all_non_exited_threads instead
297 of ALL_NON_EXITED_THREADS. Use a lambda for repeated code.
298 (clean_up_just_stopped_threads_fsms): Use all_non_exited_threads
299 instead of ALL_NON_EXITED_THREADS.
300 (handle_no_resumed): Use all_non_exited_threads instead of
301 ALL_NON_EXITED_THREADS. Use all_inferiors instead of
302 ALL_INFERIORS.
303 (restart_threads, switch_back_to_stepped_thread): Use
304 all_non_exited_threads instead of ALL_NON_EXITED_THREADS.
305 * linux-nat.c (check_zombie_leaders): Replace ALL_INFERIORS with
306 all_inferiors.
307 (kill_unfollowed_fork_children): Use inf->non_exited_threads
308 instead of ALL_NON_EXITED_THREADS.
309 * linux-tdep.c (linux_make_corefile_notes): Use
310 inf->non_exited_threads instead of ALL_NON_EXITED_THREADS.
311 * linux-thread-db.c (thread_db_target::update_thread_list):
312 Replace ALL_INFERIORS with all_inferiors.
313 (thread_db_target::thread_handle_to_thread_info): Use
314 inf->non_exited_threads instead of ALL_NON_EXITED_THREADS.
315 * mi/mi-interp.c (multiple_inferiors_p): New.
316 (mi_on_resume_1): Simplify using all_non_exited_threads and
317 multiple_inferiors_p.
318 * mi/mi-main.c (mi_cmd_thread_list_ids): Use all_non_exited_threads
319 instead of ALL_NON_EXITED_THREADS.
320 * nto-procfs.c (nto_procfs_target::open): Don't call
321 init_thread_list here.
322 * record-btrace.c (record_btrace_target_open)
323 (record_btrace_target::stop_recording)
324 (record_btrace_target::close)
325 (record_btrace_target::record_is_replaying)
326 (record_btrace_target::resume, record_btrace_target::wait)
327 (record_btrace_target::record_stop_replaying): Use
328 all_non_exited_threads instead of ALL_NON_EXITED_THREADS.
329 * record-full.c (record_full_wait_1): Use all_non_exited_threads
330 instead of ALL_NON_EXITED_THREADS.
331 * regcache.c (cooked_read_test): Remove reference to global
332 thread_list.
333 * remote-sim.c (gdbsim_target::create_inferior): Don't call
334 init_thread_list here.
335 * remote.c (remote_target::update_thread_list): Use
336 all_threads_safe instead of ALL_NON_EXITED_THREADS.
337 (remote_target::process_initial_stop_replies): Replace
338 ALL_INFERIORS with all_non_exited_inferiors and use
339 all_non_exited_threads instead of ALL_NON_EXITED_THREADS.
340 (remote_target::open_1): Don't call init_thread_list here.
341 (remote_target::append_pending_thread_resumptions)
342 (remote_target::remote_resume_with_hc): Use all_non_exited_threads
343 instead of ALL_NON_EXITED_THREADS.
344 (remote_target::commit_resume)
345 (remote_target::remove_new_fork_children): Replace ALL_INFERIORS
346 with all_non_exited_inferiors and use all_non_exited_threads
347 instead of ALL_NON_EXITED_THREADS.
348 (remote_target::kill_new_fork_children): Use
349 all_non_exited_threads instead of ALL_NON_EXITED_THREADS. Remove
350 init_thread_list and init_wait_for_inferior calls.
351 (remote_target::remote_btrace_maybe_reopen)
352 (remote_target::thread_handle_to_thread_info): Use
353 all_non_exited_threads instead of ALL_NON_EXITED_THREADS.
354 * target.c (target_terminal::restore_inferior)
355 (target_terminal_is_ours_kind): Replace ALL_INFERIORS with
356 all_non_exited_inferiors.
357 * thread-iter.c: New file.
358 * thread-iter.h: New file.
359 * thread.c: Include "inline-frame.h".
360 (thread_list): Delete.
361 (clear_thread_inferior_resources): Call clear_inline_frame_state.
362 (init_thread_list): Use all_threads_safe instead of
363 ALL_THREADS_SAFE. Adjust to per-inferior thread lists.
364 (new_thread): Adjust to per-inferior thread lists.
365 (add_thread_silent): Pass inferior to find_thread_ptid.
366 (thread_info::deletable): New, moved from the header.
367 (delete_thread_1): Adjust to per-inferior thread lists.
368 (find_thread_global_id): Use inf->threads().
369 (find_thread_ptid): Use find_inferior_ptid and pass inferior to
370 find_thread_ptid.
371 (find_thread_ptid(inferior*, ptid_t)): New overload.
372 (iterate_over_threads): Use all_threads_safe.
373 (any_thread_p): New.
374 (thread_count): Use all_threads and std::distance.
375 (live_threads_count): Use all_non_exited_threads and
376 std::distance.
377 (valid_global_thread_id): Use all_threads.
378 (in_thread_list): Use find_thread_ptid.
379 (first_thread_of_inferior): Adjust to per-inferior thread lists.
380 (any_thread_of_inferior, any_live_thread_of_inferior): Use
381 inf->non_exited_threads().
382 (prune_threads, delete_exited_threads): Use all_threads_safe.
383 (thread_change_ptid): Pass inferior pointer to find_thread_ptid.
384 (set_resumed, set_running): Use all_non_exited_threads.
385 (is_thread_state, is_stopped, is_exited, is_running)
386 (is_executing): Delete.
387 (set_executing, set_stop_requested, finish_thread_state): Use
388 all_non_exited_threads.
389 (print_thread_info_1): Use all_inferiors and all_threads.
390 (thread_apply_all_command): Use all_non_exited_threads.
391 (thread_find_command): Use all_threads.
392 (update_threads_executing): Use all_non_exited_threads.
393 * tid-parse.c (parse_thread_id): Use inf->threads.
394 * x86-bsd-nat.c (x86bsd_dr_set): Use inf->non_exited_threads ().
395
396 2018-11-22 Pedro Alves <palves@redhat.com>
397
398 * infrun.c (follow_exec) <set follow-exec new>: Add thread and
399 switch to it before calling into try_open_exec_file.
400
401 2018-11-22 Pedro Alves <palves@redhat.com>
402
403 * cli/cli-interp.c (cli_on_user_selected_context_changed): Use
404 inferior_thread instead of find_thread_ptid, and only when
405 inferior_ptid is not null_ptid.
406 * inferior.c (add_inferior): Don't include target_pid_to_str
407 output when the inferior is not started.
408 * python/py-inferior.c (python_on_normal_stop): Don't use
409 find_thread_ptid.
410 (tui_on_user_selected_context_changed): Use inferior_thread
411 instead of find_thread_ptid, and only when inferior_ptid is not
412 null_ptid.
413
414 2018-11-21 Benno Fünfstück <benno.fuenfstueck@gmail.com>
415
416 PR python/23714
417 * gdb/python/python.c (execute_gdb_command): Call
418 prevent_dont_repeat earlier to avoid affecting dont_repeat.
419
420 2018-11-21 Andrew Burgess <andrew.burgess@embecosm.com>
421
422 * Makefile.in (ALL_TARGET_OBS): Add arch/riscv.o.
423 (HFILES_NO_SRCDIR): Add arch/riscv.h.
424 * arch/riscv.c: New file.
425 * arch/riscv.h: New file.
426 * configure.tgt: Add cpu_obs list of riscv, move riscv-tdep.o into
427 this list, and add arch/riscv.o.
428 * features/Makefile: Add riscv features.
429 * features/riscv/32bit-cpu.c: New file.
430 * features/riscv/32bit-cpu.xml: New file.
431 * features/riscv/32bit-csr.c: New file.
432 * features/riscv/32bit-csr.xml: New file.
433 * features/riscv/32bit-fpu.c: New file.
434 * features/riscv/32bit-fpu.xml: New file.
435 * features/riscv/64bit-cpu.c: New file.
436 * features/riscv/64bit-cpu.xml: New file.
437 * features/riscv/64bit-csr.c: New file.
438 * features/riscv/64bit-csr.xml: New file.
439 * features/riscv/64bit-fpu.c: New file.
440 * features/riscv/64bit-fpu.xml: New file.
441 * features/riscv/rebuild-csr-xml.sh: New file.
442 * riscv-tdep.c: Add 'arch/riscv.h' include.
443 (riscv_gdb_reg_names): Delete.
444 (csr_reggroup): New global.
445 (struct riscv_register_alias): Delete.
446 (struct riscv_register_feature): New structure.
447 (riscv_register_aliases): Delete.
448 (riscv_xreg_feature): New global.
449 (riscv_freg_feature): New global.
450 (riscv_virtual_feature): New global.
451 (riscv_csr_feature): New global.
452 (riscv_create_csr_aliases): New function.
453 (riscv_read_misa_reg): Delete.
454 (riscv_has_feature): Delete.
455 (riscv_isa_xlen): Simplify, just return cached xlen.
456 (riscv_isa_flen): Simplify, just return cached flen.
457 (riscv_has_fp_abi): Update for changes in struct gdbarch_tdep.
458 (riscv_register_name): Update to make use of tdesc_register_name.
459 Look up xreg and freg names in the new globals riscv_xreg_feature
460 and riscv_freg_feature. Don't supply csr aliases here.
461 (riscv_fpreg_q_type): Delete.
462 (riscv_register_type): Use tdesc_register_type in almost all
463 cases, override the returned type in a few specific cases only.
464 (riscv_print_one_register_info): Handle errors reading registers.
465 (riscv_register_reggroup_p): Use tdesc_register_in_reggroup_p for
466 registers that are otherwise unknown to GDB. Also check the
467 csr_reggroup.
468 (riscv_print_registers_info): Remove assert about upper register
469 number, and use gdbarch_register_reggroup_p instead of
470 short-cutting.
471 (riscv_find_default_target_description): New function.
472 (riscv_check_tdesc_feature): New function.
473 (riscv_add_reggroups): New function.
474 (riscv_setup_register_aliases): New function.
475 (riscv_init_reggroups): New function.
476 (_initialize_riscv_tdep): Add calls to setup CSR aliases, and
477 setup register groups. Register new riscv debug variable.
478 * riscv-tdep.h: Add 'arch/riscv.h' include.
479 (struct gdbarch_tdep): Remove abi union, and add
480 riscv_gdbarch_features field. Remove cached quad floating point
481 type, and provide initialisation for double type field.
482 * target-descriptions.c (maint_print_c_tdesc_cmd): Add riscv to
483 the list of targets using the feature based target descriptions.
484 * NEWS: Mention target description support.
485
486 2018-11-21 Pedro Alves <palves@redhat.com>
487
488 * valops.c (find_method_list, value_find_oload_method_list)
489 (find_overload_match, find_oload_champ): Rename parameters and
490 locals.
491
492 2018-11-21 Pedro Alves <palves@redhat.com>
493
494 * valops.c (find_method_list): Replace pointer and length
495 parameters with an gdb::array_view. Adjust.
496 (value_find_oload_method_list): Likewise.
497 (find_overload_match): Use gdb::array_view for methods list.
498 Adjust to find_oload_champ interface change.
499 (find_oload_champ): 'xm_worker_vec' parameter now a pointer/array.
500 'num_fns' parameter now a size_t. Eliminate 'fn_count' local.
501
502 2018-11-21 Pedro Alves <palves@redhat.com>
503
504 * gdbtypes.c (compare_badness): Change type of parameters to const
505 reference. Adjust to badness_vector being a std::vector now.
506 (rank_function): Adjust to badness_vector being a std::vector now.
507 * gdbtypes.h (badness_vector): Now a typedef to std::vector.
508 (LENGTH_MATCH): Delete.
509 (compare_badness): Change type of parameters to const reference.
510 (rank_function): Return a badness_vector by value now.
511 (find_overload_match): Adjust to badness_vector being a
512 std::vector now. Remove cleanups.
513 (find_oload_champ_namespace): 'oload_champ_bv' parameter now a
514 badness_vector pointer.
515 (find_oload_champ_namespace_loop): 'oload_champ_bv' parameter now
516 a badness_vector pointer. Adjust to badness_vector being a
517 std::vector now. Remove cleanups.
518 (find_oload_champ): 'oload_champ_bv' parameter now
519 a badness_vector pointer. Adjust to badness_vector being a
520 std::vector now. Remove cleanups.
521
522 2018-11-21 Pedro Alves <palves@redhat.com>
523
524 * cp-support.c (sym_return_val_size, sym_return_val_index)
525 (sym_return_val): Delete.
526 (overload_list_add_symbol): Add std::vector parameter. Adjust to
527 add to the vector.
528 (make_symbol_overload_list): Adjust to return a std::vector
529 instead of maintaining a global open coded vector.
530 (make_symbol_overload_list_block): Add std::vector parameter.
531 (make_symbol_overload_list_block): Rename to ...
532 (add_symbol_overload_list_block): ... this and add std::vector
533 parameter.
534 (make_symbol_overload_list_namespace): Rename to ...
535 (add_symbol_overload_list_namespace): ... this and add std::vector
536 parameter.
537 (make_symbol_overload_list_adl_namespace): Rename to ...
538 (add_symbol_overload_list_adl_namespace): ... this and add
539 std::vector parameter.
540 (make_symbol_overload_list_adl): Delete.
541 (add_symbol_overload_list_adl): New.
542 (make_symbol_overload_list_using): Rename to ...
543 (add_symbol_overload_list_using): ... this and add std::vector
544 parameter.
545 (make_symbol_overload_list_qualified): Rename to ...
546 (add_symbol_overload_list_qualified): ... this and add std::vector
547 parameter.
548 * cp-support.h: Include "common/array-view.h" and <vector>.
549 (make_symbol_overload_list): Change return type to std::vector.
550 (make_symbol_overload_list_adl): Delete declaration.
551 (add_symbol_overload_list_adl): New declaration.
552 * valops.c (find_overload_match): Local 'oload_syms' now a
553 std::vector.
554 (find_oload_champ_namespace): 'oload_syms' parameter now a
555 std::vector pointer.
556 (find_oload_champ_namespace_loop): 'oload_syms' parameter now a
557 std::vector pointer. Adjust to new make_symbol_overload_list
558 interface.
559
560 2018-11-21 Pedro Alves <palves@redhat.com>
561
562 * common/array-view.h (array_view::splice(size_type, size_t)): New.
563 (array_view::splice(size_type)): New.
564 * eval.c (eval_call, evaluate_funcall): Adjust to use array_view.
565 * extension.c (xmethod_worker::get_arg_types): Adjust to return an
566 std::vector.
567 (xmethod_worker::get_result_type): Adjust to use gdb::array_view.
568 * extension.h: Include "common/array-view.h".
569 (xmethod_worker::invoke): Adjust to use gdb::array_view.
570 (xmethod_worker::get_arg_types): Adjust to return an std::vector.
571 (xmethod_worker::get_result_type): Adjust to use gdb::array_view.
572 (xmethod_worker::do_get_arg_types): Adjust to use std::vector.
573 (xmethod_worker::do_get_result_type): Adjust to use
574 gdb::array_view.
575 * gdbtypes.c (rank_function): Adjust to use gdb::array_view.
576 * gdbtypes.h: Include "common/array-view.h".
577 (rank_function): Adjust to use gdb::array_view.
578 * python/py-xmethods.c (python_xmethod_worker::invoke)
579 (python_xmethod_worker::do_get_arg_types)
580 (python_xmethod_worker::do_get_result_type)
581 (python_xmethod_worker::invoke): Adjust to new interfaces.
582 * valarith.c (value_user_defined_cpp_op, value_user_defined_op)
583 (value_x_binop, value_x_unop): Adjust to use gdb::array_view.
584 * valops.c (find_overload_match, find_oload_champ_namespace)
585 (find_oload_champ_namespace_loop, find_oload_champ): Adjust to use
586 gdb:array_view and the new xmethod_worker interfaces.
587 * value.c (result_type_of_xmethod, call_xmethod): Adjust to use
588 gdb::array_view.
589 * value.h (find_overload_match, result_type_of_xmethod)
590 (call_xmethod): Adjust to use gdb::array_view.
591 * unittests/array-view-selftests.c: Add slicing tests.
592
593 2018-11-21 Pedro Alves <palves@redhat.com>
594
595 * ada-lang.c (ada_evaluate_subexp): Adjust to pass an array_view.
596 * common/array-view.h (make_array_view): New.
597 * compile/compile-object-run.c (compile_object_run): Adjust to
598 pass an array_view.
599 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust.
600 * eval.c (eval_call): Adjust to pass an array_view.
601 (evaluate_subexp_standard): Adjust to pass an array_view.
602 * gcore.c (call_target_sbrk): Adjust to pass an array_view.
603 * guile/scm-value.c (gdbscm_value_call): Likewise.
604 * infcall.c (push_dummy_code): Replace pointer + size parameters
605 with an array_view parameter.
606 (call_function_by_hand, call_function_by_hand_dummy): Likewise and
607 adjust.
608 * infcall.h: Include "common/array-view.h".
609 (call_function_by_hand, call_function_by_hand_dummy): Replace
610 pointer + size parameters with an array_view parameter.
611 * linux-fork.c (inferior_call_waitpid): Adjust to use array_view.
612 * linux-tdep.c (linux_infcall_mmap): Likewise.
613 * objc-lang.c (lookup_objc_class, lookup_child_selector)
614 (value_nsstring, print_object_command): Likewise.
615 * python/py-value.c (valpy_call): Likewise.
616 * rust-lang.c (rust_evaluate_funcall): Likewise.
617 * spu-tdep.c (flush_ea_cache): Likewise.
618 * valarith.c (value_x_binop, value_x_unop): Likewise.
619 * valops.c (value_allocate_space_in_inferior): Likewise.
620 * unittests/array-view-selftests.c (run_tests): Add
621 gdb::make_array_view test.
622
623 2018-11-20 Andrew Burgess <andrew.burgess@embecosm.com>
624
625 * cli-out.c (cli_ui_out::do_field_int): Use string_printf rather
626 than a fixed size buffer.
627
628 2018-11-20 Andrew Burgess <andrew.burgess@embecosm.com>
629
630 * breakpoint.c (print_one_breakpoint_location): Reduce whitespace,
631 and remove insertion of extra spaces in GDB's output.
632 * cli-out.c (cli_ui_out::do_field_fmt): Update header comment.
633 Layout field into a temporary buffer, and then output it as a
634 string field.
635
636 2018-11-20 Philippe Waroquiers <philippe.waroquiers@skynet.be>
637
638 * NEWS: Document the language choice done by
639 'info [types|functions|variables]|rbreak'.
640
641 2018-11-20 Philippe Waroquiers <philippe.waroquiers@skynet.be>
642
643 * symtab.c (treg_matches_sym_type_name): Use
644 scoped_switch_to_sym_language_if_auto instead of local logic.
645 (print_symbol_info): Use scoped_switch_to_sym_language_if_auto
646 to switch to SYM language when language mode is auto.
647
648 2018-11-20 Philippe Waroquiers <philippe.waroquiers@skynet.be>
649
650 * language.h (scoped_switch_to_sym_language_if_auto): New class.
651
652 2018-11-20 Philippe Waroquiers <philippe.waroquiers@skynet.be>
653
654 * symtab.c (search_symbols): Properly check absence of type regexp
655 before entering the loop scanning the minimal symbols.
656
657 2018-11-20 John Darrington <john@darrington.wattle.id.au>
658
659 * s12z-tdep.c (s12z_extract_return_value): New function.
660 (inv_reg_perm) New array.
661 (s12z_return_value): Populate readbuf if non-null.
662
663 2018-11-20 Eli Zaretskii <eliz@gnu.org>
664
665 * common/filestuff.c (gdb_fopen_cloexec): Disable use of "e" mode
666 with 'fopen' also if O_CLOEXEC is equal to O_NOINHERIT, to cater
667 to MinGW fixed by Gnulib.
668 (O_NOINHERIT): Define if not defined.
669
670 2018-11-19 John Darrington <john@darrington.wattle.id.au>
671
672 * s12z-tdep.c (s12z_frame_cache): Add an assertion.
673
674 2018-11-19 Simon Marchi <simon.marchi@polymtl.ca>
675
676 * infrun.c (displaced_step_inferior_state) <next>: Remove.
677
678 2018-11-19 Tom Tromey <tom@tromey.com>
679
680 * source.c (get_filename_and_charpos): Return void.
681
682 2018-11-19 Simon Marchi <simon.marchi@polymtl.ca>
683
684 * skip.c (_initialize_step_skip): Fix "info skip" help.
685
686 2018-11-16 Tom Tromey <tom@tromey.com>
687
688 PR rust/23625:
689 * rust-lang.c (rust_internal_print_type): Handle TYPE_CODE_PTR.
690
691 2018-11-19 Simon Marchi <simon.marchi@ericsson.com>
692
693 * infrun.c (displaced_step_inferior_states): Change type to
694 std::forward_list.
695 (get_displaced_stepping_state): Adjust.
696 (displaced_step_in_progress_any_inferior): Adjust.
697 (add_displaced_stepping_state): Adjust.
698 (remove_displaced_stepping_state): Adjust.
699
700 2018-11-18 Tom Tromey <tom@tromey.com>
701
702 PR build/23814:
703 * target-delegates.c: Rebuild.
704 * ia64-linux-nat.c (class ia64_linux_nat_target)
705 <have_steppable_watchpoint>: Use override. Return true, not 1.
706 (ia64_linux_nat_target::can_use_hw_breakpoint): Rename. Remove
707 "self" argument.
708 (ia64_linux_nat_target::low_new_thread): Rename.
709 (class ia64_linux_nat_target) <read_description>: Don't declare.
710 * target.h (struct target_ops) <have_steppable_watchpoint>: Return
711 bool.
712
713 2018-11-16 Alan Hayward <alan.hayward@arm.com>
714
715 PR gdb/22736:
716 * aarch64-tdep.c (aarch64_push_dummy_call): Remove
717 lang_struct_return code.
718
719 2018-11-16 Alan Hayward <alan.hayward@arm.com>
720
721 * aarch64-tdep.c (aarch64_push_dummy_call): Replace arg with
722 return_method.
723 * alpha-tdep.c (alpha_push_dummy_call): Likewise.
724 * amd64-tdep.c (amd64_push_arguments): Likewise.
725 (amd64_push_dummy_call): Likewise.
726 * amd64-windows-tdep.c (amd64_windows_push_arguments): Likewise.
727 * arc-tdep.c (arc_push_dummy_call): Likewise.
728 * arm-tdep.c (arm_push_dummy_call): Likewise.
729 * avr-tdep.c (avr_push_dummy_call): Likewise.
730 * bfin-tdep.c (bfin_push_dummy_call): Likewise.
731 * cris-tdep.c (cris_push_dummy_call): Likewise.
732 * csky-tdep.c (csky_push_dummy_call): Likewise.
733 * frv-tdep.c (frv_push_dummy_call): Likewise.
734 * gdbarch.c: Regenerate.
735 * gdbarch.h: Regenerate.
736 * gdbarch.sh (gdbarch_push_dummy_call): Replace arg with
737 return_method.
738 * h8300-tdep.c (h8300_push_dummy_call): Likewise.
739 * hppa-tdep.c (hppa32_push_dummy_call): Likewise.
740 (hppa64_push_dummy_call): Likewise.
741 * i386-darwin-tdep.c (i386_darwin_push_dummy_call): Likewise.
742 * i386-tdep.c (i386_push_dummy_call): Likewise.
743 * ia64-tdep.c (ia64_push_dummy_call): Likewise.
744 * infcall.c (call_function_by_hand_dummy): Likewise.
745 * iq2000-tdep.c (iq2000_push_dummy_call): Likewise.
746 * lm32-tdep.c (lm32_push_dummy_call): Likewise.
747 * m32c-tdep.c (m32c_push_dummy_call): Likewise.
748 * m32r-tdep.c (m32r_push_dummy_call): Likewise.
749 * m68hc11-tdep.c (m68hc11_push_dummy_call): Likewise.
750 * m68k-tdep.c (m68k_push_dummy_call): Likewise.
751 * mep-tdep.c (mep_push_dummy_call): Likewise.
752 * mips-tdep.c (mips_eabi_push_dummy_call): Likewise.
753 (mips_n32n64_push_dummy_call): Likewise.
754 (mips_o32_push_dummy_call): Likewise.
755 (mips_o64_push_dummy_call): Likewise.
756 * mn10300-tdep.c (mn10300_push_dummy_call): Likewise.
757 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
758 * nds32-tdep.c (nds32_push_dummy_call): Likewise.
759 * nios2-tdep.c (nios2_push_dummy_call): Likewise.
760 * or1k-tdep.c (or1k_push_dummy_call): Likewise.
761 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
762 (ppc64_sysv_abi_push_dummy_call): Likewise.
763 * ppc-tdep.h (ppc_sysv_abi_push_dummy_call): Likewise.
764 (ppc64_sysv_abi_push_dummy_call): Likewise.
765 * riscv-tdep.c (riscv_push_dummy_call): Likewise.
766 * rl78-tdep.c (rl78_push_dummy_call): Likewise.
767 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
768 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
769 * rx-tdep.c (rx_push_dummy_call): Likewise.
770 * s390-tdep.c (s390_push_dummy_call): Likewise.
771 * score-tdep.c (score_push_dummy_call): Likewise.
772 * sh-tdep.c (sh_push_dummy_call_fpu): Likewise.
773 (sh_push_dummy_call_nofpu): Likewise.
774 * sparc-tdep.c (sparc32_store_arguments): Likewise.
775 (sparc32_push_dummy_call): Likewise.
776 * sparc64-tdep.c (sparc64_store_arguments): Likewise.
777 (sparc64_push_dummy_call): Likewise.
778 * spu-tdep.c (spu_push_dummy_call): Likewise.
779 * tic6x-tdep.c (tic6x_push_dummy_call): Likewise.
780 * tilegx-tdep.c (tilegx_push_dummy_call): Likewise.
781 * v850-tdep.c (v850_push_dummy_call): Likewise.
782 * vax-tdep.c (vax_push_dummy_call): Likewise.
783 * xstormy16-tdep.c (xstormy16_push_dummy_call): Likewise.
784 * xtensa-tdep.c (xtensa_push_dummy_call): Likewise.
785
786 2018-11-16 Alan Hayward <alan.hayward@arm.com>
787
788 * gdbarch.sh (enum function_call_return_method): Add enum.
789 * gdbarch.h: Regenerate.
790 * infcall.c (call_function_by_hand_dummy): Replace vars with enum.
791
792 2018-11-15 Joel Brobecker <brobecker@adacore.com>
793
794 * unittests/copy_bitwise-selftests.c: New file.
795 * utils.c (selftests::bits_to_str, selftests::check_copy_bitwise)
796 (selftests::copy_bitwise_tests): Delete, moving this code to
797 unittests/copy_bitwise-selftests.c instead.
798 (_initialize_utils): Do not register copy_bitwise tests.
799 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
800 unittests/copy_bitwise-selftests.c.
801
802 2018-11-14 Joel Brobecker <brobecker@adacore.com>
803
804 * ada-lang.c (move_bits): Delete. Update all callers to use
805 copy_bitwise instead.
806 * dwarf2loc.c (copy_bitwise, bits_to_str::bits_to_str)
807 (selftests::check_copy_bitwise, selftests::copy_bitwise_tests):
808 Move from here to utils.c.
809 (_initialize_dwarf2loc): Remove call to register copy_bitwise
810 selftests.
811 * utils.h (copy_bitwise): Add declaration.
812 * utils.c (copy_bitwise, bits_to_str::bits_to_str)
813 (selftests::check_copy_bitwise, selftests::copy_bitwise_tests):
814 Moved here from dwarf2loc.c.
815 (_initialize_utils): Register copy_bitwise selftests.
816
817 2018-11-14 Jim Wilson <jimw@sifive.com>
818
819 * riscv-tdep.c (struct riscv_arg_info): New field is_unnamed.
820 (riscv_call_arg_scalar_int): If unnamed arg with twice xlen alignment,
821 then increment next_regnum if odd.
822 (riscv_arg_location): New arg is_unnamed. Set ainfo->is_unnamed.
823 (riscv_push_dummy_call): New local ftype. Call check_typedef to set
824 function type. Pass new arg to riscv_arg_location based on function
825 type.
826 (riscv_return_value): Pass new arg to riscv_arg_location.
827
828 * riscv-tdep.c (BIGGEST_ALIGNMENT): New.
829 (riscv_type_alignment) <TYPE_CODE_ARRAY>: If TYPE_VECTOR, return min
830 of TYPE_LENGTH and BIGGEST_ALIGNMENT.
831
832 * riscv-tdep.c (riscv_call_arg_scalar_int): Use std::min when
833 setting len. New local align, set to max of arg align and xlen,
834 and pass to first riscv_assign_stack_location call.
835
836 2018-11-12 Simon Marchi <simon.marchi@polymtl.ca>
837
838 * skip.c (complete_skip_number): New function.
839 (_initialize_step_skip): Add completers to some skip commands.
840
841 2018-11-09 Tom Tromey <tom@tromey.com>
842
843 * remote.c (remote_g_packet_guess_s): Remove typedef and DEF_VEC.
844 (struct remote_g_packet_data): Derive from allocate_on_obstack.
845 <guesses>: Now a std::vector.
846 (remote_g_packet_data_init, register_remote_g_packet_guess):
847 Update.
848 (remote_read_description_p): Update. Return bool.
849 (remote_target::read_description): Update.
850 (struct remote_g_packet_guess): Add constructor.
851
852 2018-11-09 Tom Tromey <tom@tromey.com>
853
854 * common/scoped_fd.h (class scoped_fd): Add move constructor and
855 move assignment operator.
856 * psymtab.c (psymtab_to_fullname): Update.
857 * source.h (open_source_file): Return scoped_fd.
858 (find_and_open_source): Likewise.
859 * source.c (open_source_file): Return scoped_fd.
860 (get_filename_and_charpos): Update.
861 (print_source_lines_base): Update. Use scoped_fd::to_file.
862 (forward_search_command): Likewise.
863 (reverse_search_command): Likewise.
864 (find_and_open_source): Return scoped_fd.
865 * tui/tui-source.c (tui_set_source_content): Update. Use
866 gdb_file_up.
867
868 2018-11-09 John Baldwin <jhb@FreeBSD.org>
869
870 * minsyms.c (minimal_symbol_reader::install): Fix unsigned
871 overflow.
872
873 2018-11-09 Hafiz Abid Qadeer <abidh@codesourcery.com>
874
875 * configure: Regenerate.
876
877 2018-11-09 Tom de Vries <tdevries@suse.de>
878
879 * symtab.c (symbol_set_names): Call symbol_find_demangled_name
880 unconditionally, to set the language of the symbol. Manage freeing
881 returned pointer using gdb::unique_xmalloc_ptr.
882
883 2018-11-08 Tom Tromey <tom@tromey.com>
884
885 * record.c (require_record_target): Upper-case "<TAB>".
886
887 2018-11-08 Tom Tromey <tom@tromey.com>
888
889 * python/lib/gdb/command/pretty_printers.py
890 (InfoPrettyPrinter.invoke): Don't indent "objfile" heading.
891
892 2018-11-08 Tom Tromey <tom@tromey.com>
893
894 PR gdb/23555:
895 PR gdb/23838:
896 * target.h (target_supports_terminal_ours): Return bool.
897 * target.c (target_supports_terminal_ours): Handle case where
898 current_top_target returns nullptr. Return bool.
899
900 2018-11-08 Joel Brobecker <brobecker@adacore.com>
901
902 * aarch64-tdep.c (aapcs_is_vfp_call_or_return_candidate_1):
903 return the correct count for potential HFAs.
904
905 2018-11-08 Jan Beulich <jbeulich@suse.com>
906
907 * i387-tdep.c (i387_supply_xsave): Split handling of
908 X86_XSTATE_ZMM_H and X86_XSTATE_ZMM.
909 (i387_collect_xsave): Likewise.
910
911 2018-11-08 Andrew Burgess <andrew.burgess@embecosm.com>
912
913 * riscv-tdep.c (riscv_insn::decode): Update header comment.
914 (riscv_frame_this_id): Catch errors thrown while building the
915 frame cache, leave the frame id as the default, which is the outer
916 frame id.
917
918 2018-11-07 Joel Brobecker <brobecker@adacore.com>
919
920 * ada-lang.c (read_atcb): Only set task_info->called_task if
921 task_info->state == Entry_Caller_Sleep.
922 (print_ada_task_info): Do not check task_info->state before
923 checking task_info->called_task.
924 (info_task): Likewise.
925
926 2018-11-07 Joel Brobecker <brobecker@adacore.com>
927
928 * ada-tasks.c (read_atcb): Clear task_info before computing
929 the value of each of its fields.
930
931 2018-11-07 Andrew Burgess <andrew.burgess@embecosm.com>
932
933 * dwarf2read.c (dwarf2_init_integer_type): Check for name being
934 NULL before dereferencing it.
935
936 2018-11-06 Tom de Vries <tdevries@suse.de>
937
938 * linux-tdep.c (linux_vsyscall_range_raw): Use xmalloc to allocate
939 program headers.
940
941 2018-11-06 Max Filippov <jcmvbkbc@gmail.com>
942
943 * configure.tgt (xtensa*-*-linux*): Change to xtensa*-*-*linux*
944 so that it applies to uclinux as well.
945
946 2018-11-06 Marius Muench <marius.muench@eurecom.fr>
947
948 * arm-tdep.c (arm_scan_prologue): Don't dereference FP reg
949 when on AAPCS.
950
951 2018-11-06 John Baldwin <jhb@FreeBSD.org>
952
953 * riscv-fbsd-nat.c (getregs_supplies): Return true for
954 RISCV_CSR_SSTATUS_REGNUM.
955
956 2018-11-04 Philippe Waroquiers <philippe.waroquiers@skynet.be>
957
958 * source.c (open_source_file): Fix leak by transferring the
959 current s->fullname to the unique_xmalloc_ptr fullname given
960 to find_and_open_source.
961
962 2018-11-04 Tom Tromey <tom@tromey.com>
963
964 * varobj.c (install_default_visualizer): Update.
965 * python/python-internal.h (gdbpy_get_varobj_pretty_printer):
966 Return gdbpy_ref.
967 * python/py-prettyprint.c (search_pp_list): Return gdbpy_ref.
968 (find_pretty_printer_from_progspace)
969 (find_pretty_printer_from_gdb, find_pretty_printer)
970 (gdbpy_get_varobj_pretty_printer): Return gdbpy_ref.
971 (gdbpy_get_varobj_pretty_printer, gdbpy_default_visualizer):
972 Update.
973
974 2018-11-04 Tom Tromey <tom@tromey.com>
975
976 * python/python.c (gdbpy_parameter_value): Update.
977 * python/python-internal.h (python_string_to_unicode)
978 (python_string_to_target_python_string)
979 (host_string_to_python_string): Return gdbpy_ref.
980 * python/py-utils.c (python_string_to_unicode)
981 (unicode_to_encoded_python_string)
982 (unicode_to_target_python_string)
983 (python_string_to_target_string)
984 (python_string_to_target_python_string): Return gdbpy_ref.
985 (python_string_to_host_string): Update.
986 (host_string_to_python_string): Return gdbpy_ref.
987 * python/py-symtab.c (stpy_get_filename, stpy_get_producer)
988 (stpy_fullname): Update.
989 * python/py-progspace.c (pspy_get_filename, pspy_solib_name):
990 Update.
991 * python/py-prettyprint.c (print_string_repr): Update.
992 * python/py-objfile.c (objfpy_get_filename, objfpy_get_username)
993 (objfpy_get_build_id): Update.
994 * python/py-breakpoint.c (bppy_get_location)
995 (bppy_get_expression, bppy_get_condition, bppy_get_commands):
996 Update.
997
998 2018-11-04 Tom Tromey <tom@tromey.com>
999
1000 * python/python-internal.h (gdb_py_object_from_longest)
1001 (gdb_py_object_from_ulongest): Return gdbpy_ref.
1002 * python/py-value.c (valpy_int): Update.
1003 * python/py-utils.c (gdb_py_object_from_longest): Return
1004 gdbpy_ref.
1005 (gdb_py_object_from_ulongest): Likewise.
1006 * python/py-type.c (typy_get_alignof): Update.
1007 * python/py-linetable.c (ltpy_get_all_source_lines)
1008 (ltpy_entry_get_line, ltpy_entry_get_pc): Update.
1009 * python/py-block.c (blpy_get_start, blpy_get_end): Update.
1010
1011 2018-11-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1012
1013 * ada-lang.c (_initialize_ada_language): Fix typo.
1014
1015 2018-11-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1016
1017 * language.c (type): Remove.
1018 (_initialize_language): Remove assignment to type.
1019
1020 2018-11-02 Joel Brobecker <brobecker@adacore.com>
1021
1022 * aarch64-ravenscar-thread.h, aarch64-ravenscar-thread.c: New files.
1023 * aarch64-tdep.c: #include "aarch64-ravenscar-thread.h".
1024 (aarch64_gdbarch_init): Add call to register_aarch64_ravenscar_ops.
1025 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-ravenscar-thread.o.
1026 (HFILES_NO_SRCDIR): Add aarch64-ravenscar-thread.h.
1027 (ALLDEPFILES): Add aarch64-ravenscar-thread.c.
1028 * configure.tgt (cpu_obs) [aarch64*-*-*]: Add ravenscar-thread.o
1029 and aarch64-ravenscar-thread.o.
1030 * NEWS: Add entry documenting Ravenscar tasking support
1031 on AArch64 ELF.
1032
1033 2018-11-02 Matthew Malcomson <matthew.malcomson@arm.com>
1034
1035 * symtab.c (info_functions_command): Initialize quiet flag.
1036 * stack.c (info_args_command): Likewise.
1037
1038 2018-11-01 Jim Wilson <jimw@sifive.com>
1039
1040 * riscv-tdep.c (riscv_breakpoint_kind_from_pc): New local unaligned_p.
1041 Set if pcptr if unaligned. Return 2 if unaligned_p true. Update
1042 debugging messages.
1043
1044 2018-11-01 Joel Brobecker <brobecker@adacore.com>
1045
1046 * ada-lang.c (ada_watch_location_expression): New function.
1047 (ada_language_defn): Set la_watch_location_expression to
1048 ada_watch_location_expression.
1049
1050 2018-11-01 Joel Brobecker <brobecker@adacore.com>
1051
1052 * print-utils.c (int_string): Remove unnecessary trailing spaces.
1053
1054 2018-11-01 Joel Brobecker <brobecker@adacore.com>
1055
1056 * rs6000-tdep.c (skip_prologue): Fix potential negative left
1057 shifting.
1058
1059 2018-11-01 Jerome Guitton <guitton@adacore.com>
1060 Joel Brobecker <brobecker@adacore.com>
1061
1062 * defs.h (enum gdb_osabi): Add GDB_OSABI_PIKEOS.
1063 * osabi.c (gdb_osabi_names): Add name for GDB_OSABI_PIKEOS.
1064 * arm-pikeos-tdep.c: New file.
1065 * configure.tgt: Add arm-pikeos-tdep.o to the case of ARM
1066 embedded system.
1067 * Makefile.in (ALL_TARGET_OBS): Add arm-pikeos-tdep.o.
1068
1069 2018-11-01 Simon Marchi <simon.marchi@ericsson.com>
1070
1071 * common/pathstuff.c (get_standard_temp_dir): New.
1072 * common/pathstuff.h (get_standard_temp_dir): New.
1073 * config.in: Re-generate.
1074 * configure: Re-generate.
1075 * configure.ac: Don't check for mkdtemp.
1076 * gnulib/aclocal-m4-deps.mk: Re-generate.
1077 * gnulib/aclocal.m4: Re-generate.
1078 * gnulib/config.in: Re-generate.
1079 * gnulib/configure: Re-generate.
1080 * gnulib/import/Makefile.am: Re-generate.
1081 * gnulib/import/Makefile.in: Re-generate.
1082 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
1083 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
1084 * gnulib/import/m4/mkdtemp.m4: New file.
1085 * gnulib/import/mkdtemp.c: New file.
1086 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES):
1087 Add mkdtemp module.
1088 * unittests/mkdir-recursive-selftests.c (test): Use
1089 get_standard_temp_dir.
1090 (_initialize_mkdir_recursive_selftests): Remove HAVE_MKDTEMP
1091 ifdef.
1092 * compile/compile.c (get_compile_file_tempdir): Likewise.
1093
1094 2018-11-01 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
1095
1096 * rs6000-aix-tdep.c: Include "trad-frame.h" and "frame-unwind.h".
1097 (SIG_FRAME_LR_OFFSET64): New define.
1098 (SIG_FRAME_FP_OFFSET64): New define.
1099 (aix_sighandle_frame_cache): New Function.
1100 (aix_sighandle_frame_this_id): New Function.
1101 (aix_sighandle_frame_prev_register): New Function.
1102 (aix_sighandle_frame_sniffer): New Function.
1103 (aix_sighandle_frame_unwind): New global variable.
1104 (rs6000_aix_init_osabi): Install new frame unwinder.
1105
1106 2018-10-31 Sergio Durigan Junior <sergiodj@redhat.com>
1107
1108 PR gdb/23835
1109 * common/common-defs.h: Don't redefine _FORTIFY_SOURCE if it's
1110 already defined.
1111
1112 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1113
1114 * ppc-linux-nat.c: Include nat/linux-ptrace.h.
1115
1116 2018-10-31 Andrew Burgess <andrew.burgess@embecosm.com>
1117
1118 * dwarf2read.c (struct dwarf2_cu): Add producer_is_icc field.
1119 (producer_is_icc): New function.
1120 (check_producer): Set producer_is_icc field on dwarf2_cu.
1121 (dwarf2_init_integer_type): New function.
1122 (read_base_type): Call dwarf2_init_integer_type instead of
1123 init_integer_type in all cases.
1124 (dwarf2_cu::dwarf2_cu): Initialise producer_is_icc field.
1125 * valprint.c (maybe_negate_by_bytes): Add an assertion that the
1126 LEN is greater than 0.
1127
1128 2018-10-30 Tom Tromey <tom@tromey.com>
1129
1130 * main.c (captured_main_1): Check return value of bfd_init.
1131
1132 2018-10-29 Sergio Durigan Junior <sergiodj@redhat.com>
1133
1134 * common/offset-type.h (DEFINE_OFFSET_REL_OP): Delete.
1135 Adjust comments.
1136
1137 2018-10-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1138
1139 * procfs.c: Include common/pathstuff.h.
1140
1141 2018-10-28 Andrew Burgess <andrew.burgess@embecosm.com>
1142
1143 * riscv-linux-nat.c (riscv_linux_nat_target::fetch_registers):
1144 Add missing braces. No functional change.
1145
1146 2018-10-27 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1147
1148 * macrocmd.c (info_macro_command): Use report_unrecognized_option_error
1149 to report a bad option and fix indentation.
1150 * demangle.c (demangle_command): Use report_unrecognized_option_error
1151 to report a bad option and correctly report the bad option.
1152
1153 2018-10-27 Tom Tromey <tom@tromey.com>
1154
1155 PR cli/23364:
1156 * darwin-nat.c (copied_shell): New global.
1157 (may_have_sip): Rename from should_disable_startup_with_shell.
1158 (copy_shell_to_cache, maybe_cache_shell): New functions.
1159 (darwin_nat_target::create_inferior): Update. Use
1160 copied_shell.
1161
1162 2018-10-27 Tom Tromey <tom@tromey.com>
1163
1164 * unittests/scoped_fd-selftests.c (test_to_file): New function.
1165 (run_tests): Call test_to_file.
1166 * dwarf-index-write.c (write_psymtabs_to_index): Do not reopen
1167 temporary files.
1168 * common/scoped_fd.h (scoped_fd::to_file): New method.
1169
1170 2018-10-27 Tom Tromey <tom@tromey.com>
1171
1172 * unittests/scoped_mmap-selftests.c (test_normal): Use
1173 gdb_mkostemp_cloexec.
1174 * unittests/scoped_fd-selftests.c (test_destroy, test_release):
1175 Use gdb_mkostemp_cloexec.
1176 * gnulib/aclocal-m4-deps.mk, gnulib/aclocal.m4,
1177 gnulib/config.in, gnulib/configure,
1178 gnulib/import/Makefile.am, gnulib/import/Makefile.in,
1179 gnulib/import/m4/gnulib-cache.m4,
1180 gnulib/import/m4/gnulib-comp.m4: Update.
1181 * gnulib/import/m4/mkostemp.m4: New file.
1182 * gnulib/import/m4/mkstemp.m4: Remove.
1183 * gnulib/import/mkostemp.c: New file.
1184 * gnulib/import/mkstemp.m4: Remove.
1185 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Remove
1186 mkstemp, add mkostemp. Apply new patch.
1187 * gnulib/import/stdlib.in.h: Apply patch.
1188 * gnulib/patches/0002-mkostemp-mkostemps-Fix-compilation-error-in-C-mode-o.patch:
1189 New file.
1190 * dwarf-index-write.c (write_psymtabs_to_index): Use
1191 gdb_mkostemp_cloexec.
1192 * common/filestuff.h (gdb_mkostemp_cloexec): New function.
1193
1194 2018-10-27 Tom Tromey <tom@tromey.com>
1195
1196 * unittests/mkdir-recursive-selftests.c: New file.
1197 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1198 unittests/mkdir-recursive-selftests.c.
1199 * dwarf-index-cache.c (mkdir_recursive): Move to
1200 common/filestuff.c.
1201 (index_cache::store): Check return value of mkdir_recursive.
1202 (create_dir_and_check, test_mkdir_recursive): Move to new file.
1203 (_initialize_index_cache): Don't register test.
1204 * common/filestuff.h (mkdir_recursive): Declare.
1205 * common/filestuff.c (mkdir_recursive): Move from
1206 dwarf-index-cache.c. Return bool.
1207
1208 2018-10-27 Tom Tromey <tom@tromey.com>
1209
1210 * dwarf-index-write.c (write_psymtabs_to_index): Move
1211 make_temp_filename to common/pathstuff.c.
1212 * common/pathstuff.h (make_temp_filename): Declare.
1213 * common/pathstuff.c (make_temp_filename): New function, moved
1214 from dwarf-index-write.c.
1215
1216 2018-10-27 Tom Tromey <tom@tromey.com>
1217
1218 * procfs.c (procfs_target::create_inferior): Use get_shell.
1219 * cli/cli-cmds.c (shell_escape): Use get_shell.
1220 * windows-nat.c (windows_nat_target::create_inferior): Use
1221 get_shell.
1222 * common/pathstuff.c (get_shell): New function.
1223 * nat/fork-inferior.c (SHELL_FILE, get_startup_shell): Remove.
1224 (fork_inferior): Use get_shell.
1225 * common/pathstuff.h (get_shell): Declare.
1226
1227 2018-10-27 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1228
1229 * NEWS: Mention changes to 'info [args|functions|locals|variables]'
1230
1231 2018-10-27 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1232
1233 * stack.c (print_variable_and_value_data): Add preg and treg.
1234 (print_frame_local_vars): Add quiet, regexp and t_regexp arguments,
1235 and update callers.
1236 (print_frame_arg_vars): Likewise.
1237 (prepare_reg): New function.
1238 (info_locals_command): Extract info print args and use them.
1239 (info_args_command): Likewise.
1240 (_initialize_stack): Modify on-line help.
1241 * symtab.c (treg_matches_sym_type_name): New function.
1242 (search_symbols): New arg t_regexp.
1243 (symtab_symbol_info): New args quiet, regexp, t_regexp.
1244 (info_variables_command): Extract info print args and use them.
1245 (info_functions_command): Likewise.
1246 (info_types_command): Update call to symtab_symbol_info.
1247 (_initialize_symtab): Modify on-line help.
1248 * symtab.h (treg_matches_sym_type_name): New function.
1249 (search_symbols): New t_regexp arg.
1250
1251 2018-10-27 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1252
1253 * cli-utils.c (extract_arg_maybe_quoted): New function.
1254 (extract_info_print_args): New function.
1255 (info_print_args_help): New function.
1256 (report_unrecognized_option_error): New function.
1257 * cli-utils.h (extract_arg_maybe_quoted): New function.
1258 (extract_info_print_args): New function.
1259 (info_print_args_help): New function.
1260 (report_unrecognized_option_error): New function.
1261
1262 2018-10-26 Tom Tromey <tom@tromey.com>
1263
1264 * dwarf2read.c (recursively_compute_inclusions): Use std::vector.
1265 (compute_compunit_symtab_includes): Update.
1266 * symtab.h: (symtab_ptr): Remove typedef. Don't define a VEC.
1267 (compunit_symtab_ptr): Likewise.
1268
1269 2018-10-26 John Baldwin <jhb@FreeBSD.org>
1270
1271 * fbsd-tdep.c (fbsd_print_auxv_entry): Only use
1272 default_print_auxv_entry for specific tag values.
1273
1274 2018-10-26 John Baldwin <jhb@FreeBSD.org>
1275
1276 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_FREEBSD_HWCAP2.
1277
1278 2018-10-26 Jim Wilson <jimw@sifive.com>
1279
1280 * riscv-linux-tdep.c: Include tramp-frame.h and trad-frame.h.
1281 (riscv_linux_sigframe_init): Declare.
1282 (RISCV_INST_LI_A7_SIGRETURN, RISCV_INT_ECALL): New.
1283 (riscv_linux_sigframe): New.
1284 (SIGFRAME_SIGINFO_SIZE, UCONTEXT_MCONTEXT_OFFSET): New.
1285 (riscv_linux_sigframe_init): Define.
1286 (riscv_linux_init_abi): Call tramp_frame_prepend_unwinder.
1287
1288 * riscv-tdep.c (riscv_isa_xlen): Refer to riscv-tdep.h comment.
1289 (riscv_isa_flen): Likewise. Drop static.
1290 * riscv-tdep.h (riscv_isa_xlen): Move riscv-tdep.c comment to here.
1291 (riscv_isa_flen): Likewise. Declare.
1292
1293 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
1294 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1295
1296 * arch/ppc-linux-tdesc.h (tdesc_powerpc_isa207_htm_vsx32l)
1297 (tdesc_powerpc_isa207_htm_vsx64l): Declare.
1298 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_TM_SPRREGSET)
1299 (PPC32_LINUX_SIZEOF_CGPRREGSET, PPC64_LINUX_SIZEOF_CGPRREGSET)
1300 (PPC_LINUX_SIZEOF_CFPRREGSET, PPC_LINUX_SIZEOF_CVMXREGSET)
1301 (PPC_LINUX_SIZEOF_CVSXREGSET, PPC_LINUX_SIZEOF_CPPRREGSET)
1302 (PPC_LINUX_SIZEOF_CDSCRREGSET, PPC_LINUX_SIZEOF_CTARREGSET):
1303 Define.
1304 (struct ppc_linux_features) <htm>: New field.
1305 (ppc_linux_no_features): Add initializer for htm field.
1306 * arch/ppc-linux-common.c (ppc_linux_match_description): Return
1307 new tdescs.
1308 * nat/ppc-linux.h (PPC_FEATURE2_HTM, NT_PPC_TM_CGPR)
1309 (NT_PPC_TM_CFPR, NT_PPC_TM_CVMX, NT_PPC_TM_CVSX)
1310 (NT_PPC_TM_SPR, NT_PPC_TM_CTAR, NT_PPC_TM_CPPR, NT_PPC_TM_CDSCR):
1311 Define if not already defined.
1312 * features/Makefile (WHICH): Add rs6000/powerpc-isa207-htm-vsx32l
1313 and rs6000/powerpc-isa207-htm-vsx64l.
1314 (XMLTOC): Add rs6000/powerpc-isa207-htm-vsx32l.xml and
1315 rs6000/powerpc-isa207-htm-vsx64l.xml.
1316 * features/rs6000/power-htm-spr.xml: New file.
1317 * features/rs6000/power-htm-core.xml: New file.
1318 * features/rs6000/power64-htm-core.xml: New file.
1319 * features/rs6000/power-htm-fpu.xml: New file.
1320 * features/rs6000/power-htm-altivec.xml: New file.
1321 * features/rs6000/power-htm-vsx.xml: New file.
1322 * features/rs6000/power-htm-ppr.xml: New file.
1323 * features/rs6000/power-htm-dscr.xml: New file.
1324 * features/rs6000/power-htm-tar.xml: New file.
1325 * features/rs6000/powerpc-isa207-htm-vsx32l.xml: New file.
1326 * features/rs6000/powerpc-isa207-htm-vsx64l.xml: New file.
1327 * features/rs6000/powerpc-isa207-htm-vsx32l.c: Generate.
1328 * features/rs6000/powerpc-isa207-htm-vsx64l.c: Generate.
1329 * regformats/rs6000/powerpc-isa207-htm-vsx32l.dat: Generate.
1330 * regformats/rs6000/powerpc-isa207-htm-vsx64l.dat: Generate.
1331 * ppc-linux-nat.c (fetch_register, fetch_ppc_registers): Call
1332 fetch_regset with HTM regsets.
1333 (store_register, store_ppc_registers): Call store_regset with HTM
1334 regsets.
1335 (ppc_linux_nat_target::read_description): Set htm field in the
1336 features struct if needed.
1337 * ppc-linux-tdep.c: Include
1338 features/rs6000/powerpc-isa207-htm-vsx32l.c and
1339 features/rs6000/powerpc-isa207-htm-vsx64l.c.
1340 (ppc32_regmap_tm_spr, ppc32_regmap_cgpr, ppc64_le_regmap_cgpr)
1341 (ppc64_be_regmap_cgpr, ppc32_regmap_cfpr, ppc32_le_regmap_cvmx)
1342 (ppc32_be_regmap_cvmx, ppc32_regmap_cvsx, ppc32_regmap_cppr)
1343 (ppc32_regmap_cdscr, ppc32_regmap_ctar): New globals.
1344 (ppc32_linux_tm_sprregset, ppc32_linux_cgprregset)
1345 (ppc64_be_linux_cgprregset, ppc64_le_linux_cgprregset)
1346 (ppc32_linux_cfprregset, ppc32_le_linux_cvmxregset)
1347 (ppc32_be_linux_cvmxregset, ppc32_linux_cvsxregset)
1348 (ppc32_linux_cpprregset, ppc32_linux_cdscrregset)
1349 (ppc32_linux_ctarregset): New globals.
1350 (ppc_linux_cgprregset, ppc_linux_cvmxregset): New functions.
1351 (ppc_linux_collect_core_cpgrregset): New function.
1352 (ppc_linux_iterate_over_regset_sections): Call back with the htm
1353 regsets.
1354 (ppc_linux_core_read_description): Check if the tm spr section is
1355 present and set htm in the features struct.
1356 (_initialize_ppc_linux_tdep): Call
1357 initialize_tdesc_powerpc_isa207_htm_vsx32l and
1358 initialize_tdesc_powerpc_isa207_htm_vsx64l.
1359 * ppc-linux-tdep.h (ppc_linux_cgprregset, ppc_linux_cvmxregset):
1360 Declare.
1361 (ppc32_linux_tm_sprregset, ppc32_linux_cfprregset)
1362 (ppc32_linux_cvsxregset, ppc32_linux_cpprregset)
1363 (ppc32_linux_cdscrregset, ppc32_linux_ctarregset): Declare.
1364 * ppc-tdep.h (struct gdbarch_tdep) <have_htm_spr, have_htm_core>:
1365 New fields.
1366 <have_htm_fpu, have_htm_altivec, have_htm_vsx>:
1367 Likewise.
1368 <ppc_cppr_regnum, ppc_cdscr_regnum, ppc_ctar_regnum>: Likewise.
1369 <ppc_cdl0_regnum, ppc_cvsr0_regnum, ppc_cefpr0_regnum>: Likewise.
1370 (enum) <PPC_TFHAR_REGNUM, PPC_TEXASR_REGNUM, PPC_TFIAR_REGNUM>:
1371 New enum fields.
1372 <PPC_CR0_REGNUM, PPC_CCR_REGNUM, PPC_CXER_REGNUM>: Likewise.
1373 <PPC_CLR_REGNUM, PPC_CCTR_REGNUM, PPC_CF0_REGNUM>: Likewise.
1374 <PPC_CFPSCR_REGNUM, PPC_CVR0_REGNUM, PPC_CVSCR_REGNUM>: Likewise.
1375 <PPC_CVRSAVE_REGNUM, PPC_CVSR0_UPPER_REGNUM>: Likewise.
1376 <PPC_CPPR_REGNUM, PPC_CDSCR_REGNUM>: Likewise.
1377 <PPC_CTAR_REGNUM>: Likewise.
1378 (PPC_IS_TMSPR_REGNUM, PPC_IS_CKPTGP_REGNUM, PPC_IS_CKPTFP_REGNUM)
1379 (PPC_IS_CKPTVMX_REGNUM, PPC_IS_CKPTVSX_REGNUM): Define.
1380 * rs6000-tdep.c (IS_CDFP_PSEUDOREG, IS_CVSX_PSEUDOREG)
1381 (IS_CEFP_PSEUDOREG): Define.
1382 (rs6000_register_name): Hide the upper halves of checkpointed VSX
1383 registers. Return names for the checkpointed DFP, VSX, and EFP
1384 pseudo registers.
1385 (rs6000_pseudo_register_type): Remove initial assert and raise an
1386 internal error in the else clause instead. Return types for the
1387 checkpointed DFP, VSX, and EFP pseudo registers.
1388 (dfp_pseudo_register_read, dfp_pseudo_register_write): Handle
1389 checkpointed DFP pseudo registers.
1390 (vsx_pseudo_register_read, vsx_pseudo_register_write): Handle
1391 checkpointed VSX pseudo registers.
1392 (efp_pseudo_register_read, efp_pseudo_register_write): Rename
1393 from efpr_pseudo_register_read and
1394 efpr_pseudo_register_write. Handle checkpointed EFP pseudo
1395 registers.
1396 (rs6000_pseudo_register_read, rs6000_pseudo_register_write):
1397 Handle checkpointed DFP, VSX, and EFP registers.
1398 (dfp_ax_pseudo_register_collect, vsx_ax_pseudo_register_collect)
1399 (efp_ax_pseudo_register_collect): New functions.
1400 (rs6000_ax_pseudo_register_collect): Move DFP, VSX and EFP pseudo
1401 register logic to new functions. Handle checkpointed DFP, VSX,
1402 and EFP pseudo registers.
1403 (rs6000_gdbarch_init): Look for and validate the htm features.
1404 Include checkpointed DFP, VSX and EFP pseudo-registers.
1405 * NEWS: Mention access to PPR, DSCR, TAR, EBB/PMU registers and
1406 HTM registers.
1407
1408 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1409
1410 * rs6000-tdep.c (rs6000_gdbarch_init): Reject tdescs with vsx but
1411 without altivec or fpu.
1412
1413 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
1414 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1415
1416 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_EBBREGSET)
1417 (PPC_LINUX_SIZEOF_PMUREGSET): Declare.
1418 * nat/ppc-linux.h (PPC_FEATURE2_EBB, NT_PPC_EBB, NT_PPC_PMU):
1419 Define if not already defined.
1420 * features/rs6000/power-ebb.xml: New file.
1421 * features/rs6000/power-linux-pmu.xml: New file.
1422 * features/rs6000/powerpc-isa207-vsx32l.xml: Include ebb and pmu
1423 features.
1424 * features/rs6000/powerpc-isa207-vsx64l.xml: Likewise.
1425 * features/rs6000/powerpc-isa207-vsx32l.c: Re-generate.
1426 * features/rs6000/powerpc-isa207-vsx64l.c: Re-generate.
1427 * regformats/rs6000/powerpc-isa207-vsx32l.dat: Re-generate.
1428 * regformats/rs6000/powerpc-isa207-vsx64l.dat: Re-generate.
1429 * ppc-linux-nat.c (fetch_register, fetch_ppc_registers): Call
1430 fetch_regset with ebb and pmu regsets.
1431 (store_register, store_ppc_registers): Call store_regset with ebb
1432 and pmu regsets.
1433 (ppc_linux_nat_target::read_description): Set isa207 field in the
1434 features struct if ebb and pmu are avaiable.
1435 * ppc-linux-tdep.c (ppc32_regmap_ebb, ppc32_regmap_pmu)
1436 (ppc32_linux_ebbregset, ppc32_linux_pmuregset): New globals.
1437 (ppc_linux_iterate_over_regset_sections): Call back with the ebb
1438 and pmu regsets.
1439 (ppc_linux_core_read_description): Check if the pmu section is
1440 present and set isa207 in the features struct.
1441 * ppc-linux-tdep.h (ppc32_linux_ebbregset)
1442 (ppc32_linux_pmuregset): Declare.
1443 * ppc-tdep.h (struct gdbarch_tdep) <ppc_mmcr0_regnum>: New field.
1444 <ppc_mmcr2_regnum, ppc_siar_regnum, ppc_sdar_regnum>: New fields.
1445 <ppc_sier_regnum>: New field.
1446 (enum): <PPC_BESCR_REGNUM, PPC_EBBHR_REGNUM, PPC_EBBRR_REGNUM>:
1447 New enum values.
1448 <PPC_MMCR0_REGNUM, PPC_MMCR2_REGNUM, PPC_SIAR_REGNUM>: New enum
1449 values.
1450 <PPC_SDAR_REGNUM, PPC_SIER_REGNUM>: New enum values.
1451 (PPC_IS_EBB_REGNUM, PPC_IS_PMU_REGNUM): Define.
1452 * rs6000-tdep.c (rs6000_gdbarch_init): Look for and validate the
1453 ebb and pmu features.
1454
1455 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
1456 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1457
1458 * arch/ppc-linux-tdesc.h (tdesc_powerpc_isa207_vsx32l)
1459 (tdesc_powerpc_isa207_vsx64l): Declare.
1460 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_TARREGSET): Define.
1461 (struct ppc_linux_features) <isa207>: New field.
1462 (ppc_linux_no_features): Add initializer for isa207 field.
1463 * arch/ppc-linux-common.c (ppc_linux_match_description): Return
1464 new tdescs.
1465 * nat/ppc-linux.h (PPC_FEATURE2_ARCH_2_07, PPC_FEATURE2_TAR)
1466 (NT_PPC_TAR): Define if not already defined.
1467 * features/Makefile (WHICH): Add rs6000/powerpc-isa207-vsx32l and
1468 rs6000/powerpc-isa207-vsx64l.
1469 (XMLTOC): Add rs6000/powerpc-isa207-vsx32l.xml and
1470 rs6000/powerpc-isa207-vsx64l.xml.
1471 * features/rs6000/power-tar.xml: New file.
1472 * features/rs6000/powerpc-isa207-vsx32l.xml: New file.
1473 * features/rs6000/powerpc-isa207-vsx64l.xml: New file.
1474 * features/rs6000/powerpc-isa207-vsx32l.c: Generate.
1475 * features/rs6000/powerpc-isa207-vsx64l.c: Generate.
1476 * regformats/rs6000/powerpc-isa207-vsx32l.dat: Generate.
1477 * regformats/rs6000/powerpc-isa207-vsx64l.dat: Generate.
1478 * ppc-linux-nat.c (fetch_register, fetch_ppc_registers): Call
1479 fetch_regset with the TAR regset.
1480 (store_register, store_ppc_registers): Call store_regset with the
1481 TAR regset.
1482 (ppc_linux_nat_target::read_description): Set isa207 field in the
1483 features struct if needed.
1484 * ppc-linux-tdep.c: Include
1485 features/rs6000/powerpc-isa207-vsx32l.c and
1486 features/rs6000/powerpc-isa207-vsx64l.c.
1487 (ppc32_regmap_tar, ppc32_linux_tarregset): New globals.
1488 (ppc_linux_iterate_over_regset_sections): Call back with the tar
1489 regset.
1490 (ppc_linux_core_read_description): Check if the tar section is
1491 present and set isa207 in the features struct.
1492 (_initialize_ppc_linux_tdep): Call
1493 initialize_tdesc_powerpc_isa207_vsx32l and
1494 initialize_tdesc_powerpc_isa207_vsx64l.
1495 * ppc-linux-tdep.h (ppc32_linux_tarregset): Declare.
1496 * ppc-tdep.h (gdbarch_tdep) <ppc_tar_regnum>: New field.
1497 (enum) <PPC_TAR_REGNUM>: New enum value.
1498 * rs6000-tdep.c (rs6000_gdbarch_init): Look for and validate tar
1499 feature.
1500 (ppc_process_record_op31): Record changes to TAR.
1501
1502 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
1503 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1504
1505 * arch/ppc-linux-tdesc.h (tdesc_powerpc_isa205_ppr_dscr_vsx32l)
1506 (tdesc_powerpc_isa205_ppr_dscr_vsx64l): Declare.
1507 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_PPRREGSET)
1508 (PPC_LINUX_SIZEOF_DSCRREGSET): Define.
1509 (struct ppc_linux_features) <ppr_dscr>: New field.
1510 (ppc_linux_no_features): Add initializer for ppr_dscr field.
1511 * arch/ppc-linux-common.c (ppc_linux_match_description): Return
1512 new tdescs.
1513 * nat/ppc-linux.h (PPC_FEATURE2_DSCR, NT_PPC_PPR, NT_PPC_DSCR):
1514 Define if not already defined.
1515 * features/Makefile (WHICH): Add
1516 rs6000/powerpc-isa205-ppr-dscr-vsx32l and
1517 rs6000/powerpc-isa205-ppr-dscr-vsx64l.
1518 (XMLTOC): Add rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
1519 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml.
1520 * features/rs6000/power-dscr.xml: New file.
1521 * features/rs6000/power-ppr.xml: New file.
1522 * features/rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml: New file.
1523 * features/rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml: New file.
1524 * features/rs6000/powerpc-isa205-ppr-dscr-vsx32l.c: Generate.
1525 * features/rs6000/powerpc-isa205-ppr-dscr-vsx64l.c: Generate.
1526 * regformats/rs6000/powerpc-isa205-ppr-dscr-vsx32l.dat: Generate.
1527 * regformats/rs6000/powerpc-isa205-ppr-dscr-vsx64l.dat: Generate.
1528 * ppc-linux-nat.c: Include <sys/uio.h>.
1529 (fetch_regset, store_regset, check_regset): New functions.
1530 (fetch_register, fetch_ppc_registers): Call fetch_regset with
1531 DSCR and PPR regsets.
1532 (store_register, store_ppc_registers): Call store_regset with
1533 DSCR and PPR regsets.
1534 (ppc_linux_get_hwcap2): New function.
1535 (ppc_linux_nat_target::read_description): Call
1536 ppc_linux_get_hwcap2 and check_regset, set ppr_dscr field in the
1537 features struct if needed.
1538 * ppc-linux-tdep.c: Include
1539 features/rs6000/powerpc-isa205-ppr-dscr-vsx32l.c and
1540 features/rs6000/powerpc-isa205-ppr-dscr-vsx64l.c.
1541 (ppc32_regmap_ppr, ppc32_regmap_dscr, ppc32_linux_pprregset)
1542 (ppc32_linux_dscrregset): New globals.
1543 (ppc_linux_iterate_over_regset_sections): Call back with the ppr
1544 and dscr regsets.
1545 (ppc_linux_core_read_description): Check if the ppr and dscr
1546 sections are present and set ppr_dscr in the features struct.
1547 (_initialize_ppc_linux_tdep): Call
1548 initialize_tdesc_powerpc_isa205_ppr_dscr_vsx32l and
1549 initialize_tdesc_powerpc_isa205_ppr_dscr_vsx64l.
1550 * ppc-linux-tdep.h (ppc32_linux_pprregset)
1551 (ppc32_linux_dscrregset): Declare.
1552 * ppc-tdep.h (struct gdbarch_tdep) <ppc_ppr_regnum>: New field.
1553 <ppc_dscr_regnum>: New field.
1554 (enum) <PPC_PPR_REGNUM, PPC_DSCR_REGNUM>: New enum values.
1555 * rs6000-tdep.c (rs6000_gdbarch_init): Look for and validate ppr
1556 and dscr features.
1557 (ppc_process_record_op31): Record changes to PPR and DSCR.
1558
1559 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1560
1561 * rs6000-tdep.c (rs6000_gdbarch_init): Replace line wrapping by a
1562 second initializer line for the have_* variables. Initialize
1563 have_fpu to 0 instead of 1.
1564
1565 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1566
1567 * arch/ppc-linux-common.c (ppc_linux_match_description):
1568 Parenthesize tdesc assignements and indent them properly.
1569
1570 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1571
1572 * ppc-linux-nat.c (fetch_register): Change if statement to else
1573 if.
1574 (store_register): Likewise.
1575
1576 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1577
1578 * rs6000-tdep.c: Remove reggroups.h include.
1579 (rs6000_pseudo_register_reggroup_p): Remove.
1580 (rs6000_gdbarch_init): Remove call to
1581 set_tdesc_pseudo_register_reggroup_p.
1582
1583 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1584
1585 * reggroups.c (default_register_reggroup_p): Return true for
1586 decfloat registers and float_reggroup.
1587
1588 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1589
1590 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): Remove.
1591 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): Replace
1592 ppc_linux_collect_vrregset by regcache_collect_regset.
1593
1594 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1595
1596 * linux-tdep.c (linux_collect_regset_section_cb): Use
1597 std::vector<gdb_byte> instead of char * and malloc for buf.
1598 Remove xfree.
1599
1600 2018-10-26 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
1601
1602 * xcoffread.c (read_xcoff_symtab): Pass deduced language to
1603 symtab_start instead of always using language_unknown.
1604
1605 2018-10-26 Andrew Burgess <andrew.burgess@embecosm.com>
1606
1607 * riscv-tdep.c (riscv_read_misa_reg): Update comment, remove
1608 READ_P parameter, catch and ignore register access errors from
1609 either the old or new MISA location.
1610 (riscv_has_feature): Update call to riscv_read_misa_reg.
1611
1612 2018-10-25 Andrew Burgess <andrew.burgess@embecosm.com>
1613
1614 * python/py-function.c (convert_values_to_python): Return
1615 gdbpy_ref<>. Add header comment.
1616 (fnpy_call): Adjust.
1617
1618 2018-10-25 Andrew Burgess <andrew.burgess@embecosm.com>
1619
1620 * python/py-cmd.c (cmdpy_completer_helper): Return gdbpy_ref<>.
1621 (cmdpy_completer_handle_brkchars): Adjust.
1622 (cmdpy_completer): Adjust.
1623
1624 2018-10-25 Andrew Burgess <andrew.burgess@embecosm.com>
1625
1626 * riscv-linux-nat.c (riscv_linux_nat_target::fetch_registers):
1627 Pass correct regnum to raw_supply_zeroed.
1628
1629 2018-10-23 Hafiz Abid Qadeer <abidh@codesourcery.com>
1630
1631 * regcache.c (cooked_read_test): Add CSKY to the list of
1632 architectures with a save_reggroup
1633
1634 2018-10-23 Simon Marchi <simon.marchi@polymtl.ca>
1635
1636 PR gdb/23368
1637 * infrun.c (follow_exec): In the follow_exec_mode_new case,
1638 transfer terminal state from old new new inferior.
1639 * terminal.h (swap_terminal_info): New function.
1640 * inflow.c (swap_terminal_info): New function.
1641
1642 2018-10-23 Tom Tromey <tom@tromey.com>
1643
1644 * record-btrace.c (get_thread_current_frame_id): Rename from
1645 get_thread_current_frame. Return a frame_id.
1646 (record_btrace_start_replaying): Update.
1647
1648 2018-10-23 Andrew Burgess <andrew.burgess@embecosm.com>
1649
1650 * riscv-tdep.c (riscv_register_name): Use the user-friendly names
1651 for CSRs.
1652
1653 2018-10-23 Joel Brobecker <brobecker@adacore.com>
1654
1655 * riscv-tdep.c (riscv_gdbarch_init): Set the gdbarch's
1656 have_nonsteppable_watchpoint attribute to 1.
1657
1658 2018-10-23 Andrew Burgess <andrew.burgess@embecosm.com>
1659
1660 * riscv-tdep.c (riscv_gdb_reg_names): Update comment, and all
1661 register names.
1662 (struct register_alias): Rename to...
1663 (struct riscv_register_alias): ...this, and update comment.
1664 (riscv_register_aliases): Update type, and alias names. Remove
1665 CSR names from this list.
1666 (riscv_register_name): Use riscv_gdb_reg_names for int and float
1667 register names. Add an extra assertion.
1668 (riscv_is_regnum_a_named_csr): New function.
1669 (riscv_register_reggroup_p): Use riscv_is_regnum_a_named_csr.
1670
1671 2018-10-23 John Darrington <john@darrington.wattle.id.au>
1672
1673 * configure.tgt: Add configuration for s12z.
1674 * s12z-tdep.c: New file.
1675 * NEWS: Mention new target.
1676
1677 2018-10-22 Jim Wilson <jimw@sifive.com>
1678
1679 * riscv-tdep.c (riscv_push_dummy_call) <in_reg>: Check for value in
1680 FP reg smaller than FP reg size, and fill with -1 instead of 0.
1681
1682 * riscv-tdep.c (riscv_fpreg_d_type, riscv_fpreg_q_type): New.
1683 (riscv_register_type): Use them.
1684 (riscv_print_one_register_info): Handle union of floats same as float.
1685 * riscv-tdep.h (struct gdbarch_tdep): Add riscv_fpreg_d_type and
1686 riscv_fpreg_q_type fields.
1687
1688 2018-10-21 Simon Marchi <simon.marchi@ericsson.com>
1689
1690 * gdbarch.sh (gdbarch_num_cooked_regs): New.
1691 * gdbarch.h: Re-generate.
1692 * ax-gdb.c (gen_expr): Use gdbarch_num_cooked_regs.
1693 * dwarf2-frame.c (dwarf2_frame_cache): Likewise.
1694 * eval.c (evaluate_subexp_standard): Likewise.
1695 * findvar.c (value_of_register): Likewise.
1696 (value_of_register_lazy): Likewise.
1697 (address_from_register): Likewise.
1698 * frame.c (get_frame_register_bytes): Likewise.
1699 * gdbarch-selftests.c (register_to_value_test): Likewise.
1700 * h8300-tdep.c (h8300_register_type): Likewise.
1701 * i386-tdep.c (i386_dbx_reg_to_regnum): Likewise.
1702 (i386_svr4_reg_to_regnum): Likewise.
1703 * infcmd.c (default_print_registers_info): Likewise.
1704 (registers_info): Likewise.
1705 (print_vector_info): Likewise.
1706 (default_print_float_info): Likewise.
1707 * m68hc11-tdep.c (m68hc11_frame_unwind_cache): Likewise.
1708 * mdebugread.c (mdebug_reg_to_regnum): Likewise.
1709 * mi/mi-main.c (mi_cmd_data_list_register_names): Likewise.
1710 (mi_cmd_data_list_changed_registers): Likewise.
1711 (mi_cmd_data_list_register_values): Likewise.
1712 (mi_cmd_data_write_register_values): Likewise.
1713 (mi_cmd_trace_frame_collected): Likewise.
1714 * mips-tdep.c (print_gp_register_row): Likewise.
1715 (mips_print_registers_info): Likewise.
1716 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
1717 * regcache.c (init_regcache_descr): Likewise.
1718 (register_size): Likewise.
1719 (register_dump::dump): Likewise.
1720 (cooked_read_test): Likewise.
1721 (cooked_write_test): Likewise.
1722 * rs6000-tdep.c (rs6000_register_sim_regno): Likewise.
1723 (rs6000_gdbarch_init): Likewise.
1724 * stabsread.c (stab_reg_to_regnum): Likewise.
1725 * stack.c (info_frame_command): Likewise.
1726 * target-descriptions.c (tdesc_register_name): Likewise.
1727 * trad-frame.c (trad_frame_alloc_saved_regs): Likewise.
1728 * tui/tui-regs.c (tui_show_register_group): Likewise.
1729 * user-regs.c (user_reg_map_name_to_regnum): Likewise.
1730 (user_reg_map_regnum_to_name): Likewise.
1731 (value_of_user_reg): Likewise.
1732 (maintenance_print_user_registers): Likewise.
1733 * xtensa-tdep.c (xtensa_find_register_by_name): Likewise.
1734 (xtensa_register_name): Likewise.
1735 (xtensa_register_type): Likewise.
1736 (xtensa_reg_to_regnum): Likewise.
1737 (xtensa_pseudo_register_read): Likewise.
1738 (xtensa_pseudo_register_write): Likewise.
1739
1740 2018-10-21 Simon Marchi <simon.marchi@polymtl.ca>
1741
1742 * amd64-tdep.c (amd64_pseudo_register_read_value): Use
1743 correctly-sized buffer with raw_read.
1744 (amd64_pseudo_register_write): Use correctly-sized buffer for
1745 raw_read/raw_write.
1746
1747 2018-10-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1748
1749 * typeprint.c (_initialize_typeprint): Fix wrong prefixname arg
1750 in add_prefix_cmd of set print type.
1751
1752 2018-10-19 Tom Tromey <tom@tromey.com>
1753
1754 PR tui/18388:
1755 * NEWS: Mention tabset deprecation.
1756 * tui/tui-win.c (tui_tab_width, internal_tab_width): New globals.
1757 (update_tab_width): New function.
1758 (tui_set_tab_width, tui_show_tab_width): New functions.
1759 (tui_set_tab_width_command): Use update_tab_width.
1760 (_initialize_tui_win): Move to end of file. Deprecate "tabset".
1761 Add new "set tui tab-width" command.
1762 * tui/tui-source.c (tui_set_source_content): Update.
1763 * tui/tui-disasm.c (tui_set_disassem_content): Update.
1764 * tui/tui-data.h (tui_default_tab_len, tui_set_default_tab_len):
1765 Don't declare.
1766 (tui_tab_width): Declare.
1767 * tui/tui-data.c (default_tab_len, tui_default_tab_len)
1768 (tui_set_default_tab_len): Remove.
1769
1770 2018-10-19 Tom Tromey <tom@tromey.com>
1771
1772 * tui/tui-io.h (key_is_start_sequence, key_is_end_sequence)
1773 (key_is_backspace, tui_getc): Don't declare.
1774 * tui/tui-io.c (key_is_start_sequence): Now static.
1775 (key_is_end_sequence, key_is_backspace): Remove.
1776 (tui_getc): Now static.
1777
1778 2018-10-19 Tom Tromey <tom@tromey.com>
1779
1780 * symfile.c (reread_symbols): Clear "static_links".
1781
1782 2018-10-19 Alan Hayward <alan.hayward@arm.com>
1783
1784 * aarch64-linux-tdep.c (AARCH64_SIGCONTEXT_RESERVED_SIZE): New
1785 define.
1786 (aarch64_linux_sigframe_init): Extra boundary checks.
1787
1788 2018-10-19 Andreas Arnez <arnez@linux.ibm.com>
1789
1790 * s390-tdep.c (s390_pseudo_register_type): For v0-v15 don't yield
1791 the possibly non-existent tdesc type 'vec128', but the type of raw
1792 register v16 instead.
1793
1794 2018-10-19 Gary Benson <gbenson@redhat.com>
1795
1796 * cli/cli-interp.c (cli_interp::~cli_interp): New function.
1797
1798 2018-10-18 Sergio Durigan Junior <sergiodj@redhat.com>
1799
1800 PR cli/23785
1801 * cli/cli-dump.c (restore_binary_file): Check if "file" is
1802 NULL.
1803
1804 2018-10-17 Paul Koning <paul_koning@dell.com>
1805
1806 * charset.c (convert_between_encodings): Fix unsigned overflow.
1807
1808 2018-10-17 John Baldwin <jhb@FreeBSD.org>
1809
1810 * fbsd-nat.c (fbsd_nat_target::info_proc) Use
1811 fbsd_info_proc_mappings_header and fbsd_info_proc_mappings_entry.
1812 * fbsd-tdep.c (fbsd_vm_map_entry_flags): Mark static.
1813 (fbsd_info_proc_mappings_header, fbsd_info_proc_mappings_entry):
1814 New functions.
1815 (fbsd_core_info_proc_mappings): Use fbsd_info_proc_mappings_header
1816 and fbsd_info_proc_mappings_header.
1817 * fbsd-tdep.h (fbsd_vm_map_entry_flags): Remove.
1818 (fbsd_info_proc_mappings_header, fbsd_info_proc_mappings_entry):
1819 New.
1820
1821 2018-10-17 Joel Brobecker <brobecker@adacore.com>
1822
1823 * MAINTAINERS (Responsible Maintainers): Add Rainer Orth as
1824 Solaris Maintainer.
1825
1826 2018-10-15 Tom Tromey <tom@tromey.com>
1827
1828 * tui/tui.c (strcat_to_buf): Remove casts.
1829 * tui/tui-winsource.c (tui_show_source_line)
1830 (tui_set_is_exec_point_at, tui_line_is_displayed): Remove casts.
1831 * tui/tui-wingeneral.c (tui_refresh_win, box_win): Remove casts.
1832 * tui/tui-windata.c (tui_first_data_item_displayed)
1833 (tui_delete_data_content_windows, tui_erase_data_content)
1834 (tui_display_all_data, tui_display_data_from)
1835 (tui_refresh_data_win, tui_vertical_data_scroll): Remove casts.
1836 * tui/tui-win.c (tui_set_win_height)
1837 (make_invisible_and_set_new_height, parse_scrolling_args): Remove
1838 casts.
1839 * tui/tui-win.c (tui_resize_all): Remove casts.
1840 (tui_scroll_backward_command, tui_set_focus)
1841 (tui_set_tab_width_command): Likewise.
1842 * tui/tui-source.c (tui_vertical_source_scroll): Remove cast.
1843 * tui/tui-regs.c (tui_show_register_group): Remove cast.
1844 * tui/tui-layout.c (tui_set_layout_by_name): Remove cast.
1845 * tui/tui-disasm.c (tui_vertical_disassem_scroll): Remove cast.
1846 * tui/tui-data.c (tui_partial_win_by_name, tui_free_win_content):
1847 Remove casts.
1848
1849 2018-10-15 Simon Marchi <simon.marchi@ericsson.com>
1850
1851 * MAINTAINERS (Responsible Maintainers): Add Alan Hayward as
1852 AArch64/ARM maintainer.
1853
1854 2018-10-11 Gary Benson <gbenson@redhat.com>
1855
1856 * interps.h (interp::m_name): Make private and mutable.
1857 * interps.c (interp::~interp): Free m_name.
1858
1859 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
1860 Simon Marchi <simark@simark.ca>
1861
1862 * README (`configure' options): Add documentation for new
1863 "--enable-unit-tests" option.
1864 * acinclude.m4: Include "selftest.m4".
1865 * configure: Regenerate.
1866 * configure.ac: Use "GDB_AC_SELFTEST".
1867 * maint.c (maintenance_selftest): Update message informing
1868 that selftests have been disabled.
1869 (maintenance_info_selftests): Likewise.
1870 * selftest.m4: New file.
1871
1872 2018-10-10 Gary Benson <gbenson@redhat.com>
1873
1874 * remote.c (remote_target::remote_send_printf): Add
1875 missing va_end found by Coverity.
1876
1877 2018-10-10 Markus Metzger <markus.t.metzger@intel.com>
1878
1879 * btrace.c (ftrace_update_function): Add indirect jump heuristic.
1880
1881 2018-10-09 Tom Tromey <tom@tromey.com>
1882
1883 * configure: Rebuild.
1884 * sanitize.m4 (AM_GDB_UBSAN): Default to no.
1885 * NEWS: Update --enable-ubsan documentation.
1886
1887 2018-10-09 Gary Benson <gbenson@redhat.com>
1888
1889 * dwarf2read.c (create_dwp_hash_table): Fix buffer overrun
1890 found by Coverity.
1891
1892 2018-10-08 Tom Tromey <tom@tromey.com>
1893
1894 * riscv-fbsd-tdep.c (riscv_fbsd_sigframe_init): Remove unused
1895 variable.
1896 (riscv_fbsd_init_abi): Likewise.
1897
1898 2018-10-08 Weimin Pan <weimin.pan@oracle.com>
1899 * valops.c (value_struct_elt_for_reference): Rename local variable
1900 to work around the shadowing a previous local warning.
1901
1902 2018-10-08 John Baldwin <jhb@FreeBSD.org>
1903
1904 * Makefile.in (ALLDEPFILES): Add riscv-fbsd-nat.c.
1905 * NEWS: Mention new FreeBSD/riscv native configuration.
1906 * configure.host: Add riscv*-*-freebsd*.
1907 * configure.nat: Likewise.
1908 * riscv-fbsd-nat.c: New file.
1909
1910 2018-10-08 John Baldwin <jhb@FreeBSD.org>
1911
1912 * Makefile.in (ALL_TARGET_OBS): Add riscv-fbsd-tdep.o.
1913 (HFILES_NO_SRCDIR): Add riscv-fbsd-tdep.h.
1914 (ALLDEPFILES): Add riscv-fbsd-tdep.c.
1915 * NEWS: Mention new FreeBSD/riscv target.
1916 * configure.tgt: Add riscv*-*-freebsd*.
1917 * riscv-fbsd-tdep.c: New file.
1918 * riscv-fbsd-tdep.h: New file.
1919
1920 2018-10-08 John Baldwin <jhb@FreeBSD.org>
1921
1922 * regcache.h (struct regcache_map_entry): Note that this type can
1923 be used with traditional frame caches.
1924 * trad-frame.c (trad_frame_set_reg_regmap): New.
1925 * trad-frame.h (trad_frame_set_reg_regmap): New.
1926
1927 2018-10-08 Weimin Pan <weimin.pan@oracle.com>
1928
1929 PR c++/16841
1930 * valops.c (get_virtual_base_offset): New function.
1931 (value_struct_elt_for_reference): Use it to get virtual base offset
1932 and add it in calculating class member address.
1933
1934 2018-10-08 John Darrington <john@darrington.wattle.id.au>
1935
1936 * dwarf2read.c (dwarf2_cu) <producer_is_codewarrior>: New field.
1937 (check_producer): Check if the producer is codewarrior.
1938 (producer_is_codewarrior): New function.
1939 (lnp_state_machine::record_line): Ignore is_stmt flag for records
1940 produced by codewarrior.
1941 (dwarf2_cu::dwarf2_cu): Initialize producer_is_codewarrior.
1942
1943 2018-10-06 Tom Tromey <tom@tromey.com>
1944
1945 PR python/19399:
1946 * python/py-inferior.c: Add "architecture" entry.
1947 (infpy_architecture): New function.
1948
1949 2018-10-06 Tom Tromey <tom@tromey.com>
1950
1951 PR python/21765:
1952 * python/py-symbol.c (gdbpy_initialize_symbols): Redefine
1953 SYMBOL_VARIABLES_DOMAIN, SYMBOL_FUNCTIONS_DOMAIN,
1954 SYMBOL_TYPES_DOMAIN. Define SYMBOL_MODULE_DOMAIN,
1955 SYMBOL_COMMON_BLOCK_DOMAIN, SYMBOL_LOC_COMMON_BLOCK.
1956
1957 2018-10-06 Tom Tromey <tom@tromey.com>
1958
1959 PR build/17077:
1960 * Makefile.in (OPCODES_CFLAGS): Remove "-I$(OPCODES_SRC)/..".
1961 * arc-tdep.c, frv-tdep.c, lm32-tdep.c, mep-tdep.c,
1962 microblaze-tdep.c, or1k-tdep.h: Use ../opcodes, not opcodes, in
1963 #include.
1964
1965 2018-10-06 Tom Tromey <tom@tromey.com>
1966
1967 * python/py-breakpoint.c (bppy_get_location): Handle a
1968 bp_breakpoint without a location.
1969
1970 2018-10-06 Tom Tromey <tom@tromey.com>
1971
1972 * python/lib/gdb/function/strfns.py (_MemEq, _StrLen, _StrEq)
1973 (_RegEx): Reformat help text.
1974 * python/lib/gdb/function/caller_is.py (CallerIs, CallerMatches)
1975 (AnyCallerIs, AnyCallerMatches): Reformat help text.
1976 * python/lib/gdb/function/as_string.py (_AsString): Reformat help
1977 text.
1978 * python/lib/gdb/command/xmethods.py (InfoXMethod)
1979 (EnableXMethod, DisableXMethod): Remove help indentation.
1980 Capitalize meta-syntactic variables.
1981 * python/lib/gdb/command/unwinders.py (InfoUnwinder)
1982 (EnableUnwinder, DisableUnwinder): Remove help indentation.
1983 Capitalize meta-syntactic variables.
1984 * python/lib/gdb/command/explore.py (ExploreCommand)
1985 (ExploreValueCommand, ExploreTypeCommand): Reformat help text.
1986 * python/lib/gdb/command/type_printers.py (InfoTypePrinter)
1987 (EnableTypePrinter, DisableTypePrinter): Remove help indentation.
1988 * python/lib/gdb/command/pretty_printers.py (InfoPrettyPrinter):
1989 Remove help indentation.
1990 (EnablePrettyPrinter, DisablePrettyPrinter): Likewise.
1991 * python/lib/gdb/command/frame_filters.py (EnableFrameFilter)
1992 (DisableFrameFilter, SetFrameFilterPriority)
1993 (ShowFrameFilterPriority, InfoFrameFilter): Reword help text.
1994
1995 2018-10-06 Tom Tromey <tom@tromey.com>
1996
1997 PR tui/28819:
1998 * tui/tui-io.c (gdb_wgetch): New function.
1999 (tui_mld_getc, tui_getc): Use it.
2000
2001 2018-10-05 Tom Tromey <tom@tromey.com>
2002
2003 * sol-thread.c (sol_thread_target::wait): Rename inner
2004 "save_ptid".
2005
2006 2018-10-04 Tom Tromey <tom@tromey.com>
2007
2008 * configure: Rebuild.
2009 * warning.m4 (AM_GDB_WARNINGS): Add -Wshadow=local.
2010
2011 2018-10-04 Tom Tromey <tom@tromey.com>
2012
2013 * guile/scm-frame.c (gdbscm_frame_read_var): Remove inner
2014 declaration of "block".
2015
2016 2018-10-04 Tom Tromey <tom@tromey.com>
2017
2018 * common/filestuff.c (fdwalk): Remove inner declaration of
2019 "result".
2020
2021 2018-10-04 Tom Tromey <tom@tromey.com>
2022
2023 * msp430-tdep.c (msp430_push_dummy_call): Rename inner
2024 "structs_addr" and hoist declaration.
2025
2026 2018-10-04 Tom Tromey <tom@tromey.com>
2027
2028 * linux-tdep.c (linux_make_mappings_corefile_notes): Introduce new
2029 variable "size".
2030
2031 2018-10-04 Tom Tromey <tom@tromey.com>
2032
2033 * mdebugread.c (parse_partial_symbols): Use std::string.
2034
2035 2018-10-04 Tom Tromey <tom@tromey.com>
2036
2037 * ctf.c (SET_ARRAY_FIELD): Rename "u32".
2038 * p-valprint.c (pascal_val_print): Split inner "i" variable.
2039 * xtensa-tdep.c (xtensa_push_dummy_call): Declare "i" in loop
2040 header.
2041 * xstormy16-tdep.c (xstormy16_push_dummy_call): Declare "val" in
2042 more inner scope.
2043 * xcoffread.c (read_xcoff_symtab): Rename inner "symbol".
2044 * varobj.c (varobj_update): Rename inner "newobj",
2045 "type_changed".
2046 * valprint.c (generic_emit_char): Rename inner "buf".
2047 * valops.c (find_overload_match): Rename inner "temp".
2048 (value_struct_elt_for_reference): Declare "v" in more inner
2049 scope.
2050 * v850-tdep.c (v850_push_dummy_call): Rename "len".
2051 * unittests/array-view-selftests.c (run_tests): Rename inner
2052 "vec".
2053 * tui/tui-stack.c (tui_show_frame_info): Declare "i" in loop
2054 header.
2055 * tracepoint.c (merge_uploaded_trace_state_variables): Declare
2056 "tsv" in more inner scope.
2057 (print_one_static_tracepoint_marker): Rename inner
2058 "tuple_emitter".
2059 * tic6x-tdep.c (tic6x_analyze_prologue): Declare "inst" lower.
2060 (tic6x_push_dummy_call): Don't redeclare "addr".
2061 * target-float.c: Declare "dto" lower.
2062 * symtab.c (lookup_local_symbol): Rename inner "sym".
2063 (find_pc_sect_line): Rename inner "pc".
2064 * stack.c (print_frame): Don't redeclare "gdbarch".
2065 (return_command): Rename inner "gdbarch".
2066 * s390-tdep.c (s390_prologue_frame_unwind_cache): Renam inner
2067 "sp".
2068 * rust-lang.c (rust_internal_print_type): Declare "i" in loop
2069 header.
2070 * rs6000-tdep.c (ppc_process_record): Rename inner "addr".
2071 * riscv-tdep.c (riscv_push_dummy_call): Declare "info" in inner
2072 scope.
2073 * remote.c (remote_target::update_thread_list): Don't redeclare
2074 "tp".
2075 (remote_target::process_initial_stop_replies): Rename inner
2076 "thread".
2077 (remote_target::remote_parse_stop_reply): Don't redeclare "p".
2078 (remote_target::wait_as): Don't redeclare "stop_reply".
2079 (remote_target::get_thread_local_address): Rename inner
2080 "result".
2081 (remote_target::get_tib_address): Likewise.
2082
2083 * regcache.c (cooked_read_test): Rename "regnum".
2084 * record-btrace.c (cmd_record_btrace_start): Rename inner
2085 "exception".
2086 * ppc-sysv-tdep.c (ppc64_sysv_abi_return_value): Declare "i" in
2087 loop header.
2088 * ppc-linux-tdep.c (ppc_linux_syscall_record): Declare "i" in loop
2089 header.
2090 (ppu2spu_sniffer): Rename inner "buf".
2091 * parse.c (operator_check_standard): Rename inner "type",
2092 "objfile".
2093 * p-valprint.c (pascal_val_print): Introduce new scope for
2094 "low_bound", "high_bound".
2095 * p-exp.y (yylex): Declare "i" in loop header.
2096 * objfiles.c (objfile_relocate1): Declare "i" in loop header.
2097 Lower declaration of "s".
2098 * nios2-tdep.c (nios2_analyze_prologue): Declare "i" in loop
2099 header.
2100 (nios2_push_dummy_call): Rename "len".
2101 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Rename static
2102 "buf".
2103 (linux_xfer_osdata_fds, linux_xfer_osdata_shm)
2104 (linux_xfer_osdata_sem, linux_xfer_osdata_msg)
2105 (linux_xfer_osdata_modules): Likewise.
2106 * mips-tdep.c (mips_eabi_push_dummy_call): Rename outer "len".
2107 (mips_n32n64_push_dummy_call, mips_o32_push_dummy_call)
2108 (mips_o64_push_dummy_call): Likewise.
2109 * microblaze-tdep.c (microblaze_analyze_prologue): Rename inner
2110 "op".
2111 * mi/mi-main.c (list_available_thread_groups): Rename inner
2112 "tuple_emitter".
2113 (mi_cmd_data_read_memory): Rename inner "opts".
2114 * mi/mi-cmd-var.c (varobj_update_one): Rename inner
2115 "tuple_emitter".
2116 * mep-tdep.c (mep_analyze_prologue): Declare "rn" in loop header.
2117 * mdebugread.c (parse_symbol): Rename inner "b". Declare "f" in
2118 more inner scope.
2119 (parse_partial_symbols): Rename inner "pst", "p", "name"
2120 * main.c (captured_main_1): Rename inner "i"s.
2121 * machoread.c (macho_symfile_read_all_oso): Don't redeclare
2122 "oso2".
2123 * linux-tdep.c (linux_info_proc): Rename inner "filename".
2124 * linespec.c (linespec_lexer_lex_string): Rename inner "p".
2125 * infrun.c (handle_no_resumed): Don't redeclare "thread".
2126 (handle_signal_stop): Rename inner "gdbarch".
2127 (handle_command): Declare "signum" in loop header.
2128 * ia64-tdep.c (ia64_pseudo_register_read): Don't redeclare
2129 "status".
2130 (examine_prologue): Rename inner "sol" and "sof".
2131 (ia64_extract_return_value): Rename inner "val". Declare another
2132 "val" in a more inner scope.
2133 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Declare "buf" in
2134 inner scope.
2135 * guile/scm-symbol.c (gdbscm_lookup_symbol): Rename inner
2136 "except".
2137 * findvar.c (default_read_var_value): Don't redeclare "addr".
2138 * f-exp.y (yylex): Declare "i" in loop header.
2139 * eval.c (evaluate_subexp_standard): Don't redeclare "type".
2140 Rename inner "type", "expect_type".
2141 (evaluate_subexp_for_sizeof): Rename inner "pc".
2142 * elfread.c (elf_symfile_read): Rename inner "abfd".
2143 * dwarf2read.c (read_debug_names_from_section): Don't redeclare
2144 "bytes_read".
2145 (process_psymtab_comp_unit_reader): Don't redeclare "gdbarch".
2146 (add_partial_subprogram): Rename inner "lowpc" and "highpc".
2147 (dwarf_decode_line_header): Rename inner "lh".
2148 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Don't redeclare
2149 "offset". Declare "i" in loop header.
2150 (disassemble_dwarf_expression): Rename inner "addr_size".
2151 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Rename
2152 inner "result".
2153 (dwarf_expr_context::execute_stack_op): Rename inner "offset".
2154 * dwarf2-frame.c (decode_frame_entry_1): Rename inner "length"s.
2155 * disasm.c (do_mixed_source_and_assembly_deprecated): Rename inner
2156 "inner_list_emitter".
2157 (do_mixed_source_and_assembly): Rename inner "tuple_emitter".
2158 * disasm-selftests.c (print_one_insn_test): Wrap "bplen"
2159 declaration in a block.
2160 * csky-tdep.c (csky_analyze_prologue): Declare "offset" lower.
2161 * cp-valprint.c (cp_print_value_fields): Don't redeclare
2162 "obstack_final_size".
2163 * cp-support.c (inspect_type): Declare "i" in loop header.
2164 * compile/compile.c (compile_instance::insert_symbol_error):
2165 Rename inner "e".
2166 * common/agent.c (agent_run_command): Remove inner "ret"
2167 declaration.
2168 * coffread.c (coff_symfile_read): Rename inner "name".
2169 (coff_symfile_read): Rename inner "abfd".
2170 * cli/cli-utils.c (get_number_trailer): Rename inner "val".
2171 * cli/cli-cmds.c (print_disassembly): Rename inner "low" and
2172 "high".
2173 * c-exp.y (lex_one_token): Move "len" declaration lower.
2174 * breakpoint.c (create_longjmp_master_breakpoint): Don't redeclare
2175 "gdbarch".
2176 (create_exception_master_breakpoint): Likewise. Don't redeclare
2177 "b".
2178 (watch_command_1): Declare "mark" later.
2179 (clear_command): Don't shadow "a" or "b".
2180 (delete_command): Rename inner "b".
2181 (delete_trace_command): Likewise.
2182 * arm-tdep.c (thumb_process_displaced_32bit_insn): Rename inner
2183 "op".
2184 (arm_gdbarch_init): Remove inner "e_flags".
2185 * arch/arm-get-next-pcs.c (thumb_get_next_pcs_raw): Declare
2186 "offset" in inner blocks.
2187
2188 2018-10-04 Simon Marchi <simon.marchi@ericsson.com>
2189
2190 * dwarf-index-write.c (file_write): Don't write if the vector is
2191 empty.
2192
2193 2018-10-05 Tom de Vries <tdevries@suse.de>
2194
2195 * python/py-progspace.c (pspy_solib_name): Fix type mismatch in
2196 PyArg_ParseTuple call.
2197
2198 2018-10-05 Tom de Vries <tdevries@suse.de>
2199
2200 * python/py-record-btrace.c (recpy_bt_goto): Fix type mismatch in
2201 PyArg_ParseTuple call.
2202
2203 2018-10-04 Joel Brobecker <brobecker@adacore.com>
2204
2205 * psymtab.c (recursively_search_psymtabs): Reformat parameters
2206 to avoid exceeding 80 characters per line limit.
2207
2208 2018-10-04 Tom Tromey <tom@tromey.com>
2209
2210 * symfile.c (syms_from_objfile_1, finish_new_objfile)
2211 (reread_symbols): Update.
2212 * complaints.h (clear_complaints): Remove argument.
2213 * complaints.c (enum complaint_series): Remove.
2214 (series): Remove global.
2215 (complaint_internal): Update.
2216 (clear_complaints): Remove argument.
2217
2218 2018-10-04 Tom Tromey <tom@tromey.com>
2219
2220 * symfile.c (symbol_file_add_with_addrs): Do not print "no
2221 debugging symbols" message if there is a separate debug objfile.
2222
2223 2018-10-04 Tom Tromey <tom@tromey.com>
2224
2225 PR cli/19551:
2226 * symfile.c (symbol_file_add_with_addrs): Update output.
2227 * psymtab.c (require_partial_symbols): Update output.
2228
2229 2018-10-04 Tom Tromey <tom@tromey.com>
2230
2231 PR cli/22234:
2232 * complaints.c: Emit \n.
2233
2234 2018-10-04 Tom Tromey <tom@tromey.com>
2235
2236 * symfile.c (symbol_file_add_with_addrs, symbol_file_clear)
2237 (separate_debug_file_exists, find_separate_debug_file)
2238 (add_symbol_file_command, reread_symbols, allocate_symtab)
2239 (allocate_compunit_symtab): Use filtered printing, not
2240 unfiltered.
2241 * psymtab.c (require_partial_symbols, dump_psymtab)
2242 (allocate_psymtab): Use filtered printing, not unfiltered.
2243
2244 2018-10-04 Tom Tromey <tom@tromey.com>
2245
2246 * complaints.c (complaint_internal): Correctly check complaint
2247 count.
2248
2249 2018-10-04 Tom Tromey <tom@tromey.com>
2250
2251 * complaints.h (struct complaints): Remove declaration.
2252 * complaints.c (clear_complaints): Remove an unused variable.
2253
2254 2018-10-04 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2255
2256 * MAINTAINERS (Write After Approval): Add self.
2257
2258 2018-10-03 Tom Tromey <tom@tromey.com>
2259
2260 * guile/scm-value.c (gdbscm_value_to_string): Initialize
2261 "buffer_contents".
2262 * coffread.c (coff_symtab_read): Initialize "newobj".
2263
2264 2018-10-03 Simon Marchi <simon.marchi@polymtl.ca>
2265
2266 * dwarf2read.c (read_func_scope): Remove struct keyword in
2267 range-based for.
2268
2269 2018-10-03 Tom Tromey <tom@tromey.com>
2270
2271 * README: Mention --enable-ubsan.
2272 * NEWS: Mention --enable-ubsan.
2273 * acinclude.m4: Include sanitize.m4.
2274 * configure: Rebuild.
2275 * configure.ac: Call AM_GDB_UBSAN.
2276 * sanitize.m4: New file.
2277
2278 2018-10-03 Tom Tromey <tom@tromey.com>
2279
2280 * expression.h (enum exp_opcode): Use uint8_t as base type.
2281 * expprint.c (op_name): Handle invalid opcodes.
2282
2283 2018-10-03 Tom Tromey <tom@tromey.com>
2284
2285 * parse.c (prefixify_expression): Add assert.
2286 (parse_exp_in_context_1): Throw exception if the expression is
2287 empty.
2288
2289 2018-10-03 Tom Tromey <tom@tromey.com>
2290
2291 * dwarf2read.c (read_signed_leb128): Work in ULONGEST.
2292
2293 2018-10-03 Tom Tromey <tom@tromey.com>
2294
2295 * c-exp.y (parse_number): Work in unsigned. Remove casts.
2296
2297 2018-10-03 Tom Tromey <tom@tromey.com>
2298
2299 * dwarf2read.c (read_subrange_type): Make "negative_mask"
2300 unsigned.
2301
2302 2018-10-03 Tom Tromey <tom@tromey.com>
2303
2304 * findvar.c (extract_integer): Do work in an unsigned type.
2305
2306 2018-10-03 Tom Tromey <tom@tromey.com>
2307
2308 * common/enum-flags.h (enum_flags::operator~): Add static assert.
2309 * symfile-add-flags.h (enum symfile_add_flag): Use unsigned as
2310 base type.
2311 * objfile-flags.h (enum objfile_flag): Use unsigned as base type.
2312 * gdbtypes.h (enum type_instance_flag_value): Use unsigned as base
2313 type.
2314 * c-lang.h (enum c_string_type_values): Use unsigned as base
2315 type.
2316 * btrace.h (enum btrace_thread_flag): Use unsigned as base type.
2317
2318 2018-10-03 Tom Tromey <tom@tromey.com>
2319
2320 * dwarf2-frame.h (dwarf2_frame_state_reg_info)
2321 <~dwarf2_frame_state_reg_info>: Update.
2322 <dwarf2_frame_state_reg_info>: Update.
2323 <alloc_regs>: Add assertion. Update.
2324 <reg>: Now a std::vector.
2325 <num_regs>: Remove.
2326 <swap>: Update.
2327 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
2328 (execute_cfa_program_test, dwarf2_frame_cache): Update.
2329
2330 2018-10-03 Tom Tromey <tom@tromey.com>
2331
2332 * namespace.c (add_using_directive): Don't pass NULL to memcpy.
2333
2334 2018-10-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2335
2336 * tid-parse.c (tid_is_in_list): Fix wrong 'See' comment.
2337
2338 2018-10-02 Tom Tromey <tom@tromey.com>
2339
2340 * aarch64-linux-tdep.c (aarch64_linux_sigframe_init): Use pulongest.
2341
2342 2018-10-02 John Darrington <john@darrington.wattle.id.au>
2343
2344 * NEWS: Mention changed commands.
2345 * ser-uds.c: New file.
2346 * configure.ac (SER_HARDWIRE): Add ser-uds.o.
2347 * configure: Regenerate.
2348 * Makefile.in: Add new file.
2349 * serial.c (serial_open): Check if filename is a socket
2350 and lookup the appropriate interface accordingly.
2351
2352 2018-10-01 Alan Hayward <alan.hayward@arm.com>
2353
2354 * aarch64-linux-tdep.c (AARCH64_SIGCONTEXT_RESERVED_OFFSET): Add
2355 define.
2356 (AARCH64_EXTRA_MAGIC): Likewise.
2357 (AARCH64_FPSIMD_MAGIC): Likewise.
2358 (AARCH64_SVE_MAGIC): Likewise.
2359 (AARCH64_EXTRA_DATAP_OFFSET): Likewise.
2360 (AARCH64_FPSIMD_FPSR_OFFSET): Likewise.
2361 (AARCH64_FPSIMD_FPCR_OFFSET): Likewise.
2362 (AARCH64_FPSIMD_V0_OFFSET): Likewise.
2363 (AARCH64_FPSIMD_VREG_SIZE): Likewise.
2364 (AARCH64_SVE_CONTEXT_VL_OFFSET): Likewise.
2365 (AARCH64_SVE_CONTEXT_REGS_OFFSET): Likewise.
2366 (AARCH64_SVE_CONTEXT_P_REGS_OFFSET): Likewise.
2367 (AARCH64_SVE_CONTEXT_FFR_OFFSET): Likewise.
2368 (AARCH64_SVE_CONTEXT_SIZE): Likewise.
2369 (read_aarch64_ctx): Add function.
2370 (aarch64_linux_sigframe_init): Detect FP registers.
2371
2372 2018-10-01 Alan Hayward <alan.hayward@arm.com>
2373
2374 * aarch64-tdep.c (AARCH64_Q0_REGNUM): Move to here.
2375 (AARCH64_D0_REGNUM): Likewise.
2376 (AARCH64_S0_REGNUM): Likewise.
2377 (AARCH64_H0_REGNUM): Likewise.
2378 (AARCH64_B0_REGNUM): Likewise.
2379 (AARCH64_SVE_V0_REGNUM): Likewise.
2380 * arch/aarch64.h (AARCH64_Q0_REGNUM): Move from here.
2381 (AARCH64_D0_REGNUM): Likewise.
2382 (AARCH64_S0_REGNUM): Likewise.
2383 (AARCH64_H0_REGNUM): Likewise.
2384 (AARCH64_B0_REGNUM): Likewise.
2385 (AARCH64_SVE_V0_REGNUM): Likewise.
2386
2387 2018-10-01 Gary Benson <gbenson@redhat.com>
2388
2389 * gdb_proc_service.h (gdb_prfpregset_t): Remove typedef.
2390 * proc-service.c (ps_lgetfpregs, ps_lsetfpregs): Use
2391 prfpregset_t instead of gdb_prfpregset_t.
2392 * configure.ac (PRFPREGSET_T_BROKEN): Remove check.
2393 * configure, config.in: Rebuild.
2394
2395 2018-10-01 Gary Benson <gbenson@redhat.com>
2396
2397 * common/gdb_proc_service.h: New file, factored out from...
2398 * gdb_proc_service.h: Moved common code to the above file.
2399 * Makefile.in (HFILES_NO_SRCDIR): Add the above new file.
2400
2401 2018-10-01 Gary Benson <gbenson@redhat.com>
2402
2403 * gdb_proc_service.h: Use elf_gregset_t if prgregset_t is
2404 undefined. Use elf_fpregset_t if prfpregset_t is undefined.
2405
2406 2018-10-01 Gary Benson <gbenson@redhat.com>
2407
2408 * configure.ac: Check if sys/procfs.h defines elf_fpregset_t.
2409 (AC_CHECK_HEADERS): Check for linux/elf.h.
2410 * configure, config.in: Rebuild.
2411 * gdb_proc_service.h: Include linux/elf.h if sys/procfs.h
2412 doesn't define elf_fpregset_t.
2413
2414 2018-10-01 Gary Benson <gbenson@redhat.com>
2415
2416 * gdb_proc_service.h: Whitespace change.
2417
2418 2018-10-01 Tom Tromey <tom@tromey.com>
2419
2420 * unittests/scoped_mmap-selftests.c: Don't check HAVE_UNISTD_H.
2421 * unittests/scoped_fd-selftests.c: Don't check HAVE_UNISTD_H.
2422 * common/scoped_fd.h: Don't check HAVE_UNISTD_H.
2423
2424 2018-10-01 Tom Tromey <tom@tromey.com>
2425
2426 * README: Minor change.
2427
2428 2018-09-30 Pedro Alves <palves@redhat.com>
2429
2430 * darwin-nat-info.c (darwin_debug_regions_recurse)
2431 (info_mach_exceptions_command): Remove unused local variables.
2432 * darwin-nat.c (darwin_decode_notify_message)
2433 (darwin_nat_target::resume, darwin_nat_target::mourn_inferior)
2434 (darwin_stop_inferior, darwin_setup_exceptions)
2435 (darwin_nat_target::kill, darwin_attach_pid, darwin_ptrace_him)
2436 (darwin_nat_target::attach, darwin_nat_target::detach)
2437 (darwin_read_write_inferior, darwin_read_dyld_info): Remove unused
2438 local variables.
2439 * i386-darwin-nat.c (i386_darwin_dr_set): Remove unused local
2440 variables.
2441
2442 2018-09-29 Tom Tromey <tom@tromey.com>
2443
2444 * README: Remove some leftover text.
2445
2446 2018-09-29 Tom Tromey <tom@tromey.com>
2447
2448 * PROBLEMS: Rewrite.
2449 * README: Update.
2450
2451 2018-09-28 John Baldwin <jhb@FreeBSD.org>
2452
2453 * disasm-selftests.c (print_one_insn_test): Add bfd_arch_riscv to
2454 case with explicit breakpoint kind.
2455 * riscv-tdep.c (show_use_compressed_breakpoints): Remove
2456 'additional_info' and related logic.
2457 (riscv_debug_breakpoints): New variable.
2458 (riscv_breakpoint_kind_from_pc): Use the length of the existing
2459 instruction to determine the breakpoint kind.
2460 (_initialize_riscv_tdep): Add 'set/show debug riscv breakpoints'
2461 flag. Update description of 'set/show riscv
2462 use-compressed-breakpoints' flag.
2463
2464 2018-09-28 Andrew Burgess <andrew.burgess@embecosm.com>
2465
2466 (NEWS): Mention changes to frame related commands.
2467 * cli/cli-decode.c (add_cmd_suppress_notification): New function.
2468 (add_prefix_cmd_suppress_notification): New function.
2469 (add_com_suppress_notification): Call
2470 add_cmd_suppress_notification.
2471 * command.h (add_cmd_suppress_notification): Declare.
2472 (add_prefix_cmd_suppress_notification): Declare.
2473 * mi/mi-cmd-stack.c: Add 'safe-ctype.h' include.
2474 (parse_frame_specification): Moved from stack.c, with
2475 simplification to handle a single argument.
2476 (mi_cmd_stack_select_frame): Use parse_frame_specification, the
2477 switch to the selected frame. Add a header comment.
2478 * stack.c: Remove 'safe-ctype.h' include.
2479 (find_frame_for_function): Add declaration.
2480 (find_frame_for_address): New function.
2481 (parse_frame_specification): Moved into mi/mi-cmd-stack.c.
2482 (frame_selection_by_function_completer): New function.
2483 (info_frame_command): Rename to...
2484 (info_frame_command_core): ...this, and update parameter types.
2485 (select_frame_command): Rename to...
2486 (select_frame_command_core): ...this, and update parameter types.
2487 (frame_command): Rename to...
2488 (frame_command_core): ...this, and update parameter types.
2489 (class frame_command_helper): New class to wrap implementations of
2490 frame related sub-commands.
2491 (frame_apply_cmd_list): New static global.
2492 (frame_cmd_list): Make static.
2493 (select_frame_cmd_list): New global for sub-commands.
2494 (info_frame_cmd_list): New global for sub-commands.
2495 (_initialize_stack): Register sub-commands for 'frame',
2496 'select-frame', and 'info frame'. Update 'frame apply' commands
2497 to use frame_apply_cmd_list. Move function local static
2498 frame_apply_list to file static frame_apply_cmd_list for
2499 consistency.
2500 * stack.h (select_frame_command): Delete declarationn.
2501 (select_frame_for_mi): Declare new function.
2502
2503 2018-09-26 Andrew Burgess <andrew.burgess@embecosm.com>
2504
2505 * riscv-tdep.c (riscv_insn::decode): Decode c.lui.
2506 (riscv_scan_prologue): Split handling of AUIPC, LUI, ADD, ADDI,
2507 and NOP.
2508
2509 2018-09-26 Simon Marchi <simon.marchi@ericsson.com>
2510
2511 * elf32-nds32.c (elf32_nds32_allocate_dynrelocs): Remove.
2512
2513 2018-09-26 Tom Tromey <tom@tromey.com>
2514
2515 * valops.c (auto_abandon): Remove dead code.
2516
2517 2018-09-26 Tom Tromey <tom@tromey.com>
2518
2519 * tui/tui-win.c (WIN_HEIGHT_USAGE): Remove extra ">"s.
2520
2521 2018-09-24 Tom Tromey <tom@tromey.com>
2522
2523 * common/pathstuff.c (get_standard_cache_dir): Make
2524 "xdg_cache_home" and "home" const.
2525 * top.c (init_history): Make "tmpenv" const.
2526 * main.c (get_init_files): Make "homedir" const.
2527
2528 2018-09-23 Tom Tromey <tom@tromey.com>
2529
2530 PR python/18852:
2531 * python/py-param.c (get_set_value): Use gdbpy_handle_exception.
2532
2533 2018-09-23 Tom Tromey <tom@tromey.com>
2534
2535 * python/py-function.c (fnpy_call): Use gdbpy_handle_exception.
2536 * python/py-cmd.c (cmdpy_function): Use gdbpy_handle_exception.
2537 * python/python-internal.h (gdbpy_handle_exception): Declare.
2538 * python/py-utils.c (gdbpy_handle_exception): New function.
2539
2540 2018-09-23 Tom Tromey <tom@tromey.com>
2541
2542 PR python/17284:
2543 * python/py-type.c (typy_template_argument): Check for negative
2544 argument number.
2545
2546 2018-09-23 Tom Tromey <tom@tromey.com>
2547
2548 PR python/14062:
2549 * python/python.c (gdbpy_run_events): Do not ignore exceptions.
2550
2551 2018-09-23 Tom Tromey <tom@tromey.com>
2552
2553 PR python/18170:
2554 * python/py-value.c (valpy_int): Allow conversion from pointer
2555 type.
2556
2557 2018-09-23 Tom Tromey <tom@tromey.com>
2558
2559 PR python/20126:
2560 * python/py-value.c (valpy_int): Respect type sign.
2561
2562 2018-09-23 Tom Tromey <tom@tromey.com>
2563
2564 PR python/18352;
2565 * python/py-value.c (valpy_float): Allow conversions from int or
2566 char.
2567 (valpy_int, valpy_long): Allow conversions from float.
2568
2569 2018-09-23 Tom Tromey <tom@tromey.com>
2570
2571 * ctf.c (ctf_start): Use gdb_fopen_cloexec.
2572 * common/scoped_mmap.c (mmap_file): Use gdb_open_cloexec.
2573
2574 2018-09-23 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2575
2576 * amd64-sol2-tdep.c (amd64_sol2_sigtramp_p): Also recognize
2577 __sighndlr.
2578 * i386-sol2-tdep.c (i386_sol2_sigtramp_p): Likewise.
2579
2580 2018-08-02 Jon Turney <jon.turney@dronecode.org.uk>
2581
2582 * windows-nat.c (windows_nat_target::wait): Remove a spurious
2583 target_terminal::ours().
2584
2585 2018-09-23 Simon Marchi <simon.marchi@ericsson.com>
2586
2587 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): Change type
2588 of vl to ULONGEST.
2589
2590 2018-09-21 Yacov Simhony <ysimhony@gmail.com>
2591
2592 * breakpoint.c (update_inserted_breakpoint_locations): Remove
2593 redundant condition.
2594
2595 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2596
2597 * proc-utils.h (PROC_CTL_WORD_TYPE): Remove.
2598
2599 * procfs.c: Don't check for PR_MODEL_NATIVE definition.
2600 * sparc-sol2-nat.c: Likewise. Remove Linux, __arch64__ references.
2601 * sol-thread.c (ps_pdmodel): Don't guard definition.
2602
2603 * procfs.c: Fix formatting.
2604
2605 * procfs.c (sysset_t_alloc): Remove.
2606 (create_procinfo): Use XNEW instead of sysset_t_alloc.
2607 (procfs_debug_inferior): Likewise.
2608 (procfs_set_exec_trap): Likewise.
2609 (proc_set_traced_sysentry): Don't allocate argp dynamically.
2610 (proc_set_traced_sysexit): Likewise.
2611
2612 * procfs.c (create_procinfo): Use xsnprintf to fix ARI warning.
2613 (dead_procinfo): Likewise.
2614 (proc_warn): Likewise.
2615 (proc_error): Likewise.
2616 (proc_get_LDT_entry): Likewise.
2617 (do_attach): Likewise.
2618 (procfs_target::pid_to_str): Likewise.
2619 (iterate_over_mappings): Likewise.
2620
2621 * procfs.c (create_procinfo): Fix ARI warning.
2622 (proc_get_status): Likewise.
2623 (proc_stop_process): Likewise.
2624 (proc_run_process): Likewise.
2625 (proc_kill): Likewise.
2626 (proc_get_LDT_entry): Likewise.
2627 (procfs_find_LDT_entry): Likewise.
2628 (proc_update_threads): Likewise.
2629 (proc_iterate_over_threads): Likewise.
2630 (do_attach): Likewise.
2631 (procfs_xfer_memory): Likewise.
2632 (invalidate_cache): Likewise.
2633 (procfs_target::resume): Likewise.
2634 (procfs_init_inferior): Likewise.
2635 (procfs_set_exec_trap): Likewise.
2636 (procfs_target::thread_alive): Likewise.
2637 (procfs_target::pid_to_exec_file): Likewise.
2638 (iterate_over_mappings): Likewise.
2639 (procfs_target::make_corefile_notes): Likewise.
2640 * sol-thread.c (sol_thread_target::thread_alive): Likewise.
2641
2642 * procfs.c (procfs_find_LDT_entry): Silence ARI warning.
2643 (procfs_find_LDT_entry): Likewise.
2644 * sol-thread.c (ps_lgetLDT): Likewise.
2645
2646 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2647
2648 PR tdep/17903
2649 * procfs.c (procfs_target): Declare pid_to_exec_file.
2650 (procfs_target::pid_to_exec_file): New.
2651
2652 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2653
2654 * auxv.c (default_print_auxv_entry): Reflect AT_SUN_CAP_HW1
2655 renaming.
2656 Handle AT_SUN_EMULATOR, AT_SUN_BRANDNAME, AT_SUN_BRAND_AUX1,
2657 AT_SUN_BRAND_AUX2, AT_SUN_BRAND_AUX3, AT_SUN_CAP_HW2.
2658
2659 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2660
2661 * i386-v4-nat.c (regmap, supply_gregset, fill_gregset)
2662 (supply_fpregset, fill_fpregset): Move ...
2663 * i386-sol2-nat.c [PR_MODEL_NATIVE != PR_MODEL_LP64]: ... here.
2664 Remove HAVE_GREGSET_T, HAVE_FPREGET_T guards.
2665 Remove references to ioctl-based procfs.
2666 Include <sys/reg.h>.
2667 Remove PR_MODEL_NATIVE guards.
2668 * configure.nat <sol2, i386> (NATDEPFILES): Remove i386-v4-nat.o.
2669 * Makefile.in (ALLDEPFILES): Remove i386-v4-nat.c.
2670
2671 2018-09-19 Xavier Roirand <roirand@adacore.com>
2672
2673 PR gdb/20981:
2674 * solib-darwin.c (darwin_get_dyld_bfd): New function.
2675 (darwin_solib_get_all_image_info_addr_at_init): Update call.
2676 (darwin_solib_create_inferior_hook): Handle unrelocated dyld.
2677
2678 2018-09-19 John Baldwin <jhb@FreeBSD.org>
2679
2680 * fbsd-tdep.c (fbsd_print_sockaddr_in): Style fix.
2681 (fbsd_print_sockaddr_in6): Likewise.
2682
2683 2018-09-19 Richard Bunt <richard.bunt@arm.com>
2684 Chris January <chris.january@arm.com>
2685
2686 * eval.c (skip_undetermined_arglist): Skip argument list helper.
2687 (evaluate_subexp_standard): Return a dummy type when
2688 honoring EVAL_SKIP in OP_VAR_VALUE and handle skipping in the
2689 OP_F77_UNDETERMINED_ARGLIST case.
2690 * expression.h (enum noside): Update comment.
2691
2692 2018-09-19 George Vasick <george.vasick@oracle.com>
2693
2694 * solib-svr4.c (svr4_same_1): Also handle amd64 ld.so.1.
2695
2696 2018-09-19 Stefan Teleman <stefan.teleman@oracle.com>
2697 April Chin <april.chin@oracle.com>
2698 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2699
2700 * procfs.c (MAX_PROC_NAME_SIZE): Allow for 6-digit PID_MAX and
2701 uint_t lwpid_t.
2702 (create_procinfo): Print pids in /proc without leading zeros.
2703
2704 2018-09-18 Sandra Loosemore <sandra@codesourcery.com>
2705
2706 * nios2-tdep.c (nios2_gcc_target_options): New.
2707 (nios2_gdb_arch_init): Install new hook.
2708
2709 2018-09-18 Simon Marchi <simon.marchi@ericsson.com>
2710
2711 * patches/0001-Fix-PR-gdb-23558-Use-system-s-getcwd-when-cross-comp.patch:
2712 New file.
2713 * update-gnulib.sh: Apply patch.
2714 * configure: Re-generate.
2715
2716 2018-09-18 John Baldwin <jhb@FreeBSD.org>
2717
2718 * infcmd.c (_initialize_infcmd): Remove "running" from "info proc"
2719 description. Make "info proc" command descriptions more
2720 consistent.
2721
2722 2018-09-18 John Baldwin <jhb@FreeBSD.org>
2723
2724 * NEWS: Mention 'info proc files' command.
2725
2726 2018-09-18 John Baldwin <jhb@FreeBSD.org>
2727
2728 * fbsd-nat.c (fbsd_nat_target::info_proc): List open file
2729 descriptors for IP_FILES and IP_ALL.
2730
2731 2018-09-18 John Baldwin <jhb@FreeBSD.org>
2732
2733 * fbsd-tdep.c (KF_FLAGS, KF_OFFSET, KF_VNODE_TYPE, KF_SOCK_DOMAIN)
2734 (KF_SOCK_TYPE, KF_SOCK_PROTOCOL, KF_SA_LOCAL, KF_SA_PEER)
2735 (KINFO_FILE_TYPE_SOCKET, KINFO_FILE_TYPE_PIPE)
2736 (KINFO_FILE_TYPE_FIFO, KINFO_FILE_TYPE_KQUEUE)
2737 (KINFO_FILE_TYPE_CRYPTO, KINFO_FILE_TYPE_MQUEUE)
2738 (KINFO_FILE_TYPE_SHM, KINFO_FILE_TYPE_SEM, KINFO_FILE_TYPE_PTS)
2739 (KINFO_FILE_TYPE_PROCDESC, KINFO_FILE_FD_TYPE_ROOT)
2740 (KINFO_FILE_FD_TYPE_JAIL, KINFO_FILE_FD_TYPE_TRACE)
2741 (KINFO_FILE_FD_TYPE_CTTY, KINFO_FILE_FLAG_READ)
2742 (KINFO_FILE_FLAG_WRITE, KINFO_FILE_FLAG_APPEND)
2743 (KINFO_FILE_FLAG_ASYNC, KINFO_FILE_FLAG_FSYNC)
2744 (KINFO_FILE_FLAG_NONBLOCK, KINFO_FILE_FLAG_DIRECT)
2745 (KINFO_FILE_FLAG_HASLOCK, KINFO_FILE_FLAG_EXEC)
2746 (KINFO_FILE_VTYPE_VREG, KINFO_FILE_VTYPE_VDIR)
2747 (KINFO_FILE_VTYPE_VCHR, KINFO_FILE_VTYPE_VLNK)
2748 (KINFO_FILE_VTYPE_VSOCK, KINFO_FILE_VTYPE_VFIFO, FBSD_AF_UNIX)
2749 (FBSD_AF_INET, FBSD_AF_INET6, FBSD_SOCK_STREAM, FBSD_SOCK_DGRAM)
2750 (FBSD_SOCK_SEQPACKET, FBSD_IPPROTO_ICMP, FBSD_IPPROTO_TCP)
2751 (FBSD_IPPROTO_UDP, FBSD_IPPROTO_SCTP): New defines.
2752 (struct fbsd_sockaddr_in, struct fbsd_sockaddr_in6)
2753 (struct fbsd_sockaddr_un): New types.
2754 (fbsd_file_fd, fbsd_file_type, fbsd_file_flags, fbsd_ipproto)
2755 (fbsd_print_sockaddr_in, fbsd_print_sockaddr_in6)
2756 (fbsd_info_proc_files_header, fbsd_info_proc_files_entry)
2757 (fbsd_core_info_proc_files): New functions.
2758 (fbsd_core_info_proc): List open file descriptors for IP_FILES and
2759 IP_ALL.
2760 * fbsd-tdep.h (fbsd_info_proc_files_header)
2761 (fbsd_info_proc_files_entry): New.
2762
2763 2018-09-18 John Baldwin <jhb@FreeBSD.org>
2764
2765 * defs.h (enum info_proc_what) [IP_FILES]: New value.
2766 * infcmd.c (info_proc_cmd_files): New function.
2767 (_initialize_infcmd): Register 'info proc files' command.
2768
2769 2018-09-18 John Baldwin <jhb@FreeBSD.org>
2770
2771 * gnulib/aclocal-m4-deps.mk: Re-generate.
2772 * gnulib/aclocal.m4: Re-generate.
2773 * gnulib/config.in: Re-generate.
2774 * gnulib/configure: Re-generate.
2775 * gnulib/import/Makefile.am: Re-generate.
2776 * gnulib/import/Makefile.in: Re-generate.
2777 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
2778 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
2779 * gnulib/import/arpa_inet.in.h: New file.
2780 * gnulib/import/inet_ntop.c: New file.
2781 * gnulib/import/m4/arpa_inet_h.m4: New file.
2782 * gnulib/import/m4/inet_ntop.m4: New file.
2783 * gnulib/import/m4/netinet_in_h.m4: New file.
2784 * gnulib/import/m4/socklen.m4: New file.
2785 * gnulib/import/m4/sockpfaf.m4: New file.
2786 * gnulib/import/m4/stdalign.m4: New file.
2787 * gnulib/import/m4/sys_uio_h.m4: New file.
2788 * gnulib/import/netinet_in.in.h: New file.
2789 * gnulib/import/stdalign.in.h: New file.
2790 * gnulib/import/sys_socket.c: New file.
2791 * gnulib/import/sys_socket.in.h: New file.
2792 * gnulib/import/sys_uio.in.h: New file.
2793 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add inet_ntop
2794 module.
2795
2796 2018-09-18 John Baldwin <jhb@FreeBSD.org>
2797
2798 * gnulib/aclocal-m4-deps.mk: New file.
2799 * gnulib/update-gnulib.sh: Generate "aclocal-m4-deps.mk"
2800 deterministically.
2801
2802 2018-09-18 John Baldwin <jhb@FreeBSD.org>
2803
2804 * fbsd-tdep.c (fbsd_core_vnode_path): Use KF_PATH instead of
2805 KVE_PATH.
2806
2807 2018-09-18 Tom Tromey <tom@tromey.com>
2808
2809 * compile/compile-object-load.c (struct
2810 link_hash_table_cleanup_data): Add constructor and destructor.
2811 Use DISABLE_COPY_AND_ASSIGN.
2812 (~link_hash_table_cleanup_data): Rename from
2813 link_hash_table_free. Now a destructor.
2814 (copy_sections): Use gdb::unique_xmalloc_ptr. Remove cleanups.
2815
2816 2018-09-18 Tom Tromey <tom@tromey.com>
2817
2818 * compile/compile-object-run.c (do_module_cleanup): Use delete.
2819 * compile/compile-object-load.c (struct munmap_list): Move to
2820 header file.
2821 (munmap_list::add): Rename from munmap_list_add; rewrite.
2822 (munmap_list::~munmap_list): Rename from munmap_list_free.
2823 (munmap_listp_free_cleanup): Remove.
2824 (compile_object_load): Update.
2825 * compile/compile-object-load.h (struct munmap_list): Move from
2826 compile-object-load.c. Rewrite.
2827
2828 2018-09-18 Alan Hayward <alan.hayward@arm.com>
2829
2830 * aarch64-tdep.c (pass_in_v): Use register size.
2831 (aarch64_extract_return_value): Likewise.
2832 (aarch64_store_return_value): Likewise.
2833
2834 2018-09-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2835
2836 * utils.c (dump_core) [HAVE_SETRLIMIT]: Cast RLIM_INFINITY to
2837 rlim_t.
2838
2839 2018-09-17 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2840
2841 * python/lib/gdb/command/frame_filters.py (EnableFrameFilter):
2842 Fix short help line.
2843
2844 2018-09-17 Tom Tromey <tom@tromey.com>
2845
2846 PR python/20445:
2847 * configure: Rebuild.
2848 * configure.ac: Conditionally use -DNDEBUG for Python.
2849
2850 2018-09-17 Tom Tromey <tom@tromey.com>
2851
2852 * configure: Rebuild.
2853 * configure.ac: Use gmp as a library dependency when checking for
2854 mpfr.
2855
2856 2018-09-17 Pedro Alves <palves@redhat.com>
2857
2858 * python/py-inferior.c (find_inferior_object): Delete.
2859
2860 2018-09-17 Simon Marchi <simon.marchi@ericsson.com>
2861
2862 * compile/compile-cplus-types.c
2863 (compile_cplus_instance::enter_scope): Don't use new_scope after
2864 std::move.
2865
2866 2018-09-17 Tom Tromey <tom@tromey.com>
2867
2868 * common/pathstuff.c (get_standard_cache_dir): Use
2869 ~/Library/Caches on macOS.
2870 * common/pathstuff.h (get_standard_cache_dir): Update comment.
2871
2872 2018-09-17 Simon Marchi <simon.marchi@polymtl.ca>
2873
2874 PR python/23669
2875 * breakpoint.c (commands_cmd_element): New.
2876 (_initialize_breakpoint): Assign commands_cmd_element.
2877 * breakpoint.h (commands_cmd_element): New.
2878 * cli/cli-script.c (while_cmd_element, if_command,
2879 define_cmd_element): New.
2880 (command_name_equals): Remove.
2881 (process_next_line): Compare commands by pointer, not by name.
2882 (_initialize_cli_script): Assign the various cmd_list_element
2883 variables.
2884 * compile/compile.c (compile_cmd_element): New.
2885 (_initialize_compile): Assign compile_cmd_element.
2886 * compile/compile.h (compile_cmd_element): New.
2887 * guile/guile.c (guile_cmd_element): New.
2888 (install_gdb_commands): Assign guile_cmd_element.
2889 * guile/guile.h (guile_cmd_element): New.
2890 * python/python.c (python_cmd_element): New.
2891 (_initialize_python): Assign python_cmd_element.
2892 * python/python.h (python_cmd_element): New.
2893 * tracepoint.c (while_stepping_cmd_element): New.
2894 (_initialize_tracepoint): Assign while_stepping_cmd_element.
2895 * tracepoint.h (while_stepping_cmd_element): New.
2896
2897 2018-09-17 Tom Tromey <tom@tromey.com>
2898
2899 * infrun.c (save_infcall_suspend_state): Return
2900 infcall_suspend_state_up.
2901 (save_infcall_control_state): Return infcall_control_state_up.
2902 * inferior.h (save_infcall_suspend_state)
2903 (save_infcall_control_state): Declare later. Return unique
2904 pointers.
2905
2906 2018-09-17 Tom Tromey <tom@tromey.com>
2907
2908 * infrun.c (struct stop_context): Declare constructor,
2909 destructor, "changed" method.
2910 (stop_context::stop_context): Rename from save_stop_context.
2911 (stop_context::~stop_context): Rename from
2912 release_stop_context_cleanup.
2913 (normal_stop): Update.
2914 (stop_context::changed): Rename from stop_context_changed. Return
2915 bool.
2916
2917 2018-09-17 Tom Tromey <tom@tromey.com>
2918
2919 * inferior.h (struct infcall_suspend_state_deleter): New.
2920 (infcall_suspend_state_up): New typedef.
2921 (struct infcall_control_state_deleter): New.
2922 (infcall_control_state_up): New typedef.
2923 (make_cleanup_restore_infcall_suspend_state)
2924 (make_cleanup_restore_infcall_control_state): Don't declare.
2925 * infcall.c (call_function_by_hand_dummy): Update.
2926 * infrun.c (do_restore_infcall_suspend_state_cleanup)
2927 (make_cleanup_restore_infcall_suspend_state): Remove.
2928 (do_restore_infcall_control_state_cleanup)
2929 (make_cleanup_restore_infcall_control_state): Remove.
2930
2931 2018-09-17 Tom Tromey <tom@tromey.com>
2932
2933 * gdbthread.h (struct thread_control_state): Add initializer.
2934 (class thread_info) <control>: Remove initializer.
2935 * inferior.h (struct inferior_control_state): Add initializer.
2936 (class inferior) <control>: Remove initializer.
2937 (exit_inferior_1): Update.
2938 * infrun.c (struct infcall_control_state): Add constructors.
2939 (save_infcall_control_state): Use new.
2940 (restore_infcall_control_state, discard_infcall_control_state):
2941 Use delete.
2942
2943 2018-09-17 Tom Tromey <tom@tromey.com>
2944
2945 * infrun.c (struct infcall_suspend_state) <registers>: Now a
2946 unique_ptr.
2947 <siginfo_data>: Now a unique_xmalloc_ptr.
2948 (save_infcall_suspend_state, restore_infcall_suspend_state)
2949 (discard_infcall_suspend_state)
2950 (get_infcall_suspend_state_regcache): Update.
2951
2952 2018-09-17 Tom Tromey <tom@tromey.com>
2953
2954 * gdbthread.h (struct thread_suspend_state): Add initializers.
2955 (class thread_info) <suspend>: Remove initializer.
2956 * infrun.c (struct infcall_suspend_state): Add initializers.
2957 (save_infcall_suspend_state): Use new.
2958 (discard_infcall_suspend_state): Use delete.
2959
2960 2018-09-16 Tom Tromey <tom@tromey.com>
2961
2962 * python/python-internal.h (CPYCHECKER_STEALS_REFERENCE_TO_ARG):
2963 Remove.
2964 * python/py-varobj.c (py_varobj_iter_ctor): Change pyiter to
2965 rvalue reference. Remove CPYCHECKER_STEALS_REFERENCE_TO_ARG.
2966 (py_varobj_iter_new): Likewise.
2967 (py_varobj_get_iterator): Use gdbpy_ref.
2968
2969 2018-09-16 Tom Tromey <tom@tromey.com>
2970
2971 * python/py-threadevent.c (py_get_event_thread): Simplify.
2972 * python/py-inferior.c (infpy_thread_from_thread_handle):
2973 Return immediately after calling thread_to_thread_object. Use
2974 Py_RETURN_NONE.
2975 (thread_to_thread_object): Set the exception on a NULL return.
2976
2977 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
2978
2979 * Makefile.in (LIBGDB_OBS): Sort COMMON_OBS.
2980
2981 2018-09-16 Tom Tromey <tom@tromey.com>
2982
2983 * python/python-internal.h (CPYCHECKER_RETURNS_BORROWED_REF):
2984 Remove.
2985
2986 2018-09-16 Tom Tromey <tom@tromey.com>
2987
2988 * python/python-internal.h (thread_to_thread_object): Change
2989 return type.
2990 * python/py-inferior.c (thread_to_thread_object): Return a new
2991 reference.
2992 (infpy_thread_from_thread_handle): Update.
2993 * python/py-infthread.c (gdbpy_selected_thread): Update.
2994 * python/py-stopevent.c (create_stop_event_object): Update.
2995 * python/py-threadevent.c (py_get_event_thread): Return a new
2996 reference.
2997 (py_get_event_thread): Update.
2998 * python/py-event.h (py_get_event_thread): Change return type.
2999 * python/py-continueevent.c (create_continue_event_object):
3000 Update.
3001
3002 2018-09-16 Tom Tromey <tom@tromey.com>
3003
3004 * python/py-progspace.c (pspy_get_objfiles): Update.
3005 * python/python-internal.h (objfile_to_objfile_object): Change
3006 return type.
3007 * python/py-newobjfileevent.c (create_new_objfile_event_object):
3008 Update.
3009 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
3010 Update.
3011 * python/python.c (gdbpy_get_current_objfile): Update.
3012 (gdbpy_objfiles): Update.
3013 * python/py-objfile.c (objfpy_get_owner, gdbpy_lookup_objfile):
3014 Update.
3015 (objfile_to_objfile_object): Return a new reference.
3016 * python/py-symtab.c (stpy_get_objfile): Update.
3017 * python/py-prettyprint.c (find_pretty_printer_from_objfiles):
3018 Update.
3019
3020 2018-09-16 Tom Tromey <tom@tromey.com>
3021
3022 * python/py-inferior.c (infpy_get_progspace): Update.
3023 * python/python-internal.h (pspace_to_pspace_object): Change
3024 return type.
3025 * python/py-newobjfileevent.c
3026 (create_clear_objfiles_event_object): Update.
3027 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
3028 Update.
3029 * python/python.c (gdbpy_get_current_progspace): Update.
3030 (gdbpy_progspaces): Update.
3031 * python/py-progspace.c (pspace_to_pspace_object): Return a new
3032 reference.
3033 * python/py-objfile.c (objfpy_get_progspace): Update.
3034 * python/py-prettyprint.c (find_pretty_printer_from_progspace):
3035 Update.
3036
3037 2018-09-16 Tom Tromey <tom@tromey.com>
3038
3039 * python/lib/gdb/__init__.py (current_progspace, objfiles)
3040 (solib_name, block_for_pc, find_pc_line): New functions.
3041 (execute_unwinders): Update.
3042 * python/py-block.c (gdbpy_block_for_pc): Remove.
3043 * python/py-inferior.c (infpy_get_progspace): New function.
3044 (inferior_object_getset) <progspace>: Add.
3045 * python/py-progspace.c (pspy_objfiles): Rewrite.
3046 (pspy_solib_name, pspy_block_for_pc)
3047 (pspy_find_pc_line, pspy_is_valid): New functions.
3048 (progspace_object_methods): Add entries for solib_name,
3049 block_for_pc, find_pc_line, is_valid.
3050 * python/python-internal.h (gdbpy_block_for_pc)
3051 (build_objfiles_list): Don't declare.
3052 * python/python.c: Don't include solib.h.
3053 (gdbpy_solib_name, gdbpy_find_pc_line)
3054 (gdbpy_get_current_progspace, build_objfiles_list)
3055 (gdbpy_objfiles): Remove.
3056 (GdbMethods) <current_progspace, objfiles, block_for_pc,
3057 solib_name, find_pc_line>: Remove entries.
3058
3059 2018-09-16 Tom Tromey <tom@tromey.com>
3060
3061 * top.c (new_ui_command): Use GNU style for metasyntactic
3062 variables.
3063 * breakpoint.c (stopat_command): Use GNU style for metasyntactic
3064 variables.
3065 * maint.c (maintenance_translate_address): Remove "<>" around
3066 text.
3067 * interps.c (interpreter_exec_cmd): Use GNU style for
3068 metasyntactic variables.
3069 * nto-procfs.c (nto_procfs_target_info): Use GNU style for
3070 metasyntactic variables.
3071 * tracepoint.c (tfind_range_command): Use GNU style for
3072 metasyntactic variables.
3073 (tfind_outside_command): Likewise.
3074 (_initialize_tracepoint): Likewise.
3075 * remote.c (extended_remote_target::create_inferior): Use GNU
3076 style for metasyntactic variables.
3077 * sparc64-tdep.c (adi_examine_command): Use GNU style for
3078 metasyntactic variables.
3079 (adi_assign_command): Likewise.
3080
3081 2018-09-16 Tom Tromey <tom@tromey.com>
3082
3083 * disasm.c (show_disassembler_options_sfunc): Use GNU style for
3084 metasyntactic variables. Print message if no disassembler options
3085 are available.
3086
3087 2018-09-15 Tom Tromey <tom@tromey.com>
3088
3089 * infcmd.c (get_inferior_args): Return const char *.
3090 * inferior.h (get_inferior_args): Return type now const.
3091 * linux-tdep.c (linux_fill_prpsinfo): Update.
3092 * procfs.c (procfs_target::make_corefile_notes): Update.
3093
3094 2018-09-07 Tom Tromey <tom@tromey.com>
3095
3096 * python/python.c (execute_gdb_command): Call bpstat_do_actions
3097 inside the TRY.
3098
3099 2018-09-14 Sandra Loosemore <sandra@codesourcery.com>
3100
3101 * nios2-tdep.c (nios2_type_align): New.
3102 (nios2_gdb_arch_init): Install type_align hook.
3103
3104 2018-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
3105
3106 * eval.c (fake_method::fake_method): Call xzalloc directly for a
3107 type that is neither object file owned, nor gdbarch owned.
3108 * gdbtypes.c (get_type_gdbarch): Add an assert that returned
3109 gdbarch is non-NULL.
3110 (alloc_type_instance): Allocate non-objfile owned types on the
3111 gdbarch obstack.
3112 (copy_type_recursive): Allocate TYPE_FIELDS and TYPE_RANGE_DATA
3113 using TYPE_ALLOC to ensure memory is allocated on the correct
3114 obstack.
3115 * gdbtypes.h (TYPE_ALLOC): Allocate space on either the objfile
3116 obstack, or the gdbarch obstack.
3117 (TYPE_ZALLOC): Rewrite using TYPE_ALLOC.
3118
3119 2018-09-14 Tom Tromey <tom@tromey.com>
3120
3121 * infcall.c (call_function_by_hand_dummy): Remove unnecessary
3122 block.
3123
3124 2018-09-14 Tom Tromey <tom@tromey.com>
3125
3126 * nat/fork-inferior.c (get_startup_shell): Remove "static".
3127
3128 2018-09-13 Tom Tromey <tom@tromey.com>
3129
3130 * python/py-inferior.c (infpy_thread_from_thread_handle): Now
3131 static.
3132
3133 2018-09-13 Tom Tromey <tom@tromey.com>
3134
3135 * exec.c (try_open_exec_file): Use std::string.
3136
3137 2018-09-13 Tom Tromey <tom@tromey.com>
3138
3139 * utils.h (gdb_bfd_errmsg): Return std::string.
3140 * exec.c (exec_file_attach): Update.
3141 * compile/compile-object-load.c (compile_object_load): Update.
3142 * utils.c (gdb_bfd_errmsg): Return std::string.
3143
3144 2018-09-13 Tom Tromey <tom@tromey.com>
3145
3146 * procfs.c (struct procinfo_deleter): New.
3147 (procinfo_up): New typedef.
3148 (do_destroy_procinfo_cleanup): Remove.
3149 (procfs_target::info_proc): Use procinfo_up. Remove cleanups.
3150
3151 2018-09-13 Tom Tromey <tom@tromey.com>
3152
3153 * source.c (add_path): Use gdb::unique_xmalloc_ptr.
3154
3155 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
3156 2018-09-13 Tom Tromey <tom@tromey.com>
3157
3158 * python/py-progspace.c (PSPY_REQUIRE_VALID): New macro.
3159 (pspy_get_objfiles): New function.
3160 (progspace_object_methods): New.
3161 (pspace_object_type): Add tp_methods callback.
3162 * python/python-internal.h (build_objfiles_list): New
3163 declaration.
3164 * python/python.c (build_objfiles_list): New function.
3165 (gdbpy_objfiles): Implement using build_objfiles_list.
3166 * NEWS: Mention the Progspace.objfiles method.
3167
3168 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
3169
3170 * python/py-inferior.c (infpy_get_progspace): New function.
3171 (inferior_object_getset): Add progspace property.
3172 * NEWS: Mention the new property.
3173
3174 2018-09-13 Tom Tromey <tom@tromey.com>
3175
3176 PR rust/23650:
3177 * rust-lang.c (rust_evaluate_subexp): Use field name, not "foo".
3178
3179 2018-09-13 Tom Tromey <tom@tromey.com>
3180
3181 PR rust/23626:
3182 * rust-lang.c (rust_enum_variant): Now static.
3183 (rust_empty_enum_p): New function.
3184 (rust_print_enum, rust_evaluate_subexp, rust_print_struct_def):
3185 Handle empty enum.
3186
3187 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
3188
3189 * python/py-inferior.c (infpy_repr): New.
3190 (inferior_object_type): Register infpy_repr.
3191 * python/py-objfile.c (objfpy_repr): New.
3192 (objfile_object_type): Register objfpy_repr.
3193
3194 2018-09-12 John Baldwin <jhb@FreeBSD.org>
3195
3196 * fbsd-nat.c (fbsd_nat_target::info_proc): Remove unused variable.
3197
3198 2018-09-12 John Baldwin <jhb@FreeBSD.org>
3199
3200 * aarch64-fbsd-tdep.h (AARCH64_FBSD_SIZEOF_GREGSET): Fix comment
3201 typo.
3202
3203 2018-09-12 Sergio Durigan Junior <sergiodj@redhat.com>
3204
3205 * common/common-utils.c: Don't include '<sys/stat.h>'.
3206 (is_regular_file): Move to...
3207 * common/filestuff.c (is_regular_file): ... here.
3208 * common/common-utils.h (is_regular_file): Move to...
3209 * common/filestuff.h (is_regular_file): ... here.
3210
3211 2018-09-12 Simon Marchi <simon.marchi@ericsson.com>
3212
3213 * skip.c (debug_skip): New variable.
3214 (skiplist_entry::do_skip_file_p): Add debug output.
3215 (skiplist_entry::do_skip_gfile_p): Likewise.
3216 (skiplist_entry::skip_function_p): Likewise.
3217 (_initialize_step_skip): Create debug command.
3218 * NEWS: Mention set/show debug skip.
3219
3220 2018-09-11 Xavier Roirand <roirand@adacore.com>
3221
3222 * darwin-nat.c (should_disable_startup_with_shell):
3223 New function.
3224 (darwin_nat_target::create_inferior): Add call.
3225
3226 2018-09-11 Xavier Roirand <roirand@adacore.com>
3227
3228 * darwin-nat.h (struct darwin_thread_info) <gdb_port,
3229 inf_port, msg_state>: Initialize.
3230 (struct darwin_thread_info) <signaled, single_step>: Change
3231 type and initialize.
3232 (struct darwin_thread_info) <event>: Initialize.
3233
3234 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
3235
3236 PR gdb/23555
3237 PR gdb/23558
3238 * gnulib/import/m4/getcwd-path-max.m4: Add cross-compilation
3239 guesses.
3240
3241 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
3242
3243 Revert:
3244 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
3245
3246 PR gdb/23555
3247 PR gdb/23558
3248 * gnulib/aclocal.m4: Regenerate.
3249 * gnulib/config.in: Regenerate.
3250 * gnulib/configure: Regenerate.
3251 * gnulib/import/Makefile.am: Update.
3252 * gnulib/import/Makefile.in: Update.
3253 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
3254 * gnulib/import/_Noreturn.h: ... this.
3255 * gnulib/import/alloca.in.h: Update.
3256 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
3257 * gnulib/import/arg-nonnull.h: ... this.
3258 * gnulib/import/assure.h: Update.
3259 * gnulib/import/at-func.c: Update.
3260 * gnulib/import/basename-lgpl.c: Update.
3261 * gnulib/import/extra/snippet/c++defs.h: Rename to...
3262 * gnulib/import/c++defs.h: ... this.
3263 * gnulib/import/canonicalize-lgpl.c: Update.
3264 * gnulib/import/cdefs.h: Update.
3265 * gnulib/import/chdir-long.c: Update.
3266 * gnulib/import/chdir-long.h: Update.
3267 * gnulib/import/cloexec.c: Update.
3268 * gnulib/import/cloexec.h: Update.
3269 * gnulib/import/close.c: Update.
3270 * gnulib/import/closedir.c: Update.
3271 * gnulib/import/config.charset: Update.
3272 * gnulib/import/dirent-private.h: Update.
3273 * gnulib/import/dirent.in.h: Update.
3274 * gnulib/import/dirfd.c: Update.
3275 * gnulib/import/dirname-lgpl.c: Update.
3276 * gnulib/import/dirname.h: Update.
3277 * gnulib/import/dosname.h: Update.
3278 * gnulib/import/dup-safer-flag.c: Update.
3279 * gnulib/import/dup-safer.c: Update.
3280 * gnulib/import/dup.c: Update.
3281 * gnulib/import/dup2.c: Update.
3282 * gnulib/import/errno.in.h: Update.
3283 * gnulib/import/error.c: Update.
3284 * gnulib/import/error.h: Update.
3285 * gnulib/import/exitfail.c: Update.
3286 * gnulib/import/exitfail.h: Update.
3287 * gnulib/import/extra/update-copyright: Update.
3288 * gnulib/import/fchdir.c: Update.
3289 * gnulib/import/fcntl.c: Update.
3290 * gnulib/import/fcntl.in.h: Update.
3291 * gnulib/import/fd-hook.c: Update.
3292 * gnulib/import/fd-hook.h: Update.
3293 * gnulib/import/fd-safer-flag.c: Update.
3294 * gnulib/import/fd-safer.c: Update.
3295 * gnulib/import/fdopendir.c: Update.
3296 * gnulib/import/filename.h: Update.
3297 * gnulib/import/filenamecat-lgpl.c: Update.
3298 * gnulib/import/filenamecat.h: Update.
3299 * gnulib/import/flexmember.h: Update.
3300 * gnulib/import/float+.h: Update.
3301 * gnulib/import/float.c: Update.
3302 * gnulib/import/float.in.h: Update.
3303 * gnulib/import/fnmatch.c: Update.
3304 * gnulib/import/fnmatch.in.h: Update.
3305 * gnulib/import/fnmatch_loop.c: Update.
3306 * gnulib/import/fpucw.h: Update.
3307 * gnulib/import/frexp.c: Update.
3308 * gnulib/import/frexpl.c: Update.
3309 * gnulib/import/fstat.c: Update.
3310 * gnulib/import/fstatat.c: Update.
3311 * gnulib/import/getcwd-lgpl.c: Update.
3312 * gnulib/import/getcwd.c: Update.
3313 * gnulib/import/getdtablesize.c: Update.
3314 * gnulib/import/getlogin_r.c: Update.
3315 * gnulib/import/getprogname.c: Update.
3316 * gnulib/import/getprogname.h: Update.
3317 * gnulib/import/gettext.h: Update.
3318 * gnulib/import/gettimeofday.c: Update.
3319 * gnulib/import/glob-libc.h: Update.
3320 * gnulib/import/glob.c: Update.
3321 * gnulib/import/glob.in.h: Update.
3322 * gnulib/import/glob_internal.h: Update.
3323 * gnulib/import/glob_pattern_p.c: Update.
3324 * gnulib/import/globfree.c: Update.
3325 * gnulib/import/hard-locale.c: Update.
3326 * gnulib/import/hard-locale.h: Update.
3327 * gnulib/import/intprops.h: Update.
3328 * gnulib/import/inttypes.in.h: Update.
3329 * gnulib/import/isnan.c: Update.
3330 * gnulib/import/isnand-nolibm.h: Update.
3331 * gnulib/import/isnand.c: Update.
3332 * gnulib/import/isnanl-nolibm.h: Update.
3333 * gnulib/import/isnanl.c: Update.
3334 * gnulib/import/itold.c: Update.
3335 * gnulib/import/libc-config.h: Update.
3336 * gnulib/import/limits.in.h: Update.
3337 * gnulib/import/localcharset.c: Update.
3338 * gnulib/import/localcharset.h: Update.
3339 * gnulib/import/localtime-buffer.c: Update.
3340 * gnulib/import/localtime-buffer.h: Update.
3341 * gnulib/import/lstat.c: Update.
3342 * gnulib/import/m4/00gnulib.m4: Update.
3343 * gnulib/import/m4/__inline.m4: Update.
3344 * gnulib/import/m4/absolute-header.m4: Update.
3345 * gnulib/import/m4/alloca.m4: Update.
3346 * gnulib/import/m4/builtin-expect.m4: Update.
3347 * gnulib/import/m4/canonicalize.m4: Update.
3348 * gnulib/import/m4/chdir-long.m4: Update.
3349 * gnulib/import/m4/close.m4: Update.
3350 * gnulib/import/m4/closedir.m4: Update.
3351 * gnulib/import/m4/configmake.m4: Update.
3352 * gnulib/import/m4/d-ino.m4: Update.
3353 * gnulib/import/m4/d-type.m4: Update.
3354 * gnulib/import/m4/dirent_h.m4: Update.
3355 * gnulib/import/m4/dirfd.m4: Update.
3356 * gnulib/import/m4/dirname.m4: Update.
3357 * gnulib/import/m4/double-slash-root.m4: Update.
3358 * gnulib/import/m4/dup.m4: Update.
3359 * gnulib/import/m4/dup2.m4: Update.
3360 * gnulib/import/m4/eealloc.m4: Update.
3361 * gnulib/import/m4/environ.m4: Update.
3362 * gnulib/import/m4/errno_h.m4: Update.
3363 * gnulib/import/m4/error.m4: Update.
3364 * gnulib/import/m4/exponentd.m4: Update.
3365 * gnulib/import/m4/exponentl.m4: Update.
3366 * gnulib/import/m4/extensions.m4: Update.
3367 * gnulib/import/m4/extern-inline.m4: Update.
3368 * gnulib/import/m4/fchdir.m4: Update.
3369 * gnulib/import/m4/fcntl-o.m4: Update.
3370 * gnulib/import/m4/fcntl.m4: Update.
3371 * gnulib/import/m4/fcntl_h.m4: Update.
3372 * gnulib/import/m4/fdopendir.m4: Update.
3373 * gnulib/import/m4/filenamecat.m4: Update.
3374 * gnulib/import/m4/flexmember.m4: Update.
3375 * gnulib/import/m4/float_h.m4: Update.
3376 * gnulib/import/m4/fnmatch.m4: Update.
3377 * gnulib/import/m4/fnmatch_h.m4: Update.
3378 * gnulib/import/m4/fpieee.m4: Update.
3379 * gnulib/import/m4/frexp.m4: Update.
3380 * gnulib/import/m4/frexpl.m4: Update.
3381 * gnulib/import/m4/fstat.m4: Update.
3382 * gnulib/import/m4/fstatat.m4: Update.
3383 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
3384 * gnulib/import/m4/getcwd-path-max.m4: Update.
3385 * gnulib/import/m4/getcwd.m4: Update.
3386 * gnulib/import/m4/getdtablesize.m4: Update.
3387 * gnulib/import/m4/getlogin.m4: Update.
3388 * gnulib/import/m4/getlogin_r.m4: Update.
3389 * gnulib/import/m4/getpagesize.m4: Update.
3390 * gnulib/import/m4/getprogname.m4: Update.
3391 * gnulib/import/m4/gettimeofday.m4: Update.
3392 * gnulib/import/m4/glibc21.m4: Update.
3393 * gnulib/import/m4/glob.m4: Update.
3394 * gnulib/import/m4/glob_h.m4: Update.
3395 * gnulib/import/m4/gnulib-cache.m4: Update.
3396 * gnulib/import/m4/gnulib-common.m4: Update.
3397 * gnulib/import/m4/gnulib-comp.m4: Update.
3398 * gnulib/import/m4/gnulib-tool.m4: Update.
3399 * gnulib/import/m4/hard-locale.m4: Update.
3400 * gnulib/import/m4/include_next.m4: Update.
3401 * gnulib/import/m4/inttypes-pri.m4: Update.
3402 * gnulib/import/m4/inttypes.m4: Update.
3403 * gnulib/import/m4/isnand.m4: Update.
3404 * gnulib/import/m4/isnanl.m4: Update.
3405 * gnulib/import/m4/largefile.m4: Update.
3406 * gnulib/import/m4/limits-h.m4: Update.
3407 * gnulib/import/m4/localcharset.m4: Update.
3408 * gnulib/import/m4/locale-fr.m4: Update.
3409 * gnulib/import/m4/locale-ja.m4: Update.
3410 * gnulib/import/m4/locale-zh.m4: Update.
3411 * gnulib/import/m4/localtime-buffer.m4: Update.
3412 * gnulib/import/m4/longlong.m4: Update.
3413 * gnulib/import/m4/lstat.m4: Update.
3414 * gnulib/import/m4/malloc.m4: Update.
3415 * gnulib/import/m4/malloca.m4: Update.
3416 * gnulib/import/m4/math_h.m4: Update.
3417 * gnulib/import/m4/mbrtowc.m4: Update.
3418 * gnulib/import/m4/mbsinit.m4: Update.
3419 * gnulib/import/m4/mbsrtowcs.m4: Update.
3420 * gnulib/import/m4/mbstate_t.m4: Update.
3421 * gnulib/import/m4/memchr.m4: Update.
3422 * gnulib/import/m4/memmem.m4: Update.
3423 * gnulib/import/m4/mempcpy.m4: Update.
3424 * gnulib/import/m4/memrchr.m4: Update.
3425 * gnulib/import/m4/mkdir.m4: Update.
3426 * gnulib/import/m4/mkstemp.m4: Update.
3427 * gnulib/import/m4/mmap-anon.m4: Update.
3428 * gnulib/import/m4/mode_t.m4: Update.
3429 * gnulib/import/m4/msvc-inval.m4: Update.
3430 * gnulib/import/m4/msvc-nothrow.m4: Update.
3431 * gnulib/import/m4/multiarch.m4: Update.
3432 * gnulib/import/m4/nocrash.m4: Update.
3433 * gnulib/import/m4/off_t.m4: Update.
3434 * gnulib/import/m4/onceonly.m4: Update.
3435 * gnulib/import/m4/open-cloexec.m4: Update.
3436 * gnulib/import/m4/open.m4: Update.
3437 * gnulib/import/m4/openat.m4: Update.
3438 * gnulib/import/m4/opendir.m4: Update.
3439 * gnulib/import/m4/pathmax.m4: Update.
3440 * gnulib/import/m4/rawmemchr.m4: Update.
3441 * gnulib/import/m4/readdir.m4: Update.
3442 * gnulib/import/m4/readlink.m4: Update.
3443 * gnulib/import/m4/realloc.m4: Update.
3444 * gnulib/import/m4/rename.m4: Update.
3445 * gnulib/import/m4/rewinddir.m4: Update.
3446 * gnulib/import/m4/rmdir.m4: Update.
3447 * gnulib/import/m4/save-cwd.m4: Update.
3448 * gnulib/import/m4/secure_getenv.m4: Update.
3449 * gnulib/import/m4/setenv.m4: Update.
3450 * gnulib/import/m4/signal_h.m4: Update.
3451 * gnulib/import/m4/ssize_t.m4: Update.
3452 * gnulib/import/m4/stat-time.m4: Update.
3453 * gnulib/import/m4/stat.m4: Update.
3454 * gnulib/import/m4/std-gnu11.m4: Update.
3455 * gnulib/import/m4/stdbool.m4: Update.
3456 * gnulib/import/m4/stddef_h.m4: Update.
3457 * gnulib/import/m4/stdint.m4: Update.
3458 * gnulib/import/m4/stdio_h.m4: Update.
3459 * gnulib/import/m4/stdlib_h.m4: Update.
3460 * gnulib/import/m4/strchrnul.m4: Update.
3461 * gnulib/import/m4/strdup.m4: Update.
3462 * gnulib/import/m4/strerror.m4: Update.
3463 * gnulib/import/m4/string_h.m4: Update.
3464 * gnulib/import/m4/strstr.m4: Update.
3465 * gnulib/import/m4/strtok_r.m4: Update.
3466 * gnulib/import/m4/sys_socket_h.m4: Update.
3467 * gnulib/import/m4/sys_stat_h.m4: Update.
3468 * gnulib/import/m4/sys_time_h.m4: Update.
3469 * gnulib/import/m4/sys_types_h.m4: Update.
3470 * gnulib/import/m4/tempname.m4: Update.
3471 * gnulib/import/m4/time_h.m4: Update.
3472 * gnulib/import/m4/unistd-safer.m4: Update.
3473 * gnulib/import/m4/unistd_h.m4: Update.
3474 * gnulib/import/m4/warn-on-use.m4: Update.
3475 * gnulib/import/m4/wchar_h.m4: Update.
3476 * gnulib/import/m4/wchar_t.m4: Update.
3477 * gnulib/import/m4/wctype_h.m4: Update.
3478 * gnulib/import/m4/wint_t.m4: Update.
3479 * gnulib/import/malloc.c: Update.
3480 * gnulib/import/malloc/scratch_buffer.h: Update.
3481 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
3482 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
3483 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
3484 * gnulib/import/malloca.c: Update.
3485 * gnulib/import/malloca.h: Update.
3486 * gnulib/import/malloca.valgrind: Update.
3487 * gnulib/import/math.in.h: Update.
3488 * gnulib/import/mbrtowc.c: Update.
3489 * gnulib/import/mbsinit.c: Update.
3490 * gnulib/import/mbsrtowcs-impl.h: Update.
3491 * gnulib/import/mbsrtowcs-state.c: Update.
3492 * gnulib/import/mbsrtowcs.c: Update.
3493 * gnulib/import/memchr.c: Update.
3494 * gnulib/import/memmem.c: Update.
3495 * gnulib/import/mempcpy.c: Update.
3496 * gnulib/import/memrchr.c: Update.
3497 * gnulib/import/mkdir.c: Update.
3498 * gnulib/import/mkstemp.c: Update.
3499 * gnulib/import/msvc-inval.c: Update.
3500 * gnulib/import/msvc-inval.h: Update.
3501 * gnulib/import/msvc-nothrow.c: Update.
3502 * gnulib/import/msvc-nothrow.h: Update.
3503 * gnulib/import/open.c: Update.
3504 * gnulib/import/openat-die.c: Update.
3505 * gnulib/import/openat-priv.h: Update.
3506 * gnulib/import/openat-proc.c: Update.
3507 * gnulib/import/openat.c: Update.
3508 * gnulib/import/openat.h: Update.
3509 * gnulib/import/opendir.c: Update.
3510 * gnulib/import/pathmax.h: Update.
3511 * gnulib/import/pipe-safer.c: Update.
3512 * gnulib/import/rawmemchr.c: Update.
3513 * gnulib/import/readdir.c: Update.
3514 * gnulib/import/readlink.c: Update.
3515 * gnulib/import/realloc.c: Update.
3516 * gnulib/import/ref-add.sin: Update.
3517 * gnulib/import/ref-del.sin: Update.
3518 * gnulib/import/rename.c: Update.
3519 * gnulib/import/rewinddir.c: Update.
3520 * gnulib/import/rmdir.c: Update.
3521 * gnulib/import/same-inode.h: Update.
3522 * gnulib/import/save-cwd.c: Update.
3523 * gnulib/import/save-cwd.h: Update.
3524 * gnulib/import/scratch_buffer.h: Update.
3525 * gnulib/import/secure_getenv.c: Update.
3526 * gnulib/import/setenv.c: Update.
3527 * gnulib/import/signal.in.h: Update.
3528 * gnulib/import/stat-time.c: Update.
3529 * gnulib/import/stat-time.h: Update.
3530 * gnulib/import/stat-w32.c: Update.
3531 * gnulib/import/stat-w32.h: Update.
3532 * gnulib/import/stat.c: Update.
3533 * gnulib/import/stdbool.in.h: Update.
3534 * gnulib/import/stddef.in.h: Update.
3535 * gnulib/import/stdint.in.h: Update.
3536 * gnulib/import/stdio.in.h: Update.
3537 * gnulib/import/stdlib.in.h: Update.
3538 * gnulib/import/str-two-way.h: Update.
3539 * gnulib/import/strchrnul.c: Update.
3540 * gnulib/import/strdup.c: Update.
3541 * gnulib/import/streq.h: Update.
3542 * gnulib/import/strerror-override.c: Update.
3543 * gnulib/import/strerror-override.h: Update.
3544 * gnulib/import/strerror.c: Update.
3545 * gnulib/import/string.in.h: Update.
3546 * gnulib/import/stripslash.c: Update.
3547 * gnulib/import/strnlen1.c: Update.
3548 * gnulib/import/strnlen1.h: Update.
3549 * gnulib/import/strstr.c: Update.
3550 * gnulib/import/strtok_r.c: Update.
3551 * gnulib/import/sys_stat.in.h: Update.
3552 * gnulib/import/sys_time.in.h: Update.
3553 * gnulib/import/sys_types.in.h: Update.
3554 * gnulib/import/tempname.c: Update.
3555 * gnulib/import/tempname.h: Update.
3556 * gnulib/import/time.in.h: Update.
3557 * gnulib/import/unistd--.h: Update.
3558 * gnulib/import/unistd-safer.h: Update.
3559 * gnulib/import/unistd.in.h: Update.
3560 * gnulib/import/unsetenv.c: Update.
3561 * gnulib/import/verify.h: Update.
3562 * gnulib/import/extra/snippet/warn-on-use.h: Update.
3563 * gnulib/import/wchar.in.h: Update.
3564 * gnulib/import/wctype.in.h: Update.
3565 * gnulib/import/xalloc-oversized.h: Update.
3566 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
3567 "53e2c179f26a890fa6685af4b6c1397ee370433b".
3568
3569 2018-09-10 Simon Marchi <simon.marchi@ericsson.com>
3570
3571 * record-btrace.c (get_thread_current_frame): Remove
3572 old_inferior_ptid.
3573
3574 2018-09-10 Jerome Guitton <guitton@adacore.com>
3575
3576 * ada-lang.c (ada_value_struct_elt): Call ada_to_fixed_type
3577 with check_tag to 1 if and only if the type is tagged and the
3578 component being searched cannot been found in the current
3579 view. Otherwise, always call ada_to_fixed_type with
3580 check_tag to 0.
3581
3582 2018-09-10 Xavier Roirand <roirand@adacore.com>
3583
3584 * ada-lang.c (ada_is_access_to_unconstrained_array): Remove static
3585 declaration.
3586 * ada-lang.h: add ada_is_access_to_unconstrained_array prototype.
3587 * ada-varobj.c (ada_varobj_get_number_of_children,
3588 ada_varobj_describe_child, ada_value_is_changeable_p): Cleanup code.
3589
3590 2018-09-10 Xavier Roirand <roirand@adacore.com>
3591
3592 * ada-valprint.c (ada_value_print): Use type instead of
3593 enclosing type.
3594
3595 2018-09-10 Xavier Roirand <roirand@adacore.com>
3596
3597 * ada-lang.c (ada_value_subscript): Handle case when parameter is
3598 an array of access to unconstrained array.
3599
3600 2018-09-10 Xavier Roirand <roirand@adacore.com>
3601
3602 * ada-lang.c (ada_is_access_to_unconstrained_array): New function.
3603 (ada_check_typedef): Use it.
3604
3605 2018-09-10 Xavier Roirand <roirand@adacore.com>
3606
3607 * ada-varobj.c (ada_varobj_describe_struct_child)
3608 (ada_varobj_describe_child): Handle union case like struct one.
3609
3610 2018-09-10 Tom Tromey <tom@tromey.com>
3611
3612 PR python/18380:
3613 * python/python.c (_initialize_python): Make example in "python"
3614 help work in Python 3.
3615
3616 2018-09-10 Eli Zaretskii <eliz@gnu.org>
3617
3618 * Makefile.in (transformed_name): Use INSTALL_SCRIPT instead of
3619 INSTALL_PROGRAM to install gdb-add-index.sh. Don't append
3620 $(EXEEXT) to the script, as it is not a program.
3621
3622 2018-09-09 Simon Marchi <simon.marchi@ericsson.com>
3623
3624 * python/py-prettyprint.c (pretty_print_one_value): Return
3625 gdbpy_ref<>.
3626 (print_string_repr): Adjust.
3627 (apply_varobj_pretty_printer): Return gdbpy_ref<>.
3628 * python/python-internal.h (apply_varobj_pretty_printer): Return
3629 gdbpy_ref<>.
3630 * varobj.c (varobj_value_get_print_value): Adjust.
3631
3632 2018-09-08 Tom Tromey <tom@tromey.com>
3633
3634 PR python/16047:
3635 * python/py-prettyprint.c (pretty_print_one_value): Check for
3636 to_string method.
3637
3638 2018-09-08 Joel Brobecker <brobecker@adacore.com>
3639
3640 * ada-lang.c (resolve_subexp): Pass correct OPLEN in call to
3641 replace_operator_with_call.
3642
3643 2018-09-08 Joel Brobecker <brobecker@adacore.com>
3644
3645 * ada-lang.c (ada_value_cast): Remove unnecessary parentheses.
3646
3647 2018-09-08 Joel Brobecker <brobecker@adacore.com>
3648
3649 * ada-typeprint.c (print_range): Print the bounds using TYPE
3650 rather than its TYPE_TARGET_TYPE.
3651
3652 2018-09-08 Joel Brobecker <brobecker@adacore.com>
3653
3654 * ada-lang.c (ada_to_fixed_value): Minor reformatting in
3655 call to ada_to_fixed_value_create.
3656
3657 2018-09-08 Jerome Guitton <guitton@adacore.com>
3658
3659 * ada-lang.c (ada_decode): strip dot prefix in symbol name.
3660
3661 2018-09-08 Joel Brobecker <brobecker@adacore.com>
3662
3663 * ada-lang.c (ada_exception_sal): Replace gdb_assert calls
3664 by calls to error.
3665
3666 2018-09-08 Joel Brobecker <brobecker@adacore.com>
3667
3668 * ada-lang.c (ada_unhandled_exception_name_addr_from_raise):
3669 Move update of loop variable "fi".
3670
3671 2018-09-08 Joel Brobecker <brobecker@adacore.com>
3672
3673 * ada-lang.c (value_assign_to_component): In the case of
3674 big-endian targets, extract the bits of the given VAL
3675 using an src_offset of zero if container is not a scalar.
3676
3677 2018-09-06 Simon Ser <contact@emersion.fr>
3678
3679 PR gdb/23105
3680 * fbsd-nat.c (fbsd_nat_target::xfer_partial): Add support for
3681 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
3682 * fbsd-tdep.c (fbsd_make_note_desc): New.
3683 (fbsd_make_corefile_notes): Write NT_PROCSTAT_AUXV,
3684 NT_PROCSTAT_VMMAP and NT_PROCSTAT_PS_STRINGS notes.
3685 * target.h (enum target_object) Add FreeBSD-specific
3686 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
3687
3688 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
3689
3690 * compile/compile-c.h (generate_c_for_variable_locations):
3691 Change reference to pointer.
3692 * compile/compile-c-support.c (compile_program) <compute>:
3693 Likewise.
3694 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
3695 (generate_c_for_for_one_variable): Likewise
3696 (generate_c_for_variable_locations): Likewise
3697 * compile/compile-c-types.c (compile_c_instance::convert_type):
3698 Likewise
3699 * compile/compile-cplus-symbols.c (convert_one_symbol):
3700 std::move the scope passed to enter_scope.
3701 * compile/compile-cplus-types.c
3702 (compile_cplus_instance::enter_scope): Make parameter
3703 rvalue-reference.
3704 (compile_cplus_instance::new_scope): Change reference to
3705 pointer.
3706 (compile_cplus_instance::convert_type): Likewise
3707 (compile_cplus_convert_typedef): std::move the scope passed to
3708 enter_scope.
3709 (compile_cplus_convert_struct_or_union): Likewise.
3710 (compile_cplus_convert_enum): Likewise.
3711 (compile_cplus_convert_namespace): Likewise.
3712 * compile/compile-cplus.h (compile_cplus_instance)
3713 <enter_scope>: Make parameter rvalue-reference.
3714 * compile/compile-internal.h (compile_instance)
3715 <get_cached_type>: Likewise
3716 * compile/compile-loc2c.c (push): Likewise
3717 (pushf): Likewise
3718 (unary): Likewise
3719 (binary): Likewise
3720 (print_label): Likewise
3721 (pushf_register_address): Likewise
3722 (pushf_register): Likewise
3723 (do_compile_dwarf_expr_to_c): Likewise
3724 (compile_dwarf_expr_to_c): Likewise
3725 (compile_dwarf_bounds_to_c): Likewise
3726 * compile/compile.c (compile_instance::get_cached_type):
3727 Likewise
3728 * compile/compile.h (compile_dwarf_expr_to_c): Likewise.
3729 (compile_dwarf_bounds_to_c): Likewise
3730 * dwarf2loc.c (locexpr_generate_c_location): Likewise.
3731 (dwarf2_compile_property_to_c): Likewise
3732 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise
3733 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
3734 Likewise
3735
3736 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
3737
3738 * tui/tui-data.h (struct tui_win_element) <highlight>: Remove.
3739 * tui/tui-data.c (init_content_element): Don't initialize it.
3740
3741 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
3742
3743 * tui/tui-data.h (struct tui_win_info)
3744 <detail::opaque>: Remove.
3745 * tui/tui-data.c (init_win_info): Remove assignment.
3746
3747 2018-09-05 Tom Tromey <tom@tromey.com>
3748
3749 * warning.m4 (AM_GDB_WARNINGS): Add -Wformat when testing
3750 -Wformat-nonliteral.
3751 * target-float.c (host_float_ops<T>::to_string)
3752 (host_float_ops<T>::from_string): Use
3753 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
3754 * configure: Rebuild.
3755
3756 2018-09-05 Simon Marchi <simon.marchi@ericsson.com>
3757
3758 * printcmd.c (printf_c_string): Use
3759 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
3760 (printf_wide_c_string, printf_pointer, ui_printf): Likewise.
3761
3762 2018-09-05 Tom Tromey <tom@tromey.com>
3763
3764 * cli/cli-cmds.c (shell_escape, edit_command): Remove cast.
3765
3766 2018-09-05 Tom de Vries <tdevries@suse.de>
3767
3768 * dwarf2loc.c (sect_variable_value): Call indirect_synthetic_pointer
3769 with resolve_abstract_p == true.
3770 (indirect_synthetic_pointer): Add resolve_abstract_p parameter,
3771 defaulting to false. Propagate resolve_abstract_p to
3772 dwarf2_fetch_die_loc_sect_off.
3773 * dwarf2loc.h (dwarf2_fetch_die_loc_sect_off): Add resolve_abstract_p
3774 parameter, defaulting to false.
3775 * dwarf2read.c (read_variable): Add variable to abstract_to_concrete.
3776 (dwarf2_fetch_die_loc_sect_off): Add and handle resolve_abstract_p
3777 parameter.
3778 * dwarf2read.h (struct die_info): Forward-declare.
3779 (die_info_ptr): New typedef.
3780 (struct dwarf2_per_objfile): Add abstract_to_concrete field.
3781
3782 2018-09-05 Joel Brobecker <brobecker@adacore.com>
3783
3784 GDB 8.2 released.
3785
3786 2018-09-04 Sergio Durigan Junior <sergiodj@redhat.com>
3787 Pedro Alves <palves@redhat.com>
3788
3789 * gnulib/Makefile.in (aclocal_m4_deps): Move to
3790 "aclocal-m4-deps.mk". Include file here.
3791 $(srcdir)/aclocal.m4: Add "configure.ac".
3792 * gnulib/aclocal-m4-deps.mk: New file.
3793 * gnulib/update-gnulib.sh: Automatically update
3794 "aclocal-m4-deps.mk".
3795
3796 2018-09-04 Tom Tromey <tom@tromey.com>
3797
3798 * configure: Rebuild.
3799 * configure.ac: Remove multi-ice code.
3800
3801 2018-09-04 Tom Tromey <tom@tromey.com>
3802
3803 * Makefile.in (GDB_WARN_CFLAGS_NO_DEFS): Remove.
3804 (ada-exp.o): Update.
3805
3806 2018-09-04 Tom Tromey <tom@tromey.com>
3807
3808 * Makefile.in (printcmd.o, target-float.o): Remove.
3809 (GDB_WARN_CFLAGS_NO_FORMAT): Remove.
3810
3811 2018-09-04 Tom Tromey <tom@tromey.com>
3812
3813 * gnulib/Makefile.in: Remove obsolete comment.
3814 * Makefile.in: Remove obsolete comment.
3815
3816 2018-09-04 Andrew Burgess <andrew.burgess@embecosm.com>
3817
3818 * riscv-tdep.c (riscv_frame_cache): Fix ARI warning, don't end a
3819 line with '+'.
3820
3821 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
3822
3823 * riscv-tdep.c: Add 'prologue-value.h' include.
3824 (struct riscv_unwind_cache): New struct.
3825 (riscv_debug_unwinder): New global.
3826 (riscv_scan_prologue): Update arguments, capture register details
3827 from prologue scan.
3828 (riscv_skip_prologue): Reformat arguments line, move end of
3829 prologue calculation into riscv_scan_prologue.
3830 (riscv_frame_cache): Update return type, create
3831 riscv_unwind_cache, scan the prologue, and fill in remaining cache
3832 details.
3833 (riscv_frame_this_id): Use frame id computed in riscv_frame_cache.
3834 (riscv_frame_prev_register): Use the trad_frame within the
3835 riscv_unwind_cache.
3836 (_initialize_riscv_tdep): Add 'set/show debug riscv unwinder'
3837 flag.
3838
3839 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
3840
3841 * trad-frame.h (trad_frame_set_realreg): Declare.
3842 (trad_frame_set_addr): Declare.
3843 * trad-frame.c (trad_frame_set_realreg): Define new function.
3844 (trad_frame_set_addr): Define new function.
3845 (trad_frame_set_reg_realreg): Use new function.
3846 (trad_frame_set_reg_addr): Use new function.
3847
3848 2018-09-01 Keith Seitz <keiths@redhat.com>
3849
3850 * compile/compile-cplus-types.c (compile_cplus_debug_output_1): Use
3851 pulongest instead of "%lld".
3852 * compile/compile-cplus-symbols.c (gcc_cplus_convert_symbol): Remove
3853 ATTRIBUTE_UNUSED.
3854
3855 2018-08-31 Tom Tromey <tom@tromey.com>
3856
3857 * dwarf2read.c (dwarf2_add_field): Set the TYPE_LENGTH of the
3858 variant part type.
3859
3860 2018-08-31 Pedro Alves <palves@redhat.com>
3861
3862 * gdbarch.h: Regenerate.
3863
3864 2018-08-31 Pedro Alves <palves@redhat.com>
3865
3866 * gdbarch.sh (have_nonsteppable_watchpoint): Add comment.
3867 * target.h (Hardware watchpoint interfaces): Describe
3868 continuable/steppable/non-steppable watchpoints.
3869 * gdbarch.h, gdbarch.c: Regenerate.
3870
3871 2018-08-31 Pedro Alves <palves@redhat.com>
3872
3873 * nto-procfs.c (nto_procfs_target::have_continuable_watchpoint):
3874 Delete.
3875 * s390-linux-nat.c
3876 (s390_linux_nat_target::have_continuable_watchpoint): Delete.
3877 * target.h (target_ops::have_continuable_watchpoint): Delete.
3878 (target_have_continuable_watchpoint): Delete.
3879 * x86-nat.h (x86_nat_target::have_continuable_watchpoint): Delete.
3880 * target-delegates.c: Regenerate.
3881
3882 2018-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
3883
3884 * gnulib/Makefile.in (aclocal_m4_deps): Update according to
3885 the files present in "gnulib/import/m4/".
3886
3887 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
3888
3889 * riscv-tdep.c (riscv_insn::decode): Decode c.addi4spn, c.sd,
3890 c.sw, c.swsp, and c.sdsp.
3891
3892 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
3893
3894 * riscv-tdep.c (struct riscv_inferior_data): Delete.
3895 (riscv_read_misa_reg): Don't cache value read into inferior data.
3896 (riscv_new_inferior_data): Delete.
3897 (riscv_inferior_data_cleanup): Delete.
3898 (riscv_inferior_data): Delete.
3899 (riscv_invalidate_inferior_data): Delete.
3900 (_initialize_riscv_tdep): Remove initialisation of inferior data.
3901
3902 2018-08-30 Simon Marchi <simon.marchi@ericsson.com>
3903
3904 * compile/compile-cplus-types.c
3905 (compile_cplus_instance::leave_scope): Take the address of scope
3906 object.
3907 (compile_cplus_instance::convert_qualified_base): Compare quals
3908 to 0.
3909
3910 2018-08-30 Keith Seitz <keiths@redhat.com>
3911
3912 * compile/compile-cplus-types.c (compile_cplus_instance::enter_scope):
3913 Use "%s" and host_address_to_string instead of "%p" in printf.
3914
3915 2018-08-29 Keith Seitz <keiths@redhat.com>
3916
3917 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Add compile-cplus-symbols.c
3918 and compile-cplus-types.c.
3919 (HFILES_NO_SRCDIR): Add gcc-cp-plugin.h.
3920 * c-lang.c (cplus_language_defn): Set C++ compile functions.
3921 * c-lang.h (cplus_get_compile_context, cplus_compute_program):
3922 Declare.
3923 * compile/compile-c-support.c: Include compile-cplus.h.
3924 (load_libcompile): Templatize.
3925 (get_compile_context): "New" function.
3926 (c_get_compile_context): Use get_compile_context.
3927 (cplus_get_compile_context): New function.
3928 (cplus_push_user_expression, cplus_pop_user_expression)
3929 (cplus_add_code_header, cplus_add_input, cplus_compile_program)
3930 (cplus_compute_program): Define new structs/functions.
3931 * compile/compile-cplus-symmbols.c: New file.
3932 * compile/compile-cplus-types.c: New file.
3933 * compile/compile-cplus.h: New file.
3934 * compile/compile-internal.h (debug_compile_oracle, GCC_TYPE_NONE):
3935 Declare.
3936 * compile/compile-object-load.c (get_out_value_type): Use
3937 strncmp_iw when comparing symbol names.
3938 (compile_object_load): Add mst_bss and mst_data.
3939 * compile/compile.c (_initialize_compile): Remove
3940 -Wno-implicit-function-declaration from `compile_args'.
3941 * compile/gcc-cp-plugin.h: New file.
3942 * NEWS: Mention C++ compile support and new debug options.
3943
3944 2018-08-29 Keith Seitz <keiths@redhat.com>
3945
3946 * linespec.c (collect_info::add_symbol): Make virtual.
3947 (struct symbol_searcher_collect_info): New struct.
3948 (symbol_searcher::find_all_symbols): New method.
3949 * symtab.h (class symbol_searcher): New class.
3950
3951 2018-08-29 Keith Seitz <keiths@redhat.com>
3952
3953 * linespec.c (struct linespec) <function_symbols, label_symbols>:
3954 Change to vector of block_symbol. Update all users.
3955 (struct collect_info) <symbols>: Likewise.
3956 (collect_info::add_symbol): Take block_symbol as argument.
3957 Update all callers.
3958 (decode_compound_collector) <m_symbols>: Change type to vector
3959 of block_symbol. Update all users.
3960 (decode_compound_collector::operator ()): Change parameter type
3961 to block_symbol.
3962 (find_method, find_function_symbols, find_linespec_symbols)
3963 (find_label_symbols_in_block, find_label_symbols): Change symbol
3964 vectors to block_symbol vectors.
3965 * symtab.h (symbol_found_callback_ftype): Change parameter type to
3966 block_symbol.
3967
3968 2018-08-29 Keith Seitz <keiths@redhat.com>
3969
3970 * linespec.c (symbolp): Remove typedef and VEC definitions.
3971 (bound_minimal_symbol_d): Likewise.
3972
3973 2018-08-29 Keith Seitz <keiths@redhat.com>
3974
3975 * linespec.c (decode_compound_collector::decode_compound_collector):
3976 Remove initialization for `m_symtabs'.
3977 (decode_compound_collector::release_symbols): Change return type
3978 to std::vector. Update all callers.
3979 (class decode_compound_collector) <m_symbols>: Change type to
3980 std::vector.
3981 (lookup_prefix_sym): Change return type to std::vector. Update all
3982 callers.
3983 (compare_symbols): Remove.
3984 (std_compare_symbols): Rename to `compare_symbols'.
3985 (find_method): Change `sym_classes' parameter to std::vector.
3986 Update all callers. Use std::sort to sort sym_classes.
3987 (find_linespec_symbols): Remove cleanup.
3988
3989 2018-08-29 Keith Seitz <keiths@redhat.com>
3990
3991 * linespec.c (struct linespec) <minimal_symbols>: Change type to
3992 std::vector. Update all users.
3993 (convert_linespec_to_sals): Use std::sort to sort minimal symbols.
3994 (struct collect_info) <minimal_symbols>: Likewise.
3995 (compare_msymbols): Return bool. Change parameters to const
3996 bound_minimal_symbol references.
3997 (find_method, find_function_symbols, find_linespec_symbols): Change
3998 `minsyms' parameter to std::vector. Update all callers.
3999
4000 2018-08-29 Keith Seitz <keiths@redhat.com>
4001
4002 * linespec.c (struct linespec) <label_symbols>: Change type to
4003 std::vector. Update all users.
4004 (find_label_symbols_in_block): Change `result' parameter to
4005 std::vector. Update all callers.
4006 (find_label_symbols): Return std::vector. Update all callers.
4007
4008 2018-08-29 Keith Seitz <keiths@redhat.com>
4009
4010 * linespec.c (struct linespec) <function_symbols>: Change type to
4011 std::vector. Update all users.
4012 (struct collect_info) <function_symbols>: Likewise.
4013 (convert_linespec_to_sals): Use std::sort to sort function_symbols.
4014 (std_compare_symbols): New function.
4015 (find_method, find_function_symbols, find_linespec_symbols)
4016 (find_label_symbols_in_block): Change `symbols' parameter to
4017 std::vector. Update all callers.
4018 (find_label_symbols): Likewise for `function_symbols' and
4019 `label_funcs_ret'.
4020
4021 2018-08-29 Keith Seitz <keiths@redhat.com>
4022
4023 * linespec.c (symtab_vector_up): Define.
4024 (struct linespec) <file_symtabs>: Change type to std::vector *.
4025 Update all uses.
4026 (struct collect_info) <file_symtabs>: Likewise.
4027 (collect_symtabs_from_filename): Return symtab_vector_up.
4028 Update all callers.
4029 (decode_objc): Remove cleanup.
4030 (symtab_collector::symtab_collector): Initialize `m_symtabs'.
4031 (symtab_collector::release_symtabs): Return symtab_vector_up.
4032 Update all callers.
4033 (class symtab_collector) <m_symtabs>: Change type to symtab_vector_up.
4034 Update all users.
4035 (collect_symtabs_from_filename, symtabs_from_filename): Return
4036 symtab_vector_up. Update all callers.
4037
4038 2018-08-29 Tom Tromey <tom@tromey.com>
4039
4040 * csky-tdep.c (csky_analyze_prologue): Use
4041 core_addr_to_string_nz.
4042
4043 2018-08-29 Tom Tromey <tom@tromey.com>
4044
4045 * windows-nat.c (struct xlate_exception) <them>: Change type to
4046 DWORD.
4047 (xlate): Fix formatting. Remove last entry.
4048 (struct xlate_exception, xlate): Comment out.
4049 (windows_nat_target::resume): Use ranged for.
4050
4051 2018-08-29 Jim Wilson <jimw@sifive.com>
4052
4053 * riscv-linux-nat.c: Include elf/common.h instead of elf.h.
4054 (riscv_linux_nat_target::fetch_registers): Use NT_FPREGSET instead
4055 of NT_PRFPREG.
4056 (riscv_linux_nat_target::store_registers): Likewise.
4057
4058 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
4059
4060 PR gdb/23555
4061 PR gdb/23558
4062 * gnulib/aclocal.m4: Regenerate.
4063 * gnulib/config.in: Regenerate.
4064 * gnulib/configure: Regenerate.
4065 * gnulib/import/Makefile.am: Update.
4066 * gnulib/import/Makefile.in: Update.
4067 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
4068 * gnulib/import/_Noreturn.h: ... this.
4069 * gnulib/import/alloca.in.h: Update.
4070 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
4071 * gnulib/import/arg-nonnull.h: ... this.
4072 * gnulib/import/assure.h: Update.
4073 * gnulib/import/at-func.c: Update.
4074 * gnulib/import/basename-lgpl.c: Update.
4075 * gnulib/import/extra/snippet/c++defs.h: Rename to...
4076 * gnulib/import/c++defs.h: ... this.
4077 * gnulib/import/canonicalize-lgpl.c: Update.
4078 * gnulib/import/cdefs.h: Update.
4079 * gnulib/import/chdir-long.c: Update.
4080 * gnulib/import/chdir-long.h: Update.
4081 * gnulib/import/cloexec.c: Update.
4082 * gnulib/import/cloexec.h: Update.
4083 * gnulib/import/close.c: Update.
4084 * gnulib/import/closedir.c: Update.
4085 * gnulib/import/config.charset: Update.
4086 * gnulib/import/dirent-private.h: Update.
4087 * gnulib/import/dirent.in.h: Update.
4088 * gnulib/import/dirfd.c: Update.
4089 * gnulib/import/dirname-lgpl.c: Update.
4090 * gnulib/import/dirname.h: Update.
4091 * gnulib/import/dosname.h: Update.
4092 * gnulib/import/dup-safer-flag.c: Update.
4093 * gnulib/import/dup-safer.c: Update.
4094 * gnulib/import/dup.c: Update.
4095 * gnulib/import/dup2.c: Update.
4096 * gnulib/import/errno.in.h: Update.
4097 * gnulib/import/error.c: Update.
4098 * gnulib/import/error.h: Update.
4099 * gnulib/import/exitfail.c: Update.
4100 * gnulib/import/exitfail.h: Update.
4101 * gnulib/import/extra/update-copyright: Update.
4102 * gnulib/import/fchdir.c: Update.
4103 * gnulib/import/fcntl.c: Update.
4104 * gnulib/import/fcntl.in.h: Update.
4105 * gnulib/import/fd-hook.c: Update.
4106 * gnulib/import/fd-hook.h: Update.
4107 * gnulib/import/fd-safer-flag.c: Update.
4108 * gnulib/import/fd-safer.c: Update.
4109 * gnulib/import/fdopendir.c: Update.
4110 * gnulib/import/filename.h: Update.
4111 * gnulib/import/filenamecat-lgpl.c: Update.
4112 * gnulib/import/filenamecat.h: Update.
4113 * gnulib/import/flexmember.h: Update.
4114 * gnulib/import/float+.h: Update.
4115 * gnulib/import/float.c: Update.
4116 * gnulib/import/float.in.h: Update.
4117 * gnulib/import/fnmatch.c: Update.
4118 * gnulib/import/fnmatch.in.h: Update.
4119 * gnulib/import/fnmatch_loop.c: Update.
4120 * gnulib/import/fpucw.h: Update.
4121 * gnulib/import/frexp.c: Update.
4122 * gnulib/import/frexpl.c: Update.
4123 * gnulib/import/fstat.c: Update.
4124 * gnulib/import/fstatat.c: Update.
4125 * gnulib/import/getcwd-lgpl.c: Update.
4126 * gnulib/import/getcwd.c: Update.
4127 * gnulib/import/getdtablesize.c: Update.
4128 * gnulib/import/getlogin_r.c: Update.
4129 * gnulib/import/getprogname.c: Update.
4130 * gnulib/import/getprogname.h: Update.
4131 * gnulib/import/gettext.h: Update.
4132 * gnulib/import/gettimeofday.c: Update.
4133 * gnulib/import/glob-libc.h: Update.
4134 * gnulib/import/glob.c: Update.
4135 * gnulib/import/glob.in.h: Update.
4136 * gnulib/import/glob_internal.h: Update.
4137 * gnulib/import/glob_pattern_p.c: Update.
4138 * gnulib/import/globfree.c: Update.
4139 * gnulib/import/hard-locale.c: Update.
4140 * gnulib/import/hard-locale.h: Update.
4141 * gnulib/import/intprops.h: Update.
4142 * gnulib/import/inttypes.in.h: Update.
4143 * gnulib/import/isnan.c: Update.
4144 * gnulib/import/isnand-nolibm.h: Update.
4145 * gnulib/import/isnand.c: Update.
4146 * gnulib/import/isnanl-nolibm.h: Update.
4147 * gnulib/import/isnanl.c: Update.
4148 * gnulib/import/itold.c: Update.
4149 * gnulib/import/libc-config.h: Update.
4150 * gnulib/import/limits.in.h: Update.
4151 * gnulib/import/localcharset.c: Update.
4152 * gnulib/import/localcharset.h: Update.
4153 * gnulib/import/localtime-buffer.c: Update.
4154 * gnulib/import/localtime-buffer.h: Update.
4155 * gnulib/import/lstat.c: Update.
4156 * gnulib/import/m4/00gnulib.m4: Update.
4157 * gnulib/import/m4/__inline.m4: Update.
4158 * gnulib/import/m4/absolute-header.m4: Update.
4159 * gnulib/import/m4/alloca.m4: Update.
4160 * gnulib/import/m4/builtin-expect.m4: Update.
4161 * gnulib/import/m4/canonicalize.m4: Update.
4162 * gnulib/import/m4/chdir-long.m4: Update.
4163 * gnulib/import/m4/close.m4: Update.
4164 * gnulib/import/m4/closedir.m4: Update.
4165 * gnulib/import/m4/configmake.m4: Update.
4166 * gnulib/import/m4/d-ino.m4: Update.
4167 * gnulib/import/m4/d-type.m4: Update.
4168 * gnulib/import/m4/dirent_h.m4: Update.
4169 * gnulib/import/m4/dirfd.m4: Update.
4170 * gnulib/import/m4/dirname.m4: Update.
4171 * gnulib/import/m4/double-slash-root.m4: Update.
4172 * gnulib/import/m4/dup.m4: Update.
4173 * gnulib/import/m4/dup2.m4: Update.
4174 * gnulib/import/m4/eealloc.m4: Update.
4175 * gnulib/import/m4/environ.m4: Update.
4176 * gnulib/import/m4/errno_h.m4: Update.
4177 * gnulib/import/m4/error.m4: Update.
4178 * gnulib/import/m4/exponentd.m4: Update.
4179 * gnulib/import/m4/exponentl.m4: Update.
4180 * gnulib/import/m4/extensions.m4: Update.
4181 * gnulib/import/m4/extern-inline.m4: Update.
4182 * gnulib/import/m4/fchdir.m4: Update.
4183 * gnulib/import/m4/fcntl-o.m4: Update.
4184 * gnulib/import/m4/fcntl.m4: Update.
4185 * gnulib/import/m4/fcntl_h.m4: Update.
4186 * gnulib/import/m4/fdopendir.m4: Update.
4187 * gnulib/import/m4/filenamecat.m4: Update.
4188 * gnulib/import/m4/flexmember.m4: Update.
4189 * gnulib/import/m4/float_h.m4: Update.
4190 * gnulib/import/m4/fnmatch.m4: Update.
4191 * gnulib/import/m4/fnmatch_h.m4: Update.
4192 * gnulib/import/m4/fpieee.m4: Update.
4193 * gnulib/import/m4/frexp.m4: Update.
4194 * gnulib/import/m4/frexpl.m4: Update.
4195 * gnulib/import/m4/fstat.m4: Update.
4196 * gnulib/import/m4/fstatat.m4: Update.
4197 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
4198 * gnulib/import/m4/getcwd-path-max.m4: Update.
4199 * gnulib/import/m4/getcwd.m4: Update.
4200 * gnulib/import/m4/getdtablesize.m4: Update.
4201 * gnulib/import/m4/getlogin.m4: Update.
4202 * gnulib/import/m4/getlogin_r.m4: Update.
4203 * gnulib/import/m4/getpagesize.m4: Update.
4204 * gnulib/import/m4/getprogname.m4: Update.
4205 * gnulib/import/m4/gettimeofday.m4: Update.
4206 * gnulib/import/m4/glibc21.m4: Update.
4207 * gnulib/import/m4/glob.m4: Update.
4208 * gnulib/import/m4/glob_h.m4: Update.
4209 * gnulib/import/m4/gnulib-cache.m4: Update.
4210 * gnulib/import/m4/gnulib-common.m4: Update.
4211 * gnulib/import/m4/gnulib-comp.m4: Update.
4212 * gnulib/import/m4/gnulib-tool.m4: Update.
4213 * gnulib/import/m4/hard-locale.m4: Update.
4214 * gnulib/import/m4/include_next.m4: Update.
4215 * gnulib/import/m4/inttypes-pri.m4: Update.
4216 * gnulib/import/m4/inttypes.m4: Update.
4217 * gnulib/import/m4/isnand.m4: Update.
4218 * gnulib/import/m4/isnanl.m4: Update.
4219 * gnulib/import/m4/largefile.m4: Update.
4220 * gnulib/import/m4/limits-h.m4: Update.
4221 * gnulib/import/m4/localcharset.m4: Update.
4222 * gnulib/import/m4/locale-fr.m4: Update.
4223 * gnulib/import/m4/locale-ja.m4: Update.
4224 * gnulib/import/m4/locale-zh.m4: Update.
4225 * gnulib/import/m4/localtime-buffer.m4: Update.
4226 * gnulib/import/m4/longlong.m4: Update.
4227 * gnulib/import/m4/lstat.m4: Update.
4228 * gnulib/import/m4/malloc.m4: Update.
4229 * gnulib/import/m4/malloca.m4: Update.
4230 * gnulib/import/m4/math_h.m4: Update.
4231 * gnulib/import/m4/mbrtowc.m4: Update.
4232 * gnulib/import/m4/mbsinit.m4: Update.
4233 * gnulib/import/m4/mbsrtowcs.m4: Update.
4234 * gnulib/import/m4/mbstate_t.m4: Update.
4235 * gnulib/import/m4/memchr.m4: Update.
4236 * gnulib/import/m4/memmem.m4: Update.
4237 * gnulib/import/m4/mempcpy.m4: Update.
4238 * gnulib/import/m4/memrchr.m4: Update.
4239 * gnulib/import/m4/mkdir.m4: Update.
4240 * gnulib/import/m4/mkstemp.m4: Update.
4241 * gnulib/import/m4/mmap-anon.m4: Update.
4242 * gnulib/import/m4/mode_t.m4: Update.
4243 * gnulib/import/m4/msvc-inval.m4: Update.
4244 * gnulib/import/m4/msvc-nothrow.m4: Update.
4245 * gnulib/import/m4/multiarch.m4: Update.
4246 * gnulib/import/m4/nocrash.m4: Update.
4247 * gnulib/import/m4/off_t.m4: Update.
4248 * gnulib/import/m4/onceonly.m4: Update.
4249 * gnulib/import/m4/open-cloexec.m4: Update.
4250 * gnulib/import/m4/open.m4: Update.
4251 * gnulib/import/m4/openat.m4: Update.
4252 * gnulib/import/m4/opendir.m4: Update.
4253 * gnulib/import/m4/pathmax.m4: Update.
4254 * gnulib/import/m4/rawmemchr.m4: Update.
4255 * gnulib/import/m4/readdir.m4: Update.
4256 * gnulib/import/m4/readlink.m4: Update.
4257 * gnulib/import/m4/realloc.m4: Update.
4258 * gnulib/import/m4/rename.m4: Update.
4259 * gnulib/import/m4/rewinddir.m4: Update.
4260 * gnulib/import/m4/rmdir.m4: Update.
4261 * gnulib/import/m4/save-cwd.m4: Update.
4262 * gnulib/import/m4/secure_getenv.m4: Update.
4263 * gnulib/import/m4/setenv.m4: Update.
4264 * gnulib/import/m4/signal_h.m4: Update.
4265 * gnulib/import/m4/ssize_t.m4: Update.
4266 * gnulib/import/m4/stat-time.m4: Update.
4267 * gnulib/import/m4/stat.m4: Update.
4268 * gnulib/import/m4/std-gnu11.m4: Update.
4269 * gnulib/import/m4/stdbool.m4: Update.
4270 * gnulib/import/m4/stddef_h.m4: Update.
4271 * gnulib/import/m4/stdint.m4: Update.
4272 * gnulib/import/m4/stdio_h.m4: Update.
4273 * gnulib/import/m4/stdlib_h.m4: Update.
4274 * gnulib/import/m4/strchrnul.m4: Update.
4275 * gnulib/import/m4/strdup.m4: Update.
4276 * gnulib/import/m4/strerror.m4: Update.
4277 * gnulib/import/m4/string_h.m4: Update.
4278 * gnulib/import/m4/strstr.m4: Update.
4279 * gnulib/import/m4/strtok_r.m4: Update.
4280 * gnulib/import/m4/sys_socket_h.m4: Update.
4281 * gnulib/import/m4/sys_stat_h.m4: Update.
4282 * gnulib/import/m4/sys_time_h.m4: Update.
4283 * gnulib/import/m4/sys_types_h.m4: Update.
4284 * gnulib/import/m4/tempname.m4: Update.
4285 * gnulib/import/m4/time_h.m4: Update.
4286 * gnulib/import/m4/unistd-safer.m4: Update.
4287 * gnulib/import/m4/unistd_h.m4: Update.
4288 * gnulib/import/m4/warn-on-use.m4: Update.
4289 * gnulib/import/m4/wchar_h.m4: Update.
4290 * gnulib/import/m4/wchar_t.m4: Update.
4291 * gnulib/import/m4/wctype_h.m4: Update.
4292 * gnulib/import/m4/wint_t.m4: Update.
4293 * gnulib/import/malloc.c: Update.
4294 * gnulib/import/malloc/scratch_buffer.h: Update.
4295 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
4296 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
4297 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
4298 * gnulib/import/malloca.c: Update.
4299 * gnulib/import/malloca.h: Update.
4300 * gnulib/import/malloca.valgrind: Update.
4301 * gnulib/import/math.in.h: Update.
4302 * gnulib/import/mbrtowc.c: Update.
4303 * gnulib/import/mbsinit.c: Update.
4304 * gnulib/import/mbsrtowcs-impl.h: Update.
4305 * gnulib/import/mbsrtowcs-state.c: Update.
4306 * gnulib/import/mbsrtowcs.c: Update.
4307 * gnulib/import/memchr.c: Update.
4308 * gnulib/import/memmem.c: Update.
4309 * gnulib/import/mempcpy.c: Update.
4310 * gnulib/import/memrchr.c: Update.
4311 * gnulib/import/mkdir.c: Update.
4312 * gnulib/import/mkstemp.c: Update.
4313 * gnulib/import/msvc-inval.c: Update.
4314 * gnulib/import/msvc-inval.h: Update.
4315 * gnulib/import/msvc-nothrow.c: Update.
4316 * gnulib/import/msvc-nothrow.h: Update.
4317 * gnulib/import/open.c: Update.
4318 * gnulib/import/openat-die.c: Update.
4319 * gnulib/import/openat-priv.h: Update.
4320 * gnulib/import/openat-proc.c: Update.
4321 * gnulib/import/openat.c: Update.
4322 * gnulib/import/openat.h: Update.
4323 * gnulib/import/opendir.c: Update.
4324 * gnulib/import/pathmax.h: Update.
4325 * gnulib/import/pipe-safer.c: Update.
4326 * gnulib/import/rawmemchr.c: Update.
4327 * gnulib/import/readdir.c: Update.
4328 * gnulib/import/readlink.c: Update.
4329 * gnulib/import/realloc.c: Update.
4330 * gnulib/import/ref-add.sin: Update.
4331 * gnulib/import/ref-del.sin: Update.
4332 * gnulib/import/rename.c: Update.
4333 * gnulib/import/rewinddir.c: Update.
4334 * gnulib/import/rmdir.c: Update.
4335 * gnulib/import/same-inode.h: Update.
4336 * gnulib/import/save-cwd.c: Update.
4337 * gnulib/import/save-cwd.h: Update.
4338 * gnulib/import/scratch_buffer.h: Update.
4339 * gnulib/import/secure_getenv.c: Update.
4340 * gnulib/import/setenv.c: Update.
4341 * gnulib/import/signal.in.h: Update.
4342 * gnulib/import/stat-time.c: Update.
4343 * gnulib/import/stat-time.h: Update.
4344 * gnulib/import/stat-w32.c: Update.
4345 * gnulib/import/stat-w32.h: Update.
4346 * gnulib/import/stat.c: Update.
4347 * gnulib/import/stdbool.in.h: Update.
4348 * gnulib/import/stddef.in.h: Update.
4349 * gnulib/import/stdint.in.h: Update.
4350 * gnulib/import/stdio.in.h: Update.
4351 * gnulib/import/stdlib.in.h: Update.
4352 * gnulib/import/str-two-way.h: Update.
4353 * gnulib/import/strchrnul.c: Update.
4354 * gnulib/import/strdup.c: Update.
4355 * gnulib/import/streq.h: Update.
4356 * gnulib/import/strerror-override.c: Update.
4357 * gnulib/import/strerror-override.h: Update.
4358 * gnulib/import/strerror.c: Update.
4359 * gnulib/import/string.in.h: Update.
4360 * gnulib/import/stripslash.c: Update.
4361 * gnulib/import/strnlen1.c: Update.
4362 * gnulib/import/strnlen1.h: Update.
4363 * gnulib/import/strstr.c: Update.
4364 * gnulib/import/strtok_r.c: Update.
4365 * gnulib/import/sys_stat.in.h: Update.
4366 * gnulib/import/sys_time.in.h: Update.
4367 * gnulib/import/sys_types.in.h: Update.
4368 * gnulib/import/tempname.c: Update.
4369 * gnulib/import/tempname.h: Update.
4370 * gnulib/import/time.in.h: Update.
4371 * gnulib/import/unistd--.h: Update.
4372 * gnulib/import/unistd-safer.h: Update.
4373 * gnulib/import/unistd.in.h: Update.
4374 * gnulib/import/unsetenv.c: Update.
4375 * gnulib/import/verify.h: Update.
4376 * gnulib/import/extra/snippet/warn-on-use.h: Update.
4377 * gnulib/import/wchar.in.h: Update.
4378 * gnulib/import/wctype.in.h: Update.
4379 * gnulib/import/xalloc-oversized.h: Update.
4380 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
4381 "53e2c179f26a890fa6685af4b6c1397ee370433b".
4382
4383 2018-08-16 Gary Benson <gbenson@redhat.com>
4384
4385 PR gdb/13000:
4386 * gdb/main.c (captured_main_1): Exit with nonzero status
4387 in batch mode if the last command to be executed failed.
4388 * NEWS: Mention the above.
4389
4390 2018-08-29 Simon Marchi <simon.marchi@ericsson.com>
4391
4392 * csky-tdep.c (csky_memory_insert_breakpoint): Remove newline at
4393 end of warning message.
4394
4395 2018-08-29 Alan Hayward <alan.hayward@arm.com>
4396
4397 PR gdb/22943:
4398 * aarch64-tdep.c (is_hfa_or_hva): Remove function.
4399 (aarch64_extract_return_value): Use
4400 aapcs_is_vfp_call_or_return_candidate.
4401 (aarch64_return_in_memory): Likewise.
4402 (aarch64_store_return_value): Likewise.
4403
4404 2018-08-29 Alan Hayward <alan.hayward@arm.com>
4405
4406 * aarch64-tdep.c
4407 (aapcs_is_vfp_call_or_return_candidate): Make static
4408 (pass_in_v_or_stack): Remove function.
4409 (pass_in_v_vfp_candidate): New function.
4410 (aarch64_push_dummy_call): Check for float register candidates.
4411
4412 2018-08-29 Alan Hayward <alan.hayward@arm.com>
4413
4414 * aarch64-tdep.c (HA_MAX_NUM_FLDS): New macro.
4415 (aapcs_is_vfp_call_or_return_candidate_1): New function.
4416 (aapcs_is_vfp_call_or_return_candidate): Likewise.
4417
4418 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
4419
4420 PR build/23399
4421 * common/agent.c (IPA_SYM_STRUCT_NAME): Define.
4422 (struct ipa_sym_addresses): Rename to...
4423 (struct ipa_sym_addresses_common): ... this.
4424 * common/agent.h (IPA_SYM): Use IPA_SYM_STRUCT_NAME.
4425
4426 2018-08-28 Tom Tromey <tom@tromey.com>
4427
4428 * c-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
4429 (token_fifo): Now a std::vector.
4430 (yylex, c_parse): Update.
4431 * d-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
4432 (token_fifo): Now a std::vector.
4433 (yylex, d_parse): Update.
4434 * go-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
4435 (token_fifo): Now a std::vector.
4436 (yylex, go_parse): Update.
4437
4438 2018-08-28 Simon Marchi <simon.marchi@ericsson.com>
4439
4440 * parser-defs.h (struct type_stack) <elements>: Change type to
4441 std::vector<union type_stack_elt>.
4442 <depth, size>: Remove.
4443 * parse.c (parse_exp_in_context_1): Adjust.
4444 (type_stack_reserve): Remove.
4445 (check_type_stack_depth): Remove.
4446 (insert_into_type_stack): Adjust to std::vector.
4447 (insert_type): Likewise.
4448 (push_type): Likewise.
4449 (push_type_int): Likewise.
4450 (insert_type_address_space): Likewise.
4451 (pop_type): Likewise.
4452 (pop_type_int): Likewise.
4453 (pop_typelist): Likewise.
4454 (pop_type_stack): Likewise.
4455 (append_type_stack): Likewise.
4456 (push_type_stack): Likewise.
4457 (get_type_stack): Likewise.
4458 (type_stack_cleanup): Likewise.
4459 (push_typelist): Likewise.
4460 (follow_types): Likewise.
4461 (_initialize_parse): Likewise.
4462
4463 2018-08-28 Hafiz Abid Qadeer <abidh@codesourcery.com>
4464
4465 * NEWS: Mention csky target.
4466
4467 2018-08-28 Jiangshuai Li <jiangshuai_li@c-sky.com>
4468 Hafiz Abid Qadeer <abidh@codesourcery.com>
4469 Don Breazeal <donb@codesourcery.com>
4470
4471 * csky-linux-tdep.c: New file.
4472 * csky-tdep.c: Likewise.
4473 * csky-tdep.h: Likewise.
4474 * Makefile.in (ALL_TARGET_OBS): Add csky-linux-tdep.o and
4475 csky-tdep.o.
4476 (HFILES_NO_SRCDIR): Add csky-tdep.h.
4477 (ALLDEPFILES): Add csky-linux-tdep.c and csky-tdep.c
4478 * configure.tgt: Add csky support.
4479
4480 2018-08-27 Jan Vrany <jan.vrany@fit.cvut.cz>
4481
4482 * python/py-framefilter.c (py_print_frame): Print frame architecture
4483 when printing on an MI output.
4484
4485 2018-08-27 Tom Tromey <tom@tromey.com>
4486
4487 PR build/23087:
4488 * configure: Rebuild.
4489 * warning.m4 (AM_GDB_WARNINGS): Remove -Wno-narrowing.
4490
4491 2018-08-27 Tom Tromey <tom@tromey.com>
4492
4493 * aarch64-linux-tdep.c
4494 (aarch64_linux_iterate_over_regset_sections) <sve_regmap>: Add
4495 casts to int.
4496
4497 2018-08-27 Tom Tromey <tom@tromey.com>
4498
4499 * ppc64-tdep.c (insn_d, insn_ds, insn_xfx): Add casts to
4500 unsigned.
4501 (ppc64_standard_linkage1, ppc64_standard_linkage2)
4502 (ppc64_standard_linkage3, ppc64_standard_linkage4)
4503 (ppc64_standard_linkage5, ppc64_standard_linkage6)
4504 (ppc64_standard_linkage7, ppc64_standard_linkage8): Add casts to
4505 unsigned.
4506
4507 2018-08-27 Tom Tromey <tom@tromey.com>
4508
4509 * xtensa-tdep.h (XTREG_END): Add cast to unsigned.
4510 (XTENSA_GDBARCH_TDEP_INSTANTIATE): Likewise.
4511
4512 2018-08-27 Tom Tromey <tom@tromey.com>
4513
4514 * tramp-frame.h (TRAMP_SENTINEL_INSN): Redefine.
4515 * tilegx-linux-tdep.c (tilegx_linux_rt_sigframe): Use
4516 ULONGEST_MAX.
4517 * tic6x-linux-tdep.c (tic6x_linux_rt_sigreturn_tramp_frame): Use
4518 ULONGEST_MAX.
4519 * sparc64-linux-tdep.c (sparc64_linux_rt_sigframe): Use
4520 ULONGEST_MAX.
4521 * sparc-linux-tdep.c (sparc32_linux_sigframe)
4522 (sparc32_linux_rt_sigframe): Use ULONGEST_MAX.
4523 * ppc-nbsd-tdep.c (ppcnbsd_sigtramp, ppcnbsd2_sigtramp): Use
4524 ULONGEST_MAX.
4525 * ppc-linux-tdep.c (ppc32_linux_sigaction_tramp_frame)
4526 (ppc64_linux_sigaction_tramp_frame)
4527 (ppc32_linux_sighandler_tramp_frame)
4528 (ppc64_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
4529 * nios2-linux-tdep.c (nios2_r1_linux_rt_sigreturn_tramp_frame)
4530 (nios2_r2_linux_rt_sigreturn_tramp_frame): Use ULONGEST_MAX.
4531 * mn10300-linux-tdep.c (am33_linux_sigframe)
4532 (am33_linux_rt_sigframe): Use ULONGEST_MAX.
4533 * mips64-obsd-tdep.c (mips64obsd_sigframe): Use ULONGEST_MAX.
4534 * mips-linux-tdep.c (mips_linux_o32_sigframe)
4535 (mips_linux_o32_rt_sigframe, mips_linux_n32_rt_sigframe)
4536 (mips_linux_n64_rt_sigframe, micromips_linux_o32_sigframe)
4537 (micromips_linux_o32_rt_sigframe, micromips_linux_n32_rt_sigframe)
4538 (micromips_linux_n64_rt_sigframe): Use ULONGEST_MAX.
4539 * mips-fbsd-tdep.c (mips_fbsd_sigframe, mipsn32_fbsd_sigframe)
4540 (mips64_fbsd_sigframe): Use ULONGEST_MAX.
4541 * microblaze-linux-tdep.c
4542 (microblaze_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
4543 * i386-nbsd-tdep.c (i386nbsd_sigtramp_sc16, i386nbsd_sigtramp_sc2)
4544 (i386nbsd_sigtramp_si2, i386nbsd_sigtramp_si31)
4545 (i386nbsd_sigtramp_si4): Use ULONGEST_MAX.
4546 * hppa-nbsd-tdep.c (hppanbsd_sigtramp_si4): Use ULONGEST_MAX.
4547 * common/common-types.h (ULONGEST_MAX): New define.
4548 (CORE_ADDR_MAX): Fix formatting.
4549 * bfin-linux-tdep.c (bfin_linux_sigframe): Use ULONGEST_MAX.
4550 * arm-obsd-tdep.c (armobsd_sigframe): Use ULONGEST_MAX.
4551 * arm-linux-tdep.c (arm_linux_sigreturn_tramp_frame)
4552 (arm_linux_rt_sigreturn_tramp_frame)
4553 (arm_eabi_linux_sigreturn_tramp_frame)
4554 (arm_eabi_linux_rt_sigreturn_tramp_frame)
4555 (thumb2_eabi_linux_sigreturn_tramp_frame)
4556 (thumb2_eabi_linux_rt_sigreturn_tramp_frame)
4557 (arm_linux_restart_syscall_tramp_frame)
4558 (arm_kernel_linux_restart_syscall_tramp_frame): Use ULONGEST_MAX.
4559 * arm-fbsd-tdep.c (arm_fbsd_sigframe): Use ULONGEST_MAX.
4560 * aarch64-linux-tdep.c (aarch64_linux_rt_sigframe): Use
4561 ULONGEST_MAX.
4562 * aarch64-fbsd-tdep.c (aarch64_fbsd_sigframe): Use ULONGEST_MAX.
4563
4564 2018-08-27 Tom Tromey <tom@tromey.com>
4565
4566 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Use
4567 CORE_ADDR_MAX.
4568 * mips-tdep.c (mips_deal_with_atomic_sequence)
4569 (micromips_deal_with_atomic_sequence): Use CORE_ADDR_MAX.
4570 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw)
4571 (arm_deal_with_atomic_sequence_raw): Use CORE_ADDR_MAX.
4572 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Use
4573 CORE_ADDR_MAX.
4574 * aarch64-tdep.c (aarch64_software_single_step): Use
4575 CORE_ADDR_MAX.
4576
4577 2018-08-27 Tom Tromey <tom@tromey.com>
4578
4579 * linespec.c (complete_linespec_component): Add cast to "char".
4580 * completer.c (completion_tracker::build_completion_result): Add
4581 cast to "char".
4582
4583 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
4584
4585 * solist.h (struct solist, struct target_so_ops): Fix
4586 indentation.
4587
4588 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
4589
4590 * ada-tasks.c (ada_task_info_s): Remove typedef.
4591 (DEF_VEC_O(ada_task_info_s)): Remove.
4592 (struct ada_tasks_inferior_data): Initialize fields.
4593 <task_list>: Make an std::vector.
4594 (get_ada_tasks_inferior_data): Allocate with new.
4595 (ada_get_task_number): Adjust.
4596 (get_task_number_from_id): Likewise.
4597 (valid_task_id): Likewise.
4598 (ada_get_task_info_from_ptid): Likewise.
4599 (iterate_over_live_ada_tasks): Likewise.
4600 (add_ada_task): Likewise.
4601 (read_known_tasks): Likewise.
4602 (ada_build_task_list): Likewise.
4603 (print_ada_task_info): Likewise.
4604 (info_task): Likewise.
4605 (task_command_1): Likewise.
4606
4607 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
4608
4609 * ada-lang.c (add_angle_brackets): Return std::string.
4610
4611 2018-08-25 Simon Marchi <simon.marchi@polymtl.ca>
4612
4613 * python/py-threadevent.c (py_get_event_thread): Initialize
4614 pythread.
4615
4616 2018-08-24 Pedro Alves <palves@redhat.com>
4617
4618 * python/py-bpevent.c (create_breakpoint_event_object): Use
4619 copy-initialization.
4620 * python/py-continueevent.c (emit_continue_event): Use
4621 copy-initialization.
4622 * python/py-exitedevent.c (create_exited_event_object): Return a
4623 gdbpy_ref<>.
4624 (emit_exited_event): Use copy-initialization.
4625 * python/py-inferior.c (python_new_inferior)
4626 (python_inferior_deleted, add_thread_object): Use
4627 copy-initialization.
4628 * python/py-infevents.c (create_inferior_call_event_object)
4629 (create_register_changed_event_object)
4630 (create_memory_changed_event_object): Return a gdbpy_ref<>.
4631 (emit_inferior_call_event, emit_memory_changed_event)
4632 (emit_register_changed_event): Use copy-initialization.
4633 * python/py-newobjfileevent.c (create_new_objfile_event_object):
4634 Return a gdbpy_ref<>.
4635 (emit_new_objfile_event): Use copy-initialization.
4636 (create_clear_objfiles_event_object): Return a gdbpy_ref<>.
4637 (emit_clear_objfiles_event): Use copy-initialization.
4638 * python/py-signalevent.c (create_signal_event_object): Use
4639 copy-initialization.
4640 * python/py-threadevent.c (create_thread_event_object): Use
4641 copy-initialization.
4642
4643 2018-08-24 Pedro Alves <palves@redhat.com>
4644 Simon Marchi <simon.marchi@ericsson.com>
4645
4646 PR gdb/23379
4647 * python/py-continueevent.c: Include "gdbthread.h".
4648 (create_continue_event_object): Add intro comment. Add 'ptid'
4649 parameter. Use it to find thread to pass to
4650 create_thread_event_object.
4651 (emit_continue_event): Pass PTID down to
4652 create_continue_event_object.
4653 * python/py-event.h (py_get_event_thread): Declare.
4654 (create_thread_event_object): Remove default from 'thread'
4655 parameter.
4656 * python/py-stopevent.c (create_stop_event_object): Use
4657 py_get_event_thread.
4658 * python/py-threadevent.c (get_event_thread): Rename to ...
4659 (py_get_event_thread): ... this, make extern, add 'ptid' parameter
4660 and use it to find the thread.
4661 (create_thread_event_object): Assert that THREAD isn't null.
4662 Don't find the event thread here.
4663
4664 2018-08-23 Kevin Buettner <kevinb@redhat.com>
4665
4666 * block.h (blockrange, blockranges): New struct declarations.
4667 (struct block): Add new field named `ranges'.
4668 (BLOCK_RANGES, BLOCK_NRANGES, BLOCK_RANGE, BLOCK_CONTIGUOUS_P)
4669 (BLOCK_RANGE_START, BLOCK_RANGE_END, BLOCK_ENTRY_PC): New
4670 macros for accessing ranges in struct block.
4671 (make_blockranges): New declaration.
4672 block.c (make_blockranges): New function.
4673 * dwarf2read.c (dwarf2_record_block_ranges): Fill in BLOCK_RANGES
4674 for block.
4675 * symtab.h (find_pc_partial_function): Add new parameter `block'.
4676 * blockframe.c (cache_pc_function_block): New static global.
4677 (clear_pc_function_cache): Clear cache_pc_function_block.
4678 (find_pc_partial_function): Move comment to symtab.h. Add
4679 support for non-contiguous blocks.
4680 * cli/cli-cmds.c (block.h): Include.
4681 (print_disassembly): Handle printing of non-contiguous blocks.
4682 (disassemble_current_function): Likewise.
4683 (disassemble_command): Likewise.
4684
4685 * ax-gdb.c (gen_var_ref): Use BLOCK_ENTRY_PC in place of
4686 BLOCK_START.
4687 * blockframe.c (get_pc_function_start): Likewise.
4688 * compile/compile-c-symbols.c (convert_one_symbol): Likewise.
4689 (gcc_symbol_address): Likewise.
4690 * compile/compile-object-run.c (compile_object_run): Likewise.
4691 * compile/compile.c (get_expr_block_and_pc): Likewise.
4692 * dwarf2loc.c (dwarf2_find_location_expression): Likewise.
4693 (func_addr_to_tail_call_list): Likewise.
4694 * findvar.c (default_read_var_value): Likewise.
4695 * inline-frame.c (inline_frame_this_id): Likewise.
4696 (skip-inline_frames): Likewise.
4697 * infcmd.c (until_next_command): Likewise.
4698 * linespec.c (convert_linespec_to_sals): Likewise.
4699 * parse.c (parse_exp_in_context_1): Likewise.
4700 * printcmd.c (build_address_symbolic): likewise.
4701 (info_address_command): Likewise.
4702 symtab.c (find_function_start_sal): Likewise.
4703 (skip_prologue_sal): Likewise.
4704 (find_function_alias_target): Likewise.
4705 (find_gnu_ifunc): Likewise.
4706 * stack.c (find_frame_funname): Likewise.
4707 * symtab.c (fixup_symbol_section): Likewise.
4708 (find_function_start_sal): Likewise.
4709 (skip_prologue_sal): Likewsie.
4710 (find_function_alias_target): Likewise.
4711 (find_gnu_ifunc): Likewise.
4712 * tracepoint.c (info_scope_command): Likewise.
4713 * value.c (value_fn_field): Likewise.
4714
4715 * infrun.c (fill_in_stop_func): Use find_function_entry_range_from_pc
4716 in place of find_pc_partial_function.
4717 * blockframe.c (find_function_entry_range_from_pc): New function.
4718 * symtab.h (find_function_entry_range_from_pc): Declare and document.
4719 * objfiles.c (objfile_relocate1): Relocate start and end addresses
4720 for each range in a block.
4721
4722
4723 2018-08-23 Xavier Roirand <roirand@adacore.com>
4724
4725 * machoread.c (macho_symfile_read_all_oso): Remove uneeded
4726 incrementation.
4727
4728 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
4729
4730 * solib-svr4.c (read_program_headers_from_bfd): Return
4731 gdb::optional<gdb::byte_vector>.
4732 (svr4_exec_displacement): Adjust.
4733
4734 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
4735
4736 * solib-svr4.c (read_program_header): Return
4737 gdb::optional<gdb::byte_vector>, remove p_sect_size param.
4738 (find_program_interpreter): Return
4739 gdb::optional<gdb::byte_vector>.
4740 (scan_dyntag_auxv): Adjust.
4741 (enable_break): Adjust.
4742 (svr4_exec_displacement): Adjust.
4743
4744 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
4745
4746 * inf-child.h (inf_child_target) <terminal_save_inferior>: New.
4747 * inf-child.c (inf_child_target::terminal_save_inferior): New.
4748
4749 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
4750
4751 * guile/scm-string.c (gdbscm_scm_from_printf): Use
4752 string_vprintf.
4753 * guile/scm-utils.c (gdbscm_printf): Likewise.
4754 * serial.c (serial_printf): Likewise.
4755 * xml-support.c (gdb_xml_parser::vdebug): Likewise.
4756
4757 2018-08-22 Jan Vrany <jan.vrany@fit.cvut.cz>
4758
4759 * stack.c (print_frame): Print frame architecture when printing on
4760 an MI output.
4761 * NEWS: Mention new "arch" attribute in frame output.
4762
4763 2018-08-21 Alan Hayward <alan.hayward@arm.com>
4764
4765 * arch/aarch64.h (aarch64_regnum): Update comment.
4766
4767 2018-08-21 Alan Hayward <alan.hayward@arm.com>
4768
4769 * NEWS: Add SVE to 8.2 section.
4770
4771 2018-08-21 Pedro Alves <palves@redhat.com>
4772
4773 * guile/scm-utils.c (gdbscm_parse_function_args_1): New, factored
4774 out from gdbscm_parse_function_args.
4775 (gdbscm_parse_function_args): Rework to use gdbscm_wrap and
4776 gdbscm_parse_function_args_1.
4777
4778 2018-08-21 Simon Marchi <simon.marchi@ericsson.com>
4779
4780 PR gdb/17816
4781 * m32c-tdep.c (m32c_decode_srcdest4): Remove unnecessary ternary
4782 operator.
4783
4784 2018-08-19 Simon Marchi <simon.marchi@polymtl.ca>
4785
4786 * solib-svr4.c (svr4_exec_displacement): Fix formatting.
4787
4788 2018-08-19 Michael Spang <spang@google.com>
4789
4790 PR gdb/11786
4791 * solib-svr4.c (svr4_exec_displacement): Ignore memsz fields
4792 for PT_TLS segments.
4793
4794 2018-08-18 Kevin Buettner <kevinb@redhat.com>
4795
4796 * dwarf2expr.h (struct dwarf_expr_context): Add virtual method
4797 dwarf_variable_value.
4798 * dwarf2-frame.c (class dwarf_expr_executor):
4799 Add override for dwarf_variable_value.
4800 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Likewise.
4801 (class symbol_needs_eval_context): Likewise.
4802 (indirect_synthetic_pointer): Add forward declaration.
4803 (sect_variable_value): New function.
4804 (dwarf2_compile_expr_to_ax): Add case for DW_OP_GNU_variable_value.
4805 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Add case
4806 for DW_OP_GNU_variable_value.
4807
4808 2018-08-16 Tom Tromey <tom@tromey.com>
4809
4810 * top.c (read_command_file): Update.
4811 (command_line_input): Remove "repeat" argument.
4812 * ada-lang.c (get_selections): Update.
4813 * linespec.c (decode_line_2): Update.
4814 * defs.h (command_line_input): Remove argument.
4815 * cli/cli-script.c (read_next_line): Update.
4816 * python/py-gdb-readline.c: Update.
4817
4818 2018-08-17 Tom Tromey <tom@tromey.com>
4819
4820 * cli/cli-script.c (read_next_line): Pass 0 as repeat argument to
4821 command_line_input.
4822
4823 2018-08-15 Tom Tromey <tom@tromey.com>
4824
4825 * aarch64-linux-tdep.c (aarch64_linux_core_read_vq): Use pulongest.
4826
4827 2018-08-14 Jan Vrany <jan.vrany@fit.cvut.cz>
4828
4829 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Add -a option.
4830 If used, use find_pc_partial_function to find address range
4831 to disassemble.
4832 * mi/mi-main.c (mi_cmd_list_features): Report
4833 "data-disassemble-a-option" feature.
4834 * NEWS: Mention new -data-disassemble option -a.
4835
4836 2018-08-13 Tom Tromey <tom@tromey.com>
4837
4838 * common/common-defs.h (_FORTIFY_SOURCE): Define.
4839
4840 2018-08-13 Alan Hayward <alan.hayward@arm.com>
4841
4842 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): New function.
4843 (aarch64_linux_collect_sve_regset): Likewise.
4844 (aarch64_linux_iterate_over_regset_sections): Check for SVE.
4845 * regcache.h (regcache_map_entry_size): New function.
4846
4847 2018-08-13 Alan Hayward <alan.hayward@arm.com>
4848
4849 * aarch64-linux-tdep.c (SVE_HEADER_SIZE_LENGTH): Add define.
4850 (SVE_HEADER_MAX_SIZE_LENGTH): Likewise.
4851 (SVE_HEADER_VL_LENGTH): Likewise.
4852 (SVE_HEADER_MAX_VL_LENGTH): Likewise.
4853 (SVE_HEADER_FLAGS_LENGTH): Likewise.
4854 (SVE_HEADER_RESERVED_LENGTH): Likewise.
4855 (SVE_HEADER_SIZE_OFFSET): Likewise.
4856 (SVE_HEADER_MAX_SIZE_OFFSET): Likewise.
4857 (SVE_HEADER_VL_OFFSET): Likewise.
4858 (SVE_HEADER_MAX_VL_OFFSET): Likewise.
4859 (SVE_HEADER_FLAGS_OFFSET): Likewise.
4860 (SVE_HEADER_RESERVED_OFFSET): Likewise.
4861 (SVE_HEADER_SIZE): Likewise.
4862 (aarch64_linux_core_read_vq): Add function.
4863 (aarch64_linux_core_read_description): Check for SVE section.
4864
4865 2018-08-13 Alan Hayward <alan.hayward@arm.com>
4866
4867 * aarch64-fbsd-tdep.c
4868 (aarch64_fbsd_iterate_over_regset_sections): Add supply_size and
4869 collect_size.
4870 * aarch64-linux-tdep.c
4871 (aarch64_linux_iterate_over_regset_sections): Likewise.
4872 * alpha-linux-tdep.c
4873 (alpha_linux_iterate_over_regset_sections):
4874 * alpha-nbsd-tdep.c
4875 (alphanbsd_iterate_over_regset_sections): Likewise.
4876 * amd64-fbsd-tdep.c
4877 (amd64fbsd_iterate_over_regset_sections): Likewise.
4878 * amd64-linux-tdep.c
4879 (amd64_linux_iterate_over_regset_sections): Likewise.
4880 * arm-bsd-tdep.c
4881 (armbsd_iterate_over_regset_sections): Likewise.
4882 * arm-fbsd-tdep.c
4883 (arm_fbsd_iterate_over_regset_sections): Likewise.
4884 * arm-linux-tdep.c
4885 (arm_linux_iterate_over_regset_sections): Likewise.
4886 * corelow.c (get_core_registers_cb): Likewise.
4887 (core_target::fetch_registers): Likewise.
4888 * fbsd-tdep.c (fbsd_collect_regset_section_cb): Likewise.
4889 * frv-linux-tdep.c (frv_linux_iterate_over_regset_sections): Likewise.
4890 * gdbarch.h (void): Regenerate.
4891 * gdbarch.sh: Add supply_size and collect_size.
4892 * hppa-linux-tdep.c (hppa_linux_iterate_over_regset_sections): Likewise.
4893 * hppa-nbsd-tdep.c (hppanbsd_iterate_over_regset_sections): Likewise.
4894 * hppa-obsd-tdep.c (hppaobsd_iterate_over_regset_sections): Likewise.
4895 * i386-fbsd-tdep.c (i386fbsd_iterate_over_regset_sections): Likewise.
4896 * i386-linux-tdep.c (i386_linux_iterate_over_regset_sections): Likewise.
4897 * i386-tdep.c (i386_iterate_over_regset_sections): Likewise.
4898 * ia64-linux-tdep.c (ia64_linux_iterate_over_regset_sections): Likewise.
4899 * linux-tdep.c (linux_collect_regset_section_cb): Likewise.
4900 * m32r-linux-tdep.c (m32r_linux_iterate_over_regset_sections): Likewise.
4901 * m68k-bsd-tdep.c (m68kbsd_iterate_over_regset_sections): Likewise.
4902 * m68k-linux-tdep.c (m68k_linux_iterate_over_regset_sections): Likewise.
4903 * mips-fbsd-tdep.c (mips_fbsd_iterate_over_regset_sections): Likewise.
4904 * mips-linux-tdep.c (mips_linux_iterate_over_regset_sections): Likewise.
4905 * mips-nbsd-tdep.c (mipsnbsd_iterate_over_regset_sections): Likewise.
4906 * mips64-obsd-tdep.c (mips64obsd_iterate_over_regset_sections):
4907 Likewise.
4908 * mn10300-linux-tdep.c (am33_iterate_over_regset_sections): Likewise.
4909 * nios2-linux-tdep.c (nios2_iterate_over_regset_sections): Likewise.
4910 * ppc-fbsd-tdep.c (ppcfbsd_iterate_over_regset_sections): Likewise.
4911 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections): Likewise.
4912 * ppc-nbsd-tdep.c (ppcnbsd_iterate_over_regset_sections): Likewise.
4913 * ppc-obsd-tdep.c (ppcobsd_iterate_over_regset_sections): Likewise.
4914 * riscv-linux-tdep.c (riscv_linux_iterate_over_regset_sections):
4915 Likewise.
4916 * rs6000-aix-tdep.c (rs6000_aix_iterate_over_regset_sections): Likewise.
4917 * s390-linux-tdep.c (s390_iterate_over_regset_sections): Likewise.
4918 * score-tdep.c (score7_linux_iterate_over_regset_sections): Likewise.
4919 * sh-tdep.c (sh_iterate_over_regset_sections): Likewise.
4920 * sparc-tdep.c (sparc_iterate_over_regset_sections): Likewise.
4921 * tilegx-linux-tdep.c (tilegx_iterate_over_regset_sections): Likewise.
4922 * vax-tdep.c (vax_iterate_over_regset_sections): Likewise.
4923 * xtensa-tdep.c (xtensa_iterate_over_regset_sections): Likewise.
4924
4925 2018-08-10 Simon Marchi <simon.marchi@ericsson.com>
4926
4927 * nat/linux-osdata.c (commandline_from_pid): Replace xstrprintf
4928 with string_printf.
4929
4930 2018-08-10 Keith Seitz <keiths@redhat.com>
4931
4932 * compile/compile-c-support.c (add_code_header, add_code_footer):
4933 Move into policy class.
4934 (c_push_user_expression, pop_user_expression_nop)
4935 (c_add_code_header, c_add_code_footer, c_add_input): New policy class.
4936 (compile_program): New host class.
4937 (c_compile_program): New typedef.
4938 (c_compute_porgram): Use c_compile_program.
4939
4940 2018-08-10 Keith Seitz <keiths@redhat.com>
4941
4942 * compile/compile-internal.h (compile_instance::~compile_instance):
4943 Remove calls to htab_delete.
4944 <m_type_map, m_symbol_err_map>: Switch type to htab_up.
4945 * compile.c (compile_instance::compile_instance): Initialize
4946 htab unique pointers.
4947 (compile_instance::get_cached_type, compile_instance::insert_type)
4948 (compile_instance::error_symbol_once): Update for unique_ptr.
4949
4950 2018-08-10 Keith Seitz <keiths@redhat.com>
4951
4952 * compile/compile-c-symbols.c (struct symbol_error)
4953 (hash_symbol_error, eq_symbol_error, del_symbol_error)
4954 (compile_instance::insert_symbol_error)
4955 (compile_instance::error_symbol_once): Move to ...
4956 * compile/compile.c: ... here.
4957
4958 2018-08-10 Keith Seitz <keiths@redhat.com>
4959
4960 * compile/compile-c-support.c (c_get_compile_context): Use `new'
4961 instead of `new_compile_instance'.
4962 * compile/compile-c-symbols.c (compile_instance::insert_symbol_error):
4963 Update description.
4964 If the symbol error map is not initialized, create it.
4965 (generate_c_for_for_one_symbol): Do not check/initialize
4966 the symbol error map.
4967 * compile/compile-c-types.c (compile_c_instance): Make a class.
4968 Update all callers.
4969 (compile_instance::compile_instance): Initialize the type cache.
4970 (get_cached_type): New function.
4971 (insert_type): Update description.
4972 (compile_c_instance::m_default_cflags): Define.
4973 (convert_type): Update description. Use get_cached_type.
4974 (delete_instance): Moved to destructor.
4975 (new_compile_instance): Moved to constructor.
4976 * compile/compile-c.h (compile_c_instance): Make class inheriting
4977 from compile_instance.
4978 <base>: Remove field.
4979 <type_map, symbol_err_map>: Move to base class.
4980 <c_plugin>: Rename to `m_plugin' and remove pointer type.
4981 * compile/compile-internal.h (compile_instance): Make class.
4982 <type_map_t, symbol_err_map_t>: Define.
4983 <fe>: Rename to `m_gcc_fe'.
4984 <scope, block, gcc_target_options>: Add `m_' prefix.
4985 <m_type_map, m_symbol_err_map>: New fields, moved from
4986 compile_c_instance.
4987 <destroy>: Remove.
4988 (convert_type, new_compile_instance): Remove.
4989 * compile/compile.c (cleanup_compile_instance): Remove.
4990 (compile_to_object): Use unique_ptr to eliminate cleanups.
4991 (compile_instance::set_print_callback, compile_instance::version)
4992 (compile_instance::set_verbose)
4993 (compile_instance::set_driver_filename)
4994 (compile_instance::set_triplet_regexp)
4995 (compile_instance::set_arguments)
4996 (compile_instance::set_source_file)
4997 (compile_instance::compile): Define.
4998
4999 2018-08-10 Keith Seitz <keiths@redhat.com>
5000
5001 * Makefile.in (HFILES_NO_SRCDIR): Add compile/gcc-c-plugin.h.
5002 * compile/compile-c-types.c: Define GCC_METHODN macros and include
5003 gcc-c-fe.def to define C plugin.
5004 (delete_instance): Delete `c_plugin'.
5005 (new_compile_instance): Initialize `c_plugin'.
5006 * compile/compile-c.h: Include gcc_c_plugin.h.
5007 (struct compile_c_instance) <c_plugin>: New member.
5008 * gcc-c-plugin.h: New file.
5009 Update all callers with API change.
5010
5011 2018-08-10 Keith Seitz <keiths@redhat.com>
5012
5013 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Move header files ...
5014 (HFILES_NO_SRCDIR): ... to here.
5015 Add compile-internal.h and compile-c.h.
5016 * compile/compile-c-support.c: Include compile-c.h.
5017 * compile/compile-c-symbols.c: Include compile-c.h.
5018 (generate_c_for_variable_locations): Update comment.
5019 * compile/compile-c-types.c: Include compile-c.h.
5020 * compile/compile-c.h: New file -- moved C language declarations
5021 from other files here.
5022 * compile/compile-internal.h: Do not include hashtab.h or
5023 common/enum-flags.h.
5024 (gcc_qualifiers_flags, struct compile_c_instance, C_CTX)
5025 (gcc_convert_symbol, gcc_symbol_address)
5026 (generate_c_for_variable_locations, c_get_mode_for_size)
5027 (c_get_range_decl_name): Definitions moved to compile-c.h.
5028 * compile/compile-loc2c.c: Include compile-c.h.
5029
5030 2018-08-10 Keith Seitz <keiths@redhat.com>
5031
5032 * compile/compile-c-symbols.c (symbol_substitution_name): Rename to ...
5033 (c_symbol_substitution_name): ... this.
5034 Update all callers.
5035
5036 2018-08-10 Keith Seitz <keiths@redhat.com>
5037
5038 * compile/compile-c-support.c (c_compute_program): Use
5039 unique_xmalloc_ptr to eliminate cleanup.
5040 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
5041 Return a unique_xmalloc_ptr and eliminate cleanup.
5042 * compile/compile-internal.h (generate_c_for_variable_locations):
5043 Return unique_xmalloc_ptr and update description.
5044
5045 2018-08-10 Alan Hayward <alan.hayward@arm.com>
5046
5047 * corelow.c (core_target::get_core_register_section): Rename
5048 min_size to section_min_size.
5049
5050 2018-08-09 Jim Wilson <jimw@sifive.com>
5051
5052 * Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
5053 (ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
5054 * NEWS: Mention new GNU/Linux RISC-V target.
5055 * configure.host: Add riscv*-*-linux*.
5056 * configure.nat: Add riscv*.
5057 * configure.tgt: Add riscv*-*-linux*.
5058 * riscv-linux-nat.c: New file.
5059 * riscv-linux-tdep.c: New file.
5060
5061 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
5062
5063 * infrun.c (resume): Make static, add forward declaration.
5064 (proceed): Update header comment.
5065 * infrun.h (resume): Delete declaration.
5066
5067 2018-08-09 Tom Tromey <tom@tromey.com>
5068
5069 * riscv-tdep.h: Minor formatting fixes.
5070
5071 2018-08-09 Simon Marchi <simon.marchi@ericsson.com>
5072
5073 * common/scoped_mmap.c (mmap_file): Silence ARI warning.
5074 * dwarf-index-cache.c (create_dir_and_check): Likewise.
5075 (test_mkdir_recursive): Likewise.
5076 * dwarf-index-write.c (write_psymtabs_to_index): Likewise.
5077
5078 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
5079
5080 * valarith.c (value_subscripted_rvalue): If an array is not in
5081 memory, and we don't know the upper bound, then we can't know that
5082 the requested element exists or not.
5083
5084 2018-08-08 Simon Marchi <simon.marchi@ericsson.com>
5085
5086 * target.c (str_comma_list_concat_elem): Fix typo in comment.
5087 (target_options_to_string): Add comment.
5088
5089 2018-08-08 Tom Tromey <tom@tromey.com>
5090
5091 * unittests/scoped_mmap-selftests.c: Check result of "write".
5092
5093 2018-08-08 Jim Wilson <jimw@sifive.com>
5094
5095 * riscv-tdep.c (enum opcode): Add jump, branch, lr, and sc opcodes.
5096 (decode_register_index_short): New.
5097 (decode_j_type_insn, decode_cj_type_insn): New.
5098 (decode_b_type_insn, decode_cb_type_insn): New.
5099 (riscv_insn::decode): Add support for jumps, branches, lr, and sc. New
5100 local xlen. Check xlen when decoding ambiguous compressed insns. In
5101 compressed decode, use is_c_lui_insn instead of is_lui_insn, and
5102 is_c_sw_insn instead of is_sw_insn.
5103 (riscv_next_pc, riscv_next_pc_atomic_sequence): New.
5104 (riscv_software_single_step): New.
5105 * riscv-tdep.h (riscv_software_single_step): Declare.
5106
5107 * riscv-tdep.c (riscv_isa_xlen): Drop static.
5108 * riscv-tdep.h (riscv_isa_xlen): Add extern declaration.
5109
5110 2018-08-08 Andrew Burgess <andrew.burgess@embecosm.com>
5111
5112 PR gdb/18050:
5113 * target.c (dispose_inferior): Don't dispose of inferiors that are
5114 already killed.
5115
5116 2018-08-08 Szabolcs Nagy <szabolcs.nagy@arm.com>
5117
5118 * remote.c (remote_target::download_tracepoint): Change char* to
5119 const char*.
5120
5121 2018-08-07 Simon Marchi <simon.marchi@polymtl.ca>
5122
5123 * target.h (target_options_to_string): Return an std::string.
5124 * target.c (str_comma_list_concat_elem): Return void, use
5125 std::string.
5126 (do_option): Likewise.
5127 (target_options_to_string): Return an std::string.
5128 * linux-nat.c (linux_nat_target::wait): Adjust.
5129 * target-debug.h (target_debug_print_options): Adjust.
5130
5131 2018-08-07 Tom Tromey <tom@tromey.com>
5132
5133 * Makefile.in (CPPFLAGS): New variable.
5134 (INTERNAL_CPPFLAGS): Use it.
5135
5136 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5137
5138 * NEWS: Mention the index cache.
5139
5140 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5141
5142 * common/pathstuff.h (get_standard_cache_dir): New.
5143 * common/pathstuff.c (get_standard_cache_dir): New.
5144 * build-id.h (build_id_to_string): New.
5145 * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
5146 DEBUG_STR_SUFFIX): Move to here.
5147 * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
5148 DEBUG_STR_SUFFIX): Move from there.
5149 (write_psymtabs_to_index): Make non-static, add basename
5150 parameter. Write to temporary files, rename when done.
5151 (save_gdb_index_command): Adjust call to
5152 write_psymtabs_to_index.
5153 * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
5154 field.
5155 * dwarf2read.c (dwz_file) <index_cache_res>: New field.
5156 (get_gdb_index_contents_from_cache): New.
5157 (get_gdb_index_contents_from_cache_dwz): New.
5158 (dwarf2_initialize_objfile): Read index from cache.
5159 (dwarf2_build_psymtabs): Save to index.
5160 * dwarf-index-cache.h: New file.
5161 * dwarf-index-cache.c: New file.
5162 * dwarf-index-write.h: New file.
5163
5164 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5165
5166 * gnulib/aclocal.m4: Re-generate.
5167 * gnulib/config.in: Re-generate.
5168 * gnulib/configure: Re-generate.
5169 * gnulib/import/Makefile.am: Re-generate.
5170 * gnulib/import/Makefile.in: Re-generate.
5171 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
5172 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
5173 * gnulib/import/m4/mkdir.m4: New file.
5174 * gnulib/import/mkdir.c: New file.
5175 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
5176 module.
5177
5178 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5179
5180 * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
5181 * common/scoped_mmap.c: New file.
5182 * common/scoped_mmap.h (destroy): New method.
5183 (~scoped_mmap, reset): Use destroy.
5184 (scoped_mmap): New move constructor.
5185 (mmap_file): New declaration.
5186 * unittests/scoped_mmap-selftests.c (test_normal,
5187 test_invalid_filename, run_tests): New functions.
5188 (_initialize_scoped_mmap_selftests): Register selftest.
5189
5190 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5191
5192 * dwarf2read.c (read_gdb_index_from_section): Rename to...
5193 (read_gdb_index_from_buffer): ... this. Remove section
5194 parameter, add buffer parameter.
5195 (get_gdb_index_contents_ftype,
5196 get_gdb_index_contents_dwz_ftype): New typedefs.
5197 (dwarf2_read_gdb_index): Add callback parameters to get the
5198 index contents.
5199 (get_gdb_index_contents_from_section): New.
5200 (dwarf2_initialize_objfile): Update call to
5201 dwarf2_read_gdb_index.
5202
5203 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
5204
5205 * common/filestuff.h (gdb_fopen_cloexec): New overload.
5206 (gdb_open_cloexec): Likewise.
5207 * nat/linux-osdata.c (command_from_pid): Use string_printf.
5208 (commandline_from_pid): Likewise.
5209 (linux_xfer_osdata_threads): Likewise.
5210 (linux_xfer_osdata_fds): Likewise.
5211 * ada-lang.c (is_package_name): Likewise.
5212 * auxv.c (procfs_xfer_auxv): Likewise.
5213 * breakpoint.c (print_one_breakpoint_location): Use
5214 uiout::field_fmt.
5215 (print_one_catch_solib): Use string_printf.
5216 * coff-pe-read.c (add_pe_exported_sym): Likewise.
5217 (add_pe_forwarded_sym): Likewise.
5218 * dwarf2read.c (create_type_unit_group): Likewise.
5219 (build_error_marker_type): Likewise.
5220 * infcall.c (get_function_name): Likewise.
5221 * valprint.c (print_converted_chars_to_obstack): Likewise.
5222 * xtensa-tdep.c (xtensa_register_type): Likewise.
5223
5224 2018-08-06 Simon Marchi <simon.marchi@ericsson.com>
5225
5226 * remote.c (remote_target::download_tracepoint): Fix format
5227 string errors.
5228
5229 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5230
5231 * tracefile.c: Include common/byte-vector.h.
5232 (trace_save): Change type of buf to gdb::byte_vector. Initialize
5233 with trace_regblock_size if needed. Update uses of buf.
5234
5235 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5236
5237 * tracepoint.h (collection_list) <m_regs_mask>: Change type to
5238 std::vector<unsigned char>.
5239 * tracepoint.c (collection_list::collection_list): Remove
5240 m_regs_mask initializer from initializer list. Resize
5241 m_regs_mask using the largest remote register number.
5242 (collection_list::add_remote_register): Remove size check on
5243 m_regs_mask. Use at to access element.
5244 (collection_list::stringify): Change type of temp_buf to
5245 gdb::char_vector. Update uses of temp_buf. Resize if needed to
5246 stringify the register mask. Use pack_hex_byte for the register
5247 mask.
5248
5249 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5250
5251 * tracepoint.h (class collection_list) <add_register>: Remove.
5252 <add_remote_register, add_ax_registers, add_local_register>:
5253 Declare.
5254 <add_memrange>: Add scope parameter.
5255 * tracepoint.c (encode_actions_1): Likewise.
5256 (collection_list::add_register): Rename to ...
5257 (collection_list::add_remote_register): ... this. Update
5258 comment.
5259 (collection_list::add_ax_registers, add_local_register): New
5260 methods.
5261 (collection_list::add_memrange): Add scope parameter. Call
5262 add_local_register instead of add_register.
5263 (finalize_tracepoint_aexpr): New function.
5264 (collection_list::collect_symbol): Update calls to add_memrange.
5265 Call add_local_register instead of add_register. Call
5266 add_ax_registers. Call finalize_tracepoint_aexpr.
5267 (encode_actions_1): Get remote regnos for $reg action. Call
5268 add_remote_register, add_ax_registers, and add_local_register.
5269 Update call to add_memrange. Call finalize_tracepoint_aexpr.
5270 (validate_actionline): Call finalize_tracepoint_aexpr.
5271
5272 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5273
5274 * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
5275 Replace array buf with gdb::char_vector buf, of size
5276 get_remote_packet_size (). Replace references to buf and
5277 BUF_SIZE to buf.data () and buf.size (). Replace strcpy, strcat
5278 and xsnprintf with snprintf. Raise errors if the buffer is too
5279 small.
5280
5281 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5282
5283 * remote.c (remote_target::download_tracepoint): Fix the has_more
5284 predicate in the QTDP action list iteration.
5285
5286 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5287
5288 * remote.c (remote_target::download_tracepoint): Fix indentation
5289 in for block.
5290
5291 2018-08-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5292
5293 * proc-api.c (_initialize_proc_api): Remove c, unused.
5294 * procfs.c (procfs_init_inferior): Remove signals, unused.
5295 (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
5296 unused.
5297
5298 2018-08-06 Sergey Korolev <s.korolev@ndmsystems.com>
5299 Andrew Burgess <andrew.burgess@embecosm.com>
5300
5301 * linux-nat.c (linux_nat_target::follow_fork): Avoid using
5302 'W_STOPCODE (0)' as this could be ambiguous.
5303
5304 2018-08-03 Sergio Durigan Junior <sergiodj@redhat.com>
5305
5306 * ser-tcp.c (net_open): Fix thinko when deciding whether to
5307 disable TCP's Nagle algorithm (use "ai_protocol" instead of
5308 "ai_socktype").
5309
5310 2018-08-02 Tom Tromey <tom@tromey.com>
5311
5312 PR symtab/16842.
5313 * dwarf2read.c (read_func_scope): Set symtab on template parameter
5314 symbols.
5315 (process_structure_scope): Likewise.
5316
5317 2018-08-02 Xavier Roirand <roirand@adacore.com>
5318
5319 PR gdb/22629:
5320 * darwin-nat.c (darwin_kill_inferior): Fix handling of
5321 kill inferior.
5322
5323 2018-08-02 Tom Tromey <tom@tromey.com>
5324
5325 * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
5326 (darwin_suspend_inferior, darwin_resume_inferior)
5327 (darwin_decode_notify_message, darwin_resume_inferior_threads)
5328 (darwin_check_new_threads): Check result of get_darwin_inferior.
5329
5330 2018-07-31 Joel Brobecker <brobecker@adacore.com>
5331
5332 GDB 8.1.1 released.
5333
5334 2018-07-31 Jan Vrany <jan.vrany@fit.cvut.cz>
5335
5336 * varobj.c (varobj_get_path_expr_parent): Report an error if
5337 parent is a dynamic varobj.
5338
5339 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
5340
5341 * gnulib/aclocal.m4: Re-generate.
5342 * gnulib/config.in: Re-generate.
5343 * gnulib/configure: Re-generate.
5344 * gnulib/import/Makefile.in: Re-generate.
5345 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
5346 * gnulib/import/m4/onceonly.m4: Re-generate.
5347
5348 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
5349
5350 * target-descriptions.c (struct xml_test_tdesc): New.
5351 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
5352 (record_xml_tdesc): Update.
5353 (maintenance_check_xml_descriptions): Update.
5354 * target-descriptions.h (record_xml_tdesc): Update comment.
5355
5356 2018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
5357
5358 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
5359 checking array bounds are defined.
5360
5361 2018-07-30 Tom Tromey <tom@tromey.com>
5362
5363 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
5364 irreflexivity violation.
5365
5366 2018-07-30 Tom Tromey <tom@tromey.com>
5367
5368 * cli/cli-decode.c (lookup_cmd): Remove lint code.
5369 * value.c (unpack_long): Remove lint code.
5370 * valops.c (value_ind): Remove lint code.
5371 * valarith.c (value_x_binop, value_x_unop, value_equal)
5372 (value_pos): Remove lint code.
5373
5374 2018-07-28 Tom de Vries <tdevries@suse.de>
5375
5376 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
5377 with undefined upper bound as <optimized out>.
5378
5379 2018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
5380
5381 * gcore.in: Rename variable "name" to "prefix". Expand
5382 "usage" text.
5383
5384 2018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
5385
5386 * windows-nat.c (windows_nat_target::create_inferior): Update to
5387 call close() in global namespace.
5388
5389 2018-07-26 Tom Tromey <tom@tromey.com>
5390
5391 * dwarf-index-write.c (add_address_entry): Don't add objfile
5392 offsets.
5393 * dbxread.c (find_stab_function): Rename from
5394 find_stab_function_addr. Return a bound_minimal_symbol.
5395 (read_dbx_symtab): Use raw_text_low, raw_text_high.
5396 Don't add objfile offsets.
5397 (end_psymtab): Use raw_text_low, raw_text_high,
5398 MSYMBOL_VALUE_RAW_ADDRESS.
5399 (read_ofile_symtab): Update.
5400 (process_one_symbol): Update.
5401 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
5402 offsets.
5403 (dw2_relocate): Remove.
5404 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
5405 searching addrmap.
5406 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
5407 Update.
5408 (process_psymtab_comp_unit_reader, add_partial_symbol)
5409 (add_partial_subprogram, dwarf2_ranges_read): Update.
5410 (load_partial_dies): Update.
5411 (add_address_entry): Don't add objfile offsets.
5412 (dwarf2_build_include_psymtabs): Update.
5413 (create_addrmap_from_aranges): Don't add objfile offsets.
5414 (dw2_find_pc_sect_compunit_symtab): Update.
5415 * mdebugread.c (parse_symbol): Don't add objfile offsets.
5416 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
5417 Update.
5418 (parse_partial_symbols): Don't add objfile offsets. Use
5419 raw_text_low, raw_text_high. Update.
5420 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
5421 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
5422 or call 'relocate' quick function. Clear psymbol_map.
5423 * psympriv.h (struct partial_symbol) <address>: Add section
5424 offset.
5425 <set_unrelocated_address>: Rename from set_address.
5426 <raw_text_low, raw_text_high>: New methods.
5427 <text_low, text_high>: Add objfile parameter.
5428 (add_psymbol_to_bcache): Add 'section' parameter. Call
5429 set_unrelocated_address.
5430 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
5431 (find_pc_psymbol): Update.
5432 (fixup_psymbol_section, relocate_psymtabs): Remove.
5433 (dump_psymtab, psym_functions): Update.
5434 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
5435 parameter.
5436 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
5437 (start_psymtab_common): Update.
5438 * symfile-debug.c (debug_qf_relocate): Remove.
5439 (debug_sym_quick_functions): Update.
5440 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
5441 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
5442 Update.
5443
5444 2018-07-26 Tom Tromey <tromey@redhat.com>
5445
5446 * dbxread.c (end_psymtab): Use text_high_valid and
5447 text_low_valid.
5448 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
5449 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
5450 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
5451 Update comment.
5452 <text_low_valid, text_high_valid>: New fields.
5453 <set_text_low, set_text_high>: Update.
5454 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
5455
5456 2018-07-26 Tom Tromey <tom@tromey.com>
5457
5458 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
5459 Update.
5460 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
5461 textlow and texthigh fields.
5462 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
5463 Update.
5464 * mdebugread.c (parse_lines, parse_partial_symbols)
5465 (psymtab_to_symtab_1): Update.
5466 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
5467 Rename fields. Update comment. Now private.
5468 <text_low, text_high, set_text_low, set_text_high>: New methods.
5469 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
5470 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
5471 (start_psymtab_common, maintenance_info_psymtabs)
5472 (maintenance_check_psymtabs): Update.
5473 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
5474 texthigh fields.
5475 (scan_xcoff_symtab): Update.
5476
5477 2018-07-26 Tom Tromey <tromey@redhat.com>
5478
5479 * psympriv.h (struct partial_symbol) <unrelocated_address,
5480 address, set_address>: New methods.
5481 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
5482 (fixup_psymbol_section, relocate_psymtabs): Update.
5483 (print_partial_symbols): Add 'objfile' parameter. Update.
5484 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
5485 Update.
5486
5487 2018-07-26 Tom Tromey <tom@tromey.com>
5488
5489 * dwarf-index-write.c (write_psymbols, debug_names::insert)
5490 (debug_names::write_psymbols): Update.
5491 * psympriv.h (struct partial_symbol): Derive from
5492 general_symbol_info.
5493 <obj_section>: New method.
5494 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
5495 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
5496 (find_pc_sect_psymbol, fixup_psymbol_section)
5497 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
5498 (print_partial_symbols, recursively_search_psymtabs)
5499 (compare_psymbols, psymbol_hash, psymbol_compare)
5500 (add_psymbol_to_bcache, maintenance_check_psymtabs)
5501 (psymbol_name_matches, psym_fill_psymbol_map): Update.
5502
5503 2018-07-26 Tom Tromey <tromey@redhat.com>
5504
5505 * dbxread.c (end_psymtab): Remove dead code.
5506
5507 2018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
5508
5509 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
5510 DWARF unwinders are disabled.
5511 * dwarf2-frame.c: Add dwarf2read.h include.
5512 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
5513 disabled.
5514 (dwarf2_frame_unwinders_enabled_p): Define.
5515 (show_dwarf_unwinders_enabled_p): New function.
5516 (_initialize_dwarf2_frame): Register switch to control DWARF
5517 unwinder use.
5518 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
5519 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
5520 (show_dwarf_cmdlist): Remove static keyword.
5521 * dwarf2read.h (set_dwarf_cmdlist): Declare.
5522 (show_dwarf_cmdlist): Declare.
5523 * NEWS: Document new feature.
5524
5525 2018-07-26 Tom de Vries <tdevries@suse.de>
5526
5527 PR breakpoints/23366
5528 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
5529
5530 2018-07-26 Tom de Vries <tdevries@suse.de>
5531
5532 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
5533 DW_AT_count can't be translated to a dynamic prop.
5534
5535 2018-07-25 Tom de Vries <tdevries@suse.de>
5536
5537 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
5538 try/catch.
5539
5540 2018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
5541
5542 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
5543
5544 2018-07-25 Joel Brobecker <brobecker@adacore.com>
5545
5546 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
5547
5548 2018-07-24 Keith Seitz <keiths@redhat.comt
5549
5550 PR symtab/23010
5551 * dwarf2read.c (dw2_add_symbol_to_list): New function.
5552 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
5553 instead of add_symbol_to_list.
5554 (read_file_scope): Call prepare_one_comp_unit before reading
5555 any other DIEs.
5556
5557 2018-07-24 Simon Marchi <simon.marchi@ericsson.com>
5558
5559 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
5560
5561 2018-07-24 Tom Tromey <tom@tromey.com>
5562
5563 * utils.c (malloc, realloc, free): Don't declare.
5564 * configure, config.in: Rebuild.
5565 * configure.ac: Don't check for declarations of free, malloc, or
5566 realloc.
5567
5568 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
5569
5570 * aarch64-linux-nat.c
5571 (aarch64_linux_nat_target::stopped_data_address): Remove unused
5572 variable.
5573 * arm-linux-nat.c (fetch_regs): Likewise.
5574 (store_regs): Likewise.
5575 (fetch_vfp_regs): Likewise.
5576 (store_vfp_regs): Likewise.
5577 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
5578 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
5579 (arm_linux_nat_target::insert_watchpoint): Likewise.
5580 (arm_linux_nat_target::remove_watchpoint): Likewise.
5581 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
5582 Likewise.
5583 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
5584 Likewise.
5585 * ppc-linux-nat.c (fetch_register): Likewise.
5586 (fetch_all_gp_regs): Likewise.
5587 (fetch_ppc_registers): Likewise.
5588 (store_all_gp_regs): Likewise.
5589 (store_ppc_registers): Likewise.
5590 (hwdebug_insert_point): Likewise.
5591 (can_use_watchpoint_cond_accel): Likewise.
5592 * remote-sim.c (gdb_os_write_stdout): Likewise.
5593
5594 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
5595 Tom Tromey <tom@tromey.com>
5596
5597 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
5598 test for it.
5599 * configure: Rebuild.
5600
5601 2018-07-22 Tom Tromey <tom@tromey.com>
5602
5603 * regformats/regdat.sh: Define xmltarget_${name} inside
5604 #ifndef IN_PROCESS_AGENT.
5605
5606 2018-07-22 Tom Tromey <tom@tromey.com>
5607
5608 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
5609
5610 2018-07-22 Tom Tromey <tom@tromey.com>
5611
5612 * symfile.c (reread_symbols): Notify iter, not objfile.
5613
5614 2018-07-22 Tom Tromey <tom@tromey.com>
5615
5616 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
5617 Use arch_ops.
5618 (ravenscar_thread_target::prepare_to_store): Likewise.
5619
5620 2018-07-22 Tom Tromey <tom@tromey.com>
5621
5622 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
5623 unused variable. Call value_fetch_lazy when needed.
5624 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
5625 Remove unused variable. Call value_fetch_lazy when needed.
5626
5627 2018-07-22 Tom Tromey <tom@tromey.com>
5628
5629 * m32c-tdep.c (mark_dma): Return void.
5630 (make_regs): Remove unused declarations.
5631
5632 2018-07-22 Tom Tromey <tom@tromey.com>
5633
5634 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
5635 cmdscm_get_valid_command_smob_arg_unsafe for effect.
5636 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
5637 bkscm_get_valid_block_smob_arg_unsafe for effect.
5638
5639 2018-07-22 Tom Tromey <tom@tromey.com>
5640
5641 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
5642 value_type.
5643
5644 2018-07-22 Tom Tromey <tom@tromey.com>
5645
5646 * windows-nat.c (saved_context): Conditionally define.
5647 * remote.c (remote_target::remote_btrace_maybe_reopen):
5648 Conditionally declare "warned".
5649 * inflow.c (sigquit_ours): Conditionally define.
5650 (new_tty): Move "tty" declaration inside #if.
5651 * guile/guile.c (guile_datadir): Conditionally define.
5652 * charset.c (set_be_le_names): Move some declarations inside #if.
5653 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
5654 #if.
5655 (parse_xml_btrace_conf): Likewise.
5656
5657 2018-07-22 Tom Tromey <tom@tromey.com>
5658
5659 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
5660
5661 2018-07-22 Tom Tromey <tom@tromey.com>
5662
5663 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
5664 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
5665 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
5666 * buildsym-legacy.c (get_macro_table): Remove unused variable.
5667 * stack.c (frame_apply_level_command): Remove unused variable.
5668 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
5669 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
5670 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
5671 unused variable.
5672 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
5673 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
5674 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
5675 variable.
5676 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
5677 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
5678 variable.
5679 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
5680 Remove unused variable.
5681 * cli/cli-script.c (recurse_read_control_structure): Remove unused
5682 variable.
5683 * common/tdesc.c (print_xml_feature::visit): Remove unused
5684 variable.
5685 * compile/compile-object-load.c (store_regs): Remove unused
5686 variables.
5687 * complaints.c (clear_complaints): Remove unused variable.
5688 * corelow.c (core_target_open): Remove unused variable.
5689 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
5690 variable.
5691 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
5692 variable.
5693 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
5694 variable.
5695 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
5696 variable.
5697 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
5698 variable.
5699 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
5700 variable.
5701 * ia64-tdep.c (examine_prologue): Remove unused variable.
5702 * infcall.c (run_inferior_call): Remove unused variable.
5703 * inferior.c (exit_inferior): Remove unused variable.
5704 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
5705 * linespec.c (decode_line_2): Remove unused variable.
5706 * linux-nat.c (super_close): Remove.
5707 * linux-tdep.c (linux_info_proc): Remove unused variable.
5708 * mi/mi-main.c (mi_execute_command): Remove unused variable.
5709 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
5710 Remove unused variable.
5711 * parse.c (find_minsym_type_and_address): Remove unused variable.
5712 * printcmd.c (info_symbol_command, printf_floating): Remove unused
5713 variable.
5714 * python/py-breakpoint.c (bppy_set_commands): Remove unused
5715 variable.
5716 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
5717 variables.
5718 * record-btrace.c (record_btrace_target::store_registers): Remove
5719 unused variable.
5720 (cmd_show_record_btrace_cpu): Remove unused variable.
5721 * riscv-tdep.c (riscv_register_reggroup_p)
5722 (riscv_push_dummy_call, riscv_return_value): Remove unused
5723 variable.
5724 * rust-exp.y (literal): Remove unused variable.
5725 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
5726 unused variable.
5727 <STRUCTOP_ANONYMOUS>: Likewise.
5728 * s390-linux-tdep.c (s390_linux_init_abi_31)
5729 (s390_linux_init_abi_64): Remove unused variable.
5730 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
5731 (file_select_thread, net_windows_open, _initialize_ser_windows):
5732 Remove unused variables.
5733 * symtab.c (find_pc_sect_line): Remove unused variable.
5734 * target-memory.c (compute_garbled_blocks): Remove unused
5735 variable.
5736 (target_write_memory_blocks): Remove unused variable.
5737 * target.c (target_stack::unpush): Remove unused variables.
5738 * tracepoint.c (start_tracing, all_tracepoint_actions)
5739 (merge_uploaded_trace_state_variables)
5740 (print_one_static_tracepoint_marker): Remove unused variable.
5741 * unittests/basic_string_view/element_access/char/1.cc (test01):
5742 Remove unused variable.
5743 * windows-nat.c (windows_continue, windows_add_all_dlls)
5744 (do_initial_windows_stuff, windows_nat_target::create_inferior):
5745 Remove unused variables.
5746
5747 2018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
5748
5749 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
5750 attr_profile in HAVE_ELF.
5751 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
5752 HAVE_ELF.
5753
5754 2018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
5755
5756 * frame.c (frame_register_unwind): Change parameter name.
5757 (frame_unwind_register): Likewise.
5758 (frame_unwind_register_value): Likewise.
5759 (frame_unwind_register_signed): Likewise.
5760 (frame_unwind_register_unsigned): Likewise.
5761 * frame.h (frame_register_unwind): Likewise.
5762 (frame_unwind_register): Likewise.
5763 (frame_unwind_register_value): Likewise.
5764 (frame_unwind_register_signed): Likewise.
5765 (frame_unwind_register_unsigned): Likewise.
5766 (frame_unwind_arch): Likewise.
5767
5768 2018-07-20 Maciej W. Rozycki <macro@mips.com>
5769
5770 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
5771 ISA maintenance.
5772
5773 2018-07-20 Maciej W. Rozycki <macro@mips.com>
5774
5775 * mips-linux-nat.c (mips_linux_nat_target::read_description):
5776 Call `get_ptrace_pid' rather than extracting the ptrace PID by
5777 hand.
5778
5779 2018-07-20 Keith Seitz <keiths@redhat.com>
5780
5781 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
5782 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
5783 m_compunit_symtab, m_language>: Add "m_" prefix.
5784 Update all uses.
5785 * buildsym.c: Update all uses.
5786
5787 2018-07-20 Tom Tromey <tom@tromey.com>
5788
5789 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
5790 * buildsym.h (record_line_ftype): Remove typedef.
5791
5792 2018-07-20 Tom Tromey <tom@tromey.com>
5793
5794 * buildsym-legacy.h (augment_type_symtab): Don't declare.
5795 (end_expandable_symtab): Likewise.
5796 (end_symtab_get_static_block): Likewise.
5797 (end_symtab_from_static_block): Likewise.
5798 * buildsym-legacy.c (augment_type_symtab): Remove.
5799 (end_expandable_symtab): Remove.
5800 (end_symtab_get_static_block): Remove.
5801 (end_symtab_from_static_block): Remove.
5802
5803 2018-07-20 Tom Tromey <tom@tromey.com>
5804
5805 * dwarf2read.c: Include buildsym.h.
5806 (struct dwarf2_cu) <builder>: New method.
5807 (fixup_go_packaging): Update.
5808 (process_full_comp_unit, process_full_type_unit): Update. Don't
5809 use scoped_free_pendings.
5810 (using_directives): Add "cu" parameter, remove "language".
5811 (read_import_statement, setup_type_unit_groups, )
5812 (read_func_scope, read_lexical_block_scope)
5813 (dwarf2_record_block_ranges, read_namespace): Update.
5814 (lnp_state_machine::lnp_state_machine): Add cu parameter.
5815 (lnp_state_machine::handle_end_sequence): Update.
5816 (class lnp_state_machine) <m_cu>: New member.
5817 <m_record_line_callback>: Remove.
5818 <m_currently_recording_lines>: New member.
5819 (lnp_state_machine::handle_set_file): Update.
5820 (noop_record_line): Remove.
5821 (dwarf_record_line_p): Add cu parameter.
5822 (dwarf_record_line_1, dwarf_finish_line): Likewise.
5823 (lnp_state_machine::record_line)
5824 (lnp_state_machine::lnp_state_machine)
5825 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
5826 (dwarf_decode_lines): Update.
5827 (dwarf2_start_subfile): Add cu parameter.
5828 (dwarf2_start_symtab, new_symbol): Update.
5829 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
5830 Remove dwarf2_per_objfile parameter.
5831 (dwarf_decode_macros): Update.
5832
5833 2018-07-20 Tom Tromey <tom@tromey.com>
5834
5835 * stabsread.c (define_symbol): Update.
5836 * buildsym-legacy.h (get_buildsym_compunit): Declare.
5837 * dwarf2read.c (new_symbol): Update.
5838 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
5839 * cp-namespace.c: Include buildsym.h.
5840 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
5841 * buildsym-legacy.c (get_buildsym_compunit): New function.
5842
5843 2018-07-20 Tom Tromey <tom@tromey.com>
5844
5845 * xcoffread.c: Include buildsym-legacy.h.
5846 * windows-nat.c: Include buildsym-legacy.h.
5847 * stabsread.c: Include buildsym-legacy.h.
5848 * mdebugread.c: Include buildsym-legacy.h.
5849 * buildsym-legacy.h: New file.
5850 * buildsym-legacy.c: New file, from buildsym.c.
5851 * go32-nat.c: Include buildsym-legacy.h.
5852 * dwarf2read.c: Include buildsym-legacy.h.
5853 * dbxread.c: Include buildsym-legacy.h.
5854 * cp-namespace.c: Include buildsym-legacy.h.
5855 * coffread.c: Include buildsym-legacy.h.
5856 * buildsym.h: Move some contents to buildsym-legacy.h.
5857 * buildsym.c: Include buildsym-legacy.h. Move many functions to
5858 buildsym-legacy.c.
5859 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
5860
5861 2018-07-20 Tom Tromey <tom@tromey.com>
5862
5863 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
5864 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
5865 (buildsym_compunit::buildsym_compunit)
5866 (buildsym_compunit::~buildsym_compunit)
5867 (buildsym_compunit::get_macro_table): Define.
5868
5869 2018-07-20 Tom Tromey <tom@tromey.com>
5870
5871 * buildsym.c (reset_symtab_globals): Remove.
5872 (buildsym_compunit::end_symtab_from_static_block): Update.
5873 (buildsym_compunit::augment_type_symtab): Update.
5874 (end_symtab_from_static_block): Call free_buildsym_compunit.
5875 (augment_type_symtab, end_symtab, end_expandable_symtab):
5876 Likewise.
5877
5878 2018-07-20 Tom Tromey <tom@tromey.com>
5879
5880 * arch-utils.c: Do not include buildsym.h.
5881 * mipsread.c: Do not include buildsym.h.
5882 * machoread.c: Do not include buildsym.h.
5883 * elfread.c: Do not include buildsym.h.
5884
5885 2018-07-20 Tom Tromey <tom@tromey.com>
5886
5887 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
5888 initialization.
5889 (buildsym_compunit): Add new constructor.
5890 (struct buildsym_compunit) <get_last_source_file, finish_block,
5891 record_block_range, start_subfile, patch_subfile_names,
5892 push_subfile, pop_subfile, record_line, get_compunit_symtab,
5893 set_last_source_start_addr, get_last_source_start_addr,
5894 get_local_using_directives, set_local_using_directives,
5895 get_global_using_directives, outermost_context_p,
5896 get_current_context_stack, get_context_stack_depth,
5897 get_current_subfile, get_local_symbols, get_file_symbols,
5898 get_global_symbols, record_debugformat, record_producer,
5899 push_context, pop_context, end_symtab_get_static_block,
5900 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
5901 New public methods.
5902 <record_pending_block, finish_block_internal, make_blockvector,
5903 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
5904 private methods.
5905 Update all users.
5906
5907 2018-05-22 Tom Tromey <tom@tromey.com>
5908
5909 * buildsym.c (record_pending_block): Move earlier. Remove objfile
5910 parameter.
5911 (finish_block_internal): Update.
5912
5913 2018-07-20 Tom Tromey <tom@tromey.com>
5914
5915 * buildsym.c (record_pending_block): Move earlier. Remove objfile
5916 parameter.
5917 (finish_block_internal): Update.
5918
5919 2018-07-20 Tom Tromey <tom@tromey.com>
5920
5921 * buildsym.h (EXTERN): Don't define or undef.
5922 * buildsym.c (EXTERN): Don't define.
5923
5924 2018-07-20 Tom Tromey <tom@tromey.com>
5925
5926 * buildsym.c: Remove TODO comment.
5927
5928 2018-07-20 Tom Tromey <tom@tromey.com>
5929
5930 * coffread.c (coff_symtab_read): Update.
5931 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
5932 (xcoff_new_init): Update.
5933 * mipsread.c (mipscoff_new_init): Update.
5934 * mdebugread.c (mdebug_build_psymtabs): Update.
5935 * elfread.c (elf_new_init): Update.
5936 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
5937 Update.
5938 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
5939 (coffstab_build_psymtabs, elfstab_build_psymtabs)
5940 (stabsect_build_psymtabs): Update.
5941 * buildsym.h (buildsym_init): Don't declare.
5942 * buildsym.c: Update comment.
5943 (prepare_for_building): Remove.
5944 (start_symtab, restart_symtab): Update.
5945 (reset_symtab_globals): Update comment.
5946 (buildsym_init): Remove.
5947
5948 2018-07-20 Tom Tromey <tom@tromey.com>
5949
5950 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
5951 * stabsread.c (patch_block_stabs, define_symbol, read_type)
5952 (read_enum_type, common_block_start, common_block_end)
5953 (cleanup_undefined_types_1, finish_global_stabs): Update.
5954 * mdebugread.c (psymtab_to_symtab_1): Update.
5955 * dwarf2read.c (fixup_go_packaging, read_func_scope)
5956 (read_lexical_block_scope, new_symbol): Update.
5957 * dbxread.c (process_one_symbol): Update.
5958 * coffread.c (coff_symtab_read, process_coff_symbol)
5959 (coff_read_enum_type): Update.
5960 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
5961 declare.
5962 (get_local_symbols, get_file_symbols, get_global_symbols): New
5963 functions.
5964 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
5965 m_global_symbols.
5966 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
5967 (~scoped_free_pendings): Update.
5968 (finish_block, prepare_for_building, reset_symtab_globals)
5969 (end_symtab_get_static_block, end_symtab_with_blockvector)
5970 (augment_type_symtab, push_context): Update.
5971 (get_local_symbols, get_file_symbols, get_global_symbols): New
5972 functions.
5973 (buildsym_init): Update.
5974
5975 2018-07-20 Tom Tromey <tom@tromey.com>
5976
5977 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
5978 (process_full_type_unit): Likewise.
5979 (dwarf2_start_symtab): Set list_in_scope.
5980
5981 2018-07-20 Tom Tromey <tom@tromey.com>
5982
5983 * dwarf2read.c (process_psymtab_comp_unit_reader)
5984 (build_type_psymtabs_reader): Do not set list_in_scope.
5985
5986 2018-07-20 Tom Tromey <tom@tromey.com>
5987
5988 * buildsym.c (free_pendings): Remove.
5989 (add_symbol_to_list, scoped_free_pendings)
5990 (finish_block_internal, buildsym_init): Update.
5991
5992 2018-07-20 Tom Tromey <tom@tromey.com>
5993
5994 * xcoffread.c (read_xcoff_symtab): Update.
5995 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
5996 Update.
5997 * dbxread.c (process_one_symbol): Update.
5998 * coffread.c (coff_symtab_read): Update.
5999 * buildsym.h (finish_block): Update.
6000 * buildsym.c (finish_block): Remove "listhead" argument.
6001 (end_symtab_get_static_block): Update.
6002
6003 2018-07-20 Tom Tromey <tom@tromey.com>
6004
6005 * buildsym.h (class scoped_free_pendings): Remove constructor.
6006 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
6007 method.
6008 <m_pending_block_obstack, m_pending_blocks>: New members.
6009 (pending_block_obstack, pending_blocks): Remove.
6010 (scoped_free_pendings::scoped_free_pendings): Default.
6011 (~scoped_free_pendings): Update.
6012 (free_pending_blocks): Remove.
6013 (finish_block_internal, record_pending_block, make_blockvector)
6014 (end_symtab_get_static_block, augment_type_symtab, push_context)
6015 (buildsym_init): Update.
6016
6017 2018-07-20 Tom Tromey <tom@tromey.com>
6018
6019 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
6020 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
6021 members.
6022 (pending_addrmap, pending_addrmap_obstack)
6023 (pending_addrmap_interesting): Remove.
6024 (scoped_free_pendings, record_block_range, make_blockvector)
6025 (prepare_for_building, reset_symtab_globals, buildsym_init):
6026 Update.
6027
6028 2018-07-20 Tom Tromey <tom@tromey.com>
6029
6030 * xcoffread.c (process_linenos): Update.
6031 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
6032 * mdebugread.c (psymtab_to_symtab_1): Update.
6033 * dwarf2read.c (setup_type_unit_groups)
6034 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
6035 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
6036 * dbxread.c (process_one_symbol): Update.
6037 * coffread.c (coff_symtab_read, enter_linenos)
6038 (process_coff_symbol): Update.
6039 * buildsym.h (current_subfile): Don't declare.
6040 (get_current_subfile): Declare.
6041 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
6042 member.
6043 (start_subfile, free_buildsym_compunit, push_subfile)
6044 (prepare_for_building, start_symtab): Update.
6045 (get_current_subfile): New function.
6046
6047 2018-07-20 Tom Tromey <tom@tromey.com>
6048
6049 * coffread.c (coff_symtab_read): Update.
6050 * xcoffread.c (read_xcoff_symtab): Update.
6051 * dwarf2read.c (new_symbol): Update.
6052 (read_func_scope, read_lexical_block_scope): Update.
6053 * dbxread.c (process_one_symbol): Update.
6054 * buildsym.h (context_stack, context_stack_depth): Don't declare.
6055 (outermost_context_p): Remove macro.
6056 (outermost_context_p, get_current_context_stack)
6057 (get_context_stack_depth): Declare.
6058 (pop_context): Return struct context_stack.
6059 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
6060 member.
6061 (context_stack_size): Remove.
6062 (INITIAL_CONTEXT_STACK_SIZE): Remove.
6063 (prepare_for_building, end_symtab_get_static_block)
6064 (augment_type_symtab, push_context): Update.
6065 (pop_context): Return struct context_stack.
6066 (outermost_context_p, get_current_context_stack)
6067 (get_context_stack_depth): New functions.
6068 (buildsym_init): Update.
6069
6070 2018-07-20 Tom Tromey <tom@tromey.com>
6071
6072 * rust-exp.y: Now a pure parser. Update all rules.
6073 (%union): Move earlier.
6074 (current_parser, work_obstack): Remove globals.
6075 (rust_parser, ~rust_parser): Update.
6076 (class rust_parser) <copy_name, concat3, crate_name, super_name,
6077 lex_character, lex_number, lex_string, lex_identifier,
6078 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
6079 convert_name, convert_params_to_expression,
6080 convert_ast_to_expression, ast_basic_type, ast_operation,
6081 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
6082 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
6083 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
6084 ast_array_type, ast_slice_type, ast_reference_type,
6085 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
6086 (rust_parse): Update.
6087 (rustyyerror, rustyylex): Add parser parameter.
6088 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
6089 (rust_lex_stringish_test, rust_lex_test_sequence)
6090 (rust_lex_test_trailing_dot, rust_lex_test_completion)
6091 (rust_lex_test_push_back, rust_lex_tests): Update.
6092
6093 2018-07-19 Pedro Alves <palves@redhat.com>
6094
6095 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
6096 gdb::unique_xmalloc_ptr.
6097 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
6098 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
6099 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
6100 copy-initialization.
6101 * guile/scm-pretty-print.c (ppscm_print_children): Use
6102 gdb::unique_xmalloc_ptr instead of cleanups.
6103 (gdbscm_apply_val_pretty_printer): Remove cleanups.
6104 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
6105 gdb::unique_xmalloc_ptr.
6106 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
6107 Adjust to use gdb::unique_xmalloc_ptr.
6108 * guile/scm-utils.c (extract_arg): Adjust.
6109 * guile/scm-value.c (gdbscm_value_field): Adjust to use
6110 gdb::unique_xmalloc_ptr instead of a cleanup.
6111
6112 2018-07-19 Tom Tromey <tom@tromey.com>
6113
6114 * utils.c (do_value_free_to_mark)
6115 (make_cleanup_value_free_to_mark): Remove.
6116 * utils.h (make_cleanup_value_free_to_mark): Remove.
6117
6118 2018-07-19 Pedro Alves <palves@redhat.com>
6119
6120 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
6121 forwarding reference.
6122
6123 2018-07-18 Pedro Alves <palves@redhat.com>
6124
6125 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
6126 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
6127 cleanup.
6128
6129 2018-07-18 Pedro Alves <palves@redhat.com>
6130
6131 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
6132 exceptions.
6133 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
6134 (gdbscm_wrap): New.
6135 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
6136 directly instead of a cleanup.
6137 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
6138 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
6139 (vlscm_binop_gdbthrow): New, factored out from ...
6140 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
6141 (vlscm_rich_compare): Use gdbscm_wrap.
6142 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
6143 instead of a cleanup.
6144 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
6145 cleanup.
6146 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
6147 Use xfree directly instead of a cleanup.
6148 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
6149 Adjust to use gdbscm_wrap and scoped_value_mark.
6150 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
6151 (gdbscm_value_address, gdbscm_value_dereference)
6152 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
6153 scoped_value_mark.
6154 (gdbscm_value_dynamic_type): Use scoped_value_mark.
6155 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
6156 scoped_value_mark.
6157 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
6158 gdbscm_wrap and scoped_value_mark.
6159 (gdbscm_value_to_string): Use xfree directly instead of a
6160 cleanup. Move 'buffer' unique_ptr to TRY scope.
6161 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
6162 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
6163 scoped_value_mark.
6164 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
6165 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
6166 scoped_value_mark.
6167 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
6168 gdbscm_wrap.
6169
6170 2018-07-18 Tom de Vries <tdevries@suse.de>
6171
6172 * findvar.c (default_read_var_value): Also resolve dynamic type for
6173 LOC_OPTIMIZED_OUT vars.
6174
6175 2018-07-18 Maciej W. Rozycki <macro@mips.com>
6176
6177 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
6178 decoding.
6179
6180 2018-07-17 Tom Tromey <tom@tromey.com>
6181
6182 * guile/scm-param.c (pascm_set_func, pascm_show_func)
6183 (compute_enum_list, pascm_set_param_value_x)
6184 (gdbscm_parameter_value): Update.
6185 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
6186 (gdbscm_scm_to_host_string): Update.
6187 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
6188 Update.
6189 * guile/scm-cmd.c (cmdscm_add_completion): Update.
6190 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
6191 * guile/scm-string.c (gdbscm_scm_to_string): Return
6192 unique_xmalloc_ptr.
6193 (gdbscm_scm_to_host_string): Likewise.
6194
6195 2018-07-17 Tom Tromey <tom@tromey.com>
6196
6197 * guile/guile.c (gdbscm_eval_from_control_command): Update.
6198 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
6199 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
6200 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
6201 unique_xmalloc_ptr.
6202
6203 2018-07-17 Tom Tromey <tom@tromey.com>
6204
6205 * guile/scm-param.c (pascm_signal_setshow_error): Update.
6206 * guile/guile-internal.h (gdbscm_exception_message_to_string):
6207 Update.
6208 * guile/scm-cmd.c (cmdscm_function): Update.
6209 * guile/scm-pretty-print.c
6210 (ppscm_print_exception_unless_memory_error): Update.
6211 * guile/scm-exception.c (gdbscm_exception_message_to_string):
6212 Return unique_xmalloc_ptr.
6213
6214 2018-07-17 Tom Tromey <tom@tromey.com>
6215
6216 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
6217 Use string_printf.
6218
6219 2018-07-17 Jim Wilson <jimw@sifive.com>
6220
6221 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
6222 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
6223 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
6224 unecessary braces after EF_RISCV_RVC test. Delete call to
6225 set_gdbarch_decr_pc_after_break.
6226
6227 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
6228 RISCV_LAST_FP_REGNUM + 1.
6229 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
6230
6231 2018-07-17 Tom Tromey <tom@tromey.com>
6232
6233 * configure.ac: Remove --disable-gdbcli.
6234 * configure: Rebuild.
6235 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
6236 (SUBDIR_CLI_CFLAGS): Remove.
6237 (SFILES): Use SUBDIR_CLI_SRCS.
6238 (COMMON_OBS): Use SUBDIR_CLI_OBS.
6239
6240 2018-07-17 Tom Tromey <tom@tromey.com>
6241
6242 PR gdb/18624:
6243 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
6244
6245 2018-07-16 Jim Wilson <jimw@sifive.com>
6246
6247 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
6248
6249 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
6250
6251 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
6252 variable.
6253 (libunwind_frame_sniffer): Likewise.
6254 (libunwind_frame_prev_register): Likewise.
6255 (libunwind_sigtramp_frame_sniffer): Likewise.
6256 * ia64-tdep.c (ia64_access_reg): Likewise.
6257 (ia64_access_rse_reg): Likewise.
6258 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
6259 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
6260
6261 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
6262
6263 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
6264
6265 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
6266
6267 * remote-sim.c (gdbsim_target::close,
6268 gdbsim_target::mourn_inferior): Remove unused variables.
6269
6270 2018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
6271
6272 * ia64-tdep.c (ktab_buf): New global.
6273 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
6274 (get_kernel_table): Adjust.
6275
6276 2018-07-16 Tom Tromey <tom@tromey.com>
6277
6278 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
6279 * dwarf2read.c (using_directives, new_symbol): Use
6280 outermost_context_p.
6281 * dbxread.c (process_one_symbol): Use outermost_context_p.
6282 * coffread.c (coff_symtab_read): Use outermost_context_p.
6283
6284 2018-07-16 Tom Tromey <tom@tromey.com>
6285
6286 * dwarf2read.c (using_directives, read_func_scope)
6287 (read_lexical_block_scope): Update.
6288 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
6289 * buildsym.h (local_using_directives, global_using_directives):
6290 Don't declare.
6291 (get_local_using_directives, set_local_using_directives)
6292 (get_global_using_directives): Declare.
6293 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
6294 m_global_using_directives>: New members.
6295 (finish_block_internal, prepare_for_building)
6296 (reset_symtab_globals, end_symtab_get_static_block)
6297 (push_context): Update.
6298 (get_local_using_directives, set_local_using_directives)
6299 (get_global_using_directives): New functions.
6300 (buildsym_init): Update.
6301
6302 2018-07-16 Tom Tromey <tom@tromey.com>
6303
6304 * xcoffread.c (xcoff_initial_scan): Don't call
6305 free_pending_blocks.
6306 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
6307 * buildsym.h (class scoped_free_pendings): Add constructor.
6308 (free_pending_blocks): Don't declare.
6309 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
6310 (free_pending_blocks): Now static.
6311
6312 2018-07-16 Tom Tromey <tom@tromey.com>
6313
6314 * buildsym.h (push_subfile, pop_subfile): Update declarations.
6315 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
6316 member.
6317 (struct subfile_stack): Remove.
6318 (subfile_stack): Remove.
6319 (push_subfile, pop_subfile, buildsym_init): Update.
6320
6321 2018-07-16 Tom Tromey <tom@tromey.com>
6322
6323 * buildsym.c (push_subfile): Use gdb_assert.
6324 (pop_subfile): Use gdb_assert.
6325
6326 2018-07-16 Tom Tromey <tom@tromey.com>
6327
6328 * buildsym.h (merge_symbol_lists): Remove.
6329 * buildsym.c (merge_symbol_lists): Remove.
6330
6331 2018-07-16 Tom Tromey <tom@tromey.com>
6332
6333 * stabsread.c (scan_file_globals): Update comment.
6334 * stabsread.h (scan_file_globals): Move from buildsym.h.
6335 * buildsym.h (scan_file_globals): Move to stabsread.h.
6336
6337 2018-07-16 Tom Tromey <tom@tromey.com>
6338
6339 * xcoffread.c (xcoff_new_init): Update.
6340 * mipsread.c (mipscoff_new_init): Update.
6341 * mdebugread.c (mdebug_build_psymtabs): Update.
6342 * elfread.c (elf_new_init): Update.
6343 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
6344 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
6345 * buildsym.h (buildsym_new_init): Don't declare.
6346 * buildsym.c (buildsym_new_init): Remove.
6347
6348 2018-07-16 Tom Tromey <tom@tromey.com>
6349
6350 * stabsread.h (within_function): Move from buildsym.h.
6351 * stabsread.c (start_stabs): Clear within_function.
6352 * coffread.c (coff_start_symtab): Clear within_function.
6353 * buildsym.h (within_function): Move to stabsread.h.
6354 * buildsym.c (prepare_for_building): Update.
6355
6356 2018-07-16 Tom Tromey <tom@tromey.com>
6357
6358 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
6359 * dwarf2read.c (dwarf2_start_symtab): Don't set
6360 processing_gcc_compilation.
6361 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
6362
6363 2018-07-16 Tom Tromey <tom@tromey.com>
6364
6365 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
6366 (next_symbol_text_func): Move from buildsym.h.
6367 * stabsread.c (hashname): Move from buildsym.c.
6368 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
6369 (next_symbol_text_func, hashname): Move to stabsread.h.
6370 * buildsym.c: Don't include bcache.h
6371 (hashname): Move to stasbread.c.
6372
6373 2018-07-16 Tom Tromey <tom@tromey.com>
6374
6375 * buildsym.h (context_stack_size): Don't declare.
6376 * buildsym.c (context_stack_size): New global.
6377
6378 2018-07-16 Tom Tromey <tom@tromey.com>
6379
6380 * dbxread.c (processing_acc_compilation): New global.
6381 * buildsym.h (processing_acc_compilation): Don't declare.
6382
6383 2018-07-16 Tom Tromey <tom@tromey.com>
6384
6385 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
6386 * dbxread.c (read_ofile_symtab): Update.
6387 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
6388 * buildsym.h (last_source_start_addr): Remove.
6389 (set_last_source_start_addr, get_last_source_start_addr):
6390 Declare.
6391 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
6392 parameter.
6393 (struct buildsym_compunit) <m_last_source_start_addr>: New
6394 member.
6395 (prepare_for_building): Remove start_addr parameter.
6396 (start_symtab, restart_symtab, end_symtab_get_static_block)
6397 (end_symtab_with_blockvector): Update.
6398 (set_last_source_start_addr, get_last_source_start_addr): New
6399 functions.
6400
6401 2018-07-16 Tom Tromey <tom@tromey.com>
6402
6403 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
6404 member.
6405 (have_line_numbers): Remove.
6406 (record_line, prepare_for_building, end_symtab_get_static_block)
6407 (augment_type_symtab): Update.
6408
6409 2018-07-16 Tom Tromey <tom@tromey.com>
6410
6411 * buildsym.c (~buildsym_compunit): Free the macro table.
6412 (struct buildsym_compunit) <get_macro_table, release_macros>: New
6413 methods.
6414 <m_pending_macros>: New member.
6415 (pending_macros): Remove.
6416 (~scoped_free_pendings, get_macro_table, prepare_for_building)
6417 (reset_symtab_globals, end_symtab_get_static_block)
6418 (end_symtab_with_blockvector, augment_type_symtab)
6419 (buildsym_init): Update.
6420
6421 2018-07-16 Tom Tromey <tom@tromey.com>
6422
6423 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
6424 parameter.
6425 (buildsym_compunit::set_last_source_file): New method.
6426 <m_last_source_file>: New member.
6427 (prepare_for_building): Remove "name" parameter.
6428 (start_symtab, restart_symtab, reset_symtab_globals): Update.
6429 (last_source_file): Remove.
6430 (set_last_source_file, get_last_source_file): Update.
6431
6432 2018-07-16 Tom Tromey <tom@tromey.com>
6433
6434 * buildsym.c (prepare_for_building): Add assert.
6435
6436 2018-07-16 Tom Tromey <tom@tromey.com>
6437
6438 * buildsym.c (~buildsym_compunit): Update.
6439 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
6440 (start_subfile, patch_subfile_names)
6441 (end_symtab_with_blockvector): Update.
6442
6443 2018-07-16 Tom Tromey <tom@tromey.com>
6444
6445 * buildsym.c (struct buildsym_compunit): Add constructor,
6446 destructor, initializers.
6447 (start_buildsym_compunit): Remove.
6448 (free_buildsym_compunit): Use "delete".
6449 (start_symtab, restart_symtab): Use "new".
6450
6451 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
6452
6453 * symfile.c (set_objfile_default_section_offset): Remove struct
6454 keyword.
6455
6456 2018-07-14 Stafford Horne <shorne@gmail.com>
6457
6458 * (Responsible Maintainers): Add myself as or1k maintainer.
6459
6460 2018-07-13 Tom Tromey <tom@tromey.com>
6461
6462 * symfile.c (set_objfile_default_section_offset): Use extra braces
6463 around initializer.
6464
6465 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
6466
6467 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
6468 non-branching basr.
6469
6470 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6471
6472 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6473 unittests/cli-utils-selftests.c
6474 * unittests/cli-utils-selftests.c: New file.
6475
6476 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6477
6478 * NEWS: Mention new commands. Mention change to 'thread apply'.
6479
6480 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6481
6482 * thread.c (thr_try_catch_cmd): New function.
6483 (thread_apply_all_command): Handle qcs flags.
6484 (thread_apply_command): Handle qcs flags.
6485 (taas_command): New function.
6486 (tfaas_command): New function.
6487 (_initialize_thread): Update to setup the new commands 'taas
6488 and 'tfaas'. Change doc string for 'thread apply'.
6489
6490 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6491
6492 * stack.c: (trailing_outermost_frame): New function, mostly
6493 extracted from backtrace_command_1.
6494 (leading_innermost_frame): New function.
6495 (backtrace_command_1): Update to call trailing_outermost_frame.
6496 (frame_apply_command_count): New function.
6497 (frame_apply_level_command): New function.
6498 (frame_apply_all_command): New function.
6499 (frame_apply_command): New function.
6500 (faas_command): New function.
6501 (frame_cmd_list): New variable.
6502 (_initialize_stack): Update to setup the new commands 'frame apply'
6503 and 'faas'.
6504
6505 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6506
6507 * cli-utils.c (number_or_range_parser::get_number): Only handle
6508 numbers or convenience var as numbers.
6509 (parse_flags): New function.
6510 (parse_flags_qcs): New function.
6511 (number_or_range_parser::finished): Ensure parsing end is detected
6512 before end of string.
6513 * cli-utils.h (parse_flags): New function.
6514 (parse_flags_qcs): New function.
6515 (number_or_range_parser): Remove m_finished bool.
6516 (number_or_range_parser::skip_range): Set m_in_range to false.
6517
6518 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
6519
6520 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
6521 on Windows.
6522
6523 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
6524 Jan Kratochvil <jan.kratochvil@redhat.com>
6525 Paul Fertser <fercerpav@gmail.com>
6526 Tsutomu Seki <sekiriki@gmail.com>
6527 Pedro Alves <palves@redhat.com>
6528
6529 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6530 'unittests/parse-connection-spec-selftests.c'.
6531 (COMMON_SFILES): Add 'common/netstuff.c'.
6532 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
6533 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
6534 * common/netstuff.c: New file.
6535 * common/netstuff.h: New file.
6536 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
6537 (wait_for_connect): Update comment. New parameter
6538 'gdb::optional<int> sock' instead of 'struct serial *scb'.
6539 Use 'sock' directly instead of 'scb->fd'.
6540 (try_connect): New function, with code from 'net_open'.
6541 (net_open): Rewrite main loop to deal with multiple
6542 sockets/addresses. Handle IPv6-style hostnames; implement
6543 support for IPv6 connections.
6544 * unittests/parse-connection-spec-selftests.c: New file.
6545
6546 2018-07-11 Pedro Alves <palves@redhat.com>
6547
6548 PR gdb/23377
6549 * remote.c (remote_target::remote_detach_pid): Call
6550 set_current_process.
6551
6552 2018-07-11 Pedro Alves <palves@redhat.com>
6553
6554 * h8300-tdep.c (h8300_gdbarch_init): Remove
6555 set_gdbarch_ecoff_reg_to_regnum calls.
6556
6557 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
6558
6559 PR c++/23373
6560 * c-typeprint.c (c_type_print_base_struct_union): Don't print
6561 offsets/sizes for static members of a class/struct.
6562
6563 2018-07-11 Alan Hayward <alan.hayward@arm.com>
6564
6565 * target-descriptions.c (tdesc_register_bitsize): Rename.
6566 * target-descriptions.h (tdesc_register_bitsize): Likewise.
6567 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
6568 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
6569
6570 2018-07-10 Tom Tromey <tom@tromey.com>
6571
6572 * breakpoint.c (moribund_locations): Now static and a
6573 std::vector.
6574 (breakpoint_init_inferior, moribund_breakpoint_here_p)
6575 (build_bpstat_chain, update_global_location_list)
6576 (breakpoint_retire_moribund): Update.
6577 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
6578 VEC.
6579
6580 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
6581
6582 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
6583 (riscv_register_reggroup_p): Use new function, remove unneeded
6584 parenthesis.
6585 (riscv_push_dummy_call): Extend assert to compare against xlen or
6586 flen based on register type.
6587
6588 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
6589
6590 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
6591
6592 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
6593
6594 * remote.c (show_hardware_watchpoint_limit): New function.
6595 (show_hardware_watchpoint_length_limit): New function.
6596 (show_hardware_breakpoint_limit): New function.
6597 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
6598 where appropriate, update help text.
6599
6600 2018-07-09 Tom Tromey <tom@tromey.com>
6601
6602 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
6603 (CLIBS): Don't mention NAT_CLIBS.
6604
6605 2018-07-09 Tom Tromey <tom@tromey.com>
6606
6607 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
6608 (LIBGDB_OBS, clean mostlyclean): Update.
6609 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
6610
6611 2018-07-09 Tom Tromey <tom@tromey.com>
6612
6613 * Makefile.in (%.c: %.y): Use ECHO_YACC.
6614 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
6615 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
6616
6617 2018-07-09 Tom Tromey <tom@tromey.com>
6618
6619 * Makefile.in (ALLDEPFILES): Remove exec.c.
6620 (COMMON_OBS): Remove exec.o.
6621 (COMMON_SFILES): Add exec.c.
6622
6623 2018-07-09 Tom Tromey <tom@tromey.com>
6624
6625 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
6626
6627 2018-07-09 Tom Tromey <tom@tromey.com>
6628
6629 * Makefile.in (clean mostlyclean): Remove stamp-version.
6630 (version.c): Depend on stamp-version.
6631 (stamp-version): New rule, from version.c rule.
6632
6633 2018-07-09 Tom Tromey <tom@tromey.com>
6634
6635 * Makefile.in (init.c): Depend on stamp-init.
6636 (stamp-init): New rule, from init.c rule.
6637 (clean mostlyclean): Remove stamp-init.
6638
6639 2018-07-09 Tom Tromey <tom@tromey.com>
6640
6641 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
6642 SUBDIR_GCC_COMPILE_SRCS.
6643
6644 2018-07-09 Tom Tromey <tom@tromey.com>
6645
6646 * Makefile.in (init.c): Remove some unused sed rules.
6647
6648 2018-07-09 Tom Tromey <tom@tromey.com>
6649
6650 * Makefile.in (TSOBS): Remove.
6651 (INIT_FILES): Update.
6652 (LIBGDB_OBS): Update.
6653 (COMMON_SFILES): Add inflow.c.
6654 (SFILES): Remove inflow.c.
6655
6656 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
6657
6658 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
6659
6660 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
6661
6662 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
6663 get_saveloc_name, is_signal_frame_name, step_name,
6664 init_remote_name, create_addr_space_name,
6665 destroy_addr_space_name, search_unwind_table_name,
6666 find_dyn_list_name): Constify.
6667
6668 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
6669
6670 * darwin-nat.c (darwin_pthread_kill): New function.
6671 (darwin_resume_thread): Use darwin_pthread_kill.
6672
6673 2018-07-05 Tom de Vries <tdevries@suse.de>
6674
6675 * macroexp.c (macro_buffer) <operator=>: New member function.
6676
6677 2018-07-04 Tom Tromey <tom@tromey.com>
6678
6679 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
6680
6681 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
6682
6683 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
6684 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
6685 * maint.c: Likewise.
6686 * top.c: Likewise.
6687
6688 2018-07-04 Joel Brobecker <brobecker@adacore.com>
6689
6690 * NEWS: Create a new section for the next release branch.
6691 Rename the section of the current branch, now that it has
6692 been cut.
6693
6694 2018-07-04 Joel Brobecker <brobecker@adacore.com>
6695
6696 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
6697 * version.in: Bump version to 8.2.50.DATE-git.
6698
6699 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
6700 Pedro Alves <palves@redhat.com>
6701
6702 * linux-nat.c (linux_init_ptrace): Rename to ...
6703 (linux_init_ptrace_procfs): ... this. Call
6704 linux_proc_init_warnings.
6705 (linux_nat_target::post_attach)
6706 (linux_nat_target::post_startup_inferior): Adjust.
6707 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
6708 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
6709
6710 2018-07-04 Tom de Vries <tdevries@suse.de>
6711
6712 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
6713 check ...
6714 (read_comp_unit_head): ... here.
6715
6716 2018-07-03 Tom Tromey <tom@tromey.com>
6717
6718 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
6719 (stop_tracing, tstatus_command)
6720 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
6721 (print_one_static_tracepoint_marker): Update.
6722 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
6723 std::vector.
6724 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
6725 VEC.
6726 (all_tracepoints, static_tracepoints_here): Return std::vector.
6727
6728 2018-07-03 Tom Tromey <tom@tromey.com>
6729
6730 * common/ptid.c (ptid_equal): Remove.
6731 * common/ptid.h (ptid_equal): Don't declare.
6732 * ada-tasks.c: Update.
6733 * breakpoint.c: Update.
6734 * common/agent.c: Update.
6735 * corelow.c: Update.
6736 * darwin-nat-info.c: Update.
6737 * darwin-nat.c: Update.
6738 * dcache.c: Update.
6739 * dtrace-probe.c: Update.
6740 * dummy-frame.c: Update.
6741 * fbsd-nat.c: Update.
6742 * frame.c: Update.
6743 * gdbthread.h: Update.
6744 * gnu-nat.c: Update.
6745 * go32-nat.c: Update.
6746 * inf-loop.c: Update.
6747 * inf-ptrace.c: Update.
6748 * infcall.c: Update.
6749 * infcmd.c: Update.
6750 * inflow.c: Update.
6751 * infrun.c: Update.
6752 * linux-fork.c: Update.
6753 * linux-nat.c: Update.
6754 * linux-thread-db.c: Update.
6755 * mi/mi-cmd-var.c: Update.
6756 * mi/mi-interp.c: Update.
6757 * mi/mi-main.c: Update.
6758 * nto-procfs.c: Update.
6759 * ppc-linux-tdep.c: Update.
6760 * procfs.c: Update.
6761 * python/py-inferior.c: Update.
6762 * python/py-record-btrace.c: Update.
6763 * python/py-record.c: Update.
6764 * ravenscar-thread.c: Update.
6765 * regcache.c: Update.
6766 * remote-sim.c: Update.
6767 * remote.c: Update.
6768 * sol-thread.c: Update.
6769 * solib.c: Update.
6770 * target.c: Update.
6771 * tui/tui-stack.c: Update.
6772 * varobj.c: Update.
6773 * windows-nat.c: Update.
6774 * windows-tdep.c: Update.
6775
6776 2018-07-03 Tom Tromey <tom@tromey.com>
6777
6778 * common/ptid.c (ptid_match): Remove.
6779 * common/ptid.h (ptid_match): Don't declare.
6780 * fbsd-nat.c: Update.
6781 * infcmd.c: Update.
6782 * infrun.c: Update.
6783 * linux-nat.c: Update.
6784 * record-btrace.c: Update.
6785 * regcache.c: Update.
6786 * remote.c: Update.
6787
6788 2018-07-03 Tom Tromey <tom@tromey.com>
6789
6790 * common/ptid.c (ptid_tid_p): Remove.
6791 * common/ptid.h (ptid_tid_p): Don't declare.
6792 * sol-thread.c: Update.
6793
6794 2018-07-03 Tom Tromey <tom@tromey.com>
6795
6796 * common/ptid.c (ptid_lwp_p): Remove.
6797 * common/ptid.h (ptid_lwp_p): Don't declare.
6798 * fbsd-nat.c: Update.
6799 * linux-nat.c: Update.
6800 * nat/linux-procfs.c: Update.
6801 * nat/x86-linux-dregs.c: Update.
6802 * sol-thread.c: Update.
6803
6804 2018-07-03 Tom Tromey <tom@tromey.com>
6805
6806 * common/ptid.c (ptid_is_pid): Remove.
6807 * common/ptid.h (ptid_is_pid): Don't declare.
6808 * infrun.c: Update.
6809 * linux-nat.c: Update.
6810 * mi/mi-interp.c: Update.
6811 * remote.c: Update.
6812 * thread.c: Update.
6813
6814 2018-07-03 Tom Tromey <tom@tromey.com>
6815
6816 * common/ptid.c (ptid_get_tid): Remove.
6817 * common/ptid.h (ptid_get_tid): Don't declare.
6818 * ada-tasks.c: Update.
6819 * aix-thread.c: Update.
6820 * bsd-uthread.c: Update.
6821 * darwin-nat.c: Update.
6822 * fbsd-nat.c: Update.
6823 * i386-darwin-nat.c: Update.
6824 * infrun.c: Update.
6825 * linux-tdep.c: Update.
6826 * nto-procfs.c: Update.
6827 * ppc-ravenscar-thread.c: Update.
6828 * python/py-infthread.c: Update.
6829 * ravenscar-thread.c: Update.
6830 * sol-thread.c: Update.
6831 * sparc-ravenscar-thread.c: Update.
6832 * windows-nat.c: Update.
6833
6834 2018-07-03 Tom Tromey <tom@tromey.com>
6835
6836 * common/ptid.c (ptid_get_lwp): Remove.
6837 * common/ptid.h (ptid_get_lwp): Don't declare.
6838 * aarch64-linux-nat.c: Update.
6839 * ada-tasks.c: Update.
6840 * aix-thread.c: Update.
6841 * amd64-linux-nat.c: Update.
6842 * arm-linux-nat.c: Update.
6843 * corelow.c: Update.
6844 * fbsd-nat.c: Update.
6845 * fbsd-tdep.c: Update.
6846 * gnu-nat.c: Update.
6847 * i386-cygwin-tdep.c: Update.
6848 * i386-gnu-nat.c: Update.
6849 * i386-linux-nat.c: Update.
6850 * ia64-linux-nat.c: Update.
6851 * inf-ptrace.c: Update.
6852 * infrun.c: Update.
6853 * linux-fork.c: Update.
6854 * linux-nat.c: Update.
6855 * linux-tdep.c: Update.
6856 * linux-thread-db.c: Update.
6857 * mips-linux-nat.c: Update.
6858 * nat/aarch64-linux-hw-point.c: Update.
6859 * nat/aarch64-linux.c: Update.
6860 * nat/linux-btrace.c: Update.
6861 * nat/linux-osdata.c: Update.
6862 * nat/linux-procfs.c: Update.
6863 * nat/x86-linux-dregs.c: Update.
6864 * obsd-nat.c: Update.
6865 * ppc-fbsd-nat.c: Update.
6866 * ppc-linux-nat.c: Update.
6867 * procfs.c: Update.
6868 * python/py-infthread.c: Update.
6869 * ravenscar-thread.c: Update.
6870 * remote.c: Update.
6871 * s390-linux-nat.c: Update.
6872 * sol-thread.c: Update.
6873 * sol2-tdep.c: Update.
6874 * spu-linux-nat.c: Update.
6875 * x86-linux-nat.c: Update.
6876 * xtensa-linux-nat.c: Update.
6877
6878 2018-07-03 Tom Tromey <tom@tromey.com>
6879
6880 * common/ptid.c (ptid_get_pid): Remove.
6881 * common/ptid.h (ptid_get_pid): Don't declare.
6882 * aarch64-linux-nat.c: Update.
6883 * ada-lang.c: Update.
6884 * aix-thread.c: Update.
6885 * alpha-bsd-nat.c: Update.
6886 * amd64-fbsd-nat.c: Update.
6887 * amd64-linux-nat.c: Update.
6888 * arm-linux-nat.c: Update.
6889 * arm-nbsd-nat.c: Update.
6890 * auxv.c: Update.
6891 * break-catch-syscall.c: Update.
6892 * breakpoint.c: Update.
6893 * bsd-uthread.c: Update.
6894 * corelow.c: Update.
6895 * ctf.c: Update.
6896 * darwin-nat.c: Update.
6897 * fbsd-nat.c: Update.
6898 * fbsd-tdep.c: Update.
6899 * gcore.c: Update.
6900 * gnu-nat.c: Update.
6901 * hppa-nbsd-nat.c: Update.
6902 * hppa-obsd-nat.c: Update.
6903 * i386-fbsd-nat.c: Update.
6904 * ia64-linux-nat.c: Update.
6905 * inf-ptrace.c: Update.
6906 * infcmd.c: Update.
6907 * inferior.c: Update.
6908 * inferior.h: Update.
6909 * inflow.c: Update.
6910 * infrun.c: Update.
6911 * linux-fork.c: Update.
6912 * linux-nat.c: Update.
6913 * linux-tdep.c: Update.
6914 * linux-thread-db.c: Update.
6915 * m68k-bsd-nat.c: Update.
6916 * mi/mi-interp.c: Update.
6917 * mi/mi-main.c: Update.
6918 * mips-linux-nat.c: Update.
6919 * mips-nbsd-nat.c: Update.
6920 * mips64-obsd-nat.c: Update.
6921 * nat/aarch64-linux-hw-point.c: Update.
6922 * nat/aarch64-linux.c: Update.
6923 * nat/linux-btrace.c: Update.
6924 * nat/linux-osdata.c: Update.
6925 * nat/linux-procfs.c: Update.
6926 * nat/x86-linux-dregs.c: Update.
6927 * nto-procfs.c: Update.
6928 * obsd-nat.c: Update.
6929 * ppc-linux-nat.c: Update.
6930 * ppc-nbsd-nat.c: Update.
6931 * ppc-obsd-nat.c: Update.
6932 * proc-service.c: Update.
6933 * procfs.c: Update.
6934 * python/py-inferior.c: Update.
6935 * python/py-infthread.c: Update.
6936 * ravenscar-thread.c: Update.
6937 * record.c: Update.
6938 * remote-sim.c: Update.
6939 * remote.c: Update.
6940 * rs6000-nat.c: Update.
6941 * s390-linux-nat.c: Update.
6942 * sh-nbsd-nat.c: Update.
6943 * sol-thread.c: Update.
6944 * sparc-nat.c: Update.
6945 * sparc64-tdep.c: Update.
6946 * spu-linux-nat.c: Update.
6947 * spu-tdep.c: Update.
6948 * target-debug.h: Update.
6949 * target.c: Update.
6950 * thread.c: Update.
6951 * tid-parse.c: Update.
6952 * tracefile-tfile.c: Update.
6953 * vax-bsd-nat.c: Update.
6954 * windows-nat.c: Update.
6955 * x86-linux-nat.c: Update.
6956 * x86-nat.c: Update.
6957
6958 2018-07-03 Tom Tromey <tom@tromey.com>
6959
6960 * common/ptid.c (pid_to_ptid): Remove.
6961 * common/ptid.h (pid_to_ptid): Don't declare.
6962 * aix-thread.c: Update.
6963 * arm-linux-nat.c: Update.
6964 * common/ptid.c: Update.
6965 * common/ptid.h: Update.
6966 * corelow.c: Update.
6967 * ctf.c: Update.
6968 * darwin-nat.c: Update.
6969 * fbsd-nat.c: Update.
6970 * fork-child.c: Update.
6971 * gnu-nat.c: Update.
6972 * go32-nat.c: Update.
6973 * inf-ptrace.c: Update.
6974 * infcmd.c: Update.
6975 * inferior.c: Update.
6976 * infrun.c: Update.
6977 * linux-fork.c: Update.
6978 * linux-nat.c: Update.
6979 * nat/aarch64-linux-hw-point.c: Update.
6980 * nat/fork-inferior.c: Update.
6981 * nat/x86-linux-dregs.c: Update.
6982 * nto-procfs.c: Update.
6983 * obsd-nat.c: Update.
6984 * procfs.c: Update.
6985 * progspace.c: Update.
6986 * remote.c: Update.
6987 * rs6000-nat.c: Update.
6988 * s390-linux-nat.c: Update.
6989 * sol-thread.c: Update.
6990 * spu-linux-nat.c: Update.
6991 * target.c: Update.
6992 * top.c: Update.
6993 * tracefile-tfile.c: Update.
6994 * windows-nat.c: Update.
6995
6996 2018-07-03 Tom Tromey <tom@tromey.com>
6997
6998 * common/ptid.h (ptid_build): Don't declare.
6999 * common/ptid.c (ptid_build): Remove.
7000 * aix-thread.c: Update.
7001 * bsd-kvm.c: Update.
7002 * bsd-uthread.c: Update.
7003 * common/agent.c: Update.
7004 * common/ptid.c: Update.
7005 * common/ptid.h: Update.
7006 * corelow.c: Update.
7007 * darwin-nat.c: Update.
7008 * fbsd-nat.c: Update.
7009 * gnu-nat.c: Update.
7010 * linux-fork.c: Update.
7011 * linux-nat.c: Update.
7012 * linux-thread-db.c: Update.
7013 * nat/linux-osdata.c: Update.
7014 * nat/linux-procfs.c: Update.
7015 * nto-procfs.c: Update.
7016 * obsd-nat.c: Update.
7017 * proc-service.c: Update.
7018 * procfs.c: Update.
7019 * ravenscar-thread.c: Update.
7020 * remote-sim.c: Update.
7021 * remote.c: Update.
7022 * sol-thread.c: Update.
7023 * target.c: Update.
7024 * windows-nat.c: Update.
7025
7026 2018-07-03 Tom Tromey <tom@tromey.com>
7027
7028 * infrun.c (follow_exec): Use exit_inferior_silent.
7029 * inferior.c (exit_inferior_num_silent): Remove.
7030 * inferior.h (exit_inferior_num_silent): Don't declare.
7031
7032 2018-07-03 Tom Tromey <tom@tromey.com>
7033
7034 PR cli/23340:
7035 * darwin-nat.c (darwin_attach_pid): Reset inferior and
7036 inferior_ptid on error.
7037
7038 2018-07-02 Maciej W. Rozycki <macro@mips.com>
7039 Simon Marchi <simon.marchi@polymtl.ca>
7040
7041 PR tdep/8282
7042 * disasm.h (gdb_disassembler): Add
7043 `m_disassembler_options_holder'. member
7044 * disasm.c (get_all_disassembler_options): New function.
7045 (gdb_disassembler::gdb_disassembler): Use it.
7046 (gdb_buffered_insn_length_init_dis): Likewise.
7047 (gdb_buffered_insn_length): Adjust accordingly.
7048 (set_disassembler_options): Handle options with arguments.
7049 (show_disassembler_options_sfunc): Likewise. Add a leading new
7050 line if showing options with descriptions.
7051 (disassembler_options_completer): Adapt to using the
7052 `disasm_options_and_args_t' structure.
7053 * mips-tdep.c (mips_disassembler_options): New variable.
7054 (mips_disassembler_options_o32): Likewise.
7055 (mips_disassembler_options_n32): Likewise.
7056 (mips_disassembler_options_n64): Likewise.
7057 (gdb_print_insn_mips): Don't set `disassembler_options'.
7058 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
7059 functions.
7060 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
7061 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
7062 `gdbarch_disassembler_options_implicit' and
7063 `gdbarch_valid_disassembler_options'.
7064 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
7065 `disasm_options_and_args_t' structure.
7066 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
7067 method.
7068 (valid_disassembler_options): Switch from `disasm_options_t' to
7069 the `disasm_options_and_args_t' structure.
7070 * NEWS: Document `set disassembler-options' support for the MIPS
7071 target.
7072 * gdbarch.h: Regenerate.
7073 * gdbarch.c: Regenerate.
7074
7075 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
7076
7077 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
7078
7079 2018-06-29 Joel Brobecker <brobecker@adacore.com>
7080
7081 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
7082 parameter in call to amd64_target_description.
7083 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
7084 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
7085 (amd64fbsd_init_abi): Likewise.
7086 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
7087 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
7088 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
7089 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
7090
7091 2018-06-29 Pedro Alves <palves@redhat.com>
7092
7093 * gdb/amd64-tdep.h (amd64_create_target_description): Add
7094 "segments" parameter.
7095 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
7096 (_initialize_amd64_tdep): Update call to
7097 amd64_create_target_description.
7098 (amd64_target_description): Add "segments" parameter. Adjust
7099 the implementation to use it.
7100 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
7101 call to amd64_create_target_description.
7102 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
7103 * gdb/arch/amd64.h (amd64_create_target_description): Add
7104 "segments" register.
7105 * gdb/arch/amd64.c (amd64_create_target_description): Add
7106 "segments" parameter. Call create_feature_i386_64bit_segments
7107 only if SEGMENTS is true.
7108 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
7109 call to amd64_create_target_description.
7110
7111 2018-06-29 Pedro Alves <palves@redhat.com>
7112
7113 * thread.c (thread_target_id_str): New, factored out from ...
7114 (print_thread_info_1): ... here. Use it to compute the max
7115 "Target Id" column width.
7116
7117 2018-06-29 Pedro Alves <palves@redhat.com>
7118
7119 * remote.c (remote_target::extra_thread_info): Delete
7120 'display_buf' and 'n' locals. from the cache, regardless of
7121 packet mechanims is in use. Use cache for qThreadExtra and qP
7122 methods too.
7123
7124 2018-06-29 Pedro Alves <palves@redhat.com>
7125
7126 * blockframe.c (find_pc_sect_containing_function): New function.
7127 * breakpoint.c (print_breakpoint_location): Don't call
7128 find_pc_sect_function.
7129 * linespec.c (create_sals_line_offset): Record the location's
7130 symbol in the sal.
7131 * linespec.c (convert_address_location_to_sals): Fill in sal's
7132 symbol with find_pc_sect_containing_function.
7133 * symtab.c (find_function_start_sal): Rename to ...
7134 (find_function_start_sal_1): ... this.
7135 (find_function_start_sal): Reimplement as wrapper around
7136 find_function_start_sal_1, and use
7137 find_pc_sect_containing_function to fill in the sal's symbol.
7138 (find_function_start_sal(symbol*, bool)): Adjust.
7139 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
7140 comments.
7141 (find_pc_sect_containing_function): Declare.
7142
7143 2018-06-29 Pedro Alves <palves@redhat.com>
7144
7145 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
7146 true if the the location has no symbol.
7147
7148 2018-06-28 Tom Tromey <tom@tromey.com>
7149
7150 * NEWS: Mention --enable-codesign.
7151 * silent-rules.mk (ECHO_SIGN): New variable.
7152 * configure.ac: Add --enable-codesign.
7153 * configure: Rebuild.
7154 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
7155 (gdb$(EXEEXT)): Optionally invoke codesign.
7156
7157 2018-06-28 Pedro Alves <palves@redhat.com>
7158
7159 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
7160 comments.
7161 (switch_to_thread_no_regs): Adjust comment.
7162 * infcmd.c (stop_pc): Delete.
7163 (post_create_inferior, info_program_command): Replace references
7164 to stop_pc with references to thread_info->suspend.stop_pc.
7165 * inferior.h (stop_pc): Delete declaration.
7166 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
7167 (handle_inferior_event_1, handle_signal_stop)
7168 (process_event_stop_test, keep_going_stepped_thread)
7169 (handle_step_into_function, handle_step_into_function_backward)
7170 (print_stop_location): Replace references to stop_pc with
7171 references to thread_info->suspend.stop_pc.
7172 (struct infcall_suspend_state) <stop_pc>: Delete field.
7173 (save_infcall_suspend_state, restore_infcall_suspend_state):
7174 Remove references to inf_stat->stop_pc.
7175 * linux-fork.c (fork_load_infrun_state): Likewise.
7176 * record-btrace.c (record_btrace_set_replay): Likewise.
7177 * record-full.c (record_full_goto_entry): Likewise.
7178 * remote.c (print_one_stopped_thread): Likewise.
7179 * target.c (target_resume): Extend comment.
7180 * thread.c (set_executing_thread): New.
7181 (set_executing): Use it.
7182 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
7183 Remove references to stop_pc.
7184
7185 2018-06-28 Pedro Alves <palves@redhat.com>
7186
7187 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
7188 Moving fetching stop_pc until after ecs->event_thread is refreshed.
7189
7190 2018-06-28 Tom Tromey <tom@tromey.com>
7191
7192 * coffread.c (coff_symfile_finish): Update.
7193 * xcoffread.c (xcoff_symfile_finish): Update.
7194 * elfread.c (elf_symfile_finish): Update.
7195 * symfile.h (dwarf2_free_objfile): Don't declare.
7196 * dwarf2read.c (_initialize_dwarf2_read): Use
7197 register_objfile_data_with_cleanup.
7198 (dwarf2_free_objfile): Now static. Change signature.
7199
7200 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
7201
7202 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
7203 option "-o" to add-symbol-file-load to add an offset to each
7204 section's load address.
7205 * symfile.c (set_objfile_default_section_offset): New function.
7206
7207 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
7208
7209 * symfile.c (add_symbol_file_command): Make sure that sections
7210 with the same name are sorted in the same order.
7211
7212 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
7213
7214 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
7215 require the second argument. If omitted, load sections at the
7216 addresses specified in the file.
7217
7218 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
7219
7220 * symfile.c (symbol_file_command, symbol_file_add_main_1)
7221 (_initialize_symfile): Add option "-o" to symbol-file to add an
7222 offset to each section of the symbol file.
7223
7224 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
7225
7226 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
7227
7228 2018-06-27 Tom Tromey <tom@tromey.com>
7229
7230 * stack.c (_initialize_stack): Update "func" help text.
7231
7232 2018-06-27 Tom Tromey <tom@tromey.com>
7233
7234 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
7235 std::vector.
7236 (unwind_infopy_str, pyuw_create_unwind_info)
7237 (unwind_infopy_add_saved_register, pyuw_sniffer)
7238 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
7239 Update.
7240 (struct saved_reg): Add constructor.
7241 <value>: Now a gdbpy_ref<>.
7242
7243 2018-06-27 Tom Tromey <tom@tromey.com>
7244
7245 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
7246
7247 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7248
7249 * gdb-gdb.py.in: Format using autopep8.
7250
7251 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7252
7253 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
7254 (type_lookup_function): Recognize CORE_ADDR values.
7255
7256 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7257
7258 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
7259 print tag_name.
7260
7261 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7262
7263 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
7264 <__lt__>: Add.
7265
7266 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7267
7268 * gdb-gdb.py: Move to...
7269 * gdb-gdb.py.in: ... here.
7270 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
7271 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
7272 dependencies.
7273 (distclean): Remove gdb-gdb.py when cleaning.
7274 (gdb-gdb.py, gdb-gdb.gdb): New rules.
7275 * configure: Re-generate.
7276
7277 2018-06-27 Pedro Alves <palves@redhat.com>
7278
7279 * proc-service.c (get_ps_regcache): New.
7280 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
7281 (ps_lsetfpregs): Use it.
7282
7283 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
7284
7285 PR gdb/21695
7286 * dwarf2read.c (lnp_state_machine::check_line_address): Update
7287 declaration.
7288 (dwarf_decode_lines_1): Adjust.
7289
7290 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
7291
7292 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
7293 override.
7294 <info_proc>: Likewise.
7295
7296 2018-06-26 Joel Brobecker <brobecker@adacore.com>
7297
7298 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
7299 to windows_fetch_one_register, and only handle the case of
7300 fetching one register. Move the code that reloads the context
7301 and iterates over all registers if R is negative to...
7302 (windows_nat_target::fetch_registers): ... here.
7303 (do_windows_store_inferior_registers): Rename to
7304 windows_store_one_register, and only handle the case of storing
7305 one register. Move the code that handles the case where r is
7306 negative to...
7307 (windows_nat_target::store_registers) ... here.
7308
7309 2018-06-26 Tom Tromey <tom@tromey.com>
7310
7311 PR rust/22574:
7312 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
7313 * rust-lang.c (rust_print_struct_def): Add podata parameter.
7314 Update.
7315 (rust_internal_print_type): Add podata parameter.
7316 (rust_print_type): Update.
7317
7318 2018-06-26 Tom Tromey <tom@tromey.com>
7319
7320 * typeprint.h (struct print_offset_data) <update, finish,
7321 maybe_print_hole>: New methods.
7322 <indentation>: New constant.
7323 * typeprint.c (print_offset_data::indentation): Define.
7324 (print_offset_data::maybe_print_hole, print_offset_data::update)
7325 (print_offset_data::finish): Move from c-typeprint.c and rename.
7326 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
7327 (print_spaces_filtered_with_print_options): Update.
7328 (c_print_type_union_field_offset, maybe_print_hole)
7329 (c_print_type_struct_field_offset): Move to typeprint.c and
7330 rename.
7331 (c_type_print_base_struct_union): Update.
7332
7333 2018-06-25 Pedro Alves <palves@redhat.com>
7334
7335 * gdbthread.h (thread_info_ref, delete_thread)
7336 (delete_thread_silent, first_thread_of_inferior)
7337 (any_thread_of_inferior, switch_to_thread)
7338 (enable_thread_stack_temporaries)
7339 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
7340 (get_last_thread_stack_temporary)
7341 (value_in_thread_stack_temporaries, can_access_registers_thread):
7342 Spell out "struct thread_info" instead of just "thread_info".
7343 * inferior.h (notice_new_inferior): Likewise.
7344
7345 2018-06-25 Pedro Alves <palves@redhat.com>
7346
7347 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
7348 pass thread_info pointer to delete_thread.
7349 (windows_nat_target::detach): Pass inferior pointer to
7350 detach_inferior.
7351 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
7352 delete_thread.
7353 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
7354 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
7355 and pass a thread_info pointer to delete_thread.
7356 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
7357 pass thread_info pointer to delete_thread.
7358 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
7359 delete_thread_silent call.
7360 * procfs.c (procfs_target::detach): Pass inferior pointer to
7361 detach_inferior.
7362 (procfs_target::wait): Pass thread_info pointer to delete_thread.
7363 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
7364 delete_thread_silent call.
7365 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
7366 pass thread_info pointer to delete_thread.
7367 (windows_nat_target::detach): Pass inferior pointer to
7368 delete_inferior.
7369
7370 2018-06-22 Alan Hayward <alan.hayward@arm.com>
7371
7372 * regcache.c (readable_regcache::read_part): Fix asserts.
7373 (reg_buffer::raw_collect_part): New function.
7374 (regcache::write_part): Fix asserts.
7375 (reg_buffer::raw_supply_part): New function.
7376 (regcache::transfer_regset_register): New helper function.
7377 (regcache::transfer_regset): Call new functions.
7378 (regcache_supply_regset): Use gdb_byte*.
7379 (regcache::supply_regset): Likewise.
7380 (regcache_collect_regset): Likewise.
7381 (regcache::collect_regset): Likewise.
7382 * regcache.h (reg_buffer::raw_collect_part): New declaration.
7383 (reg_buffer::raw_supply_part): Likewise.
7384 (regcache::transfer_regset_register): Likewise.
7385 (regcache::transfer_regset): Use gdb_byte*.
7386
7387 2018-06-22 Alan Hayward <alan.hayward@arm.com>
7388
7389 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
7390
7391 2018-06-21 Pedro Alves <palves@redhat.com>
7392
7393 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
7394 instead of a ptid_t. All callers adjusted.
7395 * ada-tasks.c (ada_get_task_number): Likewise. All callers
7396 adjusted.
7397 (print_ada_task_info, display_current_task_id, task_command_1):
7398 Adjust.
7399 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
7400 inferior_thread.
7401 (breakpoint_kind): Adjust.
7402 (remove_breakpoints_pid): Rename to ...
7403 (remove_breakpoints_inf): ... this. Adjust to take an inferior
7404 pointer. All callers adjusted.
7405 (bpstat_clear_actions): Use inferior_thread.
7406 (get_bpstat_thread): New.
7407 (bpstat_do_actions): Use it.
7408 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
7409 to take a thread_info pointer. All callers adjusted.
7410 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
7411 (breakpoint_re_set_thread): Use inferior_thread.
7412 * breakpoint.h (struct inferior): Forward declare.
7413 (bpstat_stop_status): Update.
7414 (remove_breakpoints_pid): Delete.
7415 (remove_breakpoints_inf): New.
7416 * bsd-uthread.c (bsd_uthread_target::wait)
7417 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
7418 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
7419 (maint_btrace_packet_history_cmd)
7420 (maint_btrace_clear_packet_history_cmd): Adjust.
7421 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
7422 inferior_thread.
7423 * cli/cli-interp.c: Include "inferior.h".
7424 * common/refcounted-object.h (struct
7425 refcounted_object_ref_policy): New.
7426 * compile/compile-object-load.c: Include gdbthread.h.
7427 (store_regs): Use inferior_thread.
7428 * corelow.c (core_target::close): Use current_inferior.
7429 (core_target_open): Adjust to use first_thread_of_inferior and use
7430 the current inferior.
7431 * ctf.c (ctf_target::close): Adjust to use current_inferior.
7432 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
7433 <thread>: ... this new field. All references adjusted.
7434 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
7435 Take a thread_info pointer instead of a ptid_t.
7436 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
7437 (dummy_frame_discard, register_dummy_frame_dtor): Take a
7438 thread_info pointer instead of a ptid_t.
7439 * elfread.c: Include "inferior.h".
7440 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
7441 Use inferior_thread.
7442 * eval.c (evaluate_subexp): Likewise.
7443 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
7444 inferior_thread.
7445 * gdb_proc_service.h (struct thread_info): Forward declare.
7446 (struct ps_prochandle) <ptid>: Delete, replaced by ...
7447 <thread>: ... this new field. All references adjusted.
7448 * gdbarch.h, gdbarch.c: Regenerate.
7449 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
7450 'thread' parameter. All implementations and callers adjusted.
7451 * gdbthread.h (thread_info) <set_running>: New method.
7452 (delete_thread, delete_thread_silent): Take a thread_info pointer
7453 instead of a ptid.
7454 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
7455 (first_thread_of_process): Delete, replaced by ...
7456 (first_thread_of_inferior): ... this new function. All callers
7457 adjusted.
7458 (any_live_thread_of_process): Delete, replaced by ...
7459 (any_live_thread_of_inferior): ... this new function. All callers
7460 adjusted.
7461 (switch_to_thread, switch_to_no_thread): Declare.
7462 (is_executing): Delete.
7463 (enable_thread_stack_temporaries): Update comment.
7464 <enable_thread_stack_temporaries>: Take a thread_info pointer
7465 instead of a ptid_t. Incref the thread.
7466 <~enable_thread_stack_temporaries>: Decref the thread.
7467 <m_ptid>: Delete
7468 <m_thr>: New.
7469 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
7470 (get_last_thread_stack_temporary)
7471 (value_in_thread_stack_temporaries, can_access_registers_thread):
7472 Take a thread_info pointer instead of a ptid_t. All callers
7473 adjusted.
7474 * infcall.c (get_call_return_value): Use inferior_thread.
7475 (run_inferior_call): Work with thread pointers instead of ptid_t.
7476 (call_function_by_hand_dummy): Work with thread pointers instead
7477 of ptid_t. Use thread_info_ref.
7478 * infcmd.c (proceed_thread_callback): Access thread's state
7479 directly.
7480 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
7481 access thread's state directly.
7482 (continue_command): Use inferior_thread.
7483 (info_program_command): Use find_thread_ptid and access thread
7484 state directly.
7485 (proceed_after_attach_callback): Use thread state directly.
7486 (notice_new_inferior): Take a thread_info pointer instead of a
7487 ptid_t. All callers adjusted.
7488 (exit_inferior): Take an inferior pointer instead of a pid. All
7489 callers adjusted.
7490 (exit_inferior_silent): New.
7491 (detach_inferior): Delete.
7492 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
7493 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
7494 (detach_inferior_command, kill_inferior_command): Use
7495 find_inferior_id instead of valid_gdb_inferior_id and
7496 gdb_inferior_id_to_pid.
7497 (inferior_command): Use inferior and thread pointers.
7498 * inferior.h (struct thread_info): Forward declare.
7499 (notice_new_inferior): Take a thread_info pointer instead of a
7500 ptid_t. All callers adjusted.
7501 (detach_inferior): Delete declaration.
7502 (exit_inferior, exit_inferior_silent): Take an inferior pointer
7503 instead of a pid. All callers adjusted.
7504 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
7505 (valid_gdb_inferior_id): Delete.
7506 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
7507 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
7508 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
7509 ...
7510 <inf>: ... this new field.
7511 <step_ptid>: Delete, replaced by ...
7512 <step_thread>: ... this new field.
7513 (get_displaced_stepping_state): Take an inferior pointer instead
7514 of a pid. All callers adjusted.
7515 (displaced_step_in_progress_any_inferior): Adjust.
7516 (displaced_step_in_progress_thread): Take a thread pointer instead
7517 of a ptid_t. All callers adjusted.
7518 (displaced_step_in_progress, add_displaced_stepping_state): Take
7519 an inferior pointer instead of a pid. All callers adjusted.
7520 (get_displaced_step_closure_by_addr): Adjust.
7521 (remove_displaced_stepping_state): Take an inferior pointer
7522 instead of a pid. All callers adjusted.
7523 (displaced_step_prepare_throw, displaced_step_prepare)
7524 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
7525 All callers adjusted.
7526 (start_step_over): Adjust.
7527 (infrun_thread_ptid_changed): Remove bit updating ptids in the
7528 displaced step queue.
7529 (do_target_resume): Adjust.
7530 (fetch_inferior_event): Use inferior_thread.
7531 (context_switch, get_inferior_stop_soon): Take an
7532 execution_control_state pointer instead of a ptid_t. All callers
7533 adjusted.
7534 (switch_to_thread_cleanup): Delete.
7535 (stop_all_threads): Use scoped_restore_current_thread.
7536 * inline-frame.c: Include "gdbthread.h".
7537 (inline_state) <inline_state>: Take a thread pointer instead of a
7538 ptid_t. All callers adjusted.
7539 <ptid>: Delete, replaced by ...
7540 <thread>: ... this new field.
7541 (find_inline_frame_state): Take a thread pointer instead of a
7542 ptid_t. All callers adjusted.
7543 (skip_inline_frames, step_into_inline_frame)
7544 (inline_skipped_frames, inline_skipped_symbol): Take a thread
7545 pointer instead of a ptid_t. All callers adjusted.
7546 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
7547 (inline_skipped_frames, inline_skipped_symbol): Likewise.
7548 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
7549 pointers directly.
7550 * linux-nat.c (get_detach_signal): Likewise.
7551 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
7552 (thread_db_notice_clone): Adjust.
7553 (thread_db_find_new_threads_silently)
7554 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
7555 a thread pointer instead of a ptid_t. All callers adjusted.
7556 * mi/mi-cmd-var.c: Include "inferior.h".
7557 (mi_cmd_var_update_iter): Update to use thread pointers.
7558 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
7559 inferior directly.
7560 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
7561 out to ...
7562 (mi_output_running): ... this new function.
7563 (mi_on_resume_1): Adjust to use it.
7564 (mi_user_selected_context_changed): Adjust to use inferior_thread.
7565 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
7566 directly.
7567 (interrupt_thread_callback): : Adjust to use thread and inferior
7568 pointers.
7569 * proc-service.c: Include "gdbthread.h".
7570 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
7571 * progspace-and-thread.c: Include "inferior.h".
7572 * progspace.c: Include "inferior.h".
7573 * python/py-exitedevent.c (create_exited_event_object): Adjust to
7574 hold a reference to an inferior_object.
7575 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
7576 inferior_thread.
7577 * python/py-inferior.c (struct inferior_object): Give the type a
7578 tag name instead of a typedef.
7579 (python_on_normal_stop): No need to check if the current thread is
7580 listed.
7581 (inferior_to_inferior_object): Change return type to
7582 inferior_object. All callers adjusted.
7583 (find_thread_object): Delete, bits factored out to ...
7584 (thread_to_thread_object): ... this new function.
7585 * python/py-infthread.c (create_thread_object): Use
7586 inferior_to_inferior_object.
7587 (thpy_is_stopped): Use thread pointer directly.
7588 (gdbpy_selected_thread): Use inferior_thread.
7589 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
7590 field, replaced with ...
7591 <thread>: ... this new field. All users adjusted.
7592 (btpy_insn_or_gap_new): Drop const.
7593 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
7594 callers adjusted.
7595 * python/py-record.c: Include "gdbthread.h".
7596 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
7597 a ptid_t. All callers adjusted.
7598 (gdbpy_current_recording): Use inferior_thread.
7599 * python/py-record.h (recpy_record_object) <ptid>: Delete
7600 field, replaced with ...
7601 <thread>: ... this new field. All users adjusted.
7602 (recpy_element_object) <ptid>: Delete
7603 field, replaced with ...
7604 <thread>: ... this new field. All users adjusted.
7605 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
7606 a ptid_t. All callers adjusted.
7607 * python/py-threadevent.c: Include "gdbthread.h".
7608 (get_event_thread): Use thread_to_thread_object.
7609 * python/python-internal.h (struct inferior_object): Forward
7610 declare.
7611 (find_thread_object, find_inferior_object): Delete declarations.
7612 (thread_to_thread_object, inferior_to_inferior_object): New
7613 declarations.
7614 * record-btrace.c: Include "inferior.h".
7615 (require_btrace_thread): Use inferior_thread.
7616 (record_btrace_frame_sniffer)
7617 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
7618 (get_thread_current_frame): Use scoped_restore_current_thread and
7619 switch_to_thread.
7620 (get_thread_current_frame): Use thread pointer directly.
7621 (record_btrace_replay_at_breakpoint): Use thread's inferior
7622 pointer directly.
7623 * record-full.c: Include "inferior.h".
7624 * regcache.c: Include "gdbthread.h".
7625 (get_thread_arch_regcache): Use the inferior's address space
7626 directly.
7627 (get_thread_regcache, registers_changed_thread): New.
7628 * regcache.h (get_thread_regcache(thread_info *thread)): New
7629 overload.
7630 (registers_changed_thread): New.
7631 (remote_target) <remote_detach_1>: Swap order of parameters.
7632 (remote_add_thread): <remote_add_thread>: Return the new thread.
7633 (get_remote_thread_info(ptid_t)): New overload.
7634 (remote_target::remote_notice_new_inferior): Use thread pointers
7635 directly.
7636 (remote_target::process_initial_stop_replies): Use
7637 thread_info::set_running.
7638 (remote_target::remote_detach_1, remote_target::detach)
7639 (extended_remote_target::detach): Adjust.
7640 * stack.c (frame_show_address): Use inferior_thread.
7641 * target-debug.h (target_debug_print_thread_info_pp): New.
7642 * target-delegates.c: Regenerate.
7643 * target.c (default_thread_address_space): Delete.
7644 (memory_xfer_partial_1): Use current_inferior.
7645 (target_detach): Use current_inferior.
7646 (target_thread_address_space): Delete.
7647 (generic_mourn_inferior): Use current_inferior.
7648 * target.h (struct target_ops) <thread_address_space>: Delete.
7649 (target_thread_address_space): Delete.
7650 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
7651 pointers directly.
7652 (delete_thread_1, delete_thread, delete_thread_silent): Take a
7653 thread pointer instead of a ptid_t. Adjust all callers.
7654 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
7655 (first_thread_of_process): Delete, replaced by ...
7656 (first_thread_of_inferior): ... this new function. All callers
7657 adjusted.
7658 (any_thread_of_process): Rename to ...
7659 (any_thread_of_inferior): ... this, and take an inferior pointer.
7660 (any_live_thread_of_process): Rename to ...
7661 (any_live_thread_of_inferior): ... this, and take an inferior
7662 pointer.
7663 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
7664 (value_in_thread_stack_temporaries)
7665 (get_last_thread_stack_temporary): Take a thread pointer instead
7666 of a ptid_t. Adjust all callers.
7667 (thread_info::set_running): New.
7668 (validate_registers_access): Use inferior_thread.
7669 (can_access_registers_ptid): Rename to ...
7670 (can_access_registers_thread): ... this, and take a thread
7671 pointer.
7672 (print_thread_info_1): Adjust to compare thread pointers instead
7673 of ptids.
7674 (switch_to_no_thread, switch_to_thread): Make extern.
7675 (scoped_restore_current_thread::~scoped_restore_current_thread):
7676 Use m_thread pointer directly.
7677 (scoped_restore_current_thread::scoped_restore_current_thread):
7678 Use inferior_thread.
7679 (thread_command): Use thread pointer directly.
7680 (thread_num_make_value_helper): Use inferior_thread.
7681 * top.c (execute_command): Use inferior_thread.
7682 * tui/tui-interp.c: Include "inferior.h".
7683 * varobj.c (varobj_create): Use inferior_thread.
7684 (value_of_root_1): Use find_thread_global_id instead of
7685 global_thread_id_to_ptid.
7686
7687 2018-06-21 Alan Hayward <alan.hayward@arm.com>
7688
7689 * regcache.c (readable_regcache::read_part): Avoid memcpy when
7690 possible.
7691 (regcache::write_part): Likewise.
7692 (readable_regcache::cooked_read_part): Update comment.
7693 (readable_regcache::cooked_write_part): Likewise.
7694 * regcache.h: (readable_regcache::read_part): Likewise.
7695 (regcache::write_part): Likewise.
7696
7697 2018-06-21 Richard Bunt <richard.bunt@arm.com>
7698 Dirk Schubert <dirk.schubert@arm.com>
7699
7700 * aarch64-linux-nat.c (post_attach): New.
7701 (aarch64_linux_nat_target::post_attach): Override post_attach to
7702 record the number of hardware debug registers.
7703
7704 2018-06-20 Tom Tromey <tom@tromey.com>
7705
7706 * python/py-param.c (add_setshow_generic): Make parameters const.
7707 (parmpy_init): Update.
7708
7709 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
7710
7711 * regcache.h (regcache_cooked_read_ftype): Rename to...
7712 (register_read_ftype): ...this, change type to function_view.
7713 (class reg_buffer) <save>: Remove src parameter.
7714 (readonly_detached_regcache) <readonly_detached_regcache>: Make
7715 parameter non-const in first overload. Remove src parameter in
7716 second overload.
7717 * regcache.c (do_cooked_read): Remove.
7718 (readonly_detached_regcache::readonly_detached_regcache): Make
7719 parameter non-const, adjust call to other constructor.
7720 (reg_buffer::save): Remove src parameter.
7721 * frame.c (do_frame_register_read): Remove.
7722 (frame_save_as_regcache): Use lambda function.
7723 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
7724 parameter to ppu2spu_data *.
7725 (ppu2spu_sniffer): Use lambda function.
7726
7727 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
7728
7729 * record-full.c (record_full_target::insert_breakpoint): Remove
7730 "struct" keyword, add const.
7731
7732 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
7733
7734 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
7735 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
7736 * configure.ac: Remove AC_PREREQ, add missing quoting.
7737 * gnulib/configure.ac: Modernize usage of
7738 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
7739 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
7740 (AUTOMAKE_VERSION): Bump to 1.15.1.
7741 * configure: Re-generate.
7742 * config.in: Re-generate.
7743 * aclocal.m4: Re-generate.
7744 * gnulib/aclocal.m4: Re-generate.
7745 * gnulib/config.in: Re-generate.
7746 * gnulib/configure: Re-generate.
7747 * gnulib/import/Makefile.in: Re-generate.
7748
7749 2018-06-19 Pedro Alves <palves@redhat.com>
7750
7751 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
7752 (lookup_minimal_symbol_by_pc_section): ... here with
7753 gdb_assert_not_reached added.
7754
7755 2018-06-19 Pedro Alves <palves@redhat.com>
7756
7757 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
7758 parameter with a block parameter. Compare location's block symbol
7759 with the frame's block instead of addresses.
7760 (skip_inline_frames): Pass the current block instead of the
7761 frame's address. Break out as soon as we determine the frame
7762 should not be skipped.
7763
7764 2018-06-18 Tom Tromey <tom@tromey.com>
7765
7766 * solib-aix.c (solib_aix_get_section_offsets): Return
7767 unique_xmalloc_ptr.
7768 (solib_aix_solib_create_inferior_hook): Update.
7769
7770 2018-06-18 Tom Tromey <tom@tromey.com>
7771
7772 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
7773
7774 2018-06-18 Tom Tromey <tom@tromey.com>
7775
7776 * solib-frv.c (frv_relocate_main_executable): Use
7777 unique_xmalloc_ptr.
7778 * solib-dsbt.c (dsbt_relocate_main_executable): Use
7779 unique_xmalloc_ptr.
7780
7781 2018-06-18 Tom Tromey <tom@tromey.com>
7782
7783 * objfiles.h (inhibit_section_map_updates): Update.
7784 (resume_section_map_updates, resume_section_map_updates_cleanup):
7785 Remove.
7786 * solib-svr4.c (svr4_handle_solib_event): Update.
7787 * objfiles.c (inhibit_section_map_updates): Return
7788 scoped_restore_tmpl<int>.
7789 (resume_section_map_updates, resume_section_map_updates_cleanup):
7790 Remove.
7791
7792 2018-06-18 Tom Tromey <tom@tromey.com>
7793
7794 * valprint.h (read_string): Update.
7795 * valprint.c (read_string): Change type of "buffer".
7796 (val_print_string): Update.
7797 * python/py-value.c (valpy_string): Update.
7798 * language.h (struct language_defn) <la_get_string>: Change
7799 type of "buffer".
7800 (default_get_string, c_get_string): Update.
7801 * language.c (default_get_string): Change type of "buffer".
7802 * guile/scm-value.c (gdbscm_value_to_string): Update.
7803 * c-lang.c (c_get_string): Change type of "buffer".
7804
7805 2018-06-18 Tom Tromey <tom@tromey.com>
7806
7807 * ser-mingw.c (struct pipe_state_destroyer): New.
7808 (pipe_state_up): New typedef.
7809 (cleanup_pipe_state): Remove.
7810 (pipe_windows_open): Use pipe_state_up. Don't release argv.
7811
7812 2018-06-18 Tom Tromey <tom@tromey.com>
7813
7814 * rust-lang.h (rust_yyerror): Don't declare.
7815 * rust-lang.c (rust_language_defn): Update.
7816 * rust-exp.y (yyerror): Now static.
7817 * parse.c (parse_exp_in_context_1): Update.
7818 * p-lang.h (p_yyerror): Don't declare.
7819 * p-lang.c (p_language_defn): Update.
7820 * p-exp.y (yyerror): Now static.
7821 * opencl-lang.c (opencl_language_defn): Update.
7822 * objc-lang.c (objc_language_defn): Update.
7823 * m2-lang.h (m2_yyerror): Don't declare.
7824 * m2-lang.c (m2_language_defn): Update.
7825 * m2-exp.y (yyerror): Now static.
7826 * language.h (struct language_defn) <la_error>: Remove.
7827 * language.c (unk_lang_error): Remove.
7828 (unknown_language_defn, auto_language_defn): Remove.
7829 * go-lang.h (go_yyerror): Don't declare.
7830 * go-lang.c (go_language_defn): Update.
7831 * go-exp.y (yyerror): Now static.
7832 * f-lang.h (f_yyerror): Don't declare.
7833 * f-lang.c (f_language_defn): Update.
7834 * f-exp.y (yyerror): Now static.
7835 * d-lang.h (d_yyerror): Don't declare.
7836 * d-lang.c (d_language_defn): Update.
7837 * d-exp.y (yyerror): Now static.
7838 * c-lang.h (c_yyerror): Don't declare.
7839 * c-lang.c (c_language_defn, cplus_language_defn)
7840 (asm_language_defn, minimal_language_defn): Update.
7841 * c-exp.y (yyerror): Now static.
7842 * ada-lang.h (ada_yyerror): Don't declare.
7843 * ada-lang.c (ada_language_defn): Update.
7844 * ada-exp.y (yyerror): Now static.
7845
7846 2018-06-18 Alan Hayward <alan.hayward@arm.com>
7847
7848 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
7849 (store_sveregs_to_thread): Likewise.
7850 (aarch64_linux_fetch_inferior_registers): Check for SVE.
7851 (aarch64_linux_store_inferior_registers): Likewise.
7852 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
7853 function.
7854 (aarch64_sve_regs_copy_to_regcache): Likewise.
7855 (aarch64_sve_regs_copy_from_regcache): Likewise.
7856 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
7857 declaration.
7858 (aarch64_sve_regs_copy_to_regcache): Likewise.
7859 (aarch64_sve_regs_copy_from_regcache): Likewise.
7860 (sve_context): Structure from Linux headers.
7861 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
7862 (SVE_SIG_ZREG_SIZE): Likewise.
7863 (SVE_SIG_PREG_SIZE): Likewise.
7864 (SVE_SIG_FFR_SIZE): Likewise.
7865 (SVE_SIG_REGS_OFFSET): Likewise.
7866 (SVE_SIG_ZREGS_OFFSET): Likewise.
7867 (SVE_SIG_ZREG_OFFSET): Likewise.
7868 (SVE_SIG_ZREGS_SIZE): Likewise.
7869 (SVE_SIG_PREGS_OFFSET): Likewise.
7870 (SVE_SIG_PREG_OFFSET): Likewise.
7871 (SVE_SIG_PREGS_SIZE): Likewise.
7872 (SVE_SIG_FFR_OFFSET): Likewise.
7873 (SVE_SIG_REGS_SIZE): Likewise.
7874 (SVE_SIG_CONTEXT_SIZE): Likewise.
7875 (SVE_PT_REGS_MASK): Likewise.
7876 (SVE_PT_REGS_FPSIMD): Likewise.
7877 (SVE_PT_REGS_SVE): Likewise.
7878 (SVE_PT_VL_INHERIT): Likewise.
7879 (SVE_PT_VL_ONEXEC): Likewise.
7880 (SVE_PT_REGS_OFFSET): Likewise.
7881 (SVE_PT_FPSIMD_OFFSET): Likewise.
7882 (SVE_PT_FPSIMD_SIZE): Likewise.
7883 (SVE_PT_SVE_ZREG_SIZE): Likewise.
7884 (SVE_PT_SVE_PREG_SIZE): Likewise.
7885 (SVE_PT_SVE_FFR_SIZE): Likewise.
7886 (SVE_PT_SVE_FPSR_SIZE): Likewise.
7887 (SVE_PT_SVE_FPCR_SIZE): Likewise.
7888 (__SVE_SIG_TO_PT): Likewise.
7889 (SVE_PT_SVE_OFFSET): Likewise.
7890 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
7891 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
7892 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
7893 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
7894 (SVE_PT_SVE_PREG_OFFSET): Likewise.
7895 (SVE_PT_SVE_PREGS_SIZE): Likewise.
7896 (SVE_PT_SVE_FFR_OFFSET): Likewise.
7897 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
7898 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
7899 (SVE_PT_SVE_SIZE): Likewise.
7900 (SVE_PT_SIZE): Likewise.
7901 (HAS_SVE_STATE): New define.
7902
7903 2018-06-18 Alan Hayward <alan.hayward@arm.com>
7904
7905 * nat/aarch64-sve-linux-sigcontext.h: New file.
7906 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
7907 new files.
7908 (SVE_VQ_MIN): Likewise.
7909 (SVE_VQ_MAX): Likewise.
7910 (SVE_VL_MIN): Likewise.
7911 (SVE_VL_MAX): Likewise.
7912 (SVE_NUM_ZREGS): Likewise.
7913 (SVE_NUM_PREGS): Likewise.
7914 (sve_vl_valid): Likewise.
7915 (struct user_sve_header): Likewise.
7916
7917 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
7918 Richard Bunt <Richard.Bunt@arm.com>
7919
7920 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
7921 was requested by GDB.
7922
7923 2018-06-15 Tom de Vries <tdevries@suse.de>
7924
7925 * MAINTAINERS (Write After Approval): Add Tom de Vries.
7926
7927 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
7928
7929 * gnulib/update-gnulib.sh: Print expected versions of
7930 autoconf/aclocal.
7931
7932 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
7933
7934 * arch-utils.c (default_type_align): Use type_length_units.
7935 * gdbtypes.c (type_align): Use type_length_units.
7936
7937 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7938
7939 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
7940 of 'define' command.
7941
7942 2018-06-14 Tom de Vries <tdevries@suse.de>
7943
7944 PR cli/22573
7945 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
7946 get_no_prettyformat_print_options.
7947
7948 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
7949
7950 * sparc-nat.h: Include target.h.
7951 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
7952 <fetch_registers>: Remove this argument in function call.
7953 <store_registers>: Remove this argument in function call, remove
7954 extra semicolon.
7955 <low_forget_process>: Call sparc64_forget_process instead of
7956 sparc_forget_process.
7957
7958 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7959
7960 * procfs.c (_initialize_procfs): Use add_inf_child_target.
7961 (procfs_target::make_corefile_notes): Adjust to new
7962 target_read_alloc return type.
7963
7964 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
7965 Stephen Roberts <stephen.roberts@arm.com>
7966
7967 PR gdb/22882
7968 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
7969 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
7970 Move should_notify_stop local into more inner scope.
7971
7972 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
7973 Stephen Roberts <stephen.roberts@arm.com>
7974
7975 PR gdb/22882
7976 * infrun.c (resume_1): Add call to mark_async_event_handler.
7977
7978 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
7979
7980 * infrun.c (do_target_wait): Change old version of $pc printed.
7981
7982 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
7983
7984 * dwarf2read.c (read_index_from_section): Rename to...
7985 (read_gdb_index_from_section): ... this, update all callers.
7986 (dwarf2_read_index): Rename to...
7987 (dwarf2_read_gdb_index): ... this, update all callers.
7988
7989 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
7990
7991 * hppa-linux-nat.c
7992 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
7993 hppa_linux_nat_target::fetch_registers.
7994
7995 2018-06-11 Alan Hayward <alan.hayward@arm.com>
7996
7997 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
7998 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
7999 (AARCH64_DWARF_SVE_FFR): Likewise.
8000 (AARCH64_DWARF_SVE_P0): Likewise.
8001 (AARCH64_DWARF_SVE_Z0): Likewise.
8002
8003 2018-06-11 Alan Hayward <alan.hayward@arm.com>
8004
8005 * common/common-regcache.h (raw_compare): New function.
8006 * regcache.c (regcache::raw_compare): Likewise.
8007 * regcache.h (regcache::raw_compare): New declaration.
8008
8009 2018-06-11 Alan Hayward <alan.hayward@arm.com>
8010
8011 * common/common-regcache.h (reg_buffer_common): New structure.
8012 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
8013 (reg_buffer::raw_supply): Likewise.
8014 (reg_buffer::raw_supply_integer): Likewise.
8015 (reg_buffer::raw_supply_zeroed): Likewise.
8016 (reg_buffer::raw_collect): Likewise.
8017 (reg_buffer::raw_collect_integer): Likewise.
8018 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
8019 (reg_buffer::raw_supply): Likewise.
8020 (reg_buffer::raw_supply_integer): Likewise.
8021 (reg_buffer::raw_supply_zeroed): Likewise.
8022 (reg_buffer::raw_collect): Likewise.
8023 (reg_buffer::raw_collect_integer): Likewise.
8024
8025 2018-06-10 Tom Tromey <tom@tromey.com>
8026
8027 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
8028 (class remote_state) <stop_reply_queue>: Now std::vector.
8029 (remote_state::~remote_state)
8030 (remote_target::stop_reply_queue_length): Update.
8031 (struct queue_iter_param, remove_child_of_pending_fork)
8032 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
8033 (check_pending_event_prevents_wildcard_vcont_callback)
8034 (remove_stop_reply_for_inferior)
8035 (remove_stop_reply_of_remote_state)
8036 (remote_notif_remove_once_on_match)
8037 (stop_reply_match_ptid_and_ws)
8038 (remote_kill_child_of_pending_fork): Remove.
8039 (remote_target::remove_new_fork_children)
8040 (remote_target::check_pending_events_prevent_wildcard_vcont)
8041 (remote_target::discard_pending_stop_replies)
8042 (remote_target::discard_pending_stop_replies_in_queue)
8043 (remote_target::remote_notif_remove_queued_reply)
8044 (remote_target::queued_stop_reply)
8045 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
8046 (remote_target::wait, remote_target::kill_new_fork_children)
8047 (remote_target::async): Update.
8048
8049 2018-06-10 Tom Tromey <tom@tromey.com>
8050
8051 * record-full.c (record_full_arch_list_cleanups): Remove.
8052 (record_full_message): Use try/catch.
8053 (record_full_wait_cleanups): Remove.
8054 (record_full_wait_1): Use try/catch.
8055 (record_full_restore): Likewise.
8056
8057 2018-06-10 Tom Tromey <tom@tromey.com>
8058
8059 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
8060 declare VEC. Add constructor.
8061 <in_target_beneath>: Now bool.
8062 (record_full_breakpoints): Now a std::vector, static.
8063 (record_full_sync_record_breakpoints)
8064 (record_full_init_record_breakpoints)
8065 (record_full_target::insert_breakpoint)
8066 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
8067
8068 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
8069
8070 * dwarf2read.c (process_cu_includes): Remove struct keyword.
8071 * serial.c (serial_interface_lookup): Remove struct keyword.
8072
8073 2018-06-10 Tom Tromey <tom@tromey.com>
8074
8075 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
8076 method.
8077 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
8078 a method.
8079 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
8080 method.
8081 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
8082 "beneath" as a method.
8083 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
8084 Use "beneath" as a method.
8085
8086 2018-06-10 Tom Tromey <tom@tromey.com>
8087
8088 * tracefile.c (struct trace_file_writer_deleter): New.
8089 <operator()>: Rename from trace_file_writer_xfree.
8090 (trace_file_writer_up): New typedef.
8091 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
8092
8093 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
8094
8095 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
8096 <m_registers, m_register_status>: Change type to
8097 std::unique_ptr.
8098 * regcache.c (reg_buffer::reg_buffer): Use new instead of
8099 XCNEWVEC.
8100
8101 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
8102
8103 * common/common-regcache.h (enum register_status): Add
8104 underlying type "signed char".
8105 * regcache.h (reg_buffer) <m_register_status>: Change type to
8106 register_status *.
8107 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
8108 register_status instead of signed char.
8109 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
8110 (reg_buffer::get_register_status): Remove cast.
8111 (readable_regcache::raw_read): Remove cast.
8112 (readable_regcache::cooked_read): Remove cast.
8113
8114 2018-06-09 Tom Tromey <tom@tromey.com>
8115
8116 * source.c (reverse_search_command, forward_search_command): Use
8117 scoped_fd.
8118
8119 2018-06-09 Tom Tromey <tom@tromey.com>
8120
8121 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
8122 (serial_ops_list): Now static, std::vector.
8123 (serial_interface_lookup, serial_add_interface): Update.
8124
8125 2018-06-09 Tom Tromey <tom@tromey.com>
8126
8127 * dwarf2read.c (process_cu_includes): Update.
8128 (process_full_comp_unit): Update.
8129 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
8130 std::vector.
8131
8132 2018-06-08 Paul Koning <paul_koning@dell.com>
8133
8134 PR gdb/23252
8135
8136 * python/python.c (do_start_initialization):
8137 Avoid call to internal Python API.
8138 (init__gdb_module): New function.
8139
8140 2018-06-08 Gary Benson <gbenson@redhat.com>
8141
8142 * linux-thread-db.c (valprint.h): New include.
8143 (struct check_thread_db_info): New structure.
8144 (check_thread_db_on_load, tdb_testinfo): New static globals.
8145 (check_thread_db, check_thread_db_callback): New functions.
8146 (try_thread_db_load_1): Run integrity checks if requested.
8147 (maintenance_check_libthread_db): New function.
8148 (_initialize_thread_db): Register "maint check libthread-db"
8149 and "maint set/show check-libthread-db".
8150 * NEWS: Mention the above new commands.
8151
8152 2018-06-08 Tom Tromey <tom@tromey.com>
8153
8154 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
8155 now a method.
8156
8157 2018-06-08 Tom Tromey <tom@tromey.com>
8158
8159 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
8160
8161 2018-06-08 Tom Tromey <tom@tromey.com>
8162
8163 * common/btrace-common.h (struct btrace_data): Add constructor,
8164 destructor, move assignment operator.
8165 <empty, clear, fini>: New methods.
8166 <format>: Initialize.
8167 (btrace_data_init, btrace_data_fini, btrace_data_clear)
8168 (btrace_data_empty): Don't declare.
8169 * common/btrace-common.c (btrace_data_init): Remove.
8170 (btrace_data::fini): Rename from btrace_data_fini.
8171 (btrace_data::empty): Rename from btrace_data_empty.
8172 (btrace_data::clear): Rename from btrace_data_clear. Return
8173 bool.
8174 * btrace.h (make_cleanup_btrace_data): Don't declare.
8175 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
8176 (parse_xml_btrace): Update.
8177 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
8178 (maint_btrace_clear_packet_history_cmd): Update.
8179
8180 2018-06-07 Pedro Alves <palves@redhat.com>
8181
8182 * target.h (target_ops) <beneath>: Now a method. All references
8183 updated.
8184 (class target_stack): New.
8185 * target.c (g_target_stack): New.
8186 (g_current_top_target): Delete.
8187 (current_top_target): Get the top target out of g_target_stack.
8188 (target_stack::push, target_stack::unpush): New.
8189 (push_target, unpush_target): Reimplement.
8190 (target_is_pushed): Reimplement in terms of g_target_stack.
8191 (target_ops::beneath, target_stack::find_beneath): New.
8192
8193 2018-06-07 Pedro Alves <palves@redhat.com>
8194
8195 * target.h (find_target_beneath): Delete declaration.
8196 * target.c (find_target_beneath): Delete definition.
8197 * aix-thread.c: All callers of find_target_beneath adjusted to
8198 call target_ops::beneath instead.
8199 * bsd-uthread.c: Likewise.
8200 * linux-thread-db.c: Likewise.
8201 * ravenscar-thread.c: Likewise.
8202 * sol-thread.c: Likewise.
8203 * spu-multiarch.c: Likewise.
8204
8205 2018-06-07 Pedro Alves <palves@redhat.com>
8206
8207 * target.h (target_ops) <beneath>: Now a method. All references
8208 updated.
8209 (target_ops) <m_beneath>: New.
8210 * target.c (target_ops::beneath): New.
8211 * corelow.c: Adjust all references to target_ops::beneath.
8212 * linux-thread-db.c: Likewise.
8213 * make-target-delegates: Likewise.
8214 * record-btrace.c: Likewise.
8215 * record-full.c: Likewise.
8216 * remote.c: Likewise.
8217 * target.c: Likewise.
8218 * target-delegates.c: Regenerate.
8219
8220 2018-06-07 Pedro Alves <palves@redhat.com>
8221
8222 * target.h (target_stack): Delete.
8223 (current_top_target): Declare function.
8224 * target.c (target_stack): Delete.
8225 (g_current_top_target): New.
8226 (current_top_target): New function.
8227 * auxv.c: Use current_top_target instead of target_stack
8228 throughout.
8229 * avr-tdep.c: Likewise.
8230 * breakpoint.c: Likewise.
8231 * corefile.c: Likewise.
8232 * elfread.c: Likewise.
8233 * eval.c: Likewise.
8234 * exceptions.c: Likewise.
8235 * frame.c: Likewise.
8236 * gdbarch-selftests.c: Likewise.
8237 * gnu-v3-abi.c: Likewise.
8238 * ia64-tdep.c: Likewise.
8239 * ia64-vms-tdep.c: Likewise.
8240 * infcall.c: Likewise.
8241 * infcmd.c: Likewise.
8242 * infrun.c: Likewise.
8243 * linespec.c: Likewise.
8244 * linux-tdep.c: Likewise.
8245 * minsyms.c: Likewise.
8246 * ppc-linux-nat.c: Likewise.
8247 * ppc-linux-tdep.c: Likewise.
8248 * procfs.c: Likewise.
8249 * regcache.c: Likewise.
8250 * remote.c: Likewise.
8251 * rs6000-tdep.c: Likewise.
8252 * s390-linux-nat.c: Likewise.
8253 * s390-tdep.c: Likewise.
8254 * solib-aix.c: Likewise.
8255 * solib-darwin.c: Likewise.
8256 * solib-dsbt.c: Likewise.
8257 * solib-spu.c: Likewise.
8258 * solib-svr4.c: Likewise.
8259 * solib-target.c: Likewise.
8260 * sparc-tdep.c: Likewise.
8261 * sparc64-tdep.c: Likewise.
8262 * spu-tdep.c: Likewise.
8263 * symfile.c: Likewise.
8264 * symtab.c: Likewise.
8265 * target-descriptions.c: Likewise.
8266 * target-memory.c: Likewise.
8267 * target.c: Likewise.
8268 * target.h: Likewise.
8269 * tracefile-tfile.c: Likewise.
8270 * tracepoint.c: Likewise.
8271 * valops.c: Likewise.
8272 * valprint.c: Likewise.
8273 * value.c: Likewise.
8274 * windows-tdep.c: Likewise.
8275 * mi/mi-main.c: Likewise.
8276
8277 2018-06-07 Tom Tromey <tom@tromey.com>
8278
8279 * valprint.h (build_address_symbolic): Declare.
8280 * printcmd.c (print_address_symbolic): Update.
8281 (build_address_symbolic): Change "name" and "filename" to
8282 std::string.
8283 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
8284 Update.
8285 * defs.h (build_address_symbolic): Remove declaration.
8286
8287 2018-06-07 Alan Hayward <alan.hayward@arm.com>
8288
8289 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
8290 (aarch64_vnv_type): Add function.
8291 (aarch64_pseudo_register_name): Add V regs for SVE.
8292 (aarch64_pseudo_register_type): Likewise.
8293 (aarch64_pseudo_register_reggroup_p): Likewise.
8294 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
8295 (aarch64_pseudo_read_value): Add V regs for SVE.
8296 (aarch64_pseudo_write_2): Use V0 offset for SVE
8297 (aarch64_pseudo_write): Add V regs for SVE.
8298 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
8299
8300 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
8301
8302 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
8303 (sve_vl_from_vq): Likewise.
8304
8305 2018-06-05 Tom Tromey <tom@tromey.com>
8306
8307 * cli/cli-cmds.c (show_version): Update.
8308 * top.c (print_gdb_version): Add "interactive" parameter.
8309 Update.
8310 * main.c (captured_main_1): Update.
8311 * top.h (print_gdb_version): Add "interactive" parameter and a
8312 comment.
8313
8314 2018-06-05 David Malcolm <dmalcolm@redhat.com>
8315
8316 * common/enum-flags.h: Add trailing semicolon to example in
8317 comment.
8318
8319 2018-06-05 Tom Tromey <tom@tromey.com>
8320
8321 PR cli/12326:
8322 * NEWS: Add entry about pager.
8323 * utils.c (pagination_disabled_for_command): New global.
8324 (prompt_for_continue): Allow "c" response to prompt.
8325 (reinitialize_more_filter): Clear
8326 pagination_disabled_for_command.
8327 (fputs_maybe_filtered): Check pagination_disabled_for_command.
8328
8329 2018-06-04 Tom Tromey <tom@tromey.com>
8330
8331 * ada-lang.h (ada_lookup_symbol_list): Update.
8332 * ada-lang.c (resolve_subexp): Update.
8333 (symbols_are_identical_enums): Change type of syms. Remove nsyms
8334 parameter.
8335 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
8336 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
8337 results parameter to std::vector.
8338 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
8339 Update.
8340 * ada-exp.y (block_lookup): Update.
8341 (select_possible_type_sym): Change type of syms. Remove nsyms
8342 parameter.
8343 (write_var_or_type, write_name_assoc): Update.
8344
8345 2018-06-04 Joel Brobecker <brobecker@adacore.com>
8346
8347 * windows-nat.c (windows_nat_target::xfer_partial): Return
8348 TARGET_XFER_E_IO if we need to delegate to the target beneath
8349 but BENEATH is NULL.
8350
8351 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
8352
8353 * Makefile.in (config.status): Add configure.nat as a
8354 dependency.
8355
8356 2018-06-04 Tom Tromey <tom@tromey.com>
8357
8358 * cp-name-parser.y (cpname_state): Add method declarations.
8359 (HANDLE_QUAL): Update.
8360 (cpname_state::d_grab, cpname_state::fill_comp)
8361 (cpname_state::make_operator, cpname_state::make_dtor)
8362 (cpname_state::make_builtin_type, cpname_state::make_name)
8363 (cpname_state::d_qualify, cpname_state::d_int_type)
8364 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
8365 (%union): Move earlier.
8366
8367 2018-06-04 Alan Hayward <alan.hayward@arm.com>
8368
8369 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
8370
8371 2018-06-04 Alan Hayward <alan.hayward@arm.com>
8372
8373 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
8374 (aarch64_pseudo_write_1): Likewise.
8375 (aarch64_pseudo_read_value): Use helper.
8376 (aarch64_pseudo_write): Likewise.
8377
8378 2018-06-04 Pedro Alves <palves@redhat.com>
8379
8380 * darwin-nat.c (darwin_ops): Delete.
8381 (darwin_attach_pid): Use get_native_target.
8382
8383 2018-06-04 Alan Hayward <alan.hayward@arm.com>
8384
8385 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
8386 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
8387
8388 2018-06-04 Alan Hayward <alan.hayward@arm.com>
8389
8390 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
8391 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
8392 (aarch64_gdbarch_init): Check for SVE.
8393 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
8394
8395 2018-06-04 Alan Hayward <alan.hayward@arm.com>
8396
8397 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
8398 * aarch64-tdep.h (aarch64_read_description): Likewise.
8399 * arch/aarch64.c (aarch64_create_target_description): Likewise.
8400 * arch/aarch64.h (aarch64_create_target_description): Likewise.
8401 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
8402 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
8403 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
8404
8405 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
8406
8407 * value.c (value_fetch_lazy_bitfield): New.
8408 (value_fetch_lazy_memory): New.
8409 (value_fetch_lazy_register): New.
8410 (value_fetch_lazy): Factor out to smaller functions.
8411
8412 2018-06-01 Tom Tromey <tom@tromey.com>
8413
8414 * cp-name-parser.y (backslashable, represented): Now const.
8415
8416 2018-06-01 Tom Tromey <tom@tromey.com>
8417
8418 * cp-name-parser.y: Include parser-defs.h.
8419 (parser_fprintf): Remove declaration.
8420
8421 2018-06-01 Tom Tromey <tom@tromey.com>
8422
8423 * cp-name-parser.y: Use %pure-parser, %lex-param, and
8424 %parse-param.
8425 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
8426 (global_result): Remove globals.
8427 (struct cpname_state): New.
8428 (yyparse): Don't declare.
8429 (yylex, yyerror): Move declarations after %union.
8430 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
8431 (make_name): Add state parameter.
8432 Update all callers.
8433 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
8434 parameter.
8435 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
8436 Update.
8437 (yylex): Add lvalp, state parameters.
8438 (yyerror): Add state parameter.
8439 (cp_demangled_name_to_comp): Update.
8440
8441 2018-06-01 Tom Tromey <tom@tromey.com>
8442
8443 * cp-name-parser.y (parser_fprintf): Declare.
8444 (GDB_YY_REMAP_PREFIX): Define.
8445 Include yy-remap.h. Don't redefine yy* identifiers.
8446
8447 2018-06-01 Tom Tromey <tom@tromey.com>
8448
8449 * python/py-type.c (typy_legacy_template_argument): Update.
8450 * cp-support.h (cp_demangled_name_to_comp): Update.
8451 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
8452 parameter to be a "std::string *".
8453 (main): Update.
8454
8455 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
8456
8457 * ada-lex.l: Include "diagnostics.h" instead of
8458 "common/diagnostics.h".
8459 * unittests/environ-selftests.c: Likewise.
8460 * common/diagnostics.h: Moved to ../include.
8461
8462 2018-06-01 Joel Brobecker <brobecker@adacore.com>
8463
8464 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
8465 to language_mode_manual while calling breakpoint_re_set_one.
8466
8467 2018-06-01 Tom Tromey <tom@tromey.com>
8468
8469 * valops.c (value_cast_structs, destructor_name_p): Update.
8470 * symtab.c (gdb_mangle_name): Update.
8471 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
8472 Update.
8473 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
8474 (pascal_object_print_value_fields, pascal_object_print_value):
8475 Update.
8476 * p-typeprint.c (pascal_type_print_derivation_info): Update.
8477 * linespec.c (find_methods): Update.
8478 * gdbtypes.h (type_name_no_tag): Remove.
8479 (type_name_or_error): Rename from type_name_no_tag_or_error.
8480 * gdbtypes.c (type_name_no_tag): Remove.
8481 (type_name_or_error): Rename from type_name_no_tag_or_error.
8482 (lookup_struct_elt_type, check_typedef): Update.
8483 * expprint.c (print_subexp_standard): Update.
8484 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
8485 * d-namespace.c (d_lookup_nested_symbol): Update.
8486 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
8487 (cp_print_class_member): Update.
8488 * cp-namespace.c (cp_lookup_nested_symbol): Update.
8489 * completer.c (add_struct_fields): Update.
8490 * c-typeprint.c (cp_type_print_derivation_info)
8491 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
8492 Update.
8493 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
8494 (ada_prefer_type, ada_is_exception_sym): Update.
8495
8496 2018-06-01 Tom Tromey <tom@tromey.com>
8497
8498 * valops.c (enum_constant_from_type, value_namespace_elt)
8499 (value_maybe_namespace_elt): Update.
8500 * valarith.c (find_size_for_pointer_math): Update.
8501 * target-descriptions.c (make_gdb_type): Update.
8502 * symmisc.c (print_symbol): Update.
8503 * stabsread.c (define_symbol, read_type)
8504 (complain_about_struct_wipeout, add_undefined_type)
8505 (cleanup_undefined_types_1): Update.
8506 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
8507 (rust_range_type_p, val_print_struct, rust_print_struct_def)
8508 (rust_internal_print_type, rust_composite_type)
8509 (rust_evaluate_funcall, rust_evaluate_subexp)
8510 (rust_inclusive_range_type_p): Update.
8511 * python/py-type.c (typy_get_tag): Update.
8512 * p-typeprint.c (pascal_type_print_base): Update.
8513 * mdebugread.c (parse_symbol, parse_type): Update.
8514 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
8515 Update.
8516 * guile/scm-type.c (gdbscm_type_tag): Update.
8517 * go-lang.c (sixg_string_p): Update.
8518 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
8519 Update.
8520 * gdbtypes.h (struct main_type) <tag_name>: Remove.
8521 (TYPE_TAG_NAME): Remove.
8522 * gdbtypes.c (type_name_no_tag): Simplify.
8523 (check_typedef, check_types_equal, recursive_dump_type)
8524 (copy_type_recursive, arch_composite_type): Update.
8525 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
8526 in summary mode when needed.
8527 * eval.c (evaluate_funcall): Update.
8528 * dwarf2read.c (fixup_go_packaging, read_structure_type)
8529 (process_structure_scope, read_enumeration_type)
8530 (read_namespace_type, read_module_type, determine_prefix): Update.
8531 * cp-support.c (inspect_type): Update.
8532 * coffread.c (process_coff_symbol, decode_base_type): Update.
8533 * c-varobj.c (c_is_path_expr_parent): Update.
8534 * c-typeprint.c (c_type_print_base_struct_union): Update.
8535 (c_type_print_base_1): Update. Print struct/class/union/enum in
8536 summary when using C language.
8537 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
8538 (gen_maybe_namespace_elt): Update.
8539 * ada-lang.c (ada_type_name): Simplify.
8540 (empty_record, ada_template_to_fixed_record_type_1)
8541 (template_to_static_fixed_type)
8542 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
8543
8544 2018-06-01 Tom Tromey <tom@tromey.com>
8545
8546 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
8547 c_print_type.
8548 * c-typeprint.c (c_print_type_1): Add "language" parameter.
8549 (c_print_type): Update.
8550 (c_print_type): New overload.
8551 (c_type_print_varspec_prefix, c_type_print_args)
8552 (c_type_print_varspec_suffix, c_print_type_no_offsets)
8553 (c_type_print_base_struct_union, c_type_print_base_1)
8554 (cp_type_print_method_args): Add "language" parameter.
8555 (c_type_print_base): Update.
8556 * c-lang.h (c_print_type): Add new overload.
8557
8558 2018-06-01 Tom Tromey <tom@tromey.com>
8559
8560 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
8561 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
8562
8563 2018-06-01 Alan Hayward <alan.hayward@arm.com>
8564
8565 * aarch64-tdep.c (aarch64_sve_register_names): New const
8566 var.
8567 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
8568 (AARCH64_SVE_Z_REGS_NUM): New define.
8569 (AARCH64_SVE_P_REGS_NUM): Likewise.
8570 (AARCH64_SVE_NUM_REGS): Likewise.
8571
8572 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
8573
8574 * nat/linux-ptrace.h [__alpha__]
8575 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
8576 definitions.
8577
8578 2018-05-31 Maciej W. Rozycki <macro@mips.com>
8579
8580 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
8581 the endianness selected.
8582 * NEWS: Document `set endian auto' mode operation update.
8583
8584 2018-05-31 Alan Hayward <alan.hayward@arm.com>
8585
8586 * Makefile.in: Add new header.
8587 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
8588 (sve_vl_from_vg): Likewise.
8589 (sve_vq_from_vl): Likewise.
8590 (sve_vl_from_vq): Likewise.
8591 (sve_vq_from_vg): Likewise.
8592 (sve_vg_from_vq): Likewise.
8593 * configure.nat: Add new c file.
8594 * nat/aarch64-sve-linux-ptrace.c: New file.
8595 * nat/aarch64-sve-linux-ptrace.h: New file.
8596
8597 2018-05-31 Alan Hayward <alan.hayward@arm.com>
8598
8599 * aarch64-linux-nat.c (aarch64_linux_read_description):
8600 Add parmeter zero.
8601 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
8602 Likewise.
8603 * aarch64-tdep.c (tdesc_aarch64_list): Add.
8604 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
8605 (aarch64_gdbarch_init): Add parmeter zero.
8606 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
8607 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
8608 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
8609 parmeter.
8610 * doc/gdb.texinfo: Describe SVE feature
8611 * features/aarch64-sve.c: New file.
8612
8613 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
8614
8615 PR gdb/23210
8616 * gdbarch.sh (significant_addr_bit): Default to zero when
8617 not set by target architecture.
8618 * gdbarch.c: Re-generated.
8619 * utils.c (address_significant): Update.
8620
8621 2018-05-30 Joel Brobecker <brobecker@adacore.com>
8622
8623 * stack.c (func_command): Remove trailing newline in call to error.
8624
8625 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8626
8627 * regcache.h (regcache_raw_collect): Remove, update callers to
8628 use regcache::raw_collect.
8629 * regcache.c (regcache_raw_collect): Remove.
8630
8631 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8632
8633 * regcache.h (regcache_raw_supply): Remove, update callers to
8634 use detached_regcache::raw_supply.
8635 * regcache.c (regcache_raw_supply): Remove.
8636
8637 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8638
8639 * regcache.h (regcache_cooked_write_part): Remove, update
8640 callers to use regcache::cooked_write_part.
8641 * regcache.c (regcache_cooked_write_part): Remove.
8642
8643 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8644
8645 * regcache.h (regcache_cooked_read_part): Remove, update callers
8646 to use readable_regcache::cooked_read_part.
8647 * regcache.c (regcache_cooked_read_part): Remove.
8648
8649 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8650
8651 * regcache.h (regcache_cooked_read_value): Remove, update
8652 callers to use readable_regcache::cooked_read_value.
8653 * regcache.c (regcache_cooked_read_value): Remove.
8654
8655 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8656
8657 * regcache.h (regcache_cooked_write): Remove, update callers to
8658 use regcache::cooked_write.
8659 * regcache.c (regcache_cooked_write): Remove.
8660
8661 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8662
8663 * regcache.h (regcache_invalidate): Remove, update callers to
8664 use detached_regcache::invalidate instead.
8665 * regcache.c (regcache_invalidate): Remove.
8666
8667 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8668
8669 * regcache.h (regcache_raw_write_part): Remove, update callers
8670 to use regcache::raw_write_part instead.
8671 * regcache.c (regcache_raw_write_part): Remove.
8672
8673 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8674
8675 * regcache.h (regcache_raw_read_part): Remove, update callers to
8676 use readable_regcache::raw_read_part instead.
8677 * regcache.c (regcache_raw_read_part): Remove.
8678
8679 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8680
8681 * regcache.h (regcache_cooked_read): Remove, update callers to
8682 use readable_regcache::cooked_read instead.
8683 * regcache.c (regcache_cooked_read): Remove.
8684
8685 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8686
8687 * regcache.h (regcache_raw_write): Remove, update callers to use
8688 regcache::raw_write instead.
8689 * regcache.c (regcache_raw_write): Remove.
8690
8691 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8692
8693 * regcache.h (regcache_raw_read): Remove, update callers to use
8694 readable_regcache::raw_read instead.
8695 * regcache.c (regcache_raw_read): Remove.
8696
8697 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8698
8699 * regcache.h (regcache_raw_update): Remove, update callers to
8700 use readable_regcache::raw_update instead.
8701 * regcache.c (regcache_raw_update): Remove.
8702
8703 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8704
8705 * regcache.h (regcache_register_status): Remove, update callers
8706 to use reg_buffer::get_register_status directly instead.
8707 * regcache.c (regcache_register_status): Remove.
8708
8709 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8710
8711 * regcache.h (regcache_get_ptid): Remove, update all callers to
8712 call regcache::ptid instead.
8713 * regcache.c (regcache_get_ptid): Remove.
8714
8715 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
8716
8717 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
8718
8719 2018-05-30 Pedro Alves <palves@redhat.com>
8720
8721 * common/common-exceptions.h (exception_rethrow): Use
8722 ATTRIBUTE_NORETURN.
8723
8724 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
8725
8726 * breakpoint.c (print_solib_event, check_status_catch_solib):
8727 Remove struct keyword in range-based for loops.
8728 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
8729 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
8730 Likewise.
8731 * linespec.c (find_superclass_methods, search_minsyms_for_name):
8732 Likewise.
8733 * symfile.c (addr_info_make_relative): Likewise.
8734 * thread.c (value_in_thread_stack_temporaries): Likewise.
8735
8736 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
8737
8738 PR gdb/16841
8739 * valops.c (value_struct_elt_for_reference): Call check_typedef on
8740 aggregate type to get its real type before accessing it.
8741
8742 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
8743
8744 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
8745 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
8746 * coff-pe-read.c (add_pe_forwarded_sym): Replace
8747 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
8748 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
8749 * jit.c (jit_breakpoint_re_set_internal): Likewise.
8750 * printcmd.c (info_address_command): Likewise.
8751
8752 2018-05-29 Tom Tromey <tom@tromey.com>
8753
8754 * windows-nat.c (handle_exception): Update fall-through comment.
8755
8756 2018-05-29 Tom Tromey <tom@tromey.com>
8757
8758 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
8759 (struct program_space) <added_solibs>: Now a std::vector.
8760 * breakpoint.c (print_solib_event): Update.
8761 (check_status_catch_solib): Update.
8762 * progspace.c (clear_program_space_solib_cache): Update.
8763 * solib.c (update_solib_list): Update.
8764
8765 2018-05-29 Tom Tromey <tom@tromey.com>
8766
8767 * python/py-type.c (typy_richcompare): Update.
8768 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
8769 * gdbtypes.h (types_deeply_equal): Return bool.
8770 (types_equal): Likewise.
8771 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
8772 declare VEC.
8773 (check_types_equal): Change worklist to std::vector. Return
8774 bool.
8775 (struct type_equality_entry): Add constructor.
8776 (compare_maybe_null_strings): Return bool.
8777 (check_types_worklist): Return bool. Change worklist to
8778 std::vector.
8779 (types_deeply_equal): Use std::vector.
8780 (types_equal): Return bool.
8781 (compare_maybe_null_strings): Simplify.
8782
8783 2018-05-29 Tom Tromey <tom@tromey.com>
8784
8785 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
8786
8787 2018-05-29 Tom Tromey <tom@tromey.com>
8788
8789 * objc-lang.h: Don't include cp-support.h.
8790 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
8791 declare VEC.
8792
8793 2018-05-27 Tom Tromey <tom@tromey.com>
8794
8795 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
8796
8797 2018-05-25 Tom Tromey <tom@tromey.com>
8798
8799 * value.c (value::location): Initialize.
8800
8801 2018-05-25 Tom Tromey <tom@tromey.com>
8802
8803 * dbxread.c (init_bincl_list): Remove.
8804 (bincl_list): Now a std::vector.
8805 (bincls_allocated, next_bincl): Remove.
8806 (free_bincl_list, do_free_bincl_list_cleanup)
8807 (make_cleanup_free_bincl_list): Remove.
8808 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
8809 unique_xmalloc_ptr.
8810 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
8811 (struct header_file_location): Add constructor.
8812 (add_bincl_to_list): Remove.
8813
8814 2018-05-25 Tom Tromey <tom@tromey.com>
8815
8816 * tui/tui.c (tui_enable): Update.
8817 * mi/mi-interp.c (mi_interp::init): Update.
8818 * interps.h (class interp) <name>: New method.
8819 <m_name>: Rename from name.
8820 (~scoped_restore_interp): Update.
8821 * interps.c (interp::interp): Update.
8822 (interp_add, interp_set, interp_lookup_existing)
8823 (current_interp_named_p): Update.
8824
8825 2018-05-25 Tom Tromey <tom@tromey.com>
8826
8827 * interps.c (interp_name): Remove.
8828 * mi/mi-interp.c (mi_interp::init): Update.
8829 * interps.h (interp_name): Remove.
8830 (~scoped_restore_interp): Update.
8831 * tui/tui.c (tui_enable): Update.
8832
8833 2018-05-25 Tom Tromey <tom@tromey.com>
8834
8835 * utils.c (fputs_maybe_filtered): Update.
8836 * linespec.c (decode_line_full): Update.
8837 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
8838 (mi_print_breakpoint_for_event, mi_solib_loaded)
8839 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
8840 (mi_user_selected_context_changed): Update.
8841 * mi/mi-main.c (mi_execute_command): Update.
8842 * cli/cli-script.c (execute_control_command): Update.
8843 * python/python.c (execute_gdb_command): Update.
8844 * solib.c (info_sharedlibrary_command): Update.
8845 * interps.c (interp_ui_out): Remove.
8846 * interps.h (interp_ui_out): Remove.
8847
8848 2018-05-25 Tom Tromey <tom@tromey.com>
8849
8850 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
8851 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
8852 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
8853
8854 2018-05-25 Tom Tromey <tom@tromey.com>
8855
8856 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
8857 * interps.c (interp_exec): Use scoped_restore.
8858
8859 2018-05-25 Tom Tromey <tom@tromey.com>
8860
8861 * remote.c (remote_target::remote_file_get): Use
8862 gdb::byte_vector.
8863 (remote_target::remote_file_put): Likewise.
8864
8865 2018-05-25 Tom Tromey <tom@tromey.com>
8866
8867 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
8868 a std::string.
8869 (get_pe_section_index, add_pe_exported_sym): Update.
8870 (read_pe_exported_syms): Use gdb::def_vector.
8871
8872 2018-05-25 Tom Tromey <tom@tromey.com>
8873
8874 * frame.c (remove_prev_frame): Remove.
8875 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
8876
8877 2018-05-25 Maciej W. Rozycki <macro@mips.com>
8878
8879 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
8880 Remove prototypes.
8881 * mips-linux-nat.c (supply_fpregset): Always call
8882 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
8883 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
8884 `mips_fill_fpregset'.
8885 * mips-linux-tdep.c (mips_supply_fpregset)
8886 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
8887 (mips_fill_fpregset_wrapper): Remove functions.
8888 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
8889 (mips_linux_fpregset): Remove variable.
8890 (mips_linux_iterate_over_regset_sections): Use
8891 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
8892 (mips_linux_o32_sigframe_init): Remove comment.
8893
8894 2018-05-25 Pedro Alves <palves@redhat.com>
8895
8896 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
8897 (struct readahead_cache, struct packet_reg, struct
8898 remote_arch_state, class remote_state): Move higher up in the
8899 file.
8900 (remote_target::m_remote_state): Now an object instead of a pointer.
8901 (remote_target::get_remote_state): Adjust.
8902
8903 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
8904
8905 * stack.c (select_and_print_frame): Delete.
8906 (struct function_bounds): Move struct within function.
8907 (func_command): Most content moved into new function
8908 find_frame_for_function, use new function, print result, add
8909 function comment.
8910 (find_frame_for_function): New function, now returns a result.
8911
8912 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8913
8914 * stack.c (iterate_over_block_arg_vars): Fix comment.
8915 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
8916
8917 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
8918
8919 PR gdb/23203
8920 * frame.c
8921 (scoped_restore_selected_frame::scoped_restore_selected_frame):
8922 Define.
8923 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
8924 Define.
8925 * frame.h (class scoped_restore_selected_frame): New class.
8926 * stack.c (print_frame_local_vars): Remove catching and rethrowing
8927 of any exception, use scoped_restore_selected_frame to restore the
8928 frame instead.
8929
8930 2018-05-24 Pedro Alves <palves@redhat.com>
8931
8932 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
8933 override.
8934
8935 2018-05-23 Tom Tromey <tom@tromey.com>
8936
8937 * complaints.c (struct complaints): Remove.
8938 (symfile_complaint_book): Remove.
8939 (series): New global.
8940 (complaint_internal): Update.
8941 (clear_complaints): Update.
8942
8943 2018-05-23 Tom Tromey <tom@tromey.com>
8944
8945 * complaints.c (counters): New global.
8946 (struct complain): Remove.
8947 (struct complaints) <root>: Remove.
8948 (complaint_sentinel): Remove.
8949 (symfile_complaint_book): Update.
8950 (find_complaint) Remove.
8951 (complaint_internal, clear_complaints): Update.
8952
8953 2018-05-23 Tom Tromey <tom@tromey.com>
8954
8955 * complaints.c (struct complain) <file, line>: Remove.
8956 (find_complaint): Remove file, line parameters.
8957 (complaint_internal): Update.
8958
8959 2018-05-23 Tom Tromey <tom@tromey.com>
8960
8961 * complaints.c (vcomplaint): Remove.
8962 (complaint_internal) Merge in contents of vcomplaint.
8963
8964 2018-05-23 Tom Tromey <tom@tromey.com>
8965
8966 * complaints.c (struct complaints) <explanation>: Remove.
8967 (symfile_explanations): Remove.
8968 (symfile_complaint_book): Update.
8969 (vcomplaint): Update.
8970 (struct explanation): Remove.
8971
8972 2018-05-23 Tom Tromey <tom@tromey.com>
8973
8974 * complaints.c (symfile_complaints): Remove.
8975 (complaint_internal): Remove "complaints" parameter.
8976 (clear_complaints, vcomplaint): Remove "c" parameter.
8977 (get_complaints): Remove.
8978 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
8979 (dwarf2_debug_line_missing_file_complaint)
8980 (dwarf2_debug_line_missing_end_sequence_complaint)
8981 (dwarf2_complex_location_expr_complaint)
8982 (dwarf2_const_value_length_mismatch_complaint)
8983 (dwarf2_section_buffer_overflow_complaint)
8984 (dwarf2_macro_malformed_definition_complaint)
8985 (dwarf2_invalid_attrib_class_complaint)
8986 (create_addrmap_from_index, dw2_symtab_iter_next)
8987 (dw2_expand_marked_cus)
8988 (dw2_debug_names_iterator::find_vec_in_debug_names)
8989 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
8990 (create_debug_type_hash_table, init_cutu_and_read_dies)
8991 (partial_die_parent_scope, add_partial_enumeration)
8992 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
8993 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
8994 (read_import_statement, read_file_scope, create_dwo_cu_reader)
8995 (create_cus_hash_table, create_dwp_hash_table)
8996 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
8997 (dwarf2_rnglists_process, dwarf2_ranges_process)
8998 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
8999 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
9000 (handle_struct_member_die, process_structure_scope)
9001 (read_array_type, read_common_block, read_module_type)
9002 (read_tag_pointer_type, read_typedef, read_base_type)
9003 (read_subrange_type, load_partial_dies, partial_die_info::read)
9004 (partial_die_info::read, partial_die_info::read)
9005 (partial_die_info::read, read_checked_initial_length_and_offset)
9006 (dwarf2_string_attr, read_formatted_entries)
9007 (dwarf_decode_line_header)
9008 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
9009 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
9010 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
9011 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
9012 (get_signatured_type, get_DW_AT_signature_type)
9013 (decode_locdesc, file_file_name, consume_improper_spaces)
9014 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
9015 (dwarf_decode_macro_bytes, dwarf_decode_macros)
9016 (dwarf2_symbol_mark_computed, set_die_type)
9017 (read_attribute_value): Update.
9018 * stap-probe.c (handle_stap_probe, get_stap_base_address):
9019 Update.
9020 * dbxread.c (unknown_symtype_complaint)
9021 (lbrac_mismatch_complaint, repeated_header_complaint)
9022 (set_namestring, function_outside_compilation_unit_complaint)
9023 (read_dbx_symtab, process_one_symbol): Update.
9024 * gdbtypes.c (stub_noname_complaint): Update.
9025 * windows-nat.c (handle_unload_dll): Update.
9026 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
9027 (decode_base_type): Update.
9028 * xcoffread.c (bf_notfound_complaint, ef_complaint)
9029 (eb_complaint, record_include_begin, record_include_end)
9030 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
9031 (process_xcoff_symbol, read_symbol)
9032 (function_outside_compilation_unit_complaint)
9033 (scan_xcoff_symtab): Update.
9034 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
9035 * buildsym.c (finish_block_internal, make_blockvector)
9036 (end_symtab_get_static_block, augment_type_symtab): Update.
9037 * dtrace-probe.c (dtrace_process_dof)
9038 (dtrace_static_probe_ops::get_probes): Update.
9039 * complaints.h (struct complaint): Don't declare.
9040 (symfile_complaints): Remove.
9041 (complaint_internal): Remove "complaints" parameter.
9042 (complaint): Likewise.
9043 (clear_complaints): Likewise.
9044 * symfile.c (syms_from_objfile_1, finish_new_objfile)
9045 (reread_symbols): Update.
9046 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
9047 (dwarf2_frame_cache, decode_frame_entry): Update.
9048 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
9049 * objc-lang.c (lookup_objc_class, lookup_child_selector)
9050 (info_selectors_command): Update.
9051 * macrotab.c (macro_include, check_for_redefinition)
9052 (macro_undef): Update.
9053 * objfiles.c (filter_overlapping_sections): Update.
9054 * stabsread.c (invalid_cpp_abbrev_complaint)
9055 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
9056 (define_symbol, error_type, read_type, rs6000_builtin_type)
9057 (stabs_method_name_from_physname, read_member_functions)
9058 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
9059 (attach_fields_to_type, complain_about_struct_wipeout)
9060 (read_range_type, read_args, common_block_start)
9061 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
9062 Update.
9063 * mdebugread.c (index_complaint, unknown_ext_complaint)
9064 (basic_type_complaint, bad_tag_guess_complaint)
9065 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
9066 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
9067 (parse_procedure, parse_lines)
9068 (function_outside_compilation_unit_complaint)
9069 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
9070 (bad_tag_guess_complaint, reg_value_complaint): Update.
9071 * cp-support.c (demangled_name_complaint): Update.
9072 * macroscope.c (sal_macro_scope): Update.
9073 * dwarf-index-write.c (class debug_names): Update.
9074
9075 2018-05-23 Tom Tromey <tom@tromey.com>
9076
9077 * complaints.c (clear_complaints): Remove "noisy" parameter.
9078 * complaints.h (clear_complaints): Update.
9079 * symfile.c (syms_from_objfile_1, finish_new_objfile)
9080 (reread_symbols): Update.
9081
9082 2018-05-23 Tom Tromey <tom@tromey.com>
9083
9084 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
9085 SUBSEQUENT_MESSAGE.
9086 (vcomplaint, clear_complaints): Update.
9087 (symfile_explanations): Remove some messages.
9088
9089 2018-05-23 Tom Tromey <tom@tromey.com>
9090
9091 * complaints.c (internal_complaint): Remove.
9092 * complaints.h (internal_complaint): Remove.
9093
9094 2018-05-22 Maciej W. Rozycki <macro@mips.com>
9095
9096 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
9097
9098 2018-05-22 Pedro Alves <palves@redhat.com>
9099
9100 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
9101 (remote_fileio_badfd, remote_fileio_return_errno)
9102 (remote_fileio_return_success, remote_fileio_func_open)
9103 (remote_fileio_func_open, remote_fileio_func_close)
9104 (remote_fileio_func_read, remote_fileio_func_write)
9105 (remote_fileio_func_lseek, remote_fileio_func_rename)
9106 (remote_fileio_func_unlink, remote_fileio_func_stat)
9107 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
9108 (remote_fileio_func_isatty, remote_fileio_func_system): Add
9109 remote_target parameter.
9110 (remote_fio_func_map) <func>: Add remote_target parameter.
9111 (do_remote_fileio_request, remote_fileio_request):
9112 * remote-fileio.h (remote_fileio_request):
9113 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
9114 remote_target parameter.
9115 (remote_notif_process, handle_notification): Adjust to pass down
9116 the remote.
9117 (remote_notif_state_allocate): Add remote_target parameter. Save
9118 it.
9119 * remote-notif.h (struct remote_target): Forward declare.
9120 (struct notif_client) <parse, ack, can_get_pending_events>: Add
9121 remote_target parameter.
9122 (struct remote_notif_state) <remote>: New field.
9123 (remote_notif_ack, remote_notif_parse): Add remote_target
9124 parameter.
9125 (remote_notif_state_allocate, remote_notif_state_allocate): Add
9126 remote_target parameter.
9127 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
9128 (threads_listing_context, rmt_thread_action, protocol_feature)
9129 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
9130 (packet_result, struct threads_listing_context, remote_state):
9131 Move definitions and declarations higher up.
9132 (remote_target) <~remote_target>: Declare.
9133 (remote_download_command_source, remote_file_put, remote_file_get)
9134 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
9135 (remote_hostio_pread_vFile, remote_hostio_send_command)
9136 (remote_hostio_set_filesystem, remote_hostio_open)
9137 (remote_hostio_close, remote_hostio_unlink, remote_state)
9138 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
9139 (get_memory_write_packet_size, get_memory_read_packet_size)
9140 (append_pending_thread_resumptions, remote_detach_1)
9141 (append_resumption, remote_resume_with_vcont)
9142 (add_current_inferior_and_thread, wait_ns, wait_as)
9143 (process_stop_reply, remote_notice_new_inferior)
9144 (process_initial_stop_replies, remote_add_thread)
9145 (btrace_sync_conf, remote_btrace_maybe_reopen)
9146 (remove_new_fork_children, kill_new_fork_children)
9147 (discard_pending_stop_replies, stop_reply_queue_length)
9148 (check_pending_events_prevent_wildcard_vcont)
9149 (discard_pending_stop_replies_in_queue, stop_reply)
9150 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
9151 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
9152 (remote_interrupt_as, remote_interrupt_ns)
9153 (remote_get_noisy_reply, remote_query_attached)
9154 (remote_add_inferior, remote_current_thread, get_current_thread)
9155 (set_thread, set_general_thread, set_continue_thread)
9156 (set_general_process, write_ptid)
9157 (remote_unpack_thread_info_response, remote_get_threadinfo)
9158 (parse_threadlist_response, remote_get_threadlist)
9159 (remote_threadlist_iterator, remote_get_threads_with_ql)
9160 (remote_get_threads_with_qxfer)
9161 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
9162 (get_offsets, remote_check_symbols, remote_supported_packet)
9163 (remote_query_supported, remote_packet_size)
9164 (remote_serial_quit_handler, remote_detach_pid)
9165 (remote_vcont_probe, remote_resume_with_hc)
9166 (send_interrupt_sequence, interrupt_query)
9167 (remote_notif_get_pending_events, fetch_register_using_p)
9168 (send_g_packet, process_g_packet, fetch_registers_using_g)
9169 (store_register_using_P, store_registers_using_G)
9170 (set_remote_traceframe, check_binary_download)
9171 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
9172 (remote_xfer_live_readonly_partial, remote_read_bytes)
9173 (remote_send_printf, remote_flash_write, readchar)
9174 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
9175 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
9176 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
9177 (extended_remote_disable_randomization, extended_remote_run)
9178 (send_environment_packet, extended_remote_environment_support)
9179 (extended_remote_set_inferior_cwd, remote_write_qxfer)
9180 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
9181 (packet_command): Now methods of ...
9182 (remote_target): ... this class.
9183 (m_remote_state) <remote_target>: New field.
9184 (struct remote_state) <stop_reply_queue,
9185 remote_async_inferior_event_token, wait_forever_enabled_p>: New
9186 fields.
9187 (remote_state::remote_state): Allocate stop_reply_queue.
9188 (remote_state): Delete global.
9189 (get_remote_state_raw): Delete.
9190 (remote_target::get_remote_state): Allocate m_remote_state on
9191 demand.
9192 (get_current_remote_target): New.
9193 (remote_ops, extended_remote_ops): Delete.
9194 (wait_forever_enabled_p, remote_async_inferior_event_token):
9195 Delete, moved to struct remote_state.
9196 (remote_target::close): Delete self. Destruction bits split to
9197 ...
9198 (remote_target::~remote_target): ... this.
9199 (show_memory_packet_size): Adjust to use
9200 get_current_remote_target.
9201 (struct protocol_feature) <func>: Add remote_target parameter.
9202 All callers adjusted.
9203 (curr_quit_handler_target): New.
9204 (remote_serial_quit_handler): Reimplement.
9205 (remote_target::open_1): Adjust to use get_current_remote_target.
9206 Heap-allocate remote_target/extended_remote_target instances.
9207 (vcont_builder::vcont_builder): Add remote_target parameter, and
9208 save it in m_remote. All callers adjusted.
9209 (vcont_builder::m_remote): New field.
9210 (vcont_builder::restart, vcont_builder::flush)
9211 (vcont_builder::push_action): Use it.
9212 (remote_target::commit_resume): Use it.
9213 (struct queue_iter_param) <remote>: New field.
9214 (remote_target::remove_new_fork_children): Fill in 'remote' field.
9215 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
9216 (check_pending_event_prevents_wildcard_vcont_callback)
9217 (remote_target::check_pending_events_prevent_wildcard_vcont)
9218 (remote_target::discard_pending_stop_replies)
9219 (remote_target::discard_pending_stop_replies_in_queue)
9220 (remote_target::remote_notif_remove_queued_reply): Fill in
9221 'remote' field.
9222 (remote_notif_get_pending_events): New.
9223 (remote_target::readchar, remote_target::remote_serial_write):
9224 Save/restore curr_quit_handler_target.
9225 (putpkt): New.
9226 (kill_new_fork_children): Fill in 'remote' field.
9227 (packet_command): Use get_current_remote_target, defer to
9228 remote_target method of same name.
9229 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
9230 parameter, and save it in m_remote. All callers adjusted.
9231 (scoped_remote_fd::release): Use m_remote.
9232 (scoped_remote_fd::m_remote): New field.
9233 (remote_file_put, remote_file_get, remote_file_delete): Use
9234 get_current_remote_target, defer to remote_target method of same
9235 name.
9236 (remote_btrace_reset): Add remote_state paremeter. Update all
9237 callers.
9238 (remote_async_inferior_event_handler). Pass down 'data'.
9239 (remote_new_objfile): Use get_current_remote_target.
9240 (remote_target::vcont_r_supported): New.
9241 (set_range_stepping): Use get_current_remote_target and
9242 remote_target::vcont_r_supported.
9243 (_initialize_remote): Don't allocate 'remote_state' and
9244 'stop_reply_queue' globals.
9245 * remote.h (struct remote_target): Forward declare.
9246 (getpkt, putpkt, remote_notif_get_pending_events): Add
9247 'remote_target' parameter.
9248
9249 2018-05-22 Pedro Alves <palves@redhat.com>
9250
9251 * remote.c (vcont_builder): Now a class. Make all data members
9252 private.
9253 (vcont_builder) <vcont_builder, restart, flush, push_action>:
9254 Declare methods.
9255 (vcont_builder_restart): Rename to ...
9256 (vcont_builder::restart): ... this.
9257 (vcont_builder_flush): Rename to ...
9258 (vcont_builder::flush): ... this.
9259 (vcont_builder_push_action): Rename to ...
9260 (vcont_builder::push_action): ... this.
9261 (remote_target::commit_resume): Adjust.
9262
9263 2018-05-22 Pedro Alves <palves@redhat.com>
9264
9265 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
9266 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
9267 (get_fixed_memory_packet_size): New.
9268 (get_memory_packet_size): Use it.
9269 (set_memory_packet_size): Don't override the config size with
9270 DEFAULT_MAX_MEMORY_PACKET_SIZE.
9271 (show_memory_packet_size): Use get_fixed_memory_packet_size.
9272 Don't refer to get_memory_packet_size if not connected to a remote
9273 target. Show "(default)" if configured size is 0.
9274
9275 2018-05-22 Pedro Alves <palves@redhat.com>
9276
9277 * remote.c (remote_target::mourn_inferior): Move
9278 discard_pending_stop_replies call here from ...
9279 (_initialize_remote): ... here.
9280
9281 2018-05-22 Pedro Alves <palves@redhat.com>
9282
9283 * remote.c (compare_section_command): Remove set_general_process
9284 call.
9285
9286 2018-05-22 Pedro Alves <palves@redhat.com>
9287
9288 * remote.c (struct packet_reg, struct remote_arch_state):
9289 Move higher up in the file.
9290 (remote_state) <m_arch_states>: Store remote_arch_state values
9291 instead of remote_arch_state pointers.
9292 (remote_state::get_remote_arch_state): Adjust.
9293
9294 2018-05-22 Pedro Alves <palves@redhat.com>
9295
9296 * remote.c: Include <unordered_map>.
9297 (remote_state): Now a class.
9298 (remote_state) <get_remote_arch_state>: Declare method.
9299 <get_remote_arch_state>: New field.
9300 (remote_arch_state) <remote_arch_state>: Declare ctor.
9301 <regs>: Now a unique_ptr.
9302 (remote_gdbarch_data_handle): Delete.
9303 (get_remote_arch_state): Delete.
9304 (remote_state::get_remote_arch_state): New.
9305 (get_remote_state): Adjust to call remote_state's
9306 get_remote_arch_state method.
9307 (init_remote_state): Delete, bits factored out to ...
9308 (remote_arch_state::remote_arch_state): ... this new method.
9309 (get_remote_packet_size, get_memory_packet_size)
9310 (process_g_packet, remote_target::fetch_registers)
9311 (remote_target::prepare_to_store, store_registers_using_G)
9312 (remote_target::store_registers, remote_target::get_trace_status):
9313 Adjust to call remote_state's method.
9314 (_initialize_remote): Remove reference to
9315 remote_gdbarch_data_handle.
9316
9317 2018-05-22 Pedro Alves <palves@redhat.com>
9318
9319 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
9320 pread>: New method declarations.
9321 (remote_target::open_1): Adjust.
9322 (readahead_cache_invalidate): Rename to ...
9323 (readahead_cache::invalidate): ... this, and adjust to be a class
9324 method.
9325 (readahead_cache_invalidate_fd): Rename to ...
9326 (readahead_cache::invalidate_fd): ... this, and adjust to be a
9327 class method.
9328 (remote_hostio_pwrite): Adjust.
9329 (remote_hostio_pread_from_cache): Rename to ...
9330 (readahead_cache::pread): ... this, and adjust to be a class
9331 method.
9332 (remote_hostio_close): Adjust.
9333
9334 2018-05-22 Pedro Alves <palves@redhat.com>
9335
9336 * remote.c (remote_hostio_close_cleanup): Delete.
9337 (class scoped_remote_fd): New.
9338 (remote_file_put, remote_file_get): Use it.
9339
9340 2018-05-22 Pedro Alves <palves@redhat.com>
9341
9342 (struct vCont_action_support): Use bool and initialize all fields.
9343 (struct readahead_cache): Initialize all fields.
9344 (remote_state): Use bool and initialize all fields.
9345 (remote_state::remote_state, remote_state::~remote_state): New.
9346 (new_remote_state): Delete.
9347 (_initialize_remote): Use new to allocate remote_state.
9348
9349 2018-05-22 Pedro Alves <palves@redhat.com>
9350 張俊芝 <zjz@zjz.name>
9351
9352 PR gdb/22973
9353 * c-exp.y: Include "c-support.h".
9354 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
9355 of tolower. Use c_ident_is_alpha to scan names.
9356 * c-lang.c: Include "c-support.h".
9357 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
9358 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
9359 * c-support.h: New file, with bits factored out from ...
9360 * cp-name-parser.y: ... this file.
9361 Include "c-support.h".
9362 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
9363 c-support.h and renamed.
9364 (symbol_end, yylex): Adjust.
9365
9366 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9367
9368 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
9369 parameter type to CORE_ADDR.
9370 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
9371 parameter type in declaration to CORE_ADDR.
9372 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
9373 target_auxv_search to get AT_HWCAP and use the result to get the
9374 target description.
9375 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
9376 to CORE_ADDR. Remove the cast of the return value to unsigned
9377 long. Fix error predicate of target_auxv_search.
9378 (ppc_linux_nat_target::read_description): Change the type of the
9379 hwcap variable to CORE_ADDR.
9380
9381 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9382
9383 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
9384 if the size of fpscr is larger than 32 bits.
9385
9386 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9387
9388 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
9389 (ppc32_linux_vsxregmap): New global.
9390 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
9391 regcache_supply_regset, and regcache_collect_regset.
9392 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
9393 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
9394 (fetch_vsx_register, store_vsx_register): Remove.
9395 (fetch_vsx_registers): Add regno parameter. Get regset using
9396 ppc_linux_vsxregset. Use regset to supply registers.
9397 (store_vsx_registers): Add regno parameter. Get regset using
9398 ppc_linux_vsxregset. Use regset to collect registers.
9399 (fetch_register): Call fetch_vsx_registers instead of
9400 fetch_vsx_register.
9401 (store_register): Call store_vsx_registers instead of
9402 store_vsx_register.
9403 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
9404 new regno parameter.
9405 (store_ppc_registers): Call store_vsx_registers with -1 for the
9406 new regno parameter.
9407 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
9408 (ppc_collect_vsxregset): Remove.
9409
9410 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9411
9412 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
9413 offset fields.
9414 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
9415 for vector register offset fields.
9416 (ppc64_fbsd_reg_offsets): Likewise.
9417 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
9418 to vector register offset fields.
9419 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
9420 to vector register offset fields.
9421 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
9422 vector register offset fields.
9423 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
9424 initializers for vector register offset fields.
9425 (rs6000_aix64_reg_offsets): Likewise.
9426 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
9427 (ppc_supply_vrregset): Remove.
9428 (ppc_collect_vrregset): Remove.
9429 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
9430 (ppc_linux_vrregset) : New function.
9431 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
9432 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
9433 (ppc32_linux_vrregset): Remove.
9434 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
9435 and use result instead of ppc32_linux_vrregset.
9436 (ppc32_linux_reg_offsets): Remove initializers for vector register
9437 offset fields.
9438 (ppc64_linux_reg_offsets): Likewise.
9439 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
9440 * ppc-linux-nat.c: Include regset.h.
9441 (gdb_vrregset_t): Adjust comment to account for little-endian
9442 mode.
9443 (supply_vrregset, fill_vrregset): Remove.
9444 (fetch_altivec_register, store_altivec_register): Remove.
9445 (fetch_altivec_registers): Add regno parameter. Get regset using
9446 ppc_linux_vrregset. Use regset to supply registers.
9447 (store_altivec_registers): Add regno parameter. Get regset using
9448 ppc_linux_vrregset. Use regset to collect registers.
9449 (fetch_register): Call fetch_altivec_registers instead of
9450 fetch_altivec_register.
9451 (store_register): Call store_altivec_registers instead of
9452 store_altivec_register.
9453 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
9454 the new regno parameter.
9455 (store_ppc_registers): Call store_altivec_registers with -1 for
9456 the new regno parameter.
9457
9458 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9459
9460 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
9461 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
9462 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
9463 (gdb_vrregset_t): Change array type size to
9464 PPC_LINUX_SIZEOF_VRREGSET.
9465 (gdb_vsxregset_t): Change array type size to
9466 PPC_LINUX_SIZEOF_VSXREGSET.
9467 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
9468 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
9469 PPC_LINUX_SIZEOF_VSXREGSET.
9470
9471 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9472
9473 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
9474 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
9475 nat/ppc-linux.c.
9476 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
9477 ppc_linux_target_wordsize with tid.
9478 (ppc_linux_nat_target::read_description): Call ppc_linux_target
9479 wordsize with tid.
9480 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
9481 (ppc64_64bit_inferior_p): Add static and inline specifiers.
9482 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
9483 tid parameter. Remove static specifier.
9484 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
9485 (ppc_linux_target_wordsize): New declaration.
9486
9487 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
9488
9489 * arch/ppc-linux-common.c: New file.
9490 * arch/ppc-linux-common.h: New file.
9491 * arch/ppc-linux-tdesc.h: New file.
9492 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
9493 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
9494 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
9495 arch/ppc-linux-tdesc.h.
9496 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
9497 arch/ppc-linux-tdesc.h.
9498 (ppc_linux_nat_target::read_description): Remove target
9499 description matching code. Fill a ppc_linux_features struct and
9500 call ppc_linux_match_description with it. Move comment about ISA
9501 2.05 to ppc-linux-common.c.
9502 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
9503 arch/ppc-linux-tdesc.h.
9504 (ppc_linux_core_read_description): Remove target description
9505 matching code. Fill a ppc_linux_features struct and call
9506 ppc_linux_match_description with it.
9507 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
9508 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
9509 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
9510 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
9511 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
9512 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
9513 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
9514 (tdesc_powerpc_e500l): Remove.
9515
9516 2018-05-22 Joel Brobecker <brobecker@adacore.com>
9517
9518 * ada-lang.c (catch_assert_command): Pass empty string instead
9519 of NULL for excep_string argument.
9520
9521 2018-05-22 Maciej W. Rozycki <macro@mips.com>
9522
9523 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
9524 the width of the requested register exceeds the width of the
9525 `ptrace' data type.
9526
9527 2018-05-21 Tom Tromey <tom@tromey.com>
9528
9529 * printcmd.c (output_command): Remove.
9530 (output_command_const): Rename to output_command.
9531 * valprint.h (output_command): Rename from output_command_const.
9532 * tracepoint.c (trace_dump_actions): Call output_command.
9533
9534 2018-05-21 Tom Tromey <tom@tromey.com>
9535
9536 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
9537 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
9538 * ada-lang.h (create_ada_exception_catchpoint): Update.
9539 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
9540 std::string.
9541 (create_excep_cond_exprs, ~ada_catchpoint)
9542 (should_stop_exception, print_one_exception)
9543 (print_mention_exception, print_recreate_exception): Update.
9544 (ada_get_next_arg): Remove.
9545 (catch_ada_exception_command_split): Use std::string. Change type
9546 of "excep_string", "cond_string".
9547 (catch_ada_exception_command): Update.
9548 (create_ada_exception_catchpoint): Change type of excep_string.
9549 (ada_exception_sal): Remove excep_string parameter.
9550 (~ada_catchpoint): Remove.
9551
9552 2018-05-21 Tom Tromey <tom@tromey.com>
9553
9554 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
9555 cleanup.
9556
9557 2018-05-21 Tom Tromey <tom@tromey.com>
9558
9559 * ada-lang.c (ada_exception_message_1, ada_exception_message):
9560 Return unique_xmalloc_ptr.
9561 (print_it_exception): Update.
9562
9563 2018-05-21 Tom Tromey <tom@tromey.com>
9564
9565 * tracepoint.c (trace_dump_actions): Use std::string.
9566
9567 2018-05-21 Tom Tromey <tom@tromey.com>
9568
9569 * symfile.c (reread_symbols): Use std::string for original_name.
9570
9571 2018-05-21 Tom Tromey <tom@tromey.com>
9572
9573 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
9574 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
9575 constructor.
9576
9577 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
9578
9579 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
9580 instance to...
9581 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
9582 * objfiles.c (get_objfile_bfd_data): Allocate
9583 objfile_per_bfd_storage with obstack_new when allocating on
9584 obstack.
9585
9586 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
9587
9588 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
9589 OBSTACK_ZALLOC.
9590 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
9591 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
9592 * mdebugread.c (mdebug_build_psymtabs): Likewise.
9593 (add_pending): Likewise.
9594 (parse_symbol): Likewise.
9595 (parse_partial_symbols): Likewise.
9596 (psymtab_to_symtab_1): Likewise.
9597 (new_psymtab): Likewise.
9598 (elfmdebug_build_psymtabs): Likewise.
9599 * minsyms.c (terminate_minimal_symbol_table): Likewise.
9600 * objfiles.c (get_objfile_bfd_data): Likewise.
9601 (objfile_register_static_link): Likewise.
9602 * psymtab.c (allocate_psymtab): Likewise.
9603 * stabsread.c (read_member_functions): Likewise.
9604 * xcoffread.c (xcoff_end_psymtab): Likewise.
9605
9606 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
9607
9608 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
9609 compiler supports std::is_trivially_constructible.
9610 * common/poison.h: Include obstack.h.
9611 (IsMallocable): Define to is_trivially_constructible if the
9612 compiler supports it, define to true_type otherwise.
9613 (xobnew): New.
9614 (XOBNEW): Redefine.
9615 (xobnewvec): New.
9616 (XOBNEWVEC): Redefine.
9617 * gdb_obstack.h (obstack_zalloc): New.
9618 (OBSTACK_ZALLOC): Redefine.
9619 (obstack_calloc): New.
9620 (OBSTACK_CALLOC): Redefine.
9621 (obstack_new): New.
9622 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
9623 (gdbarch_obstack): New declaration in gdbarch.h, definition in
9624 gdbarch.c.
9625 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
9626 obstack_calloc/obstack_zalloc.
9627 (gdbarch_obstack_zalloc): Remove.
9628 * target-descriptions.c (tdesc_data_init): Use obstack_new.
9629
9630 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9631
9632 * stack.c (backtrace_command_1): Remove useless variable int i.
9633
9634 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9635
9636 * stack.c (print_frame_info): Fix comment.
9637
9638 2018-05-18 Tom Tromey <tom@tromey.com>
9639
9640 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
9641 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
9642 (~dwarf2_per_objfile): Update
9643 (dwarf2_get_dwz_file): Use new.
9644 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
9645 unique_ptr.
9646
9647 2018-05-18 Tom Tromey <tom@tromey.com>
9648
9649 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
9650 unique_ptr.
9651 * dwarf2read.c (struct dwp_file): Add constructor and
9652 initializers.
9653 (open_and_init_dwp_file): Return a unique_ptr.
9654 (dwarf2_per_objfile, create_dwp_hash_table)
9655 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
9656 (lookup_dwo_unit_in_dwp): Update.
9657 (open_and_init_dwp_file, get_dwp_file): Update.
9658
9659 2018-05-18 Tom Tromey <tom@tromey.com>
9660
9661 * dwarf2read.c (dwarf2_per_objfile): Update.
9662 (struct mapped_index): Add initializers.
9663 (dwarf2_read_index): Use new.
9664 (dw2_symtab_iter_init): Update.
9665 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
9666 unique_ptr.
9667
9668 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
9669
9670 * dwarf2read.c (mapped_index) <total_size>: Remove.
9671
9672 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
9673
9674 * unittests/format_pieces-selftests.c (test_format_specifier):
9675 Add ARI comments.
9676
9677 2018-05-18 Tom Tromey <tom@tromey.com>
9678
9679 * c-typeprint.c (maybe_print_hole): New function.
9680 (c_print_type_struct_field_offset): Update.
9681 (c_type_print_base_struct_union): Call maybe_print_hole.
9682
9683 2018-05-17 Keith Seitz <keiths@redhat.com>
9684
9685 * breakpoint.c (build_bpstat_chain): New function, moved from
9686 bpstat_stop_status.
9687 (bpstat_stop_status): Add optional parameter, `stop_chain'.
9688 If no stop chain is passed, call build_bpstat_chain to build it.
9689 * breakpoint.h (build_bpstat_chain): Declare.
9690 (bpstat_stop_status): Move documentation here from breakpoint.c.
9691 * infrun.c (handle_signal_stop): Before eliding inlined frames,
9692 build the stop chain and pass it to skip_inline_frames.
9693 Pass this stop chain to bpstat_stop_status.
9694 * inline-frame.c: Include breakpoint.h.
9695 (stopped_by_user_bp_inline_frame): New function.
9696 (skip_inline_frames): Add parameter `stop_chain'.
9697 Move documention to inline-frame.h.
9698 If non-NULL, use stopped_by_user_bp_inline_frame to determine
9699 whether the frame should be elided.
9700 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
9701 Add moved documentation and update for new parameter.
9702
9703 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
9704
9705 PR cli/14975
9706 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9707 unittests/format_pieces-selftests.c.
9708 * common/format.h (format_piece) <operator==>: New.
9709 (format_pieces) <operator[]>: Remove.
9710 * common/format.c (format_pieces::format_pieces): Handle \e.
9711 * unittests/format_pieces-selftests.c: New.
9712
9713 2018-05-17 Tom Tromey <tom@tromey.com>
9714
9715 PR symtab/23010:
9716 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
9717 (dw2_instantiate_symtab): Add skip_partial parameter.
9718 (dw2_find_last_source_symtab, dw2_map_expand_apply)
9719 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
9720 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
9721 (dw2_expand_symtabs_matching_one)
9722 (dw2_find_pc_sect_compunit_symtab)
9723 (dw2_debug_names_lookup_symbol)
9724 (dw2_debug_names_expand_symtabs_for_function): Update.
9725 (init_cutu_and_read_dies): Add skip_partial parameter.
9726 (process_psymtab_comp_unit, build_type_psymtabs_1)
9727 (process_skeletonless_type_unit, load_partial_comp_unit)
9728 (psymtab_to_symtab_1): Update.
9729 (load_full_comp_unit): Add skip_partial parameter.
9730 (process_imported_unit_die, dwarf2_read_addr_index)
9731 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
9732 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
9733 (read_signatured_type): Update.
9734
9735 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
9736
9737 * value.c (release_value): Remove unused variable.
9738 (record_latest_value): Likewise.
9739 (access_value_history): Likewise.
9740 (preserve_values): Likewise.
9741
9742 2018-05-17 Tom Tromey <tom@tromey.com>
9743
9744 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
9745 Initialize.
9746
9747 2018-05-16 Maciej W. Rozycki <macro@mips.com>
9748
9749 PR gdb/22286
9750 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
9751 Also handle registers whose width is not a multiple of
9752 PTRACE_TYPE_RET.
9753 (linux_nat_trad_target::store_register): Likewise.
9754
9755 2018-05-16 Tom Tromey <tom@tromey.com>
9756
9757 * gdbcore.h (core_bfd): Redefine.
9758 * corelow.c (core_target::close): Update.
9759 (core_target_open): Update.
9760 * progspace.h (struct program_space) <cbfd>: Now a
9761 gdb_bfd_ref_ptr.
9762
9763 2018-05-16 Tom Tromey <tom@tromey.com>
9764
9765 PR cli/19551:
9766 * symfile-add-flags.h (enum symfile_add_flags)
9767 <SYMFILE_NOT_FILENAME>: New constant.
9768 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
9769 objfile name from BFD.
9770 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
9771 * minidebug.c (find_separate_debug_file_in_section): Put
9772 ".gnu_debugdata" into BFD's file name.
9773
9774 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
9775
9776 * regcache.c (regcache_read_ftype, regcache_write_ftype):
9777 Remove.
9778
9779 2018-05-15 Tamar Christina <tamar.christina@arm.com>
9780
9781 PR binutils/21446
9782 * aarch64-tdep.c (aarch64_analyze_prologue,
9783 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
9784 Indicate not interested in errors.
9785
9786 2018-05-15 Maciej W. Rozycki <macro@mips.com>
9787
9788 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
9789 Supply the MIPS_ZERO_REGNUM register.
9790
9791 2018-05-15 Maciej W. Rozycki <macro@mips.com>
9792
9793 * mips-tdep.c (mask_address_var): Make variable static.
9794
9795 2018-05-14 Tom Tromey <tom@tromey.com>
9796
9797 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
9798
9799 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
9800
9801 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
9802 FXSAVE_ADDR for the mxcsr register.
9803
9804 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
9805
9806 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
9807
9808 2018-05-11 Pedro Alves <palves@redhat.com>
9809
9810 * corelow.c (core_target) <core_target>: No longer inline.
9811 Initialize m_core_gdbarch, m_core_vec and build the section table
9812 here.
9813 <~core_target>: New.
9814 <core_gdbarch, get_core_register_section>: New methods.
9815 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
9816 factored out from ...
9817 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
9818 (core_ops): Delete.
9819 (sniff_core_bfd): Add gdbarch parameter.
9820 (core_close): Delete, merged into ...
9821 (core_target::close): ... here. Delete self.
9822 (core_close_cleanup): Delete.
9823 (core_target_open): Allocate a core_target on the heap. Use a
9824 unique_ptr instead of a cleanup. Bits moved into the core_target
9825 ctor. Adjust to use core_target methods instead of globals.
9826 (get_core_register_section): Rename to ...
9827 (core_target::get_core_register_section): ... this and adjust.
9828 (struct get_core_registers_cb_data): New.
9829 (get_core_registers_cb): Use it. Use bool.
9830 (core_target::fetch_registers, core_target::files_info)
9831 (core_target::xfer_partial, core_target::read_description)
9832 (core_target::pid_to, core_target::thread_name): Adjust to
9833 reference class fields instead of globals.
9834 * target.h (struct target_ops_deleter, target_ops_up): New.
9835
9836 2018-05-11 Pedro Alves <palves@redhat.com>
9837
9838 * corefile.c (core_file_command): Move to corelow.c.
9839 * corelow.c (the_core_target): Delete.
9840 (core_file_command): Moved from corefile.c. Check exec_bfd
9841 instead of the_core_target. Use target_detach instead of calling
9842 into the_core_target directly.
9843 (maybe_say_no_core_file_now): New.
9844 (core_target::detach): Use it.
9845 (_initialize_corelow): Remove references to the_core_target.
9846 * gdbcore.h (the_core_target): Delete.
9847
9848 2018-05-11 Tom Tromey <tromey@redhat.com>
9849 Pedro Alves <palves@redhat.com>
9850
9851 * corefile.c (core_bfd): Remove.
9852 * gdbcore.h (core_bfd): Now a macro.
9853 * progspace.h (struct program_space) <cbfd>: New field.
9854
9855 2018-05-11 Tom Tromey <tom@tromey.com>
9856
9857 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
9858 gdb::def_vector.
9859
9860 2018-05-10 Tom Tromey <tom@tromey.com>
9861
9862 * configure: Rebuild.
9863 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
9864
9865 2018-05-10 Joel Brobecker <brobecker@adacore.com>
9866
9867 PR server/23158:
9868 * regformats/regdat.sh: Adjust script, following the addition
9869 of the new expedite_regs parameter to init_target_desc.
9870
9871 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
9872
9873 PR gdb/23127
9874 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
9875 set_gdbarch_significant_addr_bit.
9876 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
9877 set_gdbarch_significant_addr_bit.
9878 * utils.c (address_significant): Update to sign extend addr.
9879
9880 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
9881
9882 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
9883 (xtensa_linux_init_abi): Limit tdep->num_regs by
9884 tdep->num_nopriv_regs.
9885 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
9886 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
9887 not initialized.
9888
9889 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
9890
9891 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
9892
9893 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
9894
9895 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
9896 (I387_MXCSR_INIT_VAL): New constant.
9897 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
9898 buffer if it was supplied by the inferior.
9899 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
9900 (i387_xsave_get_clear_bv): New function.
9901 (i387_supply_xsave): Only read x87 control registers from the
9902 xsave buffer if the feature is enabled, and the state will have
9903 been written, otherwise, provide a suitable default.
9904 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
9905 including x87 control registers. Update control registers if they
9906 have changed from the default value, and mark features as enabled
9907 as required.
9908 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
9909
9910 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
9911
9912 * spu-tdep.c (info_spu_event_command): Fix output formatting.
9913
9914 2018-05-07 Tom Tromey <tom@tromey.com>
9915
9916 * configure: Rebuild.
9917 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
9918
9919 2018-05-07 Tom Tromey <tom@tromey.com>
9920
9921 PR tdep/20362:
9922 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
9923 bit. Use correct value for VDIV.
9924
9925 2018-05-04 Tom Tromey <tom@tromey.com>
9926
9927 * configure: Rebuild.
9928 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
9929
9930 2018-05-04 Tom Tromey <tom@tromey.com>
9931
9932 * linux-record.c (record_linux_system_call) <case
9933 RECORD_SYS_RECVFROM>: Add "break".
9934
9935 2018-05-04 Tom Tromey <tom@tromey.com>
9936
9937 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
9938 Add missing "break".
9939 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
9940 Add missing "break".
9941
9942 2018-05-04 Tom Tromey <tom@tromey.com>
9943
9944 * rs6000-tdep.c (ppc_process_record_op4)
9945 (ppc_process_record_op63): Add fall-through comment.
9946
9947 2018-05-04 Tom Tromey <tom@tromey.com>
9948
9949 * i386-tdep.c (i386_process_record): Add fall-through comment.
9950
9951 2018-05-04 Tom Tromey <tom@tromey.com>
9952
9953 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
9954 comment.
9955
9956 2018-05-04 Tom Tromey <tom@tromey.com>
9957
9958 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
9959 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
9960 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
9961 comment.
9962 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
9963 comment.
9964 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
9965 comment.
9966
9967 2018-05-04 Tom Tromey <tom@tromey.com>
9968
9969 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
9970
9971 2018-05-04 Tom Tromey <tom@tromey.com>
9972
9973 * s390-tdep.c (s390_process_record): Fix fall-through comments.
9974 * xcoffread.c (scan_xcoff_symtab): Move comment later.
9975 * symfile.c (section_is_mapped): Fix fall-through comment.
9976 * stabsread.c (define_symbol, read_member_functions): Fix
9977 fall-through comment.
9978 * s390-linux-tdep.c (s390_process_record): Fix fall-through
9979 comment.
9980 * remote.c (remote_wait_as): Fix fall-through comment.
9981 * p-exp.y (yylex): Fix fall-through comment.
9982 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
9983 comment.
9984 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
9985 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
9986 * jv-exp.y (yylex): Fix fall-through comment.
9987 * go-exp.y (lex_one_token): Fix fall-through comment.
9988 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
9989 fall-through comment.
9990 * f-exp.y (yylex): Fix fall-through comment.
9991 * dwarf2read.c (process_die): Fix fall-through comments.
9992 * dbxread.c (process_one_symbol): Fix fall-through comment.
9993 * d-exp.y (lex_one_token): Fix fall-through comment.
9994 * cp-name-parser.y (yylex): Fix fall-through comment.
9995 * coffread.c (coff_symtab_read): Fix fall-through comment.
9996 * c-exp.y (lex_one_token): Fix fall-through comment.
9997 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
9998 comment.
9999 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
10000 comment.
10001
10002 2018-05-04 Tom Tromey <tom@tromey.com>
10003
10004 PR python/22730:
10005 * NEWS: Mention gdb.execute change.
10006 * gdbcmd.h (execute_control_command): Don't declare.
10007 * python/python.c (execute_gdb_command): Use read_command_lines_1,
10008 execute_control_commands, execute_control_commands_to_string.
10009 * cli/cli-script.h (execute_control_commands)
10010 (execute_control_commands_to_string): Declare.
10011 (execute_control_command): Add from_tty parameter.
10012 * cli/cli-script.c (execute_control_commands)
10013 (execute_control_commands_to_string): New functions.
10014 (execute_user_command): Use execute_control_commands.
10015 (execute_control_command_1): Add "from_tty" parameter. Update.
10016 (execute_control_command): Likewise.
10017
10018 2018-05-04 Tom Tromey <tom@tromey.com>
10019
10020 PR python/22731:
10021 * NEWS: Mention that breakpoint commands are writable.
10022 * python/py-breakpoint.c (bppy_set_commands): New function.
10023 (breakpoint_object_getset) <"commands">: Use it.
10024
10025 2018-05-04 Tom Tromey <tom@tromey.com>
10026
10027 * tracepoint.c (actions_command): Update.
10028 * mi/mi-cmd-break.c (mi_command_line_array)
10029 (mi_command_line_array_cnt, mi_command_line_array_ptr)
10030 (mi_read_next_line): Remove.
10031 (mi_cmd_break_commands): Update.
10032 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
10033 function_view.
10034 * cli/cli-script.c (get_command_line): Update.
10035 (process_next_line): Use function_view. Constify.
10036 (recurse_read_control_structure, read_command_lines)
10037 (read_command_lines_1): Change argument types to function_view.
10038 (do_define_command, document_command): Update.
10039 * breakpoint.h (check_tracepoint_command): Don't declare.
10040 * breakpoint.c (check_tracepoint_command): Remove.
10041 (commands_command_1, create_tracepoint_from_upload): Update.
10042
10043 2018-05-04 Tom Tromey <tom@tromey.com>
10044
10045 PR gdb/11750:
10046 * cli/cli-script.h (enum command_control_type) <define_control>:
10047 New constant.
10048 * cli/cli-script.c (multi_line_command_p): Handle define_control.
10049 (build_command_line, execute_control_command_1)
10050 (process_next_line): Likewise.
10051 (do_define_command): New function, extracted from define_command.
10052 (define_command): Use it.
10053
10054 2018-05-04 Tom Tromey <tom@tromey.com>
10055
10056 * tracepoint.c (actions_command): Update.
10057 * cli/cli-script.h (read_command_lines): Update.
10058 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
10059 (MAX_TMPBUF): Remove define.
10060 (define_command): Use string_printf.
10061 (document_command): Likewise.
10062 * breakpoint.c (commands_command_1): Update.
10063
10064 2018-05-04 Tom Tromey <tom@tromey.com>
10065
10066 * top.c (execute_command): Update.
10067 * cli/cli-script.h (print_command_lines): Now varargs.
10068 * cli/cli-script.c (print_command_lines): Now varargs.
10069 (execute_control_command_1) <case while_control, case if_control>:
10070 Update.
10071
10072 2018-05-04 Tom Tromey <tom@tromey.com>
10073
10074 * tracepoint.c (all_tracepoint_actions): Rename from
10075 all_tracepoint_actions_and_cleanup. Change return type.
10076 (actions_command, encode_actions_1, encode_actions)
10077 (trace_dump_actions, tdump_command): Update.
10078 * remote.c (remote_download_command_source): Update.
10079 * python/python.c (gdbpy_eval_from_control_command)
10080 (python_command, python_interactive_command): Update.
10081 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
10082 * guile/guile.c (guile_command)
10083 (gdbscm_eval_from_control_command, guile_command): Update.
10084 * compile/compile.c (compile_code_command)
10085 (compile_print_command, compile_to_object): Update.
10086 * cli/cli-script.h (struct command_lines_deleter): New.
10087 (counted_command_line): New typedef.
10088 (struct command_line): Add constructor, destructor.
10089 <body_list>: Remove.
10090 <body_list_0, body_list_1>: New members.
10091 (command_line_up): Remove typedef.
10092 (read_command_lines, read_command_lines_1, get_command_line):
10093 Update.
10094 (copy_command_lines): Don't declare.
10095 * cli/cli-script.c (build_command_line): Use "new".
10096 (get_command_line): Return counted_command_line.
10097 (print_command_lines, execute_user_command)
10098 (execute_control_command_1, while_command, if_command): Update.
10099 (realloc_body_list): Remove.
10100 (process_next_line, recurse_read_control_structure): Update.
10101 (read_command_lines, read_command_lines_1): Return counted_command_line.
10102 (free_command_lines): Use "delete".
10103 (copy_command_lines): Remove.
10104 (define_command, document_command, show_user_1): Update.
10105 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
10106 a counted_command_line.
10107 * breakpoint.h (counted_command_line): Remove typedef.
10108 (breakpoint_set_commands): Update.
10109 * breakpoint.c (check_no_tracepoint_commands)
10110 (validate_commands_for_breakpoint): Update.
10111 (breakpoint_set_commands): Change commands to be a
10112 counted_command_line.
10113 (commands_command_1, update_dprintf_command_list)
10114 (create_tracepoint_from_upload): Update.
10115
10116 2018-05-04 Tom Tromey <tom@tromey.com>
10117
10118 * cli/cli-decode.h (cmd_list_element): New constructor.
10119 (~cmd_list_element): New destructor.
10120 (struct cmd_list_element): Add initializers.
10121 * cli/cli-decode.c (do_add_cmd): Use "new".
10122 (delete_cmd): Use "delete".
10123
10124 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
10125 Pedro Alves <palves@redhat.com>
10126
10127 PR breakpoints/19806 and support for PR external/20207.
10128 * NEWS: Mention Aarch64 watchpoint improvements.
10129 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
10130 watchpoints and PR external/20207 watchpoints.
10131 * nat/aarch64-linux-hw-point.c
10132 (kernel_supports_any_contiguous_range): New.
10133 (aarch64_watchpoint_offset): New.
10134 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
10135 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
10136 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
10137 (aarch64_align_watchpoint): New parameters aligned_offset_p and
10138 next_addr_orig_p. Support PR external/20207 watchpoints.
10139 (aarch64_downgrade_regs): New.
10140 (aarch64_dr_state_insert_one_point): New parameters offset and
10141 addr_orig.
10142 (aarch64_dr_state_remove_one_point): Likewise.
10143 (aarch64_handle_breakpoint): Update caller.
10144 (aarch64_handle_aligned_watchpoint): Likewise.
10145 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
10146 aligned_offset.
10147 (aarch64_linux_set_debug_regs): Remove const from state. Call
10148 aarch64_downgrade_regs.
10149 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
10150 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
10151 (DR_CONTROL_MASK): ... this.
10152 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
10153 (unsigned int aarch64_watchpoint_offset): New prototype.
10154 (aarch64_linux_set_debug_regs): Remove const from state.
10155 * utils.c (align_up, align_down): Move to ...
10156 * common/common-utils.c (align_up, align_down): ... here.
10157 * utils.h (align_up, align_down): Move to ...
10158 * common/common-utils.h (align_up, align_down): ... here.
10159
10160 2018-05-04 Joel Brobecker <brobecker@adacore.com>
10161
10162 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
10163 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
10164 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
10165 Re-implement to match the ABI as summarized in GCC's
10166 gcc/config/sparc/sparc.c. All callers updated.
10167 (sparc32_store_arguments): Remove assertion.
10168
10169 2018-05-04 Tom Tromey <tom@tromey.com>
10170
10171 * printcmd.c: Don't include tui.h.
10172 (decode_format): Use skip_spaces.
10173
10174 2018-05-04 Tom Tromey <tom@tromey.com>
10175
10176 PR gdb/22619:
10177 * printcmd.c (last_count): New global.
10178 (x_command): Use saved count when repeating.
10179
10180 2018-05-04 Tom Tromey <tom@tromey.com>
10181
10182 * nto-procfs.c (do_closedir_cleanup): Remove.
10183 (procfs_pidlist): Use gdb_dir_up.
10184 * procfs.c (do_closedir_cleanup): Remove.
10185 (proc_update_threads): Use gdb_dir_up.
10186 * common/filestuff.h (struct gdb_dir_deleter): New.
10187 (gdb_dir_up): New typedef.
10188
10189 2018-05-04 Tom Tromey <tom@tromey.com>
10190
10191 * ada-lang.c (print_mention_exception): Use std::string.
10192
10193 2018-05-04 Tom Tromey <tom@tromey.com>
10194
10195 * ada-lang.c (create_excep_cond_exprs): Update.
10196 (ada_exception_catchpoint_cond_string): Use std::string.
10197
10198 2018-05-04 Tom Tromey <tom@tromey.com>
10199
10200 * ada-lang.c (xget_renaming_scope): Return std::string.
10201 (old_renaming_is_invisible): Update.
10202
10203 2018-05-04 Tom Tromey <tom@tromey.com>
10204
10205 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
10206 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
10207
10208 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
10209
10210 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
10211
10212 2018-05-04 Tom Tromey <tom@tromey.com>
10213
10214 * remote.c (remote_query_supported_append): Change type.
10215 (remote_check_symbols): Update.
10216
10217 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
10218
10219 PR gdb/11420
10220 * configure.ac: Prepend libpython.
10221 * python/python-config.py: Likewise.
10222 * configure: Regenerate.
10223
10224 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
10225
10226 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
10227
10228 2018-05-03 Pedro Alves <palves@redhat.com>
10229
10230 * s390-linux-nat.c
10231 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
10232 override. Write 'true' instead of '1'.
10233 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
10234 declaration.
10235
10236 2018-05-02 Pedro Alves <palves@redhat.com>
10237
10238 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
10239 add_inf_child_target.
10240 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
10241 add_inf_child_target.
10242 * aix-thread.c (aix_thread_target_info): New.
10243 (aix_thread_target) <shortname, longname, doc>: Delete.
10244 <info>: New.
10245 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
10246 add_inf_child_target.
10247 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
10248 add_inf_child_target.
10249 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
10250 add_inf_child_target.
10251 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
10252 add_inf_child_target.
10253 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
10254 add_inf_child_target.
10255 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
10256 add_inf_child_target.
10257 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
10258 add_inf_child_target.
10259 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
10260 add_inf_child_target.
10261 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
10262 add_inf_child_target.
10263 * bfd-target.c (target_bfd_target_info): New.
10264 (target_bfd) <shortname, longname, doc>: Delete.
10265 <info>: New.
10266 * bsd-kvm.c (bsd_kvm_target_info): New.
10267 (bsd_kvm_target) <shortname, longname, doc>: Delete.
10268 <info>: New.
10269 (bsd_kvm_target::open): Rename to ...
10270 (bsd_kvm_target_open): ... this. Adjust.
10271 * bsd-uthread.c (bsd_uthread_target_info): New.
10272 (bsd_uthread_target) <shortname, longname, doc>: Delete.
10273 <info>: New.
10274 * corefile.c (core_file_command): Adjust.
10275 * corelow.c (core_target_info): New.
10276 (core_target) <shortname, longname, doc>: Delete.
10277 <info>: New.
10278 (core_target::open): Rename to ...
10279 (core_target_open): ... this. Adjust.
10280 * ctf.c (ctf_target_info): New.
10281 (ctf_target) <shortname, longname, doc>: Delete.
10282 <info>: New.
10283 (ctf_target::open): Rename to ...
10284 (ctf_target_open): ... this.
10285 (_initialize_ctf): Adjust.
10286 * exec.c (exec_target_info): New.
10287 (exec_target) <shortname, longname, doc>: Delete.
10288 <info>: New.
10289 (exec_target::open): Rename to ...
10290 (exec_target_open): ... this.
10291 * gdbcore.h (core_target_open): Declare.
10292 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
10293 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
10294 add_inf_child_target.
10295 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
10296 add_inf_child_target.
10297 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
10298 add_inf_child_target.
10299 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
10300 add_inf_child_target.
10301 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
10302 add_inf_child_target.
10303 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
10304 add_inf_child_target.
10305 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
10306 add_inf_child_target.
10307 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
10308 add_inf_child_target.
10309 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
10310 add_inf_child_target.
10311 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
10312 add_inf_child_target.
10313 * inf-child.c (inf_child_target_info): New.
10314 (inf_child_target::info): New.
10315 (inf_child_open_target): Remove 'target' parameter. Use
10316 get_native_target instead.
10317 (inf_child_target::open): Delete.
10318 (add_inf_child_target): New.
10319 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
10320 Delete.
10321 <info>: New.
10322 (add_inf_child_target): Declare.
10323 (inf_child_open_target): Declare.
10324 * linux-thread-db.c (thread_db_target_info): New.
10325 (thread_db_target) <shortname, longname, doc>: Delete.
10326 <info>: New.
10327 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
10328 add_inf_child_target.
10329 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
10330 add_inf_child_target.
10331 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
10332 add_inf_child_target.
10333 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
10334 add_inf_child_target.
10335 * make-target-delegates (print_class): Adjust.
10336 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
10337 add_inf_child_target.
10338 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
10339 add_inf_child_target.
10340 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
10341 add_inf_child_target.
10342 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
10343 add_inf_child_target.
10344 * nto-procfs.c (nto_native_target_info): New.
10345 (nto_procfs_target_native) <shortname, longname, doc>:
10346 Delete.
10347 <info>: New.
10348 (nto_procfs_target_info): New.
10349 (nto_procfs_target_procfs) <shortname, longname, doc>:
10350 Delete.
10351 <info>: New.
10352 (init_procfs_targets): Adjust.
10353 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
10354 add_inf_child_target.
10355 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
10356 add_inf_child_target.
10357 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
10358 add_inf_child_target.
10359 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
10360 add_inf_child_target.
10361 * ravenscar-thread.c (ravenscar_target_info): New.
10362 (ravenscar_thread_target) <shortname, longname, doc>:
10363 Delete.
10364 <info>: New.
10365 * record-btrace.c (record_btrace_target_info):
10366 (record_btrace_target) <shortname, longname, doc>: Delete.
10367 <info>: New.
10368 (record_btrace_target::open): Rename to ...
10369 (record_btrace_target_open): ... this. Adjust.
10370 * record-full.c (record_longname, record_doc): New.
10371 (record_full_base_target) <shortname, longname, doc>: Delete.
10372 <info>: New.
10373 (record_full_target_info): New.
10374 (record_full_target): <shortname>: Delete.
10375 <info>: New.
10376 (record_full_core_open_1, record_full_open_1): Update comments.
10377 (record_full_base_target::open): Rename to ...
10378 (record_full_open): ... this.
10379 (cmd_record_full_restore): Update.
10380 (_initialize_record_full): Update.
10381 * remote-sim.c (remote_sim_target_info): New.
10382 (gdbsim_target) <shortname, longname, doc>: Delete.
10383 <info>: New.
10384 (gdbsim_target::open): Rename to ...
10385 (gdbsim_target_open): ... this.
10386 (_initialize_remote_sim): Adjust.
10387 * remote.c (remote_doc): New.
10388 (remote_target_info): New.
10389 (remote_target) <shortname, longname, doc>: Delete.
10390 <info>: New.
10391 (extended_remote_target_info): New.
10392 (extended_remote_target) <shortname, longname, doc>: Delete.
10393 <info>: New.
10394 (remote_target::open_1): Make static. Adjust.
10395 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
10396 * s390-linux-nat.c (_initialize_s390_nat): Use
10397 add_inf_child_target.
10398 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
10399 add_inf_child_target.
10400 * sol-thread.c (thread_db_target_info): New.
10401 (sol_thread_target) <shortname, longname, doc>: Delete.
10402 <info>: New.
10403 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
10404 add_inf_child_target.
10405 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
10406 add_inf_child_target.
10407 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
10408 add_inf_child_target.
10409 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
10410 add_inf_child_target.
10411 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
10412 add_inf_child_target.
10413 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
10414 add_inf_child_target.
10415 * spu-linux-nat.c (_initialize_spu_nat): Use
10416 add_inf_child_target.
10417 * spu-multiarch.c (spu_multiarch_target_info): New.
10418 (spu_multiarch_target) <shortname, longname, doc>: Delete.
10419 <info>: New.
10420 * target-delegates.c: Regenerate.
10421 * target.c: Include <unordered_map>.
10422 (target_ops_p): Delete.
10423 (DEF_VEC_P(target_ops_p)): Delete.
10424 (target_factories): New.
10425 (test_target_info): New.
10426 (test_target_ops::info): New.
10427 (open_target): Adjust to use target_factories.
10428 (add_target_with_completer): Rename to ...
10429 (add_target): ... this. Change prototype. Register target_info
10430 and open callback in target_factories. Register target_info in
10431 command context instead of target_ops.
10432 (add_target): Delete old implementation.
10433 (add_deprecated_target_alias): Change prototype. Adjust.
10434 (the_native_target): New.
10435 (set_native_target, get_native_target): New.
10436 (find_default_run_target): Use the_native_target.
10437 (find_attach_target, find_run_target): Simplify.
10438 (target_ops::open): Delete.
10439 (dummy_target_info): New.
10440 (dummy_target::shortname, dummy_target::longname)
10441 (dummy_target::doc): Delete.
10442 (dummy_target::info): New.
10443 (debug_target::shortname, debug_target::longname)
10444 (debug_target::doc): Delete.
10445 (debug_target::info): New.
10446 * target.h (struct target_info): New.
10447 (target_ops::~target_ops): Add comment.
10448 (target_ops::info): New.
10449 (target_ops::shortname, target_ops::longname, target_ops::doc): No
10450 longer virtual. Implement in terms of target_info.
10451 (set_native_target, get_native_target): Declare.
10452 (target_open_ftype): New.
10453 (add_target, add_target_with_completer)
10454 (add_deprecated_target_alias): Change prototype.
10455 (test_target) <shortname, longname, doc>: Delete.
10456 <info>: New.
10457 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
10458 add_inf_child_target.
10459 * tracefile-tfile.c (tfile_target_info): New.
10460 (tfile_target) <shortname, longname, doc>: Delete.
10461 <info>: New.
10462 (tfile_target::open): Rename to ...
10463 (tfile_target_open): ... this.
10464 (_initialize_tracefile_tfile): Adjust.
10465 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
10466 add_inf_child_target.
10467 * windows-nat.c (_initialize_windows_nat): Use
10468 add_inf_child_target.
10469 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
10470 add_inf_child_target.
10471
10472 2018-05-02 Pedro Alves <palves@redhat.com>
10473
10474 * linux-nat.h (linux_nat_target) <low_new_thread,
10475 low_delete_thread, low_new_fork, low_forget_process,
10476 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
10477 New virtual methods.
10478 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
10479 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
10480 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
10481 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
10482 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
10483 Delete.
10484 * linux-fork.c (delete_fork): Adjust to call low method.
10485 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
10486 (linux_nat_new_fork, linux_nat_forget_process_hook)
10487 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
10488 (linux_nat_status_is_event):
10489 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
10490 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
10491 to call low method.
10492 (sigtrap_is_event): Rename to ...
10493 (linux_nat_target::low_status_is_event): ... this.
10494 (linux_nat_set_status_is_event): Delete.
10495 (save_stop_reason, linux_nat_wait_1)
10496 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
10497 low methods.
10498 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
10499 (linux_nat_set_new_fork, linux_nat_set_forget_process)
10500 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
10501 (linux_nat_set_prepare_to_resume): Delete.
10502 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
10503 low virtual methods.
10504 * amd64-linux-nat.c: Likewise.
10505 * arm-linux-nat.c: Likewise.
10506 * i386-linux-nat.c: Likewise.
10507 * ia64-linux-nat.c: Likewise.
10508 * mips-linux-nat.c: Likewise.
10509 * ppc-linux-nat.c: Likewise.
10510 * s390-linux-nat.c: Likewise.
10511 * sparc64-linux-nat.c: Likewise.
10512 * x86-linux-nat.c: Likewise.
10513 * x86-linux-nat.h: Include "nat/x86-linux.h".
10514 (x86_linux_nat_target) <low_new_fork, low_forget_process,
10515 low_prepare_to_resume, low_new_thread, low_delete_thread>:
10516 Override methods.
10517
10518 2018-05-02 Pedro Alves <palves@redhat.com>
10519
10520 * target.h (target_ops)
10521 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
10522 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
10523 stopped_by_watchpoint, have_continuable_watchpoint,
10524 stopped_data_address, watchpoint_addr_within_range,
10525 can_accel_watchpoint_condition, can_run, thread_alive,
10526 has_all_memory, has_memory, has_stack, has_registers,
10527 has_execution, can_async_p, is_async_p, supports_non_stop,
10528 always_non_stop_p, can_execute_reverse, supports_multi_process,
10529 supports_enable_disable_tracepoint,
10530 supports_disable_randomization, supports_string_tracing,
10531 supports_evaluation_of_breakpoint_conditions,
10532 can_run_breakpoint_commands, filesystem_is_local,
10533 can_download_tracepoint, get_trace_state_variable_value,
10534 set_trace_notes, get_tib_address, use_agent, can_use_agent,
10535 record_is_replaying, record_will_replay,
10536 augmented_libraries_svr4_read>: Adjust to return bool.
10537 * aarch64-linux-nat.c: All implementations adjusted.
10538 * aix-thread.c: All implementations adjusted.
10539 * arm-linux-nat.c: All implementations adjusted.
10540 * breakpoint.c: All implementations adjusted.
10541 * bsd-kvm.c: All implementations adjusted.
10542 * bsd-uthread.c: All implementations adjusted.
10543 * corelow.c: All implementations adjusted.
10544 * ctf.c: All implementations adjusted.
10545 * darwin-nat.c: All implementations adjusted.
10546 * darwin-nat.h: All implementations adjusted.
10547 * exec.c: All implementations adjusted.
10548 * fbsd-nat.c: All implementations adjusted.
10549 * fbsd-nat.h: All implementations adjusted.
10550 * gnu-nat.c: All implementations adjusted.
10551 * gnu-nat.h: All implementations adjusted.
10552 * go32-nat.c: All implementations adjusted.
10553 * ia64-linux-nat.c: All implementations adjusted.
10554 * inf-child.c: All implementations adjusted.
10555 * inf-child.h: All implementations adjusted.
10556 * inf-ptrace.c: All implementations adjusted.
10557 * inf-ptrace.h: All implementations adjusted.
10558 * linux-nat.c: All implementations adjusted.
10559 * linux-nat.h: All implementations adjusted.
10560 * mips-linux-nat.c: All implementations adjusted.
10561 * nto-procfs.c: All implementations adjusted.
10562 * ppc-linux-nat.c: All implementations adjusted.
10563 * procfs.c: All implementations adjusted.
10564 * ravenscar-thread.c: All implementations adjusted.
10565 * record-btrace.c: All implementations adjusted.
10566 * record-full.c: All implementations adjusted.
10567 * remote-sim.c: All implementations adjusted.
10568 * remote.c: All implementations adjusted.
10569 * s390-linux-nat.c: All implementations adjusted.
10570 * sol-thread.c: All implementations adjusted.
10571 * spu-multiarch.c: All implementations adjusted.
10572 * target-delegates.c: All implementations adjusted.
10573 * target.c: All implementations adjusted.
10574 * target.h: All implementations adjusted.
10575 * tracefile-tfile.c: All implementations adjusted.
10576 * tracefile.c: All implementations adjusted.
10577 * tracefile.h: All implementations adjusted.
10578 * windows-nat.c: All implementations adjusted.
10579 * x86-linux-nat.h: All implementations adjusted.
10580 * x86-nat.h: All implementations adjusted.
10581
10582 2018-05-02 Pedro Alves <palves@redhat.com>
10583
10584 * make-target-delegates (scan_target_h): Don't trim lines here.
10585 Replace sequences of tabs and/or whitespace with a single
10586 whitespace.
10587 (top level, parsing methods): Trim each line before processing it
10588 here.
10589
10590 2018-05-02 Pedro Alves <palves@redhat.com>
10591 John Baldwin <jhb@freebsd.org>
10592
10593 * target.h (enum strata) <debug_stratum>: New.
10594 (struct target_ops) <all delegation methods>: Replace by C++
10595 virtual methods, and drop "to_" prefix. All references updated
10596 throughout.
10597 <to_shortname, to_longname, to_doc, to_data,
10598 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
10599 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
10600 virtual methods. All references updated throughout.
10601 <can_attach, supports_terminal_ours, can_create_inferior,
10602 get_thread_control_capabilities, attach_no_wait>: New
10603 virtual methods.
10604 <insert_breakpoint, remove_breakpoint>: Now
10605 TARGET_DEFAULT_NORETURN methods.
10606 <info_proc>: Now returns bool.
10607 <to_magic>: Delete.
10608 (OPS_MAGIC): Delete.
10609 (current_target): Delete. All references replaced by references
10610 to ...
10611 (target_stack): ... this. New.
10612 (target_shortname, target_longname): Adjust.
10613 (target_can_run): Now a function declaration.
10614 (default_child_has_all_memory, default_child_has_memory)
10615 (default_child_has_stack, default_child_has_registers)
10616 (default_child_has_execution): Remove target_ops parameter.
10617 (complete_target_initialization): Delete.
10618 (memory_breakpoint_target): New template class.
10619 (test_target_ops): Refactor as a C++ class with virtual methods.
10620 * make-target-delegates (NAME_PART): Tighten.
10621 (POINTER_PART, CP_SYMBOL): New.
10622 (SIMPLE_RETURN_PART): Reimplement.
10623 (VEC_RETURN_PART): Expect less.
10624 (RETURN_PART, VIRTUAL_PART): New.
10625 (METHOD): Adjust to C++ virtual methods.
10626 (scan_target_h): Remove reference to C99.
10627 (dname): Output "target_ops::" prefix.
10628 (write_function_header): Adjust to output a C++ class method.
10629 (write_declaration): New.
10630 (write_delegator): Adjust to output a C++ class method.
10631 (tdname): Output "dummy_target::" prefix.
10632 (write_tdefault, write_debugmethod): Adjust to output a C++ class
10633 method.
10634 (tdefault_names, debug_names): Delete.
10635 (return_types, tdefaults, styles, argtypes_array): New.
10636 (top level): All methods are delegators.
10637 (print_class): New.
10638 (top level): Print dummy_target and debug_target classes.
10639 * target-delegates.c: Regenerate.
10640 * target-debug.h (target_debug_print_enum_info_proc_what)
10641 (target_debug_print_thread_control_capabilities)
10642 (target_debug_print_thread_info_p): New.
10643 * target.c (dummy_target): Delete.
10644 (the_dummy_target, the_debug_target): New.
10645 (target_stack): Now extern.
10646 (set_targetdebug): Push/unpush debug target.
10647 (default_child_has_all_memory, default_child_has_memory)
10648 (default_child_has_stack, default_child_has_registers)
10649 (default_child_has_execution): Remove target_ops parameter.
10650 (complete_target_initialization): Delete.
10651 (add_target_with_completer): No longer call
10652 complete_target_initialization.
10653 (target_supports_terminal_ours): Use regular delegation.
10654 (update_current_target): Delete.
10655 (push_target): No longer check magic number. Don't call
10656 update_current_target.
10657 (unpush_target): Don't call update_current_target.
10658 (target_is_pushed): No longer check magic number.
10659 (target_require_runnable): Skip for all stratums over
10660 process_stratum.
10661 (target_ops::info_proc): New.
10662 (target_info_proc): Use find_target_at and
10663 find_default_run_target.
10664 (target_supports_disable_randomization): Use regular delegation.
10665 (target_get_osdata): Use find_target_at.
10666 (target_ops::open, target_ops::close, target_ops::can_attach)
10667 (target_ops::attach, target_ops::can_create_inferior)
10668 (target_ops::create_inferior, target_ops::can_run)
10669 (target_can_run): New.
10670 (default_fileio_target): Use regular delegation.
10671 (target_ops::fileio_open, target_ops::fileio_pwrite)
10672 (target_ops::fileio_pread, target_ops::fileio_fstat)
10673 (target_ops::fileio_close, target_ops::fileio_unlink)
10674 (target_ops::fileio_readlink): New.
10675 (target_fileio_open_1, target_fileio_unlink)
10676 (target_fileio_readlink): Always call the target method. Handle
10677 FILEIO_ENOSYS.
10678 (return_zero, return_zero_has_execution): Delete.
10679 (init_dummy_target): Delete.
10680 (dummy_target::dummy_target, dummy_target::shortname)
10681 (dummy_target::longname, dummy_target::doc)
10682 (debug_target::debug_target, debug_target::shortname)
10683 (debug_target::longname, debug_target::doc): New.
10684 (target_supports_delete_record): Use regular delegation.
10685 (setup_target_debug): Delete.
10686 (maintenance_print_target_stack): Skip debug_stratum.
10687 (initialize_targets): Instantiate the_dummy_target and
10688 the_debug_target.
10689 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
10690 use target_stack.
10691 (target_auxv_search, fprint_target_auxv): Adjust.
10692 (info_auxv_command): Adjust to use target_stack.
10693 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
10694 * exceptions.c (print_flush): Handle a NULL target_stack.
10695 * regcache.c (target_ops_no_register): Refactor as class with
10696 virtual methods.
10697
10698 * exec.c (exec_target): New class.
10699 (exec_ops): Now an exec_target.
10700 (exec_open, exec_close_1, exec_get_section_table)
10701 (exec_xfer_partial, exec_files_info, exec_has_memory)
10702 (exec_make_note_section): Refactor as exec_target methods.
10703 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
10704 Delete.
10705 (exec_target::find_memory_regions): New.
10706 (_initialize_exec): Don't call init_exec_ops.
10707 * gdbcore.h (exec_file_clear): Delete.
10708
10709 * corefile.c (core_target): Delete.
10710 (core_file_command): Adjust.
10711 * corelow.c (core_target): New class.
10712 (the_core_target): New.
10713 (core_close): Remove target_ops parameter.
10714 (core_close_cleanup): Adjust.
10715 (core_target::close): New.
10716 (core_open, core_detach, get_core_registers, core_files_info)
10717 (core_xfer_partial, core_thread_alive, core_read_description)
10718 (core_pid_to_str, core_thread_name, core_has_memory)
10719 (core_has_stack, core_has_registers, core_info_proc): Rework as
10720 core_target methods.
10721 (ignore, core_remove_breakpoint, init_core_ops): Delete.
10722 (_initialize_corelow): Initialize the_core_target.
10723 * gdbcore.h (core_target): Delete.
10724 (the_core_target): New.
10725
10726 * ctf.c: (ctf_target): New class.
10727 (ctf_ops): Now a ctf_target.
10728 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
10729 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
10730 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
10731 methods.
10732 (init_ctf_ops): Delete.
10733 (_initialize_ctf): Don't call it.
10734 * tracefile-tfile.c (tfile_target): New class.
10735 (tfile_ops): Now a tfile_target.
10736 (tfile_open, tfile_close, tfile_files_info)
10737 (tfile_get_tracepoint_status, tfile_trace_find)
10738 (tfile_fetch_registers, tfile_xfer_partial)
10739 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
10740 Refactor as tfile_target methods.
10741 (tfile_xfer_partial_features): Remove target_ops parameter.
10742 (init_tfile_ops): Delete.
10743 (_initialize_tracefile_tfile): Don't call it.
10744 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
10745 (tracefile_has_stack, tracefile_has_registers)
10746 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
10747 tracefile_target methods.
10748 (init_tracefile_ops): Delete.
10749 (tracefile_target::tracefile_target): New.
10750 * tracefile.h: Include "target.h".
10751 (tracefile_target): New class.
10752 (init_tracefile_ops): Delete.
10753
10754 * spu-multiarch.c (spu_multiarch_target): New class.
10755 (spu_ops): Now a spu_multiarch_target.
10756 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
10757 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
10758 (spu_search_memory, spu_mourn_inferior): Refactor as
10759 spu_multiarch_target methods.
10760 (init_spu_ops): Delete.
10761 (_initialize_spu_multiarch): Remove references to init_spu_ops,
10762 complete_target_initialization.
10763
10764 * ravenscar-thread.c (ravenscar_thread_target): New class.
10765 (ravenscar_ops): Now a ravenscar_thread_target.
10766 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
10767 (ravenscar_thread_alive, ravenscar_pid_to_str)
10768 (ravenscar_fetch_registers, ravenscar_store_registers)
10769 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
10770 (ravenscar_stopped_by_hw_breakpoint)
10771 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
10772 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
10773 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
10774 methods.
10775 (init_ravenscar_thread_ops): Delete.
10776 (_initialize_ravenscar): Remove references to
10777 init_ravenscar_thread_ops and complete_target_initialization.
10778
10779 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
10780 (bsd_uthread_target): New class.
10781 (bsd_uthread_ops): Now a bsd_uthread_target.
10782 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
10783 (bsd_uthread_close, bsd_uthread_mourn_inferior)
10784 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
10785 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
10786 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
10787 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
10788 (bsd_uthread_target): Delete function.
10789 (_initialize_bsd_uthread): Remove reference to
10790 complete_target_initialization.
10791
10792 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
10793 (target_bfd): ... this new class.
10794 (target_bfd_xfer_partial, target_bfd_get_section_table)
10795 (target_bfd_close): Refactor as target_bfd methods.
10796 (target_bfd::~target_bfd): New.
10797 (target_bfd_reopen): Adjust.
10798 (target_bfd::close): New.
10799
10800 * record-btrace.c (record_btrace_target): New class.
10801 (record_btrace_ops): Now a record_btrace_target.
10802 (record_btrace_open, record_btrace_stop_recording)
10803 (record_btrace_disconnect, record_btrace_close)
10804 (record_btrace_async, record_btrace_info)
10805 (record_btrace_insn_history, record_btrace_insn_history_range)
10806 (record_btrace_insn_history_from, record_btrace_call_history)
10807 (record_btrace_call_history_range)
10808 (record_btrace_call_history_from, record_btrace_record_method)
10809 (record_btrace_is_replaying, record_btrace_will_replay)
10810 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
10811 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
10812 (record_btrace_store_registers, record_btrace_prepare_to_store)
10813 (record_btrace_to_get_unwinder)
10814 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
10815 (record_btrace_commit_resume, record_btrace_wait)
10816 (record_btrace_stop, record_btrace_can_execute_reverse)
10817 (record_btrace_stopped_by_sw_breakpoint)
10818 (record_btrace_supports_stopped_by_sw_breakpoint)
10819 (record_btrace_stopped_by_hw_breakpoint)
10820 (record_btrace_supports_stopped_by_hw_breakpoint)
10821 (record_btrace_update_thread_list, record_btrace_thread_alive)
10822 (record_btrace_goto_begin, record_btrace_goto_end)
10823 (record_btrace_goto, record_btrace_stop_replaying_all)
10824 (record_btrace_execution_direction)
10825 (record_btrace_prepare_to_generate_core)
10826 (record_btrace_done_generating_core): Refactor as
10827 record_btrace_target methods.
10828 (init_record_btrace_ops): Delete.
10829 (_initialize_record_btrace): Remove reference to
10830 init_record_btrace_ops.
10831 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
10832 the execution_direction global.
10833 (record_full_base_target, record_full_target)
10834 (record_full_core_target): New classes.
10835 (record_full_ops): Now a record_full_target.
10836 (record_full_core_ops): Now a record_full_core_target.
10837 (record_full_target::detach, record_full_target::disconnect)
10838 (record_full_core_target::disconnect)
10839 (record_full_target::mourn_inferior, record_full_target::kill):
10840 New.
10841 (record_full_open, record_full_close, record_full_async): Refactor
10842 as methods of the record_full_base_target class.
10843 (record_full_resume, record_full_commit_resume): Refactor
10844 as methods of the record_full_target class.
10845 (record_full_wait, record_full_stopped_by_watchpoint)
10846 (record_full_stopped_data_address)
10847 (record_full_stopped_by_sw_breakpoint)
10848 (record_full_supports_stopped_by_sw_breakpoint)
10849 (record_full_stopped_by_hw_breakpoint)
10850 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
10851 methods of the record_full_base_target class.
10852 (record_full_store_registers, record_full_xfer_partial)
10853 (record_full_insert_breakpoint, record_full_remove_breakpoint):
10854 Refactor as methods of the record_full_target class.
10855 (record_full_can_execute_reverse, record_full_get_bookmark)
10856 (record_full_goto_bookmark, record_full_execution_direction)
10857 (record_full_record_method, record_full_info, record_full_delete)
10858 (record_full_is_replaying, record_full_will_replay)
10859 (record_full_goto_begin, record_full_goto_end, record_full_goto)
10860 (record_full_stop_replaying): Refactor as methods of the
10861 record_full_base_target class.
10862 (record_full_core_resume, record_full_core_kill)
10863 (record_full_core_fetch_registers)
10864 (record_full_core_prepare_to_store)
10865 (record_full_core_store_registers, record_full_core_xfer_partial)
10866 (record_full_core_insert_breakpoint)
10867 (record_full_core_remove_breakpoint)
10868 (record_full_core_has_execution): Refactor
10869 as methods of the record_full_core_target class.
10870 (record_full_base_target::supports_delete_record): New.
10871 (init_record_full_ops): Delete.
10872 (init_record_full_core_ops): Delete.
10873 (record_full_save): Refactor as method of the
10874 record_full_base_target class.
10875 (_initialize_record_full): Remove references to
10876 init_record_full_ops and init_record_full_core_ops.
10877
10878 * remote.c (remote_target, extended_remote_target): New classes.
10879 (remote_ops): Now a remote_target.
10880 (extended_remote_ops): Now an extended_remote_target.
10881 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
10882 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
10883 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
10884 (remote_pass_signals, remote_set_syscall_catchpoint)
10885 (remote_program_signals, )
10886 (remote_thread_always_alive): Remove target_ops parameter.
10887 (remote_thread_alive, remote_thread_name)
10888 (remote_update_thread_list, remote_threads_extra_info)
10889 (remote_static_tracepoint_marker_at)
10890 (remote_static_tracepoint_markers_by_strid)
10891 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
10892 (remote_open): Refactor as methods of remote_target.
10893 (extended_remote_open, extended_remote_detach)
10894 (extended_remote_attach, extended_remote_post_attach):
10895 (extended_remote_supports_disable_randomization)
10896 (extended_remote_create_inferior): : Refactor as method of
10897 extended_remote_target.
10898 (remote_set_permissions, remote_open_1, remote_detach)
10899 (remote_follow_fork, remote_follow_exec, remote_disconnect)
10900 (remote_resume, remote_commit_resume, remote_stop)
10901 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
10902 (remote_terminal_ours, remote_wait, remote_fetch_registers)
10903 (remote_prepare_to_store, remote_store_registers)
10904 (remote_flash_erase, remote_flash_done, remote_files_info)
10905 (remote_kill, remote_mourn, remote_insert_breakpoint)
10906 (remote_remove_breakpoint, remote_insert_watchpoint)
10907 (remote_watchpoint_addr_within_range)
10908 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
10909 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
10910 (remote_supports_stopped_by_sw_breakpoint)
10911 (remote_stopped_by_hw_breakpoint)
10912 (remote_supports_stopped_by_hw_breakpoint)
10913 (remote_stopped_by_watchpoint, remote_stopped_data_address)
10914 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
10915 (remote_verify_memory): Refactor as methods of remote_target.
10916 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
10917 parameter.
10918 (remote_xfer_partial, remote_get_memory_xfer_limit)
10919 (remote_search_memory, remote_rcmd, remote_memory_map)
10920 (remote_pid_to_str, remote_get_thread_local_address)
10921 (remote_get_tib_address, remote_read_description): Refactor as
10922 methods of remote_target.
10923 (remote_target::fileio_open, remote_target::fileio_pwrite)
10924 (remote_target::fileio_pread, remote_target::fileio_close): New.
10925 (remote_hostio_readlink, remote_hostio_fstat)
10926 (remote_filesystem_is_local, remote_can_execute_reverse)
10927 (remote_supports_non_stop, remote_supports_disable_randomization)
10928 (remote_supports_multi_process, remote_supports_cond_breakpoints)
10929 (remote_supports_enable_disable_tracepoint)
10930 (remote_supports_string_tracing)
10931 (remote_can_run_breakpoint_commands, remote_trace_init)
10932 (remote_download_tracepoint, remote_can_download_tracepoint)
10933 (remote_download_trace_state_variable, remote_enable_tracepoint)
10934 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
10935 (remote_trace_start, remote_get_trace_status)
10936 (remote_get_tracepoint_status, remote_trace_stop)
10937 (remote_trace_find, remote_get_trace_state_variable_value)
10938 (remote_save_trace_data, remote_get_raw_trace_data)
10939 (remote_set_disconnected_tracing, remote_core_of_thread)
10940 (remote_set_circular_trace_buffer, remote_traceframe_info)
10941 (remote_get_min_fast_tracepoint_insn_len)
10942 (remote_set_trace_buffer_size, remote_set_trace_notes)
10943 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
10944 (remote_disable_btrace, remote_teardown_btrace)
10945 (remote_read_btrace, remote_btrace_conf)
10946 (remote_augmented_libraries_svr4_read, remote_load)
10947 (remote_pid_to_exec_file, remote_can_do_single_step)
10948 (remote_execution_direction, remote_thread_handle_to_thread_info):
10949 Refactor as methods of remote_target.
10950 (init_remote_ops, init_extended_remote_ops): Delete.
10951 (remote_can_async_p, remote_is_async_p, remote_async)
10952 (remote_thread_events, remote_upload_tracepoints)
10953 (remote_upload_trace_state_variables): Refactor as methods of
10954 remote_target.
10955 (_initialize_remote): Remove references to init_remote_ops and
10956 init_extended_remote_ops.
10957
10958 * remote-sim.c (gdbsim_target): New class.
10959 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
10960 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
10961 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
10962 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
10963 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
10964 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
10965 Refactor as methods of gdbsim_target.
10966 (gdbsim_ops): Now a gdbsim_target.
10967 (init_gdbsim_ops): Delete.
10968 (gdbsim_cntrl_c): Adjust.
10969 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
10970
10971 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
10972 (the_amd64_linux_nat_target): New.
10973 (amd64_linux_fetch_inferior_registers)
10974 (amd64_linux_store_inferior_registers): Refactor as methods of
10975 amd64_linux_nat_target.
10976 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
10977 * i386-linux-nat.c: Don't include "linux-nat.h".
10978 (i386_linux_nat_target): New class.
10979 (the_i386_linux_nat_target): New.
10980 (i386_linux_fetch_inferior_registers)
10981 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
10982 as methods of i386_linux_nat_target.
10983 (_initialize_i386_linux_nat): Adjust. Set linux_target.
10984 * inf-child.c (inf_child_ops): Delete.
10985 (inf_child_fetch_inferior_registers)
10986 (inf_child_store_inferior_registers): Delete.
10987 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
10988 methods of inf_child_target.
10989 (inf_child_target::supports_terminal_ours)
10990 (inf_child_target::terminal_init)
10991 (inf_child_target::terminal_inferior)
10992 (inf_child_target::terminal_ours_for_output)
10993 (inf_child_target::terminal_ours, inf_child_target::interrupt)
10994 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
10995 New.
10996 (inf_child_open, inf_child_disconnect, inf_child_close)
10997 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
10998 (inf_child_post_startup_inferior, inf_child_can_run)
10999 (inf_child_pid_to_exec_file): Refactor as methods of
11000 inf_child_target.
11001 (inf_child_follow_fork): Delete.
11002 (inf_child_target::can_create_inferior)
11003 (inf_child_target::can_attach): New.
11004 (inf_child_target::has_all_memory, inf_child_target::has_memory)
11005 (inf_child_target::has_stack, inf_child_target::has_registers)
11006 (inf_child_target::has_execution): New.
11007 (inf_child_fileio_open, inf_child_fileio_pwrite)
11008 (inf_child_fileio_pread, inf_child_fileio_fstat)
11009 (inf_child_fileio_close, inf_child_fileio_unlink)
11010 (inf_child_fileio_readlink, inf_child_use_agent)
11011 (inf_child_can_use_agent): Refactor as methods of
11012 inf_child_target.
11013 (return_zero, inf_child_target): Delete.
11014 (inf_child_target::inf_child_target): New.
11015 * inf-child.h: Include "target.h".
11016 (inf_child_target): Delete function prototype.
11017 (inf_child_target): New class.
11018 (inf_child_open_target, inf_child_mourn_inferior)
11019 (inf_child_maybe_unpush_target): Delete.
11020 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
11021 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
11022 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
11023 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
11024 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
11025 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
11026 (inf_ptrace_wait, inf_ptrace_xfer_partial)
11027 (inf_ptrace_thread_alive, inf_ptrace_files_info)
11028 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
11029 methods of inf_ptrace_target.
11030 (inf_ptrace_target): Delete function.
11031 * inf-ptrace.h: Include "inf-child.h".
11032 (inf_ptrace_target): Delete function declaration.
11033 (inf_ptrace_target): New class.
11034 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
11035 * linux-nat.c (linux_target): New.
11036 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
11037 (linux_nat_target::~linux_nat_target): New.
11038 (linux_child_post_attach, linux_child_post_startup_inferior)
11039 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
11040 (linux_child_remove_fork_catchpoint)
11041 (linux_child_insert_vfork_catchpoint)
11042 (linux_child_remove_vfork_catchpoint)
11043 (linux_child_insert_exec_catchpoint)
11044 (linux_child_remove_exec_catchpoint)
11045 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
11046 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
11047 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
11048 (linux_nat_stopped_data_address)
11049 (linux_nat_stopped_by_sw_breakpoint)
11050 (linux_nat_supports_stopped_by_sw_breakpoint)
11051 (linux_nat_stopped_by_hw_breakpoint)
11052 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
11053 (linux_nat_kill, linux_nat_mourn_inferior)
11054 (linux_nat_xfer_partial, linux_nat_thread_alive)
11055 (linux_nat_update_thread_list, linux_nat_pid_to_str)
11056 (linux_nat_thread_name, linux_child_pid_to_exec_file)
11057 (linux_child_static_tracepoint_markers_by_strid)
11058 (linux_nat_is_async_p, linux_nat_can_async_p)
11059 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
11060 (linux_nat_supports_multi_process)
11061 (linux_nat_supports_disable_randomization, linux_nat_async)
11062 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
11063 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
11064 (linux_nat_fileio_open, linux_nat_fileio_readlink)
11065 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
11066 methods of linux_nat_target.
11067 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
11068 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
11069 parameter.
11070 (check_stopped_by_watchpoint): Adjust.
11071 (linux_xfer_partial): Delete.
11072 (linux_target_install_ops, linux_target, linux_nat_add_target):
11073 Delete.
11074 (linux_nat_target::linux_nat_target): New.
11075 * linux-nat.h: Include "inf-ptrace.h".
11076 (linux_nat_target): New.
11077 (linux_target, linux_target_install_ops, linux_nat_add_target):
11078 Delete function declarations.
11079 (linux_target): Declare global.
11080 * linux-thread-db.c (thread_db_target): New.
11081 (thread_db_target::thread_db_target): New.
11082 (thread_db_ops): Delete.
11083 (the_thread_db_target): New.
11084 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
11085 (thread_db_update_thread_list, thread_db_pid_to_str)
11086 (thread_db_extra_thread_info)
11087 (thread_db_thread_handle_to_thread_info)
11088 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
11089 (thread_db_resume): Refactor as methods of thread_db_target.
11090 (init_thread_db_ops): Delete.
11091 (_initialize_thread_db): Remove reference to init_thread_db_ops.
11092 * x86-linux-nat.c: Don't include "linux-nat.h".
11093 (super_post_startup_inferior): Delete.
11094 (x86_linux_nat_target::~x86_linux_nat_target): New.
11095 (x86_linux_child_post_startup_inferior)
11096 (x86_linux_read_description, x86_linux_enable_btrace)
11097 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
11098 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
11099 methods of x86_linux_nat_target.
11100 (x86_linux_create_target): Delete. Bits folded ...
11101 (x86_linux_add_target): ... here. Now takes a linux_nat_target
11102 pointer.
11103 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
11104 (x86_linux_nat_target): New class.
11105 (x86_linux_create_target): Delete.
11106 (x86_linux_add_target): Now takes a linux_nat_target pointer.
11107 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
11108 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
11109 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
11110 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
11111 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
11112 make extern.
11113 (x86_use_watchpoints): Delete.
11114 * x86-nat.h: Include "breakpoint.h" and "target.h".
11115 (x86_use_watchpoints): Delete.
11116 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
11117 (x86_stopped_by_watchpoint, x86_stopped_data_address)
11118 (x86_insert_watchpoint, x86_remove_watchpoint)
11119 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
11120 (x86_stopped_by_hw_breakpoint): New declarations.
11121 (x86_nat_target): New template class.
11122
11123 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
11124 (the_ppc_linux_nat_target): New.
11125 (ppc_linux_fetch_inferior_registers)
11126 (ppc_linux_can_use_hw_breakpoint)
11127 (ppc_linux_region_ok_for_hw_watchpoint)
11128 (ppc_linux_ranged_break_num_registers)
11129 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
11130 (ppc_linux_insert_mask_watchpoint)
11131 (ppc_linux_remove_mask_watchpoint)
11132 (ppc_linux_can_accel_watchpoint_condition)
11133 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
11134 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
11135 (ppc_linux_watchpoint_addr_within_range)
11136 (ppc_linux_masked_watch_num_registers)
11137 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
11138 (ppc_linux_read_description): Refactor as methods of
11139 ppc_linux_nat_target.
11140 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
11141
11142 * procfs.c (procfs_xfer_partial): Delete forward declaration.
11143 (procfs_target): New class.
11144 (the_procfs_target): New.
11145 (procfs_target): Delete function.
11146 (procfs_auxv_parse, procfs_attach, procfs_detach)
11147 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
11148 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
11149 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
11150 (procfs_create_inferior, procfs_update_thread_list)
11151 (procfs_thread_alive, procfs_pid_to_str)
11152 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
11153 (procfs_stopped_data_address, procfs_insert_watchpoint)
11154 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
11155 (proc_find_memory_regions, procfs_info_proc)
11156 (procfs_make_note_section): Refactor as methods of procfs_target.
11157 (_initialize_procfs): Adjust.
11158 * sol-thread.c (sol_thread_target): New class.
11159 (sol_thread_ops): Now a sol_thread_target.
11160 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
11161 (sol_thread_fetch_registers, sol_thread_store_registers)
11162 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
11163 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
11164 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
11165 (init_sol_thread_ops): Delete.
11166 (_initialize_sol_thread): Adjust. Remove references to
11167 init_sol_thread_ops and complete_target_initialization.
11168
11169 * windows-nat.c (windows_nat_target): New class.
11170 (windows_fetch_inferior_registers)
11171 (windows_store_inferior_registers, windows_resume, windows_wait)
11172 (windows_attach, windows_detach, windows_pid_to_exec_file)
11173 (windows_files_info, windows_create_inferior)
11174 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
11175 (windows_close, windows_pid_to_str, windows_xfer_partial)
11176 (windows_get_tib_address, windows_get_ada_task_ptid)
11177 (windows_thread_name, windows_thread_alive): Refactor as
11178 windows_nat_target methods.
11179 (do_initial_windows_stuff): Adjust.
11180 (windows_target): Delete function.
11181 (_initialize_windows_nat): Adjust.
11182
11183 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
11184 (darwin_mourn_inferior, darwin_kill_inferior)
11185 (darwin_create_inferior, darwin_attach, darwin_detach)
11186 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
11187 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
11188 (darwin_supports_multi_process): Refactor as darwin_nat_target
11189 methods.
11190 (darwin_resume_to, darwin_files_info): Delete.
11191 (_initialize_darwin_inferior): Rename to ...
11192 (_initialize_darwin_nat): ... this. Adjust to C++ification.
11193 * darwin-nat.h: Include "inf-child.h".
11194 (darwin_nat_target): New class.
11195 (darwin_complete_target): Delete.
11196 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
11197 (darwin_target): New.
11198 (i386_darwin_fetch_inferior_registers)
11199 (i386_darwin_store_inferior_registers): Refactor as methods of
11200 darwin_nat_target.
11201 (darwin_complete_target): Delete, with ...
11202 (_initialize_i386_darwin_nat): ... bits factored out here.
11203
11204 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
11205 (the_alpha_linux_nat_target): New.
11206 (alpha_linux_register_u_offset): Refactor as
11207 alpha_linux_nat_target method.
11208 (_initialize_alpha_linux_nat): Adjust.
11209 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
11210 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
11211 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
11212 methods of linux_nat_trad_target.
11213 (linux_trad_target): Delete.
11214 * linux-nat-trad.h (linux_trad_target): Delete function.
11215 (linux_nat_trad_target): New class.
11216 * mips-linux-nat.c (mips_linux_nat_target): New class.
11217 (super_fetch_registers, super_store_registers, super_close):
11218 Delete.
11219 (the_mips_linux_nat_target): New.
11220 (mips64_linux_regsets_fetch_registers)
11221 (mips64_linux_regsets_store_registers)
11222 (mips64_linux_fetch_registers, mips64_linux_store_registers)
11223 (mips_linux_register_u_offset, mips_linux_read_description)
11224 (mips_linux_can_use_hw_breakpoint)
11225 (mips_linux_stopped_by_watchpoint)
11226 (mips_linux_stopped_data_address)
11227 (mips_linux_region_ok_for_hw_watchpoint)
11228 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
11229 (mips_linux_close): Refactor as methods of mips_linux_nat.
11230 (_initialize_mips_linux_nat): Adjust to C++ification.
11231
11232 * aix-thread.c (aix_thread_target): New class.
11233 (aix_thread_ops): Now an aix_thread_target.
11234 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
11235 (aix_thread_fetch_registers, aix_thread_store_registers)
11236 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
11237 (aix_thread_thread_alive, aix_thread_pid_to_str)
11238 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
11239 Refactor as methods of aix_thread_target.
11240 (init_aix_thread_ops): Delete.
11241 (_initialize_aix_thread): Remove references to init_aix_thread_ops
11242 and complete_target_initialization.
11243 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
11244 (rs6000_nat_target): New class.
11245 (the_rs6000_nat_target): New.
11246 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
11247 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
11248 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
11249 (super_create_inferior): Delete.
11250 (_initialize_rs6000_nat): Adjust to C++ification.
11251
11252 * arm-linux-nat.c (arm_linux_nat_target): New class.
11253 (the_arm_linux_nat_target): New.
11254 (arm_linux_fetch_inferior_registers)
11255 (arm_linux_store_inferior_registers, arm_linux_read_description)
11256 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
11257 (arm_linux_remove_hw_breakpoint)
11258 (arm_linux_region_ok_for_hw_watchpoint)
11259 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
11260 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
11261 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
11262 arm_linux_nat_target.
11263 (_initialize_arm_linux_nat): Adjust to C++ification.
11264
11265 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
11266 (the_aarch64_linux_nat_target): New.
11267 (aarch64_linux_fetch_inferior_registers)
11268 (aarch64_linux_store_inferior_registers)
11269 (aarch64_linux_child_post_startup_inferior)
11270 (aarch64_linux_read_description)
11271 (aarch64_linux_can_use_hw_breakpoint)
11272 (aarch64_linux_insert_hw_breakpoint)
11273 (aarch64_linux_remove_hw_breakpoint)
11274 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
11275 (aarch64_linux_region_ok_for_hw_watchpoint)
11276 (aarch64_linux_stopped_data_address)
11277 (aarch64_linux_stopped_by_watchpoint)
11278 (aarch64_linux_watchpoint_addr_within_range)
11279 (aarch64_linux_can_do_single_step): Refactor as methods of
11280 aarch64_linux_nat_target.
11281 (super_post_startup_inferior): Delete.
11282 (_initialize_aarch64_linux_nat): Adjust to C++ification.
11283
11284 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
11285 (the_hppa_linux_nat_target): New.
11286 (hppa_linux_fetch_inferior_registers)
11287 (hppa_linux_store_inferior_registers): Refactor as methods of
11288 hppa_linux_nat_target.
11289 (_initialize_hppa_linux_nat): Adjust to C++ification.
11290
11291 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
11292 (the_ia64_linux_nat_target): New.
11293 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
11294 (ia64_linux_stopped_data_address)
11295 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
11296 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
11297 ia64_linux_nat_target methods.
11298 (super_xfer_partial): Delete.
11299 (_initialize_ia64_linux_nat): Adjust to C++ification.
11300
11301 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
11302 (the_m32r_linux_nat_target): New.
11303 (m32r_linux_fetch_inferior_registers)
11304 (m32r_linux_store_inferior_registers): Refactor as
11305 m32r_linux_nat_target methods.
11306 (_initialize_m32r_linux_nat): Adjust to C++ification.
11307
11308 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
11309 (the_m68k_linux_nat_target): New.
11310 (m68k_linux_fetch_inferior_registers)
11311 (m68k_linux_store_inferior_registers): Refactor as
11312 m68k_linux_nat_target methods.
11313 (_initialize_m68k_linux_nat): Adjust to C++ification.
11314
11315 * s390-linux-nat.c (s390_linux_nat_target): New class.
11316 (the_s390_linux_nat_target): New.
11317 (s390_linux_fetch_inferior_registers)
11318 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
11319 (s390_insert_watchpoint, s390_remove_watchpoint)
11320 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
11321 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
11322 (s390_auxv_parse, s390_read_description): Refactor as methods of
11323 s390_linux_nat_target.
11324 (_initialize_s390_nat): Adjust to C++ification.
11325
11326 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
11327 (the_sparc_linux_nat_target): New.
11328 (_initialize_sparc_linux_nat): Adjust to C++ification.
11329 * sparc-nat.c (sparc_fetch_inferior_registers)
11330 (sparc_store_inferior_registers): Remove target_ops parameter.
11331 * sparc-nat.h (sparc_fetch_inferior_registers)
11332 (sparc_store_inferior_registers): Remove target_ops parameter.
11333 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
11334 (the_sparc64_linux_nat_target): New.
11335 (_initialize_sparc64_linux_nat): Adjust to C++ification.
11336
11337 * spu-linux-nat.c (spu_linux_nat_target): New class.
11338 (the_spu_linux_nat_target): New.
11339 (spu_child_post_startup_inferior, spu_child_post_attach)
11340 (spu_child_wait, spu_fetch_inferior_registers)
11341 (spu_store_inferior_registers, spu_xfer_partial)
11342 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
11343 methods.
11344 (_initialize_spu_nat): Adjust to C++ification.
11345
11346 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
11347 (the_tilegx_linux_nat_target): New.
11348 (fetch_inferior_registers, store_inferior_registers):
11349 Refactor as methods.
11350 (_initialize_tile_linux_nat): Adjust to C++ification.
11351
11352 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
11353 (the_xtensa_linux_nat_target): New.
11354 (xtensa_linux_fetch_inferior_registers)
11355 (xtensa_linux_store_inferior_registers): Refactor as
11356 xtensa_linux_nat_target methods.
11357 (_initialize_xtensa_linux_nat): Adjust to C++ification.
11358
11359 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
11360 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
11361 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
11362 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
11363 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
11364 (fbsd_stopped_by_sw_breakpoint)
11365 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
11366 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
11367 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
11368 (fbsd_post_startup_inferior, fbsd_post_attach)
11369 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
11370 (fbsd_set_syscall_catchpoint)
11371 (super_xfer_partial, super_resume, super_wait)
11372 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
11373 (fbsd_handle_debug_trap): Remove target_ops parameter.
11374 (fbsd_nat_add_target): Delete.
11375 * fbsd-nat.h: Include "inf-ptrace.h".
11376 (fbsd_nat_add_target): Delete.
11377 (USE_SIGTRAP_SIGINFO): Define.
11378 (fbsd_nat_target): New class.
11379
11380 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
11381 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
11382 (amd64bsd_target): Delete.
11383 * amd64-bsd-nat.h: New file.
11384 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
11385 "x86-bsd-nat.h".
11386 (amd64_fbsd_nat_target): New class.
11387 (the_amd64_fbsd_nat_target): New.
11388 (amd64fbsd_read_description): Refactor as method of
11389 amd64_fbsd_nat_target.
11390 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
11391 (_initialize_amd64fbsd_nat): Adjust to C++ification.
11392 * amd64-nat.h (amd64bsd_target): Delete function declaration.
11393 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
11394 (i386bsd_store_inferior_registers): Remove target_ops parameter.
11395 (i386bsd_target): Delete.
11396 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
11397 (i386bsd_fetch_inferior_registers)
11398 (i386bsd_store_inferior_registers): Declare.
11399 (i386_bsd_nat_target): New class.
11400 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
11401 (the_i386_fbsd_nat_target): New.
11402 (i386fbsd_resume, i386fbsd_read_description): Refactor as
11403 i386_fbsd_nat_target methods.
11404 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
11405 (_initialize_i386fbsd_nat): Adjust to C++ification.
11406 * x86-bsd-nat.c (super_mourn_inferior): Delete.
11407 (x86bsd_mourn_inferior, x86bsd_target): Delete.
11408 (_initialize_x86_bsd_nat): Adjust to C++ification.
11409 * x86-bsd-nat.h: Include "x86-nat.h".
11410 (x86bsd_target): Delete declaration.
11411 (x86bsd_nat_target): New class.
11412
11413 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
11414 (the_aarch64_fbsd_nat_target): New.
11415 (aarch64_fbsd_fetch_inferior_registers)
11416 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
11417 aarch64_fbsd_nat_target.
11418 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
11419 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
11420 (the_alpha_bsd_nat_target): New.
11421 (alphabsd_fetch_inferior_registers)
11422 (alphabsd_store_inferior_registers): Refactor as
11423 alpha_bsd_nat_target methods.
11424 (_initialize_alphabsd_nat): Refactor as methods of
11425 alpha_bsd_nat_target.
11426 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
11427 (the_amd64_nbsd_nat_target): New.
11428 (_initialize_amd64nbsd_nat): Adjust to C++ification.
11429 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
11430 (the_amd64_obsd_nat_target): New.
11431 (_initialize_amd64obsd_nat): Adjust to C++ification.
11432 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
11433 (the_arm_fbsd_nat_target): New.
11434 (arm_fbsd_fetch_inferior_registers)
11435 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
11436 (_initialize_arm_fbsd_nat): Refactor as methods of
11437 arm_fbsd_nat_target.
11438 (_initialize_arm_fbsd_nat): Adjust to C++ification.
11439 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
11440 (the_arm_netbsd_nat_target): New.
11441 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
11442 arm_netbsd_nat_target.
11443 (_initialize_arm_netbsd_nat): Adjust to C++ification.
11444 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
11445 (the_hppa_nbsd_nat_target): New.
11446 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
11447 hppa_nbsd_nat_target methods.
11448 (_initialize_hppanbsd_nat): Adjust to C++ification.
11449 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
11450 (the_hppa_obsd_nat_target): New.
11451 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
11452 methods of hppa_obsd_nat_target.
11453 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
11454 add_target.
11455 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
11456 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
11457 add_target.
11458 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
11459 (_initialize_i386obsd_nat): Use add_target.
11460 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
11461 (the_m68k_bsd_nat_target): New.
11462 (m68kbsd_fetch_inferior_registers)
11463 (m68kbsd_store_inferior_registers): Refactor as methods of
11464 m68k_bsd_nat_target.
11465 (_initialize_m68kbsd_nat): Adjust to C++ification.
11466 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
11467 (the_mips_fbsd_nat_target): New.
11468 (mips_fbsd_fetch_inferior_registers)
11469 (mips_fbsd_store_inferior_registers): Refactor as methods of
11470 mips_fbsd_nat_target.
11471 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
11472 add_target.
11473 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
11474 (the_mips_nbsd_nat_target): New.
11475 (mipsnbsd_fetch_inferior_registers)
11476 (mipsnbsd_store_inferior_registers): Refactor as methods of
11477 mips_nbsd_nat_target.
11478 (_initialize_mipsnbsd_nat): Adjust to C++ification.
11479 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
11480 (the_mips64_obsd_nat_target): New.
11481 (mips64obsd_fetch_inferior_registers)
11482 (mips64obsd_store_inferior_registers): Refactor as methods of
11483 mips64_obsd_nat_target.
11484 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
11485 add_target.
11486 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
11487 nbsd_nat_target.
11488 * nbsd-nat.h: Include "inf-ptrace.h".
11489 (nbsd_nat_target): New class.
11490 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
11491 (obsd_wait): Refactor as methods of obsd_nat_target.
11492 (obsd_add_target): Delete.
11493 * obsd-nat.h: Include "inf-ptrace.h".
11494 (obsd_nat_target): New class.
11495 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
11496 (the_ppc_fbsd_nat_target): New.
11497 (ppcfbsd_fetch_inferior_registers)
11498 (ppcfbsd_store_inferior_registers): Refactor as methods of
11499 ppc_fbsd_nat_target.
11500 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
11501 add_target.
11502 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
11503 (the_ppc_nbsd_nat_target): New.
11504 (ppcnbsd_fetch_inferior_registers)
11505 (ppcnbsd_store_inferior_registers): Refactor as methods of
11506 ppc_nbsd_nat_target.
11507 (_initialize_ppcnbsd_nat): Adjust to C++ification.
11508 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
11509 (the_ppc_obsd_nat_target): New.
11510 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
11511 methods of ppc_obsd_nat_target.
11512 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
11513 add_target.
11514 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
11515 (the_sh_nbsd_nat_target): New.
11516 (shnbsd_fetch_inferior_registers)
11517 (shnbsd_store_inferior_registers): Refactor as methods of
11518 sh_nbsd_nat_target.
11519 (_initialize_shnbsd_nat): Adjust to C++ification.
11520 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
11521 (inf_ptrace_xfer_partial): Delete.
11522 (sparc_xfer_partial, sparc_target): Delete.
11523 * sparc-nat.h (sparc_fetch_inferior_registers)
11524 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
11525 (sparc_target): Delete function declaration.
11526 (sparc_target): New template class.
11527 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
11528 (_initialize_sparcnbsd_nat): Adjust to C++ification.
11529 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
11530 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
11531 add_target.
11532 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
11533 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
11534 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
11535 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
11536 add_target.
11537 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
11538 (the_vax_bsd_nat_target): New.
11539 (vaxbsd_fetch_inferior_registers)
11540 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
11541 methods.
11542 (_initialize_vaxbsd_nat): Adjust to C++ification.
11543
11544 * bsd-kvm.c (bsd_kvm_target): New class.
11545 (bsd_kvm_ops): Now a bsd_kvm_target.
11546 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
11547 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
11548 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
11549 bsd_kvm_target.
11550 (bsd_kvm_return_one): Delete.
11551 (bsd_kvm_add_target): Adjust to C++ification.
11552
11553 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
11554 (nto_procfs_target_procfs): New classes.
11555 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
11556 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
11557 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
11558 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
11559 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
11560 (procfs_remove_hw_breakpoint, procfs_resume)
11561 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
11562 (procfs_kill_inferior, procfs_store_registers)
11563 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
11564 as methods of nto_procfs_target.
11565 (nto_procfs_ops): Now an nto_procfs_target_procfs.
11566 (nto_native_ops): Delete.
11567 (procfs_open, procfs_native_open): Delete.
11568 (nto_native_ops): Now an nto_procfs_target_native.
11569 (init_procfs_targets): Adjust to C++ification.
11570 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
11571 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
11572 Refactor as methods of nto_procfs_target.
11573
11574 * go32-nat.c (go32_nat_target): New class.
11575 (the_go32_nat_target): New.
11576 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
11577 (go32_store_registers, go32_xfer_partial, go32_files_info)
11578 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
11579 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
11580 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
11581 (go32_pid_to_str): Refactor as methods of go32_nat_target.
11582 (go32_target): Delete.
11583 (_initialize_go32_nat): Adjust to C++ification.
11584
11585 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
11586 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
11587 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
11588 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
11589 gnu_nat_target.
11590 (gnu_target): Delete.
11591 * gnu-nat.h (gnu_target): Delete.
11592 (gnu_nat_target): New class.
11593 * i386-gnu-nat.c (gnu_base_target): New.
11594 (i386_gnu_nat_target): New class.
11595 (the_i386_gnu_nat_target): New.
11596 (_initialize_i386gnu_nat): Adjust to C++ification.
11597
11598 2018-05-02 Pedro Alves <palves@redhat.com>
11599
11600 * bfd-target.c (target_bfd_xclose): Rename to ...
11601 (target_bfd_close): ... this.
11602 (target_bfd_reopen): Adjust.
11603 * target.c (target_close): Remove references to to_xclose.
11604 * target.h (target_ops::to_xclose): Delete.
11605 (target_ops::to_close): Update comments.
11606
11607 2018-05-02 Pedro Alves <palves@redhat.com>
11608
11609 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
11610 "linux-nat.h".
11611 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
11612 * inf-ptrace.c (inf_ptrace_register_u_offset)
11613 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
11614 (inf_ptrace_store_register, inf_ptrace_store_registers)
11615 (inf_ptrace_trad_target): Move to ...
11616 * linux-nat-trad.c: ... this new file.
11617 * linux-nat-trad.h: New file.
11618 * linux-nat.c (linux_target_install_ops): Make extern.
11619 (linux_trad_target): Delete.
11620 * linux-nat.h (linux_trad_target): Delete declaration.
11621 (linux_target_install_ops): Declare.
11622 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
11623 "linux-nat.h".
11624
11625 2018-05-02 Pedro Alves <palves@redhat.com>
11626
11627 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
11628 procfs_target/add_target here.
11629 * procfs.c (procfs_target): Make static.
11630 (_initialize_procfs): Call add_target here.
11631 * procfs.h (struct target_ops): Remove forward declaration.
11632 (procfs_target): Remove declaration.
11633 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
11634
11635 2018-05-02 Pedro Alves <palves@redhat.com>
11636
11637 * procfs.c (procfs_stopped_by_watchpoint)
11638 (procfs_insert_watchpoint, procfs_remove_watchpoint)
11639 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
11640 Forward declare.
11641 (procfs_use_watchpoints): Delete, move contents...
11642 (procfs_target): ... here.
11643 * procfs.h (procfs_use_watchpoints): Delete declaration.
11644 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
11645 procfs_use_watchpoints.
11646 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
11647 procfs_use_watchpoints.
11648
11649 2018-05-02 Tom Tromey <tom@tromey.com>
11650
11651 PR python/20084:
11652 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
11653 and var_zuinteger_unlimited.
11654 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
11655 and PARAM_ZUINTEGER_UNLIMITED.
11656 (set_parameter_value): Handle var_zuinteger and
11657 var_zuinteger_unlimited.
11658 (add_setshow_generic): Likewise.
11659 (parmpy_init): Likewise.
11660
11661 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
11662
11663 PR rust/23124
11664 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
11665 pointer is not null before dereferencing it.
11666
11667 2018-04-30 Tom Tromey <tom@tromey.com>
11668
11669 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
11670 is_mi_like_p.
11671
11672 2018-04-30 Tom Tromey <tom@tromey.com>
11673
11674 * breakpoint.c (mention): Remove use of is_mi_like_p.
11675 (print_mention_ranged_breakpoint): Likewise.
11676 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
11677 of is_mi_like_p.
11678
11679 2018-04-30 Tom Tromey <tom@tromey.com>
11680
11681 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
11682
11683 2018-04-30 Tom Tromey <tom@tromey.com>
11684
11685 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
11686 (info_spu_event_command): Remove some uses of is_mi_like_p.
11687
11688 2018-04-30 Tom Tromey <tom@tromey.com>
11689
11690 * python/py-framefilter.c (py_print_single_arg)
11691 (enumerate_locals, py_print_args, py_print_frame): Remove some
11692 uses of is_mi_like_p.
11693
11694 2018-04-30 Tom Tromey <tom@tromey.com>
11695
11696 * ui-out.c: Update.
11697 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
11698 * ui-out.h (ui_out::is_mi_like_p): Now const.
11699 (ui_out::do_is_mi_like_p): Now const.
11700 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
11701
11702 2018-04-30 Tom Tromey <tom@tromey.com>
11703
11704 * varobj.c (varobj_set_visualizer): Use new_reference.
11705 * python/python.c (gdbpy_decode_line): Use new_reference.
11706 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
11707 new_reference.
11708
11709 2018-04-30 Tom Tromey <tom@tromey.com>
11710
11711 * varobj.c (install_new_value): Use new_reference.
11712 * value.h (value_incref): Return void. Swap intro comment with
11713 value_decref.
11714 * value.c (set_value_parent): Use new_reference.
11715 (value_incref): Return void. Update intro comment.
11716 (release_value): Use new_reference.
11717 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
11718
11719 2018-04-30 Tom Tromey <tom@tromey.com>
11720
11721 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
11722 * gdb_bfd.h (new_bfd_ref): Remove.
11723 (gdb_bfd_open): Update comment.
11724 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
11725 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
11726 (gdb_bfd_fdopenr): Use new_reference.
11727 * exec.c (exec_file_attach): Use new_reference.
11728
11729 2018-04-30 Tom Tromey <tom@tromey.com>
11730
11731 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
11732 method.
11733
11734 2018-04-30 Tom Tromey <tom@tromey.com>
11735
11736 * jit.c (jit_read_code_entry): Use type_align.
11737 * i386-tdep.c (i386_gdbarch_init): Don't call
11738 set_gdbarch_long_long_align_bit.
11739 * gdbarch.sh: Remove long_long_align_bit.
11740 * gdbarch.c, gdbarch.h: Rebuild.
11741 * arc-tdep.c (arc_type_align): New function.
11742 (arc_gdbarch_init): Use arc_type_align. Don't call
11743 set_gdbarch_long_long_align_bit.
11744
11745 2018-04-30 Tom Tromey <tom@tromey.com>
11746
11747 * rust-lang.c (rust_type_alignment): Remove.
11748 (rust_composite_type): Use type_align.
11749
11750 2018-04-30 Tom Tromey <tom@tromey.com>
11751
11752 * NEWS: Mention Type.align.
11753 * python/py-type.c (typy_get_alignof): New function.
11754 (type_object_getset): Add "alignof".
11755
11756 2018-04-30 Tom Tromey <tom@tromey.com>
11757
11758 PR exp/17095:
11759 * NEWS: Update.
11760 * std-operator.def (UNOP_ALIGNOF): New operator.
11761 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
11762 New.
11763 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
11764 * c-lang.c (c_op_print_tab): Add alignof.
11765 * c-exp.y (ALIGNOF): New token.
11766 (exp): Add "ALIGNOF" production.
11767 (ident_tokens): Add _Alignof and alignof.
11768
11769 2018-04-30 Tom Tromey <tom@tromey.com>
11770
11771 * i386-tdep.c (i386_type_align): New function.
11772 (i386_gdbarch_init): Update.
11773 * gdbarch.sh (type_align): New method.
11774 * gdbarch.c, gdbarch.h: Rebuild.
11775 * arch-utils.h (default_type_align): Declare.
11776 * arch-utils.c (default_type_align): New function.
11777 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
11778 (struct type) <align_log2>: New field.
11779 <instance_flags>: Now a bitfield.
11780 (TYPE_RAW_ALIGN): New macro.
11781 (type_align, type_raw_align, set_type_align): Declare.
11782 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
11783 functions.
11784 * dwarf2read.c (quirk_rust_enum): Set type alignment.
11785 (get_alignment, maybe_set_alignment): New functions.
11786 (read_structure_type, read_enumeration_type, read_array_type)
11787 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
11788 (read_subrange_type, read_base_type): Set type alignment.
11789
11790 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
11791
11792 * dwarf2read.c (read_index_from_section): Use bool.
11793
11794 2018-04-29 Fabian Groffen <grobian@gentoo.org>
11795
11796 PR gdb/22950
11797 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
11798 with #ifdef.
11799
11800 2018-04-29 John Reiser <jreiser@BitWagon.com>
11801
11802 PR build/22873
11803 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
11804 last step, and do it atomically.
11805
11806 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
11807
11808 * compile/compile-c-types.c (convert_int, convert_float):
11809 Update for C FE v1.
11810
11811 2018-04-27 Tom Tromey <tom@tromey.com>
11812
11813 PR rust/22545:
11814 * rust-lang.c (rust_inclusive_range_type_p): New function.
11815 (rust_range): Handle inclusive ranges.
11816 (rust_compute_range): Likewise.
11817 * rust-exp.y (struct rust_op) <inclusive>: New field.
11818 (DOTDOTEQ): New constant.
11819 (range_expr): Add "..=" productions.
11820 (operator_tokens): Add "..=" token.
11821 (ast_range): Add "inclusive" parameter.
11822 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
11823 ranges.
11824 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
11825 bounds values.
11826 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
11827 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
11828 Update comments.
11829 * expprint.c (print_subexp_standard): Handle new bounds values.
11830 (dump_subexp_body_standard): Likewise.
11831
11832 2018-04-27 Tom Tromey <tom@tromey.com>
11833
11834 * configure: Rebuild.
11835 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
11836 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
11837 "OVERRIDE".
11838 (class symbol_needs_eval_context): Likewise.
11839 * dwarf2read.c (mock_mapped_index::symbol_name_count)
11840 (mock_mapped_index::symbol_name_at): Use "override". Remove
11841 "virtual".
11842 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
11843 "override".
11844 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
11845 * aarch64-tdep.c (instruction_reader::read): Use "override".
11846 (instruction_reader_test::read): Likewise.
11847 * arm-tdep.c (instruction_reader::read): Use "override".
11848 (instruction_reader_thumb::read): Likewise.
11849
11850 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
11851
11852 PR remote/9665
11853 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
11854 instead of remote_send.
11855 (remote_send): Remove.
11856
11857 2018-04-26 Pedro Alves <palves@redhat.com>
11858
11859 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
11860 find_function_start_sal instead of find_pc_line.
11861
11862 2018-04-26 Pedro Alves <palves@redhat.com>
11863
11864 * breakpoint.c (set_breakpoint_location_function): Handle
11865 mst_data_gnu_ifunc.
11866 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
11867 * elfread.c (elf_symtab_read): Give data symbols with
11868 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
11869 (elf_rel_plt_read): Update comment.
11870 * linespec.c (convert_linespec_to_sals): Handle
11871 mst_data_gnu_ifunc.
11872 (minsym_found): Handle mst_data_gnu_ifunc.
11873 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
11874 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
11875 * parse.c (find_minsym_type_and_address): Handle
11876 mst_data_gnu_ifunc.
11877 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
11878 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
11879 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
11880 comment.
11881 <mst_data_gnu_ifunc>: New enumerator.
11882
11883 2018-04-26 Pedro Alves <palves@redhat.com>
11884
11885 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
11886 (lookup_minimal_symbol_by_pc_section): ... this. Replace
11887 'want_trampoline' parameter by a lookup_msym_prefer parameter.
11888 Handle it.
11889 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
11890 (lookup_minimal_symbol_by_pc): Adjust.
11891 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
11892 (lookup_solib_trampoline_symbol_by_pc): Adjust.
11893 * minsyms.h (lookup_msym_prefer): New enum.
11894 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
11895 parameter by a lookup_msym_prefer parameter.
11896
11897 2018-04-26 Pedro Alves <palves@redhat.com>
11898
11899 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
11900 ends in "@plt" instead of looking at the symbol's section.
11901
11902 2018-04-26 Pedro Alves <palves@redhat.com>
11903
11904 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
11905 all references.
11906 (find_pc_partial_function_gnu_ifunc): Rename to ...
11907 (find_pc_partial_function): ... this, and remove references to
11908 'is_gnu_ifunc_p'.
11909 (find_pc_partial_function): Delete old implementation.
11910 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
11911
11912 2018-04-26 Pedro Alves <palves@redhat.com>
11913
11914 * linespec.c (struct bound_minimal_symbol_search_key): New.
11915 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
11916 skip first line if we found a GNU ifunc minimal symbol by name.
11917 (compare_msymbols): Change parameters to work with a destructured
11918 lhs minsym.
11919 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
11920 functions.
11921
11922 2018-04-26 Pedro Alves <palves@redhat.com>
11923
11924 * breakpoint.c (set_breakpoint_location_function): Don't resolve
11925 ifunc targets here. Instead, if we have an ifunc minsym, use its
11926 address/name.
11927 (add_location_to_breakpoint): Store the minsym and the objfile in
11928 the breakpoint location.
11929 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
11930 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
11931 Record the minsym in the sal.
11932 * symtab.h (symtab_and_line) <msymbol>: New field.
11933
11934 2018-04-26 Pedro Alves <palves@redhat.com>
11935
11936 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
11937 unless we actually resolved the ifunc.
11938
11939 2018-04-26 Pedro Alves <palves@redhat.com>
11940
11941 * c-exp.y (variable production): Prefer ifunc minsyms over
11942 regular function symbols.
11943 * symtab.c (find_gnu_ifunc): New function.
11944 * minsyms.h (lookup_msym_prefer): New enum.
11945 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
11946 parameter by a lookup_msym_prefer parameter.
11947 * symtab.h (find_gnu_ifunc): New declaration.
11948
11949 2018-04-26 Pedro Alves <palves@redhat.com>
11950
11951 * blockframe.c (find_gnu_ifunc_target_type): New function.
11952 (find_function_type): New.
11953 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
11954 return a value with a memory address.
11955 (eval_call): For calls to GNU ifunc functions, try to find the
11956 type of the target function from the type that the resolver
11957 returns.
11958 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
11959 symbols.
11960 * infcall.c (find_function_return_type): Delete.
11961 (find_function_addr): Add 'function_type' parameter. For calls to
11962 GNU ifunc functions, try to find the type of the target function
11963 from the type that the resolver returns, and return it via
11964 FUNCTION_TYPE.
11965 (call_function_by_hand_dummy): Adjust to use the function type
11966 returned by find_function_addr.
11967 (find_function_addr): Add 'function_type' parameter and move
11968 description here.
11969 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
11970 declarations.
11971
11972 2018-04-26 Pedro Alves <palves@redhat.com>
11973
11974 * c-exp.y (variable production): Skip finding an alias for ifunc
11975 symbols.
11976
11977 2018-04-26 Pedro Alves <palves@redhat.com>
11978
11979 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
11980
11981 2018-04-25 Pedro Alves <palves@redhat.com>
11982
11983 * infcmd.c (kill_command): Print the pid as string, not the whole
11984 thread's ptid. Add comment. s/has been killed/killed/ in output
11985 message.
11986 * remote.c (remote_detach_1): Print the pid as string, not the
11987 whole thread's ptid.
11988
11989 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
11990 Sergio Durigan Junior <sergiodj@redhat.com>
11991 Pedro Alves <palves@redhat.com>
11992
11993 * infcmd.c (kill_command): Print message when inferior has
11994 been killed.
11995 * inferior.c (print_inferior_events): Remove 'static'. Set as
11996 '1'.
11997 (add_inferior): Improve message printed when
11998 'print_inferior_events' is on.
11999 (exit_inferior): Remove message printed when
12000 'print_inferior_events' is on.
12001 (detach_inferior): Improve message printed when
12002 'print_inferior_events' is on.
12003 (initialize_inferiors): Use 'add_inferior_silent' to set
12004 'current_inferior_'.
12005 * inferior.h (print_inferior_events): Declare here as
12006 'extern'.
12007 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
12008 '[Detaching...]' messages when 'print_inferior_events' is on.
12009 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
12010 as prefix/suffix for messages. Remove periods. Fix erroneous
12011 'Detaching after fork from child...', replace it by '... from
12012 parent...'.
12013 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
12014 prefix/suffix when printing 'Detaching...' messages. Print
12015 them when 'print_inferior_events' is on.
12016 * remote.c (remote_detach_1): Print message when detaching
12017 from inferior and '!is_fork_parent'.
12018
12019 2018-04-24 Tom Tromey <tom@tromey.com>
12020
12021 * cli-out.h: Reindent.
12022
12023 2018-04-24 Tom Tromey <tom@tromey.com>
12024
12025 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
12026 (cli_ui_out::do_field_string): Use fputs_filtered.
12027 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
12028
12029 2018-04-23 Tom Tromey <tom@tromey.com>
12030
12031 * guile/scm-frame.c (gdbscm_frame_read_var): Use
12032 gdb::unique_xmalloc_ptr.
12033
12034 2018-04-23 Tom Tromey <tom@tromey.com>
12035
12036 * configure: Rebuild.
12037
12038 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
12039
12040 PR gdb/23095
12041 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
12042 prepare_for_testing. Set normal_bp to r_debug_state if target
12043 is bsd.
12044
12045 2018-04-21 Pedro Alves <palves@redhat.com>
12046 Rajendra SY <rajendra.sy@gmail.com>
12047
12048 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
12049 * remote.c (extended_remote_attach): In all-stop mode, mark the
12050 thread as executing.
12051
12052 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
12053
12054 * thread.c (thread_apply_all_command): Fix comment.
12055 (thread_command): Fix comment.
12056
12057 2018-04-10 Alan Hayward <alan.hayward@arm.com>
12058
12059 * common/tdesc.h (tdesc_create_feature): Remove xml filename
12060 parameter.
12061 * features/aarch64-core.c (create_feature_aarch64_core):
12062 Regenerate.
12063 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
12064 Likewise.
12065 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
12066 Likewise.
12067 * features/i386/32bit-avx512.c
12068 (create_feature_i386_32bit_avx512): Likewise.
12069 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
12070 Likewise.
12071 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
12072 Likewise.
12073 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
12074 Likewise.
12075 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
12076 Likewise.
12077 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
12078 Likewise.
12079 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
12080 Likewise.
12081 * features/i386/64bit-avx512.c
12082 (create_feature_i386_64bit_avx512): Likewise.
12083 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
12084 Likewise.
12085 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
12086 Likewise.
12087 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
12088 Likewise.
12089 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
12090 Likewise.
12091 * features/i386/64bit-segments.c
12092 (create_feature_i386_64bit_segments): Likewise.
12093 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
12094 Likewise.
12095 * features/i386/x32-core.c
12096 (create_feature_i386_x32_core): Likewise.
12097 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
12098 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
12099 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
12100 * target-descriptions.c: In generated code, don't pass xml
12101 filename.
12102
12103 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12104
12105 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
12106 (print_xml_feature::visit_post): Likewise.
12107 (print_xml_feature::visit): Likewise.
12108 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
12109 (print_xml_feature): Add new class.
12110 * regformats/regdat.sh: Null xmltarget on feature targets.
12111 * target-descriptions.c (struct target_desc): Add xmltarget.
12112 (maintenance_check_tdesc_xml_convert): Add unittest function.
12113 (tdesc_get_features_xml): Add function to get xml.
12114 (maintenance_check_xml_descriptions): Test xml generation.
12115 * xml-tdesc.c (string_read_description_xml): Add function.
12116 * xml-tdesc.h (string_read_description_xml): Add declaration.
12117
12118 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12119
12120 * features/Makefile: Add feature marker to targets with new style
12121 target descriptions.
12122 * regformats/aarch64.dat: Regenerate.
12123 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
12124 * regformats/i386/amd64-avx-linux.dat: Likewise.
12125 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
12126 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
12127 * regformats/i386/amd64-linux.dat: Likewise.
12128 * regformats/i386/amd64-mpx-linux.dat: Likewise.
12129 * regformats/i386/amd64.dat: Likewise.
12130 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
12131 * regformats/i386/i386-avx-linux.dat: Likewise.
12132 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
12133 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
12134 * regformats/i386/i386-linux.dat: Likewise.
12135 * regformats/i386/i386-mmx-linux.dat: Likewise.
12136 * regformats/i386/i386-mpx-linux.dat: Likewise.
12137 * regformats/i386/i386.dat: Likewise.
12138 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
12139 * regformats/i386/x32-avx-linux.dat: Likewise.
12140 * regformats/i386/x32-linux.dat: Likewise.
12141 * regformats/tic6x-c62x-linux.dat: Likewise.
12142 * regformats/tic6x-c64x-linux.dat: Likewise.
12143 * regformats/tic6x-c64xp-linux.dat: Likewise.
12144 * regformats/regdat.sh: Parse feature marker.
12145
12146 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12147
12148 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
12149 (tdesc_osabi_name): Likewise.
12150 * target-descriptions.c (tdesc_architecture_name): Add new
12151 function.
12152 (tdesc_osabi_name): Likewise.
12153
12154 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12155
12156 * common/tdesc.c (tdesc_predefined_type): Move to here.
12157 (tdesc_named_type): Likewise.
12158 (tdesc_create_vector): Likewise.
12159 (tdesc_create_struct): Likewise.
12160 (tdesc_set_struct_size): Likewise.
12161 (tdesc_create_union): Likewise.
12162 (tdesc_create_flags): Likewise.
12163 (tdesc_create_enum): Likewise.
12164 (tdesc_add_field): Likewise.
12165 (tdesc_add_typed_bitfield): Likewise.
12166 (tdesc_add_bitfield): Likewise.
12167 (tdesc_add_flag): Likewise.
12168 (tdesc_add_enum_value): Likewise.
12169 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
12170 (struct tdesc_type_vector): Likewise.
12171 (struct tdesc_type_field): Likewise.
12172 (struct tdesc_type_with_fields): Likewise.
12173 (tdesc_create_enum): Add declaration.
12174 (tdesc_add_typed_bitfield): Likewise.
12175 (tdesc_add_enum_value): Likewise.
12176 * target-descriptions.c (tdesc_type_field): Move from here.
12177 (tdesc_type_builtin): Likewise.
12178 (tdesc_type_vector): Likewise.
12179 (tdesc_type_with_fields): Likewise.
12180 (tdesc_predefined_types): Likewise.
12181 (tdesc_named_type): Likewise.
12182 (tdesc_create_vector): Likewise.
12183 (tdesc_create_struct): Likewise.
12184 (tdesc_set_struct_size): Likewise.
12185 (tdesc_create_union): Likewise.
12186 (tdesc_create_flags): Likewise.
12187 (tdesc_create_enum): Likewise.
12188 (tdesc_add_field): Likewise.
12189 (tdesc_add_typed_bitfield): Likewise.
12190 (tdesc_add_bitfield): Likewise.
12191 (tdesc_add_flag): Likewise.
12192 (tdesc_add_enum_value): Likewise.
12193 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
12194 (tdesc_add_typed_bitfield): Likewise.
12195 (tdesc_add_enum_value): Likewise.
12196
12197 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12198
12199 * common/tdesc.c (tdesc_feature::accept): Move to here.
12200 (tdesc_feature::operator==): Likewise.
12201 (tdesc_create_reg): Likewise.
12202 * common/tdesc.h (tdesc_type_kind): Likewise.
12203 (struct tdesc_type): Likewise.
12204 (struct tdesc_feature): Likewise.
12205 * regformats/regdat.sh: Create a feature.
12206 * target-descriptions.c (tdesc_type_kind): Move from here.
12207 (tdesc_type): Likewise.
12208 (tdesc_type_up): Likewise.
12209 (tdesc_feature): Likewise.
12210 (tdesc_create_reg): Likewise.
12211
12212 2018-04-18 Alan Hayward <alan.hayward@arm.com>
12213
12214 * Makefile.in: Add arch/tdesc.c
12215 * common/tdesc.c: New file.
12216 * common/tdesc.h (tdesc_element_visitor): Move to here.
12217 (tdesc_element): Likewise.
12218 (tdesc_reg): Likewise.
12219 (tdesc_reg_up): Likewise.
12220 * regformats/regdef.h (reg): Add offset to constructors.
12221 * target-descriptions.c (tdesc_element_visitor): Move from here.
12222 (tdesc_element): Likewise.
12223 (tdesc_reg): Likewise.
12224 (tdesc_reg_up): Likewise.
12225
12226 2018-04-17 Tom Tromey <tom@tromey.com>
12227
12228 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
12229 discriminant field.
12230
12231 2018-04-17 Tom Tromey <tom@tromey.com>
12232
12233 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
12234
12235 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
12236
12237 * symtab.c (print_symbol_info): Skip printing filename and line
12238 number when `last' is NULL.
12239 (symtab_symbol_info): Use empty string instead of NULL for first
12240 invocation of print_symbol_info.
12241 (rbreak_command): Pass NULL to `last' parameter of
12242 print_symbol_info.
12243
12244 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
12245
12246 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
12247 instead of nullptr.
12248
12249 2018-04-16 Pedro Alves <palves@redhat.com>
12250
12251 * MAINTAINERS (sh): Remove.
12252 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
12253 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
12254 (ALLDEPFILES): Remove sh64-tdep.c.
12255 * NEWS: Mentions that support for SH-5/SH64 is removed.
12256 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
12257 (sh*-*-openbsd*): Ditto.
12258 (sh64-*-elf*): Remove.
12259 (sh*): Remove.
12260 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
12261 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
12262 * sh-tdep.c: No longer include "sh64-tdep.h".
12263 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
12264 * sh64-tdep.c, sh64-tdep.h: Remove files.
12265
12266 2018-04-16 Pedro Alves <palves@redhat.com>
12267
12268 * MAINTAINERS: Remove m88k.
12269 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
12270 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
12271 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
12272 * NEWS: Mention that support for m88k was removed.
12273 * configure.host (m88*-*-*): Remove support.
12274 * configure.nat (m88k-*-*): Remove support.
12275 * configure.tgt (m88*-*-openbsd*): Remove.
12276 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
12277
12278 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
12279
12280 * configure.tgt (x86_tobjs): New variable.
12281 (amd64_tobjs, i386_tobjs): Use it.
12282
12283 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
12284
12285 * symtab.c (print_symbol_info): Precede the symbol definition by
12286 the line number when available.
12287 * NEWS: Advertise this enhancement.
12288
12289 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
12290
12291 * NEWS (New options): announce set/show record btrace cpu.
12292 * btrace.c: Include record-btrace.h.
12293 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
12294 the vendor is unknown.
12295 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
12296 Maybe overwrite the btrace configuration's cpu.
12297 (btrace_compute_ftrace): Add cpu parameter. Update callers.
12298 (btrace_fetch): Add cpu parameter. Update callers.
12299 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
12300 Maybe overwrite the btrace configuration's cpu. Skip enabling
12301 errata workarounds if the vendor is unknown.
12302 * python/py-record-btrace.c: Include record-btrace.h.
12303 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
12304 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
12305 * record-btrace.c (record_btrace_cpu_state_kind): New.
12306 (record_btrace_cpu): New.
12307 (set_record_btrace_cpu_cmdlist): New.
12308 (record_btrace_get_cpu): New.
12309 (require_btrace_thread, record_btrace_info)
12310 (record_btrace_resume_thread): Call record_btrace_get_cpu.
12311 (cmd_set_record_btrace_cpu_none): New.
12312 (cmd_set_record_btrace_cpu_auto): New.
12313 (cmd_set_record_btrace_cpu): New.
12314 (cmd_show_record_btrace_cpu): New.
12315 (_initialize_record_btrace): Initialize set/show record btrace cpu
12316 commands.
12317 * record-btrace.h (record_btrace_get_cpu): New.
12318
12319 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
12320
12321 * record.c (set_record_command): Fix typo in message.
12322
12323 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
12324
12325 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
12326
12327 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
12328
12329 * infrun.c (process_event_stop_test): Call
12330 gdbarch_in_indirect_branch_thunk.
12331 * gdbarch.sh (in_indirect_branch_thunk): New.
12332 * gdbarch.c: Regenerated.
12333 * gdbarch.h: Regenerated.
12334 * x86-tdep.h: New.
12335 * x86-tdep.c: New.
12336 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
12337 (HFILES_NO_SRCDIR): Add x86-tdep.h.
12338 (ALLDEPFILES): Add x86-tdep.c.
12339 * arch-utils.h (default_in_indirect_branch_thunk): New.
12340 * arch-utils.c (default_in_indirect_branch_thunk): New.
12341 * i386-tdep: Include x86-tdep.h.
12342 (i386_in_indirect_branch_thunk): New.
12343 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
12344 function.
12345 * amd64-tdep: Include x86-tdep.h.
12346 (amd64_in_indirect_branch_thunk): New.
12347 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
12348
12349 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
12350
12351 PR gdb/23053
12352 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
12353 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
12354 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
12355 regression.
12356
12357 2018-04-12 Tom Tromey <tom@tromey.com>
12358
12359 * rust-lang.c (rust_print_struct_def): Remove univariant code.
12360 (rust_evaluate_subexp): Likewise.
12361
12362 2018-04-12 Pedro Alves <palves@redhat.com>
12363
12364 * procfs.c (procfs_detach): Make forward declaration's prototype
12365 match definition's protototype.
12366 (proc_get_LDT_entry): Remove stale do_cleanups call.
12367
12368 2018-04-12 Pedro Alves <palves@redhat.com>
12369
12370 * target.h (target_ops::to_has_exited): Delete.
12371 (target_has_exited): Delete.
12372 * target-delegates.c: Regenerate.
12373
12374 2018-04-11 Pedro Alves <palves@redhat.com>
12375
12376 * target.c (fileio_fh_t::t): Add comment.
12377 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
12378 (target_fileio_close): Handle a NULL target.
12379 (invalidate_fileio_fh): New.
12380 (target_close): Call it.
12381 * remote.c (remote_hostio_send_command): No longer check whether
12382 remote_desc is open.
12383
12384 2018-04-11 Pedro Alves <palves@redhat.com>
12385
12386 * target.c (fileio_fh_t): Make it a named struct instead of a
12387 typedef.
12388 (fileio_fh_t::is_closed): New method.
12389 (DEF_VEC_O (fileio_fh_t)): Remove.
12390 (fileio_fhandles): Now a std::vector.
12391 (is_closed_fileio_fh): Delete.
12392 (acquire_fileio_fd): Adjust. Rename parameters.
12393 (release_fileio_fd): Adjust.
12394 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
12395 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
12396 (target_fileio_close): Adjust.
12397
12398 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
12399
12400 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
12401 index.
12402
12403 2018-04-10 Pedro Alves <palves@redhat.com>
12404
12405 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
12406 (scoped_finish_thread_state): New class.
12407 * infcmd.c (run_command_1): Use it instead of finish_thread_state
12408 cleanup.
12409 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
12410 (fetch_inferior_event, normal_stop): Likewise.
12411 * thread.c (finish_thread_state_cleanup): Delete.
12412
12413 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12414 Pedro Alves <palves@redhat.com>
12415
12416 * value.c: Include "selftest.h" and "common/array-view.h".
12417 (struct range) <operator ==>: New.
12418 (test_ranges_contain): New.
12419 (check_ranges_vector): New.
12420 (test_insert_into_bit_range_vector): New.
12421 (_initialize_values): Register selftests.
12422 * common/array-view.h (operator==, operator!=): New.
12423
12424 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12425
12426 * common/gdb_vecs.h (unordered_remove): Add overload that takes
12427 an iterator.
12428 * inline-frame.c: Include <algorithm>.
12429 (struct inline_state): Add constructor.
12430 (inline_state_s): Remove.
12431 (DEF_VEC_O(inline_state_s)): Remove.
12432 (inline_states): Change type to std::vector.
12433 (find_inline_frame_state): Adjust to std::vector.
12434 (allocate_inline_frame_state): Remove.
12435 (clear_inline_frame_state): Adjust to std::vector.
12436 (skip_inline_frames): Adjust to std::vector.
12437
12438 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12439
12440 * tracepoint.h (struct trace_state_variable): Add constructor.
12441 <name>: Change type to std::string.
12442 * tracepoint.c (tsv_s): Remove.
12443 (DEF_VEC_O(tsv_s)): Remove.
12444 (tvariables): Change to std::vector.
12445 (create_trace_state_variable): Adjust to std::vector.
12446 (find_trace_state_variable): Likewise.
12447 (find_trace_state_variable_by_number): Likewise.
12448 (delete_trace_state_variable): Likewise.
12449 (trace_variable_command): Adjust to std::string.
12450 (delete_trace_variable_command): Likewise.
12451 (tvariables_info_1): Adjust to std::vector.
12452 (save_trace_state_variables): Likewise.
12453 (start_tracing): Likewise.
12454 (merge_uploaded_trace_state_variables): Adjust to std::vector
12455 and std::string.
12456 * target.h (struct target_ops)
12457 <to_download_trace_state_variable>: Pass reference to
12458 trace_state_variable.
12459 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
12460 * target-delegates.c: Re-generate.
12461 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
12462 (mi_tsv_deleted): Likewise.
12463 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
12464 * remote.c (remote_download_trace_state_variable): Change
12465 pointer to reference and adjust.
12466 * make-target-delegates (parse_argtypes): Handle references.
12467 (write_function_header): Likewise.
12468 (munge_type): Likewise.
12469
12470 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12471
12472 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12473 string_view-selftests.c.
12474 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
12475 testsuite.
12476 * unittests/basic_string_view/cons/char/1.cc: Likewise.
12477 * unittests/basic_string_view/cons/char/2.cc: Likewise.
12478 * unittests/basic_string_view/cons/char/3.cc: Likewise.
12479 * unittests/basic_string_view/element_access/char/1.cc:
12480 Likewise.
12481 * unittests/basic_string_view/element_access/char/empty.cc:
12482 Likewise.
12483 * unittests/basic_string_view/element_access/char/front_back.cc:
12484 Likewise.
12485 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
12486 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
12487 Likewise.
12488 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
12489 Likewise.
12490 * unittests/basic_string_view/modifiers/swap/char/1.cc:
12491 Likewise.
12492 * unittests/basic_string_view/operations/compare/char/1.cc:
12493 Likewise.
12494 * unittests/basic_string_view/operations/compare/char/13650.cc:
12495 Likewise.
12496 * unittests/basic_string_view/operations/copy/char/1.cc:
12497 Likewise.
12498 * unittests/basic_string_view/operations/data/char/1.cc:
12499 Likewise.
12500 * unittests/basic_string_view/operations/find/char/1.cc:
12501 Likewise.
12502 * unittests/basic_string_view/operations/find/char/2.cc:
12503 Likewise.
12504 * unittests/basic_string_view/operations/find/char/3.cc:
12505 Likewise.
12506 * unittests/basic_string_view/operations/find/char/4.cc:
12507 Likewise.
12508 * unittests/basic_string_view/operations/rfind/char/1.cc:
12509 Likewise.
12510 * unittests/basic_string_view/operations/rfind/char/2.cc:
12511 Likewise.
12512 * unittests/basic_string_view/operations/rfind/char/3.cc:
12513 Likewise.
12514 * unittests/basic_string_view/operations/substr/char/1.cc:
12515 Likewise.
12516 * unittests/basic_string_view/operators/char/2.cc: Likewise.
12517 * unittests/string_view-selftests.c: New file.
12518
12519 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12520
12521 * unittests/basic_string_view/capacity/1.cc: New file.
12522 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
12523 * unittests/basic_string_view/cons/char/1.cc: New file.
12524 * unittests/basic_string_view/cons/char/2.cc: New file.
12525 * unittests/basic_string_view/cons/char/3.cc: New file.
12526 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
12527 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
12528 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
12529 * unittests/basic_string_view/element_access/char/1.cc: New file.
12530 * unittests/basic_string_view/element_access/char/2.cc: New file.
12531 * unittests/basic_string_view/element_access/char/empty.cc: New file.
12532 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
12533 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
12534 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
12535 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
12536 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
12537 * unittests/basic_string_view/include.cc: New file.
12538 * unittests/basic_string_view/inserters/char/1.cc: New file.
12539 * unittests/basic_string_view/inserters/char/2.cc: New file.
12540 * unittests/basic_string_view/inserters/char/3.cc: New file.
12541 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
12542 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
12543 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
12544 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
12545 * unittests/basic_string_view/literals/types.cc: New file.
12546 * unittests/basic_string_view/literals/values.cc: New file.
12547 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
12548 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
12549 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
12550 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
12551 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
12552 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
12553 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
12554 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
12555 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
12556 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
12557 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
12558 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
12559 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
12560 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
12561 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
12562 * unittests/basic_string_view/operations/data/char/1.cc: New file.
12563 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
12564 * unittests/basic_string_view/operations/find/char/1.cc: New file.
12565 * unittests/basic_string_view/operations/find/char/2.cc: New file.
12566 * unittests/basic_string_view/operations/find/char/3.cc: New file.
12567 * unittests/basic_string_view/operations/find/char/4.cc: New file.
12568 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
12569 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
12570 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
12571 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
12572 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
12573 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
12574 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
12575 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
12576 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
12577 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
12578 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
12579 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
12580 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
12581 * unittests/basic_string_view/operators/char/2.cc: New file.
12582 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
12583 * unittests/basic_string_view/range_access/char/1.cc: New file.
12584 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
12585 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
12586 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
12587 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
12588 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
12589 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
12590 * unittests/basic_string_view/requirements/typedefs.cc: New file.
12591 * unittests/basic_string_view/typedefs.cc: New file.
12592 * unittests/basic_string_view/types/1.cc: New file.
12593
12594 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12595
12596 * common/gdb_string_view.h: Remove libstdc++ implementation
12597 details, adjust to gdb reality.
12598 * common/gdb_string_view.tcc: Likewise.
12599 * cli/cli-script.c (struct string_view): Remove.
12600 (user_args) <m_args>: Change element type to gdb::string_view.
12601 (user_args::insert_args): Adjust.
12602
12603 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12604
12605 * common/gdb_string_view.h: New file.
12606 * common/gdb_string_view.tcc: New file.
12607
12608 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12609
12610 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
12611 * configure: Re-generate.
12612
12613 2018-04-09 Pedro Alves <palves@redhat.com>
12614
12615 * gdbarch.sh: Include "observable.h" instead of "observer.h".
12616 (set_target_gdbarch): Call
12617 gdb::observers::architecture_changed.notify instead of
12618 observer_notify_architecture_changed.
12619
12620 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
12621
12622 * tracepoint.c (struct current_traceframe_cleanup): Remove.
12623 (do_restore_current_traceframe_cleanup): Remove.
12624 (restore_current_traceframe_cleanup_dtor): Remove.
12625 (make_cleanup_restore_current_traceframe): Remove.
12626 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
12627 New.
12628 * tracepoint.h (struct scoped_restore_current_traceframe): New.
12629 * infrun.c (fetch_inferior_event): Use
12630 scoped_restore_current_traceframe.
12631
12632 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
12633
12634 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
12635 Remove.
12636 <n_allocated_type_units>: Remove.
12637 <all_type_units>: Change to std::vector.
12638 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
12639 to std::vector change.
12640 (dwarf2_per_objfile::get_cutu): Likewise.
12641 (dwarf2_per_objfile::get_tu): Likewise.
12642 (create_signatured_type_table_from_index): Likewise.
12643 (create_signatured_type_table_from_debug_names): Likewise.
12644 (dw2_symtab_iter_next): Likewise.
12645 (dw2_print_stats): Likewise.
12646 (dw2_expand_all_symtabs): Likewise.
12647 (dw2_expand_marked_cus): Likewise.
12648 (dw2_debug_names_iterator::next): Likewise.
12649 (dwarf2_initialize_objfile): Likewise.
12650 (add_signatured_type_cu_to_table): Likewise.
12651 (create_all_type_units): Likewise.
12652 (add_type_unit): Likewise.
12653 (struct tu_abbrev_offset): Add constructor.
12654 (build_type_psymtabs_1): Adjust to std::vector change.
12655 (print_tu_stats): Likewise.
12656 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
12657 (write_debug_names): Likewise.
12658
12659 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
12660
12661 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
12662 Make an std::vector.
12663 <n_comp_units>: Remove.
12664 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
12665 to std::vector change.
12666 (dwarf2_per_objfile::get_cutu): Likewise.
12667 (dwarf2_per_objfile::get_cu): Likewise.
12668 (create_cus_from_index): Likewise.
12669 (create_addrmap_from_index): Likewise.
12670 (create_addrmap_from_aranges): Likewise.
12671 (dwarf2_read_index): Likewise.
12672 (dw2_find_last_source_symtab): Likewise.
12673 (dw2_map_symtabs_matching_filename): Likewise.
12674 (dw2_symtab_iter_next): Likewise.
12675 (dw2_print_stats): Likewise.
12676 (dw2_expand_all_symtabs): Likewise.
12677 (dw2_expand_symtabs_with_fullname): Likewise.
12678 (dw2_expand_marked_cus): Likewise.
12679 (dw2_map_symbol_filenames): Likewise.
12680 (create_cus_from_debug_names): Likewise.
12681 (dwarf2_read_debug_names): Likewise.
12682 (dw2_debug_names_iterator::next): Likewise.
12683 (dwarf2_initialize_objfile): Likewise.
12684 (set_partial_user): Likewise.
12685 (dwarf2_build_psymtabs_hard): Likewise.
12686 (read_comp_units_from_section): Remove arguments, adjust to
12687 std::vector change.
12688 (create_all_comp_units): Adjust to std::vector and
12689 read_comp_units_from_section changes.
12690 (dwarf2_find_containing_comp_unit): Adjust to std::vector
12691 change.
12692 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
12693 (psyms_seen_size): Likewise.
12694 (write_gdbindex): Likewise.
12695 (write_debug_names): Likewise.
12696
12697 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
12698
12699 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
12700 with dwarf2_per_objfile.
12701 (create_cus_from_index): Likewise.
12702 (create_signatured_type_table_from_index): Likewise.
12703 (dwarf2_read_index): Likewise.
12704 (dwarf2_initialize_objfile): Likewise.
12705 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
12706 per_cu rather than get_dwarf2_per_objfile.
12707
12708 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
12709
12710 * dwarf2read.h (struct signatured_type): Forward declare.
12711 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
12712 New methods.
12713 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
12714 (dw2_get_cutu): ...this.
12715 (dwarf2_per_objfile::get_cu): Rename from...
12716 (dw2_get_cu): ...this.
12717 (dwarf2_per_objfile::get_tu): New.
12718 (create_addrmap_from_index): Adjust.
12719 (create_addrmap_from_aranges): Adjust.
12720 (dw2_find_last_source_symtab): Adjust.
12721 (dw2_map_symtabs_matching_filename): Adjust.
12722 (dw2_symtab_iter_next): Adjust.
12723 (dw2_print_stats): Adjust.
12724 (dw2_expand_all_symtabs): Adjust.
12725 (dw2_expand_symtabs_with_fullname): Adjust.
12726 (dw2_expand_marked_cus): Adjust.
12727 (dw_expand_symtabs_matching_file_matcher): Adjust.
12728 (dw2_map_symbol_filenames): Adjust.
12729 (dw2_debug_names_iterator::next): Adjust.
12730 (dwarf2_initialize_objfile): Adjust.
12731 (set_partial_user): Adjust.
12732 (dwarf2_build_psymtabs_hard): Adjust.
12733
12734 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
12735
12736 * dwarf2read.c (create_signatured_type_table_from_debug_names):
12737 Remove unused variables.
12738 (dw2_map_symtabs_matching_filename): Likewise.
12739 (dwarf2_record_block_ranges): Likewise.
12740 (dwarf2_read_addr_index): Likewise.
12741 (follow_die_offset): Likewise.
12742
12743 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
12744
12745 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
12746 to symbol_file_add_main.
12747
12748 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
12749
12750 PR mi/22299
12751 * mi/mi-console.c (do_fputc_async_safe): New.
12752 (mi_console_file::write_async_safe): New.
12753 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
12754 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
12755 New.
12756 * ui-file.c (ui_file::putstrn): Adjust call to
12757 fputstrn_unfiltered.
12758 * utils.c (printchar): Replace do_fputs and do_fprintf
12759 parameters by do_fputc.
12760 (fputstr_filtered): Adjust call to printchar.
12761 (fputstr_unfiltered): Likewise.
12762 (fputstrn_filtered): Likewise.
12763 (fputstrn_unfiltered): Add do_fputc parameter, pass to
12764 printchar.
12765 * utils.h (do_fputc_ftype): New typedef.
12766 (fputstrn_unfiltered): Add do_fputc parameter.
12767
12768 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
12769
12770 * regformats/i386/i386-avx.dat: Remove.
12771
12772 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
12773
12774 PR gdb/22979
12775 * amd64-tdep.c (amd64_none_init_abi): New function.
12776 (amd64_x32_none_init_abi): New function.
12777 (_initialize_amd64_tdep): Register handlers for x86-64 and
12778 x64_32 with GDB_OSABI_NONE.
12779 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
12780 GDB_OSABI_NONE osabi.
12781
12782 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
12783
12784 PR gdb/22980
12785 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
12786 GDB_OSABI_NONE.
12787 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
12788 * osabi.c (gdb_osabi_names): Add "unknown" entry.
12789
12790 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
12791
12792 * common/byte-vector.h (char_vector): New type.
12793 * target.h (target_read_alloc): Return
12794 gdb::optional<byte_vector>.
12795 (target_read_stralloc): Return gdb::optional<char_vector>.
12796 (target_get_osdata): Return gdb::optional<char_vector>.
12797 * target.c (target_read_alloc_1): Templatize. Replacement
12798 manual memory management with vector.
12799 (target_read_alloc): Change return type, adjust.
12800 (target_read_stralloc): Change return type, adjust.
12801 (target_get_osdata): Change return type, adjust.
12802 * auxv.c (struct auxv_info) <length>: Remove.
12803 <data>: Change type to gdb::optional<byte_vector>.
12804 (auxv_inferior_data_cleanup): Free auxv_info with delete.
12805 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
12806 (target_auxv_search): Adjust.
12807 (fprint_target_auxv): Adjust.
12808 * avr-tdep.c (avr_io_reg_read_command): Adjust.
12809 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
12810 (linux_make_corefile_notes): Adjust.
12811 * osdata.c (get_osdata): Adjust.
12812 * remote.c (remote_get_threads_with_qxfer): Adjust.
12813 (remote_memory_map): Adjust.
12814 (remote_traceframe_info): Adjust.
12815 (btrace_read_config): Adjust.
12816 (remote_read_btrace): Adjust.
12817 (remote_pid_to_exec_file): Adjust.
12818 * solib-aix.c (solib_aix_get_library_list): Adjust.
12819 * solib-dsbt.c (decode_loadmap): Don't free buf.
12820 (dsbt_get_initial_loadmaps): Adjust.
12821 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
12822 * solib-target.c (solib_target_current_sos): Adjust.
12823 * tracepoint.c (sdata_make_value): Adjust.
12824 * xml-support.c (xinclude_start_include): Adjust.
12825 (xml_fetch_content_from_file): Adjust.
12826 * xml-support.h (xml_fetch_another): Change return type.
12827 (xml_fetch_content_from_file): Change return type.
12828 * xml-syscall.c (xml_init_syscalls_info): Adjust.
12829 * xml-tdesc.c (file_read_description_xml): Adjust.
12830 (fetch_available_features_from_target): Change return type.
12831 (target_fetch_description_xml): Adjust.
12832 (target_read_description_xml): Adjust.
12833
12834 2018-04-06 Tom Tromey <tom@tromey.com>
12835
12836 * value.c (~value): Update.
12837 (struct value) <contents>: Now unique_xmalloc_ptr.
12838 (value_contents_bits_eq, allocate_value_contents)
12839 (value_contents_raw, value_contents_all_raw)
12840 (value_contents_for_printing, value_contents_for_printing_const)
12841 (set_value_enclosing_type): Update.
12842
12843 2018-04-06 Tom Tromey <tom@tromey.com>
12844
12845 * value.c (range_s): Remove typedef, VEC.
12846 (struct range): Add operator<.
12847 (range_lessthan): Remove.
12848 (ranges_contain): Change type.
12849 (~value): Update.
12850 (struct value) <unavailable, optimized_out>: Now std::vector.
12851 (value_entirely_available)
12852 (value_entirely_covered_by_range_vector)
12853 (value_entirely_unavailable, value_entirely_optimized_out):
12854 Update.
12855 (insert_into_bit_range_vector): Change argument type.
12856 (find_first_range_overlap): Likewise.
12857 (struct ranges_and_idx, value_contents_bits_eq)
12858 (require_not_optimized_out, require_available): Update.
12859 (ranges_copy_adjusted): Change argument types.
12860 (value_optimized_out, value_copy, value_fetch_lazy): Update.
12861
12862 2018-04-06 Tom Tromey <tom@tromey.com>
12863
12864 * value.c (~value): Update.
12865 (struct value) <parent>: Now a value_ref_ptr.
12866 (value_parent, set_value_parent, value_address, value_copy):
12867 Update.
12868
12869 2018-04-06 Tom Tromey <tom@tromey.com>
12870
12871 * value.c (struct value): Add constructor, destructor, and member
12872 initializers.
12873 (allocate_value_lazy, value_decref): Update.
12874
12875 2018-04-06 Tom Tromey <tom@tromey.com>
12876
12877 * value.c (struct value) <released, next>: Remove.
12878 (all_values): Now a std::vector.
12879 (allocate_value_lazy): Update.
12880 (value_next): Remove.
12881 (value_mark, value_free_to_mark, release_value)
12882 (value_release_to_mark): Update.
12883
12884 2018-04-06 Tom Tromey <tom@tromey.com>
12885
12886 * value.h (fetch_subexp_value, value_release_to_mark): Update.
12887 (free_value_chain): Remove.
12888 * value.c (free_value_chain): Remove.
12889 (value_release_to_mark): Return a std::vector.
12890 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
12891 std::vector.
12892 (check_condition): Update.
12893 * eval.c (fetch_subexp_value): Change "val_chain" to a
12894 std::vector.
12895 * breakpoint.c (update_watchpoint): Update.
12896 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
12897
12898 2018-04-06 Tom Tromey <tom@tromey.com>
12899
12900 * value.h (free_all_values): Remove.
12901 * value.c (free_all_values): Remove.
12902
12903 2018-04-06 Tom Tromey <tom@tromey.com>
12904
12905 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
12906 (value_history_chain, value_history_count): Remove.
12907 (value_history): New global.
12908 (record_latest_value, access_value_history, show_values)
12909 (preserve_values): Update.
12910
12911 2018-04-06 Tom Tromey <tom@tromey.com>
12912
12913 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
12914 * varobj.c (varobj_set_display_format, varobj_set_value)
12915 (install_default_visualizer, construct_visualizer)
12916 (install_new_value, ~varobj, varobj_get_value_type)
12917 (my_value_of_variable, varobj_editable_p): Update.
12918 * c-varobj.c (c_describe_child, c_value_of_variable)
12919 (cplus_number_of_children, cplus_describe_child): Update.
12920 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
12921 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
12922 (ada_value_of_variable, ada_value_is_changeable_p): Update.
12923
12924 2018-04-06 Tom Tromey <tom@tromey.com>
12925
12926 * printcmd.c (last_examine_address): Change type to
12927 value_ref_ptr.
12928 (do_examine, x_command): Update.
12929
12930 2018-04-06 Tom Tromey <tom@tromey.com>
12931
12932 * value.c (release_value): Update.
12933 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
12934 (struct bpstats) <val>: Now a value_ref_ptr.
12935 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
12936 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
12937 (~watchpoint, print_it_watchpoint, watch_command_1)
12938 (invalidate_bp_value_on_memory_change): Update.
12939
12940 2018-04-06 Tom Tromey <tom@tromey.com>
12941
12942 * varobj.c (varobj_clear_saved_item)
12943 (update_dynamic_varobj_children, install_new_value, ~varobj):
12944 Update.
12945 * value.h (value_incref): Move declaration earlier.
12946 (value_decref): Rename from value_free.
12947 (struct value_ref_policy): New.
12948 (value_ref_ptr): New typedef.
12949 (struct value_deleter): Remove.
12950 (gdb_value_up): Remove typedef.
12951 (release_value): Change return type.
12952 (release_value_or_incref): Remove.
12953 * value.c (set_value_parent): Update.
12954 (value_incref): Change return type.
12955 (value_decref): Rename from value_free.
12956 (value_free_to_mark, free_all_values, free_value_chain): Update.
12957 (release_value): Return value_ref_ptr.
12958 (release_value_or_incref): Remove.
12959 (record_latest_value, set_internalvar, clear_internalvar):
12960 Update.
12961 * stack.c (info_frame_command): Don't call value_free.
12962 * python/py-value.c (valpy_dealloc, valpy_new)
12963 (value_to_value_object): Update.
12964 * printcmd.c (do_examine): Update.
12965 * opencl-lang.c (lval_func_free_closure): Update.
12966 * mi/mi-main.c (register_changed_p): Don't call value_free.
12967 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
12968 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
12969 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
12970 value_free.
12971 * guile/scm-value.c (vlscm_free_value_smob)
12972 (vlscm_scm_from_value): Update.
12973 * frame.c (frame_register_unwind, frame_unwind_register_signed)
12974 (frame_unwind_register_unsigned, get_frame_register_bytes)
12975 (put_frame_register_bytes): Don't call value_free.
12976 * findvar.c (address_from_register): Don't call value_free.
12977 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
12978 * dwarf2loc.c (entry_data_value_free_closure)
12979 (value_of_dwarf_reg_entry, free_pieced_value_closure)
12980 (dwarf2_evaluate_loc_desc_full): Update.
12981 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
12982 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
12983 (~watchpoint, watch_command_1)
12984 (invalidate_bp_value_on_memory_change): Update.
12985 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
12986
12987 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
12988
12989 PR gdb/23022
12990 * warning.m4: Add -Wno-error=deprecated-register.
12991 * configure: Re-generate.
12992
12993 2018-04-05 Tom Tromey <tom@tromey.com>
12994
12995 * linespec.h: Remove include of "vec.h".
12996
12997 2018-04-05 Tom Tromey <tom@tromey.com>
12998
12999 * linespec.c (typep): Remove typedef.
13000 (find_methods, find_superclass_methods): Take a std::vector.
13001 (find_method): Use std::vector.
13002
13003 2018-04-05 Tom Tromey <tom@tromey.com>
13004
13005 * utils.c (compare_strings): Remove.
13006 * utils.h (compare_strings): Remove.
13007 * objc-lang.h (find_imps): Update.
13008 * objc-lang.c (find_methods): Take a std::vector.
13009 (uniquify_strings, find_imps): Likewise.
13010 * linespec.c (find_methods): Take a std::vector.
13011 (decode_objc): Use std::vector.
13012 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
13013 a std::vector.
13014 (find_method, find_function_symbols): Use std::vector.
13015
13016 2018-04-05 Tom Tromey <tom@tromey.com>
13017
13018 * completer.c (completion_tracker::completion_tracker): Remove
13019 cast.
13020 (completion_tracker::discard_completions): Likewise.
13021 * breakpoint.c (ambiguous_names_p): Remove cast.
13022 * ada-lang.c (_initialize_ada_language): Remove cast.
13023 * utils.h (streq): Update.
13024 (streq_hash): Add new declaration.
13025 * utils.c (streq): Return bool.
13026 (streq_hash): New function.
13027
13028 2018-04-05 Tom Tromey <tom@tromey.com>
13029
13030 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
13031 Remove a string copy.
13032
13033 2018-04-05 Tom Tromey <tom@tromey.com>
13034
13035 * linespec.c (filter_results): Use std::vector.
13036 (decode_line_2, decode_line_full): Update.
13037
13038 2018-04-05 Tom Tromey <tom@tromey.com>
13039
13040 * linespec.c (canonical_to_fullform): Return std::string.
13041 (filter_results): Update.
13042 (struct decode_line_2_item): Add constructor.
13043 <fullform, displayform>: Now std::string.
13044 (decode_line_2_compare_items): Now a std::sort comparator.
13045 (decode_line_2): Update.
13046
13047 2018-04-05 Tom Tromey <tom@tromey.com>
13048
13049 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
13050 (unexpected_linespec_error): Update.
13051 (linespec_parse_basic, parse_linespec): Update.
13052
13053 2018-04-05 Tom Tromey <tom@tromey.com>
13054
13055 * linespec.c (linespec_parse_basic): Reindent.
13056
13057 2018-04-05 Tom Tromey <tom@tromey.com>
13058
13059 * minsyms.h (iterate_over_minimal_symbols): Update.
13060 * minsyms.c (iterate_over_minimal_symbols): Take a
13061 gdb::function_view.
13062 * linespec.c (struct collect_minsyms): Remove.
13063 (compare_msyms): Now a std::sort comparator.
13064 (add_minsym): Add parameters.
13065 (search_minsyms_for_name): Update. Use std::vector.
13066
13067 2018-04-03 Tom Tromey <tom@tromey.com>
13068
13069 * mipsread.c (read_alphacoff_dynamic_symtab): Use
13070 gdb::byte_vector.
13071
13072 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
13073
13074 * MAINTAINERS (Write After Approval): Add Weimin Pan.
13075
13076 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
13077
13078 PR gdb/16959
13079 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
13080 printing static type.
13081
13082 2018-04-01 Tom Tromey <tom@tromey.com>
13083
13084 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
13085 (rs6000_xfer_shared_libraries): Update.
13086
13087 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
13088
13089 * common/gdb_vecs.h (char_ptr): Remove.
13090 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
13091
13092 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
13093
13094 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
13095 with std::vector.
13096 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
13097
13098 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
13099
13100 * tracepoint.h (struct uploaded_tp): Initialize fields.
13101 <actions, step_actions, cmd_strings>: Change type to
13102 std::vector<char *>.
13103 * tracepoint.c (get_uploaded_tp): Allocate with new.
13104 (free_uploaded_tps): Free with delete.
13105 (parse_tracepoint_definition): Adjust to std::vector change.
13106 * breakpoint.c (read_uploaded_action): Likewise.
13107 (create_tracepoint_from_upload): Likewise.
13108 * ctf.c (ctf_write_uploaded_tp): Likewise.
13109 (SET_ARRAY_FIELD): Likewise.
13110 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
13111
13112 2018-03-30 Tom Tromey <tom@tromey.com>
13113
13114 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
13115 std::unique_ptr.
13116 (svr4_keep_data_in_core): Update.
13117 (svr4_read_so_list): Update.
13118
13119 2018-03-30 Tom Tromey <tom@tromey.com>
13120
13121 * windows-nat.c (handle_output_debug_string, handle_exception):
13122 Update.
13123 * target.h (target_read_string): Update.
13124 * target.c (target_read_string): Change "string" to
13125 unique_xmalloc_ptr.
13126 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
13127 Update.
13128 * solib-frv.c (frv_current_sos): Update.
13129 * solib-dsbt.c (dsbt_current_sos): Update.
13130 * solib-darwin.c (darwin_current_sos): Update.
13131 * linux-thread-db.c (inferior_has_bug): Update.
13132 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
13133 Update. Remove alloca.
13134 * ada-lang.c (ada_main_name): Update.
13135
13136 2018-03-30 Tom Tromey <tom@tromey.com>
13137
13138 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
13139 (struct dwo_file_deleter): New.
13140 (dwo_file_up): New typedef.
13141 (open_and_init_dwo_file): Use dwo_file_up.
13142 (free_dwo_file_cleanup): Remove.
13143
13144 2018-03-30 Tom Tromey <tom@tromey.com>
13145
13146 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
13147 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
13148
13149 2018-03-30 Tom Tromey <tom@tromey.com>
13150
13151 * dwarf2read.c (class free_cached_comp_units): New class.
13152 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
13153 (free_cached_comp_units): Remove function.
13154
13155 2018-03-30 Tom Tromey <tom@tromey.com>
13156
13157 * utils.h (make_cleanup_unpush_target): Remove.
13158 * inf-ptrace.c (struct target_unpusher): New.
13159 (target_unpush_up) New typedef.
13160 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
13161 target_unpush_up.
13162 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
13163
13164 2018-03-27 Tom Tromey <tom@tromey.com>
13165
13166 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
13167
13168 2018-03-27 Pedro Alves <palves@redhat.com>
13169 Tom Tromey <tom@tromey.com>
13170
13171 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
13172 destructor. Now a class.
13173 (gdb_readline_wrapper_cleanup): Remove function.
13174 (gdb_readline_wrapper): Remove cleanups.
13175
13176 2018-03-27 Tom Tromey <tom@tromey.com>
13177
13178 * typeprint.h (struct type_print_options) <local_typedefs,
13179 global_typedefs>: Remove "struct" keyword.
13180 (class typedef_hash_table): New class.
13181 (recursively_update_typedef_hash, add_template_parameters)
13182 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
13183 (find_typedef_in_hash): Don't declare.
13184 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
13185 (typedef_hash_table::recursively_update): Rename from
13186 recursively_update_typedef_hash. Now a member.
13187 (typedef_hash_table::add_template_parameters): Rename from
13188 add_template_parameters. Now a member.
13189 (typedef_hash_table::typedef_hash_table): Now a constructor;
13190 rename from create_typedef_hash.
13191 (typedef_hash_table::~typedef_hash_table): Now a destructor;
13192 rename from free_typedef_hash.
13193 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
13194 (do_free_global_table): Remove.
13195 (typedef_hash_table::typedef_hash_table): New constructor; renamed
13196 from copy_type_recursive.
13197 (create_global_typedef_table): Remove.
13198 (typedef_hash_table::find_global_typedef): Now a member of
13199 typedef_hash_table.
13200 (typedef_hash_table::find_typedef): Rename from
13201 find_typedef_in_hash; now a member.
13202 (whatis_exp): Update.
13203 * extension.h (struct ext_lang_type_printers): Add constructor and
13204 destructor.
13205 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
13206 declare.
13207 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
13208 Now a constructor; rename from start_ext_lang_type_printers.
13209 (ext_lang_type_printers): Now a destructor; rename from
13210 free_ext_lang_type_printers.
13211 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
13212 Update.
13213 (c_type_print_base_struct_union): Update. Remove cleanups.
13214
13215 2018-03-27 Tom Tromey <tom@tromey.com>
13216
13217 * dwarf-index-write.c: Include <cmath>.
13218
13219 2018-03-27 Joel Brobecker <brobecker@adacore.com>
13220
13221 * NEWS: Add entry describing new "set|show varsize-limit" command.
13222 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
13223 command.
13224 * printcmd.c (_initialize_printcmd): Add "set var" alias of
13225 "set variable".
13226
13227 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
13228
13229 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
13230 dwarf-index-write.c
13231 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
13232 * dwarf-index-common.c: New file.
13233 * dwarf-index-common.h: New file.
13234 * dwarf-index-write.c: New file.
13235 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
13236 (struct dwarf2_section_info): Move from here.
13237 (dwarf2_section_info_def): Likewise.
13238 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
13239 (offset_type): Likewise.
13240 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
13241 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
13242 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
13243 (byte_swap): Likewise.
13244 (MAYBE_SWAP): Likewise.
13245 (dwarf2_per_cu_ptr): Likewise.
13246 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
13247 (struct tu_stats): Likewise.
13248 (struct dwarf2_per_objfile): Likewise.
13249 (struct dwarf2_per_cu_data): Likewise.
13250 (struct signatured_type): Likewise.
13251 (sig_type_ptr): Likewise.
13252 (DEF_VEC_P (sig_type_ptr)): Likewise.
13253 (INDEX4_SUFFIX): Likewise.
13254 (INDEX5_SUFFIX): Likewise.
13255 (DEBUG_STR_SUFFIX): Likewise.
13256 (dwarf2_read_section): Make non-static.
13257 (mapped_index_string_hash): Move from here.
13258 (dwarf5_djb_hash): Likewise.
13259 (file_write): Likewise.
13260 (class data_buf): Likewise.
13261 (struct symtab_index_entry): Likewise.
13262 (struct mapped_symtab): Likewise.
13263 (find_slot): Likewise.
13264 (hash_expand): Likewise.
13265 (add_index_entry): Likewise.
13266 (uniquify_cu_indices): Likewise.
13267 (class c_str_view): Likewise.
13268 (class c_str_view_hasher): Likewise.
13269 (class vector_hasher): Likewise.
13270 (write_hash_table): Likewise.
13271 (psym_index_map): Likewise.
13272 (struct addrmap_index_data): Likewise.
13273 (add_address_entry): Likewise.
13274 (add_address_entry_worker): Likewise.
13275 (write_address_map): Likewise.
13276 (symbol_kind): Likewise.
13277 (write_psymbols): Likewise.
13278 (struct signatured_type_index_data): Likewise.
13279 (write_one_signatured_type): Likewise.
13280 (recursively_count_psymbols): Likewise.
13281 (recursively_write_psymbols): Likewise.
13282 (class debug_names): Likewise.
13283 (check_dwarf64_offsets): Likewise.
13284 (psyms_seen_size): Likewise.
13285 (write_gdbindex): Likewise.
13286 (write_debug_names): Likewise.
13287 (assert_file_size): Likewise.
13288 (write_psymtabs_to_index): Likewise.
13289 (save_gdb_index_command): Likewise.
13290 (_initialize_dwarf2_read): Don't register the "save gdb-index"
13291 command.
13292 * dwarf2read.h: New file.
13293
13294 2018-03-27 Joel Brobecker <brobecker@adacore.com>
13295
13296 PR gdb/22670
13297 * dwarf2read.c (dwarf2_physname): Do not return the demangled
13298 symbol name if the CU's language stores symbol names in linkage
13299 format.
13300 * language.h (struct language_defn)
13301 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
13302 all instances of this struct.
13303
13304 2018-03-26 Tom Tromey <tom@tromey.com>
13305
13306 * stack.c (backtrace_command_1): Remove verbose code.
13307
13308 2018-03-26 Tom Tromey <tom@tromey.com>
13309
13310 * python/py-framefilter.c (py_print_type): Don't catch
13311 exceptions. Return void.
13312 (py_print_value): Likewise.
13313 (py_print_single_arg): Likewise.
13314 (enumerate_args): Don't catch exceptions.
13315 (py_print_args): Likewise.
13316 (py_print_frame): Likewise.
13317 (gdbpy_apply_frame_filter): Catch exceptions here.
13318
13319 2018-03-26 Tom Tromey <tom@tromey.com>
13320
13321 * stack.c (_initialize_stack): Remove trailing newlines from help
13322 text. Add "Usage" line to "backtrace" help.
13323
13324 2018-03-26 Tom Tromey <tom@tromey.com>
13325
13326 PR python/16486:
13327 * python/py-framefilter.c (py_print_args): Call wrap_hint.
13328
13329 2018-03-26 Tom Tromey <tom@tromey.com>
13330
13331 * python/py-framefilter.c (py_print_single_arg): Return
13332 EXT_LANG_BT_ERROR from catch.
13333
13334 2018-03-26 Tom Tromey <tom@tromey.com>
13335
13336 PR backtrace/15584:
13337 * stack.c (backtrace_command_1): Move some code into no-filters
13338 "if".
13339
13340 2018-03-26 Tom Tromey <tom@tromey.com>
13341
13342 * python/py-framefilter.c (throw_quit_or_print_exception): New
13343 function.
13344 (gdbpy_apply_frame_filter): Use it.
13345
13346 2018-03-26 Tom Tromey <tom@tromey.com>
13347
13348 PR cli/17716:
13349 * python/py-framefilter.c (py_print_type, py_print_value)
13350 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
13351 RETURN_MASK_ERROR.
13352
13353 2018-03-26 Tom Tromey <tom@tromey.com>
13354
13355 * python/py-framefilter.c (enumerate_args): Use
13356 gdb::unique_xmalloc_ptr.
13357
13358 2018-03-26 Tom Tromey <tom@tromey.com>
13359
13360 * python/py-framefilter.c (py_print_frame): Return
13361 EXT_LANG_BT_OK.
13362 (gdbpy_apply_frame_filter): Update comment.
13363 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
13364 Remove.
13365 <EXT_LANG_BT_NO_FILTERS>: Change value.
13366
13367 2018-03-26 Tom Tromey <tom@tromey.com>
13368
13369 PR backtrace/15582:
13370 * stack.c (backtrace_command): Parse "hide" argument.
13371 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
13372 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
13373 constant.
13374
13375 2018-03-26 Tom Tromey <tom@tromey.com>
13376
13377 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
13378 add "flags".
13379 (backtrace_command): Remove "fulltrace", add "flags".
13380
13381 2018-03-26 Tom Tromey <tom@tromey.com>
13382
13383 * stack.c (backtrace_command): Rewrite command line parsing.
13384
13385 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
13386
13387 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
13388
13389 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
13390
13391 * filename-seen-cache.h: Add include guard.
13392
13393 2018-03-26 Keith Seitz <keiths@redhat.com>
13394
13395 * symfile.c (place_section): Remove "struct" from section_addr_info
13396 in comment.
13397 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
13398 "struct" keyword from section_addr_info.
13399
13400 2018-03-26 Alan Hayward <alan.hayward@arm.com>
13401
13402 * regformats/regdef.h (reg): Add constructors.
13403
13404 2018-03-25 Pedro Alves <palves@redhat.com>
13405
13406 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
13407 if then/else bodies in var_func_name extraction.
13408
13409 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
13410
13411 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
13412 lookup_minimal_symbol() to find symbol entry.
13413 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
13414
13415 2018-03-23 Keith Seitz <keiths@redhat.com>
13416
13417 PR c++/22968
13418 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
13419 nested type definitions for C++, too.
13420
13421 2018-03-23 Tom Tromey <tom@tromey.com>
13422
13423 * machoread.c (struct oso_el): Add a constructor. Don't define as
13424 a typedef.
13425 (macho_register_oso): Remove.
13426 (macho_symtab_read): Take a std::vector.
13427 (oso_el_compare_name): Now a std::sort comparator.
13428 (macho_symfile_read_all_oso): Take a std::vector.
13429 (macho_symfile_read): Use std::vector. Remove cleanups.
13430
13431 2018-03-22 Tom Tromey <tom@tromey.com>
13432
13433 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
13434 (record_full_goto_bookmark): Use std::string.
13435
13436 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
13437
13438 PR tdep/18295
13439 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
13440 a single mask.
13441
13442 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
13443
13444 * rs6000-tdep.c (store_insn_p): New function.
13445 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
13446 and cr_reg to their unshifted values. Use store_insn_p to
13447 match LR saves using either R1 or fdata->alloca_reg. Use
13448 store_insn_p to match CR saves. Set alloca_reg_offset
13449 when alloca_reg and framep are set. Remove lr_reg shift
13450 when assigning to fdata->lr_register.
13451
13452 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
13453
13454 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
13455 command line args instead of emitting a warning.
13456
13457 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
13458
13459 * tracepoint.h (struct static_tracepoint_marker): Initialize
13460 fields, define default constructor, move constructor and move
13461 assignment, disable the rest.
13462 <str_id, extra>: Make std::string.
13463 (release_static_tracepoint_marker): Remove.
13464 (free_current_marker): Remove.
13465 * tracepoint.c (free_current_marker): Remove.
13466 (parse_static_tracepoint_marker_definition): Adjust to
13467 std::string, use new hex2str overload.
13468 (release_static_tracepoint_marker): Remove.
13469 (print_one_static_tracepoint_marker): Get marker by reference
13470 and adjust to std::string.
13471 (info_static_tracepoint_markers_command): Adjust to std::vector
13472 changes
13473 * target.h (static_tracepoint_marker_p): Remove typedef.
13474 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
13475 (struct target_ops) <to_static_tracepoint_marker_at>: Return
13476 bool.
13477 <to_static_tracepoint_markers_by_strid>: Return std::vector.
13478 * target-debug.h
13479 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
13480 (target_debug_print_std_vector_static_tracepoint_marker): New.
13481 (target_debug_print_struct_static_tracepoint_marker_p): Rename
13482 to...
13483 (target_debug_print_static_tracepoint_marker_p): ... this.
13484 * target-delegates.c: Re-generate.
13485 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
13486 Make std::string.
13487 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
13488 (decode_static_tracepoint_spec): Adjust to std::vector.
13489 (tracepoint_print_one_detail): Adjust to std::string.
13490 (strace_marker_decode_location): Adjust to std::string.
13491 (update_static_tracepoint): Adjust to std::string, remove call
13492 to release_static_tracepoint_marker.
13493 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
13494 Adjust to std::vector.
13495 * remote.c (remote_static_tracepoint_marker_at): Return bool.
13496 (remote_static_tracepoint_markers_by_strid): Adjust to
13497 std::vector.
13498 * common/rsp-low.h (hex2str): New overload with explicit count
13499 of bytes.
13500 * common/rsp-low.c (hex2str): New overload with explicit count
13501 of bytes.
13502 * unittests/rsp-low-selftests.c (test_hex2str): New function.
13503 (_initialize_rsp_low_selftests): Add test_hex2str test.
13504 * unittests/tracepoint-selftests.c
13505 (test_parse_static_tracepoint_marker_definition): Adjust to
13506 std::string.
13507
13508 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
13509
13510 * tracepoint.c (parse_static_tracepoint_marker_definition):
13511 Consider case where the definition is followed by more
13512 definitions.
13513 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13514 tracepoint-selftests.c.
13515 * unittests/tracepoint-selftests.c: New.
13516
13517 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
13518
13519 * MAINTAINERS (Write After Approval): Add Pedro Franco de
13520 Carvalho.
13521
13522 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
13523
13524 * symtab.c (find_pc_sect_line): fixed indentation.
13525
13526 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
13527
13528 * symtab.c (find_pc_sect_line): now uses binary search.
13529
13530 2018-03-19 Tom Tromey <tom@tromey.com>
13531
13532 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
13533 "IDENT" production.
13534
13535 2018-03-19 Pedro Alves <palves@redhat.com>
13536 Tom Tromey <tom@tromey.com>
13537
13538 * unittests/observable-selftests.c: New file.
13539 * common/observable.h: New file.
13540 * observable.h: New file.
13541 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
13542 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
13543 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
13544 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
13545 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
13546 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
13547 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
13548 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
13549 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
13550 python/py-breakpoint.c, python/py-finishbreakpoint.c,
13551 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
13552 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
13553 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
13554 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
13555 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
13556 tui/tui-interp.c, valops.c: Update all users.
13557 * tui/tui-hooks.c (tui_bp_created_observer)
13558 (tui_bp_deleted_observer, tui_bp_modified_observer)
13559 (tui_inferior_exit_observer, tui_before_prompt_observer)
13560 (tui_normal_stop_observer, tui_register_changed_observer):
13561 Remove.
13562 (tui_observers_token): New global.
13563 (attach_or_detach, tui_attach_detach_observers): New functions.
13564 (tui_install_hooks, tui_remove_hooks): Use
13565 tui_attach_detach_observers.
13566 * record-btrace.c (record_btrace_thread_observer): Remove.
13567 (record_btrace_thread_observer_token): New global.
13568 * observer.sh: Remove.
13569 * observer.c: Rename to observable.c.
13570 * observable.c (namespace gdb_observers): Define new objects.
13571 (observer_debug): Move into gdb_observers namespace.
13572 (struct observer, struct observer_list, xalloc_observer_list_node)
13573 (xfree_observer_list_node, generic_observer_attach)
13574 (generic_observer_detach, generic_observer_notify): Remove.
13575 (_initialize_observer): Update.
13576 Don't include observer.inc.
13577 * Makefile.in (generated_files): Remove observer.h, observer.inc.
13578 (clean mostlyclean): Likewise.
13579 (observer.h, observer.inc): Remove targets.
13580 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
13581 (COMMON_SFILES): Use observable.c, not observer.c.
13582 * .gitignore: Remove observer.h.
13583
13584 2018-03-18 Tom Tromey <tom@tromey.com>
13585
13586 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
13587 gdb::def_vector.
13588 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
13589
13590 2018-03-17 Tom Tromey <tom@tromey.com>
13591
13592 * auto-load.c (auto_load_objfile_script_1): Use std::string.
13593
13594 2018-03-17 Tom Tromey <tom@tromey.com>
13595
13596 * target.c (class scoped_target_fd): New.
13597 (target_fileio_close_cleanup): Remove.
13598 (target_fileio_read_alloc_1): Use scoped_target_fd.
13599
13600 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
13601
13602 * silent-rules.mk: New.
13603 * Makefile.in: Include silent-rules.mk
13604 (srcdir, VPATH, top_srcdir): Move up.
13605 (COMPILE): Add ECHO_CXX.
13606 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
13607 (init.c): Add ECHO_INIT_C.
13608 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
13609 (version.c): Add ECHO_GEN.
13610 (printcmd.o): Add ECHO_CXX.
13611 (target-float.o): Add ECHO_CXX.
13612 (ada-exp.o): Add ECHO_CXX.
13613 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
13614 (insight$(EXEEXT)): Add ECHO_CXXLD.
13615 * gnulib/configure.ac: Add AM_SILENT_RULES.
13616 * gnulib/aclocal.m4: Re-generate.
13617 * gnulib/configure: Re-generate.
13618 * gnulib/import/Makefile.in: Re-generate.
13619
13620 2018-03-16 Tom Tromey <tom@tromey.com>
13621
13622 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
13623 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
13624 * utils.c (do_free_section_addr_info)
13625 (make_cleanup_free_section_addr_info): Remove.
13626 * symfile.h (struct other_sections): Add constructor.
13627 (struct section_addr_info): Remove.
13628 (section_addr_info): New typedef.
13629 (struct sym_fns) <sym_offsets>: Change type of parameter.
13630 (build_section_addr_info_from_objfile)
13631 (relative_addr_info_to_section_offsets, addr_info_make_relative)
13632 (default_symfile_offsets, symbol_file_add)
13633 (symbol_file_add_from_bfd)
13634 (build_section_addr_info_from_section_table): Update.
13635 (alloc_section_addr_info, free_section_addr_info): Don't declare.
13636 * symfile.c (alloc_section_addr_info): Remove.
13637 (build_section_addr_info_from_section_table): Change return type.
13638 Update.
13639 (build_section_addr_info_from_bfd)
13640 (build_section_addr_info_from_objfile): Likewise.
13641 (free_section_addr_info): Remove.
13642 (relative_addr_info_to_section_offsets): Change type of "addrs".
13643 (addrs_section_compar): Now a std::sort comparator.
13644 (addrs_section_sort): Change return type.
13645 (addr_info_make_relative): Change type of "addrs". Update.
13646 (default_symfile_offsets, syms_from_objfile_1)
13647 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
13648 (symbol_file_add_separate): Update.
13649 (symbol_file_add): Change type of "addrs". Update.
13650 (add_symbol_file_command): Update. Remove cleanups.
13651 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
13652 cleanups.
13653 * symfile-debug.c (debug_sym_offsets): Change type of "info".
13654 * solib.c (solib_read_symbols): Update.
13655 * objfiles.c (objfile_relocate): Update. Remove cleanups.
13656 * machoread.c (macho_symfile_offsets): Update.
13657 * jit.c (jit_bfd_try_read_symtab): Update.
13658
13659 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
13660
13661 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13662 unittests/utils-selftests.c.
13663 * unittests/utils-selftests.c: New file.
13664
13665 2018-03-14 Tom Tromey <tom@tromey.com>
13666
13667 PR cli/14977:
13668 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
13669 for NULL.
13670
13671 2018-03-14 Tom Tromey <tom@tromey.com>
13672
13673 PR cli/19918:
13674 * printcmd.c (printf_pointer): Allow "-" in format.
13675
13676 2018-03-14 Tom Tromey <tom@tromey.com>
13677
13678 * printcmd.c (_initialize_printcmd): Add usage to printf.
13679
13680 2018-03-14 Yao Qi <qiyao@sourceware.org>
13681
13682 * MAINTAINERS: Update my email address.
13683
13684 2018-03-13 Tom Tromey <tom@tromey.com>
13685
13686 * machoread.c (macho_check_dsym): Change filenamep to a
13687 std::string*.
13688 (macho_symfile_read): Update.
13689 * symfile.c (load_command): Use std::string.
13690
13691 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
13692
13693 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
13694 to error message string.
13695 (riscv_register_name): Use xsnprintf instead of sprintf.
13696 (riscv_insn::fetch_instruction): Use gdb_assert instead of
13697 internal_error.
13698 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
13699 error.
13700 (riscv_push_dummy_call): Likewise.
13701
13702 2018-03-12 Tom Tromey <tom@tromey.com>
13703
13704 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
13705 Use gdb::byte_vector.
13706 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
13707
13708 2018-03-12 Yao Qi <yao.qi@linaro.org>
13709
13710 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
13711 parameter type to readable_regcache.
13712 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
13713 the declaration.
13714
13715 2018-03-11 Tom Tromey <tom@tromey.com>
13716
13717 * dwarf2read.c (struct nextfield): Add initializers.
13718 (struct nextfnfield): Remove.
13719 (struct fnfieldlist): Add initializers. Remove "length" and
13720 "head", use std::vector.
13721 (struct decl_field_list): Remove.
13722 (struct field_info): Add initializers.
13723 <fields, baseclasses>: Now std::vector.
13724 <nbaseclasses, nfnfields, typedef_field_list_count,
13725 nested_types_list_count>: Remove.
13726 (dwarf2_add_field, dwarf2_add_type_defn)
13727 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
13728 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
13729 (process_structure_scope): Update.
13730
13731 2018-03-11 Tom Tromey <tom@tromey.com>
13732
13733 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
13734 for use by std::sort.
13735 (build_type_psymtabs_1): Use std::vector.
13736
13737 2018-03-09 Eli Zaretskii <eliz@gnu.org>
13738
13739 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
13740 and LIBMPFR in the printed configuration.
13741
13742 2018-03-08 Tom Tromey <tom@tromey.com>
13743
13744 * source.c (get_filename_and_charpos): Use scoped_fd.
13745 * nto-procfs.c (procfs_open_1): Use scoped_fd.
13746 (procfs_pidlist): Likewise.
13747 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
13748 (iterate_over_mappings): Likewise.
13749
13750 2018-03-08 Tom Tromey <tom@tromey.com>
13751
13752 * infcall.c (struct call_return_meta_info)
13753 <stack_temporaries_enabled>: Remove.
13754 (get_call_return_value, call_function_by_hand_dummy): Update.
13755 * thread.c (disable_thread_stack_temporaries): Remove.
13756 (enable_thread_stack_temporaries): Remove.
13757 (thread_stack_temporaries_enabled_p): Return bool.
13758 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
13759 (get_last_thread_stack_temporary): Update.
13760 * eval.c (evaluate_subexp): Update.
13761 * gdbthread.h (class enable_thread_stack_temporaries): Now a
13762 class, not a function.
13763 (value_ptr, value_vec): Remove typedefs.
13764 (class thread_info) <stack_temporaries_enabled>: Now bool.
13765 <stack_temporaries>: Now a std::vector.
13766 (thread_stack_temporaries_enabled_p)
13767 (value_in_thread_stack_temporaries): Return bool.
13768
13769 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
13770
13771 * remote.c (putpkt_binary): Fix omitted bytes reporting.
13772 (getpkt_or_notif_sane_1): Likewise.
13773
13774 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
13775
13776 * build-id.c (build_id_to_debug_bfd): Use std::string.
13777
13778 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
13779
13780 * build-id.c (find_separate_debug_file_by_buildid): Return
13781 std::string.
13782 * build-id.h (find_separate_debug_file_by_buildid): Return
13783 std::string.
13784 * coffread.c (coff_symfile_read): Adjust to std::string.
13785 * elfread.c (elf_symfile_read): Adjust to std::string.
13786 * symfile.c (separate_debug_file_exists): Change parameter to
13787 std::string.
13788 (find_separate_debug_file): Return std::string.
13789 (find_separate_debug_file_by_debuglink): Return std::string.
13790 * symfile.h (find_separate_debug_file_by_debuglink): Return
13791 std::string.
13792
13793 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
13794
13795 * common/xml-utils.c (xml_escape_text): Move code to...
13796 (xml_escape_text_append): ... this new function.
13797 * common/xml-utils.h (xml_escape_text_append): New declaration.
13798 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
13799 New function.
13800 (_initialize_xml_utils): register test_xml_escape_text_append as
13801 a selftest.
13802
13803 2018-03-07 Alan Hayward <alan.hayward@arm.com>
13804
13805 * defs.h: Remove MAX_REGISTER_SIZE.
13806 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
13807 asserts.
13808 * python/py-unwind.c (pyuw_sniffer): Likewise.
13809
13810 2018-03-07 Tom Tromey <tom@tromey.com>
13811
13812 * linux-tdep.c (linux_info_proc): Update.
13813 * target.h (struct target_ops) <to_fileio_readlink>: Return
13814 optional<string>.
13815 (target_fileio_readlink): Return optional<string>.
13816 * remote.c (remote_hostio_readlink): Return optional<string>.
13817 * inf-child.c (inf_child_fileio_readlink): Return
13818 optional<string>.
13819 * target.c (target_fileio_readlink): Return optional<string>.
13820
13821 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
13822
13823 * regcache.c (cooked_read_test): Add riscv to the list of
13824 architectures that have a save_reggroup.
13825
13826 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
13827
13828 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
13829 value is not a dynamic class object.
13830
13831 2018-03-06 Tom Tromey <tom@tromey.com>
13832
13833 * rust-exp.y: Formatting fixes.
13834
13835 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
13836
13837 * riscv-tdep.c (riscv_register_name): Remove target description
13838 support.
13839 (riscv_gdbarch_init): Remove target description check.
13840
13841 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
13842
13843 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
13844 comment.
13845 * riscv-tdep.h: Likewise.
13846
13847 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
13848
13849 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
13850 (riscv_pseudo_register_write): Delete.
13851 (riscv_gdbarch_init): Remove all use of pseudo registers.
13852
13853 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
13854
13855 * record-btrace.c (btrace_print_lines): Replace cleanup
13856 parameter with RAII equivalents.
13857 (btrace_insn_history): Replace cleanup with RAII equivalents.
13858 * ui-out.h (make_cleanup_ui_out_list_begin_end,
13859 make_cleanup_ui_out_tuple_begin_end): Remove.
13860 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
13861 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
13862 make_cleanup_ui_out_list_begin_end): Remove.
13863
13864 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
13865
13866 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
13867 parameter types to std::vector. Use bool.
13868 (record_btrace_wait): Replace VEC(tp_t) with
13869 std::vector<thread_info *>.
13870 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
13871
13872 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
13873
13874 * record-btrace.c (record_btrace_disable_callback): Remove.
13875 (struct scoped_btrace_disable): New.
13876 (record_btrace_open): Use scoped_btrace_disable.
13877
13878 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
13879
13880 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
13881 reading values from registers.
13882
13883 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
13884
13885 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
13886 where appropriate.
13887
13888 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
13889
13890 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
13891 change parameter type. Use GDB's print functions, and use
13892 core_addr_to_string where appropriate.
13893 (riscv_push_dummy_call): Use core_addr_to_string where
13894 appropriate, update call to riscv_print_arg_location, and reindent
13895 a few lines.
13896 (riscv_return_value): Update call to riscv_print_arg_location.
13897
13898 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
13899 Tim Newsome <tim@sifive.com>
13900 Albert Ou <a0u@eecs.berkeley.edu>
13901 Darius Rad <darius@bluespec.com>
13902
13903 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
13904 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
13905 (ALLDEPFILES): Add riscv-tdep.c
13906 * configure.tgt: Add riscv support.
13907 * riscv-tdep.c: New file.
13908 * riscv-tdep.h: New file.
13909 * NEWS: Mention new target.
13910 * MAINTAINERS: Add entry for riscv.
13911
13912 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
13913
13914 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
13915 fields within aggregates.
13916
13917 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
13918
13919 * record-btrace.c (btrace_print_lines): Change type of flags to
13920 gdb_disassembly_flags.
13921
13922 2018-03-04 John Baldwin <jhb@FreeBSD.org>
13923
13924 * fbsd-nat.c: Include "inf-ptrace.h".
13925 (USE_SIGTRAP_SIGINFO): Conditionally define.
13926 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
13927 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
13928 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
13929 function.
13930 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
13931 Likewise.
13932 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
13933 Likewise.
13934 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
13935 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
13936 "supports_stopped_by_hw_breakpoint" target methods.
13937
13938 2018-03-04 John Baldwin <jhb@FreeBSD.org>
13939
13940 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
13941 * fbsd-nat.c (debug_fbsd_nat): New variable.
13942 (show_fbsd_nat_debug): New function.
13943 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
13944 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
13945
13946 2018-03-04 John Baldwin <jhb@FreeBSD.org>
13947
13948 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
13949 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
13950 prototype.
13951 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
13952 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
13953 method.
13954
13955 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
13956
13957 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
13958 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
13959
13960 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
13961
13962 * charset.c (struct charset_vector): New.
13963 (charsets): Change type to charset_vector.
13964 (find_charset_names): Adjust.
13965 (add_one): Adjust.
13966 (_initialize_charset): Adjust.
13967
13968 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
13969
13970 * progspace.h (struct program_space) <deleted_solibs>: Change
13971 type to std::vector<std::string>.
13972 * progspace.c (clear_program_space_solib_cache): Adjust.
13973 * breakpoint.c (print_solib_event): Adjust.
13974 (check_status_catch_solib): Adjust.
13975 * solib.c (update_solib_list): Adjust.
13976 * ui-out.h (class ui_out) <field_string>: New overload.
13977 * ui-out.c (ui_out::field_string): New overload.
13978
13979 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
13980
13981 * progspace.h (struct program_space): Add constructor and
13982 destructor, initialize fields.
13983 (add_program_space): Remove.
13984 * progspace.c (add_program_space): Rename to...
13985 (program_space::program_space): ... this.
13986 (release_program_space): Rename to...
13987 (program_space::~program_space): ... this.
13988 (delete_program_space): Use delete to delete program_space.
13989 (initialize_progspace): Use new to allocate program_space.
13990 * inferior.c (add_inferior_with_spaces): Likewise.
13991 (clone_inferior_command): Likewise.
13992 * infrun.c (follow_fork_inferior): Likewise.
13993 (handle_vfork_child_exec_or_exit): Likewise.
13994
13995 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
13996
13997 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
13998 (delim_string_to_char_ptr_vec): Return std::vector of
13999 gdb::unique_xmalloc_ptr.
14000 (dirnames_to_char_ptr_vec_append): Take std::vector of
14001 gdb::unique_xmalloc_ptr.
14002 (dirnames_to_char_ptr_vec): Return std::vector of
14003 gdb::unique_xmalloc_ptr.
14004 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
14005 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
14006 (delim_string_to_char_ptr_vec): Return an std::vector of
14007 gdb::unique_xmalloc_ptr, adjust the code.
14008 (dirnames_to_char_ptr_vec_append): Take an std::vector of
14009 gdb::unique_xmalloc_ptr, adjust the code.
14010 (dirnames_to_char_ptr_vec): Return an std::vector of
14011 gdb::unique_xmalloc_ptr, adjust the code.
14012 * auto-load.c (auto_load_safe_path_vec): Change type to
14013 std::vector of gdb::unique_xmalloc_ptr.
14014 (auto_load_expand_dir_vars): Return an std::vector of
14015 gdb::unique_xmalloc_ptr, adjust the code.
14016 (auto_load_safe_path_vec_update): Adjust.
14017 (filename_is_in_auto_load_safe_path_vec): Adjust.
14018 (auto_load_objfile_script_1): Adjust.
14019 * build-id.c (build_id_to_debug_bfd): Adjust.
14020 * linux-thread-db.c (thread_db_load_search): Adjust.
14021 * source.c (add_path): Adjust.
14022 (openp): Adjust.
14023 * symfile.c (find_separate_debug_file): Adjust.
14024 * utils.c (do_free_char_ptr_vec): Remove.
14025 (make_cleanup_free_char_ptr_vec): Remove.
14026
14027 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
14028
14029 PR gdb/22907
14030 * common/pathstuff.c: Conditionally include "<windows.h>".
14031
14032 2018-03-01 Georg Sauthoff <mail@georg.so>
14033
14034 PR gdb/22888
14035 * gcore.in: Quote variables and switch interpreter to bash.
14036
14037 2018-03-01 Tom Tromey <tom@tromey.com>
14038
14039 * dwarf2read.c (alloc_discriminant_info): Fix default_index
14040 assertion. Add assertion for discriminant_index.
14041 (quirk_rust_enum): Use correct base type name in univariant case.
14042
14043 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
14044
14045 * record.c (get_call_history_modifiers): Return a
14046 record_print_flags.
14047 (cmd_record_call_history): Adjust.
14048 * record-btrace.c (record_btrace_call_history): Adjust.
14049 (record_btrace_call_history_range): Adjust.
14050 (record_btrace_call_history_from): Adjust.
14051 * target-debug.h (target_debug_print_record_print_flags): New.
14052 * target-delegates.c: Re-generate.
14053 * target.c (target_call_history): Change flags type.
14054 (target_call_history_from): Likewise.
14055 (target_call_history_range): Likewise.
14056 * target.h (struct target_ops) <target_call_history>: Likewise.
14057 (target_call_history_from): Likewise.
14058 (target_call_history_range): Likewise.
14059
14060 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
14061 Simon Marchi <simon.marchi@polymtl.ca>
14062
14063 * common/common-utils.c: Include "sys/stat.h".
14064 (is_regular_file): Move here from "source.c"; change return
14065 type to "bool".
14066 * common/common-utils.h (is_regular_file): New prototype.
14067 * common/pathstuff.c (contains_dir_separator): New function.
14068 * common/pathstuff.h (contains_dir_separator): New prototype.
14069 * source.c: Don't include "sys/stat.h".
14070 (is_regular_file): Move to "common/common-utils.c".
14071
14072 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
14073
14074 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
14075 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
14076 * auto-load.c: Include "common/pathstuff.h".
14077 * common/common-def.h (current_directory): Move here.
14078 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
14079 function.
14080 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
14081 prototype.
14082 * common/pathstuff.c: New file.
14083 * common/pathstuff.h: New file.
14084 * compile/compile.c: Include "common/pathstuff.h".
14085 * defs.h (current_directory): Move to "common/common-defs.h".
14086 * dwarf2read.c: Include "common/pathstuff.h".
14087 * exec.c: Likewise.
14088 * guile/scm-safe-call.c: Likewise.
14089 * linux-thread-db.c: Likewise.
14090 * main.c: Likewise.
14091 * nto-tdep.c: Likewise.
14092 * objfiles.c: Likewise.
14093 * source.c: Likewise.
14094 * symtab.c: Likewise.
14095 * utils.c: Include "common/pathstuff.h".
14096 (gdb_realpath): Move to "common/pathstuff.c".
14097 (gdb_realpath_keepfile): Likewise.
14098 (gdb_abspath): Likewise.
14099 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
14100 (gdb_realpath_keepfile): Likewise.
14101 (gdb_abspath): Likewise.
14102
14103 2018-02-28 John Baldwin <jhb@FreeBSD.org>
14104
14105 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
14106 wildcard process pid for super_resume for kernels with a
14107 specific bug.
14108
14109 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
14110
14111 * compile/compile.c (get_args): Add additional comments
14112 explaining function.
14113
14114 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
14115 Tom Tromey <tom@tromey.com>
14116
14117 * target.h (memory_write_request_s): Remove typedef. Don't define
14118 VEC.
14119 (target_write_memory_blocks): Change argument to std::vector.
14120 (struct memory_write_request): Add constructor.
14121 * target-memory.c (compare_block_starting_address): Return bool.
14122 Change argument types.
14123 (claim_memory): Change arguments to use std::vector.
14124 (split_regular_and_flash_blocks, blocks_to_erase)
14125 (compute_garbled_blocks): Likewise.
14126 (cleanup_request_data, cleanup_write_requests_vector): Remove.
14127 (target_write_memory_blocks): Change argument to std::vector.
14128 * symfile.c (struct load_section_data): Add constructor and
14129 destructor. Use std::vector for "requests".
14130 (struct load_progress_data): Add initializers.
14131 (load_section_callback): Update. Use "new".
14132 (clear_memory_write_data): Remove.
14133 (generic_load): Update.
14134
14135 2018-02-27 Alan Hayward <alan.hayward@arm.com>
14136
14137 * arch/aarch64.h: Use common/tdesc.h.
14138
14139 2018-02-26 Maciej W. Rozycki <macro@mips.com>
14140
14141 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
14142 architecture with a 64-bit ABI.
14143
14144 2018-02-26 Maciej W. Rozycki <macro@mips.com>
14145
14146 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
14147 ahead of target description loading.
14148
14149 2018-02-26 Tom Tromey <tom@tromey.com>
14150
14151 * stack.c (backtrace_command_1): Update.
14152 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
14153 of "flags".
14154 * python/py-framefilter.c (py_print_frame)
14155 (gdbpy_apply_frame_filter): Change type of "flags".
14156 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
14157 of "flags".
14158 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
14159 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
14160 * extension.h (enum frame_filter_flag): Rename from
14161 frame_filter_flags.
14162 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
14163 (apply_ext_lang_frame_filter): Change type of "flags".
14164 * extension.c (apply_ext_lang_frame_filter): Change type of
14165 "flags".
14166 * extension-priv.h (struct extension_language_ops)
14167 <apply_frame_filter>: Change type of "flags".
14168
14169 2018-02-26 Tom Tromey <tom@tromey.com>
14170
14171 PR python/16497:
14172 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
14173 off-by-one in py_end computation.
14174 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
14175 PRINT_MORE_FRAMES.
14176 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
14177 constant.
14178
14179 2018-02-26 Tom Tromey <tom@tromey.com>
14180
14181 * dwarf2read.c (struct variant_field): New.
14182 (struct nextfield) <variant>: New field.
14183 (dwarf2_add_field): Handle DW_TAG_variant_part.
14184 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
14185 discriminated union.
14186 (read_structure_type): Handle DW_TAG_variant_part.
14187 (handle_struct_member_die): New function, extracted from
14188 process_structure_scope. Handle DW_TAG_variant.
14189 (process_structure_scope): Handle discriminated unions. Call
14190 handle_struct_member_die.
14191
14192 2018-02-26 Tom Tromey <tom@tromey.com>
14193
14194 * rust-lang.h (rust_last_path_segment): Declare.
14195 * rust-lang.c (rust_last_path_segment): Now public. Change
14196 contract.
14197 (struct disr_info): Remove.
14198 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
14199 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
14200 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
14201 (rust_enum_p, rust_enum_variant): New function.
14202 (rust_underscore_fields): Remove "offset" parameter.
14203 (rust_print_enum): New function.
14204 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
14205 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
14206 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
14207 enums.
14208 (rust_internal_print_type): New function, from rust_print_type.
14209 Remove enum code.
14210 (rust_print_type): Call rust_internal_print_type.
14211 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
14212 Update enum handling.
14213 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
14214 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
14215 (rust_union_quirks): New functions.
14216 (process_full_comp_unit, process_full_type_unit): Call
14217 rust_union_quirks.
14218 (process_structure_scope): Update rust_unions if necessary.
14219
14220 2018-02-26 Tom Tromey <tom@tromey.com>
14221
14222 * value.h (value_union_variant): Declare.
14223 * valops.c (value_union_variant): New function.
14224 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
14225 (struct discriminant_info): New.
14226 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
14227 enumerator.
14228 (struct main_type) <flag_discriminated_union>: New field.
14229
14230 2018-02-26 Tom Tromey <tom@tromey.com>
14231
14232 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
14233 unittests/unpack-selftests.c.
14234 * unittests/unpack-selftests.c: New file.
14235 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
14236
14237 2018-02-26 Yao Qi <yao.qi@linaro.org>
14238
14239 * dwarf2read.c (struct partial_die_info) <read>: New method.
14240 (read_partial_die): Remove the declaration.
14241 (load_partial_dies): Update.
14242 (partial_die_info::partial_die_info):
14243 (read_partial_die): Change it to partial_die_info::read.
14244
14245 2018-02-26 Yao Qi <yao.qi@linaro.org>
14246
14247 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
14248 (fixup_partial_die): Remove declaration.
14249 (scan_partial_symbols): Update.
14250 (partial_die_parent_scope): Likewise.
14251 (partial_die_full_name): Likewise.
14252 (fixup_partial_die): Change it to partial_die_info::fixup.
14253
14254 2018-02-26 Yao Qi <yao.qi@linaro.org>
14255
14256 * dwarf2read.c (read_partial_die): Update the declaration.
14257 (load_partial_dies): Caller update.
14258 (read_partial_die): Remove one argument abbrev_len.
14259
14260 2018-02-26 Yao Qi <yao.qi@linaro.org>
14261
14262 * dwarf2read.c (struct partial_die_info): Add ctor, delete
14263 assignment operator.
14264 (load_partial_dies): Use ctor and copy ctor.
14265 (read_partial_die): Update.
14266 (dwarf2_cu::find_partial_die): Use ctor.
14267
14268 2018-02-26 Yao Qi <yao.qi@linaro.org>
14269
14270 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
14271 (find_partial_die_in_comp_unit): Change it to
14272 dwarf2_cu::find_partial_die.
14273 (find_partial_die): Update.
14274
14275 2018-02-26 Yao Qi <yao.qi@linaro.org>
14276
14277 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
14278 is NULL.
14279
14280 2018-02-26 Yao Qi <yao.qi@linaro.org>
14281
14282 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
14283
14284 2018-02-26 Alan Hayward <alan.hayward@arm.com>
14285
14286 * arch/amd64.h: Use common/tdesc.h.
14287 * arch/i386.c: Likewise.
14288 * arch/i386.h: Likewise.
14289 * arch/tic6x.c: Likewise.
14290 * arch/tdesc.h: Move file from here...
14291 * common/tdesc.h: ...to here.
14292 * features/aarch64-core.c: Regenerate.
14293 * features/aarch64-fpu.c: Regenerate.
14294 * features/i386/32bit-avx.c: Regenerate.
14295 * features/i386/32bit-avx512.c: Regenerate.
14296 * features/i386/32bit-core.c: Regenerate.
14297 * features/i386/32bit-linux.c: Regenerate.
14298 * features/i386/32bit-mpx.c: Regenerate.
14299 * features/i386/32bit-pkeys.c: Regenerate.
14300 * features/i386/32bit-sse.c: Regenerate.
14301 * features/i386/64bit-avx.c: Regenerate.
14302 * features/i386/64bit-avx512.c: Regenerate.
14303 * features/i386/64bit-core.c: Regenerate.
14304 * features/i386/64bit-linux.c: Regenerate.
14305 * features/i386/64bit-mpx.c: Regenerate.
14306 * features/i386/64bit-pkeys.c: Regenerate.
14307 * features/i386/64bit-segments.c: Regenerate.
14308 * features/i386/64bit-sse.c: Regenerate.
14309 * features/i386/x32-core.c: Regenerate.
14310 * features/tic6x-c6xp.c: Regenerate.
14311 * features/tic6x-core.c: Regenerate.
14312 * features/tic6x-gp.c: Regenerate.
14313 * target-descriptions.c: Use common/tdesc.h.
14314 * target-descriptions.h: Likewise.
14315
14316 2018-02-24 Tom Tromey <tom@tromey.com>
14317
14318 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
14319 (try_thread_db_load_from_dir, thread_db_load_search): Use
14320 std::string.
14321 (info_auto_load_libthread_db_compare): Return bool. Change
14322 argument types.
14323 (info_auto_load_libthread_db): Use std::vector, std::string.
14324 Remove cleanups.
14325
14326 2018-02-24 Tom Tromey <tom@tromey.com>
14327
14328 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
14329 std::string.
14330 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
14331 std::string*.
14332 * gdbarch.c: Rebuild.
14333 * gdbarch.h: Rebuild.
14334 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
14335 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
14336 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
14337 std::string*.
14338
14339 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
14340
14341 * gdbtypes.h (sect_offset): Change type to uint64_t.
14342 (sect_offset_str): New function.
14343 * dwarf2read.c (create_addrmap_from_aranges): Use
14344 sect_offset_str.
14345 (error_check_comp_unit_head): Likewise.
14346 (create_debug_type_hash_table): Likewise.
14347 (read_cutu_die_from_dwo): Likewise.
14348 (init_cutu_and_read_dies): Likewise.
14349 (init_cutu_and_read_dies_no_follow): Likewise.
14350 (process_psymtab_comp_unit_reader): Likewise.
14351 (partial_die_parent_scope): Likewise.
14352 (peek_die_abbrev): Likewise.
14353 (process_queue): Likewise.
14354 (dwarf2_physname): Likewise.
14355 (read_namespace_alias): Likewise.
14356 (read_import_statement): Likewise.
14357 (create_dwo_cu_reader): Likewise.
14358 (create_cus_hash_table): Likewise.
14359 (lookup_dwo_cutu): Likewise.
14360 (inherit_abstract_dies): Likewise.
14361 (read_func_scope): Likewise.
14362 (read_call_site_scope): Likewise.
14363 (dwarf2_add_member_fn): Likewise.
14364 (read_common_block): Likewise.
14365 (read_module_type): Likewise.
14366 (read_typedef): Likewise.
14367 (read_subrange_type): Likewise.
14368 (load_partial_dies): Likewise.
14369 (read_partial_die): Likewise.
14370 (find_partial_die): Likewise.
14371 (read_str_index): Likewise.
14372 (dwarf2_string_attr): Likewise.
14373 (build_error_marker_type): Likewise.
14374 (lookup_die_type): Likewise.
14375 (dump_die_shallow): Likewise.
14376 (follow_die_ref): Likewise.
14377 (dwarf2_fetch_die_loc_sect_off): Likewise.
14378 (dwarf2_fetch_constant_bytes): Likewise.
14379 (follow_die_sig): Likewise.
14380 (get_signatured_type): Likewise.
14381 (get_DW_AT_signature_type): Likewise.
14382 (dwarf2_find_containing_comp_unit): Likewise.
14383 (set_die_type): Likewise.
14384
14385 2018-02-21 John Baldwin <jhb@FreeBSD.org>
14386
14387 * arch/aarch64.c: Include "common-defs.h".
14388 * arch/amd64.c: Likewise.
14389 * arch/i386.c: Likewise.
14390
14391 2018-02-21 Tom Tromey <tom@tromey.com>
14392
14393 * value.h: (extract_field_op): Update.
14394 * eval.c (extract_field_op): Return a const char *.
14395 * expression.h (parse_expression_for_completion): Update.
14396 * completer.c (complete_expression): Update.
14397 (add_struct_fields): Make fieldname const.
14398 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
14399 (mark_completion_tag, parse_exp_in_context_1): Update.
14400 (parse_expression_for_completion): Change "name" to
14401 unique_xmalloc_ptr*.
14402
14403 2018-02-21 Tom Tromey <tom@tromey.com>
14404
14405 * infcall.c (call_function_by_hand_dummy): Use std::vector.
14406
14407 2018-02-21 Yao Qi <yao.qi@linaro.org>
14408
14409 * avr-tdep.c (avr_read_pc): Change parameter type to
14410 readable_regcache.
14411 * gdbarch.sh (read_pc): Likewise.
14412 * gdbarch.c: Re-generated.
14413 * gdbarch.h: Re-generated.
14414 * hppa-tdep.c (hppa_read_pc): Change parameter type to
14415 readable_regcache.
14416 * ia64-tdep.c (ia64_read_pc): Likewise.
14417 * mips-tdep.c (mips_read_pc): Likewise.
14418 * spu-tdep.c (spu_read_pc): Likewise.
14419
14420 2018-02-21 Yao Qi <yao.qi@linaro.org>
14421
14422 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
14423 * regcache-dump.c: New file.
14424 * regcache.c: Move register_dump to regcache-dump.c.
14425 (maintenance_print_registers): Likewise.
14426 (maintenance_print_raw_registers): Likewise.
14427 (maintenance_print_cooked_registers): Likewise.
14428 (maintenance_print_register_groups): Likewise.
14429 (maintenance_print_remote_registers): Likewise.
14430 (_initialize_regcache): Likewise.
14431 * regcache.h (register_dump): Moved from regcache.c.
14432
14433 2018-02-21 Yao Qi <yao.qi@linaro.org>
14434
14435 * regcache.c (regcache::regcache): Update.
14436 (regcache::invalidate): Move it to detached_regcache::invalidate.
14437 (get_thread_arch_aspace_regcache): Update.
14438 (regcache::raw_update): Update.
14439 (regcache::cooked_read): Remove some code.
14440 (regcache::cooked_read_value): Likewise.
14441 (regcache::raw_write): Remove assert on m_readonly_p.
14442 (regcache::raw_supply_integer): Move it to
14443 detached_regcache::raw_supply_integer.
14444 (regcache::raw_supply_zeroed): Likewise.
14445 * regcache.h (detached_regcache) <raw_supply_integer>: New
14446 declaration.
14447 <raw_supply_zeroed, invalidate>: Likewise.
14448 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
14449 <invalidate>: Likewise.
14450 <m_readonly_p>: Removed.
14451
14452 2018-02-21 Yao Qi <yao.qi@linaro.org>
14453
14454 * infcmd.c (get_return_value): Let stop_regs point to
14455 get_current_regcache.
14456 * regcache.c (regcache::regcache): Remove.
14457 (register_dump_reg_buffer): New class.
14458 (regcache_print): Adjust.
14459 * regcache.h (regcache): Remove constructors.
14460
14461 2018-02-21 Yao Qi <yao.qi@linaro.org>
14462
14463 * regcache.c (class register_dump): New class.
14464 (register_dump_regcache, register_dump_none): New class.
14465 (register_dump_remote, register_dump_groups): New class.
14466 (regcache_print): Update.
14467 * regcache.h (regcache_dump_what): Move it to regcache.c.
14468 (regcache) <dump>: Remove.
14469
14470 2018-02-21 Yao Qi <yao.qi@linaro.org>
14471
14472 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
14473 reg_buffer_rw *.
14474 (jit_unwind_reg_set_impl): Call raw_supply.
14475 (jit_frame_sniffer): Use reg_buffer_rw.
14476 * record-full.c (record_full_core_regbuf): Change its type.
14477 (record_full_core_open_1): Use reg_buffer_rw.
14478 (record_full_close): Likewise.
14479 (record_full_core_fetch_registers): Use regcache->raw_supply.
14480 (record_full_core_store_registers): Likewise.
14481 * regcache.c (regcache::get_register_status): Move it to
14482 reg_buffer.
14483 (regcache_raw_set_cached_value): Remove.
14484 (regcache::raw_set_cached_value): Remove.
14485 (regcache::raw_write): Call raw_supply.
14486 (regcache::raw_supply): Move it to reg_buffer_rw.
14487 * regcache.h (regcache_raw_set_cached_value): Remove.
14488 (reg_buffer_rw): New class.
14489
14490 2018-02-21 Yao Qi <yao.qi@linaro.org>
14491
14492 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
14493 readonly_detached_regcache.
14494 (dummy_frame_prev_register): Use regcache->cooked_read.
14495 * frame.c (frame_save_as_regcache): Change return type.
14496 (frame_pop): Update.
14497 * frame.h (frame_save_as_regcache): Update declaration.
14498 * inferior.h (get_infcall_suspend_state_regcache): Update
14499 declaration.
14500 * infrun.c (infcall_suspend_state) <registers>: use
14501 readonly_detached_regcache.
14502 (save_infcall_suspend_state): Don't use regcache_dup.
14503 (get_infcall_suspend_state_regcache): Change return type.
14504 * linux-fork.c (struct fork_info) <savedregs>: Change to
14505 readonly_detached_regcache.
14506 <pc>: New field.
14507 (fork_save_infrun_state): Don't use regcache_dup.
14508 (info_checkpoints_command): Adjust.
14509 * mi/mi-main.c (register_changed_p): Update declaration.
14510 (mi_cmd_data_list_changed_registers): Use
14511 readonly_detached_regcache.
14512 (register_changed_p): Change parameter type to
14513 readonly_detached_regcache.
14514 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
14515 readonly_detached_regcache.
14516 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
14517 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
14518 New.
14519 (regcache::save): Move it to reg_buffer.
14520 (regcache::restore): Change parameter type.
14521 (regcache_dup): Remove.
14522 * regcache.h (reg_buffer) <save>: New method.
14523 (readonly_detached_regcache): New class.
14524 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
14525 readonly_detached_regcache.
14526 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
14527
14528 2018-02-21 Yao Qi <yao.qi@linaro.org>
14529
14530 * frame.c (frame_save_as_regcache): Use regcache method save.
14531 (frame_pop): Use regcache method restore.
14532 * infrun.c (restore_infcall_suspend_state): Likewise.
14533 * linux-fork.c (fork_load_infrun_state): Likewise.
14534 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
14535 save.
14536 * regcache.c (regcache_save): Remove.
14537 (regcache::restore): More asserts.
14538 (regcache_cpy): Remove.
14539 * regcache.h (regcache_save): Remove the declaration.
14540 (regcache::restore): Move from private to public.
14541 Remove the friend declaration of regcache_cpy.
14542 (regcache_cpy): Remove declaration.
14543
14544 2018-02-21 Yao Qi <yao.qi@linaro.org>
14545
14546 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
14547 parameter type to 'readable_regcache *'.
14548 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
14549 * arm-tdep.c (arm_neon_quad_read): Likewise.
14550 (arm_pseudo_read): Likewise.
14551 * avr-tdep.c (avr_pseudo_register_read): Likewise.
14552 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
14553 * frv-tdep.c (frv_pseudo_register_read): Likewise.
14554 * gdbarch.c: Re-generated.
14555 * gdbarch.h: Re-generated.
14556 * gdbarch.sh (pseudo_register_read): Change parameter type to
14557 'readable_regcache *'.
14558 (pseudo_register_read_value): Likewise.
14559 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
14560 (h8300_pseudo_register_read): Likewise.
14561 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
14562 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
14563 (i386_pseudo_register_read_into_value): Likewise.
14564 (i386_pseudo_register_read_value): Likewise.
14565 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
14566 declaration.
14567 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
14568 * m32c-tdep.c (m32c_raw_read): Likewise.
14569 (m32c_read_flg): Likewise.
14570 (m32c_banked_register): Likewise.
14571 (m32c_banked_read): Likewise.
14572 (m32c_sb_read): Likewise.
14573 (m32c_part_read): Likewise.
14574 (m32c_cat_read): Likewise.
14575 (m32c_r3r2r1r0_read): Likewise.
14576 (m32c_pseudo_register_read): Likewise.
14577 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
14578 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
14579 (mep_pseudo_cr64_read): Likewise.
14580 (mep_pseudo_register_read): Likewise.
14581 * mips-tdep.c (mips_pseudo_register_read): Likewise.
14582 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
14583 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
14584 * regcache.c (regcache::raw_read): Move it to readable_regcache.
14585 (regcache::cooked_read): Likewise.
14586 (regcache::cooked_read_value): Likewise.
14587 (regcache_cooked_read_signed):
14588 (regcache::cooked_read): Likewise.
14589 * regcache.h (readable_regcache): New class.
14590 (regcache): Inherit readable_regcache. Move some methods to
14591 readable_regcache.
14592 * rl78-tdep.c (rl78_pseudo_register_read): Change
14593 parameter type to 'readable_regcache *'.
14594 * rs6000-tdep.c (do_regcache_raw_read): Remove.
14595 (e500_pseudo_register_read): Change parameter type to
14596 'readable_regcache *'.
14597 (dfp_pseudo_register_read): Likewise.
14598 (vsx_pseudo_register_read): Likewise.
14599 (efpr_pseudo_register_read): Likewise.
14600 * s390-tdep.c (s390_pseudo_register_read): Likewise.
14601 * sh-tdep.c (sh_pseudo_register_read): Likewise.
14602 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
14603 (sh64_pseudo_register_read): Likewise.
14604 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
14605 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
14606 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
14607 (spu_pseudo_register_read): Likewise.
14608 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
14609 (xtensa_pseudo_register_read): Likewise.
14610
14611 2018-02-21 Yao Qi <yao.qi@linaro.org>
14612
14613 * regcache.c (regcache::regcache): Call reg_buffer ctor.
14614 (regcache::arch): Move it to reg_buffer::arch.
14615 (regcache::register_buffer): Likewise.
14616 (regcache::assert_regnum): Likewise.
14617 (regcache::num_raw_registers): Likewise.
14618 * regcache.h (reg_buffer): New class.
14619 (regcache): Inherit reg_buffer.
14620
14621 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
14622
14623 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
14624 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
14625
14626 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
14627
14628 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
14629
14630 2018-02-19 Alan Hayward <alan.hayward@arm.com>
14631
14632 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
14633 (SFILES): Remove common/*.c files.
14634 (COMMON_OBS): Remove some *.o files built from common/*.c files.
14635 * common/common.host: Add common reference.
14636 * configure.ac: Likewise.
14637 * configure: Regenerate.
14638
14639 2018-02-16 Yao Qi <yao.qi@linaro.org>
14640
14641 * block.c (block_namespace_info): Inherit allocate_on_obstack.
14642 (block_initialize_namespace): Use new.
14643 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
14644 (dwarf2_free_objfile): Use delete.
14645 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
14646 (copy_type_recursive): Use new.
14647 * gdb_obstack.h (allocate_on_obstack): New.
14648
14649 2018-02-15 Yao Qi <yao.qi@linaro.org>
14650
14651 PR gdb/22849
14652 * inferior.c (exit_inferior_1): Reset inf->control.
14653
14654 2018-02-15 Joel Brobecker <brobecker@adacore.com>
14655
14656 * ada-lang.c (ada_to_fixed_value_create): Delete advance
14657 declaration.
14658
14659 2018-02-14 Pedro Alves <palves@redhat.com>
14660
14661 * frame-unwind.c (frame_unwind_try_unwinder): Always call
14662 frame_cleanup_after_sniffer on exception.
14663
14664 2018-02-14 Tom Tromey <tom@tromey.com>
14665
14666 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
14667 const.
14668 (solib_bfd_open): Make pathname const.
14669 * solib.c (solib_bfd_open): Make pathname const.
14670 * solib-spu.c (spu_bfd_fopen): Make name const.
14671 (spu_bfd_open): Make pathname const.
14672 * solib-darwin.c (darwin_bfd_open): Make pathname const.
14673 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
14674
14675 2018-02-14 Tom Tromey <tom@tromey.com>
14676
14677 * symfile.c (symfile_bfd_open): Update.
14678 * source.h (openp, source_full_path_of, find_and_open_source):
14679 Change argument type to unique_xmalloc_ptr.
14680 * source.c (openp): Take a unique_xmalloc_ptr.
14681 (source_full_path_of, find_and_open_source): Likewise.
14682 (open_source_file, symtab_to_fullname): Update.
14683 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
14684 unique_xmalloc_ptr.
14685 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
14686 (exec_file_find): Update.
14687 * psymtab.c (psymtab_to_fullname): Update.
14688 * nto-tdep.h (nto_find_and_open_solib): Update.
14689 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
14690 unique_xmalloc_ptr.
14691 * exec.c (exec_file_attach): Update.
14692 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
14693 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
14694
14695 2018-02-14 Tom Tromey <tom@tromey.com>
14696
14697 * solib.c: Include source.h.
14698 * nto-tdep.c: Include source.h.
14699 * mi/mi-cmd-env.c: Include source.h.
14700 * infcmd.c: Include source.h.
14701 * exec.c: Include source.h.
14702 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
14703 (add_path, directory_switch, source_path, init_source_path): Move
14704 declarations...
14705 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
14706 (add_path, directory_switch, source_path, init_source_path):
14707 ...here.
14708
14709 2018-02-14 Tom Tromey <tom@tromey.com>
14710
14711 * solist.h (exec_file_find, solib_find): Return
14712 unique_xmalloc_ptr.
14713 (solib_bfd_fopen): Take a const char *.
14714 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
14715 (exec_file_find, solib_find): Likewise.
14716 (solib_bfd_fopen): Do not take ownership of "pathname".
14717 (solib_bfd_open): Use unique_xmalloc_ptr.
14718 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
14719 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
14720 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
14721 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
14722
14723 2018-02-14 Joel Brobecker <brobecker@adacore.com>
14724
14725 * ada-lang.c (name_match_type_from_name): Remove reference to
14726 ada_name_for_lookup in function's documentation.
14727 * ada-lang.h (ada_name_for_lookup): Delete declaration.
14728
14729 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
14730
14731 * defs.h (enum openp_flags): New enum.
14732 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
14733 Move to enum openp_flags.
14734 (openp_flags): New enum flags.
14735 (openp): Change parameter type to openp_flags.
14736 * source.c (openp): Change parameter type to openp_flags.
14737 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
14738 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
14739
14740 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
14741
14742 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
14743 per-command.
14744
14745 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
14746
14747 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
14748 into...
14749 (class dwarf2_queue_guard): ...the destructor of this new class.
14750 (dw2_do_instantiate_symtab): Create instance of the new class
14751 dwarf2_queue_guard, remove cleanup.
14752
14753 2018-02-09 Tom Tromey <tom@tromey.com>
14754
14755 * source.c (find_source_lines): Don't reference past the end of
14756 the vector.
14757
14758 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
14759
14760 * remote.c (remote_btrace_maybe_reopen): Change error message.
14761 * btrace.c (btrace_enable): Likewise.
14762 (parse_xml_btrace): Likewise.
14763 (parse_xml_btrace_conf): Likewise.
14764
14765 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
14766
14767 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
14768 (linux_enable_pt, linux_enable_bts): Call
14769 diagnose_perf_event_open_fail.
14770
14771 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
14772
14773 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
14774 Remove parameter and change return type. Update callers. Move it.
14775 (linux_enable_bts, linux_enable_pt): Improve error message.
14776 (linux_enable_pt): Remove zero buffer size check.
14777 (linux_enable_btrace): Improve error messages. Remove NULL return
14778 check.
14779
14780 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
14781
14782 * btrace.c (btrace_enable): Remove target_supports_btrace call.
14783 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
14784 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
14785 (linux_supports_pt, linux_supports_btrace): Remove.
14786 (linux_enable_bts): Call cpu_supports_bts.
14787 * nat/linux-btrace.h (linux_supports_btrace): Remove.
14788 * remote.c (remote_supports_btrace): Remove.
14789 (init_remote_ops): Remove remote_supports_btrace.
14790 * target-delegates.c: Regenerated.
14791 * target.c (target_supports_btrace): Remove.
14792 * target.h (target_ops) <to_supports_btrace>: Remove
14793 (target_supports_btrace): Remove.
14794 * x86-linux-nat.c (x86_linux_create_target): Remove
14795 linux_supports_btrace.
14796
14797 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
14798
14799 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
14800 btrace failed.
14801 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
14802 exception and use message in own exception.
14803
14804 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
14805
14806 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
14807 (perf_event_pt_event_type): Use gdb_file_up.
14808 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
14809 scoped_fd, and scoped_mmap.
14810
14811 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
14812
14813 * common/scoped_mmap.h: New.
14814 * unittests/scoped_mmap-selftest.c: New.
14815 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
14816 unittests/scoped_mmap-selftest.c.
14817
14818 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
14819
14820 * common/scoped_fd.h: New.
14821 * unittests/scoped_fd-selftest.c: New.
14822 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
14823 unittests/scoped_fd-selftest.c.
14824
14825 2018-02-09 Tom Tromey <tom@tromey.com>
14826
14827 * auto-load.c (auto_load_section_scripts): Use
14828 gdb::unique_xmalloc_ptr.
14829
14830 2018-02-09 Tom Tromey <tom@tromey.com>
14831
14832 * auto-load.c (execute_script_contents): Use std::string.
14833
14834 2018-02-09 Joel Brobecker <brobecker@adacore.com>
14835
14836 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
14837 Python function, rather than a new command.
14838
14839 2018-02-08 Tom Tromey <tom@tromey.com>
14840
14841 * solib.c (solib_find_1): Use std::string.
14842 (solib_bfd_fopen): Use unique_xmalloc_ptr.
14843
14844 2018-02-08 Tom Tromey <tom@tromey.com>
14845
14846 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
14847
14848 2018-02-08 Tom Tromey <tom@tromey.com>
14849
14850 * source.c (find_source_lines): Use gdb::def_vector.
14851
14852 2018-02-08 Tom Tromey <tom@tromey.com>
14853
14854 * macrocmd.c (struct temporary_macro_definition): New.
14855 (macro_define_command): Use temporary_macro_definition. Remove
14856 cleanups.
14857 (free_macro_definition_ptr): Remove.
14858
14859 2018-02-08 Tom Tromey <tom@tromey.com>
14860
14861 * macroexp.c (maybe_expand): Use std::string.
14862
14863 2018-02-08 Tom Tromey <tom@tromey.com>
14864
14865 * macroexp.c (struct macro_buffer): Add initializers for some
14866 members.
14867 (init_buffer, init_shared_buffer, free_buffer)
14868 (free_buffer_return_text): Remove.
14869 (macro_buffer): New constructors.
14870 (~macro_buffer): New destructor.
14871 (macro_buffer::set_shared): New method.
14872 (macro_buffer::resize_buffer, macro_buffer::appendc)
14873 (macro_buffer::appendmem): Now methods, not free functions.
14874 (set_token, append_tokens_without_splicing, stringify)
14875 (macro_stringify): Update.
14876 (gather_arguments): Change return type. Remove argc_p argument,
14877 add args_ptr argument. Use std::vector.
14878 (substitute_args): Remove argc argument. Accept std::vector.
14879 (expand): Update. Use std::vector.
14880 (scan, macro_expand, macro_expand_next): Update.
14881
14882 2018-02-08 Tom Tromey <tom@tromey.com>
14883
14884 * symtab.c (default_collect_symbol_completion_matches_break_on):
14885 Use unique_xmalloc_ptr.
14886 * macroscope.h: (sal_macro_scope, user_macro_scope)
14887 (default_macro_scope): Return unique_xmalloc_ptr.
14888 * macroscope.c (sal_macro_scope, user_macro_scope)
14889 (default_macro_scope): Return unique_xmalloc_ptr.
14890 * macroexp.h (macro_expand, macro_expand_once): Return
14891 unique_xmalloc_ptr.
14892 * macroexp.c (macro_expand, macro_expand_once): Return
14893 unique_xmalloc_ptr.
14894 * macrocmd.c (macro_expand_command, macro_expand_once_command)
14895 (info_macro_command, info_macros_command): Use
14896 unique_xmalloc_ptr.
14897 * compile/compile-c-support.c (write_macro_definitions): Use
14898 unique_xmalloc_ptr.
14899 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
14900
14901 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
14902
14903 * value.c (value_static_field): Assign field type instead of
14904 containing type when returning an optimized out value.
14905
14906 2018-02-06 Yao Qi <yao.qi@linaro.org>
14907
14908 * ft32-tdep.c (ft32_read_pc): Remove.
14909 (ft32_write_pc): Remove.
14910 (ft32_gdbarch_init): Update.
14911 * m32r-tdep.c (m32r_read_pc): Remove.
14912 (m32r_gdbarch_init): Update.
14913 * mep-tdep.c (mep_read_pc): Remove.
14914 (mep_gdbarch_init): Update.
14915 * microblaze-tdep.c (microblaze_write_pc): Remove.
14916 (microblaze_gdbarch_init): Update.
14917 * mn10300-tdep.c (mn10300_read_pc): Remove.
14918 (mn10300_write_pc): Remove.
14919 (mn10300_gdbarch_init): Update.
14920 * moxie-tdep.c (moxie_read_pc): Remove.
14921 (moxie_write_pc): Remove.
14922 (moxie_gdbarch_init): Update.
14923
14924 2018-02-06 Yao Qi <yao.qi@linaro.org>
14925
14926 * expprint.c (print_subexp_standard): Handle
14927 OP_F77_UNDETERMINED_ARGLIST.
14928 (dump_subexp_body_standard): Likewise.
14929
14930 2018-02-05 Alan Hayward <alan.hayward@arm.com>
14931
14932 * target-descriptions.c (tdesc_element_visitor) Add empty
14933 implementations.
14934 (tdesc_type): Move make_gdb_type from here.
14935 (tdesc_type_builtin): Likewise.
14936 (tdesc_type_vector): Likewise.
14937 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
14938 (make_gdb_type_struct): Move from tdesc_type_with_fields.
14939 (make_gdb_type_union): Likewise.
14940 (make_gdb_type_flags): Likewise.
14941 (make_gdb_type_enum): Likewise.
14942 (make_gdb_type): New function.
14943 (tdesc_register_type): Use static make_gdb_type.
14944
14945 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
14946
14947 * infcmd.c (default_print_one_register_info): Align natural-format
14948 column values consistently one under another.
14949 (pad_to_column): New function.
14950
14951 2018-02-05 Joel Brobecker <brobecker@adacore.com>
14952
14953 * dwarf2read.c (dwarf2_physname): Move commment.
14954
14955 2018-02-01 Leszek Swirski <leszeks@google.com>
14956
14957 * varobj.c (varobj_formatted_print_options): Allow recursive
14958 pretty printing if pretty printing is enabled.
14959
14960 2018-02-01 Leszek Swirski <leszeks@google.com>
14961
14962 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
14963 names after a structop as a filename.
14964
14965 2018-02-01 Yao Qi <yao.qi@linaro.org>
14966
14967 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
14968 (arm_record_coproc_data_proc): Likewise.
14969
14970 2018-02-01 Yao Qi <yao.qi@linaro.org>
14971
14972 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
14973
14974 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
14975
14976 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
14977 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
14978
14979 2018-01-31 Pedro Alves <palves@redhat.com>
14980
14981 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
14982 * inflow.c (child_terminal_save_inferior): Wrap reference to
14983 tcgetpgrp in HAVE_TERMIOS_H.
14984 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
14985 _WIN32.
14986 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
14987 always iterate over all inferiors.
14988 (gdbsim_cntrl_c): Adjust.
14989 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
14990
14991 2018-01-31 Joel Brobecker <brobecker@adacore.com>
14992
14993 * gdbtypes.c (lookup_array_range_type): Make sure the array's
14994 index type is objfile-owned if the element type is as well.
14995
14996 2018-01-31 Joel Brobecker <brobecker@adacore.com>
14997
14998 GDB 8.1 released.
14999
15000 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
15001
15002 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
15003 "features/s390x-linux64.c".
15004 (_initialize_s390_linux_tdep): Remove initialization of tdescs
15005 s390_linux32 and s390x_linux64.
15006 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
15007 default tdesc.
15008 * s390-tdep.c: Include "features/s390-linux32.c" and
15009 "features/s390x-linux64.c".
15010 (s390_tdesc_valid): Add check for tdesc_has_registers.
15011 (s390_gdbarch_init): Make sure there is always a valid tdesc.
15012 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
15013 tdesc_s390x_linux64.
15014 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
15015 tdesc_s390x_linux64 to...
15016 * s390-tdep.h: ...here.
15017
15018 2018-01-30 Pedro Alves <palves@redhat.com>
15019
15020 PR gdb/13211
15021 * config.in, configure: Regenerate.
15022 * configure.ac: Check for getpgid.
15023 * go32-nat.c (go32_pass_ctrlc): New.
15024 (go32_target): Install it.
15025 * inf-child.c (inf_child_target): Install
15026 child_terminal_save_inferior, child_pass_ctrlc and
15027 child_interrupt.
15028 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
15029 (inf_ptrace_target): No longer install it.
15030 * infcmd.c (interrupt_target_1): Adjust.
15031 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
15032 (child_interrupt): Declare.
15033 (inferior::terminal_state): New.
15034 * inflow.c (struct terminal_info): Update comments.
15035 (inferior_process_group): Delete.
15036 (terminal_is_ours): Delete.
15037 (gdb_tty_state): New.
15038 (child_terminal_init): Adjust.
15039 (is_gdb_terminal, sharing_input_terminal_1)
15040 (sharing_input_terminal): New functions.
15041 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
15042 Set the process's actual process group in the foreground if
15043 possible. Handle is_ours_for_output/is_ours distinction. Don't
15044 mark terminal as the inferior's if not sharing GDB's terminal.
15045 Don't check attach_flag.
15046 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
15047 pass down a target_terminal_state.
15048 (child_terminal_save_inferior): New, factored out from ...
15049 (child_terminal_ours_1): ... this. Handle
15050 target_terminal_state::is_ours_for_output.
15051 (child_interrupt, child_pass_ctrlc): New.
15052 (inflow_inferior_exit): Clear the inferior's terminal_state.
15053 (copy_terminal_info): Copy the inferior's terminal state.
15054 (_initialize_inflow): Remove reference to terminal_is_ours.
15055 * inflow.h (inferior_process_group): Delete.
15056 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
15057 * procfs.c (procfs_target): Don't install procfs_interrupt.
15058 (procfs_interrupt): Delete.
15059 * remote.c (remote_serial_quit_handler): Adjust.
15060 (remote_interrupt): Remove ptid parameter. Adjust.
15061 * target-delegates.c: Regenerate.
15062 * target.c: Include "terminal.h".
15063 (target_terminal::terminal_state): Rename to ...
15064 (target_terminal::m_terminal_state): ... this.
15065 (target_terminal::init): Adjust.
15066 (target_terminal::inferior): Adjust to per-inferior
15067 terminal_state.
15068 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
15069 (target_terminal::ours, target_terminal::ours_for_output): Use
15070 target_terminal_is_ours_kind.
15071 (target_interrupt): Remove ptid parameter. Adjust.
15072 (default_target_pass_ctrlc): Adjust.
15073 * target.h (target_ops::to_terminal_save_inferior): New field.
15074 (target_ops::to_interrupt): Remove ptid_t parameter.
15075 (target_interrupt): Remove ptid_t parameter. Update comment.
15076 (target_pass_ctrlc): Update comment.
15077 * target/target.h (target_terminal_state): New scoped enum,
15078 factored out of ...
15079 (target_terminal::terminal_state): ... here.
15080 (target_terminal::inferior): Update comments.
15081 (target_terminal::restore_inferior): New.
15082 (target_terminal::is_inferior, target_terminal::is_ours)
15083 (target_terminal::is_ours_for_output): Adjust.
15084 (target_terminal::scoped_restore_terminal_state): Adjust to
15085 rename, and call restore_inferior() instead of inferior().
15086 (target_terminal::scoped_restore_terminal_state::m_state): Change
15087 type.
15088 (target_terminal::terminal_state): Rename to ...
15089 (target_terminal::m_terminal_state): ... this and change type.
15090
15091 2018-01-30 Pedro Alves <palves@redhat.com>
15092
15093 * linux-nat.c (wait_for_signal): New function.
15094 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
15095 directly.
15096 (async_terminal_is_ours)
15097 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
15098 (linux_nat_add_target): Don't override
15099 to_terminal_inferior/to_terminal_ours.
15100
15101 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
15102
15103 * remote.c (remote_follow_fork): Don't call "detach_inferior".
15104
15105 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
15106
15107 * dwarf2read.c (free_dwo_files): Add forward-declaration.
15108 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
15109 dwarf2_per_objfile_free here.
15110 (dwarf2_per_objfile_free): Remove.
15111 (_initialize_dwarf2_read): Don't register
15112 dwarf2_per_objfile_free as a registry cleanup.
15113
15114 2018-01-27 Eli Zaretskii <eliz@gnu.org>
15115
15116 Avoid compilation errors in MinGW native builds
15117
15118 The error is triggered by including python-internal.h, and the
15119 error message is:
15120
15121 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
15122 from build-gnulib/import/math.h:27,
15123 from d:/usr/Python26/include/pyport.h:235,
15124 from d:/usr/Python26/include/Python.h:58,
15125 from python/python-internal.h:94,
15126 from python/py-arch.c:24:
15127 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
15128 using ::hypot;
15129 ^~~~~
15130
15131 This happens because Python headers define 'hypot' to expand t
15132 '_hypot' in the Windows builds.
15133 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
15134 'hypoth'. This avoids a compilation error.
15135
15136 2018-01-26 Alan Hayward <alan.hayward@arm.com>
15137
15138 * MAINTAINERS (Write After Approval): Fix ordering.
15139
15140 2018-01-26 Alan Hayward <alan.hayward@arm.com>
15141
15142 * MAINTAINERS (Write After Approval): Add Alan Hayward.
15143
15144 2018-01-26 Alan Modra <amodra@gmail.com>
15145
15146 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
15147 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
15148 Remove nop. Make const. Comment.
15149 (powerpc32_plt_stub_so_2): New.
15150 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
15151 Correct count. Update uses.
15152 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
15153 Move common code reading PLT entry word. Correct
15154 powerpc32_plt_stub PLT address calculation.
15155 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
15156 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
15157 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
15158 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
15159 (ppc64_standard_linkage8): Likewise.
15160 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
15161 Correct insns description.
15162 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
15163
15164 2018-01-24 Pedro Alves <palves@redhat.com>
15165
15166 GCC PR libstdc++/83906
15167 * gdbtypes.c (operator==(const dynamic_prop &,
15168 const dynamic_prop &)): New.
15169 (operator==(const range_bounds &, const range_bounds &)): New.
15170 (check_types_equal): Use them instead of memcmp.
15171 * gdbtypes.h (operator==(const dynamic_prop &,
15172 const dynamic_prop &)): Declare.
15173 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
15174 (operator==(const range_bounds &, const range_bounds &)): Declare.
15175 (operator!=(const range_bounds &, const range_bounds &)): Declare.
15176
15177 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15178
15179 * s390-linux-tdep.c (s390_record_address_mask)
15180 (s390_record_calc_disp_common, s390_record_calc_disp)
15181 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
15182 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
15183 (s390_process_record): Move to s390-tdep.c.
15184 (s390_linux_init_abi_any): Adjust.
15185 * s390-tdep.c (s390_record_address_mask)
15186 (s390_record_calc_disp_common, s390_record_calc_disp)
15187 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
15188 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
15189 (s390_process_record): Moved from s390-linux-tdep.c
15190 (s390_gdbarch_init): Adjust.
15191
15192 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15193
15194 * s390-linux-nat.c (s390-tdep.h): New include.
15195 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
15196 (HFILES_NO_SRCDIR): Add s390-tdep.h.
15197 (ALLDEPFILES): Add s390-tdep.c.
15198 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
15199 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
15200 * s390-tdep.h: ...this. New file.
15201 * s390-linux-tdep.c (s390-tdep.h): New include.
15202 (_initialize_s390_tdep): Rename to...
15203 (_initialize_s390_linux_tdep): ...this and adjust.
15204 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
15205 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
15206 s390-tdep.h.
15207 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
15208 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
15209 (s390_is_partial_instruction, s390_software_single_step)
15210 (is_non_branch_ril, s390_displaced_step_copy_insn)
15211 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
15212 (s390_prologue_data, s390_addr, s390_store, s390_load)
15213 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
15214 (s390_register_call_saved, s390_guess_tracepoint_registers)
15215 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
15216 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
15217 (s390_pseudo_register_name, s390_pseudo_register_type)
15218 (s390_pseudo_register_read, s390_pseudo_register_write)
15219 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
15220 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
15221 (s390_addr_bits_remove, s390_address_class_type_flags)
15222 (s390_address_class_type_flags_to_name)
15223 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
15224 (s390_function_arg_float, s390_function_arg_vector)
15225 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
15226 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
15227 (s390_frame_align, s390_register_return_value, s390_return_value)
15228 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
15229 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
15230 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
15231 (s390_trad_frame_prev_register, s390_unwind_cache)
15232 (s390_prologue_frame_unwind_cache)
15233 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
15234 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
15235 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
15236 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
15237 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
15238 (s390_frame_base_address, s390_local_base_address)
15239 (s390_frame_base, s390_gcc_target_options)
15240 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
15241 (s390_validate_reg_range, s390_tdesc_valid)
15242 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
15243 * s390-tdep.c: ...this. New file.
15244
15245 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15246
15247 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
15248 (s390_process_record, s390_gdbarch_tdep_alloc)
15249 (s390_linux_init_abi_any): Use/set new hook.
15250
15251 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15252
15253 * s390-linux-tdep.c (osabi.h): New include.
15254 (s390_linux_init_abi_31, s390_linux_init_abi_64)
15255 (s390_linux_init_abi_any): New functions.
15256 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
15257
15258 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15259
15260 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
15261 tdesc_has_registers check
15262
15263 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15264
15265 * s390-linux-tdep.c (s390_tdesc_valid): New function.
15266 (s390_validate_reg_range): New macro.
15267 (s390_gdbarch_init): Adjust.
15268
15269 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15270
15271 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
15272 (s390_gdbarch_tdep_alloc): Adjust.
15273 (s390_gdbarch_init): Adjust.
15274
15275 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15276
15277 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
15278 <have_tdb>: Change type to bool.
15279 (s390_gdbarch_tdep_alloc): Adjust.
15280 (s390_gdbarch_init): Adjust.
15281
15282 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15283
15284 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
15285 (gdbarch_tdep) <have_upper, have_vx>: New fields.
15286 (s390_gdbarch_tdep_alloc): New function.
15287 (s390_gdbarch_init): Allocate tdep at start and use its fields
15288 instead of separate variables.
15289
15290 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15291
15292 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
15293 when looking for cached gdbarch and add comment for remaining.
15294
15295 2018-01-22 Pedro Alves <palves@redhat.com>
15296 Sergio Durigan Junior <sergiodj@redhat.com>
15297
15298 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
15299 case.
15300
15301 2018-01-22 Maciej W. Rozycki <macro@mips.com>
15302
15303 * MAINTAINERS: Update my company e-mail address.
15304
15305 2018-01-22 Yao Qi <yao.qi@linaro.org>
15306
15307 * regcache.c (cooked_write_test): New function.
15308 (_initialize_regcache): Register the test.
15309
15310 2018-01-22 Yao Qi <yao.qi@linaro.org>
15311
15312 * ia64-tdep.c (ia64_pseudo_register_read): Call
15313 regcache->cooked_read instead of regcache_cooked_read_unsigned.
15314 * m32c-tdep.c (m32c_cat_read): Likewise.
15315 (m32c_r3r2r1r0_read): Likewise.
15316 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
15317 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
15318
15319 2018-01-22 Yao Qi <yao.qi@linaro.org>
15320
15321 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
15322 method raw_read instead of regcache_raw_read.
15323 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
15324 * arm-tdep.c (arm_neon_quad_read): Likewise.
15325 * avr-tdep.c (avr_pseudo_register_read): Likewise.
15326 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
15327 * frv-tdep.c (frv_pseudo_register_read): Likewise.
15328 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
15329 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
15330 (i386_pseudo_register_read_into_value): Likewise.
15331 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
15332 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
15333 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
15334 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
15335 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
15336 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
15337 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
15338 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
15339 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
15340
15341 2018-01-22 Yao Qi <yao.qi@linaro.org>
15342
15343 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
15344 * configure.tgt: Remove target mt.
15345 * mt-tdep.c: Remove.
15346 * regcache.c (cooked_read_test): Remove the check for mt.
15347
15348 2018-01-22 Yao Qi <yao.qi@linaro.org>
15349
15350 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
15351 instead of gdbarch_pseudo_register_read_value.
15352
15353 2018-01-22 Joel Brobecker <brobecker@adacore.com>
15354
15355 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
15356 language is Ada.
15357
15358 2018-01-22 Joel Brobecker <brobecker@adacore.com>
15359
15360 * linespec.c (create_sals_line_offset): Remove code that preserved
15361 the symtab_and_line's line number.
15362
15363 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
15364
15365 * varobj.c (varobj_create): Don't set valid_block when creating a
15366 floating varobj.
15367
15368 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
15369
15370 * varobj.c (varobj_create): Remove out of date comment.
15371
15372 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
15373
15374 PR mi/20395
15375 * ada-exp.y (write_var_from_sym): Pass extra parameter when
15376 updating innermost block.
15377 * parse.c (innermost_block_tracker::update): Take extra type
15378 parameter, and check types match before updating innermost block.
15379 (write_dollar_variable): Update innermost block for registers.
15380 * parser-defs.h (enum innermost_block_tracker_type): New enum.
15381 (innermost_block_tracker::innermost_block_tracker): Initialise
15382 m_types member.
15383 (innermost_block_tracker::reset): Take type parameter.
15384 (innermost_block_tracker::update): Take type parameter, and pass
15385 type through as needed.
15386 (innermost_block_tracker::m_types): New member.
15387 * varobj.c (varobj_create): Pass type when reseting innermost
15388 block.
15389
15390 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
15391
15392 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
15393 * ada-lang.c (resolve_subexp): Likewise.
15394 * breakpoint.c (set_breakpoint_condition) Likewise.
15395 (watch_command_1) Likewise.
15396 * c-exp.y (variable): Likewise.
15397 * d-exp.y (PrimaryExpression): Likewise.
15398 * f-exp.y (variable): Likewise.
15399 * go-exp.y (variable): Likewise.
15400 * m2-exp.y (variable): Likewise.
15401 * objfiles.c (objfile::~objfile): Likewise.
15402 * p-exp.y (variable): Likewise.
15403 * parse.c (innermost_block): Change type.
15404 * parser-defs.h (class innermost_block_tracker): New.
15405 (innermost_block): Change to innermost_block_tracker.
15406 * printcmd.c (display_command): Switch to innermost_block API.
15407 (do_one_display): Likewise.
15408 * rust-exp.y (do_one_display): Likewise.
15409 * symfile.c (clear_symtab_users): Likewise.
15410 * varobj.c (varobj_create): Switch to innermost_block API, replace
15411 use of innermost_block with block stored on varobj object.
15412
15413 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
15414
15415 * expression.h (innermost_block): Remove declaration.
15416 * varobj.c: Add 'parser-defs.h' include.
15417
15418 2018-01-19 Tom Tromey <tom@tromey.com>
15419
15420 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
15421 symbols in the static and global blocks.
15422
15423 2018-01-19 James Clarke <jrtc27@jrtc27.com>
15424
15425 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
15426 gdb_ptrace.h, and move including gdb_wait.h ...
15427 * nat/linux-ptrace.h: ... to here.
15428
15429 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
15430
15431 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
15432 inf_ptrace_detach_success.
15433 (inf_ptrace_detach_success): Add inferior parameter, use it
15434 instead of inferior_ptid, pass it to detach_inferior.
15435 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
15436 parameter.
15437 * inferior.c (detach_inferior): Add overload that takes an
15438 inferior object.
15439 * inferior.h (detach_inferior): Likewise.
15440 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
15441 use inferior_ptid, adjust call to inf_ptrace_detach_success.
15442 * linux-thread-db.c (thread_db_detach): Use inf parameter.
15443
15444 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
15445
15446 * target.h (struct target_ops) <to_detach>: Add inferior
15447 parameter.
15448 (target_detach): Likewise.
15449 * target.c (dispose_inferior): Pass inferior down.
15450 (target_detach): Pass inferior down. Assert that it is equal to
15451 the current inferior.
15452 * aix-thread.c (aix_thread_detach): Pass inferior down.
15453 * corefile.c (core_file_command): Pass current_inferior() down.
15454 * corelow.c (core_detach): Add inferior parameter.
15455 * darwin-nat.c (darwin_detach): Likewise.
15456 * gnu-nat.c (gnu_detach): Likewise.
15457 * inf-ptrace.c (inf_ptrace_detach): Likewise.
15458 * infcmd.c (detach_command): Pass current_inferior() down to
15459 target_detach.
15460 * infrun.c (follow_fork_inferior): Pass parent_inf to
15461 target_detach.
15462 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
15463 target_detach.
15464 * linux-nat.c (linux_nat_detach): Add inferior parameter.
15465 * linux-thread-db.c (thread_db_detach): Likewise.
15466 * nto-procfs.c (procfs_detach): Likewise.
15467 * procfs.c (procfs_detach): Likewise.
15468 * record.c (record_detach): Likewise.
15469 * record.h (struct inferior): Forward-declare.
15470 (record_detach): Add inferior parameter.
15471 * remote-sim.c (gdbsim_detach): Likewise.
15472 * remote.c (remote_detach_1): Likewise.
15473 (remote_detach): Likewise.
15474 (extended_remote_detach): Likewise.
15475 * sol-thread.c (sol_thread_detach): Likewise.
15476 * target-debug.h (target_debug_print_inferior_p): New macro.
15477 * target-delegates.c: Re-generate.
15478 * top.c (kill_or_detach): Pass inferior down to target_detach.
15479 * windows-nat.c (windows_detach): Add inferior parameter.
15480
15481 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
15482
15483 * target.h (struct target_ops) <to_detach>: Remove args
15484 parameter.
15485 (target_detach): Likewise.
15486 * target.c (dispose_inferior): Adjust.
15487 (target_detach): Remove args parameter, adjust.
15488 * aix-thread.c (aix_thread_detach): Adjust.
15489 * corefile.c (core_file_command): Adjust.
15490 * corelow.c (core_detach): Adjust.
15491 * darwin-nat.c (darwin_detach): Adjust.
15492 * gnu-nat.c (gnu_detach): Adjust.
15493 * inf-ptrace.c (inf_ptrace_detach): Adjust.
15494 * infcmd.c (detach_command): Adjust
15495 * infrun.c (follow_fork_inferior): Adjust.
15496 (handle_vfork_child_exec_or_exit): Adjust.
15497 * linux-fork.c (linux_fork_detach): Remove args parameter.
15498 * linux-fork.h (linux_fork_detach): Likewise.
15499 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
15500 * linux-thread-db.c (thread_db_detach): Likewise.
15501 * nto-procfs.c (procfs_detach): Likewise.
15502 * procfs.c (procfs_detach): Likewise.
15503 (do_detach): Remove signo parameter.
15504 * record.c (record_detach): Remove args parameter.
15505 * record.h (record_detach): Likewise.
15506 * remote-sim.c (gdbsim_detach): Likewise.
15507 * remote.c (remote_detach_1): Likewise.
15508 (remote_detach): Likewise.
15509 (extended_remote_detach): Likewise.
15510 * sol-thread.c (sol_thread_detach): Likewise.
15511 * target-delegates.c: Re-generate.
15512 * top.c (struct qt_args) <args>: Remove field.
15513 (kill_or_detach): Don't pass args.
15514 (quit_force): Don't set args.
15515 * windows-nat.c (windows_detach): Remove args parameter.
15516
15517 2018-01-19 Yao Qi <yao.qi@linaro.org>
15518
15519 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
15520 (arm_linux_init_abi): Install it.
15521
15522 2018-01-19 Yao Qi <yao.qi@linaro.org>
15523
15524 * osabi.c (gdb_osabi_names): Extend the regexp for
15525 arm-linux-gnueabihf.
15526
15527 2018-01-18 Yao Qi <yao.qi@linaro.org>
15528
15529 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
15530 m_abbrevs.
15531 (abbrev_table::add_abbrev): Update.
15532 (abbrev_table::lookup_abbrev): Update.
15533
15534 2018-01-18 Yao Qi <yao.qi@linaro.org>
15535
15536 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
15537
15538 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
15539
15540 * compile/compile.c (compile_to_object): Convert "triplet_rx"
15541 to "std::string".
15542
15543 2018-01-17 Tom Tromey <tom@tromey.com>
15544
15545 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
15546
15547 2018-01-17 Tom Tromey <tom@tromey.com>
15548
15549 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
15550 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
15551 (create_array_type_with_stride): Update.
15552 * dwarf2read.c (set_die_type): Update.
15553
15554 2018-01-17 Tom Tromey <tom@tromey.com>
15555
15556 * dwarf2read.c (delayed_method_info): Remove typedef.
15557 (dwarf2_cu::method_info): Now a std::vector.
15558 (add_to_method_list): Update.
15559 (free_delayed_list): Remove.
15560 (compute_delayed_physnames): Update.
15561 (process_full_comp_unit, process_full_type_unit): Clear the method
15562 list. Remove cleanups.
15563 (psymtab_include_file_name): Add name_holder parameter. Use
15564 unique_xmalloc_ptr.
15565 (dwarf_decode_lines): Update.
15566
15567 2018-01-17 Tom Tromey <tom@tromey.com>
15568 Simon Marchi <simon.marchi@ericsson.com>
15569
15570 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
15571 (dwarf2_per_objfile::free_cached_comp_units)
15572 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
15573 (init_cutu_and_read_dies_no_follow): Update.
15574 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
15575 (dwarf2_cu::~dwarf2_cu): New.
15576 (free_heap_comp_unit, free_stack_comp_unit): Remove.
15577 (age_cached_comp_units, free_one_cached_comp_unit): Update.
15578
15579 2018-01-17 Tom Tromey <tom@tromey.com>
15580 Simon Marchi <simon.marchi@ericsson.com>
15581
15582 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
15583 (struct die_reader_specs) <abbrev_table>: New member.
15584 (struct abbrev_table): Add constructor.
15585 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
15586 <abbrev_obstack>: Now an auto_obstack.
15587 (abbrev_table_up): New typedef.
15588 (init_cu_die_reader): Add abbrev_table parameter.
15589 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
15590 Add result_dwo_abbrev_table.
15591 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
15592 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
15593 Update.
15594 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
15595 parameter.
15596 (skip_children): Update.
15597 (abbrev_table::alloc_abbrev): Rename from
15598 abbrev_table_alloc_abbrev.
15599 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
15600 (abbrev_table::lookup_abbrev): Rename from
15601 abbrev_table_lookup_abbrev.
15602 (abbrev_table_read_table): Return abbrev_table_up.
15603 (abbrev_table_free, abbrev_table_free_cleanup)
15604 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
15605 (load_partial_dies): Update.
15606
15607 2018-01-17 Tom Tromey <tom@tromey.com>
15608
15609 * dwarf2read.c (dwarf2_compute_name): Update comment.
15610 (read_func_scope, read_variable): Update.
15611 (new_symbol): Remove.
15612 (new_symbol_full): Rename to new_symbol.
15613
15614 2018-01-17 Mike Gulick <mgulick@mathworks.com>
15615
15616 PR gdb/16577
15617 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
15618 a warning instead of throwing an error, set section size to 0 and return
15619 NULL.
15620 * gdb_bfd.h (gdb_bfd_map_section): Update description.
15621
15622 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
15623
15624 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
15625 std::string.
15626 (linux_ptrace_attach_fail_reason_string): Likewise.
15627 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
15628 Likewise.
15629 (linux_ptrace_attach_fail_reason_string): Likewise.
15630 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
15631
15632 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
15633
15634 * linux-nat.c (linux_nat_attach): Remove xstrdup.
15635
15636 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
15637
15638 PR gdb/21559
15639 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
15640 checking for fs_base/gs_base fields in struct user_regs_struct.
15641 * configure: Regenerate.
15642
15643 2018-01-17 Yao Qi <yao.qi@linaro.org>
15644
15645 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
15646 function.
15647 (aarch64_linux_init_abi): Install it to gdbarch hook
15648 gcc_target_options.
15649
15650 2018-01-15 Pedro Alves <palves@redhat.com>
15651
15652 * common/signals-state-save-restore.c
15653 (save_original_signals_state): Fix typos.
15654
15655 2017-01-12 Tom Tromey <tom@tromey.com>
15656 Sergio Durigan Junior <sergiodj@redhat.com>
15657
15658 * Makefile.in (install-only): Install gdb-add-index.
15659
15660 2018-01-12 John Baldwin <jhb@FreeBSD.org>
15661
15662 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
15663
15664 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
15665
15666 * infrun.c (keep_going_pass_signal): Clear step-over info when
15667 insert_breakpoints fails.
15668
15669 2018-01-11 Pedro Alves <palves@redhat.com>
15670
15671 PR gdb/22583
15672 * infrun.c (resume): Rename to ...
15673 (resume_1): ... this.
15674 (resume): Reimplement as wrapper around resume_1.
15675
15676 2018-01-11 Pedro Alves <palves@redhat.com>
15677
15678 PR remote/22597
15679 * remote.c (remote_parse_stop_reply): Default to the last-set
15680 general thread instead of to 'magic_null_ptid'.
15681
15682 2018-01-10 Pedro Alves <palves@redhat.com>
15683
15684 * language.h (language_get_symbol_name_matcher): Rename ...
15685 (get_symbol_name_matcher): ... this.
15686 * language.c (language_get_symbol_name_matcher): Ditto.
15687 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
15688 callers adjusted.
15689
15690 2018-01-10 Pedro Alves <palves@redhat.com>
15691
15692 PR gdb/22670
15693 * dwarf2read.c
15694 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
15695 Adjust to use language_get_symbol_name_matcher instead of
15696 language_defn::la_get_symbol_name_matcher.
15697 * language.c (language_get_symbol_name_matcher): If in Ada mode
15698 and the lookup name is a verbatim match, return Ada's matcher.
15699 * language.h (language_get_symbol_name_matcher): Adjust comment.
15700 (ada_lookup_name_info::verbatim_p):: New method.
15701
15702 2018-01-10 Pedro Alves <palves@redhat.com>
15703
15704 PR gdb/22670
15705 * ada-lang.c (ada_collect_symbol_completion_matches): If the
15706 minsym's language is language_auto or language_cplus, pass down
15707 language_ada instead.
15708 * symtab.c (compare_symbol_name): Don't frob symbol language here.
15709
15710 2018-01-10 Pedro Alves <palves@redhat.com>
15711
15712 PR gdb/22670
15713 * minsyms.c (linkage_name_str): New function.
15714 (iterate_over_minimal_symbols): Use it.
15715
15716 2018-01-09 John Baldwin <jhb@FreeBSD.org>
15717
15718 * NEWS: Document that 'info proc' now works on FreeBSD.
15719
15720 2018-01-09 John Baldwin <jhb@FreeBSD.org>
15721
15722 * configure.ac: Check for kinfo_getfile in libutil.
15723 * configure: Regenerate.
15724 * config.in: Regenerate.
15725 * fbsd-nat.c: Include "fbsd-tdep.h".
15726 (fbsd_fetch_cmdline): New.
15727 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
15728 rather than calling error.
15729 (fbsd_info_proc): New.
15730 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
15731 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
15732 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
15733
15734 2018-01-09 John Baldwin <jhb@FreeBSD.org>
15735
15736 * fbsd-nat.c (struct free_deleter): Remove.
15737 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
15738
15739 2018-01-09 John Baldwin <jhb@FreeBSD.org>
15740
15741 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
15742 NULL for an empty pathname.
15743
15744 2018-01-09 John Baldwin <jhb@FreeBSD.org>
15745
15746 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
15747 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
15748 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
15749 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
15750 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
15751 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
15752 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
15753 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
15754 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
15755 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
15756 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
15757 (fbsd_core_fetch_timeval, fbsd_print_sigset)
15758 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
15759 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
15760 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
15761
15762 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
15763
15764 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
15765 (gnu_xfer_auxv): New function.
15766 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
15767 TARGET_OBJECT_AUXV.
15768
15769 2018-01-08 Yao Qi <yao.qi@linaro.org>
15770 Simon Marchi <simon.marchi@ericsson.com>
15771
15772 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
15773 common/selftest.c.
15774 (COMMON_OBS): Remove selftest.o.
15775 * configure.ac: Append selftest-arch.c and common/selftest.c to
15776 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
15777 * configure: Re-generated.
15778 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
15779 GDB_SELF_TEST.
15780 (maintenance_info_selftests): Likewise.
15781
15782 2018-01-08 Xavier Roirand <roirand@adacore.com>
15783
15784 * ada-valprint.c (val_print_packed_array_elements): Use
15785 proper number of elements when printing an array indexed
15786 by an enumeration type.
15787
15788 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
15789
15790 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
15791 (dw2_get_file_names_reader): Adjust.
15792 (lookup_dwo_signatured_type): Adjust.
15793 (lookup_dwp_signatured_type): Adjust.
15794 (lookup_signatured_type): Adjust.
15795 (create_type_unit_group): Adjust.
15796 (get_type_unit_group): Adjust.
15797 (process_psymtab_comp_unit_reader): Adjust.
15798 (build_type_psymtabs_reader): Adjust.
15799 (scan_partial_symbols): Adjust.
15800 (add_partial_symbol): Adjust.
15801 (add_partial_subprogram): Adjust.
15802 (peek_die_abbrev): Adjust.
15803 (fixup_go_packaging): Adjust.
15804 (process_imported_unit_die): Adjust.
15805 (dwarf2_compute_name): Adjust.
15806 (dwarf2_physname): Adjust.
15807 (read_import_statement): Adjust.
15808 (handle_DW_AT_stmt_list): Adjust.
15809 (read_file_scope): Adjust.
15810 (read_func_scope): Adjust.
15811 (read_lexical_block_scope): Adjust.
15812 (read_call_site_scope): Adjust.
15813 (read_variable): Adjust.
15814 (dwarf2_rnglists_process): Adjust.
15815 (dwarf2_ranges_process): Adjust.
15816 (dwarf2_ranges_read): Adjust.
15817 (dwarf2_get_pc_bounds): Adjust.
15818 (dwarf2_record_block_ranges): Adjust.
15819 (dwarf2_add_field): Adjust.
15820 (dwarf2_add_member_fn): Adjust.
15821 (read_structure_type): Adjust.
15822 (process_structure_scope): Adjust.
15823 (read_enumeration_type): Adjust.
15824 (read_array_type): Adjust.
15825 (mark_common_block_symbol_computed): Adjust.
15826 (read_common_block): Adjust.
15827 (read_namespace_type): Adjust.
15828 (read_namespace): Adjust.
15829 (read_module_type): Adjust.
15830 (read_tag_pointer_type): Adjust.
15831 (read_tag_ptr_to_member_type): Adjust.
15832 (read_tag_string_type): Adjust.
15833 (read_subroutine_type): Adjust.
15834 (read_typedef): Adjust.
15835 (read_base_type): Adjust.
15836 (attr_to_dynamic_prop): Adjust.
15837 (read_subrange_type): Adjust.
15838 (read_unspecified_type): Adjust.
15839 (dwarf2_read_abbrevs): Adjust.
15840 (load_partial_dies): Adjust.
15841 (read_partial_die): Adjust.
15842 (find_partial_die): Adjust.
15843 (guess_partial_die_structure_name): Adjust.
15844 (fixup_partial_die): Adjust.
15845 (read_attribute_value): Adjust.
15846 (read_addr_index): Adjust.
15847 (read_addr_index_from_leb128): Adjust.
15848 (read_str_index): Adjust.
15849 (dwarf2_string_attr): Adjust.
15850 (get_debug_line_section): Adjust.
15851 (dwarf_decode_line_header): Adjust.
15852 (lnp_state_machine::check_line_address): Adjust.
15853 (dwarf_decode_lines_1): Adjust.
15854 (dwarf_decode_lines): Adjust.
15855 (dwarf2_start_symtab): Adjust.
15856 (var_decode_location): Adjust.
15857 (new_symbol_full): Adjust.
15858 (dwarf2_const_value_data): Adjust.
15859 (dwarf2_const_value_attr): Adjust.
15860 (dwarf2_const_value): Adjust.
15861 (die_type): Adjust.
15862 (die_containing_type): Adjust.
15863 (build_error_marker_type): Adjust.
15864 (lookup_die_type): Adjust.
15865 (guess_full_die_structure_name): Adjust.
15866 (anonymous_struct_prefix): Adjust.
15867 (determine_prefix): Adjust.
15868 (dwarf2_name): Adjust.
15869 (follow_die_ref_or_sig): Adjust.
15870 (follow_die_offset): Adjust.
15871 (follow_die_ref): Adjust.
15872 (follow_die_sig_1): Adjust.
15873 (follow_die_sig): Adjust.
15874 (get_signatured_type): Adjust.
15875 (get_DW_AT_signature_type): Adjust.
15876 (decode_locdesc): Adjust.
15877 (dwarf_decode_macros): Adjust.
15878 (cu_debug_loc_section): Adjust.
15879 (fill_in_loclist_baton): Adjust.
15880 (dwarf2_symbol_mark_computed): Adjust.
15881 (init_one_comp_unit): Don't assign
15882 dwarf2_cu::dwarf2_per_objfile.
15883 (set_die_type): Adjust.
15884
15885 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
15886
15887 * dwarf2read.c (struct mapped_debug_names): Add constructor.
15888 <dwarf2_per_objfile>: New field.
15889 (dwarf2_per_objfile): Remove global.
15890 (get_dwarf2_per_objfile): New function.
15891 (set_dwarf2_per_objfile): New function.
15892 (dwarf2_build_psymtabs_hard): Change objfile parameter to
15893 dwarf2_per_objfile.
15894 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
15895 (read_abbrev_offset): Likewise.
15896 (read_indirect_string): Likewise.
15897 (read_indirect_line_string): Likewise.
15898 (read_indirect_string_at_offset): Likewise.
15899 (read_indirect_string_from_dwz): Likewise.
15900 (dwarf2_find_containing_comp_unit): Change objfile parameter to
15901 dwarf2_per_objfile.
15902 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
15903 (create_all_comp_units): Change objfile parameter to
15904 dwarf2_per_objfile.
15905 (create_all_type_units): Likewise.
15906 (process_queue): Add dwarf2_per_objfile parameter.
15907 (read_and_check_comp_unit_head): Likewise.
15908 (lookup_dwo_unit_in_dwp): Likewise.
15909 (get_dwp_file): Likewise.
15910 (process_cu_includes): Likewise.
15911 (struct free_dwo_file_cleanup_data): New struct.
15912 (dwarf2_has_info): Use get_dwarf2_per_objfile and
15913 set_dwarf2_per_objfile.
15914 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
15915 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
15916 context, adjust calls.
15917 (dw2_instantiate_symtab): Likewise.
15918 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
15919 (dw2_get_cu): Likewise.
15920 (create_cu_from_index_list): Change objfile parameter to
15921 dwarf2_per_objfile.
15922 (create_cus_from_index_list): Get dwarf2_per_objfile from
15923 context, adjust calls.
15924 (create_cus_from_index): Likewise.
15925 (create_signatured_type_table_from_index): Change objfile
15926 parameter to dwarf2_per_objfile.
15927 (create_signatured_type_table_from_debug_names): Change objfile
15928 parameter to dwarf2_per_objfile.
15929 (create_addrmap_from_index): Likewise.
15930 (create_addrmap_from_aranges): Likewise.
15931 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
15932 (dw2_setup): Remove.
15933 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
15934 context.
15935 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
15936 get_dwarf2_per_objfile.
15937 (dw2_forget_cached_source_info): Likewise.
15938 (dw2_map_symtabs_matching_filename): Likewise.
15939 (struct dw2_symtab_iterator) <index>: Remove.
15940 <dwarf2_per_objfile>: New field.
15941 (dw2_symtab_iter_init): Replace index parameter with
15942 dwarf2_per_objfile.
15943 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
15944 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
15945 (dw2_print_stats): Likewise.
15946 (dw2_dump): Likewise.
15947 (dw2_expand_symtabs_for_function): Likewise.
15948 (dw2_expand_all_symtabs): Likewise.
15949 (dw2_expand_symtabs_with_fullname): Likewise.
15950 (dw2_expand_marked_cus): Replace index and objfile parameters
15951 with dwarf2_per_objfile.
15952 (dw_expand_symtabs_matching_file_matcher): Add
15953 dwarf2_per_objfile parameter and adjust calls.
15954 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
15955 adjust calls.
15956 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
15957 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
15958 adjust calls.
15959 (create_cus_from_debug_names_list): Replace objfile parameter
15960 with dwarf2_per_objfile and adjust calls.
15961 (create_cus_from_debug_names): Likewise.
15962 (dwarf2_read_debug_names): Likewise.
15963 (mapped_debug_names::namei_to_name): Adjust call.
15964 (dw2_debug_names_iterator::next): Likewise.
15965 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
15966 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
15967 (dw2_debug_names_dump): Likewise.
15968 (dw2_debug_names_expand_symtabs_for_function): Likewise.
15969 (dw2_debug_names_expand_symtabs_matching): Likewise.
15970 (dwarf2_initialize_objfile): Likewise.
15971 (dwarf2_build_psymtabs): Likewise.
15972 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
15973 this_cu.
15974 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
15975 (read_and_check_comp_unit_head): Likewise.
15976 (read_abbrev_offset): Likewise.
15977 (create_debug_type_hash_table): Likewise.
15978 (create_debug_types_hash_table): Likewise.
15979 (create_all_type_units): Replace objfile parameter with
15980 dwarf2_per_objfile.
15981 (add_type_unit): Add dwarf2_per_objfile parameter.
15982 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
15983 with dwarf2_per_objfile.
15984 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
15985 (lookup_dwp_signatured_type): Likewise.
15986 (lookup_signatured_type): Likewise.
15987 (read_cutu_die_from_dwo): Likewise.
15988 (init_tu_and_read_dwo_dies): Likewise.
15989 (init_cutu_and_read_dies): Likewise.
15990 (init_cutu_and_read_dies_no_follow): Likewise.
15991 (allocate_type_unit_groups_table): Add objfile parameter.
15992 (create_type_unit_group): Use dwarf2_per_objfile from cu.
15993 (get_type_unit_group): Likewise.
15994 (process_psymtab_comp_unit): Update call.
15995 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
15996 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
15997 (print_tu_stats): Likewise.
15998 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
15999 in void* parameter.
16000 (build_type_psymtabs): Change objfile parameter to
16001 dwarf2_per_objfile.
16002 (process_skeletonless_type_unit): Use dwarf2_per_objfile
16003 passed in void* parameter.
16004 (process_skeletonless_type_units): Change objfile parameter to
16005 dwarf2_per_objfile.
16006 (set_partial_user): Likewise.
16007 (dwarf2_build_psymtabs_hard): Likewise.
16008 (read_comp_units_from_section): Likewise.
16009 (create_all_comp_units): Likewise.
16010 (scan_partial_symbols): Update calls.
16011 (add_partial_symbol): Likewise.
16012 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
16013 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
16014 (process_queue): Add dwarf2_per_objfile parameter.
16015 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
16016 (compute_compunit_symtab_includes): Likewise.
16017 (process_cu_includes): Add dwarf2_per_objfile parameter.
16018 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
16019 (process_full_type_unit): Likewise.
16020 (process_imported_unit_die): Update call.
16021 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
16022 (read_file_scope): Likewise.
16023 (allocate_dwo_file_hash_table): Add objfile parameter.
16024 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
16025 (create_cus_hash_table): Likewise.
16026 (create_dwp_hash_table): Likewise.
16027 (create_dwo_unit_in_dwp_v1): Likewise.
16028 (create_dwp_v2_section): Likewise.
16029 (create_dwo_unit_in_dwp_v2): Likewise.
16030 (lookup_dwo_unit_in_dwp): Likewise.
16031 (try_open_dwop_file): Likewise.
16032 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
16033 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
16034 cleanup to include a reference to dwarf2_per_objfile.
16035 (open_dwp_file): Add dwarf2_per_objfile parameter.
16036 (open_and_init_dwp_file): Likewise.
16037 (get_dwp_file): Likewise.
16038 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
16039 (queue_and_load_all_dwo_tus): Update call.
16040 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
16041 data.
16042 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
16043 (dwarf2_ranges_process): Likewise.
16044 (dwarf2_get_pc_bounds): Likewise.
16045 (mark_common_block_symbol_computed): Likewise.
16046 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
16047 (dwarf2_read_abbrevs): Update call.
16048 (read_partial_die): Use dwarf2_per_objfile from cu.
16049 (find_partial_die): Likewise.
16050 (fixup_partial_die): Likewise.
16051 (read_attribute_value): Likewise.
16052 (read_indirect_string_at_offset_from): Add objfile parameter.
16053 (read_indirect_string_at_offset): Add dwarf2_per_objfile
16054 parameter.
16055 (read_indirect_string_from_dwz): Add objfile parameter.
16056 (read_indirect_string): Add objfile parameter.
16057 (read_addr_index_1): Add dwarf2_per_objfile parameter.
16058 (read_addr_index): Use dwarf2_per_objfile from cu.
16059 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
16060 call dw2_setup.
16061 (read_str_index): Use dwarf2_per_objfile from cu.
16062 (get_debug_line_section): Likewise.
16063 (read_formatted_entries): Add dwarf2_per_objfile parameter.
16064 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
16065 (new_symbol_full): Use dwarf2_per_objfile from cu.
16066 (build_error_marker_type): Likewise.
16067 (lookup_die_type): Likewise.
16068 (determine_prefix): Likewise.
16069 (follow_die_offset): Likewise.
16070 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
16071 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
16072 (dwarf2_fetch_die_type_sect_off): Likewise.
16073 (dwarf2_get_die_type): Likewise.
16074 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
16075 (get_signatured_type): Likewise.
16076 (get_DW_AT_signature_type): Likewise.
16077 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
16078 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
16079 (cu_debug_loc_section): Likewise.
16080 (fill_in_loclist_baton): Likewise.
16081 (dwarf2_symbol_mark_computed): Likewise.
16082 (dwarf2_find_containing_comp_unit): Change objfile parameter to
16083 dwarf2_per_objfile.
16084 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
16085 parameter.
16086 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
16087 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
16088 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
16089 (set_die_type): Use dwarf2_free_objfile from cu.
16090 (get_die_type_at_offset): Likewise.
16091 (dwarf2_per_objfile_free): Don't assign global variable.
16092 (debug_names) <constructor>: Add dwarf2_per_objfile
16093 parameter, update m_debugstrlookup construction.
16094 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
16095 parameter.
16096 <m_dwarf2_per_objfile>: New field.
16097 <lookup>: Use m_dwarf2_per_objfile.
16098 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
16099 (psyms_seen_size): Likewise.
16100 (write_gdbindex): Replace objfile parameter with
16101 dwarf2_per_objfile.
16102 (write_debug_names): Likewise.
16103 (write_psymtabs_to_index): Likewise.
16104 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
16105 calls.
16106
16107 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
16108
16109 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
16110 <dwarf2_per_objfile>: New field.
16111 (struct dwarf2_per_cu_data) <objfile>: Remove.
16112 <dwarf2_per_objfile>: New field.
16113 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
16114 of objfile.
16115 (create_signatured_type_table_from_index): Likewise.
16116 (create_debug_type_hash_table): Likewise.
16117 (fill_in_sig_entry_from_dwo_entry): Likewise.
16118 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
16119 (create_type_unit_group): Assign dwarf2_per_objfile instead of
16120 objfile.
16121 (create_partial_symtab): Access objfile through
16122 dwarf2_per_objfile.
16123 (process_psymtab_comp_unit_reader): Likewise.
16124 (read_comp_units_from_section): Likewise.
16125 (scan_partial_symbols): Likewise.
16126 (add_partial_symbol): Likewise.
16127 (add_partial_subprogram): Likewise.
16128 (peek_die_abbrev): Likewise.
16129 (fixup_go_packaging): Likewise.
16130 (process_full_comp_unit): Likewise.
16131 (process_full_type_unit): Likewise.
16132 (process_imported_unit_die): Likewise.
16133 (dwarf2_compute_name): Likewise.
16134 (dwarf2_physname): Likewise.
16135 (read_import_statement): Likewise.
16136 (create_cus_hash_table): Assign dwarf2_physname instead of
16137 objfile.
16138 (read_func_scope): Access objfile through dwarf2_per_objfile.
16139 (read_lexical_block_scope): Likewise.
16140 (read_call_site_scope): Likewise.
16141 (read_variable): Likewise.
16142 (dwarf2_rnglists_process): Likewise.
16143 (dwarf2_ranges_process): Likewise.
16144 (dwarf2_ranges_read): Likewise.
16145 (dwarf2_record_block_ranges): Likewise.
16146 (dwarf2_add_field): Likewise.
16147 (dwarf2_add_member_fn): Likewise.
16148 (read_structure_type): Likewise.
16149 (process_structure_scope): Likewise.
16150 (read_enumeration_type): Likewise.
16151 (read_array_type): Likewise.
16152 (read_common_block): Likewise.
16153 (read_namespace_type): Likewise.
16154 (read_namespace): Likewise.
16155 (read_module_type): Likewise.
16156 (read_tag_pointer_type): Likewise.
16157 (read_tag_ptr_to_member_type): Likewise.
16158 (read_tag_string_type): Likewise.
16159 (read_subroutine_type): Likewise.
16160 (read_typedef): Likewise.
16161 (read_base_type): Likewise.
16162 (attr_to_dynamic_prop): Likewise.
16163 (read_subrange_type): Likewise.
16164 (read_unspecified_type): Likewise.
16165 (load_partial_dies): Likewise.
16166 (read_partial_die): Likewise.
16167 (find_partial_die): Likewise.
16168 (guess_partial_die_structure_name): Likewise.
16169 (fixup_partial_die): Likewise.
16170 (read_attribute_value): Likewise.
16171 (read_addr_index_from_leb128): Likewise.
16172 (dwarf2_read_addr_index): Likewise.
16173 (dwarf2_string_attr): Likewise.
16174 (lnp_state_machine::check_line_address): Likewise.
16175 (dwarf_decode_lines_1): Likewise.
16176 (dwarf_decode_lines): Likewise.
16177 (dwarf2_start_symtab): Likewise.
16178 (var_decode_location): Likewise.
16179 (new_symbol_full): Likewise.
16180 (dwarf2_const_value_data): Likewise.
16181 (dwarf2_const_value_attr): Likewise.
16182 (dwarf2_const_value): Likewise.
16183 (die_type): Likewise.
16184 (die_containing_type): Likewise.
16185 (lookup_die_type): Likewise.
16186 (guess_full_die_structure_name): Likewise.
16187 (anonymous_struct_prefix): Likewise.
16188 (dwarf2_name): Likewise.
16189 (follow_die_ref_or_sig): Likewise.
16190 (follow_die_offset): Likewise.
16191 (follow_die_ref): Likewise.
16192 (dwarf2_fetch_die_loc_sect_off): Likewise.
16193 (dwarf2_fetch_constant_bytes): Likewise.
16194 (dwarf2_fetch_die_type_sect_off): Likewise.
16195 (dwarf2_get_die_type): Likewise.
16196 (follow_die_sig): Likewise.
16197 (decode_locdesc): Likewise.
16198 (dwarf2_per_cu_objfile): Likewise.
16199 (dwarf2_per_cu_text_offset): Likewise.
16200 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
16201 objfile.
16202 (set_die_type): Access objfile through
16203 dwarf2_per_objfile.
16204
16205 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
16206
16207 * valprint.c (converted_character_d): Remove typedef.
16208 (DEF_VEC_O (converted_character_d)): Remove.
16209 (count_next_character): Use std::vector.
16210 (print_converted_chars_to_obstack): Likewise.
16211 (generic_printstr): Likewise.
16212
16213 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
16214
16215 * xml-support.h (struct gdb_xml_value): Add constructor.
16216 <value>: Change type to unique_xmalloc_ptr.
16217 (gdb_xml_value_s): Remove typedef.
16218 (DEF_VEC_O (gdb_xml_value_s)): Remove.
16219 (gdb_xml_element_start_handler): Change parameter type to
16220 std::vector.
16221 (xml_find_attribute): Likewise.
16222 * xml-support.c (xml_find_attribute): Change parameter type to
16223 std::vector and adjust.
16224 (gdb_xml_values_cleanup): Remove.
16225 (gdb_xml_parser::start_element): Adjust to std::vector.
16226 (xinclude_start_include): Change paraeter type to std::vector
16227 and adjust.
16228 * btrace.c (check_xml_btrace_version): Likewise.
16229 (parse_xml_btrace_block): Likewise.
16230 (parse_xml_btrace_pt_config_cpu): Likewise.
16231 (parse_xml_btrace_pt): Likewise.
16232 (parse_xml_btrace_conf_bts): Likewise.
16233 (parse_xml_btrace_conf_pt): Likewise.
16234 * memory-map.c (memory_map_start_memory): Likewise.
16235 (memory_map_start_property): Likewise.
16236 * osdata.c (osdata_start_osdata): Likewise.
16237 (osdata_start_item): Likewise.
16238 (osdata_start_column): Likewise.
16239 * remote.c (start_thread): Likewise.
16240 * solib-aix.c (library_list_start_library): Likewise.
16241 (library_list_start_list): Likewise.
16242 * solib-svr4.c (library_list_start_library): Likewise.
16243 (svr4_library_list_start_list): Likewise.
16244 * solib-target.c (library_list_start_segment): Likewise.
16245 (library_list_start_section): Likewise.
16246 (library_list_start_library): Likewise.
16247 (library_list_start_list): Likewise.
16248 * tracepoint.c (traceframe_info_start_memory): Likewise.
16249 (traceframe_info_start_tvar): Likewise.
16250 * xml-syscall.c (syscall_start_syscall): Likewise.
16251 * xml-tdesc.c (tdesc_start_target): Likewise.
16252 (tdesc_start_feature): Likewise.
16253 (tdesc_start_reg): Likewise.
16254 (tdesc_start_union): Likewise.
16255 (tdesc_start_struct): Likewise.
16256 (tdesc_start_flags): Likewise.
16257 (tdesc_start_enum): Likewise.
16258 (tdesc_start_field): Likewise.
16259 (tdesc_start_enum_value): Likewise.
16260 (tdesc_start_vector): Likewise.
16261
16262 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
16263
16264 * extension.h (struct xmethod_worker) <clone>: Remove.
16265 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
16266 Remove.
16267 (python_xmethod_worker::clone): Remove.
16268 * valops.c (find_overload_match): Use std::move instead of
16269 clone.
16270
16271 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
16272
16273 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
16274 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
16275 <free_xmethod_worker_data>: Remove.
16276 <get_matching_xmethod_workers>: Chance VEC to std::vector.
16277 <get_xmethod_arg_types>: Remove.
16278 <get_xmethod_result_type>: Remove.
16279 <invoke_xmethod>: Remove.
16280 * extension.c (new_xmethod_worker): Remove.
16281 (clone_xmethod_worker): Remove.
16282 (get_matching_xmethod_workers): Return void, pass std::vector by
16283 pointer.
16284 (get_xmethod_arg_types): Rename to...
16285 (xmethod_worker::get_arg_types): ... this, and adjust.
16286 (get_xmethod_result_type): Rename to...
16287 (xmethod_worker::get_result_type): ... this, and adjust.
16288 (invoke_xmethod): Remove.
16289 (free_xmethod_worker): Remove.
16290 (free_xmethod_worker_vec): Remove.
16291 * extension.h (enum ext_lang_rc): Move here from
16292 extension-priv.h.
16293 (struct xmethod_worker): Add constructor and destructor.
16294 <data>: Remove.
16295 <value>: Remove.
16296 <invoke, clone, do_get_result_type, do_get_arg_types>: New
16297 virtual pure methods.
16298 <get_arg_types, get_result_type>: New methods.
16299 (xmethod_worker_ptr): Remove typedef.
16300 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
16301 (xmethod_worker_vec): Remove typedef.
16302 (xmethod_worker_up): New typedef.
16303 (invoke_xmethod): Remove.
16304 (clone_xmethod_worker): Remove.
16305 (free_xmethod_worker): Remove.
16306 (free_xmethod_worker_vec): Remove.
16307 (get_xmethod_arg_types): Remove.
16308 (get_xmethod_result_type): Remove.
16309 * valops.c (find_method_list): Use std::vector, don't use
16310 intermediate vector.
16311 (value_find_oload_method_list): Use std::vector.
16312 (find_overload_match): Use std::vector.
16313 (find_oload_champ): Use std::vector.
16314 * value.c (value_free): Use operator delete.
16315 (value_of_xmethod): Rename to...
16316 (value_from_xmethod): ... this. Don't assign
16317 xmethod_worker::value, take rvalue-reference.
16318 (result_type_of_xmethod): Adjust.
16319 (call_xmethod): Adjust.
16320 * value.h: Include extension.h.
16321 (struct xmethod_worker): Don't forward-declare.
16322 (value_of_xmethod): Rename to...
16323 (value_from_xmethod): ... this, take rvalue-reference.
16324 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
16325 (struct python_xmethod_worker): ... this, add constructor and
16326 destructor.
16327 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
16328 (gdbpy_free_xmethod_worker_data): Rename to...
16329 (python_xmethod_worker::~python_xmethod_worker): ... this and
16330 adjust.
16331 (gdbpy_clone_xmethod_worker_data): Rename to...
16332 (python_xmethod_worker::clone): ... this and adjust.
16333 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
16334 temporary vector.
16335 (gdbpy_get_xmethod_arg_types): Rename to...
16336 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
16337 (gdbpy_get_xmethod_result_type): Rename to...
16338 (python_xmethod_worker::do_get_result_type): ... this and
16339 adjust.
16340 (gdbpy_invoke_xmethod): Rename to...
16341 (python_xmethod_worker::invoke): ... this and adjust.
16342 (new_python_xmethod_worker): Rename to...
16343 (python_xmethod_worker::python_xmethod_worker): ... this and
16344 adjust.
16345 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
16346 Remove.
16347 (gdbpy_free_xmethod_worker_data): Remove.
16348 (gdbpy_get_matching_xmethod_workers): Use std::vector.
16349 (gdbpy_get_xmethod_arg_types): Remove.
16350 (gdbpy_get_xmethod_result_type): Remove.
16351 (gdbpy_invoke_xmethod): Remove.
16352 * python/python.c (python_extension_ops): Remove obsolete
16353 callbacks.
16354
16355 2018-01-05 Pedro Alves <palves@redhat.com>
16356
16357 PR gdb/18653
16358 * common/signals-state-save-restore.c
16359 (save_original_signals_state): New parameter 'quiet'. Warn if we
16360 find a custom handler preinstalled, instead of internal erroring.
16361 But only warn if !quiet.
16362 * common/signals-state-save-restore.h
16363 (save_original_signals_state): New parameter 'quiet'.
16364 * main.c (captured_main_1): Move save_original_signals_state call
16365 after option handling, and pass QUIET.
16366
16367 2018-01-05 Pedro Alves <palves@redhat.com>
16368
16369 * spu-tdep.c (spu_catch_start): Pass
16370 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
16371
16372 2018-01-05 Pedro Alves <palves@redhat.com>
16373
16374 PR gdb/22670
16375 * ada-lang.c (literal_symbol_name_matcher): New function.
16376 (ada_get_symbol_name_matcher): Use it for
16377 symbol_name_match_type::SEARCH_NAME.
16378 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
16379 it down instead of assuming symbol_name_match_type::FULL.
16380 * block.h (block_lookup_symbol): New parameter 'match_type'.
16381 * c-valprint.c (print_unpacked_pointer): Use
16382 lookup_symbol_search_name instead of lookup_symbol.
16383 * compile/compile-object-load.c (get_out_value_type): Pass down
16384 symbol_name_match_type::SEARCH_NAME.
16385 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
16386 symbol_name_match_type::FULL.
16387 * cp-support.c (cp_get_symbol_name_matcher): Handle
16388 symbol_name_match_type::SEARCH_NAME.
16389 * infrun.c (insert_exception_resume_breakpoint): Use
16390 lookup_symbol_search_name.
16391 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
16392 * psymtab.c (maintenance_check_psymtabs): Use
16393 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
16394 * stack.c (print_frame_args): Use lookup_symbol_search_name and
16395 SYMBOL_SEARCH_NAME.
16396 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
16397 if symbol_name_match_type::SEARCH_NAME.
16398 (lookup_symbol_in_language): Pass down
16399 symbol_name_match_type::FULL.
16400 (lookup_symbol_search_name): New.
16401 (lookup_language_this): Pass down
16402 symbol_name_match_type::SEARCH_NAME.
16403 (lookup_symbol_aux, lookup_local_symbol): New parameter
16404 'match_type'. Pass it down.
16405 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
16406 (lookup_symbol_search_name): New declaration.
16407 (lookup_symbol_in_block): New 'match_type' parameter.
16408
16409 2018-01-05 Pedro Alves <palves@redhat.com>
16410
16411 PR gdb/22670
16412 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
16413 ada_lookup_symbol.
16414 (ada_lookup_symbol): Reimplement in terms of
16415 ada_lookup_symbol_list, bits factored out from
16416 ada_lookup_encoded_symbol.
16417
16418 2018-01-05 Joel Brobecker <brobecker@adacore.com>
16419
16420 * ada-exp.y (write_object_renaming): When subscripting an array
16421 using a symbol as the index, pass the block in call to
16422 ada_lookup_encoded_symbol when looking that symbol up.
16423
16424 2018-01-05 Jerome Guitton <guitton@adacore.com>
16425
16426 * ada-lang.c (ada_array_length): Use ada_index_type instead of
16427 TYPE_INDEX_TYPE.
16428
16429 2018-01-05 Joel Brobecker <brobecker@adacore.com>
16430
16431 * ada-lang.c (ada_to_fixed_value_create): Add handling of
16432 the case where VALUE_LVAL (val0) is not lval_memory.
16433
16434 2018-01-05 Xavier Roirand <roirand@adacore.com>
16435
16436 * ada-valprint.c (print_optional_low_bound): Handle
16437 character-indexed array printing like boolean-indexed array
16438 printing.
16439
16440 2018-01-05 Joel Brobecker <brobecker@adacore.com>
16441
16442 * NEWS: Create a new section for the next release branch.
16443 Rename the section of the current branch, now that it has
16444 been cut.
16445
16446 2018-01-05 Joel Brobecker <brobecker@adacore.com>
16447
16448 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
16449 * version.in: Bump version to 8.1.50.DATE-git.
16450
16451 2018-01-03 Xavier Roirand <roirand@adacore.com>
16452
16453 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
16454 Add field.
16455 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
16456 Add field.
16457 (default_exception_support_info) <catch_handlers_sym>: Add field.
16458 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
16459 (ada_exception_name_addr_1): Add "catch handlers" handling.
16460 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
16461 Update all callers.
16462 (create_excep_cond_exprs) <ex>: Add parameter.
16463 (re_set_exception): Update create_excep_cond_exprs call.
16464 (print_it_exception, print_one_exception, print_mention_exception)
16465 (print_recreate_exception): Add "catch handler" handling.
16466 (allocate_location_catch_handlers, re_set_catch_handlers)
16467 (check_status_catch_handlers, print_it_catch_handlers)
16468 (print_one_catch_handlers, print_mention_catch_handlers)
16469 (print_recreate_catch_handlers): New function.
16470 (catch_handlers_breakpoint_ops): New variable.
16471 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
16472 Add parameter. Add "catch handler" handling.
16473 (ada_exception_sym_name, ada_exception_breakpoint_ops):
16474 Add "catch handler" handling.
16475 (ada_exception_catchpoint_cond_string): Add "catch handler"
16476 handling.
16477 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
16478 call.
16479 (catch_ada_handlers_command): New function.
16480 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
16481 operations structure.
16482 (_initialize_ada_language): Add "catch handlers" command entry.
16483 * NEWS: Document "catch handlers" feature.
16484
16485 2018-01-02 Joel Brobecker <brobecker@adacore.com>
16486
16487 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
16488 account when creating the array type of the slice.
16489 (ada_value_slice): Likewise.
16490
16491 2018-01-02 Joel Brobecker <brobecker@adacore.com>
16492
16493 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
16494 New enum value.
16495 (create_array_type_with_stride): Add byte_stride_prop parameter.
16496 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
16497 New parameter. Update all callers in this file.
16498 (array_type_has_dynamic_stride): New function.
16499 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
16500 of arrays with dynamic byte strides.
16501 * dwarf2read.c (read_array_type): Add support for dynamic
16502 DW_AT_byte_stride attributes.
16503
16504 2018-01-02 Joel Brobecker <brobecker@adacore.com>
16505
16506 * dwarf2read.c (read_unspecified_type): Treat
16507 DW_TAG_enumeration_type DIEs from Ada units as stubs.
16508
16509 2018-01-01 Joel Brobecker <brobecker@adacore.com>
16510
16511 Update copyright year range in all GDB files.
16512
16513 2018-01-01, 18 Joel Brobecker <brobecker@adacore.com>
16514
16515 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
16516 and gdb/testsuite/gdb.base/step-line.c.
16517
16518 2018-01-01 Joel Brobecker <brobecker@adacore.com>
16519
16520 * copyright.py (main): Dump the contents of
16521 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
16522 even if BY_HAND is empty.
16523
16524 2018-01-01 Joel Brobecker <brobecker@adacore.com>
16525
16526 * top.c (print_gdb_version): Update Copyright year in version
16527 message.
16528
16529 2018-01-01 Joel Brobecker <brobecker@adacore.com>
16530
16531 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
16532
16533 For older changes see ChangeLog-2017.
16534 \f
16535 Local Variables:
16536 mode: change-log
16537 left-margin: 8
16538 fill-column: 74
16539 version-control: never
16540 coding: utf-8
16541 End:
This page took 0.341481 seconds and 5 git commands to generate.