Add unit test for xml_escape_text
[deliverable/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
c3d7b541
SM
12017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2
3 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
4 (SUBDIR_UNITTESTS_OBS): Add new object file.
5 * unittests/xml-utils-selftests.c: New file.
6
1526853e
SM
72017-09-16 Simon Marchi <simon.marchi@ericsson.com>
8
9 * common/selftest.h (selftest): New struct/interface.
10 (register_test): Add name parameter, add new overload.
11 (run_tests): Add filter parameter.
12 (for_each_selftest_ftype): New typedef.
13 (for_each_selftest): New declaration.
14 * common/selftest.c (tests): Change type to
15 map<string, unique_ptr<selftest>>.
16 (simple_selftest): New struct.
17 (register_test): New function.
18 (register_test): Add name parameter and use it.
19 (run_tests): Add filter parameter and use it. Add prints.
20 Adjust to vector -> map change.
21 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
22 registering selftests.
23 * arm-tdep.c (_initialize_arm_tdep): Likewise.
24 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
25 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
26 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
27 * findvar.c (_initialize_findvar): Likewise.
28 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
29 * maint.c (maintenance_selftest): Update call to run_tests.
30 (maintenance_info_selftests): New function.
31 (_initialize_maint_cmds): Register "maintenance info selftests"
32 command. Update "maintenance selftest" doc.
33 * regcache.c (_initialize_regcache): Add names when registering
34 selftests.
35 * rust-exp.y (_initialize_rust_exp): Likewise.
36 * selftest-arch.c (gdbarch_selftest): New struct.
37 (gdbarch_tests): Remove.
38 (register_test_foreach_arch): Add name parameter. Call
39 register_test.
40 (tests_with_arch): Remove, move most content to
41 gdbarch_selftest::operator().
42 (_initialize_selftests_foreach_arch): Remove.
43 * selftest-arch.h (register_test_foreach_arch): Add name
44 parameter.
45 (run_tests_with_arch): New declaration.
46 * utils-selftests.c (_initialize_utils_selftests): Add names
47 when registering selftests.
48 * utils.c (_initialize_utils): Likewise.
49 * unittests/array-view-selftests.c
50 (_initialize_array_view_selftests): Likewise.
51 * unittests/environ-selftests.c (_initialize_environ_selftests):
52 Likewise.
53 * unittests/function-view-selftests.c
54 (_initialize_function_view_selftests): Likewise.
55 * unittests/offset-type-selftests.c
56 (_initialize_offset_type_selftests): Likewise.
57 * unittests/optional-selftests.c
58 (_initialize_optional_selftests): Likewise.
59 * unittests/scoped_restore-selftests.c
60 (_initialize_scoped_restore_selftests): Likewise.
61 * NEWS: Document "maintenance selftest" and "maint info
62 selftests".
63
5846367a
SM
642017-09-16 Simon Marchi <simon.marchi@ericsson.com>
65
66 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
67 scoped_restore.
68
bd77e8ff
SM
692017-09-16 Simon Marchi <simon.marchi@ericsson.com>
70
71 * mi/mi-main.c (mi_load_progress): Make uiout variable
72 a unique_ptr.
73
26a67918
PA
742017-09-15 Pedro Alves <palves@redhat.com>
75
76 * compile/compile-c-types.c (convert_enum, convert_int)
77 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
78
3f8a7804
SM
792017-09-15 Simon Marchi <simon.marchi@ericsson.com>
80
81 * dwarf2read.c (copy_string): Remove.
82 (parse_macro_definition): Replace copy_string with savestring.
83
8d200706
YQ
842017-09-15 Yao Qi <yao.qi@linaro.org>
85
86 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
87 gdb_target_obs.
88 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
89 Likewise.
90 (i[34567]86-*-linux*): Likewise.
91
d185219d
SM
922017-09-14 Simon Marchi <simon.marchi@ericsson.com>
93
94 * dwarf2expr.h (dwarf_stack_value): Add constructor.
95 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
96 <stack>: Change type to std::vector.
97 <stack_len, stack_allocated>: Remove.
98 <grow_stack>: Remove.
99 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
100 (dwarf_expr_context::~dwarf_expr_context): Remove.
101 (dwarf_expr_context::grow_stack): Remove.
102 (dwarf_expr_context::push): Adjust.
103 (dwarf_expr_context::pop): Adjust.
104 (dwarf_expr_context::fetch): Adjust.
105 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
106 (dwarf_expr_context::stack_empty_p): Adjust.
107 (dwarf_expr_context::execute_stack_op): Adjust.
108
eccd80d6
SM
1092017-09-14 Simon Marchi <simon.marchi@ericsson.com>
110
111 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
112 return type to bool.
113 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
114
69009882
SM
1152017-09-14 Simon Marchi <simon.marchi@ericsson.com>
116
117 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
118 Change type to bool.
119 (dwarf_stack_value) <in_stack_memory>: Likewise.
120 (dwarf_expr_context) <push_address>: Change parameter type to
121 bool.
122 <fetch_in_stack_memory>: Change return type to bool.
123 <push>: Change parameter type to bool.
124 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
125 to bool.
126 (dwarf_expr_context::push_address): Likewise.
127 (dwarf_expr_context::fetch_in_stack_memory): Change return type
128 to bool.
129 (dwarf_expr_context::execute_stack_op): Adjust.
130 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
131
1e467161
SM
1322017-09-14 Simon Marchi <simon.marchi@ericsson.com>
133
134 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
135 (struct dwarf_expr_context) <n_pieces>: Remove.
136 <pieces>: Change type to std::vector.
137 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
138 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
139 pieces.
140 (dwarf_expr_context::add_piece): Adjust.
141 * dwarf2loc.c (struct piece_closure): Initialize fields.
142 <n_pieces>: Remove.
143 <pieces>: Change type to std::vector.
144 (allocate_piece_closure): Adjust, change parameter to
145 std::vector rvalue and std::move it to piece_closure.
146 (rw_pieced_value): Adjust.
147 (check_pieced_synthetic_pointer): Adjust.
148 (indirect_synthetic_pointer): Adjust.
149 (coerce_pieced_ref): Adjust.
150 (free_pieced_value_closure): Adjust. Use delete to free
151 piece_closure.
152 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
153 to allocate_piece_closure.
154 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
155
0782db84
SM
1562017-09-12 Simon Marchi <simon.marchi@ericsson.com>
157
158 * probe.h (probe_ops_cp): Remove typedef.
159 (DEF_VEC_P (probe_ops_cp)): Remove.
160 (all_probe_ops): Change type to std::vector.
161 * probe.c (info_probes_for_ops): Adjust to vector change.
162 (probe_linespec_to_ops): Likewise.
163 (all_probe_ops): Change type to std::vector.
164 (_initialize_probe): Adjust to vector change.
165 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
166 * elfread.c (elf_get_probes): Likewise.
167 * stap-probe.c (_initialize_stap_probe): Likewise.
168
1eac6bea
SM
1692017-09-12 Simon Marchi <simon.marchi@ericsson.com>
170
171 * probe.h (struct bound_probe): Define constructors.
172 * probe.c (bound_probe_s): Remove typedef.
173 (DEF_VEC_O (bound_probe_s)): Remove VEC.
174 (collect_probes): Change return type to std::vector, remove
175 cleanup.
176 (compare_probes): Return bool, change parameter type. Change
177 semantic to "less than".
178 (gen_ui_out_table_header_info): Change parameter to std::vector
179 and update.
180 (exists_probe_with_pops): Likewise.
181 (info_probes_for_ops): Update to std::vector change.
182 (enable_probes_command): Likewise.
183 (disable_probes_command): Likewise.
184
aaa63a31
SM
1852017-09-12 Simon Marchi <simon.marchi@ericsson.com>
186
187 * probe.h (struct probe_ops) <get_probes>: Change parameter from
188 vec to std::vector.
189 * probe.c (parse_probes_in_pspace): Update.
190 (find_probes_in_objfile): Update.
191 (find_probe_by_pc): Update.
192 (collect_probes): Update.
193 (probe_any_get_probes): Update.
194 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
195 return type to reference to std::vector.
196 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
197 std::vector and update.
198 (dtrace_process_dof): Likewise.
199 (dtrace_get_probes): Likewise.
200 * elfread.c (elf_get_probes): Change return type to std::vector,
201 store an std::vector in bfd_data.
202 (probe_key_free): Update to std::vector.
203 * stap-probe.c (handle_stap_probe): Change parameter to
204 std::vector and update.
205 (stap_get_probes): Likewise.
206 * symfile-debug.c (debug_sym_get_probes): Change return type to
207 std::vector and update.
208
cb85b21b
TT
2092017-09-11 Tom Tromey <tom@tromey.com>
210
211 * breakpoint.c (program_breakpoint_here_p): Update.
212 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
213 from make_show_memory_breakpoints_cleanup. Return a
214 scoped_restore_tmpl<int>.
215 (restore_show_memory_breakpoints): Remove.
216 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
217 * mem-break.c (memory_validate_breakpoint): Update.
218 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
219 (ia64_memory_remove_breakpoint): Update.
220 (ia64_breakpoint_from_pc): Update.
221 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
222 from make_show_memory_breakpoints_cleanup.
223
8fbc99ef
TT
2242017-09-11 Tom Tromey <tom@tromey.com>
225
226 * d-namespace.c (d_lookup_symbol): Use std::string.
227 (find_symbol_in_baseclass): Likewise.
228
50feb4bd
TT
2292017-09-11 Tom Tromey <tom@tromey.com>
230
231 * ctf.c (ctf_start): Use std::string.
232
c6dc63a1
TT
2332017-09-11 Tom Tromey <tom@tromey.com>
234
235 * ada-lang.c (is_known_support_routine): Update.
236 (ada_unhandled_exception_name_addr_from_raise): Update.
237 * guile/scm-frame.c (gdbscm_frame_name): Update.
238 * python/py-frame.c (frapy_name): Update.
239 (frapy_function): Update.
240 * stack.h (find_frame_funname): Update.
241 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
242 (print_frame): Update.
243
d6b9b80f
TT
2442017-09-11 Tom Tromey <tom@tromey.com>
245
246 * findcmd.c (put_bits): Take a gdb::byte_vector.
247 (parse_find_args): Return gdb::byte_vector. "args" now const.
248 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
249 cleanups.
250 (find_command): Update.
251
a9921622
TT
2522017-09-11 Tom Tromey <tom@tromey.com>
253
254 * cli/cli-script.c (class scoped_restore_hook_in): New.
255 (clear_hook_in_cleanup): Remove.
256 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
257 scoped_restore_hook_in.
258
be0d7abb
TT
2592017-09-11 Tom Tromey <tom@tromey.com>
260
261 * cli/cli-script.c (restore_interp): Remove.
262 (read_command_lines): Use scoped_restore_interp.
263 * interps.c (scoped_restore_interp::set_temp): Rename from
264 interp_set_temp.
265 * interps.h (class scoped_restore_interp): New.
266 (interp_set_temp): Remove.
267
00f675ff
TT
2682017-09-11 Tom Tromey <tom@tromey.com>
269
270 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
271 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
272 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
273 scoped_restore.
274 (mi_cmd_break_insert_1): Update.
275 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
276 scoped_restore.
277
cb791d59
TT
2782017-09-11 Tom Tromey <tom@tromey.com>
279
280 * demangle.c (demangle_command): Update.
281 * breakpoint.c (disable_command): Update.
282 (enable_command): Update.
283 (find_location_by_number): Make "number" const. Use
284 get_number_trailer.
285 * cli/cli-utils.c (extract_arg): Return std::string.
286 * probe.c (parse_probe_linespec): Update. Change types.
287 (collect_probes): Take string arguments.
288 (parse_probe_linespec): Likewise.
289 (info_probes_for_ops): Update.
290 (enable_probes_command): Update.
291 (disable_probes_command): Update.
292 * break-catch-sig.c (catch_signal_split_args): Update.
293 * mi/mi-parse.c (mi_parse): Update.
294
2039bd9f
TT
2952017-09-11 Tom Tromey <tom@tromey.com>
296
297 * language.h (language_enum): Make argument const.
298 * language.c (language_enum): Make argument const.
299
f1735a53
TT
3002017-09-11 Tom Tromey <tom@tromey.com>
301
302 * common/common-utils.h (skip_to_space): Remove macro, redeclare
303 as function.
304 (skip_to_space): Rename from skip_to_space_const.
305 * common/common-utils.c (skip_to_space): New function.
306 (skip_to_space): Rename from skip_to_space_const.
307 * cli/cli-utils.h (get_number): Rename from get_number_const.
308 (extract_arg): Rename from extract_arg_const.
309 * cli/cli-utils.c (get_number): Rename from get_number_const.
310 (extract_arg): Rename from extract_arg_const.
311 (number_or_range_parser::get_number): Use ::get_number.
312 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
313 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
314 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
315 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
316 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
317 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
318 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
319 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
320
7d221d74
TT
3212017-09-11 Tom Tromey <tom@tromey.com>
322
323 * python/python.c (do_start_initialization): Use
324 py-event-types.def to initialize types.
325 Define all object type structures.
326 * python/python-internal.h: Don't declare event initialization
327 functions.
328 * python/py-threadevent.c (thread_event_object_type): Don't
329 define.
330 * python/py-stopevent.c (stop_event_object_type): Don't define.
331 * python/py-signalevent.c (signal_event_object_type): Don't
332 declare or define.
333 * python/py-newobjfileevent.c (new_objfile_event_object_type)
334 (clear_objfiles_event_object_type): Don't declare or define.
335 * python/py-infevents.c (inferior_call_pre_event_object_type)
336 (inferior_call_post_event_object_type)
337 (register_changed_event_object_type)
338 (memory_changed_event_object_type): Don't declare or define.
339 * python/py-inferior.c (new_thread_event_object_type)
340 (new_inferior_event_object_type)
341 (inferior_deleted_event_object_type): Don't declare or define.
342 * python/py-exitedevent.c (exited_event_object_type): Don't
343 declare or define.
344 * python/py-evts.c (gdbpy_initialize_py_events): Use
345 py-all-events.def.
346 * python/py-events.h (thread_event_object_type): Don't declare.
347 (events_object): Use py-all-events.def.
348 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
349 py-event-types.def.
350 * python/py-event-types.def: New file.
351 * python/py-continueevent.c (create_continue_event_object): Don't
352 declare or define.
353 * python/py-bpevent.c (breakpoint_event_object_type): Don't
354 declare or define.
355 * python/py-all-events.def: New file.
356
35c61a1d
TT
3572017-09-11 Tom Tromey <tom@tromey.com>
358
359 * python/py-threadevent.c (create_thread_event_object): Return
360 gdbpy_ref.
361 * python/py-stopevent.h (create_stop_event_object)
362 (create_breakpoint_event_object, create_signal_event_object):
363 Update.
364 * python/py-stopevent.c (create_stop_event_object): Return
365 gdbpy_ref.
366 (emit_stop_event): Update.
367 * python/py-signalevent.c (create_signal_event_object): Return
368 gdbpy_ref.
369 * python/py-infevents.c (create_inferior_call_event_object):
370 Update.
371 * python/py-event.h (create_event_object)
372 (create_thread_event_object): Update.
373 * python/py-event.c (create_event_object): Return gdbpy_ref.
374 * python/py-continueevent.c: Return gdbpy_ref.
375 * python/py-bpevent.c (create_breakpoint_event_object): Return
376 gdbpy_ref.
377
7c96f8c1
TT
3782017-09-11 Tom Tromey <tom@tromey.com>
379
380 PR python/15622:
381 * NEWS: Add entry.
382 * python/python.c (do_start_initialization): Initialize new event
383 types.
384 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
385 (gdbpy_initialize_inferior_deleted_event)
386 (gdbpy_initialize_new_thread_event): Declare.
387 * python/py-threadevent.c (create_thread_event_object): Add option
388 "thread" parameter.
389 * python/py-inferior.c (new_thread_event_object_type)
390 (new_inferior_event_object_type)
391 (inferior_deleted_event_object_type): Declare.
392 (python_new_inferior, python_inferior_deleted): New functions.
393 (add_thread_object): Emit new_thread event.
394 (gdbpy_initialize_inferior): Attach new functions to corresponding
395 observers.
396 (new_thread, new_inferior, inferior_deleted): Define new event
397 types.
398 * python/py-evts.c (gdbpy_initialize_py_events): Add new
399 registries.
400 * python/py-events.h (events_object) <new_inferior,
401 inferior_deleted, new_thread>: New fields.
402 * python/py-event.h (create_thread_event_breakpoint): Add optional
403 "thread" parameter.
404
72542b8e
AB
4052017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
406
407 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
408 check current_ui instead.
409 (internal_vproblem): Likewise.
410
0d64823e
SM
4112017-09-09 Simon Marchi <simon.marchi@ericsson.com>
412
413 * thread.c (print_thread_info_1): Remove unnecessary calls to
414 uiout->is_mi_like_p.
415
eb1e02fd
TT
4162017-09-09 Tom Tromey <tom@tromey.com>
417
418 * namespace.h (add_using_directive): Update.
419 * namespace.c (add_using_directive): Change type of excludes to
420 std::vector.
421 * dwarf2read.c (read_import_statement): Use std::vector.
422 (read_namespace): Update.
423 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
424
0fc21fd8
TT
4252017-09-09 Tom Tromey <tom@tromey.com>
426
427 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
428
49663d05
TT
4292017-09-09 Tom Tromey <tom@tromey.com>
430
431 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
432
0b868b60
TT
4332017-09-09 Tom Tromey <tom@tromey.com>
434
435 * stack.c (func_command): Use gdb::def_vector.
436
c0470d48
TT
4372017-09-09 Tom Tromey <tom@tromey.com>
438
439 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
440 ui_out_emit_list, ui_out_emit_tuple.
441 (mi_cmd_var_update): Likewise.
442
ca5909c7
TT
4432017-09-09 Tom Tromey <tom@tromey.com>
444
445 * mi/mi-interp.c (mi_user_selected_context_changed): Use
446 ui_out_redirect_pop.
447 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
448 ui_out_redirect_pop.
449 * utils.c (do_ui_out_redirect_pop)
450 (make_cleanup_ui_out_redirect_pop): Remove.
451 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
452 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
453 * ui-out.h (ui_out_redirect_pop): New class.
454
e6a2252a
TT
4552017-09-09 Tom Tromey <tom@tromey.com>
456
457 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
458 (list_available_thread_groups, mi_cmd_list_thread_groups)
459 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
460 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
461 Likewise.
462
393702cd
TT
4632017-09-09 Tom Tromey <tom@tromey.com>
464
465 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
466 ui_out_emit_tuple.
467
76f9c9cf
TT
4682017-09-09 Tom Tromey <tom@tromey.com>
469
470 * target.c (flash_erase_command): Use ui_out_emit_tuple.
471 * stack.c (print_frame): Use ui_out_emit_tuple.
472 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
473 (info_spu_mailbox_command, info_spu_dma_command)
474 (info_spu_proxydma_command): Likewise.
475 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
476 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
477 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
478 ui_out_emit_tuple.
479 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
480
dc9fe180
TT
4812017-09-09 Tom Tromey <tom@tromey.com>
482
483 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
484 (class ui_out_emit_table): Update comment.
485 * ui-out.c (do_cleanup_table_end)
486 (make_cleanup_ui_out_table_begin_end): Remove.
487 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
488 (info_spu_dma_cmdlist): Likewise.
489 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
490 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
491 ui_out_emit_table.
492
f8cc3da6
TT
4932017-09-09 Tom Tromey <tom@tromey.com>
494
495 * thread.c (print_thread_info_1): Use ui_out_emit_table,
496 ui_out_emit_list, gdb::optional.
497
481695ed
JB
4982017-09-09 John Baldwin <jhb@FreeBSD.org>
499
500 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
501 prototype.
502 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
503 prototype.
504 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
505 prototype.
506 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
507 * ada-exp.y: Remove _initialize_ada_exp prototype.
508 * ada-lang.c: Remove _initialize_ada_language prototype.
509 * ada-tasks.c: Remove _initialize_tasks prototype.
510 * addrmap.c: Remove _initialize_addrmap prototype.
511 * agent.c: Remove _initialize_agent prototype.
512 * aix-thread.c: Remove _initialize_aix_thread prototype.
513 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
514 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
515 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
516 prototype.
517 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
518 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
519 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
520 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
521 prototype.
522 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
523 prototype.
524 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
525 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
526 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
527 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
528 prototype.
529 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
530 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
531 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
532 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
533 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
534 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
535 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
536 prototype.
537 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
538 prototype.
539 * annotate.c: Remove _initialize_annotate prototype.
540 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
541 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
542 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
543 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
544 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
545 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
546 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
547 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
548 prototype.
549 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
550 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
551 * auto-load.c: Remove _initialize_auto_load prototype.
552 * auxv.c: Remove _initialize_auxv prototype.
553 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
554 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
555 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
556 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
557 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
558 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
559 prototype.
560 * break-catch-throw.c: Remove _initialize_break_catch_throw
561 prototype.
562 * breakpoint.c: Remove _initialize_breakpoint prototype.
563 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
564 * btrace.c: Remove _initialize_btrace prototype.
565 * charset.c: Remove _initialize_charset prototype.
566 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
567 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
568 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
569 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
570 * cli/cli-script.c: Remove _initialize_cli_script prototype.
571 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
572 * coffread.c: Remove _initialize_coffread prototype.
573 * compile/compile.c: Remove _initialize_compile prototype.
574 * complaints.c: Remove _initialize_complaints prototype.
575 * completer.c: Remove _initialize_completer prototype.
576 * copying.awk: Remove _initialize_copying prototype.
577 * copying.c: Regenerate.
578 * core-regset.c: Remove _initialize_core_regset prototype.
579 * corefile.c: Remove _initialize_core prototype.
580 * corelow.c: Remove _initialize_corelow prototype.
581 * cp-abi.c: Remove _initialize_cp_abi prototype.
582 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
583 * cp-support.c: Remove _initialize_cp_support prototype.
584 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
585 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
586 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
587 * ctf.c: Remove _initialize_ctf prototype.
588 * d-lang.c: Remove _initialize_d_language prototype.
589 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
590 prototype.
591 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
592 * dbxread.c: Remove _initialize_dbxread prototype.
593 * dcache.c: Remove _initialize_dcache prototype.
594 * demangle.c: Remove _initialize_demangler prototype.
595 * disasm-selftests.c: Remove _initialize_disasm_selftests
596 prototype.
597 * disasm.c: Remove _initialize_disasm prototype.
598 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
599 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
600 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
601 prototype.
602 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
603 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
604 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
605 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
606 * elfread.c: Remove _initialize_elfread prototype.
607 * exec.c: Remove _initialize_exec prototype.
608 * extension.c: Remove _initialize_extension prototype.
609 * f-lang.c: Remove _initialize_f_language prototype.
610 * f-valprint.c: Remove _initialize_f_valprint prototype.
611 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
612 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
613 * filesystem.c: Remove _initialize_filesystem prototype.
614 * findcmd.c: Remove _initialize_mem_search prototype.
615 * fork-child.c: Remove _initialize_fork_child prototype.
616 * frame-base.c: Remove _initialize_frame_base prototype.
617 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
618 * frame.c: Remove _initialize_frame prototype.
619 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
620 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
621 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
622 * gcore.c: Remove _initialize_gcore prototype.
623 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
624 * gdbarch.c: Regenerate.
625 * gdbarch.sh: Remove _initialize_gdbarch prototype.
626 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
627 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
628 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
629 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
630 * go-lang.c: Remove _initialize_go_language prototype.
631 * go32-nat.c: Remove _initialize_go32_nat prototype.
632 * guile/guile.c: Remove _initialize_guile prototype.
633 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
634 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
635 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
636 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
637 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
638 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
639 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
640 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
641 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
642 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
643 prototype.
644 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
645 prototype.
646 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
647 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
648 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
649 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
650 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
651 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
652 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
653 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
654 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
655 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
656 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
657 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
658 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
659 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
660 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
661 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
662 prototype.
663 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
664 prototype.
665 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
666 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
667 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
668 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
669 * infcall.c: Remove _initialize_infcall prototype.
670 * infcmd.c: Remove _initialize_infcmd prototype.
671 * inferior.c: Remove _initialize_inferiors prototype.
672 * inflow.c: Remove _initialize_inflow prototype.
673 * infrun.c: Remove _initialize_infrun prototype.
674 * interps.c: Remove _initialize_interpreter prototype.
675 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
676 * jit.c: Remove _initialize_jit prototype.
677 * language.c: Remove _initialize_language prototype.
678 * linux-fork.c: Remove _initialize_linux_fork prototype.
679 * linux-nat.c: Remove _initialize_linux_nat prototype.
680 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
681 * linux-thread-db.c: Remove _initialize_thread_db prototype.
682 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
683 * m2-lang.c: Remove _initialize_m2_language prototype.
684 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
685 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
686 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
687 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
688 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
689 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
690 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
691 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
692 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
693 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
694 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
695 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
696 * machoread.c: Remove _initialize_machoread prototype.
697 * macrocmd.c: Remove _initialize_macrocmd prototype.
698 * macroscope.c: Remove _initialize_macroscope prototype.
699 * maint.c: Remove _initialize_maint_cmds prototype.
700 * mdebugread.c: Remove _initialize_mdebugread prototype.
701 * memattr.c: Remove _initialize_mem prototype.
702 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
703 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
704 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
705 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
706 * mi/mi-main.c: Remove _initialize_mi_main prototype.
707 * microblaze-linux-tdep.c: Remove
708 _initialize_microblaze_linux_tdep prototype.
709 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
710 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
711 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
712 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
713 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
714 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
715 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
716 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
717 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
718 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
719 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
720 prototype.
721 * mipsread.c: Remove _initialize_mipsread prototype.
722 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
723 prototype.
724 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
725 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
726 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
727 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
728 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
729 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
730 prototype.
731 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
732 * nto-procfs.c: Remove _initialize_procfs prototype.
733 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
734 * objc-lang.c: Remove _initialize_objc_language prototype.
735 * objfiles.c: Remove _initialize_objfiles prototype.
736 * observer.c: Remove observer_test_first_notification_function,
737 observer_test_second_notification_function,
738 observer_test_third_notification_function, and
739 _initialize_observer prototypes.
740 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
741 * osabi.c: Remove _initialize_gdb_osabi prototype.
742 * osdata.c: Remove _initialize_osdata prototype.
743 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
744 * parse.c: Remove _initialize_parse prototype.
745 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
746 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
747 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
748 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
749 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
750 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
751 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
752 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
753 * printcmd.c: Remove _initialize_printcmd prototype.
754 * probe.c: Remove _initialize_probe prototype.
755 * proc-api.c: Remove _initialize_proc_api prototype.
756 * proc-events.c: Remove _initialize_proc_events prototype.
757 * proc-service.c: Remove _initialize_proc_service prototype.
758 * procfs.c: Remove _initialize_procfs prototype.
759 * psymtab.c: Remove _initialize_psymtab prototype.
760 * python/python.c: Remove _initialize_python prototype.
761 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
762 * record-btrace.c: Remove _initialize_record_btrace prototype.
763 * record-full.c: Remove _initialize_record_full prototype.
764 * record.c: Remove _initialize_record prototype.
765 * regcache.c: Remove _initialize_regcache prototype.
766 * reggroups.c: Remove _initialize_reggroup prototype.
767 * remote-notif.c: Remove _initialize_notif prototype.
768 * remote-sim.c: Remove _initialize_remote_sim prototype.
769 * remote.c: Remove _initialize_remote prototype.
770 * reverse.c: Remove _initialize_reverse prototype.
771 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
772 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
773 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
774 prototype.
775 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
776 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
777 * rust-exp.y: Remove _initialize_rust_exp prototype.
778 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
779 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
780 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
781 * score-tdep.c: Remove _initialize_score_tdep prototype.
782 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
783 prototype.
784 * ser-go32.c: Remove _initialize_ser_dos prototype.
785 * ser-mingw.c: Remove _initialize_ser_windows prototype.
786 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
787 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
788 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
789 * serial.c: Remove _initialize_serial prototype.
790 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
791 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
792 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
793 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
794 * skip.c: Remove _initialize_step_skip prototype.
795 * sol-thread.c: Remove _initialize_sol_thread prototype.
796 * solib-aix.c: Remove _initialize_solib_aix prototype.
797 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
798 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
799 * solib-frv.c: Remove _initialize_frv_solib prototype.
800 * solib-spu.c: Remove _initialize_spu_solib prototype.
801 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
802 * solib-target.c: Remove _initialize_solib_target prototype.
803 * solib.c: Remove _initialize_solib prototype.
804 * source.c: Remove _initialize_source prototype.
805 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
806 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
807 prototype.
808 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
809 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
810 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
811 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
812 prototype.
813 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
814 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
815 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
816 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
817 prototype.
818 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
819 prototype.
820 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
821 prototype.
822 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
823 prototype.
824 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
825 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
826 prototype.
827 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
828 prototype.
829 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
830 prototype.
831 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
832 prototype.
833 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
834 prototype.
835 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
836 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
837 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
838 * stabsread.c: Remove _initialize_stabsread prototype.
839 * stack.c: Remove _initialize_stack prototype.
840 * stap-probe.c: Remove _initialize_stap_probe prototype.
841 * std-regs.c: Remove _initialize_frame_reg prototype.
842 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
843 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
844 * symfile.c: Remove _initialize_symfile prototype.
845 * symmisc.c: Remove _initialize_symmisc prototype.
846 * symtab.c: Remove _initialize_symtab prototype.
847 * target-dcache.c: Remove _initialize_target_dcache prototype.
848 * target-descriptions.c: Remove _initialize_target_descriptions
849 prototype.
850 * thread.c: Remove _initialize_thread prototype.
851 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
852 prototype.
853 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
854 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
855 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
856 prototype.
857 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
858 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
859 * tracefile.c: Remove _initialize_tracefile prototype.
860 * tracepoint.c: Remove _initialize_tracepoint prototype.
861 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
862 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
863 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
864 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
865 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
866 * tui/tui-win.c: Remove _initialize_tui_win prototype.
867 * tui/tui.c: Remove _initialize_tui prototype.
868 * typeprint.c: Remove _initialize_typeprint prototype.
869 * user-regs.c: Remove _initialize_user_regs prototype.
870 * utils.c: Remove _initialize_utils prototype.
871 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
872 * valarith.c: Remove _initialize_valarith prototype.
873 * valops.c: Remove _initialize_valops prototype.
874 * valprint.c: Remove _initialize_valprint prototype.
875 * value.c: Remove _initialize_values prototype.
876 * varobj.c: Remove _initialize_varobj prototype.
877 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
878 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
879 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
880 * windows-nat.c: Remove _initialize_windows_nat,
881 _initialize_check_for_gdb_ini, and _initialize_loadable
882 prototypes.
883 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
884 * xcoffread.c: Remove _initialize_xcoffread prototype.
885 * xml-support.c: Remove _initialize_xml_support prototype.
886 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
887 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
888 prototype.
889 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
890 prototype.
891 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
892
a611b5cb
KS
8932017-09-08 Keith Seitz <keiths@redhat.com>
894
895 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
896 field.
897
469412dd
CW
8982017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
899
900 * f-valprint.c (f_val_print): Remove check for one byte
901 sized integers. Remove printing of character type.
902
a5ad232b
FP
9032017-09-08 Frank Penczek <frank.penczek@intel.com>
904 Christoph Weinmann <christoph.t.weinmann@intel.com>
905 Bernhard Heckel <bernhard.heckel@intel.com>
906
907 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
908 to maintain proper indentation when printing pointers/refs.
909
e5014227
JB
9102017-09-07 Joel Brobecker <brobecker@adacore.com>
911
912 GDB 8.0.1 released.
913
63c99141
JB
9142017-09-07 Joel Brobecker <brobecker@adacore.com>
915
916 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
917
69c1e056
TT
9182017-09-05 Tom Tromey <tom@tromey.com>
919
920 * parse.c (funcall_chain): Now a std::vector.
921 (start_arglist, end_arglist): Simplify.
922 (free_funcalls): Remove.
923 (parse_exp_in_context_1): Remove cleanup.
924
fef704bf
TT
9252017-09-05 Tom Tromey <tom@tromey.com>
926
927 * go-exp.y (go_parse): Don't create a cleanup.
928
5613c585
TT
9292017-09-05 Tom Tromey <tom@tromey.com>
930
931 * d-exp.y (PrimaryExpression): Use std::string.
932 (d_parse): Don't create a cleanup.
933
eae49211
TT
9342017-09-05 Tom Tromey <tom@tromey.com>
935
936 * utils.c (do_clear_parser_state): Remove.
937 (make_cleanup_clear_parser_state): Remove.
938 * p-exp.y (pascal_parse): Use scoped_restore.
939 * m2-exp.y (m2_parse): Use scoped_restore.
940 * f-exp.y (f_parse): Use scoped_restore.
941 * d-exp.y (d_parse): Use scoped_restore.
942 * c-exp.y (c_parse): Use scoped_restore.
943 * ada-exp.y (ada_parse): Use scoped_restore.
944 * utils.h (make_cleanup_clear_parser_state): Remove.
945
73b9be8b
KS
9462017-09-06 Keith Seitz <keiths@redhat.com>
947
948 * dwarf2read.c (dw2_linkage_name_attr): New function.
949 (dw2_linkage_name): New function.
950 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
951 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
952 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
953
a102602b
KR
9542017-09-06 Kamil Rytarowski <n54@gmx.com>
955
956 * config/djgpp/djconfig.sh: Correct shell portability issue.
957
28ad437d
KR
9582017-09-06 Kamil Rytarowski <n54@gmx.com>
959
960 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
961
351787dd
JB
9622017-09-06 John Baldwin <jhb@FreeBSD.org>
963
964 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
965 * NEWS: Mention new FreeBSD/mips native configuration.
966 * configure.host: Add aarch64*-*-freebsd*.
967 * configure.nat: Likewise.
968 * aarch64-fbsd-nat.c: New file.
969
c0f84956
JB
9702017-09-06 John Baldwin <jhb@FreeBSD.org>
971
972 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
973 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
974 * NEWS: Mention new FreeBSD/aarch64 target.
975 * configure.tgt: Add aarch64*-*-freebsd*.
976 * aarch64-fbsd-tdep.c: New file.
977 * aarch64-fbsd-tdep.h: New file.
978
7610297a
KR
9792017-09-06 Kamil Rytarowski <n54@gmx.com>
980
981 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
982
fbd1b771
JK
9832017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
984
985 * parse.c (find_minsym_type_and_address): Don't relocate addresses
986 of TLS symbols.
987
5ca79eae
PW
9882017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
989
990 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
991 call.
992
bf93d7ba
SM
9932017-09-05 Simon Marchi <simon.marchi@ericsson.com>
994
995 * infrun.c (follow_exec): Call add_thread after
996 target_find_description.
997
1bb7c059
SM
9982017-09-05 Simon Marchi <simon.marchi@ericsson.com>
999
1000 * infrun.c (handle_inferior_event_1): When exec'ing, read
1001 stop_pc after follow_exec.
1002
fc809827
SM
10032017-09-05 Simon Marchi <simon.marchi@ericsson.com>
1004
1005 * remote.c (process_g_packet): Update error message.
1006
d2fcdd85
YQ
10072017-09-05 Yao Qi <yao.qi@linaro.org>
1008
1009 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
1010 targets.
1011
e69570ee
PA
10122017-09-05 Pedro Alves <palves@redhat.com>
1013
1014 * eval.c (eval_call, evaluate_funcall): New functions, factored
1015 out from ...
1016 (evaluate_subexp_standard): ... this.
1017
22916b07
YQ
10182017-09-05 Yao Qi <yao.qi@linaro.org>
1019
1020 * amd64-tdep.c (amd64_target_description): Create target
1021 descriptions.
1022 (_initialize_amd64_tdep): Don't call functions
1023 initialize_tdesc_amd64_*. Add self tests.
1024 * arch/amd64.c (amd64_create_target_description): Add parameter
1025 is_linux. Call set_tdesc_osabi if is_linux is true.
1026 * arch/amd64.h (amd64_create_target_description): Update the
1027 declaration.
1028 * arch/i386.c (i386_create_target_description): Add parameter
1029 is_linux. Call set_tdesc_osabi if is_linux is true.
1030 * arch/i386.h (i386_create_target_description): Update
1031 declaration.
1032 * configure.tgt: Add i386.o to gdb_target_obs.
1033 * features/Makefile (XMLTOC): Remove i386/*.xml.
1034 * features/i386/amd64-avx-avx512.c: Remove.
1035 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
1036 * features/i386/amd64-avx-mpx.c: Remove.
1037 * features/i386/amd64-avx.c: Remove.
1038 * features/i386/amd64-mpx.c: Remove.
1039 * features/i386/amd64.c: Remove.
1040 * features/i386/i386-avx-avx512.c: Remove.
1041 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
1042 * features/i386/i386-avx-mpx.c: Remove.
1043 * features/i386/i386-avx.c: Remove.
1044 * features/i386/i386-mmx.c: Remove.
1045 * features/i386/i386-mpx.c: Remove.
1046 * features/i386/i386.c: Remove.
1047 * i386-tdep.c: Don't include features/i386/i386*.c., include
1048 target-descriptions.h and arch/i386.h.
1049 (i386_target_description): Create target descriptions.
1050 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
1051 functions. Do self tests.
1052
0854b7b1
YQ
10532017-09-05 Yao Qi <yao.qi@linaro.org>
1054
1055 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
1056 * features/i386/amd64-avx-avx512-linux.c: Removed.
1057 * features/i386/amd64-avx-linux.c: Removed.
1058 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
1059 * features/i386/amd64-avx-mpx-linux.c: Removed.
1060 * features/i386/amd64-linux.c: Removed.
1061 * features/i386/amd64-mpx-linux.c: Removed.
1062 * features/i386/x32-avx-avx512-linux.c: Removed.
1063 * features/i386/x32-avx-linux.c: Removed.
1064 * features/i386/x32-linux.c: Removed.
1065
b4570e4b
YQ
10662017-09-05 Yao Qi <yao.qi@linaro.org>
1067
1068 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
1069 features/i386/*.c.
1070 (amd64_linux_read_description): Call
1071 amd64_create_target_description.
1072 * arch/amd64.c: New file.
1073 * arch/amd64.h: New file.
1074 * configure.tgt (x86_64-*-linux*): Append amd64.o.
1075 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
1076
6c73f67f
YQ
10772017-09-05 Yao Qi <yao.qi@linaro.org>
1078
1079 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
1080 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
1081 (amd64_linux_read_description): Create target descriptions.
1082 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
1083 functions. Add unit tests.
1084 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
1085 x32-core.xml.
1086 * features/i386/64bit-avx.c: Generated.
1087 * features/i386/64bit-avx512.c: Generated.
1088 * features/i386/64bit-core.c: Generated.
1089 * features/i386/64bit-linux.c: Generated.
1090 * features/i386/64bit-mpx.c: Generated.
1091 * features/i386/64bit-pkeys.c: Generated.
1092 * features/i386/64bit-segments.c: Generated.
1093 * features/i386/64bit-sse.c: Generated.
1094 * features/i386/x32-core.c: Generated.
1095 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
1096 c files for amd64-linux and x32-linux.
1097
9d3d478b
YQ
10982017-09-05 Yao Qi <yao.qi@linaro.org>
1099
1100 * amd64-linux-tdep.c (amd64_linux_read_description): New
1101 function.
1102 (amd64_linux_core_read_description): Call
1103 amd64_linux_read_description.
1104 (amd64_linux_init_abi): Likewise.
1105 (amd64_x32_linux_init_abi): Likewise.
1106 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
1107 * x86-linux-nat.c (x86_linux_read_description): Call
1108 amd64_linux_read_description.
1109
b9f1d50f
YQ
11102017-09-05 Yao Qi <yao.qi@linaro.org>
1111
1112 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
1113 comments.
1114
188c9e6d
YQ
11152017-09-05 Yao Qi <yao.qi@linaro.org>
1116
1117 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
1118 * features/i386/i386-avx-avx512-linux.c: Remove.
1119 * features/i386/i386-avx-linux.c: Remove.
1120 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
1121 * features/i386/i386-avx-mpx-linux.c: Remove.
1122 * features/i386/i386-linux.c: Remove.
1123 * features/i386/i386-mmx-linux.c: Remove.
1124 * features/i386/i386-mpx-linux.c: Remove.
1125
5f035c07
YQ
11262017-09-05 Yao Qi <yao.qi@linaro.org>
1127
1128 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
1129 (SFILES): Add arch/i386.c.
1130 (HFILES_NO_SRCDIR): Add arch/i386.h.
1131 * arch/i386.c: New file.
1132 * arch/i386.h: New file.
1133 * arch/tdesc.h (allocate_target_description): Declare.
1134 (set_tdesc_architecture): Declare.
1135 (set_tdesc_osabi): Declare.
1136 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
1137 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
1138 include arch/i386.h.
1139 (i386_linux_read_description): Remove code and call
1140 i386_create_target_description.
1141 (set_tdesc_architecture): New function.
1142 (set_tdesc_osabi): New function.
1143 * target-descriptions.h (allocate_target_description): Remove.
1144
0abe8a89
YQ
11452017-09-05 Yao Qi <yao.qi@linaro.org>
1146
1147 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
1148 * target-descriptions.c (tdesc_create_feature): Likewise, and
1149 adjust code.
1150 * features/i386/32bit-avx.c: Re-generated.
1151 * features/i386/32bit-avx512.c: Re-generated.
1152 * features/i386/32bit-core.c: Re-generated.
1153 * features/i386/32bit-linux.c: Re-generated.
1154 * features/i386/32bit-mpx.c: Re-generated.
1155 * features/i386/32bit-pkeys.c: Re-generated.
1156 * features/i386/32bit-sse.c: Re-generated.
1157
0a188386
YQ
11582017-09-05 Yao Qi <yao.qi@linaro.org>
1159
1160 * regformats/regdef.h (struct reg): Override operator == and !=.
1161
f49ff000
YQ
11622017-09-05 Yao Qi <yao.qi@linaro.org>
1163
1164 * arch/tdesc.h: New file.
1165 * regformats/regdat.sh: Generate code using tdesc_create_reg.
1166 * target-descriptions.c: Update comments.
1167 * target-descriptions.h: Include "arch/tdesc.h". Remove the
1168 declarations.
1169 * features/i386/32bit-avx.c: Re-generated.
1170 * features/i386/32bit-avx512.c: Re-generated.
1171 * features/i386/32bit-core.c: Re-generated.
1172 * features/i386/32bit-linux.c: Re-generated.
1173 * features/i386/32bit-mpx.c: Re-generated.
1174 * features/i386/32bit-pkeys.c: Re-generated.
1175 * features/i386/32bit-sse.c: Re-generated.
1176
f7000548
YQ
11772017-09-05 Yao Qi <yao.qi@linaro.org>
1178
1179 * regformats/regdat.sh: Update generated code.
1180
c9a5e2a5
YQ
11812017-09-05 Yao Qi <yao.qi@linaro.org>
1182
1183 * regformats/regdat.sh: Adjust code order.
1184
d6b687ac
SM
11852017-09-05 Simon Marchi <simon.marchi@ericsson.com>
1186
1187 * expprint.c (dump_subexp_body_standard): Use constant format
1188 string in fprintf_filtered call.
1189
a379bfd0
JB
11902017-09-04 John Baldwin <jhb@FreeBSD.org>
1191
1192 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
1193 NetBSD/i386.
1194 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
1195
f7efc967
JB
11962017-09-04 John Baldwin <jhb@FreeBSD.org>
1197
1198 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
1199
c49fbc6c
JB
12002017-09-04 John Baldwin <jhb@FreeBSD.org>
1201
1202 * bsd-kvm.o: Define _KMEMUSER.
1203 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
1204 * configure: Regenerate.
1205
26562e73
JB
12062017-09-04 John Baldwin <jhb@FreeBSD.org>
1207
1208 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
1209 * i386-fbsd-nat.c: Likewise.
1210
31cf1487
JB
12112017-09-04 John Baldwin <jhb@FreeBSD.org>
1212
1213 * unittests/array-view-selftests.c: Add include of <array>.
1214
5b9f8a7c
JB
12152017-09-04 John Baldwin <jhb@FreeBSD.org>
1216
1217 * spu-tdep.c (flush_ea_cache): Add missing argument to
1218 call_function_by_hand.
1219
d69cf9b2
PA
12202017-09-04 Pedro Alves <palves@redhat.com>
1221
1222 * NEWS (Safer support for debugging with no debug info): New.
1223
3693fdb3
PA
12242017-09-04 Pedro Alves <palves@redhat.com>
1225
1226 * c-exp.y (function_method, function_method_void): Add current
1227 instance flags to TYPE_INSTANCE.
1228 * dwarf2read.c (check_modifier): New.
1229 (compute_delayed_physnames): Assert that only C++ adds delayed
1230 physnames. Mark fn_fields as const/volatile depending on
1231 physname.
1232 * eval.c (make_params): New type_instance_flags parameter. Use
1233 it as the new type's instance flags.
1234 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
1235 flags element and pass it to make_params.
1236 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
1237 instance flags element.
1238 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
1239 * gdbtypes.h: Include "enum-flags.h".
1240 (type_instance_flags): New enum-flags type.
1241 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
1242 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
1243 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
1244 (follow_type_instance_flags): New function.
1245 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
1246 * parser-defs.h (follow_type_instance_flags): Declare.
1247 * valops.c (value_struct_elt_for_reference): const/volatile must
1248 match too.
1249
e68cb8e0
PA
12502017-09-04 Pedro Alves <palves@redhat.com>
1251
1252 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
1253 function/method scopes; lookup the nested name as a function local
1254 static variable.
1255
858be34c
PA
12562017-09-04 Pedro Alves <palves@redhat.com>
1257
1258 (%type <voidval>): Add function_method.
1259 * c-exp.y (exp): New production for calls with no arguments.
1260 (function_method, function_method_void_or_typelist): New
1261 productions.
1262 (exp): New production for "method()::static_var".
1263 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
1264 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
1265 Handle OP_FUNC_STATIC_VAR.
1266 * parse.c (operator_length_standard):
1267 Handle OP_FUNC_STATIC_VAR.
1268
dd5901a6
PA
12692017-09-04 Pedro Alves <palves@redhat.com>
1270
1271 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
1272 handling.
1273 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
1274 Ditto.
1275 * parse.c (operator_length_standard, operator_check_standard):
1276 Ditto.
1277 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
1278
46a4882b
PA
12792017-09-04 Pedro Alves <palves@redhat.com>
1280
1281 * ax-gdb.c: Include "typeprint.h".
1282 (gen_expr_for_cast): New function.
1283 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
1284 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
1285 type is unknown.
1286 * dwarf2read.c (new_symbol_full): Fallback to int instead of
1287 nodebug_data_symbol.
1288 * eval.c: Include "typeprint.h".
1289 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
1290 Error out if symbol has unknown type.
1291 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
1292 evaluate_subexp_for_cast.
1293 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
1294 OP_VAR_MSYM_VALUE.
1295 (evaluate_subexp_for_cast): New function.
1296 * gdbtypes.c (init_nodebug_var_type): New function.
1297 (objfile_type): Use it to initialize types of variables with no
1298 debug info.
1299 * typeprint.c (error_unknown_type): New.
1300 * typeprint.h (error_unknown_type): New declaration.
1301 * compile/compile-c-types.c (convert_type_basic): Handle
1302 TYPE_CODE_ERROR; warn and fallback to int for variables with
1303 unknown type.
1304
fe13dfec
PA
13052017-09-04 Pedro Alves <palves@redhat.com>
1306
1307 * eval.c (evaluate_var_value): New function, factored out from ...
1308 (evaluate_subexp_standard): ... here.
1309
d008ee21
PA
13102017-09-04 Pedro Alves <palves@redhat.com>
1311
1312 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
1313 Remove useless assignments to 'op'.
1314
827d0c51
PA
13152017-09-04 Pedro Alves <palves@redhat.com>
1316
1317 * eval.c (eval_skip_value): New function.
1318 (evaluate_subexp_standard): Use it.
1319
2c5a2be1
PA
13202017-09-04 Pedro Alves <palves@redhat.com>
1321
1322 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
1323 function name from symbol/minsym and pass it to
1324 error_call_unknown_return_type.
1325
74ea4be4
PA
13262017-09-04 Pedro Alves <palves@redhat.com>
1327
1328 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
1329 * ax-gdb.c (gen_msym_var_ref): New function.
1330 (gen_expr): Handle OP_VAR_MSYM_VALUE.
1331 * eval.c (evaluate_var_msym_value): New function.
1332 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
1333 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
1334 to call_function_by_hand.
1335 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
1336 Handle OP_VAR_MSYM_VALUE.
1337 (union exp_element) <msymbol>: New field.
1338 * minsyms.h (struct type): Forward declare.
1339 (find_minsym_type_and_address): Declare.
1340 * parse.c (write_exp_elt_msym): New function.
1341 (write_exp_msymbol): Delete, refactored as ...
1342 (find_minsym_type_and_address): ... this new function.
1343 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
1344 (operator_length_standard, operator_check_standard): Handle
1345 OP_VAR_MSYM_VALUE.
1346 * std-operator.def (OP_VAR_MSYM_VALUE): New.
1347
7022349d
PA
13482017-09-04 Pedro Alves <palves@redhat.com>
1349
1350 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
1351 TYPE_GNU_IFUNC specially here. Throw error if return type is
1352 unknown.
1353 * ada-typeprint.c (print_func_type): Handle functions with unknown
1354 return type.
1355 * c-typeprint.c (c_type_print_base): Handle functions and methods
1356 with unknown return type.
1357 * compile/compile-c-symbols.c (convert_symbol_bmsym)
1358 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
1359 * compile/compile-c-types.c: Include "objfiles.h".
1360 (convert_func): For functions with unknown return type, warn and
1361 default to int.
1362 * compile/compile-object-run.c (compile_object_run): Adjust call
1363 to call_function_by_hand_dummy.
1364 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
1365 call_function_by_hand.
1366 * eval.c (evaluate_subexp_standard): Adjust calls to
1367 call_function_by_hand. Handle functions and methods with unknown
1368 return type. Pass expect_type to call_function_by_hand.
1369 * f-typeprint.c (f_type_print_base): Handle functions with unknown
1370 return type.
1371 * gcore.c (call_target_sbrk): Adjust call to
1372 call_function_by_hand.
1373 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
1374 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
1375 an integer address type instead of nodebug.
1376 * guile/scm-value.c (gdbscm_value_call): Adjust call to
1377 call_function_by_hand.
1378 * infcall.c (error_call_unknown_return_type): New function.
1379 (call_function_by_hand): New "default_return_type" parameter.
1380 Pass it down.
1381 (call_function_by_hand_dummy): New "default_return_type"
1382 parameter. Use it instead of defaulting to int. If there's no
1383 default and the return type is unknown, throw an error. If
1384 there's a default return type, and the called function has no
1385 debug info, then assume the function is prototyped.
1386 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
1387 New "default_return_type" parameter.
1388 (error_call_unknown_return_type): New declaration.
1389 * linux-fork.c (call_lseek): Cast return type of lseek.
1390 (inferior_call_waitpid, checkpoint_command): Adjust calls to
1391 call_function_by_hand.
1392 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
1393 calls to call_function_by_hand.
1394 * m2-typeprint.c (m2_procedure): Handle functions with unknown
1395 return type.
1396 * objc-lang.c (lookup_objc_class, lookup_child_selector)
1397 (value_nsstring, print_object_command): Adjust calls to
1398 call_function_by_hand.
1399 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
1400 functions with unknown return type.
1401 (pascal_type_print_func_varspec_suffix): New function.
1402 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
1403 TYPE_CODE_METHOD>: Use it.
1404 * python/py-value.c (valpy_call): Adjust call to
1405 call_function_by_hand.
1406 * rust-lang.c (rust_evaluate_funcall): Adjust call to
1407 call_function_by_hand.
1408 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
1409 call_function_by_hand.
1410 * valops.c (value_allocate_space_in_inferior): Adjust call to
1411 call_function_by_hand.
1412 * typeprint.c (type_print_unknown_return_type): New function.
1413 * typeprint.h (type_print_unknown_return_type): New declaration.
1414
54990598
PA
14152017-09-04 Pedro Alves <palves@redhat.com>
1416
1417 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
1418 types with more than one parameter as prototyped.
1419
9a24775b
PA
14202017-09-04 Pedro Alves <palves@redhat.com>
1421
1422 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
1423 (disassemble_command): Use gdb_disassembly_flags instead of bare
1424 int.
1425 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
1426 (dump_insns, do_mixed_source_and_assembly_deprecated)
1427 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
1428 Use gdb_disassembly_flags instead of bare int.
1429 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
1430 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
1431 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
1432 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
1433 (enum gdb_disassembly_flag): ... values of this new enumeration.
1434 (gdb_disassembly_flags): Define.
1435 (gdb_disassembly)
1436 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
1437 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
1438 gdb_disassembly_flags instead of bare int.
1439 * record-btrace.c (btrace_insn_history)
1440 (record_btrace_insn_history, record_btrace_insn_history_range)
1441 (record_btrace_insn_history_from): Use gdb_disassembly_flags
1442 instead of bare int.
1443 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
1444 Use gdb_disassembly_flags instead of bare int.
1445 * target-debug.h (target_debug_print_gdb_disassembly_flags):
1446 Define.
1447 * target-delegates.c: Regenerate.
1448 * target.c (target_insn_history, target_insn_history_from)
1449 (target_insn_history_range): Use gdb_disassembly_flags instead of
1450 bare int.
1451 * target.h: Include "disasm.h".
1452 (struct target_ops) <to_insn_history, to_insn_history_from,
1453 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
1454 int.
1455 (target_insn_history, target_insn_history_from)
1456 (target_insn_history_range): Use gdb_disassembly_flags instead of
1457 bare int.
1458
80a65e9b
SM
14592017-09-04 Simon Marchi <simon.marchi@ericsson.com>
1460
1461 * cli/cli-script.c (build_command_line): For if/while commands,
1462 check whether args is empty.
1463
6b66338c
SM
14642017-09-04 Simon Marchi <simon.marchi@ericsson.com>
1465
1466 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
1467 (enum command_control_type): Likewise.
1468 (struct command_line): Likewise.
1469 (free_command_lines): Likewise.
1470 (struct command_lines_deleter): Likewise.
1471 (command_line_up): Likewise.
1472 (read_command_lines): Likewise.
1473 (read_command_lines_1): Likewise.
1474 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
1475 (enum command_control_type): Likewise.
1476 (struct command_line): Likewise.
1477 (free_command_lines): Likewise.
1478 (struct command_lines_deleter): Likewise.
1479 (command_line_up): Likewise.
1480 (read_command_lines): Likewise.
1481 (read_command_lines_1): Likewise.
1482 * breakpoint.h: Include cli/cli-script.h.
1483 * extension-priv.h: Likewise.
1484 * gdbcmd.h: Likewise.
1485
51abb421
PA
14862017-09-04 Pedro Alves <palves@redhat.com>
1487
1488 * ada-lang.c (is_known_support_routine): Move sal declaration to
1489 where it is initialized.
1490 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
1491 (parse_breakpoint_sals, decode_static_tracepoint_spec)
1492 (clear_command, update_static_tracepoint): Remove init_sal
1493 references. Move declarations closer to initializations.
1494 * cli/cli-cmds.c (list_command): Move sal declarations closer to
1495 initializations.
1496 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
1497 references. Move sal declarations closer to initializations.
1498 * frame.c (find_frame_sal): Return a symtab_and_line via function
1499 return instead of output parameter. Remove init_sal references.
1500 * frame.h (find_frame_sal): Return a symtab_and_line via function
1501 return instead of output parameter.
1502 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
1503 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
1504 instead of memset.
1505 (gdbscm_find_pc_line): Remove init_sal reference.
1506 * infcall.c (call_function_by_hand_dummy): Remove init_sal
1507 references. Move declarations closer to initializations.
1508 * infcmd.c (set_step_frame): Update. Move declarations closer to
1509 initializations.
1510 (finish_backward): Remove init_sal references. Move declarations
1511 closer to initializations.
1512 * infrun.c (process_event_stop_test, handle_step_into_function)
1513 (insert_hp_step_resume_breakpoint_at_frame)
1514 (insert_step_resume_breakpoint_at_caller): Likewise.
1515 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
1516 (symbol_to_sal): Likewise.
1517 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
1518 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
1519 to its initialization.
1520 * reverse.c (save_bookmark_command): Use new/delete. Remove
1521 init_sal references. Move declarations closer to initializations.
1522 * source.c (get_current_source_symtab_and_line): Remove brace
1523 initialization.
1524 (set_current_source_symtab_and_line): Now takes the sal by const
1525 reference. Remove brace initialization.
1526 (line_info): Remove init_sal reference.
1527 * source.h (set_current_source_symtab_and_line): Now takes a
1528 symtab_and_line via const reference.
1529 * stack.c (set_current_sal_from_frame): Adjust.
1530 (print_frame_info): Adjust.
1531 (get_last_displayed_sal): Return the sal via function return
1532 instead of via output parameter. Simplify.
1533 (frame_info): Adjust.
1534 * stack.h (get_last_displayed_sal): Return the sal via function
1535 return instead of via output parameter.
1536 * symtab.c (init_sal): Delete.
1537 (find_pc_sect_line): Remove init_sal references. Move
1538 declarations closer to initializations.
1539 (find_function_start_sal): Remove init_sal references. Move
1540 declarations closer to initializations.
1541 * symtab.h (struct symtab_and_line): In-class initialize all
1542 fields.
1543 * tracepoint.c (set_traceframe_context)
1544 (print_one_static_tracepoint_marker): Remove init_sal references.
1545 Move declarations closer to initializations.
1546 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
1547 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
1548 declarations closer to initializations.
1549 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
1550 init_sal references. Adjust.
1551
6c5b2ebe
PA
15522017-09-04 Pedro Alves <palves@redhat.com>
1553
1554 * ax-gdb.c (agent_command_1): Use range-for.
1555 * break-catch-throw.c (re_set_exception_catchpoint): Update.
1556 * breakpoint.c: Include "common/array-view.h".
1557 (init_breakpoint_sal, create_breakpoint_sal): Change sals
1558 parameter from struct symtabs_and_lines to
1559 array_view<symtab_and_line>. Adjust. Use range-for. Update.
1560 (breakpoint_sals_to_pc): Change sals parameter from struct
1561 symtabs_and_lines to std::vector reference.
1562 (check_fast_tracepoint_sals): Change sals parameter from struct
1563 symtabs_and_lines to std::array_view. Use range-for.
1564 (decode_static_tracepoint_spec): Return a std::vector instead of
1565 symtabs_and_lines. Update.
1566 (create_breakpoint): Update.
1567 (break_range_command, until_break_command, clear_command): Update.
1568 (base_breakpoint_decode_location, bkpt_decode_location)
1569 (bkpt_probe_create_sals_from_location)
1570 (bkpt_probe_decode_location, tracepoint_decode_location)
1571 (tracepoint_probe_decode_location)
1572 (strace_marker_create_sals_from_location): Return a std::vector
1573 instead of symtabs_and_lines.
1574 (strace_marker_create_breakpoints_sal): Update.
1575 (strace_marker_decode_location): Return a std::vector instead of
1576 symtabs_and_lines. Update.
1577 (update_breakpoint_locations): Change struct symtabs_and_lines
1578 parameters to gdb::array_view. Adjust.
1579 (location_to_sals): Return a std::vector instead of
1580 symtabs_and_lines. Update.
1581 (breakpoint_re_set_default): Use std::vector instead of struct
1582 symtabs_and_lines.
1583 (decode_location_default): Return a std::vector instead of
1584 symtabs_and_lines. Update.
1585 * breakpoint.h: Include "common/array-view.h".
1586 (struct breakpoint_ops) <decode_location>: Now returns a
1587 std::vector instead of returning a symtabs_and_lines via output
1588 parameter.
1589 (update_breakpoint_locations): Change sals parameters to use
1590 gdb::array_view.
1591 * cli/cli-cmds.c (edit_command, list_command): Update to use
1592 std::vector and gdb::array_view.
1593 (ambiguous_line_spec): Adjust to use gdb::array_view and
1594 range-for.
1595 (compare_symtabs): Rename to ...
1596 (cmp_symtabs): ... this. Change parameters to symtab_and_line
1597 const reference and adjust.
1598 (filter_sals): Rewrite using std::vector and standard algorithms.
1599 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
1600 (jump_command): Update to use std::vector.
1601 * linespec.c (struct linespec_state) <canonical_names>: Update
1602 comment.
1603 (add_sal_to_sals_basic): Delete.
1604 (add_sal_to_sals, filter_results, convert_results_to_lsals)
1605 (decode_line_2, create_sals_line_offset)
1606 (convert_address_location_to_sals, convert_linespec_to_sals)
1607 (convert_explicit_location_to_sals, parse_linespec)
1608 (event_location_to_sals, decode_line_full, decode_line_1)
1609 (decode_line_with_current_source)
1610 (decode_line_with_last_displayed, decode_objc)
1611 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
1612 (linespec_result::~linespec_result): Adjust to use std::vector
1613 instead of symtabs_and_lines.
1614 * linespec.h (linespec_sals::sals): Now a std::vector.
1615 (struct linespec_result): Use std::vector, bool, and in-class
1616 initialization.
1617 (decode_line_1, decode_line_with_current_source)
1618 (decode_line_with_last_displayed): Return std::vector.
1619 * macrocmd.c (info_macros_command): Use std::vector.
1620 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
1621 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
1622 std::vector.
1623 * probe.h (parse_probes): Return a std::vector.
1624 * python/python.c (gdbpy_decode_line): Use std::vector and
1625 gdb::array_view.
1626 * source.c (select_source_symtab, line_info): Use std::vector.
1627 * stack.c (func_command): Use std::vector.
1628 * symtab.h (struct symtabs_and_lines): Delete.
1629 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
1630
7c44b49c
PA
16312017-09-04 Pedro Alves <palves@redhat.com>
1632
1633 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1634 unittests/array-view-selftests.c.
1635 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
1636 * common/array-view.h: New file.
1637 * unittests/array-view-selftests.c: New file.
1638
e439fa14
PA
16392017-09-04 Pedro Alves <palves@redhat.com>
1640
1641 * cli/cli-cmds.c (edit_command): Pass message to
1642 ambiguous_line_spec.
1643 (list_command): Pass message to ambiguous_line_spec. Say
1644 "first"/"last" instead of "start" and "end" to be consistent with
1645 the manual.
1646 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
1647 them to print formatted message.
1648
7525b645
PA
16492017-09-04 Pedro Alves <palves@redhat.com>
1650
1651 * btrace.c (ftrace_add_pt): Pass btrace_insn to
1652 ftrace_update_insns by reference instead of pointer.
1653
badc0020
YQ
16542017-09-04 Yao Qi <yao.qi@linaro.org>
1655
1656 * i386-go32-tdep.c: Include x86-xstate.h.
1657 (i386_go32_init_abi): Call i386_target_description.
1658 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
1659 if xcr0 is X86_XSTATE_X87_MASK.
1660 * i386-tdep.h (tdesc_i386): Remove the declaration.
1661 (tdesc_i386_mmx): Likewise.
1662
d78bdb54
YQ
16632017-09-04 Yao Qi <yao.qi@linaro.org>
1664
1665 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
1666 X86_XSTATE_SSE_MASK instead of 0.
1667
ca1fa5ee
YQ
16682017-09-04 Yao Qi <yao.qi@linaro.org>
1669
1670 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
1671 i386_target_description.
1672 * i386-fbsd-nat.c (i386fbsd_read_description): Call
1673 i386_target_description.
1674 * i386-tdep.c (i386_gdbarch_init): Likewise.
1675
2434b019
YQ
16762017-09-04 Yao Qi <yao.qi@linaro.org>
1677
1678 * amd64-darwin-tdep.c: Include "x86-xstate.h".
1679 (x86_darwin_init_abi_64): Call amd64_target_description.
1680 * amd64-dicos-tdep.c: Likewise.
1681 * amd64-fbsd-nat.c: Likewise.
1682 * amd64-fbsd-tdep.c: Likewise.
1683 * amd64-nbsd-tdep.c: Likewise.
1684 * amd64-obsd-tdep.c: Likewise.
1685 * amd64-sol2-tdep.c: Likewise.
1686 * amd64-windows-tdep.c: Likewise.
1687 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
1688
0860c437
SM
16892017-09-04 Simon Marchi <simon.marchi@ericsson.com>
1690
1691 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
1692 (btrace_function) <insn>: Change type to use std::vector.
1693 * btrace.c (ftrace_debug, ftrace_call_num_insn,
1694 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
1695 ftrace_update_insns, ftrace_compute_global_level_offset,
1696 btrace_stitch_bts, btrace_clear, btrace_insn_get,
1697 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
1698 change to std::vector.
1699 (ftrace_update_insns): Adjust to change to std::vector, change
1700 type of INSN parameter.
1701 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
1702 * record-btrace.c (btrace_call_history_insn_range,
1703 btrace_compute_src_line_range,
1704 record_btrace_frame_prev_register): Adjust to change to
1705 std::vector.
1706 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
1707 to change to std::vector.
1708
0638b7f9
TT
17092017-09-03 Tom Tromey <tom@tromey.com>
1710
1711 * corefile.c (reopen_exec_file): Use std::string.
1712
8f84fb0e
TT
17132017-09-03 Tom Tromey <tom@tromey.com>
1714
1715 * compile/compile.c (compile_register_name_mangled): Return
1716 std::string.
1717 * compile/compile-loc2c.c (pushf_register_address): Update.
1718 (pushf_register): Update.
1719 * compile/compile-c-types.c (convert_array): Update.
1720 * compile/compile-c-symbols.c (generate_vla_size): Update.
1721 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
1722 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
1723 (convert_one_symbol): Update.
1724 (generate_c_for_for_one_variable): Update.
1725 * compile/compile-c-support.c (c_get_range_decl_name): Return a
1726 std::string.
1727 (generate_register_struct): Update.
1728 * compile/compile-internal.h (c_get_range_decl_name): Return a
1729 std::string.
1730 (compile_register_name_mangled): Return std::string.
1731
18e9961f
TT
17322017-09-03 Tom Tromey <tom@tromey.com>
1733
1734 * utils.c (perror_string): Return a std::string.
1735 (throw_perror_with_name, perror_warning_with_name): Update.
1736
45343786
TT
17372017-09-03 Tom Tromey <tom@tromey.com>
1738
1739 * demangle.c (demangle_command): Use std::string,
1740 unique_xmalloc_ptr.
1741
b57af503
TT
17422017-09-03 Tom Tromey <tom@tromey.com>
1743
1744 * cli/cli-setshow.c (do_set_command): Use std::string.
1745
6eecf35f
TT
17462017-09-03 Tom Tromey <tom@tromey.com>
1747
1748 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
1749
56496dd4
TT
17502017-09-03 Tom Tromey <tom@tromey.com>
1751
1752 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
1753
e91a1fa7
TT
17542017-09-03 Tom Tromey <tom@tromey.com>
1755
1756 * mi/mi-cmd-env.c (env_execute_cli_command): Use
1757 gdb::unique_xmalloc_ptr.
1758
7ffd83d7
TT
17592017-09-03 Tom Tromey <tom@tromey.com>
1760
1761 * thread.c (print_thread_info_1): Use string_printf.
1762 (thread_apply_command, thread_apply_all_command): Use
1763 std::string.
1764
1ccbe998
TT
17652017-09-03 Tom Tromey <tom@tromey.com>
1766
1767 * valprint.c (val_print_string): Update.
1768 * gdbcore.h (memory_error_message): Return std::string.
1769 * corefile.c (memory_error_message): Return std::string.
1770 (memory_error): Update.
1771 * breakpoint.c (insert_bp_location): Update.
1772
23fdd69e
SM
17732017-09-03 Simon Marchi <simon.marchi@ericsson.com>
1774
1775 * target/waitstatus.h (target_waitstatus_to_string): Change
1776 return type to std::string.
1777 * target/waitstatus.c (target_waitstatus_to_string): Return
1778 std::string.
1779 * target.h (target_waitstatus_to_string): Remove declaration.
1780 * infrun.c (resume, clear_proceed_status_thread,
1781 print_target_wait_results, do_target_wait, save_waitstatus,
1782 stop_all_threads): Adjust.
1783 * record-btrace.c (record_btrace_wait): Adjust.
1784 * target-debug.h
1785 (target_debug_print_struct_target_waitstatus_p): Adjust.
1786
5c811d30
JK
17872017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
1788
1789 PR gdb/22046
1790 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
1791 detection.
1792
0a2dde4a
SDJ
17932017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
1794
1795 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
1796 for setting/unsetting environment variables on the remote target.
1797 (New remote packets): Add entries for QEnvironmentHexEncoded,
1798 QEnvironmentUnset and QEnvironmentReset.
1799 * common/environ.c (gdb_environ::operator=): Extend method to
1800 handle m_user_set_env_list and m_user_unset_env_list.
1801 (gdb_environ::clear): Likewise.
1802 (match_var_in_string): Change type of first parameter from 'char
1803 *' to 'const char *'.
1804 (gdb_environ::set): Extend method to handle
1805 m_user_set_env_list and m_user_unset_env_list.
1806 (gdb_environ::unset): Likewise.
1807 (gdb_environ::clear_user_set_env): New method.
1808 (gdb_environ::user_set_envp): Likewise.
1809 (gdb_environ::user_unset_envp): Likewise.
1810 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
1811 m_user_unset_env_list on move constructor/assignment.
1812 (unset): Add new default parameter 'update_unset_list = true'.
1813 (clear_user_set_env): New method.
1814 (user_set_envp): Likewise.
1815 (user_unset_envp): Likewise.
1816 (m_user_set_env_list): New std::set.
1817 (m_user_unset_env_list): Likewise.
1818 * common/rsp-low.c (hex2str): New function.
1819 (bin2hex): New overload for bin2hex function.
1820 * common/rsp-low.c (hex2str): New prototype.
1821 (str2hex): New overload prototype.
1822 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
1823 QEnvironmentUnset and QEnvironmentReset.
1824 (remote_protocol_features): Add QEnvironmentHexEncoded,
1825 QEnvironmentUnset and QEnvironmentReset packets.
1826 (send_environment_packet): New function.
1827 (extended_remote_environment_support): Likewise.
1828 (extended_remote_create_inferior): Call
1829 extended_remote_environment_support.
1830 (_initialize_remote): Add QEnvironmentHexEncoded,
1831 QEnvironmentUnset and QEnvironmentReset packet configs.
1832 * unittests/environ-selftests.c (gdb_selftest_env_var):
1833 New variable.
1834 (test_vector_initialization): New function.
1835 (test_init_from_host_environ): Likewise.
1836 (test_reinit_from_host_environ): Likewise.
1837 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
1838 Likewise.
1839 (test_unset_set_empty_vector): Likewise.
1840 (test_vector_clear): Likewise.
1841 (test_std_move): Likewise.
1842 (test_move_constructor):
1843 (test_self_move): Likewise.
1844 (test_set_unset_reset): Likewise.
1845 (run_tests): Rewrite in terms of the functions above.
1846
654670a4
WP
18472017-08-31 Weimin Pan <weimin.pan@oracle.com>
1848
1849 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
1850 (adi_available): Use a temp variable of type CORE_ADDR as argument
1851 3 when calling target_auxv_search.
1852 (adi_normalize_address): Use masks and xor operators to calculate
1853 normalized address.
1854 (adi_read_versions, adi_write_versions, adi_print_versions)
1855 (do_examine, do_assign): Use paddress.
1856
7755ddb7
JB
18572017-08-29 John Baldwin <jhb@FreeBSD.org>
1858
1859 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
1860 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
1861 out of loop and add supply of FIR.
1862 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
1863 add collect of FIR.
1864
fd437cbc
SM
18652017-08-28 Simon Marchi <simon.marchi@ericsson.com>
1866
3804a343 1867 PR gdb/21827
fd437cbc
SM
1868 * cli/cli-script.c (define_command): Don't convert command name
1869 to lower case.
1870
988f6b3d
JB
18712017-08-25 Joel Brobecker <brobecker@adacore.com>
1872
1873 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
1874 Update all callers accordingly. Remove all code blocks handling
1875 the case where DISPP is not NULL.
1876
663c44ac
JK
18772017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
1878
1879 PR symtab/22003
1880 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
1881 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
1882 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
1883
f1902523
JK
18842017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
1885
1886 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
1887 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
1888 (read_comp_units_from_section): New parameter abbrev_section, use
1889 read_and_check_comp_unit_head, allocate signatured_type if needed.
1890 (create_all_comp_units): Update read_comp_units_from_section caller.
1891
87215ad1
SDJ
18922017-08-23 Pedro Alves <palves@redhat.com>
1893
1894 PR remote/21852
1895 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
1896 to null_ptid and switch to thread without reading the registers
1897 after adding the inferior.
1898
6e41ddec
JK
18992017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
1900
1901 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
1902 compile-gcc.
1903 * compile/compile.c (compile_gcc, show_compile_gcc): New.
1904 (compile_to_object): Implement compile_gcc.
1905 (_initialize_compile): Install "set compile-gcc". Initialize
1906 compile_gcc.
1907
e68c32d5
JK
19082017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
1909
1910 * compile/compile.c (compile_to_object): Conditionally call
1911 set_verbose. Conditionally call compile or compile_v0.
1912
58afddc6
WP
19132017-08-07 Weimin Pan <weimin.pan@oracle.com>
1914
1915 * sparc64-tdep.h: (adi_normalize_address): New export.
1916 * sparc-nat.h: (open_adi_tag_fd): New export.
1917 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
1918 * sparc64-linux-tdep.c:
1919 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
1920 (sparc64_linux_handle_segmentation_fault): New function.
1921 (sparc64_linux_init_abi): Register
1922 sparc64_linux_handle_segmentation_fault
1923 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
1924 (sparc64_addr_bits_remove): New function.
1925 (sparc64_init_abi): Register sparc64_addr_bits_remove.
1926 (MAX_PROC_NAME_SIZE): New macro.
1927 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
1928 (sparc64adilist): New variable.
1929 (adi_proc_list): New variable.
1930 (find_adi_info): New function.
1931 (add_adi_info): New function.
1932 (get_adi_info_proc): New function.
1933 (get_adi_info): New function.
1934 (info_adi_command): New function.
1935 (read_maps_entry): New function.
1936 (adi_available): New function.
1937 (adi_normalize_address): New function.
1938 (adi_align_address): New function.
1939 (adi_convert_byte_count): New function.
1940 (adi_tag_fd): New function.
1941 (adi_is_addr_mapped): New function.
1942 (adi_read_versions): New function.
1943 (adi_write_versions): New function.
1944 (adi_print_versions): New function.
1945 (do_examine): New function.
1946 (do_assign): New function.
1947 (adi_examine_command): New function.
1948 (adi_assign_command): New function.
1949 (_initialize_sparc64_adi_tdep): New function.
1950
11db9430
SM
19512017-08-22 Simon Marchi <simon.marchi@ericsson.com>
1952
1953 * breakpoint.c (breakpoints_info): Rename to ...
1954 (info_breakpoints_command): ... this.
1955 (watchpoints_info): Rename to ...
1956 (info_watchpoints_command): ... this.
1957 (tracepoints_info): Rename to ...
1958 (info_tracepoints_command): ... this.
1959 (_initialize_breakpoint): Adjust.
1960 * dcache.c (dcache_info): Rename to ...
1961 (info_display_command): ... this.
1962 (_initialize_dcache): Adjust.
1963 * frame.h (args_info): Rename to ...
1964 (info_args_command): ... this.
1965 (locals_info): Rename to ...
1966 (info_locals_command): ... this.
1967 * infcmd.c (nofp_registers_info): Rename to ...
1968 (info_registers_command): ... this.
1969 (float_info): Rename to ...
1970 (info_float_command): ... this.
1971 (program_info): Rename to ...
1972 (info_program_command): ... this.
1973 (all_registers_info): Rename to ...
1974 (info_all_registers_command): ... this.
1975 (vector_info): Rename to ...
1976 (info_vector_command): ... this.
1977 (float_info): Rename to ...
1978 (info_float_command): ... this.
1979 (_initialize_infcmd): Adjust.
1980 * inferior.h (term_info): Rename to ...
1981 (info_terminal_command): ... this.
1982 * inflow.c (term_info): Rename to ...
1983 (info_terminal_command): ... this.
1984 (_initialize_inflow): Adjust.
1985 * infrun.c (signals_info): Rename to ...
1986 (info_signals_command): ... this.
1987 (_initialize_infrun): Adjust.
1988 * objc-lang.c (classes_info): Rename to ...
1989 (info_classes_command): ... this.
1990 (selectors_info): Rename to ...
1991 (info_selectors_command): ... this.
1992 (_initialize_objc_language): Adjust.
1993 * printcmd.c (sym_info): Rename to ...
1994 (info_symbol_command): ... this.
1995 (address_info): Rename to ...
1996 (info_address_command): ... this.
1997 (display_info): Rename to ...
1998 (info_display_command): ... this.
1999 (_initialize_printcmd): Adjust.
2000 * reverse.c (bookmarks_info): Rename to ...
2001 (info_breakpoints_command): ... this.
2002 (_initialize_reverse): Adjust.
2003 * ser-go32.c (dos_info): Rename to ...
2004 (info_serial_command): ... this.
2005 (_initialize_ser_dos): Adjust.
2006 * skip.c (skip_info): Rename to ...
2007 (info_skip_command): ... this.
2008 (_initialize_step_skip): Adjust.
2009 * source.c (line_info): Rename to ...
2010 (info_line_command): ... this.
2011 (source_info): Rename to ...
2012 (info_source_command)
2013 * stack.c (frame_info): Rename to ...
2014 (info_frame_command): ... this.
2015 (locals_info): Rename to ...
2016 (info_locals_command): ... this.
2017 (args_info): Rename to ...
2018 (info_args_command): ... this.
2019 (_initialize_stack): Adjust.
2020 * symtab.c (sources_info): Rename to ...
2021 (info_sources_command): ... this.
2022 (variables_info): Rename to ...
2023 (info_variables_command): ... this.
2024 (functions_info): Rename to ...
2025 (info_functions_command): ... this.
2026 (types_info): Rename to ...
2027 (info_types_command): ... this.
2028 (_initialize_symtab): Adjust.
2029 * target.c (target_info): Rename to ...
2030 (info_target_command): ... this.
2031 (initialize_targets): Adjust.
2032 * tracepoint.c (tvariables_info): Rename to ...
2033 (info_tvariables_command): ... this.
2034 (scope_info): Rename to ...
2035 (info_scope_command): ... this.
2036 (trace_dump_actions): Adjust.
2037 (_initialize_tracepoint): Adjust.
2038
b270e6f9
TT
20392017-08-22 Tom Tromey <tom@tromey.com>
2040
2041 * breakpoint.h (install_breakpoint): Update.
2042 * breakpoint.c (add_solib_catchpoint): Update.
2043 (install_breakpoint): Change argument to a std::unique_ptr.
2044 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
2045 (create_breakpoint_sal, create_breakpoint): Update.
2046 (watch_command_1, catch_exec_command_1)
2047 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
2048 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
2049 Return the breakpoint.
2050 (set_raw_breakpoint_without_location, set_raw_breakpoint)
2051 (new_single_step_breakpoint): Update.
2052 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
2053 std::unique_ptr.
2054 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
2055 std::unique_ptr.
2056 * break-catch-sig.c (create_signal_catchpoint): Use
2057 std::unique_ptr.
2058 * ada-lang.c (create_ada_exception_catchpoint): Use
2059 std::unique_ptr.
2060
36bd8eaa
TT
20612017-08-22 Tom Tromey <tom@tromey.com>
2062
2063 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
2064
56f37645
TT
20652017-08-22 Tom Tromey <tom@tromey.com>
2066
2067 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
2068 (lookup_partial_symbol): Update.
2069
0b581c69
TT
20702017-08-22 Tom Tromey <tom@tromey.com>
2071
2072 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
2073 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
2074 (find_and_open_source, symtab_to_fullname): Update.
2075 * psymtab.c (psymtab_to_fullname): Update.
2076
14278e1f
TT
20772017-08-22 Tom Tromey <tom@tromey.com>
2078
2079 * exec.c (exec_file_attach): Update.
2080 * linux-thread-db.c (try_thread_db_load): Update.
2081 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
2082 * utils.c (gdb_realpath): Change return type.
2083 (gdb_realpath_keepfile): Update.
2084 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
2085 (_initialize_utils): Register the new self test.
2086 * source.c (openp): Update.
2087 (find_and_open_source): Update.
2088 * nto-tdep.c (nto_find_and_open_solib): Update.
2089 * main.c (set_gdb_data_directory): Update.
2090 (captured_main_1): Update.
2091 * dwarf2read.c (dwarf2_get_dwz_file): Update
2092 (dw2_map_symbol_filenames): Update.
2093 * auto-load.c (auto_load_safe_path_vec_update): Update.
2094 (filename_is_in_auto_load_safe_path_vec): Change type of
2095 "filename_realp".
2096 (auto_load_objfile_script): Update.
2097 (file_is_auto_load_safe): Update. Use std::string.
2098 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
2099
4971c9a7
TT
21002017-08-22 Tom Tromey <tom@tromey.com>
2101
2102 * utils.c (gdb_realpath_keepfile): Return a
2103 gdb::unique_xmalloc_ptr.
2104 * exec.c (exec_file_attach): Update.
2105 * utils.h (gdb_realpath_keepfile): Return a
2106 gdb::unique_xmalloc_ptr.
2107
e3e41d58
TT
21082017-08-22 Tom Tromey <tom@tromey.com>
2109
2110 * compile/compile.c (compile_file_command): Use
2111 gdb::unique_xmalloc_ptr, std::string.
2112 * utils.c (gdb_abspath): Change return type.
2113 * source.c (openp): Update.
2114 * objfiles.c (allocate_objfile): Update.
2115 * main.c (set_gdb_data_directory): Update.
2116 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
2117
0d999a6e
ZZ
21182017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
2119
2120 * cli-cmds.c (list_commands): List actual code around more than
2121 one location.
2122
329d5e7e
JB
21232017-08-21 John Baldwin <jhb@FreeBSD.org>
2124
2125 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
2126
bf223d3e
PA
21272017-08-21 Pedro Alves <palves@redhat.com>
2128
2129 PR gdb/19487
2130 * c-exp.y (variable production): Handle function aliases.
2131 * minsyms.c (msymbol_is_text): New function.
2132 * minsyms.h (msymbol_is_text): Declare.
2133 * symtab.c (find_function_alias_target): New function.
2134 * symtab.h (find_function_alias_target): Declare.
2135
c973d0aa
PA
21362017-08-21 Pedro Alves <palves@redhat.com>
2137
2138 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
2139 typedefs.
2140 * typeprint.c (whatis_exp): If handling "whatis", and expression
2141 is OP_TYPE, strip one typedef level. Otherwise don't strip
2142 typedefs here.
2143 * valops.c (value_cast): Save "to" type before resolving
2144 stubs/typedefs. Use that type as resulting value's type.
2145
2989a365
TT
21462017-08-18 Tom Tromey <tom@tromey.com>
2147 Pedro Alves <palves@redhat.com>
2148
2149 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
2150 * sol-thread.c (sol_thread_resume, sol_thread_wait)
2151 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
2152 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
2153 * proc-service.c (ps_xfer_memory): Use scoped_restore.
2154 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
2155 (linux_get_siginfo_data): Add "thread" argument. Use
2156 scoped_restore.
2157 * linux-nat.c (linux_child_follow_fork)
2158 (check_stopped_by_watchpoint): Use scoped_restore.
2159 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
2160 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
2161 (restore_inferior_ptid, save_inferior_ptid): Remove.
2162 * btrace.c (btrace_fetch): Use scoped_restore.
2163 * bsd-uthread.c (bsd_uthread_fetch_registers)
2164 (bsd_uthread_store_registers): Use scoped_restore.
2165 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
2166 scoped_restore.
2167 * aix-thread.c (aix_thread_resume, aix_thread_wait)
2168 (aix_thread_xfer_partial): Use scoped_restore.
2169 * inferior.h (save_inferior_ptid): Remove.
2170
e60eb288
YQ
21712017-08-18 Yao Qi <yao.qi@linaro.org>
2172
2173 PR tdep/21818
2174 * arm-tdep.c (gdb_print_insn_arm): Mark
2175 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
2176
6d580b63
YQ
21772017-08-18 Yao Qi <yao.qi@linaro.org>
2178
2179 * NEWS: Mention GDBserver's new option "--selftest".
2180 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
2181 * selftest.c: Move it to common/selftest.c.
2182 * selftest.h: Move it to common/selftest.h.
2183 * selftest-arch.c (reset): New function.
2184 (tests_with_arch): Call reset.
2185
86dcbf50
YQ
21862017-08-18 Yao Qi <yao.qi@linaro.org>
2187
2188 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
2189 instead of exception_fprintf and printf_filtered.
2190
7649770c
YQ
21912017-08-18 Yao Qi <yao.qi@linaro.org>
2192
2193 * selftest.c (register_self_test): Rename it to
2194 selftests::register_test.
2195 (run_self_tests): selftest::run_tests.
2196 * selftest.h: Update declarations.
2197 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
2198 selftests::register_test_foreach_arch.
2199 * selftest-arch.h: Update declaration.
2200 * aarch64-tdep.c: Update.
2201 * arm-tdep.c: Likewise.
2202 * disasm-selftests.c: Likewise.
2203 * dwarf2loc.c: Likewise.
2204 * dwarf2-frame.c: Likewise.
2205 * findvar.c: Likewise.
2206 * gdbarch-selftests.c: Likewise.
2207 * maint.c (maintenance_selftest): Likewise.
2208 * regcache.c: Likewise.
2209 * rust-exp.y: Likewise.
2210 * selftest-arch.c: Likewise.
2211 * unittests/environ-selftests.c: Likewise.
2212 * unittests/function-view-selftests.c: Likewise.
2213 * unittests/offset-type-selftests.c: Likewise.
2214 * unittests/optional-selftests.c: Likewise.
2215 * unittests/scoped_restore-selftests.c: Likewise.
2216 * utils-selftests.c: Likewise.
2217
b0cba12e
PA
22182017-08-17 Pedro Alves <palves@redhat.com>
2219
2220 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
2221 local.
2222
4c8aa72d
PA
22232017-08-17 Pedro Alves <palves@redhat.com>
2224
2225 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
2226 field.
2227 (reset_die_in_process): Delete, replaced by ...
2228 (process_die_scope): ... this new class. Make it responsible for
2229 freeing cu->line_header too.
2230 (process_die): Use process_die_scope.
2231 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
2232 cu->line_header_die_owner. Don't release the line header if it's
2233 owned by the CU.
2234 (setup_type_unit_groups): Make the CU/DIE own the line header.
2235 Don't release the line header here.
2236
ba713918
AL
22372017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
2238
2239 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
2240
44d0fb3a
RK
22412017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
2242
2243 * NEWS: Mention new shortcuts for nexti and stepi in TUI
2244 Single-Key mode
2245
a5afdb16
RK
22462017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
2247
2248 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
2249 mode command list.
2250
47613aeb
SH
22512017-08-15 Stafford Horne <shorne@gmail.com>
2252
2253 * MAINTAINERS (Write After Approval): Add Stafford Horne.
2254
9c3cc999
SH
22552017-08-15 Stafford Horne <shorne@gmail.com>
2256
2257 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
2258
206726fb
SDJ
22592017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
2260
2261 PR gdb/21954
2262 * infcmd.c (unset_environment_command): Use the 'clear' method on
2263 the environment instead of resetting it.
2264
0335ac6d
JB
22652017-08-15 John Baldwin <jhb@FreeBSD.org>
2266
2267 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
2268 platforms.
2269
d3abe1c8
TT
22702017-08-14 Tom Tromey <tom@tromey.com>
2271
2272 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
2273 (print_binary_chars): Likewise.
2274 (BITS_IN_BYTES): Remove.
2275
d6382fff
TT
22762017-08-14 Tom Tromey <tom@tromey.com>
2277
2278 PR gdb/21675
2279 * valprint.c (LOW_ZERO): Change value to 034.
2280 (print_octal_chars): Add static_asserts for octal constants.
2281 * printcmd.c (print_scalar_formatted): Add 'd' case.
2282
f978cb06
TT
22832017-08-11 Tom Tromey <tom@tromey.com>
2284
2285 * symfile.c (add_symbol_file_command): Use std::vector.
2286
2f5404b3
TT
22872017-08-14 Tom Tromey <tom@tromey.com>
2288
2289 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
2290 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
2291 std::move.
2292 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
2293
de7985c3
PA
22942017-08-11 Pedro Alves <palves@redhat.com>
2295
2296 * infrun.c (process_event_stop_test): Adjust
2297 function_name_is_marked_for_skip call.
2298 * skip.c: Include <list>.
2299 (skiplist_entry): Make it a class with private fields, and
2300 getters/setters.
2301 (skiplist_entry_chain): Delete.
2302 (skiplist_entries): New.
2303 (skiplist_entry_count): Delete.
2304 (highest_skiplist_entry_num): New.
2305 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
2306 (add_skiplist_entry): Delete.
2307 (skiplist_entry::skiplist_entry): New.
2308 (skiplist_entry::add_entry): New.
2309 (skip_file_command, skip_function): Adjust.
2310 (compile_skip_regexp): Delete.
2311 (skip_command): Don't compile regexp here. Adjust to use
2312 skiplist_entry::add_entry.
2313 (skip_info): Adjust to use range-for and getters.
2314 (skip_enable_command, skip_disable_command): Adjust to use
2315 range-for and setters.
2316 (skip_delete_command): Adjust to use std::list.
2317 (add_skiplist_entry): Delete.
2318 (skip_file_p): Delete, refactored as ...
2319 (skiplist_entry::do_skip_file_p): ... this new method.
2320 (skip_gfile_p): Delete, refactored as ...
2321 (skiplist_entry::do_gskip_file_p): ... this new method.
2322 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
2323 (skiplist_entry::skip_function_p): ... this new method.
2324 (function_name_is_marked_for_skip): Now returns bool, and takes
2325 the function sal by const reference. Adjust to use range-for and
2326 skiplist_entry methods.
2327 (_initialize_step_skip): Remove references to
2328 skiplist_entry_chain, skiplist_entry_count.
2329 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
2330 takes the function sal by const reference.
2331
be7d3cd5
YQ
23322017-08-11 Yao Qi <yao.qi@linaro.org>
2333
2334 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
2335 (dwarf2_frame_cache): Remove reset_cache_cleanup.
2336 (dwarf2_frame_cache):
2337 * frame-unwind.c (frame_unwind_try_unwinder): Catch
2338 RETURN_MASK_ALL and set *this_case to NULL.
2339 * frame-unwind.h: Update comments.
2340
1c90d9f0
YQ
23412017-08-11 Yao Qi <yao.qi@linaro.org>
2342
2343 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
2344 (dwarf2_frame_state_copy_regs): Remove.
2345 (dwarf2_frame_state_free_regs): Remove.
2346 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
2347 (dwarf2_restore_rule): Call method .alloc_regs instead of
2348 dwarf2_frame_state_alloc_regs.
2349 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
2350 constructor. Call std::move.
2351 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
2352 (dwarf2_frame_cache): Likewise.
2353
2354 [GDB_SELF_TEST]: Include selftest.h and
2355 selftest-arch.h.
2356 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
2357 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
2358 execute_cfa_program_test.
2359
2360 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
2361 copy ctor, assignment operator, move assignment.
2362 <alloc_regs>: New method.
2363 <swap>: New method.
2364 (struct dwarf2_frame_state): Delete dtor.
2365 (dwarf2_frame_state_alloc_regs): Remove declaration.
2366 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
2367 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
2368
afe37d6b
YQ
23692017-08-11 Yao Qi <yao.qi@linaro.org>
2370
2371 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
2372 (dwarf2_frame_state::dwarf2_frame_state): New.
2373 (dwarf2_frame_state::~dwarf2_frame_state): New.
2374 (dwarf2_fetch_cfa_info): Update.
2375 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
2376 rather than a pointer. Update code.
2377 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
2378 dtor.
2379 <data_align, code_align, retaddr_column>: Change them to const.
2380 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
2381 to bool.
2382
b348037f
YQ
23832017-08-11 Yao Qi <yao.qi@linaro.org>
2384
2385 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
2386 <loc.exp>: New field.
2387 * dwarf2-frame.c (execute_cfa_program): Update.
2388 (dwarf2_frame_prev_register): Update.
2389
e7c9de26
PA
23902017-08-10 Pedro Alves <palves@redhat.com>
2391
2392 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
2393
e8c6b620
JB
23942017-08-09 John Baldwin <jhb@FreeBSD.org>
2395
2396 * fbsd-nat.c (struct fbsd_fork_info): Remove.
2397 (fbsd_pending_children): Use std::list.
2398 (fbsd_remember_child): Likewise.
2399 (fbsd_is_child_pending): Likewise.
2400 (fbsd_pending_vfork_done): Use std::forward_list.
2401 (fbsd_add_vfork_done): Likewise.
2402 (fbsd_is_vfork_done_pending): Likewise.
2403 (fbsd_next_vfork_done): Likewise.
2404
e4a26669
JB
24052017-08-09 John Baldwin <jhb@FreeBSD.org>
2406
2407 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
2408 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
2409 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
2410 for `mapfilename'.
2411 (fbsd_xfer_partial): Use gdb::byte_vector.
af3881e6 2412 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
e4a26669 2413
142311d3
JB
24142017-08-09 John Baldwin <jhb@FreeBSD.org>
2415
2416 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
2417 "filestuff.h".
2418 (fbsd_find_memory_regions): Fix `mapfile' initialization.
2419
42fa2e0e
TT
24202017-08-09 Tom Tromey <tom@tromey.com>
2421
2422 * skip.c (skiplist_entry): New constructor.
2423 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
2424 (skiplist_entry::file_is_glob): Now bool.
2425 (skiplist_entry::file, skiplist_entry::function): Now
2426 std::string.
2427 (make_skip_entry): Return a unique_ptr. Use new.
2428 (free_skiplist_entry, free_skiplist_entry_cleanup)
2429 (make_free_skiplist_entry_cleanup): Remove.
2430 (skip_command, skip_disable_command, add_skiplist_entry)
2431 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
2432 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
2433 (function_name_is_marked_for_skip): Update.
2434 (skip_delete_command): Update. Use delete.
2435
cd3af38d
JW
24362017-08-09 Jiong Wang <jiong.wang@arm.com>
2437
2438 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
2439 (aarch64_linux_core_read_description): New function.
2440 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
2441
29592bde
PA
24422017-08-09 Pedro Alves <palves@redhat.com>
2443
2444 * cp-name-parser.y (cp_comp_to_string): Return a
2445 gdb::unique_xmalloc_ptr<char>.
2446 * cp-support.c (replace_typedefs_qualified_name)
2447 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
2448 (cp_canonicalize_string_full): Use op= instead of explicit
2449 convertion.
2450 (cp_class_name_from_physname, method_name_from_physname)
2451 (cp_func_name, cp_remove_params): Adjust to use
2452 gdb::unique_xmalloc_ptr<char>.
2453 * cp-support.h (cp_comp_to_string): Return a
2454 gdb::unique_xmalloc_ptr<char>.
2455 * python/py-type.c (typy_lookup_type): Adjust to use
2456 gdb::unique_xmalloc_ptr<char>.
2457
b3340438
L
24582017-08-09 H.J. Lu <hongjiu.lu@intel.com>
2459
2460 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
2461
e88e8651
YQ
24622017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
2463 Yao Qi <yao.qi@linaro.org>
2464
2465 * cp-support.c (cp_canonicalize_string_full): Use
2466 gdb::unique_xmalloc_ptr<char>.
2467 (cp_canonicalize_string): Likewise.
2468
f5a29eb0
YQ
24692017-08-09 Yao Qi <yao.qi@linaro.org>
2470
2471 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
2472 * regformats/i386/amd64-avx-avx512.dat: Remove.
2473 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
2474 * regformats/i386/amd64-avx-mpx.dat:Remove.
2475 * regformats/i386/amd64-avx.dat: Remove.
2476 * regformats/i386/amd64-mpx.dat: Remove.
2477 * regformats/i386/i386-avx-avx512.dat: Remove.
2478 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
2479 * regformats/i386/i386-avx-mpx.dat: Remove.
2480 * regformats/i386/i386-mmx.dat: Remove.
2481 * regformats/i386/i386-mpx.dat: Remove.
2482
57757c2f
YQ
24832017-08-09 Yao Qi <yao.qi@linaro.org>
2484
2485 * amd64-tdep.h (tdesc_x32): Remove the declaration.
2486 * amd64-tdep.c: Don't include features/i386/x32*.c.
2487 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
2488 functions.
2489 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
2490 and i386/x32-avx-avx512.
2491 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
2492 and i386/x32.xml.
2493 * features/i386/x32-avx-avx512.c: Removed.
2494 * features/i386/x32-avx-avx512.xml: Removed.
2495 * features/i386/x32-avx.c: Removed.
2496 * features/i386/x32-avx.xml: Removed.
2497 * features/i386/x32.c: Removed.
2498 * features/i386/x32.xml: Removed.
2499 * regformats/i386/x32-avx-avx512.dat: Removed.
2500 * regformats/i386/x32-avx.dat: Removed.
2501 * regformats/i386/x32.dat: Removed.
2502
ba7b109b
MR
25032017-08-07 Maciej W. Rozycki <macro@imgtec.com>
2504
2505 PR breakpoints/21886
2506 * mem-break.c (default_memory_insert_breakpoint): Use
2507 `->placed_address' rather than `->reqstd_address' for the
2508 breakpoint location.
2509
e347efc3
MR
25102017-08-07 Maciej W. Rozycki <macro@imgtec.com>
2511
2512 * arch-utils.c (default_print_insn): Remove arch/mach/endian
2513 assertions.
2514
0dba2a6c
MR
25152017-08-07 Maciej W. Rozycki <macro@imgtec.com>
2516
2517 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
2518 a union of `tdep_info', `tdesc_data' and `id'.
2519 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
2520 rather than `info.tdep_info'.
2521 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
2522 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
2523 * i386-tdep.c (i386_gdbarch_init): Likewise.
2524 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
2525 * mips-tdep.c (mips_gdbarch_init): Likewise.
2526 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
2527 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
2528 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
2529 `info.tdep_info'.
2530 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
2531 `info.tdep_info'.
2532 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
2533 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
2534 `info.tdep_info'.
2535 * spu-tdep.c (spu_gdbarch_init): Likewise.
2536 * gdbarch.h: Regenerate.
2537
16eb6b2d
LS
25382017-08-07 Leszek Swirski <leszeks@google.com>
2539
7b005726 2540 PR symtab/20899
16eb6b2d
LS
2541 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
2542
74cbb09e
SM
25432017-08-07 Simon Marchi <simon.marchi@ericsson.com>
2544
2545 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
2546 (gdbsim_open): Rename gdb_argv args object to argv.
2547
ee0c3293
TT
25482017-08-05 Tom Tromey <tom@tromey.com>
2549
2550 * compile/compile-object-load.c (compile_object_load): Use
2551 gdb::unique_xmalloc_ptr.
2552 * cli/cli-dump.c (scan_filename): Rename from
2553 scan_filename_with_cleanup. Change return type.
2554 (scan_expression): Rename from scan_expression_with_cleanup.
2555 Change return type.
2556 (dump_memory_to_file, dump_value_to_file, restore_command):
2557 Use gdb::unique_xmalloc_ptr. Update.
2558 * cli/cli-cmds.c (find_and_open_script): Use
2559 gdb::unique_xmalloc_ptr.
2560 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
2561 * symmisc.c (maintenance_print_symbols)
2562 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
2563 * symfile.c (symfile_bfd_open, generic_load)
2564 (add_symbol_file_command, remove_symbol_file_command): Use
2565 gdb::unique_xmalloc_ptr.
2566 * source.c (openp): Use gdb::unique_xmalloc_ptr.
2567 * psymtab.c (maintenance_print_psymbols): Use
2568 gdb::unique_xmalloc_ptr.
2569 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
2570 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
2571 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
2572 (reload_shared_libraries_1): Likewise.
2573
3232fabd
TT
25742017-08-05 Tom Tromey <tom@tromey.com>
2575
2576 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
2577 (rust_op_vector, rust_set_vector): New typedefs.
2578 (current_parser): New global.
2579 (work_obstack): Change to pointer type. Update all users.
2580 (rust_ast, pstate): Remove globals.
2581 (struct rust_parser): New.
2582 (%union) <params, field_inits>: Change type.
2583 (start, tuple_expr, unit_expr, struct_expr_list, literal)
2584 (field_expr, expr_list, maybe_expr_list, type_list): Update.
2585 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
2586 (convert_params_to_types, convert_params_to_expression): Change
2587 type of "params".
2588 (ast_string): Change type of "fields".
2589 (rust_parse): Make a rust_parser. Remove cleanups.
2590 (rust_lex_tests): Make and install an auto_obstack.
2591
f02fd774
YQ
25922017-08-04 Yao Qi <yao.qi@linaro.org>
2593
2594 * configure.srv (ipa_x32_linux_regobj): New.
2595 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
2596 instead of X86_TDESC_AVX512.
2597 (initialize_low_tracepoint): Call
2598 init_registers_x32_avx_avx512_linux.
2599
91975afd
YQ
26002017-08-04 Yao Qi <yao.qi@linaro.org>
2601
2602 * utils.h (gdb_argv): Add namespace std for nullptr_t.
2603
2331fa3a
RK
26042017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
2605
2606 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
2607
744e4fe1
TT
26082017-08-03 Tom Tromey <tom@tromey.com>
2609
2610 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
2611 Remove.
2612 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
2613
1c034b67
TT
26142017-08-03 Tom Tromey <tom@tromey.com>
2615
2616 * python/py-param.c (compute_enum_values): Use gdb_argv.
2617
773a1edc
TT
26182017-08-03 Tom Tromey <tom@tromey.com>
2619
2620 * utils.h (struct gdb_argv_deleter): New.
2621 (gdb_argv): New class.
2622 * utils.c (gdb_argv::reset): New method.
2623 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
2624 * tracefile.c (tsave_command): Use gdb_argv.
2625 * top.c (new_ui_command): Use gdb_argv.
2626 * symmisc.c (maintenance_print_symbols)
2627 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
2628 * symfile.c (symbol_file_command, generic_load)
2629 (remove_symbol_file_command): Use gdb_argv.
2630 * stack.c (backtrace_command): Use gdb_argv.
2631 * source.c (add_path, show_substitute_path_command)
2632 (unset_substitute_path_command, set_substitute_path_command):
2633 Use gdb_argv.
2634 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
2635 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
2636 * remote.c (extended_remote_run, remote_put_command)
2637 (remote_get_command, remote_delete_command): Use gdb_argv.
2638 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
2639 (gdbsim_open): Use gdb_argv.
2640 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
2641 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
2642 * procfs.c (procfs_info_proc): Use gdb_argv.
2643 * interps.c (interpreter_exec_cmd): Use gdb_argv.
2644 * infrun.c (handle_command): Use gdb_argv.
2645 * inferior.c (add_inferior_command, clone_inferior_command):
2646 Use gdb_argv.
2647 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
2648 * exec.c (exec_file_command): Use gdb_argv.
2649 * cli/cli-cmds.c (alias_command): Use gdb_argv.
2650 * compile/compile.c (build_argc_argv): Use gdb_argv.
2651
0d50bde3
TT
26522017-08-03 Tom Tromey <tom@tromey.com>
2653
2654 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
2655
7f968c89
TT
26562017-08-03 Tom Tromey <tom@tromey.com>
2657
2658 * python/python.c (compute_python_string): Return std::string.
2659 (gdbpy_eval_from_control_command): Update.
2660 (do_start_initialization): Use std::string.
2661 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
2662 xstrprintf.
2663 * python/py-breakpoint.c (local_setattro): Use string_printf, not
2664 xstrprintf.
2665
3c9ebddd
TT
26662017-08-03 Tom Tromey <tom@tromey.com>
2667
2668 * top.h (do_restore_instream_cleanup): Remove.
2669 * top.c (do_restore_instream_cleanup): Remove.
2670 (read_command_file): Use scoped_restore.
2671 * cli/cli-script.c (execute_user_command): Use scoped_restore.
2672
b51b225e
TT
26732017-08-03 Tom Tromey <tom@tromey.com>
2674
2675 * cli/cli-script.c (execute_user_command)
2676 (execute_control_command): Use scoped_restore.
2677
ac991630
TT
26782017-08-03 Tom Tromey <tom@tromey.com>
2679
2680 * cli/cli-script.c (do_restore_user_call_depth): Remove.
2681 (execute_user_command): Remove user_call_depth; use
2682 user_args_stack's size instead.
2683
898e0c8e
TT
26842017-08-03 Tom Tromey <tom@tromey.com>
2685
2686 * top.h (in_user_command): Remove.
2687 * top.c (in_user_command): Remove.
2688 * cli/cli-script.c (do_restore_user_call_depth)
2689 (execute_user_command): Update.
2690
26fcd5d7
TT
26912017-08-03 Tom Tromey <tom@tromey.com>
2692
2693 * valops.c (search_struct_method): Use gdb::byte_vector.
2694 * valarith.c (value_concat): Use std::vector.
2695 * target.c (memory_xfer_partial): Use gdb::byte_vector.
2696 (simple_search_memory): Likewise.
2697 * printcmd.c (find_string_backward): Use gdb::byte_vector.
2698 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
2699 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
2700 * elfread.c (elf_rel_plt_read): Use std::string.
2701 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
2702 * cli/cli-dump.c (restore_section_callback): Use
2703 gdb::byte_vector.
2704
7c218e6c
TT
27052017-08-03 Tom Tromey <tom@tromey.com>
2706
2707 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
2708
31b68d4a
TT
27092017-08-03 Tom Tromey <tom@tromey.com>
2710
2711 * tui/tui-regs.c (tui_restore_gdbout): Remove.
2712 (tui_register_format): Use scoped_restore.
2713
2ec845e7
TT
27142017-08-03 Tom Tromey <tom@tromey.com>
2715
2716 * reverse.c (exec_direction_default): Remove.
2717 (exec_reverse_once): Use scoped_restore.
2718 * remote.c (restore_remote_timeout): Remove.
2719 (remote_flash_erase, remote_flash_write, remote_flash_done)
2720 (readchar, remote_serial_write): Use scoped_restore.
2721 * cli/cli-script.c (struct source_cleanup_lines_args)
2722 (source_cleanup_lines): Remove.
2723 (script_from_file): Use scoped_restore.
2724 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
2725 (source_command): Use scoped_restore.
2726
b3bc8453
TT
27272017-08-03 Tom Tromey <tom@tromey.com>
2728
2729 * utils.h (make_cleanup_free_so): Remove.
2730 * utils.c (do_free_so, make_cleanup_free_so): Remove.
2731 * solist.h (struct so_deleter): New.
2732 (so_list_up): New typedef.
2733 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
2734
e3ad2841
TT
27352017-08-03 Tom Tromey <tom@tromey.com>
2736
2737 * utils.h (make_cleanup_restore_current_language): Remove.
2738 * utils.c (do_restore_current_language)
2739 (make_cleanup_restore_current_language): Remove.
2740 * parse.c (parse_exp_in_context_1)
2741 (parse_expression_with_language): Use
2742 scoped_restore_current_language.
2743 * mi/mi-main.c (mi_cmd_execute): Use
2744 scoped_restore_current_language.
2745 * language.h (scoped_restore_current_language): New class.
2746
b80cf838
TT
27472017-08-03 Tom Tromey <tom@tromey.com>
2748
2749 * compile/compile.c (cleanup_unlink_file): Remove.
2750 (compile_to_object): Use gdb::unlinker.
2751 (eval_compile_command): Likewise.
2752
fad0444a
TT
27532017-08-03 Tom Tromey <tom@tromey.com>
2754
2755 * utils.h (make_cleanup_fclose): Remove.
2756 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
2757
6e7bc05c
TT
27582017-08-03 Tom Tromey <tom@tromey.com>
2759
2760 * top.c (open_terminal_stream): Return gdb_file_up.
2761 (new_ui_command): Update.
2762
4a45905b
TT
27632017-08-03 Tom Tromey <tom@tromey.com>
2764
2765 * source.c (print_source_lines_base, forward_search_command)
2766 (reverse_search_command): Use gdb_file_up.
2767
7cd06d6e
TT
27682017-08-03 Tom Tromey <tom@tromey.com>
2769
2770 * fbsd-nat.c (fbsd_find_memory_regions): Update.
2771
ed166945
TT
27722017-08-03 Tom Tromey <tom@tromey.com>
2773
2774 * cli/cli-cmds.c (find_and_open_script): Change return type.
2775 Remove "streamp" and "full_path" parameters.
2776 (source_script_with_search): Update.
2777 * auto-load.c (source_script_file): Update.
2778 * cli/cli-cmds.h (find_and_open_script): Change type.
2779 (open_script): New struct.
2780
d419f42d
TT
27812017-08-03 Tom Tromey <tom@tromey.com>
2782
2783 * xml-support.c (xml_fetch_content_from_file): Update.
2784 * ui-file.c (stdio_file::open): Update.
2785 * tracefile-tfile.c (tfile_start): Update.
2786 * remote.c (remote_file_put, remote_file_get): Update.
2787 * nat/linux-procfs.c (linux_proc_get_int)
2788 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
2789 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
2790 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
2791 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
2792 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
2793 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
2794 * linux-nat.c (linux_proc_pending_signals): Update.
2795 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
2796 (file_closer): Remove.
2797 * compile/compile.c (compile_to_object): Update.
2798 * common/filestuff.h (struct gdb_file_deleter): New.
2799 (gdb_file_up): New typedef.
2800 (gdb_fopen_cloexec): Change return type.
2801 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
2802 * cli/cli-dump.c (fopen_with_cleanup): Remove.
2803 (dump_binary_file, restore_binary_file): Update.
2804 * auto-load.c (auto_load_objfile_script_1): Update.
2805
4a2b031d
TT
28062017-08-03 Tom Tromey <tom@tromey.com>
2807
2808 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
2809 (info_static_tracepoint_markers_command): Likewise.
2810 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
2811 * skip.c (skip_info): Use ui_out_emit_table.
2812 * progspace.c (print_program_space): Use ui_out_emit_table.
2813 * osdata.c (info_osdata): Use ui_out_emit_table.
2814 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
2815 ui_out_emit_table.
2816 * linux-thread-db.c (info_auto_load_libthread_db): Use
2817 ui_out_emit_table.
2818 * inferior.c (print_inferior): Use ui_out_emit_table.
2819 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
2820 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
2821 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
2822 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
2823 * ui-out.h (class ui_out_emit_table): New.
2824
a4f320fd
MR
28252017-08-02 Maciej W. Rozycki <macro@imgtec.com>
2826
2827 * mips-tdep.c (mips_fpu_type_str): New function.
2828 (mips_dump_tdep): Call it.
2829
a2f1f308
MR
28302017-08-01 Maciej W. Rozycki <macro@imgtec.com>
2831
2832 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
2833 `->mips_fpu_type'.
2834
7e5ed83b
XR
28352017-07-31 Xavier Roirand <roirand@adacore.com>
2836
2837 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
2838
4c9dc811
XR
28392017-07-27 Xavier Roirand <roirand@adacore.com>
2840
2841 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
2842
27d41eac
YQ
28432017-07-26 Yao Qi <yao.qi@linaro.org>
2844
2845 * cli/cli-cmds.c (maintenancechecklist): New variable.
2846 * gdbcmd.h (maintenancechecklist): Declare it.
2847 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
2848 Call i386_linux_read_description with different masks.
2849 * maint.c (maintenance_check_command): New function.
2850 (_initialize_maint_cmds): Call add_prefix_cmd.
2851 * target-descriptions.c (tdesc_reg): override operator != and ==.
2852 (tdesc_type): Likewise.
2853 (tdesc_feature): Likewise.
2854 (target_desc): Likewise.
2855 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
2856 (maintenance_check_xml_descriptions): New function.
2857 (_initialize_target_descriptions) Add command "xml-descriptions".
2858 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
2859
ea03d0d3
YQ
28602017-07-26 Yao Qi <yao.qi@linaro.org>
2861
2862 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
2863 Include features/i386/32bit-*.c.
2864 (i386_linux_read_description): Generate target description if it
2865 doesn't exist.
2866 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
2867 functions.
2868 * features/i386/32bit-linux.c: Re-generated.
2869 * features/i386/32bit-sse.c: Likewise.
2870 * target-descriptions.c (print_c_feature::visit): Print code to
2871 set register number if needed.
2872 (print_c_feature) <m_next_regnum>: New field.
2873
25aa13e5
YQ
28742017-07-26 Yao Qi <yao.qi@linaro.org>
2875
2876 * features/Makefile (CFILES): Rename with TDESC_CFILES.
2877 (FEATURE_XMLFILES): New.
2878 (FEATURE_CFILES): New.
2879 New rules.
2880 (clean-cfiles): Remove generated c files.
2881 * features/i386/32bit-avx.c: Generated.
2882 * features/i386/32bit-avx512.c: Generated.
2883 * features/i386/32bit-core.c: Generated.
2884 * features/i386/32bit-linux.c: Generated.
2885 * features/i386/32bit-mpx.c: Generated.
2886 * features/i386/32bit-pkeys.c: Generated.
2887 * features/i386/32bit-sse.c: Generated.
2888 * target-descriptions.c: Include algorithm.
2889 (tdesc_element_visitor): Add method visit_end.
2890 (print_c_tdesc): Implement visit_end.
2891 (print_c_tdesc:: m_filename_after_features): Move it to
2892 protected.
2893 (print_c_feature): New class.
2894 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
2895 name starts with "i386/32bit-".
2896
6eb1e6a8
YQ
28972017-07-26 Yao Qi <yao.qi@linaro.org>
2898
2899 * target-descriptions.c (tdesc_element_visitor): New class.
2900 (tdesc_element): New class.
2901 (tdesc_reg): Inherit from tdesc_element.
2902 (tdesc_reg::accept): New function.
2903 (tdesc_type): Inherit from tdesc_element.
2904 (tdesc_type::accept): New function.
2905 (tdesc_feature): Inherit from tdesc_element.
2906 (tdesc_feature::accept): New function.
2907 (target_desc): Inherit from tdesc_element.
2908 (target_desc::target_desc): New.
2909 (target_desc::~target_desc): New.
2910 (target_desc::accept): New.
2911 (allocate_target_description): Use new.
2912 (free_target_description): Use delete.
2913 (print_c_tdesc): New class.
2914 (maint_print_c_tdesc_cmd): Adjust.
2915
2916 * features/aarch64.c: Re-generated.
2917 * features/arc-arcompact.c: Re-generated.
2918 * features/arc-v2.c: Re-generated.
2919 * features/arm/arm-with-iwmmxt.c: Re-generated.
2920 * features/arm/arm-with-m.c: Re-generated.
2921 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
2922 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
2923 * features/arm/arm-with-neon.c: Re-generated.
2924 * features/arm/arm-with-vfpv2.c: Re-generated.
2925 * features/arm/arm-with-vfpv3.c: Re-generated.
2926 * features/i386/amd64-avx-avx512.c: Re-generated.
2927 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
2928 * features/i386/amd64-avx.c: Re-generated.
2929 * features/i386/amd64-avx-linux.c: Re-generated.
2930 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
2931 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
2932 * features/i386/amd64-avx-mpx.c: Re-generated.
2933 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
2934 * features/i386/amd64.c: Re-generated.
2935 * features/i386/amd64-linux.c: Re-generated.
2936 * features/i386/amd64-mpx.c: Re-generated.
2937 * features/i386/amd64-mpx-linux.c: Re-generated.
2938 * features/i386/i386-avx-avx512.c: Re-generated.
2939 * features/i386/i386-avx-avx512-linux.c: Re-generated.
2940 * features/i386/i386-avx.c: Re-generated.
2941 * features/i386/i386-avx-linux.c: Re-generated.
2942 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
2943 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
2944 * features/i386/i386-avx-mpx.c: Re-generated.
2945 * features/i386/i386-avx-mpx-linux.c: Re-generated.
2946 * features/i386/i386.c: Re-generated.
2947 * features/i386/i386-linux.c: Re-generated.
2948 * features/i386/i386-mmx.c: Re-generated.
2949 * features/i386/i386-mmx-linux.c: Re-generated.
2950 * features/i386/i386-mpx.c: Re-generated.
2951 * features/i386/i386-mpx-linux.c: Re-generated.
2952 * features/i386/x32-avx-avx512.c: Re-generated.
2953 * features/i386/x32-avx-avx512-linux.c: Re-generated.
2954 * features/i386/x32-avx.c: Re-generated.
2955 * features/i386/x32-avx-linux.c: Re-generated.
2956 * features/i386/x32.c: Re-generated.
2957 * features/i386/x32-linux.c: Re-generated.
2958 * features/microblaze.c: Re-generated.
2959 * features/microblaze-with-stack-protect.c: Re-generated.
2960 * features/mips64-dsp-linux.c: Re-generated.
2961 * features/mips64-linux.c: Re-generated.
2962 * features/mips-dsp-linux.c: Re-generated.
2963 * features/mips-linux.c: Re-generated.
2964 * features/nds32.c: Re-generated.
2965 * features/nios2.c: Re-generated.
2966 * features/nios2-linux.c: Re-generated.
2967 * features/rs6000/powerpc-32.c: Re-generated.
2968 * features/rs6000/powerpc-32l.c: Re-generated.
2969 * features/rs6000/powerpc-403.c: Re-generated.
2970 * features/rs6000/powerpc-403gc.c : Re-generated.
2971 * features/rs6000/powerpc-405.c: Re-generated.
2972 * features/rs6000/powerpc-505.c: Re-generated.
2973 * features/rs6000/powerpc-601.c: Re-generated.
2974 * features/rs6000/powerpc-602.c: Re-generated.
2975 * features/rs6000/powerpc-603.c: Re-generated.
2976 * features/rs6000/powerpc-604.c: Re-generated.
2977 * features/rs6000/powerpc-64.c: Re-generated.
2978 * features/rs6000/powerpc-64l.c: Re-generated.
2979 * features/rs6000/powerpc-7400.c: Re-generated.
2980 * features/rs6000/powerpc-750.c: Re-generated.
2981 * features/rs6000/powerpc-860.c: Re-generated.
2982 * features/rs6000/powerpc-altivec32.c: Re-generated.
2983 * features/rs6000/powerpc-altivec32l.c: Re-generated.
2984 * features/rs6000/powerpc-altivec64.c: Re-generated.
2985 * features/rs6000/powerpc-altivec64l.c: Re-generated.
2986 * features/rs6000/powerpc-cell32l.c: Re-generated.
2987 * features/rs6000/powerpc-cell64l.c: Re-generated.
2988 * features/rs6000/powerpc-e500.c: Re-generated.
2989 * features/rs6000/powerpc-e500l.c: Re-generated.
2990 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
2991 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
2992 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
2993 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
2994 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
2995 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
2996 * features/rs6000/powerpc-vsx32.c: Re-generated.
2997 * features/rs6000/powerpc-vsx32l.c: Re-generated.
2998 * features/rs6000/powerpc-vsx64.c: Re-generated.
2999 * features/rs6000/powerpc-vsx64l.c: Re-generated.
3000 * features/rs6000/rs6000.c: Re-generated.
3001 * features/s390-linux32.c: Re-generated.
3002 * features/s390-linux32v1.c: Re-generated.
3003 * features/s390-linux32v2.c: Re-generated.
3004 * features/s390-linux64.c: Re-generated.
3005 * features/s390-linux64v1.c: Re-generated.
3006 * features/s390-linux64v2.c: Re-generated.
3007 * features/s390-te-linux64.c: Re-generated.
3008 * features/s390-tevx-linux64.c: Re-generated.
3009 * features/s390-vx-linux64.c: Re-generated.
3010 * features/s390x-linux64.c: Re-generated.
3011 * features/s390x-linux64v1.c: Re-generated.
3012 * features/s390x-linux64v2.c: Re-generated.
3013 * features/s390x-te-linux64.c: Re-generated.
3014 * features/s390x-tevx-linux64.c: Re-generated.
3015 * features/s390x-vx-linux64.c: Re-generated.
3016 * features/sparc/sparc32-solaris.c: Re-generated.
3017 * features/sparc/sparc64-solaris.c: Re-generated.
3018 * features/tic6x-c62x.c: Re-generated.
3019 * features/tic6x-c62x-linux.c: Re-generated.
3020 * features/tic6x-c64x.c: Re-generated.
3021 * features/tic6x-c64x-linux.c: Re-generated.
3022 * features/tic6x-c64xp.c: Re-generated.
3023 * features/tic6x-c64xp-linux.c: Re-generated.
3024
35b4818d
YQ
30252017-07-26 Yao Qi <yao.qi@linaro.org>
3026
3027 * i386-linux-tdep.c (i386_linux_read_description): New function.
3028 (i386_linux_core_read_description): Call
3029 i386_linux_read_description.
3030 * i386-linux-tdep.h (i386_linux_read_description): Declare.
3031 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
3032 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
3033 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
3034 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
3035 * x86-linux-nat.c (x86_linux_read_description): Call
3036 i386_linux_read_description.
3037
8e2141c6
YQ
30382017-07-26 Yao Qi <yao.qi@linaro.org>
3039
3040 * NEWS: Mention it.
3041 * features/Makefile (%.c: %.xml): Pass the xml file name to
3042 command "maint print c-tdesc".
3043 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
3044 name from 'arg'.
3045
b468ff4c
YQ
30462017-07-26 Yao Qi <yao.qi@linaro.org>
3047
3048 * target-descriptions.c (target_desc): Add ctor and dtor. Do
3049 in-class initialization.
3050 (tdesc_create_feature): Call new instead of XCNEW.
3051 (free_target_description): Ue delete.
3052
b9c0e1b4
JB
30532017-07-25 John Baldwin <jhb@FreeBSD.org>
3054
3055 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
3056
a04b5337
YQ
30572017-07-25 Yao Qi <yao.qi@linaro.org>
3058
3059 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
3060 constant.
3061 (amd64_x32_init_abi): Likewise.
3062 * amd64-tdep.h (amd64_init_abi): Update declaration.
3063 (amd64_x32_init_abi): Likewise.
3064
02ad7fc2
YQ
30652017-07-25 Yao Qi <yao.qi@linaro.org>
3066
3067 PR tdep/21717
3068 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
3069 condition for FPSCR.
3070 (arm_linux_store_inferior_registers): Likewise.
3071
b6f48cb0
TT
30722017-07-22 Tom Tromey <tom@tromey.com>
3073
3074 * break-catch-syscall.c (struct catch_syscall_inferior_data)
3075 <syscalls_counts>: Now a std::vector.
3076 (get_catch_syscall_inferior_data): Use "new".
3077 (catch_syscall_inferior_data_cleanup): Use "delete".
3078 (insert_catch_syscall, remove_catch_syscall)
3079 (clear_syscall_counts): Update.
3080
e12c9b7a
TT
30812017-07-22 Tom Tromey <tom@tromey.com>
3082
3083 * break-catch-syscall.c (syscall_catchpoint)
3084 <syscalls_to_be_caught>: Now a std::vector<int>
3085 (~syscall_catchpoint): Remove.
3086 (insert_catch_syscall, remove_catch_syscall)
3087 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
3088 (print_mention_catch_syscall, print_recreate_catch_syscall):
3089 Update.
3090 (create_syscall_event_catchpoint): Change type of "filter"
3091 parameter.
3092 (catch_syscall_split_args): Return a std::vector.
3093 (catch_syscall_command_1, catching_syscall_number_1): Update.
3094
4fa8aeac
TT
30952017-07-22 Tom Tromey <tom@tromey.com>
3096
3097 * break-catch-throw.c (struct exception_catchpoint)
3098 <exception_rx>: Now a std::string.
3099 (~exception_catchpoint): Remove.
3100 (print_one_detail_exception_catchpoint): Update.
3101 (handle_gnu_v3_exceptions): Change type of except_rx.
3102 (extract_exception_regexp): Return a std::string.
3103 (catch_exception_command_1): Update.
3104
f746a154
TT
31052017-07-22 Tom Tromey <tom@tromey.com>
3106
3107 * break-catch-sig.c (gdb_signal_type): Remove typedef.
3108 (struct signal_catchpoint) <signals_to_be_caught>: Now a
3109 std::vector.
3110 <catch_all>: Now a bool.
3111 (~signal_catchpoint): Remove.
3112 (signal_catchpoint_insert_location)
3113 (signal_catchpoint_remove_location)
3114 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
3115 (signal_catchpoint_print_mention)
3116 (signal_catchpoint_print_recreate)
3117 (signal_catchpoint_explains_signal): Update.
3118 (create_signal_catchpoint): Change type of "filter" and
3119 "catch_all".
3120 (catch_signal_split_args): Return a std::vector. Change type of
3121 "catch_all".
3122 (catch_signal_command): Update.
3123
47e77640
PA
31242017-07-20 Pedro Alves <palves@redhat.com>
3125
3126 * ada-lang.c (ada_language_defn): Make extern.
3127 (_initialize_ada_language): Remove add_language call.
3128 * c-lang.c (c_language_defn, cplus_language_defn)
3129 (asm_language_defn, minimal_language_defn): Make extern.
3130 (_initialize_c_language): Delete.
3131 * completer.c (compare_cstrings): Delete, moved to utils.h.
3132 * d-lang.c (d_language_defn): Make extern.
3133 (_initialize_d_language): Remove add_language calls.
3134 * defs.h (enum language): Add comment.
3135 * f-lang.c (f_language_defn): Make extern.
3136 (_initialize_f_language): Remove add_language call.
3137 * go-lang.c (go_language_defn): Make extern.
3138 (_initialize_go_language): Remove add_language call.
3139 * language.c: Include <algorithm>.
3140 (languages): Redefine as const array.
3141 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
3142 (set_language_command): Handle "local". Use for-range loop.
3143 (set_language): Remove loop.
3144 (language_enum): Rewrite.
3145 (language_def, language_str): Remove loops.
3146 (add_language): Delete.
3147 (add_set_language_command): New, based on add_languages.
3148 (skip_language_trampoline): Adjust.
3149 (local_language_defn): Delete.
3150 (language_gdbarch_post_init): Adjust.
3151 (_initialize_language): Remove add_language calls. Call
3152 add_set_language_command.
3153 * language.h (add_language): Delete.
3154 (auto_language_defn)
3155 (unknown_language_defn, minimal_language_defn, ada_language_defn)
3156 (asm_language_defn, c_language_defn, cplus_language_defn)
3157 (d_language_defn, f_language_defn, go_language_defn)
3158 (m2_language_defn, objc_language_defn, opencl_language_defn)
3159 (pascal_language_defn, rust_language_defn): Declare.
3160 * m2-lang.c (m2_language_defn): Make extern.
3161 (_initialize_m2_language): Remove add_language call.
3162 * objc-lang.c (objc_language_defn): Make extern.
3163 (_initialize_objc_language): Remove add_language call.
3164 * opencl-lang.c (opencl_language_defn): Make extern.
3165 (_initialize_opencl_language): Remove add_language call.
3166 * p-lang.c (pascal_language_defn): Make extern.
3167 (_initialize_pascal_language): Delete.
3168 * rust-lang.c (rust_language_defn): Make extern.
3169 (_initialize_rust_language): Delete.
3170 * utils.h (compare_cstrings): New static inline function.
3171
edb0c9cb
PA
31722017-07-20 Pedro Alves <palves@redhat.com>
3173
3174 * ada-lang.c (ada_to_fixed_type_1): Adjust.
3175 (get_var_value): Constify parameters.
3176 (get_int_var_value): Change prototype.
3177 (to_fixed_range_type): Adjust.
3178 * ada-lang.h (get_int_var_value): Change prototype.
3179
a778f165
PA
31802017-07-20 Pedro Alves <palves@redhat.com>
3181
3182 * dwarf2read.c (dw2_lookup_symbol): Use
3183 SYMBOL_MATCHES_SEARCH_NAME.
3184 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
3185
42edd901
PA
31862017-07-20 Pedro Alves <palves@redhat.com>
3187
3188 * block.c (block_iter_name_step, block_iter_name_first)
3189 (block_iter_name_next): Delete.
3190 (block_lookup_symbol_primary): Adjust to use
3191 dict_iter_match_first/dict_iter_match_next.
3192 * block.h (block_iter_name_first, block_iter_name_next): Delete
3193 declarations.
3194 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
3195 dict_iter_match_first/dict_iter_match_next.
3196
cf325299
PA
31972017-07-20 Pedro Alves <palves@redhat.com>
3198
3199 * cp-support.c (cp_find_first_component_aux): Add missing case for
3200 end of string.
3201
c5ed0576
DB
32022017-07-18 David Blaikie <dblaikie@gmail.com>
3203
3204 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
3205 of dwo_cu's dwo_file.
3206
27841e76
YQ
32072017-07-18 Yao Qi <yao.qi@linaro.org>
3208
3209 * remote.c (store_registers_using_G): Remove one line comment.
3210
cfb7e58b
YQ
32112017-07-18 Yao Qi <yao.qi@linaro.org>
3212
3213 * regcache.c (regcache_cpy): Simplify it.
3214 (regcache::cpy_no_passthrough): Remove it.
3215 * regcache.h (cpy_no_passthrough): Remove it.
3216 (regcache_dup, regcache_cpy): Update comments.
3217
386535dd
PA
32182017-07-18 Pedro Alves <palves@redhat.com>
3219
3220 * remote-sim.c (sim_command_completer): Adjust to work with a
3221 completion_tracker instead of a VEC.
3222
c45ec17c
PA
32232017-07-17 Pedro Alves <palves@redhat.com>
3224
3225 * completer.c (complete_source_filenames): New function.
3226 (complete_address_and_linespec_locations): New function.
3227 (location_completer): Use complete_address_and_linespec_locations.
3228 (completion_tracker::build_completion_result): Honor the tracker's
3229 request to suppress append.
3230 * completer.h (completion_tracker::suppress_append_ws)
3231 (completion_tracker::set_suppress_append_ws): New methods.
3232 (completion_tracker::m_suppress_append_ws): New field.
3233 (complete_source_filenames): New declaration.
3234 * linespec.c (linespec_complete_what): New.
3235 (struct ls_parser) <complete_what, completion_word,
3236 completion_quote_char, completion_quote_end, completion_tracker>:
3237 New fields.
3238 (string_find_incomplete_keyword_at_end): New.
3239 (linespec_lexer_lex_string): Record quote char. If in completion
3240 mode, don't throw.
3241 (linespec_lexer_consume_token): Advance the completion word point.
3242 (linespec_lexer_peek_token): Save/restore completion info.
3243 (save_stream_and_consume_token): New.
3244 (set_completion_after_number): New.
3245 (linespec_parse_basic): Set what to complete next depending on
3246 token. Handle function and label completions specially.
3247 (parse_linespec): Disable objc shortcut in completion mode. Set
3248 what to complete next depending on token type. Skip keyword if in
3249 completion mode.
3250 (complete_linespec_component, linespec_complete): New.
3251 * linespec.h (linespec_complete): Declare.
3252
be966d42
PA
32532017-07-17 Pedro Alves <palves@redhat.com>
3254
3255 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
3256 Handle 'operator<' / 'operator<<'.
3257
a2459270
PA
32582017-07-17 Pedro Alves <palves@redhat.com>
3259
3260 * completer.c (collect_explicit_location_matches): Handle
3261 MATCH_LABEL.
3262 (convert_explicit_location_to_linespec): New, factored out from
3263 ...
3264 (convert_explicit_location_to_sals): ... this.
3265 (complete_label): New.
3266 (linespec_complete_label, find_label_symbols_in_block): New.
3267 (find_label_symbols): Add completion_mode parameter and adjust to
3268 call find_label_symbols_in_block.
3269 * linespec.h (linespec_complete_label): Declare.
3270
c6756f62
PA
32712017-07-17 Pedro Alves <palves@redhat.com>
3272
3273 * ada-lang.c (ada_collect_symbol_completion_matches): Add
3274 complete_symbol_mode parameter.
3275 * cli/cli-cmds.c (complete_command): Get the completion result out
3276 of the handle_brkchars tracker if used a custom word point.
3277 * completer.c: Include "linespec.h".
3278 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
3279 (advance_to_expression_complete_word_point): New.
3280 (completion_tracker::completes_to_completion_word): New.
3281 (complete_files_symbols): Pass down
3282 complete_symbol_mode::EXPRESSION.
3283 (explicit_options, probe_options): New.
3284 (collect_explicit_location_matches): Complete on the
3285 explictit_loc->foo instead of word. Use
3286 linespec_complete_function. Handle MATCH_LINE. Handle offering
3287 keyword and options completions.
3288 (backup_text_ptr): Delete.
3289 (skip_keyword): New.
3290 (complete_explicit_location): Remove 'word' parameter. Add
3291 language, quoted_arg_start and quoted_arg_end parameters.
3292 Rewrite, parsing left to right.
3293 (location_completer): Rewrite.
3294 (location_completer_handle_brkchars): New function.
3295 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
3296 (enum complete_line_internal_reason): Adjust comments.
3297 (completion_tracker::discard_completions): New.
3298 (completer_handle_brkchars_func_for_completer): Handle
3299 location_completer.
3300 (gdb_custom_word_point_brkchars)
3301 (gdb_org_rl_basic_quote_characters): New.
3302 (gdb_completion_word_break_characters_throw)
3303 (completion_find_completion_word): Handle trackers that use a
3304 custom word point.
3305 (completion_tracker::advance_custom_word_point_by): New.
3306 (completion_tracker::build_completion_result): Don't rely on
3307 readline appending the quote char.
3308 (gdb_rl_attempted_completion_function_throw): Handle trackers that
3309 use a custom word point.
3310 (gdb_rl_attempted_completion_function): Restore
3311 rl_basic_quote_characters.
3312 * completer.h (class completion_tracker): Extend intro comment.
3313 (completion_tracker::set_quote_char)
3314 (completion_tracker::quote_char)
3315 (completion_tracker::set_use_custom_word_point)
3316 (completion_tracker::use_custom_word_point)
3317 (completion_tracker::custom_word_point)
3318 (completion_tracker::set_custom_word_point)
3319 (completion_tracker::advance_custom_word_point_by)
3320 (completion_tracker::completes_to_completion_word)
3321 (completion_tracker::discard_completions): New methods.
3322 (completion_tracker::m_quote_char)
3323 (completion_tracker::m_use_custom_word_point)
3324 (completion_tracker::m_custom_word_point): New fields.
3325 (advance_to_expression_complete_word_point): Declare.
3326 * f-lang.c (f_collect_symbol_completion_matches): Add
3327 complete_symbol_mode parameter.
3328 * language.h (struct language_defn)
3329 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
3330 parameter.
3331 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
3332 (linespec_complete_function): New function.
3333 (linespec_lexer_lex_keyword): Adjust.
3334 * linespec.h (linespec_keywords, linespec_complete_function): New
3335 declarations.
3336 * location.c (find_end_quote): New function.
3337 (explicit_location_lex_one): Add explicit_completion_info
3338 parameter. Save quoting info. Don't throw if being called for
3339 completion. Don't handle Ada operators here.
3340 (is_cp_operator, skip_op_false_positives, first_of)
3341 (explicit_location_lex_one_function): New function.
3342 (string_to_explicit_location): Replace 'dont_throw' parameter with
3343 an explicit_completion_info pointer parameter. Handle it. Don't
3344 use explicit_location_lex_one to lex function names. Use
3345 explicit_location_lex_one_function instead.
3346 * location.h (struct explicit_completion_info): New.
3347 (string_to_explicit_location): Replace 'dont_throw' parameter with
3348 an explicit_completion_info pointer parameter.
3349 * symtab.c (default_collect_symbol_completion_matches_break_on):
3350 Add complete_symbol_mode parameter. Handle LINESPEC mode.
3351 (default_collect_symbol_completion_matches)
3352 (collect_symbol_completion_matches): Add complete_symbol_mode
3353 parameter.
3354 (collect_symbol_completion_matches_type): Pass down
3355 complete_symbol_mode::EXPRESSION.
3356 (collect_file_symbol_completion_matches): Add complete_symbol_mode
3357 parameter. Handle LINESPEC mode.
3358 * symtab.h (complete_symbol_mode): New.
3359 (default_collect_symbol_completion_matches_break_on)
3360 (default_collect_symbol_completion_matches)
3361 (collect_symbol_completion_matches)
3362 (collect_file_symbol_completion_matches): Add complete_symbol_mode
3363 parameter.
3364
1d550c82
PA
33652017-07-17 Pedro Alves <palves@redhat.com>
3366
3367 * utils.c (enum class strncmp_iw_mode): New.
3368 (strcmp_iw): Rename to ...
3369 (strncmp_iw_with_mode): ... this. Add string2_len and mode
3370 parameters. Handle them.
3371 (strncmp_iw): New.
3372 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
3373 * utils.h (strncmp_iw): Declare.
3374 (strcmp_iw): Move describing comments here.
3375
8090b426
PA
33762017-07-17 Pedro Alves <palves@redhat.com>
3377
3378 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
3379 CP_OPERATOR_STR.
3380 * c-typeprint.c (is_type_conversion_operator): Use
3381 CP_OPERATOR_STR.
3382 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
3383 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
3384 CP_OPERATOR_LEN.
3385 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
3386 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
3387 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
3388 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
3389 CP_OPERATOR_STR.
3390 * location.c: Include "cp-support.h".
3391 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
3392 CP_OPERATOR_STR.
3393 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
3394 CP_OPERATOR_LEN.
3395
6a2c1b87
PA
33962017-07-17 Pedro Alves <palves@redhat.com>
3397
3398 * cli/cli-cmds.c (complete_command): Use a completion tracker
3399 along with completion_find_completion_word for handle_brkchars
3400 phase.
3401 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
3402 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
3403 (struct gdb_rl_completion_word_info): New.
3404 (gdb_rl_find_completion_word): New.
3405 (completion_find_completion_word): New.
3406 * completer.h (completion_find_completion_word): Declare.
3407
eb3ff9a5
PA
34082017-07-17 Pedro Alves <palves@redhat.com>
3409
3410 * ada-lang.c (symbol_completion_match): Adjust comments.
3411 (symbol_completion_add): Replace vector parameter with
3412 completion_tracker parameter. Use it.
3413 (ada_make_symbol_completion_list): Rename to...
3414 (ada_collect_symbol_completion_matches): ... this. Add
3415 completion_tracker parameter and use it.
3416 (ada_language_defn): Adjust.
3417 * break-catch-syscall.c (catch_syscall_completer): Adjust
3418 prototype and work with completion_tracker instead of VEC.
3419 * breakpoint.c (condition_completer): Adjust prototype and work
3420 with completion_tracker instead of VEC.
3421 * c-lang.c (c_language_defn, cplus_language_defn)
3422 (asm_language_defn, minimal_language_defn): Adjust to renames.
3423 * cli/cli-cmds.c (complete_command): Rework using
3424 completion_tracker. Catch exceptions when completing.
3425 * cli/cli-decode.c (integer_unlimited_completer)
3426 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
3427 with completion_tracker instead of VEC.
3428 * command.h (struct completion_tracker): Forward declare.
3429 (completer_ftype, completer_handle_brkchars_ftype): Change
3430 types.
3431 (complete_on_cmdlist, complete_on_enum): Adjust.
3432 * completer.c: Include <algorithm>.
3433 (struct gdb_completer_state): New.
3434 (current_completion): New global.
3435 (readline_line_completion_function): Delete.
3436 (noop_completer, filename_completer)
3437 (filename_completer_handle_brkchars, complete_files_symbols)
3438 (linespec_location_completer): Adjust to work with a
3439 completion_tracker instead of a VEC.
3440 (string_or_empty): New.
3441 (collect_explicit_location_matches): Adjust to work with a
3442 completion_tracker instead of a VEC.
3443 (explicit_location_completer): Rename to ...
3444 (complete_explicit_location): ... this and adjust to work with a
3445 completion_tracker instead of a VEC.
3446 (location_completer): Adjust to work with a completion_tracker
3447 instead of a VEC.
3448 (add_struct_fields): Adjust to work with a completion_list instead
3449 of VEC.
3450 (expression_completer): Rename to ...
3451 (complete_expression): ... this and adjust to work with a
3452 completion_tracker instead of a VEC. Use complete_files_symbols.
3453 (expression_completer): Reimplement on top of complete_expression.
3454 (symbol_completer): Adjust to work with a completion_tracker
3455 instead of a VEC.
3456 (enum complete_line_internal_reason): Add describing comments.
3457 (complete_line_internal_normal_command): Adjust to work with a
3458 completion_tracker instead of a VEC.
3459 (complete_line_internal): Rename to ...
3460 (complete_line_internal_1): ... this and adjust to work with a
3461 completion_tracker instead of a VEC. Assert TEXT is NULL in the
3462 handle_brkchars phase.
3463 (new_completion_tracker): Delete.
3464 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
3465 complete_line_internal_1.
3466 (free_completion_tracker): Delete.
3467 (INITIAL_COMPLETION_HTAB_SIZE): New.
3468 (completion_tracker::completion_tracker)
3469 (completion_tracker::~completion_tracker): New.
3470 (maybe_add_completion): Delete.
3471 (completion_tracker::maybe_add_completion)
3472 (completion_tracker::add_completion)
3473 (completion_tracker::add_completions): New.
3474 (throw_max_completions_reached_error): Delete.
3475 (complete_line): Adjust to work with a completion_tracker instead
3476 of a VEC. Don't create a completion_tracker_t or check for max
3477 completions here.
3478 (command_completer, command_completer_handle_brkchars)
3479 (signal_completer, reg_or_group_completer_1)
3480 (reg_or_group_completer, default_completer_handle_brkchars):
3481 Adjust to work with a completion_tracker.
3482 (gdb_completion_word_break_characters_throw): New.
3483 (gdb_completion_word_break_characters): Reimplement.
3484 (line_completion_function): Delete.
3485 (completion_tracker::recompute_lowest_common_denominator)
3486 (expand_preserving_ws)
3487 (completion_tracker::build_completion_result)
3488 (completion_result::completion_result)
3489 (completion_result::completion_result)
3490 (completion_result::~completion_result)
3491 (completion_result::completion_result)
3492 (completion_result::release_match_list, compare_cstrings)
3493 (completion_result::sort_match_list)
3494 (completion_result::reset_match_list)
3495 (gdb_rl_attempted_completion_function_throw)
3496 (gdb_rl_attempted_completion_function): New.
3497 * completer.h (completion_list, struct completion_result)
3498 (class completion_tracker): New.
3499 (complete_line): Add completion_tracker parameter.
3500 (readline_line_completion_function): Delete.
3501 (gdb_rl_attempted_completion_function): New.
3502 (noop_completer, filename_completer, expression_completer)
3503 (location_completer, symbol_completer, command_completer)
3504 (signal_completer, reg_or_group_completer): Update prototypes.
3505 (completion_tracker_t, new_completion_tracker)
3506 (make_cleanup_free_completion_tracker): Delete.
3507 (enum maybe_add_completion_enum): Delete.
3508 (maybe_add_completion): Delete.
3509 (throw_max_completions_reached_error): Delete.
3510 * corefile.c (complete_set_gnutarget): Adjust to work with a
3511 completion_tracker instead of a VEC.
3512 * cp-abi.c (cp_abi_completer): Adjust to work with a
3513 completion_tracker instead of a VEC.
3514 * d-lang.c (d_language_defn): Adjust.
3515 * disasm.c (disassembler_options_completer): Adjust to work with a
3516 completion_tracker instead of a VEC.
3517 * f-lang.c (f_make_symbol_completion_list): Rename to ...
3518 (f_collect_symbol_completion_matches): ... this. Adjust to work
3519 with a completion_tracker instead of a VEC.
3520 (f_language_defn): Adjust.
3521 * go-lang.c (go_language_defn): Adjust.
3522 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
3523 Adjust to work with a completion_tracker instead of a VEC.
3524 * infrun.c (handle_completer): Likewise.
3525 * interps.c (interpreter_completer): Likewise.
3526 * interps.h (interpreter_completer): Likewise.
3527 * language.c (unknown_language_defn, auto_language_defn)
3528 (local_language_defn): Adjust.
3529 * language.h (language_defn::la_make_symbol_completion_list):
3530 Rename to ...
3531 (language_defn::la_collect_symbol_completion_matches): ... this
3532 and adjust to work with a completion_tracker instead of a VEC.
3533 * m2-lang.c (m2_language_defn): Adjust.
3534 * objc-lang.c (objc_language_defn): Adjust.
3535 * opencl-lang.c (opencl_language_defn): Adjust.
3536 * p-lang.c (pascal_language_defn): Adjust.
3537 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
3538 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
3539 with a completion_tracker.
3540 * rust-lang.c (rust_language_defn): Adjust.
3541 * symtab.c (free_completion_list, do_free_completion_list)
3542 (return_val, completion_tracker): Delete.
3543 (completion_list_add_name, completion_list_add_symbol)
3544 (completion_list_add_msymbol, completion_list_objc_symbol)
3545 (completion_list_add_fields, add_symtab_completions): Add
3546 completion_tracker parameter and use it.
3547 (default_make_symbol_completion_list_break_on_1): Rename to...
3548 (default_collect_symbol_completion_matches_break_on): ... this.
3549 Add completion_tracker parameter and use it instead of allocating
3550 a completion tracker here.
3551 (default_make_symbol_completion_list_break_on): Delete old
3552 implementation.
3553 (default_make_symbol_completion_list): Delete.
3554 (default_collect_symbol_completion_matches): New.
3555 (make_symbol_completion_list): Delete.
3556 (collect_symbol_completion_matches): New.
3557 (make_symbol_completion_type): Rename to ...
3558 (collect_symbol_completion_matches_type): ... this. Add
3559 completion_tracker parameter and use it instead of VEC.
3560 (make_file_symbol_completion_list_1): Rename to...
3561 (collect_file_symbol_completion_matches): ... this. Add
3562 completion_tracker parameter and use it instead of VEC.
3563 (make_file_symbol_completion_list): Delete.
3564 (add_filename_to_list): Use completion_list instead of a VEC.
3565 (add_partial_filename_data::list): Now a completion_list.
3566 (make_source_files_completion_list): Work with a completion_list
3567 instead of a VEC.
3568 * symtab.h: Include "completer.h".
3569 (default_make_symbol_completion_list_break_on)
3570 (default_make_symbol_completion_list, make_symbol_completion_list)
3571 (make_symbol_completion_type, make_file_symbol_completion_list)
3572 (make_source_files_completion_list): Delete.
3573 (default_collect_symbol_completion_matches_break_on)
3574 (default_collect_symbol_completion_matches)
3575 (collect_symbol_completion_matches)
3576 (collect_symbol_completion_matches_type)
3577 (collect_file_symbol_completion_matches)
3578 (make_source_files_completion_list): New.
3579 * top.c (init_main): Don't install a rl_completion_entry_function
3580 hook. Install a rl_attempted_completion_function hook instead.
3581 * tui/tui-layout.c (layout_completer): Adjust to work with a
3582 completion_tracker.
3583 * tui/tui-regs.c (tui_reggroup_completer):
3584 * tui/tui-win.c (window_name_completer, focus_completer)
3585 (winheight_completer): Adjust to work with a completion_tracker.
3586 * value.c: Include "completer.h".
3587 (complete_internalvar): Adjust to work with a completion_tracker.
3588 * value.h (complete_internalvar): Likewise.
3589
6e1dbf8c
PA
35902017-07-17 Pedro Alves <palves@redhat.com>
3591
3592 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
3593 renames.
3594 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
3595 comments to completer_ftype's declaration.
3596 <completer_handle_brkchars>: Change type to
3597 completer_handle_brkchars_ftype.
3598 * command.h (completer_ftype): Add describing comment and give
3599 names to parameters.
3600 (completer_ftype_void): Rename to ...
3601 (completer_handle_brkchars_ftype) ... this. Add describing comment.
3602 (set_cmd_completer_handle_brkchars): Adjust.
3603 * completer.c (filename_completer_handle_brkchars): New function.
3604 (complete_line_internal_normal_command): New function, factored
3605 out from ...
3606 (complete_line_internal): ... here.
3607 (command_completer_handle_brkchars)
3608 (default_completer_handle_brkchars)
3609 (completer_handle_brkchars_func_for_completer): New functions.
3610 * completer.h (set_gdb_completion_word_break_characters): Delete
3611 declaration.
3612 (completer_handle_brkchars_func_for_completer): New declaration.
3613 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
3614 completer_handle_brkchars_func_for_completer.
3615
78b13106
PA
36162017-07-17 Pedro Alves <palves@redhat.com>
3617
3618 * completer.c (symbol_completer): New function, based on
3619 make_symbol_completion_list_fn.
3620 * completer.h (symbol_completer): New declaration.
3621 * guile/scm-cmd.c (cmdscm_completers): Adjust.
3622 * python/py-cmd.c (completers): Adjust.
3623 * symtab.c (make_symbol_completion_list_fn): Delete.
3624 * symtab.h (make_symbol_completion_list_fn): Delete.
3625 * cli/cli-decode.c (add_cmd): Adjust.
3626
bbf2f4df
PA
36272017-07-17 Pedro Alves <palves@redhat.com>
3628
3629 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
3630 * dwarf2read.c: Include "filename-seen-cache.h".
3631 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
3632 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
3633 * filename-seen-cache.c: New file.
3634 * filename-seen-cache.h: New file.
3635 * symtab.c: Include "filename-seen-cache.h".
3636 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
3637 (create_filename_seen_cache, clear_filename_seen_cache)
3638 (delete_filename_seen_cache, filename_seen): Delete, parts moved
3639 to filename-seen-cache.h/filename-seen-cache.c.
3640 (output_source_filename, sources_info)
3641 (maybe_add_partial_symtab_filename)
3642 (make_source_files_completion_list): Adjust to use
3643 filename_seen_cache.
3644
330cdd98
PA
36452017-07-17 Pedro Alves <palves@redhat.com>
3646
3647 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
3648 fields.
3649 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
3650 dwarf2_debug_sections*)): New.
3651 (dwarf2_per_objfile::dwarf2_per_objfile(const
3652 dwarf2_per_objfile&)): Declare as deleted.
3653 (dwarf2_per_objfile::operator=): Declare as deleted.
3654 (dwarf2_per_objfile::dwarf2_per_objfile)
3655 (dwarf2_per_objfile::~dwarf2_per_objfile)
3656 (dwarf2_per_objfile::free_cached_comp_units): New.
3657 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
3658 ctor. Call dwarf2_per_objfile's ctor manually.
3659 (dwarf2_locate_sections): Deleted/refactored as ...
3660 (dwarf2_per_objfile::locate_sections): ... this new method.
3661 (free_cached_comp_units): Defer to
3662 dwarf2_per_objfile::free_cached_comp_units.
3663 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
3664
8880f2a9
TT
36652017-07-14 Tom Tromey <tom@tromey.com>
3666
3667 PR rust/21764:
3668 * rust-exp.y (convert_ast_to_expression): Add "want_type"
3669 parameter.
3670 <UNOP_SIZEOF>: Split into separate case.
3671 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
3672
65547233
TT
36732017-07-14 Tom Tromey <tom@tromey.com>
3674
3675 PR rust/21763:
3676 * symtab.c (symbol_matches_domain): Add language_rust to special
3677 case.
3678 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
3679 treat LOC_TYPEDEF symbols as variables.
3680
8f14146e
PA
36812017-07-14 Pedro Alves <palves@redhat.com>
3682
3683 * symtab.c (make_file_symbol_completion_list_1): Iterate over
3684 symtabs matching all symtabs with SRCFILE as file name instead of
3685 only considering the first hit, with lookup_symtab.
3686
2347965c
SM
36872017-07-14 Simon Marchi <simon.marchi@ericsson.com>
3688
3689 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
3690 operator_name parameters.
3691 (gen_expr): Update function call.
3692
40f4af28
SM
36932017-07-14 Simon Marchi <simon.marchi@ericsson.com>
3694
3695 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
3696 parameter.
3697 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
3698 Likewise.
3699 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
3700 parameter, use agent_expr::gdbarch instead, update function
3701 calls.
3702 (locexpr_tracepoint_var_ref): Likewise.
3703 (loclist_tracepoint_var_ref): Likewise.
3704 * ax-gdb.c (gen_trace_static_fields): Likewise.
3705 (gen_traced_pop): Likewise.
3706 (gen_frame_args_address): Likewise.
3707 (gen_frame_locals_address): Likewise.
3708 (gen_var_ref): Likewise.
3709 (gen_struct_ref_recursive): Likewise.
3710 (gen_static_field): Likewise.
3711 (gen_maybe_namespace_elt): Likewise.
3712 (gen_expr): Likewise.
3713 (gen_trace_for_var): Likewise.
3714 (gen_trace_for_expr): Likewise.
3715 (gen_trace_for_return_address): Likewise.
3716
053f8057
SM
37172017-07-14 Simon Marchi <simon.marchi@ericsson.com>
3718
3719 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
3720 parameter.
3721 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
3722
6661ad48
SM
37232017-07-14 Simon Marchi <simon.marchi@ericsson.com>
3724
3725 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
3726 from ax, update calls.
3727 (gen_usual_arithmetic): Likewise.
3728 (gen_integral_promotions): Likewise.
3729 (gen_bitfield_ref): Likewise.
3730 (gen_primitive_field): Likewise.
3731 (gen_struct_ref_recursive): Likewise.
3732 (gen_struct_ref): Likewise.
3733 (gen_maybe_namespace_elt): Likewise.
3734 (gen_struct_elt_for_reference): Likewise.
3735 (gen_namespace_elt): Likewise.
3736 (gen_aggregate_elt_ref): Likewise.
3737 (gen_expr): Get gdbarch from ax, update calls.
3738 (gen_expr_binop_rest): Likewise.
3739
c55a47e7
PA
37402017-07-13 Pedro Alves <palves@redhat.com>
3741
3742 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
3743 as default tdesc.
3744 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
3745 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
3746 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
3747 tdesc_amd64_linux as default tdesc. Get final tdesc from the
3748 tdep.
3749 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
3750 Get final tdesc from the tdep.
3751 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
3752 default tdesc.
3753 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
3754 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
3755 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
3756 Use it as default tdesc.
3757 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
3758 down to amd_init_abi. No longer handle fallback tdesc here.
3759 * amd64-tdep.h (tdesc_x32): Declare.
3760 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
3761 parameter.
3762 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
3763 as default tdesc.
3764
55efceab
AA
37652017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
3766
3767 * s390-linux-tdep.c (s390_process_record): Add support for
3768 instructions new in arch12.
3769
0aa37b65
JB
37702017-07-11 John Baldwin <jhb@FreeBSD.org>
3771
3772 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
3773 PT_GETFSBASE and PT_GETGSBASE.
3774 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
3775 PT_SETGSBASE.
3776
48aeef91
JB
37772017-07-11 John Baldwin <jhb@FreeBSD.org>
3778
3779 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
3780 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
3781 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
3782 those rules.
3783 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
3784 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
3785 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
3786 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
3787 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
3788 * features/i386/amd64.xml: Add 64bit-segments.xml.
3789 * features/i386/amd64-avx-avx512.c: Regenerated.
3790 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
3791 * features/i386/amd64-avx-mpx.c: Regenerated.
3792 * features/i386/amd64-avx.c: Regenerated.
3793 * features/i386/amd64-mpx.c: Regenerated.
3794 * features/i386/amd64.c: Regenerated.
3795 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
3796 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
3797 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
3798 * regformats/i386/amd64-avx.dat: Regenerated.
3799 * regformats/i386/amd64-mpx.dat: Regenerated.
3800 * regformats/i386/amd64.dat: Regenerated.
3801
77c501bc
YQ
38022017-07-10 Yao Qi <yao.qi@linaro.org>
3803
3804 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
3805 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
3806
6dc8d757
AK
38072017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
3808
3809 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
3810 unsetenv.
3811 * gnulib/aclocal.m4: Regenerate.
3812 * gnulib/config.in: Regenerate.
3813 * gnulib/configure: Regenerate.
3814 * gnulib/import/Makefile.am: Regenerate.
3815 * gnulib/import/Makefile.in: Regenerate.
3816 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
3817 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
3818 * gnulib/import/m4/environ.m4: New file.
3819 * gnulib/import/m4/setenv.m4: New file.
3820 * gnulib/import/setenv.c: New file.
3821 * gnulib/import/unsetenv.c: New file.
3822
266934d1
SM
38232017-07-09 Simon Marchi <simon.marchi@ericsson.com>
3824
3825 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
3826 address when op is DW_OP_addr.
3827
03278692
TT
38282017-07-09 Tom Tromey <tom@tromey.com>
3829
3830 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
3831 check and apply to outer type.
3832
4b654465
JB
38332017-07-07 John Baldwin <jhb@FreeBSD.org>
3834
3835 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
3836 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
3837 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
3838 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
3839
2af9fc44
JB
38402017-07-07 John Baldwin <jhb@FreeBSD.org>
3841
3842 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
3843
382b69bb
JB
38442017-07-07 John Baldwin <jhb@FreeBSD.org>
3845
3846 * corelow.c (get_core_siginfo): Remove.
3847 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
3848 instead of get_core_siginfo.
3849 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
3850 * gdbarch.h: Re-generate.
3851 * gdbarch.c: Re-generate.
3852 * linux-tdep.c (linux_core_xfer_siginfo): New.
3853 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
3854
6e5eab33
JB
38552017-07-07 John Baldwin <jhb@FreeBSD.org>
3856
3857 * corelow.c (thread_section_name): Move to ...
3858 * gdbcore.h (thread_section_name): ... here.
3859
929edea9
JB
38602017-07-07 John Baldwin <jhb@FreeBSD.org>
3861
3862 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
3863 (struct siginfo32): New.
3864 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
3865 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
3866 via ptrace(PT_LWPINFO).
3867
762c974a
JB
38682017-07-07 John Baldwin <jhb@FreeBSD.org>
3869
3870 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
3871 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
3872 (fbsd_get_siginfo_type): New.
3873 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
3874 (_initialize_fbsd_tdep): New.
3875
33c5cd75
DB
38762017-07-06 David Blaikie <dblaikie@gmail.com>
3877
3878 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
3879 a singular dwo_unit*) to support multiple CUs in the same way that
3880 multiple TUs are supported.
3881 (create_cus_hash_table): Replace create_dwo_cu with a function for
3882 parsing multiple CUs from a DWO file.
3883 (open_and_init_dwo_file): Use create_cus_hash_table rather than
3884 create_dwo_cu.
3885 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
3886 htab_find, rather than comparing the signature to a singleton CU in
3887 the dwo_file.
3888
8455d262
PA
38892017-07-06 Pedro Alves <palves@redhat.com>
3890
3891 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
3892
4da3eb35
PA
38932017-07-04 Pedro Alves <palves@redhat.com>
3894
3895 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
3896 * gdbtypes.h (TYPE_STATIC): Delete.
3897 (struct fn_field) <is_public, is_abstract, is_static, is_final,
3898 is_synchronized, is_native>: Delete.
3899 <dummy>: Bump.
3900 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
3901 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
3902 (TYPE_FN_FIELD_ABSTRACT): Delete.
3903
5bfd255c
SM
39042017-07-03 Simon Marchi <simon.marchi@ericsson.com>
3905
3906 * buffer.h (buffer_finish): Fix spelling mistakes.
3907
25c54127
EZ
39082017-07-01 Eli Zaretskii <eliz@gnu.org>
3909
3910 * .dir-locals.el: Automatically switch to C-style comments in
3911 versions of Emacs that support the feature.
3912
dc4bde35
SDJ
39132017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
3914 Pedro Alves <palves@redhat.com>
3915
3916 PR cli/21688
3917 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
3918 (process_next_line): New variable 'inline_cmd'.
3919 Adjust 'if' clauses for "python", "compile" and "guile" to use
3920 'command_name_equals' and check for '!inline_cmd'.
3921
51ed89aa
SDJ
39222017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
3923
3924 PR cli/21688
3925 * cli/cli-script.c (command_name_equals_not_inline): New function.
3926 (process_next_line): Adjust 'if' clauses for "python", "compile"
3927 and "guile" to use command_name_equals_not_inline.
3928
eb17d413
PA
39292017-06-29 Pedro Alves <palves@redhat.com>
3930
3931 * completer.c (expression_completer): Call
3932 linespec_location_completer instead of location_completer.
3933
195bcdd5
PA
39342017-06-29 Pedro Alves <palves@redhat.com>
3935
3936 * completer.c (expression_completer): Remove code that recomputes
3937 'text' from 'word'.
3938
adc764e7
YQ
39392017-06-29 Yao Qi <yao.qi@linaro.org>
3940
3941 * regformats/regdat.sh: Generate code with
3942 "ifndef IN_PROCESS_AGENT".
3943
6e75794e
PA
39442017-06-28 Pedro Alves <palves@redhat.com>
3945
3946 * command.h: Include "common/scoped_restore.h".
3947
bc491f2e
YQ
39482017-06-28 Yao Qi <yao.qi@linaro.org>
3949
3950 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
3951 instead of obstack_grow.
3952
41664b45
DG
39532017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
3954
3955 PR gdb/21337
3956 * symfile.c (reread_symbols): Call objfiles_changed just before
3957 read_symbols.
3958
6da67eb1
PA
39592017-06-27 Pedro Alves <palves@redhat.com>
3960
3961 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
3962 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
3963 (completion_list_add_symbol, completion_list_add_msymbol):
3964 ... these new functions.
3965 (add_symtab_completions)
3966 (default_make_symbol_completion_list_break_on_1): Adjust.
3967
23732b1e
PA
39682017-06-27 Pedro Alves <palves@redhat.com>
3969
3970 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
3971 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
3972 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
3973 dtor.
3974 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
3975 'storage_obstack' field an auto_obstack. In-class initialize all
3976 non-bitfield fields. Make minsyms_read bool.
3977 * symfile.c (read_symbols): Adjust.
3978
a4d1e79a
AH
39792017-06-27 Alan Hayward <alan.hayward@arm.com>
3980
3981 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
3982 (gdbsim_store_register): Likewise.
3983
8268c778
PA
39842017-06-27 Pedro Alves <palves@redhat.com>
3985
3986 * c-exp.y (name_obstack): Now an auto_obstack.
3987 (yylex): Use auto_obstack::clear.
3988 (c_parse): Use auto_obstack::clear instead of reinitializing and
3989 freeing the obstack.
3990 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
3991 * d-exp.y (name_obstack): Now an auto_obstack.
3992 (yylex): Use auto_obstack::clear.
3993 (d_parse): Use auto_obstack::clear instead of reinitializing and
3994 freeing the obstack.
3995 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
3996 auto_obstack.
3997 * dwarf2read.c (create_addrmap_from_index)
3998 (dwarf2_build_psymtabs_hard)
3999 (update_enumeration_type_from_children): Likewise.
4000 * gdb_obstack.h (auto_obstack): New type.
4001 * go-exp.y (name_obstack): Now an auto_obstack.
4002 (build_packaged_name): Use auto_obstack::clear.
4003 (go_parse): Use auto_obstack::clear instead of reinitializing and
4004 freeing the obstack.
4005 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
4006 auto_obstack.
4007 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
4008 * rust-exp.y (work_obstack): Now an auto_obstack.
4009 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
4010 reinitializing and freeing the obstack.
4011 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
4012 (host_char_to_target): Use auto_obstack.
4013 * utils.h (make_cleanup_obstack_free): Delete declaration.
4014 * valprint.c (generic_emit_char, generic_printstr): Use
4015 auto_obstack.
4016
db665f42
SM
40172017-06-27 Simon Marchi <simon.marchi@ericsson.com>
4018
4019 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
4020 thread.
4021 (darwin_init_thread_list): Don't update dummy thread.
4022 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
4023
873c0814
SM
40242017-06-26 Simon Marchi <simon.marchi@ericsson.com>
4025
4026 * record-full.c (netorder16): Remove.
4027
8b5a7a6e
SM
40282017-06-26 Simon Marchi <simon.marchi@ericsson.com>
4029
4030 * common/diagnostics.h: Define macros for GCC.
4031 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
4032 * common/vec.h: Include diagnostics.h.
4033 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
4034 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
4035 warning.
4036
d1435379
SM
40372017-06-26 Simon Marchi <simon.marchi@ericsson.com>
4038
4039 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
4040 New macro.
4041 * ada-lex.l: Ignore deprecated register warnings.
4042
cc75e0fd
SM
40432017-06-25 Simon Marchi <simon.marchi@ericsson.com>
4044
4045 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
4046 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
4047
07809eaf
SM
40482017-06-25 Simon Marchi <simon.marchi@ericsson.com>
4049
4050 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
4051 its own line.
4052
f076f034
SM
40532017-06-25 Simon Marchi <simon.marchi@ericsson.com>
4054
4055 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
4056
0dd5cbc5
AH
40572017-06-23 Alan Hayward <alan.hayward@arm.com>
4058
4059 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
4060 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
4061 (xtensa_register_read_masked): Likewise.
4062
d4c6ce5b
SDJ
40632017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
4064
4065 * common/environ.c (gdb_environ::unset): Update comment.
4066
16892a03
AH
40672017-06-22 Alan Hayward <alan.hayward@arm.com>
4068
4069 * python/py-unwind.c (pyuw_sniffer): Allocate space for
4070 registers.
4071
d7dcbefc
AH
40722017-06-22 Alan Hayward <alan.hayward@arm.com>
4073
4074 * record-full.c (record_full_exec_insn): Use byte_vector.
4075
b30ff123
YQ
40762017-06-22 Yao Qi <yao.qi@linaro.org>
4077
4078 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
4079 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
4080
4fa847d7
AH
40812017-06-22 Alan Hayward <alan.hayward@arm.com>
4082
4083 * remote.c (cached_reg): Move from here...
4084 * regcache.h (cached_reg): ...to here.
4085 * python/py-unwind.c (struct reg_info): Remove.
4086 (cached_frame_info): Use cached_reg_t.
4087 (pyuw_prev_register): Likewise.
4088 (pyuw_sniffer): Use cached_reg_t and allocate registers.
4089 (pyuw_dealloc_cache): Free all registers.
4090
f4906a9a
PA
40912017-06-22 Pedro Alves <palves@redhat.com>
4092 Simon Marchi <simon.marchi@ericsson.com>
4093
4094 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
4095 warning.
4096 * common/diagnostics.h: New file.
4097
b45a1208
PA
40982017-06-22 Pedro Alves <palves@redhat.com>
4099
4100 * common/agent.h: Add include guards.
4101
e4da2c61
SM
41022017-06-21 Simon Marchi <simon.marchi@ericsson.com>
4103
4104 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
4105 talk about addressable units instead of bytes.
4106
96160d60
SDJ
41072017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
4108
4109 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
4110 of '::const_iterator'.
4111
9a6c7d9c
SDJ
41122017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
4113
4114 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4115 'unittests/environ-selftests.c'.
4116 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
4117 * charset.c (find_charset_names): Declare object 'iconv_env'.
4118 Update code to use 'iconv_env' object. Remove call to
4119 'free_environ'.
4120 * common/environ.c: Include <utility>.
4121 (make_environ): Delete function.
4122 (free_environ): Delete function.
4123 (gdb_environ::clear): New function.
4124 (gdb_environ::operator=): New function.
4125 (gdb_environ::get): Likewise.
4126 (environ_vector): Delete function.
4127 (set_in_environ): Delete function.
4128 (gdb_environ::set): New function.
4129 (unset_in_environ): Delete function.
4130 (gdb_environ::unset): New function.
4131 (gdb_environ::envp): Likewise.
4132 * common/environ.h: Include <vector>.
4133 (struct gdb_environ): Delete; transform into...
4134 (class gdb_environ): ... this class.
4135 (free_environ): Delete prototype.
4136 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
4137 environ_vector): Likewise.
4138 * infcmd.c (run_command_1): Update code to call
4139 'envp' from 'gdb_environ' class.
4140 (environment_info): Update code to call methods from 'gdb_environ'
4141 class.
4142 (unset_environment_command): Likewise.
4143 (path_info): Likewise.
4144 (path_command): Likewise.
4145 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
4146 (inferior::inferior): Initialize 'environment' using the host's
4147 information.
4148 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
4149 Include "environ.h".
4150 (class inferior) <environment>: Change type from 'struct
4151 gdb_environ' to 'gdb_environ'.
4152 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
4153 methods from 'gdb_environ' class.
4154 * solib.c (solib_find_1): Likewise
4155 * unittests/environ-selftests.c: New file.
4156
75c554cf
YQ
41572017-06-20 Yao Qi <yao.qi@linaro.org>
4158
4159 * features/i386/i386-linux.xml: Exchange the order of including
4160 32bit-linux.xml and 32bit-sse.xml.
4161 * features/i386/i386-linux.c: Regenerated.
4162
72ddacb7
YQ
41632017-06-20 Yao Qi <yao.qi@linaro.org>
4164
4165 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
4166 Delete copy ctor and assignment operator.
4167 (tdesc_type): Likewise.
4168 (tdesc_feature): Likewise.
4169 (tdesc_free_reg): Remove.
4170 (tdesc_create_reg): Use new.
4171 (tdesc_free_type): Remove.
4172 (tdesc_create_vector): Use new.
4173 (tdesc_create_union): Likewise.
4174 (tdesc_create_flags): Likewise.
4175 (tdesc_create_enum): Likewise.
4176 (tdesc_free_feature): Delete.
4177 (free_target_description): Use delete.
4178
325c9fd4
JB
41792017-06-19 John Baldwin <jhb@FreeBSD.org>
4180
4181 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
4182 registers.
4183
16b7a719
PA
41842017-06-19 Pedro Alves <palves@redhat.com>
4185
4186 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
4187 after gdb::unlinker.
4188
1c8e01c9
SDJ
41892017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
4190
4191 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
4192 gdb_environ to access an environment variable.
4193
ffce45d2
TP
41942017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
4195
4196 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
4197 gdb_byte*.
4198
1d4fbac9
SM
41992017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4200
4201 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
4202
8465943a
SM
42032017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4204
4205 * configure: Re-generate.
4206 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
4207
3e019bdc
SM
42082017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4209
4210 * configure: Re-generate.
4211 * warning.m4: Pass -Werror to compiler when checking for
4212 supported warning flags.
4213
cf0dd6f0
SM
42142017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4215
4216 * Makefile.in (COMPILE.pre): Add "-x c++".
4217
6f98355c
YQ
42182017-06-16 Alan Hayward <alan.hayward@arm.com>
4219 Pedro Alves <palves@redhat.com>
4220 Yao Qi <yao.qi@linaro.org>
4221
4222 * defs.h (RequireLongest): New.
4223 (extract_integer): Declare function template.
4224 (extract_signed_integer): Remove the declaration, but define it
4225 static inline.
4226 (extract_unsigned_integer): Likewise.
4227 (store_integer): Declare function template.
4228 (store_signed_integer): Remove the declaration, but define it
4229 static inline.
4230 (store_unsigned_integer): Likewise.
4231 * findvar.c (extract_integer): New function template.
4232 (extract_signed_integer): Remove.
4233 (extract_unsigned_integer): Remove.
4234 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
4235 instantiations.
4236 (store_integer): New function template.
4237 (store_signed_integer): Remove.
4238 (store_unsigned_integer): Remove.
4239 (store_integer): Explicit instantiations.
4240 * regcache.c (regcache_raw_read_signed): Update.
4241 (regcache::raw_read): New function.
4242 (regcache::raw_read_signed): Remove.
4243 (regcache::raw_read_unsigned): Remove.
4244 (regcache_raw_read_unsigned): Update.
4245 (regcache_raw_write_unsigned): Update.
4246 (regcache::raw_write_signed): Remove.
4247 (regcache::raw_write): New function.
4248 (regcache_cooked_read_signed): Update.
4249 (regcache::raw_write_unsigned): Remove.
4250 (regcache::cooked_read_signed): Remove.
4251 (regcache_cooked_read_unsigned): Update.
4252 (regcache::cooked_read_unsigned): Remove.
4253 (regcache_cooked_write_signed): Update.
4254 (regcache_cooked_write_unsigned): Update.
4255 * regcache.h (regcache) <raw_read_signed>: Remove.
4256 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
4257 <raw_read, raw_write>: New.
4258 <cooked_read_signed, cooked_write_signed>: Remove.
4259 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
4260 <cooked_read, cooked_write>: New.
4261 * sh64-tdep.c (sh64_pseudo_register_read): Update.
4262 (sh64_pseudo_register_write): Update.
4263
a87dc45a
AK
42642017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
4265
4266 * arc-tdep.c (arc_disassembler_options): New variable.
4267 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
4268 of default_print_insn.
4269 (arc_delayed_print_insn): Set info->section when needed,
4270 use default_print_insn to retrieve a disassembler.
4271
45159d6a
SDJ
42722017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
4273
4274 PR gdb/21574
4275 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
4276 to mention $SHELL and startup-with-shell.
4277
b46c4cf0
MF
42782017-06-14 Max Filippov <jcmvbkbc@gmail.com>
4279
4280 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
4281
6394c606
YQ
42822017-06-14 Yao Qi <yao.qi@linaro.org>
4283
4284 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
4285 default_print_insn instead of print_insn_aarch64.
4286 * arm-tdep.c (gdb_print_insn_arm): Call
4287 default_print_insn instead of print_insn_big_arm
4288 and print_insn_little_arm.
4289 * i386-tdep.c (i386_print_insn): Call default_print_insn
4290 instead of print_insn_i386.
4291 * ia64-tdep.c (ia64_print_insn): Call
4292 default_print_insn instead of print_insn_ia64.
4293 * mips-tdep.c (gdb_print_insn_mips): Call
4294 default_print_insn instead of print_insn_big_mips
4295 and print_insn_little_mips.
4296 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
4297 instead of print_insn_spu.
4298
d5722aa2
PA
42992017-06-14 Pedro Alves <palves@redhat.com>
4300
4301 * ada-lang.c: Include "common/byte-vector.h".
4302 (ada_value_primitive_packed_val): Use gdb::byte_vector.
4303 * charset.c (wchar_iterator::iterate): Resize the vector instead
4304 of reserving it.
4305 * common/byte-vector.h: Include "common/def-vector.h".
4306 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
4307 * cli/cli-dump.c: Include "common/byte-vector.h".
4308 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
4309 * common/byte-vector.h: New file.
4310 * common/def-vector.h: New file.
4311 * common/default-init-alloc.h: New file.
4312 * dwarf2loc.c: Include "common/byte-vector.h".
4313 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
4314 instead of reserving it.
4315 * dwarf2read.c: Include "common/byte-vector.h".
4316 (data_buf::m_vec): Now a gdb::byte_vector.
4317 * gdb_regex.c: Include "common/def-vector.h".
4318 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
4319 * mi/mi-main.c: Include "common/byte-vector.h".
4320 (mi_cmd_data_read_memory): Use gdb::byte_vector.
4321 * printcmd.c: Include "common/byte-vector.h".
4322 (print_scalar_formatted): Use gdb::byte_vector.
4323 * valprint.c: Include "common/byte-vector.h".
4324 (maybe_negate_by_bytes, print_decimal_chars): Use
4325 gdb::byte_vector.
4326
01ec7a27
SM
43272017-06-13 Simon Marchi <simon.marchi@ericsson.com>
4328
4329 * darwin-nat.c: Include "nat/fork-inferior.h".
4330
848d9074
SM
43312017-06-13 Simon Marchi <simon.marchi@ericsson.com>
4332
4333 * configure.nat: Factor out Darwin bits that are not
4334 architecture-specific. Add fork-inferior.o.
4335
3b912944
SM
43362017-06-13 Simon Marchi <simon.marchi@ericsson.com>
4337
4338 * configure.nat: Factor out AIX bits that are not
4339 architecture-specific. Add fork-inferior.o.
4340
55acdf22
AA
43412017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4342
4343 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
4344 (read_pieced_value, write_pieced_value): ...here. Reduce to
4345 wrappers that just call rw_pieced_value.
4346
f65e2044
AA
43472017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4348
4349 * dwarf2loc.c (write_pieced_value): When writing the data for a
4350 memory piece, use write_memory_with_notification instead of
4351 write_memory.
4352
23f945bf
AA
43532017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4354
4355 * valops.c (read_value_memory): Change embedded_offset to
4356 represent a bit offset instead of a byte offset.
4357 * value.h (read_value_memory): Adjust comment.
4358
f236533e
AA
43592017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4360
4361 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
4362 dest_offset_bits and source_offset_bits.
4363 (write_pieced_value): Likewise.
4364
65d84b76
AA
43652017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4366
4367 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
4368 given by DW_OP_bit_piece.
4369 (write_pieced_value): Likewise.
4370
242d31ab
AA
43712017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4372
4373 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
4374 some other preparations to the places where sufficient information
4375 is available.
4376 (write_pieced_value): Likewise.
4377
03c8af18
AA
43782017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4379
4380 * dwarf2loc.c (bits_to_bytes): New function.
4381 (read_pieced_value): Fix offset calculations for register pieces
4382 on big-endian targets.
4383 (write_pieced_value): Likewise.
4384
840989c1
AA
43852017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4386
4387 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
4388 (write_pieced_value): Likewise.
4389
359b19bb
AA
43902017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4391
4392 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
4393 transfer the source value's least significant bits, instead of its
4394 lowest-addressed ones. Rename type_len to max_offset.
4395 (read_pieced_value): Mirror above changes to write_pieced_value as
4396 applicable.
4397
07c9ca3b
AA
43982017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4399
4400 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
4401 truncate full bytes from dest_offset_bits before using it as an
4402 offset into the buffer.
4403
f1cc9874
AA
44042017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4405
4406 * dwarf2loc.c (write_pieced_value): Include transfer size in
4407 byte-wise check.
4408
cdaac320
AA
44092017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4410
4411 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
4412 calculation of this_size.
4413
af547a96
AA
44142017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4415
4416 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
4417 when targeting a bit-field.
4418 (write_pieced_value): Likewise.
4419
ddd7882a
AA
44202017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4421
4422 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
4423 (allocate_piece_closure): Drop addr_size parameter.
4424 (dwarf2_evaluate_loc_desc_full): Adjust call to
4425 allocate_piece_closure.
4426
e9352324
AA
44272017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4428
4429 PR gdb/21226
4430 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
4431 the LSB end, independent of endianness.
4432
d5d1163e
AA
44332017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4434
4435 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
4436 size capping.
4437
032bb6ea
YQ
44382017-06-13 Yao Qi <yao.qi@linaro.org>
4439
4440 * mips-linux-nat.c: Move include features/mips*-linux.c to
4441 mips-linux-tdep.c.
4442 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
4443 to mips-linux-tdep.c.
4444 * mips-linux-tdep.c: Include features/mips*-linux.c
4445 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
4446 functions.
4447 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
4448 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
4449 (tdesc_mips64_dsp_linux): Declare.
4450
f12f6bad
TT
44512017-06-12 Tom Tromey <tom@tromey.com>
4452
4453 * valprint.h (val_print_type_code_int): Remove.
4454 * valprint.c (generic_val_print_int): Always call
4455 val_print_scalar_formatted.
4456 (val_print_type_code_int): Remove.
4457 * printcmd.c (print_scalar_formatted): Handle options->format==0.
4458 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
4459 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
4460 * ada-valprint.c (ada_val_print_num): Use
4461 val_print_scalar_formatted.
4462
d9109c80
TT
44632017-06-12 Tom Tromey <tom@tromey.com>
4464
4465 * printcmd.c (print_scalar_formatted): Unify the two switches.
4466 Don't convert scalars to LONGEST.
4467
4ac0cb1c
TT
44682017-06-12 Tom Tromey <tom@tromey.com>
4469
4470 PR exp/16225:
4471 * valprint.h (print_decimal_chars): Update.
4472 * valprint.c (maybe_negate_by_bytes): New function.
4473 (print_decimal_chars): Add "is_signed" argument.
4474 * printcmd.c (print_scalar_formatted): Update.
4475
30a25466
TT
44762017-06-12 Tom Tromey <tom@tromey.com>
4477
4478 PR exp/16225:
4479 * valprint.h (print_binary_chars, print_hex_chars): Update.
4480 * valprint.c (val_print_type_code_int): Update.
4481 (print_binary_chars): Add "zero_pad" argument.
4482 (emit_octal_digit): New function.
4483 (print_octal_chars): Don't zero-pad.
4484 (print_decimal_chars): Likewise.
4485 (print_hex_chars): Add "zero_pad" argument.
4486 * sh64-tdep.c (sh64_do_fp_register): Update.
4487 * regcache.c (regcache::dump): Update.
4488 * printcmd.c (print_scalar_formatted): Update.
4489 * infcmd.c (default_print_one_register_info): Update.
4490
b3464d03
PA
44912017-06-12 Pedro Alves <palves@redhat.com>
4492 Alan Hayward <alan.hayward@arm.com>
4493
4494 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
4495 (mips_eabi_push_dummy_call): Rename local 'regsize' to
4496 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
4497 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
4498 Assert that abi_regsize bytes fit in 'ref_valbuf'.
4499
4b76cda9
PA
45002017-06-12 Pedro Alves <palves@redhat.com>
4501
4502 * dwarf2read.c (mapped_symtab::data): Now a vector of
4503 symtab_index_entry instead of vector of
4504 std::unique_ptr<symtab_index_entry>. All users adjusted to check
4505 whether an element's name is NULL instead of checking whether the
4506 element itself is NULL.
4507 (find_slot): Change return type. Adjust.
4508 (hash_expand, , add_index_entry, uniquify_cu_indices)
4509 (write_hash_table): Adjust.
4510
e8f8bcb3
PA
45112017-06-12 Pedro Alves <palves@redhat.com>
4512
4513 * dwarf2read.c (recursively_count_psymbols): New function.
4514 (write_psymtabs_to_index): Call it to compute number of psyms and
4515 pass estimate size of psyms_seen to unordered_set's ctor.
4516
70a1152b
PA
45172017-06-12 Pedro Alves <palves@redhat.com>
4518
4519 * dwarf2read.c (write_hash_table): Check if key already exists
4520 before emplacing.
4521
c2f134ac
PA
45222017-06-12 Pedro Alves <palves@redhat.com>
4523
4524 * dwarf2read.c (data_buf::append_space): Rename to...
4525 (data_buf::grow): ... this, and make private. Adjust all callers.
4526 (data_buf::append_uint): New method.
4527 (add_address_entry, write_one_signatured_type)
4528 (write_psymtabs_to_index): Use it.
4529
a81e6d4d
PA
45302017-06-12 Pedro Alves <palves@redhat.com>
4531
4532 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
4533 (file_write (FILE *, const std::vector<Elem>&)): Delete.
4534 (data_buf::file_write): Call ::fwrite directly.
4535
6fd931f2
PA
45362017-06-12 Pedro Alves <palves@redhat.com>
4537
4538 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
4539 std::vector::erase.
4540
bc8f2430
JK
45412017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
4542
4543 Code cleanup: C++ify .gdb_index producer.
4544 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
4545 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
4546 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
4547 (create_strtab, add_string): Remove.
4548 (file_write, data_buf): New.
4549 (struct symtab_index_entry): Use std::vector for cu_indices.
4550 (struct mapped_symtab): Use std::vector for data.
4551 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
4552 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
4553 Remove.
4554 (find_slot): Change return type. Update it to the new data structures.
4555 (hash_expand, add_index_entry): Update it to the new data structures.
4556 (offset_type_compare): Remove.
4557 (uniquify_cu_indices): Update it to the new data structures.
4558 (c_str_view, c_str_view_hasher, vector_hasher): New.
4559 (add_indices_to_cpool): Remove.
4560 (write_hash_table): Update it to the new data structures.
4561 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
4562 (eq_psymtab_cu_index): Remove.
4563 (psym_index_map): New typedef.
4564 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
4565 reference and std::unordered_map for cu_index_htab.
4566 (add_address_entry, add_address_entry_worker, write_address_map)
4567 (write_psymbols): Update it to the new data structures.
4568 (write_obstack): Remove.
4569 (struct signatured_type_index_data): Change types_list to a data_buf
4570 reference and psyms_seen to a std::unordered_set reference.
4571 (write_one_signatured_type, recursively_write_psymbols)
4572 (write_psymtabs_to_index): Update it to the new data structures.
4573
c4dcb155
SM
45742017-06-11 Simon Marchi <simon.marchi@ericsson.com>
4575
4576 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
4577 separate-debug-file commands.
4578 * symfile.h (separate_debug_file_debug): New global.
4579 * symfile.c (separate_debug_file_debug): New global.
4580 (separate_debug_file_exists, find_separate_debug_file): Add
4581 debug output.
4582 (_initialize_symfile): Add "set debug separate-debug-file"
4583 command.
4584 * build-id.c (build_id_to_debug_bfd,
4585 find_separate_debug_file_by_buildid): Add debug output.
4586
6d45d4b4
SM
45872017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
4588
4589 * gdbarch.sh (displaced_step_free_closure): Remove.
4590 * gdbarch.h, gdbarch.c: Re-generate.
4591 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
4592 displaced_step_free_closure.
4593 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
4594 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
4595 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
4596 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
4597 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
4598 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
4599 * arch-utils.h (simple_displaced_step_free_closure): Remove.
4600 * arch-utils.c (simple_displaced_step_free_closure): Remove.
4601 * infrun.c (displaced_step_clear): Call xfree instead of
4602 gdbarch_displaced_step_free_closure.
4603
2f91880f
SDJ
46042017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
4605
4606 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
4607 NULL".
4608
b8b6e72f
AH
46092017-06-08 Alan Hayward <alan.hayward@arm.com>
4610
4611 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
4612 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
4613 (mn10300_push_dummy_call): Likewise.
4614
5369082e
AH
46152017-06-08 Alan Hayward <alan.hayward@arm.com>
4616
4617 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
4618
ff4ca5ac
AH
46192017-06-08 Alan Hayward <alan.hayward@arm.com>
4620
4621 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
4622
aefd8b33
SDJ
46232017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4624
4625 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
4626 able to start inferiors using a shell.
4627 (New remote packets): Announce new packet "QStartupWithShell".
4628 * remote.c: Add PACKET_QStartupWithShell.
4629 (extended_remote_create_inferior): Handle new
4630 PACKET_QStartupWithShell.
4631 (remote_protocol_features) <QStartupWithShell>: New entry for
4632 PACKET_QStartupWithShell.
4633 (_initialize_remote): Call "add_packet_config_cmd" for
4634 QStartupShell.
4635
2090129c
SDJ
46362017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4637 Pedro Alves <palves@redhat.com>
4638
4639 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
4640 and "nat/fork-inferior.h".
4641 * common/common-inferior.h: New file, with contents from
4642 "gdb/inferior.h".
4643 * commom/common-utils.c: Include "common-utils.h".
4644 (stringify_argv): New function.
4645 * common/common-utils.h (stringify_argv): New prototype.
4646 * configure.nat: Add "fork-inferior.o" as a dependency for
4647 "*linux*", "fbsd*" and "nbsd*" hosts.
4648 * corefile.c (get_exec_file): Update comment.
4649 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
4650 instead of "startup_inferior".
4651 (darwin_create_inferior): Call "add_thread_silent" after
4652 "fork_inferior".
4653 * fork-child.c: Cleanup unnecessary includes.
4654 (SHELL_FILE): Move to "common/common-fork-child.c".
4655 (environ): Likewise.
4656 (exec_wrapper): Initialize.
4657 (get_exec_wrapper): New function.
4658 (breakup_args): Move to "common/common-fork-child.c"; rename to
4659 "breakup_args_for_exec".
4660 (escape_bang_in_quoted_argument): Move to
4661 "common/common-fork-child.c".
4662 (saved_ui): New variable.
4663 (prefork_hook): New function.
4664 (postfork_hook): Likewise.
4665 (postfork_child_hook): Likewise.
4666 (gdb_startup_inferior): Likewise.
4667 (fork_inferior): Move to "common/common-fork-child.c". Update
4668 function to support gdbserver.
4669 (startup_inferior): Likewise.
4670 * gdbcore.h (get_exec_file): Remove declaration.
4671 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
4672 instead of "startup_inferior". Call "add_thread_silent" after
4673 "fork_inferior".
4674 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
4675 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
4676 instead of "startup_inferior". Call "add_thread_silent" after
4677 "fork_inferior".
4678 * inferior.h: Include "common-inferior.h".
4679 (trace_start_error): Move to "common/common-utils.h".
4680 (trace_start_error_with_name): Likewise.
4681 (fork_inferior): Move prototype to "nat/fork-inferior.h".
4682 (startup_inferior): Likewise.
4683 (gdb_startup_inferior): New prototype.
4684 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
4685 * nat/fork-inferior.h: New file.
4686 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
4687 instead of "startup_inferior". Call "add_thread_silent" after
4688 "fork_inferior".
4689 * target.h (target_terminal_init): Move prototype to
4690 "target/target.h".
4691 (target_terminal_inferior): Likewise.
4692 (target_terminal_ours): Likewise.
4693 * target/target.h (target_terminal_init): New prototype, moved
4694 from "target.h".
4695 (target_terminal_inferior): Likewise.
4696 (target_terminal_ours): Likewise.
4697 * utils.c (gdb_flush_out_err): New function.
4698
043a4934
SDJ
46992017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4700
4701 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
4702 * common/common-gdbthread.h: New file, with parts from
4703 "gdb/gdbthread.h".
4704 * gdbthread.h: Include "common-gdbthread.h".
4705 (switch_to_thread): Moved to "common/common-gdbthread.h".
4706
15652511
SDJ
47072017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
4708
4709 * Makefile.in (SFILES): Add "common/job-control.c".
4710 (HFILES_NO_SRCDIR): Add "common/job-control.h".
4711 (COMMON_OBS): Add "job-control.o".
4712 * common/job-control.c: New file, with contents from
4713 "gdb/inflow.c".
4714 * common/job-control.h: New file, with contents from "terminal.h".
4715 * fork-child.c: Include "job-control.h".
4716 * inflow.c: Include "job-control.h".
4717 (gdb_setpgid): Move to "common/common-inflow.c".
4718 (_initialize_inflow): Move setting of "job_control" to
4719 "handle_job_control".
4720 * terminal.h (job_control): Moved to "common/common-terminal.h".
4721 (gdb_setpgid): Likewise.
4722 * top.c: Include "job_control.h".
4723 * utils.c: Likewise.
4724 (job_control): Moved to "job-control.c".
4725
2d7cc5c7
PA
47262017-06-07 Pedro Alves <palves@redhat.com>
4727
4728 * Makefile.in (SFILES): Add gdb_regex.c.
4729 (COMMON_OBS): Add gdb_regex.o.
4730 * ada-lang.c (ada_add_standard_exceptions)
4731 (ada_add_exceptions_from_frame, name_matches_regex)
4732 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
4733 parameter type to compiled_regex. Adjust.
4734 (ada_exceptions_list): Use compiled_regex.
4735 * break-catch-throw.c (exception_catchpoint::pattern): Now a
4736 std::unique_ptr<compiled_regex>.
4737 (exception_catchpoint::~exception_catchpoint): Remove regfree
4738 call.
4739 (check_status_exception_catchpoint): Adjust to use compiled_regex.
4740 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
4741 * breakpoint.c (solib_catchpoint::compiled): Now a
4742 std::unique_ptr<compiled_regex>.
4743 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
4744 (check_status_catch_solib): Adjust to use compiled_regex.
4745 (add_solib_catchpoint): Adjust to use compiled_regex.
4746 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
4747 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
4748 compiled_regex reference. Adjust to use it.
4749 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
4750 declaration. Include "gdb_regex.h".
4751 (apropos_cmd): Change regex parameter to compiled_regex reference.
4752 * gdb_regex.c: New file.
4753 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
4754 declarations.
4755 (class compiled_regex): New.
4756 * linux-tdep.c: Include "common/gdb_optional.h".
4757 (struct mapping_regexes): New, factored out from
4758 mapping_is_anonymous_p, and adjusted to use compiled_regex.
4759 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
4760 gdb::optional and remove cleanups. Adjust to compiled_regex.
4761 * probe.c: Include "common/gdb_optional.h".
4762 (collect_probes): Use compiled_regex and gdb::optional and remove
4763 cleanups.
4764 * skip.c: Include "common/gdb_optional.h".
4765 (skiplist_entry::compiled_function_regexp): Now a
4766 gdb::optional<compiled_regex>.
4767 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
4768 (free_skiplist_entry): Remove regfree call.
4769 (compile_skip_regexp, skip_rfunction_p): Adjust to use
4770 compiled_regex and gdb::optional.
4771 * symtab.c: Include "common/gdb_optional.h".
4772 (search_symbols): Use compiled_regex and gdb::optional.
4773 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
4774 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
4775 to gdb_regex.c.
4776
50d6adef
AH
47772017-06-07 Alan Hayward <alan.hayward@arm.com>
4778
4779 * regcache.c (regcache::save): Avoid buffer use.
4780 (regcache::dump): Likewise.
4781
4a8a33c8
AH
47822017-06-07 Alan Hayward <alan.hayward@arm.com>
4783
4784 * sh-tdep.c (sh_pseudo_register_read): Remove
4785 MAX_REGISTER_SIZE.
4786 (sh_pseudo_register_write): Likewise.
4787 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
4788 (sh64_pseudo_register_write): Likewise
4789
d1be909e
AH
47902017-06-07 Alan Hayward <alan.hayward@arm.com>
4791
4792 * aarch64-tdep.c (aarch64_store_return_value): Use
4793 V_REGISTER_SIZE.
4794 (aarch64_pseudo_read_value): Likewise.
4795 (aarch64_pseudo_write): Likewise.
4796
f4a65042
YQ
47972017-06-06 Yao Qi <yao.qi@linaro.org>
4798
4799 * regformats/regdef.h (set_register_cache): Remove the
4800 declaration.
4801
9f7fb0aa
AH
48022017-06-06 Alan Hayward <alan.hayward@arm.com>
4803
4804 * frame.c (frame_unwind_register_signed): Use
4805 frame_unwind_register_value.
4806
e1e01040
PA
48072017-06-06 Pedro Alves <palves@redhat.com>
4808
4809 PR breakpoints/21553
4810 * breakpoint.c (create_breakpoints_sal_default)
4811 (init_breakpoint_sal, create_breakpoint_sal): Use
4812 gdb::unique_xmalloc_ptr for string parameters.
4813 (create_breakpoint): Constify 'extra_string' and 'cond_string'
4814 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
4815 (base_breakpoint_create_breakpoints_sal)
4816 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
4817 (strace_marker_create_breakpoints_sal)
4818 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
4819 string parameters.
4820 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
4821 gdb::unique_xmalloc_ptr for string parameters.
4822 (create_breakpoint): Constify 'extra_string' and 'cond_string'
4823 parameters.
4824
fbe654c8
AH
48252017-06-06 Alan Hayward <alan.hayward@arm.com>
4826
4827 * alpha-tdep.c (alpha_register_to_value): Use
4828 get_frame_register_value.
4829 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
4830
ae0d01d6
AH
48312017-06-06 Alan Hayward <alan.hayward@arm.com>
4832
4833 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
4834 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
4835 (ia64_value_to_register): Likewise.
4836 (ia64_extract_return_value): Likewise.
4837 (ia64_store_return_value): Likewise.
4838 (ia64_push_dummy_call): Likewise.
4839
49cf576c
JB
48402017-06-04 Joel Brobecker <brobecker@adacore.com>
4841
4842 GDB 8.0 released.
4843
26b6a6ab
SM
48442017-06-03 Simon Marchi <simon.marchi@ericsson.com>
4845
4846 * x86-linux-nat.c (struct arch_lwp_info): Remove.
4847
22827c51
SM
48482017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
4849
4850 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
4851 parameter.
4852 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
4853
0e05cf3a
SM
48542017-06-02 Simon Marchi <simon.marchi@ericsson.com>
4855
4856 * event-loop.c (poll_timers): Unallocate timer using delete
4857 instead of xfree.
4858
c1fc2657
SM
48592017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
4860
4861 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
4862 (struct breakpoint) <~breakpoint>: New.
4863 (struct watchpoint): Inherit from breakpoint.
4864 <~watchpoint>: New.
4865 <base>: Remove.
4866 (struct tracepoint): Inherit from breakpoint.
4867 <base>: Remove.
4868 * breakpoint.c (longjmp_breakpoint_ops): Remove.
4869 (struct longjmp_breakpoint): Inherit from breakpoint.
4870 <~longjmp_breakpoint>: New.
4871 <base>: Remove.
4872 (new_breakpoint_from_type): Remove casts.
4873 (watchpoint_in_thread_scope): Remove reference to base field.
4874 (watchpoint_del_at_next_stop): Likewise.
4875 (update_watchpoint): Likewise.
4876 (watchpoint_check): Likewise.
4877 (bpstat_check_watchpoint): Likewise.
4878 (set_longjmp_breakpoint): Likewise.
4879 (struct fork_catchpoint): Inherit from breakpoint.
4880 <base>: Remove.
4881 (struct solib_catchpoint): Inherit from breakpoint.
4882 <~solib_catchpoint>: New.
4883 <base>: Remove.
4884 (dtor_catch_solib): Change to ...
4885 (solib_catchpoint::~solib_catchpoint): ... this.
4886 (breakpoint_hit_catch_solib): Remove reference to base field.
4887 (add_solib_catchpoint): Likewise.
4888 (create_fork_vfork_event_catchpoint): Likewise.
4889 (struct exec_catchpoint): Inherit from breakpoint.
4890 <~exec_catchpoint>: New.
4891 <base>: Remove.
4892 (dtor_catch_exec): Change to ...
4893 (exec_catchpoint::~exec_catchpoint): ... this.
4894 (dtor_watchpoint): Change to ...
4895 (watchpoint::~watchpoint): ... this.
4896 (watch_command_1): Remove reference to base field.
4897 (catch_exec_command_1): Likewise.
4898 (base_breakpoint_dtor): Change to ...
4899 (breakpoint::~breakpoint): ... this.
4900 (base_breakpoint_ops): Remove dtor field value.
4901 (longjmp_bkpt_dtor): Change to ...
4902 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
4903 (strace_marker_create_breakpoints_sal): Remove reference to base
4904 field.
4905 (delete_breakpoint): Don't manually call breakpoint destructor.
4906 (create_tracepoint_from_upload): Remove reference to base field.
4907 (trace_pass_set_count): Likewise.
4908 (initialize_breakpoint_ops): Don't initialize
4909 momentary_breakpoint_ops, don't set dtors.
4910 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
4911 <~ada_catchpoint>: New.
4912 <base>: Remove.
4913 (create_excep_cond_exprs): Remove reference to base field.
4914 (dtor_exception): Change to ...
4915 (ada_catchpoint::~ada_catchpoint): ... this.
4916 (dtor_catch_exception): Remove.
4917 (dtor_catch_exception_unhandled): Remove.
4918 (dtor_catch_assert): Remove.
4919 (create_ada_exception_catchpoint): Remove reference to base
4920 field.
4921 (initialize_ada_catchpoint_ops): Don't set dtors.
4922 * break-catch-sig.c (struct signal_catchpoint): Inherit from
4923 breakpoint.
4924 <~signal_catchpoint>: New.
4925 <base>: Remove.
4926 (signal_catchpoint_dtor): Change to ...
4927 (signal_catchpoint::~signal_catchpoint): ... this.
4928 (create_signal_catchpoint): Remove reference to base field.
4929 (initialize_signal_catchpoint_ops): Don't set dtor.
4930 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
4931 from breakpoint.
4932 <~syscall_catchpoint>: New.
4933 <base>: Remove.
4934 (dtor_catch_syscall): Change to ...
4935 (syscall_catchpoint::~syscall_catchpoint): ... this.
4936 (create_syscall_event_catchpoint): Remove reference to base
4937 field.
4938 (initialize_syscall_catchpoint_ops): Don't set dtor.
4939 * break-catch-throw.c (struct exception_catchpoint): Inherit
4940 from breakpoint.
4941 <~exception_catchpoint>: New.
4942 <base>: Remove.
4943 (dtor_exception_catchpoint): Change to ...
4944 (exception_catchpoint::~exception_catchpoint): ... this.
4945 (handle_gnu_v3_exceptions): Remove reference to base field.
4946 (initialize_throw_catchpoint_ops): Don't set dtor.
4947 * ctf.c (ctf_get_traceframe_address): Remove reference to base
4948 field.
4949 * remote.c (remote_get_tracepoint_status): Likewise.
4950 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
4951 * tracefile.c (tracefile_fetch_registers): Likewise.
4952 * tracepoint.c (actions_command): Likewise.
4953 (validate_actionline): Likewise.
4954 (tfind_1): Likewise.
4955 (get_traceframe_location): Likewise.
4956 (find_matching_tracepoint_location): Likewise.
4957 (parse_tracepoint_status): Likewise.
4958 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
4959
3b0871f4
SM
49602017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
4961
4962 * breakpoint.c (struct longjmp_breakpoint): New struct.
4963 (is_tracepoint_type): Change return type to bool.
4964 (is_longjmp_type): New function.
4965 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
4966 (set_raw_breakpoint_without_location): Use
4967 new_breakpoint_from_type.
4968 (set_raw_breakpoint): Likewise.
4969
a5e364af
SM
49702017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
4971
4972 * breakpoint.c (new_breakpoint_from_type): New function.
4973 (create_breakpoint_sal): Use new_breakpoint_from_type and
4974 unique_ptr.
4975 (create_breakpoint): Likewise.
4976
ae3b3f34
SM
49772017-05-31 Simon Marchi <simon.marchi@ericsson.com>
4978
4979 * memattr.c (mem_info_command): Rename to ...
4980 (info_mem_command): ... this.
4981 (mem_enable_command): Rename to ...
4982 (enable_mem_command): ... this.
4983 (mem_disable_command): Rename to ...
4984 (disable_mem_command): ... this.
4985 (mem_delete_command): Rename to ...
4986 (delete_mem_command): ... this.
4987 (_initialize_mem): Adjust function names.
4988
13ace077
MM
49892017-05-31 Markus Metzger <markus.t.metzger@intel.com>
4990
4991 * btrace.c (handle_pt_insn_events): New.
4992 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
4993 STATUS. Split into this and ...
4994 (handle_pt_insn_event_flags): ... this.
4995
c56ccc05
MM
49962017-05-31 Markus Metzger <markus.t.metzger@intel.com>
4997
4998 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
4999 and struct pt_insn.resynced.
5000 * configure: Regenerated.
5001 * config.in: Regenerated.
5002
08c3f6d2
TW
50032017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5004
5005 * btrace.c (ftrace_find_call_by_number): New function.
5006 (ftrace_new_function): Store objects, not pointers.
5007 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
5008 ftrace_new_gap, ftrace_update_function,
5009 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
5010 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
5011 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
5012 btrace_ends_with_single_insn, btrace_call_get): Account for
5013 btrace_thread_info::functions now storing objects.
5014 * btrace.h (struct btrace_thread_info): Add constructor.
5015 (struct btrace_thread_info) <functions>: Make std::vector.
5016 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
5017 Initialize with default values.
5018 * record-btrace.c (record_btrace_frame_sniffer): Account for
5019 btrace_thread_info::functions now storing objects.
5020
8ffd39f2
TW
50212017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5022
5023 * btrace.c: Remove typedef bfun_s.
5024 (ftrace_new_gap): Directly add gaps to the list of gaps.
5025 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
5026 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
5027 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
5028 instead of gdb VEC.
5029
4aeb0dfc
TW
50302017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5031
5032 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
5033 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
5034 with btrace_thread_info::next_segment and
5035 btrace_thread_info::prev_segment.
5036 * btrace.h: Remove struct btrace_func_link.
5037 (struct btrace_function): Replace pair of function segment pointers
5038 with pair of indices.
5039 * python/py-record-btrace.c (btpy_call_prev_sibling,
5040 btpy_call_next_sibling): Replace references to
5041 btrace_thread_info::segment with btrace_thread_info::next_segment and
5042 btrace_thread_info::prev_segment.
5043 * record-btrace.c (record_btrace_frame_this_id): Use
5044 btrace_find_call_by_number.
5045
eb8f2b9c
TW
50462017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5047
5048 * btrace.c (ftrace_new_function, ftrace_fixup_level,
5049 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
5050 btrace_insn_next, btrace_insn_prev): Remove references to
5051 btrace_thread_info::flow.
5052 * btrace.h (struct btrace_function): Remove FLOW.
5053
42bfe59e
TW
50542017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5055
5056 * btrace.c (ftrace_find_call_by_number): New function.
5057 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
5058 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
5059 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
5060 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
5061 index.
5062 * btrace.h (struct btrace_function): Turn UP into an index.
5063 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
5064 as an index.
5065 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
5066 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
5067 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
5068
b54b03bd
TW
50692017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5070
5071 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
5072 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
5073 ftrace_update_function, ftrace_compute_global_level_offset,
5074 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
5075 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
5076 btrace_insn_end, btrace_is_empty): Remove references to
5077 btrace_thread_info::begin and btrace_thread_info::end.
5078 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
5079 (struct btrace_thread_info) <functions>: Adjust comment.
5080 * record-btrace.c (record_btrace_start_replaying): Remove reference to
5081 btrace_thread_info::begin.
5082
8286623c
TW
50832017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5084
5085 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
5086 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
5087 ftrace_update_function): Remove arguments that implicitly were always
5088 BTINFO->END.
5089 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
5090 Don't pass BTINFO->END.
5091
a0f1b963
TW
50922017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5093
5094 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
5095 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
5096 btrace_find_insn_by_number): Replace function segment pointer with
5097 index.
5098 (btrace_insn_cmp): Simplify.
5099 * btrace.h: (struct btrace_insn_iterator) Rename index to
5100 insn_index. Replace function segment pointer with index into function
5101 segment vector.
5102 * record-btrace.c (record_btrace_call_history): Replace function
5103 segment pointer use with index.
5104 (record_btrace_frame_sniffer): Retrieve function call segment through
5105 vector.
5106 (record_btrace_set_replay): Remove defunc't safety check.
5107
f158f208
TW
51082017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5109
5110 * btrace.c (btrace_ends_with_single_insn): New function.
5111 (btrace_call_get, btrace_call_number, btrace_call_begin,
5112 btrace_call_end, btrace_call_next, btrace_call_prev,
5113 btrace_find_call_by_number): Use index into call segment vector
5114 instead of pointer.
5115 (btrace_call_cmp): Simplify.
5116 * btrace.h (struct btrace_call_iterator): Replace function call segment
5117 pointer with index into vector.
5118 * record-btrace.c (record_btrace_call_history): Use index instead of
5119 pointer.
5120
521103fd
TW
51212017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5122
5123 * btrace.c (btrace_insn_begin, btrace_insn_end,
5124 btrace_find_insn_by_number): Add btinfo to iterator.
5125 * btrace.h (struct btrace_insn_iterator): Add btinfo.
5126
17b89b34
TW
51272017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5128
5129 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
5130 and save pointers directly.
5131 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
5132 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
5133 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
5134 changed signature of functions.
5135 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
5136 (btrace_fetch): Remove code that adds btrace_function pointers to
5137 vector of btrace_functions.
5138 (btrace_clear): Simplify freeing vector of btrace_functions.
5139
2b51eddc
TW
51402017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5141
5142 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
5143 Replace VEC_* with std::vector functions.
5144 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
5145 (struct btrace_thread_info)<functions>: Change type to std::vector.
5146
db6be0d5
SM
51472017-05-30 Simon Marchi <simon.marchi@ericsson.com>
5148
5149 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
5150 "Removed targets and native configurations" up. Merge duplicate
5151 "New commands" sub-sections. Add "New options" sub-sections.
5152
b057297a
AH
51532017-05-26 Alan Hayward <alan.hayward@arm.com>
5154
5155 * defs.h (copy_integer_to_size): New declaration.
5156 * findvar.c (copy_integer_to_size): New function.
5157 (do_cint_test): New selftest function.
5158 (copy_integer_to_size_test): Likewise.
5159 (_initialize_findvar): Likewise.
5160 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
5161 (mips_fbsd_collect_reg): Use raw_collect_integer.
5162 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
5163 (mips64_fill_gregset): Use raw_collect_integer
5164 (mips64_fill_fpregset): Use raw_supply_integer.
5165 * regcache.c (regcache::raw_supply_integer): New function.
5166 (regcache::raw_collect_integer): Likewise.
5167 * regcache.h: (regcache::raw_supply_integer): New declaration.
5168 (regcache::raw_collect_integer): Likewise.
5169
b77b02a5
YQ
51702017-05-24 Yao Qi <yao.qi@linaro.org>
5171
5172 * Makefile.in (SFILES): Add gdbarch-selftests.c.
5173 (COMMON_OBS): Add gdbarch-selftests.o.
5174 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
5175 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
5176 * gdbarch-selftests.c: New file.
5177 * regcache.h (regcache) <~regcache>: Mark it virtual if
5178 GDB_SELF_TEST.
5179 <raw_write>: Likewise.
5180
e521e87e
YQ
51812017-05-24 Yao Qi <yao.qi@linaro.org>
5182
5183 * regcache.c (current_regcache): Change it to
5184 regcache::current_regcache.
5185 (regcache_observer_target_changed): Update.
5186 (regcache_thread_ptid_changed): Make it a regcache static
5187 method.
5188 (regcache_thread_ptid_changed): Update.
5189 (class regcache_access): New.
5190 (current_regcache_test): Update.
5191 (_initialize_regcache): Update.
5192 * regcache.h: Include forward_list.
5193 (regcache): Declare regcache_thread_ptid_changed and declare
5194 registers_changed_ptid as friend.
5195
d8e07dda
YQ
51962017-05-24 Yao Qi <yao.qi@linaro.org>
5197
5198 * i387-tdep.c (i387_register_to_value): Use register_size
5199 instead of TYPE_LENGTH.
5200 * m68k-tdep.c (m68k_register_to_value): Likewise.
5201
8c8f9122
YQ
52022017-05-24 Yao Qi <yao.qi@linaro.org>
5203
5204 * i387-tdep.c (i387_convert_register_p): Return false if type
5205 code isn't TYPE_CODE_FLT.
5206
68fce50f
YQ
52072017-05-24 Yao Qi <yao.qi@linaro.org>
5208
5209 * alpha-tdep.c (alpha_convert_register_p): Return true if type
5210 length is 4.
5211 (alpha_register_to_value): Remove type length check.
5212 (alpha_value_to_register): Likewise.
5213
88954b49
YQ
52142017-05-24 Yao Qi <yao.qi@linaro.org>
5215
5216 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
5217 TYPE_CODE_FLT.
5218
e3ec9b69
YQ
52192017-05-24 Yao Qi <yao.qi@linaro.org>
5220
5221 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
5222 TYPE_CODE_FLT or not.
5223
cdd238da
YQ
52242017-05-24 Yao Qi <yao.qi@linaro.org>
5225
5226 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
5227 * avr-tdep.c (avr_gdbarch_init): Likewise.
5228 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
5229 * cris-tdep.c (cris_gdbarch_init): Likewise.
5230 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
5231 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
5232 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
5233 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
5234 * mep-tdep.c (mep_gdbarch_init): Likewise.
5235 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
5236 * mips-tdep.c (mips_gdbarch_init): Likewise.
5237 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
5238 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
5239 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
5240 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
5241 * v850-tdep.c (v850_gdbarch_init): Likewise.
5242
7a3929c4
YQ
52432017-05-24 Yao Qi <yao.qi@linaro.org>
5244
5245 * selftest-arch.c (tests_with_arch): Call registers_changed
5246 and reinit_frame_cache.
5247 * selftest.c (run_self_tests): Likewise.
5248
f4985dba
YQ
52492017-05-24 Yao Qi <yao.qi@linaro.org>
5250
5251 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
5252 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
5253
ab20fa4a
YQ
52542017-05-24 Yao Qi <yao.qi@linaro.org>
5255
5256 * rl78-tdep.c (rl78_gdbarch_init): Don't call
5257 set_gdbarch_print_insn.
5258
f532ab94
YQ
52592017-05-24 Yao Qi <yao.qi@linaro.org>
5260
5261 * h8300-tdep.c (h8300_gdbarch_init): Don't call
5262 set_gdbarch_print_insn.
5263
39503f82
YQ
52642017-05-24 Yao Qi <yao.qi@linaro.org>
5265
5266 * alpha-tdep.c (alpha_gdbarch_init): Don't call
5267 set_gdbarch_print_insn.
5268 * arc-tdep.c (arc_gdbarch_init): Likewise.
5269 * arch-utils.c: include dis-asm.h.
5270 (default_print_insn): New function.
5271 * arch-utils.h (default_print_insn): Declare.
5272 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
5273 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
5274 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
5275 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
5276 * frv-tdep.c (frv_gdbarch_init): Likewise.
5277 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
5278 * gdbarch.sh (print_insn): Use default_print_insn.
5279 * gdbarch.c: Regenerated.
5280 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
5281 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
5282 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
5283 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
5284 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
5285 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
5286 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
5287 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
5288 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
5289 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
5290 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
5291 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
5292 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
5293 * mt-tdep.c (mt_gdbarch_init): Likewise.
5294 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
5295 * nios2-tdep.c (nios2_print_insn): Remove.
5296 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
5297 * rx-tdep.c (rx_gdbarch_init): Likewise.
5298 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
5299 * score-tdep.c (score_print_insn): Remove.
5300 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
5301 * sh-tdep.c (sh_gdbarch_init): Likewise.
5302 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
5303 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
5304 * tic6x-tdep.c (tic6x_print_insn): Remove.
5305 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
5306 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
5307 * v850-tdep.c (v850_gdbarch_init): Likewise.
5308 * vax-tdep.c (vax_gdbarch_init): Likewise.
5309 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
5310 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
5311
f7241d4f
JB
53122017-05-23 John Baldwin <jhb@FreeBSD.org>
5313
5314 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
5315 (MIPS_FP0_REGNUM): Remove.
5316 (MIPS_FSR_REGNUM): Remove.
5317 (mips_fbsd_supply_fpregs): Use mips_regnum.
5318 (mips_fbsd_supply_gregs): Likewise.
5319 (mips_fbsd_collect_fpregs): Likewise.
5320 (mips_fbsd_collect_gregs): Likewise.
5321
d489d81d
JB
53222017-05-23 John Baldwin <jhb@FreeBSD.org>
5323
5324 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
5325 (getpfpregs_supplies): New function.
5326 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
5327 getfpregs_supplies.
5328 (mips_fbsd_store_inferior_registers): Likewise.
5329
e11b3cdc
PA
53302017-05-22 Pedro Alves <palves@redhat.com>
5331
5332 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
5333 maintainer.
5334
0f068fb5
AH
53352017-05-22 Alan Hayward <alan.hayward@arm.com>
5336
5337 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
5338 (store_register): Likewise.
5339 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
5340 (get_decimal_float_return_value): Likewise.
5341 (do_ppc_sysv_return_value): Likewise.
5342 (ppc64_sysv_abi_push_integer): Likewise.
5343 (ppc64_sysv_abi_push_freg): Likewise.
5344 (ppc64_sysv_abi_return_value_base): Likewise.
5345 (ppc64_sysv_abi_return_value): Likewise.
5346 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
5347 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
5348 * rs6000-nat.c: Likewise.
5349 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
5350 (rs6000_value_to_register): Likewise.
5351 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
5352
e6cf65f2
TT
53532017-05-21 Tom Tromey <tom@tromey.com>
5354
5355 PR rust/21466:
5356 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
5357 arrays as "[T]", not "[T; ]".
5358
43cc5389
TT
53592017-05-19 Tom Tromey <tom@tromey.com>
5360
5361 PR rust/21484:
5362 * rust-lang.c (exp_descriptor_rust): New function.
5363 (rust_language_defn): Use it.
5364 * p-lang.c (pascal_language_defn): Update.
5365 * opencl-lang.c (opencl_language_defn): Update.
5366 * objc-lang.c (objc_language_defn): Update.
5367 * m2-lang.c (m2_language_defn): Update.
5368 * language.h (struct language_defn)
5369 <la_watch_location_expression>: New member.
5370 * language.c (unknown_language_defn, auto_language_defn)
5371 (local_language_defn): Update.
5372 * go-lang.c (go_language_defn): Update.
5373 * f-lang.c (f_language_defn): Update.
5374 * d-lang.c (d_language_defn): Update.
5375 * c-lang.h (c_watch_location_expression): Declare.
5376 * c-lang.c (c_watch_location_expression): New function.
5377 (c_language_defn, cplus_language_defn, asm_language_defn)
5378 (minimal_language_defn): Use it.
5379 * breakpoint.c (watch_command_1): Call
5380 la_watch_location_expression.
5381 * ada-lang.c (ada_language_defn): Update.
5382
7a6e7fcc
RO
53832017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5384
6e7e1744
RO
5385 PR tui/21482
5386 * gdb_curses.h (NOMACROS): Define.
5387 (NCURSES_NOMACROS): Define.
5388
53892017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5390
5391 PR tui/21482
7a6e7fcc
RO
5392 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
5393 arg to char *.
5394 * tui/tui-wingeneral.c (box_win): Likewise.
5395 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
5396 (tui_show_source_line): Likewise.
5397 (tui_show_exec_info_content): Likewise.
5398
1933fd8e
VM
53992017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
5400
5401 * sparc-tdep.c (sparc_structure_return_p)
5402 (sparc_arg_on_registers_p): New functions.
5403 (sparc32_store_arguments): Use them.
5404 * sparc64-tdep.c (sparc64_16_byte_align_p)
5405 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
5406 Handle TYPE_CODE_ARRAY.
5407
21873064
YQ
54082017-05-17 Yao Qi <yao.qi@linaro.org>
5409
5410 * cli/cli-decode.c (add_alias_cmd): New function.
5411 * command.h (add_alias_cmd): Declare.
5412 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
5413 instead call add_alias_cmd.
5414
2b351b19
PA
54152017-05-17 Pedro Alves <palves@redhat.com>
5416
5417 * Makefile.in (nat_extra_makefile_frag): Rename to ...
5418 (nat_makefile_frag): ... this. All references updated.
5419 * configure.ac: Likewise.
5420 * configure.nat: Likewise. Enhance comments.
5421 * configure: Regenerate.
5422
5f2ad7a3
RO
54232017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5424
5425 * procfs.c (procfs_create_inferior): Change prototype to match
5426 definition.
5427
adf3dde5
EZ
54282017-05-13 Eli Zaretskii <eliz@gnu.org>
5429
5430 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
5431 C++ compiler warning.
5432
6830f270
TT
54332017-05-12 Tom Tromey <tom@tromey.com>
5434
5435 PR rust/21483:
5436 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
5437 recurse, just call value_struct_elt directly.
5438
68f2f2e3
TT
54392017-05-12 Tom Tromey <tom@tromey.com>
5440
5441 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
5442 OP_RUST_ARRAY>: Fix.
5443
256afbc2
TT
54442017-05-12 Tom Tromey <tom@tromey.com>
5445
5446 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
5447
94bb8dfe
YQ
54482017-05-09 Yao Qi <yao.qi@linaro.org>
5449
5450 * regcache.c: Include <forward_list>.
5451 (struct regcache_list): Remove.
5452 (current_regcache): Update.
5453 (get_thread_arch_aspace_regcache): Update for std::forward_list.
5454 (regcache_thread_ptid_changed): Likewise.
5455 (registers_changed_ptid): Likewise.
5456 (current_regcache_size): Likewise.
5457
8248946c
YQ
54582017-05-09 Yao Qi <yao.qi@linaro.org>
5459
5460 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
5461 (current_regcache_size): New function.
5462 (current_regcache_test): New function.
5463 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
5464
313c5961
AH
54652017-05-08 Alan Hayward <alan.hayward@arm.com>
5466
5467 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
5468 (print_gp_register_row): Use get_frame_register_value.
5469
27bfc1d1
AH
54702017-05-08 Alan Hayward <alan.hayward@arm.com>
5471
5472 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
5473 (mips_supply_fpregset): Likewise.
5474 (mips64_supply_gregset): Likewise.
5475
146e6c5c
AH
54762017-05-08 Alan Hayward <alan.hayward@arm.com>
5477
5478 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
5479 regcache->raw_supply_zeroed.
5480
e50f25ec
SDJ
54812017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
5482
5483 * configure.nat: Rearrange 'case' statements to match
5484 host before cpu.
5485
21ea5acd
SDJ
54862017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
5487
5488 * Makefile.in: Remove "@host_makefile_frag@". Add variables
5489 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
5490 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
5491 "@nat_extra_makefile_frag@".
5492 (Makefile): Remove dependency on "@frags@".
5493 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
5494 (data-directory/Makefile): Likewise.
5495 * config/aarch64/linux.mh: Deleted; moved contents to
5496 "gdb/configure.nat".
5497 * config/alpha/alpha-linux.mh: Likewise.
5498 * config/alpha/nbsd.mh: Likewise.
5499 * config/arm/linux.mh: Likewise.
5500 * config/arm/nbsdelf.mh: Likewise.
5501 * config/i386/cygwin.mh: Likewise.
5502 * config/i386/cygwin64.mh: Likewise.
5503 * config/i386/darwin.mh: Likewise.
5504 * config/i386/fbsd.mh: Likewise.
5505 * config/i386/fbsd64.mh: Likewise.
5506 * config/i386/go32.mh: Likewise.
5507 * config/i386/i386gnu.mh: Likewise.
5508 * config/i386/i386sol2.mh: Likewise.
5509 * config/i386/linux.mh: Likewise.
5510 * config/i386/linux64.mh: Likewise.
5511 * config/i386/mingw.mh: Likewise.
5512 * config/i386/mingw64.mh: Likewise.
5513 * config/i386/nbsd64.mh: Likewise.
5514 * config/i386/nbsdelf.mh: Likewise.
5515 * config/i386/nto.mh: Likewise.
5516 * config/i386/obsd.mh: Likewise.
5517 * config/i386/obsd64.mh: Likewise.
5518 * config/i386/sol2-64.mh: Likewise.
5519 * config/ia64/linux.mh: Likewise.
5520 * config/m32r/linux.mh: Likewise.
5521 * config/m68k/linux.mh: Likewise.
5522 * config/m68k/nbsdelf.mh: Likewise.
5523 * config/m68k/obsd.mh: Likewise.
5524 * config/m88k/obsd.mh: Likewise.
5525 * config/mips/fbsd.mh: Likewise.
5526 * config/mips/linux.mh: Likewise.
5527 * config/mips/nbsd.mh: Likewise.
5528 * config/mips/obsd64.mh: Likewise.
5529 * config/pa/linux.mh: Likewise.
5530 * config/pa/nbsd.mh: Likewise.
5531 * config/pa/obsd.mh: Likewise.
5532 * config/powerpc/aix.mh: Likewise.
5533 * config/powerpc/fbsd.mh: Likewise.
5534 * config/powerpc/linux.mh: Likewise.
5535 * config/powerpc/nbsd.mh: Likewise.
5536 * config/powerpc/obsd.mh: Likewise.
5537 * config/powerpc/ppc64-linux.mh: Likewise.
5538 * config/powerpc/spu-linux.mh: Likewise.
5539 * config/s390/linux.mh: Likewise.
5540 * config/sh/nbsd.mh: Likewise.
5541 * config/sparc/fbsd.mh: Likewise.
5542 * config/sparc/linux.mh: Likewise.
5543 * config/sparc/linux64.mh: Likewise.
5544 * config/sparc/nbsd64.mh: Likewise.
5545 * config/sparc/nbsdelf.mh: Likewise.
5546 * config/sparc/obsd64.mh: Likewise.
5547 * config/sparc/sol2.mh: Likewise.
5548 * config/tilegx/linux.mh: Likewise.
5549 * config/vax/nbsdelf.mh: Likewise.
5550 * config/vax/obsd.mh: Likewise.
5551 * config/xtensa/linux.mh: Likewise.
5552 * config/i386/i386gnu.mn: New file, with excerpts from
5553 "config/i386/i386gnu.mh".
5554 * configure: Regenerate.
5555 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
5556 *.mh files under "gdb/config".
5557 * configure.nat: New file, with contents from the
5558 "gdb/config/*/*.mh" files.
5559
7ed1acaf
TW
55602017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
5561
5562 * btrace.c (btrace_clear): Free insn vector.
5563
e13cb306
PA
55642017-05-05 Pedro Alves <palves@redhat.com>
5565
5566 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
5567 * configure: Regenerate.
5568
5ed8105e
PA
55692017-05-04 Pedro Alves <palves@redhat.com>
5570
5571 * Makefile.in (SFILES): Add progspace-and-thread.c.
5572 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
5573 (COMMON_OBS): Add progspace-and-thread.o.
5574 * breakpoint.c: Include "progspace-and-thread.h".
5575 (update_inserted_breakpoint_locations)
5576 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
5577 Use scoped_restore_current_pspace_and_thread.
5578 (create_std_terminate_master_breakpoint): Use
5579 scoped_restore_current_program_space.
5580 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
5581 (print_breakpoint_location): Use
5582 scoped_restore_current_program_space.
5583 (bp_loc_is_permanent): Use
5584 scoped_restore_current_pspace_and_thread.
5585 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
5586 (download_tracepoint_locations): Use
5587 scoped_restore_current_pspace_and_thread.
5588 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
5589 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
5590 (enum step_over_calls_kind): Moved from inferior.h.
5591 (class scoped_restore_current_thread): New class.
5592 * gdbthread.h (make_cleanup_restore_current_thread): Delete
5593 declaration.
5594 (scoped_restore_current_thread): New class.
5595 * infcmd.c: Include "common/gdb_optional.h".
5596 (continue_1, proceed_after_attach): Use
5597 scoped_restore_current_thread.
5598 (notice_new_inferior): Use scoped_restore_current_thread.
5599 * inferior.c: Include "progspace-and-thread.h".
5600 (restore_inferior, save_current_inferior): Delete.
5601 (add_inferior_command, clone_inferior_command): Use
5602 scoped_restore_current_pspace_and_thread.
5603 * inferior.h (scoped_restore_current_inferior): New class.
5604 * infrun.c: Include "progspace-and-thread.h" and
5605 "common/gdb_optional.h".
5606 (follow_fork_inferior): Use
5607 scoped_restore_current_pspace_and_thread.
5608 (scoped_restore_exited_inferior): New class.
5609 (handle_vfork_child_exec_or_exit): Use
5610 scoped_restore_exited_inferior,
5611 scoped_restore_current_pspace_and_thread,
5612 scoped_restore_current_thread and scoped_restore.
5613 (fetch_inferior_event): Use scoped_restore_current_thread.
5614 * linespec.c (decode_line_full, decode_line_1): Use
5615 scoped_restore_current_program_space.
5616 * mi/mi-main.c: Include "progspace-and-thread.h".
5617 (exec_continue): Use scoped_restore_current_thread.
5618 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
5619 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
5620 * proc-service.c (ps_pglobal_lookup): Use
5621 scoped_restore_current_program_space.
5622 * progspace-and-thread.c: New file.
5623 * progspace-and-thread.h: New file.
5624 * progspace.c (release_program_space, clone_program_space): Use
5625 scoped_restore_current_program_space.
5626 (restore_program_space, save_current_program_space)
5627 (save_current_space_and_thread): Delete.
5628 (switch_to_program_space_and_thread): Moved to
5629 progspace-and-thread.c.
5630 * progspace.h (save_current_program_space)
5631 (save_current_space_and_thread): Delete declarations.
5632 (scoped_restore_current_program_space): New class.
5633 * remote.c (remote_btrace_maybe_reopen): Use
5634 scoped_restore_current_thread.
5635 * symtab.c: Include "progspace-and-thread.h".
5636 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
5637 * thread.c (print_thread_info_1): Use
5638 scoped_restore_current_thread.
5639 (struct current_thread_cleanup): Delete.
5640 (do_restore_current_thread_cleanup)
5641 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
5642 (scoped_restore_current_thread::~scoped_restore_current_thread):
5643 ... this new dtor.
5644 (make_cleanup_restore_current_thread): Rename/convert to ...
5645 (scoped_restore_current_thread::scoped_restore_current_thread):
5646 ... this new ctor.
5647 (thread_apply_all_command): Use scoped_restore_current_thread.
5648 (thread_apply_command): Use scoped_restore_current_thread.
5649 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
5650 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
5651
f6223dbb
PA
56522017-05-04 Pedro Alves <palves@redhat.com>
5653
5654 * thread.c (make_cleanup_restore_current_thread): Move
5655 find_thread_ptid call before the is_stopped call. Assert that the
5656 thread is found. Replace is_stopped call by checking the thread's
5657 state directly. Remove unnecessary NULL-thread check.
5658
3c3ae77e
PA
56592017-05-04 Pedro Alves <palves@redhat.com>
5660
5661 * corelow.c (thread_section_name): New class.
5662 (get_core_register_section, get_core_siginfo): Use it.
5663
45eba0ab
AA
56642017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
5665
5666 * corelow.c (sniff_core_bfd): Remove extra semicolon.
5667 (get_core_register_section): Remove xfree of NULL pointer.
5668
f81fdd35
AH
56692017-05-03 Alan Hayward <alan.hayward@arm.com>
5670
5671 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
5672 * regcache.c (regcache::raw_supply_zeroed): New function.
5673 * regcache.h (regcache::raw_supply_zeroed): New declaration.
5674
35837774
SM
56752017-05-03 Simon Marchi <simon.marchi@ericsson.com>
5676
5677 * gdbarch.sh: Remove commented out definition of
5678 TARGET_CHAR_BIT.
5679 * gdbarch.h: Re-generate.
5680
c94fee56
SDJ
56812017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
5682
5683 * configure: Regenerate.
5684
d17f7b36
SM
56852017-05-02 Simon Marchi <simon.marchi@ericsson.com>
5686
5687 * solib-target.c (solib_target_relocate_section_addresses):
5688 Remove num_section_bases, num_bases, segment_bases variables.
5689
b560ebd6
SM
56902017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
5691
5692 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
5693
f2f46dfc
SM
56942017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
5695
5696 * solib-target.c: Include <vector>
5697 (struct lm_info_target) <~lm_info_target>: Remove.
5698 <segment_bases, section_bases>: Change type to
5699 std::vector<CORE_ADDR>.
5700 (library_list_start_segment, library_list_start_section,
5701 library_list_end_library,
5702 solib_target_relocate_section_addresses): Adjust.
5703
a0ff9e1a
SM
57042017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
5705
5706 * gdbarch.sh (software_single_step): Change return type to
5707 std::vector<CORE_ADDR>.
5708 * gdbarch.c, gdbarch.h: Re-generate.
5709 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
5710 Adjust.
5711 (arm_deal_with_atomic_sequence_raw): Adjust.
5712 (thumb_get_next_pcs_raw): Adjust.
5713 (arm_get_next_pcs_raw): Adjust.
5714 (arm_get_next_pcs): Adjust.
5715 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
5716 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
5717 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
5718 (alpha_software_single_step): Adjust.
5719 * alpha-tdep.h (alpha_software_single_step): Adjust.
5720 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
5721 * arm-tdep.c (arm_software_single_step): Adjust.
5722 (arm_breakpoint_kind_from_current_state): Adjust.
5723 * arm-tdep.h (arm_software_single_step): Adjust.
5724 * breakpoint.c (insert_single_step_breakpoint): Adjust.
5725 * cris-tdep.c (cris_software_single_step): Adjust.
5726 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
5727 (micromips_deal_with_atomic_sequence): Adjust.
5728 (deal_with_atomic_sequence): Adjust.
5729 (mips_software_single_step): Adjust.
5730 * mips-tdep.h (mips_software_single_step): Adjust.
5731 * moxie-tdep.c (moxie_software_single_step): Adjust.
5732 * nios2-tdep.c (nios2_software_single_step): Adjust.
5733 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
5734 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
5735 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
5736 * s390-linux-tdep.c (s390_software_single_step): Adjust.
5737 * sparc-tdep.c (sparc_software_single_step): Adjust.
5738 * spu-tdep.c (spu_software_single_step): Adjust.
5739 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
5740
ea480a30
SM
57412017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
5742
5743 * gdbarch.sh: Use semi-colon as field separator instead of colon.
5744 * gdbarch.h: Re-generate.
5745
d050f7d7
TW
57462017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
5747
5748 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
5749 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
5750 * python/py-instruction.c, python/py-instruction.h: New file.
5751 * python/py-record.c: Add py-instruction.h include.
5752 (gdbpy_initialize_record): Make gdb.Instruction a super class of
5753 gdb.RecordInstruction.
5754 * python/python-internal.h: Add gdbpy_initialize_instruction
5755 declaration.
5756 * python/python.c (do_start_initialization): Add
5757 gdbpy_initialize_instruction.
5758
14f819c8
TW
57592017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
5760
5761 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
5762 Remove.
5763 (btrace_func_from_recpy_func): New function.
5764 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
5765 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
5766 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
5767 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
5768 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
5769 Also, use new helper functions.
5770 (btpy_list_item): Use new helper functions.
5771 (recpy_bt_function_call_history): Use new type name.
5772 (btpy_call_getset): Remove.
5773 (gdbpy_initialize_btrace): Remove code to initialize
5774 gdb.BtraceFunctionCall.
5775 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
5776 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
5777 recpy_bt_func_prev, recpy_bt_func_next): New export.
5778 * python/py-record.c (recpy_func_type): New static object.
5779 (recpy_func_new, recpy_func_level, recpy_func_symbol,
5780 recpy_func_instructions, recpy_func_up, recpy_func_prev,
5781 recpy_func_next): New function.
5782 (recpy_element_hash, recpy_element_richcompare): Updated comment.
5783 (recpy_func_getset): New static object.
5784 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
5785 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
5786
0ed5da75
TW
57872017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
5788
5789 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
5790 (btpy_object, btpy_insn_type, btpy_new): Remove.
5791 (btpy_list_object): Use gdb.RecordInstruction type instead of
5792 gdb.BtraceInstruction type.
5793 (btrace_insn_from_recpy_insn): New function.
5794 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
5795 btpy_new.
5796 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
5797 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
5798 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
5799 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
5800 instead of btpy_object.
5801 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
5802 btpy_insn_data, btpy_insn_decode): Rename to ...
5803 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
5804 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
5805 recpy_bt_insn_decode): This. Also, use new helper functions.
5806 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
5807 recpy_insn_type.
5808 (btpy_insn_getset): Remove.
5809 (gdbpy_initialize_btrace): Remove code to initialize
5810 gdb.BtraceInstruction. Use recpy_element_object.
5811 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
5812 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
5813 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
5814 * python/py-record.c (recpy_insn_type): New static object.
5815 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
5816 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
5817 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
5818 New function.
5819 (recpy_insn_getset): New static object.
5820 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
5821 * python/py-record.h (recpy_element_object): New typedef.
5822 (recpy_insn_type, recpy_insn_new): New export.
5823
913aeadd
TW
58242017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
5825
5826 * py-record-btrace.c (btpy_insn_new): Removed.
5827 (btpy_insn_or_gap_new): New function.
5828 (btpy_insn_error): Removed.
5829 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
5830 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
5831 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
5832 btpy_insn_or_gap_new instead of btpy_insn_new.
5833 (btpy_insn_getset): Remove btpy_insn_error.
5834 * py-record.c (recpy_gap_type): New static object.
5835 (recpy_gap_object): New typedef.
5836 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
5837 recpy_gap_reason_string): New function.
5838 (recpy_gap_getset): New static object.
5839 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
5840 * py-record.h (recpy_gap_new): New export.
5841
a3be24ad
TW
58422017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
5843
5844 * python/py-record.c (recpy_ptid): Remove.
5845 (recpy_record_getset): Remove recpy_ptid.
5846
ae20e79a
TW
58472017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
5848
5849 * btrace.c (btrace_fetch): Set inferior_ptid.
5850 * python/py-record-btrace.c: Add "py-record.h" include.
5851 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
5852 recpy_bt_end, recpy_bt_instruction_history,
5853 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
5854 in gdb.Record object instead of current ptid.
5855 * python/py-record.c: Include new "py-record.h" file.
5856 (recpy_record_object): Moved to py-record.h.
5857 * python/py-record.h: New file.
5858
8d0050ea
TW
58592017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
5860
5861 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
5862 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
5863 indentation.
5864
3f380b50
JB
58652017-05-01 Joel Brobecker <brobecker@adacore.com>
5866
5867 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
5868 the past maintainers section.
5869
07495424
YQ
58702017-04-28 Yao Qi <yao.qi@linaro.org>
5871
5872 * infcmd.c (get_return_value): Use regcache ctor, and remove
5873 cleanup.
5874
deb1fa3e
YQ
58752017-04-28 Yao Qi <yao.qi@linaro.org>
5876 Pedro Alves <palves@redhat.com>
5877
5878 * regcache.c (regcache::regcache): New tag dispatch ctor.
5879 (do_cooked_read): Moved above.
5880 (regcache_dup): Use the tag dispatch ctor..
5881 * regcache.h (regcache): Declare ctor, delete copy ctor and
5882 assignment operator, remove friend regcache_dup.
5883
b421c83c
YQ
58842017-04-28 Yao Qi <yao.qi@linaro.org>
5885
5886 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
5887 call method save instead of regcache_cpy.
5888 * regcache.h (struct regcache): Make regcache_dup a friend.
5889
ef79d9a3
YQ
58902017-04-28 Yao Qi <yao.qi@linaro.org>
5891
5892 * regcache.c (struct regcache): Move to regcache.h
5893 (regcache::arch): New method.
5894 (regcache_get_ptid): Update.
5895 (get_regcache_arch): Call arch method.
5896 (get_regcache_aspace): Call method aspace.
5897 (register_buffer): Change it to method.
5898 (regcache_save): Change it to regcache::save.
5899 (regcache_restore): Likewise.
5900 (regcache_cpy_no_passthrough): Remove the declaration.
5901 (regcache_cpy): Call methods restore and cpy_no_passthrough.
5902 (regcache_cpy_no_passthrough): Change it to method
5903 cpy_no_passthrough.
5904 (regcache_register_status): Change it to method
5905 get_register_status.
5906 (regcache_invalidate): Change it to method invalidate.
5907 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
5908 (regcache_raw_update): Change it to method raw_update.
5909 (regcache_raw_read): Likewise.
5910 (regcache_raw_read_signed): Likewise.
5911 (regcache_raw_read_unsigned): Likewise.
5912 (regcache_raw_write_signed): Likewise.
5913 (regcache_raw_write_unsigned): Likewise.
5914 (regcache_cooked_read): Likewise.
5915 (regcache_cooked_read_value): Likewise.
5916 (regcache_cooked_read_signed): Likewise.
5917 (regcache_cooked_read_unsigned): Likewise.
5918 (regcache_cooked_write_signed): Likewise.
5919 (regcache_cooked_write_unsigned): Likewise.
5920 (regcache_raw_set_cached_value): Likewise.
5921 (regcache_raw_write): Likewise.
5922 (regcache_cooked_write): Likewise.
5923 (regcache_xfer_part): Likewise.
5924 (regcache_raw_read_part): Likewise.
5925 (regcache_raw_write_part): Likewise.
5926 (regcache_cooked_read_part): Likewise.
5927 (regcache_cooked_write_part): Likewise.
5928 (regcache_raw_supply): Likewise.
5929 (regcache_raw_collect): Likewise.
5930 (regcache_transfer_regset): Likewise.
5931 (regcache_supply_regset): Likewise.
5932 (regcache_collect_regset): Likewise.
5933 (regcache_debug_print_register): Likewise.
5934 (enum regcache_dump_what): Move it to regcache.h.
5935 (regcache_dump): Change it to method dump.
5936 * regcache.h (enum regcache_dump_what): New.
5937 (class regcache): New.
5938 * target.c (target_fetch_registers): Call method
5939 debug_print_register.
5940 (target_store_registers): Likewise.
5941
f8fdb78e
SM
59422017-04-28 Simon Marchi <simon.marchi@ericsson.com>
5943
5944 * windows-nat.c (struct lm_info_windows): Initialize field.
5945 (windows_make_so): Allocate lm_info_windows with new.
5946 (windows_free_so): Free lm_info_windows with delete.
5947
9ccbfd7b
SM
59482017-04-28 Simon Marchi <simon.marchi@ericsson.com>
5949
5950 * solib-darwin.c (struct lm_info_darwin): Initialize field.
5951 (darwin_current_sos): Allocate lm_info_darwin with new, remove
5952 cleanup.
5953 (darwin_free_so): Free lm_info_darwin with delete.
5954
76e75227
SM
59552017-04-28 Simon Marchi <simon.marchi@ericsson.com>
5956
5957 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
5958 <l_addr_p>: Change type to bool.
5959 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
5960 (svr4_free_so): Free lm_info_svr4 with delete.
5961 (svr4_copy_library_list): Replace memcpy with call to copy
5962 constructor.
5963 (library_list_start_library, svr4_default_sos): Allocate
5964 lm_info_svr4 with new.
5965
51046d9e
SM
59662017-04-28 Simon Marchi <simon.marchi@ericsson.com>
5967
5968 * solib-target.c (struct lm_info_target): Add destructor,
5969 initialize fields.
5970 <name>: Change type to std::string.
5971 (library_list_start_library): Allocate lm_info_target with new.
5972 (solib_target_free_library_list): Free lm_info_target with
5973 delete.
5974 (solib_target_current_sos): Adapt to std::string.
5975 (solib_target_free_so): Free lm_info_target with delete.
5976
4023ae76
SM
59772017-04-28 Simon Marchi <simon.marchi@ericsson.com>
5978
5979 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
5980 fields.
5981 (frv_current_sos): Allocate lm_info_frv with new.
5982 (frv_relocate_main_executable): Free lm_info_frv with delete,
5983 allocate with new.
5984 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
5985
af43057b
SM
59862017-04-28 Simon Marchi <simon.marchi@ericsson.com>
5987
5988 * solib-frv.c (struct lm_info_frv): Fix indentation.
5989
b0911207
SM
59902017-04-28 Simon Marchi <simon.marchi@ericsson.com>
5991
5992 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
5993 map field.
5994 (dsbt_current_sos): Allocate lm_info_dsbt with new.
5995 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
5996 and allocate with new.
5997 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
5998
6c401f72
SM
59992017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6000
6001 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
6002 <filename, member_name>: Change type to std::string.
6003 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
6004 (library_list_start_library): Allocate lm_info_aix with new.
6005 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
6006 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
6007 with copy constructor.
6008
d0e449a1
SM
60092017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6010
6011 * solist.h (struct lm_info): Remove.
6012 (struct lm_info_base): New class.
6013 (struct so_list) <lm_info>: Change type to lm_info_base *.
6014 * nto-tdep.c (struct lm_info): Remove.
6015 (lm_addr): Adjust.
6016 * solib-aix.c (struct lm_info): Rename to ...
6017 (struct lm_info_aix): ... this. Extend lm_info_base.
6018 (lm_info_p): Rename to ...
6019 (lm_info_aix_p): ... this, and adjust.
6020 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
6021 solib_aix_parse_libraries, library_list_start_library,
6022 solib_aix_free_library_list, solib_aix_parse_libraries,
6023 solib_aix_get_library_list,
6024 solib_aix_relocate_section_addresses, solib_aix_free_so,
6025 solib_aix_get_section_offsets,
6026 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
6027 Adjust.
6028 (struct solib_aix_inferior_data) <library_list>: Adjust.
6029 * solib-darwin.c (struct lm_info): Rename to ...
6030 (struct lm_info_darwin): ... this. Extend lm_info_base.
6031 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
6032 * solib-dsbt.c (struct lm_info): Rename to ...
6033 (struct lm_info_dsbt): ... this. Extend lm_info_base.
6034 (struct dsbt_info) <main_executable_lm_info): Adjust.
6035 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
6036 dsbt_relocate_section_addresses): Adjust.
6037 * solib-frv.c (struct lm_info): Rename to ...
6038 (struct lm_info_frv): ... this. Extend lm_info_base.
6039 (main_executable_lm_info): Adjust.
6040 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
6041 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
6042 find_canonical_descriptor_in_load_object,
6043 frv_fdpic_find_canonical_descriptor): Adjust.
6044 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
6045 to lm_info_svr4.
6046 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
6047 svr4_clear_so, svr4_copy_library_list,
6048 library_list_start_library, svr4_default_sos, svr4_read_so_list,
6049 svr4_current_sos, svr4_fetch_objfile_link_map,
6050 solist_update_incremental): Adjust.
6051 * solib-svr4.h (struct lm_info_svr4): Move here from
6052 solib-svr4.c.
6053 * solib-target.c (struct lm_info): Rename to ...
6054 (struct lm_info_target): ... this. Extend lm_info_base.
6055 (lm_info_p): Rename to ...
6056 (lm_info_target_p): ... this.
6057 (solib_target_parse_libraries, library_list_start_segment,
6058 library_list_start_section, library_list_start_library,
6059 library_list_end_library, solib_target_free_library_list,
6060 solib_target_current_sos, solib_target_free_so,
6061 solib_target_relocate_section_addresses): Adjust.
6062 * windows-nat.c (struct lm_info): Rename to ...
6063 (struct lm_info_windows): ... this. Extend lm_info_base.
6064 (windows_make_so, handle_load_dll, handle_unload_dll,
6065 windows_xfer_shared_libraries): Adjust.
6066
434a4023
SM
60672017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6068
6069 * solib-darwin.c (struct darwin_so_list): Remove.
6070 (darwin_current_sos): Allocate an so_list object instead of a
6071 darwin_so_list, separately allocate an lm_info object.
6072 (darwin_free_so): Free lm_info.
6073
428544e8
JB
60742017-04-28 John Baldwin <jhb@FreeBSD.org>
6075
6076 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
6077 with fprintf_filtered.
6078
4621115f
YQ
60792017-04-28 Yao Qi <yao.qi@linaro.org>
6080
6081 * regcache.c (regcache::regcache): New function.
6082 (regcache::~regcache): New function.
6083 (regcache_xmalloc_1): Remove.
6084 (regcache_xmalloc): Call new regcache.
6085 (regcache_xfree): Call delete regcache.
6086 (get_thread_arch_aspace_regcache): Call new regcache.
6087
339053c2
YQ
60882017-04-28 Yao Qi <yao.qi@linaro.org>
6089
6090 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
6091 lwp instead of ptid_get_lwp.
6092
7974a605
YQ
60932017-04-28 Yao Qi <yao.qi@linaro.org>
6094
6095 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
6096 lwp_info instead of getting from inferior_ptid.
6097
e15c3eb4
KS
60982017-04-27 Keith Seitz <keiths@redhat.com>
6099
6100 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
6101 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
6102 (CV_CONVERSION_BADNESS): Define.
6103 (rank_one_type): Remove overly restrictive rvalue reference
6104 rank checks.
6105 Add cv-qualifier checks and subranks for type equality.
6106 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
6107 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
6108 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
6109
72bc1d24
SM
61102017-04-27 Simon Marchi <simon.marchi@ericsson.com>
6111
6112 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
6113 count when creating the object.
6114
55bcecda
UW
61152017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
6116 Ulrich Weigand <uweigand@de.ibm.com>
6117
6118 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
6119 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
6120 is used in AIX.
6121 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
6122 (process_xcoff_symbol): Likewise.
6123 (scan_xcoff_symtab): Likewise.
6124
5c99fcf8
AH
61252017-04-26 Alan Hayward <alan.hayward@arm.com>
6126
6127 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
6128 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
6129 (ia64_access_reg): Use get_frame_register_unsigned.
6130 (ia64_access_rse_reg): Likewise.
6131 (ia64_libunwind_frame_prev_register): Likewise.
6132
b41c5a85
JW
61332017-04-26 Jiong Wang <jiong.wang@arm.com>
6134
6135 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
6136 * gdbarch.c: Regenerated.
6137 * gdbarch.h: Regenerated.
6138 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
6139 visibility external.
6140 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
6141 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
6142 (enum cfa_how_kind): Move to ...
6143 (struct dwarf2_frame_state_reg_info): Likewise.
6144 (struct dwarf2_frame_state): Likewise.
6145 * dwarf2-frame.h: ... here.
6146 (dwarf2_frame_state_alloc_regs): New declaration.
6147 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
6148 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
6149
c185f580
AH
61502017-04-26 Alan Hayward <alan.hayward@arm.com>
6151
6152 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
6153 regcache_raw_read_unsigned.
6154 (xtensa_pseudo_register_write): Likewise.
6155
19c45594
AH
61562017-04-26 Alan Hayward <alan.hayward@arm.com>
6157
6158 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
6159 (nds32_pseudo_register_write): Likewise.
6160
4658f12e
YQ
61612017-04-25 Yao Qi <yao.qi@linaro.org>
6162
6163 * regcache.c (struct regcache) <readonly_p>: Change its type
6164 to bool.
6165 (regcache_xmalloc_1): Update parameter type and callers update.
6166
d581dda8
YQ
61672017-04-25 Yao Qi <yao.qi@linaro.org>
6168
6169 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
6170 set_gdbarch_wchar_bit.
6171 * arm-tdep.c (arm_gdbarch_init): Likewise.
6172
debed3db
PA
61732017-04-25 Pedro Alves <palves@redhat.com>
6174
6175 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
6176 (BothAreRelocatable, memcopy, memmove): Don't define.
6177 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
6178 macros.
6179
b0b92aeb
PA
61802017-04-25 Pedro Alves <palves@redhat.com>
6181
6182 * common/common-defs.h: Include "common/poison.h".
6183 * common/function-view.h: (Not, Or, Requires): Move to traits.h
6184 and adjust.
6185 * common/poison.h: New file.
6186 * common/traits.h: Include <type_traits>.
6187 (Not, Or, Requires): New, moved from common/function-view.h.
6188
16c4d54a
PA
61892017-04-25 Pedro Alves <palves@redhat.com>
6190
6191 * breakpoint.h (struct breakpoint): In-class initialize all
6192 fields. Make boolean fields "bool".
6193 * breakpoint.c (init_raw_breakpoint_without_location): Remove
6194 memset call and initializations no longer necessary.
6195
b5c36682
PA
61962017-04-25 Pedro Alves <palves@redhat.com>
6197
6198 * btrace.c (pt_btrace_insn_flags): Change parameter type to
6199 reference.
6200 (pt_btrace_insn): New function.
6201 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
6202
5625a286
PA
62032017-04-25 Pedro Alves <palves@redhat.com>
6204
6205 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
6206 "base" field and inherit from "bp_location" instead. Add
6207 non-default ctor.
6208 (allocate_location_exception): Use new non-default ctor.
6209 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
6210 (init_bp_location): Convert to ...
6211 (bp_location::bp_location): ... this new ctor, and remove memset
6212 call.
6213 (base_breakpoint_allocate_location): Use the new non-default ctor.
6214 * breakpoint.h (bp_location): Now a class. Declare default and
6215 non-default ctors. In-class initialize all members.
6216 (init_bp_location): Remove declaration.
6217
23bcc18f
PA
62182017-04-25 Pedro Alves <palves@redhat.com>
6219
6220 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
6221 assignment operator.
6222
e1ba3053
YQ
62232017-04-24 Yao Qi <yao.qi@linaro.org>
6224
6225 * doublest.c (convert_doublest_to_floatformat): Call
6226 floatformat_totalsize_bytes.
6227
10f489e5
TT
62282017-04-22 Tom Tromey <tom@tromey.com>
6229
6230 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
6231 ui_out_emit_list.
6232 * stack.c (print_frame): Use ui_out_emit_list.
6233 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
6234 ui_out_emit_list.
6235 * mi/mi-main.c (print_one_inferior)
6236 (mi_cmd_data_list_register_names)
6237 (mi_cmd_data_list_register_values, mi_cmd_list_features)
6238 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
6239 ui_out_emit_list.
6240 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
6241 (mi_output_solib_attribs): Use ui_out_emit_list,
6242 ui_out_emit_tuple.
6243 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
6244 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
6245 (mi_cmd_stack_list_args, list_args_or_locals): Use
6246 ui_out_emit_list.
6247 * disasm.c (do_assembly_only): Use ui_out_emit_list.
6248 * breakpoint.c (print_solib_event, output_thread_groups): Use
6249 ui_out_emit_list.
6250
0092b74d
TT
62512017-04-22 Tom Tromey <tom@tromey.com>
6252
6253 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
6254 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
6255 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
6256
a14a62dd
TT
62572017-04-22 Tom Tromey <tom@tromey.com>
6258
6259 * tracepoint.c (tvariables_info_1)
6260 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
6261
46b9c129
TT
62622017-04-22 Tom Tromey <tom@tromey.com>
6263
6264 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
6265 annotate_arg_emitter.
6266 * breakpoint.c (print_mention_watchpoint)
6267 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
6268 * annotate.h (struct annotate_arg_emitter): New.
6269
2e783024
TT
62702017-04-22 Tom Tromey <tom@tromey.com>
6271
6272 * record-btrace.c (record_btrace_insn_history)
6273 (record_btrace_insn_history_range, record_btrace_call_history)
6274 (record_btrace_call_history_range): Use ui_out_emit_tuple.
6275 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
6276 ui_out_emit_tuple.
6277 * stack.c (print_frame_info): Use ui_out_emit_tuple.
6278 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
6279 * skip.c (skip_info): Use ui_out_emit_tuple.
6280 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
6281 * progspace.c (print_program_space): Use ui_out_emit_tuple.
6282 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
6283 * osdata.c (info_osdata): Use ui_out_emit_tuple.
6284 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
6285 ui_out_emit_tuple.
6286 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
6287 (output_register, mi_cmd_data_read_memory)
6288 (mi_cmd_data_read_memory_bytes, mi_load_progress)
6289 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
6290 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
6291 Use ui_out_emit_tuple.
6292 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
6293 ui_out_emit_tuple.
6294 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
6295 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
6296 * linux-thread-db.c (info_auto_load_libthread_db): Use
6297 ui_out_emit_tuple.
6298 * inferior.c (print_inferior): Use ui_out_emit_tuple.
6299 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
6300 * disasm.c (do_mixed_source_and_assembly_deprecated)
6301 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
6302 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
6303 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
6304 * breakpoint.c (print_one_breakpoint_location)
6305 (print_one_breakpoint): Use ui_out_emit_tuple.
6306 * auto-load.c (print_script, info_auto_load_cmd): Use
6307 ui_out_emit_tuple.
6308 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
6309
9be21bb4
SM
63102017-04-21 Simon Marchi <simon.marchi@ericsson.com>
6311
6312 * thread.c (print_thread_info_1): Remove dead code.
6313
0d4c07af
JK
63142017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
6315
6316 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
6317 GDB_SELF_TEST.
6318 * arm-tdep.c (selftests::arm_record_test): Likewise.
6319
4daf993d
YQ
63202017-04-21 Yao Qi <yao.qi@linaro.org>
6321
6322 * regcache.c (regcache_restore): Remove argument 2. Replace
6323 argument 3 with regcache. Get register status from
6324 src->register_status and get register contents from
6325 register_buffer (src, regnum).
6326 (regcache_cpy): Update.
6327
a6c21d4a
PA
63282017-04-19 Pedro Alves <palves@redhat.com>
6329
6330 * gdbthread.h (thread): Add missing closing parenthesis in
6331 comment.
6332
3a3fd0fd
PA
63332017-04-19 Pedro Alves <palves@redhat.com>
6334
6335 * common/refcounted-object.h: New file.
6336 * gdbthread.h: Include "common/refcounted-object.h".
6337 (thread_info): Inherit from refcounted_object and add comments.
6338 (thread_info::incref, thread_info::decref)
6339 (thread_info::m_refcount): Delete.
6340 (thread_info::deletable): Use the refcounted_object::refcount()
6341 method.
6342 * inferior.c (current_inferior_): Add comment.
6343 (set_current_inferior): Increment/decrement refcounts.
6344 (prune_inferiors, remove_inferior_command): Skip inferiors marked
6345 not-deletable instead of comparing with the current inferior.
6346 (initialize_inferiors): Increment the initial inferior's refcount.
6347 * inferior.h (struct inferior): Forward declare.
6348 Include "common/refcounted-object.h".
6349 (current_inferior, set_current_inferior): Move declaration to
6350 before struct inferior's definition, and fix comment.
6351 (inferior): Inherit from refcounted_object. Add comments.
6352 * thread.c (switch_to_thread_no_regs): Reference the thread's
6353 inferior pointer directly instead of doing a ptid lookup.
6354 (switch_to_no_thread): New function.
6355 (switch_to_thread(thread_info *)): New function, factored out
6356 from ...
6357 (switch_to_thread(ptid_t)): ... this.
6358 (restore_current_thread): Delete.
6359 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
6360 fields, and add 'inf' field.
6361 (do_restore_current_thread_cleanup): Check whether old->inf is
6362 alive instead of looking up an inferior by ptid. Use
6363 switch_to_thread and switch_to_no_thread.
6364 (restore_current_thread_cleanup_dtor): Use old->inf directly
6365 instead of lookup up an inferior by id. Decref the inferior.
6366 Don't restore 'removable'.
6367 (make_cleanup_restore_current_thread): Same the inferior pointer
6368 in old, instead of the inferior number. Incref the inferior.
6369 Don't save/clear 'removable'.
6370
9bcb1f16
PA
63712017-04-19 Pedro Alves <palves@redhat.com>
6372
6373 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6374 unittests/scoped_restore-selftests.c.
6375 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
6376 * common/scoped_restore.h (scoped_restore_base): Make "class".
6377 (scoped_restore_base::release): New public method.
6378 (scoped_restore_base::scoped_restore_base): New protected ctor.
6379 (scoped_restore_base::m_saved_var): New protected field.
6380 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
6381 scoped_restore_base base class instead of m_saved_var directly.
6382 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
6383 (scoped_restore_tmpl::scoped_restore_tmpl(const
6384 scoped_restore_tmpl<T>&)): Likewise.
6385 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
6386 method.
6387 (scoped_restore_tmpl::saved_var): New method.
6388 (scoped_restore_tmpl::m_saved_var): Delete.
6389 * inferior.h (inferior::detaching): Now a bool.
6390 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
6391 cleanup.
6392 * unittests/scoped_restore-selftests.c: New file.
6393
26fcd539
PA
63942017-04-19 Pedro Alves <palves@redhat.com>
6395
6396 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
6397 Re-sort in alphabetic order.
6398
fdd243b0
PA
63992017-04-18 Pedro Alves <palves@redhat.com>
6400
6401 * xml-support.c (obstack_xml_printf): Delete.
6402 * xml-support.h (obstack_xml_printf): Delete.
6403
4895cde2
PA
64042017-04-18 Pedro Alves <palves@redhat.com>
6405
6406 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
6407 vdebug, verror, body_text, start_element, end_element, name,
6408 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
6409 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
6410 is_xinclude>: Make private and add m_ prefix.
6411 (gdb_xml_parser::body_text): New method, based on ...
6412 (gdb_xml_body_text): ... this. Adjust.
6413 (gdb_xml_parser::vdebug): New method, based on ...
6414 (gdb_xml_debug): ... this. Adjust.
6415 (gdb_xml_parser::verror): New method, based on ...
6416 (gdb_xml_error): ... this. Adjust.
6417 (gdb_xml_parser::start_element): New method, based on ...
6418 (gdb_xml_start_element): ... this. Adjust.
6419 (gdb_xml_start_element_wrapper): Defer to
6420 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
6421 (gdb_xml_parser::end_element): New method, based on ...
6422 (gdb_xml_end_element_wrapper): ... this. Adjust.
6423 (gdb_xml_parser::~gdb_xml_parser): Adjust.
6424 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
6425 (gdb_xml_parser::use_dtd): New method, based on ...
6426 (gdb_xml_use_dtd): ... this. Adjust.
6427 (gdb_xml_parser::parse): New method, based on ...
6428 (gdb_xml_parse): ... this. Adjust.
6429 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
6430 (xinclude_start_include): Adjust to call the parser's name method.
6431 (xml_xinclude_default, xml_xinclude_start_doctype)
6432 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
6433 method.
6434 (xml_process_xincludes): Adjust to call parser methods.
6435 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
6436 declarations.
6437
bd8a901f
PA
64382017-04-18 Pedro Alves <palves@redhat.com>
6439
6440 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
6441 gdb::optional<std::string>.
6442 * xml-support.c: Include <string>.
6443 (scope_level::scope_level(scope_level &&))
6444 (scope_level::~scope_level): Delete.
6445 (scope_level::body): Now a std::string.
6446 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
6447 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
6448 parameter.
6449 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
6450 (xinclude_parsing_data::output): Now a std::string reference.
6451 (xinclude_start_include): Adjust.
6452 (xml_xinclude_default): Adjust.
6453 (xml_process_xincludes): Add 'output' parameter, and return bool.
6454 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
6455 and return bool.
6456 * xml-tdesc.c: Include <unordered_map> and <string>.
6457 (tdesc_xml_cache): Delete.
6458 (tdesc_xml_cache_s): Delete.
6459 (xml_cache): Now an std::unordered_map.
6460 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
6461 (target_fetch_description_xml): Change return type to
6462 gdb::optional<std::string>, and adjust.
6463 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
6464 (target_fetch_description_xml): Change return type to
6465 gdb::optional<std::string>.
6466
d35d1958
PA
64672017-04-18 Pedro Alves <palves@redhat.com>
6468
6469 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6470 unittests/optional-selftests.c.
6471 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
6472 * unittests/optional-selftests.c: New file.
6473 * unittests/optional/assignment/1.cc: New file.
6474 * unittests/optional/assignment/2.cc: New file.
6475 * unittests/optional/assignment/3.cc: New file.
6476 * unittests/optional/assignment/4.cc: New file.
6477 * unittests/optional/assignment/5.cc: New file.
6478 * unittests/optional/assignment/6.cc: New file.
6479 * unittests/optional/assignment/7.cc: New file.
6480 * unittests/optional/cons/copy.cc: New file.
6481 * unittests/optional/cons/default.cc: New file.
6482 * unittests/optional/cons/move.cc: New file.
6483 * unittests/optional/cons/value.cc: New file.
6484 * unittests/optional/in_place.cc: New file.
6485 * unittests/optional/observers/1.cc: New file.
6486 * unittests/optional/observers/2.cc: New file.
6487
22796e97
PA
64882017-04-18 Pedro Alves <palves@redhat.com>
6489
6490 * common/gdb_optional.h: Include common/traits.h.
6491 (in_place_t): New type.
6492 (in_place): New constexpr variable.
6493 (optional::optional): Remove member initialization of
6494 m_instantiated.
6495 (optional::optional(in_place_t...)): New constructor.
6496 (optional::~optional): Use reset.
6497 (optional::optional(const optional&)): New.
6498 (optional::optional(const optional&&)): New.
6499 (optional::optional(T &)): New.
6500 (optional::optional(T &&)): New.
6501 (operator::operator=(const optional &)): New.
6502 (operator::operator=(optional &&)): New.
6503 (operator::operator= (const T &))
6504 (operator::operator= (T &&))
6505 (operator::emplace (Args &&... args)): Return a T&. Use reset.
6506 (operator::reset): New.
6507 (operator::m_instantiated):: Add in-class initializer.
6508 * common/traits.h: Include <type_traits>.
6509 (struct And): New types.
6510
a7fc9b61
PA
65112017-04-18 Pedro Alves <palves@redhat.com>
6512
6513 * xml-support.c: Include <vector>.
6514 (scope_level::scope_level(const gdb_xml_element *))
6515 (scope_level::scope_level(scope_level&&)): New.
6516 (scope_level::~scope_level): New.
6517 (scope_level_s): Delete.
6518 (gdb_xml_parser::scopes): Now a std::vector.
6519 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
6520 Use std::vector.
6521 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
6522 scope cleanup code.
6523 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
6524 of the scopes member. Use std::vector::emplace_back.
6525
010151c9
PA
65262017-04-18 Pedro Alves <palves@redhat.com>
6527
6528 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
6529 a bool.
6530 (gdb_xml_end_element): Change type of first parameter.
6531 (gdb_xml_cleanup): Rename to ...
6532 (gdb_xml_parser::~gdb_xml_parser): ... this.
6533 (gdb_xml_create_parser_and_cleanup): Delete with ...
6534 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
6535 to this new ctor.
6536 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
6537 using gdb_xml_create_parser_and_cleanup.
6538 (xinclude_parsing_data): Add ctor/dtor.
6539 (xml_xinclude_cleanup): Delete.
6540 (xml_process_xincludes): Create a local xinclude_parsing_data
6541 instead of heap-allocating one. Create a local gdb_xml_parser
6542 instead of heap-allocating one with
6543 gdb_xml_create_parser_and_cleanup.
6544
d56060f0
JB
65452017-04-18 John Baldwin <jhb@FreeBSD.org>
6546
6547 PR threads/20743
6548 * fbsd-nat.c (resume_one_thread_cb): Remove.
6549 (resume_all_threads_cb): Remove.
6550 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
6551 iterate_over_threads.
6552
305d16a9
JB
65532017-04-17 Joel Brobecker <brobecker@adacore.com>
6554
6555 * NEWS: Create a new section for the next release branch.
6556 Rename the section of the current branch, now that it has
6557 been cut.
6558
8bb57231
JB
65592017-04-17 Joel Brobecker <brobecker@adacore.com>
6560
6561 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
6562 * version.in: Bump version to 8.0.50.DATE-git.
6563
096c92dd
SDJ
65642017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
6565
6566 PR gdb/21385
6567 * windows-nat.c (windows_create_inferior): Declare 'allargs'
6568 independently of the host, and fix build breakage on Cygwin.
6569
0550c955
PA
65702017-04-13 Pedro Alves <palves@redhat.com>
6571
6572 * inferior.c (free_inferior): Convert to ...
6573 (inferior::~inferior): ... this dtor.
6574 (inferior::inferior): New ctor, factored out from ...
6575 (add_inferior_silent): ... here. Allocate the inferior with a new
6576 expression.
6577 (delete_inferior): Call delete instead of free_inferior.
6578 * inferior.h (gdb_environ, continuation): Forward declare.
6579 (inferior): Now a class. Add in-class initialization to all
6580 members. Make boolean fields bool, except 'detaching'.
6581 (inferior::inferior): New explicit ctor.
6582 (inferior::~inferior): New.
6583
e3d60dfc
PA
65842017-04-13 Pedro Alves <palves@redhat.com>
6585
6586 * inferior.c (init_inferior_list): Delete.
6587 * inferior.h (init_inferior_list): Delete.
6588
5fd69d0a
PA
65892017-04-13 Pedro Alves <palves@redhat.com>
6590
6591 PR threads/13217
6592 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
6593 (top level): Call it twice, with different thread sets.
6594
c6609450
PA
65952017-04-13 Pedro Alves <palves@redhat.com>
6596
6597 * thread.c: Include <algorithm>.
6598 (thread_array_cleanup): Delete.
6599 (scoped_inc_dec_ref): New class.
6600 (live_threads_count): New function.
6601 (set_thread_refcount): Delete.
6602 (tp_array_compar_ascending): Now a bool.
6603 (tp_array_compar): Convert to a std::sort comparison function.
6604 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
6605 and live_threads_count.
6606
2a00d7ce
PA
66072017-04-13 Pedro Alves <palves@redhat.com>
6608
6609 * infrun.c (follow_fork_inferior): Also switch the current
6610 inferior.
6611
441d7c93
PA
66122017-04-13 Pedro Alves <palves@redhat.com>
6613
6614 * breakpoint.c (watch_command_1): Save watchpoint-frame info
6615 before calling create_internal_breakpoint.
6616
808480f6
PA
66172017-04-13 Pedro Alves <palves@redhat.com>
6618
6619 * fork-child.c (execv_argv): New class.
6620 (breakup_args): Refactored as ...
6621 (execv_argv::init_for_no_shell): .. this method of execv_argv.
6622 Copy arguments to storage and replace separators with NULL
6623 terminators in place.
6624 (escape_bang_in_quoted_argument): Adjust to return bool.
6625 (execv_argv::execv_argv): New ctor.
6626 (execv_argv::init_for_shell): New method, factored out from
6627 fork_inferior. Don't strdup strings into the vector.
6628 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
6629 Remove free_vector_argv call.
6630
ad3d022a
YQ
66312017-04-13 Yao Qi <yao.qi@linaro.org>
6632
6633 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
6634 tdep->rx_psw_type.
6635
e6ddc3bf
YQ
66362017-04-13 Yao Qi <yao.qi@linaro.org>
6637
6638 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
6639 * rx-tdep.c (rx_gdbarch_init): Likewise.
6640
bfb8cf90
PA
66412017-04-13 Pedro Alves <palves@redhat.com>
6642
6643 * breakpoint.h (struct breakpoint): Reindent.
6644
f5336ca5
PA
66452017-04-13 Pedro Alves <palves@redhat.com>
6646
6647 * breakpoint.c (bp_location): Rename to ...
6648 (bp_locations): ... this. All references updated.
6649 (bp_location_count): Rename to ...
6650 (bp_locations_count): ... this. All references updated.
6651 (bp_location_placed_address_before_address_max): Rename to ...
6652 (bp_locations_placed_address_before_address_max): ... this. All
6653 references updated.
6654 (bp_location_shadow_len_after_address_max): Rename to ...
6655 (bp_locations_shadow_len_after_address_max): ... this. All
6656 references updated.
6657 (bp_location_compare_addrs): Rename to ...
6658 (bp_locations_compare_addrs): ... this. All references updated.
6659 (bp_location_compare):Rename to ...
6660 (bp_locations_compare): ... this. All references updated.
6661 (bp_location_target_extensions_update): Rename to ...
6662 (bp_locations_target_extensions_update): ... this. All references
6663 updated.
6664
be628ab8
SDJ
66652017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
6666
6667 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
6668 * common/common.m4: Check headers 'termios.h', 'termio.h' and
6669 'sgtty.h'.
6670 * common/gdb_termios.h: New file, with parts of "terminal.h".
6671 * inflow.c: Include "gdb_termios.h".
6672 * ser-unix.c: Include "gdb_termios.h".
6673 * terminal.h: Move terminal-related defines to
6674 "common/gdb_termios.h".
6675
8e9e35b1
TT
66762017-04-12 Tom Tromey <tom@tromey.com>
6677
6678 * probe.c (parse_probes): Update.
6679 * location.h (delete_event_location): Don't declare.
6680 (event_location_deleter::operator()): Update.
6681 * location.c (event_location_deleter::operator()): Rename from
6682 delete_event_location.
6683 * linespec.h (linespec_result) <location>: Change type to
6684 event_location_up.
6685 * linespec.c (canonicalize_linespec, event_location_to_sals)
6686 (decode_objc): Update.
6687 (linespec_result): Don't call delete_event_location.
6688 * breakpoint.c (create_breakpoints_sal)
6689 (bkpt_probe_create_sals_from_location)
6690 (strace_marker_create_sals_from_location): Update.
6691
16e802b9
TT
66922017-04-12 Tom Tromey <tom@tromey.com>
6693
6694 * linespec.h (struct linespec_result): Add constructor and
6695 destructor.
6696 (init_linespec_result, destroy_linespec_result)
6697 (make_cleanup_destroy_linespec_result): Don't declare.
6698 * linespec.c (init_linespec_result): Remove.
6699 (linespec_result::~linespec_result): Rename from
6700 destroy_linespec_result. Update.
6701 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
6702 Remove.
6703 * breakpoint.c (create_breakpoint, break_range_command)
6704 (decode_location_default): Update.
6705 * ax-gdb.c (agent_command_1): Update.
6706
d28cd78a
TT
67072017-04-12 Tom Tromey <tom@tromey.com>
6708
6709 * remote.c (remote_download_tracepoint): Update.
6710 * python/py-breakpoint.c (bppy_get_location): Update.
6711 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
6712 (gdbscm_breakpoint_location): Update.
6713 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
6714 * breakpoint.h (struct breakpoint) <location, location_range_end>:
6715 Change type to event_location_up.
6716 * breakpoint.c (create_overlay_event_breakpoint)
6717 (create_longjmp_master_breakpoint)
6718 (create_std_terminate_master_breakpoint)
6719 (create_exception_master_breakpoint)
6720 (breakpoint_event_location_empty_p, print_breakpoint_location)
6721 (print_one_breakpoint_location, create_thread_event_breakpoint)
6722 (init_breakpoint_sal, create_breakpoint)
6723 (print_recreate_ranged_breakpoint, break_range_command)
6724 (init_ada_exception_breakpoint, say_where): Update.
6725 (base_breakpoint_dtor): Don't call delete_event_location.
6726 (bkpt_print_recreate, tracepoint_print_recreate)
6727 (dprintf_print_recreate, update_static_tracepoint)
6728 (breakpoint_re_set_default): Update.
6729
711799d5
TT
67302017-04-12 Tom Tromey <tom@tromey.com>
6731
6732 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
6733 type of "to_do". Update.
6734 (compute_stack_depth): Use std::vector.
6735
52d214d3
TT
67362017-04-12 Tom Tromey <tom@tromey.com>
6737
6738 * printcmd.c (find_instruction_backward): Use std::vector.
6739
4c404b8b
TT
67402017-04-12 Tom Tromey <tom@tromey.com>
6741
6742 * symfile.c (objfilep): Remove typedef.
6743 (reread_symbols): Use a std::vector.
6744
156d9eab
TT
67452017-04-12 Tom Tromey <tom@tromey.com>
6746
6747 * mi/mi-main.c (exec_direction_forward): Remove.
6748 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
6749 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
6750 scoped_restore.
6751 * guile/guile.c (guile_repl_command, guile_command)
6752 (gdbscm_execute_gdb_command): Use scoped_restore.
6753 * go-exp.y (go_parse): Use scoped_restore.
6754 * d-exp.y (d_parse): Use scoped_restore.
6755 * cli/cli-decode.c (cmd_func): Use scoped_restore.
6756 * c-exp.y (c_parse): Use scoped_restore.
6757
4d89769a
TT
67582017-04-12 Tom Tromey <tom@tromey.com>
6759
6760 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
6761 (mi_parse): Update return type.
6762 (mi_parse_free): Remove.
6763 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
6764 (mi_parse::~mi_parse): Rename from mi_parse_free.
6765 (mi_parse_cleanup): Remove.
6766 (mi_parse): Return a unique_ptr. Use new.
6767 * mi/mi-main.c (mi_execute_command): Update.
6768
4b217cc7
TT
67692017-04-12 Tom Tromey <tom@tromey.com>
6770
6771 * location.c (explicit_location_lex_one): Return a
6772 unique_xmalloc_ptr.
6773 (string_to_explicit_location): Update. Remove cleanups.
6774
59d3651b
TT
67752017-04-12 Tom Tromey <tom@tromey.com>
6776
6777 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
6778 (compare_value_and_voffset): Change type. Update.
6779 (compute_vtable_size): Change type of "offset_vec".
6780 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
6781 (gnuv3_get_typeid): Remove extraneous declaration.
6782
b24b0d6c
TT
67832017-04-12 Tom Tromey <tom@tromey.com>
6784
6785 * charset.h (wchar_iterator): Fix comment.
6786
80a3b8c5
TT
67872017-04-12 Tom Tromey <tom@tromey.com>
6788
6789 * charset.c (iconv_wrapper): New class.
6790 (cleanup_iconv): Remove.
6791 (convert_between_encodings): Use it.
6792
c83dd867
TT
67932017-04-12 Tom Tromey <tom@tromey.com>
6794
6795 * symfile.h (increment_reading_symtab): Update type.
6796 * symfile.c (decrement_reading_symtab): Remove.
6797 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
6798 * psymtab.c (psymtab_to_symtab): Update.
6799 * dwarf2read.c (dw2_instantiate_symtab): Update.
6800
0e8621a0
TT
68012017-04-12 Tom Tromey <tom@tromey.com>
6802
6803 * jit.c (struct jit_reader): Declare separately. Add constructor
6804 and destructor. Change type of "handle".
6805 (loaded_jit_reader): Define separately.
6806 (jit_reader_load): Update. New "new".
6807 (jit_reader_unload_command): Use "delete".
6808 * gdb-dlfcn.h (struct dlclose_deleter): New.
6809 (gdb_dlhandle_up): New typedef.
6810 (gdb_dlopen, gdb_dlsym): Update types.
6811 (gdb_dlclose): Remove.
6812 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
6813 (gdb_dlsym): Change type of "handle".
6814 (make_cleanup_dlclose): Remove.
6815 (dlclose_deleter::operator()): Rename from gdb_dlclose.
6816 * compile/compile-c-support.c (load_libcc): Update.
6817
67d89901
TT
68182017-04-12 Tom Tromey <tom@tromey.com>
6819
6820 * symtab.h (find_pcs_for_symtab_line): Change return type.
6821 * symtab.c (find_pcs_for_symtab_line): Change return type.
6822 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
6823 type of "vec". Update.
6824 (ltpy_get_pcs_for_line): Update.
6825 * linespec.c (decode_digits_ordinary): Update.
6826
93921405
TT
68272017-04-12 Tom Tromey <tom@tromey.com>
6828
6829 * tracepoint.c (actions_command): Update.
6830 * python/python.c (python_command, python_interactive_command):
6831 Update.
6832 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
6833 * guile/guile.c (guile_command): Update.
6834 * defs.h (read_command_lines, read_command_lines_1): Return
6835 command_line_up.
6836 (command_lines_deleter): New struct.
6837 (command_line_up): New typedef.
6838 * compile/compile.c (compile_code_command)
6839 (compile_print_command): Update.
6840 * cli/cli-script.h (get_command_line, copy_command_lines): Return
6841 command_line_up.
6842 (make_cleanup_free_command_lines): Remove.
6843 * cli/cli-script.c (get_command_line, read_command_lines_1)
6844 (copy_command_lines): Return command_line_up.
6845 (while_command, if_command, read_command_lines, define_command)
6846 (document_command): Update.
6847 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
6848 Remove.
6849 * breakpoint.h (breakpoint_set_commands): Change type of
6850 "commands".
6851 * breakpoint.c (breakpoint_set_commands): Change type of
6852 "commands". Update.
6853 (do_map_commands_command, update_dprintf_command_list)
6854 (create_tracepoint_from_upload): Update.
6855
ffc2605c
TT
68562017-04-12 Tom Tromey <tom@tromey.com>
6857
6858 * tracepoint.c (scope_info): Update.
6859 * spu-tdep.c (spu_catch_start): Update.
6860 * python/python.c (gdbpy_decode_line): Update.
6861 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
6862 * python/py-breakpoint.c (bppy_init): Update.
6863 * probe.c (parse_probes): Update.
6864 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
6865 * location.h (event_location_deleter): New struct.
6866 (event_location_up): New typedef.
6867 (new_linespec_location, new_address_location, new_probe_location)
6868 (new_explicit_location, copy_event_location)
6869 (string_to_event_location, string_to_event_location_basic)
6870 (string_to_explicit_location): Update return type.
6871 (make_cleanup_delete_event_location): Remove.
6872 * location.c (new_linespec_location, new_address_location)
6873 (new_probe_location, new_explicit_location, copy_event_location):
6874 Return event_location_up.
6875 (delete_event_location_cleanup)
6876 (make_cleanup_delete_event_location): Remove.
6877 (string_to_explicit_location, string_to_event_location_basic)
6878 (string_to_event_location): Return event_location_up.
6879 * linespec.c (canonicalize_linespec, event_location_to_sals)
6880 (decode_line_with_current_source)
6881 (decode_line_with_last_displayed, decode_objc): Update.
6882 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
6883 * completer.c (location_completer): Update.
6884 * cli/cli-cmds.c (edit_command, list_command): Update.
6885 * breakpoint.c (create_overlay_event_breakpoint)
6886 (create_longjmp_master_breakpoint)
6887 (create_std_terminate_master_breakpoint)
6888 (create_exception_master_breakpoint)
6889 (create_thread_event_breakpoint): Update.
6890 (init_breakpoint_sal): Update. Remove some dead code.
6891 (create_breakpoint_sal): Change type of "location". Update.
6892 (create_breakpoints_sal, create_breakpoint, break_command_1)
6893 (dprintf_command, break_range_command, until_break_command)
6894 (init_ada_exception_breakpoint)
6895 (strace_marker_create_sals_from_location)
6896 (update_static_tracepoint, trace_command, ftrace_command)
6897 (strace_command, create_tracepoint_from_upload): Update.
6898 * break-catch-throw.c (re_set_exception_catchpoint): Update.
6899 * ax-gdb.c (agent_command_1): Update.
6900
8f10c932
PA
69012017-04-12 Pedro Alves <palves@redhat.com>
6902
6903 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
6904 * configure.tgt: Handle i[34567]86-*-go32* and
6905 i[34567]86-*-msdosdjgpp*.
6906 * i386-tdep.c (i386_svr4_reg_to_regnum):
6907 Make extern.
6908 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
6909 i386-go32-tdep.c.
6910 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
6911 * i386-go32-tdep.c: New file.
6912 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
6913 declarations.
6914
0a31ccfb
SM
69152017-04-12 Simon Marchi <simon.marchi@ericsson.com>
6916
6917 * aix-thread.c (pd_status2str): Change return type to const char *.
6918
e9bb3fbb
PA
69192017-04-12 Pedro Alves <palves@redhat.com>
6920
6921 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
6922 calls to set_gdbarch_gnu_triplet_regexp.
6923
53375380
PA
69242017-04-12 Pedro Alves <palves@redhat.com>
6925
6926 PR gdb/21323
6927 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
6928 New enum value.
6929 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
6930 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
6931 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
6932 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
6933 * gdbarch.h, gdbarch.c: Regenerate.
6934 * aarch64-tdep.c (aarch64_gdbarch_init): Override
6935 gdbarch_wchar_bit and gdbarch_wchar_signed.
6936 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
6937 * arm-tdep.c (arm_gdbarch_init): Likewise.
6938 * avr-tdep.c (avr_gdbarch_init): Likewise.
6939 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
6940 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
6941 * i386-tdep.c (i386_go32_init_abi): Likewise.
6942 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
6943 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
6944 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
6945 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
6946 * sh-tdep.c (sh_gdbarch_init): Likewise.
6947 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
6948 * sparc64-tdep.c (sparc64_init_abi): Likewise.
6949 * windows-tdep.c (windows_init_abi): Likewise.
6950 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
6951
53e710ac
PA
69522017-04-12 Pedro Alves <palves@redhat.com>
6953
6954 PR c++/21323
6955 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
6956 cplus_primitive_type_char32_t>: New enum values.
6957 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
6958 and cplus_primitive_type_char32_t.
6959 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
6960 32, use the archtecture's built-in type for char16_t and char32_t,
6961 respectively. Otherwise, fallback to init_integer_type as before,
6962 but make the type unsigned, and issue a complaint.
6963 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
6964
ab0538b8
AH
69652017-04-12 Alan Hayward <alan.hayward@arm.com>
6966
5e0e0422 6967 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
ab0538b8
AH
6968 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
6969
5430098f
SDJ
69702017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
6971
6972 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
6973 'const char *'.
6974
7c5ded6a
SDJ
69752017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
6976
6977 * common/common-utils.c (free_vector_argv): New function.
6978 * common/common-utils.h: Include <vector>.
6979 (free_vector_argv): New prototype.
6980 * darwin-nat.c (darwin_create_inferior): Rewrite function
6981 prototype in order to constify "exec_file" and accept a
6982 "std::string" for "allargs".
6983 * fork-child.c: Include <vector>.
6984 (breakup_args): Rewrite function, using C++.
6985 (fork_inferior): Rewrite function header, constify "exec_file_arg"
6986 and accept "std::string" for "allargs". Update the code to
6987 calculate "argv" based on "allargs". Update calls to "exec_fun"
6988 and "execvp".
6989 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
6990 order to constify "exec_file" and accept a "std::string" for
6991 "allargs".
6992 * go32-nat.c (go32_create_inferior): Likewise.
6993 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
6994 * infcmd.c (run_command_1): Constify "exec_file". Use
6995 "std::string" for inferior arguments.
6996 * inferior.h (fork_inferior): Update prototype.
6997 * linux-nat.c (linux_nat_create_inferior): Rewrite function
6998 prototype in order to constify "exec_file" and accept a
6999 "std::string" for "allargs".
7000 * nto-procfs.c (procfs_create_inferior): Likewise.
7001 * procfs.c (procfs_create_inferior): Likewise.
7002 * remote-sim.c (gdbsim_create_inferior): Likewise.
7003 * remote.c (extended_remote_run): Update code to accept
7004 "std::string" as argument.
7005 (extended_remote_create_inferior): Rewrite function prototype in
7006 order to constify "exec_file" and accept a "std::string" for
7007 "allargs".
7008 * rs6000-nat.c (super_create_inferior): Likewise.
7009 (rs6000_create_inferior): Likewise.
7010 * target.h (struct target_ops) <to_create_inferior>: Likewise.
7011 * windows-nat.c (windows_create_inferior): Likewise.
7012
ae0eee42
PA
70132017-04-11 Pedro Alves <palves@redhat.com>
7014
7015 * thread.c: Fix whitespace throughout.
7016
a6acac06
PR
70172017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
7018
7019 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
7020
64403bd1
AH
70212017-04-11 Alan Hayward <alan.hayward@arm.com>
7022
7023 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
7024
a5bef50f
SDJ
70252017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
7026
7027 PR gdb/21364
7028 * osdata.c (info_osdata): Check if 'type' is an empty string
7029 instead of NULL.
7030
9295a5a9
PA
70312017-04-10 Pedro Alves <palves@redhat.com>
7032
7033 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
7034 (ptid_to_global_thread_id, in_thread_list)
7035 (do_captured_list_thread_ids, set_resumed, set_running)
7036 (set_executing, set_stop_requested, finish_thread_state)
7037 (validate_registers_access, can_access_registers_ptid)
7038 (print_thread_info_1, switch_to_thread)
7039 (do_restore_current_thread_cleanup)
7040 (make_cleanup_restore_current_thread, thread_command)
7041 (thread_name_command): Use operator== instead of ptid_equal.
7042
996812e3
PA
70432017-04-10 Pedro Alves <palves@redhat.com>
7044
7045 * thread.c (struct current_thread_cleanup) <next>: Delete field.
7046 (current_thread_cleanup_chain): Delete.
7047 (restore_current_thread_cleanup_dtor)
7048 (make_cleanup_restore_current_thread): Remove references to
7049 current_thread_cleanup_chain.
7050
845b344f
AH
70512017-04-10 Alan Hayward <alan.hayward@arm.com>
7052
7053 * msp430-tdep.c (msp430_pseudo_register_read): Never return
7054 REG_UNKNOWN.
7055
803bdfe4
YQ
70562017-04-10 Yao Qi <yao.qi@linaro.org>
7057
7058 PR gdb/19942
7059 * gdbthread.h (thread_info::deletable): New method.
7060 (thread_info::incref): New method.
7061 (thread_info::decref): New method.
7062 (thread_info::refcount): Move it to private.
7063 * infrun.c (save_stop_context): Call inc_refcount.
7064 (release_stop_context_cleanup): Likewise.
7065 * thread.c (set_thread_exited): New function.
7066 (init_thread_list): Delete "tp" only it is deletable, otherwise
7067 call set_thread_exited.
7068 (delete_thread_1): Call set_thread_exited.
7069 (current_thread_cleanup) <inferior_pid>: Remove.
7070 <thread>: New field.
7071 (restore_current_thread_ptid_changed): Removed.
7072 (do_restore_current_thread_cleanup): Adjust.
7073 (restore_current_thread_cleanup_dtor): Don't call
7074 find_thread_ptid.
7075 (set_thread_refcount): Use dec_refcount.
7076 (make_cleanup_restore_current_thread): Adjust.
7077 (thread_apply_all_command): Call inc_refcount.
7078 (_initialize_thread): Don't call
7079 observer_attach_thread_ptid_changed.
7080
8c25b497
YQ
70812017-04-10 Yao Qi <yao.qi@linaro.org>
7082
7083 * thread.c (delete_thread_1): Hoist code on marking thread as
7084 exited.
7085
8473b447
SM
70862017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7087
7088 * windows-nat.c (windows_detach): Initialize ptid with
7089 minus_one_ptid.
7090
6670ec13
SM
70912017-04-07 Simon Marchi <simon.marchi@ericsson.com>
7092
7093 * unittests/ptid-selftests.c: Fix erroneous assert messages.
7094
ba2f91bb
AH
70952017-04-07 Alan Hayward <alan.hayward@arm.com>
7096
7097 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
7098 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
7099 (bfin_pseudo_register_write): Likewise
7100
436252de
SM
71012017-04-06 Simon Marchi <simon.marchi@ericsson.com>
7102
7103 * common/ptid.h (struct ptid): Change to...
7104 (class ptid_t): ... this.
7105 <ptid_t>: New constructors.
7106 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
7107 matches>: New methods.
7108 <make_null, make_minus_one>: New static methods.
7109 <pid>: Rename to...
7110 <m_pid>: ...this.
7111 <lwp>: Rename to...
7112 <m_lwp>: ...this.
7113 <tid>: Rename to...
7114 <m_tid>: ...this.
7115 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
7116 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
7117 as references, move comment to class ptid_t.
7118 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
7119 ptid_t static methods.
7120 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
7121 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
7122 Take ptid arguments as references, implement using ptid_t methods.
7123 * unittests/ptid-selftests.c: New file.
7124 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7125 unittests/ptid-selftests.c.
7126 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
7127
0dedf377
TP
71282017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
7129
7130 * python/python.c (python_run_simple_file): Cast mode literal to
7131 non-const char pointer as expected by PyFile_FromString.
7132
4e9868d4
SM
71332017-04-05 Simon Marchi <simon.marchi@ericsson.com>
7134
7135 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
7136 minus_one_ptid and null_ptid.
7137
9bf2a700
PA
71382017-04-05 Pedro Alves <palves@redhat.com>
7139
7140 * warning.m4 (build_warnings): Remove -Wno-write-strings.
7141 * configure: Regenerate.
7142
a121b7c1
PA
71432017-04-05 Pedro Alves <palves@redhat.com>
7144
7145 * ada-exp.y (yyerror): Constify.
7146 * ada-lang.c (bound_name, get_selections)
7147 (ada_variant_discrim_type)
7148 (ada_variant_discrim_name, ada_value_struct_elt)
7149 (ada_lookup_struct_elt_type, is_unchecked_variant)
7150 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
7151 (catch_ada_exception_command_split)
7152 (catch_ada_assert_command_split, catch_assert_command)
7153 (ada_op_name): Constify.
7154 * ada-lang.h (ada_yyerror, get_selections)
7155 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
7156 * arc-tdep.c (arc_print_frame_cache): Constify.
7157 * arm-tdep.c (arm_skip_stub): Constify.
7158 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
7159 (gen_aggregate_elt_ref): Constify.
7160 * bcache.c (print_bcache_statistics): Constify.
7161 * bcache.h (print_bcache_statistics): Constify.
7162 * break-catch-throw.c (catch_exception_command_1):
7163 * breakpoint.c (struct ep_type_description::description):
7164 Constify.
7165 (add_solib_catchpoint): Constify.
7166 (catch_fork_command_1): Add cast.
7167 (add_catch_command): Constify.
7168 * breakpoint.h (add_catch_command, add_solib_catchpoint):
7169 Constify.
7170 * bsd-uthread.c (bsd_uthread_state): Constify.
7171 * buildsym.c (patch_subfile_names): Constify.
7172 * buildsym.h (next_symbol_text_func, patch_subfile_names):
7173 Constify.
7174 * c-exp.y (yyerror): Constify.
7175 (token::oper): Constify.
7176 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
7177 * c-varobj.c (cplus_describe_child): Constify.
7178 * charset.c (find_charset_names): Add cast.
7179 (find_charset_names): Constify array and add const_cast.
7180 * cli/cli-cmds.c (complete_command, cd_command): Constify.
7181 (edit_command): Constify.
7182 * cli/cli-decode.c (lookup_cmd): Constify.
7183 * cli/cli-dump.c (dump_memory_command, dump_value_command):
7184 Constify.
7185 (struct dump_context): Constify.
7186 (add_dump_command, restore_command): Constify.
7187 * cli/cli-script.c (get_command_line): Constify.
7188 * cli/cli-script.h (get_command_line): Constify.
7189 * cli/cli-utils.c (check_for_argument): Constify.
7190 * cli/cli-utils.h (check_for_argument): Constify.
7191 * coff-pe-read.c (struct read_pe_section_data): Constify.
7192 * command.h (lookup_cmd): Constify.
7193 * common/print-utils.c (decimal2str): Constify.
7194 * completer.c (gdb_print_filename): Constify.
7195 * corefile.c (set_gnutarget): Constify.
7196 * cp-name-parser.y (yyerror): Constify.
7197 * cp-valprint.c (cp_print_class_member): Constify.
7198 * cris-tdep.c (cris_register_name, crisv32_register_name):
7199 Constify.
7200 * d-exp.y (yyerror): Constify.
7201 (struct token::oper): Constify.
7202 * d-lang.h (d_yyerror): Constify.
7203 * dbxread.c (struct header_file_location::name): Constify.
7204 (add_old_header_file, add_new_header_file, last_function_name)
7205 (dbx_next_symbol_text, add_bincl_to_list)
7206 (find_corresponding_bincl_psymtab, set_namestring)
7207 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
7208 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
7209 * defs.h (command_line_input, print_address_symbolic)
7210 (deprecated_readline_begin_hook): Constify.
7211 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
7212 Constify.
7213 * event-top.c (handle_line_of_input): Constify and add cast.
7214 * exceptions.c (catch_errors): Constify.
7215 * exceptions.h (catch_errors): Constify.
7216 * expprint.c (print_subexp_standard, op_string, op_name)
7217 (op_name_standard, dump_raw_expression, dump_raw_expression):
7218 * expression.h (op_name, op_string, dump_raw_expression):
7219 Constify.
7220 * f-exp.y (yyerror): Constify.
7221 (struct token::oper): Constify.
7222 (struct f77_boolean_val::name): Constify.
7223 * f-lang.c (f_word_break_characters): Constify.
7224 * f-lang.h (f_yyerror): Constify.
7225 * fork-child.c (fork_inferior): Add cast.
7226 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
7227 (new_variant): Constify.
7228 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
7229 * gdbarch.c: Regenerate.
7230 * gdbcore.h (set_gnutarget): Constify.
7231 * go-exp.y (yyerror): Constify.
7232 (token::oper): Constify.
7233 * go-lang.h (go_yyerror): Constify.
7234 * go32-nat.c (go32_sysinfo): Constify.
7235 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
7236 * guile/scm-cmd.c (cmdscm_function): Constify.
7237 * guile/scm-param.c (pascm_param_value): Constify.
7238 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
7239 (h8300sx_register_name): Constify.
7240 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
7241 Constify.
7242 * ia64-tdep.c (ia64_register_names): Constify.
7243 * infcmd.c (construct_inferior_arguments): Constify.
7244 (path_command, attach_post_wait): Constify.
7245 * language.c (show_range_command, show_case_command)
7246 (unk_lang_error): Constify.
7247 * language.h (language_defn::la_error)
7248 (language_defn::la_name_of_this): Constify.
7249 * linespec.c (decode_line_2): Constify.
7250 * linux-thread-db.c (thread_db_err_str): Constify.
7251 * lm32-tdep.c (lm32_register_name): Constify.
7252 * m2-exp.y (yyerror): Constify.
7253 * m2-lang.h (m2_yyerror): Constify.
7254 * m32r-tdep.c (m32r_register_names): Constify and make static.
7255 * m68hc11-tdep.c (m68hc11_register_names): Constify.
7256 * m88k-tdep.c (m88k_register_name): Constify.
7257 * macroexp.c (appendmem): Constify.
7258 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
7259 (upgrade_type, parse_external, parse_partial_symbols)
7260 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
7261 (new_symbol): Constify.
7262 * memattr.c (mem_info_command): Constify.
7263 * mep-tdep.c (register_name_from_keyword): Constify.
7264 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
7265 Constify.
7266 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
7267 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
7268 * mi/mi-main.c (captured_mi_execute_command): Constify and add
7269 cast.
7270 (mi_execute_async_cli_command): Constify.
7271 * mips-tdep.c (mips_register_name): Constify.
7272 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
7273 (am33_register_name, am33_2_register_name)
7274 * moxie-tdep.c (moxie_register_names): Constify.
7275 * nat/linux-osdata.c (osdata_type): Constify fields.
7276 * nto-tdep.c (nto_parse_redirection): Constify.
7277 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
7278 (lookup_child_selector): Constify.
7279 (objc_methcall::name): Constify.
7280 * objc-lang.h (lookup_objc_class, lookup_child_selector)
7281 (lookup_struct_typedef): Constify.
7282 * objfiles.c (pc_in_section): Constify.
7283 * objfiles.h (pc_in_section): Constify.
7284 * p-exp.y (struct token::oper): Constify.
7285 (yyerror): Constify.
7286 * p-lang.h (pascal_yyerror): Constify.
7287 * parser-defs.h (op_name_standard): Constify.
7288 (op_print::string): Constify.
7289 (exp_descriptor::op_name): Constify.
7290 * printcmd.c (print_address_symbolic): Constify.
7291 * psymtab.c (print_partial_symbols): Constify.
7292 * python/py-breakpoint.c (stop_func): Constify.
7293 (bppy_get_expression): Constify.
7294 * python/py-cmd.c (cmdpy_completer::name): Constify.
7295 (cmdpy_function): Constify.
7296 * python/py-event.c (evpy_add_attribute)
7297 (gdbpy_initialize_event_generic): Constify.
7298 * python/py-event.h (evpy_add_attribute)
7299 (gdbpy_initialize_event_generic): Constify.
7300 * python/py-evts.c (add_new_registry): Constify.
7301 * python/py-finishbreakpoint.c (outofscope_func): Constify.
7302 * python/py-framefilter.c (get_py_iter_from_func): Constify.
7303 * python/py-inferior.c (get_buffer): Add cast.
7304 * python/py-param.c (parm_constant::name): Constify.
7305 * python/py-unwind.c (fprint_frame_id): Constify.
7306 * python/python.c (gdbpy_parameter_value): Constify.
7307 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
7308 * remote.c (memory_packet_config::name): Constify.
7309 (show_packet_config_cmd, remote_write_bytes)
7310 (remote_buffer_add_string):
7311 * reverse.c (exec_reverse_once): Constify.
7312 * rs6000-tdep.c (variant::name, variant::description): Constify.
7313 * rust-exp.y (rustyyerror): Constify.
7314 * rust-lang.c (rust_op_name): Constify.
7315 * rust-lang.h (rustyyerror): Constify.
7316 * serial.h (serial_ops::name): Constify.
7317 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
7318 (sh_sh3e_register_name, sh_sh2e_register_name)
7319 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
7320 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
7321 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
7322 (sh_sh4al_dsp_register_name): Constify.
7323 * sh64-tdep.c (sh64_register_name): Constify.
7324 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
7325 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
7326 * stabsread.c (patch_block_stabs, read_type_number)
7327 (ref_map::stabs, ref_add, process_reference)
7328 (symbol_reference_defined, define_symbol, define_symbol)
7329 (error_type, read_type, read_member_functions, read_cpp_abbrev)
7330 (read_one_struct_field, read_struct_fields, read_baseclasses)
7331 (read_tilde_fields, read_struct_type, read_array_type)
7332 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
7333 (read_huge_number, read_range_type, read_args, common_block_start)
7334 (find_name_end): Constify.
7335 * stabsread.h (common_block_start, define_symbol)
7336 (process_one_symbol, symbol_reference_defined, ref_add):
7337 * symfile.c (get_section_index, add_symbol_file_command):
7338 * symfile.h (get_section_index): Constify.
7339 * target-descriptions.c (tdesc_type::name): Constify.
7340 (tdesc_free_type): Add cast.
7341 * target.c (find_default_run_target):
7342 (add_deprecated_target_alias, find_default_run_target)
7343 (target_announce_detach): Constify.
7344 (do_option): Constify.
7345 * target.h (add_deprecated_target_alias): Constify.
7346 * thread.c (print_thread_info_1): Constify.
7347 * top.c (deprecated_readline_begin_hook, command_line_input):
7348 Constify.
7349 (init_main): Add casts.
7350 * top.h (handle_line_of_input): Constify.
7351 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
7352 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
7353 (tfind_command): Rename to ...
7354 (tfind_command_1): ... this and constify.
7355 (tfind_command): New function.
7356 (tfind_end_command, tfind_start_command): Adjust.
7357 (encode_source_string): Constify.
7358 * tracepoint.h (encode_source_string): Constify.
7359 * tui/tui-data.c (tui_partial_win_by_name): Constify.
7360 * tui/tui-data.h (tui_partial_win_by_name): Constify.
7361 * tui/tui-source.c (tui_set_source_content_nil): Constify.
7362 * tui/tui-source.h (tui_set_source_content_nil): Constify.
7363 * tui/tui-win.c (parse_scrolling_args): Constify.
7364 * tui/tui-windata.c (tui_erase_data_content): Constify.
7365 * tui/tui-windata.h (tui_erase_data_content): Constify.
7366 * tui/tui-winsource.c (tui_erase_source_content): Constify.
7367 * tui/tui.c (tui_enable): Add cast.
7368 * utils.c (defaulted_query): Constify.
7369 (init_page_info): Add cast.
7370 (puts_debug, subset_compare): Constify.
7371 * utils.h (subset_compare): Constify.
7372 * varobj.c (varobj_format_string): Constify.
7373 * varobj.h (varobj_format_string): Constify.
7374 * vax-tdep.c (vax_register_name): Constify.
7375 * windows-nat.c (windows_detach): Constify.
7376 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
7377 * xml-support.c (gdb_xml_end_element): Constify.
7378 * xml-tdesc.c (tdesc_start_reg): Constify.
7379 * xstormy16-tdep.c (xstormy16_register_name): Constify.
7380 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
7381 * xtensa-tdep.h (xtensa_register_t::name): Constify.
7382
995816ba
PA
73832017-04-05 Pedro Alves <palves@redhat.com>
7384
7385 * proc-api.c (struct trans): Constify.
7386 (procfs_note): Constify.
7387 * proc-events.c (struct trans, syscall_table):
7388 * proc-flags.c (struct trans): Constify.
7389 * proc-utils.h (procfs_note): Constify.
7390 * proc-why.c (struct trans): Constify.
7391 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
7392 (procfs_detach): Constify.
7393 * sol-thread.c (struct string_map): Constify.
7394 (td_err_string, td_state_string): Constify.
7395
3e83a920
PA
73962017-04-05 Pedro Alves <palves@redhat.com>
7397
7398 * proc-api.c (procfs_filename): Don't initialize
7399 procfs_filename.
7400 (prepare_to_trace): Assume procfs_filename is non-NULL.
7401 (_initialize_proc_api): Give procfs_filename a default value here.
7402
63160a43
PA
74032017-04-05 Pedro Alves <palves@redhat.com>
7404
7405 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
7406 'cond_string' parameter.
7407 (extract_exception_regexp): Constify 'string' parameter.
7408 (catch_exception_command_1): Constify.
7409 * breakpoint.c (init_catchpoint)
7410 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
7411 parameter.
7412 (ep_parse_optional_if_clause, catch_fork_command_1)
7413 (catch_exec_command_1): Constify.
7414 * breakpoint.h (init_catchpoint): Constify 'cond_string'
7415 parameter.
7416 (ep_parse_optional_if_clause): Constify.
7417 * cli/cli-utils.c (remove_trailing_whitespace)
7418 (check_for_argument): Constify.
7419 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
7420 non-const overload.
7421 (check_for_argument): Likewise.
7422
9b2eba3d
PA
74232017-04-05 Pedro Alves <palves@redhat.com>
7424
7425 * event-top.c (command_line_handler): Add cast to execute_command
7426 call.
7427 * record-btrace.c (cmd_record_btrace_bts_start)
7428 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
7429 (cmd_record_btrace_start): Add cast to execute_command call.
7430 * record-full.c (record_full_goto_insn):
7431 * record.c (record_start, record_stop): Add cast to
7432 execute_command_to_string calls.
7433 (cmd_record_start): Add cast to execute_command calls.
7434
2adadf51
PA
74352017-04-05 Pedro Alves <palves@redhat.com>
7436
7437 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
7438 static inline function.
7439 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
7440 array and use gdb_PyArg_ParseTupleAndKeywords.
7441 * python/py-cmd.c (cmdpy_init): Likewise.
7442 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
7443 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
7444 (infpy_search_memory): Likewise.
7445 * python/py-objfile.c (objfpy_add_separate_debug_file)
7446 (gdbpy_lookup_objfile): Likewise.
7447 * python/py-symbol.c (gdbpy_lookup_symbol)
7448 (gdbpy_lookup_global_symbol): Likewise.
7449 * python/py-type.c (gdbpy_lookup_type): Likewise.
7450 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
7451 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
7452 Likewise.
7453
0d1f4ceb
PA
74542017-04-05 Pedro Alves <palves@redhat.com>
7455
7456 * python/python-internal.h (gdb_PyGetSetDef): New type.
7457 * python/py-block.c (block_object_getset)
7458 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
7459 * python/py-event.c (event_object_getset)
7460 (finish_breakpoint_object_getset): Likewise.
7461 * python/py-inferior.c (inferior_object_getset): Likewise.
7462 * python/py-infthread.c (thread_object_getset): Likewise.
7463 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
7464 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
7465 * python/py-objfile.c (objfile_getset): Likewise.
7466 * python/py-progspace.c (pspace_getset): Likewise.
7467 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
7468 Likewise.
7469 * python/py-record.c (recpy_record_getset): Likewise.
7470 * python/py-symbol.c (symbol_object_getset): Likewise.
7471 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
7472 Likewise.
7473 * python/py-type.c (type_object_getset, field_object_getset):
7474 Likewise.
7475 * python/py-value.c (value_object_getset): Likewise.
7476
4d759979
PA
74772017-04-05 Pedro Alves <palves@redhat.com>
7478
7479 * python/python-internal.h (gdb_PyObject_CallMethod)
7480 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
7481 New functions.
7482 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
7483 (PySys_GetObject, PySys_SetPath): New macros.
7484
fdf9e36f
PA
74852017-04-05 Pedro Alves <palves@redhat.com>
7486
7487 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
7488 info_osdata_command.
7489 * osdata.c (info_osdata_command): Rename to ...
7490 (info_osdata): ... this. Constify 'type' parameter, and remove
7491 the 'from_tty' parameter. Accept NULL TYPE.
7492 (info_osdata_command): New function.
7493 * osdata.h (info_osdata_command): Remove declaration.
7494 (info_osdata): New declaration.
7495
9f33b8b7
PA
74962017-04-05 Pedro Alves <palves@redhat.com>
7497
7498 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
7499 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
7500 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
7501 parameter.
7502 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
7503 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
7504 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
7505 parameter.
7506 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
7507 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
7508 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
7509 (mi_cmd_file_list_exec_source_files)
7510 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
7511 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
7512 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
7513 parameter.
7514 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
7515 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
7516 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
7517 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
7518 (mi_cmd_stack_info_frame): Constify 'command' parameter.
7519 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
7520 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
7521 'command' parameter.
7522 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
7523 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
7524 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
7525 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
7526 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
7527 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
7528 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
7529 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
7530 (mi_cmd_var_set_update_range): Constify 'command' parameter.
7531 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
7532 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
7533 parameter.
7534 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
7535 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
7536 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
7537 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
7538 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
7539 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
7540 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
7541 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
7542 (mi_cmd_data_list_changed_registers)
7543 (mi_cmd_data_write_register_values)
7544 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
7545 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
7546 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
7547 (mi_cmd_list_features, mi_cmd_list_target_features)
7548 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
7549 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
7550 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
7551 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
7552 (mi_cmd_trace_frame_collected): Constify 'command'
7553 parameter.
7554 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
7555 'command' parameter.
7556
67cb5b2d
PA
75572017-04-05 Pedro Alves <palves@redhat.com>
7558
7559 * ada-lang.c (ada_completer_word_break_characters): Now a const
7560 array.
7561 (ada_get_gdb_completer_word_break_characters): Constify.
7562 * completer.c (gdb_completer_command_word_break_characters)
7563 (gdb_completer_file_name_break_characters)
7564 (gdb_completer_quote_characters): Now const arrays.
7565 (get_gdb_completer_quote_characters): Constify.
7566 (set_rl_completer_word_break_characters): New function.
7567 (set_gdb_completion_word_break_characters)
7568 (complete_line_internal): Use it.
7569 * completer.h (get_gdb_completer_quote_characters): Constify.
7570 (set_rl_completer_word_break_characters): Declare.
7571 * f-lang.c (f_word_break_characters): Constify.
7572 * language.c (default_word_break_characters): Constify.
7573 * language.h (language_defn::la_word_break_characters): Constify.
7574 (default_word_break_characters): Constify.
7575 * top.c (init_main): Use set_rl_completer_word_break_characters.
7576
7a114964
PA
75772017-04-05 Pedro Alves <palves@redhat.com>
7578
7579 * aix-thread.c (aix_thread_pid_to_str)
7580 (aix_thread_extra_thread_info): Constify.
7581 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
7582 * bsd-uthread.c (bsd_uthread_extra_thread_info)
7583 (bsd_uthread_pid_to_str): Constify.
7584 * corelow.c (core_pid_to_str): Constify.
7585 * darwin-nat.c (darwin_pid_to_str): Constify.
7586 * fbsd-nat.c (fbsd_pid_to_str): Constify.
7587 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
7588 Constify.
7589 * gnu-nat.c (gnu_pid_to_str): Constify.
7590 * go32-nat.c (go32_pid_to_str): Constify.
7591 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
7592 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
7593 * inferior.c (inferior_pid_to_str): Constify.
7594 * linux-nat.c (linux_nat_pid_to_str): Constify.
7595 * linux-tdep.c (linux_core_pid_to_str): Constify.
7596 * linux-thread-db.c (thread_db_pid_to_str)
7597 (thread_db_extra_thread_info): Constify.
7598 * nto-tdep.c (nto_extra_thread_info): Constify.
7599 * nto-tdep.h (nto_extra_thread_info): Constify.
7600 * obsd-nat.c (obsd_pid_to_str): Constify.
7601 * procfs.c (procfs_pid_to_str): Constify.
7602 * ravenscar-thread.c (ravenscar_extra_thread_info)
7603 (ravenscar_pid_to_str): Constify.
7604 * remote-sim.c (gdbsim_pid_to_str): Constify.
7605 * remote.c (remote_threads_extra_info, remote_pid_to_str):
7606 Constify.
7607 * sol-thread.c (solaris_pid_to_str): Constify.
7608 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
7609 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
7610 * target.c (default_pid_to_str, target_pid_to_str)
7611 (normal_pid_to_str, default_pid_to_str): Constify.
7612 * target.h (target_ops::to_pid_to_str)
7613 (target_ops::to_extra_thread_info): Constify.
7614 (target_pid_to_str, normal_pid_to_str): Constify.
7615 * windows-nat.c (windows_pid_to_str): Constify.
7616 * gdbarch.sh (core_pid_to_str): Constify.
7617 * target-delegates.c: Regenerate.
7618 * gdbarch.h, gdbarch.c: Regenerate.
7619
69bbf465
PA
76202017-04-05 Pedro Alves <palves@redhat.com>
7621
7622 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
7623 the memory of the temporary warning_pre_print override.
7624 * utils.c (warning_pre_print): Constify.
7625 * utils.h (warning_pre_print): Constify.
7626
be47f9e8
PA
76272017-04-05 Pedro Alves <palves@redhat.com>
7628
7629 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
7630 (shell_command): New function.
7631 (make_command): Use std::string.
7632 (init_cli_cmds): Register shell_command instead of shell_escape.
7633
bde6261a
PA
76342017-04-05 Pedro Alves <palves@redhat.com>
7635
7636 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
7637 * tracepoint.c (default_collect): Don't initialize.
7638
b38ef47f
PA
76392017-04-05 Pedro Alves <palves@redhat.com>
7640
7641 * macroexp.c (macro_buffer::shared): Now a bool.
7642 (init_buffer): Update.
7643 (init_shared_buffer): Constify 'addr' parameter.
7644 (substitute_args, expand, macro_expand, macro_expand_next): Remove
7645 casts.
7646
f995bbe8
PA
76472017-04-05 Pedro Alves <palves@redhat.com>
7648
7649 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
7650 * disasm.c (set_disassembler_options): Constify local.
7651 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
7652
4a596fe2
SDJ
76532017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
7654
7655 PR gdb/21352
7656 * tracefile.c (tsave_command): Fix argument parsing for '-r'
7657 option.
7658
2cad08ea
YQ
76592017-04-05 Yao Qi <yao.qi@linaro.org>
7660
7661 * frame.c (frame_unwind_register_unsigned): Call
7662 frame_unwind_register_value.
7663
55a98976
YQ
76642017-04-05 Yao Qi <yao.qi@linaro.org>
7665
7666 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
7667 Use gdb_test_multiple, and don't match anchor.
7668
4ac40124
PA
76692017-04-05 Pedro Alves <palves@redhat.com>
7670
7671 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
7672 (Write After Approval): Remove Simon Marchi.
7673
c053b654
PA
76742017-04-05 Pedro Alves <palves@redhat.com>
7675
7676 * common/gdb_optional.h (optional::optional): Make constexpr and
7677 initialize m_dummy.
7678
4c7bf4f9
JB
76792017-04-04 John Baldwin <jhb@FreeBSD.org>
7680
7681 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
7682 (amd64fbsd_jmp_buf_reg_offset): Remove.
7683 (amd64fbsd_supply_uthread): Remove function.
7684 (amd64fbsd_collect_uthread): Remove function.
7685 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
7686 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
7687 (x86_64-*-freebsd*): Remove bsd-uthread.o.
7688 (fbsd-nat.c): Update comment.
7689 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
7690 (i386fbsd_jmp_buf_reg_offset): Remove.
7691 (i386fbsd_supply_uthread): Remove function.
7692 (i386fbsd_collect_uthread): Remove function.
7693 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
7694
1e1a8bef
JB
76952017-04-04 John Baldwin <jhb@FreeBSD.org>
7696
7697 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
7698 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
7699 * NEWS: Mention that support for FreeBSD/alpha was removed.
7700 * alpha-fbsd-tdep.c: Delete file.
7701 * config/alpha/fbsd.mh: Delete file.
7702 * configure.host: Delete alpha*-*-freebsd* and
7703 alpha*-*-kfreebsd*-gnu.
7704 * configure.tgt: Delete alpha*-*-freebsd* and
7705 alpha*-*-kfreebsd*-gnu.
7706
49907934
JB
77072017-04-04 John Baldwin <jhb@FreeBSD.org>
7708
7709 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
7710 amd64bsd_store_inferior_registers): Use ptid from regcache.
7711
6f77053d
PA
77122017-04-04 Pedro Alves <palves@redhat.com>
7713
7714 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
7715 data fields, make them private and add "m_" prefixes.
7716 (lnp_state_machine::lnp_state_machine): New ctor.
7717 (record_line, check_line_address, handle_set_discriminator)
7718 (handle_set_address, handle_advance_pc, handle_special_opcode)
7719 (handle_advance_line, handle_set_file, handle_negate_stmt)
7720 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
7721 (end_sequence, advance_line): New methods.
7722 (m_gdbarch, m_record_lines_p): New fields.
7723 (lnp_reader_state): Delete.
7724 (dwarf_record_line): Rename to ...
7725 (lnp_state_machine::record_line): ... adjust.
7726 (init_lnp_state_machine): Delete.
7727 (lnp_state_machine::lnp_state_machine): New.
7728 (check_line_address): Rename to ...
7729 (lnp_state_machine::check_line_address): This.
7730 (dwarf_decode_lines_1): Remove reference to "reader_state".
7731 Adjust lnp_state_machine having a non-default ctor. Use bool.
7732 State machine internal state manipulation moved to
7733 lnp_state_machine methods.
7734
9c541725
PA
77352017-04-04 Pedro Alves <palves@redhat.com>
7736
7737 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7738 unittests/offset-type-selftests.c.
7739 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
7740 * common/offset-type.h: New file.
7741 * common/preprocessor.h: New file.
7742 * common/traits.h: New file.
7743 * common/valid-expr.h: New file.
7744 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
7745 sect_offset and cu_offset strong typedefs throughout.
7746 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
7747 typedefs throughout.
7748 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
7749 sect_offset and cu_offset strong typedefs throughout.
7750 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
7751 typedefs throughout.
7752 * gdbtypes.h: Include "common/offset-type.h".
7753 (cu_offset): Now an offset type (strong typedef) instead of a
7754 struct.
7755 (sect_offset): Likewise.
7756 (union call_site_parameter_u): Rename "param_offset" field to
7757 "param_cu_off".
7758 * unittests/offset-type-selftests.c: New file.
7759
ecfb656c
PA
77602017-04-04 Pedro Alves <palves@redhat.com>
7761
7762 * common/underlying.h: New file.
7763 * dwarf2read.c: Include "common/gdb_optional.h" and
7764 "common/underlying.h".
7765 (dir_index, file_name_index): New types.
7766 (file_entry): Use them.
7767 (file_entry::include): Use to_underlying.
7768 (line_header::add_file_name): Use dir_index.
7769 (read_formatted_entries): Use gdb::optional. Read form before
7770 writting to file_entry.
7771 (dwarf_decode_line_header): Use dir_index.
7772 (lnp_state_machine::current_file): Use to_underlying.
7773 (lnp_state_machine::file): Change type to file_name_index.
7774 (dwarf_record_line): Use to_underlying.
7775 (init_lnp_state_machine): Use file_name_index.
7776 (dwarf_decode_lines_1): Use dir_index and file_name_index.
7777
d194f1fe
PA
77782017-04-04 Pedro Alves <palves@redhat.com>
7779
7780 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
7781 operator bool, has_value and get methods.
7782
fff8551c
PA
77832017-04-04 Pedro Alves <palves@redhat.com>
7784
7785 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
7786 fields.
7787 (line_header): Initialize all data fields. Change type of
7788 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
7789 Change type of include_dirs to std::vector<const char *>. Remove
7790 num_include_dirs, include_dirs_size. Change type of file_names to
7791 std::vector<file_entry>. Remove num_file_names, file_names_size.
7792 (line_header::line_header): New.
7793 (line_header::add_include_dir, line_header::add_file_name): New
7794 methods.
7795 (line_header::include_dir_at): Remove NULL check.
7796 (line_header::file_name_at): Add const overload.
7797 (line_header_up): New unique_ptr typedef.
7798 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
7799 std::vector. Remove free_line_header call.
7800 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
7801 free_line_header call.
7802 (free_cu_line_header): Delete.
7803 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
7804 (setup_type_unit_groups): Use line_header_up instead of cleanups.
7805 Adjust to use std::vector.
7806 (free_line_header): Delete.
7807 (free_line_header_voidp): Use delete.
7808 (add_include_dir): Replace with ...
7809 (line_header::add_include_dir): ... this method. Use std::vector.
7810 (add_file_name): Replace with ...
7811 (line_header::add_file_name): ... this method. Use std::vector.
7812 (add_include_dir_stub): Delete.
7813 (read_formatted_entries): Remove memset.
7814 (dwarf_decode_line_header): Return a line_header_up instead of a
7815 raw pointer. Remove cleanup handling. Pass lambdas to
7816 read_formatted_entries. Adjust to use line_header methods.
7817 (dwarf_decode_lines_1): Adjust to use line_header methods.
7818 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
7819 use std::vector.
7820
d62a8ae2
SM
78212017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
7822
7823 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
7824 instead of struct ptid.
7825
db3a1dc7
AH
78262017-05-04 Alan Hayward <alan.hayward@arm.com>
7827
7828 * frame.c (get_frame_register_bytes): Unwind using value.
7829 (put_frame_register_bytes): Likewise.
7830
b1b45502
IB
78312017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
7832
7833 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
7834 aggregate-like.
7835
ec13808e
JK
78362017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
7837
7838 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
7839
12316564
YQ
78402017-03-29 Yao Qi <yao.qi@linaro.org>
7841
7842 * gdbthread.h (struct thread_info): Declare constructor and
7843 destructor. Add some in-class member initializers.
7844 * thread.c (free_thread): Remove.
7845 (init_thread_list): Call delete instead of free_thread.
7846 (new_thread): Call thread_info constructor.
7847 (thread_info::thread_info): New function.
7848 (thread_info::~thread_info): New function.
7849 (delete_thread_1): Call delete instead of free_thread.
7850 (make_cleanup_restore_current_thread): Move tp and frame to
7851 inner block.
7852
fe5f7374
AK
78532017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
7854
7855 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
7856 (arc_skip_prologue): Likewise.
7857 (arc_make_frame_cache): Likewise.
7858 (arc_pv_get_operand): New function.
7859 (arc_is_in_prologue): Likewise.
7860 (arc_analyze_prologue): Likewise.
7861 (arc_print_frame_cache): Likewise.
7862 (MAX_PROLOGUE_LENGTH): New constant.
7863
eea78757
AK
78642017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
7865
7866 * configure.tgt: Add arc-insn.o.
7867 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
7868 (dump_arc_instruction_command): New function.
7869 (arc_fprintf_disasm): Likewise.
7870 (arc_disassemble_info): Likewise.
7871 (arc_insn_get_operand_value): Likewise.
7872 (arc_insn_get_operand_value_signed): Likewise.
7873 (arc_insn_get_memory_base_reg): Likewise.
7874 (arc_insn_get_memory_offset): Likewise.
7875 (arc_insn_get_branch_target): Likewise.
7876 (arc_insn_dump): Likewise.
7877 (arc_insn_get_linear_next_pc): Likewise.
7878 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
7879 (arc_disassemble_info): Likewise.
7880 (arc_insn_get_branch_target): Likewise.
7881 (arc_insn_get_linear_next_pc): Likewise.
7882 * NEWS: Mention new "maint print arc arc-instruction".
7883
3be78afd
AK
78842017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
7885
7886 * arc-tdep (maintenance_print_arc_list): New variable.
7887 (maintenance_print_arc_command): New function.
7888
296ec4fa
AK
78892017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
7890
7891 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
7892 Add "limm" and "reserved".
7893 (arc_cannot_fetch_register, arc_cannot_store_register): Add
7894 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
7895 * arc-tdep.h (arc_regnum): Likewise.
7896
f74f865e
MF
78972017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7898
7899 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
7900 for THREADPTR register.
7901 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
7902 register.
7903 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
7904 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
7905 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
7906
0d0bf81a
MF
79072017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7908
7909 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
7910 registers above gdbarch_num_regs (gdbarch) as privileged in
7911 call0 ABI.
7912
0ce4291e
MF
79132017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7914
7915 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
7916 for a single specified register or for all registers in
7917 a0_base..a0_base + C0_NREGS range.
7918 (supply_gregset_reg): Call regcache_raw_supply for a single
7919 specified register or for all registers in a0_base..a0_base +
7920 C0_NREGS range.
7921
c56054f9
MF
79222017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7923
7924 * arch/xtensa.h (C0_NREGS): Add definition.
7925 * xtensa-tdep.c (C0_NREGS): Remove definition.
7926
a4398628
MF
79272017-03-27 Max Filippov <jcmvbkbc@gmail.com>
7928
7929 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
7930 Drop xtensa_default_isa initialization.
7931 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
7932
8c43009f
PA
79332017-03-27 Pedro Alves <palves@redhat.com>
7934
7935 * dwarf2read.c (file_entry) <dir_index>: Add comment.
7936 (file_entry::include_dir): New method.
7937 (line_header::include_dir_at, line_header::file_name_at): New
7938 methods.
7939 (setup_type_unit_groups, setup_type_unit_groups)
7940 (psymtab_include_file_name): Simplify using the new methods.
7941 (lnp_state_machine) <the_line_header>: New field.
7942 <file>: Add comment.
7943 (lnp_state_machine::current_file): New method.
7944 (dwarf_record_line): Simplify using the new methods.
7945 (init_lnp_state_machine): Initialize the "the_line_header" field.
7946 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
7947 Simplify using the new methods.
7948
a7e80b9e
PA
79492017-03-27 Pedro Alves <palves@redhat.com>
7950
7951 * cp-name-parser.y (make_empty): Delete.
7952 (demangler_special, nested_name, ptr_operator, array_indicator)
7953 (direct_declarator, declarator_1): Use fill_comp instead of
7954 make_empty.
7955
21047726
PA
79562017-03-27 Pedro Alves <palves@redhat.com>
7957
7958 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
7959 to ATTRIBUTE_PRINTF.
7960 * solib-target.c (library_list_start_list): Print "string" not
7961 "version".
7962 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
7963 gdb_xml_error call.
7964
d721ba37
PA
79652017-03-27 Pedro Alves <palves@redhat.com>
7966
7967 * dwarf2read.c (struct file_and_directory): New.
7968 (dwarf2_get_dwz_file): Adjust to use std::string.
7969 (dw2_get_file_names_reader): Adjust to use file_and_directory.
7970 (find_file_and_directory): Adjust to return a file_and_directory
7971 object.
7972 (read_file_scope): Adjust to use file_and_directory. Remove
7973 make_cleanup/do_cleanups calls.
7974 (open_and_init_dwp_file): Adjust to use std::string. Remove
7975 make_cleanup/do_cleanups calls.
7976 * python/python.c (do_start_initialization): Adjust to ldirname
7977 returning a std::string.
7978 * utils.c (ldirname): Now returns a std::string.
7979 * utils.h (ldirname): Change return type to std::string.
7980 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
7981 returning a std::string.
7982 * xml-tdesc.c (file_read_description_xml): Likewise.
7983
ed771251
AH
79842017-03-24 Alan Hayward <alan.hayward@arm.com>
7985
7986 * regcache.c (regcache_debug_print_register): New function.
7987 * regcache.h (regcache_debug_print_register): New declaration.
7988 * target.c (debug_print_register): Remove.
7989 (target_fetch_registers): Call regcache_debug_print_register.
7990 (target_store_registers): Likewise.
7991
568c1b9f
PB
79922017-03-24 Pádraig Brady <pbrady@fb.com>
7993
7994 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
7995 reference beyond the 'lh->include_dirs' array before accessing to
7996 it.
7997 (psymtab_include_file_name): Likewise.
7998 (dwarf_decode_lines_1): Likewise.
7999 (dwarf_decode_lines): Likewise.
8000 (file_file_name): Likewise.
8001
3e00d44f
SM
80022017-03-23 Simon Marchi <simon.marchi@ericsson.com>
8003
8004 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
8005 inferior_ptid.
8006 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
8007 ps_lsetfpregs): Likewise.
8008 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
8009 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
8010 ps_lsetfpregs): Likewise.
8011 * target.c (target_fetch_registers, target_store_registers):
8012 Remove asserts.
8013
077ae656
AH
80142017-03-23 Alan Hayward <alan.hayward@arm.com>
8015
8016 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
8017
1e2b521d
YQ
80182017-03-23 Yao Qi <yao.qi@linaro.org>
8019
8020 * aarch64-tdep.c (aarch64_process_record_test): Declare.
8021 (_initialize_aarch64_tdep): Register it.
8022 (aarch64_record_load_store): Handle PRFM instruction.
8023 (aarch64_process_record_test): New function.
8024
33877125
YQ
80252017-03-23 Yao Qi <yao.qi@linaro.org>
8026
8027 * aarch64-tdep.c (aarch64_record_load_store): Fix code
8028 indentation.
8029
a0eef940
YQ
80302017-03-23 Yao Qi <yao.qi@linaro.org>
8031
8032 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
8033
3f2a3564
PR
80342017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8035
8036 python/python.c (do_start_initialization): Fix memory leak.
8037
b67aeab0
SM
80382017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
8039
8040 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
8041 using get_ptrace_pid.
8042 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
8043 inferior_ptid.
8044 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
8045 inferior_ptid instead of pid.
8046
ffdbe864
YQ
80472017-03-22 Yao Qi <yao.qi@linaro.org>
8048
8049 * aarch64-tdep.c: Wrap locally used classes in anonymous
8050 namespace.
8051 * arm-tdep.c: Likewise.
8052 * linespec.c: Likewise.
8053 * ui-out.c: Likewise.
8054
9d736fbf
JG
80552017-03-22 Jonah Graham <jonah@kichwacoders.com>
8056
8057 PR gdb/19637
8058 * python/lib/gdb/printer/bound_registers.py: Import sys.
8059
3de88e9a
SM
80602017-03-21 Simon Marchi <simon.marchi@ericsson.com>
8061
8062 * windows-nat.c (do_windows_fetch_inferior_registers): Add
8063 windows_thread_info parameter and use it instead of
8064 current_thread.
8065 (windows_fetch_inferior_registers): Don't set current_thread,
8066 pass the thread to do_windows_fetch_inferior_registers. Use
8067 ptid from regcache instead of inferior_ptid.
8068 (do_windows_store_inferior_registers): Add windows_thread_info
8069 parameter and use it instead of current_thread.
8070 (windows_store_inferior_registers): Don't set current_thread,
8071 pass the thread to do_windows_store_inferior_registers. Use
8072 ptid from regcache instead of inferior_ptid.
8073
0e7b8f61
SM
80742017-03-21 Simon Marchi <simon.marchi@ericsson.com>
8075
8076 * ser-mingw.c (ser_windows_raw): Remove reference to
8077 struct serial::current_timeout.
8078
5badf10a
IR
80792017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
8080
8081 PR tdep/20928
8082 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
8083 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
8084 (sparc64_fsr_type): Fix %fsr decoding.
8085
cee59b3f
TW
80862017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
8087
8088 * python/py-record-btrace.c (btpy_insn_data): Change return type
8089 for Python 2.
8090
639a9038
SM
80912017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
8092
8093 * spu-linux-nat.c (spu_fetch_inferior_registers,
8094 spu_store_inferior_registers): Use ptid from regcache, set and
8095 restore inferior_ptid.
8096 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
8097 Likewise.
8098
bcc0c096
SM
80992017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
8100
8101 * i386-linux-nat.c (fetch_register, store_register,
8102 i386_linux_fetch_inferior_registers,
8103 i386_linux_store_inferior_registers): Use ptid from regcache.
8104 * ia64-linux-nat.c (ia64_linux_fetch_register,
8105 ia64_linux_store_register): Likewise.
8106 * inf-ptrace.c (inf_ptrace_fetch_register,
8107 inf_ptrace_store_register): Likewise.
8108 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
8109 m32r_linux_store_inferior_registers): Likewise.
8110 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
8111 m68kbsd_store_inferior_registers): Likewise.
8112 * m68k-linux-nat.c (fetch_register, store_register,
8113 m68k_linux_fetch_inferior_registers,
8114 m68k_linux_store_inferior_registers): Likewise.
8115 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
8116 m88kbsd_store_inferior_registers): Likewise.
8117 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
8118 mips_fbsd_store_inferior_registers): Likewise.
8119 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
8120 mips64_linux_regsets_store_registers): Likewise.
8121 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
8122 mipsnbsd_store_inferior_registers): Likewise.
8123 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
8124 mips64obsd_store_inferior_registers): Likewise.
8125 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
8126 Likewise.
8127 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
8128 ppcfbsd_store_inferior_registers): Likewise.
8129 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
8130 ppc_linux_store_inferior_registers): Likewise.
8131 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
8132 ppcnbsd_store_inferior_registers): Likewise.
8133 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
8134 ppcobsd_store_registers): Likewise.
8135 * procfs.c (procfs_fetch_registers, procfs_store_registers):
8136 Likewise.
8137 * ravenscar-thread.c (ravenscar_fetch_registers,
8138 ravenscar_store_registers, ravenscar_prepare_to_store):
8139 Likewise.
8140 * record-btrace.c (record_btrace_fetch_registers,
8141 record_btrace_store_registers, record_btrace_prepare_to_store):
8142 Likewise.
8143 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
8144 Lookup inferior using ptid from regcache, instead of
8145 current_inferior.
8146 * remote.c (remote_fetch_registers, remote_store_registers): Use
8147 ptid from regcache.
8148 * rs6000-nat.c (fetch_register, store_register): Likewise.
8149 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
8150 s390_linux_store_inferior_registers): Likewise.
8151 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
8152 shnbsd_store_inferior_registers): Likewise.
8153 * sol-thread.c (sol_thread_fetch_registers,
8154 sol_thread_store_registers): Likewise.
8155 * sparc-nat.c (sparc_fetch_inferior_registers,
8156 sparc_store_inferior_registers): Likewise.
8157 * tilegx-linux-nat.c (fetch_inferior_registers,
8158 store_inferior_registers): Likewise.
8159 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
8160 vaxbsd_store_inferior_registers): Likewise.
8161 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
8162 store_xtregs): Likewise.
8163
c0f55cc6
AV
81642017-03-20 Artemiy Volkov <artemiyv@acm.org>
8165
8166 PR gdb/14441
8167 * NEWS: Mention support for rvalue references in GDB and python.
8168 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
8169 supports both lvalue and rvalue references.
8170
15c0a2a9
AV
81712017-03-20 Artemiy Volkov <artemiyv@acm.org>
8172
8173 PR gdb/14441
8174 * gdbtypes.c (rank_one_type): Implement overloading
8175 resolution rules regarding rvalue references.
8176
aa006118
AV
81772017-03-20 Artemiy Volkov <artemiyv@acm.org>
8178
8179 PR gdb/14441
8180 * aarch64-tdep.c (aarch64_type_align)
8181 (aarch64_extract_return_value, aarch64_store_return_value): Change
8182 lvalue reference type checks to general reference type checks.
8183 * amd64-tdep.c (amd64_classify): Likewise.
8184 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
8185 Likewise.
8186 * arm-tdep.c (arm_type_align, arm_extract_return_value)
8187 (arm_store_return_value): Likewise.
8188 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
8189 * c-typeprint.c (c_print_type): Likewise.
8190 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
8191 (cplus_number_of_children, cplus_describe_child): Likewise.
8192 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
8193 * completer.c (expression_completer): Likewise.
8194 * cp-support.c (make_symbol_overload_list_adl_namespace):
8195 Likewise.
8196 * darwin-nat-info.c (info_mach_region_command): Likewise.
8197 * dwarf2loc.c (entry_data_value_coerce_ref)
8198 (value_of_dwarf_reg_entry): Likewise.
8199 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
8200 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
8201 Likewise.
8202 * findvar.c (extract_typed_address, store_typed_address):
8203 Likewise.
8204 * gdbtypes.c (rank_one_type): Likewise.
8205 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
8206 * infcall.c (value_arg_coerce): Likewise.
8207 * language.c (pointer_type): Likewise.
8208 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
8209 Likewise.
8210 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
8211 * mn10300-tdep.c (mn10300_type_align): Likewise.
8212 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
8213 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
8214 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
8215 Likewise.
8216 * printcmd.c (print_formatted, x_command): Likewise.
8217 * python/py-type.c (typy_get_composite, typy_template_argument):
8218 Likewise.
8219 * python/py-value.c (valpy_referenced_value)
8220 (valpy_get_dynamic_type, value_has_field): Likewise.
8221 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
8222 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
8223 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
8224 * spu-tdep.c (spu_scalar_value_p): Likewise.
8225 * symtab.c (lookup_symbol_aux): Likewise.
8226 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
8227 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
8228 Likewise.
8229 * valops.c (value_cast_pointers, value_cast)
8230 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
8231 (value_struct_elt, value_struct_elt_bitpos)
8232 (value_find_oload_method_list, find_overload_match)
8233 (value_rtti_indirect_type): Likewise.
8234 * valprint.c (val_print_scalar_type_p, generic_val_print):
8235 Likewise.
8236 * value.c (value_actual_type, value_as_address, unpack_long)
8237 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
8238 (coerce_ref): Likewise.
8239 * varobj.c (varobj_get_value_type): Likewise.
8240
3fcf899d
AV
82412017-03-20 Artemiy Volkov <artemiyv@acm.org>
8242
8243 PR gdb/14441
8244 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
8245 table of constants.
8246 * python/lib/gdb/command/explore.py: Support exploring values
8247 of rvalue reference types.
8248 * python/lib/gdb/types.py: Implement get_basic_type() for
8249 rvalue reference types.
8250 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
8251 constant.
8252 * python/py-value.c (valpy_getitem): Add an rvalue reference
8253 check.
8254 (valpy_reference_value): Add new parameter "refcode".
8255 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
8256 New wrappers for valpy_reference_value().
8257 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
8258 (gdbpy_invoke_xmethod): Likewise.
8259
4297a3f0
AV
82602017-03-20 Artemiy Volkov <artemiyv@acm.org>
8261
8262 PR gdb/14441
8263 * dwarf2read.c (process_die, read_type_die_1): Handle the
8264 DW_TAG_rvalue_reference_type DIE.
8265 (read_tag_reference_type): Add new parameter "refcode".
8266
e1cb3213
AV
82672017-03-20 Artemiy Volkov <artemiyv@acm.org>
8268
8269 PR gdb/14441
8270 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
8271 (c_type_print_modifier, c_type_print_varspec_suffix)
8272 (c_type_print_base): Support printing rvalue reference types.
8273 * c-valprint.c (c_val_print, c_value_print): Support printing
8274 rvalue reference values.
8275
e4347c89
AV
82762017-03-20 Artemiy Volkov <artemiyv@acm.org>
8277
8278 PR gdb/14441
8279 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
8280 typename.
8281 * cp-support.c (replace_typedefs): Handle
8282 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
8283 * python/py-type.c (typy_lookup_type): Likewise.
8284
53cc15f5
AV
82852017-03-20 Artemiy Volkov <artemiyv@acm.org>
8286
8287 PR gdb/14441
8288 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
8289 * parse.c (insert_type): Change assert statement.
8290 (follow_types): Handle rvalue reference types.
8291 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
8292 constant.
8293
a65cfae5
AV
82942017-03-20 Artemiy Volkov <artemiyv@acm.org>
8295
8296 PR gdb/14441
8297 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
8298 value_ref() interface.
8299 * c-valprint.c (c_value_print): Likewise.
8300 * infcall.c (value_arg_coerce): Likewise.
8301 * python/py-value.c (valpy_reference_value): Likewise.
8302 * valops.c (value_cast, value_reinterpret_cast)
8303 (value_dynamic_cast, typecmp): Likewise.
8304 (value_ref): Parameterize by kind of return value reference type.
8305 * value.h (value_ref): Add new parameter "refcode".
8306
3b224330
AV
83072017-03-20 Artemiy Volkov <artemiyv@acm.org>
8308
8309 PR gdb/14441
8310 * dwarf2read.c (read_tag_reference_type): Use
8311 lookup_lvalue_reference_type() instead of lookup_reference_type().
8312 * eval.c (evaluate_subexp_standard): Likewise.
8313 * f-exp.y: Likewise.
8314 * gdbtypes.c (make_reference_type, lookup_reference_type):
8315 Generalize with rvalue reference types.
8316 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
8317 convenience wrappers for lookup_reference_type().
8318 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
8319 reference kind parameter.
8320 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
8321 wrappers for lookup_reference_type().
8322 * guile/scm-type.c (gdbscm_type_reference): Use
8323 lookup_lvalue_reference_type() instead of lookup_reference_type().
8324 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
8325 * parse.c (follow_types): Likewise.
8326 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
8327 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
8328 Likewise.
8329 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
8330 (gdbpy_invoke_xmethod): Likewise.
8331 * stabsread.c: Provide extra argument to make_reference_type()
8332 call.
8333 * valops.c (value_ref, value_rtti_indirect_type): Use
8334 lookup_lvalue_reference_type() instead of lookup_reference_type().
8335
f9aeb8d4
AV
83362017-03-20 Artemiy Volkov <artemiyv@acm.org>
8337
8338 PR gdb/14441
8339 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
8340 (TYPE_IS_REFERENCE): New macro.
8341 (struct type): Add rvalue_reference_type field.
8342 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
8343
51457a05
MAL
83442017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
8345
8346 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
8347 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
8348 New function definition.
8349 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
8350 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
8351 New function declaration.
8352 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
8353 * mi/mi-interp.h: New file.
8354 * solib.c (info_sharedlibrary_command): Replace for loop with
8355 ALL_SO_LIBS macro
8356 * solib.h (update_solib_list): New function declaration.
8357 (so_list_head): Move macro.
8358 * solist.h (ALL_SO_LIBS): New macro.
8359
e696b3ad
MAL
83602017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
8361
8362 * infcmd.c (post_create_inferior): Remove unused argument in
8363 call to solib_add.
8364 * remote.c (remote_start_remote): Likewise.
8365 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
8366 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
8367 (enable_break): Likewise.
8368 * solib.c (update_solib_list): Remove unused target argument
8369 and its documentation.
8370 (solib_add): Remove unused target argument. Remove unused
8371 argument in call to update_solib_list.
8372 (info_sharedlibrary_command): Remove unused argument in call
8373 to update_solib_list.
8374 (sharedlibrary_command): Remove unused argument in call to
8375 solib_add.
8376 (handle_solib_event): Likewise.
8377 (reload_shared_libraries): Likewise.
8378 * solib.h (solib_add): Remove unused target argument.
8379
dcb84eda
AA
83802017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
8381
8382 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
8383 (s390_displaced_step_fixup): Cover relative branches with the
8384 default fixup handling. This fixes lack of support for some
8385 relative branch instructions.
8386
d9cb6cdc
SM
83872017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
8388
8389 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
8390 ptid from regcache.
8391
1afaf9f4
SM
83922017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
8393
8394 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
8395 i386_darwin_store_inferior_registers): Use ptid from regcache.
8396
aac12e24
SM
83972017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
8398
8399 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
8400 i386bsd_store_inferior_registers): Use ptid from regcache.
8401
bbe1eef1
SM
84022017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
8403
8404 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
8405 hppaobsd_store_registers): Use ptid from regcache.
8406
10799020
SM
84072017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
8408
8409 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
8410 hppanbsd_store_registers): Use ptid from regcache.
8411
00204cf7
SM
84122017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
8413
8414 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
8415 from regcache. Use get_ptrace_pid.
8416
11a33714
SM
84172017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
8418
8419 * corelow.c (get_core_register_section): Use ptid from regcache,
8420 update doc.
8421
317cd492
SM
84222017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
8423
8424 * bsd-uthread.c (bsd_uthread_fetch_registers,
8425 bsd_uthread_store_registers): Use ptid from regcache, set and
8426 restore inferior_ptid.
8427
9ac8a7c2
SM
84282017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
8429
8430 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
8431 fetch_fp_regs, store_register, store_regs, store_fp_register,
8432 store_fp_regs): Use ptid from regcache.
8433
4ac4bb6a
SM
84342017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
8435
8436 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
8437 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
8438 store_vfp_regs): Use ptid from regcache.
8439
9bcbdca8
PA
84402017-03-17 Pedro Alves <palves@redhat.com>
8441
8442 PR remote/21188
8443 * ser-base.c (ser_base_wait_for): Add comment.
8444 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
8445 version.
8446 * ser-unix.c (hardwire_raw): Remove reference to
8447 scb->current_timeout.
8448 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
8449 (hardwire_ops): Install ser_base_readchar instead of
8450 hardwire_readchar.
8451 * serial.h (struct serial) <current_timeout, timeout_remaining>:
8452 Remove fields.
8453
7503099f
JG
84542017-03-17 Jonah Graham <jonah@kichwacoders.com>
8455
8456 PR gdb/19637
8457 * python/lib/gdb/printer/bound_registers.py: Add support for
8458 Python 3.
8459
7942e96e
AA
84602017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
8461
8462 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
8463 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
8464 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
8465 byte_offset to subobj_byte_offset. Fix the handling of
8466 DWARF_VALUE_STACK on big-endian targets when coming via an
8467 implicit pointer.
8468 (dwarf2_evaluate_loc_desc): Adjust call to
8469 dwarf2_evaluate_loc_desc_full.
8470 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
8471 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
8472
ba14f379
YQ
84732017-03-16 Yao Qi <yao.qi@linaro.org>
8474
8475 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
8476 and REVSH instructions.
8477
b121eeb9
YQ
84782017-03-16 Yao Qi <yao.qi@linaro.org>
8479
8480 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
8481 (arm_record_test): Declare.
8482 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
8483 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
8484 align with the manual.
8485 (thumb_record_misc): Adjust the code order to align with the
8486 manual.
8487 (thumb2_record_decode_insn_handler): Fix instruction matching.
8488 (instruction_reader_thumb): New class.
8489 (arm_record_test): New function.
8490
728a7913
YQ
84912017-03-16 Yao Qi <yao.qi@linaro.org>
8492
8493 * arm-tdep.c (abstract_memory_reader): New class.
8494 (instruction_reader): New class.
8495 (extract_arm_insn): Add argument 'reader'. Callers updated.
8496 (decode_insn): Likewise.
8497
34b43320
DE
84982017-03-16 Doug Evans <dje@google.com>
8499
a7c0469f
DE
8500 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
8501 member. Change type of TYPE member to SCM. All uses updated.
8502 (lsscm_make_lazy_string_smob): Add assert.
8503 (lsscm_make_lazy_string): Flag bad length values.
8504 (lsscm_elt_type): New function.
8505 (gdbscm_lazy_string_to_value): Rewrite to use
8506 lsscm_safe_lazy_string_to_value.
8507 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
8508 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
8509 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
8510 in incoming type.
8511 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
8512 * guile/scm-type.c (tyscm_scm_to_type): New function.
8513
85142017-03-15 Doug Evans <dje@google.com>
8515
34b43320
DE
8516 PR python/17728, python/18439, python/18779
8517 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
8518 member. Change type of TYPE member to PyObject *. All uses updated.
8519 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
8520 (gdbpy_create_lazy_string_object): Flag bad length values.
8521 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
8522 Handle typedefs in incoming type.
8523 (stpy_lazy_string_elt_type): New function.
8524 (gdbpy_extract_lazy_string): Call it.
8525 * python/py-value.c (valpy_lazy_string): Flag bad length values.
8526 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
8527 typedefs in incoming type.
8528
a3a5fecc
DE
85292017-03-16 Doug Evans <dje@google.com>
8530
8531 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
8532 * guile/scm-type.c (tyscm_scm_to_type): New function.
8533
28f1c605
JW
85342017-03-16 Jiong Wang <jiong.wang@arm.com>
8535
8536 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
8537 "ULONGEST" for "skip".
8538
87c336f6
AA
85392017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
8540
8541 PR gdb/21220
8542 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
8543 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
8544 (inf_ptrace_peek_poke): ...here. New function. Now also loop
8545 over ptrace peek/poke until end of buffer or error.
8546
cf81cf60
SM
85472017-03-14 Simon Marchi <simon.marchi@ericsson.com>
8548
8549 * parse.c (length_of_subexp): Make static.
8550 * parser-defs.h (length_of_subexp): Remove.
8551
a379284a
AA
85522017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
8553
8554 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
8555 as well.
8556
8a6200ba
PA
85572017-03-14 Pedro Alves <palves@redhat.com>
8558
8559 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
8560 (main): Use std::unique_ptr. Remove calls to
8561 cp_demangled_name_parse_free.
8562
f79ec206
SM
85632017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
8564
8565 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
8566 alphabsd_store_inferior_registers): Use regcache->ptid instead
8567 of inferior_ptid.
8568
edb5fb00
SM
85692017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
8570
8571 * aix-thread.c (aix_thread_fetch_registers,
8572 aix_thread_store_registers): Use regcache->ptid instead of
8573 inferior_ptid.
8574
55119686
SM
85752017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
8576
8577 * aarch64-linux-nat.c (fetch_gregs_from_thread,
8578 store_gregs_to_thread, fetch_fpregs_from_thread,
8579 store_fpregs_to_thread): Use regcache->ptid instead of
8580 inferior_ptid.
8581
6a06fbb7
SM
85822017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
8583
8584 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
8585 amd64_linux_fetch_inferior_registers): Use regcache->ptid
8586 instead of inferior_ptid.
8587
c6386875
SM
85882017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
8589
8590 * target.c (target_fetch_registers, target_store_registers): Add
8591 assert.
8592
ddaaf0fb
SM
85932017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
8594
8595 * regcache.h (regcache_get_ptid): New function.
8596 * regcache.c (regcache_get_ptid): New function.
8597
b9da89d1 85982017-03-13 Mark Wielaard <mark@klomp.org>
8599
8600 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
8601
5f4d1085
KS
86022017-03-10 Keith Seitz <keiths@redhat.com>
8603
8604 PR c++/8218
8605 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
8606
c65d6b55
PA
86072017-03-08 Pedro Alves <palves@redhat.com>
8608
8609 PR gdb/18360
8610 * infrun.c (start_step_over, do_target_resume, resume)
8611 (restart_threads): Assert we're not resuming a thread that is
8612 meant to be stopped.
8613 (infrun_thread_stop_requested_callback): Delete.
8614 (infrun_thread_stop_requested): If the thread is internally
8615 stopped, queue a pending stop event and clear the thread's
8616 inline-frame state.
8617 (handle_stop_requested): New function.
8618 (handle_syscall_event, handle_inferior_event_1): Use
8619 handle_stop_requested.
8620 (handle_stop_requested): New function.
8621 (handle_signal_stop): Set the thread's stop_signal here instead of
8622 at caller.
8623 (finish_step_over): Clear step over info unconditionally.
8624 (handle_signal_stop): If the user had interrupted the event
8625 thread, consider the stop a random signal.
8626 (handle_signal_stop) <signal arrived while stepping over
8627 breakpoint>: Don't restart threads here.
8628 (stop_waiting): Don't clear step-over info here.
8629
15c22686
PA
86302017-03-08 Pedro Alves <palves@redhat.com>
8631
8632 PR 21206
8633 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
8634 goes to argument 2, not 1.
8635
6e5d74e7
PA
86362017-03-08 Pedro Alves <palves@redhat.com>
8637
8638 PR cli/21218
8639 * top.c (gdb_readline_wrapper): Avoid passing NULL to
8640 display_gdb_prompt.
8641 (command_line_input): Add comment.
8642
9753a2f6
PA
86432017-03-08 Pedro Alves <palves@redhat.com>
8644
8645 PR tui/21216
8646 * tui/tui-file.c (tui_file::write): New.
8647 * tui/tui-file.h (tui_file): Override "write".
8648 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
8649 factored out from ...
8650 (tui_puts): ... here.
8651 (tui_putc): Use them.
8652 (tui_write): New function.
8653 * tui/tui-io.h (tui_write): Declare.
8654
1672e0d9
SDJ
86552017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
8656
8657 * Makefile.in (SFILES): Replace "environ.c" with
8658 "common/environ.c".
8659 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
8660 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
8661 to...
8662 * common/environ.c: ... here.
8663 * environ.h: Moved to...
8664 * common/environ.h: ... here.
8665
f7bb4e3a
PB
86662017-03-07 Peter Bergner <bergner@vnet.ibm.com>
8667
8668 * gdbarch.sh (pstring_ptr): New static function.
8669 (gdbarch_disassembler_options): Use it.
8670 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
8671 not valid_disassembler_option->name.
8672 * gdbarch.c: Regenerate.
8673
e45ced6c
PB
86742017-03-07 Peter Bergner <bergner@vnet.ibm.com>
8675
8676 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
8677
5f6fd321
PA
86782017-03-07 Pedro Alves <palves@redhat.com>
8679
8680 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
8681
6dbb839a 86822017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
4a612d6f
WT
8683
8684 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
8685 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
8686 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
6dbb839a 8687 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
4a612d6f 8688
d274ecf4
SM
86892017-03-06 Simon Marchi <simon.marchi@ericsson.com>
8690
8691 * xtensa-linux-nat.c (fetch_gregs): Remove const.
8692
df97be55
SM
86932017-03-03 Simon Marchi <simon.marchi@ericsson.com>
8694
8695 * remote.c (remote_add_target_side_commands): Use range-based
8696 for loop.
8697
7d45f3df
YQ
86982017-03-03 Yao Qi <yao.qi@linaro.org>
8699
8700 PR gdb/21165
8701 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
8702 value is lazy.
8703 * valprint.c (common_val_print): Likewise.
8704
65b48a81
PB
87052017-02-28 Peter Bergner <bergner@vnet.ibm.com>
8706
8707 * NEWS: Mention new set/show disassembler-options commands.
8708 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
8709 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
8710 (prospective_options): New static variable.
8711 (gdb_disassembler::gdb_disassembler): Initialize
8712 m_di.disassembler_options.
8713 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
8714 (get_disassembler_options): New function.
8715 (set_disassembler_options): Likewise.
8716 (set_disassembler_options_sfunc): Likewise.
8717 (show_disassembler_options_sfunc): Likewise.
8718 (disassembler_options_completer): Likewise.
8719 (_initialize_disasm): Likewise.
8720 * disasm.h (get_disassembler_options): New prototype.
8721 (set_disassembler_options): Likewise.
8722 * gdbarch.sh (gdbarch_disassembler_options): New variable.
8723 (gdbarch_verify_disassembler_options): Likewise.
8724 * gdbarch.c: Regenerate.
8725 * gdbarch.h: Likewise.
8726 * arm-tdep.c (num_disassembly_options): Delete.
8727 (set_disassembly_style): Likewise.
8728 (arm_disassembler_options): New static variable.
8729 (set_disassembly_style_sfunc): Convert short style name into long
8730 option name. Call set_disassembler_options.
8731 (show_disassembly_style_sfunc): New function.
8732 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
8733 set_gdbarch_verify_disassembler_options.
8734 (_initialize_arm_tdep): Delete regnames variable and update callers.
8735 (arm_disassembler_options): Initialize.
8736 (disasm_options): New variable.
8737 (num_disassembly_options): Rename from this...
8738 (num_disassembly_styles): ...to this. Compute by scanning through
8739 disasm_options.
8740 (valid_disassembly_styles): Initialize using disasm_options.
8741 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
8742 set_arm_regname_option.
8743 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
8744 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
8745 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
8746 set_gdbarch_verify_disassembler_options.
8747 * s390-tdep.c (s390_disassembler_options): New static variable.
8748 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
8749 set_gdbarch_verify_disassembler_options.
8750
d538e36d
SM
87512017-02-27 Simon Marchi <simon.marchi@ericsson.com>
8752
8753 * remote.c (remote_add_target_side_condition): Remove "struct"
8754 keyword from range-based for loop.
8755
83621223
SM
87562017-02-27 Simon Marchi <simon.marchi@ericsson.com>
8757
8758 * remote.c (remote_add_target_side_condition): Use range-based
8759 for loop. Update comment.
8760
2123df0e
YQ
87612017-02-27 Yao Qi <yao.qi@linaro.org>
8762
8763 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
8764
8e368124
AH
87652017-02-26 Alan Hayward <alan.hayward@arm.com>
8766
8767 * regcache.c (regcache_raw_update): New function.
8768 (regcache_raw_read): Move code to regcache_raw_update.
8769 * regcache.h (regcache_raw_update): New declaration.
8770 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
8771
a49dd8dd
JK
87722017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
8773
8774 * dwarf2read.c (create_debug_type_hash_table): Initialize
8775 header.signature and header.type_offset_in_tu.
8776
34e4bae9
PA
87772017-02-24 Pedro Alves <palves@redhat.com>
8778
8779 * symtab.c (make_file_symbol_completion_list_1): Use
8780 add_symtab_completions.
8781
b0e4b369
AH
87822017-02-24 Alan Hayward <alan.hayward@arm.com>
8783
8784 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
8785
975c21ab
AH
87862017-02-24 Alan Hayward <alan.hayward@arm.com>
8787
8788 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
8789 I386_MAX_REGISTER_SIZE.
8790 (i386_pseudo_register_write): Likewise.
8791 (i386_process_record): Likewise.
8792 * i387-tdep.c (i387_supply_xsave): Likewise.
8793 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
8794 (store_register): Likewise.
8795
14bc53a8
PA
87962017-02-23 Pedro Alves <palves@redhat.com>
8797
8798 * ada-lang.c: Include "common/function-view.h".
8799 (ada_iterate_over_symbols): Adjust to use function_view as
8800 callback type.
8801 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
8802 (ada_make_symbol_completion_list): Use a lambda.
8803 (ada_exc_search_name_matches): Delete.
8804 (name_matches_regex): New.
8805 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
8806 * compile/compile-c-support.c: Include "common/function-view.h".
8807 (print_one_macro): Change prototype to accept a ui_file pointer.
8808 (write_macro_definitions): Use a lambda.
8809 * dwarf2read.c: Include "common/function-view.h".
8810 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
8811 (dw2_expand_symtabs_matching): Adjust to use function_view as
8812 callback type.
8813 * language.h: Include "common/function-view.h".
8814 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
8815 function_view as callback type.
8816 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
8817 * linespec.c: Include "common/function-view.h".
8818 (collect_info::add_symbol): New method.
8819 (struct symbol_and_data_callback, iterate_inline_only, struct
8820 symbol_matcher_data, iterate_name_matcher): Delete.
8821 (iterate_over_all_matching_symtabs): Adjust to use function_view
8822 as callback type and lambdas.
8823 (iterate_over_file_blocks): Adjust to use function_view as
8824 callback type.
8825 (decode_compound_collector): Now a class with private fields.
8826 (decode_compound_collector::release_symbols): New method.
8827 (collect_one_symbol): Rename to...
8828 (decode_compound_collector::operator()): ... this and adjust.
8829 (lookup_prefix_sym): decode_compound_collector construction bits
8830 move to decode_compound_collector ctor. Pass the
8831 decode_compound_collector object directly as callback. Remove
8832 cleanups and use decode_compound_collector::release_symbols
8833 instead.
8834 (symtab_collector): Now a class with private fields.
8835 (symtab_collector::release_symtabs): New method.
8836 (add_symtabs_to_list): Rename to...
8837 (symtab_collector::operator()): ... this and adjust.
8838 (collect_symtabs_from_filename): symtab_collector construction
8839 bits move to symtab_collector ctor. Pass the symtab_collector
8840 object directly as callback. Remove cleanups and use
8841 symtab_collector::release_symtabs instead.
8842 (collect_symbols): Delete.
8843 (add_matching_symbols_to_info): Use lambdas.
8844 * macrocmd.c (print_macro_callback): Delete.
8845 (info_macro_command): Use a lambda.
8846 (info_macros_command): Pass print_macro_definition as callable
8847 directly.
8848 (print_one_macro): Remove 'ignore' parameter.
8849 (macro_list_command): Adjust.
8850 * macrotab.c (macro_for_each_data::fn): Now a function_view.
8851 (macro_for_each_data::user_data): Delete field.
8852 (foreach_macro): Adjust to call the function_view.
8853 (macro_for_each): Adjust to use function_view as callback type.
8854 (foreach_macro_in_scope): Adjust to call the function_view.
8855 (macro_for_each_in_scope): Adjust to use function_view as callback
8856 type.
8857 * macrotab.h: Include "common/function-view.h".
8858 (macro_callback_fn): Declare a prototype instead of a pointer.
8859 Remove "user_data" parameter.
8860 (macro_for_each, macro_for_each_in_scope): Adjust to use
8861 function_view as callback type.
8862 * psymtab.c (partial_map_expand_apply)
8863 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
8864 Adjust to use function_view as callback type and to return bool.
8865 (psym_expand_symtabs_matching): Adjust to use function_view as
8866 callback types.
8867 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
8868 to use function_view as callback type and to return bool.
8869 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
8870 callback types.
8871 * symfile.c (expand_symtabs_matching): Adjust to use function_view
8872 as callback types.
8873 * symfile.h: Include "common/function-view.h".
8874 (expand_symtabs_file_matcher_ftype)
8875 (expand_symtabs_symbol_matcher_ftype)
8876 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
8877 return bool.
8878 (quick_symbol_functions::map_symtabs_matching_filename)
8879 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
8880 function_view as callback type and return bool.
8881 (expand_symtabs_matching): Adjust to use function_view as callback
8882 type.
8883 (maintenance_expand_name_matcher)
8884 (maintenance_expand_file_matcher): Delete.
8885 (maintenance_expand_symtabs): Use lambdas.
8886 * symtab.c (iterate_over_some_symtabs): Adjust to use
8887 function_view as callback types and return bool.
8888 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
8889 of a cleanup.
8890 (lookup_symtab_callback): Delete.
8891 (lookup_symtab): Use a lambda.
8892 (iterate_over_symbols): Adjust to use function_view as callback
8893 type.
8894 (struct search_symbols_data, search_symbols_file_matches)
8895 (search_symbols_name_matches): Delete.
8896 (search_symbols): Use a pair of lambdas.
8897 (struct add_name_data, add_macro_name, symbol_completion_matcher)
8898 (symtab_expansion_callback): Delete.
8899 (default_make_symbol_completion_list_break_on_1): Use lambdas.
8900 * symtab.h: Include "common/function-view.h".
8901 (iterate_over_some_symtabs): Adjust to use function_view as
8902 callback type and return bool.
8903 (iterate_over_symtabs): Adjust to use function_view as callback
8904 type.
8905 (symbol_found_callback_ftype): Remove 'data' parameter and return
8906 bool.
8907 (iterate_over_symbols): Adjust to use function_view as callback
8908 type.
8909
07e253aa
PA
89102017-02-23 Pedro Alves <palves@redhat.com>
8911
8912 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
8913 (%.o) <unittests/%.c>: New pattern.
8914 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
8915 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
8916 * common/function-view.h: New file.
8917 * unittests/function-view-selftests.c: New file.
8918 * configure: Regenerate.
8919
8eaf5320
SM
89202017-02-23 Simon Marchi <simon.marchi@ericsson.com>
8921
8922 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
8923 inferior_ptid.
8924 * go32-nat.c (go32_thread_alive): Likewise.
8925
38768751
YQ
89262017-02-23 Yao Qi <yao.qi@linaro.org>
8927
8928 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
8929 delete.
8930
0a8beaba
YQ
89312017-02-23 Yao Qi <yao.qi@linaro.org>
8932
8933 * varobj.c (varobj_clear_saved_item): Use delete instead of
8934 xfree.
8935 (update_dynamic_varobj_children): Likewise.
8936
58fdfd2c
JK
89372017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
8938
8939 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
8940
1b90b139
SM
89412017-02-21 Simon Marchi <simon.marchi@ericsson.com>
8942
8943 * common/enum-flags.h (enum_flags::enum_flags): Initialize
8944 m_enum_value to 0 in default constructor.
8945
2039d74e
EBM
89462017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
8947
8948 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
8949 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
8950 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
8951 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
8952 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
8953 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
8954 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
8955 IS_STORE_CONDITIONAL_INSN.
8956
7814882a
JK
89572017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
8958
8959 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
8960
0ae60b63
JK
89612017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
8962
8963 * NEWS (Changes since GDB 7.12): Add DWARF-5.
8964
0224619f
JK
89652017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
8966
8967 * dwarf2read.c (skip_one_die, read_attribute_value)
8968 (dwarf2_const_value_attr, dump_die_shallow)
8969 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
8970 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
8971
0af92d60
JK
89722017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
8973
8974 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
8975 (dwarf_parse_macro_header): Accept DWARF version 5.
8976 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
8977
216f72a1
JK
89782017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
8979
8980 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
8981 DW_AT_GNU_*.
8982 * common/common-exceptions.h (enum errors): Likewise.
8983 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
8984 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
8985 (dwarf_expr_context::execute_stack_op): Likewise.
8986 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
8987 Likewise.
8988 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
8989 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
8990 (show_entry_values_debug, call_site_to_target_addr)
8991 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
8992 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
8993 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
8994 (value_of_dwarf_block_entry, indirect_pieced_value)
8995 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
8996 (disassemble_dwarf_expression): Likewise.
8997 * dwarf2read.c (process_die, inherit_abstract_dies)
8998 (read_call_site_scope): Likewise.
8999 * gdbtypes.h (struct func_type, struct call_site_parameter)
9000 (struct call_site): Likewise.
9001 * stack.c (read_frame_arg): Likewise.
9002 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
9003
43988095
JK
90042017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
9005
9006 * defs.h (read_unsigned_leb128): New declaration.
9007 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
9008 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
9009 (dwarf2_find_location_expression): Call also
9010 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
9011 * dwarf2loc.h (dwarf2_version): New declaration.
9012 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
9013 rnglists.
9014 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
9015 .debug_rnglists.
9016 (struct dwop_section_names): Add loclists_dwo.
9017 (dwop_section_names): Add .debug_loclists.dwo.
9018 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
9019 (struct dwarf2_per_cu_data): Add dwarf_version.
9020 (struct dwo_sections): Add loclists.
9021 (struct attr_abbrev): Add implicit_const.
9022 (read_indirect_line_string): New declaration.
9023 (read_unsigned_leb128): Delete declaration.
9024 (rcuh_kind): New definition.
9025 (read_and_check_comp_unit_head): Change parameter
9026 is_debug_types_section to section_kind.
9027 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
9028 (read_comp_unit_head): Change parameter abfd to section, add parameter
9029 section_kind. Handle DWARF-5.
9030 (error_check_comp_unit_head): Accept also DWARF version 5.
9031 (read_and_check_comp_unit_head): Change parameter
9032 is_debug_types_section to section_kind.
9033 (read_and_check_type_unit_head): Delete function.
9034 (read_abbrev_offset): Handle DWARF-5.
9035 (create_debug_type_hash_table): Add parameter section_kind. Process
9036 only DW_UT_type. Use signature and type_offset_in_tu from struct
9037 comp_unit_head.
9038 (create_debug_types_hash_table): Update create_debug_type_hash_table
9039 caller.
9040 (create_all_type_units): Call create_debug_type_hash_table.
9041 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
9042 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
9043 caller.
9044 (skip_one_die): Handle DW_FORM_implicit_const.
9045 (dwarf2_rnglists_process): New function.
9046 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
9047 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
9048 (read_attribute_value): Handle DW_FORM_implicit_const,
9049 DW_FORM_line_strp.
9050 (read_attribute): Handle DW_FORM_implicit_const.
9051 (read_indirect_string_at_offset_from): New function from
9052 read_indirect_string_at_offset.
9053 (read_indirect_string_at_offset): Call
9054 read_indirect_string_at_offset_from.
9055 (read_indirect_line_string_at_offset): New function.
9056 (read_indirect_string): New function comment.
9057 (read_indirect_line_string): New function.
9058 (read_unsigned_leb128): Make it global.
9059 (dwarf2_string_attr): Handle DWARF-5.
9060 (add_include_dir_stub, read_formatted_entries): New functions.
9061 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
9062 Handle DWARF-5.
9063 (per_cu_header_read_in): Update read_comp_unit_head caller.
9064 (dwarf2_version): New function.
9065 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
9066 rnglists.
9067 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
9068 fields.
9069
22d2f3ab
JK
90702017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
9071
9072 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
9073
5f46c5a5
JK
90742017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
9075
9076 * dwarf2read.c (dwarf2_ranges_process): New function from
9077 dwarf2_ranges_read.
9078 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
9079 dwarf2_ranges_process.
9080
78d4d2c5
JK
90812017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
9082
9083 * dwarf2read.c (create_debug_type_hash_table): New function from
9084 create_debug_types_hash_table.
9085 (create_debug_types_hash_table): Call create_debug_type_hash_table.
9086 (create_all_type_units, open_and_init_dwo_file): Update
9087 create_debug_types_hash_table callers.
9088
1b076f25
SDJ
90892017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
9090
9091 PR gdb/16188
9092 * fork-child.c (trace_start_error): Fix thinko. va_end should
9093 refer to 'ap', not 'args'.
9094
0db8980c
SDJ
90952017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
9096 Pedro Alves <palves@redhat.com>
9097
9098 PR gdb/16188
9099 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
9100 calls succeeded.
9101 * fork-child.c (trace_start_error): New function.
9102 (trace_start_error_with_name): Likewise.
9103 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
9104 * inf-ptrace.c (inf_ptrace_me): Likewise.
9105 * inferior.h (trace_start_error): New prototype.
9106 (trace_start_error_with_name): Likewise.
9107
99e8a4f9
SDJ
91082017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
9109
9110 PR gdb/21164
9111 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
9112 NULL before using it.
9113 * symmisc.c (maintenance_print_symbols): Likewise.
9114 (maintenance_print_msymbols): Likewise.
9115
4e746bb6
TW
91162017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
9117
9118 * NEWS: Add record Python bindings entry.
9119
91202017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
9121
9122 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
9123 py-record-full.o.
9124 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
9125 * python/py-record-btrace.c, python/py-record-btrace.h,
9126 python/py-record-full.c, python/py-record-full.h: New file.
9127 * python/py-record.c: Add include for py-record-btrace.h and
9128 py-record-full.h.
9129 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
9130 recpy_instruction_history, recpy_function_call_history, recpy_begin,
9131 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
9132 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
9133 New definition.
9134 (gdbpy_initialize_btrace): New export.
9135 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
9136
91372017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
9138
9139 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
9140 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
9141 * python/py-record.c: New file.
9142 * python/python-internal.h (gdbpy_start_recording,
9143 gdbpy_current_recording, gdpy_stop_recording,
9144 gdbpy_initialize_record): New export.
9145 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
9146 (python_GdbMethods): Add gdbpy_start_recording,
9147 gdbpy_current_recording and gdbpy_stop_recording.
9148
91492017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
9150
9151 * record-btrace.c (record_btrace_record_method): New function.
9152 (init_record_btrace_ops): Initialize to_record_method.
9153 * record-full.c (record_full_record_method): New function.
9154 (init_record_full_ops, init_record_full_core_ops): Add
9155 record_full_record_method.
9156 * record.h (enum record_method): New enum.
9157 * target-debug.h (target_debug_print_enum_record_method: New define.
9158 * target-delegates.c: Regenerate.
9159 * target.c (target_record_method): New function.
9160 * target.h: Include record.h.
9161 (struct target_ops) <to_record_method>: New field.
9162 (target_record_method): New export.
9163
91642017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
9165
9166 * record.h (record_start, record_stop): New export.
9167 * record.c (record_start, record_stop): New function.
9168
91692017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
9170
9171 * btrace.c (btrace_fetch): Copy function call segments pointer
9172 into a vector.
9173 (btrace_clear): Clear the vector.
9174 (btrace_find_insn_by_number): Use binary search to find the correct
9175 function call segment.
9176 * btrace.h (brace_fun_p): New typedef.
9177 (struct btrace_thread_info) <functions>: New field.
9178
91792017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
9180
9181 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
9182 * btrace.c (btrace_decode_error): ... here. New function.
9183 * btrace.h (btrace_decode_error): New export.
9184
91852017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
9186
9187 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
9188 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
9189 btrace_find_insn_by_number): Remove special case for gaps.
9190 * btrace.h (btrace_insn_get_error): New export.
9191 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
9192 * record-btrace.c (btrace_insn_history): Print number for gaps.
9193 (record_btrace_info, record_btrace_goto): Handle gaps.
9194
3f77c769
TT
91952017-02-14 Tom Tromey <tom@tromey.com>
9196
9197 PR python/13598:
9198 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
9199 event.
9200 * python/py-evts.c (gdbpy_initialize_py_events): Add
9201 before_prompt registry.
9202 * python/py-events.h (events_object) <before_prompt>: New field.
9203
4c2c7ac6
MM
92042017-02-14 Markus Metzger <markus.t.metzger@intel.com>
9205
9206 * btrace.c (ftrace_new_switch): Preserve up link and flags.
9207
5cf30ebf
LM
92082017-02-13 Luis Machado <lgustavo@codesourcery.com>
9209
9210 * symfile (_initialize_symfile): Add usage text to the load command's
9211 help text.
9212
26a06916
SM
92132017-02-10 Simon Marchi <simon.marchi@ericsson.com>
9214
9215 * utils.c (defaulted_query): Don't query on secondary UIs.
9216
0b145e37
TT
92172017-02-10 Tom Tromey <tom@tromey.com>
9218
9219 * rust-lang.c (rust_get_disr_info): Remove unused variable.
9220
2d8365c4
TT
92212017-02-10 Tom Tromey <tom@tromey.com>
9222
9223 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
9224 "cleanup" local.
9225 * python/py-type.c (typy_legacy_template_argument): Remove
9226 unnecessary "cleanup" local.
9227
2bb8f231
TT
92282017-02-10 Tom Tromey <tom@tromey.com>
9229
9230 * python/python.c (do_start_initialization): New function, from
9231 _initialize_python.
9232 (_initialize_python): Call do_start_initialization.
9233 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
9234 goto.
9235
1bdfaf42
TT
92362017-02-10 Tom Tromey <tom@tromey.com>
9237
9238 * python/py-prettyprint.c (pretty_print_one_value): Use
9239 gdbpy_ref.
9240
88b6faea
TT
92412017-02-10 Tom Tromey <tom@tromey.com>
9242
9243 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
9244 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
9245 gdbpy_ref.
9246 * python/py-type.c (field_new): Use gdbpy_ref.
9247 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
9248 gdbpy_ref.
9249 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
9250 (py_free_pspace): Likewise.
9251 (pspace_to_pspace_object): Likewise.
9252 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
9253 (py_free_objfile): Likewise.
9254 (objfile_to_objfile_object): Likewise.
9255 * python/py-inferior.c (delete_thread_object): Use
9256 gdbpy_ref.
9257 (infpy_read_memory): Likewise.
9258 (py_free_inferior): Likewise.
9259 * python/py-evtregistry.c (create_eventregistry_object): Use
9260 gdbpy_ref.
9261 * python/py-event.c (create_event_object): Use gdbpy_ref.
9262
7780f186
TT
92632017-02-10 Tom Tromey <tom@tromey.com>
9264
9265 * python/py-ref.h (gdbpy_ref_policy): Now a template.
9266 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
9267 used.
9268 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
9269 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
9270 python/py-exitedevent.c, python/py-finishbreakpoint.c,
9271 python/py-framefilter.c, python/py-function.c,
9272 python/py-inferior.c, python/py-infevents.c,
9273 python/py-linetable.c, python/py-newobjfileevent.c,
9274 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
9275 python/py-signalevent.c, python/py-stopevent.c,
9276 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
9277 python/py-unwind.c, python/py-utils.c, python/py-value.c,
9278 python/py-varobj.c, python/py-xmethods.c, python/python.c,
9279 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
9280
d4b0bb18
TT
92812017-02-10 Tom Tromey <tom@tromey.com>
9282
9283 * ui-out.h (ui_out_emit_type): New class.
9284 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
9285 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
9286 and ui_out_emit_tuple.
9287 (enumerate_locals): Likewise.
9288 (py_mi_print_variables, py_print_locals, py_print_args): Use
9289 ui_out_emit_list.
9290 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
9291 ui_out_emit_list.
9292 * common/gdb_optional.h: New file.
9293
f67f945c
MG
92942017-02-10 Martin Galvan <martingalvan@sourceware.org>
9295
9296 * MAINTAINERS (Write After Approval): Update my e-mail address.
9297
18da0c51
MG
92982017-02-10 Martin Galvan <martingalvan@sourceware.org>
9299
9300 PR gdb/21122
9301 * breakpoint.c (_initialize_breakpoint): Update the help description
9302 of the 'commands' command to indicate that it takes a list argument.
9303
62c14536
SM
93042017-02-09 Simon Marchi <simon.marchi@ericsson.com>
9305
9306 * interps.c (current_interp_set_logging): Remove "return".
9307
ff6fa247
GB
93082017-02-09 Gary Benson <gbenson@redhat.com>
9309
9310 * symtab.c (add_symtab_completions): Prevent NULL pointer
9311 dereference.
9312
a474bd8e
PA
93132017-02-08 Pedro Alves <palves@redhat.com>
9314
9315 * interps.c (interp::interp): Remove reference to quiet_p.
9316 (interp_set): Make static. Remove dead "Switching to" output
9317 code.
9318 (interp_quiet_p, interp_set_quiet): Delete.
9319 (interpreter_exec_cmd): Don't set the interpreter quiet.
9320 * interps.h (interp_quiet_p): Make static.
9321 (class interp) <quiet_p>: Remove field
9322
3d7b173c
JG
93232017-02-08 Jerome Guitton <guitton@adacore.com>
9324
604c4576
JG
9325 * cli/cli-decode.c (find_command_name_length): Make it extern.
9326 * cli/cli-decode.h (find_command_name_length): Declare.
9327 * cli/cli-script.c (command_name_equals, line_first_arg):
9328 New functions.
9329 (process_next_line): Use cli-decode to parse command names.
9330 (build_command_line): Make args a constant pointer.
9331
93322017-02-08 Jerome Guitton <guitton@adacore.com>
6dbb839a 9333
3d7b173c
JG
9334 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
9335 Remove case-insensitive search.
9336
1291063d
JM
93372017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
9338
9339 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
9340 at the end of the line. Avoids an ARI warning.
9341
20b477a7
LM
93422017-02-06 Luis Machado <lgustavo@codesourcery.com>
9343
9344 * NEWS: Mention support for record/replay of Intel 64 rdrand and
9345 rdseed instructions.
9346 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
9347
3f7b46f2
IR
93482017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
9349
9350 PR tdep/20936
9351 Provide and use sparc32 and sparc64 target description XML files.
9352 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
9353 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
9354 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
9355 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
9356 * features/sparc/sparc32-solaris.xml: New file.
9357 * features/sparc/sparc64-solaris.xml: New file.
9358 * features/sparc/sparc32-solaris.c: Generated.
9359 * features/sparc/sparc64-solaris.c: Generated.
9360 * sparc-tdep.h: Account for differences in target descriptions.
9361 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
9362 (sparc32_register_type): Use target provided registers.
9363 (validate_tdesc_registers): New function.
9364 (sparc32_gdbarch_init): Use tdesc_has_registers.
9365 Set pseudoregister functions.
9366 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
9367 (sparc64_register_type): Use target provided registers.
9368 (sparc64_init_abi): Set pseudoregister functions.
9369
f0fd41c1
TT
93702017-02-03 Tom Tromey <tom@tromey.com>
9371
9372 PR rust/21097:
9373 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
9374 with a single member.
9375
d6f9b0fb
PA
93762017-02-03 Pedro Alves <palves@redhat.com>
9377
9378 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
9379 (cli_interp_base::~cli_interp_base): New.
9380 (cli_interp): New struct.
9381 (as_cli_interp): Cast the interp itself to cli_interp.
9382 (cli_interpreter_pre_command_loop): Rename to ...
9383 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
9384 parameter.
9385 (cli_interpreter_init): Rename to ...
9386 (cli_interp::init): ... this. Remove 'self' parameter. Use
9387 boolean. Make extern.
9388 (cli_interpreter_resume): Rename to ...
9389 (cli_interp::resume): ... this. Remove 'data' parameter. Make
9390 extern.
9391 (cli_interpreter_suspend): Rename to ...
9392 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
9393 extern.
9394 (cli_interpreter_exec): Rename to ...
9395 (cli_interp::exec): ... this. Remove 'data' parameter. Make
9396 extern.
9397 (cli_interpreter_supports_command_editing): Rename to ...
9398 (cli_interp_base::supports_command_editing): ... this. Remove
9399 'interp' parameter. Make extern.
9400 (cli_ui_out): Rename to ...
9401 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
9402 Make extern.
9403 (cli_set_logging): Rename to ...
9404 (cli_interp_base::set_logging): ... this. Remove 'interp'
9405 parameter. Make extern.
9406 (cli_interp_procs): Delete.
9407 (cli_interp_factory): Adjust to use "new".
9408 * cli/cli-interp.h: Include "interps.h".
9409 (struct cli_interp_base): New struct.
9410 * interps.c (struct interp): Delete. Fields moved to interps.h.
9411 (interp_new): Delete.
9412 (interp::interp, interp::~interp): New.
9413 (interp_set): Use bool, and return void. Assume the interpreter
9414 has suspend, init and resume methods, and that the all return
9415 void.
9416 (set_top_level_interpreter): interp_set returns void.
9417 (interp_ui_out): Adapt.
9418 (current_interp_set_logging): Adapt.
9419 (interp_data): Delete.
9420 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
9421 (interp_exec): Adapt.
9422 (top_level_interpreter_data): Delete.
9423 * interps.h (interp_init_ftype, interp_resume_ftype)
9424 (interp_suspend_ftype, interp_exec_ftype)
9425 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
9426 (class interp): New.
9427 (interp_new): Delete.
9428 (interp_set): Now returns void. Use bool.
9429 (interp_data, top_level_interpreter_data): Delete.
9430 * mi/mi-common.h: Include interps.h.
9431 (class mi_interp): Inherit from interp. Define a ctor. Declare
9432 init, resume, suspect, exec, interp_ui_out, set_logging and
9433 pre_command_loop methods.
9434 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
9435 (mi_interpreter_init): Rename to ...
9436 (mi_interp::init): ... this. Remove the 'interp' parameter, use
9437 bool, return void and make extern. Adjust.
9438 (mi_interpreter_resume): ... Rename to ...
9439 (mi_interp::resume): ... this. Remove the 'data' parameter,
9440 return void and make extern. Adjust.
9441 (mi_interpreter_suspend): ... Rename to ...
9442 (mi_interp::suspend): ... this. Remove the 'data' parameter,
9443 return void and make extern. Adjust.
9444 (mi_interpreter_exec): ... Rename to ...
9445 (mi_interp::exec): ... this. Remove the 'data' parameter and make
9446 extern. Adjust.
9447 (mi_interpreter_pre_command_loop): ... Rename to ...
9448 (mi_interp::pre_command_loop): ... this. Remove the 'self'
9449 parameter and make extern.
9450 (mi_on_normal_stop_1): Adjust.
9451 (mi_ui_out): Rename to ...
9452 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
9453 parameter and make extern. Adjust.
9454 (mi_set_logging): Rename to ...
9455 (mi_interp::set_logging): ... this. Remove the 'interp'
9456 parameter and make extern. Adjust.
9457 (mi_interp_procs): Delete.
9458 (mi_interp_factory): Adjust to use 'new'.
9459 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
9460 (mi_print_exception, mi_execute_command, mi_load_progress):
9461 Adjust.
9462 * tui/tui-interp.c (tui_interp): New class.
9463 (as_tui_interp): Return a tui_interp pointer.
9464 (tui_on_normal_stop, tui_on_signal_received)
9465 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
9466 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
9467 to use interp::interp_ui_out.
9468 (tui_init): Rename to ...
9469 (tui_interp::init): ... this. Remove the 'self' parameter, use
9470 bool, return void and make extern. Adjust.
9471 (tui_resume): Rename to ...
9472 (tui_interp::resume): ... this. Remove the 'data' parameter,
9473 return void and make extern. Adjust.
9474 (tui_suspend): Rename to ...
9475 (tui_interp::suspend): ... this. Remove the 'data' parameter,
9476 return void and make extern. Adjust.
9477 (tui_ui_out): Rename to ...
9478 (tui_interp::interp_ui_out): ... this. Remove the 'self'
9479 parameter, and make extern. Adjust.
9480 (tui_exec): Rename to ...
9481 (tui_interp::exec): ... this. Remove the 'data' parameter and
9482 make extern.
9483 (tui_interp_procs): Delete.
9484 (tui_interp_factory): Use "new".
9485
65c40c95
TT
94862017-02-02 Tom Tromey <tom@tromey.com>
9487
9488 * rust-exp.y (ends_raw_string, space_then_number)
9489 (rust_identifier_start_p): Return bool.
9490 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
9491 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
9492 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
9493 (rust_chartype_p): Return bool.
9494 (val_print_struct, rust_print_struct_def, rust_print_type):
9495 Update.
9496 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
9497 Return bool.
9498
b50f188d
TT
94992017-02-02 Tom Tromey <tom@tromey.com>
9500
9501 * rust-lang.c: Reindent.
9502
03c85b11
TT
95032017-02-02 Tom Tromey <tom@tromey.com>
9504
9505 * rust-lang.h (rust_crate_for_block): Update.
9506 * rust-lang.c (rust_crate_for_block): Return std::string.
9507 (rust_get_disr_info): Use std:;string, not
9508 gdb::unique_xmalloc_ptr.
9509 * rust-exp.y (crate_name): Update.
9510
9b6da501
PA
95112017-02-02 Pedro Alves <palves@redhat.com>
9512
9513 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
9514 field out of gdb_disassembler_test and make it static.
9515
ec4cb20b
PA
95162017-02-02 Pedro Alves <palves@redhat.com>
9517
9518 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
9519 mi1_interp and mi_interp fields.
9520
5be5dbf0
PA
95212017-02-02 Pedro Alves <palves@redhat.com>
9522
616268b6
PA
9523 * cli/cli-interp.c (struct saved_output_files, saved_output):
9524 Moved from cli/cli-logging.c.
9525 (cli_set_logging): New function.
9526 (cli_interp_procs): Install cli_set_logging.
9527 * cli/cli-interp.h (make_logging_output, cli_set_logging):
9528 Declare.
9529 * cli/cli-logging.c (struct saved_output_files, saved_output):
9530 Moved to cli/cli-interp.c.
9531 (pop_output_files): Don't save outputs here.
9532 (make_logging_output): New function.
9533 (handle_redirections): Don't build tee nor save previous outputs
9534 here.
9535 * interps.c (current_interp_set_logging): Change prototype.
9536 Assume there's always a set_logging_proc method installed.
9537 * interps.h (interp_set_logging_ftype): Change prototype.
9538 (current_interp_set_logging): Change prototype and adjust comment.
9539 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
9540 use make_logging_output.
9541 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
95422017-02-02 Pedro Alves <palves@redhat.com>
9543
5be5dbf0
PA
9544 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
9545 from ...
9546 (set_logging_overwrite): ... here.
9547 (logging_no_redirect_file): Delete.
9548 (set_logging_redirect): Don't handle redirection on the fly.
9549 Instead warn that "logging off" / "logging on" is necessary.
9550 (pop_output_files): Delete references to logging_no_redirect_file.
9551 (show_logging_command): Always speak in terms of what will happen
9552 once logging is reenabled.
9553
c99cc448
PA
95542017-02-02 Pedro Alves <palves@redhat.com>
9555
9556 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
9557
8b172ce7
PA
95582017-02-02 Pedro Alves <palves@redhat.com>
9559
9560 * disasm.c (gdb_pretty_print_insn): Rename to ...
9561 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
9562 Remove gdbarch parameter. Adapt to clear the object's buffers
9563 instead of allocating new buffers, and to print using the object's
9564 gdb_disassembler instead of calling gdb_print_insn.
9565 (dump_insns): Use gdb_pretty_print_disassembler.
9566 * disasm.h (gdb_pretty_print_insn): Delete declaration.
9567 (gdb_pretty_print_disassembler): New class.
9568 * record-btrace.c (btrace_insn_history): Use
9569 gdb_pretty_print_disassembler.
9570
d7e74731
PA
95712017-02-02 Pedro Alves <palves@redhat.com>
9572
9573 * ada-lang.c (type_as_string): Use string_file.
9574 * ada-valprint.c (ada_print_floating): Use string_file.
9575 * ada-varobj.c (ada_varobj_scalar_image)
9576 (ada_varobj_get_value_image): Use string_file.
9577 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
9578 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
9579 * breakpoint.c (update_inserted_breakpoint_locations)
9580 (insert_breakpoint_locations, reattach_breakpoints)
9581 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
9582 (print_it_watchpoint): Use string_file.
9583 (save_breakpoints): Use stdio_file.
9584 * c-exp.y (oper): Use string_file.
9585 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
9586 tee_file.
9587 (pop_output_files): Use delete.
9588 (handle_redirections): Use stdio_file and tee_file.
9589 * cli/cli-setshow.c (do_show_command): Use string_file.
9590 * compile/compile-c-support.c (c_compute_program): Use
9591 string_file.
9592 * compile/compile-c-symbols.c (generate_vla_size): Take a
9593 'string_file &' instead of a 'ui_file *'.
9594 (generate_c_for_for_one_variable): Take a 'string_file &' instead
9595 of a 'ui_file *'. Use string_file.
9596 (generate_c_for_variable_locations): Take a 'string_file &'
9597 instead of a 'ui_file *'.
9598 * compile/compile-internal.h (generate_c_for_for_one_variable):
9599 Take a 'string_file &' instead of a 'ui_file *'.
9600 * compile/compile-loc2c.c (push, pushf, unary, binary)
9601 (print_label, pushf_register_address, pushf_register)
9602 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
9603 'ui_file *'. Adjust.
9604 * compile/compile.c (compile_to_object): Use string_file.
9605 * compile/compile.h (compile_dwarf_expr_to_c)
9606 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
9607 'ui_file *'.
9608 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
9609 (replace_typedefs_qualified_name): Use string_file and
9610 obstack_copy0.
9611 * disasm.c (gdb_pretty_print_insn): Use string_file.
9612 (gdb_disassembly): Adjust reference the null_stream global.
9613 (do_ui_file_delete): Delete.
9614 (gdb_insn_length): Use null_stream.
9615 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
9616 * dwarf2loc.c (dwarf2_compile_property_to_c)
9617 (locexpr_generate_c_location, loclist_generate_c_location): Take a
9618 'string_file &' instead of a 'ui_file *'.
9619 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
9620 * dwarf2read.c (do_ui_file_peek_last): Delete.
9621 (dwarf2_compute_name): Use string_file.
9622 * event-top.c (gdb_setup_readline): Use stdio_file.
9623 * gdbarch.sh (verify_gdbarch): Use string_file.
9624 * gdbtypes.c (safe_parse_type): Use null_stream.
9625 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
9626 string_file.
9627 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
9628 'string_file *' instead of a 'ui_file *'.
9629 (gdbscm_arch_disassemble): Use string_file.
9630 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
9631 * guile/scm-ports.c (class ioscm_file_port): Now a class that
9632 inherits from ui_file.
9633 (ioscm_file_port_delete, ioscm_file_port_rewind)
9634 (ioscm_file_port_put): Delete.
9635 (ioscm_file_port_write): Rename to ...
9636 (ioscm_file_port::write): ... this. Remove file_port_magic
9637 checks.
9638 (ioscm_file_port_new): Delete.
9639 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
9640 ui_file_up.
9641 * guile/scm-type.c (tyscm_type_name): Use string_file.
9642 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
9643 Use string_file.
9644 * infcmd.c (print_return_value_1): Use string_file.
9645 * infrun.c (print_target_wait_results): Use string_file.
9646 * language.c (add_language): Use string_file.
9647 * location.c (explicit_to_string_internal): Use string_file.
9648 * main.c (captured_main_1): Use null_file.
9649 * maint.c (maintenance_print_architecture): Use stdio_file.
9650 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
9651 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
9652 event_channel>: Change type to mi_console_file pointer.
9653 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
9654 (mi_console_file_delete): Delete.
9655 (struct mi_console_file): Delete.
9656 (mi_console_file_magic): Delete.
9657 (mi_console_file_new): Delete.
9658 (mi_console_file::mi_console_file): New.
9659 (mi_console_file_delete): Delete.
9660 (mi_console_file_fputs): Delete.
9661 (mi_console_file::write): New.
9662 (mi_console_raw_packet): Delete.
9663 (mi_console_file::flush): New.
9664 (mi_console_file_flush): Delete.
9665 (mi_console_set_raw): Rename to ...
9666 (mi_console_file::set_raw): ... this.
9667 * mi/mi-console.h (class mi_console_file): New class.
9668 (mi_console_file_new, mi_console_set_raw): Delete.
9669 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
9670 (mi_set_logging): Use delete and tee_file. Adjust.
9671 * mi/mi-main.c (output_register): Use string_file.
9672 (mi_cmd_data_evaluate_expression): Use string_file.
9673 (mi_cmd_data_read_memory): Use string_file.
9674 (mi_cmd_execute, print_variable_or_computed): Use string_file.
9675 * mi/mi-out.c (mi_ui_out::main_stream): New.
9676 (mi_ui_out::rewind): Use main_stream and
9677 string_file.
9678 (mi_ui_out::put): Use main_stream and string_file.
9679 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
9680 Allocate a 'string_file' instead.
9681 (mi_out_new): Don't allocate a mem_fileopen stream here.
9682 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
9683 (mi_ui_out::main_stream): Declare method.
9684 * printcmd.c (eval_command): Use string_file.
9685 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
9686 * python/py-arch.c (archpy_disassemble): Use string_file.
9687 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
9688 * python/py-frame.c (frapy_str): Use string_file.
9689 * python/py-framefilter.c (py_print_type, py_print_single_arg):
9690 Use string_file.
9691 * python/py-type.c (typy_str): Use string_file.
9692 * python/py-unwind.c (unwind_infopy_str): Use string_file.
9693 * python/py-value.c (valpy_str): Use string_file.
9694 * record-btrace.c (btrace_insn_history): Use string_file.
9695 * regcache.c (regcache_print): Use stdio_file.
9696 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
9697 * remote.c (escape_buffer): Use string_file.
9698 * rust-lang.c (rust_get_disr_info): Use string_file.
9699 * serial.c (serial_open_ops_1): Use stdio_file.
9700 (do_serial_close): Use delete.
9701 * stack.c (print_frame_arg): Use string_file.
9702 (print_frame_args): Remove local mem_fileopen stream, not used.
9703 (print_frame): Use string_file.
9704 * symmisc.c (maintenance_print_symbols): Use stdio_file.
9705 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
9706 Take a 'string_file *' instead of a 'ui_file *'.
9707 * top.c (new_ui): Use stdio_file and stderr_file.
9708 (free_ui): Use delete.
9709 (execute_command_to_string): Use string_file.
9710 (quit_confirm): Use string_file.
9711 * tracepoint.c (collection_list::append_exp): Use string_file.
9712 * tui/tui-disasm.c (tui_disassemble): Use string_file.
9713 * tui/tui-file.c: Don't include "ui-file.h".
9714 (enum streamtype, struct tui_stream): Delete.
9715 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
9716 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
9717 (tui_file::tui_file): New method.
9718 (tui_file_fputs): Delete.
9719 (tui_file_get_strbuf): Delete.
9720 (tui_file::puts): New method.
9721 (tui_file_adjust_strbuf): Delete.
9722 (tui_file_flush): Delete.
9723 (tui_file::flush): New method.
9724 * tui/tui-file.h: Tweak intro comment.
9725 Include ui-file.h.
9726 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
9727 (tui_file_adjust_strbuf): Delete declarations.
9728 (class tui_file): New class.
9729 * tui/tui-io.c (tui_initialize_io): Use tui_file.
9730 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
9731 (tui_register_format): Use string_stream.
9732 * tui/tui-stack.c (tui_make_status_line): Use string_file.
9733 (tui_get_function_from_frame): Use string_file.
9734 * typeprint.c (type_to_string): Use string_file.
9735 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
9736 (null_stream): New global.
9737 (ui_file_delete): Delete.
9738 (ui_file::ui_file): New.
9739 (null_file_isatty): Delete.
9740 (ui_file::~ui_file): New.
9741 (null_file_rewind): Delete.
9742 (ui_file::printf): New.
9743 (null_file_put): Delete.
9744 (null_file_flush): Delete.
9745 (ui_file::putstr): New.
9746 (null_file_write): Delete.
9747 (ui_file::putstrn): New.
9748 (null_file_read): Delete.
9749 (ui_file::putc): New.
9750 (null_file_fputs): Delete.
9751 (null_file_write_async_safe): Delete.
9752 (ui_file::vprintf): New.
9753 (null_file_delete): Delete.
9754 (null_file::write): New.
9755 (null_file_fseek): Delete.
9756 (null_file::puts): New.
9757 (ui_file_data): Delete.
9758 (null_file::write_async_safe): New.
9759 (gdb_flush, ui_file_isatty): Adjust.
9760 (ui_file_put, ui_file_rewind): Delete.
9761 (ui_file_write): Adjust.
9762 (ui_file_write_for_put): Delete.
9763 (ui_file_write_async_safe, ui_file_read): Adjust.
9764 (ui_file_fseek): Delete.
9765 (fputs_unfiltered): Adjust.
9766 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
9767 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
9768 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
9769 (set_ui_file_data): Delete.
9770 (string_file::~string_file, string_file::write)
9771 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
9772 (do_ui_file_as_string, ui_file_as_string): Delete.
9773 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
9774 (struct mem_file): Delete.
9775 (mem_file_new): Delete.
9776 (stdio_file::stdio_file): New.
9777 (mem_file_delete): Delete.
9778 (stdio_file::stdio_file): New.
9779 (mem_fileopen): Delete.
9780 (stdio_file::~stdio_file): New.
9781 (mem_file_rewind): Delete.
9782 (stdio_file::set_stream): New.
9783 (mem_file_put): Delete.
9784 (stdio_file::open): New.
9785 (mem_file_write): Delete.
9786 (stdio_file_magic, struct stdio_file): Delete.
9787 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
9788 (stdio_file::flush): New.
9789 (stdio_file_read): Rename to ...
9790 (stdio_file::read): ... this. Adjust.
9791 (stdio_file_write): Rename to ...
9792 (stdio_file::write): ... this. Adjust.
9793 (stdio_file_write_async_safe): Rename to ...
9794 (stdio_file::write_async_safe) ... this. Adjust.
9795 (stdio_file_fputs): Rename to ...
9796 (stdio_file::puts) ... this. Adjust.
9797 (stdio_file_isatty): Delete.
9798 (stdio_file_fseek): Delete.
9799 (stdio_file::isatty): New.
9800 (stderr_file_write): Rename to ...
9801 (stderr_file::write) ... this. Adjust.
9802 (stderr_file_fputs): Rename to ...
9803 (stderr_file::puts) ... this. Adjust.
9804 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
9805 (stderr_file::stderr_file): New.
9806 (tee_file_magic): Delete.
9807 (struct tee_file): Delete.
9808 (tee_file::tee_file): New.
9809 (tee_file_new): Delete.
9810 (tee_file::~tee_file): New.
9811 (tee_file_delete): Delete.
9812 (tee_file_flush): Rename to ...
9813 (tee_file::flush): ... this. Adjust.
9814 (tee_file_write): Rename to ...
9815 (tee_file::write): ... this. Adjust.
9816 (tee_file::write_async_safe): New.
9817 (tee_file_fputs): Rename to ...
9818 (tee_file::puts): ... this. Adjust.
9819 (tee_file_isatty): Rename to ...
9820 (tee_file::isatty): ... this. Adjust.
9821 * ui-file.h (struct obstack, struct ui_file): Don't
9822 forward-declare.
9823 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
9824 (ui_file_write_ftype)
9825 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
9826 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
9827 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
9828 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
9829 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
9830 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
9831 (set_ui_file_fseek): Delete.
9832 (ui_file_data, ui_file_delete, ui_file_rewind)
9833 (struct ui_file): New.
9834 (ui_file_up): New.
9835 (class null_file): New.
9836 (null_stream): Declare.
9837 (ui_file_write_for_put, ui_file_put): Delete.
9838 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
9839 Delete.
9840 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
9841 (gdb_fopen, tee_file_new): Delete.
9842 (struct string_file): New.
9843 (struct stdio_file): New.
9844 (stdio_file_up): New.
9845 (struct stderr_file): New.
9846 (class tee_file): New.
9847 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
9848 of a 'ui_file *'. Adjust.
9849 * ui-out.h (class ui_out) <field_stream>: Likewise.
9850 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
9851 (null_stream): Delete.
9852 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
9853 Adjust.
9854 * utils.h (struct ui_file): Delete forward declaration..
9855 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
9856 (error_stream): Take a 'string_file &' instead of a
9857 'ui_file *'.
9858 * varobj.c (varobj_value_get_print_value): Use string_file.
9859 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
9860 * gdbarch.c: Regenerate.
9861
187808b0
PA
98622017-02-02 Pedro Alves <palves@redhat.com>
9863
9864 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
9865 (gdb_pretty_print_insn): ... this. Now a free function. Add back
9866 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
9867 Adjust to call gdb_print_insn instead of
9868 gdb_disassembler::print_insn.
9869 (dump_insns, do_mixed_source_and_assembly_deprecated)
9870 (do_mixed_source_and_assembly, do_assembly_only): Add back a
9871 'gdbarch' parameter. Remove gdb_disassembler parameter.
9872 (gdb_disassembly): Don't allocate a gdb_disassembler here.
9873 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
9874 declaration.
9875 (gdb_pretty_print_insn): Re-add declaration.
9876 * record-btrace.c (btrace_insn_history): Don't allocate a
9877 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
9878
7a8eb317
SM
98792017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
9880
9881 * disasm.h (gdb_disassembly): Remove file_string parameter.
9882 * disasm.c (gdb_disassembly): Likewise.
9883 * cli/cli-cmds.c (print_disassembly): Adapt.
9884 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
9885 * stack.c (do_gdb_disassembly): Likewise.
9886
7346ef59
AA
98872017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
9888
9889 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
9890 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
9891 targets. And if the implicit value is longer than needed, extract
9892 the first bytes instead of the "least significant" ones.
9893
cd4007e4
MM
98942017-02-01 Markus Metzger <markus.t.metzger@intel.com>
9895
9896 * btrace.c (btrace_enable): Do not call btrace_add_pc for
9897 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
9898 (btrace_fetch): Assert can_access_registers_ptid.
9899 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
9900 validate_registers_access.
9901
cf77c34e
MM
99022017-02-01 Markus Metzger <markus.t.metzger@intel.com>
9903
9904 * gdbthread.h (can_access_registers_ptid): New.
9905 * thread.c (can_access_registers_ptid): New.
9906
be85ce7d
PA
99072017-02-01 Pedro Alves <palves@redhat.com>
9908
9909 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
9910
29b0b251
PA
99112017-01-31 Pedro Alves <palves@redhat.com>
9912
9913 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
9914 Fix typos.
9915
289b5b24
PA
99162017-01-31 Pedro Alves <palves@redhat.com>
9917
9918 * stack.c (print_frame_args): Remove local mem_fileopen stream,
9919 not used.
9920
b47413b4
PA
99212017-01-31 Pedro Alves <palves@redhat.com>
9922
9923 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
9924
60adb36c
PA
99252017-01-31 Pedro Alves <palves@redhat.com>
9926
9927 * common/scoped_restore.h
9928 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
9929 change the value's parameter type to T2.
9930 (make_scoped_restore): Likewise.
9931
2735833d
WT
99322017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
9933 Richard Henderson <rth@redhat.com>
9934
9935 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
9936 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
9937 GS_BASE for older kernels.
9938 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
9939 GS_BASE for older kernels.
9940 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
9941 and GS_BASE to the offset table.
9942 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
9943 system register group.
9944 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
9945 for older kernels.
9946 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
9947 amd64 ABI.
9948 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
9949 AMD64_GSBASE_REGNUM.
9950 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
9951 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
9952 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
9953 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
9954 i386/64bit-segments.xml in those rules.
9955 * features/i386/64bit-segments.xml: New file.
9956 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
9957 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
9958 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
9959 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
9960 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
9961 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
9962 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
9963 * features/i386/amd64-avx-linux.c: Regenerated.
9964 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
9965 * features/i386/amd64-avx-mpx.c: Regenerated.
9966 * features/i386/amd64-avx512-linux.c: Regenerated.
9967 * features/i386/amd64-linux.c: Regenerated.
9968 * features/i386/amd64-mpx-linux.c: Regenerated.
9969 * features/i386/i386-avx-mpx-linux.c: Regenerated.
9970 * features/i386/i386-avx-mpx.c: Regenerated.
9971 * features/i386/x32-avx-linux.c: Regenerated.
9972 * features/i386/x32-avx512-linux.c: Regenerated.
9973 * regformats/i386/amd64-avx-linux.dat: Regenerated.
9974 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
9975 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
9976 * regformats/i386/amd64-linux.dat: Regenerated.
9977 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
9978 * regformats/i386/x32-avx-linux.dat: Regenerated.
9979 * regformats/i386/x32-avx512-linux.dat: Regenerated.
9980 * regformats/i386/x32-linux.dat: Regenerated.
9981
8884e97e
WT
99822017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
9983
9984 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
9985 Set to AMD64_NUM_REGS.
9986
7005d26a
WT
99872017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
9988
9989 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
9990 that checks validity of a register number.
9991
4bd2e1b2
KC
99922017-01-27 Kees Cook <keescook@google.com>
9993
9994 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
9995 fetch_fpregs if target has fpa registers.
9996 (arm_linux_store_inferior_registers): Call store_fpregs if target
9997 has fpa registers.
9998
7cf1de6c
AA
99992017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
10000
10001 * cris-tdep.c (cris_gdbarch_init): Remove check for
10002 info.byte_order and force it to BFD_ENDIAN_LITTLE.
10003
874a1c8c
AT
100042017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
10005
10006 * corelow.c (get_core_register_section): Check for regset
10007 existence before checking for REGSET_VARIABLE_SIZE.
10008
d8b49cf0
YQ
100092017-01-26 Yao Qi <yao.qi@linaro.org>
10010 Pedro Alves <palves@redhat.com>
10011
10012 PR gdb/20939
10013 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
10014 call memory_error, save memaddr instead.
10015 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
10016 negative, cal memory_error.
10017 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
10018
658ca58c
YQ
100192017-01-26 Yao Qi <yao.qi@linaro.org>
10020
10021 * disasm-selftests.c (memory_error_test): New function.
10022 (_initialize_disasm_selftests): Register memory_error_test.
10023
79843d45
YQ
100242017-01-26 Yao Qi <yao.qi@linaro.org>
10025
10026 * Makefile.in (SFILES): Add disasm-selftests.c and
10027 selftest-arch.c.
10028 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
10029 * disasm-selftests.c: New file.
10030 * selftest-arch.c: New file.
10031 * selftest-arch.h: New file.
10032
8cafda32
YQ
100332017-01-26 Yao Qi <yao.qi@linaro.org>
10034
10035 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
10036 to bfd_arch_mep. Don't return 0 if section is not
10037 found. Call print_insn_mep.
10038
e47ad6c0
YQ
100392017-01-26 Pedro Alves <palves@redhat.com>
10040 Yao Qi <yao.qi@linaro.org>
10041
10042 * arm-tdep.c: Include "disasm.h".
10043 (gdb_print_insn_arm): Update code to get gdbarch.
10044 * disasm.c (dis_asm_read_memory): Change it to
10045 gdb_disassembler::dis_asm_read_memory.
10046 (dis_asm_memory_error): Likewise.
10047 (dis_asm_print_address): Likewise.
10048 (gdb_pretty_print_insn): Change it to
10049 gdb_disassembler::pretty_print_insn.
10050 (dump_insns): Add one argument gdb_disassemlber. All
10051 callers updated.
10052 (do_mixed_source_and_assembly_deprecated): Likewise.
10053 (do_mixed_source_and_assembly): Likewise.
10054 (do_assembly_only): Likewise.
10055 (gdb_disassembler::gdb_disassembler): New.
10056 (gdb_disassembler::print_insn): New.
10057 * disasm.h (class gdb_disassembler): New.
10058 (gdb_pretty_print_insn): Remove declaration.
10059 (gdb_disassemble_info): Likewise.
10060 * guile/scm-disasm.c (class gdbscm_disassembler): New.
10061 (gdbscm_disasm_read_memory_worker): Update.
10062 (gdbscm_disasm_read_memory): Update.
10063 (gdbscm_disasm_memory_error): Remove.
10064 (gdbscm_disasm_print_address): Remove.
10065 (gdbscm_disassembler::gdbscm_disassembler): New.
10066 (gdbscm_print_insn_from_port): Update.
10067 * mips-tdep.c: Include disasm.h.
10068 (gdb_print_insn_mips): Update code to get gdbarch.
10069 * record-btrace.c (btrace_insn_history): Update.
10070 * spu-tdep.c: Include disasm.h.
10071 (struct spu_dis_asm_data): Remove.
10072 (struct spu_dis_asm_info): New.
10073 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
10074 SPU id.
10075 (gdb_print_insn_spu): Cast disassemble_info to
10076 spu_dis_asm_info.
10077
80d75874
YQ
100782017-01-26 Yao Qi <yao.qi@linaro.org>
10079
10080 * disasm.c (do_ui_file_delete): Delete.
10081 (gdb_insn_length): Move code creating stream to ...
10082 * utils.c (null_stream): ... here. New function.
10083 * utils.h (null_stream): Declare.
10084
60685cd0
SM
100852017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
10086
10087 * python/py-inferior.c (find_thread_object): Return directly
10088 from the loop. Remove "found" variable.
10089
eb1cdb62
JB
100902017-01-21 Joel Brobecker <brobecker@adacore.com>
10091
10092 GDB 7.12.1 released.
10093
b1ce6568
SM
100942017-01-20 Simon Marchi <simon.marchi@ericsson.com>
10095
10096 * python/py-function.c (fnpy_call): Reorder declarations to have
10097 the gdbpy_enter object declared first.
10098 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
10099
6f8b0407
SM
101002017-01-20 Simon Marchi <simon.marchi@ericsson.com>
10101
fec93fb1 10102 PR python/21068
6f8b0407
SM
10103 * python/python-internal.h (PyMem_RawMalloc): Define for
10104 Python < 3.4.
10105 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
10106 PyMem_RawMalloc instead of PyMem_Malloc.
10107
78cbbba8
LM
101082017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
10109 Luis Machado <lgustavo@codesourcery.com>
10110
10111 * NEWS (New commands): Mention flash-erase.
10112 (New MI commands): Mention target-flash-erase.
10113 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
10114 command.
10115 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
10116 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
10117 * target.c (flash_erase_command): New function.
10118 (initialize_targets): Add new flash-erase command.
10119 * target.h (flash_erase_command): New declaration.
10120
2132fe85
JB
101212017-01-20 Joel Brobecker <brobecker@adacore.com>
10122
10123 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
10124 HAVE_SYS_PROCFS_H is defined.
10125
d1dff226
AH
101262017-01-18 Alan Hayward <alan.hayward@arm.com>
10127
10128 * remote.c (struct cached_reg): Change data into a pointer.
10129 * (stop_reply_dtr): Free data pointers before deleting vector.
10130 (process_stop_reply): Likewise.
10131 (remote_parse_stop_reply): Allocate space for data
10132
9890e433
AH
101332017-01-18 Alan Hayward <alan.hayward@arm.com>
10134
10135 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
10136 MAX_REGISTER_SIZE.
10137 (amd64_pseudo_register_read_value): Likewise.
10138 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
10139 (store_register_using_P): Likewise.
10140 * regcache.c (regcache_xfer_part): Likewise.
10141
7a36499a
IR
101422017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
10143
10144 Split real and pseudo registers.
10145 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
10146 (sparc32_pseudo_regnum): New enum.
10147 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
10148 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
10149 (SPARC32_CP0_REGISTERS): New macro.
10150 (sparc32_pseudo_register_name): New function.
10151 (sparc32_register_name): Use sparc32_pseudo_register_name.
10152 (sparc32_pseudo_register_type): New function.
10153 (sparc32_register_type): Use sparc32_pseudo_register_type.
10154 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
10155 pseudo register numbers.
10156 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
10157 (SPARC64_CP0_REGISTERS): New macro.
10158 (sparc64_pseudo_register_name): New function.
10159 (sparc64_register_name): Use sparc64_pseudo_register_name.
10160 (sparc64_pseudo_register_type): New function.
10161 (sparc64_register_type): Use sparc64_pseudo_register_type.
10162 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
10163 pseudo register numbers.
10164 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
10165 sparc64_store_arguments): Handle pseudo register numbers.
10166
6f8976bf
YQ
101672017-01-13 Yao Qi <yao.qi@linaro.org>
10168
10169 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
10170 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
10171 output.
10172 (getpkt_or_notif_sane_1): Likewise.
10173
e4241ace
YQ
101742017-01-13 Yao Qi <yao.qi@linaro.org>
10175
10176 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
10177 of CC. Pass "-x c++-header" instead of "-x c".
10178
3015c064
SM
101792017-01-12 Simon Marchi <simon.marchi@ericsson.com>
10180
10181 * remote.c (remote_can_async_p): Update comment.
10182
fde1b17d
SM
101832017-01-12 Simon Marchi <simon.marchi@ericsson.com>
10184
10185 * linux-nat.c (linux_nat_can_async_p): Update comment.
10186
ca1ca08b
SM
101872017-01-12 Simon Marchi <simon.marchi@ericsson.com>
10188
10189 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
10190
4ad2da73
SM
101912017-01-11 Simon Marchi <simon.marchi@ericsson.com>
10192
10193 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
10194
c8b23b3f
TT
101952017-01-10 Tom Tromey <tom@tromey.com>
10196
10197 * python/py-type.c (typy_legacy_template_argument): Update.
10198 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
10199 ~demangle_parse_info): Declare new members.
10200 (cp_demangled_name_to_comp): Return unique_ptr.
10201 (cp_demangled_name_parse_free)
10202 (make_cleanup_cp_demangled_name_parse_free)
10203 (cp_new_demangle_parse_info): Remove.
10204 * cp-support.c (do_demangled_name_parse_free_cleanup)
10205 (make_cleanup_cp_demangled_name_parse_free): Remove.
10206 (inspect_type, cp_canonicalize_string_full)
10207 (cp_canonicalize_string): Update.
10208 (mangled_name_to_comp): Change return type.
10209 (cp_class_name_from_physname, method_name_from_physname)
10210 (cp_func_name, cp_remove_params): Update.
10211 * cp-name-parser.y (demangle_parse_info): New constructor, from
10212 cp_new_demangle_parse_info.
10213 (~demangle_parse_info): New destructor, from
10214 cp_demangled_name_parse_free.
10215 (cp_merge_demangle_parse_infos): Update.
10216 (cp_demangled_name_to_comp): Change return type.
10217
1ac32117
TT
102182017-01-10 Tom Tromey <tom@tromey.com>
10219
10220 * top.c (prevent_dont_repeat): Change return type.
10221 * python/python.c (execute_gdb_command): Use std::string.
10222 Update.
10223 * guile/guile.c (gdbscm_execute_gdb_command): Update.
10224 * command.h (prevent_dont_repeat): Change return type.
10225 * breakpoint.c (bpstat_do_actions_1): Update.
10226
0cf08227
TT
102272017-01-10 Tom Tromey <tom@tromey.com>
10228
10229 * value.h (scoped_value_mark::~scoped_value_mark): Call
10230 free_to_mark.
10231 (scoped_value_mark::free_to_mark): New method.
10232 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
10233 scoped_value_mark.
10234
eb115069
TT
102352017-01-10 Tom Tromey <tom@tromey.com>
10236
10237 * python/py-value.c (valpy_dereference, valpy_referenced_value)
10238 (valpy_reference_value, valpy_const_value, valpy_get_address)
10239 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
10240 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
10241 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
10242 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
10243 scoped_value_mark.
10244 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
10245 * value.h (scoped_value_mark): New class.
10246
906768f9
TT
102472017-01-10 Tom Tromey <tom@tromey.com>
10248
10249 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
10250 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
10251 * psymtab.c (discard_psymtabs_upto): Remove.
10252 (make_cleanup_discard_psymtabs): Remove.
10253 (struct psymtab_state): Remove.
10254
bef155c3
TT
102552017-01-10 Tom Tromey <tom@tromey.com>
10256
10257 * record-full.c (record_full_save_cleanups): Remove.
10258 (record_full_save): Use gdb::unlinker.
10259 * gcore.c (do_bfd_delete_cleanup): Remove.
10260 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
10261 cleanups.
10262 * dwarf2read.c (unlink_if_set): Remove.
10263 (write_psymtabs_to_index): Use gdb::unlinker.
10264 * common/gdb_unlinker.h: New file.
10265
192b62ce
TT
102662017-01-10 Tom Tromey <tom@tromey.com>
10267
10268 * windows-tdep.c (windows_xfer_shared_library): Update.
10269 * windows-nat.c (windows_make_so): Update.
10270 * utils.h (make_cleanup_bfd_unref): Remove.
10271 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
10272 * symfile.h (symfile_bfd_open)
10273 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
10274 * symfile.c (read_symbols, symbol_file_add)
10275 (separate_debug_file_exists): Update.
10276 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
10277 (generic_load, reread_symbols): Update.
10278 * symfile-mem.c (symbol_file_add_from_memory): Update.
10279 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
10280 (spu_symbol_file_add_from_memory): Update.
10281 * solist.h (struct target_so_ops) <bfd_open>: Return
10282 gdb_bfd_ref_ptr.
10283 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
10284 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
10285 gdb_bfd_ref_ptr.
10286 (solib_map_sections, reload_shared_libraries_1): Update.
10287 * solib-svr4.c (enable_break): Update.
10288 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
10289 * solib-frv.c (enable_break2): Update.
10290 * solib-dsbt.c (enable_break): Update.
10291 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
10292 gdb_bfd_ref_ptr.
10293 (darwin_solib_get_all_image_info_addr_at_init): Update.
10294 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
10295 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
10296 * record-full.c (record_full_save): Update.
10297 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
10298 * procfs.c (insert_dbx_link_bpt_in_file): Update.
10299 * minidebug.c (find_separate_debug_file_in_section): Return
10300 gdb_bfd_ref_ptr.
10301 * machoread.c (macho_add_oso_symfile): Change abfd to
10302 gdb_bfd_ref_ptr.
10303 (macho_symfile_read_all_oso): Update.
10304 (macho_check_dsym): Return gdb_bfd_ref_ptr.
10305 (macho_symfile_read): Update.
10306 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
10307 (jit_bfd_try_read_symtab): Update.
10308 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
10309 (gdb_bfd_openw, gdb_bfd_openr_iovec)
10310 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
10311 gdb_bfd_ref_ptr.
10312 (gdb_bfd_ref_policy): New struct.
10313 (gdb_bfd_ref_ptr): New typedef.
10314 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
10315 (gdb_bfd_openw, gdb_bfd_openr_iovec)
10316 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
10317 gdb_bfd_ref_ptr.
10318 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
10319 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
10320 (gcore_command): Update.
10321 * exec.c (exec_file_attach): Update.
10322 * elfread.c (elf_symfile_read): Update.
10323 * dwarf2read.c (dwarf2_get_dwz_file): Update.
10324 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
10325 (open_and_init_dwo_file): Update.
10326 (open_dwp_file): Return gdb_bfd_ref_ptr.
10327 (open_and_init_dwp_file): Update.
10328 * corelow.c (core_open): Update.
10329 * compile/compile-object-load.c (compile_object_load): Update.
10330 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
10331 * coffread.c (coff_symfile_read): Update.
10332 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
10333 gdb_bfd_ref_ptr. Rename.
10334 (dump_bfd_file, restore_command): Update.
10335 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
10336 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
10337 (find_separate_debug_file_by_buildid): Update.
10338
50315b21
TT
103392017-01-10 Tom Tromey <tom@tromey.com>
10340
10341 * common/gdb_ref_ptr.h: New file.
10342 * python/py-ref.h (struct gdbpy_ref_policy): New.
10343 (gdbpy_ref): Now a typedef.
10344
fc4007c9
TT
103452017-01-10 Tom Tromey <tom@tromey.com>
10346
10347 * utils.h (make_cleanup_htab_delete): Don't declare.
10348 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
10349 Remove.
10350 * linespec.c (decode_compound_collector): Add constructor,
10351 destructor.
10352 (lookup_prefix_sym): Remove cleanup.
10353 (symtab_collector): Add constructor, destructor.
10354 (collect_symtabs_from_filename): Remove cleanup.
10355 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
10356 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
10357 Use htab_up.
10358 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
10359 * dwarf2read.c (dw2_expand_symtabs_matching)
10360 (dw2_map_symbol_filenames, dwarf_decode_macros)
10361 (write_psymtabs_to_index): Use htab_up.
10362 * dwarf2loc.c (func_verify_no_selftailcall)
10363 (call_site_find_chain_1, func_verify_no_selftailcall)
10364 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
10365 std::vector, gdb::unique_xmalloc_ptr.
10366 (call_sitep): Remove typedef.
10367 (dwarf2_locexpr_baton_eval): Remove unused variable.
10368
8dbcee67
TT
103692017-01-10 Tom Tromey <tom@tromey.com>
10370
10371 * python/python-internal.h (make_cleanup_py_decref)
10372 (make_cleanup_py_xdecref): Don't declare.
10373 * python/py-utils.c (py_decref, make_cleanup_py_decref)
10374 (py_xdecref, make_cleanup_py_xdecref): Remove.
10375
13df46cc
TT
103762017-01-10 Tom Tromey <tom@tromey.com>
10377
10378 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
10379 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
10380
06fc9bf7
TT
103812017-01-10 Tom Tromey <tom@tromey.com>
10382
10383 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
10384
830a4934
TT
103852017-01-10 Tom Tromey <tom@tromey.com>
10386
10387 * python/py-utils.c (unicode_to_encoded_string)
10388 (python_string_to_target_string)
10389 (python_string_to_target_python_string)
10390 (python_string_to_host_string, gdbpy_obj_to_string)
10391 (get_addr_from_python): Use gdbpy_ref.
10392
4586d543
TT
103932017-01-10 Tom Tromey <tom@tromey.com>
10394
10395 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
10396 gdbpy_ref.
10397
59876f8f
TT
103982017-01-10 Tom Tromey <tom@tromey.com>
10399
10400 * python/python.c (eval_python_command, gdbpy_decode_line)
10401 (gdbpy_run_events, gdbpy_start_type_printers)
10402 (gdbpy_apply_type_printers): Use gdbpy_ref.
10403
97d83487
TT
104042017-01-10 Tom Tromey <tom@tromey.com>
10405
10406 * python/py-param.c (get_doc_string, compute_enum_values): Use
10407 gdbpy_ref.
10408
9205649a
TT
104092017-01-10 Tom Tromey <tom@tromey.com>
10410
10411 * python/py-inferior.c (find_thread_object, build_inferior_list):
10412 Use gdbpy_ref.
10413
74c49d45
TT
104142017-01-10 Tom Tromey <tom@tromey.com>
10415
10416 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
10417
16361ffb
TT
104182017-01-10 Tom Tromey <tom@tromey.com>
10419
10420 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
10421 gdbpy_ref.
10422
905f2cca
TT
104232017-01-10 Tom Tromey <tom@tromey.com>
10424
10425 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
10426 extra incref.
10427 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
10428 Use gdbpy_ref.
10429
64081434
TT
104302017-01-10 Tom Tromey <tom@tromey.com>
10431
10432 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
10433 gdbpy_ref.
10434
59e9e831
TT
104352017-01-10 Tom Tromey <tom@tromey.com>
10436
10437 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
10438 decref results of PyArg_ParseTupleAndKeywords.
10439
9de10f6d
TT
104402017-01-10 Tom Tromey <tom@tromey.com>
10441
10442 * python/python.c (python_run_simple_file): Use
10443 unique_xmalloc_ptr, gdbpy_ref.
10444
2bd5759d
TT
104452017-01-10 Tom Tromey <tom@tromey.com>
10446
10447 * python/py-prettyprint.c (print_stack_unless_memory_error)
10448 (print_string_repr, print_children): Use gdbpy_ref.
10449 (dummy_python_frame): New class.
10450 (dummy_python_frame::dummy_python_frame): Rename from
10451 push_dummy_python_frame.
10452 (py_restore_tstate): Remove.
10453
3b4e0e01
TT
104542017-01-10 Tom Tromey <tom@tromey.com>
10455
10456 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
10457
17a22718
TT
104582017-01-10 Tom Tromey <tom@tromey.com>
10459
10460 * python/python.c (ensure_python_env, restore_python_env):
10461 Remove.
10462 * python/python-internal.h (ensure_python_env): Don't declare.
10463 * varobj.h (varobj_ensure_python_env): Don't declare.
10464 * varobj.c (varobj_ensure_python_env): Remove.
10465
68cdc557
TT
104662017-01-10 Tom Tromey <tom@tromey.com>
10467
10468 * varobj.c (varobj_value_get_print_value): Use
10469 gdbpy_enter_varobj.
10470
1eba6383
TT
104712017-01-10 Tom Tromey <tom@tromey.com>
10472
10473 * python/py-prettyprint.c (print_string_repr, print_children):
10474 Update.
10475 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
10476 of "encoding".
10477 * varobj.c (varobj_value_get_print_value): Update.
10478 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
10479
bde7b3e3
TT
104802017-01-10 Tom Tromey <tom@tromey.com>
10481
10482 * varobj.c (varobj_get_display_hint)
10483 (dynamic_varobj_has_child_method, install_new_value_visualizer)
10484 (varobj_set_visualizer, free_variable): Use
10485 gdbpy_enter_varobj.
10486
a7785f8c
TT
104872017-01-10 Tom Tromey <tom@tromey.com>
10488
10489 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
10490 (do_finish_initialization): New function. Use gdbpy_ref.
10491 (gdbpy_finish_initialization): Use gdbpy_enter. Call
10492 do_finish_initialization.
10493
2865bfce
TT
104942017-01-10 Tom Tromey <tom@tromey.com>
10495
10496 * python/py-param.c (get_set_value, get_show_value): Use
10497 gdbpy_enter, gdbpy_ref.
10498
0e9dcc75
TT
104992017-01-10 Tom Tromey <tom@tromey.com>
10500
10501 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
10502
12a5cedd
TT
105032017-01-10 Tom Tromey <tom@tromey.com>
10504
10505 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
10506
788f2586
TT
105072017-01-10 Tom Tromey <tom@tromey.com>
10508
10509 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
10510 Use gdbpy_enter_varobj.
10511
6cd67bea
TT
105122017-01-10 Tom Tromey <tom@tromey.com>
10513
10514 * varobj.c (gdbpy_enter_varobj): New constructor.
10515 * python/python-internal.h (gdbpy_enter_varobj): New class.
10516 * python/py-varobj.c (py_varobj_get_iterator): Use
10517 gdbpy_enter_varobj.
10518
14b122bf
TT
105192017-01-10 Tom Tromey <tom@tromey.com>
10520
10521 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
10522 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
10523 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
10524 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
10525 unique_xmalloc_ptr.
10526 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
10527
bf1ca3b9
TT
105282017-01-10 Tom Tromey <tom@tromey.com>
10529
10530 * python/py-xmethods.c (invoke_match_method): Use
10531 gdbpy_ref.
10532
572a5524
TT
105332017-01-10 Tom Tromey <tom@tromey.com>
10534
10535 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
10536 gdbpy_enter, gdbpy_ref.
10537
396a78b6
TT
105382017-01-10 Tom Tromey <tom@tromey.com>
10539
10540 * python/python.c (python_interactive_command): Use gdbpy_enter.
10541
a88b13c7
TT
105422017-01-10 Tom Tromey <tom@tromey.com>
10543
10544 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
10545 gdbpy_ref.
10546
e9f0c363
TT
105472017-01-10 Tom Tromey <tom@tromey.com>
10548
10549 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
10550 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
10551
6349f452
TT
105522017-01-10 Tom Tromey <tom@tromey.com>
10553
10554 * utils.h (htab_deleter): New struct.
10555 (htab_up): New typedef.
10556 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
10557 gdbpy_enter, gdbpy_ref, htab_up.
10558
c0171de6
TT
105592017-01-10 Tom Tromey <tom@tromey.com>
10560
10561 * python/py-unwind.c (pending_frame_invalidate): Remove.
10562 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
10563
f18e226f
TT
105642017-01-10 Tom Tromey <tom@tromey.com>
10565
10566 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
10567 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
10568
c57af3f1
TT
105692017-01-10 Tom Tromey <tom@tromey.com>
10570
10571 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
10572
60e600ec
TT
105732017-01-10 Tom Tromey <tom@tromey.com>
10574
10575 * python/python.c (gdbpy_eval_from_control_command)
10576 (gdbpy_source_script, gdbpy_run_events)
10577 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
10578 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
10579 gdbpy_enter.
10580
bf7da5b0
TT
105812017-01-10 Tom Tromey <tom@tromey.com>
10582
10583 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
10584
2d38bced
TT
105852017-01-10 Tom Tromey <tom@tromey.com>
10586
10587 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
10588
07bc7329
TT
105892017-01-10 Tom Tromey <tom@tromey.com>
10590
10591 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
10592 (python_on_inferior_call_pre, python_on_inferior_call_post)
10593 (python_on_memory_change, python_on_register_change)
10594 (python_inferior_exit, python_new_objfile, add_thread_object)
10595 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
10596
6e7c365e
TT
105972017-01-10 Tom Tromey <tom@tromey.com>
10598
10599 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
10600 (bpfinishpy_handle_exit): Use gdbpy_enter.
10601
6ba0cd40
TT
106022017-01-10 Tom Tromey <tom@tromey.com>
10603
10604 * python/py-cmd.c (cmdpy_destroyer)
10605 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
10606 gdbpy_enter.
10607
de2dc875
TT
106082017-01-10 Tom Tromey <tom@tromey.com>
10609
10610 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
10611 gdbpy_enter.
10612 (gdbpy_breakpoint_has_cond): Likewise.
10613
4ecee2c4
TT
106142017-01-10 Tom Tromey <tom@tromey.com>
10615
10616 * python/python.c (gdbpy_enter): New constructor.
10617 (~gdbpy_enter): New destructor.
10618 (restore_python_env, ensure_python_env): Rewrite.
10619 * python/python-internal.h (gdbpy_enter): New class.
10620
37fce74f
TT
106212017-01-10 Tom Tromey <tom@tromey.com>
10622
10623 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
10624
53a0cca3
TT
106252017-01-10 Tom Tromey <tom@tromey.com>
10626
10627 * python/py-value.c (value_has_field, get_field_flag)
10628 (get_field_type, valpy_getitem, convert_value_from_python): Use
10629 gdbpy_ref.
10630
ff3724f5
TT
106312017-01-10 Tom Tromey <tom@tromey.com>
10632
10633 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
10634 gdbpy_ref.
10635
0700aea5
TT
106362017-01-10 Tom Tromey <tom@tromey.com>
10637
10638 * python/py-prettyprint.c (search_pp_list)
10639 (find_pretty_printer_from_objfiles)
10640 (find_pretty_printer_from_progspace)
10641 (find_pretty_printer_from_gdb, find_pretty_printer)
10642 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
10643 gdbpy_ref.
10644
1bb44c9f
TT
106452017-01-10 Tom Tromey <tom@tromey.com>
10646
10647 * python/py-param.c (call_doc_function): Use gdbpy_ref.
10648
87ce03fd
TT
106492017-01-10 Tom Tromey <tom@tromey.com>
10650
10651 * python/py-linetable.c (build_line_table_tuple_from_pcs)
10652 (ltpy_get_all_source_lines): Use gdbpy_ref.
10653
ee0a3fb8
TT
106542017-01-10 Tom Tromey <tom@tromey.com>
10655
10656 * python/py-framefilter.c (extract_sym, extract_value)
10657 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
10658 gdbpy_ref.
10659
bf2a52fa
TT
106602017-01-10 Tom Tromey <tom@tromey.com>
10661
10662 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
10663
f59fe7f8
TT
106642017-01-10 Tom Tromey <tom@tromey.com>
10665
10666 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
10667
80bd970a
TT
106682017-01-10 Tom Tromey <tom@tromey.com>
10669
10670 * python/py-function.c (convert_values_to_python, fnpy_init): Use
10671 gdbpy_ref.
10672
d1b3de2e
TT
106732017-01-10 Tom Tromey <tom@tromey.com>
10674
10675 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
10676
3bb43384
TT
106772017-01-10 Tom Tromey <tom@tromey.com>
10678
10679 * python/py-type.c (convert_field, make_fielditem, typy_fields)
10680 (typy_range): Use gdbpy_ref.
10681
abf5651e
TT
106822017-01-10 Tom Tromey <tom@tromey.com>
10683
10684 * python/py-threadevent.c (create_thread_event_object): Use
10685 gdbpy_ref.
10686 * python/py-stopevent.c (create_stop_event_object): Simplify.
10687 (emit_stop_event): Use gdbpy_ref.
10688 * python/py-signalevent.c (create_signal_event_object): Use
10689 gdbpy_ref.
10690 * python/py-newobjfileevent.c (create_new_objfile_event_object)
10691 (emit_new_objfile_event, create_clear_objfiles_event_object)
10692 (emit_clear_objfiles_event): Use gdbpy_ref.
10693 * python/py-infevents.c (create_inferior_call_event_object)
10694 (create_register_changed_event_object)
10695 (create_memory_changed_event_object, emit_inferior_call_event)
10696 (emit_memory_changed_event, emit_register_changed_event): Use
10697 gdbpy_ref.
10698 * python/py-exitedevent.c (create_exited_event_object)
10699 (emit_exited_event): Use gdbpy_ref.
10700 * python/py-event.h (evpy_emit_event): Remove
10701 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
10702 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
10703 * python/py-continueevent.c (emit_continue_event): Use
10704 gdbpy_ref.
10705 * python/py-breakpoint.c (gdbpy_breakpoint_created)
10706 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
10707 gdbpy_ref.
10708 * python/py-bpevent.c (create_breakpoint_event_object): Use
10709 gdbpy_ref.
10710
a68ff33e
TT
107112017-01-10 Tom Tromey <tom@tromey.com>
10712
10713 * python/py-ref.h: New file.
10714
7becfd03
SM
107152017-01-10 Simon Marchi <simon.marchi@ericsson.com>
10716
10717 * cli-out.c (cli_ui_out::do_redirect): Change return type to
10718 void.
10719 * cli-out.h (cli_ui_out::do_redirect): Likewise.
10720 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
10721 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
10722 * ui-out.c (ui_out::redirect): Likewise.
10723 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
10724 * cli/cli-logging.c (set_logging_redirect): Update call site of
10725 ui_out::redirect.
10726 (handle_redirections): Likewise.
10727 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
10728 * top.c (execute_command_to_string): Likewise.
10729 * utils.c (do_ui_out_redirect_pop): Likewise.
10730
df294654
SM
107312017-01-10 Simon Marchi <simon.marchi@ericsson.com>
10732
10733 * stack.c (_initialize_stack): Update "frame" command help message.
10734
f5e6296e
IB
107352017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
10736
10737 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
10738
0e2d6fa6
YQ
107392017-01-06 Yao Qi <yao.qi@linaro.org>
10740
10741 * x86-linux-nat.h: Include gdb_proc_service.h.
10742
44d6d3f9
YQ
107432017-01-06 Yao Qi <yao.qi@linaro.org>
10744
10745 * ser-base.h: Include serial.h.
10746
656731fe
YQ
107472017-01-06 Yao Qi <yao.qi@linaro.org>
10748
10749 * ppc-linux-tdep.h: Include ppc-tdep.h.
10750
1ca8f924
YQ
107512017-01-06 Yao Qi <yao.qi@linaro.org>
10752
10753 * nat/amd64-linux-siginfo.h: Include signal.h.
10754
bc3008c4
YQ
107552017-01-06 Yao Qi <yao.qi@linaro.org>
10756
10757 * nat/aarch64-linux-hw-point.h: Include break-common.h.
10758
66c80d03
YQ
107592017-01-06 Yao Qi <yao.qi@linaro.org>
10760
10761 * mi/mi-parse.h: Include mi-cmds.h.
10762
051d2dda
YQ
107632017-01-06 Yao Qi <yao.qi@linaro.org>
10764
10765 * inf-loop.c: Don't include "target.h".
10766 * inf-loop.h: Include it here.
10767
8018d34f
YQ
107682017-01-06 Yao Qi <yao.qi@linaro.org>
10769
10770 * dfp.h: Include "dboulest.h" and "expression.h".
10771
c0b8369c
YQ
107722017-01-06 Yao Qi <yao.qi@linaro.org>
10773
10774 * ax-gdb.h: Include "ax.h".
10775
ad5cba2a
YQ
107762017-01-06 Yao Qi <yao.qi@linaro.org>
10777
10778 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
10779 with nat/gdb_ptrace.h.
10780
1c33cd7f
YQ
107812017-01-05 Yao Qi <yao.qi@linaro.org>
10782
10783 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
10784 new line.
10785 (mips64_fbsd_sigframe_init): Likewise.
10786
c988ac1d
JB
107872017-01-04 John Baldwin <jhb@FreeBSD.org>
10788
10789 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
10790 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
10791
b268007c
JB
107922017-01-04 John Baldwin <jhb@FreeBSD.org>
10793
10794 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
10795 * NEWS: Mention new FreeBSD/mips native configuration.
10796 * config/mips/fbsd.mh: New file.
10797 * configure.host: Add mips*-*-freebsd*.
10798 * mips-fbsd-nat.c: New file.
10799
387360da
JB
108002017-01-04 John Baldwin <jhb@FreeBSD.org>
10801
10802 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
10803 (ALLDEPFILES): Add mips-fbsd-tdep.c.
10804 * NEWS: Mention new FreeBSD/mips target.
10805 * configure.tgt: Add mips*-*-freebsd*.
10806 * mips-fbsd-tdep.c: New file.
10807 * mips-fbsd-tdep.h: New file.
10808
2aaaf250
YQ
108092017-01-04 Yao Qi <yao.qi@linaro.org>
10810
10811 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
10812 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
10813
61baf725
JB
108142017-01-01 Joel Brobecker <brobecker@adacore.com>
10815
6dbb839a 10816 Update copyright year range in all GDB files.
61baf725 10817
c113e7ff 108182017-01-01 Joel Brobecker <brobecker@adacore.com>
ce0db137 10819
c113e7ff 10820 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
ce0db137 10821
c113e7ff 10822For older changes see ChangeLog-2016.
c906108c
SS
10823\f
10824Local Variables:
10825mode: change-log
10826left-margin: 8
10827fill-column: 74
10828version-control: never
57da7796 10829coding: utf-8
c906108c 10830End:
This page took 2.562191 seconds and 4 git commands to generate.