probe: Replace VEC(probe_ops_cp) with std::vector
[deliverable/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
0782db84
SM
12017-09-12 Simon Marchi <simon.marchi@ericsson.com>
2
3 * probe.h (probe_ops_cp): Remove typedef.
4 (DEF_VEC_P (probe_ops_cp)): Remove.
5 (all_probe_ops): Change type to std::vector.
6 * probe.c (info_probes_for_ops): Adjust to vector change.
7 (probe_linespec_to_ops): Likewise.
8 (all_probe_ops): Change type to std::vector.
9 (_initialize_probe): Adjust to vector change.
10 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
11 * elfread.c (elf_get_probes): Likewise.
12 * stap-probe.c (_initialize_stap_probe): Likewise.
13
1eac6bea
SM
142017-09-12 Simon Marchi <simon.marchi@ericsson.com>
15
16 * probe.h (struct bound_probe): Define constructors.
17 * probe.c (bound_probe_s): Remove typedef.
18 (DEF_VEC_O (bound_probe_s)): Remove VEC.
19 (collect_probes): Change return type to std::vector, remove
20 cleanup.
21 (compare_probes): Return bool, change parameter type. Change
22 semantic to "less than".
23 (gen_ui_out_table_header_info): Change parameter to std::vector
24 and update.
25 (exists_probe_with_pops): Likewise.
26 (info_probes_for_ops): Update to std::vector change.
27 (enable_probes_command): Likewise.
28 (disable_probes_command): Likewise.
29
aaa63a31
SM
302017-09-12 Simon Marchi <simon.marchi@ericsson.com>
31
32 * probe.h (struct probe_ops) <get_probes>: Change parameter from
33 vec to std::vector.
34 * probe.c (parse_probes_in_pspace): Update.
35 (find_probes_in_objfile): Update.
36 (find_probe_by_pc): Update.
37 (collect_probes): Update.
38 (probe_any_get_probes): Update.
39 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
40 return type to reference to std::vector.
41 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
42 std::vector and update.
43 (dtrace_process_dof): Likewise.
44 (dtrace_get_probes): Likewise.
45 * elfread.c (elf_get_probes): Change return type to std::vector,
46 store an std::vector in bfd_data.
47 (probe_key_free): Update to std::vector.
48 * stap-probe.c (handle_stap_probe): Change parameter to
49 std::vector and update.
50 (stap_get_probes): Likewise.
51 * symfile-debug.c (debug_sym_get_probes): Change return type to
52 std::vector and update.
53
cb85b21b
TT
542017-09-11 Tom Tromey <tom@tromey.com>
55
56 * breakpoint.c (program_breakpoint_here_p): Update.
57 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
58 from make_show_memory_breakpoints_cleanup. Return a
59 scoped_restore_tmpl<int>.
60 (restore_show_memory_breakpoints): Remove.
61 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
62 * mem-break.c (memory_validate_breakpoint): Update.
63 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
64 (ia64_memory_remove_breakpoint): Update.
65 (ia64_breakpoint_from_pc): Update.
66 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
67 from make_show_memory_breakpoints_cleanup.
68
8fbc99ef
TT
692017-09-11 Tom Tromey <tom@tromey.com>
70
71 * d-namespace.c (d_lookup_symbol): Use std::string.
72 (find_symbol_in_baseclass): Likewise.
73
50feb4bd
TT
742017-09-11 Tom Tromey <tom@tromey.com>
75
76 * ctf.c (ctf_start): Use std::string.
77
c6dc63a1
TT
782017-09-11 Tom Tromey <tom@tromey.com>
79
80 * ada-lang.c (is_known_support_routine): Update.
81 (ada_unhandled_exception_name_addr_from_raise): Update.
82 * guile/scm-frame.c (gdbscm_frame_name): Update.
83 * python/py-frame.c (frapy_name): Update.
84 (frapy_function): Update.
85 * stack.h (find_frame_funname): Update.
86 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
87 (print_frame): Update.
88
d6b9b80f
TT
892017-09-11 Tom Tromey <tom@tromey.com>
90
91 * findcmd.c (put_bits): Take a gdb::byte_vector.
92 (parse_find_args): Return gdb::byte_vector. "args" now const.
93 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
94 cleanups.
95 (find_command): Update.
96
a9921622
TT
972017-09-11 Tom Tromey <tom@tromey.com>
98
99 * cli/cli-script.c (class scoped_restore_hook_in): New.
100 (clear_hook_in_cleanup): Remove.
101 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
102 scoped_restore_hook_in.
103
be0d7abb
TT
1042017-09-11 Tom Tromey <tom@tromey.com>
105
106 * cli/cli-script.c (restore_interp): Remove.
107 (read_command_lines): Use scoped_restore_interp.
108 * interps.c (scoped_restore_interp::set_temp): Rename from
109 interp_set_temp.
110 * interps.h (class scoped_restore_interp): New.
111 (interp_set_temp): Remove.
112
00f675ff
TT
1132017-09-11 Tom Tromey <tom@tromey.com>
114
115 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
116 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
117 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
118 scoped_restore.
119 (mi_cmd_break_insert_1): Update.
120 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
121 scoped_restore.
122
cb791d59
TT
1232017-09-11 Tom Tromey <tom@tromey.com>
124
125 * demangle.c (demangle_command): Update.
126 * breakpoint.c (disable_command): Update.
127 (enable_command): Update.
128 (find_location_by_number): Make "number" const. Use
129 get_number_trailer.
130 * cli/cli-utils.c (extract_arg): Return std::string.
131 * probe.c (parse_probe_linespec): Update. Change types.
132 (collect_probes): Take string arguments.
133 (parse_probe_linespec): Likewise.
134 (info_probes_for_ops): Update.
135 (enable_probes_command): Update.
136 (disable_probes_command): Update.
137 * break-catch-sig.c (catch_signal_split_args): Update.
138 * mi/mi-parse.c (mi_parse): Update.
139
2039bd9f
TT
1402017-09-11 Tom Tromey <tom@tromey.com>
141
142 * language.h (language_enum): Make argument const.
143 * language.c (language_enum): Make argument const.
144
f1735a53
TT
1452017-09-11 Tom Tromey <tom@tromey.com>
146
147 * common/common-utils.h (skip_to_space): Remove macro, redeclare
148 as function.
149 (skip_to_space): Rename from skip_to_space_const.
150 * common/common-utils.c (skip_to_space): New function.
151 (skip_to_space): Rename from skip_to_space_const.
152 * cli/cli-utils.h (get_number): Rename from get_number_const.
153 (extract_arg): Rename from extract_arg_const.
154 * cli/cli-utils.c (get_number): Rename from get_number_const.
155 (extract_arg): Rename from extract_arg_const.
156 (number_or_range_parser::get_number): Use ::get_number.
157 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
158 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
159 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
160 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
161 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
162 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
163 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
164 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
165
7d221d74
TT
1662017-09-11 Tom Tromey <tom@tromey.com>
167
168 * python/python.c (do_start_initialization): Use
169 py-event-types.def to initialize types.
170 Define all object type structures.
171 * python/python-internal.h: Don't declare event initialization
172 functions.
173 * python/py-threadevent.c (thread_event_object_type): Don't
174 define.
175 * python/py-stopevent.c (stop_event_object_type): Don't define.
176 * python/py-signalevent.c (signal_event_object_type): Don't
177 declare or define.
178 * python/py-newobjfileevent.c (new_objfile_event_object_type)
179 (clear_objfiles_event_object_type): Don't declare or define.
180 * python/py-infevents.c (inferior_call_pre_event_object_type)
181 (inferior_call_post_event_object_type)
182 (register_changed_event_object_type)
183 (memory_changed_event_object_type): Don't declare or define.
184 * python/py-inferior.c (new_thread_event_object_type)
185 (new_inferior_event_object_type)
186 (inferior_deleted_event_object_type): Don't declare or define.
187 * python/py-exitedevent.c (exited_event_object_type): Don't
188 declare or define.
189 * python/py-evts.c (gdbpy_initialize_py_events): Use
190 py-all-events.def.
191 * python/py-events.h (thread_event_object_type): Don't declare.
192 (events_object): Use py-all-events.def.
193 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
194 py-event-types.def.
195 * python/py-event-types.def: New file.
196 * python/py-continueevent.c (create_continue_event_object): Don't
197 declare or define.
198 * python/py-bpevent.c (breakpoint_event_object_type): Don't
199 declare or define.
200 * python/py-all-events.def: New file.
201
35c61a1d
TT
2022017-09-11 Tom Tromey <tom@tromey.com>
203
204 * python/py-threadevent.c (create_thread_event_object): Return
205 gdbpy_ref.
206 * python/py-stopevent.h (create_stop_event_object)
207 (create_breakpoint_event_object, create_signal_event_object):
208 Update.
209 * python/py-stopevent.c (create_stop_event_object): Return
210 gdbpy_ref.
211 (emit_stop_event): Update.
212 * python/py-signalevent.c (create_signal_event_object): Return
213 gdbpy_ref.
214 * python/py-infevents.c (create_inferior_call_event_object):
215 Update.
216 * python/py-event.h (create_event_object)
217 (create_thread_event_object): Update.
218 * python/py-event.c (create_event_object): Return gdbpy_ref.
219 * python/py-continueevent.c: Return gdbpy_ref.
220 * python/py-bpevent.c (create_breakpoint_event_object): Return
221 gdbpy_ref.
222
7c96f8c1
TT
2232017-09-11 Tom Tromey <tom@tromey.com>
224
225 PR python/15622:
226 * NEWS: Add entry.
227 * python/python.c (do_start_initialization): Initialize new event
228 types.
229 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
230 (gdbpy_initialize_inferior_deleted_event)
231 (gdbpy_initialize_new_thread_event): Declare.
232 * python/py-threadevent.c (create_thread_event_object): Add option
233 "thread" parameter.
234 * python/py-inferior.c (new_thread_event_object_type)
235 (new_inferior_event_object_type)
236 (inferior_deleted_event_object_type): Declare.
237 (python_new_inferior, python_inferior_deleted): New functions.
238 (add_thread_object): Emit new_thread event.
239 (gdbpy_initialize_inferior): Attach new functions to corresponding
240 observers.
241 (new_thread, new_inferior, inferior_deleted): Define new event
242 types.
243 * python/py-evts.c (gdbpy_initialize_py_events): Add new
244 registries.
245 * python/py-events.h (events_object) <new_inferior,
246 inferior_deleted, new_thread>: New fields.
247 * python/py-event.h (create_thread_event_breakpoint): Add optional
248 "thread" parameter.
249
72542b8e
AB
2502017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
251
252 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
253 check current_ui instead.
254 (internal_vproblem): Likewise.
255
0d64823e
SM
2562017-09-09 Simon Marchi <simon.marchi@ericsson.com>
257
258 * thread.c (print_thread_info_1): Remove unnecessary calls to
259 uiout->is_mi_like_p.
260
eb1e02fd
TT
2612017-09-09 Tom Tromey <tom@tromey.com>
262
263 * namespace.h (add_using_directive): Update.
264 * namespace.c (add_using_directive): Change type of excludes to
265 std::vector.
266 * dwarf2read.c (read_import_statement): Use std::vector.
267 (read_namespace): Update.
268 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
269
0fc21fd8
TT
2702017-09-09 Tom Tromey <tom@tromey.com>
271
272 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
273
49663d05
TT
2742017-09-09 Tom Tromey <tom@tromey.com>
275
276 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
277
0b868b60
TT
2782017-09-09 Tom Tromey <tom@tromey.com>
279
280 * stack.c (func_command): Use gdb::def_vector.
281
c0470d48
TT
2822017-09-09 Tom Tromey <tom@tromey.com>
283
284 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
285 ui_out_emit_list, ui_out_emit_tuple.
286 (mi_cmd_var_update): Likewise.
287
ca5909c7
TT
2882017-09-09 Tom Tromey <tom@tromey.com>
289
290 * mi/mi-interp.c (mi_user_selected_context_changed): Use
291 ui_out_redirect_pop.
292 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
293 ui_out_redirect_pop.
294 * utils.c (do_ui_out_redirect_pop)
295 (make_cleanup_ui_out_redirect_pop): Remove.
296 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
297 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
298 * ui-out.h (ui_out_redirect_pop): New class.
299
e6a2252a
TT
3002017-09-09 Tom Tromey <tom@tromey.com>
301
302 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
303 (list_available_thread_groups, mi_cmd_list_thread_groups)
304 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
305 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
306 Likewise.
307
393702cd
TT
3082017-09-09 Tom Tromey <tom@tromey.com>
309
310 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
311 ui_out_emit_tuple.
312
76f9c9cf
TT
3132017-09-09 Tom Tromey <tom@tromey.com>
314
315 * target.c (flash_erase_command): Use ui_out_emit_tuple.
316 * stack.c (print_frame): Use ui_out_emit_tuple.
317 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
318 (info_spu_mailbox_command, info_spu_dma_command)
319 (info_spu_proxydma_command): Likewise.
320 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
321 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
322 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
323 ui_out_emit_tuple.
324 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
325
dc9fe180
TT
3262017-09-09 Tom Tromey <tom@tromey.com>
327
328 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
329 (class ui_out_emit_table): Update comment.
330 * ui-out.c (do_cleanup_table_end)
331 (make_cleanup_ui_out_table_begin_end): Remove.
332 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
333 (info_spu_dma_cmdlist): Likewise.
334 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
335 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
336 ui_out_emit_table.
337
f8cc3da6
TT
3382017-09-09 Tom Tromey <tom@tromey.com>
339
340 * thread.c (print_thread_info_1): Use ui_out_emit_table,
341 ui_out_emit_list, gdb::optional.
342
481695ed
JB
3432017-09-09 John Baldwin <jhb@FreeBSD.org>
344
345 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
346 prototype.
347 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
348 prototype.
349 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
350 prototype.
351 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
352 * ada-exp.y: Remove _initialize_ada_exp prototype.
353 * ada-lang.c: Remove _initialize_ada_language prototype.
354 * ada-tasks.c: Remove _initialize_tasks prototype.
355 * addrmap.c: Remove _initialize_addrmap prototype.
356 * agent.c: Remove _initialize_agent prototype.
357 * aix-thread.c: Remove _initialize_aix_thread prototype.
358 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
359 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
360 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
361 prototype.
362 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
363 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
364 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
365 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
366 prototype.
367 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
368 prototype.
369 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
370 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
371 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
372 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
373 prototype.
374 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
375 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
376 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
377 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
378 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
379 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
380 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
381 prototype.
382 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
383 prototype.
384 * annotate.c: Remove _initialize_annotate prototype.
385 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
386 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
387 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
388 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
389 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
390 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
391 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
392 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
393 prototype.
394 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
395 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
396 * auto-load.c: Remove _initialize_auto_load prototype.
397 * auxv.c: Remove _initialize_auxv prototype.
398 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
399 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
400 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
401 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
402 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
403 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
404 prototype.
405 * break-catch-throw.c: Remove _initialize_break_catch_throw
406 prototype.
407 * breakpoint.c: Remove _initialize_breakpoint prototype.
408 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
409 * btrace.c: Remove _initialize_btrace prototype.
410 * charset.c: Remove _initialize_charset prototype.
411 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
412 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
413 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
414 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
415 * cli/cli-script.c: Remove _initialize_cli_script prototype.
416 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
417 * coffread.c: Remove _initialize_coffread prototype.
418 * compile/compile.c: Remove _initialize_compile prototype.
419 * complaints.c: Remove _initialize_complaints prototype.
420 * completer.c: Remove _initialize_completer prototype.
421 * copying.awk: Remove _initialize_copying prototype.
422 * copying.c: Regenerate.
423 * core-regset.c: Remove _initialize_core_regset prototype.
424 * corefile.c: Remove _initialize_core prototype.
425 * corelow.c: Remove _initialize_corelow prototype.
426 * cp-abi.c: Remove _initialize_cp_abi prototype.
427 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
428 * cp-support.c: Remove _initialize_cp_support prototype.
429 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
430 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
431 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
432 * ctf.c: Remove _initialize_ctf prototype.
433 * d-lang.c: Remove _initialize_d_language prototype.
434 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
435 prototype.
436 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
437 * dbxread.c: Remove _initialize_dbxread prototype.
438 * dcache.c: Remove _initialize_dcache prototype.
439 * demangle.c: Remove _initialize_demangler prototype.
440 * disasm-selftests.c: Remove _initialize_disasm_selftests
441 prototype.
442 * disasm.c: Remove _initialize_disasm prototype.
443 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
444 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
445 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
446 prototype.
447 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
448 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
449 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
450 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
451 * elfread.c: Remove _initialize_elfread prototype.
452 * exec.c: Remove _initialize_exec prototype.
453 * extension.c: Remove _initialize_extension prototype.
454 * f-lang.c: Remove _initialize_f_language prototype.
455 * f-valprint.c: Remove _initialize_f_valprint prototype.
456 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
457 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
458 * filesystem.c: Remove _initialize_filesystem prototype.
459 * findcmd.c: Remove _initialize_mem_search prototype.
460 * fork-child.c: Remove _initialize_fork_child prototype.
461 * frame-base.c: Remove _initialize_frame_base prototype.
462 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
463 * frame.c: Remove _initialize_frame prototype.
464 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
465 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
466 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
467 * gcore.c: Remove _initialize_gcore prototype.
468 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
469 * gdbarch.c: Regenerate.
470 * gdbarch.sh: Remove _initialize_gdbarch prototype.
471 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
472 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
473 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
474 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
475 * go-lang.c: Remove _initialize_go_language prototype.
476 * go32-nat.c: Remove _initialize_go32_nat prototype.
477 * guile/guile.c: Remove _initialize_guile prototype.
478 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
479 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
480 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
481 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
482 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
483 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
484 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
485 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
486 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
487 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
488 prototype.
489 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
490 prototype.
491 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
492 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
493 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
494 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
495 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
496 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
497 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
498 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
499 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
500 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
501 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
502 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
503 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
504 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
505 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
506 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
507 prototype.
508 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
509 prototype.
510 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
511 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
512 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
513 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
514 * infcall.c: Remove _initialize_infcall prototype.
515 * infcmd.c: Remove _initialize_infcmd prototype.
516 * inferior.c: Remove _initialize_inferiors prototype.
517 * inflow.c: Remove _initialize_inflow prototype.
518 * infrun.c: Remove _initialize_infrun prototype.
519 * interps.c: Remove _initialize_interpreter prototype.
520 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
521 * jit.c: Remove _initialize_jit prototype.
522 * language.c: Remove _initialize_language prototype.
523 * linux-fork.c: Remove _initialize_linux_fork prototype.
524 * linux-nat.c: Remove _initialize_linux_nat prototype.
525 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
526 * linux-thread-db.c: Remove _initialize_thread_db prototype.
527 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
528 * m2-lang.c: Remove _initialize_m2_language prototype.
529 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
530 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
531 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
532 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
533 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
534 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
535 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
536 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
537 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
538 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
539 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
540 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
541 * machoread.c: Remove _initialize_machoread prototype.
542 * macrocmd.c: Remove _initialize_macrocmd prototype.
543 * macroscope.c: Remove _initialize_macroscope prototype.
544 * maint.c: Remove _initialize_maint_cmds prototype.
545 * mdebugread.c: Remove _initialize_mdebugread prototype.
546 * memattr.c: Remove _initialize_mem prototype.
547 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
548 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
549 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
550 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
551 * mi/mi-main.c: Remove _initialize_mi_main prototype.
552 * microblaze-linux-tdep.c: Remove
553 _initialize_microblaze_linux_tdep prototype.
554 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
555 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
556 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
557 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
558 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
559 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
560 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
561 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
562 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
563 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
564 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
565 prototype.
566 * mipsread.c: Remove _initialize_mipsread prototype.
567 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
568 prototype.
569 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
570 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
571 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
572 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
573 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
574 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
575 prototype.
576 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
577 * nto-procfs.c: Remove _initialize_procfs prototype.
578 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
579 * objc-lang.c: Remove _initialize_objc_language prototype.
580 * objfiles.c: Remove _initialize_objfiles prototype.
581 * observer.c: Remove observer_test_first_notification_function,
582 observer_test_second_notification_function,
583 observer_test_third_notification_function, and
584 _initialize_observer prototypes.
585 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
586 * osabi.c: Remove _initialize_gdb_osabi prototype.
587 * osdata.c: Remove _initialize_osdata prototype.
588 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
589 * parse.c: Remove _initialize_parse prototype.
590 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
591 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
592 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
593 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
594 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
595 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
596 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
597 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
598 * printcmd.c: Remove _initialize_printcmd prototype.
599 * probe.c: Remove _initialize_probe prototype.
600 * proc-api.c: Remove _initialize_proc_api prototype.
601 * proc-events.c: Remove _initialize_proc_events prototype.
602 * proc-service.c: Remove _initialize_proc_service prototype.
603 * procfs.c: Remove _initialize_procfs prototype.
604 * psymtab.c: Remove _initialize_psymtab prototype.
605 * python/python.c: Remove _initialize_python prototype.
606 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
607 * record-btrace.c: Remove _initialize_record_btrace prototype.
608 * record-full.c: Remove _initialize_record_full prototype.
609 * record.c: Remove _initialize_record prototype.
610 * regcache.c: Remove _initialize_regcache prototype.
611 * reggroups.c: Remove _initialize_reggroup prototype.
612 * remote-notif.c: Remove _initialize_notif prototype.
613 * remote-sim.c: Remove _initialize_remote_sim prototype.
614 * remote.c: Remove _initialize_remote prototype.
615 * reverse.c: Remove _initialize_reverse prototype.
616 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
617 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
618 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
619 prototype.
620 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
621 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
622 * rust-exp.y: Remove _initialize_rust_exp prototype.
623 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
624 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
625 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
626 * score-tdep.c: Remove _initialize_score_tdep prototype.
627 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
628 prototype.
629 * ser-go32.c: Remove _initialize_ser_dos prototype.
630 * ser-mingw.c: Remove _initialize_ser_windows prototype.
631 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
632 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
633 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
634 * serial.c: Remove _initialize_serial prototype.
635 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
636 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
637 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
638 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
639 * skip.c: Remove _initialize_step_skip prototype.
640 * sol-thread.c: Remove _initialize_sol_thread prototype.
641 * solib-aix.c: Remove _initialize_solib_aix prototype.
642 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
643 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
644 * solib-frv.c: Remove _initialize_frv_solib prototype.
645 * solib-spu.c: Remove _initialize_spu_solib prototype.
646 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
647 * solib-target.c: Remove _initialize_solib_target prototype.
648 * solib.c: Remove _initialize_solib prototype.
649 * source.c: Remove _initialize_source prototype.
650 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
651 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
652 prototype.
653 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
654 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
655 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
656 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
657 prototype.
658 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
659 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
660 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
661 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
662 prototype.
663 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
664 prototype.
665 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
666 prototype.
667 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
668 prototype.
669 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
670 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
671 prototype.
672 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
673 prototype.
674 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
675 prototype.
676 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
677 prototype.
678 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
679 prototype.
680 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
681 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
682 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
683 * stabsread.c: Remove _initialize_stabsread prototype.
684 * stack.c: Remove _initialize_stack prototype.
685 * stap-probe.c: Remove _initialize_stap_probe prototype.
686 * std-regs.c: Remove _initialize_frame_reg prototype.
687 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
688 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
689 * symfile.c: Remove _initialize_symfile prototype.
690 * symmisc.c: Remove _initialize_symmisc prototype.
691 * symtab.c: Remove _initialize_symtab prototype.
692 * target-dcache.c: Remove _initialize_target_dcache prototype.
693 * target-descriptions.c: Remove _initialize_target_descriptions
694 prototype.
695 * thread.c: Remove _initialize_thread prototype.
696 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
697 prototype.
698 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
699 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
700 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
701 prototype.
702 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
703 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
704 * tracefile.c: Remove _initialize_tracefile prototype.
705 * tracepoint.c: Remove _initialize_tracepoint prototype.
706 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
707 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
708 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
709 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
710 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
711 * tui/tui-win.c: Remove _initialize_tui_win prototype.
712 * tui/tui.c: Remove _initialize_tui prototype.
713 * typeprint.c: Remove _initialize_typeprint prototype.
714 * user-regs.c: Remove _initialize_user_regs prototype.
715 * utils.c: Remove _initialize_utils prototype.
716 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
717 * valarith.c: Remove _initialize_valarith prototype.
718 * valops.c: Remove _initialize_valops prototype.
719 * valprint.c: Remove _initialize_valprint prototype.
720 * value.c: Remove _initialize_values prototype.
721 * varobj.c: Remove _initialize_varobj prototype.
722 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
723 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
724 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
725 * windows-nat.c: Remove _initialize_windows_nat,
726 _initialize_check_for_gdb_ini, and _initialize_loadable
727 prototypes.
728 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
729 * xcoffread.c: Remove _initialize_xcoffread prototype.
730 * xml-support.c: Remove _initialize_xml_support prototype.
731 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
732 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
733 prototype.
734 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
735 prototype.
736 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
737
a611b5cb
KS
7382017-09-08 Keith Seitz <keiths@redhat.com>
739
740 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
741 field.
742
469412dd
CW
7432017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
744
745 * f-valprint.c (f_val_print): Remove check for one byte
746 sized integers. Remove printing of character type.
747
a5ad232b
FP
7482017-09-08 Frank Penczek <frank.penczek@intel.com>
749 Christoph Weinmann <christoph.t.weinmann@intel.com>
750 Bernhard Heckel <bernhard.heckel@intel.com>
751
752 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
753 to maintain proper indentation when printing pointers/refs.
754
e5014227
JB
7552017-09-07 Joel Brobecker <brobecker@adacore.com>
756
757 GDB 8.0.1 released.
758
63c99141
JB
7592017-09-07 Joel Brobecker <brobecker@adacore.com>
760
761 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
762
69c1e056
TT
7632017-09-05 Tom Tromey <tom@tromey.com>
764
765 * parse.c (funcall_chain): Now a std::vector.
766 (start_arglist, end_arglist): Simplify.
767 (free_funcalls): Remove.
768 (parse_exp_in_context_1): Remove cleanup.
769
fef704bf
TT
7702017-09-05 Tom Tromey <tom@tromey.com>
771
772 * go-exp.y (go_parse): Don't create a cleanup.
773
5613c585
TT
7742017-09-05 Tom Tromey <tom@tromey.com>
775
776 * d-exp.y (PrimaryExpression): Use std::string.
777 (d_parse): Don't create a cleanup.
778
eae49211
TT
7792017-09-05 Tom Tromey <tom@tromey.com>
780
781 * utils.c (do_clear_parser_state): Remove.
782 (make_cleanup_clear_parser_state): Remove.
783 * p-exp.y (pascal_parse): Use scoped_restore.
784 * m2-exp.y (m2_parse): Use scoped_restore.
785 * f-exp.y (f_parse): Use scoped_restore.
786 * d-exp.y (d_parse): Use scoped_restore.
787 * c-exp.y (c_parse): Use scoped_restore.
788 * ada-exp.y (ada_parse): Use scoped_restore.
789 * utils.h (make_cleanup_clear_parser_state): Remove.
790
73b9be8b
KS
7912017-09-06 Keith Seitz <keiths@redhat.com>
792
793 * dwarf2read.c (dw2_linkage_name_attr): New function.
794 (dw2_linkage_name): New function.
795 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
796 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
797 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
798
a102602b
KR
7992017-09-06 Kamil Rytarowski <n54@gmx.com>
800
801 * config/djgpp/djconfig.sh: Correct shell portability issue.
802
28ad437d
KR
8032017-09-06 Kamil Rytarowski <n54@gmx.com>
804
805 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
806
351787dd
JB
8072017-09-06 John Baldwin <jhb@FreeBSD.org>
808
809 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
810 * NEWS: Mention new FreeBSD/mips native configuration.
811 * configure.host: Add aarch64*-*-freebsd*.
812 * configure.nat: Likewise.
813 * aarch64-fbsd-nat.c: New file.
814
c0f84956
JB
8152017-09-06 John Baldwin <jhb@FreeBSD.org>
816
817 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
818 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
819 * NEWS: Mention new FreeBSD/aarch64 target.
820 * configure.tgt: Add aarch64*-*-freebsd*.
821 * aarch64-fbsd-tdep.c: New file.
822 * aarch64-fbsd-tdep.h: New file.
823
7610297a
KR
8242017-09-06 Kamil Rytarowski <n54@gmx.com>
825
826 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
827
fbd1b771
JK
8282017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
829
830 * parse.c (find_minsym_type_and_address): Don't relocate addresses
831 of TLS symbols.
832
5ca79eae
PW
8332017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
834
835 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
836 call.
837
bf93d7ba
SM
8382017-09-05 Simon Marchi <simon.marchi@ericsson.com>
839
840 * infrun.c (follow_exec): Call add_thread after
841 target_find_description.
842
1bb7c059
SM
8432017-09-05 Simon Marchi <simon.marchi@ericsson.com>
844
845 * infrun.c (handle_inferior_event_1): When exec'ing, read
846 stop_pc after follow_exec.
847
fc809827
SM
8482017-09-05 Simon Marchi <simon.marchi@ericsson.com>
849
850 * remote.c (process_g_packet): Update error message.
851
d2fcdd85
YQ
8522017-09-05 Yao Qi <yao.qi@linaro.org>
853
854 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
855 targets.
856
e69570ee
PA
8572017-09-05 Pedro Alves <palves@redhat.com>
858
859 * eval.c (eval_call, evaluate_funcall): New functions, factored
860 out from ...
861 (evaluate_subexp_standard): ... this.
862
22916b07
YQ
8632017-09-05 Yao Qi <yao.qi@linaro.org>
864
865 * amd64-tdep.c (amd64_target_description): Create target
866 descriptions.
867 (_initialize_amd64_tdep): Don't call functions
868 initialize_tdesc_amd64_*. Add self tests.
869 * arch/amd64.c (amd64_create_target_description): Add parameter
870 is_linux. Call set_tdesc_osabi if is_linux is true.
871 * arch/amd64.h (amd64_create_target_description): Update the
872 declaration.
873 * arch/i386.c (i386_create_target_description): Add parameter
874 is_linux. Call set_tdesc_osabi if is_linux is true.
875 * arch/i386.h (i386_create_target_description): Update
876 declaration.
877 * configure.tgt: Add i386.o to gdb_target_obs.
878 * features/Makefile (XMLTOC): Remove i386/*.xml.
879 * features/i386/amd64-avx-avx512.c: Remove.
880 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
881 * features/i386/amd64-avx-mpx.c: Remove.
882 * features/i386/amd64-avx.c: Remove.
883 * features/i386/amd64-mpx.c: Remove.
884 * features/i386/amd64.c: Remove.
885 * features/i386/i386-avx-avx512.c: Remove.
886 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
887 * features/i386/i386-avx-mpx.c: Remove.
888 * features/i386/i386-avx.c: Remove.
889 * features/i386/i386-mmx.c: Remove.
890 * features/i386/i386-mpx.c: Remove.
891 * features/i386/i386.c: Remove.
892 * i386-tdep.c: Don't include features/i386/i386*.c., include
893 target-descriptions.h and arch/i386.h.
894 (i386_target_description): Create target descriptions.
895 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
896 functions. Do self tests.
897
0854b7b1
YQ
8982017-09-05 Yao Qi <yao.qi@linaro.org>
899
900 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
901 * features/i386/amd64-avx-avx512-linux.c: Removed.
902 * features/i386/amd64-avx-linux.c: Removed.
903 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
904 * features/i386/amd64-avx-mpx-linux.c: Removed.
905 * features/i386/amd64-linux.c: Removed.
906 * features/i386/amd64-mpx-linux.c: Removed.
907 * features/i386/x32-avx-avx512-linux.c: Removed.
908 * features/i386/x32-avx-linux.c: Removed.
909 * features/i386/x32-linux.c: Removed.
910
b4570e4b
YQ
9112017-09-05 Yao Qi <yao.qi@linaro.org>
912
913 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
914 features/i386/*.c.
915 (amd64_linux_read_description): Call
916 amd64_create_target_description.
917 * arch/amd64.c: New file.
918 * arch/amd64.h: New file.
919 * configure.tgt (x86_64-*-linux*): Append amd64.o.
920 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
921
6c73f67f
YQ
9222017-09-05 Yao Qi <yao.qi@linaro.org>
923
924 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
925 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
926 (amd64_linux_read_description): Create target descriptions.
927 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
928 functions. Add unit tests.
929 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
930 x32-core.xml.
931 * features/i386/64bit-avx.c: Generated.
932 * features/i386/64bit-avx512.c: Generated.
933 * features/i386/64bit-core.c: Generated.
934 * features/i386/64bit-linux.c: Generated.
935 * features/i386/64bit-mpx.c: Generated.
936 * features/i386/64bit-pkeys.c: Generated.
937 * features/i386/64bit-segments.c: Generated.
938 * features/i386/64bit-sse.c: Generated.
939 * features/i386/x32-core.c: Generated.
940 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
941 c files for amd64-linux and x32-linux.
942
9d3d478b
YQ
9432017-09-05 Yao Qi <yao.qi@linaro.org>
944
945 * amd64-linux-tdep.c (amd64_linux_read_description): New
946 function.
947 (amd64_linux_core_read_description): Call
948 amd64_linux_read_description.
949 (amd64_linux_init_abi): Likewise.
950 (amd64_x32_linux_init_abi): Likewise.
951 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
952 * x86-linux-nat.c (x86_linux_read_description): Call
953 amd64_linux_read_description.
954
b9f1d50f
YQ
9552017-09-05 Yao Qi <yao.qi@linaro.org>
956
957 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
958 comments.
959
188c9e6d
YQ
9602017-09-05 Yao Qi <yao.qi@linaro.org>
961
962 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
963 * features/i386/i386-avx-avx512-linux.c: Remove.
964 * features/i386/i386-avx-linux.c: Remove.
965 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
966 * features/i386/i386-avx-mpx-linux.c: Remove.
967 * features/i386/i386-linux.c: Remove.
968 * features/i386/i386-mmx-linux.c: Remove.
969 * features/i386/i386-mpx-linux.c: Remove.
970
5f035c07
YQ
9712017-09-05 Yao Qi <yao.qi@linaro.org>
972
973 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
974 (SFILES): Add arch/i386.c.
975 (HFILES_NO_SRCDIR): Add arch/i386.h.
976 * arch/i386.c: New file.
977 * arch/i386.h: New file.
978 * arch/tdesc.h (allocate_target_description): Declare.
979 (set_tdesc_architecture): Declare.
980 (set_tdesc_osabi): Declare.
981 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
982 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
983 include arch/i386.h.
984 (i386_linux_read_description): Remove code and call
985 i386_create_target_description.
986 (set_tdesc_architecture): New function.
987 (set_tdesc_osabi): New function.
988 * target-descriptions.h (allocate_target_description): Remove.
989
0abe8a89
YQ
9902017-09-05 Yao Qi <yao.qi@linaro.org>
991
992 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
993 * target-descriptions.c (tdesc_create_feature): Likewise, and
994 adjust code.
995 * features/i386/32bit-avx.c: Re-generated.
996 * features/i386/32bit-avx512.c: Re-generated.
997 * features/i386/32bit-core.c: Re-generated.
998 * features/i386/32bit-linux.c: Re-generated.
999 * features/i386/32bit-mpx.c: Re-generated.
1000 * features/i386/32bit-pkeys.c: Re-generated.
1001 * features/i386/32bit-sse.c: Re-generated.
1002
0a188386
YQ
10032017-09-05 Yao Qi <yao.qi@linaro.org>
1004
1005 * regformats/regdef.h (struct reg): Override operator == and !=.
1006
f49ff000
YQ
10072017-09-05 Yao Qi <yao.qi@linaro.org>
1008
1009 * arch/tdesc.h: New file.
1010 * regformats/regdat.sh: Generate code using tdesc_create_reg.
1011 * target-descriptions.c: Update comments.
1012 * target-descriptions.h: Include "arch/tdesc.h". Remove the
1013 declarations.
1014 * features/i386/32bit-avx.c: Re-generated.
1015 * features/i386/32bit-avx512.c: Re-generated.
1016 * features/i386/32bit-core.c: Re-generated.
1017 * features/i386/32bit-linux.c: Re-generated.
1018 * features/i386/32bit-mpx.c: Re-generated.
1019 * features/i386/32bit-pkeys.c: Re-generated.
1020 * features/i386/32bit-sse.c: Re-generated.
1021
f7000548
YQ
10222017-09-05 Yao Qi <yao.qi@linaro.org>
1023
1024 * regformats/regdat.sh: Update generated code.
1025
c9a5e2a5
YQ
10262017-09-05 Yao Qi <yao.qi@linaro.org>
1027
1028 * regformats/regdat.sh: Adjust code order.
1029
d6b687ac
SM
10302017-09-05 Simon Marchi <simon.marchi@ericsson.com>
1031
1032 * expprint.c (dump_subexp_body_standard): Use constant format
1033 string in fprintf_filtered call.
1034
a379bfd0
JB
10352017-09-04 John Baldwin <jhb@FreeBSD.org>
1036
1037 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
1038 NetBSD/i386.
1039 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
1040
f7efc967
JB
10412017-09-04 John Baldwin <jhb@FreeBSD.org>
1042
1043 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
1044
c49fbc6c
JB
10452017-09-04 John Baldwin <jhb@FreeBSD.org>
1046
1047 * bsd-kvm.o: Define _KMEMUSER.
1048 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
1049 * configure: Regenerate.
1050
26562e73
JB
10512017-09-04 John Baldwin <jhb@FreeBSD.org>
1052
1053 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
1054 * i386-fbsd-nat.c: Likewise.
1055
31cf1487
JB
10562017-09-04 John Baldwin <jhb@FreeBSD.org>
1057
1058 * unittests/array-view-selftests.c: Add include of <array>.
1059
5b9f8a7c
JB
10602017-09-04 John Baldwin <jhb@FreeBSD.org>
1061
1062 * spu-tdep.c (flush_ea_cache): Add missing argument to
1063 call_function_by_hand.
1064
d69cf9b2
PA
10652017-09-04 Pedro Alves <palves@redhat.com>
1066
1067 * NEWS (Safer support for debugging with no debug info): New.
1068
3693fdb3
PA
10692017-09-04 Pedro Alves <palves@redhat.com>
1070
1071 * c-exp.y (function_method, function_method_void): Add current
1072 instance flags to TYPE_INSTANCE.
1073 * dwarf2read.c (check_modifier): New.
1074 (compute_delayed_physnames): Assert that only C++ adds delayed
1075 physnames. Mark fn_fields as const/volatile depending on
1076 physname.
1077 * eval.c (make_params): New type_instance_flags parameter. Use
1078 it as the new type's instance flags.
1079 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
1080 flags element and pass it to make_params.
1081 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
1082 instance flags element.
1083 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
1084 * gdbtypes.h: Include "enum-flags.h".
1085 (type_instance_flags): New enum-flags type.
1086 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
1087 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
1088 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
1089 (follow_type_instance_flags): New function.
1090 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
1091 * parser-defs.h (follow_type_instance_flags): Declare.
1092 * valops.c (value_struct_elt_for_reference): const/volatile must
1093 match too.
1094
e68cb8e0
PA
10952017-09-04 Pedro Alves <palves@redhat.com>
1096
1097 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
1098 function/method scopes; lookup the nested name as a function local
1099 static variable.
1100
858be34c
PA
11012017-09-04 Pedro Alves <palves@redhat.com>
1102
1103 (%type <voidval>): Add function_method.
1104 * c-exp.y (exp): New production for calls with no arguments.
1105 (function_method, function_method_void_or_typelist): New
1106 productions.
1107 (exp): New production for "method()::static_var".
1108 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
1109 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
1110 Handle OP_FUNC_STATIC_VAR.
1111 * parse.c (operator_length_standard):
1112 Handle OP_FUNC_STATIC_VAR.
1113
dd5901a6
PA
11142017-09-04 Pedro Alves <palves@redhat.com>
1115
1116 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
1117 handling.
1118 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
1119 Ditto.
1120 * parse.c (operator_length_standard, operator_check_standard):
1121 Ditto.
1122 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
1123
46a4882b
PA
11242017-09-04 Pedro Alves <palves@redhat.com>
1125
1126 * ax-gdb.c: Include "typeprint.h".
1127 (gen_expr_for_cast): New function.
1128 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
1129 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
1130 type is unknown.
1131 * dwarf2read.c (new_symbol_full): Fallback to int instead of
1132 nodebug_data_symbol.
1133 * eval.c: Include "typeprint.h".
1134 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
1135 Error out if symbol has unknown type.
1136 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
1137 evaluate_subexp_for_cast.
1138 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
1139 OP_VAR_MSYM_VALUE.
1140 (evaluate_subexp_for_cast): New function.
1141 * gdbtypes.c (init_nodebug_var_type): New function.
1142 (objfile_type): Use it to initialize types of variables with no
1143 debug info.
1144 * typeprint.c (error_unknown_type): New.
1145 * typeprint.h (error_unknown_type): New declaration.
1146 * compile/compile-c-types.c (convert_type_basic): Handle
1147 TYPE_CODE_ERROR; warn and fallback to int for variables with
1148 unknown type.
1149
fe13dfec
PA
11502017-09-04 Pedro Alves <palves@redhat.com>
1151
1152 * eval.c (evaluate_var_value): New function, factored out from ...
1153 (evaluate_subexp_standard): ... here.
1154
d008ee21
PA
11552017-09-04 Pedro Alves <palves@redhat.com>
1156
1157 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
1158 Remove useless assignments to 'op'.
1159
827d0c51
PA
11602017-09-04 Pedro Alves <palves@redhat.com>
1161
1162 * eval.c (eval_skip_value): New function.
1163 (evaluate_subexp_standard): Use it.
1164
2c5a2be1
PA
11652017-09-04 Pedro Alves <palves@redhat.com>
1166
1167 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
1168 function name from symbol/minsym and pass it to
1169 error_call_unknown_return_type.
1170
74ea4be4
PA
11712017-09-04 Pedro Alves <palves@redhat.com>
1172
1173 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
1174 * ax-gdb.c (gen_msym_var_ref): New function.
1175 (gen_expr): Handle OP_VAR_MSYM_VALUE.
1176 * eval.c (evaluate_var_msym_value): New function.
1177 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
1178 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
1179 to call_function_by_hand.
1180 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
1181 Handle OP_VAR_MSYM_VALUE.
1182 (union exp_element) <msymbol>: New field.
1183 * minsyms.h (struct type): Forward declare.
1184 (find_minsym_type_and_address): Declare.
1185 * parse.c (write_exp_elt_msym): New function.
1186 (write_exp_msymbol): Delete, refactored as ...
1187 (find_minsym_type_and_address): ... this new function.
1188 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
1189 (operator_length_standard, operator_check_standard): Handle
1190 OP_VAR_MSYM_VALUE.
1191 * std-operator.def (OP_VAR_MSYM_VALUE): New.
1192
7022349d
PA
11932017-09-04 Pedro Alves <palves@redhat.com>
1194
1195 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
1196 TYPE_GNU_IFUNC specially here. Throw error if return type is
1197 unknown.
1198 * ada-typeprint.c (print_func_type): Handle functions with unknown
1199 return type.
1200 * c-typeprint.c (c_type_print_base): Handle functions and methods
1201 with unknown return type.
1202 * compile/compile-c-symbols.c (convert_symbol_bmsym)
1203 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
1204 * compile/compile-c-types.c: Include "objfiles.h".
1205 (convert_func): For functions with unknown return type, warn and
1206 default to int.
1207 * compile/compile-object-run.c (compile_object_run): Adjust call
1208 to call_function_by_hand_dummy.
1209 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
1210 call_function_by_hand.
1211 * eval.c (evaluate_subexp_standard): Adjust calls to
1212 call_function_by_hand. Handle functions and methods with unknown
1213 return type. Pass expect_type to call_function_by_hand.
1214 * f-typeprint.c (f_type_print_base): Handle functions with unknown
1215 return type.
1216 * gcore.c (call_target_sbrk): Adjust call to
1217 call_function_by_hand.
1218 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
1219 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
1220 an integer address type instead of nodebug.
1221 * guile/scm-value.c (gdbscm_value_call): Adjust call to
1222 call_function_by_hand.
1223 * infcall.c (error_call_unknown_return_type): New function.
1224 (call_function_by_hand): New "default_return_type" parameter.
1225 Pass it down.
1226 (call_function_by_hand_dummy): New "default_return_type"
1227 parameter. Use it instead of defaulting to int. If there's no
1228 default and the return type is unknown, throw an error. If
1229 there's a default return type, and the called function has no
1230 debug info, then assume the function is prototyped.
1231 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
1232 New "default_return_type" parameter.
1233 (error_call_unknown_return_type): New declaration.
1234 * linux-fork.c (call_lseek): Cast return type of lseek.
1235 (inferior_call_waitpid, checkpoint_command): Adjust calls to
1236 call_function_by_hand.
1237 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
1238 calls to call_function_by_hand.
1239 * m2-typeprint.c (m2_procedure): Handle functions with unknown
1240 return type.
1241 * objc-lang.c (lookup_objc_class, lookup_child_selector)
1242 (value_nsstring, print_object_command): Adjust calls to
1243 call_function_by_hand.
1244 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
1245 functions with unknown return type.
1246 (pascal_type_print_func_varspec_suffix): New function.
1247 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
1248 TYPE_CODE_METHOD>: Use it.
1249 * python/py-value.c (valpy_call): Adjust call to
1250 call_function_by_hand.
1251 * rust-lang.c (rust_evaluate_funcall): Adjust call to
1252 call_function_by_hand.
1253 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
1254 call_function_by_hand.
1255 * valops.c (value_allocate_space_in_inferior): Adjust call to
1256 call_function_by_hand.
1257 * typeprint.c (type_print_unknown_return_type): New function.
1258 * typeprint.h (type_print_unknown_return_type): New declaration.
1259
54990598
PA
12602017-09-04 Pedro Alves <palves@redhat.com>
1261
1262 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
1263 types with more than one parameter as prototyped.
1264
9a24775b
PA
12652017-09-04 Pedro Alves <palves@redhat.com>
1266
1267 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
1268 (disassemble_command): Use gdb_disassembly_flags instead of bare
1269 int.
1270 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
1271 (dump_insns, do_mixed_source_and_assembly_deprecated)
1272 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
1273 Use gdb_disassembly_flags instead of bare int.
1274 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
1275 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
1276 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
1277 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
1278 (enum gdb_disassembly_flag): ... values of this new enumeration.
1279 (gdb_disassembly_flags): Define.
1280 (gdb_disassembly)
1281 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
1282 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
1283 gdb_disassembly_flags instead of bare int.
1284 * record-btrace.c (btrace_insn_history)
1285 (record_btrace_insn_history, record_btrace_insn_history_range)
1286 (record_btrace_insn_history_from): Use gdb_disassembly_flags
1287 instead of bare int.
1288 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
1289 Use gdb_disassembly_flags instead of bare int.
1290 * target-debug.h (target_debug_print_gdb_disassembly_flags):
1291 Define.
1292 * target-delegates.c: Regenerate.
1293 * target.c (target_insn_history, target_insn_history_from)
1294 (target_insn_history_range): Use gdb_disassembly_flags instead of
1295 bare int.
1296 * target.h: Include "disasm.h".
1297 (struct target_ops) <to_insn_history, to_insn_history_from,
1298 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
1299 int.
1300 (target_insn_history, target_insn_history_from)
1301 (target_insn_history_range): Use gdb_disassembly_flags instead of
1302 bare int.
1303
80a65e9b
SM
13042017-09-04 Simon Marchi <simon.marchi@ericsson.com>
1305
1306 * cli/cli-script.c (build_command_line): For if/while commands,
1307 check whether args is empty.
1308
6b66338c
SM
13092017-09-04 Simon Marchi <simon.marchi@ericsson.com>
1310
1311 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
1312 (enum command_control_type): Likewise.
1313 (struct command_line): Likewise.
1314 (free_command_lines): Likewise.
1315 (struct command_lines_deleter): Likewise.
1316 (command_line_up): Likewise.
1317 (read_command_lines): Likewise.
1318 (read_command_lines_1): Likewise.
1319 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
1320 (enum command_control_type): Likewise.
1321 (struct command_line): Likewise.
1322 (free_command_lines): Likewise.
1323 (struct command_lines_deleter): Likewise.
1324 (command_line_up): Likewise.
1325 (read_command_lines): Likewise.
1326 (read_command_lines_1): Likewise.
1327 * breakpoint.h: Include cli/cli-script.h.
1328 * extension-priv.h: Likewise.
1329 * gdbcmd.h: Likewise.
1330
51abb421
PA
13312017-09-04 Pedro Alves <palves@redhat.com>
1332
1333 * ada-lang.c (is_known_support_routine): Move sal declaration to
1334 where it is initialized.
1335 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
1336 (parse_breakpoint_sals, decode_static_tracepoint_spec)
1337 (clear_command, update_static_tracepoint): Remove init_sal
1338 references. Move declarations closer to initializations.
1339 * cli/cli-cmds.c (list_command): Move sal declarations closer to
1340 initializations.
1341 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
1342 references. Move sal declarations closer to initializations.
1343 * frame.c (find_frame_sal): Return a symtab_and_line via function
1344 return instead of output parameter. Remove init_sal references.
1345 * frame.h (find_frame_sal): Return a symtab_and_line via function
1346 return instead of output parameter.
1347 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
1348 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
1349 instead of memset.
1350 (gdbscm_find_pc_line): Remove init_sal reference.
1351 * infcall.c (call_function_by_hand_dummy): Remove init_sal
1352 references. Move declarations closer to initializations.
1353 * infcmd.c (set_step_frame): Update. Move declarations closer to
1354 initializations.
1355 (finish_backward): Remove init_sal references. Move declarations
1356 closer to initializations.
1357 * infrun.c (process_event_stop_test, handle_step_into_function)
1358 (insert_hp_step_resume_breakpoint_at_frame)
1359 (insert_step_resume_breakpoint_at_caller): Likewise.
1360 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
1361 (symbol_to_sal): Likewise.
1362 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
1363 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
1364 to its initialization.
1365 * reverse.c (save_bookmark_command): Use new/delete. Remove
1366 init_sal references. Move declarations closer to initializations.
1367 * source.c (get_current_source_symtab_and_line): Remove brace
1368 initialization.
1369 (set_current_source_symtab_and_line): Now takes the sal by const
1370 reference. Remove brace initialization.
1371 (line_info): Remove init_sal reference.
1372 * source.h (set_current_source_symtab_and_line): Now takes a
1373 symtab_and_line via const reference.
1374 * stack.c (set_current_sal_from_frame): Adjust.
1375 (print_frame_info): Adjust.
1376 (get_last_displayed_sal): Return the sal via function return
1377 instead of via output parameter. Simplify.
1378 (frame_info): Adjust.
1379 * stack.h (get_last_displayed_sal): Return the sal via function
1380 return instead of via output parameter.
1381 * symtab.c (init_sal): Delete.
1382 (find_pc_sect_line): Remove init_sal references. Move
1383 declarations closer to initializations.
1384 (find_function_start_sal): Remove init_sal references. Move
1385 declarations closer to initializations.
1386 * symtab.h (struct symtab_and_line): In-class initialize all
1387 fields.
1388 * tracepoint.c (set_traceframe_context)
1389 (print_one_static_tracepoint_marker): Remove init_sal references.
1390 Move declarations closer to initializations.
1391 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
1392 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
1393 declarations closer to initializations.
1394 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
1395 init_sal references. Adjust.
1396
6c5b2ebe
PA
13972017-09-04 Pedro Alves <palves@redhat.com>
1398
1399 * ax-gdb.c (agent_command_1): Use range-for.
1400 * break-catch-throw.c (re_set_exception_catchpoint): Update.
1401 * breakpoint.c: Include "common/array-view.h".
1402 (init_breakpoint_sal, create_breakpoint_sal): Change sals
1403 parameter from struct symtabs_and_lines to
1404 array_view<symtab_and_line>. Adjust. Use range-for. Update.
1405 (breakpoint_sals_to_pc): Change sals parameter from struct
1406 symtabs_and_lines to std::vector reference.
1407 (check_fast_tracepoint_sals): Change sals parameter from struct
1408 symtabs_and_lines to std::array_view. Use range-for.
1409 (decode_static_tracepoint_spec): Return a std::vector instead of
1410 symtabs_and_lines. Update.
1411 (create_breakpoint): Update.
1412 (break_range_command, until_break_command, clear_command): Update.
1413 (base_breakpoint_decode_location, bkpt_decode_location)
1414 (bkpt_probe_create_sals_from_location)
1415 (bkpt_probe_decode_location, tracepoint_decode_location)
1416 (tracepoint_probe_decode_location)
1417 (strace_marker_create_sals_from_location): Return a std::vector
1418 instead of symtabs_and_lines.
1419 (strace_marker_create_breakpoints_sal): Update.
1420 (strace_marker_decode_location): Return a std::vector instead of
1421 symtabs_and_lines. Update.
1422 (update_breakpoint_locations): Change struct symtabs_and_lines
1423 parameters to gdb::array_view. Adjust.
1424 (location_to_sals): Return a std::vector instead of
1425 symtabs_and_lines. Update.
1426 (breakpoint_re_set_default): Use std::vector instead of struct
1427 symtabs_and_lines.
1428 (decode_location_default): Return a std::vector instead of
1429 symtabs_and_lines. Update.
1430 * breakpoint.h: Include "common/array-view.h".
1431 (struct breakpoint_ops) <decode_location>: Now returns a
1432 std::vector instead of returning a symtabs_and_lines via output
1433 parameter.
1434 (update_breakpoint_locations): Change sals parameters to use
1435 gdb::array_view.
1436 * cli/cli-cmds.c (edit_command, list_command): Update to use
1437 std::vector and gdb::array_view.
1438 (ambiguous_line_spec): Adjust to use gdb::array_view and
1439 range-for.
1440 (compare_symtabs): Rename to ...
1441 (cmp_symtabs): ... this. Change parameters to symtab_and_line
1442 const reference and adjust.
1443 (filter_sals): Rewrite using std::vector and standard algorithms.
1444 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
1445 (jump_command): Update to use std::vector.
1446 * linespec.c (struct linespec_state) <canonical_names>: Update
1447 comment.
1448 (add_sal_to_sals_basic): Delete.
1449 (add_sal_to_sals, filter_results, convert_results_to_lsals)
1450 (decode_line_2, create_sals_line_offset)
1451 (convert_address_location_to_sals, convert_linespec_to_sals)
1452 (convert_explicit_location_to_sals, parse_linespec)
1453 (event_location_to_sals, decode_line_full, decode_line_1)
1454 (decode_line_with_current_source)
1455 (decode_line_with_last_displayed, decode_objc)
1456 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
1457 (linespec_result::~linespec_result): Adjust to use std::vector
1458 instead of symtabs_and_lines.
1459 * linespec.h (linespec_sals::sals): Now a std::vector.
1460 (struct linespec_result): Use std::vector, bool, and in-class
1461 initialization.
1462 (decode_line_1, decode_line_with_current_source)
1463 (decode_line_with_last_displayed): Return std::vector.
1464 * macrocmd.c (info_macros_command): Use std::vector.
1465 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
1466 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
1467 std::vector.
1468 * probe.h (parse_probes): Return a std::vector.
1469 * python/python.c (gdbpy_decode_line): Use std::vector and
1470 gdb::array_view.
1471 * source.c (select_source_symtab, line_info): Use std::vector.
1472 * stack.c (func_command): Use std::vector.
1473 * symtab.h (struct symtabs_and_lines): Delete.
1474 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
1475
7c44b49c
PA
14762017-09-04 Pedro Alves <palves@redhat.com>
1477
1478 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1479 unittests/array-view-selftests.c.
1480 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
1481 * common/array-view.h: New file.
1482 * unittests/array-view-selftests.c: New file.
1483
e439fa14
PA
14842017-09-04 Pedro Alves <palves@redhat.com>
1485
1486 * cli/cli-cmds.c (edit_command): Pass message to
1487 ambiguous_line_spec.
1488 (list_command): Pass message to ambiguous_line_spec. Say
1489 "first"/"last" instead of "start" and "end" to be consistent with
1490 the manual.
1491 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
1492 them to print formatted message.
1493
7525b645
PA
14942017-09-04 Pedro Alves <palves@redhat.com>
1495
1496 * btrace.c (ftrace_add_pt): Pass btrace_insn to
1497 ftrace_update_insns by reference instead of pointer.
1498
badc0020
YQ
14992017-09-04 Yao Qi <yao.qi@linaro.org>
1500
1501 * i386-go32-tdep.c: Include x86-xstate.h.
1502 (i386_go32_init_abi): Call i386_target_description.
1503 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
1504 if xcr0 is X86_XSTATE_X87_MASK.
1505 * i386-tdep.h (tdesc_i386): Remove the declaration.
1506 (tdesc_i386_mmx): Likewise.
1507
d78bdb54
YQ
15082017-09-04 Yao Qi <yao.qi@linaro.org>
1509
1510 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
1511 X86_XSTATE_SSE_MASK instead of 0.
1512
ca1fa5ee
YQ
15132017-09-04 Yao Qi <yao.qi@linaro.org>
1514
1515 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
1516 i386_target_description.
1517 * i386-fbsd-nat.c (i386fbsd_read_description): Call
1518 i386_target_description.
1519 * i386-tdep.c (i386_gdbarch_init): Likewise.
1520
2434b019
YQ
15212017-09-04 Yao Qi <yao.qi@linaro.org>
1522
1523 * amd64-darwin-tdep.c: Include "x86-xstate.h".
1524 (x86_darwin_init_abi_64): Call amd64_target_description.
1525 * amd64-dicos-tdep.c: Likewise.
1526 * amd64-fbsd-nat.c: Likewise.
1527 * amd64-fbsd-tdep.c: Likewise.
1528 * amd64-nbsd-tdep.c: Likewise.
1529 * amd64-obsd-tdep.c: Likewise.
1530 * amd64-sol2-tdep.c: Likewise.
1531 * amd64-windows-tdep.c: Likewise.
1532 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
1533
0860c437
SM
15342017-09-04 Simon Marchi <simon.marchi@ericsson.com>
1535
1536 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
1537 (btrace_function) <insn>: Change type to use std::vector.
1538 * btrace.c (ftrace_debug, ftrace_call_num_insn,
1539 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
1540 ftrace_update_insns, ftrace_compute_global_level_offset,
1541 btrace_stitch_bts, btrace_clear, btrace_insn_get,
1542 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
1543 change to std::vector.
1544 (ftrace_update_insns): Adjust to change to std::vector, change
1545 type of INSN parameter.
1546 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
1547 * record-btrace.c (btrace_call_history_insn_range,
1548 btrace_compute_src_line_range,
1549 record_btrace_frame_prev_register): Adjust to change to
1550 std::vector.
1551 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
1552 to change to std::vector.
1553
0638b7f9
TT
15542017-09-03 Tom Tromey <tom@tromey.com>
1555
1556 * corefile.c (reopen_exec_file): Use std::string.
1557
8f84fb0e
TT
15582017-09-03 Tom Tromey <tom@tromey.com>
1559
1560 * compile/compile.c (compile_register_name_mangled): Return
1561 std::string.
1562 * compile/compile-loc2c.c (pushf_register_address): Update.
1563 (pushf_register): Update.
1564 * compile/compile-c-types.c (convert_array): Update.
1565 * compile/compile-c-symbols.c (generate_vla_size): Update.
1566 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
1567 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
1568 (convert_one_symbol): Update.
1569 (generate_c_for_for_one_variable): Update.
1570 * compile/compile-c-support.c (c_get_range_decl_name): Return a
1571 std::string.
1572 (generate_register_struct): Update.
1573 * compile/compile-internal.h (c_get_range_decl_name): Return a
1574 std::string.
1575 (compile_register_name_mangled): Return std::string.
1576
18e9961f
TT
15772017-09-03 Tom Tromey <tom@tromey.com>
1578
1579 * utils.c (perror_string): Return a std::string.
1580 (throw_perror_with_name, perror_warning_with_name): Update.
1581
45343786
TT
15822017-09-03 Tom Tromey <tom@tromey.com>
1583
1584 * demangle.c (demangle_command): Use std::string,
1585 unique_xmalloc_ptr.
1586
b57af503
TT
15872017-09-03 Tom Tromey <tom@tromey.com>
1588
1589 * cli/cli-setshow.c (do_set_command): Use std::string.
1590
6eecf35f
TT
15912017-09-03 Tom Tromey <tom@tromey.com>
1592
1593 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
1594
56496dd4
TT
15952017-09-03 Tom Tromey <tom@tromey.com>
1596
1597 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
1598
e91a1fa7
TT
15992017-09-03 Tom Tromey <tom@tromey.com>
1600
1601 * mi/mi-cmd-env.c (env_execute_cli_command): Use
1602 gdb::unique_xmalloc_ptr.
1603
7ffd83d7
TT
16042017-09-03 Tom Tromey <tom@tromey.com>
1605
1606 * thread.c (print_thread_info_1): Use string_printf.
1607 (thread_apply_command, thread_apply_all_command): Use
1608 std::string.
1609
1ccbe998
TT
16102017-09-03 Tom Tromey <tom@tromey.com>
1611
1612 * valprint.c (val_print_string): Update.
1613 * gdbcore.h (memory_error_message): Return std::string.
1614 * corefile.c (memory_error_message): Return std::string.
1615 (memory_error): Update.
1616 * breakpoint.c (insert_bp_location): Update.
1617
23fdd69e
SM
16182017-09-03 Simon Marchi <simon.marchi@ericsson.com>
1619
1620 * target/waitstatus.h (target_waitstatus_to_string): Change
1621 return type to std::string.
1622 * target/waitstatus.c (target_waitstatus_to_string): Return
1623 std::string.
1624 * target.h (target_waitstatus_to_string): Remove declaration.
1625 * infrun.c (resume, clear_proceed_status_thread,
1626 print_target_wait_results, do_target_wait, save_waitstatus,
1627 stop_all_threads): Adjust.
1628 * record-btrace.c (record_btrace_wait): Adjust.
1629 * target-debug.h
1630 (target_debug_print_struct_target_waitstatus_p): Adjust.
1631
5c811d30
JK
16322017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
1633
1634 PR gdb/22046
1635 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
1636 detection.
1637
0a2dde4a
SDJ
16382017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
1639
1640 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
1641 for setting/unsetting environment variables on the remote target.
1642 (New remote packets): Add entries for QEnvironmentHexEncoded,
1643 QEnvironmentUnset and QEnvironmentReset.
1644 * common/environ.c (gdb_environ::operator=): Extend method to
1645 handle m_user_set_env_list and m_user_unset_env_list.
1646 (gdb_environ::clear): Likewise.
1647 (match_var_in_string): Change type of first parameter from 'char
1648 *' to 'const char *'.
1649 (gdb_environ::set): Extend method to handle
1650 m_user_set_env_list and m_user_unset_env_list.
1651 (gdb_environ::unset): Likewise.
1652 (gdb_environ::clear_user_set_env): New method.
1653 (gdb_environ::user_set_envp): Likewise.
1654 (gdb_environ::user_unset_envp): Likewise.
1655 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
1656 m_user_unset_env_list on move constructor/assignment.
1657 (unset): Add new default parameter 'update_unset_list = true'.
1658 (clear_user_set_env): New method.
1659 (user_set_envp): Likewise.
1660 (user_unset_envp): Likewise.
1661 (m_user_set_env_list): New std::set.
1662 (m_user_unset_env_list): Likewise.
1663 * common/rsp-low.c (hex2str): New function.
1664 (bin2hex): New overload for bin2hex function.
1665 * common/rsp-low.c (hex2str): New prototype.
1666 (str2hex): New overload prototype.
1667 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
1668 QEnvironmentUnset and QEnvironmentReset.
1669 (remote_protocol_features): Add QEnvironmentHexEncoded,
1670 QEnvironmentUnset and QEnvironmentReset packets.
1671 (send_environment_packet): New function.
1672 (extended_remote_environment_support): Likewise.
1673 (extended_remote_create_inferior): Call
1674 extended_remote_environment_support.
1675 (_initialize_remote): Add QEnvironmentHexEncoded,
1676 QEnvironmentUnset and QEnvironmentReset packet configs.
1677 * unittests/environ-selftests.c (gdb_selftest_env_var):
1678 New variable.
1679 (test_vector_initialization): New function.
1680 (test_init_from_host_environ): Likewise.
1681 (test_reinit_from_host_environ): Likewise.
1682 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
1683 Likewise.
1684 (test_unset_set_empty_vector): Likewise.
1685 (test_vector_clear): Likewise.
1686 (test_std_move): Likewise.
1687 (test_move_constructor):
1688 (test_self_move): Likewise.
1689 (test_set_unset_reset): Likewise.
1690 (run_tests): Rewrite in terms of the functions above.
1691
654670a4
WP
16922017-08-31 Weimin Pan <weimin.pan@oracle.com>
1693
1694 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
1695 (adi_available): Use a temp variable of type CORE_ADDR as argument
1696 3 when calling target_auxv_search.
1697 (adi_normalize_address): Use masks and xor operators to calculate
1698 normalized address.
1699 (adi_read_versions, adi_write_versions, adi_print_versions)
1700 (do_examine, do_assign): Use paddress.
1701
7755ddb7
JB
17022017-08-29 John Baldwin <jhb@FreeBSD.org>
1703
1704 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
1705 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
1706 out of loop and add supply of FIR.
1707 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
1708 add collect of FIR.
1709
fd437cbc
SM
17102017-08-28 Simon Marchi <simon.marchi@ericsson.com>
1711
3804a343 1712 PR gdb/21827
fd437cbc
SM
1713 * cli/cli-script.c (define_command): Don't convert command name
1714 to lower case.
1715
988f6b3d
JB
17162017-08-25 Joel Brobecker <brobecker@adacore.com>
1717
1718 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
1719 Update all callers accordingly. Remove all code blocks handling
1720 the case where DISPP is not NULL.
1721
663c44ac
JK
17222017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
1723
1724 PR symtab/22003
1725 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
1726 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
1727 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
1728
f1902523
JK
17292017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
1730
1731 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
1732 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
1733 (read_comp_units_from_section): New parameter abbrev_section, use
1734 read_and_check_comp_unit_head, allocate signatured_type if needed.
1735 (create_all_comp_units): Update read_comp_units_from_section caller.
1736
87215ad1
SDJ
17372017-08-23 Pedro Alves <palves@redhat.com>
1738
1739 PR remote/21852
1740 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
1741 to null_ptid and switch to thread without reading the registers
1742 after adding the inferior.
1743
6e41ddec
JK
17442017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
1745
1746 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
1747 compile-gcc.
1748 * compile/compile.c (compile_gcc, show_compile_gcc): New.
1749 (compile_to_object): Implement compile_gcc.
1750 (_initialize_compile): Install "set compile-gcc". Initialize
1751 compile_gcc.
1752
e68c32d5
JK
17532017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
1754
1755 * compile/compile.c (compile_to_object): Conditionally call
1756 set_verbose. Conditionally call compile or compile_v0.
1757
58afddc6
WP
17582017-08-07 Weimin Pan <weimin.pan@oracle.com>
1759
1760 * sparc64-tdep.h: (adi_normalize_address): New export.
1761 * sparc-nat.h: (open_adi_tag_fd): New export.
1762 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
1763 * sparc64-linux-tdep.c:
1764 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
1765 (sparc64_linux_handle_segmentation_fault): New function.
1766 (sparc64_linux_init_abi): Register
1767 sparc64_linux_handle_segmentation_fault
1768 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
1769 (sparc64_addr_bits_remove): New function.
1770 (sparc64_init_abi): Register sparc64_addr_bits_remove.
1771 (MAX_PROC_NAME_SIZE): New macro.
1772 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
1773 (sparc64adilist): New variable.
1774 (adi_proc_list): New variable.
1775 (find_adi_info): New function.
1776 (add_adi_info): New function.
1777 (get_adi_info_proc): New function.
1778 (get_adi_info): New function.
1779 (info_adi_command): New function.
1780 (read_maps_entry): New function.
1781 (adi_available): New function.
1782 (adi_normalize_address): New function.
1783 (adi_align_address): New function.
1784 (adi_convert_byte_count): New function.
1785 (adi_tag_fd): New function.
1786 (adi_is_addr_mapped): New function.
1787 (adi_read_versions): New function.
1788 (adi_write_versions): New function.
1789 (adi_print_versions): New function.
1790 (do_examine): New function.
1791 (do_assign): New function.
1792 (adi_examine_command): New function.
1793 (adi_assign_command): New function.
1794 (_initialize_sparc64_adi_tdep): New function.
1795
11db9430
SM
17962017-08-22 Simon Marchi <simon.marchi@ericsson.com>
1797
1798 * breakpoint.c (breakpoints_info): Rename to ...
1799 (info_breakpoints_command): ... this.
1800 (watchpoints_info): Rename to ...
1801 (info_watchpoints_command): ... this.
1802 (tracepoints_info): Rename to ...
1803 (info_tracepoints_command): ... this.
1804 (_initialize_breakpoint): Adjust.
1805 * dcache.c (dcache_info): Rename to ...
1806 (info_display_command): ... this.
1807 (_initialize_dcache): Adjust.
1808 * frame.h (args_info): Rename to ...
1809 (info_args_command): ... this.
1810 (locals_info): Rename to ...
1811 (info_locals_command): ... this.
1812 * infcmd.c (nofp_registers_info): Rename to ...
1813 (info_registers_command): ... this.
1814 (float_info): Rename to ...
1815 (info_float_command): ... this.
1816 (program_info): Rename to ...
1817 (info_program_command): ... this.
1818 (all_registers_info): Rename to ...
1819 (info_all_registers_command): ... this.
1820 (vector_info): Rename to ...
1821 (info_vector_command): ... this.
1822 (float_info): Rename to ...
1823 (info_float_command): ... this.
1824 (_initialize_infcmd): Adjust.
1825 * inferior.h (term_info): Rename to ...
1826 (info_terminal_command): ... this.
1827 * inflow.c (term_info): Rename to ...
1828 (info_terminal_command): ... this.
1829 (_initialize_inflow): Adjust.
1830 * infrun.c (signals_info): Rename to ...
1831 (info_signals_command): ... this.
1832 (_initialize_infrun): Adjust.
1833 * objc-lang.c (classes_info): Rename to ...
1834 (info_classes_command): ... this.
1835 (selectors_info): Rename to ...
1836 (info_selectors_command): ... this.
1837 (_initialize_objc_language): Adjust.
1838 * printcmd.c (sym_info): Rename to ...
1839 (info_symbol_command): ... this.
1840 (address_info): Rename to ...
1841 (info_address_command): ... this.
1842 (display_info): Rename to ...
1843 (info_display_command): ... this.
1844 (_initialize_printcmd): Adjust.
1845 * reverse.c (bookmarks_info): Rename to ...
1846 (info_breakpoints_command): ... this.
1847 (_initialize_reverse): Adjust.
1848 * ser-go32.c (dos_info): Rename to ...
1849 (info_serial_command): ... this.
1850 (_initialize_ser_dos): Adjust.
1851 * skip.c (skip_info): Rename to ...
1852 (info_skip_command): ... this.
1853 (_initialize_step_skip): Adjust.
1854 * source.c (line_info): Rename to ...
1855 (info_line_command): ... this.
1856 (source_info): Rename to ...
1857 (info_source_command)
1858 * stack.c (frame_info): Rename to ...
1859 (info_frame_command): ... this.
1860 (locals_info): Rename to ...
1861 (info_locals_command): ... this.
1862 (args_info): Rename to ...
1863 (info_args_command): ... this.
1864 (_initialize_stack): Adjust.
1865 * symtab.c (sources_info): Rename to ...
1866 (info_sources_command): ... this.
1867 (variables_info): Rename to ...
1868 (info_variables_command): ... this.
1869 (functions_info): Rename to ...
1870 (info_functions_command): ... this.
1871 (types_info): Rename to ...
1872 (info_types_command): ... this.
1873 (_initialize_symtab): Adjust.
1874 * target.c (target_info): Rename to ...
1875 (info_target_command): ... this.
1876 (initialize_targets): Adjust.
1877 * tracepoint.c (tvariables_info): Rename to ...
1878 (info_tvariables_command): ... this.
1879 (scope_info): Rename to ...
1880 (info_scope_command): ... this.
1881 (trace_dump_actions): Adjust.
1882 (_initialize_tracepoint): Adjust.
1883
b270e6f9
TT
18842017-08-22 Tom Tromey <tom@tromey.com>
1885
1886 * breakpoint.h (install_breakpoint): Update.
1887 * breakpoint.c (add_solib_catchpoint): Update.
1888 (install_breakpoint): Change argument to a std::unique_ptr.
1889 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
1890 (create_breakpoint_sal, create_breakpoint): Update.
1891 (watch_command_1, catch_exec_command_1)
1892 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
1893 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
1894 Return the breakpoint.
1895 (set_raw_breakpoint_without_location, set_raw_breakpoint)
1896 (new_single_step_breakpoint): Update.
1897 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
1898 std::unique_ptr.
1899 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
1900 std::unique_ptr.
1901 * break-catch-sig.c (create_signal_catchpoint): Use
1902 std::unique_ptr.
1903 * ada-lang.c (create_ada_exception_catchpoint): Use
1904 std::unique_ptr.
1905
36bd8eaa
TT
19062017-08-22 Tom Tromey <tom@tromey.com>
1907
1908 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
1909
56f37645
TT
19102017-08-22 Tom Tromey <tom@tromey.com>
1911
1912 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
1913 (lookup_partial_symbol): Update.
1914
0b581c69
TT
19152017-08-22 Tom Tromey <tom@tromey.com>
1916
1917 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
1918 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
1919 (find_and_open_source, symtab_to_fullname): Update.
1920 * psymtab.c (psymtab_to_fullname): Update.
1921
14278e1f
TT
19222017-08-22 Tom Tromey <tom@tromey.com>
1923
1924 * exec.c (exec_file_attach): Update.
1925 * linux-thread-db.c (try_thread_db_load): Update.
1926 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
1927 * utils.c (gdb_realpath): Change return type.
1928 (gdb_realpath_keepfile): Update.
1929 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
1930 (_initialize_utils): Register the new self test.
1931 * source.c (openp): Update.
1932 (find_and_open_source): Update.
1933 * nto-tdep.c (nto_find_and_open_solib): Update.
1934 * main.c (set_gdb_data_directory): Update.
1935 (captured_main_1): Update.
1936 * dwarf2read.c (dwarf2_get_dwz_file): Update
1937 (dw2_map_symbol_filenames): Update.
1938 * auto-load.c (auto_load_safe_path_vec_update): Update.
1939 (filename_is_in_auto_load_safe_path_vec): Change type of
1940 "filename_realp".
1941 (auto_load_objfile_script): Update.
1942 (file_is_auto_load_safe): Update. Use std::string.
1943 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
1944
4971c9a7
TT
19452017-08-22 Tom Tromey <tom@tromey.com>
1946
1947 * utils.c (gdb_realpath_keepfile): Return a
1948 gdb::unique_xmalloc_ptr.
1949 * exec.c (exec_file_attach): Update.
1950 * utils.h (gdb_realpath_keepfile): Return a
1951 gdb::unique_xmalloc_ptr.
1952
e3e41d58
TT
19532017-08-22 Tom Tromey <tom@tromey.com>
1954
1955 * compile/compile.c (compile_file_command): Use
1956 gdb::unique_xmalloc_ptr, std::string.
1957 * utils.c (gdb_abspath): Change return type.
1958 * source.c (openp): Update.
1959 * objfiles.c (allocate_objfile): Update.
1960 * main.c (set_gdb_data_directory): Update.
1961 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
1962
0d999a6e
ZZ
19632017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
1964
1965 * cli-cmds.c (list_commands): List actual code around more than
1966 one location.
1967
329d5e7e
JB
19682017-08-21 John Baldwin <jhb@FreeBSD.org>
1969
1970 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
1971
bf223d3e
PA
19722017-08-21 Pedro Alves <palves@redhat.com>
1973
1974 PR gdb/19487
1975 * c-exp.y (variable production): Handle function aliases.
1976 * minsyms.c (msymbol_is_text): New function.
1977 * minsyms.h (msymbol_is_text): Declare.
1978 * symtab.c (find_function_alias_target): New function.
1979 * symtab.h (find_function_alias_target): Declare.
1980
c973d0aa
PA
19812017-08-21 Pedro Alves <palves@redhat.com>
1982
1983 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
1984 typedefs.
1985 * typeprint.c (whatis_exp): If handling "whatis", and expression
1986 is OP_TYPE, strip one typedef level. Otherwise don't strip
1987 typedefs here.
1988 * valops.c (value_cast): Save "to" type before resolving
1989 stubs/typedefs. Use that type as resulting value's type.
1990
2989a365
TT
19912017-08-18 Tom Tromey <tom@tromey.com>
1992 Pedro Alves <palves@redhat.com>
1993
1994 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
1995 * sol-thread.c (sol_thread_resume, sol_thread_wait)
1996 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
1997 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
1998 * proc-service.c (ps_xfer_memory): Use scoped_restore.
1999 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
2000 (linux_get_siginfo_data): Add "thread" argument. Use
2001 scoped_restore.
2002 * linux-nat.c (linux_child_follow_fork)
2003 (check_stopped_by_watchpoint): Use scoped_restore.
2004 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
2005 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
2006 (restore_inferior_ptid, save_inferior_ptid): Remove.
2007 * btrace.c (btrace_fetch): Use scoped_restore.
2008 * bsd-uthread.c (bsd_uthread_fetch_registers)
2009 (bsd_uthread_store_registers): Use scoped_restore.
2010 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
2011 scoped_restore.
2012 * aix-thread.c (aix_thread_resume, aix_thread_wait)
2013 (aix_thread_xfer_partial): Use scoped_restore.
2014 * inferior.h (save_inferior_ptid): Remove.
2015
e60eb288
YQ
20162017-08-18 Yao Qi <yao.qi@linaro.org>
2017
2018 PR tdep/21818
2019 * arm-tdep.c (gdb_print_insn_arm): Mark
2020 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
2021
6d580b63
YQ
20222017-08-18 Yao Qi <yao.qi@linaro.org>
2023
2024 * NEWS: Mention GDBserver's new option "--selftest".
2025 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
2026 * selftest.c: Move it to common/selftest.c.
2027 * selftest.h: Move it to common/selftest.h.
2028 * selftest-arch.c (reset): New function.
2029 (tests_with_arch): Call reset.
2030
86dcbf50
YQ
20312017-08-18 Yao Qi <yao.qi@linaro.org>
2032
2033 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
2034 instead of exception_fprintf and printf_filtered.
2035
7649770c
YQ
20362017-08-18 Yao Qi <yao.qi@linaro.org>
2037
2038 * selftest.c (register_self_test): Rename it to
2039 selftests::register_test.
2040 (run_self_tests): selftest::run_tests.
2041 * selftest.h: Update declarations.
2042 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
2043 selftests::register_test_foreach_arch.
2044 * selftest-arch.h: Update declaration.
2045 * aarch64-tdep.c: Update.
2046 * arm-tdep.c: Likewise.
2047 * disasm-selftests.c: Likewise.
2048 * dwarf2loc.c: Likewise.
2049 * dwarf2-frame.c: Likewise.
2050 * findvar.c: Likewise.
2051 * gdbarch-selftests.c: Likewise.
2052 * maint.c (maintenance_selftest): Likewise.
2053 * regcache.c: Likewise.
2054 * rust-exp.y: Likewise.
2055 * selftest-arch.c: Likewise.
2056 * unittests/environ-selftests.c: Likewise.
2057 * unittests/function-view-selftests.c: Likewise.
2058 * unittests/offset-type-selftests.c: Likewise.
2059 * unittests/optional-selftests.c: Likewise.
2060 * unittests/scoped_restore-selftests.c: Likewise.
2061 * utils-selftests.c: Likewise.
2062
b0cba12e
PA
20632017-08-17 Pedro Alves <palves@redhat.com>
2064
2065 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
2066 local.
2067
4c8aa72d
PA
20682017-08-17 Pedro Alves <palves@redhat.com>
2069
2070 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
2071 field.
2072 (reset_die_in_process): Delete, replaced by ...
2073 (process_die_scope): ... this new class. Make it responsible for
2074 freeing cu->line_header too.
2075 (process_die): Use process_die_scope.
2076 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
2077 cu->line_header_die_owner. Don't release the line header if it's
2078 owned by the CU.
2079 (setup_type_unit_groups): Make the CU/DIE own the line header.
2080 Don't release the line header here.
2081
ba713918
AL
20822017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
2083
2084 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
2085
44d0fb3a
RK
20862017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
2087
2088 * NEWS: Mention new shortcuts for nexti and stepi in TUI
2089 Single-Key mode
2090
a5afdb16
RK
20912017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
2092
2093 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
2094 mode command list.
2095
47613aeb
SH
20962017-08-15 Stafford Horne <shorne@gmail.com>
2097
2098 * MAINTAINERS (Write After Approval): Add Stafford Horne.
2099
9c3cc999
SH
21002017-08-15 Stafford Horne <shorne@gmail.com>
2101
2102 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
2103
206726fb
SDJ
21042017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
2105
2106 PR gdb/21954
2107 * infcmd.c (unset_environment_command): Use the 'clear' method on
2108 the environment instead of resetting it.
2109
0335ac6d
JB
21102017-08-15 John Baldwin <jhb@FreeBSD.org>
2111
2112 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
2113 platforms.
2114
d3abe1c8
TT
21152017-08-14 Tom Tromey <tom@tromey.com>
2116
2117 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
2118 (print_binary_chars): Likewise.
2119 (BITS_IN_BYTES): Remove.
2120
d6382fff
TT
21212017-08-14 Tom Tromey <tom@tromey.com>
2122
2123 PR gdb/21675
2124 * valprint.c (LOW_ZERO): Change value to 034.
2125 (print_octal_chars): Add static_asserts for octal constants.
2126 * printcmd.c (print_scalar_formatted): Add 'd' case.
2127
f978cb06
TT
21282017-08-11 Tom Tromey <tom@tromey.com>
2129
2130 * symfile.c (add_symbol_file_command): Use std::vector.
2131
2f5404b3
TT
21322017-08-14 Tom Tromey <tom@tromey.com>
2133
2134 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
2135 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
2136 std::move.
2137 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
2138
de7985c3
PA
21392017-08-11 Pedro Alves <palves@redhat.com>
2140
2141 * infrun.c (process_event_stop_test): Adjust
2142 function_name_is_marked_for_skip call.
2143 * skip.c: Include <list>.
2144 (skiplist_entry): Make it a class with private fields, and
2145 getters/setters.
2146 (skiplist_entry_chain): Delete.
2147 (skiplist_entries): New.
2148 (skiplist_entry_count): Delete.
2149 (highest_skiplist_entry_num): New.
2150 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
2151 (add_skiplist_entry): Delete.
2152 (skiplist_entry::skiplist_entry): New.
2153 (skiplist_entry::add_entry): New.
2154 (skip_file_command, skip_function): Adjust.
2155 (compile_skip_regexp): Delete.
2156 (skip_command): Don't compile regexp here. Adjust to use
2157 skiplist_entry::add_entry.
2158 (skip_info): Adjust to use range-for and getters.
2159 (skip_enable_command, skip_disable_command): Adjust to use
2160 range-for and setters.
2161 (skip_delete_command): Adjust to use std::list.
2162 (add_skiplist_entry): Delete.
2163 (skip_file_p): Delete, refactored as ...
2164 (skiplist_entry::do_skip_file_p): ... this new method.
2165 (skip_gfile_p): Delete, refactored as ...
2166 (skiplist_entry::do_gskip_file_p): ... this new method.
2167 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
2168 (skiplist_entry::skip_function_p): ... this new method.
2169 (function_name_is_marked_for_skip): Now returns bool, and takes
2170 the function sal by const reference. Adjust to use range-for and
2171 skiplist_entry methods.
2172 (_initialize_step_skip): Remove references to
2173 skiplist_entry_chain, skiplist_entry_count.
2174 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
2175 takes the function sal by const reference.
2176
be7d3cd5
YQ
21772017-08-11 Yao Qi <yao.qi@linaro.org>
2178
2179 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
2180 (dwarf2_frame_cache): Remove reset_cache_cleanup.
2181 (dwarf2_frame_cache):
2182 * frame-unwind.c (frame_unwind_try_unwinder): Catch
2183 RETURN_MASK_ALL and set *this_case to NULL.
2184 * frame-unwind.h: Update comments.
2185
1c90d9f0
YQ
21862017-08-11 Yao Qi <yao.qi@linaro.org>
2187
2188 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
2189 (dwarf2_frame_state_copy_regs): Remove.
2190 (dwarf2_frame_state_free_regs): Remove.
2191 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
2192 (dwarf2_restore_rule): Call method .alloc_regs instead of
2193 dwarf2_frame_state_alloc_regs.
2194 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
2195 constructor. Call std::move.
2196 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
2197 (dwarf2_frame_cache): Likewise.
2198
2199 [GDB_SELF_TEST]: Include selftest.h and
2200 selftest-arch.h.
2201 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
2202 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
2203 execute_cfa_program_test.
2204
2205 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
2206 copy ctor, assignment operator, move assignment.
2207 <alloc_regs>: New method.
2208 <swap>: New method.
2209 (struct dwarf2_frame_state): Delete dtor.
2210 (dwarf2_frame_state_alloc_regs): Remove declaration.
2211 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
2212 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
2213
afe37d6b
YQ
22142017-08-11 Yao Qi <yao.qi@linaro.org>
2215
2216 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
2217 (dwarf2_frame_state::dwarf2_frame_state): New.
2218 (dwarf2_frame_state::~dwarf2_frame_state): New.
2219 (dwarf2_fetch_cfa_info): Update.
2220 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
2221 rather than a pointer. Update code.
2222 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
2223 dtor.
2224 <data_align, code_align, retaddr_column>: Change them to const.
2225 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
2226 to bool.
2227
b348037f
YQ
22282017-08-11 Yao Qi <yao.qi@linaro.org>
2229
2230 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
2231 <loc.exp>: New field.
2232 * dwarf2-frame.c (execute_cfa_program): Update.
2233 (dwarf2_frame_prev_register): Update.
2234
e7c9de26
PA
22352017-08-10 Pedro Alves <palves@redhat.com>
2236
2237 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
2238
e8c6b620
JB
22392017-08-09 John Baldwin <jhb@FreeBSD.org>
2240
2241 * fbsd-nat.c (struct fbsd_fork_info): Remove.
2242 (fbsd_pending_children): Use std::list.
2243 (fbsd_remember_child): Likewise.
2244 (fbsd_is_child_pending): Likewise.
2245 (fbsd_pending_vfork_done): Use std::forward_list.
2246 (fbsd_add_vfork_done): Likewise.
2247 (fbsd_is_vfork_done_pending): Likewise.
2248 (fbsd_next_vfork_done): Likewise.
2249
e4a26669
JB
22502017-08-09 John Baldwin <jhb@FreeBSD.org>
2251
2252 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
2253 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
2254 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
2255 for `mapfilename'.
2256 (fbsd_xfer_partial): Use gdb::byte_vector.
af3881e6 2257 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
e4a26669 2258
142311d3
JB
22592017-08-09 John Baldwin <jhb@FreeBSD.org>
2260
2261 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
2262 "filestuff.h".
2263 (fbsd_find_memory_regions): Fix `mapfile' initialization.
2264
42fa2e0e
TT
22652017-08-09 Tom Tromey <tom@tromey.com>
2266
2267 * skip.c (skiplist_entry): New constructor.
2268 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
2269 (skiplist_entry::file_is_glob): Now bool.
2270 (skiplist_entry::file, skiplist_entry::function): Now
2271 std::string.
2272 (make_skip_entry): Return a unique_ptr. Use new.
2273 (free_skiplist_entry, free_skiplist_entry_cleanup)
2274 (make_free_skiplist_entry_cleanup): Remove.
2275 (skip_command, skip_disable_command, add_skiplist_entry)
2276 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
2277 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
2278 (function_name_is_marked_for_skip): Update.
2279 (skip_delete_command): Update. Use delete.
2280
cd3af38d
JW
22812017-08-09 Jiong Wang <jiong.wang@arm.com>
2282
2283 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
2284 (aarch64_linux_core_read_description): New function.
2285 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
2286
29592bde
PA
22872017-08-09 Pedro Alves <palves@redhat.com>
2288
2289 * cp-name-parser.y (cp_comp_to_string): Return a
2290 gdb::unique_xmalloc_ptr<char>.
2291 * cp-support.c (replace_typedefs_qualified_name)
2292 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
2293 (cp_canonicalize_string_full): Use op= instead of explicit
2294 convertion.
2295 (cp_class_name_from_physname, method_name_from_physname)
2296 (cp_func_name, cp_remove_params): Adjust to use
2297 gdb::unique_xmalloc_ptr<char>.
2298 * cp-support.h (cp_comp_to_string): Return a
2299 gdb::unique_xmalloc_ptr<char>.
2300 * python/py-type.c (typy_lookup_type): Adjust to use
2301 gdb::unique_xmalloc_ptr<char>.
2302
b3340438
L
23032017-08-09 H.J. Lu <hongjiu.lu@intel.com>
2304
2305 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
2306
e88e8651
YQ
23072017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
2308 Yao Qi <yao.qi@linaro.org>
2309
2310 * cp-support.c (cp_canonicalize_string_full): Use
2311 gdb::unique_xmalloc_ptr<char>.
2312 (cp_canonicalize_string): Likewise.
2313
f5a29eb0
YQ
23142017-08-09 Yao Qi <yao.qi@linaro.org>
2315
2316 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
2317 * regformats/i386/amd64-avx-avx512.dat: Remove.
2318 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
2319 * regformats/i386/amd64-avx-mpx.dat:Remove.
2320 * regformats/i386/amd64-avx.dat: Remove.
2321 * regformats/i386/amd64-mpx.dat: Remove.
2322 * regformats/i386/i386-avx-avx512.dat: Remove.
2323 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
2324 * regformats/i386/i386-avx-mpx.dat: Remove.
2325 * regformats/i386/i386-mmx.dat: Remove.
2326 * regformats/i386/i386-mpx.dat: Remove.
2327
57757c2f
YQ
23282017-08-09 Yao Qi <yao.qi@linaro.org>
2329
2330 * amd64-tdep.h (tdesc_x32): Remove the declaration.
2331 * amd64-tdep.c: Don't include features/i386/x32*.c.
2332 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
2333 functions.
2334 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
2335 and i386/x32-avx-avx512.
2336 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
2337 and i386/x32.xml.
2338 * features/i386/x32-avx-avx512.c: Removed.
2339 * features/i386/x32-avx-avx512.xml: Removed.
2340 * features/i386/x32-avx.c: Removed.
2341 * features/i386/x32-avx.xml: Removed.
2342 * features/i386/x32.c: Removed.
2343 * features/i386/x32.xml: Removed.
2344 * regformats/i386/x32-avx-avx512.dat: Removed.
2345 * regformats/i386/x32-avx.dat: Removed.
2346 * regformats/i386/x32.dat: Removed.
2347
ba7b109b
MR
23482017-08-07 Maciej W. Rozycki <macro@imgtec.com>
2349
2350 PR breakpoints/21886
2351 * mem-break.c (default_memory_insert_breakpoint): Use
2352 `->placed_address' rather than `->reqstd_address' for the
2353 breakpoint location.
2354
e347efc3
MR
23552017-08-07 Maciej W. Rozycki <macro@imgtec.com>
2356
2357 * arch-utils.c (default_print_insn): Remove arch/mach/endian
2358 assertions.
2359
0dba2a6c
MR
23602017-08-07 Maciej W. Rozycki <macro@imgtec.com>
2361
2362 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
2363 a union of `tdep_info', `tdesc_data' and `id'.
2364 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
2365 rather than `info.tdep_info'.
2366 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
2367 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
2368 * i386-tdep.c (i386_gdbarch_init): Likewise.
2369 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
2370 * mips-tdep.c (mips_gdbarch_init): Likewise.
2371 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
2372 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
2373 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
2374 `info.tdep_info'.
2375 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
2376 `info.tdep_info'.
2377 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
2378 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
2379 `info.tdep_info'.
2380 * spu-tdep.c (spu_gdbarch_init): Likewise.
2381 * gdbarch.h: Regenerate.
2382
16eb6b2d
LS
23832017-08-07 Leszek Swirski <leszeks@google.com>
2384
7b005726 2385 PR symtab/20899
16eb6b2d
LS
2386 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
2387
74cbb09e
SM
23882017-08-07 Simon Marchi <simon.marchi@ericsson.com>
2389
2390 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
2391 (gdbsim_open): Rename gdb_argv args object to argv.
2392
ee0c3293
TT
23932017-08-05 Tom Tromey <tom@tromey.com>
2394
2395 * compile/compile-object-load.c (compile_object_load): Use
2396 gdb::unique_xmalloc_ptr.
2397 * cli/cli-dump.c (scan_filename): Rename from
2398 scan_filename_with_cleanup. Change return type.
2399 (scan_expression): Rename from scan_expression_with_cleanup.
2400 Change return type.
2401 (dump_memory_to_file, dump_value_to_file, restore_command):
2402 Use gdb::unique_xmalloc_ptr. Update.
2403 * cli/cli-cmds.c (find_and_open_script): Use
2404 gdb::unique_xmalloc_ptr.
2405 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
2406 * symmisc.c (maintenance_print_symbols)
2407 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
2408 * symfile.c (symfile_bfd_open, generic_load)
2409 (add_symbol_file_command, remove_symbol_file_command): Use
2410 gdb::unique_xmalloc_ptr.
2411 * source.c (openp): Use gdb::unique_xmalloc_ptr.
2412 * psymtab.c (maintenance_print_psymbols): Use
2413 gdb::unique_xmalloc_ptr.
2414 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
2415 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
2416 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
2417 (reload_shared_libraries_1): Likewise.
2418
3232fabd
TT
24192017-08-05 Tom Tromey <tom@tromey.com>
2420
2421 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
2422 (rust_op_vector, rust_set_vector): New typedefs.
2423 (current_parser): New global.
2424 (work_obstack): Change to pointer type. Update all users.
2425 (rust_ast, pstate): Remove globals.
2426 (struct rust_parser): New.
2427 (%union) <params, field_inits>: Change type.
2428 (start, tuple_expr, unit_expr, struct_expr_list, literal)
2429 (field_expr, expr_list, maybe_expr_list, type_list): Update.
2430 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
2431 (convert_params_to_types, convert_params_to_expression): Change
2432 type of "params".
2433 (ast_string): Change type of "fields".
2434 (rust_parse): Make a rust_parser. Remove cleanups.
2435 (rust_lex_tests): Make and install an auto_obstack.
2436
f02fd774
YQ
24372017-08-04 Yao Qi <yao.qi@linaro.org>
2438
2439 * configure.srv (ipa_x32_linux_regobj): New.
2440 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
2441 instead of X86_TDESC_AVX512.
2442 (initialize_low_tracepoint): Call
2443 init_registers_x32_avx_avx512_linux.
2444
91975afd
YQ
24452017-08-04 Yao Qi <yao.qi@linaro.org>
2446
2447 * utils.h (gdb_argv): Add namespace std for nullptr_t.
2448
2331fa3a
RK
24492017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
2450
2451 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
2452
744e4fe1
TT
24532017-08-03 Tom Tromey <tom@tromey.com>
2454
2455 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
2456 Remove.
2457 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
2458
1c034b67
TT
24592017-08-03 Tom Tromey <tom@tromey.com>
2460
2461 * python/py-param.c (compute_enum_values): Use gdb_argv.
2462
773a1edc
TT
24632017-08-03 Tom Tromey <tom@tromey.com>
2464
2465 * utils.h (struct gdb_argv_deleter): New.
2466 (gdb_argv): New class.
2467 * utils.c (gdb_argv::reset): New method.
2468 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
2469 * tracefile.c (tsave_command): Use gdb_argv.
2470 * top.c (new_ui_command): Use gdb_argv.
2471 * symmisc.c (maintenance_print_symbols)
2472 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
2473 * symfile.c (symbol_file_command, generic_load)
2474 (remove_symbol_file_command): Use gdb_argv.
2475 * stack.c (backtrace_command): Use gdb_argv.
2476 * source.c (add_path, show_substitute_path_command)
2477 (unset_substitute_path_command, set_substitute_path_command):
2478 Use gdb_argv.
2479 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
2480 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
2481 * remote.c (extended_remote_run, remote_put_command)
2482 (remote_get_command, remote_delete_command): Use gdb_argv.
2483 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
2484 (gdbsim_open): Use gdb_argv.
2485 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
2486 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
2487 * procfs.c (procfs_info_proc): Use gdb_argv.
2488 * interps.c (interpreter_exec_cmd): Use gdb_argv.
2489 * infrun.c (handle_command): Use gdb_argv.
2490 * inferior.c (add_inferior_command, clone_inferior_command):
2491 Use gdb_argv.
2492 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
2493 * exec.c (exec_file_command): Use gdb_argv.
2494 * cli/cli-cmds.c (alias_command): Use gdb_argv.
2495 * compile/compile.c (build_argc_argv): Use gdb_argv.
2496
0d50bde3
TT
24972017-08-03 Tom Tromey <tom@tromey.com>
2498
2499 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
2500
7f968c89
TT
25012017-08-03 Tom Tromey <tom@tromey.com>
2502
2503 * python/python.c (compute_python_string): Return std::string.
2504 (gdbpy_eval_from_control_command): Update.
2505 (do_start_initialization): Use std::string.
2506 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
2507 xstrprintf.
2508 * python/py-breakpoint.c (local_setattro): Use string_printf, not
2509 xstrprintf.
2510
3c9ebddd
TT
25112017-08-03 Tom Tromey <tom@tromey.com>
2512
2513 * top.h (do_restore_instream_cleanup): Remove.
2514 * top.c (do_restore_instream_cleanup): Remove.
2515 (read_command_file): Use scoped_restore.
2516 * cli/cli-script.c (execute_user_command): Use scoped_restore.
2517
b51b225e
TT
25182017-08-03 Tom Tromey <tom@tromey.com>
2519
2520 * cli/cli-script.c (execute_user_command)
2521 (execute_control_command): Use scoped_restore.
2522
ac991630
TT
25232017-08-03 Tom Tromey <tom@tromey.com>
2524
2525 * cli/cli-script.c (do_restore_user_call_depth): Remove.
2526 (execute_user_command): Remove user_call_depth; use
2527 user_args_stack's size instead.
2528
898e0c8e
TT
25292017-08-03 Tom Tromey <tom@tromey.com>
2530
2531 * top.h (in_user_command): Remove.
2532 * top.c (in_user_command): Remove.
2533 * cli/cli-script.c (do_restore_user_call_depth)
2534 (execute_user_command): Update.
2535
26fcd5d7
TT
25362017-08-03 Tom Tromey <tom@tromey.com>
2537
2538 * valops.c (search_struct_method): Use gdb::byte_vector.
2539 * valarith.c (value_concat): Use std::vector.
2540 * target.c (memory_xfer_partial): Use gdb::byte_vector.
2541 (simple_search_memory): Likewise.
2542 * printcmd.c (find_string_backward): Use gdb::byte_vector.
2543 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
2544 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
2545 * elfread.c (elf_rel_plt_read): Use std::string.
2546 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
2547 * cli/cli-dump.c (restore_section_callback): Use
2548 gdb::byte_vector.
2549
7c218e6c
TT
25502017-08-03 Tom Tromey <tom@tromey.com>
2551
2552 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
2553
31b68d4a
TT
25542017-08-03 Tom Tromey <tom@tromey.com>
2555
2556 * tui/tui-regs.c (tui_restore_gdbout): Remove.
2557 (tui_register_format): Use scoped_restore.
2558
2ec845e7
TT
25592017-08-03 Tom Tromey <tom@tromey.com>
2560
2561 * reverse.c (exec_direction_default): Remove.
2562 (exec_reverse_once): Use scoped_restore.
2563 * remote.c (restore_remote_timeout): Remove.
2564 (remote_flash_erase, remote_flash_write, remote_flash_done)
2565 (readchar, remote_serial_write): Use scoped_restore.
2566 * cli/cli-script.c (struct source_cleanup_lines_args)
2567 (source_cleanup_lines): Remove.
2568 (script_from_file): Use scoped_restore.
2569 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
2570 (source_command): Use scoped_restore.
2571
b3bc8453
TT
25722017-08-03 Tom Tromey <tom@tromey.com>
2573
2574 * utils.h (make_cleanup_free_so): Remove.
2575 * utils.c (do_free_so, make_cleanup_free_so): Remove.
2576 * solist.h (struct so_deleter): New.
2577 (so_list_up): New typedef.
2578 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
2579
e3ad2841
TT
25802017-08-03 Tom Tromey <tom@tromey.com>
2581
2582 * utils.h (make_cleanup_restore_current_language): Remove.
2583 * utils.c (do_restore_current_language)
2584 (make_cleanup_restore_current_language): Remove.
2585 * parse.c (parse_exp_in_context_1)
2586 (parse_expression_with_language): Use
2587 scoped_restore_current_language.
2588 * mi/mi-main.c (mi_cmd_execute): Use
2589 scoped_restore_current_language.
2590 * language.h (scoped_restore_current_language): New class.
2591
b80cf838
TT
25922017-08-03 Tom Tromey <tom@tromey.com>
2593
2594 * compile/compile.c (cleanup_unlink_file): Remove.
2595 (compile_to_object): Use gdb::unlinker.
2596 (eval_compile_command): Likewise.
2597
fad0444a
TT
25982017-08-03 Tom Tromey <tom@tromey.com>
2599
2600 * utils.h (make_cleanup_fclose): Remove.
2601 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
2602
6e7bc05c
TT
26032017-08-03 Tom Tromey <tom@tromey.com>
2604
2605 * top.c (open_terminal_stream): Return gdb_file_up.
2606 (new_ui_command): Update.
2607
4a45905b
TT
26082017-08-03 Tom Tromey <tom@tromey.com>
2609
2610 * source.c (print_source_lines_base, forward_search_command)
2611 (reverse_search_command): Use gdb_file_up.
2612
7cd06d6e
TT
26132017-08-03 Tom Tromey <tom@tromey.com>
2614
2615 * fbsd-nat.c (fbsd_find_memory_regions): Update.
2616
ed166945
TT
26172017-08-03 Tom Tromey <tom@tromey.com>
2618
2619 * cli/cli-cmds.c (find_and_open_script): Change return type.
2620 Remove "streamp" and "full_path" parameters.
2621 (source_script_with_search): Update.
2622 * auto-load.c (source_script_file): Update.
2623 * cli/cli-cmds.h (find_and_open_script): Change type.
2624 (open_script): New struct.
2625
d419f42d
TT
26262017-08-03 Tom Tromey <tom@tromey.com>
2627
2628 * xml-support.c (xml_fetch_content_from_file): Update.
2629 * ui-file.c (stdio_file::open): Update.
2630 * tracefile-tfile.c (tfile_start): Update.
2631 * remote.c (remote_file_put, remote_file_get): Update.
2632 * nat/linux-procfs.c (linux_proc_get_int)
2633 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
2634 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
2635 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
2636 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
2637 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
2638 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
2639 * linux-nat.c (linux_proc_pending_signals): Update.
2640 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
2641 (file_closer): Remove.
2642 * compile/compile.c (compile_to_object): Update.
2643 * common/filestuff.h (struct gdb_file_deleter): New.
2644 (gdb_file_up): New typedef.
2645 (gdb_fopen_cloexec): Change return type.
2646 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
2647 * cli/cli-dump.c (fopen_with_cleanup): Remove.
2648 (dump_binary_file, restore_binary_file): Update.
2649 * auto-load.c (auto_load_objfile_script_1): Update.
2650
4a2b031d
TT
26512017-08-03 Tom Tromey <tom@tromey.com>
2652
2653 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
2654 (info_static_tracepoint_markers_command): Likewise.
2655 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
2656 * skip.c (skip_info): Use ui_out_emit_table.
2657 * progspace.c (print_program_space): Use ui_out_emit_table.
2658 * osdata.c (info_osdata): Use ui_out_emit_table.
2659 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
2660 ui_out_emit_table.
2661 * linux-thread-db.c (info_auto_load_libthread_db): Use
2662 ui_out_emit_table.
2663 * inferior.c (print_inferior): Use ui_out_emit_table.
2664 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
2665 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
2666 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
2667 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
2668 * ui-out.h (class ui_out_emit_table): New.
2669
a4f320fd
MR
26702017-08-02 Maciej W. Rozycki <macro@imgtec.com>
2671
2672 * mips-tdep.c (mips_fpu_type_str): New function.
2673 (mips_dump_tdep): Call it.
2674
a2f1f308
MR
26752017-08-01 Maciej W. Rozycki <macro@imgtec.com>
2676
2677 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
2678 `->mips_fpu_type'.
2679
7e5ed83b
XR
26802017-07-31 Xavier Roirand <roirand@adacore.com>
2681
2682 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
2683
4c9dc811
XR
26842017-07-27 Xavier Roirand <roirand@adacore.com>
2685
2686 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
2687
27d41eac
YQ
26882017-07-26 Yao Qi <yao.qi@linaro.org>
2689
2690 * cli/cli-cmds.c (maintenancechecklist): New variable.
2691 * gdbcmd.h (maintenancechecklist): Declare it.
2692 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
2693 Call i386_linux_read_description with different masks.
2694 * maint.c (maintenance_check_command): New function.
2695 (_initialize_maint_cmds): Call add_prefix_cmd.
2696 * target-descriptions.c (tdesc_reg): override operator != and ==.
2697 (tdesc_type): Likewise.
2698 (tdesc_feature): Likewise.
2699 (target_desc): Likewise.
2700 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
2701 (maintenance_check_xml_descriptions): New function.
2702 (_initialize_target_descriptions) Add command "xml-descriptions".
2703 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
2704
ea03d0d3
YQ
27052017-07-26 Yao Qi <yao.qi@linaro.org>
2706
2707 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
2708 Include features/i386/32bit-*.c.
2709 (i386_linux_read_description): Generate target description if it
2710 doesn't exist.
2711 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
2712 functions.
2713 * features/i386/32bit-linux.c: Re-generated.
2714 * features/i386/32bit-sse.c: Likewise.
2715 * target-descriptions.c (print_c_feature::visit): Print code to
2716 set register number if needed.
2717 (print_c_feature) <m_next_regnum>: New field.
2718
25aa13e5
YQ
27192017-07-26 Yao Qi <yao.qi@linaro.org>
2720
2721 * features/Makefile (CFILES): Rename with TDESC_CFILES.
2722 (FEATURE_XMLFILES): New.
2723 (FEATURE_CFILES): New.
2724 New rules.
2725 (clean-cfiles): Remove generated c files.
2726 * features/i386/32bit-avx.c: Generated.
2727 * features/i386/32bit-avx512.c: Generated.
2728 * features/i386/32bit-core.c: Generated.
2729 * features/i386/32bit-linux.c: Generated.
2730 * features/i386/32bit-mpx.c: Generated.
2731 * features/i386/32bit-pkeys.c: Generated.
2732 * features/i386/32bit-sse.c: Generated.
2733 * target-descriptions.c: Include algorithm.
2734 (tdesc_element_visitor): Add method visit_end.
2735 (print_c_tdesc): Implement visit_end.
2736 (print_c_tdesc:: m_filename_after_features): Move it to
2737 protected.
2738 (print_c_feature): New class.
2739 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
2740 name starts with "i386/32bit-".
2741
6eb1e6a8
YQ
27422017-07-26 Yao Qi <yao.qi@linaro.org>
2743
2744 * target-descriptions.c (tdesc_element_visitor): New class.
2745 (tdesc_element): New class.
2746 (tdesc_reg): Inherit from tdesc_element.
2747 (tdesc_reg::accept): New function.
2748 (tdesc_type): Inherit from tdesc_element.
2749 (tdesc_type::accept): New function.
2750 (tdesc_feature): Inherit from tdesc_element.
2751 (tdesc_feature::accept): New function.
2752 (target_desc): Inherit from tdesc_element.
2753 (target_desc::target_desc): New.
2754 (target_desc::~target_desc): New.
2755 (target_desc::accept): New.
2756 (allocate_target_description): Use new.
2757 (free_target_description): Use delete.
2758 (print_c_tdesc): New class.
2759 (maint_print_c_tdesc_cmd): Adjust.
2760
2761 * features/aarch64.c: Re-generated.
2762 * features/arc-arcompact.c: Re-generated.
2763 * features/arc-v2.c: Re-generated.
2764 * features/arm/arm-with-iwmmxt.c: Re-generated.
2765 * features/arm/arm-with-m.c: Re-generated.
2766 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
2767 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
2768 * features/arm/arm-with-neon.c: Re-generated.
2769 * features/arm/arm-with-vfpv2.c: Re-generated.
2770 * features/arm/arm-with-vfpv3.c: Re-generated.
2771 * features/i386/amd64-avx-avx512.c: Re-generated.
2772 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
2773 * features/i386/amd64-avx.c: Re-generated.
2774 * features/i386/amd64-avx-linux.c: Re-generated.
2775 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
2776 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
2777 * features/i386/amd64-avx-mpx.c: Re-generated.
2778 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
2779 * features/i386/amd64.c: Re-generated.
2780 * features/i386/amd64-linux.c: Re-generated.
2781 * features/i386/amd64-mpx.c: Re-generated.
2782 * features/i386/amd64-mpx-linux.c: Re-generated.
2783 * features/i386/i386-avx-avx512.c: Re-generated.
2784 * features/i386/i386-avx-avx512-linux.c: Re-generated.
2785 * features/i386/i386-avx.c: Re-generated.
2786 * features/i386/i386-avx-linux.c: Re-generated.
2787 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
2788 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
2789 * features/i386/i386-avx-mpx.c: Re-generated.
2790 * features/i386/i386-avx-mpx-linux.c: Re-generated.
2791 * features/i386/i386.c: Re-generated.
2792 * features/i386/i386-linux.c: Re-generated.
2793 * features/i386/i386-mmx.c: Re-generated.
2794 * features/i386/i386-mmx-linux.c: Re-generated.
2795 * features/i386/i386-mpx.c: Re-generated.
2796 * features/i386/i386-mpx-linux.c: Re-generated.
2797 * features/i386/x32-avx-avx512.c: Re-generated.
2798 * features/i386/x32-avx-avx512-linux.c: Re-generated.
2799 * features/i386/x32-avx.c: Re-generated.
2800 * features/i386/x32-avx-linux.c: Re-generated.
2801 * features/i386/x32.c: Re-generated.
2802 * features/i386/x32-linux.c: Re-generated.
2803 * features/microblaze.c: Re-generated.
2804 * features/microblaze-with-stack-protect.c: Re-generated.
2805 * features/mips64-dsp-linux.c: Re-generated.
2806 * features/mips64-linux.c: Re-generated.
2807 * features/mips-dsp-linux.c: Re-generated.
2808 * features/mips-linux.c: Re-generated.
2809 * features/nds32.c: Re-generated.
2810 * features/nios2.c: Re-generated.
2811 * features/nios2-linux.c: Re-generated.
2812 * features/rs6000/powerpc-32.c: Re-generated.
2813 * features/rs6000/powerpc-32l.c: Re-generated.
2814 * features/rs6000/powerpc-403.c: Re-generated.
2815 * features/rs6000/powerpc-403gc.c : Re-generated.
2816 * features/rs6000/powerpc-405.c: Re-generated.
2817 * features/rs6000/powerpc-505.c: Re-generated.
2818 * features/rs6000/powerpc-601.c: Re-generated.
2819 * features/rs6000/powerpc-602.c: Re-generated.
2820 * features/rs6000/powerpc-603.c: Re-generated.
2821 * features/rs6000/powerpc-604.c: Re-generated.
2822 * features/rs6000/powerpc-64.c: Re-generated.
2823 * features/rs6000/powerpc-64l.c: Re-generated.
2824 * features/rs6000/powerpc-7400.c: Re-generated.
2825 * features/rs6000/powerpc-750.c: Re-generated.
2826 * features/rs6000/powerpc-860.c: Re-generated.
2827 * features/rs6000/powerpc-altivec32.c: Re-generated.
2828 * features/rs6000/powerpc-altivec32l.c: Re-generated.
2829 * features/rs6000/powerpc-altivec64.c: Re-generated.
2830 * features/rs6000/powerpc-altivec64l.c: Re-generated.
2831 * features/rs6000/powerpc-cell32l.c: Re-generated.
2832 * features/rs6000/powerpc-cell64l.c: Re-generated.
2833 * features/rs6000/powerpc-e500.c: Re-generated.
2834 * features/rs6000/powerpc-e500l.c: Re-generated.
2835 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
2836 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
2837 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
2838 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
2839 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
2840 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
2841 * features/rs6000/powerpc-vsx32.c: Re-generated.
2842 * features/rs6000/powerpc-vsx32l.c: Re-generated.
2843 * features/rs6000/powerpc-vsx64.c: Re-generated.
2844 * features/rs6000/powerpc-vsx64l.c: Re-generated.
2845 * features/rs6000/rs6000.c: Re-generated.
2846 * features/s390-linux32.c: Re-generated.
2847 * features/s390-linux32v1.c: Re-generated.
2848 * features/s390-linux32v2.c: Re-generated.
2849 * features/s390-linux64.c: Re-generated.
2850 * features/s390-linux64v1.c: Re-generated.
2851 * features/s390-linux64v2.c: Re-generated.
2852 * features/s390-te-linux64.c: Re-generated.
2853 * features/s390-tevx-linux64.c: Re-generated.
2854 * features/s390-vx-linux64.c: Re-generated.
2855 * features/s390x-linux64.c: Re-generated.
2856 * features/s390x-linux64v1.c: Re-generated.
2857 * features/s390x-linux64v2.c: Re-generated.
2858 * features/s390x-te-linux64.c: Re-generated.
2859 * features/s390x-tevx-linux64.c: Re-generated.
2860 * features/s390x-vx-linux64.c: Re-generated.
2861 * features/sparc/sparc32-solaris.c: Re-generated.
2862 * features/sparc/sparc64-solaris.c: Re-generated.
2863 * features/tic6x-c62x.c: Re-generated.
2864 * features/tic6x-c62x-linux.c: Re-generated.
2865 * features/tic6x-c64x.c: Re-generated.
2866 * features/tic6x-c64x-linux.c: Re-generated.
2867 * features/tic6x-c64xp.c: Re-generated.
2868 * features/tic6x-c64xp-linux.c: Re-generated.
2869
35b4818d
YQ
28702017-07-26 Yao Qi <yao.qi@linaro.org>
2871
2872 * i386-linux-tdep.c (i386_linux_read_description): New function.
2873 (i386_linux_core_read_description): Call
2874 i386_linux_read_description.
2875 * i386-linux-tdep.h (i386_linux_read_description): Declare.
2876 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
2877 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
2878 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
2879 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
2880 * x86-linux-nat.c (x86_linux_read_description): Call
2881 i386_linux_read_description.
2882
8e2141c6
YQ
28832017-07-26 Yao Qi <yao.qi@linaro.org>
2884
2885 * NEWS: Mention it.
2886 * features/Makefile (%.c: %.xml): Pass the xml file name to
2887 command "maint print c-tdesc".
2888 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
2889 name from 'arg'.
2890
b468ff4c
YQ
28912017-07-26 Yao Qi <yao.qi@linaro.org>
2892
2893 * target-descriptions.c (target_desc): Add ctor and dtor. Do
2894 in-class initialization.
2895 (tdesc_create_feature): Call new instead of XCNEW.
2896 (free_target_description): Ue delete.
2897
b9c0e1b4
JB
28982017-07-25 John Baldwin <jhb@FreeBSD.org>
2899
2900 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
2901
a04b5337
YQ
29022017-07-25 Yao Qi <yao.qi@linaro.org>
2903
2904 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
2905 constant.
2906 (amd64_x32_init_abi): Likewise.
2907 * amd64-tdep.h (amd64_init_abi): Update declaration.
2908 (amd64_x32_init_abi): Likewise.
2909
02ad7fc2
YQ
29102017-07-25 Yao Qi <yao.qi@linaro.org>
2911
2912 PR tdep/21717
2913 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
2914 condition for FPSCR.
2915 (arm_linux_store_inferior_registers): Likewise.
2916
b6f48cb0
TT
29172017-07-22 Tom Tromey <tom@tromey.com>
2918
2919 * break-catch-syscall.c (struct catch_syscall_inferior_data)
2920 <syscalls_counts>: Now a std::vector.
2921 (get_catch_syscall_inferior_data): Use "new".
2922 (catch_syscall_inferior_data_cleanup): Use "delete".
2923 (insert_catch_syscall, remove_catch_syscall)
2924 (clear_syscall_counts): Update.
2925
e12c9b7a
TT
29262017-07-22 Tom Tromey <tom@tromey.com>
2927
2928 * break-catch-syscall.c (syscall_catchpoint)
2929 <syscalls_to_be_caught>: Now a std::vector<int>
2930 (~syscall_catchpoint): Remove.
2931 (insert_catch_syscall, remove_catch_syscall)
2932 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
2933 (print_mention_catch_syscall, print_recreate_catch_syscall):
2934 Update.
2935 (create_syscall_event_catchpoint): Change type of "filter"
2936 parameter.
2937 (catch_syscall_split_args): Return a std::vector.
2938 (catch_syscall_command_1, catching_syscall_number_1): Update.
2939
4fa8aeac
TT
29402017-07-22 Tom Tromey <tom@tromey.com>
2941
2942 * break-catch-throw.c (struct exception_catchpoint)
2943 <exception_rx>: Now a std::string.
2944 (~exception_catchpoint): Remove.
2945 (print_one_detail_exception_catchpoint): Update.
2946 (handle_gnu_v3_exceptions): Change type of except_rx.
2947 (extract_exception_regexp): Return a std::string.
2948 (catch_exception_command_1): Update.
2949
f746a154
TT
29502017-07-22 Tom Tromey <tom@tromey.com>
2951
2952 * break-catch-sig.c (gdb_signal_type): Remove typedef.
2953 (struct signal_catchpoint) <signals_to_be_caught>: Now a
2954 std::vector.
2955 <catch_all>: Now a bool.
2956 (~signal_catchpoint): Remove.
2957 (signal_catchpoint_insert_location)
2958 (signal_catchpoint_remove_location)
2959 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
2960 (signal_catchpoint_print_mention)
2961 (signal_catchpoint_print_recreate)
2962 (signal_catchpoint_explains_signal): Update.
2963 (create_signal_catchpoint): Change type of "filter" and
2964 "catch_all".
2965 (catch_signal_split_args): Return a std::vector. Change type of
2966 "catch_all".
2967 (catch_signal_command): Update.
2968
47e77640
PA
29692017-07-20 Pedro Alves <palves@redhat.com>
2970
2971 * ada-lang.c (ada_language_defn): Make extern.
2972 (_initialize_ada_language): Remove add_language call.
2973 * c-lang.c (c_language_defn, cplus_language_defn)
2974 (asm_language_defn, minimal_language_defn): Make extern.
2975 (_initialize_c_language): Delete.
2976 * completer.c (compare_cstrings): Delete, moved to utils.h.
2977 * d-lang.c (d_language_defn): Make extern.
2978 (_initialize_d_language): Remove add_language calls.
2979 * defs.h (enum language): Add comment.
2980 * f-lang.c (f_language_defn): Make extern.
2981 (_initialize_f_language): Remove add_language call.
2982 * go-lang.c (go_language_defn): Make extern.
2983 (_initialize_go_language): Remove add_language call.
2984 * language.c: Include <algorithm>.
2985 (languages): Redefine as const array.
2986 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
2987 (set_language_command): Handle "local". Use for-range loop.
2988 (set_language): Remove loop.
2989 (language_enum): Rewrite.
2990 (language_def, language_str): Remove loops.
2991 (add_language): Delete.
2992 (add_set_language_command): New, based on add_languages.
2993 (skip_language_trampoline): Adjust.
2994 (local_language_defn): Delete.
2995 (language_gdbarch_post_init): Adjust.
2996 (_initialize_language): Remove add_language calls. Call
2997 add_set_language_command.
2998 * language.h (add_language): Delete.
2999 (auto_language_defn)
3000 (unknown_language_defn, minimal_language_defn, ada_language_defn)
3001 (asm_language_defn, c_language_defn, cplus_language_defn)
3002 (d_language_defn, f_language_defn, go_language_defn)
3003 (m2_language_defn, objc_language_defn, opencl_language_defn)
3004 (pascal_language_defn, rust_language_defn): Declare.
3005 * m2-lang.c (m2_language_defn): Make extern.
3006 (_initialize_m2_language): Remove add_language call.
3007 * objc-lang.c (objc_language_defn): Make extern.
3008 (_initialize_objc_language): Remove add_language call.
3009 * opencl-lang.c (opencl_language_defn): Make extern.
3010 (_initialize_opencl_language): Remove add_language call.
3011 * p-lang.c (pascal_language_defn): Make extern.
3012 (_initialize_pascal_language): Delete.
3013 * rust-lang.c (rust_language_defn): Make extern.
3014 (_initialize_rust_language): Delete.
3015 * utils.h (compare_cstrings): New static inline function.
3016
edb0c9cb
PA
30172017-07-20 Pedro Alves <palves@redhat.com>
3018
3019 * ada-lang.c (ada_to_fixed_type_1): Adjust.
3020 (get_var_value): Constify parameters.
3021 (get_int_var_value): Change prototype.
3022 (to_fixed_range_type): Adjust.
3023 * ada-lang.h (get_int_var_value): Change prototype.
3024
a778f165
PA
30252017-07-20 Pedro Alves <palves@redhat.com>
3026
3027 * dwarf2read.c (dw2_lookup_symbol): Use
3028 SYMBOL_MATCHES_SEARCH_NAME.
3029 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
3030
42edd901
PA
30312017-07-20 Pedro Alves <palves@redhat.com>
3032
3033 * block.c (block_iter_name_step, block_iter_name_first)
3034 (block_iter_name_next): Delete.
3035 (block_lookup_symbol_primary): Adjust to use
3036 dict_iter_match_first/dict_iter_match_next.
3037 * block.h (block_iter_name_first, block_iter_name_next): Delete
3038 declarations.
3039 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
3040 dict_iter_match_first/dict_iter_match_next.
3041
cf325299
PA
30422017-07-20 Pedro Alves <palves@redhat.com>
3043
3044 * cp-support.c (cp_find_first_component_aux): Add missing case for
3045 end of string.
3046
c5ed0576
DB
30472017-07-18 David Blaikie <dblaikie@gmail.com>
3048
3049 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
3050 of dwo_cu's dwo_file.
3051
27841e76
YQ
30522017-07-18 Yao Qi <yao.qi@linaro.org>
3053
3054 * remote.c (store_registers_using_G): Remove one line comment.
3055
cfb7e58b
YQ
30562017-07-18 Yao Qi <yao.qi@linaro.org>
3057
3058 * regcache.c (regcache_cpy): Simplify it.
3059 (regcache::cpy_no_passthrough): Remove it.
3060 * regcache.h (cpy_no_passthrough): Remove it.
3061 (regcache_dup, regcache_cpy): Update comments.
3062
386535dd
PA
30632017-07-18 Pedro Alves <palves@redhat.com>
3064
3065 * remote-sim.c (sim_command_completer): Adjust to work with a
3066 completion_tracker instead of a VEC.
3067
c45ec17c
PA
30682017-07-17 Pedro Alves <palves@redhat.com>
3069
3070 * completer.c (complete_source_filenames): New function.
3071 (complete_address_and_linespec_locations): New function.
3072 (location_completer): Use complete_address_and_linespec_locations.
3073 (completion_tracker::build_completion_result): Honor the tracker's
3074 request to suppress append.
3075 * completer.h (completion_tracker::suppress_append_ws)
3076 (completion_tracker::set_suppress_append_ws): New methods.
3077 (completion_tracker::m_suppress_append_ws): New field.
3078 (complete_source_filenames): New declaration.
3079 * linespec.c (linespec_complete_what): New.
3080 (struct ls_parser) <complete_what, completion_word,
3081 completion_quote_char, completion_quote_end, completion_tracker>:
3082 New fields.
3083 (string_find_incomplete_keyword_at_end): New.
3084 (linespec_lexer_lex_string): Record quote char. If in completion
3085 mode, don't throw.
3086 (linespec_lexer_consume_token): Advance the completion word point.
3087 (linespec_lexer_peek_token): Save/restore completion info.
3088 (save_stream_and_consume_token): New.
3089 (set_completion_after_number): New.
3090 (linespec_parse_basic): Set what to complete next depending on
3091 token. Handle function and label completions specially.
3092 (parse_linespec): Disable objc shortcut in completion mode. Set
3093 what to complete next depending on token type. Skip keyword if in
3094 completion mode.
3095 (complete_linespec_component, linespec_complete): New.
3096 * linespec.h (linespec_complete): Declare.
3097
be966d42
PA
30982017-07-17 Pedro Alves <palves@redhat.com>
3099
3100 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
3101 Handle 'operator<' / 'operator<<'.
3102
a2459270
PA
31032017-07-17 Pedro Alves <palves@redhat.com>
3104
3105 * completer.c (collect_explicit_location_matches): Handle
3106 MATCH_LABEL.
3107 (convert_explicit_location_to_linespec): New, factored out from
3108 ...
3109 (convert_explicit_location_to_sals): ... this.
3110 (complete_label): New.
3111 (linespec_complete_label, find_label_symbols_in_block): New.
3112 (find_label_symbols): Add completion_mode parameter and adjust to
3113 call find_label_symbols_in_block.
3114 * linespec.h (linespec_complete_label): Declare.
3115
c6756f62
PA
31162017-07-17 Pedro Alves <palves@redhat.com>
3117
3118 * ada-lang.c (ada_collect_symbol_completion_matches): Add
3119 complete_symbol_mode parameter.
3120 * cli/cli-cmds.c (complete_command): Get the completion result out
3121 of the handle_brkchars tracker if used a custom word point.
3122 * completer.c: Include "linespec.h".
3123 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
3124 (advance_to_expression_complete_word_point): New.
3125 (completion_tracker::completes_to_completion_word): New.
3126 (complete_files_symbols): Pass down
3127 complete_symbol_mode::EXPRESSION.
3128 (explicit_options, probe_options): New.
3129 (collect_explicit_location_matches): Complete on the
3130 explictit_loc->foo instead of word. Use
3131 linespec_complete_function. Handle MATCH_LINE. Handle offering
3132 keyword and options completions.
3133 (backup_text_ptr): Delete.
3134 (skip_keyword): New.
3135 (complete_explicit_location): Remove 'word' parameter. Add
3136 language, quoted_arg_start and quoted_arg_end parameters.
3137 Rewrite, parsing left to right.
3138 (location_completer): Rewrite.
3139 (location_completer_handle_brkchars): New function.
3140 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
3141 (enum complete_line_internal_reason): Adjust comments.
3142 (completion_tracker::discard_completions): New.
3143 (completer_handle_brkchars_func_for_completer): Handle
3144 location_completer.
3145 (gdb_custom_word_point_brkchars)
3146 (gdb_org_rl_basic_quote_characters): New.
3147 (gdb_completion_word_break_characters_throw)
3148 (completion_find_completion_word): Handle trackers that use a
3149 custom word point.
3150 (completion_tracker::advance_custom_word_point_by): New.
3151 (completion_tracker::build_completion_result): Don't rely on
3152 readline appending the quote char.
3153 (gdb_rl_attempted_completion_function_throw): Handle trackers that
3154 use a custom word point.
3155 (gdb_rl_attempted_completion_function): Restore
3156 rl_basic_quote_characters.
3157 * completer.h (class completion_tracker): Extend intro comment.
3158 (completion_tracker::set_quote_char)
3159 (completion_tracker::quote_char)
3160 (completion_tracker::set_use_custom_word_point)
3161 (completion_tracker::use_custom_word_point)
3162 (completion_tracker::custom_word_point)
3163 (completion_tracker::set_custom_word_point)
3164 (completion_tracker::advance_custom_word_point_by)
3165 (completion_tracker::completes_to_completion_word)
3166 (completion_tracker::discard_completions): New methods.
3167 (completion_tracker::m_quote_char)
3168 (completion_tracker::m_use_custom_word_point)
3169 (completion_tracker::m_custom_word_point): New fields.
3170 (advance_to_expression_complete_word_point): Declare.
3171 * f-lang.c (f_collect_symbol_completion_matches): Add
3172 complete_symbol_mode parameter.
3173 * language.h (struct language_defn)
3174 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
3175 parameter.
3176 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
3177 (linespec_complete_function): New function.
3178 (linespec_lexer_lex_keyword): Adjust.
3179 * linespec.h (linespec_keywords, linespec_complete_function): New
3180 declarations.
3181 * location.c (find_end_quote): New function.
3182 (explicit_location_lex_one): Add explicit_completion_info
3183 parameter. Save quoting info. Don't throw if being called for
3184 completion. Don't handle Ada operators here.
3185 (is_cp_operator, skip_op_false_positives, first_of)
3186 (explicit_location_lex_one_function): New function.
3187 (string_to_explicit_location): Replace 'dont_throw' parameter with
3188 an explicit_completion_info pointer parameter. Handle it. Don't
3189 use explicit_location_lex_one to lex function names. Use
3190 explicit_location_lex_one_function instead.
3191 * location.h (struct explicit_completion_info): New.
3192 (string_to_explicit_location): Replace 'dont_throw' parameter with
3193 an explicit_completion_info pointer parameter.
3194 * symtab.c (default_collect_symbol_completion_matches_break_on):
3195 Add complete_symbol_mode parameter. Handle LINESPEC mode.
3196 (default_collect_symbol_completion_matches)
3197 (collect_symbol_completion_matches): Add complete_symbol_mode
3198 parameter.
3199 (collect_symbol_completion_matches_type): Pass down
3200 complete_symbol_mode::EXPRESSION.
3201 (collect_file_symbol_completion_matches): Add complete_symbol_mode
3202 parameter. Handle LINESPEC mode.
3203 * symtab.h (complete_symbol_mode): New.
3204 (default_collect_symbol_completion_matches_break_on)
3205 (default_collect_symbol_completion_matches)
3206 (collect_symbol_completion_matches)
3207 (collect_file_symbol_completion_matches): Add complete_symbol_mode
3208 parameter.
3209
1d550c82
PA
32102017-07-17 Pedro Alves <palves@redhat.com>
3211
3212 * utils.c (enum class strncmp_iw_mode): New.
3213 (strcmp_iw): Rename to ...
3214 (strncmp_iw_with_mode): ... this. Add string2_len and mode
3215 parameters. Handle them.
3216 (strncmp_iw): New.
3217 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
3218 * utils.h (strncmp_iw): Declare.
3219 (strcmp_iw): Move describing comments here.
3220
8090b426
PA
32212017-07-17 Pedro Alves <palves@redhat.com>
3222
3223 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
3224 CP_OPERATOR_STR.
3225 * c-typeprint.c (is_type_conversion_operator): Use
3226 CP_OPERATOR_STR.
3227 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
3228 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
3229 CP_OPERATOR_LEN.
3230 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
3231 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
3232 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
3233 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
3234 CP_OPERATOR_STR.
3235 * location.c: Include "cp-support.h".
3236 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
3237 CP_OPERATOR_STR.
3238 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
3239 CP_OPERATOR_LEN.
3240
6a2c1b87
PA
32412017-07-17 Pedro Alves <palves@redhat.com>
3242
3243 * cli/cli-cmds.c (complete_command): Use a completion tracker
3244 along with completion_find_completion_word for handle_brkchars
3245 phase.
3246 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
3247 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
3248 (struct gdb_rl_completion_word_info): New.
3249 (gdb_rl_find_completion_word): New.
3250 (completion_find_completion_word): New.
3251 * completer.h (completion_find_completion_word): Declare.
3252
eb3ff9a5
PA
32532017-07-17 Pedro Alves <palves@redhat.com>
3254
3255 * ada-lang.c (symbol_completion_match): Adjust comments.
3256 (symbol_completion_add): Replace vector parameter with
3257 completion_tracker parameter. Use it.
3258 (ada_make_symbol_completion_list): Rename to...
3259 (ada_collect_symbol_completion_matches): ... this. Add
3260 completion_tracker parameter and use it.
3261 (ada_language_defn): Adjust.
3262 * break-catch-syscall.c (catch_syscall_completer): Adjust
3263 prototype and work with completion_tracker instead of VEC.
3264 * breakpoint.c (condition_completer): Adjust prototype and work
3265 with completion_tracker instead of VEC.
3266 * c-lang.c (c_language_defn, cplus_language_defn)
3267 (asm_language_defn, minimal_language_defn): Adjust to renames.
3268 * cli/cli-cmds.c (complete_command): Rework using
3269 completion_tracker. Catch exceptions when completing.
3270 * cli/cli-decode.c (integer_unlimited_completer)
3271 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
3272 with completion_tracker instead of VEC.
3273 * command.h (struct completion_tracker): Forward declare.
3274 (completer_ftype, completer_handle_brkchars_ftype): Change
3275 types.
3276 (complete_on_cmdlist, complete_on_enum): Adjust.
3277 * completer.c: Include <algorithm>.
3278 (struct gdb_completer_state): New.
3279 (current_completion): New global.
3280 (readline_line_completion_function): Delete.
3281 (noop_completer, filename_completer)
3282 (filename_completer_handle_brkchars, complete_files_symbols)
3283 (linespec_location_completer): Adjust to work with a
3284 completion_tracker instead of a VEC.
3285 (string_or_empty): New.
3286 (collect_explicit_location_matches): Adjust to work with a
3287 completion_tracker instead of a VEC.
3288 (explicit_location_completer): Rename to ...
3289 (complete_explicit_location): ... this and adjust to work with a
3290 completion_tracker instead of a VEC.
3291 (location_completer): Adjust to work with a completion_tracker
3292 instead of a VEC.
3293 (add_struct_fields): Adjust to work with a completion_list instead
3294 of VEC.
3295 (expression_completer): Rename to ...
3296 (complete_expression): ... this and adjust to work with a
3297 completion_tracker instead of a VEC. Use complete_files_symbols.
3298 (expression_completer): Reimplement on top of complete_expression.
3299 (symbol_completer): Adjust to work with a completion_tracker
3300 instead of a VEC.
3301 (enum complete_line_internal_reason): Add describing comments.
3302 (complete_line_internal_normal_command): Adjust to work with a
3303 completion_tracker instead of a VEC.
3304 (complete_line_internal): Rename to ...
3305 (complete_line_internal_1): ... this and adjust to work with a
3306 completion_tracker instead of a VEC. Assert TEXT is NULL in the
3307 handle_brkchars phase.
3308 (new_completion_tracker): Delete.
3309 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
3310 complete_line_internal_1.
3311 (free_completion_tracker): Delete.
3312 (INITIAL_COMPLETION_HTAB_SIZE): New.
3313 (completion_tracker::completion_tracker)
3314 (completion_tracker::~completion_tracker): New.
3315 (maybe_add_completion): Delete.
3316 (completion_tracker::maybe_add_completion)
3317 (completion_tracker::add_completion)
3318 (completion_tracker::add_completions): New.
3319 (throw_max_completions_reached_error): Delete.
3320 (complete_line): Adjust to work with a completion_tracker instead
3321 of a VEC. Don't create a completion_tracker_t or check for max
3322 completions here.
3323 (command_completer, command_completer_handle_brkchars)
3324 (signal_completer, reg_or_group_completer_1)
3325 (reg_or_group_completer, default_completer_handle_brkchars):
3326 Adjust to work with a completion_tracker.
3327 (gdb_completion_word_break_characters_throw): New.
3328 (gdb_completion_word_break_characters): Reimplement.
3329 (line_completion_function): Delete.
3330 (completion_tracker::recompute_lowest_common_denominator)
3331 (expand_preserving_ws)
3332 (completion_tracker::build_completion_result)
3333 (completion_result::completion_result)
3334 (completion_result::completion_result)
3335 (completion_result::~completion_result)
3336 (completion_result::completion_result)
3337 (completion_result::release_match_list, compare_cstrings)
3338 (completion_result::sort_match_list)
3339 (completion_result::reset_match_list)
3340 (gdb_rl_attempted_completion_function_throw)
3341 (gdb_rl_attempted_completion_function): New.
3342 * completer.h (completion_list, struct completion_result)
3343 (class completion_tracker): New.
3344 (complete_line): Add completion_tracker parameter.
3345 (readline_line_completion_function): Delete.
3346 (gdb_rl_attempted_completion_function): New.
3347 (noop_completer, filename_completer, expression_completer)
3348 (location_completer, symbol_completer, command_completer)
3349 (signal_completer, reg_or_group_completer): Update prototypes.
3350 (completion_tracker_t, new_completion_tracker)
3351 (make_cleanup_free_completion_tracker): Delete.
3352 (enum maybe_add_completion_enum): Delete.
3353 (maybe_add_completion): Delete.
3354 (throw_max_completions_reached_error): Delete.
3355 * corefile.c (complete_set_gnutarget): Adjust to work with a
3356 completion_tracker instead of a VEC.
3357 * cp-abi.c (cp_abi_completer): Adjust to work with a
3358 completion_tracker instead of a VEC.
3359 * d-lang.c (d_language_defn): Adjust.
3360 * disasm.c (disassembler_options_completer): Adjust to work with a
3361 completion_tracker instead of a VEC.
3362 * f-lang.c (f_make_symbol_completion_list): Rename to ...
3363 (f_collect_symbol_completion_matches): ... this. Adjust to work
3364 with a completion_tracker instead of a VEC.
3365 (f_language_defn): Adjust.
3366 * go-lang.c (go_language_defn): Adjust.
3367 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
3368 Adjust to work with a completion_tracker instead of a VEC.
3369 * infrun.c (handle_completer): Likewise.
3370 * interps.c (interpreter_completer): Likewise.
3371 * interps.h (interpreter_completer): Likewise.
3372 * language.c (unknown_language_defn, auto_language_defn)
3373 (local_language_defn): Adjust.
3374 * language.h (language_defn::la_make_symbol_completion_list):
3375 Rename to ...
3376 (language_defn::la_collect_symbol_completion_matches): ... this
3377 and adjust to work with a completion_tracker instead of a VEC.
3378 * m2-lang.c (m2_language_defn): Adjust.
3379 * objc-lang.c (objc_language_defn): Adjust.
3380 * opencl-lang.c (opencl_language_defn): Adjust.
3381 * p-lang.c (pascal_language_defn): Adjust.
3382 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
3383 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
3384 with a completion_tracker.
3385 * rust-lang.c (rust_language_defn): Adjust.
3386 * symtab.c (free_completion_list, do_free_completion_list)
3387 (return_val, completion_tracker): Delete.
3388 (completion_list_add_name, completion_list_add_symbol)
3389 (completion_list_add_msymbol, completion_list_objc_symbol)
3390 (completion_list_add_fields, add_symtab_completions): Add
3391 completion_tracker parameter and use it.
3392 (default_make_symbol_completion_list_break_on_1): Rename to...
3393 (default_collect_symbol_completion_matches_break_on): ... this.
3394 Add completion_tracker parameter and use it instead of allocating
3395 a completion tracker here.
3396 (default_make_symbol_completion_list_break_on): Delete old
3397 implementation.
3398 (default_make_symbol_completion_list): Delete.
3399 (default_collect_symbol_completion_matches): New.
3400 (make_symbol_completion_list): Delete.
3401 (collect_symbol_completion_matches): New.
3402 (make_symbol_completion_type): Rename to ...
3403 (collect_symbol_completion_matches_type): ... this. Add
3404 completion_tracker parameter and use it instead of VEC.
3405 (make_file_symbol_completion_list_1): Rename to...
3406 (collect_file_symbol_completion_matches): ... this. Add
3407 completion_tracker parameter and use it instead of VEC.
3408 (make_file_symbol_completion_list): Delete.
3409 (add_filename_to_list): Use completion_list instead of a VEC.
3410 (add_partial_filename_data::list): Now a completion_list.
3411 (make_source_files_completion_list): Work with a completion_list
3412 instead of a VEC.
3413 * symtab.h: Include "completer.h".
3414 (default_make_symbol_completion_list_break_on)
3415 (default_make_symbol_completion_list, make_symbol_completion_list)
3416 (make_symbol_completion_type, make_file_symbol_completion_list)
3417 (make_source_files_completion_list): Delete.
3418 (default_collect_symbol_completion_matches_break_on)
3419 (default_collect_symbol_completion_matches)
3420 (collect_symbol_completion_matches)
3421 (collect_symbol_completion_matches_type)
3422 (collect_file_symbol_completion_matches)
3423 (make_source_files_completion_list): New.
3424 * top.c (init_main): Don't install a rl_completion_entry_function
3425 hook. Install a rl_attempted_completion_function hook instead.
3426 * tui/tui-layout.c (layout_completer): Adjust to work with a
3427 completion_tracker.
3428 * tui/tui-regs.c (tui_reggroup_completer):
3429 * tui/tui-win.c (window_name_completer, focus_completer)
3430 (winheight_completer): Adjust to work with a completion_tracker.
3431 * value.c: Include "completer.h".
3432 (complete_internalvar): Adjust to work with a completion_tracker.
3433 * value.h (complete_internalvar): Likewise.
3434
6e1dbf8c
PA
34352017-07-17 Pedro Alves <palves@redhat.com>
3436
3437 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
3438 renames.
3439 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
3440 comments to completer_ftype's declaration.
3441 <completer_handle_brkchars>: Change type to
3442 completer_handle_brkchars_ftype.
3443 * command.h (completer_ftype): Add describing comment and give
3444 names to parameters.
3445 (completer_ftype_void): Rename to ...
3446 (completer_handle_brkchars_ftype) ... this. Add describing comment.
3447 (set_cmd_completer_handle_brkchars): Adjust.
3448 * completer.c (filename_completer_handle_brkchars): New function.
3449 (complete_line_internal_normal_command): New function, factored
3450 out from ...
3451 (complete_line_internal): ... here.
3452 (command_completer_handle_brkchars)
3453 (default_completer_handle_brkchars)
3454 (completer_handle_brkchars_func_for_completer): New functions.
3455 * completer.h (set_gdb_completion_word_break_characters): Delete
3456 declaration.
3457 (completer_handle_brkchars_func_for_completer): New declaration.
3458 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
3459 completer_handle_brkchars_func_for_completer.
3460
78b13106
PA
34612017-07-17 Pedro Alves <palves@redhat.com>
3462
3463 * completer.c (symbol_completer): New function, based on
3464 make_symbol_completion_list_fn.
3465 * completer.h (symbol_completer): New declaration.
3466 * guile/scm-cmd.c (cmdscm_completers): Adjust.
3467 * python/py-cmd.c (completers): Adjust.
3468 * symtab.c (make_symbol_completion_list_fn): Delete.
3469 * symtab.h (make_symbol_completion_list_fn): Delete.
3470 * cli/cli-decode.c (add_cmd): Adjust.
3471
bbf2f4df
PA
34722017-07-17 Pedro Alves <palves@redhat.com>
3473
3474 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
3475 * dwarf2read.c: Include "filename-seen-cache.h".
3476 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
3477 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
3478 * filename-seen-cache.c: New file.
3479 * filename-seen-cache.h: New file.
3480 * symtab.c: Include "filename-seen-cache.h".
3481 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
3482 (create_filename_seen_cache, clear_filename_seen_cache)
3483 (delete_filename_seen_cache, filename_seen): Delete, parts moved
3484 to filename-seen-cache.h/filename-seen-cache.c.
3485 (output_source_filename, sources_info)
3486 (maybe_add_partial_symtab_filename)
3487 (make_source_files_completion_list): Adjust to use
3488 filename_seen_cache.
3489
330cdd98
PA
34902017-07-17 Pedro Alves <palves@redhat.com>
3491
3492 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
3493 fields.
3494 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
3495 dwarf2_debug_sections*)): New.
3496 (dwarf2_per_objfile::dwarf2_per_objfile(const
3497 dwarf2_per_objfile&)): Declare as deleted.
3498 (dwarf2_per_objfile::operator=): Declare as deleted.
3499 (dwarf2_per_objfile::dwarf2_per_objfile)
3500 (dwarf2_per_objfile::~dwarf2_per_objfile)
3501 (dwarf2_per_objfile::free_cached_comp_units): New.
3502 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
3503 ctor. Call dwarf2_per_objfile's ctor manually.
3504 (dwarf2_locate_sections): Deleted/refactored as ...
3505 (dwarf2_per_objfile::locate_sections): ... this new method.
3506 (free_cached_comp_units): Defer to
3507 dwarf2_per_objfile::free_cached_comp_units.
3508 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
3509
8880f2a9
TT
35102017-07-14 Tom Tromey <tom@tromey.com>
3511
3512 PR rust/21764:
3513 * rust-exp.y (convert_ast_to_expression): Add "want_type"
3514 parameter.
3515 <UNOP_SIZEOF>: Split into separate case.
3516 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
3517
65547233
TT
35182017-07-14 Tom Tromey <tom@tromey.com>
3519
3520 PR rust/21763:
3521 * symtab.c (symbol_matches_domain): Add language_rust to special
3522 case.
3523 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
3524 treat LOC_TYPEDEF symbols as variables.
3525
8f14146e
PA
35262017-07-14 Pedro Alves <palves@redhat.com>
3527
3528 * symtab.c (make_file_symbol_completion_list_1): Iterate over
3529 symtabs matching all symtabs with SRCFILE as file name instead of
3530 only considering the first hit, with lookup_symtab.
3531
2347965c
SM
35322017-07-14 Simon Marchi <simon.marchi@ericsson.com>
3533
3534 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
3535 operator_name parameters.
3536 (gen_expr): Update function call.
3537
40f4af28
SM
35382017-07-14 Simon Marchi <simon.marchi@ericsson.com>
3539
3540 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
3541 parameter.
3542 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
3543 Likewise.
3544 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
3545 parameter, use agent_expr::gdbarch instead, update function
3546 calls.
3547 (locexpr_tracepoint_var_ref): Likewise.
3548 (loclist_tracepoint_var_ref): Likewise.
3549 * ax-gdb.c (gen_trace_static_fields): Likewise.
3550 (gen_traced_pop): Likewise.
3551 (gen_frame_args_address): Likewise.
3552 (gen_frame_locals_address): Likewise.
3553 (gen_var_ref): Likewise.
3554 (gen_struct_ref_recursive): Likewise.
3555 (gen_static_field): Likewise.
3556 (gen_maybe_namespace_elt): Likewise.
3557 (gen_expr): Likewise.
3558 (gen_trace_for_var): Likewise.
3559 (gen_trace_for_expr): Likewise.
3560 (gen_trace_for_return_address): Likewise.
3561
053f8057
SM
35622017-07-14 Simon Marchi <simon.marchi@ericsson.com>
3563
3564 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
3565 parameter.
3566 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
3567
6661ad48
SM
35682017-07-14 Simon Marchi <simon.marchi@ericsson.com>
3569
3570 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
3571 from ax, update calls.
3572 (gen_usual_arithmetic): Likewise.
3573 (gen_integral_promotions): Likewise.
3574 (gen_bitfield_ref): Likewise.
3575 (gen_primitive_field): Likewise.
3576 (gen_struct_ref_recursive): Likewise.
3577 (gen_struct_ref): Likewise.
3578 (gen_maybe_namespace_elt): Likewise.
3579 (gen_struct_elt_for_reference): Likewise.
3580 (gen_namespace_elt): Likewise.
3581 (gen_aggregate_elt_ref): Likewise.
3582 (gen_expr): Get gdbarch from ax, update calls.
3583 (gen_expr_binop_rest): Likewise.
3584
c55a47e7
PA
35852017-07-13 Pedro Alves <palves@redhat.com>
3586
3587 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
3588 as default tdesc.
3589 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
3590 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
3591 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
3592 tdesc_amd64_linux as default tdesc. Get final tdesc from the
3593 tdep.
3594 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
3595 Get final tdesc from the tdep.
3596 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
3597 default tdesc.
3598 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
3599 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
3600 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
3601 Use it as default tdesc.
3602 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
3603 down to amd_init_abi. No longer handle fallback tdesc here.
3604 * amd64-tdep.h (tdesc_x32): Declare.
3605 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
3606 parameter.
3607 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
3608 as default tdesc.
3609
55efceab
AA
36102017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
3611
3612 * s390-linux-tdep.c (s390_process_record): Add support for
3613 instructions new in arch12.
3614
0aa37b65
JB
36152017-07-11 John Baldwin <jhb@FreeBSD.org>
3616
3617 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
3618 PT_GETFSBASE and PT_GETGSBASE.
3619 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
3620 PT_SETGSBASE.
3621
48aeef91
JB
36222017-07-11 John Baldwin <jhb@FreeBSD.org>
3623
3624 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
3625 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
3626 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
3627 those rules.
3628 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
3629 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
3630 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
3631 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
3632 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
3633 * features/i386/amd64.xml: Add 64bit-segments.xml.
3634 * features/i386/amd64-avx-avx512.c: Regenerated.
3635 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
3636 * features/i386/amd64-avx-mpx.c: Regenerated.
3637 * features/i386/amd64-avx.c: Regenerated.
3638 * features/i386/amd64-mpx.c: Regenerated.
3639 * features/i386/amd64.c: Regenerated.
3640 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
3641 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
3642 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
3643 * regformats/i386/amd64-avx.dat: Regenerated.
3644 * regformats/i386/amd64-mpx.dat: Regenerated.
3645 * regformats/i386/amd64.dat: Regenerated.
3646
77c501bc
YQ
36472017-07-10 Yao Qi <yao.qi@linaro.org>
3648
3649 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
3650 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
3651
6dc8d757
AK
36522017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
3653
3654 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
3655 unsetenv.
3656 * gnulib/aclocal.m4: Regenerate.
3657 * gnulib/config.in: Regenerate.
3658 * gnulib/configure: Regenerate.
3659 * gnulib/import/Makefile.am: Regenerate.
3660 * gnulib/import/Makefile.in: Regenerate.
3661 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
3662 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
3663 * gnulib/import/m4/environ.m4: New file.
3664 * gnulib/import/m4/setenv.m4: New file.
3665 * gnulib/import/setenv.c: New file.
3666 * gnulib/import/unsetenv.c: New file.
3667
266934d1
SM
36682017-07-09 Simon Marchi <simon.marchi@ericsson.com>
3669
3670 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
3671 address when op is DW_OP_addr.
3672
03278692
TT
36732017-07-09 Tom Tromey <tom@tromey.com>
3674
3675 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
3676 check and apply to outer type.
3677
4b654465
JB
36782017-07-07 John Baldwin <jhb@FreeBSD.org>
3679
3680 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
3681 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
3682 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
3683 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
3684
2af9fc44
JB
36852017-07-07 John Baldwin <jhb@FreeBSD.org>
3686
3687 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
3688
382b69bb
JB
36892017-07-07 John Baldwin <jhb@FreeBSD.org>
3690
3691 * corelow.c (get_core_siginfo): Remove.
3692 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
3693 instead of get_core_siginfo.
3694 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
3695 * gdbarch.h: Re-generate.
3696 * gdbarch.c: Re-generate.
3697 * linux-tdep.c (linux_core_xfer_siginfo): New.
3698 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
3699
6e5eab33
JB
37002017-07-07 John Baldwin <jhb@FreeBSD.org>
3701
3702 * corelow.c (thread_section_name): Move to ...
3703 * gdbcore.h (thread_section_name): ... here.
3704
929edea9
JB
37052017-07-07 John Baldwin <jhb@FreeBSD.org>
3706
3707 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
3708 (struct siginfo32): New.
3709 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
3710 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
3711 via ptrace(PT_LWPINFO).
3712
762c974a
JB
37132017-07-07 John Baldwin <jhb@FreeBSD.org>
3714
3715 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
3716 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
3717 (fbsd_get_siginfo_type): New.
3718 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
3719 (_initialize_fbsd_tdep): New.
3720
33c5cd75
DB
37212017-07-06 David Blaikie <dblaikie@gmail.com>
3722
3723 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
3724 a singular dwo_unit*) to support multiple CUs in the same way that
3725 multiple TUs are supported.
3726 (create_cus_hash_table): Replace create_dwo_cu with a function for
3727 parsing multiple CUs from a DWO file.
3728 (open_and_init_dwo_file): Use create_cus_hash_table rather than
3729 create_dwo_cu.
3730 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
3731 htab_find, rather than comparing the signature to a singleton CU in
3732 the dwo_file.
3733
8455d262
PA
37342017-07-06 Pedro Alves <palves@redhat.com>
3735
3736 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
3737
4da3eb35
PA
37382017-07-04 Pedro Alves <palves@redhat.com>
3739
3740 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
3741 * gdbtypes.h (TYPE_STATIC): Delete.
3742 (struct fn_field) <is_public, is_abstract, is_static, is_final,
3743 is_synchronized, is_native>: Delete.
3744 <dummy>: Bump.
3745 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
3746 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
3747 (TYPE_FN_FIELD_ABSTRACT): Delete.
3748
5bfd255c
SM
37492017-07-03 Simon Marchi <simon.marchi@ericsson.com>
3750
3751 * buffer.h (buffer_finish): Fix spelling mistakes.
3752
25c54127
EZ
37532017-07-01 Eli Zaretskii <eliz@gnu.org>
3754
3755 * .dir-locals.el: Automatically switch to C-style comments in
3756 versions of Emacs that support the feature.
3757
dc4bde35
SDJ
37582017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
3759 Pedro Alves <palves@redhat.com>
3760
3761 PR cli/21688
3762 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
3763 (process_next_line): New variable 'inline_cmd'.
3764 Adjust 'if' clauses for "python", "compile" and "guile" to use
3765 'command_name_equals' and check for '!inline_cmd'.
3766
51ed89aa
SDJ
37672017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
3768
3769 PR cli/21688
3770 * cli/cli-script.c (command_name_equals_not_inline): New function.
3771 (process_next_line): Adjust 'if' clauses for "python", "compile"
3772 and "guile" to use command_name_equals_not_inline.
3773
eb17d413
PA
37742017-06-29 Pedro Alves <palves@redhat.com>
3775
3776 * completer.c (expression_completer): Call
3777 linespec_location_completer instead of location_completer.
3778
195bcdd5
PA
37792017-06-29 Pedro Alves <palves@redhat.com>
3780
3781 * completer.c (expression_completer): Remove code that recomputes
3782 'text' from 'word'.
3783
adc764e7
YQ
37842017-06-29 Yao Qi <yao.qi@linaro.org>
3785
3786 * regformats/regdat.sh: Generate code with
3787 "ifndef IN_PROCESS_AGENT".
3788
6e75794e
PA
37892017-06-28 Pedro Alves <palves@redhat.com>
3790
3791 * command.h: Include "common/scoped_restore.h".
3792
bc491f2e
YQ
37932017-06-28 Yao Qi <yao.qi@linaro.org>
3794
3795 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
3796 instead of obstack_grow.
3797
41664b45
DG
37982017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
3799
3800 PR gdb/21337
3801 * symfile.c (reread_symbols): Call objfiles_changed just before
3802 read_symbols.
3803
6da67eb1
PA
38042017-06-27 Pedro Alves <palves@redhat.com>
3805
3806 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
3807 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
3808 (completion_list_add_symbol, completion_list_add_msymbol):
3809 ... these new functions.
3810 (add_symtab_completions)
3811 (default_make_symbol_completion_list_break_on_1): Adjust.
3812
23732b1e
PA
38132017-06-27 Pedro Alves <palves@redhat.com>
3814
3815 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
3816 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
3817 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
3818 dtor.
3819 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
3820 'storage_obstack' field an auto_obstack. In-class initialize all
3821 non-bitfield fields. Make minsyms_read bool.
3822 * symfile.c (read_symbols): Adjust.
3823
a4d1e79a
AH
38242017-06-27 Alan Hayward <alan.hayward@arm.com>
3825
3826 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
3827 (gdbsim_store_register): Likewise.
3828
8268c778
PA
38292017-06-27 Pedro Alves <palves@redhat.com>
3830
3831 * c-exp.y (name_obstack): Now an auto_obstack.
3832 (yylex): Use auto_obstack::clear.
3833 (c_parse): Use auto_obstack::clear instead of reinitializing and
3834 freeing the obstack.
3835 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
3836 * d-exp.y (name_obstack): Now an auto_obstack.
3837 (yylex): Use auto_obstack::clear.
3838 (d_parse): Use auto_obstack::clear instead of reinitializing and
3839 freeing the obstack.
3840 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
3841 auto_obstack.
3842 * dwarf2read.c (create_addrmap_from_index)
3843 (dwarf2_build_psymtabs_hard)
3844 (update_enumeration_type_from_children): Likewise.
3845 * gdb_obstack.h (auto_obstack): New type.
3846 * go-exp.y (name_obstack): Now an auto_obstack.
3847 (build_packaged_name): Use auto_obstack::clear.
3848 (go_parse): Use auto_obstack::clear instead of reinitializing and
3849 freeing the obstack.
3850 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
3851 auto_obstack.
3852 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
3853 * rust-exp.y (work_obstack): Now an auto_obstack.
3854 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
3855 reinitializing and freeing the obstack.
3856 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
3857 (host_char_to_target): Use auto_obstack.
3858 * utils.h (make_cleanup_obstack_free): Delete declaration.
3859 * valprint.c (generic_emit_char, generic_printstr): Use
3860 auto_obstack.
3861
db665f42
SM
38622017-06-27 Simon Marchi <simon.marchi@ericsson.com>
3863
3864 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
3865 thread.
3866 (darwin_init_thread_list): Don't update dummy thread.
3867 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
3868
873c0814
SM
38692017-06-26 Simon Marchi <simon.marchi@ericsson.com>
3870
3871 * record-full.c (netorder16): Remove.
3872
8b5a7a6e
SM
38732017-06-26 Simon Marchi <simon.marchi@ericsson.com>
3874
3875 * common/diagnostics.h: Define macros for GCC.
3876 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
3877 * common/vec.h: Include diagnostics.h.
3878 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
3879 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
3880 warning.
3881
d1435379
SM
38822017-06-26 Simon Marchi <simon.marchi@ericsson.com>
3883
3884 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
3885 New macro.
3886 * ada-lex.l: Ignore deprecated register warnings.
3887
cc75e0fd
SM
38882017-06-25 Simon Marchi <simon.marchi@ericsson.com>
3889
3890 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
3891 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
3892
07809eaf
SM
38932017-06-25 Simon Marchi <simon.marchi@ericsson.com>
3894
3895 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
3896 its own line.
3897
f076f034
SM
38982017-06-25 Simon Marchi <simon.marchi@ericsson.com>
3899
3900 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
3901
0dd5cbc5
AH
39022017-06-23 Alan Hayward <alan.hayward@arm.com>
3903
3904 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
3905 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
3906 (xtensa_register_read_masked): Likewise.
3907
d4c6ce5b
SDJ
39082017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
3909
3910 * common/environ.c (gdb_environ::unset): Update comment.
3911
16892a03
AH
39122017-06-22 Alan Hayward <alan.hayward@arm.com>
3913
3914 * python/py-unwind.c (pyuw_sniffer): Allocate space for
3915 registers.
3916
d7dcbefc
AH
39172017-06-22 Alan Hayward <alan.hayward@arm.com>
3918
3919 * record-full.c (record_full_exec_insn): Use byte_vector.
3920
b30ff123
YQ
39212017-06-22 Yao Qi <yao.qi@linaro.org>
3922
3923 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
3924 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
3925
4fa847d7
AH
39262017-06-22 Alan Hayward <alan.hayward@arm.com>
3927
3928 * remote.c (cached_reg): Move from here...
3929 * regcache.h (cached_reg): ...to here.
3930 * python/py-unwind.c (struct reg_info): Remove.
3931 (cached_frame_info): Use cached_reg_t.
3932 (pyuw_prev_register): Likewise.
3933 (pyuw_sniffer): Use cached_reg_t and allocate registers.
3934 (pyuw_dealloc_cache): Free all registers.
3935
f4906a9a
PA
39362017-06-22 Pedro Alves <palves@redhat.com>
3937 Simon Marchi <simon.marchi@ericsson.com>
3938
3939 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
3940 warning.
3941 * common/diagnostics.h: New file.
3942
b45a1208
PA
39432017-06-22 Pedro Alves <palves@redhat.com>
3944
3945 * common/agent.h: Add include guards.
3946
e4da2c61
SM
39472017-06-21 Simon Marchi <simon.marchi@ericsson.com>
3948
3949 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
3950 talk about addressable units instead of bytes.
3951
96160d60
SDJ
39522017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
3953
3954 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
3955 of '::const_iterator'.
3956
9a6c7d9c
SDJ
39572017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
3958
3959 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3960 'unittests/environ-selftests.c'.
3961 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
3962 * charset.c (find_charset_names): Declare object 'iconv_env'.
3963 Update code to use 'iconv_env' object. Remove call to
3964 'free_environ'.
3965 * common/environ.c: Include <utility>.
3966 (make_environ): Delete function.
3967 (free_environ): Delete function.
3968 (gdb_environ::clear): New function.
3969 (gdb_environ::operator=): New function.
3970 (gdb_environ::get): Likewise.
3971 (environ_vector): Delete function.
3972 (set_in_environ): Delete function.
3973 (gdb_environ::set): New function.
3974 (unset_in_environ): Delete function.
3975 (gdb_environ::unset): New function.
3976 (gdb_environ::envp): Likewise.
3977 * common/environ.h: Include <vector>.
3978 (struct gdb_environ): Delete; transform into...
3979 (class gdb_environ): ... this class.
3980 (free_environ): Delete prototype.
3981 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
3982 environ_vector): Likewise.
3983 * infcmd.c (run_command_1): Update code to call
3984 'envp' from 'gdb_environ' class.
3985 (environment_info): Update code to call methods from 'gdb_environ'
3986 class.
3987 (unset_environment_command): Likewise.
3988 (path_info): Likewise.
3989 (path_command): Likewise.
3990 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
3991 (inferior::inferior): Initialize 'environment' using the host's
3992 information.
3993 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
3994 Include "environ.h".
3995 (class inferior) <environment>: Change type from 'struct
3996 gdb_environ' to 'gdb_environ'.
3997 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
3998 methods from 'gdb_environ' class.
3999 * solib.c (solib_find_1): Likewise
4000 * unittests/environ-selftests.c: New file.
4001
75c554cf
YQ
40022017-06-20 Yao Qi <yao.qi@linaro.org>
4003
4004 * features/i386/i386-linux.xml: Exchange the order of including
4005 32bit-linux.xml and 32bit-sse.xml.
4006 * features/i386/i386-linux.c: Regenerated.
4007
72ddacb7
YQ
40082017-06-20 Yao Qi <yao.qi@linaro.org>
4009
4010 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
4011 Delete copy ctor and assignment operator.
4012 (tdesc_type): Likewise.
4013 (tdesc_feature): Likewise.
4014 (tdesc_free_reg): Remove.
4015 (tdesc_create_reg): Use new.
4016 (tdesc_free_type): Remove.
4017 (tdesc_create_vector): Use new.
4018 (tdesc_create_union): Likewise.
4019 (tdesc_create_flags): Likewise.
4020 (tdesc_create_enum): Likewise.
4021 (tdesc_free_feature): Delete.
4022 (free_target_description): Use delete.
4023
325c9fd4
JB
40242017-06-19 John Baldwin <jhb@FreeBSD.org>
4025
4026 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
4027 registers.
4028
16b7a719
PA
40292017-06-19 Pedro Alves <palves@redhat.com>
4030
4031 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
4032 after gdb::unlinker.
4033
1c8e01c9
SDJ
40342017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
4035
4036 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
4037 gdb_environ to access an environment variable.
4038
ffce45d2
TP
40392017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
4040
4041 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
4042 gdb_byte*.
4043
1d4fbac9
SM
40442017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4045
4046 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
4047
8465943a
SM
40482017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4049
4050 * configure: Re-generate.
4051 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
4052
3e019bdc
SM
40532017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4054
4055 * configure: Re-generate.
4056 * warning.m4: Pass -Werror to compiler when checking for
4057 supported warning flags.
4058
cf0dd6f0
SM
40592017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4060
4061 * Makefile.in (COMPILE.pre): Add "-x c++".
4062
6f98355c
YQ
40632017-06-16 Alan Hayward <alan.hayward@arm.com>
4064 Pedro Alves <palves@redhat.com>
4065 Yao Qi <yao.qi@linaro.org>
4066
4067 * defs.h (RequireLongest): New.
4068 (extract_integer): Declare function template.
4069 (extract_signed_integer): Remove the declaration, but define it
4070 static inline.
4071 (extract_unsigned_integer): Likewise.
4072 (store_integer): Declare function template.
4073 (store_signed_integer): Remove the declaration, but define it
4074 static inline.
4075 (store_unsigned_integer): Likewise.
4076 * findvar.c (extract_integer): New function template.
4077 (extract_signed_integer): Remove.
4078 (extract_unsigned_integer): Remove.
4079 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
4080 instantiations.
4081 (store_integer): New function template.
4082 (store_signed_integer): Remove.
4083 (store_unsigned_integer): Remove.
4084 (store_integer): Explicit instantiations.
4085 * regcache.c (regcache_raw_read_signed): Update.
4086 (regcache::raw_read): New function.
4087 (regcache::raw_read_signed): Remove.
4088 (regcache::raw_read_unsigned): Remove.
4089 (regcache_raw_read_unsigned): Update.
4090 (regcache_raw_write_unsigned): Update.
4091 (regcache::raw_write_signed): Remove.
4092 (regcache::raw_write): New function.
4093 (regcache_cooked_read_signed): Update.
4094 (regcache::raw_write_unsigned): Remove.
4095 (regcache::cooked_read_signed): Remove.
4096 (regcache_cooked_read_unsigned): Update.
4097 (regcache::cooked_read_unsigned): Remove.
4098 (regcache_cooked_write_signed): Update.
4099 (regcache_cooked_write_unsigned): Update.
4100 * regcache.h (regcache) <raw_read_signed>: Remove.
4101 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
4102 <raw_read, raw_write>: New.
4103 <cooked_read_signed, cooked_write_signed>: Remove.
4104 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
4105 <cooked_read, cooked_write>: New.
4106 * sh64-tdep.c (sh64_pseudo_register_read): Update.
4107 (sh64_pseudo_register_write): Update.
4108
a87dc45a
AK
41092017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
4110
4111 * arc-tdep.c (arc_disassembler_options): New variable.
4112 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
4113 of default_print_insn.
4114 (arc_delayed_print_insn): Set info->section when needed,
4115 use default_print_insn to retrieve a disassembler.
4116
45159d6a
SDJ
41172017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
4118
4119 PR gdb/21574
4120 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
4121 to mention $SHELL and startup-with-shell.
4122
b46c4cf0
MF
41232017-06-14 Max Filippov <jcmvbkbc@gmail.com>
4124
4125 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
4126
6394c606
YQ
41272017-06-14 Yao Qi <yao.qi@linaro.org>
4128
4129 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
4130 default_print_insn instead of print_insn_aarch64.
4131 * arm-tdep.c (gdb_print_insn_arm): Call
4132 default_print_insn instead of print_insn_big_arm
4133 and print_insn_little_arm.
4134 * i386-tdep.c (i386_print_insn): Call default_print_insn
4135 instead of print_insn_i386.
4136 * ia64-tdep.c (ia64_print_insn): Call
4137 default_print_insn instead of print_insn_ia64.
4138 * mips-tdep.c (gdb_print_insn_mips): Call
4139 default_print_insn instead of print_insn_big_mips
4140 and print_insn_little_mips.
4141 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
4142 instead of print_insn_spu.
4143
d5722aa2
PA
41442017-06-14 Pedro Alves <palves@redhat.com>
4145
4146 * ada-lang.c: Include "common/byte-vector.h".
4147 (ada_value_primitive_packed_val): Use gdb::byte_vector.
4148 * charset.c (wchar_iterator::iterate): Resize the vector instead
4149 of reserving it.
4150 * common/byte-vector.h: Include "common/def-vector.h".
4151 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
4152 * cli/cli-dump.c: Include "common/byte-vector.h".
4153 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
4154 * common/byte-vector.h: New file.
4155 * common/def-vector.h: New file.
4156 * common/default-init-alloc.h: New file.
4157 * dwarf2loc.c: Include "common/byte-vector.h".
4158 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
4159 instead of reserving it.
4160 * dwarf2read.c: Include "common/byte-vector.h".
4161 (data_buf::m_vec): Now a gdb::byte_vector.
4162 * gdb_regex.c: Include "common/def-vector.h".
4163 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
4164 * mi/mi-main.c: Include "common/byte-vector.h".
4165 (mi_cmd_data_read_memory): Use gdb::byte_vector.
4166 * printcmd.c: Include "common/byte-vector.h".
4167 (print_scalar_formatted): Use gdb::byte_vector.
4168 * valprint.c: Include "common/byte-vector.h".
4169 (maybe_negate_by_bytes, print_decimal_chars): Use
4170 gdb::byte_vector.
4171
01ec7a27
SM
41722017-06-13 Simon Marchi <simon.marchi@ericsson.com>
4173
4174 * darwin-nat.c: Include "nat/fork-inferior.h".
4175
848d9074
SM
41762017-06-13 Simon Marchi <simon.marchi@ericsson.com>
4177
4178 * configure.nat: Factor out Darwin bits that are not
4179 architecture-specific. Add fork-inferior.o.
4180
3b912944
SM
41812017-06-13 Simon Marchi <simon.marchi@ericsson.com>
4182
4183 * configure.nat: Factor out AIX bits that are not
4184 architecture-specific. Add fork-inferior.o.
4185
55acdf22
AA
41862017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4187
4188 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
4189 (read_pieced_value, write_pieced_value): ...here. Reduce to
4190 wrappers that just call rw_pieced_value.
4191
f65e2044
AA
41922017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4193
4194 * dwarf2loc.c (write_pieced_value): When writing the data for a
4195 memory piece, use write_memory_with_notification instead of
4196 write_memory.
4197
23f945bf
AA
41982017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4199
4200 * valops.c (read_value_memory): Change embedded_offset to
4201 represent a bit offset instead of a byte offset.
4202 * value.h (read_value_memory): Adjust comment.
4203
f236533e
AA
42042017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4205
4206 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
4207 dest_offset_bits and source_offset_bits.
4208 (write_pieced_value): Likewise.
4209
65d84b76
AA
42102017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4211
4212 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
4213 given by DW_OP_bit_piece.
4214 (write_pieced_value): Likewise.
4215
242d31ab
AA
42162017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4217
4218 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
4219 some other preparations to the places where sufficient information
4220 is available.
4221 (write_pieced_value): Likewise.
4222
03c8af18
AA
42232017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4224
4225 * dwarf2loc.c (bits_to_bytes): New function.
4226 (read_pieced_value): Fix offset calculations for register pieces
4227 on big-endian targets.
4228 (write_pieced_value): Likewise.
4229
840989c1
AA
42302017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4231
4232 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
4233 (write_pieced_value): Likewise.
4234
359b19bb
AA
42352017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4236
4237 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
4238 transfer the source value's least significant bits, instead of its
4239 lowest-addressed ones. Rename type_len to max_offset.
4240 (read_pieced_value): Mirror above changes to write_pieced_value as
4241 applicable.
4242
07c9ca3b
AA
42432017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4244
4245 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
4246 truncate full bytes from dest_offset_bits before using it as an
4247 offset into the buffer.
4248
f1cc9874
AA
42492017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4250
4251 * dwarf2loc.c (write_pieced_value): Include transfer size in
4252 byte-wise check.
4253
cdaac320
AA
42542017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4255
4256 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
4257 calculation of this_size.
4258
af547a96
AA
42592017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4260
4261 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
4262 when targeting a bit-field.
4263 (write_pieced_value): Likewise.
4264
ddd7882a
AA
42652017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4266
4267 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
4268 (allocate_piece_closure): Drop addr_size parameter.
4269 (dwarf2_evaluate_loc_desc_full): Adjust call to
4270 allocate_piece_closure.
4271
e9352324
AA
42722017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4273
4274 PR gdb/21226
4275 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
4276 the LSB end, independent of endianness.
4277
d5d1163e
AA
42782017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4279
4280 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
4281 size capping.
4282
032bb6ea
YQ
42832017-06-13 Yao Qi <yao.qi@linaro.org>
4284
4285 * mips-linux-nat.c: Move include features/mips*-linux.c to
4286 mips-linux-tdep.c.
4287 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
4288 to mips-linux-tdep.c.
4289 * mips-linux-tdep.c: Include features/mips*-linux.c
4290 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
4291 functions.
4292 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
4293 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
4294 (tdesc_mips64_dsp_linux): Declare.
4295
f12f6bad
TT
42962017-06-12 Tom Tromey <tom@tromey.com>
4297
4298 * valprint.h (val_print_type_code_int): Remove.
4299 * valprint.c (generic_val_print_int): Always call
4300 val_print_scalar_formatted.
4301 (val_print_type_code_int): Remove.
4302 * printcmd.c (print_scalar_formatted): Handle options->format==0.
4303 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
4304 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
4305 * ada-valprint.c (ada_val_print_num): Use
4306 val_print_scalar_formatted.
4307
d9109c80
TT
43082017-06-12 Tom Tromey <tom@tromey.com>
4309
4310 * printcmd.c (print_scalar_formatted): Unify the two switches.
4311 Don't convert scalars to LONGEST.
4312
4ac0cb1c
TT
43132017-06-12 Tom Tromey <tom@tromey.com>
4314
4315 PR exp/16225:
4316 * valprint.h (print_decimal_chars): Update.
4317 * valprint.c (maybe_negate_by_bytes): New function.
4318 (print_decimal_chars): Add "is_signed" argument.
4319 * printcmd.c (print_scalar_formatted): Update.
4320
30a25466
TT
43212017-06-12 Tom Tromey <tom@tromey.com>
4322
4323 PR exp/16225:
4324 * valprint.h (print_binary_chars, print_hex_chars): Update.
4325 * valprint.c (val_print_type_code_int): Update.
4326 (print_binary_chars): Add "zero_pad" argument.
4327 (emit_octal_digit): New function.
4328 (print_octal_chars): Don't zero-pad.
4329 (print_decimal_chars): Likewise.
4330 (print_hex_chars): Add "zero_pad" argument.
4331 * sh64-tdep.c (sh64_do_fp_register): Update.
4332 * regcache.c (regcache::dump): Update.
4333 * printcmd.c (print_scalar_formatted): Update.
4334 * infcmd.c (default_print_one_register_info): Update.
4335
b3464d03
PA
43362017-06-12 Pedro Alves <palves@redhat.com>
4337 Alan Hayward <alan.hayward@arm.com>
4338
4339 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
4340 (mips_eabi_push_dummy_call): Rename local 'regsize' to
4341 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
4342 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
4343 Assert that abi_regsize bytes fit in 'ref_valbuf'.
4344
4b76cda9
PA
43452017-06-12 Pedro Alves <palves@redhat.com>
4346
4347 * dwarf2read.c (mapped_symtab::data): Now a vector of
4348 symtab_index_entry instead of vector of
4349 std::unique_ptr<symtab_index_entry>. All users adjusted to check
4350 whether an element's name is NULL instead of checking whether the
4351 element itself is NULL.
4352 (find_slot): Change return type. Adjust.
4353 (hash_expand, , add_index_entry, uniquify_cu_indices)
4354 (write_hash_table): Adjust.
4355
e8f8bcb3
PA
43562017-06-12 Pedro Alves <palves@redhat.com>
4357
4358 * dwarf2read.c (recursively_count_psymbols): New function.
4359 (write_psymtabs_to_index): Call it to compute number of psyms and
4360 pass estimate size of psyms_seen to unordered_set's ctor.
4361
70a1152b
PA
43622017-06-12 Pedro Alves <palves@redhat.com>
4363
4364 * dwarf2read.c (write_hash_table): Check if key already exists
4365 before emplacing.
4366
c2f134ac
PA
43672017-06-12 Pedro Alves <palves@redhat.com>
4368
4369 * dwarf2read.c (data_buf::append_space): Rename to...
4370 (data_buf::grow): ... this, and make private. Adjust all callers.
4371 (data_buf::append_uint): New method.
4372 (add_address_entry, write_one_signatured_type)
4373 (write_psymtabs_to_index): Use it.
4374
a81e6d4d
PA
43752017-06-12 Pedro Alves <palves@redhat.com>
4376
4377 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
4378 (file_write (FILE *, const std::vector<Elem>&)): Delete.
4379 (data_buf::file_write): Call ::fwrite directly.
4380
6fd931f2
PA
43812017-06-12 Pedro Alves <palves@redhat.com>
4382
4383 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
4384 std::vector::erase.
4385
bc8f2430
JK
43862017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
4387
4388 Code cleanup: C++ify .gdb_index producer.
4389 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
4390 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
4391 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
4392 (create_strtab, add_string): Remove.
4393 (file_write, data_buf): New.
4394 (struct symtab_index_entry): Use std::vector for cu_indices.
4395 (struct mapped_symtab): Use std::vector for data.
4396 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
4397 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
4398 Remove.
4399 (find_slot): Change return type. Update it to the new data structures.
4400 (hash_expand, add_index_entry): Update it to the new data structures.
4401 (offset_type_compare): Remove.
4402 (uniquify_cu_indices): Update it to the new data structures.
4403 (c_str_view, c_str_view_hasher, vector_hasher): New.
4404 (add_indices_to_cpool): Remove.
4405 (write_hash_table): Update it to the new data structures.
4406 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
4407 (eq_psymtab_cu_index): Remove.
4408 (psym_index_map): New typedef.
4409 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
4410 reference and std::unordered_map for cu_index_htab.
4411 (add_address_entry, add_address_entry_worker, write_address_map)
4412 (write_psymbols): Update it to the new data structures.
4413 (write_obstack): Remove.
4414 (struct signatured_type_index_data): Change types_list to a data_buf
4415 reference and psyms_seen to a std::unordered_set reference.
4416 (write_one_signatured_type, recursively_write_psymbols)
4417 (write_psymtabs_to_index): Update it to the new data structures.
4418
c4dcb155
SM
44192017-06-11 Simon Marchi <simon.marchi@ericsson.com>
4420
4421 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
4422 separate-debug-file commands.
4423 * symfile.h (separate_debug_file_debug): New global.
4424 * symfile.c (separate_debug_file_debug): New global.
4425 (separate_debug_file_exists, find_separate_debug_file): Add
4426 debug output.
4427 (_initialize_symfile): Add "set debug separate-debug-file"
4428 command.
4429 * build-id.c (build_id_to_debug_bfd,
4430 find_separate_debug_file_by_buildid): Add debug output.
4431
6d45d4b4
SM
44322017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
4433
4434 * gdbarch.sh (displaced_step_free_closure): Remove.
4435 * gdbarch.h, gdbarch.c: Re-generate.
4436 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
4437 displaced_step_free_closure.
4438 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
4439 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
4440 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
4441 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
4442 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
4443 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
4444 * arch-utils.h (simple_displaced_step_free_closure): Remove.
4445 * arch-utils.c (simple_displaced_step_free_closure): Remove.
4446 * infrun.c (displaced_step_clear): Call xfree instead of
4447 gdbarch_displaced_step_free_closure.
4448
2f91880f
SDJ
44492017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
4450
4451 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
4452 NULL".
4453
b8b6e72f
AH
44542017-06-08 Alan Hayward <alan.hayward@arm.com>
4455
4456 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
4457 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
4458 (mn10300_push_dummy_call): Likewise.
4459
5369082e
AH
44602017-06-08 Alan Hayward <alan.hayward@arm.com>
4461
4462 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
4463
ff4ca5ac
AH
44642017-06-08 Alan Hayward <alan.hayward@arm.com>
4465
4466 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
4467
aefd8b33
SDJ
44682017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4469
4470 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
4471 able to start inferiors using a shell.
4472 (New remote packets): Announce new packet "QStartupWithShell".
4473 * remote.c: Add PACKET_QStartupWithShell.
4474 (extended_remote_create_inferior): Handle new
4475 PACKET_QStartupWithShell.
4476 (remote_protocol_features) <QStartupWithShell>: New entry for
4477 PACKET_QStartupWithShell.
4478 (_initialize_remote): Call "add_packet_config_cmd" for
4479 QStartupShell.
4480
2090129c
SDJ
44812017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4482 Pedro Alves <palves@redhat.com>
4483
4484 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
4485 and "nat/fork-inferior.h".
4486 * common/common-inferior.h: New file, with contents from
4487 "gdb/inferior.h".
4488 * commom/common-utils.c: Include "common-utils.h".
4489 (stringify_argv): New function.
4490 * common/common-utils.h (stringify_argv): New prototype.
4491 * configure.nat: Add "fork-inferior.o" as a dependency for
4492 "*linux*", "fbsd*" and "nbsd*" hosts.
4493 * corefile.c (get_exec_file): Update comment.
4494 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
4495 instead of "startup_inferior".
4496 (darwin_create_inferior): Call "add_thread_silent" after
4497 "fork_inferior".
4498 * fork-child.c: Cleanup unnecessary includes.
4499 (SHELL_FILE): Move to "common/common-fork-child.c".
4500 (environ): Likewise.
4501 (exec_wrapper): Initialize.
4502 (get_exec_wrapper): New function.
4503 (breakup_args): Move to "common/common-fork-child.c"; rename to
4504 "breakup_args_for_exec".
4505 (escape_bang_in_quoted_argument): Move to
4506 "common/common-fork-child.c".
4507 (saved_ui): New variable.
4508 (prefork_hook): New function.
4509 (postfork_hook): Likewise.
4510 (postfork_child_hook): Likewise.
4511 (gdb_startup_inferior): Likewise.
4512 (fork_inferior): Move to "common/common-fork-child.c". Update
4513 function to support gdbserver.
4514 (startup_inferior): Likewise.
4515 * gdbcore.h (get_exec_file): Remove declaration.
4516 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
4517 instead of "startup_inferior". Call "add_thread_silent" after
4518 "fork_inferior".
4519 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
4520 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
4521 instead of "startup_inferior". Call "add_thread_silent" after
4522 "fork_inferior".
4523 * inferior.h: Include "common-inferior.h".
4524 (trace_start_error): Move to "common/common-utils.h".
4525 (trace_start_error_with_name): Likewise.
4526 (fork_inferior): Move prototype to "nat/fork-inferior.h".
4527 (startup_inferior): Likewise.
4528 (gdb_startup_inferior): New prototype.
4529 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
4530 * nat/fork-inferior.h: New file.
4531 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
4532 instead of "startup_inferior". Call "add_thread_silent" after
4533 "fork_inferior".
4534 * target.h (target_terminal_init): Move prototype to
4535 "target/target.h".
4536 (target_terminal_inferior): Likewise.
4537 (target_terminal_ours): Likewise.
4538 * target/target.h (target_terminal_init): New prototype, moved
4539 from "target.h".
4540 (target_terminal_inferior): Likewise.
4541 (target_terminal_ours): Likewise.
4542 * utils.c (gdb_flush_out_err): New function.
4543
043a4934
SDJ
45442017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4545
4546 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
4547 * common/common-gdbthread.h: New file, with parts from
4548 "gdb/gdbthread.h".
4549 * gdbthread.h: Include "common-gdbthread.h".
4550 (switch_to_thread): Moved to "common/common-gdbthread.h".
4551
15652511
SDJ
45522017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4553
4554 * Makefile.in (SFILES): Add "common/job-control.c".
4555 (HFILES_NO_SRCDIR): Add "common/job-control.h".
4556 (COMMON_OBS): Add "job-control.o".
4557 * common/job-control.c: New file, with contents from
4558 "gdb/inflow.c".
4559 * common/job-control.h: New file, with contents from "terminal.h".
4560 * fork-child.c: Include "job-control.h".
4561 * inflow.c: Include "job-control.h".
4562 (gdb_setpgid): Move to "common/common-inflow.c".
4563 (_initialize_inflow): Move setting of "job_control" to
4564 "handle_job_control".
4565 * terminal.h (job_control): Moved to "common/common-terminal.h".
4566 (gdb_setpgid): Likewise.
4567 * top.c: Include "job_control.h".
4568 * utils.c: Likewise.
4569 (job_control): Moved to "job-control.c".
4570
2d7cc5c7
PA
45712017-06-07 Pedro Alves <palves@redhat.com>
4572
4573 * Makefile.in (SFILES): Add gdb_regex.c.
4574 (COMMON_OBS): Add gdb_regex.o.
4575 * ada-lang.c (ada_add_standard_exceptions)
4576 (ada_add_exceptions_from_frame, name_matches_regex)
4577 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
4578 parameter type to compiled_regex. Adjust.
4579 (ada_exceptions_list): Use compiled_regex.
4580 * break-catch-throw.c (exception_catchpoint::pattern): Now a
4581 std::unique_ptr<compiled_regex>.
4582 (exception_catchpoint::~exception_catchpoint): Remove regfree
4583 call.
4584 (check_status_exception_catchpoint): Adjust to use compiled_regex.
4585 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
4586 * breakpoint.c (solib_catchpoint::compiled): Now a
4587 std::unique_ptr<compiled_regex>.
4588 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
4589 (check_status_catch_solib): Adjust to use compiled_regex.
4590 (add_solib_catchpoint): Adjust to use compiled_regex.
4591 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
4592 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
4593 compiled_regex reference. Adjust to use it.
4594 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
4595 declaration. Include "gdb_regex.h".
4596 (apropos_cmd): Change regex parameter to compiled_regex reference.
4597 * gdb_regex.c: New file.
4598 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
4599 declarations.
4600 (class compiled_regex): New.
4601 * linux-tdep.c: Include "common/gdb_optional.h".
4602 (struct mapping_regexes): New, factored out from
4603 mapping_is_anonymous_p, and adjusted to use compiled_regex.
4604 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
4605 gdb::optional and remove cleanups. Adjust to compiled_regex.
4606 * probe.c: Include "common/gdb_optional.h".
4607 (collect_probes): Use compiled_regex and gdb::optional and remove
4608 cleanups.
4609 * skip.c: Include "common/gdb_optional.h".
4610 (skiplist_entry::compiled_function_regexp): Now a
4611 gdb::optional<compiled_regex>.
4612 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
4613 (free_skiplist_entry): Remove regfree call.
4614 (compile_skip_regexp, skip_rfunction_p): Adjust to use
4615 compiled_regex and gdb::optional.
4616 * symtab.c: Include "common/gdb_optional.h".
4617 (search_symbols): Use compiled_regex and gdb::optional.
4618 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
4619 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
4620 to gdb_regex.c.
4621
50d6adef
AH
46222017-06-07 Alan Hayward <alan.hayward@arm.com>
4623
4624 * regcache.c (regcache::save): Avoid buffer use.
4625 (regcache::dump): Likewise.
4626
4a8a33c8
AH
46272017-06-07 Alan Hayward <alan.hayward@arm.com>
4628
4629 * sh-tdep.c (sh_pseudo_register_read): Remove
4630 MAX_REGISTER_SIZE.
4631 (sh_pseudo_register_write): Likewise.
4632 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
4633 (sh64_pseudo_register_write): Likewise
4634
d1be909e
AH
46352017-06-07 Alan Hayward <alan.hayward@arm.com>
4636
4637 * aarch64-tdep.c (aarch64_store_return_value): Use
4638 V_REGISTER_SIZE.
4639 (aarch64_pseudo_read_value): Likewise.
4640 (aarch64_pseudo_write): Likewise.
4641
f4a65042
YQ
46422017-06-06 Yao Qi <yao.qi@linaro.org>
4643
4644 * regformats/regdef.h (set_register_cache): Remove the
4645 declaration.
4646
9f7fb0aa
AH
46472017-06-06 Alan Hayward <alan.hayward@arm.com>
4648
4649 * frame.c (frame_unwind_register_signed): Use
4650 frame_unwind_register_value.
4651
e1e01040
PA
46522017-06-06 Pedro Alves <palves@redhat.com>
4653
4654 PR breakpoints/21553
4655 * breakpoint.c (create_breakpoints_sal_default)
4656 (init_breakpoint_sal, create_breakpoint_sal): Use
4657 gdb::unique_xmalloc_ptr for string parameters.
4658 (create_breakpoint): Constify 'extra_string' and 'cond_string'
4659 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
4660 (base_breakpoint_create_breakpoints_sal)
4661 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
4662 (strace_marker_create_breakpoints_sal)
4663 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
4664 string parameters.
4665 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
4666 gdb::unique_xmalloc_ptr for string parameters.
4667 (create_breakpoint): Constify 'extra_string' and 'cond_string'
4668 parameters.
4669
fbe654c8
AH
46702017-06-06 Alan Hayward <alan.hayward@arm.com>
4671
4672 * alpha-tdep.c (alpha_register_to_value): Use
4673 get_frame_register_value.
4674 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
4675
ae0d01d6
AH
46762017-06-06 Alan Hayward <alan.hayward@arm.com>
4677
4678 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
4679 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
4680 (ia64_value_to_register): Likewise.
4681 (ia64_extract_return_value): Likewise.
4682 (ia64_store_return_value): Likewise.
4683 (ia64_push_dummy_call): Likewise.
4684
49cf576c
JB
46852017-06-04 Joel Brobecker <brobecker@adacore.com>
4686
4687 GDB 8.0 released.
4688
26b6a6ab
SM
46892017-06-03 Simon Marchi <simon.marchi@ericsson.com>
4690
4691 * x86-linux-nat.c (struct arch_lwp_info): Remove.
4692
22827c51
SM
46932017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
4694
4695 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
4696 parameter.
4697 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
4698
0e05cf3a
SM
46992017-06-02 Simon Marchi <simon.marchi@ericsson.com>
4700
4701 * event-loop.c (poll_timers): Unallocate timer using delete
4702 instead of xfree.
4703
c1fc2657
SM
47042017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
4705
4706 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
4707 (struct breakpoint) <~breakpoint>: New.
4708 (struct watchpoint): Inherit from breakpoint.
4709 <~watchpoint>: New.
4710 <base>: Remove.
4711 (struct tracepoint): Inherit from breakpoint.
4712 <base>: Remove.
4713 * breakpoint.c (longjmp_breakpoint_ops): Remove.
4714 (struct longjmp_breakpoint): Inherit from breakpoint.
4715 <~longjmp_breakpoint>: New.
4716 <base>: Remove.
4717 (new_breakpoint_from_type): Remove casts.
4718 (watchpoint_in_thread_scope): Remove reference to base field.
4719 (watchpoint_del_at_next_stop): Likewise.
4720 (update_watchpoint): Likewise.
4721 (watchpoint_check): Likewise.
4722 (bpstat_check_watchpoint): Likewise.
4723 (set_longjmp_breakpoint): Likewise.
4724 (struct fork_catchpoint): Inherit from breakpoint.
4725 <base>: Remove.
4726 (struct solib_catchpoint): Inherit from breakpoint.
4727 <~solib_catchpoint>: New.
4728 <base>: Remove.
4729 (dtor_catch_solib): Change to ...
4730 (solib_catchpoint::~solib_catchpoint): ... this.
4731 (breakpoint_hit_catch_solib): Remove reference to base field.
4732 (add_solib_catchpoint): Likewise.
4733 (create_fork_vfork_event_catchpoint): Likewise.
4734 (struct exec_catchpoint): Inherit from breakpoint.
4735 <~exec_catchpoint>: New.
4736 <base>: Remove.
4737 (dtor_catch_exec): Change to ...
4738 (exec_catchpoint::~exec_catchpoint): ... this.
4739 (dtor_watchpoint): Change to ...
4740 (watchpoint::~watchpoint): ... this.
4741 (watch_command_1): Remove reference to base field.
4742 (catch_exec_command_1): Likewise.
4743 (base_breakpoint_dtor): Change to ...
4744 (breakpoint::~breakpoint): ... this.
4745 (base_breakpoint_ops): Remove dtor field value.
4746 (longjmp_bkpt_dtor): Change to ...
4747 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
4748 (strace_marker_create_breakpoints_sal): Remove reference to base
4749 field.
4750 (delete_breakpoint): Don't manually call breakpoint destructor.
4751 (create_tracepoint_from_upload): Remove reference to base field.
4752 (trace_pass_set_count): Likewise.
4753 (initialize_breakpoint_ops): Don't initialize
4754 momentary_breakpoint_ops, don't set dtors.
4755 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
4756 <~ada_catchpoint>: New.
4757 <base>: Remove.
4758 (create_excep_cond_exprs): Remove reference to base field.
4759 (dtor_exception): Change to ...
4760 (ada_catchpoint::~ada_catchpoint): ... this.
4761 (dtor_catch_exception): Remove.
4762 (dtor_catch_exception_unhandled): Remove.
4763 (dtor_catch_assert): Remove.
4764 (create_ada_exception_catchpoint): Remove reference to base
4765 field.
4766 (initialize_ada_catchpoint_ops): Don't set dtors.
4767 * break-catch-sig.c (struct signal_catchpoint): Inherit from
4768 breakpoint.
4769 <~signal_catchpoint>: New.
4770 <base>: Remove.
4771 (signal_catchpoint_dtor): Change to ...
4772 (signal_catchpoint::~signal_catchpoint): ... this.
4773 (create_signal_catchpoint): Remove reference to base field.
4774 (initialize_signal_catchpoint_ops): Don't set dtor.
4775 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
4776 from breakpoint.
4777 <~syscall_catchpoint>: New.
4778 <base>: Remove.
4779 (dtor_catch_syscall): Change to ...
4780 (syscall_catchpoint::~syscall_catchpoint): ... this.
4781 (create_syscall_event_catchpoint): Remove reference to base
4782 field.
4783 (initialize_syscall_catchpoint_ops): Don't set dtor.
4784 * break-catch-throw.c (struct exception_catchpoint): Inherit
4785 from breakpoint.
4786 <~exception_catchpoint>: New.
4787 <base>: Remove.
4788 (dtor_exception_catchpoint): Change to ...
4789 (exception_catchpoint::~exception_catchpoint): ... this.
4790 (handle_gnu_v3_exceptions): Remove reference to base field.
4791 (initialize_throw_catchpoint_ops): Don't set dtor.
4792 * ctf.c (ctf_get_traceframe_address): Remove reference to base
4793 field.
4794 * remote.c (remote_get_tracepoint_status): Likewise.
4795 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
4796 * tracefile.c (tracefile_fetch_registers): Likewise.
4797 * tracepoint.c (actions_command): Likewise.
4798 (validate_actionline): Likewise.
4799 (tfind_1): Likewise.
4800 (get_traceframe_location): Likewise.
4801 (find_matching_tracepoint_location): Likewise.
4802 (parse_tracepoint_status): Likewise.
4803 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
4804
3b0871f4
SM
48052017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
4806
4807 * breakpoint.c (struct longjmp_breakpoint): New struct.
4808 (is_tracepoint_type): Change return type to bool.
4809 (is_longjmp_type): New function.
4810 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
4811 (set_raw_breakpoint_without_location): Use
4812 new_breakpoint_from_type.
4813 (set_raw_breakpoint): Likewise.
4814
a5e364af
SM
48152017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
4816
4817 * breakpoint.c (new_breakpoint_from_type): New function.
4818 (create_breakpoint_sal): Use new_breakpoint_from_type and
4819 unique_ptr.
4820 (create_breakpoint): Likewise.
4821
ae3b3f34
SM
48222017-05-31 Simon Marchi <simon.marchi@ericsson.com>
4823
4824 * memattr.c (mem_info_command): Rename to ...
4825 (info_mem_command): ... this.
4826 (mem_enable_command): Rename to ...
4827 (enable_mem_command): ... this.
4828 (mem_disable_command): Rename to ...
4829 (disable_mem_command): ... this.
4830 (mem_delete_command): Rename to ...
4831 (delete_mem_command): ... this.
4832 (_initialize_mem): Adjust function names.
4833
13ace077
MM
48342017-05-31 Markus Metzger <markus.t.metzger@intel.com>
4835
4836 * btrace.c (handle_pt_insn_events): New.
4837 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
4838 STATUS. Split into this and ...
4839 (handle_pt_insn_event_flags): ... this.
4840
c56ccc05
MM
48412017-05-31 Markus Metzger <markus.t.metzger@intel.com>
4842
4843 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
4844 and struct pt_insn.resynced.
4845 * configure: Regenerated.
4846 * config.in: Regenerated.
4847
08c3f6d2
TW
48482017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
4849
4850 * btrace.c (ftrace_find_call_by_number): New function.
4851 (ftrace_new_function): Store objects, not pointers.
4852 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
4853 ftrace_new_gap, ftrace_update_function,
4854 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
4855 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
4856 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
4857 btrace_ends_with_single_insn, btrace_call_get): Account for
4858 btrace_thread_info::functions now storing objects.
4859 * btrace.h (struct btrace_thread_info): Add constructor.
4860 (struct btrace_thread_info) <functions>: Make std::vector.
4861 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
4862 Initialize with default values.
4863 * record-btrace.c (record_btrace_frame_sniffer): Account for
4864 btrace_thread_info::functions now storing objects.
4865
8ffd39f2
TW
48662017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
4867
4868 * btrace.c: Remove typedef bfun_s.
4869 (ftrace_new_gap): Directly add gaps to the list of gaps.
4870 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
4871 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
4872 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
4873 instead of gdb VEC.
4874
4aeb0dfc
TW
48752017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
4876
4877 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
4878 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
4879 with btrace_thread_info::next_segment and
4880 btrace_thread_info::prev_segment.
4881 * btrace.h: Remove struct btrace_func_link.
4882 (struct btrace_function): Replace pair of function segment pointers
4883 with pair of indices.
4884 * python/py-record-btrace.c (btpy_call_prev_sibling,
4885 btpy_call_next_sibling): Replace references to
4886 btrace_thread_info::segment with btrace_thread_info::next_segment and
4887 btrace_thread_info::prev_segment.
4888 * record-btrace.c (record_btrace_frame_this_id): Use
4889 btrace_find_call_by_number.
4890
eb8f2b9c
TW
48912017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
4892
4893 * btrace.c (ftrace_new_function, ftrace_fixup_level,
4894 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
4895 btrace_insn_next, btrace_insn_prev): Remove references to
4896 btrace_thread_info::flow.
4897 * btrace.h (struct btrace_function): Remove FLOW.
4898
42bfe59e
TW
48992017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
4900
4901 * btrace.c (ftrace_find_call_by_number): New function.
4902 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
4903 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
4904 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
4905 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
4906 index.
4907 * btrace.h (struct btrace_function): Turn UP into an index.
4908 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
4909 as an index.
4910 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
4911 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
4912 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
4913
b54b03bd
TW
49142017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
4915
4916 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
4917 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
4918 ftrace_update_function, ftrace_compute_global_level_offset,
4919 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
4920 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
4921 btrace_insn_end, btrace_is_empty): Remove references to
4922 btrace_thread_info::begin and btrace_thread_info::end.
4923 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
4924 (struct btrace_thread_info) <functions>: Adjust comment.
4925 * record-btrace.c (record_btrace_start_replaying): Remove reference to
4926 btrace_thread_info::begin.
4927
8286623c
TW
49282017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
4929
4930 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
4931 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
4932 ftrace_update_function): Remove arguments that implicitly were always
4933 BTINFO->END.
4934 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
4935 Don't pass BTINFO->END.
4936
a0f1b963
TW
49372017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
4938
4939 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
4940 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
4941 btrace_find_insn_by_number): Replace function segment pointer with
4942 index.
4943 (btrace_insn_cmp): Simplify.
4944 * btrace.h: (struct btrace_insn_iterator) Rename index to
4945 insn_index. Replace function segment pointer with index into function
4946 segment vector.
4947 * record-btrace.c (record_btrace_call_history): Replace function
4948 segment pointer use with index.
4949 (record_btrace_frame_sniffer): Retrieve function call segment through
4950 vector.
4951 (record_btrace_set_replay): Remove defunc't safety check.
4952
f158f208
TW
49532017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
4954
4955 * btrace.c (btrace_ends_with_single_insn): New function.
4956 (btrace_call_get, btrace_call_number, btrace_call_begin,
4957 btrace_call_end, btrace_call_next, btrace_call_prev,
4958 btrace_find_call_by_number): Use index into call segment vector
4959 instead of pointer.
4960 (btrace_call_cmp): Simplify.
4961 * btrace.h (struct btrace_call_iterator): Replace function call segment
4962 pointer with index into vector.
4963 * record-btrace.c (record_btrace_call_history): Use index instead of
4964 pointer.
4965
521103fd
TW
49662017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
4967
4968 * btrace.c (btrace_insn_begin, btrace_insn_end,
4969 btrace_find_insn_by_number): Add btinfo to iterator.
4970 * btrace.h (struct btrace_insn_iterator): Add btinfo.
4971
17b89b34
TW
49722017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
4973
4974 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
4975 and save pointers directly.
4976 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
4977 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
4978 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
4979 changed signature of functions.
4980 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
4981 (btrace_fetch): Remove code that adds btrace_function pointers to
4982 vector of btrace_functions.
4983 (btrace_clear): Simplify freeing vector of btrace_functions.
4984
2b51eddc
TW
49852017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
4986
4987 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
4988 Replace VEC_* with std::vector functions.
4989 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
4990 (struct btrace_thread_info)<functions>: Change type to std::vector.
4991
db6be0d5
SM
49922017-05-30 Simon Marchi <simon.marchi@ericsson.com>
4993
4994 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
4995 "Removed targets and native configurations" up. Merge duplicate
4996 "New commands" sub-sections. Add "New options" sub-sections.
4997
b057297a
AH
49982017-05-26 Alan Hayward <alan.hayward@arm.com>
4999
5000 * defs.h (copy_integer_to_size): New declaration.
5001 * findvar.c (copy_integer_to_size): New function.
5002 (do_cint_test): New selftest function.
5003 (copy_integer_to_size_test): Likewise.
5004 (_initialize_findvar): Likewise.
5005 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
5006 (mips_fbsd_collect_reg): Use raw_collect_integer.
5007 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
5008 (mips64_fill_gregset): Use raw_collect_integer
5009 (mips64_fill_fpregset): Use raw_supply_integer.
5010 * regcache.c (regcache::raw_supply_integer): New function.
5011 (regcache::raw_collect_integer): Likewise.
5012 * regcache.h: (regcache::raw_supply_integer): New declaration.
5013 (regcache::raw_collect_integer): Likewise.
5014
b77b02a5
YQ
50152017-05-24 Yao Qi <yao.qi@linaro.org>
5016
5017 * Makefile.in (SFILES): Add gdbarch-selftests.c.
5018 (COMMON_OBS): Add gdbarch-selftests.o.
5019 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
5020 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
5021 * gdbarch-selftests.c: New file.
5022 * regcache.h (regcache) <~regcache>: Mark it virtual if
5023 GDB_SELF_TEST.
5024 <raw_write>: Likewise.
5025
e521e87e
YQ
50262017-05-24 Yao Qi <yao.qi@linaro.org>
5027
5028 * regcache.c (current_regcache): Change it to
5029 regcache::current_regcache.
5030 (regcache_observer_target_changed): Update.
5031 (regcache_thread_ptid_changed): Make it a regcache static
5032 method.
5033 (regcache_thread_ptid_changed): Update.
5034 (class regcache_access): New.
5035 (current_regcache_test): Update.
5036 (_initialize_regcache): Update.
5037 * regcache.h: Include forward_list.
5038 (regcache): Declare regcache_thread_ptid_changed and declare
5039 registers_changed_ptid as friend.
5040
d8e07dda
YQ
50412017-05-24 Yao Qi <yao.qi@linaro.org>
5042
5043 * i387-tdep.c (i387_register_to_value): Use register_size
5044 instead of TYPE_LENGTH.
5045 * m68k-tdep.c (m68k_register_to_value): Likewise.
5046
8c8f9122
YQ
50472017-05-24 Yao Qi <yao.qi@linaro.org>
5048
5049 * i387-tdep.c (i387_convert_register_p): Return false if type
5050 code isn't TYPE_CODE_FLT.
5051
68fce50f
YQ
50522017-05-24 Yao Qi <yao.qi@linaro.org>
5053
5054 * alpha-tdep.c (alpha_convert_register_p): Return true if type
5055 length is 4.
5056 (alpha_register_to_value): Remove type length check.
5057 (alpha_value_to_register): Likewise.
5058
88954b49
YQ
50592017-05-24 Yao Qi <yao.qi@linaro.org>
5060
5061 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
5062 TYPE_CODE_FLT.
5063
e3ec9b69
YQ
50642017-05-24 Yao Qi <yao.qi@linaro.org>
5065
5066 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
5067 TYPE_CODE_FLT or not.
5068
cdd238da
YQ
50692017-05-24 Yao Qi <yao.qi@linaro.org>
5070
5071 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
5072 * avr-tdep.c (avr_gdbarch_init): Likewise.
5073 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
5074 * cris-tdep.c (cris_gdbarch_init): Likewise.
5075 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
5076 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
5077 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
5078 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
5079 * mep-tdep.c (mep_gdbarch_init): Likewise.
5080 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
5081 * mips-tdep.c (mips_gdbarch_init): Likewise.
5082 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
5083 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
5084 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
5085 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
5086 * v850-tdep.c (v850_gdbarch_init): Likewise.
5087
7a3929c4
YQ
50882017-05-24 Yao Qi <yao.qi@linaro.org>
5089
5090 * selftest-arch.c (tests_with_arch): Call registers_changed
5091 and reinit_frame_cache.
5092 * selftest.c (run_self_tests): Likewise.
5093
f4985dba
YQ
50942017-05-24 Yao Qi <yao.qi@linaro.org>
5095
5096 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
5097 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
5098
ab20fa4a
YQ
50992017-05-24 Yao Qi <yao.qi@linaro.org>
5100
5101 * rl78-tdep.c (rl78_gdbarch_init): Don't call
5102 set_gdbarch_print_insn.
5103
f532ab94
YQ
51042017-05-24 Yao Qi <yao.qi@linaro.org>
5105
5106 * h8300-tdep.c (h8300_gdbarch_init): Don't call
5107 set_gdbarch_print_insn.
5108
39503f82
YQ
51092017-05-24 Yao Qi <yao.qi@linaro.org>
5110
5111 * alpha-tdep.c (alpha_gdbarch_init): Don't call
5112 set_gdbarch_print_insn.
5113 * arc-tdep.c (arc_gdbarch_init): Likewise.
5114 * arch-utils.c: include dis-asm.h.
5115 (default_print_insn): New function.
5116 * arch-utils.h (default_print_insn): Declare.
5117 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
5118 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
5119 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
5120 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
5121 * frv-tdep.c (frv_gdbarch_init): Likewise.
5122 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
5123 * gdbarch.sh (print_insn): Use default_print_insn.
5124 * gdbarch.c: Regenerated.
5125 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
5126 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
5127 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
5128 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
5129 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
5130 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
5131 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
5132 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
5133 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
5134 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
5135 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
5136 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
5137 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
5138 * mt-tdep.c (mt_gdbarch_init): Likewise.
5139 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
5140 * nios2-tdep.c (nios2_print_insn): Remove.
5141 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
5142 * rx-tdep.c (rx_gdbarch_init): Likewise.
5143 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
5144 * score-tdep.c (score_print_insn): Remove.
5145 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
5146 * sh-tdep.c (sh_gdbarch_init): Likewise.
5147 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
5148 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
5149 * tic6x-tdep.c (tic6x_print_insn): Remove.
5150 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
5151 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
5152 * v850-tdep.c (v850_gdbarch_init): Likewise.
5153 * vax-tdep.c (vax_gdbarch_init): Likewise.
5154 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
5155 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
5156
f7241d4f
JB
51572017-05-23 John Baldwin <jhb@FreeBSD.org>
5158
5159 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
5160 (MIPS_FP0_REGNUM): Remove.
5161 (MIPS_FSR_REGNUM): Remove.
5162 (mips_fbsd_supply_fpregs): Use mips_regnum.
5163 (mips_fbsd_supply_gregs): Likewise.
5164 (mips_fbsd_collect_fpregs): Likewise.
5165 (mips_fbsd_collect_gregs): Likewise.
5166
d489d81d
JB
51672017-05-23 John Baldwin <jhb@FreeBSD.org>
5168
5169 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
5170 (getpfpregs_supplies): New function.
5171 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
5172 getfpregs_supplies.
5173 (mips_fbsd_store_inferior_registers): Likewise.
5174
e11b3cdc
PA
51752017-05-22 Pedro Alves <palves@redhat.com>
5176
5177 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
5178 maintainer.
5179
0f068fb5
AH
51802017-05-22 Alan Hayward <alan.hayward@arm.com>
5181
5182 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
5183 (store_register): Likewise.
5184 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
5185 (get_decimal_float_return_value): Likewise.
5186 (do_ppc_sysv_return_value): Likewise.
5187 (ppc64_sysv_abi_push_integer): Likewise.
5188 (ppc64_sysv_abi_push_freg): Likewise.
5189 (ppc64_sysv_abi_return_value_base): Likewise.
5190 (ppc64_sysv_abi_return_value): Likewise.
5191 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
5192 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
5193 * rs6000-nat.c: Likewise.
5194 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
5195 (rs6000_value_to_register): Likewise.
5196 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
5197
e6cf65f2
TT
51982017-05-21 Tom Tromey <tom@tromey.com>
5199
5200 PR rust/21466:
5201 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
5202 arrays as "[T]", not "[T; ]".
5203
43cc5389
TT
52042017-05-19 Tom Tromey <tom@tromey.com>
5205
5206 PR rust/21484:
5207 * rust-lang.c (exp_descriptor_rust): New function.
5208 (rust_language_defn): Use it.
5209 * p-lang.c (pascal_language_defn): Update.
5210 * opencl-lang.c (opencl_language_defn): Update.
5211 * objc-lang.c (objc_language_defn): Update.
5212 * m2-lang.c (m2_language_defn): Update.
5213 * language.h (struct language_defn)
5214 <la_watch_location_expression>: New member.
5215 * language.c (unknown_language_defn, auto_language_defn)
5216 (local_language_defn): Update.
5217 * go-lang.c (go_language_defn): Update.
5218 * f-lang.c (f_language_defn): Update.
5219 * d-lang.c (d_language_defn): Update.
5220 * c-lang.h (c_watch_location_expression): Declare.
5221 * c-lang.c (c_watch_location_expression): New function.
5222 (c_language_defn, cplus_language_defn, asm_language_defn)
5223 (minimal_language_defn): Use it.
5224 * breakpoint.c (watch_command_1): Call
5225 la_watch_location_expression.
5226 * ada-lang.c (ada_language_defn): Update.
5227
7a6e7fcc
RO
52282017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5229
6e7e1744
RO
5230 PR tui/21482
5231 * gdb_curses.h (NOMACROS): Define.
5232 (NCURSES_NOMACROS): Define.
5233
52342017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5235
5236 PR tui/21482
7a6e7fcc
RO
5237 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
5238 arg to char *.
5239 * tui/tui-wingeneral.c (box_win): Likewise.
5240 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
5241 (tui_show_source_line): Likewise.
5242 (tui_show_exec_info_content): Likewise.
5243
1933fd8e
VM
52442017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
5245
5246 * sparc-tdep.c (sparc_structure_return_p)
5247 (sparc_arg_on_registers_p): New functions.
5248 (sparc32_store_arguments): Use them.
5249 * sparc64-tdep.c (sparc64_16_byte_align_p)
5250 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
5251 Handle TYPE_CODE_ARRAY.
5252
21873064
YQ
52532017-05-17 Yao Qi <yao.qi@linaro.org>
5254
5255 * cli/cli-decode.c (add_alias_cmd): New function.
5256 * command.h (add_alias_cmd): Declare.
5257 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
5258 instead call add_alias_cmd.
5259
2b351b19
PA
52602017-05-17 Pedro Alves <palves@redhat.com>
5261
5262 * Makefile.in (nat_extra_makefile_frag): Rename to ...
5263 (nat_makefile_frag): ... this. All references updated.
5264 * configure.ac: Likewise.
5265 * configure.nat: Likewise. Enhance comments.
5266 * configure: Regenerate.
5267
5f2ad7a3
RO
52682017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5269
5270 * procfs.c (procfs_create_inferior): Change prototype to match
5271 definition.
5272
adf3dde5
EZ
52732017-05-13 Eli Zaretskii <eliz@gnu.org>
5274
5275 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
5276 C++ compiler warning.
5277
6830f270
TT
52782017-05-12 Tom Tromey <tom@tromey.com>
5279
5280 PR rust/21483:
5281 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
5282 recurse, just call value_struct_elt directly.
5283
68f2f2e3
TT
52842017-05-12 Tom Tromey <tom@tromey.com>
5285
5286 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
5287 OP_RUST_ARRAY>: Fix.
5288
256afbc2
TT
52892017-05-12 Tom Tromey <tom@tromey.com>
5290
5291 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
5292
94bb8dfe
YQ
52932017-05-09 Yao Qi <yao.qi@linaro.org>
5294
5295 * regcache.c: Include <forward_list>.
5296 (struct regcache_list): Remove.
5297 (current_regcache): Update.
5298 (get_thread_arch_aspace_regcache): Update for std::forward_list.
5299 (regcache_thread_ptid_changed): Likewise.
5300 (registers_changed_ptid): Likewise.
5301 (current_regcache_size): Likewise.
5302
8248946c
YQ
53032017-05-09 Yao Qi <yao.qi@linaro.org>
5304
5305 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
5306 (current_regcache_size): New function.
5307 (current_regcache_test): New function.
5308 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
5309
313c5961
AH
53102017-05-08 Alan Hayward <alan.hayward@arm.com>
5311
5312 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
5313 (print_gp_register_row): Use get_frame_register_value.
5314
27bfc1d1
AH
53152017-05-08 Alan Hayward <alan.hayward@arm.com>
5316
5317 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
5318 (mips_supply_fpregset): Likewise.
5319 (mips64_supply_gregset): Likewise.
5320
146e6c5c
AH
53212017-05-08 Alan Hayward <alan.hayward@arm.com>
5322
5323 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
5324 regcache->raw_supply_zeroed.
5325
e50f25ec
SDJ
53262017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
5327
5328 * configure.nat: Rearrange 'case' statements to match
5329 host before cpu.
5330
21ea5acd
SDJ
53312017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
5332
5333 * Makefile.in: Remove "@host_makefile_frag@". Add variables
5334 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
5335 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
5336 "@nat_extra_makefile_frag@".
5337 (Makefile): Remove dependency on "@frags@".
5338 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
5339 (data-directory/Makefile): Likewise.
5340 * config/aarch64/linux.mh: Deleted; moved contents to
5341 "gdb/configure.nat".
5342 * config/alpha/alpha-linux.mh: Likewise.
5343 * config/alpha/nbsd.mh: Likewise.
5344 * config/arm/linux.mh: Likewise.
5345 * config/arm/nbsdelf.mh: Likewise.
5346 * config/i386/cygwin.mh: Likewise.
5347 * config/i386/cygwin64.mh: Likewise.
5348 * config/i386/darwin.mh: Likewise.
5349 * config/i386/fbsd.mh: Likewise.
5350 * config/i386/fbsd64.mh: Likewise.
5351 * config/i386/go32.mh: Likewise.
5352 * config/i386/i386gnu.mh: Likewise.
5353 * config/i386/i386sol2.mh: Likewise.
5354 * config/i386/linux.mh: Likewise.
5355 * config/i386/linux64.mh: Likewise.
5356 * config/i386/mingw.mh: Likewise.
5357 * config/i386/mingw64.mh: Likewise.
5358 * config/i386/nbsd64.mh: Likewise.
5359 * config/i386/nbsdelf.mh: Likewise.
5360 * config/i386/nto.mh: Likewise.
5361 * config/i386/obsd.mh: Likewise.
5362 * config/i386/obsd64.mh: Likewise.
5363 * config/i386/sol2-64.mh: Likewise.
5364 * config/ia64/linux.mh: Likewise.
5365 * config/m32r/linux.mh: Likewise.
5366 * config/m68k/linux.mh: Likewise.
5367 * config/m68k/nbsdelf.mh: Likewise.
5368 * config/m68k/obsd.mh: Likewise.
5369 * config/m88k/obsd.mh: Likewise.
5370 * config/mips/fbsd.mh: Likewise.
5371 * config/mips/linux.mh: Likewise.
5372 * config/mips/nbsd.mh: Likewise.
5373 * config/mips/obsd64.mh: Likewise.
5374 * config/pa/linux.mh: Likewise.
5375 * config/pa/nbsd.mh: Likewise.
5376 * config/pa/obsd.mh: Likewise.
5377 * config/powerpc/aix.mh: Likewise.
5378 * config/powerpc/fbsd.mh: Likewise.
5379 * config/powerpc/linux.mh: Likewise.
5380 * config/powerpc/nbsd.mh: Likewise.
5381 * config/powerpc/obsd.mh: Likewise.
5382 * config/powerpc/ppc64-linux.mh: Likewise.
5383 * config/powerpc/spu-linux.mh: Likewise.
5384 * config/s390/linux.mh: Likewise.
5385 * config/sh/nbsd.mh: Likewise.
5386 * config/sparc/fbsd.mh: Likewise.
5387 * config/sparc/linux.mh: Likewise.
5388 * config/sparc/linux64.mh: Likewise.
5389 * config/sparc/nbsd64.mh: Likewise.
5390 * config/sparc/nbsdelf.mh: Likewise.
5391 * config/sparc/obsd64.mh: Likewise.
5392 * config/sparc/sol2.mh: Likewise.
5393 * config/tilegx/linux.mh: Likewise.
5394 * config/vax/nbsdelf.mh: Likewise.
5395 * config/vax/obsd.mh: Likewise.
5396 * config/xtensa/linux.mh: Likewise.
5397 * config/i386/i386gnu.mn: New file, with excerpts from
5398 "config/i386/i386gnu.mh".
5399 * configure: Regenerate.
5400 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
5401 *.mh files under "gdb/config".
5402 * configure.nat: New file, with contents from the
5403 "gdb/config/*/*.mh" files.
5404
7ed1acaf
TW
54052017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
5406
5407 * btrace.c (btrace_clear): Free insn vector.
5408
e13cb306
PA
54092017-05-05 Pedro Alves <palves@redhat.com>
5410
5411 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
5412 * configure: Regenerate.
5413
5ed8105e
PA
54142017-05-04 Pedro Alves <palves@redhat.com>
5415
5416 * Makefile.in (SFILES): Add progspace-and-thread.c.
5417 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
5418 (COMMON_OBS): Add progspace-and-thread.o.
5419 * breakpoint.c: Include "progspace-and-thread.h".
5420 (update_inserted_breakpoint_locations)
5421 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
5422 Use scoped_restore_current_pspace_and_thread.
5423 (create_std_terminate_master_breakpoint): Use
5424 scoped_restore_current_program_space.
5425 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
5426 (print_breakpoint_location): Use
5427 scoped_restore_current_program_space.
5428 (bp_loc_is_permanent): Use
5429 scoped_restore_current_pspace_and_thread.
5430 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
5431 (download_tracepoint_locations): Use
5432 scoped_restore_current_pspace_and_thread.
5433 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
5434 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
5435 (enum step_over_calls_kind): Moved from inferior.h.
5436 (class scoped_restore_current_thread): New class.
5437 * gdbthread.h (make_cleanup_restore_current_thread): Delete
5438 declaration.
5439 (scoped_restore_current_thread): New class.
5440 * infcmd.c: Include "common/gdb_optional.h".
5441 (continue_1, proceed_after_attach): Use
5442 scoped_restore_current_thread.
5443 (notice_new_inferior): Use scoped_restore_current_thread.
5444 * inferior.c: Include "progspace-and-thread.h".
5445 (restore_inferior, save_current_inferior): Delete.
5446 (add_inferior_command, clone_inferior_command): Use
5447 scoped_restore_current_pspace_and_thread.
5448 * inferior.h (scoped_restore_current_inferior): New class.
5449 * infrun.c: Include "progspace-and-thread.h" and
5450 "common/gdb_optional.h".
5451 (follow_fork_inferior): Use
5452 scoped_restore_current_pspace_and_thread.
5453 (scoped_restore_exited_inferior): New class.
5454 (handle_vfork_child_exec_or_exit): Use
5455 scoped_restore_exited_inferior,
5456 scoped_restore_current_pspace_and_thread,
5457 scoped_restore_current_thread and scoped_restore.
5458 (fetch_inferior_event): Use scoped_restore_current_thread.
5459 * linespec.c (decode_line_full, decode_line_1): Use
5460 scoped_restore_current_program_space.
5461 * mi/mi-main.c: Include "progspace-and-thread.h".
5462 (exec_continue): Use scoped_restore_current_thread.
5463 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
5464 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
5465 * proc-service.c (ps_pglobal_lookup): Use
5466 scoped_restore_current_program_space.
5467 * progspace-and-thread.c: New file.
5468 * progspace-and-thread.h: New file.
5469 * progspace.c (release_program_space, clone_program_space): Use
5470 scoped_restore_current_program_space.
5471 (restore_program_space, save_current_program_space)
5472 (save_current_space_and_thread): Delete.
5473 (switch_to_program_space_and_thread): Moved to
5474 progspace-and-thread.c.
5475 * progspace.h (save_current_program_space)
5476 (save_current_space_and_thread): Delete declarations.
5477 (scoped_restore_current_program_space): New class.
5478 * remote.c (remote_btrace_maybe_reopen): Use
5479 scoped_restore_current_thread.
5480 * symtab.c: Include "progspace-and-thread.h".
5481 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
5482 * thread.c (print_thread_info_1): Use
5483 scoped_restore_current_thread.
5484 (struct current_thread_cleanup): Delete.
5485 (do_restore_current_thread_cleanup)
5486 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
5487 (scoped_restore_current_thread::~scoped_restore_current_thread):
5488 ... this new dtor.
5489 (make_cleanup_restore_current_thread): Rename/convert to ...
5490 (scoped_restore_current_thread::scoped_restore_current_thread):
5491 ... this new ctor.
5492 (thread_apply_all_command): Use scoped_restore_current_thread.
5493 (thread_apply_command): Use scoped_restore_current_thread.
5494 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
5495 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
5496
f6223dbb
PA
54972017-05-04 Pedro Alves <palves@redhat.com>
5498
5499 * thread.c (make_cleanup_restore_current_thread): Move
5500 find_thread_ptid call before the is_stopped call. Assert that the
5501 thread is found. Replace is_stopped call by checking the thread's
5502 state directly. Remove unnecessary NULL-thread check.
5503
3c3ae77e
PA
55042017-05-04 Pedro Alves <palves@redhat.com>
5505
5506 * corelow.c (thread_section_name): New class.
5507 (get_core_register_section, get_core_siginfo): Use it.
5508
45eba0ab
AA
55092017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
5510
5511 * corelow.c (sniff_core_bfd): Remove extra semicolon.
5512 (get_core_register_section): Remove xfree of NULL pointer.
5513
f81fdd35
AH
55142017-05-03 Alan Hayward <alan.hayward@arm.com>
5515
5516 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
5517 * regcache.c (regcache::raw_supply_zeroed): New function.
5518 * regcache.h (regcache::raw_supply_zeroed): New declaration.
5519
35837774
SM
55202017-05-03 Simon Marchi <simon.marchi@ericsson.com>
5521
5522 * gdbarch.sh: Remove commented out definition of
5523 TARGET_CHAR_BIT.
5524 * gdbarch.h: Re-generate.
5525
c94fee56
SDJ
55262017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
5527
5528 * configure: Regenerate.
5529
d17f7b36
SM
55302017-05-02 Simon Marchi <simon.marchi@ericsson.com>
5531
5532 * solib-target.c (solib_target_relocate_section_addresses):
5533 Remove num_section_bases, num_bases, segment_bases variables.
5534
b560ebd6
SM
55352017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
5536
5537 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
5538
f2f46dfc
SM
55392017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
5540
5541 * solib-target.c: Include <vector>
5542 (struct lm_info_target) <~lm_info_target>: Remove.
5543 <segment_bases, section_bases>: Change type to
5544 std::vector<CORE_ADDR>.
5545 (library_list_start_segment, library_list_start_section,
5546 library_list_end_library,
5547 solib_target_relocate_section_addresses): Adjust.
5548
a0ff9e1a
SM
55492017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
5550
5551 * gdbarch.sh (software_single_step): Change return type to
5552 std::vector<CORE_ADDR>.
5553 * gdbarch.c, gdbarch.h: Re-generate.
5554 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
5555 Adjust.
5556 (arm_deal_with_atomic_sequence_raw): Adjust.
5557 (thumb_get_next_pcs_raw): Adjust.
5558 (arm_get_next_pcs_raw): Adjust.
5559 (arm_get_next_pcs): Adjust.
5560 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
5561 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
5562 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
5563 (alpha_software_single_step): Adjust.
5564 * alpha-tdep.h (alpha_software_single_step): Adjust.
5565 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
5566 * arm-tdep.c (arm_software_single_step): Adjust.
5567 (arm_breakpoint_kind_from_current_state): Adjust.
5568 * arm-tdep.h (arm_software_single_step): Adjust.
5569 * breakpoint.c (insert_single_step_breakpoint): Adjust.
5570 * cris-tdep.c (cris_software_single_step): Adjust.
5571 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
5572 (micromips_deal_with_atomic_sequence): Adjust.
5573 (deal_with_atomic_sequence): Adjust.
5574 (mips_software_single_step): Adjust.
5575 * mips-tdep.h (mips_software_single_step): Adjust.
5576 * moxie-tdep.c (moxie_software_single_step): Adjust.
5577 * nios2-tdep.c (nios2_software_single_step): Adjust.
5578 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
5579 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
5580 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
5581 * s390-linux-tdep.c (s390_software_single_step): Adjust.
5582 * sparc-tdep.c (sparc_software_single_step): Adjust.
5583 * spu-tdep.c (spu_software_single_step): Adjust.
5584 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
5585
ea480a30
SM
55862017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
5587
5588 * gdbarch.sh: Use semi-colon as field separator instead of colon.
5589 * gdbarch.h: Re-generate.
5590
d050f7d7
TW
55912017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
5592
5593 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
5594 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
5595 * python/py-instruction.c, python/py-instruction.h: New file.
5596 * python/py-record.c: Add py-instruction.h include.
5597 (gdbpy_initialize_record): Make gdb.Instruction a super class of
5598 gdb.RecordInstruction.
5599 * python/python-internal.h: Add gdbpy_initialize_instruction
5600 declaration.
5601 * python/python.c (do_start_initialization): Add
5602 gdbpy_initialize_instruction.
5603
14f819c8
TW
56042017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
5605
5606 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
5607 Remove.
5608 (btrace_func_from_recpy_func): New function.
5609 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
5610 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
5611 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
5612 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
5613 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
5614 Also, use new helper functions.
5615 (btpy_list_item): Use new helper functions.
5616 (recpy_bt_function_call_history): Use new type name.
5617 (btpy_call_getset): Remove.
5618 (gdbpy_initialize_btrace): Remove code to initialize
5619 gdb.BtraceFunctionCall.
5620 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
5621 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
5622 recpy_bt_func_prev, recpy_bt_func_next): New export.
5623 * python/py-record.c (recpy_func_type): New static object.
5624 (recpy_func_new, recpy_func_level, recpy_func_symbol,
5625 recpy_func_instructions, recpy_func_up, recpy_func_prev,
5626 recpy_func_next): New function.
5627 (recpy_element_hash, recpy_element_richcompare): Updated comment.
5628 (recpy_func_getset): New static object.
5629 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
5630 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
5631
0ed5da75
TW
56322017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
5633
5634 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
5635 (btpy_object, btpy_insn_type, btpy_new): Remove.
5636 (btpy_list_object): Use gdb.RecordInstruction type instead of
5637 gdb.BtraceInstruction type.
5638 (btrace_insn_from_recpy_insn): New function.
5639 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
5640 btpy_new.
5641 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
5642 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
5643 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
5644 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
5645 instead of btpy_object.
5646 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
5647 btpy_insn_data, btpy_insn_decode): Rename to ...
5648 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
5649 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
5650 recpy_bt_insn_decode): This. Also, use new helper functions.
5651 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
5652 recpy_insn_type.
5653 (btpy_insn_getset): Remove.
5654 (gdbpy_initialize_btrace): Remove code to initialize
5655 gdb.BtraceInstruction. Use recpy_element_object.
5656 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
5657 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
5658 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
5659 * python/py-record.c (recpy_insn_type): New static object.
5660 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
5661 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
5662 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
5663 New function.
5664 (recpy_insn_getset): New static object.
5665 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
5666 * python/py-record.h (recpy_element_object): New typedef.
5667 (recpy_insn_type, recpy_insn_new): New export.
5668
913aeadd
TW
56692017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
5670
5671 * py-record-btrace.c (btpy_insn_new): Removed.
5672 (btpy_insn_or_gap_new): New function.
5673 (btpy_insn_error): Removed.
5674 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
5675 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
5676 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
5677 btpy_insn_or_gap_new instead of btpy_insn_new.
5678 (btpy_insn_getset): Remove btpy_insn_error.
5679 * py-record.c (recpy_gap_type): New static object.
5680 (recpy_gap_object): New typedef.
5681 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
5682 recpy_gap_reason_string): New function.
5683 (recpy_gap_getset): New static object.
5684 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
5685 * py-record.h (recpy_gap_new): New export.
5686
a3be24ad
TW
56872017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
5688
5689 * python/py-record.c (recpy_ptid): Remove.
5690 (recpy_record_getset): Remove recpy_ptid.
5691
ae20e79a
TW
56922017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
5693
5694 * btrace.c (btrace_fetch): Set inferior_ptid.
5695 * python/py-record-btrace.c: Add "py-record.h" include.
5696 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
5697 recpy_bt_end, recpy_bt_instruction_history,
5698 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
5699 in gdb.Record object instead of current ptid.
5700 * python/py-record.c: Include new "py-record.h" file.
5701 (recpy_record_object): Moved to py-record.h.
5702 * python/py-record.h: New file.
5703
8d0050ea
TW
57042017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
5705
5706 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
5707 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
5708 indentation.
5709
3f380b50
JB
57102017-05-01 Joel Brobecker <brobecker@adacore.com>
5711
5712 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
5713 the past maintainers section.
5714
07495424
YQ
57152017-04-28 Yao Qi <yao.qi@linaro.org>
5716
5717 * infcmd.c (get_return_value): Use regcache ctor, and remove
5718 cleanup.
5719
deb1fa3e
YQ
57202017-04-28 Yao Qi <yao.qi@linaro.org>
5721 Pedro Alves <palves@redhat.com>
5722
5723 * regcache.c (regcache::regcache): New tag dispatch ctor.
5724 (do_cooked_read): Moved above.
5725 (regcache_dup): Use the tag dispatch ctor..
5726 * regcache.h (regcache): Declare ctor, delete copy ctor and
5727 assignment operator, remove friend regcache_dup.
5728
b421c83c
YQ
57292017-04-28 Yao Qi <yao.qi@linaro.org>
5730
5731 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
5732 call method save instead of regcache_cpy.
5733 * regcache.h (struct regcache): Make regcache_dup a friend.
5734
ef79d9a3
YQ
57352017-04-28 Yao Qi <yao.qi@linaro.org>
5736
5737 * regcache.c (struct regcache): Move to regcache.h
5738 (regcache::arch): New method.
5739 (regcache_get_ptid): Update.
5740 (get_regcache_arch): Call arch method.
5741 (get_regcache_aspace): Call method aspace.
5742 (register_buffer): Change it to method.
5743 (regcache_save): Change it to regcache::save.
5744 (regcache_restore): Likewise.
5745 (regcache_cpy_no_passthrough): Remove the declaration.
5746 (regcache_cpy): Call methods restore and cpy_no_passthrough.
5747 (regcache_cpy_no_passthrough): Change it to method
5748 cpy_no_passthrough.
5749 (regcache_register_status): Change it to method
5750 get_register_status.
5751 (regcache_invalidate): Change it to method invalidate.
5752 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
5753 (regcache_raw_update): Change it to method raw_update.
5754 (regcache_raw_read): Likewise.
5755 (regcache_raw_read_signed): Likewise.
5756 (regcache_raw_read_unsigned): Likewise.
5757 (regcache_raw_write_signed): Likewise.
5758 (regcache_raw_write_unsigned): Likewise.
5759 (regcache_cooked_read): Likewise.
5760 (regcache_cooked_read_value): Likewise.
5761 (regcache_cooked_read_signed): Likewise.
5762 (regcache_cooked_read_unsigned): Likewise.
5763 (regcache_cooked_write_signed): Likewise.
5764 (regcache_cooked_write_unsigned): Likewise.
5765 (regcache_raw_set_cached_value): Likewise.
5766 (regcache_raw_write): Likewise.
5767 (regcache_cooked_write): Likewise.
5768 (regcache_xfer_part): Likewise.
5769 (regcache_raw_read_part): Likewise.
5770 (regcache_raw_write_part): Likewise.
5771 (regcache_cooked_read_part): Likewise.
5772 (regcache_cooked_write_part): Likewise.
5773 (regcache_raw_supply): Likewise.
5774 (regcache_raw_collect): Likewise.
5775 (regcache_transfer_regset): Likewise.
5776 (regcache_supply_regset): Likewise.
5777 (regcache_collect_regset): Likewise.
5778 (regcache_debug_print_register): Likewise.
5779 (enum regcache_dump_what): Move it to regcache.h.
5780 (regcache_dump): Change it to method dump.
5781 * regcache.h (enum regcache_dump_what): New.
5782 (class regcache): New.
5783 * target.c (target_fetch_registers): Call method
5784 debug_print_register.
5785 (target_store_registers): Likewise.
5786
f8fdb78e
SM
57872017-04-28 Simon Marchi <simon.marchi@ericsson.com>
5788
5789 * windows-nat.c (struct lm_info_windows): Initialize field.
5790 (windows_make_so): Allocate lm_info_windows with new.
5791 (windows_free_so): Free lm_info_windows with delete.
5792
9ccbfd7b
SM
57932017-04-28 Simon Marchi <simon.marchi@ericsson.com>
5794
5795 * solib-darwin.c (struct lm_info_darwin): Initialize field.
5796 (darwin_current_sos): Allocate lm_info_darwin with new, remove
5797 cleanup.
5798 (darwin_free_so): Free lm_info_darwin with delete.
5799
76e75227
SM
58002017-04-28 Simon Marchi <simon.marchi@ericsson.com>
5801
5802 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
5803 <l_addr_p>: Change type to bool.
5804 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
5805 (svr4_free_so): Free lm_info_svr4 with delete.
5806 (svr4_copy_library_list): Replace memcpy with call to copy
5807 constructor.
5808 (library_list_start_library, svr4_default_sos): Allocate
5809 lm_info_svr4 with new.
5810
51046d9e
SM
58112017-04-28 Simon Marchi <simon.marchi@ericsson.com>
5812
5813 * solib-target.c (struct lm_info_target): Add destructor,
5814 initialize fields.
5815 <name>: Change type to std::string.
5816 (library_list_start_library): Allocate lm_info_target with new.
5817 (solib_target_free_library_list): Free lm_info_target with
5818 delete.
5819 (solib_target_current_sos): Adapt to std::string.
5820 (solib_target_free_so): Free lm_info_target with delete.
5821
4023ae76
SM
58222017-04-28 Simon Marchi <simon.marchi@ericsson.com>
5823
5824 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
5825 fields.
5826 (frv_current_sos): Allocate lm_info_frv with new.
5827 (frv_relocate_main_executable): Free lm_info_frv with delete,
5828 allocate with new.
5829 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
5830
af43057b
SM
58312017-04-28 Simon Marchi <simon.marchi@ericsson.com>
5832
5833 * solib-frv.c (struct lm_info_frv): Fix indentation.
5834
b0911207
SM
58352017-04-28 Simon Marchi <simon.marchi@ericsson.com>
5836
5837 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
5838 map field.
5839 (dsbt_current_sos): Allocate lm_info_dsbt with new.
5840 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
5841 and allocate with new.
5842 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
5843
6c401f72
SM
58442017-04-28 Simon Marchi <simon.marchi@ericsson.com>
5845
5846 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
5847 <filename, member_name>: Change type to std::string.
5848 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
5849 (library_list_start_library): Allocate lm_info_aix with new.
5850 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
5851 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
5852 with copy constructor.
5853
d0e449a1
SM
58542017-04-28 Simon Marchi <simon.marchi@ericsson.com>
5855
5856 * solist.h (struct lm_info): Remove.
5857 (struct lm_info_base): New class.
5858 (struct so_list) <lm_info>: Change type to lm_info_base *.
5859 * nto-tdep.c (struct lm_info): Remove.
5860 (lm_addr): Adjust.
5861 * solib-aix.c (struct lm_info): Rename to ...
5862 (struct lm_info_aix): ... this. Extend lm_info_base.
5863 (lm_info_p): Rename to ...
5864 (lm_info_aix_p): ... this, and adjust.
5865 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
5866 solib_aix_parse_libraries, library_list_start_library,
5867 solib_aix_free_library_list, solib_aix_parse_libraries,
5868 solib_aix_get_library_list,
5869 solib_aix_relocate_section_addresses, solib_aix_free_so,
5870 solib_aix_get_section_offsets,
5871 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
5872 Adjust.
5873 (struct solib_aix_inferior_data) <library_list>: Adjust.
5874 * solib-darwin.c (struct lm_info): Rename to ...
5875 (struct lm_info_darwin): ... this. Extend lm_info_base.
5876 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
5877 * solib-dsbt.c (struct lm_info): Rename to ...
5878 (struct lm_info_dsbt): ... this. Extend lm_info_base.
5879 (struct dsbt_info) <main_executable_lm_info): Adjust.
5880 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
5881 dsbt_relocate_section_addresses): Adjust.
5882 * solib-frv.c (struct lm_info): Rename to ...
5883 (struct lm_info_frv): ... this. Extend lm_info_base.
5884 (main_executable_lm_info): Adjust.
5885 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
5886 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
5887 find_canonical_descriptor_in_load_object,
5888 frv_fdpic_find_canonical_descriptor): Adjust.
5889 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
5890 to lm_info_svr4.
5891 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
5892 svr4_clear_so, svr4_copy_library_list,
5893 library_list_start_library, svr4_default_sos, svr4_read_so_list,
5894 svr4_current_sos, svr4_fetch_objfile_link_map,
5895 solist_update_incremental): Adjust.
5896 * solib-svr4.h (struct lm_info_svr4): Move here from
5897 solib-svr4.c.
5898 * solib-target.c (struct lm_info): Rename to ...
5899 (struct lm_info_target): ... this. Extend lm_info_base.
5900 (lm_info_p): Rename to ...
5901 (lm_info_target_p): ... this.
5902 (solib_target_parse_libraries, library_list_start_segment,
5903 library_list_start_section, library_list_start_library,
5904 library_list_end_library, solib_target_free_library_list,
5905 solib_target_current_sos, solib_target_free_so,
5906 solib_target_relocate_section_addresses): Adjust.
5907 * windows-nat.c (struct lm_info): Rename to ...
5908 (struct lm_info_windows): ... this. Extend lm_info_base.
5909 (windows_make_so, handle_load_dll, handle_unload_dll,
5910 windows_xfer_shared_libraries): Adjust.
5911
434a4023
SM
59122017-04-28 Simon Marchi <simon.marchi@ericsson.com>
5913
5914 * solib-darwin.c (struct darwin_so_list): Remove.
5915 (darwin_current_sos): Allocate an so_list object instead of a
5916 darwin_so_list, separately allocate an lm_info object.
5917 (darwin_free_so): Free lm_info.
5918
428544e8
JB
59192017-04-28 John Baldwin <jhb@FreeBSD.org>
5920
5921 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
5922 with fprintf_filtered.
5923
4621115f
YQ
59242017-04-28 Yao Qi <yao.qi@linaro.org>
5925
5926 * regcache.c (regcache::regcache): New function.
5927 (regcache::~regcache): New function.
5928 (regcache_xmalloc_1): Remove.
5929 (regcache_xmalloc): Call new regcache.
5930 (regcache_xfree): Call delete regcache.
5931 (get_thread_arch_aspace_regcache): Call new regcache.
5932
339053c2
YQ
59332017-04-28 Yao Qi <yao.qi@linaro.org>
5934
5935 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
5936 lwp instead of ptid_get_lwp.
5937
7974a605
YQ
59382017-04-28 Yao Qi <yao.qi@linaro.org>
5939
5940 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
5941 lwp_info instead of getting from inferior_ptid.
5942
e15c3eb4
KS
59432017-04-27 Keith Seitz <keiths@redhat.com>
5944
5945 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
5946 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
5947 (CV_CONVERSION_BADNESS): Define.
5948 (rank_one_type): Remove overly restrictive rvalue reference
5949 rank checks.
5950 Add cv-qualifier checks and subranks for type equality.
5951 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
5952 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
5953 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
5954
72bc1d24
SM
59552017-04-27 Simon Marchi <simon.marchi@ericsson.com>
5956
5957 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
5958 count when creating the object.
5959
55bcecda
UW
59602017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
5961 Ulrich Weigand <uweigand@de.ibm.com>
5962
5963 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
5964 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
5965 is used in AIX.
5966 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
5967 (process_xcoff_symbol): Likewise.
5968 (scan_xcoff_symtab): Likewise.
5969
5c99fcf8
AH
59702017-04-26 Alan Hayward <alan.hayward@arm.com>
5971
5972 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
5973 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
5974 (ia64_access_reg): Use get_frame_register_unsigned.
5975 (ia64_access_rse_reg): Likewise.
5976 (ia64_libunwind_frame_prev_register): Likewise.
5977
b41c5a85
JW
59782017-04-26 Jiong Wang <jiong.wang@arm.com>
5979
5980 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
5981 * gdbarch.c: Regenerated.
5982 * gdbarch.h: Regenerated.
5983 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
5984 visibility external.
5985 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
5986 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
5987 (enum cfa_how_kind): Move to ...
5988 (struct dwarf2_frame_state_reg_info): Likewise.
5989 (struct dwarf2_frame_state): Likewise.
5990 * dwarf2-frame.h: ... here.
5991 (dwarf2_frame_state_alloc_regs): New declaration.
5992 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
5993 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
5994
c185f580
AH
59952017-04-26 Alan Hayward <alan.hayward@arm.com>
5996
5997 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
5998 regcache_raw_read_unsigned.
5999 (xtensa_pseudo_register_write): Likewise.
6000
19c45594
AH
60012017-04-26 Alan Hayward <alan.hayward@arm.com>
6002
6003 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
6004 (nds32_pseudo_register_write): Likewise.
6005
4658f12e
YQ
60062017-04-25 Yao Qi <yao.qi@linaro.org>
6007
6008 * regcache.c (struct regcache) <readonly_p>: Change its type
6009 to bool.
6010 (regcache_xmalloc_1): Update parameter type and callers update.
6011
d581dda8
YQ
60122017-04-25 Yao Qi <yao.qi@linaro.org>
6013
6014 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
6015 set_gdbarch_wchar_bit.
6016 * arm-tdep.c (arm_gdbarch_init): Likewise.
6017
debed3db
PA
60182017-04-25 Pedro Alves <palves@redhat.com>
6019
6020 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
6021 (BothAreRelocatable, memcopy, memmove): Don't define.
6022 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
6023 macros.
6024
b0b92aeb
PA
60252017-04-25 Pedro Alves <palves@redhat.com>
6026
6027 * common/common-defs.h: Include "common/poison.h".
6028 * common/function-view.h: (Not, Or, Requires): Move to traits.h
6029 and adjust.
6030 * common/poison.h: New file.
6031 * common/traits.h: Include <type_traits>.
6032 (Not, Or, Requires): New, moved from common/function-view.h.
6033
16c4d54a
PA
60342017-04-25 Pedro Alves <palves@redhat.com>
6035
6036 * breakpoint.h (struct breakpoint): In-class initialize all
6037 fields. Make boolean fields "bool".
6038 * breakpoint.c (init_raw_breakpoint_without_location): Remove
6039 memset call and initializations no longer necessary.
6040
b5c36682
PA
60412017-04-25 Pedro Alves <palves@redhat.com>
6042
6043 * btrace.c (pt_btrace_insn_flags): Change parameter type to
6044 reference.
6045 (pt_btrace_insn): New function.
6046 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
6047
5625a286
PA
60482017-04-25 Pedro Alves <palves@redhat.com>
6049
6050 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
6051 "base" field and inherit from "bp_location" instead. Add
6052 non-default ctor.
6053 (allocate_location_exception): Use new non-default ctor.
6054 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
6055 (init_bp_location): Convert to ...
6056 (bp_location::bp_location): ... this new ctor, and remove memset
6057 call.
6058 (base_breakpoint_allocate_location): Use the new non-default ctor.
6059 * breakpoint.h (bp_location): Now a class. Declare default and
6060 non-default ctors. In-class initialize all members.
6061 (init_bp_location): Remove declaration.
6062
23bcc18f
PA
60632017-04-25 Pedro Alves <palves@redhat.com>
6064
6065 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
6066 assignment operator.
6067
e1ba3053
YQ
60682017-04-24 Yao Qi <yao.qi@linaro.org>
6069
6070 * doublest.c (convert_doublest_to_floatformat): Call
6071 floatformat_totalsize_bytes.
6072
10f489e5
TT
60732017-04-22 Tom Tromey <tom@tromey.com>
6074
6075 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
6076 ui_out_emit_list.
6077 * stack.c (print_frame): Use ui_out_emit_list.
6078 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
6079 ui_out_emit_list.
6080 * mi/mi-main.c (print_one_inferior)
6081 (mi_cmd_data_list_register_names)
6082 (mi_cmd_data_list_register_values, mi_cmd_list_features)
6083 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
6084 ui_out_emit_list.
6085 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
6086 (mi_output_solib_attribs): Use ui_out_emit_list,
6087 ui_out_emit_tuple.
6088 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
6089 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
6090 (mi_cmd_stack_list_args, list_args_or_locals): Use
6091 ui_out_emit_list.
6092 * disasm.c (do_assembly_only): Use ui_out_emit_list.
6093 * breakpoint.c (print_solib_event, output_thread_groups): Use
6094 ui_out_emit_list.
6095
0092b74d
TT
60962017-04-22 Tom Tromey <tom@tromey.com>
6097
6098 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
6099 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
6100 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
6101
a14a62dd
TT
61022017-04-22 Tom Tromey <tom@tromey.com>
6103
6104 * tracepoint.c (tvariables_info_1)
6105 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
6106
46b9c129
TT
61072017-04-22 Tom Tromey <tom@tromey.com>
6108
6109 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
6110 annotate_arg_emitter.
6111 * breakpoint.c (print_mention_watchpoint)
6112 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
6113 * annotate.h (struct annotate_arg_emitter): New.
6114
2e783024
TT
61152017-04-22 Tom Tromey <tom@tromey.com>
6116
6117 * record-btrace.c (record_btrace_insn_history)
6118 (record_btrace_insn_history_range, record_btrace_call_history)
6119 (record_btrace_call_history_range): Use ui_out_emit_tuple.
6120 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
6121 ui_out_emit_tuple.
6122 * stack.c (print_frame_info): Use ui_out_emit_tuple.
6123 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
6124 * skip.c (skip_info): Use ui_out_emit_tuple.
6125 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
6126 * progspace.c (print_program_space): Use ui_out_emit_tuple.
6127 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
6128 * osdata.c (info_osdata): Use ui_out_emit_tuple.
6129 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
6130 ui_out_emit_tuple.
6131 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
6132 (output_register, mi_cmd_data_read_memory)
6133 (mi_cmd_data_read_memory_bytes, mi_load_progress)
6134 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
6135 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
6136 Use ui_out_emit_tuple.
6137 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
6138 ui_out_emit_tuple.
6139 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
6140 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
6141 * linux-thread-db.c (info_auto_load_libthread_db): Use
6142 ui_out_emit_tuple.
6143 * inferior.c (print_inferior): Use ui_out_emit_tuple.
6144 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
6145 * disasm.c (do_mixed_source_and_assembly_deprecated)
6146 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
6147 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
6148 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
6149 * breakpoint.c (print_one_breakpoint_location)
6150 (print_one_breakpoint): Use ui_out_emit_tuple.
6151 * auto-load.c (print_script, info_auto_load_cmd): Use
6152 ui_out_emit_tuple.
6153 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
6154
9be21bb4
SM
61552017-04-21 Simon Marchi <simon.marchi@ericsson.com>
6156
6157 * thread.c (print_thread_info_1): Remove dead code.
6158
0d4c07af
JK
61592017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
6160
6161 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
6162 GDB_SELF_TEST.
6163 * arm-tdep.c (selftests::arm_record_test): Likewise.
6164
4daf993d
YQ
61652017-04-21 Yao Qi <yao.qi@linaro.org>
6166
6167 * regcache.c (regcache_restore): Remove argument 2. Replace
6168 argument 3 with regcache. Get register status from
6169 src->register_status and get register contents from
6170 register_buffer (src, regnum).
6171 (regcache_cpy): Update.
6172
a6c21d4a
PA
61732017-04-19 Pedro Alves <palves@redhat.com>
6174
6175 * gdbthread.h (thread): Add missing closing parenthesis in
6176 comment.
6177
3a3fd0fd
PA
61782017-04-19 Pedro Alves <palves@redhat.com>
6179
6180 * common/refcounted-object.h: New file.
6181 * gdbthread.h: Include "common/refcounted-object.h".
6182 (thread_info): Inherit from refcounted_object and add comments.
6183 (thread_info::incref, thread_info::decref)
6184 (thread_info::m_refcount): Delete.
6185 (thread_info::deletable): Use the refcounted_object::refcount()
6186 method.
6187 * inferior.c (current_inferior_): Add comment.
6188 (set_current_inferior): Increment/decrement refcounts.
6189 (prune_inferiors, remove_inferior_command): Skip inferiors marked
6190 not-deletable instead of comparing with the current inferior.
6191 (initialize_inferiors): Increment the initial inferior's refcount.
6192 * inferior.h (struct inferior): Forward declare.
6193 Include "common/refcounted-object.h".
6194 (current_inferior, set_current_inferior): Move declaration to
6195 before struct inferior's definition, and fix comment.
6196 (inferior): Inherit from refcounted_object. Add comments.
6197 * thread.c (switch_to_thread_no_regs): Reference the thread's
6198 inferior pointer directly instead of doing a ptid lookup.
6199 (switch_to_no_thread): New function.
6200 (switch_to_thread(thread_info *)): New function, factored out
6201 from ...
6202 (switch_to_thread(ptid_t)): ... this.
6203 (restore_current_thread): Delete.
6204 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
6205 fields, and add 'inf' field.
6206 (do_restore_current_thread_cleanup): Check whether old->inf is
6207 alive instead of looking up an inferior by ptid. Use
6208 switch_to_thread and switch_to_no_thread.
6209 (restore_current_thread_cleanup_dtor): Use old->inf directly
6210 instead of lookup up an inferior by id. Decref the inferior.
6211 Don't restore 'removable'.
6212 (make_cleanup_restore_current_thread): Same the inferior pointer
6213 in old, instead of the inferior number. Incref the inferior.
6214 Don't save/clear 'removable'.
6215
9bcb1f16
PA
62162017-04-19 Pedro Alves <palves@redhat.com>
6217
6218 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6219 unittests/scoped_restore-selftests.c.
6220 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
6221 * common/scoped_restore.h (scoped_restore_base): Make "class".
6222 (scoped_restore_base::release): New public method.
6223 (scoped_restore_base::scoped_restore_base): New protected ctor.
6224 (scoped_restore_base::m_saved_var): New protected field.
6225 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
6226 scoped_restore_base base class instead of m_saved_var directly.
6227 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
6228 (scoped_restore_tmpl::scoped_restore_tmpl(const
6229 scoped_restore_tmpl<T>&)): Likewise.
6230 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
6231 method.
6232 (scoped_restore_tmpl::saved_var): New method.
6233 (scoped_restore_tmpl::m_saved_var): Delete.
6234 * inferior.h (inferior::detaching): Now a bool.
6235 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
6236 cleanup.
6237 * unittests/scoped_restore-selftests.c: New file.
6238
26fcd539
PA
62392017-04-19 Pedro Alves <palves@redhat.com>
6240
6241 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
6242 Re-sort in alphabetic order.
6243
fdd243b0
PA
62442017-04-18 Pedro Alves <palves@redhat.com>
6245
6246 * xml-support.c (obstack_xml_printf): Delete.
6247 * xml-support.h (obstack_xml_printf): Delete.
6248
4895cde2
PA
62492017-04-18 Pedro Alves <palves@redhat.com>
6250
6251 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
6252 vdebug, verror, body_text, start_element, end_element, name,
6253 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
6254 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
6255 is_xinclude>: Make private and add m_ prefix.
6256 (gdb_xml_parser::body_text): New method, based on ...
6257 (gdb_xml_body_text): ... this. Adjust.
6258 (gdb_xml_parser::vdebug): New method, based on ...
6259 (gdb_xml_debug): ... this. Adjust.
6260 (gdb_xml_parser::verror): New method, based on ...
6261 (gdb_xml_error): ... this. Adjust.
6262 (gdb_xml_parser::start_element): New method, based on ...
6263 (gdb_xml_start_element): ... this. Adjust.
6264 (gdb_xml_start_element_wrapper): Defer to
6265 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
6266 (gdb_xml_parser::end_element): New method, based on ...
6267 (gdb_xml_end_element_wrapper): ... this. Adjust.
6268 (gdb_xml_parser::~gdb_xml_parser): Adjust.
6269 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
6270 (gdb_xml_parser::use_dtd): New method, based on ...
6271 (gdb_xml_use_dtd): ... this. Adjust.
6272 (gdb_xml_parser::parse): New method, based on ...
6273 (gdb_xml_parse): ... this. Adjust.
6274 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
6275 (xinclude_start_include): Adjust to call the parser's name method.
6276 (xml_xinclude_default, xml_xinclude_start_doctype)
6277 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
6278 method.
6279 (xml_process_xincludes): Adjust to call parser methods.
6280 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
6281 declarations.
6282
bd8a901f
PA
62832017-04-18 Pedro Alves <palves@redhat.com>
6284
6285 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
6286 gdb::optional<std::string>.
6287 * xml-support.c: Include <string>.
6288 (scope_level::scope_level(scope_level &&))
6289 (scope_level::~scope_level): Delete.
6290 (scope_level::body): Now a std::string.
6291 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
6292 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
6293 parameter.
6294 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
6295 (xinclude_parsing_data::output): Now a std::string reference.
6296 (xinclude_start_include): Adjust.
6297 (xml_xinclude_default): Adjust.
6298 (xml_process_xincludes): Add 'output' parameter, and return bool.
6299 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
6300 and return bool.
6301 * xml-tdesc.c: Include <unordered_map> and <string>.
6302 (tdesc_xml_cache): Delete.
6303 (tdesc_xml_cache_s): Delete.
6304 (xml_cache): Now an std::unordered_map.
6305 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
6306 (target_fetch_description_xml): Change return type to
6307 gdb::optional<std::string>, and adjust.
6308 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
6309 (target_fetch_description_xml): Change return type to
6310 gdb::optional<std::string>.
6311
d35d1958
PA
63122017-04-18 Pedro Alves <palves@redhat.com>
6313
6314 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6315 unittests/optional-selftests.c.
6316 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
6317 * unittests/optional-selftests.c: New file.
6318 * unittests/optional/assignment/1.cc: New file.
6319 * unittests/optional/assignment/2.cc: New file.
6320 * unittests/optional/assignment/3.cc: New file.
6321 * unittests/optional/assignment/4.cc: New file.
6322 * unittests/optional/assignment/5.cc: New file.
6323 * unittests/optional/assignment/6.cc: New file.
6324 * unittests/optional/assignment/7.cc: New file.
6325 * unittests/optional/cons/copy.cc: New file.
6326 * unittests/optional/cons/default.cc: New file.
6327 * unittests/optional/cons/move.cc: New file.
6328 * unittests/optional/cons/value.cc: New file.
6329 * unittests/optional/in_place.cc: New file.
6330 * unittests/optional/observers/1.cc: New file.
6331 * unittests/optional/observers/2.cc: New file.
6332
22796e97
PA
63332017-04-18 Pedro Alves <palves@redhat.com>
6334
6335 * common/gdb_optional.h: Include common/traits.h.
6336 (in_place_t): New type.
6337 (in_place): New constexpr variable.
6338 (optional::optional): Remove member initialization of
6339 m_instantiated.
6340 (optional::optional(in_place_t...)): New constructor.
6341 (optional::~optional): Use reset.
6342 (optional::optional(const optional&)): New.
6343 (optional::optional(const optional&&)): New.
6344 (optional::optional(T &)): New.
6345 (optional::optional(T &&)): New.
6346 (operator::operator=(const optional &)): New.
6347 (operator::operator=(optional &&)): New.
6348 (operator::operator= (const T &))
6349 (operator::operator= (T &&))
6350 (operator::emplace (Args &&... args)): Return a T&. Use reset.
6351 (operator::reset): New.
6352 (operator::m_instantiated):: Add in-class initializer.
6353 * common/traits.h: Include <type_traits>.
6354 (struct And): New types.
6355
a7fc9b61
PA
63562017-04-18 Pedro Alves <palves@redhat.com>
6357
6358 * xml-support.c: Include <vector>.
6359 (scope_level::scope_level(const gdb_xml_element *))
6360 (scope_level::scope_level(scope_level&&)): New.
6361 (scope_level::~scope_level): New.
6362 (scope_level_s): Delete.
6363 (gdb_xml_parser::scopes): Now a std::vector.
6364 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
6365 Use std::vector.
6366 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
6367 scope cleanup code.
6368 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
6369 of the scopes member. Use std::vector::emplace_back.
6370
010151c9
PA
63712017-04-18 Pedro Alves <palves@redhat.com>
6372
6373 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
6374 a bool.
6375 (gdb_xml_end_element): Change type of first parameter.
6376 (gdb_xml_cleanup): Rename to ...
6377 (gdb_xml_parser::~gdb_xml_parser): ... this.
6378 (gdb_xml_create_parser_and_cleanup): Delete with ...
6379 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
6380 to this new ctor.
6381 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
6382 using gdb_xml_create_parser_and_cleanup.
6383 (xinclude_parsing_data): Add ctor/dtor.
6384 (xml_xinclude_cleanup): Delete.
6385 (xml_process_xincludes): Create a local xinclude_parsing_data
6386 instead of heap-allocating one. Create a local gdb_xml_parser
6387 instead of heap-allocating one with
6388 gdb_xml_create_parser_and_cleanup.
6389
d56060f0
JB
63902017-04-18 John Baldwin <jhb@FreeBSD.org>
6391
6392 PR threads/20743
6393 * fbsd-nat.c (resume_one_thread_cb): Remove.
6394 (resume_all_threads_cb): Remove.
6395 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
6396 iterate_over_threads.
6397
305d16a9
JB
63982017-04-17 Joel Brobecker <brobecker@adacore.com>
6399
6400 * NEWS: Create a new section for the next release branch.
6401 Rename the section of the current branch, now that it has
6402 been cut.
6403
8bb57231
JB
64042017-04-17 Joel Brobecker <brobecker@adacore.com>
6405
6406 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
6407 * version.in: Bump version to 8.0.50.DATE-git.
6408
096c92dd
SDJ
64092017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
6410
6411 PR gdb/21385
6412 * windows-nat.c (windows_create_inferior): Declare 'allargs'
6413 independently of the host, and fix build breakage on Cygwin.
6414
0550c955
PA
64152017-04-13 Pedro Alves <palves@redhat.com>
6416
6417 * inferior.c (free_inferior): Convert to ...
6418 (inferior::~inferior): ... this dtor.
6419 (inferior::inferior): New ctor, factored out from ...
6420 (add_inferior_silent): ... here. Allocate the inferior with a new
6421 expression.
6422 (delete_inferior): Call delete instead of free_inferior.
6423 * inferior.h (gdb_environ, continuation): Forward declare.
6424 (inferior): Now a class. Add in-class initialization to all
6425 members. Make boolean fields bool, except 'detaching'.
6426 (inferior::inferior): New explicit ctor.
6427 (inferior::~inferior): New.
6428
e3d60dfc
PA
64292017-04-13 Pedro Alves <palves@redhat.com>
6430
6431 * inferior.c (init_inferior_list): Delete.
6432 * inferior.h (init_inferior_list): Delete.
6433
5fd69d0a
PA
64342017-04-13 Pedro Alves <palves@redhat.com>
6435
6436 PR threads/13217
6437 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
6438 (top level): Call it twice, with different thread sets.
6439
c6609450
PA
64402017-04-13 Pedro Alves <palves@redhat.com>
6441
6442 * thread.c: Include <algorithm>.
6443 (thread_array_cleanup): Delete.
6444 (scoped_inc_dec_ref): New class.
6445 (live_threads_count): New function.
6446 (set_thread_refcount): Delete.
6447 (tp_array_compar_ascending): Now a bool.
6448 (tp_array_compar): Convert to a std::sort comparison function.
6449 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
6450 and live_threads_count.
6451
2a00d7ce
PA
64522017-04-13 Pedro Alves <palves@redhat.com>
6453
6454 * infrun.c (follow_fork_inferior): Also switch the current
6455 inferior.
6456
441d7c93
PA
64572017-04-13 Pedro Alves <palves@redhat.com>
6458
6459 * breakpoint.c (watch_command_1): Save watchpoint-frame info
6460 before calling create_internal_breakpoint.
6461
808480f6
PA
64622017-04-13 Pedro Alves <palves@redhat.com>
6463
6464 * fork-child.c (execv_argv): New class.
6465 (breakup_args): Refactored as ...
6466 (execv_argv::init_for_no_shell): .. this method of execv_argv.
6467 Copy arguments to storage and replace separators with NULL
6468 terminators in place.
6469 (escape_bang_in_quoted_argument): Adjust to return bool.
6470 (execv_argv::execv_argv): New ctor.
6471 (execv_argv::init_for_shell): New method, factored out from
6472 fork_inferior. Don't strdup strings into the vector.
6473 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
6474 Remove free_vector_argv call.
6475
ad3d022a
YQ
64762017-04-13 Yao Qi <yao.qi@linaro.org>
6477
6478 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
6479 tdep->rx_psw_type.
6480
e6ddc3bf
YQ
64812017-04-13 Yao Qi <yao.qi@linaro.org>
6482
6483 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
6484 * rx-tdep.c (rx_gdbarch_init): Likewise.
6485
bfb8cf90
PA
64862017-04-13 Pedro Alves <palves@redhat.com>
6487
6488 * breakpoint.h (struct breakpoint): Reindent.
6489
f5336ca5
PA
64902017-04-13 Pedro Alves <palves@redhat.com>
6491
6492 * breakpoint.c (bp_location): Rename to ...
6493 (bp_locations): ... this. All references updated.
6494 (bp_location_count): Rename to ...
6495 (bp_locations_count): ... this. All references updated.
6496 (bp_location_placed_address_before_address_max): Rename to ...
6497 (bp_locations_placed_address_before_address_max): ... this. All
6498 references updated.
6499 (bp_location_shadow_len_after_address_max): Rename to ...
6500 (bp_locations_shadow_len_after_address_max): ... this. All
6501 references updated.
6502 (bp_location_compare_addrs): Rename to ...
6503 (bp_locations_compare_addrs): ... this. All references updated.
6504 (bp_location_compare):Rename to ...
6505 (bp_locations_compare): ... this. All references updated.
6506 (bp_location_target_extensions_update): Rename to ...
6507 (bp_locations_target_extensions_update): ... this. All references
6508 updated.
6509
be628ab8
SDJ
65102017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
6511
6512 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
6513 * common/common.m4: Check headers 'termios.h', 'termio.h' and
6514 'sgtty.h'.
6515 * common/gdb_termios.h: New file, with parts of "terminal.h".
6516 * inflow.c: Include "gdb_termios.h".
6517 * ser-unix.c: Include "gdb_termios.h".
6518 * terminal.h: Move terminal-related defines to
6519 "common/gdb_termios.h".
6520
8e9e35b1
TT
65212017-04-12 Tom Tromey <tom@tromey.com>
6522
6523 * probe.c (parse_probes): Update.
6524 * location.h (delete_event_location): Don't declare.
6525 (event_location_deleter::operator()): Update.
6526 * location.c (event_location_deleter::operator()): Rename from
6527 delete_event_location.
6528 * linespec.h (linespec_result) <location>: Change type to
6529 event_location_up.
6530 * linespec.c (canonicalize_linespec, event_location_to_sals)
6531 (decode_objc): Update.
6532 (linespec_result): Don't call delete_event_location.
6533 * breakpoint.c (create_breakpoints_sal)
6534 (bkpt_probe_create_sals_from_location)
6535 (strace_marker_create_sals_from_location): Update.
6536
16e802b9
TT
65372017-04-12 Tom Tromey <tom@tromey.com>
6538
6539 * linespec.h (struct linespec_result): Add constructor and
6540 destructor.
6541 (init_linespec_result, destroy_linespec_result)
6542 (make_cleanup_destroy_linespec_result): Don't declare.
6543 * linespec.c (init_linespec_result): Remove.
6544 (linespec_result::~linespec_result): Rename from
6545 destroy_linespec_result. Update.
6546 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
6547 Remove.
6548 * breakpoint.c (create_breakpoint, break_range_command)
6549 (decode_location_default): Update.
6550 * ax-gdb.c (agent_command_1): Update.
6551
d28cd78a
TT
65522017-04-12 Tom Tromey <tom@tromey.com>
6553
6554 * remote.c (remote_download_tracepoint): Update.
6555 * python/py-breakpoint.c (bppy_get_location): Update.
6556 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
6557 (gdbscm_breakpoint_location): Update.
6558 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
6559 * breakpoint.h (struct breakpoint) <location, location_range_end>:
6560 Change type to event_location_up.
6561 * breakpoint.c (create_overlay_event_breakpoint)
6562 (create_longjmp_master_breakpoint)
6563 (create_std_terminate_master_breakpoint)
6564 (create_exception_master_breakpoint)
6565 (breakpoint_event_location_empty_p, print_breakpoint_location)
6566 (print_one_breakpoint_location, create_thread_event_breakpoint)
6567 (init_breakpoint_sal, create_breakpoint)
6568 (print_recreate_ranged_breakpoint, break_range_command)
6569 (init_ada_exception_breakpoint, say_where): Update.
6570 (base_breakpoint_dtor): Don't call delete_event_location.
6571 (bkpt_print_recreate, tracepoint_print_recreate)
6572 (dprintf_print_recreate, update_static_tracepoint)
6573 (breakpoint_re_set_default): Update.
6574
711799d5
TT
65752017-04-12 Tom Tromey <tom@tromey.com>
6576
6577 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
6578 type of "to_do". Update.
6579 (compute_stack_depth): Use std::vector.
6580
52d214d3
TT
65812017-04-12 Tom Tromey <tom@tromey.com>
6582
6583 * printcmd.c (find_instruction_backward): Use std::vector.
6584
4c404b8b
TT
65852017-04-12 Tom Tromey <tom@tromey.com>
6586
6587 * symfile.c (objfilep): Remove typedef.
6588 (reread_symbols): Use a std::vector.
6589
156d9eab
TT
65902017-04-12 Tom Tromey <tom@tromey.com>
6591
6592 * mi/mi-main.c (exec_direction_forward): Remove.
6593 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
6594 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
6595 scoped_restore.
6596 * guile/guile.c (guile_repl_command, guile_command)
6597 (gdbscm_execute_gdb_command): Use scoped_restore.
6598 * go-exp.y (go_parse): Use scoped_restore.
6599 * d-exp.y (d_parse): Use scoped_restore.
6600 * cli/cli-decode.c (cmd_func): Use scoped_restore.
6601 * c-exp.y (c_parse): Use scoped_restore.
6602
4d89769a
TT
66032017-04-12 Tom Tromey <tom@tromey.com>
6604
6605 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
6606 (mi_parse): Update return type.
6607 (mi_parse_free): Remove.
6608 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
6609 (mi_parse::~mi_parse): Rename from mi_parse_free.
6610 (mi_parse_cleanup): Remove.
6611 (mi_parse): Return a unique_ptr. Use new.
6612 * mi/mi-main.c (mi_execute_command): Update.
6613
4b217cc7
TT
66142017-04-12 Tom Tromey <tom@tromey.com>
6615
6616 * location.c (explicit_location_lex_one): Return a
6617 unique_xmalloc_ptr.
6618 (string_to_explicit_location): Update. Remove cleanups.
6619
59d3651b
TT
66202017-04-12 Tom Tromey <tom@tromey.com>
6621
6622 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
6623 (compare_value_and_voffset): Change type. Update.
6624 (compute_vtable_size): Change type of "offset_vec".
6625 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
6626 (gnuv3_get_typeid): Remove extraneous declaration.
6627
b24b0d6c
TT
66282017-04-12 Tom Tromey <tom@tromey.com>
6629
6630 * charset.h (wchar_iterator): Fix comment.
6631
80a3b8c5
TT
66322017-04-12 Tom Tromey <tom@tromey.com>
6633
6634 * charset.c (iconv_wrapper): New class.
6635 (cleanup_iconv): Remove.
6636 (convert_between_encodings): Use it.
6637
c83dd867
TT
66382017-04-12 Tom Tromey <tom@tromey.com>
6639
6640 * symfile.h (increment_reading_symtab): Update type.
6641 * symfile.c (decrement_reading_symtab): Remove.
6642 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
6643 * psymtab.c (psymtab_to_symtab): Update.
6644 * dwarf2read.c (dw2_instantiate_symtab): Update.
6645
0e8621a0
TT
66462017-04-12 Tom Tromey <tom@tromey.com>
6647
6648 * jit.c (struct jit_reader): Declare separately. Add constructor
6649 and destructor. Change type of "handle".
6650 (loaded_jit_reader): Define separately.
6651 (jit_reader_load): Update. New "new".
6652 (jit_reader_unload_command): Use "delete".
6653 * gdb-dlfcn.h (struct dlclose_deleter): New.
6654 (gdb_dlhandle_up): New typedef.
6655 (gdb_dlopen, gdb_dlsym): Update types.
6656 (gdb_dlclose): Remove.
6657 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
6658 (gdb_dlsym): Change type of "handle".
6659 (make_cleanup_dlclose): Remove.
6660 (dlclose_deleter::operator()): Rename from gdb_dlclose.
6661 * compile/compile-c-support.c (load_libcc): Update.
6662
67d89901
TT
66632017-04-12 Tom Tromey <tom@tromey.com>
6664
6665 * symtab.h (find_pcs_for_symtab_line): Change return type.
6666 * symtab.c (find_pcs_for_symtab_line): Change return type.
6667 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
6668 type of "vec". Update.
6669 (ltpy_get_pcs_for_line): Update.
6670 * linespec.c (decode_digits_ordinary): Update.
6671
93921405
TT
66722017-04-12 Tom Tromey <tom@tromey.com>
6673
6674 * tracepoint.c (actions_command): Update.
6675 * python/python.c (python_command, python_interactive_command):
6676 Update.
6677 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
6678 * guile/guile.c (guile_command): Update.
6679 * defs.h (read_command_lines, read_command_lines_1): Return
6680 command_line_up.
6681 (command_lines_deleter): New struct.
6682 (command_line_up): New typedef.
6683 * compile/compile.c (compile_code_command)
6684 (compile_print_command): Update.
6685 * cli/cli-script.h (get_command_line, copy_command_lines): Return
6686 command_line_up.
6687 (make_cleanup_free_command_lines): Remove.
6688 * cli/cli-script.c (get_command_line, read_command_lines_1)
6689 (copy_command_lines): Return command_line_up.
6690 (while_command, if_command, read_command_lines, define_command)
6691 (document_command): Update.
6692 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
6693 Remove.
6694 * breakpoint.h (breakpoint_set_commands): Change type of
6695 "commands".
6696 * breakpoint.c (breakpoint_set_commands): Change type of
6697 "commands". Update.
6698 (do_map_commands_command, update_dprintf_command_list)
6699 (create_tracepoint_from_upload): Update.
6700
ffc2605c
TT
67012017-04-12 Tom Tromey <tom@tromey.com>
6702
6703 * tracepoint.c (scope_info): Update.
6704 * spu-tdep.c (spu_catch_start): Update.
6705 * python/python.c (gdbpy_decode_line): Update.
6706 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
6707 * python/py-breakpoint.c (bppy_init): Update.
6708 * probe.c (parse_probes): Update.
6709 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
6710 * location.h (event_location_deleter): New struct.
6711 (event_location_up): New typedef.
6712 (new_linespec_location, new_address_location, new_probe_location)
6713 (new_explicit_location, copy_event_location)
6714 (string_to_event_location, string_to_event_location_basic)
6715 (string_to_explicit_location): Update return type.
6716 (make_cleanup_delete_event_location): Remove.
6717 * location.c (new_linespec_location, new_address_location)
6718 (new_probe_location, new_explicit_location, copy_event_location):
6719 Return event_location_up.
6720 (delete_event_location_cleanup)
6721 (make_cleanup_delete_event_location): Remove.
6722 (string_to_explicit_location, string_to_event_location_basic)
6723 (string_to_event_location): Return event_location_up.
6724 * linespec.c (canonicalize_linespec, event_location_to_sals)
6725 (decode_line_with_current_source)
6726 (decode_line_with_last_displayed, decode_objc): Update.
6727 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
6728 * completer.c (location_completer): Update.
6729 * cli/cli-cmds.c (edit_command, list_command): Update.
6730 * breakpoint.c (create_overlay_event_breakpoint)
6731 (create_longjmp_master_breakpoint)
6732 (create_std_terminate_master_breakpoint)
6733 (create_exception_master_breakpoint)
6734 (create_thread_event_breakpoint): Update.
6735 (init_breakpoint_sal): Update. Remove some dead code.
6736 (create_breakpoint_sal): Change type of "location". Update.
6737 (create_breakpoints_sal, create_breakpoint, break_command_1)
6738 (dprintf_command, break_range_command, until_break_command)
6739 (init_ada_exception_breakpoint)
6740 (strace_marker_create_sals_from_location)
6741 (update_static_tracepoint, trace_command, ftrace_command)
6742 (strace_command, create_tracepoint_from_upload): Update.
6743 * break-catch-throw.c (re_set_exception_catchpoint): Update.
6744 * ax-gdb.c (agent_command_1): Update.
6745
8f10c932
PA
67462017-04-12 Pedro Alves <palves@redhat.com>
6747
6748 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
6749 * configure.tgt: Handle i[34567]86-*-go32* and
6750 i[34567]86-*-msdosdjgpp*.
6751 * i386-tdep.c (i386_svr4_reg_to_regnum):
6752 Make extern.
6753 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
6754 i386-go32-tdep.c.
6755 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
6756 * i386-go32-tdep.c: New file.
6757 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
6758 declarations.
6759
0a31ccfb
SM
67602017-04-12 Simon Marchi <simon.marchi@ericsson.com>
6761
6762 * aix-thread.c (pd_status2str): Change return type to const char *.
6763
e9bb3fbb
PA
67642017-04-12 Pedro Alves <palves@redhat.com>
6765
6766 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
6767 calls to set_gdbarch_gnu_triplet_regexp.
6768
53375380
PA
67692017-04-12 Pedro Alves <palves@redhat.com>
6770
6771 PR gdb/21323
6772 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
6773 New enum value.
6774 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
6775 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
6776 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
6777 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
6778 * gdbarch.h, gdbarch.c: Regenerate.
6779 * aarch64-tdep.c (aarch64_gdbarch_init): Override
6780 gdbarch_wchar_bit and gdbarch_wchar_signed.
6781 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
6782 * arm-tdep.c (arm_gdbarch_init): Likewise.
6783 * avr-tdep.c (avr_gdbarch_init): Likewise.
6784 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
6785 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
6786 * i386-tdep.c (i386_go32_init_abi): Likewise.
6787 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
6788 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
6789 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
6790 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
6791 * sh-tdep.c (sh_gdbarch_init): Likewise.
6792 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
6793 * sparc64-tdep.c (sparc64_init_abi): Likewise.
6794 * windows-tdep.c (windows_init_abi): Likewise.
6795 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
6796
53e710ac
PA
67972017-04-12 Pedro Alves <palves@redhat.com>
6798
6799 PR c++/21323
6800 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
6801 cplus_primitive_type_char32_t>: New enum values.
6802 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
6803 and cplus_primitive_type_char32_t.
6804 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
6805 32, use the archtecture's built-in type for char16_t and char32_t,
6806 respectively. Otherwise, fallback to init_integer_type as before,
6807 but make the type unsigned, and issue a complaint.
6808 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
6809
ab0538b8
AH
68102017-04-12 Alan Hayward <alan.hayward@arm.com>
6811
5e0e0422 6812 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
ab0538b8
AH
6813 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
6814
5430098f
SDJ
68152017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
6816
6817 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
6818 'const char *'.
6819
7c5ded6a
SDJ
68202017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
6821
6822 * common/common-utils.c (free_vector_argv): New function.
6823 * common/common-utils.h: Include <vector>.
6824 (free_vector_argv): New prototype.
6825 * darwin-nat.c (darwin_create_inferior): Rewrite function
6826 prototype in order to constify "exec_file" and accept a
6827 "std::string" for "allargs".
6828 * fork-child.c: Include <vector>.
6829 (breakup_args): Rewrite function, using C++.
6830 (fork_inferior): Rewrite function header, constify "exec_file_arg"
6831 and accept "std::string" for "allargs". Update the code to
6832 calculate "argv" based on "allargs". Update calls to "exec_fun"
6833 and "execvp".
6834 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
6835 order to constify "exec_file" and accept a "std::string" for
6836 "allargs".
6837 * go32-nat.c (go32_create_inferior): Likewise.
6838 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
6839 * infcmd.c (run_command_1): Constify "exec_file". Use
6840 "std::string" for inferior arguments.
6841 * inferior.h (fork_inferior): Update prototype.
6842 * linux-nat.c (linux_nat_create_inferior): Rewrite function
6843 prototype in order to constify "exec_file" and accept a
6844 "std::string" for "allargs".
6845 * nto-procfs.c (procfs_create_inferior): Likewise.
6846 * procfs.c (procfs_create_inferior): Likewise.
6847 * remote-sim.c (gdbsim_create_inferior): Likewise.
6848 * remote.c (extended_remote_run): Update code to accept
6849 "std::string" as argument.
6850 (extended_remote_create_inferior): Rewrite function prototype in
6851 order to constify "exec_file" and accept a "std::string" for
6852 "allargs".
6853 * rs6000-nat.c (super_create_inferior): Likewise.
6854 (rs6000_create_inferior): Likewise.
6855 * target.h (struct target_ops) <to_create_inferior>: Likewise.
6856 * windows-nat.c (windows_create_inferior): Likewise.
6857
ae0eee42
PA
68582017-04-11 Pedro Alves <palves@redhat.com>
6859
6860 * thread.c: Fix whitespace throughout.
6861
a6acac06
PR
68622017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
6863
6864 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
6865
64403bd1
AH
68662017-04-11 Alan Hayward <alan.hayward@arm.com>
6867
6868 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
6869
a5bef50f
SDJ
68702017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
6871
6872 PR gdb/21364
6873 * osdata.c (info_osdata): Check if 'type' is an empty string
6874 instead of NULL.
6875
9295a5a9
PA
68762017-04-10 Pedro Alves <palves@redhat.com>
6877
6878 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
6879 (ptid_to_global_thread_id, in_thread_list)
6880 (do_captured_list_thread_ids, set_resumed, set_running)
6881 (set_executing, set_stop_requested, finish_thread_state)
6882 (validate_registers_access, can_access_registers_ptid)
6883 (print_thread_info_1, switch_to_thread)
6884 (do_restore_current_thread_cleanup)
6885 (make_cleanup_restore_current_thread, thread_command)
6886 (thread_name_command): Use operator== instead of ptid_equal.
6887
996812e3
PA
68882017-04-10 Pedro Alves <palves@redhat.com>
6889
6890 * thread.c (struct current_thread_cleanup) <next>: Delete field.
6891 (current_thread_cleanup_chain): Delete.
6892 (restore_current_thread_cleanup_dtor)
6893 (make_cleanup_restore_current_thread): Remove references to
6894 current_thread_cleanup_chain.
6895
845b344f
AH
68962017-04-10 Alan Hayward <alan.hayward@arm.com>
6897
6898 * msp430-tdep.c (msp430_pseudo_register_read): Never return
6899 REG_UNKNOWN.
6900
803bdfe4
YQ
69012017-04-10 Yao Qi <yao.qi@linaro.org>
6902
6903 PR gdb/19942
6904 * gdbthread.h (thread_info::deletable): New method.
6905 (thread_info::incref): New method.
6906 (thread_info::decref): New method.
6907 (thread_info::refcount): Move it to private.
6908 * infrun.c (save_stop_context): Call inc_refcount.
6909 (release_stop_context_cleanup): Likewise.
6910 * thread.c (set_thread_exited): New function.
6911 (init_thread_list): Delete "tp" only it is deletable, otherwise
6912 call set_thread_exited.
6913 (delete_thread_1): Call set_thread_exited.
6914 (current_thread_cleanup) <inferior_pid>: Remove.
6915 <thread>: New field.
6916 (restore_current_thread_ptid_changed): Removed.
6917 (do_restore_current_thread_cleanup): Adjust.
6918 (restore_current_thread_cleanup_dtor): Don't call
6919 find_thread_ptid.
6920 (set_thread_refcount): Use dec_refcount.
6921 (make_cleanup_restore_current_thread): Adjust.
6922 (thread_apply_all_command): Call inc_refcount.
6923 (_initialize_thread): Don't call
6924 observer_attach_thread_ptid_changed.
6925
8c25b497
YQ
69262017-04-10 Yao Qi <yao.qi@linaro.org>
6927
6928 * thread.c (delete_thread_1): Hoist code on marking thread as
6929 exited.
6930
8473b447
SM
69312017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6932
6933 * windows-nat.c (windows_detach): Initialize ptid with
6934 minus_one_ptid.
6935
6670ec13
SM
69362017-04-07 Simon Marchi <simon.marchi@ericsson.com>
6937
6938 * unittests/ptid-selftests.c: Fix erroneous assert messages.
6939
ba2f91bb
AH
69402017-04-07 Alan Hayward <alan.hayward@arm.com>
6941
6942 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
6943 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
6944 (bfin_pseudo_register_write): Likewise
6945
436252de
SM
69462017-04-06 Simon Marchi <simon.marchi@ericsson.com>
6947
6948 * common/ptid.h (struct ptid): Change to...
6949 (class ptid_t): ... this.
6950 <ptid_t>: New constructors.
6951 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
6952 matches>: New methods.
6953 <make_null, make_minus_one>: New static methods.
6954 <pid>: Rename to...
6955 <m_pid>: ...this.
6956 <lwp>: Rename to...
6957 <m_lwp>: ...this.
6958 <tid>: Rename to...
6959 <m_tid>: ...this.
6960 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
6961 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
6962 as references, move comment to class ptid_t.
6963 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
6964 ptid_t static methods.
6965 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
6966 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
6967 Take ptid arguments as references, implement using ptid_t methods.
6968 * unittests/ptid-selftests.c: New file.
6969 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6970 unittests/ptid-selftests.c.
6971 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
6972
0dedf377
TP
69732017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
6974
6975 * python/python.c (python_run_simple_file): Cast mode literal to
6976 non-const char pointer as expected by PyFile_FromString.
6977
4e9868d4
SM
69782017-04-05 Simon Marchi <simon.marchi@ericsson.com>
6979
6980 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
6981 minus_one_ptid and null_ptid.
6982
9bf2a700
PA
69832017-04-05 Pedro Alves <palves@redhat.com>
6984
6985 * warning.m4 (build_warnings): Remove -Wno-write-strings.
6986 * configure: Regenerate.
6987
a121b7c1
PA
69882017-04-05 Pedro Alves <palves@redhat.com>
6989
6990 * ada-exp.y (yyerror): Constify.
6991 * ada-lang.c (bound_name, get_selections)
6992 (ada_variant_discrim_type)
6993 (ada_variant_discrim_name, ada_value_struct_elt)
6994 (ada_lookup_struct_elt_type, is_unchecked_variant)
6995 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
6996 (catch_ada_exception_command_split)
6997 (catch_ada_assert_command_split, catch_assert_command)
6998 (ada_op_name): Constify.
6999 * ada-lang.h (ada_yyerror, get_selections)
7000 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
7001 * arc-tdep.c (arc_print_frame_cache): Constify.
7002 * arm-tdep.c (arm_skip_stub): Constify.
7003 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
7004 (gen_aggregate_elt_ref): Constify.
7005 * bcache.c (print_bcache_statistics): Constify.
7006 * bcache.h (print_bcache_statistics): Constify.
7007 * break-catch-throw.c (catch_exception_command_1):
7008 * breakpoint.c (struct ep_type_description::description):
7009 Constify.
7010 (add_solib_catchpoint): Constify.
7011 (catch_fork_command_1): Add cast.
7012 (add_catch_command): Constify.
7013 * breakpoint.h (add_catch_command, add_solib_catchpoint):
7014 Constify.
7015 * bsd-uthread.c (bsd_uthread_state): Constify.
7016 * buildsym.c (patch_subfile_names): Constify.
7017 * buildsym.h (next_symbol_text_func, patch_subfile_names):
7018 Constify.
7019 * c-exp.y (yyerror): Constify.
7020 (token::oper): Constify.
7021 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
7022 * c-varobj.c (cplus_describe_child): Constify.
7023 * charset.c (find_charset_names): Add cast.
7024 (find_charset_names): Constify array and add const_cast.
7025 * cli/cli-cmds.c (complete_command, cd_command): Constify.
7026 (edit_command): Constify.
7027 * cli/cli-decode.c (lookup_cmd): Constify.
7028 * cli/cli-dump.c (dump_memory_command, dump_value_command):
7029 Constify.
7030 (struct dump_context): Constify.
7031 (add_dump_command, restore_command): Constify.
7032 * cli/cli-script.c (get_command_line): Constify.
7033 * cli/cli-script.h (get_command_line): Constify.
7034 * cli/cli-utils.c (check_for_argument): Constify.
7035 * cli/cli-utils.h (check_for_argument): Constify.
7036 * coff-pe-read.c (struct read_pe_section_data): Constify.
7037 * command.h (lookup_cmd): Constify.
7038 * common/print-utils.c (decimal2str): Constify.
7039 * completer.c (gdb_print_filename): Constify.
7040 * corefile.c (set_gnutarget): Constify.
7041 * cp-name-parser.y (yyerror): Constify.
7042 * cp-valprint.c (cp_print_class_member): Constify.
7043 * cris-tdep.c (cris_register_name, crisv32_register_name):
7044 Constify.
7045 * d-exp.y (yyerror): Constify.
7046 (struct token::oper): Constify.
7047 * d-lang.h (d_yyerror): Constify.
7048 * dbxread.c (struct header_file_location::name): Constify.
7049 (add_old_header_file, add_new_header_file, last_function_name)
7050 (dbx_next_symbol_text, add_bincl_to_list)
7051 (find_corresponding_bincl_psymtab, set_namestring)
7052 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
7053 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
7054 * defs.h (command_line_input, print_address_symbolic)
7055 (deprecated_readline_begin_hook): Constify.
7056 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
7057 Constify.
7058 * event-top.c (handle_line_of_input): Constify and add cast.
7059 * exceptions.c (catch_errors): Constify.
7060 * exceptions.h (catch_errors): Constify.
7061 * expprint.c (print_subexp_standard, op_string, op_name)
7062 (op_name_standard, dump_raw_expression, dump_raw_expression):
7063 * expression.h (op_name, op_string, dump_raw_expression):
7064 Constify.
7065 * f-exp.y (yyerror): Constify.
7066 (struct token::oper): Constify.
7067 (struct f77_boolean_val::name): Constify.
7068 * f-lang.c (f_word_break_characters): Constify.
7069 * f-lang.h (f_yyerror): Constify.
7070 * fork-child.c (fork_inferior): Add cast.
7071 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
7072 (new_variant): Constify.
7073 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
7074 * gdbarch.c: Regenerate.
7075 * gdbcore.h (set_gnutarget): Constify.
7076 * go-exp.y (yyerror): Constify.
7077 (token::oper): Constify.
7078 * go-lang.h (go_yyerror): Constify.
7079 * go32-nat.c (go32_sysinfo): Constify.
7080 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
7081 * guile/scm-cmd.c (cmdscm_function): Constify.
7082 * guile/scm-param.c (pascm_param_value): Constify.
7083 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
7084 (h8300sx_register_name): Constify.
7085 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
7086 Constify.
7087 * ia64-tdep.c (ia64_register_names): Constify.
7088 * infcmd.c (construct_inferior_arguments): Constify.
7089 (path_command, attach_post_wait): Constify.
7090 * language.c (show_range_command, show_case_command)
7091 (unk_lang_error): Constify.
7092 * language.h (language_defn::la_error)
7093 (language_defn::la_name_of_this): Constify.
7094 * linespec.c (decode_line_2): Constify.
7095 * linux-thread-db.c (thread_db_err_str): Constify.
7096 * lm32-tdep.c (lm32_register_name): Constify.
7097 * m2-exp.y (yyerror): Constify.
7098 * m2-lang.h (m2_yyerror): Constify.
7099 * m32r-tdep.c (m32r_register_names): Constify and make static.
7100 * m68hc11-tdep.c (m68hc11_register_names): Constify.
7101 * m88k-tdep.c (m88k_register_name): Constify.
7102 * macroexp.c (appendmem): Constify.
7103 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
7104 (upgrade_type, parse_external, parse_partial_symbols)
7105 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
7106 (new_symbol): Constify.
7107 * memattr.c (mem_info_command): Constify.
7108 * mep-tdep.c (register_name_from_keyword): Constify.
7109 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
7110 Constify.
7111 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
7112 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
7113 * mi/mi-main.c (captured_mi_execute_command): Constify and add
7114 cast.
7115 (mi_execute_async_cli_command): Constify.
7116 * mips-tdep.c (mips_register_name): Constify.
7117 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
7118 (am33_register_name, am33_2_register_name)
7119 * moxie-tdep.c (moxie_register_names): Constify.
7120 * nat/linux-osdata.c (osdata_type): Constify fields.
7121 * nto-tdep.c (nto_parse_redirection): Constify.
7122 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
7123 (lookup_child_selector): Constify.
7124 (objc_methcall::name): Constify.
7125 * objc-lang.h (lookup_objc_class, lookup_child_selector)
7126 (lookup_struct_typedef): Constify.
7127 * objfiles.c (pc_in_section): Constify.
7128 * objfiles.h (pc_in_section): Constify.
7129 * p-exp.y (struct token::oper): Constify.
7130 (yyerror): Constify.
7131 * p-lang.h (pascal_yyerror): Constify.
7132 * parser-defs.h (op_name_standard): Constify.
7133 (op_print::string): Constify.
7134 (exp_descriptor::op_name): Constify.
7135 * printcmd.c (print_address_symbolic): Constify.
7136 * psymtab.c (print_partial_symbols): Constify.
7137 * python/py-breakpoint.c (stop_func): Constify.
7138 (bppy_get_expression): Constify.
7139 * python/py-cmd.c (cmdpy_completer::name): Constify.
7140 (cmdpy_function): Constify.
7141 * python/py-event.c (evpy_add_attribute)
7142 (gdbpy_initialize_event_generic): Constify.
7143 * python/py-event.h (evpy_add_attribute)
7144 (gdbpy_initialize_event_generic): Constify.
7145 * python/py-evts.c (add_new_registry): Constify.
7146 * python/py-finishbreakpoint.c (outofscope_func): Constify.
7147 * python/py-framefilter.c (get_py_iter_from_func): Constify.
7148 * python/py-inferior.c (get_buffer): Add cast.
7149 * python/py-param.c (parm_constant::name): Constify.
7150 * python/py-unwind.c (fprint_frame_id): Constify.
7151 * python/python.c (gdbpy_parameter_value): Constify.
7152 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
7153 * remote.c (memory_packet_config::name): Constify.
7154 (show_packet_config_cmd, remote_write_bytes)
7155 (remote_buffer_add_string):
7156 * reverse.c (exec_reverse_once): Constify.
7157 * rs6000-tdep.c (variant::name, variant::description): Constify.
7158 * rust-exp.y (rustyyerror): Constify.
7159 * rust-lang.c (rust_op_name): Constify.
7160 * rust-lang.h (rustyyerror): Constify.
7161 * serial.h (serial_ops::name): Constify.
7162 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
7163 (sh_sh3e_register_name, sh_sh2e_register_name)
7164 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
7165 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
7166 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
7167 (sh_sh4al_dsp_register_name): Constify.
7168 * sh64-tdep.c (sh64_register_name): Constify.
7169 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
7170 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
7171 * stabsread.c (patch_block_stabs, read_type_number)
7172 (ref_map::stabs, ref_add, process_reference)
7173 (symbol_reference_defined, define_symbol, define_symbol)
7174 (error_type, read_type, read_member_functions, read_cpp_abbrev)
7175 (read_one_struct_field, read_struct_fields, read_baseclasses)
7176 (read_tilde_fields, read_struct_type, read_array_type)
7177 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
7178 (read_huge_number, read_range_type, read_args, common_block_start)
7179 (find_name_end): Constify.
7180 * stabsread.h (common_block_start, define_symbol)
7181 (process_one_symbol, symbol_reference_defined, ref_add):
7182 * symfile.c (get_section_index, add_symbol_file_command):
7183 * symfile.h (get_section_index): Constify.
7184 * target-descriptions.c (tdesc_type::name): Constify.
7185 (tdesc_free_type): Add cast.
7186 * target.c (find_default_run_target):
7187 (add_deprecated_target_alias, find_default_run_target)
7188 (target_announce_detach): Constify.
7189 (do_option): Constify.
7190 * target.h (add_deprecated_target_alias): Constify.
7191 * thread.c (print_thread_info_1): Constify.
7192 * top.c (deprecated_readline_begin_hook, command_line_input):
7193 Constify.
7194 (init_main): Add casts.
7195 * top.h (handle_line_of_input): Constify.
7196 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
7197 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
7198 (tfind_command): Rename to ...
7199 (tfind_command_1): ... this and constify.
7200 (tfind_command): New function.
7201 (tfind_end_command, tfind_start_command): Adjust.
7202 (encode_source_string): Constify.
7203 * tracepoint.h (encode_source_string): Constify.
7204 * tui/tui-data.c (tui_partial_win_by_name): Constify.
7205 * tui/tui-data.h (tui_partial_win_by_name): Constify.
7206 * tui/tui-source.c (tui_set_source_content_nil): Constify.
7207 * tui/tui-source.h (tui_set_source_content_nil): Constify.
7208 * tui/tui-win.c (parse_scrolling_args): Constify.
7209 * tui/tui-windata.c (tui_erase_data_content): Constify.
7210 * tui/tui-windata.h (tui_erase_data_content): Constify.
7211 * tui/tui-winsource.c (tui_erase_source_content): Constify.
7212 * tui/tui.c (tui_enable): Add cast.
7213 * utils.c (defaulted_query): Constify.
7214 (init_page_info): Add cast.
7215 (puts_debug, subset_compare): Constify.
7216 * utils.h (subset_compare): Constify.
7217 * varobj.c (varobj_format_string): Constify.
7218 * varobj.h (varobj_format_string): Constify.
7219 * vax-tdep.c (vax_register_name): Constify.
7220 * windows-nat.c (windows_detach): Constify.
7221 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
7222 * xml-support.c (gdb_xml_end_element): Constify.
7223 * xml-tdesc.c (tdesc_start_reg): Constify.
7224 * xstormy16-tdep.c (xstormy16_register_name): Constify.
7225 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
7226 * xtensa-tdep.h (xtensa_register_t::name): Constify.
7227
995816ba
PA
72282017-04-05 Pedro Alves <palves@redhat.com>
7229
7230 * proc-api.c (struct trans): Constify.
7231 (procfs_note): Constify.
7232 * proc-events.c (struct trans, syscall_table):
7233 * proc-flags.c (struct trans): Constify.
7234 * proc-utils.h (procfs_note): Constify.
7235 * proc-why.c (struct trans): Constify.
7236 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
7237 (procfs_detach): Constify.
7238 * sol-thread.c (struct string_map): Constify.
7239 (td_err_string, td_state_string): Constify.
7240
3e83a920
PA
72412017-04-05 Pedro Alves <palves@redhat.com>
7242
7243 * proc-api.c (procfs_filename): Don't initialize
7244 procfs_filename.
7245 (prepare_to_trace): Assume procfs_filename is non-NULL.
7246 (_initialize_proc_api): Give procfs_filename a default value here.
7247
63160a43
PA
72482017-04-05 Pedro Alves <palves@redhat.com>
7249
7250 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
7251 'cond_string' parameter.
7252 (extract_exception_regexp): Constify 'string' parameter.
7253 (catch_exception_command_1): Constify.
7254 * breakpoint.c (init_catchpoint)
7255 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
7256 parameter.
7257 (ep_parse_optional_if_clause, catch_fork_command_1)
7258 (catch_exec_command_1): Constify.
7259 * breakpoint.h (init_catchpoint): Constify 'cond_string'
7260 parameter.
7261 (ep_parse_optional_if_clause): Constify.
7262 * cli/cli-utils.c (remove_trailing_whitespace)
7263 (check_for_argument): Constify.
7264 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
7265 non-const overload.
7266 (check_for_argument): Likewise.
7267
9b2eba3d
PA
72682017-04-05 Pedro Alves <palves@redhat.com>
7269
7270 * event-top.c (command_line_handler): Add cast to execute_command
7271 call.
7272 * record-btrace.c (cmd_record_btrace_bts_start)
7273 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
7274 (cmd_record_btrace_start): Add cast to execute_command call.
7275 * record-full.c (record_full_goto_insn):
7276 * record.c (record_start, record_stop): Add cast to
7277 execute_command_to_string calls.
7278 (cmd_record_start): Add cast to execute_command calls.
7279
2adadf51
PA
72802017-04-05 Pedro Alves <palves@redhat.com>
7281
7282 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
7283 static inline function.
7284 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
7285 array and use gdb_PyArg_ParseTupleAndKeywords.
7286 * python/py-cmd.c (cmdpy_init): Likewise.
7287 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
7288 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
7289 (infpy_search_memory): Likewise.
7290 * python/py-objfile.c (objfpy_add_separate_debug_file)
7291 (gdbpy_lookup_objfile): Likewise.
7292 * python/py-symbol.c (gdbpy_lookup_symbol)
7293 (gdbpy_lookup_global_symbol): Likewise.
7294 * python/py-type.c (gdbpy_lookup_type): Likewise.
7295 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
7296 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
7297 Likewise.
7298
0d1f4ceb
PA
72992017-04-05 Pedro Alves <palves@redhat.com>
7300
7301 * python/python-internal.h (gdb_PyGetSetDef): New type.
7302 * python/py-block.c (block_object_getset)
7303 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
7304 * python/py-event.c (event_object_getset)
7305 (finish_breakpoint_object_getset): Likewise.
7306 * python/py-inferior.c (inferior_object_getset): Likewise.
7307 * python/py-infthread.c (thread_object_getset): Likewise.
7308 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
7309 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
7310 * python/py-objfile.c (objfile_getset): Likewise.
7311 * python/py-progspace.c (pspace_getset): Likewise.
7312 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
7313 Likewise.
7314 * python/py-record.c (recpy_record_getset): Likewise.
7315 * python/py-symbol.c (symbol_object_getset): Likewise.
7316 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
7317 Likewise.
7318 * python/py-type.c (type_object_getset, field_object_getset):
7319 Likewise.
7320 * python/py-value.c (value_object_getset): Likewise.
7321
4d759979
PA
73222017-04-05 Pedro Alves <palves@redhat.com>
7323
7324 * python/python-internal.h (gdb_PyObject_CallMethod)
7325 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
7326 New functions.
7327 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
7328 (PySys_GetObject, PySys_SetPath): New macros.
7329
fdf9e36f
PA
73302017-04-05 Pedro Alves <palves@redhat.com>
7331
7332 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
7333 info_osdata_command.
7334 * osdata.c (info_osdata_command): Rename to ...
7335 (info_osdata): ... this. Constify 'type' parameter, and remove
7336 the 'from_tty' parameter. Accept NULL TYPE.
7337 (info_osdata_command): New function.
7338 * osdata.h (info_osdata_command): Remove declaration.
7339 (info_osdata): New declaration.
7340
9f33b8b7
PA
73412017-04-05 Pedro Alves <palves@redhat.com>
7342
7343 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
7344 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
7345 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
7346 parameter.
7347 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
7348 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
7349 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
7350 parameter.
7351 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
7352 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
7353 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
7354 (mi_cmd_file_list_exec_source_files)
7355 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
7356 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
7357 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
7358 parameter.
7359 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
7360 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
7361 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
7362 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
7363 (mi_cmd_stack_info_frame): Constify 'command' parameter.
7364 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
7365 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
7366 'command' parameter.
7367 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
7368 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
7369 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
7370 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
7371 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
7372 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
7373 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
7374 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
7375 (mi_cmd_var_set_update_range): Constify 'command' parameter.
7376 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
7377 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
7378 parameter.
7379 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
7380 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
7381 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
7382 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
7383 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
7384 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
7385 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
7386 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
7387 (mi_cmd_data_list_changed_registers)
7388 (mi_cmd_data_write_register_values)
7389 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
7390 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
7391 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
7392 (mi_cmd_list_features, mi_cmd_list_target_features)
7393 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
7394 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
7395 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
7396 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
7397 (mi_cmd_trace_frame_collected): Constify 'command'
7398 parameter.
7399 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
7400 'command' parameter.
7401
67cb5b2d
PA
74022017-04-05 Pedro Alves <palves@redhat.com>
7403
7404 * ada-lang.c (ada_completer_word_break_characters): Now a const
7405 array.
7406 (ada_get_gdb_completer_word_break_characters): Constify.
7407 * completer.c (gdb_completer_command_word_break_characters)
7408 (gdb_completer_file_name_break_characters)
7409 (gdb_completer_quote_characters): Now const arrays.
7410 (get_gdb_completer_quote_characters): Constify.
7411 (set_rl_completer_word_break_characters): New function.
7412 (set_gdb_completion_word_break_characters)
7413 (complete_line_internal): Use it.
7414 * completer.h (get_gdb_completer_quote_characters): Constify.
7415 (set_rl_completer_word_break_characters): Declare.
7416 * f-lang.c (f_word_break_characters): Constify.
7417 * language.c (default_word_break_characters): Constify.
7418 * language.h (language_defn::la_word_break_characters): Constify.
7419 (default_word_break_characters): Constify.
7420 * top.c (init_main): Use set_rl_completer_word_break_characters.
7421
7a114964
PA
74222017-04-05 Pedro Alves <palves@redhat.com>
7423
7424 * aix-thread.c (aix_thread_pid_to_str)
7425 (aix_thread_extra_thread_info): Constify.
7426 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
7427 * bsd-uthread.c (bsd_uthread_extra_thread_info)
7428 (bsd_uthread_pid_to_str): Constify.
7429 * corelow.c (core_pid_to_str): Constify.
7430 * darwin-nat.c (darwin_pid_to_str): Constify.
7431 * fbsd-nat.c (fbsd_pid_to_str): Constify.
7432 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
7433 Constify.
7434 * gnu-nat.c (gnu_pid_to_str): Constify.
7435 * go32-nat.c (go32_pid_to_str): Constify.
7436 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
7437 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
7438 * inferior.c (inferior_pid_to_str): Constify.
7439 * linux-nat.c (linux_nat_pid_to_str): Constify.
7440 * linux-tdep.c (linux_core_pid_to_str): Constify.
7441 * linux-thread-db.c (thread_db_pid_to_str)
7442 (thread_db_extra_thread_info): Constify.
7443 * nto-tdep.c (nto_extra_thread_info): Constify.
7444 * nto-tdep.h (nto_extra_thread_info): Constify.
7445 * obsd-nat.c (obsd_pid_to_str): Constify.
7446 * procfs.c (procfs_pid_to_str): Constify.
7447 * ravenscar-thread.c (ravenscar_extra_thread_info)
7448 (ravenscar_pid_to_str): Constify.
7449 * remote-sim.c (gdbsim_pid_to_str): Constify.
7450 * remote.c (remote_threads_extra_info, remote_pid_to_str):
7451 Constify.
7452 * sol-thread.c (solaris_pid_to_str): Constify.
7453 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
7454 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
7455 * target.c (default_pid_to_str, target_pid_to_str)
7456 (normal_pid_to_str, default_pid_to_str): Constify.
7457 * target.h (target_ops::to_pid_to_str)
7458 (target_ops::to_extra_thread_info): Constify.
7459 (target_pid_to_str, normal_pid_to_str): Constify.
7460 * windows-nat.c (windows_pid_to_str): Constify.
7461 * gdbarch.sh (core_pid_to_str): Constify.
7462 * target-delegates.c: Regenerate.
7463 * gdbarch.h, gdbarch.c: Regenerate.
7464
69bbf465
PA
74652017-04-05 Pedro Alves <palves@redhat.com>
7466
7467 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
7468 the memory of the temporary warning_pre_print override.
7469 * utils.c (warning_pre_print): Constify.
7470 * utils.h (warning_pre_print): Constify.
7471
be47f9e8
PA
74722017-04-05 Pedro Alves <palves@redhat.com>
7473
7474 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
7475 (shell_command): New function.
7476 (make_command): Use std::string.
7477 (init_cli_cmds): Register shell_command instead of shell_escape.
7478
bde6261a
PA
74792017-04-05 Pedro Alves <palves@redhat.com>
7480
7481 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
7482 * tracepoint.c (default_collect): Don't initialize.
7483
b38ef47f
PA
74842017-04-05 Pedro Alves <palves@redhat.com>
7485
7486 * macroexp.c (macro_buffer::shared): Now a bool.
7487 (init_buffer): Update.
7488 (init_shared_buffer): Constify 'addr' parameter.
7489 (substitute_args, expand, macro_expand, macro_expand_next): Remove
7490 casts.
7491
f995bbe8
PA
74922017-04-05 Pedro Alves <palves@redhat.com>
7493
7494 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
7495 * disasm.c (set_disassembler_options): Constify local.
7496 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
7497
4a596fe2
SDJ
74982017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
7499
7500 PR gdb/21352
7501 * tracefile.c (tsave_command): Fix argument parsing for '-r'
7502 option.
7503
2cad08ea
YQ
75042017-04-05 Yao Qi <yao.qi@linaro.org>
7505
7506 * frame.c (frame_unwind_register_unsigned): Call
7507 frame_unwind_register_value.
7508
55a98976
YQ
75092017-04-05 Yao Qi <yao.qi@linaro.org>
7510
7511 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
7512 Use gdb_test_multiple, and don't match anchor.
7513
4ac40124
PA
75142017-04-05 Pedro Alves <palves@redhat.com>
7515
7516 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
7517 (Write After Approval): Remove Simon Marchi.
7518
c053b654
PA
75192017-04-05 Pedro Alves <palves@redhat.com>
7520
7521 * common/gdb_optional.h (optional::optional): Make constexpr and
7522 initialize m_dummy.
7523
4c7bf4f9
JB
75242017-04-04 John Baldwin <jhb@FreeBSD.org>
7525
7526 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
7527 (amd64fbsd_jmp_buf_reg_offset): Remove.
7528 (amd64fbsd_supply_uthread): Remove function.
7529 (amd64fbsd_collect_uthread): Remove function.
7530 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
7531 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
7532 (x86_64-*-freebsd*): Remove bsd-uthread.o.
7533 (fbsd-nat.c): Update comment.
7534 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
7535 (i386fbsd_jmp_buf_reg_offset): Remove.
7536 (i386fbsd_supply_uthread): Remove function.
7537 (i386fbsd_collect_uthread): Remove function.
7538 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
7539
1e1a8bef
JB
75402017-04-04 John Baldwin <jhb@FreeBSD.org>
7541
7542 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
7543 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
7544 * NEWS: Mention that support for FreeBSD/alpha was removed.
7545 * alpha-fbsd-tdep.c: Delete file.
7546 * config/alpha/fbsd.mh: Delete file.
7547 * configure.host: Delete alpha*-*-freebsd* and
7548 alpha*-*-kfreebsd*-gnu.
7549 * configure.tgt: Delete alpha*-*-freebsd* and
7550 alpha*-*-kfreebsd*-gnu.
7551
49907934
JB
75522017-04-04 John Baldwin <jhb@FreeBSD.org>
7553
7554 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
7555 amd64bsd_store_inferior_registers): Use ptid from regcache.
7556
6f77053d
PA
75572017-04-04 Pedro Alves <palves@redhat.com>
7558
7559 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
7560 data fields, make them private and add "m_" prefixes.
7561 (lnp_state_machine::lnp_state_machine): New ctor.
7562 (record_line, check_line_address, handle_set_discriminator)
7563 (handle_set_address, handle_advance_pc, handle_special_opcode)
7564 (handle_advance_line, handle_set_file, handle_negate_stmt)
7565 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
7566 (end_sequence, advance_line): New methods.
7567 (m_gdbarch, m_record_lines_p): New fields.
7568 (lnp_reader_state): Delete.
7569 (dwarf_record_line): Rename to ...
7570 (lnp_state_machine::record_line): ... adjust.
7571 (init_lnp_state_machine): Delete.
7572 (lnp_state_machine::lnp_state_machine): New.
7573 (check_line_address): Rename to ...
7574 (lnp_state_machine::check_line_address): This.
7575 (dwarf_decode_lines_1): Remove reference to "reader_state".
7576 Adjust lnp_state_machine having a non-default ctor. Use bool.
7577 State machine internal state manipulation moved to
7578 lnp_state_machine methods.
7579
9c541725
PA
75802017-04-04 Pedro Alves <palves@redhat.com>
7581
7582 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7583 unittests/offset-type-selftests.c.
7584 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
7585 * common/offset-type.h: New file.
7586 * common/preprocessor.h: New file.
7587 * common/traits.h: New file.
7588 * common/valid-expr.h: New file.
7589 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
7590 sect_offset and cu_offset strong typedefs throughout.
7591 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
7592 typedefs throughout.
7593 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
7594 sect_offset and cu_offset strong typedefs throughout.
7595 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
7596 typedefs throughout.
7597 * gdbtypes.h: Include "common/offset-type.h".
7598 (cu_offset): Now an offset type (strong typedef) instead of a
7599 struct.
7600 (sect_offset): Likewise.
7601 (union call_site_parameter_u): Rename "param_offset" field to
7602 "param_cu_off".
7603 * unittests/offset-type-selftests.c: New file.
7604
ecfb656c
PA
76052017-04-04 Pedro Alves <palves@redhat.com>
7606
7607 * common/underlying.h: New file.
7608 * dwarf2read.c: Include "common/gdb_optional.h" and
7609 "common/underlying.h".
7610 (dir_index, file_name_index): New types.
7611 (file_entry): Use them.
7612 (file_entry::include): Use to_underlying.
7613 (line_header::add_file_name): Use dir_index.
7614 (read_formatted_entries): Use gdb::optional. Read form before
7615 writting to file_entry.
7616 (dwarf_decode_line_header): Use dir_index.
7617 (lnp_state_machine::current_file): Use to_underlying.
7618 (lnp_state_machine::file): Change type to file_name_index.
7619 (dwarf_record_line): Use to_underlying.
7620 (init_lnp_state_machine): Use file_name_index.
7621 (dwarf_decode_lines_1): Use dir_index and file_name_index.
7622
d194f1fe
PA
76232017-04-04 Pedro Alves <palves@redhat.com>
7624
7625 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
7626 operator bool, has_value and get methods.
7627
fff8551c
PA
76282017-04-04 Pedro Alves <palves@redhat.com>
7629
7630 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
7631 fields.
7632 (line_header): Initialize all data fields. Change type of
7633 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
7634 Change type of include_dirs to std::vector<const char *>. Remove
7635 num_include_dirs, include_dirs_size. Change type of file_names to
7636 std::vector<file_entry>. Remove num_file_names, file_names_size.
7637 (line_header::line_header): New.
7638 (line_header::add_include_dir, line_header::add_file_name): New
7639 methods.
7640 (line_header::include_dir_at): Remove NULL check.
7641 (line_header::file_name_at): Add const overload.
7642 (line_header_up): New unique_ptr typedef.
7643 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
7644 std::vector. Remove free_line_header call.
7645 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
7646 free_line_header call.
7647 (free_cu_line_header): Delete.
7648 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
7649 (setup_type_unit_groups): Use line_header_up instead of cleanups.
7650 Adjust to use std::vector.
7651 (free_line_header): Delete.
7652 (free_line_header_voidp): Use delete.
7653 (add_include_dir): Replace with ...
7654 (line_header::add_include_dir): ... this method. Use std::vector.
7655 (add_file_name): Replace with ...
7656 (line_header::add_file_name): ... this method. Use std::vector.
7657 (add_include_dir_stub): Delete.
7658 (read_formatted_entries): Remove memset.
7659 (dwarf_decode_line_header): Return a line_header_up instead of a
7660 raw pointer. Remove cleanup handling. Pass lambdas to
7661 read_formatted_entries. Adjust to use line_header methods.
7662 (dwarf_decode_lines_1): Adjust to use line_header methods.
7663 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
7664 use std::vector.
7665
d62a8ae2
SM
76662017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
7667
7668 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
7669 instead of struct ptid.
7670
db3a1dc7
AH
76712017-05-04 Alan Hayward <alan.hayward@arm.com>
7672
7673 * frame.c (get_frame_register_bytes): Unwind using value.
7674 (put_frame_register_bytes): Likewise.
7675
b1b45502
IB
76762017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
7677
7678 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
7679 aggregate-like.
7680
ec13808e
JK
76812017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
7682
7683 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
7684
12316564
YQ
76852017-03-29 Yao Qi <yao.qi@linaro.org>
7686
7687 * gdbthread.h (struct thread_info): Declare constructor and
7688 destructor. Add some in-class member initializers.
7689 * thread.c (free_thread): Remove.
7690 (init_thread_list): Call delete instead of free_thread.
7691 (new_thread): Call thread_info constructor.
7692 (thread_info::thread_info): New function.
7693 (thread_info::~thread_info): New function.
7694 (delete_thread_1): Call delete instead of free_thread.
7695 (make_cleanup_restore_current_thread): Move tp and frame to
7696 inner block.
7697
fe5f7374
AK
76982017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
7699
7700 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
7701 (arc_skip_prologue): Likewise.
7702 (arc_make_frame_cache): Likewise.
7703 (arc_pv_get_operand): New function.
7704 (arc_is_in_prologue): Likewise.
7705 (arc_analyze_prologue): Likewise.
7706 (arc_print_frame_cache): Likewise.
7707 (MAX_PROLOGUE_LENGTH): New constant.
7708
eea78757
AK
77092017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
7710
7711 * configure.tgt: Add arc-insn.o.
7712 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
7713 (dump_arc_instruction_command): New function.
7714 (arc_fprintf_disasm): Likewise.
7715 (arc_disassemble_info): Likewise.
7716 (arc_insn_get_operand_value): Likewise.
7717 (arc_insn_get_operand_value_signed): Likewise.
7718 (arc_insn_get_memory_base_reg): Likewise.
7719 (arc_insn_get_memory_offset): Likewise.
7720 (arc_insn_get_branch_target): Likewise.
7721 (arc_insn_dump): Likewise.
7722 (arc_insn_get_linear_next_pc): Likewise.
7723 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
7724 (arc_disassemble_info): Likewise.
7725 (arc_insn_get_branch_target): Likewise.
7726 (arc_insn_get_linear_next_pc): Likewise.
7727 * NEWS: Mention new "maint print arc arc-instruction".
7728
3be78afd
AK
77292017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
7730
7731 * arc-tdep (maintenance_print_arc_list): New variable.
7732 (maintenance_print_arc_command): New function.
7733
296ec4fa
AK
77342017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
7735
7736 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
7737 Add "limm" and "reserved".
7738 (arc_cannot_fetch_register, arc_cannot_store_register): Add
7739 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
7740 * arc-tdep.h (arc_regnum): Likewise.
7741
f74f865e
MF
77422017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7743
7744 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
7745 for THREADPTR register.
7746 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
7747 register.
7748 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
7749 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
7750 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
7751
0d0bf81a
MF
77522017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7753
7754 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
7755 registers above gdbarch_num_regs (gdbarch) as privileged in
7756 call0 ABI.
7757
0ce4291e
MF
77582017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7759
7760 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
7761 for a single specified register or for all registers in
7762 a0_base..a0_base + C0_NREGS range.
7763 (supply_gregset_reg): Call regcache_raw_supply for a single
7764 specified register or for all registers in a0_base..a0_base +
7765 C0_NREGS range.
7766
c56054f9
MF
77672017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7768
7769 * arch/xtensa.h (C0_NREGS): Add definition.
7770 * xtensa-tdep.c (C0_NREGS): Remove definition.
7771
a4398628
MF
77722017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7773
7774 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
7775 Drop xtensa_default_isa initialization.
7776 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
7777
8c43009f
PA
77782017-03-27 Pedro Alves <palves@redhat.com>
7779
7780 * dwarf2read.c (file_entry) <dir_index>: Add comment.
7781 (file_entry::include_dir): New method.
7782 (line_header::include_dir_at, line_header::file_name_at): New
7783 methods.
7784 (setup_type_unit_groups, setup_type_unit_groups)
7785 (psymtab_include_file_name): Simplify using the new methods.
7786 (lnp_state_machine) <the_line_header>: New field.
7787 <file>: Add comment.
7788 (lnp_state_machine::current_file): New method.
7789 (dwarf_record_line): Simplify using the new methods.
7790 (init_lnp_state_machine): Initialize the "the_line_header" field.
7791 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
7792 Simplify using the new methods.
7793
a7e80b9e
PA
77942017-03-27 Pedro Alves <palves@redhat.com>
7795
7796 * cp-name-parser.y (make_empty): Delete.
7797 (demangler_special, nested_name, ptr_operator, array_indicator)
7798 (direct_declarator, declarator_1): Use fill_comp instead of
7799 make_empty.
7800
21047726
PA
78012017-03-27 Pedro Alves <palves@redhat.com>
7802
7803 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
7804 to ATTRIBUTE_PRINTF.
7805 * solib-target.c (library_list_start_list): Print "string" not
7806 "version".
7807 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
7808 gdb_xml_error call.
7809
d721ba37
PA
78102017-03-27 Pedro Alves <palves@redhat.com>
7811
7812 * dwarf2read.c (struct file_and_directory): New.
7813 (dwarf2_get_dwz_file): Adjust to use std::string.
7814 (dw2_get_file_names_reader): Adjust to use file_and_directory.
7815 (find_file_and_directory): Adjust to return a file_and_directory
7816 object.
7817 (read_file_scope): Adjust to use file_and_directory. Remove
7818 make_cleanup/do_cleanups calls.
7819 (open_and_init_dwp_file): Adjust to use std::string. Remove
7820 make_cleanup/do_cleanups calls.
7821 * python/python.c (do_start_initialization): Adjust to ldirname
7822 returning a std::string.
7823 * utils.c (ldirname): Now returns a std::string.
7824 * utils.h (ldirname): Change return type to std::string.
7825 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
7826 returning a std::string.
7827 * xml-tdesc.c (file_read_description_xml): Likewise.
7828
ed771251
AH
78292017-03-24 Alan Hayward <alan.hayward@arm.com>
7830
7831 * regcache.c (regcache_debug_print_register): New function.
7832 * regcache.h (regcache_debug_print_register): New declaration.
7833 * target.c (debug_print_register): Remove.
7834 (target_fetch_registers): Call regcache_debug_print_register.
7835 (target_store_registers): Likewise.
7836
568c1b9f
PB
78372017-03-24 Pádraig Brady <pbrady@fb.com>
7838
7839 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
7840 reference beyond the 'lh->include_dirs' array before accessing to
7841 it.
7842 (psymtab_include_file_name): Likewise.
7843 (dwarf_decode_lines_1): Likewise.
7844 (dwarf_decode_lines): Likewise.
7845 (file_file_name): Likewise.
7846
3e00d44f
SM
78472017-03-23 Simon Marchi <simon.marchi@ericsson.com>
7848
7849 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
7850 inferior_ptid.
7851 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
7852 ps_lsetfpregs): Likewise.
7853 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
7854 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
7855 ps_lsetfpregs): Likewise.
7856 * target.c (target_fetch_registers, target_store_registers):
7857 Remove asserts.
7858
077ae656
AH
78592017-03-23 Alan Hayward <alan.hayward@arm.com>
7860
7861 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
7862
1e2b521d
YQ
78632017-03-23 Yao Qi <yao.qi@linaro.org>
7864
7865 * aarch64-tdep.c (aarch64_process_record_test): Declare.
7866 (_initialize_aarch64_tdep): Register it.
7867 (aarch64_record_load_store): Handle PRFM instruction.
7868 (aarch64_process_record_test): New function.
7869
33877125
YQ
78702017-03-23 Yao Qi <yao.qi@linaro.org>
7871
7872 * aarch64-tdep.c (aarch64_record_load_store): Fix code
7873 indentation.
7874
a0eef940
YQ
78752017-03-23 Yao Qi <yao.qi@linaro.org>
7876
7877 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
7878
3f2a3564
PR
78792017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
7880
7881 python/python.c (do_start_initialization): Fix memory leak.
7882
b67aeab0
SM
78832017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
7884
7885 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
7886 using get_ptrace_pid.
7887 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
7888 inferior_ptid.
7889 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
7890 inferior_ptid instead of pid.
7891
ffdbe864
YQ
78922017-03-22 Yao Qi <yao.qi@linaro.org>
7893
7894 * aarch64-tdep.c: Wrap locally used classes in anonymous
7895 namespace.
7896 * arm-tdep.c: Likewise.
7897 * linespec.c: Likewise.
7898 * ui-out.c: Likewise.
7899
9d736fbf
JG
79002017-03-22 Jonah Graham <jonah@kichwacoders.com>
7901
7902 PR gdb/19637
7903 * python/lib/gdb/printer/bound_registers.py: Import sys.
7904
3de88e9a
SM
79052017-03-21 Simon Marchi <simon.marchi@ericsson.com>
7906
7907 * windows-nat.c (do_windows_fetch_inferior_registers): Add
7908 windows_thread_info parameter and use it instead of
7909 current_thread.
7910 (windows_fetch_inferior_registers): Don't set current_thread,
7911 pass the thread to do_windows_fetch_inferior_registers. Use
7912 ptid from regcache instead of inferior_ptid.
7913 (do_windows_store_inferior_registers): Add windows_thread_info
7914 parameter and use it instead of current_thread.
7915 (windows_store_inferior_registers): Don't set current_thread,
7916 pass the thread to do_windows_store_inferior_registers. Use
7917 ptid from regcache instead of inferior_ptid.
7918
0e7b8f61
SM
79192017-03-21 Simon Marchi <simon.marchi@ericsson.com>
7920
7921 * ser-mingw.c (ser_windows_raw): Remove reference to
7922 struct serial::current_timeout.
7923
5badf10a
IR
79242017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
7925
7926 PR tdep/20928
7927 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
7928 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
7929 (sparc64_fsr_type): Fix %fsr decoding.
7930
cee59b3f
TW
79312017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
7932
7933 * python/py-record-btrace.c (btpy_insn_data): Change return type
7934 for Python 2.
7935
639a9038
SM
79362017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
7937
7938 * spu-linux-nat.c (spu_fetch_inferior_registers,
7939 spu_store_inferior_registers): Use ptid from regcache, set and
7940 restore inferior_ptid.
7941 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
7942 Likewise.
7943
bcc0c096
SM
79442017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
7945
7946 * i386-linux-nat.c (fetch_register, store_register,
7947 i386_linux_fetch_inferior_registers,
7948 i386_linux_store_inferior_registers): Use ptid from regcache.
7949 * ia64-linux-nat.c (ia64_linux_fetch_register,
7950 ia64_linux_store_register): Likewise.
7951 * inf-ptrace.c (inf_ptrace_fetch_register,
7952 inf_ptrace_store_register): Likewise.
7953 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
7954 m32r_linux_store_inferior_registers): Likewise.
7955 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
7956 m68kbsd_store_inferior_registers): Likewise.
7957 * m68k-linux-nat.c (fetch_register, store_register,
7958 m68k_linux_fetch_inferior_registers,
7959 m68k_linux_store_inferior_registers): Likewise.
7960 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
7961 m88kbsd_store_inferior_registers): Likewise.
7962 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
7963 mips_fbsd_store_inferior_registers): Likewise.
7964 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
7965 mips64_linux_regsets_store_registers): Likewise.
7966 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
7967 mipsnbsd_store_inferior_registers): Likewise.
7968 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
7969 mips64obsd_store_inferior_registers): Likewise.
7970 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
7971 Likewise.
7972 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
7973 ppcfbsd_store_inferior_registers): Likewise.
7974 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
7975 ppc_linux_store_inferior_registers): Likewise.
7976 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
7977 ppcnbsd_store_inferior_registers): Likewise.
7978 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
7979 ppcobsd_store_registers): Likewise.
7980 * procfs.c (procfs_fetch_registers, procfs_store_registers):
7981 Likewise.
7982 * ravenscar-thread.c (ravenscar_fetch_registers,
7983 ravenscar_store_registers, ravenscar_prepare_to_store):
7984 Likewise.
7985 * record-btrace.c (record_btrace_fetch_registers,
7986 record_btrace_store_registers, record_btrace_prepare_to_store):
7987 Likewise.
7988 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
7989 Lookup inferior using ptid from regcache, instead of
7990 current_inferior.
7991 * remote.c (remote_fetch_registers, remote_store_registers): Use
7992 ptid from regcache.
7993 * rs6000-nat.c (fetch_register, store_register): Likewise.
7994 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
7995 s390_linux_store_inferior_registers): Likewise.
7996 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
7997 shnbsd_store_inferior_registers): Likewise.
7998 * sol-thread.c (sol_thread_fetch_registers,
7999 sol_thread_store_registers): Likewise.
8000 * sparc-nat.c (sparc_fetch_inferior_registers,
8001 sparc_store_inferior_registers): Likewise.
8002 * tilegx-linux-nat.c (fetch_inferior_registers,
8003 store_inferior_registers): Likewise.
8004 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
8005 vaxbsd_store_inferior_registers): Likewise.
8006 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
8007 store_xtregs): Likewise.
8008
c0f55cc6
AV
80092017-03-20 Artemiy Volkov <artemiyv@acm.org>
8010
8011 PR gdb/14441
8012 * NEWS: Mention support for rvalue references in GDB and python.
8013 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
8014 supports both lvalue and rvalue references.
8015
15c0a2a9
AV
80162017-03-20 Artemiy Volkov <artemiyv@acm.org>
8017
8018 PR gdb/14441
8019 * gdbtypes.c (rank_one_type): Implement overloading
8020 resolution rules regarding rvalue references.
8021
aa006118
AV
80222017-03-20 Artemiy Volkov <artemiyv@acm.org>
8023
8024 PR gdb/14441
8025 * aarch64-tdep.c (aarch64_type_align)
8026 (aarch64_extract_return_value, aarch64_store_return_value): Change
8027 lvalue reference type checks to general reference type checks.
8028 * amd64-tdep.c (amd64_classify): Likewise.
8029 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
8030 Likewise.
8031 * arm-tdep.c (arm_type_align, arm_extract_return_value)
8032 (arm_store_return_value): Likewise.
8033 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
8034 * c-typeprint.c (c_print_type): Likewise.
8035 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
8036 (cplus_number_of_children, cplus_describe_child): Likewise.
8037 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
8038 * completer.c (expression_completer): Likewise.
8039 * cp-support.c (make_symbol_overload_list_adl_namespace):
8040 Likewise.
8041 * darwin-nat-info.c (info_mach_region_command): Likewise.
8042 * dwarf2loc.c (entry_data_value_coerce_ref)
8043 (value_of_dwarf_reg_entry): Likewise.
8044 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
8045 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
8046 Likewise.
8047 * findvar.c (extract_typed_address, store_typed_address):
8048 Likewise.
8049 * gdbtypes.c (rank_one_type): Likewise.
8050 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
8051 * infcall.c (value_arg_coerce): Likewise.
8052 * language.c (pointer_type): Likewise.
8053 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
8054 Likewise.
8055 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
8056 * mn10300-tdep.c (mn10300_type_align): Likewise.
8057 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
8058 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
8059 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
8060 Likewise.
8061 * printcmd.c (print_formatted, x_command): Likewise.
8062 * python/py-type.c (typy_get_composite, typy_template_argument):
8063 Likewise.
8064 * python/py-value.c (valpy_referenced_value)
8065 (valpy_get_dynamic_type, value_has_field): Likewise.
8066 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
8067 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
8068 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
8069 * spu-tdep.c (spu_scalar_value_p): Likewise.
8070 * symtab.c (lookup_symbol_aux): Likewise.
8071 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
8072 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
8073 Likewise.
8074 * valops.c (value_cast_pointers, value_cast)
8075 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
8076 (value_struct_elt, value_struct_elt_bitpos)
8077 (value_find_oload_method_list, find_overload_match)
8078 (value_rtti_indirect_type): Likewise.
8079 * valprint.c (val_print_scalar_type_p, generic_val_print):
8080 Likewise.
8081 * value.c (value_actual_type, value_as_address, unpack_long)
8082 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
8083 (coerce_ref): Likewise.
8084 * varobj.c (varobj_get_value_type): Likewise.
8085
3fcf899d
AV
80862017-03-20 Artemiy Volkov <artemiyv@acm.org>
8087
8088 PR gdb/14441
8089 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
8090 table of constants.
8091 * python/lib/gdb/command/explore.py: Support exploring values
8092 of rvalue reference types.
8093 * python/lib/gdb/types.py: Implement get_basic_type() for
8094 rvalue reference types.
8095 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
8096 constant.
8097 * python/py-value.c (valpy_getitem): Add an rvalue reference
8098 check.
8099 (valpy_reference_value): Add new parameter "refcode".
8100 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
8101 New wrappers for valpy_reference_value().
8102 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
8103 (gdbpy_invoke_xmethod): Likewise.
8104
4297a3f0
AV
81052017-03-20 Artemiy Volkov <artemiyv@acm.org>
8106
8107 PR gdb/14441
8108 * dwarf2read.c (process_die, read_type_die_1): Handle the
8109 DW_TAG_rvalue_reference_type DIE.
8110 (read_tag_reference_type): Add new parameter "refcode".
8111
e1cb3213
AV
81122017-03-20 Artemiy Volkov <artemiyv@acm.org>
8113
8114 PR gdb/14441
8115 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
8116 (c_type_print_modifier, c_type_print_varspec_suffix)
8117 (c_type_print_base): Support printing rvalue reference types.
8118 * c-valprint.c (c_val_print, c_value_print): Support printing
8119 rvalue reference values.
8120
e4347c89
AV
81212017-03-20 Artemiy Volkov <artemiyv@acm.org>
8122
8123 PR gdb/14441
8124 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
8125 typename.
8126 * cp-support.c (replace_typedefs): Handle
8127 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
8128 * python/py-type.c (typy_lookup_type): Likewise.
8129
53cc15f5
AV
81302017-03-20 Artemiy Volkov <artemiyv@acm.org>
8131
8132 PR gdb/14441
8133 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
8134 * parse.c (insert_type): Change assert statement.
8135 (follow_types): Handle rvalue reference types.
8136 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
8137 constant.
8138
a65cfae5
AV
81392017-03-20 Artemiy Volkov <artemiyv@acm.org>
8140
8141 PR gdb/14441
8142 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
8143 value_ref() interface.
8144 * c-valprint.c (c_value_print): Likewise.
8145 * infcall.c (value_arg_coerce): Likewise.
8146 * python/py-value.c (valpy_reference_value): Likewise.
8147 * valops.c (value_cast, value_reinterpret_cast)
8148 (value_dynamic_cast, typecmp): Likewise.
8149 (value_ref): Parameterize by kind of return value reference type.
8150 * value.h (value_ref): Add new parameter "refcode".
8151
3b224330
AV
81522017-03-20 Artemiy Volkov <artemiyv@acm.org>
8153
8154 PR gdb/14441
8155 * dwarf2read.c (read_tag_reference_type): Use
8156 lookup_lvalue_reference_type() instead of lookup_reference_type().
8157 * eval.c (evaluate_subexp_standard): Likewise.
8158 * f-exp.y: Likewise.
8159 * gdbtypes.c (make_reference_type, lookup_reference_type):
8160 Generalize with rvalue reference types.
8161 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
8162 convenience wrappers for lookup_reference_type().
8163 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
8164 reference kind parameter.
8165 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
8166 wrappers for lookup_reference_type().
8167 * guile/scm-type.c (gdbscm_type_reference): Use
8168 lookup_lvalue_reference_type() instead of lookup_reference_type().
8169 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
8170 * parse.c (follow_types): Likewise.
8171 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
8172 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
8173 Likewise.
8174 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
8175 (gdbpy_invoke_xmethod): Likewise.
8176 * stabsread.c: Provide extra argument to make_reference_type()
8177 call.
8178 * valops.c (value_ref, value_rtti_indirect_type): Use
8179 lookup_lvalue_reference_type() instead of lookup_reference_type().
8180
f9aeb8d4
AV
81812017-03-20 Artemiy Volkov <artemiyv@acm.org>
8182
8183 PR gdb/14441
8184 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
8185 (TYPE_IS_REFERENCE): New macro.
8186 (struct type): Add rvalue_reference_type field.
8187 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
8188
51457a05
MAL
81892017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
8190
8191 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
8192 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
8193 New function definition.
8194 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
8195 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
8196 New function declaration.
8197 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
8198 * mi/mi-interp.h: New file.
8199 * solib.c (info_sharedlibrary_command): Replace for loop with
8200 ALL_SO_LIBS macro
8201 * solib.h (update_solib_list): New function declaration.
8202 (so_list_head): Move macro.
8203 * solist.h (ALL_SO_LIBS): New macro.
8204
e696b3ad
MAL
82052017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
8206
8207 * infcmd.c (post_create_inferior): Remove unused argument in
8208 call to solib_add.
8209 * remote.c (remote_start_remote): Likewise.
8210 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
8211 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
8212 (enable_break): Likewise.
8213 * solib.c (update_solib_list): Remove unused target argument
8214 and its documentation.
8215 (solib_add): Remove unused target argument. Remove unused
8216 argument in call to update_solib_list.
8217 (info_sharedlibrary_command): Remove unused argument in call
8218 to update_solib_list.
8219 (sharedlibrary_command): Remove unused argument in call to
8220 solib_add.
8221 (handle_solib_event): Likewise.
8222 (reload_shared_libraries): Likewise.
8223 * solib.h (solib_add): Remove unused target argument.
8224
dcb84eda
AA
82252017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
8226
8227 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
8228 (s390_displaced_step_fixup): Cover relative branches with the
8229 default fixup handling. This fixes lack of support for some
8230 relative branch instructions.
8231
d9cb6cdc
SM
82322017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
8233
8234 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
8235 ptid from regcache.
8236
1afaf9f4
SM
82372017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
8238
8239 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
8240 i386_darwin_store_inferior_registers): Use ptid from regcache.
8241
aac12e24
SM
82422017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
8243
8244 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
8245 i386bsd_store_inferior_registers): Use ptid from regcache.
8246
bbe1eef1
SM
82472017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
8248
8249 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
8250 hppaobsd_store_registers): Use ptid from regcache.
8251
10799020
SM
82522017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
8253
8254 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
8255 hppanbsd_store_registers): Use ptid from regcache.
8256
00204cf7
SM
82572017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
8258
8259 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
8260 from regcache. Use get_ptrace_pid.
8261
11a33714
SM
82622017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
8263
8264 * corelow.c (get_core_register_section): Use ptid from regcache,
8265 update doc.
8266
317cd492
SM
82672017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
8268
8269 * bsd-uthread.c (bsd_uthread_fetch_registers,
8270 bsd_uthread_store_registers): Use ptid from regcache, set and
8271 restore inferior_ptid.
8272
9ac8a7c2
SM
82732017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
8274
8275 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
8276 fetch_fp_regs, store_register, store_regs, store_fp_register,
8277 store_fp_regs): Use ptid from regcache.
8278
4ac4bb6a
SM
82792017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
8280
8281 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
8282 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
8283 store_vfp_regs): Use ptid from regcache.
8284
9bcbdca8
PA
82852017-03-17 Pedro Alves <palves@redhat.com>
8286
8287 PR remote/21188
8288 * ser-base.c (ser_base_wait_for): Add comment.
8289 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
8290 version.
8291 * ser-unix.c (hardwire_raw): Remove reference to
8292 scb->current_timeout.
8293 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
8294 (hardwire_ops): Install ser_base_readchar instead of
8295 hardwire_readchar.
8296 * serial.h (struct serial) <current_timeout, timeout_remaining>:
8297 Remove fields.
8298
7503099f
JG
82992017-03-17 Jonah Graham <jonah@kichwacoders.com>
8300
8301 PR gdb/19637
8302 * python/lib/gdb/printer/bound_registers.py: Add support for
8303 Python 3.
8304
7942e96e
AA
83052017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
8306
8307 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
8308 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
8309 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
8310 byte_offset to subobj_byte_offset. Fix the handling of
8311 DWARF_VALUE_STACK on big-endian targets when coming via an
8312 implicit pointer.
8313 (dwarf2_evaluate_loc_desc): Adjust call to
8314 dwarf2_evaluate_loc_desc_full.
8315 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
8316 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
8317
ba14f379
YQ
83182017-03-16 Yao Qi <yao.qi@linaro.org>
8319
8320 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
8321 and REVSH instructions.
8322
b121eeb9
YQ
83232017-03-16 Yao Qi <yao.qi@linaro.org>
8324
8325 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
8326 (arm_record_test): Declare.
8327 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
8328 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
8329 align with the manual.
8330 (thumb_record_misc): Adjust the code order to align with the
8331 manual.
8332 (thumb2_record_decode_insn_handler): Fix instruction matching.
8333 (instruction_reader_thumb): New class.
8334 (arm_record_test): New function.
8335
728a7913
YQ
83362017-03-16 Yao Qi <yao.qi@linaro.org>
8337
8338 * arm-tdep.c (abstract_memory_reader): New class.
8339 (instruction_reader): New class.
8340 (extract_arm_insn): Add argument 'reader'. Callers updated.
8341 (decode_insn): Likewise.
8342
34b43320
DE
83432017-03-16 Doug Evans <dje@google.com>
8344
a7c0469f
DE
8345 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
8346 member. Change type of TYPE member to SCM. All uses updated.
8347 (lsscm_make_lazy_string_smob): Add assert.
8348 (lsscm_make_lazy_string): Flag bad length values.
8349 (lsscm_elt_type): New function.
8350 (gdbscm_lazy_string_to_value): Rewrite to use
8351 lsscm_safe_lazy_string_to_value.
8352 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
8353 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
8354 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
8355 in incoming type.
8356 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
8357 * guile/scm-type.c (tyscm_scm_to_type): New function.
8358
83592017-03-15 Doug Evans <dje@google.com>
8360
34b43320
DE
8361 PR python/17728, python/18439, python/18779
8362 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
8363 member. Change type of TYPE member to PyObject *. All uses updated.
8364 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
8365 (gdbpy_create_lazy_string_object): Flag bad length values.
8366 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
8367 Handle typedefs in incoming type.
8368 (stpy_lazy_string_elt_type): New function.
8369 (gdbpy_extract_lazy_string): Call it.
8370 * python/py-value.c (valpy_lazy_string): Flag bad length values.
8371 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
8372 typedefs in incoming type.
8373
a3a5fecc
DE
83742017-03-16 Doug Evans <dje@google.com>
8375
8376 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
8377 * guile/scm-type.c (tyscm_scm_to_type): New function.
8378
28f1c605
JW
83792017-03-16 Jiong Wang <jiong.wang@arm.com>
8380
8381 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
8382 "ULONGEST" for "skip".
8383
87c336f6
AA
83842017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
8385
8386 PR gdb/21220
8387 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
8388 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
8389 (inf_ptrace_peek_poke): ...here. New function. Now also loop
8390 over ptrace peek/poke until end of buffer or error.
8391
cf81cf60
SM
83922017-03-14 Simon Marchi <simon.marchi@ericsson.com>
8393
8394 * parse.c (length_of_subexp): Make static.
8395 * parser-defs.h (length_of_subexp): Remove.
8396
a379284a
AA
83972017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
8398
8399 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
8400 as well.
8401
8a6200ba
PA
84022017-03-14 Pedro Alves <palves@redhat.com>
8403
8404 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
8405 (main): Use std::unique_ptr. Remove calls to
8406 cp_demangled_name_parse_free.
8407
f79ec206
SM
84082017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
8409
8410 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
8411 alphabsd_store_inferior_registers): Use regcache->ptid instead
8412 of inferior_ptid.
8413
edb5fb00
SM
84142017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
8415
8416 * aix-thread.c (aix_thread_fetch_registers,
8417 aix_thread_store_registers): Use regcache->ptid instead of
8418 inferior_ptid.
8419
55119686
SM
84202017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
8421
8422 * aarch64-linux-nat.c (fetch_gregs_from_thread,
8423 store_gregs_to_thread, fetch_fpregs_from_thread,
8424 store_fpregs_to_thread): Use regcache->ptid instead of
8425 inferior_ptid.
8426
6a06fbb7
SM
84272017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
8428
8429 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
8430 amd64_linux_fetch_inferior_registers): Use regcache->ptid
8431 instead of inferior_ptid.
8432
c6386875
SM
84332017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
8434
8435 * target.c (target_fetch_registers, target_store_registers): Add
8436 assert.
8437
ddaaf0fb
SM
84382017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
8439
8440 * regcache.h (regcache_get_ptid): New function.
8441 * regcache.c (regcache_get_ptid): New function.
8442
b9da89d1 84432017-03-13 Mark Wielaard <mark@klomp.org>
8444
8445 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
8446
5f4d1085
KS
84472017-03-10 Keith Seitz <keiths@redhat.com>
8448
8449 PR c++/8218
8450 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
8451
c65d6b55
PA
84522017-03-08 Pedro Alves <palves@redhat.com>
8453
8454 PR gdb/18360
8455 * infrun.c (start_step_over, do_target_resume, resume)
8456 (restart_threads): Assert we're not resuming a thread that is
8457 meant to be stopped.
8458 (infrun_thread_stop_requested_callback): Delete.
8459 (infrun_thread_stop_requested): If the thread is internally
8460 stopped, queue a pending stop event and clear the thread's
8461 inline-frame state.
8462 (handle_stop_requested): New function.
8463 (handle_syscall_event, handle_inferior_event_1): Use
8464 handle_stop_requested.
8465 (handle_stop_requested): New function.
8466 (handle_signal_stop): Set the thread's stop_signal here instead of
8467 at caller.
8468 (finish_step_over): Clear step over info unconditionally.
8469 (handle_signal_stop): If the user had interrupted the event
8470 thread, consider the stop a random signal.
8471 (handle_signal_stop) <signal arrived while stepping over
8472 breakpoint>: Don't restart threads here.
8473 (stop_waiting): Don't clear step-over info here.
8474
15c22686
PA
84752017-03-08 Pedro Alves <palves@redhat.com>
8476
8477 PR 21206
8478 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
8479 goes to argument 2, not 1.
8480
6e5d74e7
PA
84812017-03-08 Pedro Alves <palves@redhat.com>
8482
8483 PR cli/21218
8484 * top.c (gdb_readline_wrapper): Avoid passing NULL to
8485 display_gdb_prompt.
8486 (command_line_input): Add comment.
8487
9753a2f6
PA
84882017-03-08 Pedro Alves <palves@redhat.com>
8489
8490 PR tui/21216
8491 * tui/tui-file.c (tui_file::write): New.
8492 * tui/tui-file.h (tui_file): Override "write".
8493 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
8494 factored out from ...
8495 (tui_puts): ... here.
8496 (tui_putc): Use them.
8497 (tui_write): New function.
8498 * tui/tui-io.h (tui_write): Declare.
8499
1672e0d9
SDJ
85002017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
8501
8502 * Makefile.in (SFILES): Replace "environ.c" with
8503 "common/environ.c".
8504 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
8505 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
8506 to...
8507 * common/environ.c: ... here.
8508 * environ.h: Moved to...
8509 * common/environ.h: ... here.
8510
f7bb4e3a
PB
85112017-03-07 Peter Bergner <bergner@vnet.ibm.com>
8512
8513 * gdbarch.sh (pstring_ptr): New static function.
8514 (gdbarch_disassembler_options): Use it.
8515 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
8516 not valid_disassembler_option->name.
8517 * gdbarch.c: Regenerate.
8518
e45ced6c
PB
85192017-03-07 Peter Bergner <bergner@vnet.ibm.com>
8520
8521 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
8522
5f6fd321
PA
85232017-03-07 Pedro Alves <palves@redhat.com>
8524
8525 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
8526
6dbb839a 85272017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
4a612d6f
WT
8528
8529 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
8530 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
8531 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
6dbb839a 8532 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
4a612d6f 8533
d274ecf4
SM
85342017-03-06 Simon Marchi <simon.marchi@ericsson.com>
8535
8536 * xtensa-linux-nat.c (fetch_gregs): Remove const.
8537
df97be55
SM
85382017-03-03 Simon Marchi <simon.marchi@ericsson.com>
8539
8540 * remote.c (remote_add_target_side_commands): Use range-based
8541 for loop.
8542
7d45f3df
YQ
85432017-03-03 Yao Qi <yao.qi@linaro.org>
8544
8545 PR gdb/21165
8546 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
8547 value is lazy.
8548 * valprint.c (common_val_print): Likewise.
8549
65b48a81
PB
85502017-02-28 Peter Bergner <bergner@vnet.ibm.com>
8551
8552 * NEWS: Mention new set/show disassembler-options commands.
8553 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
8554 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
8555 (prospective_options): New static variable.
8556 (gdb_disassembler::gdb_disassembler): Initialize
8557 m_di.disassembler_options.
8558 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
8559 (get_disassembler_options): New function.
8560 (set_disassembler_options): Likewise.
8561 (set_disassembler_options_sfunc): Likewise.
8562 (show_disassembler_options_sfunc): Likewise.
8563 (disassembler_options_completer): Likewise.
8564 (_initialize_disasm): Likewise.
8565 * disasm.h (get_disassembler_options): New prototype.
8566 (set_disassembler_options): Likewise.
8567 * gdbarch.sh (gdbarch_disassembler_options): New variable.
8568 (gdbarch_verify_disassembler_options): Likewise.
8569 * gdbarch.c: Regenerate.
8570 * gdbarch.h: Likewise.
8571 * arm-tdep.c (num_disassembly_options): Delete.
8572 (set_disassembly_style): Likewise.
8573 (arm_disassembler_options): New static variable.
8574 (set_disassembly_style_sfunc): Convert short style name into long
8575 option name. Call set_disassembler_options.
8576 (show_disassembly_style_sfunc): New function.
8577 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
8578 set_gdbarch_verify_disassembler_options.
8579 (_initialize_arm_tdep): Delete regnames variable and update callers.
8580 (arm_disassembler_options): Initialize.
8581 (disasm_options): New variable.
8582 (num_disassembly_options): Rename from this...
8583 (num_disassembly_styles): ...to this. Compute by scanning through
8584 disasm_options.
8585 (valid_disassembly_styles): Initialize using disasm_options.
8586 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
8587 set_arm_regname_option.
8588 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
8589 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
8590 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
8591 set_gdbarch_verify_disassembler_options.
8592 * s390-tdep.c (s390_disassembler_options): New static variable.
8593 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
8594 set_gdbarch_verify_disassembler_options.
8595
d538e36d
SM
85962017-02-27 Simon Marchi <simon.marchi@ericsson.com>
8597
8598 * remote.c (remote_add_target_side_condition): Remove "struct"
8599 keyword from range-based for loop.
8600
83621223
SM
86012017-02-27 Simon Marchi <simon.marchi@ericsson.com>
8602
8603 * remote.c (remote_add_target_side_condition): Use range-based
8604 for loop. Update comment.
8605
2123df0e
YQ
86062017-02-27 Yao Qi <yao.qi@linaro.org>
8607
8608 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
8609
8e368124
AH
86102017-02-26 Alan Hayward <alan.hayward@arm.com>
8611
8612 * regcache.c (regcache_raw_update): New function.
8613 (regcache_raw_read): Move code to regcache_raw_update.
8614 * regcache.h (regcache_raw_update): New declaration.
8615 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
8616
a49dd8dd
JK
86172017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
8618
8619 * dwarf2read.c (create_debug_type_hash_table): Initialize
8620 header.signature and header.type_offset_in_tu.
8621
34e4bae9
PA
86222017-02-24 Pedro Alves <palves@redhat.com>
8623
8624 * symtab.c (make_file_symbol_completion_list_1): Use
8625 add_symtab_completions.
8626
b0e4b369
AH
86272017-02-24 Alan Hayward <alan.hayward@arm.com>
8628
8629 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
8630
975c21ab
AH
86312017-02-24 Alan Hayward <alan.hayward@arm.com>
8632
8633 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
8634 I386_MAX_REGISTER_SIZE.
8635 (i386_pseudo_register_write): Likewise.
8636 (i386_process_record): Likewise.
8637 * i387-tdep.c (i387_supply_xsave): Likewise.
8638 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
8639 (store_register): Likewise.
8640
14bc53a8
PA
86412017-02-23 Pedro Alves <palves@redhat.com>
8642
8643 * ada-lang.c: Include "common/function-view.h".
8644 (ada_iterate_over_symbols): Adjust to use function_view as
8645 callback type.
8646 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
8647 (ada_make_symbol_completion_list): Use a lambda.
8648 (ada_exc_search_name_matches): Delete.
8649 (name_matches_regex): New.
8650 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
8651 * compile/compile-c-support.c: Include "common/function-view.h".
8652 (print_one_macro): Change prototype to accept a ui_file pointer.
8653 (write_macro_definitions): Use a lambda.
8654 * dwarf2read.c: Include "common/function-view.h".
8655 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
8656 (dw2_expand_symtabs_matching): Adjust to use function_view as
8657 callback type.
8658 * language.h: Include "common/function-view.h".
8659 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
8660 function_view as callback type.
8661 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
8662 * linespec.c: Include "common/function-view.h".
8663 (collect_info::add_symbol): New method.
8664 (struct symbol_and_data_callback, iterate_inline_only, struct
8665 symbol_matcher_data, iterate_name_matcher): Delete.
8666 (iterate_over_all_matching_symtabs): Adjust to use function_view
8667 as callback type and lambdas.
8668 (iterate_over_file_blocks): Adjust to use function_view as
8669 callback type.
8670 (decode_compound_collector): Now a class with private fields.
8671 (decode_compound_collector::release_symbols): New method.
8672 (collect_one_symbol): Rename to...
8673 (decode_compound_collector::operator()): ... this and adjust.
8674 (lookup_prefix_sym): decode_compound_collector construction bits
8675 move to decode_compound_collector ctor. Pass the
8676 decode_compound_collector object directly as callback. Remove
8677 cleanups and use decode_compound_collector::release_symbols
8678 instead.
8679 (symtab_collector): Now a class with private fields.
8680 (symtab_collector::release_symtabs): New method.
8681 (add_symtabs_to_list): Rename to...
8682 (symtab_collector::operator()): ... this and adjust.
8683 (collect_symtabs_from_filename): symtab_collector construction
8684 bits move to symtab_collector ctor. Pass the symtab_collector
8685 object directly as callback. Remove cleanups and use
8686 symtab_collector::release_symtabs instead.
8687 (collect_symbols): Delete.
8688 (add_matching_symbols_to_info): Use lambdas.
8689 * macrocmd.c (print_macro_callback): Delete.
8690 (info_macro_command): Use a lambda.
8691 (info_macros_command): Pass print_macro_definition as callable
8692 directly.
8693 (print_one_macro): Remove 'ignore' parameter.
8694 (macro_list_command): Adjust.
8695 * macrotab.c (macro_for_each_data::fn): Now a function_view.
8696 (macro_for_each_data::user_data): Delete field.
8697 (foreach_macro): Adjust to call the function_view.
8698 (macro_for_each): Adjust to use function_view as callback type.
8699 (foreach_macro_in_scope): Adjust to call the function_view.
8700 (macro_for_each_in_scope): Adjust to use function_view as callback
8701 type.
8702 * macrotab.h: Include "common/function-view.h".
8703 (macro_callback_fn): Declare a prototype instead of a pointer.
8704 Remove "user_data" parameter.
8705 (macro_for_each, macro_for_each_in_scope): Adjust to use
8706 function_view as callback type.
8707 * psymtab.c (partial_map_expand_apply)
8708 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
8709 Adjust to use function_view as callback type and to return bool.
8710 (psym_expand_symtabs_matching): Adjust to use function_view as
8711 callback types.
8712 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
8713 to use function_view as callback type and to return bool.
8714 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
8715 callback types.
8716 * symfile.c (expand_symtabs_matching): Adjust to use function_view
8717 as callback types.
8718 * symfile.h: Include "common/function-view.h".
8719 (expand_symtabs_file_matcher_ftype)
8720 (expand_symtabs_symbol_matcher_ftype)
8721 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
8722 return bool.
8723 (quick_symbol_functions::map_symtabs_matching_filename)
8724 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
8725 function_view as callback type and return bool.
8726 (expand_symtabs_matching): Adjust to use function_view as callback
8727 type.
8728 (maintenance_expand_name_matcher)
8729 (maintenance_expand_file_matcher): Delete.
8730 (maintenance_expand_symtabs): Use lambdas.
8731 * symtab.c (iterate_over_some_symtabs): Adjust to use
8732 function_view as callback types and return bool.
8733 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
8734 of a cleanup.
8735 (lookup_symtab_callback): Delete.
8736 (lookup_symtab): Use a lambda.
8737 (iterate_over_symbols): Adjust to use function_view as callback
8738 type.
8739 (struct search_symbols_data, search_symbols_file_matches)
8740 (search_symbols_name_matches): Delete.
8741 (search_symbols): Use a pair of lambdas.
8742 (struct add_name_data, add_macro_name, symbol_completion_matcher)
8743 (symtab_expansion_callback): Delete.
8744 (default_make_symbol_completion_list_break_on_1): Use lambdas.
8745 * symtab.h: Include "common/function-view.h".
8746 (iterate_over_some_symtabs): Adjust to use function_view as
8747 callback type and return bool.
8748 (iterate_over_symtabs): Adjust to use function_view as callback
8749 type.
8750 (symbol_found_callback_ftype): Remove 'data' parameter and return
8751 bool.
8752 (iterate_over_symbols): Adjust to use function_view as callback
8753 type.
8754
07e253aa
PA
87552017-02-23 Pedro Alves <palves@redhat.com>
8756
8757 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
8758 (%.o) <unittests/%.c>: New pattern.
8759 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
8760 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
8761 * common/function-view.h: New file.
8762 * unittests/function-view-selftests.c: New file.
8763 * configure: Regenerate.
8764
8eaf5320
SM
87652017-02-23 Simon Marchi <simon.marchi@ericsson.com>
8766
8767 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
8768 inferior_ptid.
8769 * go32-nat.c (go32_thread_alive): Likewise.
8770
38768751
YQ
87712017-02-23 Yao Qi <yao.qi@linaro.org>
8772
8773 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
8774 delete.
8775
0a8beaba
YQ
87762017-02-23 Yao Qi <yao.qi@linaro.org>
8777
8778 * varobj.c (varobj_clear_saved_item): Use delete instead of
8779 xfree.
8780 (update_dynamic_varobj_children): Likewise.
8781
58fdfd2c
JK
87822017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
8783
8784 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
8785
1b90b139
SM
87862017-02-21 Simon Marchi <simon.marchi@ericsson.com>
8787
8788 * common/enum-flags.h (enum_flags::enum_flags): Initialize
8789 m_enum_value to 0 in default constructor.
8790
2039d74e
EBM
87912017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
8792
8793 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
8794 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
8795 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
8796 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
8797 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
8798 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
8799 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
8800 IS_STORE_CONDITIONAL_INSN.
8801
7814882a
JK
88022017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
8803
8804 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
8805
0ae60b63
JK
88062017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
8807
8808 * NEWS (Changes since GDB 7.12): Add DWARF-5.
8809
0224619f
JK
88102017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
8811
8812 * dwarf2read.c (skip_one_die, read_attribute_value)
8813 (dwarf2_const_value_attr, dump_die_shallow)
8814 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
8815 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
8816
0af92d60
JK
88172017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
8818
8819 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
8820 (dwarf_parse_macro_header): Accept DWARF version 5.
8821 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
8822
216f72a1
JK
88232017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
8824
8825 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
8826 DW_AT_GNU_*.
8827 * common/common-exceptions.h (enum errors): Likewise.
8828 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
8829 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
8830 (dwarf_expr_context::execute_stack_op): Likewise.
8831 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
8832 Likewise.
8833 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
8834 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
8835 (show_entry_values_debug, call_site_to_target_addr)
8836 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
8837 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
8838 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
8839 (value_of_dwarf_block_entry, indirect_pieced_value)
8840 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
8841 (disassemble_dwarf_expression): Likewise.
8842 * dwarf2read.c (process_die, inherit_abstract_dies)
8843 (read_call_site_scope): Likewise.
8844 * gdbtypes.h (struct func_type, struct call_site_parameter)
8845 (struct call_site): Likewise.
8846 * stack.c (read_frame_arg): Likewise.
8847 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
8848
43988095
JK
88492017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
8850
8851 * defs.h (read_unsigned_leb128): New declaration.
8852 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
8853 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
8854 (dwarf2_find_location_expression): Call also
8855 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
8856 * dwarf2loc.h (dwarf2_version): New declaration.
8857 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
8858 rnglists.
8859 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
8860 .debug_rnglists.
8861 (struct dwop_section_names): Add loclists_dwo.
8862 (dwop_section_names): Add .debug_loclists.dwo.
8863 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
8864 (struct dwarf2_per_cu_data): Add dwarf_version.
8865 (struct dwo_sections): Add loclists.
8866 (struct attr_abbrev): Add implicit_const.
8867 (read_indirect_line_string): New declaration.
8868 (read_unsigned_leb128): Delete declaration.
8869 (rcuh_kind): New definition.
8870 (read_and_check_comp_unit_head): Change parameter
8871 is_debug_types_section to section_kind.
8872 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
8873 (read_comp_unit_head): Change parameter abfd to section, add parameter
8874 section_kind. Handle DWARF-5.
8875 (error_check_comp_unit_head): Accept also DWARF version 5.
8876 (read_and_check_comp_unit_head): Change parameter
8877 is_debug_types_section to section_kind.
8878 (read_and_check_type_unit_head): Delete function.
8879 (read_abbrev_offset): Handle DWARF-5.
8880 (create_debug_type_hash_table): Add parameter section_kind. Process
8881 only DW_UT_type. Use signature and type_offset_in_tu from struct
8882 comp_unit_head.
8883 (create_debug_types_hash_table): Update create_debug_type_hash_table
8884 caller.
8885 (create_all_type_units): Call create_debug_type_hash_table.
8886 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
8887 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
8888 caller.
8889 (skip_one_die): Handle DW_FORM_implicit_const.
8890 (dwarf2_rnglists_process): New function.
8891 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
8892 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
8893 (read_attribute_value): Handle DW_FORM_implicit_const,
8894 DW_FORM_line_strp.
8895 (read_attribute): Handle DW_FORM_implicit_const.
8896 (read_indirect_string_at_offset_from): New function from
8897 read_indirect_string_at_offset.
8898 (read_indirect_string_at_offset): Call
8899 read_indirect_string_at_offset_from.
8900 (read_indirect_line_string_at_offset): New function.
8901 (read_indirect_string): New function comment.
8902 (read_indirect_line_string): New function.
8903 (read_unsigned_leb128): Make it global.
8904 (dwarf2_string_attr): Handle DWARF-5.
8905 (add_include_dir_stub, read_formatted_entries): New functions.
8906 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
8907 Handle DWARF-5.
8908 (per_cu_header_read_in): Update read_comp_unit_head caller.
8909 (dwarf2_version): New function.
8910 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
8911 rnglists.
8912 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
8913 fields.
8914
22d2f3ab
JK
89152017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
8916
8917 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
8918
5f46c5a5
JK
89192017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
8920
8921 * dwarf2read.c (dwarf2_ranges_process): New function from
8922 dwarf2_ranges_read.
8923 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
8924 dwarf2_ranges_process.
8925
78d4d2c5
JK
89262017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
8927
8928 * dwarf2read.c (create_debug_type_hash_table): New function from
8929 create_debug_types_hash_table.
8930 (create_debug_types_hash_table): Call create_debug_type_hash_table.
8931 (create_all_type_units, open_and_init_dwo_file): Update
8932 create_debug_types_hash_table callers.
8933
1b076f25
SDJ
89342017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
8935
8936 PR gdb/16188
8937 * fork-child.c (trace_start_error): Fix thinko. va_end should
8938 refer to 'ap', not 'args'.
8939
0db8980c
SDJ
89402017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
8941 Pedro Alves <palves@redhat.com>
8942
8943 PR gdb/16188
8944 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
8945 calls succeeded.
8946 * fork-child.c (trace_start_error): New function.
8947 (trace_start_error_with_name): Likewise.
8948 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
8949 * inf-ptrace.c (inf_ptrace_me): Likewise.
8950 * inferior.h (trace_start_error): New prototype.
8951 (trace_start_error_with_name): Likewise.
8952
99e8a4f9
SDJ
89532017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
8954
8955 PR gdb/21164
8956 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
8957 NULL before using it.
8958 * symmisc.c (maintenance_print_symbols): Likewise.
8959 (maintenance_print_msymbols): Likewise.
8960
4e746bb6
TW
89612017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
8962
8963 * NEWS: Add record Python bindings entry.
8964
89652017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
8966
8967 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
8968 py-record-full.o.
8969 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
8970 * python/py-record-btrace.c, python/py-record-btrace.h,
8971 python/py-record-full.c, python/py-record-full.h: New file.
8972 * python/py-record.c: Add include for py-record-btrace.h and
8973 py-record-full.h.
8974 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
8975 recpy_instruction_history, recpy_function_call_history, recpy_begin,
8976 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
8977 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
8978 New definition.
8979 (gdbpy_initialize_btrace): New export.
8980 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
8981
89822017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
8983
8984 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
8985 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
8986 * python/py-record.c: New file.
8987 * python/python-internal.h (gdbpy_start_recording,
8988 gdbpy_current_recording, gdpy_stop_recording,
8989 gdbpy_initialize_record): New export.
8990 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
8991 (python_GdbMethods): Add gdbpy_start_recording,
8992 gdbpy_current_recording and gdbpy_stop_recording.
8993
89942017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
8995
8996 * record-btrace.c (record_btrace_record_method): New function.
8997 (init_record_btrace_ops): Initialize to_record_method.
8998 * record-full.c (record_full_record_method): New function.
8999 (init_record_full_ops, init_record_full_core_ops): Add
9000 record_full_record_method.
9001 * record.h (enum record_method): New enum.
9002 * target-debug.h (target_debug_print_enum_record_method: New define.
9003 * target-delegates.c: Regenerate.
9004 * target.c (target_record_method): New function.
9005 * target.h: Include record.h.
9006 (struct target_ops) <to_record_method>: New field.
9007 (target_record_method): New export.
9008
90092017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
9010
9011 * record.h (record_start, record_stop): New export.
9012 * record.c (record_start, record_stop): New function.
9013
90142017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
9015
9016 * btrace.c (btrace_fetch): Copy function call segments pointer
9017 into a vector.
9018 (btrace_clear): Clear the vector.
9019 (btrace_find_insn_by_number): Use binary search to find the correct
9020 function call segment.
9021 * btrace.h (brace_fun_p): New typedef.
9022 (struct btrace_thread_info) <functions>: New field.
9023
90242017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
9025
9026 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
9027 * btrace.c (btrace_decode_error): ... here. New function.
9028 * btrace.h (btrace_decode_error): New export.
9029
90302017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
9031
9032 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
9033 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
9034 btrace_find_insn_by_number): Remove special case for gaps.
9035 * btrace.h (btrace_insn_get_error): New export.
9036 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
9037 * record-btrace.c (btrace_insn_history): Print number for gaps.
9038 (record_btrace_info, record_btrace_goto): Handle gaps.
9039
3f77c769
TT
90402017-02-14 Tom Tromey <tom@tromey.com>
9041
9042 PR python/13598:
9043 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
9044 event.
9045 * python/py-evts.c (gdbpy_initialize_py_events): Add
9046 before_prompt registry.
9047 * python/py-events.h (events_object) <before_prompt>: New field.
9048
4c2c7ac6
MM
90492017-02-14 Markus Metzger <markus.t.metzger@intel.com>
9050
9051 * btrace.c (ftrace_new_switch): Preserve up link and flags.
9052
5cf30ebf
LM
90532017-02-13 Luis Machado <lgustavo@codesourcery.com>
9054
9055 * symfile (_initialize_symfile): Add usage text to the load command's
9056 help text.
9057
26a06916
SM
90582017-02-10 Simon Marchi <simon.marchi@ericsson.com>
9059
9060 * utils.c (defaulted_query): Don't query on secondary UIs.
9061
0b145e37
TT
90622017-02-10 Tom Tromey <tom@tromey.com>
9063
9064 * rust-lang.c (rust_get_disr_info): Remove unused variable.
9065
2d8365c4
TT
90662017-02-10 Tom Tromey <tom@tromey.com>
9067
9068 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
9069 "cleanup" local.
9070 * python/py-type.c (typy_legacy_template_argument): Remove
9071 unnecessary "cleanup" local.
9072
2bb8f231
TT
90732017-02-10 Tom Tromey <tom@tromey.com>
9074
9075 * python/python.c (do_start_initialization): New function, from
9076 _initialize_python.
9077 (_initialize_python): Call do_start_initialization.
9078 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
9079 goto.
9080
1bdfaf42
TT
90812017-02-10 Tom Tromey <tom@tromey.com>
9082
9083 * python/py-prettyprint.c (pretty_print_one_value): Use
9084 gdbpy_ref.
9085
88b6faea
TT
90862017-02-10 Tom Tromey <tom@tromey.com>
9087
9088 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
9089 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
9090 gdbpy_ref.
9091 * python/py-type.c (field_new): Use gdbpy_ref.
9092 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
9093 gdbpy_ref.
9094 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
9095 (py_free_pspace): Likewise.
9096 (pspace_to_pspace_object): Likewise.
9097 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
9098 (py_free_objfile): Likewise.
9099 (objfile_to_objfile_object): Likewise.
9100 * python/py-inferior.c (delete_thread_object): Use
9101 gdbpy_ref.
9102 (infpy_read_memory): Likewise.
9103 (py_free_inferior): Likewise.
9104 * python/py-evtregistry.c (create_eventregistry_object): Use
9105 gdbpy_ref.
9106 * python/py-event.c (create_event_object): Use gdbpy_ref.
9107
7780f186
TT
91082017-02-10 Tom Tromey <tom@tromey.com>
9109
9110 * python/py-ref.h (gdbpy_ref_policy): Now a template.
9111 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
9112 used.
9113 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
9114 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
9115 python/py-exitedevent.c, python/py-finishbreakpoint.c,
9116 python/py-framefilter.c, python/py-function.c,
9117 python/py-inferior.c, python/py-infevents.c,
9118 python/py-linetable.c, python/py-newobjfileevent.c,
9119 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
9120 python/py-signalevent.c, python/py-stopevent.c,
9121 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
9122 python/py-unwind.c, python/py-utils.c, python/py-value.c,
9123 python/py-varobj.c, python/py-xmethods.c, python/python.c,
9124 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
9125
d4b0bb18
TT
91262017-02-10 Tom Tromey <tom@tromey.com>
9127
9128 * ui-out.h (ui_out_emit_type): New class.
9129 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
9130 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
9131 and ui_out_emit_tuple.
9132 (enumerate_locals): Likewise.
9133 (py_mi_print_variables, py_print_locals, py_print_args): Use
9134 ui_out_emit_list.
9135 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
9136 ui_out_emit_list.
9137 * common/gdb_optional.h: New file.
9138
f67f945c
MG
91392017-02-10 Martin Galvan <martingalvan@sourceware.org>
9140
9141 * MAINTAINERS (Write After Approval): Update my e-mail address.
9142
18da0c51
MG
91432017-02-10 Martin Galvan <martingalvan@sourceware.org>
9144
9145 PR gdb/21122
9146 * breakpoint.c (_initialize_breakpoint): Update the help description
9147 of the 'commands' command to indicate that it takes a list argument.
9148
62c14536
SM
91492017-02-09 Simon Marchi <simon.marchi@ericsson.com>
9150
9151 * interps.c (current_interp_set_logging): Remove "return".
9152
ff6fa247
GB
91532017-02-09 Gary Benson <gbenson@redhat.com>
9154
9155 * symtab.c (add_symtab_completions): Prevent NULL pointer
9156 dereference.
9157
a474bd8e
PA
91582017-02-08 Pedro Alves <palves@redhat.com>
9159
9160 * interps.c (interp::interp): Remove reference to quiet_p.
9161 (interp_set): Make static. Remove dead "Switching to" output
9162 code.
9163 (interp_quiet_p, interp_set_quiet): Delete.
9164 (interpreter_exec_cmd): Don't set the interpreter quiet.
9165 * interps.h (interp_quiet_p): Make static.
9166 (class interp) <quiet_p>: Remove field
9167
3d7b173c
JG
91682017-02-08 Jerome Guitton <guitton@adacore.com>
9169
604c4576
JG
9170 * cli/cli-decode.c (find_command_name_length): Make it extern.
9171 * cli/cli-decode.h (find_command_name_length): Declare.
9172 * cli/cli-script.c (command_name_equals, line_first_arg):
9173 New functions.
9174 (process_next_line): Use cli-decode to parse command names.
9175 (build_command_line): Make args a constant pointer.
9176
91772017-02-08 Jerome Guitton <guitton@adacore.com>
6dbb839a 9178
3d7b173c
JG
9179 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
9180 Remove case-insensitive search.
9181
1291063d
JM
91822017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
9183
9184 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
9185 at the end of the line. Avoids an ARI warning.
9186
20b477a7
LM
91872017-02-06 Luis Machado <lgustavo@codesourcery.com>
9188
9189 * NEWS: Mention support for record/replay of Intel 64 rdrand and
9190 rdseed instructions.
9191 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
9192
3f7b46f2
IR
91932017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
9194
9195 PR tdep/20936
9196 Provide and use sparc32 and sparc64 target description XML files.
9197 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
9198 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
9199 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
9200 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
9201 * features/sparc/sparc32-solaris.xml: New file.
9202 * features/sparc/sparc64-solaris.xml: New file.
9203 * features/sparc/sparc32-solaris.c: Generated.
9204 * features/sparc/sparc64-solaris.c: Generated.
9205 * sparc-tdep.h: Account for differences in target descriptions.
9206 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
9207 (sparc32_register_type): Use target provided registers.
9208 (validate_tdesc_registers): New function.
9209 (sparc32_gdbarch_init): Use tdesc_has_registers.
9210 Set pseudoregister functions.
9211 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
9212 (sparc64_register_type): Use target provided registers.
9213 (sparc64_init_abi): Set pseudoregister functions.
9214
f0fd41c1
TT
92152017-02-03 Tom Tromey <tom@tromey.com>
9216
9217 PR rust/21097:
9218 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
9219 with a single member.
9220
d6f9b0fb
PA
92212017-02-03 Pedro Alves <palves@redhat.com>
9222
9223 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
9224 (cli_interp_base::~cli_interp_base): New.
9225 (cli_interp): New struct.
9226 (as_cli_interp): Cast the interp itself to cli_interp.
9227 (cli_interpreter_pre_command_loop): Rename to ...
9228 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
9229 parameter.
9230 (cli_interpreter_init): Rename to ...
9231 (cli_interp::init): ... this. Remove 'self' parameter. Use
9232 boolean. Make extern.
9233 (cli_interpreter_resume): Rename to ...
9234 (cli_interp::resume): ... this. Remove 'data' parameter. Make
9235 extern.
9236 (cli_interpreter_suspend): Rename to ...
9237 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
9238 extern.
9239 (cli_interpreter_exec): Rename to ...
9240 (cli_interp::exec): ... this. Remove 'data' parameter. Make
9241 extern.
9242 (cli_interpreter_supports_command_editing): Rename to ...
9243 (cli_interp_base::supports_command_editing): ... this. Remove
9244 'interp' parameter. Make extern.
9245 (cli_ui_out): Rename to ...
9246 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
9247 Make extern.
9248 (cli_set_logging): Rename to ...
9249 (cli_interp_base::set_logging): ... this. Remove 'interp'
9250 parameter. Make extern.
9251 (cli_interp_procs): Delete.
9252 (cli_interp_factory): Adjust to use "new".
9253 * cli/cli-interp.h: Include "interps.h".
9254 (struct cli_interp_base): New struct.
9255 * interps.c (struct interp): Delete. Fields moved to interps.h.
9256 (interp_new): Delete.
9257 (interp::interp, interp::~interp): New.
9258 (interp_set): Use bool, and return void. Assume the interpreter
9259 has suspend, init and resume methods, and that the all return
9260 void.
9261 (set_top_level_interpreter): interp_set returns void.
9262 (interp_ui_out): Adapt.
9263 (current_interp_set_logging): Adapt.
9264 (interp_data): Delete.
9265 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
9266 (interp_exec): Adapt.
9267 (top_level_interpreter_data): Delete.
9268 * interps.h (interp_init_ftype, interp_resume_ftype)
9269 (interp_suspend_ftype, interp_exec_ftype)
9270 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
9271 (class interp): New.
9272 (interp_new): Delete.
9273 (interp_set): Now returns void. Use bool.
9274 (interp_data, top_level_interpreter_data): Delete.
9275 * mi/mi-common.h: Include interps.h.
9276 (class mi_interp): Inherit from interp. Define a ctor. Declare
9277 init, resume, suspect, exec, interp_ui_out, set_logging and
9278 pre_command_loop methods.
9279 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
9280 (mi_interpreter_init): Rename to ...
9281 (mi_interp::init): ... this. Remove the 'interp' parameter, use
9282 bool, return void and make extern. Adjust.
9283 (mi_interpreter_resume): ... Rename to ...
9284 (mi_interp::resume): ... this. Remove the 'data' parameter,
9285 return void and make extern. Adjust.
9286 (mi_interpreter_suspend): ... Rename to ...
9287 (mi_interp::suspend): ... this. Remove the 'data' parameter,
9288 return void and make extern. Adjust.
9289 (mi_interpreter_exec): ... Rename to ...
9290 (mi_interp::exec): ... this. Remove the 'data' parameter and make
9291 extern. Adjust.
9292 (mi_interpreter_pre_command_loop): ... Rename to ...
9293 (mi_interp::pre_command_loop): ... this. Remove the 'self'
9294 parameter and make extern.
9295 (mi_on_normal_stop_1): Adjust.
9296 (mi_ui_out): Rename to ...
9297 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
9298 parameter and make extern. Adjust.
9299 (mi_set_logging): Rename to ...
9300 (mi_interp::set_logging): ... this. Remove the 'interp'
9301 parameter and make extern. Adjust.
9302 (mi_interp_procs): Delete.
9303 (mi_interp_factory): Adjust to use 'new'.
9304 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
9305 (mi_print_exception, mi_execute_command, mi_load_progress):
9306 Adjust.
9307 * tui/tui-interp.c (tui_interp): New class.
9308 (as_tui_interp): Return a tui_interp pointer.
9309 (tui_on_normal_stop, tui_on_signal_received)
9310 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
9311 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
9312 to use interp::interp_ui_out.
9313 (tui_init): Rename to ...
9314 (tui_interp::init): ... this. Remove the 'self' parameter, use
9315 bool, return void and make extern. Adjust.
9316 (tui_resume): Rename to ...
9317 (tui_interp::resume): ... this. Remove the 'data' parameter,
9318 return void and make extern. Adjust.
9319 (tui_suspend): Rename to ...
9320 (tui_interp::suspend): ... this. Remove the 'data' parameter,
9321 return void and make extern. Adjust.
9322 (tui_ui_out): Rename to ...
9323 (tui_interp::interp_ui_out): ... this. Remove the 'self'
9324 parameter, and make extern. Adjust.
9325 (tui_exec): Rename to ...
9326 (tui_interp::exec): ... this. Remove the 'data' parameter and
9327 make extern.
9328 (tui_interp_procs): Delete.
9329 (tui_interp_factory): Use "new".
9330
65c40c95
TT
93312017-02-02 Tom Tromey <tom@tromey.com>
9332
9333 * rust-exp.y (ends_raw_string, space_then_number)
9334 (rust_identifier_start_p): Return bool.
9335 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
9336 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
9337 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
9338 (rust_chartype_p): Return bool.
9339 (val_print_struct, rust_print_struct_def, rust_print_type):
9340 Update.
9341 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
9342 Return bool.
9343
b50f188d
TT
93442017-02-02 Tom Tromey <tom@tromey.com>
9345
9346 * rust-lang.c: Reindent.
9347
03c85b11
TT
93482017-02-02 Tom Tromey <tom@tromey.com>
9349
9350 * rust-lang.h (rust_crate_for_block): Update.
9351 * rust-lang.c (rust_crate_for_block): Return std::string.
9352 (rust_get_disr_info): Use std:;string, not
9353 gdb::unique_xmalloc_ptr.
9354 * rust-exp.y (crate_name): Update.
9355
9b6da501
PA
93562017-02-02 Pedro Alves <palves@redhat.com>
9357
9358 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
9359 field out of gdb_disassembler_test and make it static.
9360
ec4cb20b
PA
93612017-02-02 Pedro Alves <palves@redhat.com>
9362
9363 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
9364 mi1_interp and mi_interp fields.
9365
5be5dbf0
PA
93662017-02-02 Pedro Alves <palves@redhat.com>
9367
616268b6
PA
9368 * cli/cli-interp.c (struct saved_output_files, saved_output):
9369 Moved from cli/cli-logging.c.
9370 (cli_set_logging): New function.
9371 (cli_interp_procs): Install cli_set_logging.
9372 * cli/cli-interp.h (make_logging_output, cli_set_logging):
9373 Declare.
9374 * cli/cli-logging.c (struct saved_output_files, saved_output):
9375 Moved to cli/cli-interp.c.
9376 (pop_output_files): Don't save outputs here.
9377 (make_logging_output): New function.
9378 (handle_redirections): Don't build tee nor save previous outputs
9379 here.
9380 * interps.c (current_interp_set_logging): Change prototype.
9381 Assume there's always a set_logging_proc method installed.
9382 * interps.h (interp_set_logging_ftype): Change prototype.
9383 (current_interp_set_logging): Change prototype and adjust comment.
9384 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
9385 use make_logging_output.
9386 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
93872017-02-02 Pedro Alves <palves@redhat.com>
9388
5be5dbf0
PA
9389 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
9390 from ...
9391 (set_logging_overwrite): ... here.
9392 (logging_no_redirect_file): Delete.
9393 (set_logging_redirect): Don't handle redirection on the fly.
9394 Instead warn that "logging off" / "logging on" is necessary.
9395 (pop_output_files): Delete references to logging_no_redirect_file.
9396 (show_logging_command): Always speak in terms of what will happen
9397 once logging is reenabled.
9398
c99cc448
PA
93992017-02-02 Pedro Alves <palves@redhat.com>
9400
9401 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
9402
8b172ce7
PA
94032017-02-02 Pedro Alves <palves@redhat.com>
9404
9405 * disasm.c (gdb_pretty_print_insn): Rename to ...
9406 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
9407 Remove gdbarch parameter. Adapt to clear the object's buffers
9408 instead of allocating new buffers, and to print using the object's
9409 gdb_disassembler instead of calling gdb_print_insn.
9410 (dump_insns): Use gdb_pretty_print_disassembler.
9411 * disasm.h (gdb_pretty_print_insn): Delete declaration.
9412 (gdb_pretty_print_disassembler): New class.
9413 * record-btrace.c (btrace_insn_history): Use
9414 gdb_pretty_print_disassembler.
9415
d7e74731
PA
94162017-02-02 Pedro Alves <palves@redhat.com>
9417
9418 * ada-lang.c (type_as_string): Use string_file.
9419 * ada-valprint.c (ada_print_floating): Use string_file.
9420 * ada-varobj.c (ada_varobj_scalar_image)
9421 (ada_varobj_get_value_image): Use string_file.
9422 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
9423 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
9424 * breakpoint.c (update_inserted_breakpoint_locations)
9425 (insert_breakpoint_locations, reattach_breakpoints)
9426 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
9427 (print_it_watchpoint): Use string_file.
9428 (save_breakpoints): Use stdio_file.
9429 * c-exp.y (oper): Use string_file.
9430 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
9431 tee_file.
9432 (pop_output_files): Use delete.
9433 (handle_redirections): Use stdio_file and tee_file.
9434 * cli/cli-setshow.c (do_show_command): Use string_file.
9435 * compile/compile-c-support.c (c_compute_program): Use
9436 string_file.
9437 * compile/compile-c-symbols.c (generate_vla_size): Take a
9438 'string_file &' instead of a 'ui_file *'.
9439 (generate_c_for_for_one_variable): Take a 'string_file &' instead
9440 of a 'ui_file *'. Use string_file.
9441 (generate_c_for_variable_locations): Take a 'string_file &'
9442 instead of a 'ui_file *'.
9443 * compile/compile-internal.h (generate_c_for_for_one_variable):
9444 Take a 'string_file &' instead of a 'ui_file *'.
9445 * compile/compile-loc2c.c (push, pushf, unary, binary)
9446 (print_label, pushf_register_address, pushf_register)
9447 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
9448 'ui_file *'. Adjust.
9449 * compile/compile.c (compile_to_object): Use string_file.
9450 * compile/compile.h (compile_dwarf_expr_to_c)
9451 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
9452 'ui_file *'.
9453 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
9454 (replace_typedefs_qualified_name): Use string_file and
9455 obstack_copy0.
9456 * disasm.c (gdb_pretty_print_insn): Use string_file.
9457 (gdb_disassembly): Adjust reference the null_stream global.
9458 (do_ui_file_delete): Delete.
9459 (gdb_insn_length): Use null_stream.
9460 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
9461 * dwarf2loc.c (dwarf2_compile_property_to_c)
9462 (locexpr_generate_c_location, loclist_generate_c_location): Take a
9463 'string_file &' instead of a 'ui_file *'.
9464 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
9465 * dwarf2read.c (do_ui_file_peek_last): Delete.
9466 (dwarf2_compute_name): Use string_file.
9467 * event-top.c (gdb_setup_readline): Use stdio_file.
9468 * gdbarch.sh (verify_gdbarch): Use string_file.
9469 * gdbtypes.c (safe_parse_type): Use null_stream.
9470 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
9471 string_file.
9472 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
9473 'string_file *' instead of a 'ui_file *'.
9474 (gdbscm_arch_disassemble): Use string_file.
9475 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
9476 * guile/scm-ports.c (class ioscm_file_port): Now a class that
9477 inherits from ui_file.
9478 (ioscm_file_port_delete, ioscm_file_port_rewind)
9479 (ioscm_file_port_put): Delete.
9480 (ioscm_file_port_write): Rename to ...
9481 (ioscm_file_port::write): ... this. Remove file_port_magic
9482 checks.
9483 (ioscm_file_port_new): Delete.
9484 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
9485 ui_file_up.
9486 * guile/scm-type.c (tyscm_type_name): Use string_file.
9487 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
9488 Use string_file.
9489 * infcmd.c (print_return_value_1): Use string_file.
9490 * infrun.c (print_target_wait_results): Use string_file.
9491 * language.c (add_language): Use string_file.
9492 * location.c (explicit_to_string_internal): Use string_file.
9493 * main.c (captured_main_1): Use null_file.
9494 * maint.c (maintenance_print_architecture): Use stdio_file.
9495 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
9496 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
9497 event_channel>: Change type to mi_console_file pointer.
9498 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
9499 (mi_console_file_delete): Delete.
9500 (struct mi_console_file): Delete.
9501 (mi_console_file_magic): Delete.
9502 (mi_console_file_new): Delete.
9503 (mi_console_file::mi_console_file): New.
9504 (mi_console_file_delete): Delete.
9505 (mi_console_file_fputs): Delete.
9506 (mi_console_file::write): New.
9507 (mi_console_raw_packet): Delete.
9508 (mi_console_file::flush): New.
9509 (mi_console_file_flush): Delete.
9510 (mi_console_set_raw): Rename to ...
9511 (mi_console_file::set_raw): ... this.
9512 * mi/mi-console.h (class mi_console_file): New class.
9513 (mi_console_file_new, mi_console_set_raw): Delete.
9514 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
9515 (mi_set_logging): Use delete and tee_file. Adjust.
9516 * mi/mi-main.c (output_register): Use string_file.
9517 (mi_cmd_data_evaluate_expression): Use string_file.
9518 (mi_cmd_data_read_memory): Use string_file.
9519 (mi_cmd_execute, print_variable_or_computed): Use string_file.
9520 * mi/mi-out.c (mi_ui_out::main_stream): New.
9521 (mi_ui_out::rewind): Use main_stream and
9522 string_file.
9523 (mi_ui_out::put): Use main_stream and string_file.
9524 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
9525 Allocate a 'string_file' instead.
9526 (mi_out_new): Don't allocate a mem_fileopen stream here.
9527 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
9528 (mi_ui_out::main_stream): Declare method.
9529 * printcmd.c (eval_command): Use string_file.
9530 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
9531 * python/py-arch.c (archpy_disassemble): Use string_file.
9532 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
9533 * python/py-frame.c (frapy_str): Use string_file.
9534 * python/py-framefilter.c (py_print_type, py_print_single_arg):
9535 Use string_file.
9536 * python/py-type.c (typy_str): Use string_file.
9537 * python/py-unwind.c (unwind_infopy_str): Use string_file.
9538 * python/py-value.c (valpy_str): Use string_file.
9539 * record-btrace.c (btrace_insn_history): Use string_file.
9540 * regcache.c (regcache_print): Use stdio_file.
9541 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
9542 * remote.c (escape_buffer): Use string_file.
9543 * rust-lang.c (rust_get_disr_info): Use string_file.
9544 * serial.c (serial_open_ops_1): Use stdio_file.
9545 (do_serial_close): Use delete.
9546 * stack.c (print_frame_arg): Use string_file.
9547 (print_frame_args): Remove local mem_fileopen stream, not used.
9548 (print_frame): Use string_file.
9549 * symmisc.c (maintenance_print_symbols): Use stdio_file.
9550 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
9551 Take a 'string_file *' instead of a 'ui_file *'.
9552 * top.c (new_ui): Use stdio_file and stderr_file.
9553 (free_ui): Use delete.
9554 (execute_command_to_string): Use string_file.
9555 (quit_confirm): Use string_file.
9556 * tracepoint.c (collection_list::append_exp): Use string_file.
9557 * tui/tui-disasm.c (tui_disassemble): Use string_file.
9558 * tui/tui-file.c: Don't include "ui-file.h".
9559 (enum streamtype, struct tui_stream): Delete.
9560 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
9561 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
9562 (tui_file::tui_file): New method.
9563 (tui_file_fputs): Delete.
9564 (tui_file_get_strbuf): Delete.
9565 (tui_file::puts): New method.
9566 (tui_file_adjust_strbuf): Delete.
9567 (tui_file_flush): Delete.
9568 (tui_file::flush): New method.
9569 * tui/tui-file.h: Tweak intro comment.
9570 Include ui-file.h.
9571 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
9572 (tui_file_adjust_strbuf): Delete declarations.
9573 (class tui_file): New class.
9574 * tui/tui-io.c (tui_initialize_io): Use tui_file.
9575 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
9576 (tui_register_format): Use string_stream.
9577 * tui/tui-stack.c (tui_make_status_line): Use string_file.
9578 (tui_get_function_from_frame): Use string_file.
9579 * typeprint.c (type_to_string): Use string_file.
9580 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
9581 (null_stream): New global.
9582 (ui_file_delete): Delete.
9583 (ui_file::ui_file): New.
9584 (null_file_isatty): Delete.
9585 (ui_file::~ui_file): New.
9586 (null_file_rewind): Delete.
9587 (ui_file::printf): New.
9588 (null_file_put): Delete.
9589 (null_file_flush): Delete.
9590 (ui_file::putstr): New.
9591 (null_file_write): Delete.
9592 (ui_file::putstrn): New.
9593 (null_file_read): Delete.
9594 (ui_file::putc): New.
9595 (null_file_fputs): Delete.
9596 (null_file_write_async_safe): Delete.
9597 (ui_file::vprintf): New.
9598 (null_file_delete): Delete.
9599 (null_file::write): New.
9600 (null_file_fseek): Delete.
9601 (null_file::puts): New.
9602 (ui_file_data): Delete.
9603 (null_file::write_async_safe): New.
9604 (gdb_flush, ui_file_isatty): Adjust.
9605 (ui_file_put, ui_file_rewind): Delete.
9606 (ui_file_write): Adjust.
9607 (ui_file_write_for_put): Delete.
9608 (ui_file_write_async_safe, ui_file_read): Adjust.
9609 (ui_file_fseek): Delete.
9610 (fputs_unfiltered): Adjust.
9611 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
9612 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
9613 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
9614 (set_ui_file_data): Delete.
9615 (string_file::~string_file, string_file::write)
9616 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
9617 (do_ui_file_as_string, ui_file_as_string): Delete.
9618 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
9619 (struct mem_file): Delete.
9620 (mem_file_new): Delete.
9621 (stdio_file::stdio_file): New.
9622 (mem_file_delete): Delete.
9623 (stdio_file::stdio_file): New.
9624 (mem_fileopen): Delete.
9625 (stdio_file::~stdio_file): New.
9626 (mem_file_rewind): Delete.
9627 (stdio_file::set_stream): New.
9628 (mem_file_put): Delete.
9629 (stdio_file::open): New.
9630 (mem_file_write): Delete.
9631 (stdio_file_magic, struct stdio_file): Delete.
9632 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
9633 (stdio_file::flush): New.
9634 (stdio_file_read): Rename to ...
9635 (stdio_file::read): ... this. Adjust.
9636 (stdio_file_write): Rename to ...
9637 (stdio_file::write): ... this. Adjust.
9638 (stdio_file_write_async_safe): Rename to ...
9639 (stdio_file::write_async_safe) ... this. Adjust.
9640 (stdio_file_fputs): Rename to ...
9641 (stdio_file::puts) ... this. Adjust.
9642 (stdio_file_isatty): Delete.
9643 (stdio_file_fseek): Delete.
9644 (stdio_file::isatty): New.
9645 (stderr_file_write): Rename to ...
9646 (stderr_file::write) ... this. Adjust.
9647 (stderr_file_fputs): Rename to ...
9648 (stderr_file::puts) ... this. Adjust.
9649 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
9650 (stderr_file::stderr_file): New.
9651 (tee_file_magic): Delete.
9652 (struct tee_file): Delete.
9653 (tee_file::tee_file): New.
9654 (tee_file_new): Delete.
9655 (tee_file::~tee_file): New.
9656 (tee_file_delete): Delete.
9657 (tee_file_flush): Rename to ...
9658 (tee_file::flush): ... this. Adjust.
9659 (tee_file_write): Rename to ...
9660 (tee_file::write): ... this. Adjust.
9661 (tee_file::write_async_safe): New.
9662 (tee_file_fputs): Rename to ...
9663 (tee_file::puts): ... this. Adjust.
9664 (tee_file_isatty): Rename to ...
9665 (tee_file::isatty): ... this. Adjust.
9666 * ui-file.h (struct obstack, struct ui_file): Don't
9667 forward-declare.
9668 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
9669 (ui_file_write_ftype)
9670 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
9671 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
9672 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
9673 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
9674 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
9675 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
9676 (set_ui_file_fseek): Delete.
9677 (ui_file_data, ui_file_delete, ui_file_rewind)
9678 (struct ui_file): New.
9679 (ui_file_up): New.
9680 (class null_file): New.
9681 (null_stream): Declare.
9682 (ui_file_write_for_put, ui_file_put): Delete.
9683 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
9684 Delete.
9685 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
9686 (gdb_fopen, tee_file_new): Delete.
9687 (struct string_file): New.
9688 (struct stdio_file): New.
9689 (stdio_file_up): New.
9690 (struct stderr_file): New.
9691 (class tee_file): New.
9692 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
9693 of a 'ui_file *'. Adjust.
9694 * ui-out.h (class ui_out) <field_stream>: Likewise.
9695 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
9696 (null_stream): Delete.
9697 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
9698 Adjust.
9699 * utils.h (struct ui_file): Delete forward declaration..
9700 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
9701 (error_stream): Take a 'string_file &' instead of a
9702 'ui_file *'.
9703 * varobj.c (varobj_value_get_print_value): Use string_file.
9704 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
9705 * gdbarch.c: Regenerate.
9706
187808b0
PA
97072017-02-02 Pedro Alves <palves@redhat.com>
9708
9709 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
9710 (gdb_pretty_print_insn): ... this. Now a free function. Add back
9711 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
9712 Adjust to call gdb_print_insn instead of
9713 gdb_disassembler::print_insn.
9714 (dump_insns, do_mixed_source_and_assembly_deprecated)
9715 (do_mixed_source_and_assembly, do_assembly_only): Add back a
9716 'gdbarch' parameter. Remove gdb_disassembler parameter.
9717 (gdb_disassembly): Don't allocate a gdb_disassembler here.
9718 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
9719 declaration.
9720 (gdb_pretty_print_insn): Re-add declaration.
9721 * record-btrace.c (btrace_insn_history): Don't allocate a
9722 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
9723
7a8eb317
SM
97242017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
9725
9726 * disasm.h (gdb_disassembly): Remove file_string parameter.
9727 * disasm.c (gdb_disassembly): Likewise.
9728 * cli/cli-cmds.c (print_disassembly): Adapt.
9729 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
9730 * stack.c (do_gdb_disassembly): Likewise.
9731
7346ef59
AA
97322017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
9733
9734 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
9735 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
9736 targets. And if the implicit value is longer than needed, extract
9737 the first bytes instead of the "least significant" ones.
9738
cd4007e4
MM
97392017-02-01 Markus Metzger <markus.t.metzger@intel.com>
9740
9741 * btrace.c (btrace_enable): Do not call btrace_add_pc for
9742 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
9743 (btrace_fetch): Assert can_access_registers_ptid.
9744 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
9745 validate_registers_access.
9746
cf77c34e
MM
97472017-02-01 Markus Metzger <markus.t.metzger@intel.com>
9748
9749 * gdbthread.h (can_access_registers_ptid): New.
9750 * thread.c (can_access_registers_ptid): New.
9751
be85ce7d
PA
97522017-02-01 Pedro Alves <palves@redhat.com>
9753
9754 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
9755
29b0b251
PA
97562017-01-31 Pedro Alves <palves@redhat.com>
9757
9758 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
9759 Fix typos.
9760
289b5b24
PA
97612017-01-31 Pedro Alves <palves@redhat.com>
9762
9763 * stack.c (print_frame_args): Remove local mem_fileopen stream,
9764 not used.
9765
b47413b4
PA
97662017-01-31 Pedro Alves <palves@redhat.com>
9767
9768 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
9769
60adb36c
PA
97702017-01-31 Pedro Alves <palves@redhat.com>
9771
9772 * common/scoped_restore.h
9773 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
9774 change the value's parameter type to T2.
9775 (make_scoped_restore): Likewise.
9776
2735833d
WT
97772017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
9778 Richard Henderson <rth@redhat.com>
9779
9780 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
9781 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
9782 GS_BASE for older kernels.
9783 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
9784 GS_BASE for older kernels.
9785 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
9786 and GS_BASE to the offset table.
9787 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
9788 system register group.
9789 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
9790 for older kernels.
9791 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
9792 amd64 ABI.
9793 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
9794 AMD64_GSBASE_REGNUM.
9795 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
9796 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
9797 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
9798 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
9799 i386/64bit-segments.xml in those rules.
9800 * features/i386/64bit-segments.xml: New file.
9801 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
9802 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
9803 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
9804 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
9805 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
9806 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
9807 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
9808 * features/i386/amd64-avx-linux.c: Regenerated.
9809 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
9810 * features/i386/amd64-avx-mpx.c: Regenerated.
9811 * features/i386/amd64-avx512-linux.c: Regenerated.
9812 * features/i386/amd64-linux.c: Regenerated.
9813 * features/i386/amd64-mpx-linux.c: Regenerated.
9814 * features/i386/i386-avx-mpx-linux.c: Regenerated.
9815 * features/i386/i386-avx-mpx.c: Regenerated.
9816 * features/i386/x32-avx-linux.c: Regenerated.
9817 * features/i386/x32-avx512-linux.c: Regenerated.
9818 * regformats/i386/amd64-avx-linux.dat: Regenerated.
9819 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
9820 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
9821 * regformats/i386/amd64-linux.dat: Regenerated.
9822 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
9823 * regformats/i386/x32-avx-linux.dat: Regenerated.
9824 * regformats/i386/x32-avx512-linux.dat: Regenerated.
9825 * regformats/i386/x32-linux.dat: Regenerated.
9826
8884e97e
WT
98272017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
9828
9829 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
9830 Set to AMD64_NUM_REGS.
9831
7005d26a
WT
98322017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
9833
9834 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
9835 that checks validity of a register number.
9836
4bd2e1b2
KC
98372017-01-27 Kees Cook <keescook@google.com>
9838
9839 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
9840 fetch_fpregs if target has fpa registers.
9841 (arm_linux_store_inferior_registers): Call store_fpregs if target
9842 has fpa registers.
9843
7cf1de6c
AA
98442017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
9845
9846 * cris-tdep.c (cris_gdbarch_init): Remove check for
9847 info.byte_order and force it to BFD_ENDIAN_LITTLE.
9848
874a1c8c
AT
98492017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
9850
9851 * corelow.c (get_core_register_section): Check for regset
9852 existence before checking for REGSET_VARIABLE_SIZE.
9853
d8b49cf0
YQ
98542017-01-26 Yao Qi <yao.qi@linaro.org>
9855 Pedro Alves <palves@redhat.com>
9856
9857 PR gdb/20939
9858 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
9859 call memory_error, save memaddr instead.
9860 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
9861 negative, cal memory_error.
9862 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
9863
658ca58c
YQ
98642017-01-26 Yao Qi <yao.qi@linaro.org>
9865
9866 * disasm-selftests.c (memory_error_test): New function.
9867 (_initialize_disasm_selftests): Register memory_error_test.
9868
79843d45
YQ
98692017-01-26 Yao Qi <yao.qi@linaro.org>
9870
9871 * Makefile.in (SFILES): Add disasm-selftests.c and
9872 selftest-arch.c.
9873 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
9874 * disasm-selftests.c: New file.
9875 * selftest-arch.c: New file.
9876 * selftest-arch.h: New file.
9877
8cafda32
YQ
98782017-01-26 Yao Qi <yao.qi@linaro.org>
9879
9880 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
9881 to bfd_arch_mep. Don't return 0 if section is not
9882 found. Call print_insn_mep.
9883
e47ad6c0
YQ
98842017-01-26 Pedro Alves <palves@redhat.com>
9885 Yao Qi <yao.qi@linaro.org>
9886
9887 * arm-tdep.c: Include "disasm.h".
9888 (gdb_print_insn_arm): Update code to get gdbarch.
9889 * disasm.c (dis_asm_read_memory): Change it to
9890 gdb_disassembler::dis_asm_read_memory.
9891 (dis_asm_memory_error): Likewise.
9892 (dis_asm_print_address): Likewise.
9893 (gdb_pretty_print_insn): Change it to
9894 gdb_disassembler::pretty_print_insn.
9895 (dump_insns): Add one argument gdb_disassemlber. All
9896 callers updated.
9897 (do_mixed_source_and_assembly_deprecated): Likewise.
9898 (do_mixed_source_and_assembly): Likewise.
9899 (do_assembly_only): Likewise.
9900 (gdb_disassembler::gdb_disassembler): New.
9901 (gdb_disassembler::print_insn): New.
9902 * disasm.h (class gdb_disassembler): New.
9903 (gdb_pretty_print_insn): Remove declaration.
9904 (gdb_disassemble_info): Likewise.
9905 * guile/scm-disasm.c (class gdbscm_disassembler): New.
9906 (gdbscm_disasm_read_memory_worker): Update.
9907 (gdbscm_disasm_read_memory): Update.
9908 (gdbscm_disasm_memory_error): Remove.
9909 (gdbscm_disasm_print_address): Remove.
9910 (gdbscm_disassembler::gdbscm_disassembler): New.
9911 (gdbscm_print_insn_from_port): Update.
9912 * mips-tdep.c: Include disasm.h.
9913 (gdb_print_insn_mips): Update code to get gdbarch.
9914 * record-btrace.c (btrace_insn_history): Update.
9915 * spu-tdep.c: Include disasm.h.
9916 (struct spu_dis_asm_data): Remove.
9917 (struct spu_dis_asm_info): New.
9918 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
9919 SPU id.
9920 (gdb_print_insn_spu): Cast disassemble_info to
9921 spu_dis_asm_info.
9922
80d75874
YQ
99232017-01-26 Yao Qi <yao.qi@linaro.org>
9924
9925 * disasm.c (do_ui_file_delete): Delete.
9926 (gdb_insn_length): Move code creating stream to ...
9927 * utils.c (null_stream): ... here. New function.
9928 * utils.h (null_stream): Declare.
9929
60685cd0
SM
99302017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
9931
9932 * python/py-inferior.c (find_thread_object): Return directly
9933 from the loop. Remove "found" variable.
9934
eb1cdb62
JB
99352017-01-21 Joel Brobecker <brobecker@adacore.com>
9936
9937 GDB 7.12.1 released.
9938
b1ce6568
SM
99392017-01-20 Simon Marchi <simon.marchi@ericsson.com>
9940
9941 * python/py-function.c (fnpy_call): Reorder declarations to have
9942 the gdbpy_enter object declared first.
9943 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
9944
6f8b0407
SM
99452017-01-20 Simon Marchi <simon.marchi@ericsson.com>
9946
fec93fb1 9947 PR python/21068
6f8b0407
SM
9948 * python/python-internal.h (PyMem_RawMalloc): Define for
9949 Python < 3.4.
9950 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
9951 PyMem_RawMalloc instead of PyMem_Malloc.
9952
78cbbba8
LM
99532017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
9954 Luis Machado <lgustavo@codesourcery.com>
9955
9956 * NEWS (New commands): Mention flash-erase.
9957 (New MI commands): Mention target-flash-erase.
9958 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
9959 command.
9960 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
9961 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
9962 * target.c (flash_erase_command): New function.
9963 (initialize_targets): Add new flash-erase command.
9964 * target.h (flash_erase_command): New declaration.
9965
2132fe85
JB
99662017-01-20 Joel Brobecker <brobecker@adacore.com>
9967
9968 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
9969 HAVE_SYS_PROCFS_H is defined.
9970
d1dff226
AH
99712017-01-18 Alan Hayward <alan.hayward@arm.com>
9972
9973 * remote.c (struct cached_reg): Change data into a pointer.
9974 * (stop_reply_dtr): Free data pointers before deleting vector.
9975 (process_stop_reply): Likewise.
9976 (remote_parse_stop_reply): Allocate space for data
9977
9890e433
AH
99782017-01-18 Alan Hayward <alan.hayward@arm.com>
9979
9980 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
9981 MAX_REGISTER_SIZE.
9982 (amd64_pseudo_register_read_value): Likewise.
9983 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
9984 (store_register_using_P): Likewise.
9985 * regcache.c (regcache_xfer_part): Likewise.
9986
7a36499a
IR
99872017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
9988
9989 Split real and pseudo registers.
9990 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
9991 (sparc32_pseudo_regnum): New enum.
9992 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
9993 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
9994 (SPARC32_CP0_REGISTERS): New macro.
9995 (sparc32_pseudo_register_name): New function.
9996 (sparc32_register_name): Use sparc32_pseudo_register_name.
9997 (sparc32_pseudo_register_type): New function.
9998 (sparc32_register_type): Use sparc32_pseudo_register_type.
9999 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
10000 pseudo register numbers.
10001 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
10002 (SPARC64_CP0_REGISTERS): New macro.
10003 (sparc64_pseudo_register_name): New function.
10004 (sparc64_register_name): Use sparc64_pseudo_register_name.
10005 (sparc64_pseudo_register_type): New function.
10006 (sparc64_register_type): Use sparc64_pseudo_register_type.
10007 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
10008 pseudo register numbers.
10009 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
10010 sparc64_store_arguments): Handle pseudo register numbers.
10011
6f8976bf
YQ
100122017-01-13 Yao Qi <yao.qi@linaro.org>
10013
10014 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
10015 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
10016 output.
10017 (getpkt_or_notif_sane_1): Likewise.
10018
e4241ace
YQ
100192017-01-13 Yao Qi <yao.qi@linaro.org>
10020
10021 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
10022 of CC. Pass "-x c++-header" instead of "-x c".
10023
3015c064
SM
100242017-01-12 Simon Marchi <simon.marchi@ericsson.com>
10025
10026 * remote.c (remote_can_async_p): Update comment.
10027
fde1b17d
SM
100282017-01-12 Simon Marchi <simon.marchi@ericsson.com>
10029
10030 * linux-nat.c (linux_nat_can_async_p): Update comment.
10031
ca1ca08b
SM
100322017-01-12 Simon Marchi <simon.marchi@ericsson.com>
10033
10034 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
10035
4ad2da73
SM
100362017-01-11 Simon Marchi <simon.marchi@ericsson.com>
10037
10038 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
10039
c8b23b3f
TT
100402017-01-10 Tom Tromey <tom@tromey.com>
10041
10042 * python/py-type.c (typy_legacy_template_argument): Update.
10043 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
10044 ~demangle_parse_info): Declare new members.
10045 (cp_demangled_name_to_comp): Return unique_ptr.
10046 (cp_demangled_name_parse_free)
10047 (make_cleanup_cp_demangled_name_parse_free)
10048 (cp_new_demangle_parse_info): Remove.
10049 * cp-support.c (do_demangled_name_parse_free_cleanup)
10050 (make_cleanup_cp_demangled_name_parse_free): Remove.
10051 (inspect_type, cp_canonicalize_string_full)
10052 (cp_canonicalize_string): Update.
10053 (mangled_name_to_comp): Change return type.
10054 (cp_class_name_from_physname, method_name_from_physname)
10055 (cp_func_name, cp_remove_params): Update.
10056 * cp-name-parser.y (demangle_parse_info): New constructor, from
10057 cp_new_demangle_parse_info.
10058 (~demangle_parse_info): New destructor, from
10059 cp_demangled_name_parse_free.
10060 (cp_merge_demangle_parse_infos): Update.
10061 (cp_demangled_name_to_comp): Change return type.
10062
1ac32117
TT
100632017-01-10 Tom Tromey <tom@tromey.com>
10064
10065 * top.c (prevent_dont_repeat): Change return type.
10066 * python/python.c (execute_gdb_command): Use std::string.
10067 Update.
10068 * guile/guile.c (gdbscm_execute_gdb_command): Update.
10069 * command.h (prevent_dont_repeat): Change return type.
10070 * breakpoint.c (bpstat_do_actions_1): Update.
10071
0cf08227
TT
100722017-01-10 Tom Tromey <tom@tromey.com>
10073
10074 * value.h (scoped_value_mark::~scoped_value_mark): Call
10075 free_to_mark.
10076 (scoped_value_mark::free_to_mark): New method.
10077 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
10078 scoped_value_mark.
10079
eb115069
TT
100802017-01-10 Tom Tromey <tom@tromey.com>
10081
10082 * python/py-value.c (valpy_dereference, valpy_referenced_value)
10083 (valpy_reference_value, valpy_const_value, valpy_get_address)
10084 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
10085 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
10086 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
10087 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
10088 scoped_value_mark.
10089 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
10090 * value.h (scoped_value_mark): New class.
10091
906768f9
TT
100922017-01-10 Tom Tromey <tom@tromey.com>
10093
10094 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
10095 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
10096 * psymtab.c (discard_psymtabs_upto): Remove.
10097 (make_cleanup_discard_psymtabs): Remove.
10098 (struct psymtab_state): Remove.
10099
bef155c3
TT
101002017-01-10 Tom Tromey <tom@tromey.com>
10101
10102 * record-full.c (record_full_save_cleanups): Remove.
10103 (record_full_save): Use gdb::unlinker.
10104 * gcore.c (do_bfd_delete_cleanup): Remove.
10105 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
10106 cleanups.
10107 * dwarf2read.c (unlink_if_set): Remove.
10108 (write_psymtabs_to_index): Use gdb::unlinker.
10109 * common/gdb_unlinker.h: New file.
10110
192b62ce
TT
101112017-01-10 Tom Tromey <tom@tromey.com>
10112
10113 * windows-tdep.c (windows_xfer_shared_library): Update.
10114 * windows-nat.c (windows_make_so): Update.
10115 * utils.h (make_cleanup_bfd_unref): Remove.
10116 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
10117 * symfile.h (symfile_bfd_open)
10118 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
10119 * symfile.c (read_symbols, symbol_file_add)
10120 (separate_debug_file_exists): Update.
10121 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
10122 (generic_load, reread_symbols): Update.
10123 * symfile-mem.c (symbol_file_add_from_memory): Update.
10124 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
10125 (spu_symbol_file_add_from_memory): Update.
10126 * solist.h (struct target_so_ops) <bfd_open>: Return
10127 gdb_bfd_ref_ptr.
10128 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
10129 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
10130 gdb_bfd_ref_ptr.
10131 (solib_map_sections, reload_shared_libraries_1): Update.
10132 * solib-svr4.c (enable_break): Update.
10133 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
10134 * solib-frv.c (enable_break2): Update.
10135 * solib-dsbt.c (enable_break): Update.
10136 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
10137 gdb_bfd_ref_ptr.
10138 (darwin_solib_get_all_image_info_addr_at_init): Update.
10139 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
10140 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
10141 * record-full.c (record_full_save): Update.
10142 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
10143 * procfs.c (insert_dbx_link_bpt_in_file): Update.
10144 * minidebug.c (find_separate_debug_file_in_section): Return
10145 gdb_bfd_ref_ptr.
10146 * machoread.c (macho_add_oso_symfile): Change abfd to
10147 gdb_bfd_ref_ptr.
10148 (macho_symfile_read_all_oso): Update.
10149 (macho_check_dsym): Return gdb_bfd_ref_ptr.
10150 (macho_symfile_read): Update.
10151 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
10152 (jit_bfd_try_read_symtab): Update.
10153 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
10154 (gdb_bfd_openw, gdb_bfd_openr_iovec)
10155 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
10156 gdb_bfd_ref_ptr.
10157 (gdb_bfd_ref_policy): New struct.
10158 (gdb_bfd_ref_ptr): New typedef.
10159 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
10160 (gdb_bfd_openw, gdb_bfd_openr_iovec)
10161 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
10162 gdb_bfd_ref_ptr.
10163 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
10164 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
10165 (gcore_command): Update.
10166 * exec.c (exec_file_attach): Update.
10167 * elfread.c (elf_symfile_read): Update.
10168 * dwarf2read.c (dwarf2_get_dwz_file): Update.
10169 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
10170 (open_and_init_dwo_file): Update.
10171 (open_dwp_file): Return gdb_bfd_ref_ptr.
10172 (open_and_init_dwp_file): Update.
10173 * corelow.c (core_open): Update.
10174 * compile/compile-object-load.c (compile_object_load): Update.
10175 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
10176 * coffread.c (coff_symfile_read): Update.
10177 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
10178 gdb_bfd_ref_ptr. Rename.
10179 (dump_bfd_file, restore_command): Update.
10180 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
10181 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
10182 (find_separate_debug_file_by_buildid): Update.
10183
50315b21
TT
101842017-01-10 Tom Tromey <tom@tromey.com>
10185
10186 * common/gdb_ref_ptr.h: New file.
10187 * python/py-ref.h (struct gdbpy_ref_policy): New.
10188 (gdbpy_ref): Now a typedef.
10189
fc4007c9
TT
101902017-01-10 Tom Tromey <tom@tromey.com>
10191
10192 * utils.h (make_cleanup_htab_delete): Don't declare.
10193 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
10194 Remove.
10195 * linespec.c (decode_compound_collector): Add constructor,
10196 destructor.
10197 (lookup_prefix_sym): Remove cleanup.
10198 (symtab_collector): Add constructor, destructor.
10199 (collect_symtabs_from_filename): Remove cleanup.
10200 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
10201 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
10202 Use htab_up.
10203 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
10204 * dwarf2read.c (dw2_expand_symtabs_matching)
10205 (dw2_map_symbol_filenames, dwarf_decode_macros)
10206 (write_psymtabs_to_index): Use htab_up.
10207 * dwarf2loc.c (func_verify_no_selftailcall)
10208 (call_site_find_chain_1, func_verify_no_selftailcall)
10209 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
10210 std::vector, gdb::unique_xmalloc_ptr.
10211 (call_sitep): Remove typedef.
10212 (dwarf2_locexpr_baton_eval): Remove unused variable.
10213
8dbcee67
TT
102142017-01-10 Tom Tromey <tom@tromey.com>
10215
10216 * python/python-internal.h (make_cleanup_py_decref)
10217 (make_cleanup_py_xdecref): Don't declare.
10218 * python/py-utils.c (py_decref, make_cleanup_py_decref)
10219 (py_xdecref, make_cleanup_py_xdecref): Remove.
10220
13df46cc
TT
102212017-01-10 Tom Tromey <tom@tromey.com>
10222
10223 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
10224 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
10225
06fc9bf7
TT
102262017-01-10 Tom Tromey <tom@tromey.com>
10227
10228 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
10229
830a4934
TT
102302017-01-10 Tom Tromey <tom@tromey.com>
10231
10232 * python/py-utils.c (unicode_to_encoded_string)
10233 (python_string_to_target_string)
10234 (python_string_to_target_python_string)
10235 (python_string_to_host_string, gdbpy_obj_to_string)
10236 (get_addr_from_python): Use gdbpy_ref.
10237
4586d543
TT
102382017-01-10 Tom Tromey <tom@tromey.com>
10239
10240 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
10241 gdbpy_ref.
10242
59876f8f
TT
102432017-01-10 Tom Tromey <tom@tromey.com>
10244
10245 * python/python.c (eval_python_command, gdbpy_decode_line)
10246 (gdbpy_run_events, gdbpy_start_type_printers)
10247 (gdbpy_apply_type_printers): Use gdbpy_ref.
10248
97d83487
TT
102492017-01-10 Tom Tromey <tom@tromey.com>
10250
10251 * python/py-param.c (get_doc_string, compute_enum_values): Use
10252 gdbpy_ref.
10253
9205649a
TT
102542017-01-10 Tom Tromey <tom@tromey.com>
10255
10256 * python/py-inferior.c (find_thread_object, build_inferior_list):
10257 Use gdbpy_ref.
10258
74c49d45
TT
102592017-01-10 Tom Tromey <tom@tromey.com>
10260
10261 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
10262
16361ffb
TT
102632017-01-10 Tom Tromey <tom@tromey.com>
10264
10265 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
10266 gdbpy_ref.
10267
905f2cca
TT
102682017-01-10 Tom Tromey <tom@tromey.com>
10269
10270 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
10271 extra incref.
10272 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
10273 Use gdbpy_ref.
10274
64081434
TT
102752017-01-10 Tom Tromey <tom@tromey.com>
10276
10277 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
10278 gdbpy_ref.
10279
59e9e831
TT
102802017-01-10 Tom Tromey <tom@tromey.com>
10281
10282 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
10283 decref results of PyArg_ParseTupleAndKeywords.
10284
9de10f6d
TT
102852017-01-10 Tom Tromey <tom@tromey.com>
10286
10287 * python/python.c (python_run_simple_file): Use
10288 unique_xmalloc_ptr, gdbpy_ref.
10289
2bd5759d
TT
102902017-01-10 Tom Tromey <tom@tromey.com>
10291
10292 * python/py-prettyprint.c (print_stack_unless_memory_error)
10293 (print_string_repr, print_children): Use gdbpy_ref.
10294 (dummy_python_frame): New class.
10295 (dummy_python_frame::dummy_python_frame): Rename from
10296 push_dummy_python_frame.
10297 (py_restore_tstate): Remove.
10298
3b4e0e01
TT
102992017-01-10 Tom Tromey <tom@tromey.com>
10300
10301 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
10302
17a22718
TT
103032017-01-10 Tom Tromey <tom@tromey.com>
10304
10305 * python/python.c (ensure_python_env, restore_python_env):
10306 Remove.
10307 * python/python-internal.h (ensure_python_env): Don't declare.
10308 * varobj.h (varobj_ensure_python_env): Don't declare.
10309 * varobj.c (varobj_ensure_python_env): Remove.
10310
68cdc557
TT
103112017-01-10 Tom Tromey <tom@tromey.com>
10312
10313 * varobj.c (varobj_value_get_print_value): Use
10314 gdbpy_enter_varobj.
10315
1eba6383
TT
103162017-01-10 Tom Tromey <tom@tromey.com>
10317
10318 * python/py-prettyprint.c (print_string_repr, print_children):
10319 Update.
10320 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
10321 of "encoding".
10322 * varobj.c (varobj_value_get_print_value): Update.
10323 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
10324
bde7b3e3
TT
103252017-01-10 Tom Tromey <tom@tromey.com>
10326
10327 * varobj.c (varobj_get_display_hint)
10328 (dynamic_varobj_has_child_method, install_new_value_visualizer)
10329 (varobj_set_visualizer, free_variable): Use
10330 gdbpy_enter_varobj.
10331
a7785f8c
TT
103322017-01-10 Tom Tromey <tom@tromey.com>
10333
10334 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
10335 (do_finish_initialization): New function. Use gdbpy_ref.
10336 (gdbpy_finish_initialization): Use gdbpy_enter. Call
10337 do_finish_initialization.
10338
2865bfce
TT
103392017-01-10 Tom Tromey <tom@tromey.com>
10340
10341 * python/py-param.c (get_set_value, get_show_value): Use
10342 gdbpy_enter, gdbpy_ref.
10343
0e9dcc75
TT
103442017-01-10 Tom Tromey <tom@tromey.com>
10345
10346 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
10347
12a5cedd
TT
103482017-01-10 Tom Tromey <tom@tromey.com>
10349
10350 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
10351
788f2586
TT
103522017-01-10 Tom Tromey <tom@tromey.com>
10353
10354 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
10355 Use gdbpy_enter_varobj.
10356
6cd67bea
TT
103572017-01-10 Tom Tromey <tom@tromey.com>
10358
10359 * varobj.c (gdbpy_enter_varobj): New constructor.
10360 * python/python-internal.h (gdbpy_enter_varobj): New class.
10361 * python/py-varobj.c (py_varobj_get_iterator): Use
10362 gdbpy_enter_varobj.
10363
14b122bf
TT
103642017-01-10 Tom Tromey <tom@tromey.com>
10365
10366 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
10367 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
10368 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
10369 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
10370 unique_xmalloc_ptr.
10371 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
10372
bf1ca3b9
TT
103732017-01-10 Tom Tromey <tom@tromey.com>
10374
10375 * python/py-xmethods.c (invoke_match_method): Use
10376 gdbpy_ref.
10377
572a5524
TT
103782017-01-10 Tom Tromey <tom@tromey.com>
10379
10380 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
10381 gdbpy_enter, gdbpy_ref.
10382
396a78b6
TT
103832017-01-10 Tom Tromey <tom@tromey.com>
10384
10385 * python/python.c (python_interactive_command): Use gdbpy_enter.
10386
a88b13c7
TT
103872017-01-10 Tom Tromey <tom@tromey.com>
10388
10389 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
10390 gdbpy_ref.
10391
e9f0c363
TT
103922017-01-10 Tom Tromey <tom@tromey.com>
10393
10394 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
10395 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
10396
6349f452
TT
103972017-01-10 Tom Tromey <tom@tromey.com>
10398
10399 * utils.h (htab_deleter): New struct.
10400 (htab_up): New typedef.
10401 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
10402 gdbpy_enter, gdbpy_ref, htab_up.
10403
c0171de6
TT
104042017-01-10 Tom Tromey <tom@tromey.com>
10405
10406 * python/py-unwind.c (pending_frame_invalidate): Remove.
10407 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
10408
f18e226f
TT
104092017-01-10 Tom Tromey <tom@tromey.com>
10410
10411 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
10412 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
10413
c57af3f1
TT
104142017-01-10 Tom Tromey <tom@tromey.com>
10415
10416 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
10417
60e600ec
TT
104182017-01-10 Tom Tromey <tom@tromey.com>
10419
10420 * python/python.c (gdbpy_eval_from_control_command)
10421 (gdbpy_source_script, gdbpy_run_events)
10422 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
10423 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
10424 gdbpy_enter.
10425
bf7da5b0
TT
104262017-01-10 Tom Tromey <tom@tromey.com>
10427
10428 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
10429
2d38bced
TT
104302017-01-10 Tom Tromey <tom@tromey.com>
10431
10432 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
10433
07bc7329
TT
104342017-01-10 Tom Tromey <tom@tromey.com>
10435
10436 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
10437 (python_on_inferior_call_pre, python_on_inferior_call_post)
10438 (python_on_memory_change, python_on_register_change)
10439 (python_inferior_exit, python_new_objfile, add_thread_object)
10440 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
10441
6e7c365e
TT
104422017-01-10 Tom Tromey <tom@tromey.com>
10443
10444 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
10445 (bpfinishpy_handle_exit): Use gdbpy_enter.
10446
6ba0cd40
TT
104472017-01-10 Tom Tromey <tom@tromey.com>
10448
10449 * python/py-cmd.c (cmdpy_destroyer)
10450 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
10451 gdbpy_enter.
10452
de2dc875
TT
104532017-01-10 Tom Tromey <tom@tromey.com>
10454
10455 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
10456 gdbpy_enter.
10457 (gdbpy_breakpoint_has_cond): Likewise.
10458
4ecee2c4
TT
104592017-01-10 Tom Tromey <tom@tromey.com>
10460
10461 * python/python.c (gdbpy_enter): New constructor.
10462 (~gdbpy_enter): New destructor.
10463 (restore_python_env, ensure_python_env): Rewrite.
10464 * python/python-internal.h (gdbpy_enter): New class.
10465
37fce74f
TT
104662017-01-10 Tom Tromey <tom@tromey.com>
10467
10468 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
10469
53a0cca3
TT
104702017-01-10 Tom Tromey <tom@tromey.com>
10471
10472 * python/py-value.c (value_has_field, get_field_flag)
10473 (get_field_type, valpy_getitem, convert_value_from_python): Use
10474 gdbpy_ref.
10475
ff3724f5
TT
104762017-01-10 Tom Tromey <tom@tromey.com>
10477
10478 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
10479 gdbpy_ref.
10480
0700aea5
TT
104812017-01-10 Tom Tromey <tom@tromey.com>
10482
10483 * python/py-prettyprint.c (search_pp_list)
10484 (find_pretty_printer_from_objfiles)
10485 (find_pretty_printer_from_progspace)
10486 (find_pretty_printer_from_gdb, find_pretty_printer)
10487 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
10488 gdbpy_ref.
10489
1bb44c9f
TT
104902017-01-10 Tom Tromey <tom@tromey.com>
10491
10492 * python/py-param.c (call_doc_function): Use gdbpy_ref.
10493
87ce03fd
TT
104942017-01-10 Tom Tromey <tom@tromey.com>
10495
10496 * python/py-linetable.c (build_line_table_tuple_from_pcs)
10497 (ltpy_get_all_source_lines): Use gdbpy_ref.
10498
ee0a3fb8
TT
104992017-01-10 Tom Tromey <tom@tromey.com>
10500
10501 * python/py-framefilter.c (extract_sym, extract_value)
10502 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
10503 gdbpy_ref.
10504
bf2a52fa
TT
105052017-01-10 Tom Tromey <tom@tromey.com>
10506
10507 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
10508
f59fe7f8
TT
105092017-01-10 Tom Tromey <tom@tromey.com>
10510
10511 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
10512
80bd970a
TT
105132017-01-10 Tom Tromey <tom@tromey.com>
10514
10515 * python/py-function.c (convert_values_to_python, fnpy_init): Use
10516 gdbpy_ref.
10517
d1b3de2e
TT
105182017-01-10 Tom Tromey <tom@tromey.com>
10519
10520 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
10521
3bb43384
TT
105222017-01-10 Tom Tromey <tom@tromey.com>
10523
10524 * python/py-type.c (convert_field, make_fielditem, typy_fields)
10525 (typy_range): Use gdbpy_ref.
10526
abf5651e
TT
105272017-01-10 Tom Tromey <tom@tromey.com>
10528
10529 * python/py-threadevent.c (create_thread_event_object): Use
10530 gdbpy_ref.
10531 * python/py-stopevent.c (create_stop_event_object): Simplify.
10532 (emit_stop_event): Use gdbpy_ref.
10533 * python/py-signalevent.c (create_signal_event_object): Use
10534 gdbpy_ref.
10535 * python/py-newobjfileevent.c (create_new_objfile_event_object)
10536 (emit_new_objfile_event, create_clear_objfiles_event_object)
10537 (emit_clear_objfiles_event): Use gdbpy_ref.
10538 * python/py-infevents.c (create_inferior_call_event_object)
10539 (create_register_changed_event_object)
10540 (create_memory_changed_event_object, emit_inferior_call_event)
10541 (emit_memory_changed_event, emit_register_changed_event): Use
10542 gdbpy_ref.
10543 * python/py-exitedevent.c (create_exited_event_object)
10544 (emit_exited_event): Use gdbpy_ref.
10545 * python/py-event.h (evpy_emit_event): Remove
10546 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
10547 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
10548 * python/py-continueevent.c (emit_continue_event): Use
10549 gdbpy_ref.
10550 * python/py-breakpoint.c (gdbpy_breakpoint_created)
10551 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
10552 gdbpy_ref.
10553 * python/py-bpevent.c (create_breakpoint_event_object): Use
10554 gdbpy_ref.
10555
a68ff33e
TT
105562017-01-10 Tom Tromey <tom@tromey.com>
10557
10558 * python/py-ref.h: New file.
10559
7becfd03
SM
105602017-01-10 Simon Marchi <simon.marchi@ericsson.com>
10561
10562 * cli-out.c (cli_ui_out::do_redirect): Change return type to
10563 void.
10564 * cli-out.h (cli_ui_out::do_redirect): Likewise.
10565 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
10566 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
10567 * ui-out.c (ui_out::redirect): Likewise.
10568 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
10569 * cli/cli-logging.c (set_logging_redirect): Update call site of
10570 ui_out::redirect.
10571 (handle_redirections): Likewise.
10572 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
10573 * top.c (execute_command_to_string): Likewise.
10574 * utils.c (do_ui_out_redirect_pop): Likewise.
10575
df294654
SM
105762017-01-10 Simon Marchi <simon.marchi@ericsson.com>
10577
10578 * stack.c (_initialize_stack): Update "frame" command help message.
10579
f5e6296e
IB
105802017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
10581
10582 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
10583
0e2d6fa6
YQ
105842017-01-06 Yao Qi <yao.qi@linaro.org>
10585
10586 * x86-linux-nat.h: Include gdb_proc_service.h.
10587
44d6d3f9
YQ
105882017-01-06 Yao Qi <yao.qi@linaro.org>
10589
10590 * ser-base.h: Include serial.h.
10591
656731fe
YQ
105922017-01-06 Yao Qi <yao.qi@linaro.org>
10593
10594 * ppc-linux-tdep.h: Include ppc-tdep.h.
10595
1ca8f924
YQ
105962017-01-06 Yao Qi <yao.qi@linaro.org>
10597
10598 * nat/amd64-linux-siginfo.h: Include signal.h.
10599
bc3008c4
YQ
106002017-01-06 Yao Qi <yao.qi@linaro.org>
10601
10602 * nat/aarch64-linux-hw-point.h: Include break-common.h.
10603
66c80d03
YQ
106042017-01-06 Yao Qi <yao.qi@linaro.org>
10605
10606 * mi/mi-parse.h: Include mi-cmds.h.
10607
051d2dda
YQ
106082017-01-06 Yao Qi <yao.qi@linaro.org>
10609
10610 * inf-loop.c: Don't include "target.h".
10611 * inf-loop.h: Include it here.
10612
8018d34f
YQ
106132017-01-06 Yao Qi <yao.qi@linaro.org>
10614
10615 * dfp.h: Include "dboulest.h" and "expression.h".
10616
c0b8369c
YQ
106172017-01-06 Yao Qi <yao.qi@linaro.org>
10618
10619 * ax-gdb.h: Include "ax.h".
10620
ad5cba2a
YQ
106212017-01-06 Yao Qi <yao.qi@linaro.org>
10622
10623 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
10624 with nat/gdb_ptrace.h.
10625
1c33cd7f
YQ
106262017-01-05 Yao Qi <yao.qi@linaro.org>
10627
10628 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
10629 new line.
10630 (mips64_fbsd_sigframe_init): Likewise.
10631
c988ac1d
JB
106322017-01-04 John Baldwin <jhb@FreeBSD.org>
10633
10634 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
10635 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
10636
b268007c
JB
106372017-01-04 John Baldwin <jhb@FreeBSD.org>
10638
10639 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
10640 * NEWS: Mention new FreeBSD/mips native configuration.
10641 * config/mips/fbsd.mh: New file.
10642 * configure.host: Add mips*-*-freebsd*.
10643 * mips-fbsd-nat.c: New file.
10644
387360da
JB
106452017-01-04 John Baldwin <jhb@FreeBSD.org>
10646
10647 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
10648 (ALLDEPFILES): Add mips-fbsd-tdep.c.
10649 * NEWS: Mention new FreeBSD/mips target.
10650 * configure.tgt: Add mips*-*-freebsd*.
10651 * mips-fbsd-tdep.c: New file.
10652 * mips-fbsd-tdep.h: New file.
10653
2aaaf250
YQ
106542017-01-04 Yao Qi <yao.qi@linaro.org>
10655
10656 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
10657 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
10658
61baf725
JB
106592017-01-01 Joel Brobecker <brobecker@adacore.com>
10660
6dbb839a 10661 Update copyright year range in all GDB files.
61baf725 10662
c113e7ff 106632017-01-01 Joel Brobecker <brobecker@adacore.com>
ce0db137 10664
c113e7ff 10665 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
ce0db137 10666
c113e7ff 10667For older changes see ChangeLog-2016.
c906108c
SS
10668\f
10669Local Variables:
10670mode: change-log
10671left-margin: 8
10672fill-column: 74
10673version-control: never
57da7796 10674coding: utf-8
c906108c 10675End:
This page took 2.361463 seconds and 4 git commands to generate.