2ffa23f830727e72a0012a90a4a4c0af29b6b586
[deliverable/binutils-gdb.git] / gdb / ChangeLog
1 2017-10-05 John Baldwin <jhb@FreeBSD.org>
2
3 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_EHDRFLAGS and
4 AT_HWCAP.
5
6 2017-10-05 Tristan Gingold <tgingold@free.fr>
7
8 * MAINTAINERS (Misc): Update my email address.
9
10 2017-10-04 Pedro Alves <palves@redhat.com>
11
12 * remote.c (get_remote_arch_state): New 'gdbarch' parameter. Use
13 it instead of target_gdbarch.
14 (get_remote_state, get_remote_packet_size): Adjust
15 get_remote_arch_state calls, passing down target_gdbarch
16 explicitly.
17 (packet_reg_from_regnum, packet_reg_from_pnum): New parameter
18 'gdbarch' and use it instead of target_gdbarch.
19 (get_memory_packet_size): Adjust get_remote_arch_state calls,
20 passing down target_gdbarch explicitly.
21 (struct stop_reply) <arch>: New field.
22 (remote_parse_stop_reply): Use the stopped thread's architecture,
23 not the current inferior's. Save the architecture in the
24 stop_reply.
25 (process_stop_reply): Use the stop reply's architecture.
26 (process_g_packet, remote_fetch_registers)
27 (remote_prepare_to_store, store_registers_using_G)
28 (remote_store_registers): Adjust get_remote_arch_state calls,
29 using the regcache's architecture.
30 (remote_get_trace_status): Adjust get_remote_arch_state calls,
31 passing down target_gdbarch explicitly.
32 * spu-multiarch.c (spu_thread_architecture): Defer to the target
33 beneath instead of calling target_gdbarch.
34 * target.c (default_thread_architecture): Use the specified
35 inferior's architecture, instead of the current inferior's
36 architecture (via target_gdbarch).
37
38 2017-10-04 Pedro Alves <palves@redhat.com>
39
40 * regcache.c (get_thread_arch_regcache): Remove null_ptid special
41 case.
42 (regcache_print): Handle !target_has_registers here instead.
43
44 2017-10-04 Pedro Alves <palves@redhat.com>
45
46 * frame.c (create_test_frame): Delete.
47 * frame.h (create_test_frame): Delete.
48 * gdbarch-selftests.c: Include gdbthread.h and target.h.
49 (class regcache_test): Delete.
50 (test_target_has_registers, test_target_has_stack)
51 (test_target_has_memory, test_target_prepare_to_store)
52 (test_target_store_registers): New functions.
53 (test_target_ops): New class.
54 (register_to_value_test): Error out if there's already a
55 process_stratum (or higher) target pushed. Create a fuller mock
56 environment, with mock target_ops, inferior, address space, thread
57 and inferior_ptid.
58 * progspace.c (struct address_space): Move to ...
59 * progspace.h (struct address_space): ... here.
60 * regcache.h (regcache::~regcache, regcache::raw_write)
61 [GDB_SELF_TEST]: No longer virtual.
62
63 2017-10-04 Simon Marchi <simon.marchi@ericsson.com>
64
65 * mi/mi-main.c (list_available_thread_groups): Reverse filter logic.
66
67 2017-10-04 Pedro Alves <palves@redhat.com>
68
69 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Move code
70 out of 'between TRY and CATCH'.
71
72 2017-10-04 Pedro Alves <palves@redhat.com>
73
74 * cli/cli-cmds.c (complete_command): Add missing END_CATCH.
75 * common/common-exceptions.h (TRY): Open an outermost scope.
76 Expand intro comment.
77 (CATCH): Reindent.
78 (END_CATCH): Close the outermost scope.
79 * completer.c (complete_line_internal): Add missing END_CATCH.
80
81 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
82
83 * NEWS (Changes since GDB 8.0): Add entry about new
84 'set-cwd-on-gdbserver' feature.
85 (New remote packets): Add entry for QSetWorkingDir.
86 * common/common-inferior.h (set_inferior_cwd): New prototype.
87 * infcmd.c (set_inferior_cwd): Remove "static".
88 (show_cwd_command): Expand text to include remote debugging.
89 * remote.c: Add PACKET_QSetWorkingDir.
90 (remote_protocol_features) <QSetWorkingDir>: New entry for
91 PACKET_QSetWorkingDir.
92 (extended_remote_set_inferior_cwd): New function.
93 (extended_remote_create_inferior): Call
94 "extended_remote_set_inferior_cwd".
95 (_initialize_remote): Call "add_packet_config_cmd" for
96 QSetWorkingDir.
97
98 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
99
100 * NEWS (New commands): Mention "set/show cwd".
101 * cli/cli-cmds.c (_initialize_cli_cmds): Mention "set cwd" on
102 "cd" command's help text.
103 * common/common-inferior.h (get_inferior_cwd): New prototype.
104 * infcmd.c (inferior_cwd_scratch): New global variable.
105 (set_inferior_cwd): New function.
106 (get_inferior_cwd): Likewise.
107 (set_cwd_command): Likewise.
108 (show_cwd_command): Likewise.
109 (_initialize_infcmd): Add "set/show cwd" commands.
110 * inferior.h (class inferior) <cwd>: New field.
111 * nat/fork-inferior.c: Include "gdb_tilde_expand.h".
112 (fork_inferior): Change inferior's cwd before its execution.
113 * windows-nat.c (windows_create_inferior): Pass inferior's cwd
114 to CreateProcess.
115
116 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
117
118 * Makefile.in (SFILES): Add gdb_tilde_expand.c.
119 (HFILES_NO_SRCDIR): Add gdb_tilde_expand.h.
120 (COMMON_OBS): Add gdb_tilde_expand.o.
121 * common/gdb_tilde_expand.c: New file.
122 * common/gdb_tilde_expand.h: Likewise.
123
124 2017-10-03 Maciej W. Rozycki <macro@imgtec.com>
125
126 * gdbarch.sh (objfile): Remove duplicate declaration.
127 * gdbarch.h: Regenerate.
128
129 2017-10-03 Tom Tromey <tom@tromey.com>
130
131 * utils.c (internal_vproblem): Use string_vprintf.
132
133 2017-10-03 Tom Tromey <tom@tromey.com>
134
135 * printcmd.c (info_symbol_command): Use std::string.
136
137 2017-10-03 Tom Tromey <tom@tromey.com>
138
139 * top.c (gdb_safe_append_history): Use std::string.
140
141 2017-10-03 Tom Tromey <tom@tromey.com>
142
143 * event-top.c (stdin_event_handler): Update.
144 * main.c (captured_main_1): Update.
145 * top.h (make_delete_ui_cleanup): Remove.
146 (struct ui): Add constructor and destructor.
147 (new_ui, delete_ui): Remove.
148 * top.c (make_delete_ui_cleanup): Remove.
149 (new_ui_command): Use std::unique_ptr.
150 (delete_ui_cleanup): Remove.
151 (ui::ui): Rename from new_ui. Update.
152 (free_ui): Remove.
153 (ui::~ui): Rename from delete_ui. Update.
154
155 2017-10-03 Tom Tromey <tom@tromey.com>
156
157 * symfile.c (load_progress): Use gdb::byte_vector.
158
159 2017-10-03 Tom Tromey <tom@tromey.com>
160
161 * mi/mi-main.c (mi_cmd_trace_frame_collected): Remove unused
162 declaration.
163 * printcmd.c (x_command): Remove unused declaration.
164 * symfile.c (symbol_file_command): Remove unused declaration.
165
166 2017-10-03 Tom Tromey <tom@tromey.com>
167
168 * utils.c (internal_vproblem): Use std::string.
169 (defaulted_query): Likewise.
170
171 2017-10-03 Tom Tromey <tom@tromey.com>
172
173 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Update.
174 * top.c (execute_command_to_string): Update.
175 * utils.c (make_cleanup_restore_page_info): Remove.
176 (do_restore_page_info_cleanup): Remove.
177 (set_batch_flag_and_restore_page_info):
178 New.
179 (make_cleanup_restore_page_info): Remove.
180 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
181 (~set_batch_flag_and_restore_page_info): New
182 (make_cleanup_restore_uinteger): Remove.
183 (make_cleanup_restore_integer): Remove.
184 (struct restore_integer_closure): Remove.
185 (restore_integer): Remove.
186 * utils.h (struct set_batch_flag_and_restore_page_info): New
187 class.
188 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
189 (make_cleanup_restore_page_info): Remove.
190 (make_cleanup_restore_uinteger) Remove.
191 (make_cleanup_restore_integer) Remove.
192
193 2017-10-03 Tom Tromey <tom@tromey.com>
194
195 * record-full.h (record_full_gdb_operation_disable_set): Return
196 scoped_restore_tmpl<int>.
197 * infrun.c (adjust_pc_after_break): Update.
198 (handle_signal_stop): Update.
199 * record-full.c (record_full_gdb_operation_disable_set): Return
200 scoped_restore_tmpl<int>.
201 (record_full_wait_1, record_full_insert_breakpoint)
202 (record_full_remove_breakpoint, record_full_save)
203 (record_full_goto_insn): Update.
204
205 2017-10-02 Tom Tromey <tom@tromey.com>
206
207 PR rust/22236:
208 * rust-lang.c (rust_val_print_str): New function.
209 (val_print_struct): Call it.
210 (rust_subscript): Preserve name of slice type.
211
212 2017-10-02 Tom Tromey <tom@tromey.com>
213
214 * rust-lang.c (rust_subscript): Handle slices in
215 EVAL_AVOID_SIDE_EFFECTS case.
216
217 2017-10-02 Tom Tromey <tom@tromey.com>
218
219 * rust-lang.c (rust_slice_type_p): Recognize &str as a slice type.
220
221 2017-10-02 Tom Tromey <tom@tromey.com>
222
223 * rust-lang.h (rust_slice_type): Add "extern".
224
225 2017-10-02 Tom Tromey <tom@tromey.com>
226 Pedro Alves <palves@redhat.com>
227
228 * ada-lang.h (ada_exc_info::operator<): Make const.
229 (ada_exc_info::operator==): Make const.
230 * ada-lang.c (ada_exc_info::operator<, ada_exc_info::operator==):
231 Make const.
232
233 2017-09-29 Tom Tromey <tom@tromey.com>
234
235 * target.c (read_whatever_is_readable): Change type of "result".
236 Update.
237 (free_memory_read_result_vector): Remove.
238 (read_memory_robust): Change return type. Update.
239 * mi/mi-main.c (mi_cmd_data_read_memory_bytes): Update. Use
240 bin2hex, std::string.
241 * target.h (memory_read_result_s): Remove typedef.
242 (free_memory_read_result_vector): Remove.
243 (read_memory_robust): Return std::vector.
244
245 2017-09-29 Tom Tromey <tom@tromey.com>
246
247 * mi/mi-main.c (captured_mi_execute_command): Use scope_restore.
248
249 2017-09-29 Tom Tromey <tom@tromey.com>
250
251 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Update.
252 * ada-lang.h (struct ada_exc_info): Remove typedef. Declare
253 operator< and operator==.
254 (ada_exceptions_list): Return a std::vector.
255 * ada-lang.c (ada_exc_info::operator<): Rename from
256 compare_ada_exception_info.
257 (ada_exc_info::operator==): New.
258 (sort_remove_dups_ada_exceptions_list): Change type of
259 "exceptions".
260 (ada_add_standard_exceptions, ada_add_exceptions_from_frame)
261 (ada_add_global_exceptions): Likewise.
262 (ada_exceptions_list_1): Return a std::vector.
263 (ada_exceptions_list): Likewise.
264
265 2017-09-29 Tom Tromey <tom@tromey.com>
266
267 * mi/mi-main.c (struct print_one_inferior_data) <inferiors>: Now a
268 'std::set *'.
269 (print_one_inferior): Update.
270 (free_vector_of_ints): Remove.
271 (list_available_thread_groups): Change "ids" to std::set.
272 (mi_cmd_list_thread_groups): Update.
273 (struct collect_cores_data) <core>: Now a std::set.
274 (collect_cores): Update.
275 (unique): Remove.
276 (print_one_inferior): Update.
277
278 2017-09-29 Tom Tromey <tom@tromey.com>
279
280 * mi/mi-main.c (mi_execute_cli_command): Use std::string.
281 (mi_execute_async_cli_command): Likewise.
282 (mi_cmd_trace_frame_collected): Use field_fmt.
283
284 2017-09-29 Tom Tromey <tom@tromey.com>
285
286 * mi/mi-main.c (mi_cmd_data_write_memory_bytes): Use
287 gdb::byte_vector.
288
289 2017-09-29 Tom Tromey <tom@tromey.com>
290
291 * mi/mi-parse.c (mi_parse): Remove unused declaration.
292
293 2017-09-29 Tom Tromey <tom@tromey.com>
294
295 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Don't copy "oarg".
296
297 2017-09-29 Tom Tromey <tom@tromey.com>
298
299 * varobj.h (varobj_gen_name): Return std::string.
300 * varobj.c (varobj_gen_name): Return std::string.
301 * mi/mi-cmd-var.c (mi_cmd_var_create): Use std::string.
302 (mi_cmd_var_delete): Don't copy "name".
303
304 2017-09-29 Tom Tromey <tom@tromey.com>
305
306 * mi/mi-cmd-break.c (mi_argv_to_format): Return std::string.
307 (mi_cmd_break_insert_1): Update.
308
309 2017-09-29 Tom Tromey <tom@tromey.com>
310
311 * target.h (make_scoped_defer_target_commit_resume): Update.
312 * target.c (make_scoped_defer_target_commit_resume): Rename from
313 make_cleanup_defer_target_commit_resume. Return a
314 scoped_restore.
315 * infrun.c (proceed): Use make_scoped_defer_target_commit_resume.
316
317 2017-09-29 Tom Tromey <tom@tromey.com>
318
319 * main.c (captured_main_1): Remove unused declaration.
320 * spu-multiarch.c (parse_spufs_run): Remove unused declaration.
321
322 2017-09-29 Tom Tromey <tom@tromey.com>
323
324 * symtab.c (search_symbols): Remove unused outer cleanup.
325 (make_source_files_completion_list): Remove unused declaration.
326
327 2017-09-29 Tom Tromey <tom@tromey.com>
328
329 * mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.
330
331 2017-09-29 Tom Tromey <tom@tromey.com>
332
333 * xstormy16-tdep.c (xstormy16_push_dummy_call): Use
334 gdb::byte_vector.
335
336 2017-09-29 Tom Tromey <tom@tromey.com>
337
338 * complaints.c (vcomplaint): Use std::string.
339
340 2017-09-29 Tom Tromey <tom@tromey.com>
341
342 * tracepoint.c (trace_variable_command): Use std::string.
343 (encode_actions_1): Remove unused declarations.
344 (create_tsv_from_upload): Use std::string.
345
346 2017-09-29 Tom Tromey <tom@tromey.com>
347
348 * cp-support.c (gdb_demangle): Use std::string.
349
350 2017-09-29 Tom Tromey <tom@tromey.com>
351
352 * stack.c (parse_frame_specification): Use std::string
353 (info_frame_command): Use gdb::unique_xmalloc_ptr.
354
355 2017-09-29 Tom Tromey <tom@tromey.com>
356
357 * tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.
358
359 2017-09-29 Tom Tromey <tom@tromey.com>
360
361 * utils.c (vfprintf_maybe_filtered): Use std::string.
362 (vfprintf_unfiltered): Likewise.
363
364 2017-09-29 Tom Tromey <tom@tromey.com>
365
366 * event-top.c (top_level_prompt): Return std::string.
367 (display_gdb_prompt): Update.
368
369 2017-09-29 Tom Tromey <tom@tromey.com>
370
371 * unittests/common-utils-selftests.c (format): New function.
372 (string_vprintf_tests): New function.
373 (_initialize_common_utils_selftests): Register new tests.
374 * common/common-utils.c (string_vprintf): New function.
375 * common/common-utils.h (string_vprintf): Declare.
376
377 2017-09-29 Pedro Alves <palves@redhat.com>
378
379 * common/rsp-low.c (unpack_varlen_hex): Constify.
380 * common/rsp-low.h (unpack_varlen_hex): Constify.
381 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
382 Constify.
383 * remote.c (remote_set_permissions, read_ptid)
384 (remote_current_thread, remote_get_threads_with_qthreadinfo)
385 (remote_static_tracepoint_marker_at)
386 (remote_static_tracepoint_markers_by_strid)
387 (stop_reply_extract_thread, remote_parse_stop_reply): Constify.
388 * tracepoint.c (parse_trace_status, parse_tracepoint_status)
389 (parse_tracepoint_definition, parse_tsv_definition)
390 (parse_static_tracepoint_marker_definition): Constify.
391 * tracepoint.h (parse_static_tracepoint_marker_definition)
392 (parse_trace_status, parse_tracepoint_status)
393 (parse_tracepoint_definition, parse_tsv_definition): Constify.
394
395 2017-09-29 Pedro Alves <palves@redhat.com>
396
397 * remote.c (target_buf, target_buf_size): Delete.
398 (remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
399 Use the connection's packet buffer instead.
400 All callers adjusted.
401 (_initialize_remote): Remove references to target_buf and
402 target_buf_size.
403
404 2017-09-28 Pedro Alves <palves@redhat.com>
405
406 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
407 unittests/common-utils-selftests.c.
408 (SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
409 (COMMON_OBS): Remove utils-selftests.o.
410 * utils-selftests.c: Move to ...
411 * unittests/common-utils-selftests.c: ... here and rename self
412 test to "string_printf".
413
414 2017-09-28 Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com> (tiny patch)
415
416 * dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
417 having NULL cus or tus.
418
419 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
420
421 * arm-tdep.c: (convert_from_extended): Remove.
422 (convert_to_extended): Likewise.
423 (arm_extract_return_value): Use convert_typed_floating.
424 (arm_store_return_value): Likewise.
425
426 * sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
427 * sh-tdep.c: Do not include "floatformat.h".
428 (sh_littlebyte_bigword_type): New function.
429 (sh_register_convert_to_virtual): Use convert_typed_floating.
430 (sh_register_convert_to_raw): Likewise.
431 * sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
432 (sh64_littlebyte_bigword_type): New function.
433 (sh64_extract_return_value): Use convert_typed_floating.
434 (sh64_register_convert_to_virtual): Likewise.
435 (sh64_register_convert_to_raw): Likewise.
436
437 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
438
439 * doublest.h (floatformat_from_type): Move to gdbtypes.h.
440 * doublest.c (floatformat_from_type): Move to gdbtypes.c.
441
442 * gdbtypes.h (union type_specific): Make field floatformat hold
443 just a single struct floatformat, not an array.
444 (floatformat_from_type): Move here.
445 * gdbtypes.c (floatformat_from_type): Move here. Update to
446 changed TYPE_FLOATFORMAT definition.
447 (verify_floatformat): Update to changed TYPE_FLOATFORMAT.
448 (recursive_dump_type): Likewise.
449 (init_float_type): Install correct floatformat for byte order.
450 (arch_float_type): Likewise.
451
452 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
453
454 * gdbtypes.c (init_type): Change incoming argument from
455 length-in-bytes to length-in-bits. Assert length is a
456 multiple of TARGET_CHAR_BITS.
457 (arch_type, arch_flags_type): Likewise.
458 (init_integer_type): Update call to init_type.
459 (init_character_type): Likewise.
460 (init_boolean_type): Likewise.
461 (init_float_type): Likewise.
462 (init_decfloat_type): Likewise.
463 (init_complex_type): Likewise.
464 (init_pointer_type): Likewise.
465 (objfile_type): Likewise.
466 (arch_integer_type): Update call to arch_type.
467 (arch_character_type): Likewise.
468 (arch_boolean_type): Likewise.
469 (arch_float_type): Likewise.
470 (arch_decfloat_type): Likewise.
471 (arch_complex_type): Likewise.
472 (arch_pointer_type): Likewise.
473 (gdbtypes_post_init): Likewise.
474
475 * dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
476 (read_base_type): Likewise.
477 * mdebugread.c (basic_type): Likewise.
478 * stabsread.c (dbx_init_float_type): Likewise.
479 (rs6000_builtin_type): Likewise.
480 (read_range_type): Likewise. Also, fix call to init_integer_type
481 with erroneous length argument.
482
483 * ada-lang.c (ada_language_arch_info): Update call to arch_type.
484 * d-lang.c (build_d_types): Likewise.
485 * f-lang.c (build_fortran_types): Likewise.
486 * go-lang.c (build_go_types): Likewise.
487 * opencl-lang.c (build_opencl_types): Likewise.
488 * jit.c (finalize_symtab): Likewise.
489 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
490 (build_std_type_info_type): Likewise.
491 * target-descriptions.c (tdesc_gdb_type): Likewise. Also,
492 update call to arch_flags_type.
493
494 * linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
495 arch_type.
496 * fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
497 * windows-tdep.c (windows_get_tlb_type): Likewise.
498
499 * avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
500 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
501 * m32c-tdep.c (make_types): Likewise.
502 * rl78-tdep.c (rl78_gdbarch_init): Likewise.
503 (rl78_psw_type): Update call to arch_flags_type.
504 * m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
505 * rx-tdep.c (rx_psw_type): Likewise.
506 (rx_fpsw_type): Likewise.
507 * sparc-tdep.c (sparc_psr_type): Likewise.
508 (sparc_fsr_type): Likewise.
509 * sparc64-tdep.c (sparc64_pstate_type): Likewise.
510 (sparc64_ccr_type): Likewise.
511 (sparc64_fsr_type): Likewise.
512 (sparc64_fprs_type): Likewise.
513
514 2017-09-27 Tom Tromey <tom@tromey.com>
515
516 * findcmd.c (find_command): Constify.
517
518 2017-09-27 Tom Tromey <tom@tromey.com>
519
520 * ada-tasks.c (task_command_1, task_command): Constify.
521
522 2017-09-27 Tom Tromey <tom@tromey.com>
523
524 * symtab.c (maintenance_print_symbol_cache)
525 (maintenance_flush_symbol_cache)
526 (maintenance_print_symbol_cache_statistics): Constify.
527
528 2017-09-27 Tom Tromey <tom@tromey.com>
529
530 * inferior.c (detach_inferior_command, kill_inferior_command)
531 (inferior_command): Constify.
532
533 2017-09-27 Tom Tromey <tom@tromey.com>
534
535 * regcache.c (regcache_print, maintenance_print_registers)
536 (maintenance_print_raw_registers)
537 (maintenance_print_cooked_registers)
538 (maintenance_print_register_groups)
539 (maintenance_print_remote_registers): Constify.
540
541 2017-09-27 Tom Tromey <tom@tromey.com>
542
543 * printcmd.c (map_display_numbers, undisplay_command)
544 (enable_disable_display_command, enable_display_command)
545 (disable_display_command): Constify.
546
547 2017-09-27 Tom Tromey <tom@tromey.com>
548
549 * breakpoint.h (delete_command): Don't declare.
550 * breakpoint.c (delete_command, enable_once_command)
551 (enable_count_command, enable_delete_command, breakpoint_1)
552 (maintenance_info_breakpoints, stopin_command, stopat_command)
553 (delete_command, delete_trace_command, save_breakpoints)
554 (save_breakpoints_command, save_tracepoints_command): Constify.
555
556 2017-09-27 Tom Tromey <tom@tromey.com>
557
558 * macrocmd.c (macro_expand_command, macro_expand_once_command)
559 (skip_ws, extract_identifier, macro_define_command)
560 (macro_undef_command, macro_list_command): Constify.
561
562 2017-09-27 Tom Tromey <tom@tromey.com>
563
564 * infcmd.c (environment_info, set_environment_command)
565 (unset_environment_command, path_info, info_proc_cmd_1)
566 (info_proc_cmd_mappings, info_proc_cmd_stat)
567 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
568 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
569
570 2017-09-27 Tom Tromey <tom@tromey.com>
571
572 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
573 Constify.
574
575 2017-09-27 Tom Tromey <tom@tromey.com>
576
577 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
578
579 2017-09-27 Tom Tromey <tom@tromey.com>
580
581 * demangle.c (demangle_command): Constify.
582
583 2017-09-27 Tom Tromey <tom@tromey.com>
584
585 * progspace.c (maintenance_info_program_spaces_command):
586 Constify.
587
588 2017-09-27 Tom Tromey <tom@tromey.com>
589
590 * compile/compile.c (check_raw_argument, compile_file_command)
591 (compile_code_command, compile_print_command): Constify.
592
593 2017-09-27 Tom Tromey <tom@tromey.com>
594
595 * reggroups.c (maintenance_print_reggroups): Constify.
596
597 2017-09-27 Tom Tromey <tom@tromey.com>
598
599 * dwarf2read.c (save_gdb_index_command): Constify.
600
601 2017-09-27 Tom Tromey <tom@tromey.com>
602
603 * stap-probe.c (info_probes_stap_command): Constify.
604
605 2017-09-27 Tom Tromey <tom@tromey.com>
606
607 * fork-child.c (unset_exec_wrapper_command): Constify.
608
609 2017-09-27 Tom Tromey <tom@tromey.com>
610
611 * btrace.c (get_uint, get_context_size, no_chunk)
612 (maint_btrace_packet_history_cmd)
613 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
614 (maint_info_btrace_cmd): Constify.
615
616 2017-09-27 Tom Tromey <tom@tromey.com>
617
618 * reverse.c (delete_bookmark_command): Constify.
619
620 2017-09-27 Tom Tromey <tom@tromey.com>
621
622 * remote.c (set_memory_packet_size)
623 (set_memory_write_packet_size, show_memory_write_packet_size)
624 (set_memory_read_packet_size, show_memory_read_packet_size)
625 (compare_sections_command, packet_command, remote_put_command)
626 (remote_get_command, remote_delete_command): Constify.
627
628 2017-09-27 Tom Tromey <tom@tromey.com>
629
630 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
631 (set_mipsfpu_double_command, set_mipsfpu_none_command)
632 (set_mipsfpu_auto_command): Constify.
633
634 2017-09-27 Tom Tromey <tom@tromey.com>
635
636 * cli/cli-cmds.h (cd_command): Constify.
637 * cli/cli-cmds.c (cd_command): Constify.
638
639 2017-09-27 Tom Tromey <tom@tromey.com>
640
641 * thread.c (thread_name_command, thread_find_command): Constify.
642
643 2017-09-27 Tom Tromey <tom@tromey.com>
644
645 * probe.c (enable_probes_command, disable_probes_command):
646 Constify.
647
648 2017-09-27 Tom Tromey <tom@tromey.com>
649
650 * symfile.c (symbol_file_command): Constify.
651 * gdbcore.h (deprecated_file_changed_hook): Constify.
652 * exec.c (deprecated_file_changed_hook, exec_file_command)
653 (file_command): Constify.
654 * defs.h (symbol_file_command): Constify.
655
656 2017-09-27 Tom Tromey <tom@tromey.com>
657
658 * remote-fileio.c (set_system_call_allowed)
659 (show_system_call_allowed): Constify.
660
661 2017-09-27 Tom Tromey <tom@tromey.com>
662
663 * tracepoint.c (delete_trace_variable_command)
664 (tfind_end_command, tfind_start_command, tfind_pc_command)
665 (tfind_tracepoint_command, tfind_line_command)
666 (tfind_range_command, tfind_outside_command): Constify.
667
668 2017-09-27 Tom Tromey <tom@tromey.com>
669
670 * ax-gdb.c (maint_agent_printf_command, agent_command)
671 (agent_eval_command): Constify.
672
673 2017-09-27 Tom Tromey <tom@tromey.com>
674
675 * tracepoint.c (info_scope_command): Constify.
676 * python/python.c (gdbpy_decode_line): Constify.
677 * python/py-breakpoint.c (bppy_init): Constify.
678 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
679 * location.h: (new_linespec_location)
680 (string_to_event_location_basic, string_to_event_location):
681 Constify.
682 * location.c (new_linespec_location)
683 (string_to_event_location_basic, string_to_event_location):
684 Constify.
685 * linespec.h (decode_line_with_current_source)
686 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
687 * linespec.c (linespec_lex_to_end)
688 (decode_line_with_current_source)
689 (decode_line_with_last_displayed): Constify.
690 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
691 Constify.
692 * cli/cli-cmds.c (edit_command, list_command): Constify.
693 * breakpoint.h (until_break_command, watch_command_wrapper)
694 (awatch_command_wrapper, rwatch_command_wrapper)
695 (init_ada_exception_breakpoint): Constify.
696 * breakpoint.c (break_command_1, dprintf_command)
697 (break_range_command, watch_command_wrapper)
698 (rwatch_command_wrapper, awatch_command_wrapper)
699 (until_break_command, init_ada_exception_breakpoint)
700 (strace_marker_create_sals_from_location, trace_command)
701 (ftrace_command, strace_command, struct tracepoint): Constify.
702 * ax-gdb.c (agent_command_1): Constify.
703 * ada-lang.c (ada_exception_sal): Constify.
704
705 2017-09-27 Tom Tromey <tom@tromey.com>
706
707 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
708 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
709 (get_context_size, no_chunk, get_insn_history_modifiers)
710 (cmd_record_insn_history, get_call_history_modifiers)
711 (cmd_record_call_history): Constify.
712
713 2017-09-27 Tom Tromey <tom@tromey.com>
714
715 * source.c (show_substitute_path_command)
716 (unset_substitute_path_command, set_substitute_path_command):
717 Constify.
718
719 2017-09-27 Tom Tromey <tom@tromey.com>
720
721 * typeprint.c (maintenance_print_type): Constify.
722 * maint.c (maintenance_dump_me, maintenance_demangle)
723 (maintenance_time_display, maintenance_info_sections)
724 (maintenance_print_statistics, maintenance_deprecate)
725 (maintenance_undeprecate): Constify.
726 (maintenance_do_deprecate): Constify. Use std::string.
727 (maintenance_selftest): Constify.
728 * gdbtypes.h (maintenance_print_type): Constify.
729
730 2017-09-27 Tom Tromey <tom@tromey.com>
731
732 * hppa-tdep.c (unwind_command): Constify.
733
734 2017-09-27 Tom Tromey <tom@tromey.com>
735
736 * target-descriptions.c (unset_tdesc_filename_cmd)
737 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
738 Constify.
739
740 2017-09-27 Tom Tromey <tom@tromey.com>
741
742 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
743
744 2017-09-27 Tom Tromey <tom@tromey.com>
745
746 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
747
748 2017-09-27 Tom Tromey <tom@tromey.com>
749
750 * tui/tui-regs.c (tui_reg_command): Constify.
751
752 2017-09-27 Tom Tromey <tom@tromey.com>
753
754 * skip.c (skip_file_command, skip_function_command)
755 (skip_enable_command, skip_disable_command, skip_delete_command):
756 Constify.
757
758 2017-09-27 Tom Tromey <tom@tromey.com>
759
760 * record-btrace.c (cmd_record_btrace_bts_start)
761 (cmd_record_btrace_pt_start): Constify.
762
763 2017-09-27 Tom Tromey <tom@tromey.com>
764
765 * symmisc.c (maintenance_print_symbols)
766 (maintenance_print_msymbols, maintenance_print_objfiles)
767 (maintenance_info_symtabs, maintenance_check_symtabs)
768 (maintenance_expand_symtabs, maintenance_info_line_tables):
769 Constify.
770
771 2017-09-27 Tom Tromey <tom@tromey.com>
772
773 * top.c (new_ui_command): Constify.
774
775 2017-09-27 Tom Tromey <tom@tromey.com>
776
777 * symfile.c (add_symbol_file_command)
778 (remove_symbol_file_command, list_overlays_command)
779 (map_overlay_command, unmap_overlay_command)
780 (overlay_auto_command, overlay_manual_command)
781 (overlay_off_command, overlay_load_command): Constify.
782
783 2017-09-27 Tom Tromey <tom@tromey.com>
784
785 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
786 (info_spu_mailbox_command, info_spu_dma_command)
787 (info_spu_proxydma_command): Constify.
788
789 2017-09-27 Tom Tromey <tom@tromey.com>
790
791 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
792
793 2017-09-27 Tom Tromey <tom@tromey.com>
794
795 * cli/cli-script.c (user_defined_command): Constify.
796
797 2017-09-27 Tom Tromey <tom@tromey.com>
798
799 * cli/cli-dump.c (dump_memory_command, dump_value_command)
800 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
801 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
802 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
803 (dump_binary_value, append_binary_memory, append_binary_value):
804 Constify.
805 (struct dump_context) <func>: Constify.
806 (add_dump_command): Update.
807
808 2017-09-27 Tom Tromey <tom@tromey.com>
809
810 * cli/cli-cmds.c (show_version, show_configuration)
811 (source_command, show_user): Constify.
812
813 2017-09-27 Tom Tromey <tom@tromey.com>
814
815 * target.c (maintenance_print_target_stack): Constify.
816
817 2017-09-27 Tom Tromey <tom@tromey.com>
818
819 * interps.c (interpreter_exec_cmd): Constify.
820
821 2017-09-27 Tom Tromey <tom@tromey.com>
822
823 * record-full.c (cmd_record_full_restore): Constify.
824
825 2017-09-27 Tom Tromey <tom@tromey.com>
826
827 * memattr.c (enable_mem_command, disable_mem_command)
828 (delete_mem_command): Constify.
829
830 2017-09-27 Tom Tromey <tom@tromey.com>
831
832 * value.c (show_convenience): Constify.
833
834 2017-09-27 Tom Tromey <tom@tromey.com>
835
836 * gdbcore.h (core_file_command): Update.
837 * corefile.c (core_file_command): Constify.
838
839 2017-09-27 Tom Tromey <tom@tromey.com>
840
841 * user-regs.c (maintenance_print_user_registers): Constify.
842
843 2017-09-27 Tom Tromey <tom@tromey.com>
844
845 * cp-namespace.c (maintenance_cplus_namespace): Constify.
846
847 2017-09-27 Tom Tromey <tom@tromey.com>
848
849 * cp-support.c (first_component_command): Constify.
850
851 2017-09-27 Tom Tromey <tom@tromey.com>
852
853 * psymtab.c (maintenance_print_psymbols)
854 (maintenance_info_psymtabs, maintenance_check_psymtabs):
855 Constify.
856
857 2017-09-27 Tom Tromey <tom@tromey.com>
858
859 * windows-tdep.c (display_tib): Constify.
860
861 2017-09-27 Tom Tromey <tom@tromey.com>
862
863 * linux-fork.c (delete_checkpoint_command)
864 (detach_checkpoint_command): Constify.
865
866 2017-09-27 Tom Tromey <tom@tromey.com>
867
868 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
869
870 2017-09-27 Tom Tromey <tom@tromey.com>
871
872 * arc-tdep.c (dump_arc_instruction_command): Constify.
873
874 2017-09-27 Tom Tromey <tom@tromey.com>
875
876 * valprint.c (set_radix, show_radix): Constify.
877
878 2017-09-27 Tom Tromey <tom@tromey.com>
879
880 * dtrace-probe.c (info_probes_dtrace_command): Constify.
881
882 2017-09-27 Tom Tromey <tom@tromey.com>
883
884 * command.h (not_just_help_class_command): Update.
885 * cli/cli-decode.h (not_just_help_class_command): Update.
886 * cli/cli-decode.c (not_just_help_class_command): Constify.
887
888 2017-09-27 Tom Tromey <tom@tromey.com>
889
890 * gdb_bfd.c (maintenance_info_bfds): Constify.
891
892 2017-09-27 Tom Tromey <tom@tromey.com>
893
894 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
895 overloads.
896 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
897 (do_const_cfunc): New function.
898 (cmd_cfunc_eq): New overload.
899 (cli_user_command_p): Check do_const_cfunc.
900 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
901 const_cfunc.
902 * command.h (add_cmd): Add const overload and no-function
903 overload.
904 (set_cmd_cfunc): Add const overload.
905 (cmd_const_cfunc_ftype): Declare.
906 (cmd_cfunc_eq): Add const overload.
907 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
908 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
909 overload.
910
911 2017-09-27 Tom Tromey <tom@tromey.com>
912
913 * macroexp.c (get_next_token_for_substitution): New function.
914 (substitute_args): Call it. Check for __VA_OPT__.
915
916 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
917 Pedro Alves <palves@redhat.com>
918
919 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
920 producer_is_icc_lt_14.
921 (producer_is_icc_lt_14): New function.
922 (check_producer): Add code for checking version of ICC.
923 (producer_is_icc): Move to producer.c.
924 (read_structure_type): Restrict ICC workaround to ICC<14.
925 * producer.c: Include selftest.h.
926 (producer_is_icc, producer_parsing_tests, _initialize_producer):
927 New functions.
928 * producer.h (producer_is_icc): New declaration.
929
930 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
931
932 * Makefile.in (SFILES): Add producer.c.
933 (COMMON_OBS): Add producer.o
934 * amd64-tdep.c (producer.h): Add new include.
935 * dwarf2read.c (producer.h): Add new include.
936 * producer.c: New file.
937 * producer.h: New file.
938 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
939 producer.c.
940 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
941 producer.h.
942
943 2017-09-26 Matthias Klose <doko@ubuntu.com>
944
945 * configure.ac: Search ncursesw before ncurses.
946 Check ncursesw/ncurses.h before ncurses/ncurses.h.
947 * gdb_curses.h: Include <ncursesw/ncurses.h>
948 * config.in, configure: Regenerate.
949
950 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
951
952 PR gdb/22185
953 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
954 obsolete.
955 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
956 Remove i386sol2 support.
957 * configure.nat <i386sol2>: Remove.
958 <sol2-64>: Fold into ...
959 <sol2>: ... this.
960 Move common settings to default section.
961 Add sol-thread.o.
962 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
963 x86_64-*-solaris2.1[0-9]*>: Rename to ...
964 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
965 <i[34567]86-*-solaris*>: Remove.
966 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
967
968 * configure.ac: Remove wctype in libw check.
969 (_MSE_INT_H): Don't define on Solaris 7-9.
970 <solaris*>: Remove libthread_db.so.1 check.
971 * configure: Regenerate.
972 * config.in: Regenerate.
973
974 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
975 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
976 (gdb_ps_size_t): Remove.
977 Use base types in users.
978 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
979
980 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
981
982 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
983
984 PR build/22206
985 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
986 (adi_is_addr_mapped): Likewise.
987 (PSR_ICC): Don't redefine.
988 (PSR_IMPL): Likewise.
989
990 2017-09-25 Tom Tromey <tom@tromey.com>
991
992 * regcache.c (regcache::dump): Use string_printf.
993
994 2017-09-25 Tom Tromey <tom@tromey.com>
995
996 * regcache.c (class regcache_invalidator): New.
997 (struct register_to_invalidate): Remove.
998 (make_cleanup_regcache_invalidate): Remove.
999 (regcache::raw_write): Use regcache_invalidator.
1000
1001 2017-09-25 Tom Tromey <tom@tromey.com>
1002
1003 * spu-tdep.c (spu2ppu_sniffer): Update.
1004 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
1005 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
1006 Remove.
1007 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
1008 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
1009 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
1010 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
1011 (frame_pop): Update.
1012
1013 2017-09-25 Tom Tromey <tom@tromey.com>
1014
1015 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
1016 * regcache.h (regcache_xfree): Don't declare.
1017 * regcache.c (regcache_xfree): Remove.
1018 (do_regcache_xfree): Use delete.
1019 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
1020 * linux-fork.c (free_fork): Use delete.
1021 (fork_save_infrun_state): Likewise.
1022 * jit.c (jit_dealloc_cache): Use delete.
1023 * infrun.c (discard_infcall_suspend_state): Use delete.
1024
1025 2017-09-25 Tom Tromey <tom@tromey.com>
1026
1027 * regcache.h (regcache_xmalloc): Don't declare.
1028 (regcache_raw_set_cached_value): Update comment.
1029 * regcache.c (regcache_xmalloc): Remove.
1030 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
1031 * jit.c (jit_frame_sniffer): Use new.
1032 * frame.c (frame_save_as_regcache): Use new.
1033
1034 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
1035
1036 * NEWS: Advertise support for guarded-storage registers on IBM z.
1037
1038 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
1039
1040 * s390-linux-nat.c (have_regset_gs): New static variable.
1041 (s390_linux_fetch_inferior_registers): Handle guarded-storage
1042 control block and guarded-storage broadcast control regsets.
1043 (s390_read_description): Detect whether the target has
1044 guarded-storage support, return appropriate tdesc.
1045 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
1046 (features/s390x-gs-linux64.c): Likewise.
1047 (struct gdbarch_tdep) <have_gs>: New field.
1048 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
1049 (s390_gsbc_regset): New variables.
1050 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
1051 and s390_gsbc_regset, if applicable.
1052 (s390_core_read_description): Check whether core file was from a
1053 target with guarded-storage support; include appropriate regsets.
1054 (s390_gdbarch_init): Add registers for guarded-storage support.
1055 (_initialize_s390_tdep): Initialize new target descriptions that
1056 include registers for guarded-storage support.
1057 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
1058 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
1059 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
1060 (S390_NUM_REGS): Adjust macro definition.
1061 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
1062 (tdesc_s390x_gs_linux64): New declarations.
1063
1064 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
1065
1066 * features/s390-gs-linux64.xml: New file.
1067 * features/s390-gs.xml: New file.
1068 * features/s390-gsbc.xml: New file.
1069 * features/s390x-gs-linux64.xml: New file.
1070 * features/Makefile (WHICH): Add s390-gs-linux64 and
1071 s390x-gs-linux64.
1072 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
1073 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
1074 * features/s390-gs-linux64.c: New generated file.
1075 * features/s390x-gs-linux64.c: New file.
1076 * regformats/s390-gs-linux64.dat: New file.
1077 * regformats/s390x-gs-linux64.dat: New file.
1078
1079 2017-09-23 Tom Tromey <tom@tromey.com>
1080
1081 * defs.h (make_cleanup_override_quit_handler): Don't declare.
1082
1083 2017-09-22 Tom Tromey <tom@tromey.com>
1084
1085 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
1086 type to scoped_restore_tmpl.
1087 <scoped_input_handler>: Initialize m_quit_handler directly.
1088
1089 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
1090
1091 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
1092 (cd_command): Likewise. Free "current_directory" before
1093 assigning to it.
1094 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
1095 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
1096 * top.c (gdb_dirbuf): Remove global declaration.
1097 * top.h (gdb_dirbuf): Likewise.
1098
1099 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
1100
1101 * gnulib/aclocal.m4: Regenerate.
1102 * gnulib/config.in: Regenerate.
1103 * gnulib/configure: Regenerate.
1104 * gnulib/import/Makefile.am: Regenerate.
1105 * gnulib/import/Makefile.in: Regenerate.
1106 * gnulib/import/assure.h: New file.
1107 * gnulib/import/at-func.c: Likewise
1108 * gnulib/import/chdir-long.c: New file.
1109 * gnulib/import/chdir-long.h: New file.
1110 * gnulib/import/cloexec.c: New file.
1111 * gnulib/import/cloexec.h: New file.
1112 * gnulib/import/close.c: New file.
1113 * gnulib/import/closedir.c: New file.
1114 * gnulib/import/dirent-private.h: New file.
1115 * gnulib/import/dup-safer.c: New file.
1116 * gnulib/import/dup.c: New file.
1117 * gnulib/import/dup2.c: New file.
1118 * gnulib/import/error.c: New file.
1119 * gnulib/import/error.h: New file.
1120 * gnulib/import/exitfail.c: New file.
1121 * gnulib/import/exitfail.h: New file.
1122 * gnulib/import/fchdir.c: New file.
1123 * gnulib/import/fcntl.c: New file.
1124 * gnulib/import/fcntl.in.h: New file.
1125 * gnulib/import/fd-hook.c: New file.
1126 * gnulib/import/fd-hook.h: New file.
1127 * gnulib/import/fd-safer.c: New file.
1128 * gnulib/import/fdopendir.c: New file.
1129 * gnulib/import/filename.h: New file.
1130 * gnulib/import/filenamecat-lgpl.c: New file.
1131 * gnulib/import/filenamecat.h: New file.
1132 * gnulib/import/fstat.c: New file.
1133 * gnulib/import/fstatat.c: New file.
1134 * gnulib/import/getcwd-lgpl.c: New file.
1135 * gnulib/import/getcwd.c: New file.
1136 * gnulib/import/getdtablesize.c: New file.
1137 * gnulib/import/getlogin_r.c: New file.
1138 * gnulib/import/getprogname.c: New file.
1139 * gnulib/import/getprogname.h: New file.
1140 * gnulib/import/gettext.h: New file.
1141 * gnulib/import/glob-libc.h: New file.
1142 * gnulib/import/glob.c: New file.
1143 * gnulib/import/glob.in.h: New file.
1144 * gnulib/import/intprops.h: New file.
1145 * gnulib/import/m4/chdir-long.m4: New file.
1146 * gnulib/import/m4/close.m4: New file.
1147 * gnulib/import/m4/closedir.m4: New file.
1148 * gnulib/import/m4/d-ino.m4: New file.
1149 * gnulib/import/m4/d-type.m4: New file.
1150 * gnulib/import/m4/dup.m4: New file.
1151 * gnulib/import/m4/dup2.m4: New file.
1152 * gnulib/import/m4/error.m4: New file.
1153 * gnulib/import/m4/fchdir.m4: New file.
1154 * gnulib/import/m4/fcntl.m4: New file.
1155 * gnulib/import/m4/fcntl_h.m4: New file.
1156 * gnulib/import/m4/fdopendir.m4: New file.
1157 * gnulib/import/m4/filenamecat.m4: New file.
1158 * gnulib/import/m4/fstat.m4: New file.
1159 * gnulib/import/m4/fstatat.m4: New file.
1160 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
1161 * gnulib/import/m4/getcwd-path-max.m4: New file.
1162 * gnulib/import/m4/getcwd.m4: New file.
1163 * gnulib/import/m4/getdtablesize.m4: New file.
1164 * gnulib/import/m4/getlogin_r.m4: New file.
1165 * gnulib/import/m4/getprogname.m4: New file.
1166 * gnulib/import/m4/glob.m4: New file.
1167 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
1168 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
1169 * gnulib/import/m4/mempcpy.m4: New file.
1170 * gnulib/import/m4/memrchr.m4: New file.
1171 * gnulib/import/m4/mode_t.m4: New file.
1172 * gnulib/import/m4/msvc-inval.m4: New file.
1173 * gnulib/import/m4/msvc-nothrow.m4: New file.
1174 * gnulib/import/m4/open.m4: New file.
1175 * gnulib/import/m4/openat.m4: New file.
1176 * gnulib/import/m4/opendir.m4: New file.
1177 * gnulib/import/m4/readdir.m4: New file.
1178 * gnulib/import/m4/realloc.m4: New file.
1179 * gnulib/import/m4/rewinddir.m4: New file.
1180 * gnulib/import/m4/save-cwd.m4: New file.
1181 * gnulib/import/m4/strdup.m4: New file.
1182 * gnulib/import/m4/strerror.m4: New file.
1183 * gnulib/import/m4/unistd-safer.m4: New file.
1184 * gnulib/import/mempcpy.c: New file.
1185 * gnulib/import/memrchr.c: New file.
1186 * gnulib/import/msvc-inval.c: New file.
1187 * gnulib/import/msvc-inval.h: New file.
1188 * gnulib/import/msvc-nothrow.c: New file.
1189 * gnulib/import/msvc-nothrow.h: New file.
1190 * gnulib/import/open.c: New file.
1191 * gnulib/import/openat-die.c: New file.
1192 * gnulib/import/openat-priv.h: New file.
1193 * gnulib/import/openat-proc.c: New file.
1194 * gnulib/import/openat.c: New file.
1195 * gnulib/import/openat.h: New file.
1196 * gnulib/import/opendir.c: New file.
1197 * gnulib/import/pipe-safer.c: New file.
1198 * gnulib/import/readdir.c: New file.
1199 * gnulib/import/realloc.c: New file.
1200 * gnulib/import/rewinddir.c: New file.
1201 * gnulib/import/save-cwd.c: New file.
1202 * gnulib/import/save-cwd.h: New file.
1203 * gnulib/import/strdup.c: New file.
1204 * gnulib/import/strerror-override.c: New file.
1205 * gnulib/import/strerror-override.h: New file.
1206 * gnulib/import/strerror.c: New file.
1207 * gnulib/import/unistd--.h: New file.
1208 * gnulib/import/unistd-safer.h: New file.
1209 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
1210 "getcwd" and "glob".
1211 * ser-tcp.c: Undefine "close" before redefining it.
1212
1213 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
1214
1215 * guile/scm-value.c (gdbscm_value_address): Initialize address,
1216 get rid of res_val.
1217
1218 2017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1219
1220 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
1221 <sol2,sparc>: Likewise.
1222 <sol2-64,i386>: Likewise.
1223
1224 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
1225 -Wdeprecated-declarations on *-*-solaris*.
1226 * configure: Regenerate.
1227
1228 * procfs.c: Include "nat/inferior.h".
1229 (procfs_info_proc): Fix typo.
1230
1231 2017-09-21 Kevin Buettner <kevinb@redhat.com>
1232
1233 * remote.c (vector): Include.
1234 (struct private_thread_info): Add field, thread_handle.
1235 (free_private_thread_info): Deallocate storage associated with
1236 thread handle.
1237 (get_private_info_thread): Initialize `thread_handle' field.
1238 (struct thread_item): Add field, thread_handle.
1239 (clear_threads_listing_context): Deallocate storage associated
1240 with thread handle.
1241 (start_thread): Add support for "handle" attribute.
1242 (thread_attributes): Add "handle".
1243 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
1244 field.
1245 (remote_update_thread_list): Update thread_handle.
1246 (remote_thread_handle_to_thread_info): New function.
1247 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
1248
1249 2017-09-21 Kevin Buettner <kevinb@redhat.com>
1250
1251 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
1252 function.
1253 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
1254 * python/python-internal.h (thread_object_type): Declare.
1255
1256 2017-09-21 Kevin Buettner <kevinb@redhat.com>
1257
1258 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
1259 (target_thread_handle_to_thread_info): Declare.
1260 * target.c (target_thread_handle_to_thread_info): New function.
1261 * target-delegates.c: Regenerate.
1262 * gdbthread.h (find_thread_by_handle): Declare.
1263 * thread.c (find_thread_by_handle): New function.
1264 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
1265 function.
1266 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
1267
1268 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
1269
1270 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
1271
1272 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
1273
1274 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
1275
1276 2017-09-21 Yao Qi <yao.qi@linaro.org>
1277
1278 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
1279 to gdb_target_obs.
1280
1281 2017-09-20 Tom Tromey <tom@tromey.com>
1282
1283 * breakpoint.c (struct counted_command_line): Remove.
1284 (breakpoint_commands): Update.
1285 (alloc_counted_command_line, incref_counted_command_line)
1286 (decref_counted_command_line, do_cleanup_counted_command_line)
1287 (make_cleanup_decref_counted_command_line): Remove.
1288 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
1289 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
1290 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
1291 (save_breakpoints): Update.
1292 * breakpoint.h (counted_command_line): Now a typedef to
1293 shared_ptr.
1294 (struct breakpoint) <commands>: Now a counted_command_line.
1295 (struct bpstats) <command>: Likewise.
1296
1297 2017-09-20 Tom Tromey <tom@tromey.com>
1298
1299 * breakpoint.c (struct commands_info, do_map_commands_command):
1300 Remove.
1301 (commands_command_1): Update.
1302 (iterate_over_related_breakpoints): Take a function_view.
1303 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
1304 (delete_command): Update.
1305 (map_breakpoint_numbers): Take a function_view.
1306 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
1307 (disable_command): Update.
1308 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
1309 (enable_command): Update.
1310 (struct disp_data, do_enable_breakpoint_disp)
1311 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
1312 (do_map_enable_delete_breakpoint): Remove.
1313 (enable_once_command, enable_count_command, enable_delete_command)
1314 (delete_trace_variable_command): Update.
1315
1316 2017-09-20 Tom Tromey <tom@tromey.com>
1317
1318 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
1319 (bpstat_clear): Use delete.
1320 (bpstats): New constructors.
1321 (bpstat_copy, bpstat_stop_status): Use new.
1322 (dprintf_after_condition_true): Update.
1323 * breakpoint.h (bpstats::bpstats): Add constructors.
1324 (bpstats::~bpstats): Add destructor.
1325
1326 2017-09-20 Pedro Alves <palves@redhat.com>
1327
1328 * eval.c (make_params): Delete, refactored as ...
1329 (class fake_method): ... this new type's ctor.
1330 (fake_method::~fake_method): New.
1331 (evaluate_subexp_standard): Use 'fake_method'.
1332
1333 2017-09-20 Tom Tromey <tom@tromey.com>
1334
1335 * windows-nat.c (get_windows_debug_event, windows_wait)
1336 (do_initial_windows_stuff, windows_attach): Update.
1337 * utils.c (vwarning, internal_vproblem): Update.
1338 (ui_unregister_input_event_handler_cleanup)
1339 (prepare_to_handle_input): Remove.
1340 (class scoped_input_handler): New.
1341 (defaulted_query, prompt_for_continue): Update.
1342 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
1343 Update.
1344 * top.c (undo_terminal_modifications_before_exit): Update.
1345 * target/target.h (target_terminal_init, target_terminal_inferior)
1346 (target_terminal_ours): Don't declare.
1347 (class target_terminal): New.
1348 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
1349 (target_terminal_ours_for_output)
1350 (make_cleanup_restore_target_terminal): Don't declare.
1351 (target_terminal_info): Remove.
1352 * target.c (enum terminal_state, terminal_state): Remove.
1353 (target_terminal::terminal_state): Define.
1354 (target_terminal::init): Rename from target_terminal_init.
1355 (target_terminal::inferior): Rename from
1356 target_terminal_inferior.
1357 (target_terminal::ours): Rename from target_terminal_ours.
1358 (target_terminal::ours_for_output): Rename from
1359 target_terminal_ours_for_output.
1360 (target_terminal::info): New method.
1361 (cleanup_restore_target_terminal)
1362 (make_cleanup_restore_target_terminal): Remove.
1363 * solib.c (handle_solib_event): Update.
1364 * remote.c (remote_serial_quit_handler): Update.
1365 (remote_terminal_inferior, remote_wait_as): Update.
1366 * record-full.c (record_full_wait_1): Update.
1367 * nto-procfs.c (procfs_create_inferior): Update.
1368 * nat/fork-inferior.c (startup_inferior): Update.
1369 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
1370 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
1371 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
1372 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
1373 (mi_breakpoint_created, mi_breakpoint_deleted)
1374 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
1375 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
1376 (mi_user_selected_context_changed, report_initial_inferior):
1377 Update.
1378 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
1379 (linux_nat_terminal_inferior): Update.
1380 * infrun.c (follow_fork_inferior)
1381 (handle_vfork_child_exec_or_exit, do_target_resume)
1382 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
1383 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
1384 Update.
1385 * inflow.c (child_terminal_init, info_terminal_command): Update.
1386 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
1387 (attach_command): Update.
1388 * infcall.c (call_thread_fsm_should_stop): Update.
1389 * gnu-nat.c (gnu_attach): Update.
1390 * extension.c (struct active_ext_lang_state)
1391 (restore_active_ext_lang): Update.
1392 * exceptions.c (print_flush): Update.
1393 * event-top.c (async_enable_stdin, default_quit_handler): Update.
1394 (struct quit_handler_cleanup_data, restore_quit_handler)
1395 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
1396 Remove.
1397 * cp-support.c (gdb_demangle): Update.
1398 * breakpoint.c (update_inserted_breakpoint_locations)
1399 (insert_breakpoint_locations, handle_jit_event)
1400 (disable_breakpoints_in_unloaded_shlib): Update.
1401 * annotate.c (annotate_breakpoints_invalid)
1402 (annotate_frames_invalid): Update.
1403
1404 2017-09-20 Tom Tromey <tom@tromey.com>
1405
1406 * main.c (catch_command_errors): Rename from
1407 catch_command_errors_const.
1408 (captured_main_1): Update.
1409
1410 2017-09-20 Pedro Alves <palves@redhat.com>
1411
1412 * cli/cli-cmds.c (list_command): Use print_sal_location.
1413 (print_sal_location): New function.
1414 (ambiguous_line_spec): Use print_sal_location.
1415 * linespec.c (symbol_to_sal): Record the symbol in the sal.
1416 * symtab.c (find_function_start_sal): Likewise.
1417 * symtab.h (symtab_and_line::symbol): New field.
1418
1419 2017-09-20 Pedro Alves <palves@redhat.com>
1420
1421 * linespec.c (minsym_found): Handle non-text minsyms.
1422 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
1423
1424 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
1425
1426 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
1427 backslash.
1428
1429 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
1430
1431 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
1432 vmovups instead vmovaps.
1433 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
1434
1435 2017-09-19 John Baldwin <jhb@FreeBSD.org>
1436
1437 * NEWS (Changes since GDB 8.0): Add starti.
1438 * infcmd.c (enum run_break): New.
1439 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
1440 case.
1441 (run_command): Use enum run_how.
1442 (start_command): Likewise.
1443 (starti_command): New function.
1444 (RUN_ARGS_HELP): New macro.
1445 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
1446 commands. Add starti command.
1447
1448 2017-09-19 Yao Qi <yao.qi@linaro.org>
1449
1450 * Makefile.in (monitor.o): Remove the rule.
1451
1452 2017-09-19 Yao Qi <yao.qi@linaro.org>
1453
1454 * annotate.h (struct annotate_arg_emitter): Use
1455 DISABLE_COPY_AND_ASSIGN.
1456 * common/refcounted-object.h (refcounted_object): Likewise.
1457 * completer.h (struct completion_result): Likewise.
1458 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
1459 * filename-seen-cache.h (filename_seen_cache): Likewise.
1460 * gdbcore.h (thread_section_name): Likewise.
1461 * gdb_regex.h (compiled_regex): Likewise.
1462 * gdbthread.h (scoped_restore_current_thread): Likewise.
1463 * inferior.h (scoped_restore_current_inferior): Likewise.
1464 * jit.c (jit_reader): Likewise.
1465 * linespec.h (struct linespec_result): Likewise.
1466 * mi/mi-parse.h (struct mi_parse): Likewise.
1467 * nat/fork-inferior.c (execv_argv): Likewise.
1468 * progspace.h (scoped_restore_current_program_space): Likewise.
1469 * python/python-internal.h (class gdbpy_enter): Likewise.
1470 * regcache.h (regcache): Likewise.
1471 * target-descriptions.c (struct tdesc_reg): Likewise.
1472 (struct tdesc_type): Likewise.
1473 (struct tdesc_feature): Likewise.
1474 * ui-out.h (ui_out_emit_type): Likewise.
1475
1476 2017-09-18 Simon Marchi <simon.marchi@ericsson.com>
1477
1478 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
1479 label abort_expression.
1480
1481 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1482
1483 * common/buffer.c (buffer_xml_printf): Adjust.
1484 * common/xml-utils.c (xml_escape_text): Change return type to
1485 std::string, update code accordingly.
1486 * common/xml-utils.h (xml_escape_text): Change return type to
1487 std::string.
1488 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
1489 * windows-tdep.c (windows_xfer_shared_library): Adjust.
1490 * unittests/xml-utils-selftests.c (test_xml_escape_text):
1491 Adjust.
1492
1493 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1494
1495 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
1496 (SUBDIR_UNITTESTS_OBS): Add new object file.
1497 * unittests/xml-utils-selftests.c: New file.
1498
1499 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1500
1501 * common/selftest.h (selftest): New struct/interface.
1502 (register_test): Add name parameter, add new overload.
1503 (run_tests): Add filter parameter.
1504 (for_each_selftest_ftype): New typedef.
1505 (for_each_selftest): New declaration.
1506 * common/selftest.c (tests): Change type to
1507 map<string, unique_ptr<selftest>>.
1508 (simple_selftest): New struct.
1509 (register_test): New function.
1510 (register_test): Add name parameter and use it.
1511 (run_tests): Add filter parameter and use it. Add prints.
1512 Adjust to vector -> map change.
1513 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
1514 registering selftests.
1515 * arm-tdep.c (_initialize_arm_tdep): Likewise.
1516 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
1517 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
1518 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
1519 * findvar.c (_initialize_findvar): Likewise.
1520 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
1521 * maint.c (maintenance_selftest): Update call to run_tests.
1522 (maintenance_info_selftests): New function.
1523 (_initialize_maint_cmds): Register "maintenance info selftests"
1524 command. Update "maintenance selftest" doc.
1525 * regcache.c (_initialize_regcache): Add names when registering
1526 selftests.
1527 * rust-exp.y (_initialize_rust_exp): Likewise.
1528 * selftest-arch.c (gdbarch_selftest): New struct.
1529 (gdbarch_tests): Remove.
1530 (register_test_foreach_arch): Add name parameter. Call
1531 register_test.
1532 (tests_with_arch): Remove, move most content to
1533 gdbarch_selftest::operator().
1534 (_initialize_selftests_foreach_arch): Remove.
1535 * selftest-arch.h (register_test_foreach_arch): Add name
1536 parameter.
1537 (run_tests_with_arch): New declaration.
1538 * utils-selftests.c (_initialize_utils_selftests): Add names
1539 when registering selftests.
1540 * utils.c (_initialize_utils): Likewise.
1541 * unittests/array-view-selftests.c
1542 (_initialize_array_view_selftests): Likewise.
1543 * unittests/environ-selftests.c (_initialize_environ_selftests):
1544 Likewise.
1545 * unittests/function-view-selftests.c
1546 (_initialize_function_view_selftests): Likewise.
1547 * unittests/offset-type-selftests.c
1548 (_initialize_offset_type_selftests): Likewise.
1549 * unittests/optional-selftests.c
1550 (_initialize_optional_selftests): Likewise.
1551 * unittests/scoped_restore-selftests.c
1552 (_initialize_scoped_restore_selftests): Likewise.
1553 * NEWS: Document "maintenance selftest" and "maint info
1554 selftests".
1555
1556 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1557
1558 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
1559 scoped_restore.
1560
1561 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1562
1563 * mi/mi-main.c (mi_load_progress): Make uiout variable
1564 a unique_ptr.
1565
1566 2017-09-15 Pedro Alves <palves@redhat.com>
1567
1568 * compile/compile-c-types.c (convert_enum, convert_int)
1569 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
1570
1571 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1572
1573 * dwarf2read.c (copy_string): Remove.
1574 (parse_macro_definition): Replace copy_string with savestring.
1575
1576 2017-09-15 Yao Qi <yao.qi@linaro.org>
1577
1578 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
1579 gdb_target_obs.
1580 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
1581 Likewise.
1582 (i[34567]86-*-linux*): Likewise.
1583
1584 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
1585
1586 * dwarf2expr.h (dwarf_stack_value): Add constructor.
1587 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
1588 <stack>: Change type to std::vector.
1589 <stack_len, stack_allocated>: Remove.
1590 <grow_stack>: Remove.
1591 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
1592 (dwarf_expr_context::~dwarf_expr_context): Remove.
1593 (dwarf_expr_context::grow_stack): Remove.
1594 (dwarf_expr_context::push): Adjust.
1595 (dwarf_expr_context::pop): Adjust.
1596 (dwarf_expr_context::fetch): Adjust.
1597 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
1598 (dwarf_expr_context::stack_empty_p): Adjust.
1599 (dwarf_expr_context::execute_stack_op): Adjust.
1600
1601 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
1602
1603 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
1604 return type to bool.
1605 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
1606
1607 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
1608
1609 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
1610 Change type to bool.
1611 (dwarf_stack_value) <in_stack_memory>: Likewise.
1612 (dwarf_expr_context) <push_address>: Change parameter type to
1613 bool.
1614 <fetch_in_stack_memory>: Change return type to bool.
1615 <push>: Change parameter type to bool.
1616 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
1617 to bool.
1618 (dwarf_expr_context::push_address): Likewise.
1619 (dwarf_expr_context::fetch_in_stack_memory): Change return type
1620 to bool.
1621 (dwarf_expr_context::execute_stack_op): Adjust.
1622 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
1623
1624 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
1625
1626 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
1627 (struct dwarf_expr_context) <n_pieces>: Remove.
1628 <pieces>: Change type to std::vector.
1629 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
1630 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
1631 pieces.
1632 (dwarf_expr_context::add_piece): Adjust.
1633 * dwarf2loc.c (struct piece_closure): Initialize fields.
1634 <n_pieces>: Remove.
1635 <pieces>: Change type to std::vector.
1636 (allocate_piece_closure): Adjust, change parameter to
1637 std::vector rvalue and std::move it to piece_closure.
1638 (rw_pieced_value): Adjust.
1639 (check_pieced_synthetic_pointer): Adjust.
1640 (indirect_synthetic_pointer): Adjust.
1641 (coerce_pieced_ref): Adjust.
1642 (free_pieced_value_closure): Adjust. Use delete to free
1643 piece_closure.
1644 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
1645 to allocate_piece_closure.
1646 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
1647
1648 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
1649
1650 * probe.h (probe_ops_cp): Remove typedef.
1651 (DEF_VEC_P (probe_ops_cp)): Remove.
1652 (all_probe_ops): Change type to std::vector.
1653 * probe.c (info_probes_for_ops): Adjust to vector change.
1654 (probe_linespec_to_ops): Likewise.
1655 (all_probe_ops): Change type to std::vector.
1656 (_initialize_probe): Adjust to vector change.
1657 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
1658 * elfread.c (elf_get_probes): Likewise.
1659 * stap-probe.c (_initialize_stap_probe): Likewise.
1660
1661 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
1662
1663 * probe.h (struct bound_probe): Define constructors.
1664 * probe.c (bound_probe_s): Remove typedef.
1665 (DEF_VEC_O (bound_probe_s)): Remove VEC.
1666 (collect_probes): Change return type to std::vector, remove
1667 cleanup.
1668 (compare_probes): Return bool, change parameter type. Change
1669 semantic to "less than".
1670 (gen_ui_out_table_header_info): Change parameter to std::vector
1671 and update.
1672 (exists_probe_with_pops): Likewise.
1673 (info_probes_for_ops): Update to std::vector change.
1674 (enable_probes_command): Likewise.
1675 (disable_probes_command): Likewise.
1676
1677 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
1678
1679 * probe.h (struct probe_ops) <get_probes>: Change parameter from
1680 vec to std::vector.
1681 * probe.c (parse_probes_in_pspace): Update.
1682 (find_probes_in_objfile): Update.
1683 (find_probe_by_pc): Update.
1684 (collect_probes): Update.
1685 (probe_any_get_probes): Update.
1686 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
1687 return type to reference to std::vector.
1688 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
1689 std::vector and update.
1690 (dtrace_process_dof): Likewise.
1691 (dtrace_get_probes): Likewise.
1692 * elfread.c (elf_get_probes): Change return type to std::vector,
1693 store an std::vector in bfd_data.
1694 (probe_key_free): Update to std::vector.
1695 * stap-probe.c (handle_stap_probe): Change parameter to
1696 std::vector and update.
1697 (stap_get_probes): Likewise.
1698 * symfile-debug.c (debug_sym_get_probes): Change return type to
1699 std::vector and update.
1700
1701 2017-09-11 Tom Tromey <tom@tromey.com>
1702
1703 * breakpoint.c (program_breakpoint_here_p): Update.
1704 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
1705 from make_show_memory_breakpoints_cleanup. Return a
1706 scoped_restore_tmpl<int>.
1707 (restore_show_memory_breakpoints): Remove.
1708 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
1709 * mem-break.c (memory_validate_breakpoint): Update.
1710 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
1711 (ia64_memory_remove_breakpoint): Update.
1712 (ia64_breakpoint_from_pc): Update.
1713 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
1714 from make_show_memory_breakpoints_cleanup.
1715
1716 2017-09-11 Tom Tromey <tom@tromey.com>
1717
1718 * d-namespace.c (d_lookup_symbol): Use std::string.
1719 (find_symbol_in_baseclass): Likewise.
1720
1721 2017-09-11 Tom Tromey <tom@tromey.com>
1722
1723 * ctf.c (ctf_start): Use std::string.
1724
1725 2017-09-11 Tom Tromey <tom@tromey.com>
1726
1727 * ada-lang.c (is_known_support_routine): Update.
1728 (ada_unhandled_exception_name_addr_from_raise): Update.
1729 * guile/scm-frame.c (gdbscm_frame_name): Update.
1730 * python/py-frame.c (frapy_name): Update.
1731 (frapy_function): Update.
1732 * stack.h (find_frame_funname): Update.
1733 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
1734 (print_frame): Update.
1735
1736 2017-09-11 Tom Tromey <tom@tromey.com>
1737
1738 * findcmd.c (put_bits): Take a gdb::byte_vector.
1739 (parse_find_args): Return gdb::byte_vector. "args" now const.
1740 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
1741 cleanups.
1742 (find_command): Update.
1743
1744 2017-09-11 Tom Tromey <tom@tromey.com>
1745
1746 * cli/cli-script.c (class scoped_restore_hook_in): New.
1747 (clear_hook_in_cleanup): Remove.
1748 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
1749 scoped_restore_hook_in.
1750
1751 2017-09-11 Tom Tromey <tom@tromey.com>
1752
1753 * cli/cli-script.c (restore_interp): Remove.
1754 (read_command_lines): Use scoped_restore_interp.
1755 * interps.c (scoped_restore_interp::set_temp): Rename from
1756 interp_set_temp.
1757 * interps.h (class scoped_restore_interp): New.
1758 (interp_set_temp): Remove.
1759
1760 2017-09-11 Tom Tromey <tom@tromey.com>
1761
1762 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
1763 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
1764 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
1765 scoped_restore.
1766 (mi_cmd_break_insert_1): Update.
1767 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
1768 scoped_restore.
1769
1770 2017-09-11 Tom Tromey <tom@tromey.com>
1771
1772 * demangle.c (demangle_command): Update.
1773 * breakpoint.c (disable_command): Update.
1774 (enable_command): Update.
1775 (find_location_by_number): Make "number" const. Use
1776 get_number_trailer.
1777 * cli/cli-utils.c (extract_arg): Return std::string.
1778 * probe.c (parse_probe_linespec): Update. Change types.
1779 (collect_probes): Take string arguments.
1780 (parse_probe_linespec): Likewise.
1781 (info_probes_for_ops): Update.
1782 (enable_probes_command): Update.
1783 (disable_probes_command): Update.
1784 * break-catch-sig.c (catch_signal_split_args): Update.
1785 * mi/mi-parse.c (mi_parse): Update.
1786
1787 2017-09-11 Tom Tromey <tom@tromey.com>
1788
1789 * language.h (language_enum): Make argument const.
1790 * language.c (language_enum): Make argument const.
1791
1792 2017-09-11 Tom Tromey <tom@tromey.com>
1793
1794 * common/common-utils.h (skip_to_space): Remove macro, redeclare
1795 as function.
1796 (skip_to_space): Rename from skip_to_space_const.
1797 * common/common-utils.c (skip_to_space): New function.
1798 (skip_to_space): Rename from skip_to_space_const.
1799 * cli/cli-utils.h (get_number): Rename from get_number_const.
1800 (extract_arg): Rename from extract_arg_const.
1801 * cli/cli-utils.c (get_number): Rename from get_number_const.
1802 (extract_arg): Rename from extract_arg_const.
1803 (number_or_range_parser::get_number): Use ::get_number.
1804 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
1805 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
1806 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
1807 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
1808 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
1809 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
1810 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
1811 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
1812
1813 2017-09-11 Tom Tromey <tom@tromey.com>
1814
1815 * python/python.c (do_start_initialization): Use
1816 py-event-types.def to initialize types.
1817 Define all object type structures.
1818 * python/python-internal.h: Don't declare event initialization
1819 functions.
1820 * python/py-threadevent.c (thread_event_object_type): Don't
1821 define.
1822 * python/py-stopevent.c (stop_event_object_type): Don't define.
1823 * python/py-signalevent.c (signal_event_object_type): Don't
1824 declare or define.
1825 * python/py-newobjfileevent.c (new_objfile_event_object_type)
1826 (clear_objfiles_event_object_type): Don't declare or define.
1827 * python/py-infevents.c (inferior_call_pre_event_object_type)
1828 (inferior_call_post_event_object_type)
1829 (register_changed_event_object_type)
1830 (memory_changed_event_object_type): Don't declare or define.
1831 * python/py-inferior.c (new_thread_event_object_type)
1832 (new_inferior_event_object_type)
1833 (inferior_deleted_event_object_type): Don't declare or define.
1834 * python/py-exitedevent.c (exited_event_object_type): Don't
1835 declare or define.
1836 * python/py-evts.c (gdbpy_initialize_py_events): Use
1837 py-all-events.def.
1838 * python/py-events.h (thread_event_object_type): Don't declare.
1839 (events_object): Use py-all-events.def.
1840 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
1841 py-event-types.def.
1842 * python/py-event-types.def: New file.
1843 * python/py-continueevent.c (create_continue_event_object): Don't
1844 declare or define.
1845 * python/py-bpevent.c (breakpoint_event_object_type): Don't
1846 declare or define.
1847 * python/py-all-events.def: New file.
1848
1849 2017-09-11 Tom Tromey <tom@tromey.com>
1850
1851 * python/py-threadevent.c (create_thread_event_object): Return
1852 gdbpy_ref.
1853 * python/py-stopevent.h (create_stop_event_object)
1854 (create_breakpoint_event_object, create_signal_event_object):
1855 Update.
1856 * python/py-stopevent.c (create_stop_event_object): Return
1857 gdbpy_ref.
1858 (emit_stop_event): Update.
1859 * python/py-signalevent.c (create_signal_event_object): Return
1860 gdbpy_ref.
1861 * python/py-infevents.c (create_inferior_call_event_object):
1862 Update.
1863 * python/py-event.h (create_event_object)
1864 (create_thread_event_object): Update.
1865 * python/py-event.c (create_event_object): Return gdbpy_ref.
1866 * python/py-continueevent.c: Return gdbpy_ref.
1867 * python/py-bpevent.c (create_breakpoint_event_object): Return
1868 gdbpy_ref.
1869
1870 2017-09-11 Tom Tromey <tom@tromey.com>
1871
1872 PR python/15622:
1873 * NEWS: Add entry.
1874 * python/python.c (do_start_initialization): Initialize new event
1875 types.
1876 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
1877 (gdbpy_initialize_inferior_deleted_event)
1878 (gdbpy_initialize_new_thread_event): Declare.
1879 * python/py-threadevent.c (create_thread_event_object): Add option
1880 "thread" parameter.
1881 * python/py-inferior.c (new_thread_event_object_type)
1882 (new_inferior_event_object_type)
1883 (inferior_deleted_event_object_type): Declare.
1884 (python_new_inferior, python_inferior_deleted): New functions.
1885 (add_thread_object): Emit new_thread event.
1886 (gdbpy_initialize_inferior): Attach new functions to corresponding
1887 observers.
1888 (new_thread, new_inferior, inferior_deleted): Define new event
1889 types.
1890 * python/py-evts.c (gdbpy_initialize_py_events): Add new
1891 registries.
1892 * python/py-events.h (events_object) <new_inferior,
1893 inferior_deleted, new_thread>: New fields.
1894 * python/py-event.h (create_thread_event_breakpoint): Add optional
1895 "thread" parameter.
1896
1897 2017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
1898
1899 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
1900 check current_ui instead.
1901 (internal_vproblem): Likewise.
1902
1903 2017-09-09 Simon Marchi <simon.marchi@ericsson.com>
1904
1905 * thread.c (print_thread_info_1): Remove unnecessary calls to
1906 uiout->is_mi_like_p.
1907
1908 2017-09-09 Tom Tromey <tom@tromey.com>
1909
1910 * namespace.h (add_using_directive): Update.
1911 * namespace.c (add_using_directive): Change type of excludes to
1912 std::vector.
1913 * dwarf2read.c (read_import_statement): Use std::vector.
1914 (read_namespace): Update.
1915 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
1916
1917 2017-09-09 Tom Tromey <tom@tromey.com>
1918
1919 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
1920
1921 2017-09-09 Tom Tromey <tom@tromey.com>
1922
1923 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
1924
1925 2017-09-09 Tom Tromey <tom@tromey.com>
1926
1927 * stack.c (func_command): Use gdb::def_vector.
1928
1929 2017-09-09 Tom Tromey <tom@tromey.com>
1930
1931 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
1932 ui_out_emit_list, ui_out_emit_tuple.
1933 (mi_cmd_var_update): Likewise.
1934
1935 2017-09-09 Tom Tromey <tom@tromey.com>
1936
1937 * mi/mi-interp.c (mi_user_selected_context_changed): Use
1938 ui_out_redirect_pop.
1939 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
1940 ui_out_redirect_pop.
1941 * utils.c (do_ui_out_redirect_pop)
1942 (make_cleanup_ui_out_redirect_pop): Remove.
1943 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
1944 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
1945 * ui-out.h (ui_out_redirect_pop): New class.
1946
1947 2017-09-09 Tom Tromey <tom@tromey.com>
1948
1949 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
1950 (list_available_thread_groups, mi_cmd_list_thread_groups)
1951 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
1952 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
1953 Likewise.
1954
1955 2017-09-09 Tom Tromey <tom@tromey.com>
1956
1957 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
1958 ui_out_emit_tuple.
1959
1960 2017-09-09 Tom Tromey <tom@tromey.com>
1961
1962 * target.c (flash_erase_command): Use ui_out_emit_tuple.
1963 * stack.c (print_frame): Use ui_out_emit_tuple.
1964 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
1965 (info_spu_mailbox_command, info_spu_dma_command)
1966 (info_spu_proxydma_command): Likewise.
1967 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
1968 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
1969 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
1970 ui_out_emit_tuple.
1971 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
1972
1973 2017-09-09 Tom Tromey <tom@tromey.com>
1974
1975 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
1976 (class ui_out_emit_table): Update comment.
1977 * ui-out.c (do_cleanup_table_end)
1978 (make_cleanup_ui_out_table_begin_end): Remove.
1979 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
1980 (info_spu_dma_cmdlist): Likewise.
1981 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
1982 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
1983 ui_out_emit_table.
1984
1985 2017-09-09 Tom Tromey <tom@tromey.com>
1986
1987 * thread.c (print_thread_info_1): Use ui_out_emit_table,
1988 ui_out_emit_list, gdb::optional.
1989
1990 2017-09-09 John Baldwin <jhb@FreeBSD.org>
1991
1992 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
1993 prototype.
1994 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
1995 prototype.
1996 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
1997 prototype.
1998 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
1999 * ada-exp.y: Remove _initialize_ada_exp prototype.
2000 * ada-lang.c: Remove _initialize_ada_language prototype.
2001 * ada-tasks.c: Remove _initialize_tasks prototype.
2002 * addrmap.c: Remove _initialize_addrmap prototype.
2003 * agent.c: Remove _initialize_agent prototype.
2004 * aix-thread.c: Remove _initialize_aix_thread prototype.
2005 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
2006 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
2007 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
2008 prototype.
2009 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
2010 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
2011 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
2012 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
2013 prototype.
2014 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
2015 prototype.
2016 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
2017 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
2018 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
2019 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
2020 prototype.
2021 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
2022 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
2023 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
2024 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
2025 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
2026 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
2027 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
2028 prototype.
2029 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
2030 prototype.
2031 * annotate.c: Remove _initialize_annotate prototype.
2032 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
2033 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
2034 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
2035 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
2036 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
2037 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
2038 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
2039 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
2040 prototype.
2041 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
2042 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
2043 * auto-load.c: Remove _initialize_auto_load prototype.
2044 * auxv.c: Remove _initialize_auxv prototype.
2045 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
2046 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
2047 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
2048 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
2049 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
2050 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
2051 prototype.
2052 * break-catch-throw.c: Remove _initialize_break_catch_throw
2053 prototype.
2054 * breakpoint.c: Remove _initialize_breakpoint prototype.
2055 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
2056 * btrace.c: Remove _initialize_btrace prototype.
2057 * charset.c: Remove _initialize_charset prototype.
2058 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
2059 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
2060 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
2061 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
2062 * cli/cli-script.c: Remove _initialize_cli_script prototype.
2063 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
2064 * coffread.c: Remove _initialize_coffread prototype.
2065 * compile/compile.c: Remove _initialize_compile prototype.
2066 * complaints.c: Remove _initialize_complaints prototype.
2067 * completer.c: Remove _initialize_completer prototype.
2068 * copying.awk: Remove _initialize_copying prototype.
2069 * copying.c: Regenerate.
2070 * core-regset.c: Remove _initialize_core_regset prototype.
2071 * corefile.c: Remove _initialize_core prototype.
2072 * corelow.c: Remove _initialize_corelow prototype.
2073 * cp-abi.c: Remove _initialize_cp_abi prototype.
2074 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
2075 * cp-support.c: Remove _initialize_cp_support prototype.
2076 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
2077 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
2078 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
2079 * ctf.c: Remove _initialize_ctf prototype.
2080 * d-lang.c: Remove _initialize_d_language prototype.
2081 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
2082 prototype.
2083 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
2084 * dbxread.c: Remove _initialize_dbxread prototype.
2085 * dcache.c: Remove _initialize_dcache prototype.
2086 * demangle.c: Remove _initialize_demangler prototype.
2087 * disasm-selftests.c: Remove _initialize_disasm_selftests
2088 prototype.
2089 * disasm.c: Remove _initialize_disasm prototype.
2090 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
2091 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
2092 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
2093 prototype.
2094 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
2095 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
2096 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
2097 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
2098 * elfread.c: Remove _initialize_elfread prototype.
2099 * exec.c: Remove _initialize_exec prototype.
2100 * extension.c: Remove _initialize_extension prototype.
2101 * f-lang.c: Remove _initialize_f_language prototype.
2102 * f-valprint.c: Remove _initialize_f_valprint prototype.
2103 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
2104 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
2105 * filesystem.c: Remove _initialize_filesystem prototype.
2106 * findcmd.c: Remove _initialize_mem_search prototype.
2107 * fork-child.c: Remove _initialize_fork_child prototype.
2108 * frame-base.c: Remove _initialize_frame_base prototype.
2109 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
2110 * frame.c: Remove _initialize_frame prototype.
2111 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
2112 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
2113 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
2114 * gcore.c: Remove _initialize_gcore prototype.
2115 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
2116 * gdbarch.c: Regenerate.
2117 * gdbarch.sh: Remove _initialize_gdbarch prototype.
2118 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
2119 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
2120 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
2121 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
2122 * go-lang.c: Remove _initialize_go_language prototype.
2123 * go32-nat.c: Remove _initialize_go32_nat prototype.
2124 * guile/guile.c: Remove _initialize_guile prototype.
2125 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
2126 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
2127 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
2128 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
2129 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
2130 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
2131 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
2132 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
2133 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
2134 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
2135 prototype.
2136 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
2137 prototype.
2138 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
2139 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
2140 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
2141 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
2142 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
2143 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
2144 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
2145 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
2146 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
2147 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
2148 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
2149 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
2150 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
2151 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
2152 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
2153 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
2154 prototype.
2155 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
2156 prototype.
2157 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
2158 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
2159 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
2160 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
2161 * infcall.c: Remove _initialize_infcall prototype.
2162 * infcmd.c: Remove _initialize_infcmd prototype.
2163 * inferior.c: Remove _initialize_inferiors prototype.
2164 * inflow.c: Remove _initialize_inflow prototype.
2165 * infrun.c: Remove _initialize_infrun prototype.
2166 * interps.c: Remove _initialize_interpreter prototype.
2167 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
2168 * jit.c: Remove _initialize_jit prototype.
2169 * language.c: Remove _initialize_language prototype.
2170 * linux-fork.c: Remove _initialize_linux_fork prototype.
2171 * linux-nat.c: Remove _initialize_linux_nat prototype.
2172 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
2173 * linux-thread-db.c: Remove _initialize_thread_db prototype.
2174 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
2175 * m2-lang.c: Remove _initialize_m2_language prototype.
2176 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
2177 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
2178 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
2179 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
2180 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
2181 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
2182 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
2183 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
2184 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
2185 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
2186 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
2187 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
2188 * machoread.c: Remove _initialize_machoread prototype.
2189 * macrocmd.c: Remove _initialize_macrocmd prototype.
2190 * macroscope.c: Remove _initialize_macroscope prototype.
2191 * maint.c: Remove _initialize_maint_cmds prototype.
2192 * mdebugread.c: Remove _initialize_mdebugread prototype.
2193 * memattr.c: Remove _initialize_mem prototype.
2194 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
2195 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
2196 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
2197 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
2198 * mi/mi-main.c: Remove _initialize_mi_main prototype.
2199 * microblaze-linux-tdep.c: Remove
2200 _initialize_microblaze_linux_tdep prototype.
2201 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
2202 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
2203 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
2204 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
2205 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
2206 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
2207 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
2208 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
2209 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
2210 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
2211 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
2212 prototype.
2213 * mipsread.c: Remove _initialize_mipsread prototype.
2214 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
2215 prototype.
2216 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
2217 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
2218 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
2219 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
2220 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
2221 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
2222 prototype.
2223 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
2224 * nto-procfs.c: Remove _initialize_procfs prototype.
2225 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
2226 * objc-lang.c: Remove _initialize_objc_language prototype.
2227 * objfiles.c: Remove _initialize_objfiles prototype.
2228 * observer.c: Remove observer_test_first_notification_function,
2229 observer_test_second_notification_function,
2230 observer_test_third_notification_function, and
2231 _initialize_observer prototypes.
2232 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
2233 * osabi.c: Remove _initialize_gdb_osabi prototype.
2234 * osdata.c: Remove _initialize_osdata prototype.
2235 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
2236 * parse.c: Remove _initialize_parse prototype.
2237 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
2238 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
2239 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
2240 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
2241 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
2242 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
2243 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
2244 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
2245 * printcmd.c: Remove _initialize_printcmd prototype.
2246 * probe.c: Remove _initialize_probe prototype.
2247 * proc-api.c: Remove _initialize_proc_api prototype.
2248 * proc-events.c: Remove _initialize_proc_events prototype.
2249 * proc-service.c: Remove _initialize_proc_service prototype.
2250 * procfs.c: Remove _initialize_procfs prototype.
2251 * psymtab.c: Remove _initialize_psymtab prototype.
2252 * python/python.c: Remove _initialize_python prototype.
2253 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
2254 * record-btrace.c: Remove _initialize_record_btrace prototype.
2255 * record-full.c: Remove _initialize_record_full prototype.
2256 * record.c: Remove _initialize_record prototype.
2257 * regcache.c: Remove _initialize_regcache prototype.
2258 * reggroups.c: Remove _initialize_reggroup prototype.
2259 * remote-notif.c: Remove _initialize_notif prototype.
2260 * remote-sim.c: Remove _initialize_remote_sim prototype.
2261 * remote.c: Remove _initialize_remote prototype.
2262 * reverse.c: Remove _initialize_reverse prototype.
2263 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
2264 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
2265 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
2266 prototype.
2267 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
2268 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
2269 * rust-exp.y: Remove _initialize_rust_exp prototype.
2270 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
2271 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
2272 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
2273 * score-tdep.c: Remove _initialize_score_tdep prototype.
2274 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
2275 prototype.
2276 * ser-go32.c: Remove _initialize_ser_dos prototype.
2277 * ser-mingw.c: Remove _initialize_ser_windows prototype.
2278 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
2279 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
2280 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
2281 * serial.c: Remove _initialize_serial prototype.
2282 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
2283 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
2284 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
2285 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
2286 * skip.c: Remove _initialize_step_skip prototype.
2287 * sol-thread.c: Remove _initialize_sol_thread prototype.
2288 * solib-aix.c: Remove _initialize_solib_aix prototype.
2289 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
2290 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
2291 * solib-frv.c: Remove _initialize_frv_solib prototype.
2292 * solib-spu.c: Remove _initialize_spu_solib prototype.
2293 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
2294 * solib-target.c: Remove _initialize_solib_target prototype.
2295 * solib.c: Remove _initialize_solib prototype.
2296 * source.c: Remove _initialize_source prototype.
2297 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
2298 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
2299 prototype.
2300 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
2301 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
2302 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
2303 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
2304 prototype.
2305 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
2306 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
2307 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
2308 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
2309 prototype.
2310 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
2311 prototype.
2312 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
2313 prototype.
2314 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
2315 prototype.
2316 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
2317 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
2318 prototype.
2319 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
2320 prototype.
2321 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
2322 prototype.
2323 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
2324 prototype.
2325 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
2326 prototype.
2327 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
2328 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
2329 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
2330 * stabsread.c: Remove _initialize_stabsread prototype.
2331 * stack.c: Remove _initialize_stack prototype.
2332 * stap-probe.c: Remove _initialize_stap_probe prototype.
2333 * std-regs.c: Remove _initialize_frame_reg prototype.
2334 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
2335 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
2336 * symfile.c: Remove _initialize_symfile prototype.
2337 * symmisc.c: Remove _initialize_symmisc prototype.
2338 * symtab.c: Remove _initialize_symtab prototype.
2339 * target-dcache.c: Remove _initialize_target_dcache prototype.
2340 * target-descriptions.c: Remove _initialize_target_descriptions
2341 prototype.
2342 * thread.c: Remove _initialize_thread prototype.
2343 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
2344 prototype.
2345 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
2346 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
2347 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
2348 prototype.
2349 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
2350 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
2351 * tracefile.c: Remove _initialize_tracefile prototype.
2352 * tracepoint.c: Remove _initialize_tracepoint prototype.
2353 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
2354 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
2355 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
2356 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
2357 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
2358 * tui/tui-win.c: Remove _initialize_tui_win prototype.
2359 * tui/tui.c: Remove _initialize_tui prototype.
2360 * typeprint.c: Remove _initialize_typeprint prototype.
2361 * user-regs.c: Remove _initialize_user_regs prototype.
2362 * utils.c: Remove _initialize_utils prototype.
2363 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
2364 * valarith.c: Remove _initialize_valarith prototype.
2365 * valops.c: Remove _initialize_valops prototype.
2366 * valprint.c: Remove _initialize_valprint prototype.
2367 * value.c: Remove _initialize_values prototype.
2368 * varobj.c: Remove _initialize_varobj prototype.
2369 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
2370 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
2371 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
2372 * windows-nat.c: Remove _initialize_windows_nat,
2373 _initialize_check_for_gdb_ini, and _initialize_loadable
2374 prototypes.
2375 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
2376 * xcoffread.c: Remove _initialize_xcoffread prototype.
2377 * xml-support.c: Remove _initialize_xml_support prototype.
2378 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
2379 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
2380 prototype.
2381 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
2382 prototype.
2383 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
2384
2385 2017-09-08 Keith Seitz <keiths@redhat.com>
2386
2387 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
2388 field.
2389
2390 2017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
2391
2392 * f-valprint.c (f_val_print): Remove check for one byte
2393 sized integers. Remove printing of character type.
2394
2395 2017-09-08 Frank Penczek <frank.penczek@intel.com>
2396 Christoph Weinmann <christoph.t.weinmann@intel.com>
2397 Bernhard Heckel <bernhard.heckel@intel.com>
2398
2399 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
2400 to maintain proper indentation when printing pointers/refs.
2401
2402 2017-09-07 Joel Brobecker <brobecker@adacore.com>
2403
2404 GDB 8.0.1 released.
2405
2406 2017-09-07 Joel Brobecker <brobecker@adacore.com>
2407
2408 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
2409
2410 2017-09-05 Tom Tromey <tom@tromey.com>
2411
2412 * parse.c (funcall_chain): Now a std::vector.
2413 (start_arglist, end_arglist): Simplify.
2414 (free_funcalls): Remove.
2415 (parse_exp_in_context_1): Remove cleanup.
2416
2417 2017-09-05 Tom Tromey <tom@tromey.com>
2418
2419 * go-exp.y (go_parse): Don't create a cleanup.
2420
2421 2017-09-05 Tom Tromey <tom@tromey.com>
2422
2423 * d-exp.y (PrimaryExpression): Use std::string.
2424 (d_parse): Don't create a cleanup.
2425
2426 2017-09-05 Tom Tromey <tom@tromey.com>
2427
2428 * utils.c (do_clear_parser_state): Remove.
2429 (make_cleanup_clear_parser_state): Remove.
2430 * p-exp.y (pascal_parse): Use scoped_restore.
2431 * m2-exp.y (m2_parse): Use scoped_restore.
2432 * f-exp.y (f_parse): Use scoped_restore.
2433 * d-exp.y (d_parse): Use scoped_restore.
2434 * c-exp.y (c_parse): Use scoped_restore.
2435 * ada-exp.y (ada_parse): Use scoped_restore.
2436 * utils.h (make_cleanup_clear_parser_state): Remove.
2437
2438 2017-09-06 Keith Seitz <keiths@redhat.com>
2439
2440 * dwarf2read.c (dw2_linkage_name_attr): New function.
2441 (dw2_linkage_name): New function.
2442 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
2443 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
2444 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
2445
2446 2017-09-06 Kamil Rytarowski <n54@gmx.com>
2447
2448 * config/djgpp/djconfig.sh: Correct shell portability issue.
2449
2450 2017-09-06 Kamil Rytarowski <n54@gmx.com>
2451
2452 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
2453
2454 2017-09-06 John Baldwin <jhb@FreeBSD.org>
2455
2456 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
2457 * NEWS: Mention new FreeBSD/mips native configuration.
2458 * configure.host: Add aarch64*-*-freebsd*.
2459 * configure.nat: Likewise.
2460 * aarch64-fbsd-nat.c: New file.
2461
2462 2017-09-06 John Baldwin <jhb@FreeBSD.org>
2463
2464 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
2465 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
2466 * NEWS: Mention new FreeBSD/aarch64 target.
2467 * configure.tgt: Add aarch64*-*-freebsd*.
2468 * aarch64-fbsd-tdep.c: New file.
2469 * aarch64-fbsd-tdep.h: New file.
2470
2471 2017-09-06 Kamil Rytarowski <n54@gmx.com>
2472
2473 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
2474
2475 2017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
2476
2477 * parse.c (find_minsym_type_and_address): Don't relocate addresses
2478 of TLS symbols.
2479
2480 2017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2481
2482 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
2483 call.
2484
2485 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
2486
2487 * infrun.c (follow_exec): Call add_thread after
2488 target_find_description.
2489
2490 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
2491
2492 * infrun.c (handle_inferior_event_1): When exec'ing, read
2493 stop_pc after follow_exec.
2494
2495 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
2496
2497 * remote.c (process_g_packet): Update error message.
2498
2499 2017-09-05 Yao Qi <yao.qi@linaro.org>
2500
2501 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
2502 targets.
2503
2504 2017-09-05 Pedro Alves <palves@redhat.com>
2505
2506 * eval.c (eval_call, evaluate_funcall): New functions, factored
2507 out from ...
2508 (evaluate_subexp_standard): ... this.
2509
2510 2017-09-05 Yao Qi <yao.qi@linaro.org>
2511
2512 * amd64-tdep.c (amd64_target_description): Create target
2513 descriptions.
2514 (_initialize_amd64_tdep): Don't call functions
2515 initialize_tdesc_amd64_*. Add self tests.
2516 * arch/amd64.c (amd64_create_target_description): Add parameter
2517 is_linux. Call set_tdesc_osabi if is_linux is true.
2518 * arch/amd64.h (amd64_create_target_description): Update the
2519 declaration.
2520 * arch/i386.c (i386_create_target_description): Add parameter
2521 is_linux. Call set_tdesc_osabi if is_linux is true.
2522 * arch/i386.h (i386_create_target_description): Update
2523 declaration.
2524 * configure.tgt: Add i386.o to gdb_target_obs.
2525 * features/Makefile (XMLTOC): Remove i386/*.xml.
2526 * features/i386/amd64-avx-avx512.c: Remove.
2527 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
2528 * features/i386/amd64-avx-mpx.c: Remove.
2529 * features/i386/amd64-avx.c: Remove.
2530 * features/i386/amd64-mpx.c: Remove.
2531 * features/i386/amd64.c: Remove.
2532 * features/i386/i386-avx-avx512.c: Remove.
2533 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
2534 * features/i386/i386-avx-mpx.c: Remove.
2535 * features/i386/i386-avx.c: Remove.
2536 * features/i386/i386-mmx.c: Remove.
2537 * features/i386/i386-mpx.c: Remove.
2538 * features/i386/i386.c: Remove.
2539 * i386-tdep.c: Don't include features/i386/i386*.c., include
2540 target-descriptions.h and arch/i386.h.
2541 (i386_target_description): Create target descriptions.
2542 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
2543 functions. Do self tests.
2544
2545 2017-09-05 Yao Qi <yao.qi@linaro.org>
2546
2547 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
2548 * features/i386/amd64-avx-avx512-linux.c: Removed.
2549 * features/i386/amd64-avx-linux.c: Removed.
2550 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
2551 * features/i386/amd64-avx-mpx-linux.c: Removed.
2552 * features/i386/amd64-linux.c: Removed.
2553 * features/i386/amd64-mpx-linux.c: Removed.
2554 * features/i386/x32-avx-avx512-linux.c: Removed.
2555 * features/i386/x32-avx-linux.c: Removed.
2556 * features/i386/x32-linux.c: Removed.
2557
2558 2017-09-05 Yao Qi <yao.qi@linaro.org>
2559
2560 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
2561 features/i386/*.c.
2562 (amd64_linux_read_description): Call
2563 amd64_create_target_description.
2564 * arch/amd64.c: New file.
2565 * arch/amd64.h: New file.
2566 * configure.tgt (x86_64-*-linux*): Append amd64.o.
2567 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
2568
2569 2017-09-05 Yao Qi <yao.qi@linaro.org>
2570
2571 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
2572 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
2573 (amd64_linux_read_description): Create target descriptions.
2574 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
2575 functions. Add unit tests.
2576 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
2577 x32-core.xml.
2578 * features/i386/64bit-avx.c: Generated.
2579 * features/i386/64bit-avx512.c: Generated.
2580 * features/i386/64bit-core.c: Generated.
2581 * features/i386/64bit-linux.c: Generated.
2582 * features/i386/64bit-mpx.c: Generated.
2583 * features/i386/64bit-pkeys.c: Generated.
2584 * features/i386/64bit-segments.c: Generated.
2585 * features/i386/64bit-sse.c: Generated.
2586 * features/i386/x32-core.c: Generated.
2587 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
2588 c files for amd64-linux and x32-linux.
2589
2590 2017-09-05 Yao Qi <yao.qi@linaro.org>
2591
2592 * amd64-linux-tdep.c (amd64_linux_read_description): New
2593 function.
2594 (amd64_linux_core_read_description): Call
2595 amd64_linux_read_description.
2596 (amd64_linux_init_abi): Likewise.
2597 (amd64_x32_linux_init_abi): Likewise.
2598 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
2599 * x86-linux-nat.c (x86_linux_read_description): Call
2600 amd64_linux_read_description.
2601
2602 2017-09-05 Yao Qi <yao.qi@linaro.org>
2603
2604 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
2605 comments.
2606
2607 2017-09-05 Yao Qi <yao.qi@linaro.org>
2608
2609 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
2610 * features/i386/i386-avx-avx512-linux.c: Remove.
2611 * features/i386/i386-avx-linux.c: Remove.
2612 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
2613 * features/i386/i386-avx-mpx-linux.c: Remove.
2614 * features/i386/i386-linux.c: Remove.
2615 * features/i386/i386-mmx-linux.c: Remove.
2616 * features/i386/i386-mpx-linux.c: Remove.
2617
2618 2017-09-05 Yao Qi <yao.qi@linaro.org>
2619
2620 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
2621 (SFILES): Add arch/i386.c.
2622 (HFILES_NO_SRCDIR): Add arch/i386.h.
2623 * arch/i386.c: New file.
2624 * arch/i386.h: New file.
2625 * arch/tdesc.h (allocate_target_description): Declare.
2626 (set_tdesc_architecture): Declare.
2627 (set_tdesc_osabi): Declare.
2628 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
2629 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
2630 include arch/i386.h.
2631 (i386_linux_read_description): Remove code and call
2632 i386_create_target_description.
2633 (set_tdesc_architecture): New function.
2634 (set_tdesc_osabi): New function.
2635 * target-descriptions.h (allocate_target_description): Remove.
2636
2637 2017-09-05 Yao Qi <yao.qi@linaro.org>
2638
2639 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
2640 * target-descriptions.c (tdesc_create_feature): Likewise, and
2641 adjust code.
2642 * features/i386/32bit-avx.c: Re-generated.
2643 * features/i386/32bit-avx512.c: Re-generated.
2644 * features/i386/32bit-core.c: Re-generated.
2645 * features/i386/32bit-linux.c: Re-generated.
2646 * features/i386/32bit-mpx.c: Re-generated.
2647 * features/i386/32bit-pkeys.c: Re-generated.
2648 * features/i386/32bit-sse.c: Re-generated.
2649
2650 2017-09-05 Yao Qi <yao.qi@linaro.org>
2651
2652 * regformats/regdef.h (struct reg): Override operator == and !=.
2653
2654 2017-09-05 Yao Qi <yao.qi@linaro.org>
2655
2656 * arch/tdesc.h: New file.
2657 * regformats/regdat.sh: Generate code using tdesc_create_reg.
2658 * target-descriptions.c: Update comments.
2659 * target-descriptions.h: Include "arch/tdesc.h". Remove the
2660 declarations.
2661 * features/i386/32bit-avx.c: Re-generated.
2662 * features/i386/32bit-avx512.c: Re-generated.
2663 * features/i386/32bit-core.c: Re-generated.
2664 * features/i386/32bit-linux.c: Re-generated.
2665 * features/i386/32bit-mpx.c: Re-generated.
2666 * features/i386/32bit-pkeys.c: Re-generated.
2667 * features/i386/32bit-sse.c: Re-generated.
2668
2669 2017-09-05 Yao Qi <yao.qi@linaro.org>
2670
2671 * regformats/regdat.sh: Update generated code.
2672
2673 2017-09-05 Yao Qi <yao.qi@linaro.org>
2674
2675 * regformats/regdat.sh: Adjust code order.
2676
2677 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
2678
2679 * expprint.c (dump_subexp_body_standard): Use constant format
2680 string in fprintf_filtered call.
2681
2682 2017-09-04 John Baldwin <jhb@FreeBSD.org>
2683
2684 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
2685 NetBSD/i386.
2686 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
2687
2688 2017-09-04 John Baldwin <jhb@FreeBSD.org>
2689
2690 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
2691
2692 2017-09-04 John Baldwin <jhb@FreeBSD.org>
2693
2694 * bsd-kvm.o: Define _KMEMUSER.
2695 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
2696 * configure: Regenerate.
2697
2698 2017-09-04 John Baldwin <jhb@FreeBSD.org>
2699
2700 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
2701 * i386-fbsd-nat.c: Likewise.
2702
2703 2017-09-04 John Baldwin <jhb@FreeBSD.org>
2704
2705 * unittests/array-view-selftests.c: Add include of <array>.
2706
2707 2017-09-04 John Baldwin <jhb@FreeBSD.org>
2708
2709 * spu-tdep.c (flush_ea_cache): Add missing argument to
2710 call_function_by_hand.
2711
2712 2017-09-04 Pedro Alves <palves@redhat.com>
2713
2714 * NEWS (Safer support for debugging with no debug info): New.
2715
2716 2017-09-04 Pedro Alves <palves@redhat.com>
2717
2718 * c-exp.y (function_method, function_method_void): Add current
2719 instance flags to TYPE_INSTANCE.
2720 * dwarf2read.c (check_modifier): New.
2721 (compute_delayed_physnames): Assert that only C++ adds delayed
2722 physnames. Mark fn_fields as const/volatile depending on
2723 physname.
2724 * eval.c (make_params): New type_instance_flags parameter. Use
2725 it as the new type's instance flags.
2726 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
2727 flags element and pass it to make_params.
2728 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
2729 instance flags element.
2730 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
2731 * gdbtypes.h: Include "enum-flags.h".
2732 (type_instance_flags): New enum-flags type.
2733 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
2734 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
2735 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
2736 (follow_type_instance_flags): New function.
2737 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
2738 * parser-defs.h (follow_type_instance_flags): Declare.
2739 * valops.c (value_struct_elt_for_reference): const/volatile must
2740 match too.
2741
2742 2017-09-04 Pedro Alves <palves@redhat.com>
2743
2744 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
2745 function/method scopes; lookup the nested name as a function local
2746 static variable.
2747
2748 2017-09-04 Pedro Alves <palves@redhat.com>
2749
2750 (%type <voidval>): Add function_method.
2751 * c-exp.y (exp): New production for calls with no arguments.
2752 (function_method, function_method_void_or_typelist): New
2753 productions.
2754 (exp): New production for "method()::static_var".
2755 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
2756 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
2757 Handle OP_FUNC_STATIC_VAR.
2758 * parse.c (operator_length_standard):
2759 Handle OP_FUNC_STATIC_VAR.
2760
2761 2017-09-04 Pedro Alves <palves@redhat.com>
2762
2763 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
2764 handling.
2765 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
2766 Ditto.
2767 * parse.c (operator_length_standard, operator_check_standard):
2768 Ditto.
2769 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
2770
2771 2017-09-04 Pedro Alves <palves@redhat.com>
2772
2773 * ax-gdb.c: Include "typeprint.h".
2774 (gen_expr_for_cast): New function.
2775 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
2776 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
2777 type is unknown.
2778 * dwarf2read.c (new_symbol_full): Fallback to int instead of
2779 nodebug_data_symbol.
2780 * eval.c: Include "typeprint.h".
2781 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
2782 Error out if symbol has unknown type.
2783 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
2784 evaluate_subexp_for_cast.
2785 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
2786 OP_VAR_MSYM_VALUE.
2787 (evaluate_subexp_for_cast): New function.
2788 * gdbtypes.c (init_nodebug_var_type): New function.
2789 (objfile_type): Use it to initialize types of variables with no
2790 debug info.
2791 * typeprint.c (error_unknown_type): New.
2792 * typeprint.h (error_unknown_type): New declaration.
2793 * compile/compile-c-types.c (convert_type_basic): Handle
2794 TYPE_CODE_ERROR; warn and fallback to int for variables with
2795 unknown type.
2796
2797 2017-09-04 Pedro Alves <palves@redhat.com>
2798
2799 * eval.c (evaluate_var_value): New function, factored out from ...
2800 (evaluate_subexp_standard): ... here.
2801
2802 2017-09-04 Pedro Alves <palves@redhat.com>
2803
2804 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
2805 Remove useless assignments to 'op'.
2806
2807 2017-09-04 Pedro Alves <palves@redhat.com>
2808
2809 * eval.c (eval_skip_value): New function.
2810 (evaluate_subexp_standard): Use it.
2811
2812 2017-09-04 Pedro Alves <palves@redhat.com>
2813
2814 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
2815 function name from symbol/minsym and pass it to
2816 error_call_unknown_return_type.
2817
2818 2017-09-04 Pedro Alves <palves@redhat.com>
2819
2820 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
2821 * ax-gdb.c (gen_msym_var_ref): New function.
2822 (gen_expr): Handle OP_VAR_MSYM_VALUE.
2823 * eval.c (evaluate_var_msym_value): New function.
2824 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
2825 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
2826 to call_function_by_hand.
2827 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
2828 Handle OP_VAR_MSYM_VALUE.
2829 (union exp_element) <msymbol>: New field.
2830 * minsyms.h (struct type): Forward declare.
2831 (find_minsym_type_and_address): Declare.
2832 * parse.c (write_exp_elt_msym): New function.
2833 (write_exp_msymbol): Delete, refactored as ...
2834 (find_minsym_type_and_address): ... this new function.
2835 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
2836 (operator_length_standard, operator_check_standard): Handle
2837 OP_VAR_MSYM_VALUE.
2838 * std-operator.def (OP_VAR_MSYM_VALUE): New.
2839
2840 2017-09-04 Pedro Alves <palves@redhat.com>
2841
2842 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
2843 TYPE_GNU_IFUNC specially here. Throw error if return type is
2844 unknown.
2845 * ada-typeprint.c (print_func_type): Handle functions with unknown
2846 return type.
2847 * c-typeprint.c (c_type_print_base): Handle functions and methods
2848 with unknown return type.
2849 * compile/compile-c-symbols.c (convert_symbol_bmsym)
2850 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
2851 * compile/compile-c-types.c: Include "objfiles.h".
2852 (convert_func): For functions with unknown return type, warn and
2853 default to int.
2854 * compile/compile-object-run.c (compile_object_run): Adjust call
2855 to call_function_by_hand_dummy.
2856 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
2857 call_function_by_hand.
2858 * eval.c (evaluate_subexp_standard): Adjust calls to
2859 call_function_by_hand. Handle functions and methods with unknown
2860 return type. Pass expect_type to call_function_by_hand.
2861 * f-typeprint.c (f_type_print_base): Handle functions with unknown
2862 return type.
2863 * gcore.c (call_target_sbrk): Adjust call to
2864 call_function_by_hand.
2865 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
2866 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
2867 an integer address type instead of nodebug.
2868 * guile/scm-value.c (gdbscm_value_call): Adjust call to
2869 call_function_by_hand.
2870 * infcall.c (error_call_unknown_return_type): New function.
2871 (call_function_by_hand): New "default_return_type" parameter.
2872 Pass it down.
2873 (call_function_by_hand_dummy): New "default_return_type"
2874 parameter. Use it instead of defaulting to int. If there's no
2875 default and the return type is unknown, throw an error. If
2876 there's a default return type, and the called function has no
2877 debug info, then assume the function is prototyped.
2878 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
2879 New "default_return_type" parameter.
2880 (error_call_unknown_return_type): New declaration.
2881 * linux-fork.c (call_lseek): Cast return type of lseek.
2882 (inferior_call_waitpid, checkpoint_command): Adjust calls to
2883 call_function_by_hand.
2884 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
2885 calls to call_function_by_hand.
2886 * m2-typeprint.c (m2_procedure): Handle functions with unknown
2887 return type.
2888 * objc-lang.c (lookup_objc_class, lookup_child_selector)
2889 (value_nsstring, print_object_command): Adjust calls to
2890 call_function_by_hand.
2891 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
2892 functions with unknown return type.
2893 (pascal_type_print_func_varspec_suffix): New function.
2894 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
2895 TYPE_CODE_METHOD>: Use it.
2896 * python/py-value.c (valpy_call): Adjust call to
2897 call_function_by_hand.
2898 * rust-lang.c (rust_evaluate_funcall): Adjust call to
2899 call_function_by_hand.
2900 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
2901 call_function_by_hand.
2902 * valops.c (value_allocate_space_in_inferior): Adjust call to
2903 call_function_by_hand.
2904 * typeprint.c (type_print_unknown_return_type): New function.
2905 * typeprint.h (type_print_unknown_return_type): New declaration.
2906
2907 2017-09-04 Pedro Alves <palves@redhat.com>
2908
2909 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
2910 types with more than one parameter as prototyped.
2911
2912 2017-09-04 Pedro Alves <palves@redhat.com>
2913
2914 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
2915 (disassemble_command): Use gdb_disassembly_flags instead of bare
2916 int.
2917 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
2918 (dump_insns, do_mixed_source_and_assembly_deprecated)
2919 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
2920 Use gdb_disassembly_flags instead of bare int.
2921 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
2922 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
2923 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
2924 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
2925 (enum gdb_disassembly_flag): ... values of this new enumeration.
2926 (gdb_disassembly_flags): Define.
2927 (gdb_disassembly)
2928 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
2929 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
2930 gdb_disassembly_flags instead of bare int.
2931 * record-btrace.c (btrace_insn_history)
2932 (record_btrace_insn_history, record_btrace_insn_history_range)
2933 (record_btrace_insn_history_from): Use gdb_disassembly_flags
2934 instead of bare int.
2935 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
2936 Use gdb_disassembly_flags instead of bare int.
2937 * target-debug.h (target_debug_print_gdb_disassembly_flags):
2938 Define.
2939 * target-delegates.c: Regenerate.
2940 * target.c (target_insn_history, target_insn_history_from)
2941 (target_insn_history_range): Use gdb_disassembly_flags instead of
2942 bare int.
2943 * target.h: Include "disasm.h".
2944 (struct target_ops) <to_insn_history, to_insn_history_from,
2945 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
2946 int.
2947 (target_insn_history, target_insn_history_from)
2948 (target_insn_history_range): Use gdb_disassembly_flags instead of
2949 bare int.
2950
2951 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2952
2953 * cli/cli-script.c (build_command_line): For if/while commands,
2954 check whether args is empty.
2955
2956 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2957
2958 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
2959 (enum command_control_type): Likewise.
2960 (struct command_line): Likewise.
2961 (free_command_lines): Likewise.
2962 (struct command_lines_deleter): Likewise.
2963 (command_line_up): Likewise.
2964 (read_command_lines): Likewise.
2965 (read_command_lines_1): Likewise.
2966 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
2967 (enum command_control_type): Likewise.
2968 (struct command_line): Likewise.
2969 (free_command_lines): Likewise.
2970 (struct command_lines_deleter): Likewise.
2971 (command_line_up): Likewise.
2972 (read_command_lines): Likewise.
2973 (read_command_lines_1): Likewise.
2974 * breakpoint.h: Include cli/cli-script.h.
2975 * extension-priv.h: Likewise.
2976 * gdbcmd.h: Likewise.
2977
2978 2017-09-04 Pedro Alves <palves@redhat.com>
2979
2980 * ada-lang.c (is_known_support_routine): Move sal declaration to
2981 where it is initialized.
2982 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
2983 (parse_breakpoint_sals, decode_static_tracepoint_spec)
2984 (clear_command, update_static_tracepoint): Remove init_sal
2985 references. Move declarations closer to initializations.
2986 * cli/cli-cmds.c (list_command): Move sal declarations closer to
2987 initializations.
2988 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
2989 references. Move sal declarations closer to initializations.
2990 * frame.c (find_frame_sal): Return a symtab_and_line via function
2991 return instead of output parameter. Remove init_sal references.
2992 * frame.h (find_frame_sal): Return a symtab_and_line via function
2993 return instead of output parameter.
2994 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
2995 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
2996 instead of memset.
2997 (gdbscm_find_pc_line): Remove init_sal reference.
2998 * infcall.c (call_function_by_hand_dummy): Remove init_sal
2999 references. Move declarations closer to initializations.
3000 * infcmd.c (set_step_frame): Update. Move declarations closer to
3001 initializations.
3002 (finish_backward): Remove init_sal references. Move declarations
3003 closer to initializations.
3004 * infrun.c (process_event_stop_test, handle_step_into_function)
3005 (insert_hp_step_resume_breakpoint_at_frame)
3006 (insert_step_resume_breakpoint_at_caller): Likewise.
3007 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
3008 (symbol_to_sal): Likewise.
3009 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
3010 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
3011 to its initialization.
3012 * reverse.c (save_bookmark_command): Use new/delete. Remove
3013 init_sal references. Move declarations closer to initializations.
3014 * source.c (get_current_source_symtab_and_line): Remove brace
3015 initialization.
3016 (set_current_source_symtab_and_line): Now takes the sal by const
3017 reference. Remove brace initialization.
3018 (line_info): Remove init_sal reference.
3019 * source.h (set_current_source_symtab_and_line): Now takes a
3020 symtab_and_line via const reference.
3021 * stack.c (set_current_sal_from_frame): Adjust.
3022 (print_frame_info): Adjust.
3023 (get_last_displayed_sal): Return the sal via function return
3024 instead of via output parameter. Simplify.
3025 (frame_info): Adjust.
3026 * stack.h (get_last_displayed_sal): Return the sal via function
3027 return instead of via output parameter.
3028 * symtab.c (init_sal): Delete.
3029 (find_pc_sect_line): Remove init_sal references. Move
3030 declarations closer to initializations.
3031 (find_function_start_sal): Remove init_sal references. Move
3032 declarations closer to initializations.
3033 * symtab.h (struct symtab_and_line): In-class initialize all
3034 fields.
3035 * tracepoint.c (set_traceframe_context)
3036 (print_one_static_tracepoint_marker): Remove init_sal references.
3037 Move declarations closer to initializations.
3038 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
3039 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
3040 declarations closer to initializations.
3041 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
3042 init_sal references. Adjust.
3043
3044 2017-09-04 Pedro Alves <palves@redhat.com>
3045
3046 * ax-gdb.c (agent_command_1): Use range-for.
3047 * break-catch-throw.c (re_set_exception_catchpoint): Update.
3048 * breakpoint.c: Include "common/array-view.h".
3049 (init_breakpoint_sal, create_breakpoint_sal): Change sals
3050 parameter from struct symtabs_and_lines to
3051 array_view<symtab_and_line>. Adjust. Use range-for. Update.
3052 (breakpoint_sals_to_pc): Change sals parameter from struct
3053 symtabs_and_lines to std::vector reference.
3054 (check_fast_tracepoint_sals): Change sals parameter from struct
3055 symtabs_and_lines to std::array_view. Use range-for.
3056 (decode_static_tracepoint_spec): Return a std::vector instead of
3057 symtabs_and_lines. Update.
3058 (create_breakpoint): Update.
3059 (break_range_command, until_break_command, clear_command): Update.
3060 (base_breakpoint_decode_location, bkpt_decode_location)
3061 (bkpt_probe_create_sals_from_location)
3062 (bkpt_probe_decode_location, tracepoint_decode_location)
3063 (tracepoint_probe_decode_location)
3064 (strace_marker_create_sals_from_location): Return a std::vector
3065 instead of symtabs_and_lines.
3066 (strace_marker_create_breakpoints_sal): Update.
3067 (strace_marker_decode_location): Return a std::vector instead of
3068 symtabs_and_lines. Update.
3069 (update_breakpoint_locations): Change struct symtabs_and_lines
3070 parameters to gdb::array_view. Adjust.
3071 (location_to_sals): Return a std::vector instead of
3072 symtabs_and_lines. Update.
3073 (breakpoint_re_set_default): Use std::vector instead of struct
3074 symtabs_and_lines.
3075 (decode_location_default): Return a std::vector instead of
3076 symtabs_and_lines. Update.
3077 * breakpoint.h: Include "common/array-view.h".
3078 (struct breakpoint_ops) <decode_location>: Now returns a
3079 std::vector instead of returning a symtabs_and_lines via output
3080 parameter.
3081 (update_breakpoint_locations): Change sals parameters to use
3082 gdb::array_view.
3083 * cli/cli-cmds.c (edit_command, list_command): Update to use
3084 std::vector and gdb::array_view.
3085 (ambiguous_line_spec): Adjust to use gdb::array_view and
3086 range-for.
3087 (compare_symtabs): Rename to ...
3088 (cmp_symtabs): ... this. Change parameters to symtab_and_line
3089 const reference and adjust.
3090 (filter_sals): Rewrite using std::vector and standard algorithms.
3091 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
3092 (jump_command): Update to use std::vector.
3093 * linespec.c (struct linespec_state) <canonical_names>: Update
3094 comment.
3095 (add_sal_to_sals_basic): Delete.
3096 (add_sal_to_sals, filter_results, convert_results_to_lsals)
3097 (decode_line_2, create_sals_line_offset)
3098 (convert_address_location_to_sals, convert_linespec_to_sals)
3099 (convert_explicit_location_to_sals, parse_linespec)
3100 (event_location_to_sals, decode_line_full, decode_line_1)
3101 (decode_line_with_current_source)
3102 (decode_line_with_last_displayed, decode_objc)
3103 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
3104 (linespec_result::~linespec_result): Adjust to use std::vector
3105 instead of symtabs_and_lines.
3106 * linespec.h (linespec_sals::sals): Now a std::vector.
3107 (struct linespec_result): Use std::vector, bool, and in-class
3108 initialization.
3109 (decode_line_1, decode_line_with_current_source)
3110 (decode_line_with_last_displayed): Return std::vector.
3111 * macrocmd.c (info_macros_command): Use std::vector.
3112 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
3113 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
3114 std::vector.
3115 * probe.h (parse_probes): Return a std::vector.
3116 * python/python.c (gdbpy_decode_line): Use std::vector and
3117 gdb::array_view.
3118 * source.c (select_source_symtab, line_info): Use std::vector.
3119 * stack.c (func_command): Use std::vector.
3120 * symtab.h (struct symtabs_and_lines): Delete.
3121 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
3122
3123 2017-09-04 Pedro Alves <palves@redhat.com>
3124
3125 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3126 unittests/array-view-selftests.c.
3127 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
3128 * common/array-view.h: New file.
3129 * unittests/array-view-selftests.c: New file.
3130
3131 2017-09-04 Pedro Alves <palves@redhat.com>
3132
3133 * cli/cli-cmds.c (edit_command): Pass message to
3134 ambiguous_line_spec.
3135 (list_command): Pass message to ambiguous_line_spec. Say
3136 "first"/"last" instead of "start" and "end" to be consistent with
3137 the manual.
3138 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
3139 them to print formatted message.
3140
3141 2017-09-04 Pedro Alves <palves@redhat.com>
3142
3143 * btrace.c (ftrace_add_pt): Pass btrace_insn to
3144 ftrace_update_insns by reference instead of pointer.
3145
3146 2017-09-04 Yao Qi <yao.qi@linaro.org>
3147
3148 * i386-go32-tdep.c: Include x86-xstate.h.
3149 (i386_go32_init_abi): Call i386_target_description.
3150 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
3151 if xcr0 is X86_XSTATE_X87_MASK.
3152 * i386-tdep.h (tdesc_i386): Remove the declaration.
3153 (tdesc_i386_mmx): Likewise.
3154
3155 2017-09-04 Yao Qi <yao.qi@linaro.org>
3156
3157 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
3158 X86_XSTATE_SSE_MASK instead of 0.
3159
3160 2017-09-04 Yao Qi <yao.qi@linaro.org>
3161
3162 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
3163 i386_target_description.
3164 * i386-fbsd-nat.c (i386fbsd_read_description): Call
3165 i386_target_description.
3166 * i386-tdep.c (i386_gdbarch_init): Likewise.
3167
3168 2017-09-04 Yao Qi <yao.qi@linaro.org>
3169
3170 * amd64-darwin-tdep.c: Include "x86-xstate.h".
3171 (x86_darwin_init_abi_64): Call amd64_target_description.
3172 * amd64-dicos-tdep.c: Likewise.
3173 * amd64-fbsd-nat.c: Likewise.
3174 * amd64-fbsd-tdep.c: Likewise.
3175 * amd64-nbsd-tdep.c: Likewise.
3176 * amd64-obsd-tdep.c: Likewise.
3177 * amd64-sol2-tdep.c: Likewise.
3178 * amd64-windows-tdep.c: Likewise.
3179 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
3180
3181 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
3182
3183 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
3184 (btrace_function) <insn>: Change type to use std::vector.
3185 * btrace.c (ftrace_debug, ftrace_call_num_insn,
3186 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
3187 ftrace_update_insns, ftrace_compute_global_level_offset,
3188 btrace_stitch_bts, btrace_clear, btrace_insn_get,
3189 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
3190 change to std::vector.
3191 (ftrace_update_insns): Adjust to change to std::vector, change
3192 type of INSN parameter.
3193 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
3194 * record-btrace.c (btrace_call_history_insn_range,
3195 btrace_compute_src_line_range,
3196 record_btrace_frame_prev_register): Adjust to change to
3197 std::vector.
3198 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
3199 to change to std::vector.
3200
3201 2017-09-03 Tom Tromey <tom@tromey.com>
3202
3203 * corefile.c (reopen_exec_file): Use std::string.
3204
3205 2017-09-03 Tom Tromey <tom@tromey.com>
3206
3207 * compile/compile.c (compile_register_name_mangled): Return
3208 std::string.
3209 * compile/compile-loc2c.c (pushf_register_address): Update.
3210 (pushf_register): Update.
3211 * compile/compile-c-types.c (convert_array): Update.
3212 * compile/compile-c-symbols.c (generate_vla_size): Update.
3213 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
3214 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
3215 (convert_one_symbol): Update.
3216 (generate_c_for_for_one_variable): Update.
3217 * compile/compile-c-support.c (c_get_range_decl_name): Return a
3218 std::string.
3219 (generate_register_struct): Update.
3220 * compile/compile-internal.h (c_get_range_decl_name): Return a
3221 std::string.
3222 (compile_register_name_mangled): Return std::string.
3223
3224 2017-09-03 Tom Tromey <tom@tromey.com>
3225
3226 * utils.c (perror_string): Return a std::string.
3227 (throw_perror_with_name, perror_warning_with_name): Update.
3228
3229 2017-09-03 Tom Tromey <tom@tromey.com>
3230
3231 * demangle.c (demangle_command): Use std::string,
3232 unique_xmalloc_ptr.
3233
3234 2017-09-03 Tom Tromey <tom@tromey.com>
3235
3236 * cli/cli-setshow.c (do_set_command): Use std::string.
3237
3238 2017-09-03 Tom Tromey <tom@tromey.com>
3239
3240 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
3241
3242 2017-09-03 Tom Tromey <tom@tromey.com>
3243
3244 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
3245
3246 2017-09-03 Tom Tromey <tom@tromey.com>
3247
3248 * mi/mi-cmd-env.c (env_execute_cli_command): Use
3249 gdb::unique_xmalloc_ptr.
3250
3251 2017-09-03 Tom Tromey <tom@tromey.com>
3252
3253 * thread.c (print_thread_info_1): Use string_printf.
3254 (thread_apply_command, thread_apply_all_command): Use
3255 std::string.
3256
3257 2017-09-03 Tom Tromey <tom@tromey.com>
3258
3259 * valprint.c (val_print_string): Update.
3260 * gdbcore.h (memory_error_message): Return std::string.
3261 * corefile.c (memory_error_message): Return std::string.
3262 (memory_error): Update.
3263 * breakpoint.c (insert_bp_location): Update.
3264
3265 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
3266
3267 * target/waitstatus.h (target_waitstatus_to_string): Change
3268 return type to std::string.
3269 * target/waitstatus.c (target_waitstatus_to_string): Return
3270 std::string.
3271 * target.h (target_waitstatus_to_string): Remove declaration.
3272 * infrun.c (resume, clear_proceed_status_thread,
3273 print_target_wait_results, do_target_wait, save_waitstatus,
3274 stop_all_threads): Adjust.
3275 * record-btrace.c (record_btrace_wait): Adjust.
3276 * target-debug.h
3277 (target_debug_print_struct_target_waitstatus_p): Adjust.
3278
3279 2017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
3280
3281 PR gdb/22046
3282 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
3283 detection.
3284
3285 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
3286
3287 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
3288 for setting/unsetting environment variables on the remote target.
3289 (New remote packets): Add entries for QEnvironmentHexEncoded,
3290 QEnvironmentUnset and QEnvironmentReset.
3291 * common/environ.c (gdb_environ::operator=): Extend method to
3292 handle m_user_set_env_list and m_user_unset_env_list.
3293 (gdb_environ::clear): Likewise.
3294 (match_var_in_string): Change type of first parameter from 'char
3295 *' to 'const char *'.
3296 (gdb_environ::set): Extend method to handle
3297 m_user_set_env_list and m_user_unset_env_list.
3298 (gdb_environ::unset): Likewise.
3299 (gdb_environ::clear_user_set_env): New method.
3300 (gdb_environ::user_set_envp): Likewise.
3301 (gdb_environ::user_unset_envp): Likewise.
3302 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
3303 m_user_unset_env_list on move constructor/assignment.
3304 (unset): Add new default parameter 'update_unset_list = true'.
3305 (clear_user_set_env): New method.
3306 (user_set_envp): Likewise.
3307 (user_unset_envp): Likewise.
3308 (m_user_set_env_list): New std::set.
3309 (m_user_unset_env_list): Likewise.
3310 * common/rsp-low.c (hex2str): New function.
3311 (bin2hex): New overload for bin2hex function.
3312 * common/rsp-low.c (hex2str): New prototype.
3313 (str2hex): New overload prototype.
3314 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
3315 QEnvironmentUnset and QEnvironmentReset.
3316 (remote_protocol_features): Add QEnvironmentHexEncoded,
3317 QEnvironmentUnset and QEnvironmentReset packets.
3318 (send_environment_packet): New function.
3319 (extended_remote_environment_support): Likewise.
3320 (extended_remote_create_inferior): Call
3321 extended_remote_environment_support.
3322 (_initialize_remote): Add QEnvironmentHexEncoded,
3323 QEnvironmentUnset and QEnvironmentReset packet configs.
3324 * unittests/environ-selftests.c (gdb_selftest_env_var):
3325 New variable.
3326 (test_vector_initialization): New function.
3327 (test_init_from_host_environ): Likewise.
3328 (test_reinit_from_host_environ): Likewise.
3329 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
3330 Likewise.
3331 (test_unset_set_empty_vector): Likewise.
3332 (test_vector_clear): Likewise.
3333 (test_std_move): Likewise.
3334 (test_move_constructor):
3335 (test_self_move): Likewise.
3336 (test_set_unset_reset): Likewise.
3337 (run_tests): Rewrite in terms of the functions above.
3338
3339 2017-08-31 Weimin Pan <weimin.pan@oracle.com>
3340
3341 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
3342 (adi_available): Use a temp variable of type CORE_ADDR as argument
3343 3 when calling target_auxv_search.
3344 (adi_normalize_address): Use masks and xor operators to calculate
3345 normalized address.
3346 (adi_read_versions, adi_write_versions, adi_print_versions)
3347 (do_examine, do_assign): Use paddress.
3348
3349 2017-08-29 John Baldwin <jhb@FreeBSD.org>
3350
3351 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
3352 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
3353 out of loop and add supply of FIR.
3354 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
3355 add collect of FIR.
3356
3357 2017-08-28 Simon Marchi <simon.marchi@ericsson.com>
3358
3359 PR gdb/21827
3360 * cli/cli-script.c (define_command): Don't convert command name
3361 to lower case.
3362
3363 2017-08-25 Joel Brobecker <brobecker@adacore.com>
3364
3365 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
3366 Update all callers accordingly. Remove all code blocks handling
3367 the case where DISPP is not NULL.
3368
3369 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
3370
3371 PR symtab/22003
3372 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
3373 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
3374 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
3375
3376 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
3377
3378 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
3379 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
3380 (read_comp_units_from_section): New parameter abbrev_section, use
3381 read_and_check_comp_unit_head, allocate signatured_type if needed.
3382 (create_all_comp_units): Update read_comp_units_from_section caller.
3383
3384 2017-08-23 Pedro Alves <palves@redhat.com>
3385
3386 PR remote/21852
3387 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
3388 to null_ptid and switch to thread without reading the registers
3389 after adding the inferior.
3390
3391 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
3392
3393 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
3394 compile-gcc.
3395 * compile/compile.c (compile_gcc, show_compile_gcc): New.
3396 (compile_to_object): Implement compile_gcc.
3397 (_initialize_compile): Install "set compile-gcc". Initialize
3398 compile_gcc.
3399
3400 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
3401
3402 * compile/compile.c (compile_to_object): Conditionally call
3403 set_verbose. Conditionally call compile or compile_v0.
3404
3405 2017-08-07 Weimin Pan <weimin.pan@oracle.com>
3406
3407 * sparc64-tdep.h: (adi_normalize_address): New export.
3408 * sparc-nat.h: (open_adi_tag_fd): New export.
3409 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
3410 * sparc64-linux-tdep.c:
3411 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
3412 (sparc64_linux_handle_segmentation_fault): New function.
3413 (sparc64_linux_init_abi): Register
3414 sparc64_linux_handle_segmentation_fault
3415 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
3416 (sparc64_addr_bits_remove): New function.
3417 (sparc64_init_abi): Register sparc64_addr_bits_remove.
3418 (MAX_PROC_NAME_SIZE): New macro.
3419 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
3420 (sparc64adilist): New variable.
3421 (adi_proc_list): New variable.
3422 (find_adi_info): New function.
3423 (add_adi_info): New function.
3424 (get_adi_info_proc): New function.
3425 (get_adi_info): New function.
3426 (info_adi_command): New function.
3427 (read_maps_entry): New function.
3428 (adi_available): New function.
3429 (adi_normalize_address): New function.
3430 (adi_align_address): New function.
3431 (adi_convert_byte_count): New function.
3432 (adi_tag_fd): New function.
3433 (adi_is_addr_mapped): New function.
3434 (adi_read_versions): New function.
3435 (adi_write_versions): New function.
3436 (adi_print_versions): New function.
3437 (do_examine): New function.
3438 (do_assign): New function.
3439 (adi_examine_command): New function.
3440 (adi_assign_command): New function.
3441 (_initialize_sparc64_adi_tdep): New function.
3442
3443 2017-08-22 Simon Marchi <simon.marchi@ericsson.com>
3444
3445 * breakpoint.c (breakpoints_info): Rename to ...
3446 (info_breakpoints_command): ... this.
3447 (watchpoints_info): Rename to ...
3448 (info_watchpoints_command): ... this.
3449 (tracepoints_info): Rename to ...
3450 (info_tracepoints_command): ... this.
3451 (_initialize_breakpoint): Adjust.
3452 * dcache.c (dcache_info): Rename to ...
3453 (info_display_command): ... this.
3454 (_initialize_dcache): Adjust.
3455 * frame.h (args_info): Rename to ...
3456 (info_args_command): ... this.
3457 (locals_info): Rename to ...
3458 (info_locals_command): ... this.
3459 * infcmd.c (nofp_registers_info): Rename to ...
3460 (info_registers_command): ... this.
3461 (float_info): Rename to ...
3462 (info_float_command): ... this.
3463 (program_info): Rename to ...
3464 (info_program_command): ... this.
3465 (all_registers_info): Rename to ...
3466 (info_all_registers_command): ... this.
3467 (vector_info): Rename to ...
3468 (info_vector_command): ... this.
3469 (float_info): Rename to ...
3470 (info_float_command): ... this.
3471 (_initialize_infcmd): Adjust.
3472 * inferior.h (term_info): Rename to ...
3473 (info_terminal_command): ... this.
3474 * inflow.c (term_info): Rename to ...
3475 (info_terminal_command): ... this.
3476 (_initialize_inflow): Adjust.
3477 * infrun.c (signals_info): Rename to ...
3478 (info_signals_command): ... this.
3479 (_initialize_infrun): Adjust.
3480 * objc-lang.c (classes_info): Rename to ...
3481 (info_classes_command): ... this.
3482 (selectors_info): Rename to ...
3483 (info_selectors_command): ... this.
3484 (_initialize_objc_language): Adjust.
3485 * printcmd.c (sym_info): Rename to ...
3486 (info_symbol_command): ... this.
3487 (address_info): Rename to ...
3488 (info_address_command): ... this.
3489 (display_info): Rename to ...
3490 (info_display_command): ... this.
3491 (_initialize_printcmd): Adjust.
3492 * reverse.c (bookmarks_info): Rename to ...
3493 (info_breakpoints_command): ... this.
3494 (_initialize_reverse): Adjust.
3495 * ser-go32.c (dos_info): Rename to ...
3496 (info_serial_command): ... this.
3497 (_initialize_ser_dos): Adjust.
3498 * skip.c (skip_info): Rename to ...
3499 (info_skip_command): ... this.
3500 (_initialize_step_skip): Adjust.
3501 * source.c (line_info): Rename to ...
3502 (info_line_command): ... this.
3503 (source_info): Rename to ...
3504 (info_source_command)
3505 * stack.c (frame_info): Rename to ...
3506 (info_frame_command): ... this.
3507 (locals_info): Rename to ...
3508 (info_locals_command): ... this.
3509 (args_info): Rename to ...
3510 (info_args_command): ... this.
3511 (_initialize_stack): Adjust.
3512 * symtab.c (sources_info): Rename to ...
3513 (info_sources_command): ... this.
3514 (variables_info): Rename to ...
3515 (info_variables_command): ... this.
3516 (functions_info): Rename to ...
3517 (info_functions_command): ... this.
3518 (types_info): Rename to ...
3519 (info_types_command): ... this.
3520 (_initialize_symtab): Adjust.
3521 * target.c (target_info): Rename to ...
3522 (info_target_command): ... this.
3523 (initialize_targets): Adjust.
3524 * tracepoint.c (tvariables_info): Rename to ...
3525 (info_tvariables_command): ... this.
3526 (scope_info): Rename to ...
3527 (info_scope_command): ... this.
3528 (trace_dump_actions): Adjust.
3529 (_initialize_tracepoint): Adjust.
3530
3531 2017-08-22 Tom Tromey <tom@tromey.com>
3532
3533 * breakpoint.h (install_breakpoint): Update.
3534 * breakpoint.c (add_solib_catchpoint): Update.
3535 (install_breakpoint): Change argument to a std::unique_ptr.
3536 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
3537 (create_breakpoint_sal, create_breakpoint): Update.
3538 (watch_command_1, catch_exec_command_1)
3539 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
3540 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
3541 Return the breakpoint.
3542 (set_raw_breakpoint_without_location, set_raw_breakpoint)
3543 (new_single_step_breakpoint): Update.
3544 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
3545 std::unique_ptr.
3546 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
3547 std::unique_ptr.
3548 * break-catch-sig.c (create_signal_catchpoint): Use
3549 std::unique_ptr.
3550 * ada-lang.c (create_ada_exception_catchpoint): Use
3551 std::unique_ptr.
3552
3553 2017-08-22 Tom Tromey <tom@tromey.com>
3554
3555 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
3556
3557 2017-08-22 Tom Tromey <tom@tromey.com>
3558
3559 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
3560 (lookup_partial_symbol): Update.
3561
3562 2017-08-22 Tom Tromey <tom@tromey.com>
3563
3564 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
3565 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
3566 (find_and_open_source, symtab_to_fullname): Update.
3567 * psymtab.c (psymtab_to_fullname): Update.
3568
3569 2017-08-22 Tom Tromey <tom@tromey.com>
3570
3571 * exec.c (exec_file_attach): Update.
3572 * linux-thread-db.c (try_thread_db_load): Update.
3573 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
3574 * utils.c (gdb_realpath): Change return type.
3575 (gdb_realpath_keepfile): Update.
3576 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
3577 (_initialize_utils): Register the new self test.
3578 * source.c (openp): Update.
3579 (find_and_open_source): Update.
3580 * nto-tdep.c (nto_find_and_open_solib): Update.
3581 * main.c (set_gdb_data_directory): Update.
3582 (captured_main_1): Update.
3583 * dwarf2read.c (dwarf2_get_dwz_file): Update
3584 (dw2_map_symbol_filenames): Update.
3585 * auto-load.c (auto_load_safe_path_vec_update): Update.
3586 (filename_is_in_auto_load_safe_path_vec): Change type of
3587 "filename_realp".
3588 (auto_load_objfile_script): Update.
3589 (file_is_auto_load_safe): Update. Use std::string.
3590 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
3591
3592 2017-08-22 Tom Tromey <tom@tromey.com>
3593
3594 * utils.c (gdb_realpath_keepfile): Return a
3595 gdb::unique_xmalloc_ptr.
3596 * exec.c (exec_file_attach): Update.
3597 * utils.h (gdb_realpath_keepfile): Return a
3598 gdb::unique_xmalloc_ptr.
3599
3600 2017-08-22 Tom Tromey <tom@tromey.com>
3601
3602 * compile/compile.c (compile_file_command): Use
3603 gdb::unique_xmalloc_ptr, std::string.
3604 * utils.c (gdb_abspath): Change return type.
3605 * source.c (openp): Update.
3606 * objfiles.c (allocate_objfile): Update.
3607 * main.c (set_gdb_data_directory): Update.
3608 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
3609
3610 2017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
3611
3612 * cli-cmds.c (list_commands): List actual code around more than
3613 one location.
3614
3615 2017-08-21 John Baldwin <jhb@FreeBSD.org>
3616
3617 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
3618
3619 2017-08-21 Pedro Alves <palves@redhat.com>
3620
3621 PR gdb/19487
3622 * c-exp.y (variable production): Handle function aliases.
3623 * minsyms.c (msymbol_is_text): New function.
3624 * minsyms.h (msymbol_is_text): Declare.
3625 * symtab.c (find_function_alias_target): New function.
3626 * symtab.h (find_function_alias_target): Declare.
3627
3628 2017-08-21 Pedro Alves <palves@redhat.com>
3629
3630 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
3631 typedefs.
3632 * typeprint.c (whatis_exp): If handling "whatis", and expression
3633 is OP_TYPE, strip one typedef level. Otherwise don't strip
3634 typedefs here.
3635 * valops.c (value_cast): Save "to" type before resolving
3636 stubs/typedefs. Use that type as resulting value's type.
3637
3638 2017-08-18 Tom Tromey <tom@tromey.com>
3639 Pedro Alves <palves@redhat.com>
3640
3641 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
3642 * sol-thread.c (sol_thread_resume, sol_thread_wait)
3643 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
3644 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
3645 * proc-service.c (ps_xfer_memory): Use scoped_restore.
3646 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
3647 (linux_get_siginfo_data): Add "thread" argument. Use
3648 scoped_restore.
3649 * linux-nat.c (linux_child_follow_fork)
3650 (check_stopped_by_watchpoint): Use scoped_restore.
3651 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
3652 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
3653 (restore_inferior_ptid, save_inferior_ptid): Remove.
3654 * btrace.c (btrace_fetch): Use scoped_restore.
3655 * bsd-uthread.c (bsd_uthread_fetch_registers)
3656 (bsd_uthread_store_registers): Use scoped_restore.
3657 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
3658 scoped_restore.
3659 * aix-thread.c (aix_thread_resume, aix_thread_wait)
3660 (aix_thread_xfer_partial): Use scoped_restore.
3661 * inferior.h (save_inferior_ptid): Remove.
3662
3663 2017-08-18 Yao Qi <yao.qi@linaro.org>
3664
3665 PR tdep/21818
3666 * arm-tdep.c (gdb_print_insn_arm): Mark
3667 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
3668
3669 2017-08-18 Yao Qi <yao.qi@linaro.org>
3670
3671 * NEWS: Mention GDBserver's new option "--selftest".
3672 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
3673 * selftest.c: Move it to common/selftest.c.
3674 * selftest.h: Move it to common/selftest.h.
3675 * selftest-arch.c (reset): New function.
3676 (tests_with_arch): Call reset.
3677
3678 2017-08-18 Yao Qi <yao.qi@linaro.org>
3679
3680 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
3681 instead of exception_fprintf and printf_filtered.
3682
3683 2017-08-18 Yao Qi <yao.qi@linaro.org>
3684
3685 * selftest.c (register_self_test): Rename it to
3686 selftests::register_test.
3687 (run_self_tests): selftest::run_tests.
3688 * selftest.h: Update declarations.
3689 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
3690 selftests::register_test_foreach_arch.
3691 * selftest-arch.h: Update declaration.
3692 * aarch64-tdep.c: Update.
3693 * arm-tdep.c: Likewise.
3694 * disasm-selftests.c: Likewise.
3695 * dwarf2loc.c: Likewise.
3696 * dwarf2-frame.c: Likewise.
3697 * findvar.c: Likewise.
3698 * gdbarch-selftests.c: Likewise.
3699 * maint.c (maintenance_selftest): Likewise.
3700 * regcache.c: Likewise.
3701 * rust-exp.y: Likewise.
3702 * selftest-arch.c: Likewise.
3703 * unittests/environ-selftests.c: Likewise.
3704 * unittests/function-view-selftests.c: Likewise.
3705 * unittests/offset-type-selftests.c: Likewise.
3706 * unittests/optional-selftests.c: Likewise.
3707 * unittests/scoped_restore-selftests.c: Likewise.
3708 * utils-selftests.c: Likewise.
3709
3710 2017-08-17 Pedro Alves <palves@redhat.com>
3711
3712 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
3713 local.
3714
3715 2017-08-17 Pedro Alves <palves@redhat.com>
3716
3717 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
3718 field.
3719 (reset_die_in_process): Delete, replaced by ...
3720 (process_die_scope): ... this new class. Make it responsible for
3721 freeing cu->line_header too.
3722 (process_die): Use process_die_scope.
3723 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
3724 cu->line_header_die_owner. Don't release the line header if it's
3725 owned by the CU.
3726 (setup_type_unit_groups): Make the CU/DIE own the line header.
3727 Don't release the line header here.
3728
3729 2017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
3730
3731 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
3732
3733 2017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
3734
3735 * NEWS: Mention new shortcuts for nexti and stepi in TUI
3736 Single-Key mode
3737
3738 2017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
3739
3740 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
3741 mode command list.
3742
3743 2017-08-15 Stafford Horne <shorne@gmail.com>
3744
3745 * MAINTAINERS (Write After Approval): Add Stafford Horne.
3746
3747 2017-08-15 Stafford Horne <shorne@gmail.com>
3748
3749 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
3750
3751 2017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
3752
3753 PR gdb/21954
3754 * infcmd.c (unset_environment_command): Use the 'clear' method on
3755 the environment instead of resetting it.
3756
3757 2017-08-15 John Baldwin <jhb@FreeBSD.org>
3758
3759 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
3760 platforms.
3761
3762 2017-08-14 Tom Tromey <tom@tromey.com>
3763
3764 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
3765 (print_binary_chars): Likewise.
3766 (BITS_IN_BYTES): Remove.
3767
3768 2017-08-14 Tom Tromey <tom@tromey.com>
3769
3770 PR gdb/21675
3771 * valprint.c (LOW_ZERO): Change value to 034.
3772 (print_octal_chars): Add static_asserts for octal constants.
3773 * printcmd.c (print_scalar_formatted): Add 'd' case.
3774
3775 2017-08-11 Tom Tromey <tom@tromey.com>
3776
3777 * symfile.c (add_symbol_file_command): Use std::vector.
3778
3779 2017-08-14 Tom Tromey <tom@tromey.com>
3780
3781 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
3782 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
3783 std::move.
3784 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
3785
3786 2017-08-11 Pedro Alves <palves@redhat.com>
3787
3788 * infrun.c (process_event_stop_test): Adjust
3789 function_name_is_marked_for_skip call.
3790 * skip.c: Include <list>.
3791 (skiplist_entry): Make it a class with private fields, and
3792 getters/setters.
3793 (skiplist_entry_chain): Delete.
3794 (skiplist_entries): New.
3795 (skiplist_entry_count): Delete.
3796 (highest_skiplist_entry_num): New.
3797 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
3798 (add_skiplist_entry): Delete.
3799 (skiplist_entry::skiplist_entry): New.
3800 (skiplist_entry::add_entry): New.
3801 (skip_file_command, skip_function): Adjust.
3802 (compile_skip_regexp): Delete.
3803 (skip_command): Don't compile regexp here. Adjust to use
3804 skiplist_entry::add_entry.
3805 (skip_info): Adjust to use range-for and getters.
3806 (skip_enable_command, skip_disable_command): Adjust to use
3807 range-for and setters.
3808 (skip_delete_command): Adjust to use std::list.
3809 (add_skiplist_entry): Delete.
3810 (skip_file_p): Delete, refactored as ...
3811 (skiplist_entry::do_skip_file_p): ... this new method.
3812 (skip_gfile_p): Delete, refactored as ...
3813 (skiplist_entry::do_gskip_file_p): ... this new method.
3814 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
3815 (skiplist_entry::skip_function_p): ... this new method.
3816 (function_name_is_marked_for_skip): Now returns bool, and takes
3817 the function sal by const reference. Adjust to use range-for and
3818 skiplist_entry methods.
3819 (_initialize_step_skip): Remove references to
3820 skiplist_entry_chain, skiplist_entry_count.
3821 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
3822 takes the function sal by const reference.
3823
3824 2017-08-11 Yao Qi <yao.qi@linaro.org>
3825
3826 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
3827 (dwarf2_frame_cache): Remove reset_cache_cleanup.
3828 (dwarf2_frame_cache):
3829 * frame-unwind.c (frame_unwind_try_unwinder): Catch
3830 RETURN_MASK_ALL and set *this_case to NULL.
3831 * frame-unwind.h: Update comments.
3832
3833 2017-08-11 Yao Qi <yao.qi@linaro.org>
3834
3835 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
3836 (dwarf2_frame_state_copy_regs): Remove.
3837 (dwarf2_frame_state_free_regs): Remove.
3838 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
3839 (dwarf2_restore_rule): Call method .alloc_regs instead of
3840 dwarf2_frame_state_alloc_regs.
3841 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
3842 constructor. Call std::move.
3843 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
3844 (dwarf2_frame_cache): Likewise.
3845
3846 [GDB_SELF_TEST]: Include selftest.h and
3847 selftest-arch.h.
3848 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
3849 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
3850 execute_cfa_program_test.
3851
3852 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
3853 copy ctor, assignment operator, move assignment.
3854 <alloc_regs>: New method.
3855 <swap>: New method.
3856 (struct dwarf2_frame_state): Delete dtor.
3857 (dwarf2_frame_state_alloc_regs): Remove declaration.
3858 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
3859 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
3860
3861 2017-08-11 Yao Qi <yao.qi@linaro.org>
3862
3863 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
3864 (dwarf2_frame_state::dwarf2_frame_state): New.
3865 (dwarf2_frame_state::~dwarf2_frame_state): New.
3866 (dwarf2_fetch_cfa_info): Update.
3867 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
3868 rather than a pointer. Update code.
3869 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
3870 dtor.
3871 <data_align, code_align, retaddr_column>: Change them to const.
3872 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
3873 to bool.
3874
3875 2017-08-11 Yao Qi <yao.qi@linaro.org>
3876
3877 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
3878 <loc.exp>: New field.
3879 * dwarf2-frame.c (execute_cfa_program): Update.
3880 (dwarf2_frame_prev_register): Update.
3881
3882 2017-08-10 Pedro Alves <palves@redhat.com>
3883
3884 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
3885
3886 2017-08-09 John Baldwin <jhb@FreeBSD.org>
3887
3888 * fbsd-nat.c (struct fbsd_fork_info): Remove.
3889 (fbsd_pending_children): Use std::list.
3890 (fbsd_remember_child): Likewise.
3891 (fbsd_is_child_pending): Likewise.
3892 (fbsd_pending_vfork_done): Use std::forward_list.
3893 (fbsd_add_vfork_done): Likewise.
3894 (fbsd_is_vfork_done_pending): Likewise.
3895 (fbsd_next_vfork_done): Likewise.
3896
3897 2017-08-09 John Baldwin <jhb@FreeBSD.org>
3898
3899 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
3900 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
3901 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
3902 for `mapfilename'.
3903 (fbsd_xfer_partial): Use gdb::byte_vector.
3904 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
3905
3906 2017-08-09 John Baldwin <jhb@FreeBSD.org>
3907
3908 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
3909 "filestuff.h".
3910 (fbsd_find_memory_regions): Fix `mapfile' initialization.
3911
3912 2017-08-09 Tom Tromey <tom@tromey.com>
3913
3914 * skip.c (skiplist_entry): New constructor.
3915 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
3916 (skiplist_entry::file_is_glob): Now bool.
3917 (skiplist_entry::file, skiplist_entry::function): Now
3918 std::string.
3919 (make_skip_entry): Return a unique_ptr. Use new.
3920 (free_skiplist_entry, free_skiplist_entry_cleanup)
3921 (make_free_skiplist_entry_cleanup): Remove.
3922 (skip_command, skip_disable_command, add_skiplist_entry)
3923 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
3924 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
3925 (function_name_is_marked_for_skip): Update.
3926 (skip_delete_command): Update. Use delete.
3927
3928 2017-08-09 Jiong Wang <jiong.wang@arm.com>
3929
3930 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
3931 (aarch64_linux_core_read_description): New function.
3932 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
3933
3934 2017-08-09 Pedro Alves <palves@redhat.com>
3935
3936 * cp-name-parser.y (cp_comp_to_string): Return a
3937 gdb::unique_xmalloc_ptr<char>.
3938 * cp-support.c (replace_typedefs_qualified_name)
3939 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
3940 (cp_canonicalize_string_full): Use op= instead of explicit
3941 convertion.
3942 (cp_class_name_from_physname, method_name_from_physname)
3943 (cp_func_name, cp_remove_params): Adjust to use
3944 gdb::unique_xmalloc_ptr<char>.
3945 * cp-support.h (cp_comp_to_string): Return a
3946 gdb::unique_xmalloc_ptr<char>.
3947 * python/py-type.c (typy_lookup_type): Adjust to use
3948 gdb::unique_xmalloc_ptr<char>.
3949
3950 2017-08-09 H.J. Lu <hongjiu.lu@intel.com>
3951
3952 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
3953
3954 2017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
3955 Yao Qi <yao.qi@linaro.org>
3956
3957 * cp-support.c (cp_canonicalize_string_full): Use
3958 gdb::unique_xmalloc_ptr<char>.
3959 (cp_canonicalize_string): Likewise.
3960
3961 2017-08-09 Yao Qi <yao.qi@linaro.org>
3962
3963 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
3964 * regformats/i386/amd64-avx-avx512.dat: Remove.
3965 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
3966 * regformats/i386/amd64-avx-mpx.dat:Remove.
3967 * regformats/i386/amd64-avx.dat: Remove.
3968 * regformats/i386/amd64-mpx.dat: Remove.
3969 * regformats/i386/i386-avx-avx512.dat: Remove.
3970 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
3971 * regformats/i386/i386-avx-mpx.dat: Remove.
3972 * regformats/i386/i386-mmx.dat: Remove.
3973 * regformats/i386/i386-mpx.dat: Remove.
3974
3975 2017-08-09 Yao Qi <yao.qi@linaro.org>
3976
3977 * amd64-tdep.h (tdesc_x32): Remove the declaration.
3978 * amd64-tdep.c: Don't include features/i386/x32*.c.
3979 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
3980 functions.
3981 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
3982 and i386/x32-avx-avx512.
3983 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
3984 and i386/x32.xml.
3985 * features/i386/x32-avx-avx512.c: Removed.
3986 * features/i386/x32-avx-avx512.xml: Removed.
3987 * features/i386/x32-avx.c: Removed.
3988 * features/i386/x32-avx.xml: Removed.
3989 * features/i386/x32.c: Removed.
3990 * features/i386/x32.xml: Removed.
3991 * regformats/i386/x32-avx-avx512.dat: Removed.
3992 * regformats/i386/x32-avx.dat: Removed.
3993 * regformats/i386/x32.dat: Removed.
3994
3995 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
3996
3997 PR breakpoints/21886
3998 * mem-break.c (default_memory_insert_breakpoint): Use
3999 `->placed_address' rather than `->reqstd_address' for the
4000 breakpoint location.
4001
4002 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
4003
4004 * arch-utils.c (default_print_insn): Remove arch/mach/endian
4005 assertions.
4006
4007 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
4008
4009 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
4010 a union of `tdep_info', `tdesc_data' and `id'.
4011 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
4012 rather than `info.tdep_info'.
4013 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
4014 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
4015 * i386-tdep.c (i386_gdbarch_init): Likewise.
4016 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
4017 * mips-tdep.c (mips_gdbarch_init): Likewise.
4018 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
4019 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
4020 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
4021 `info.tdep_info'.
4022 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
4023 `info.tdep_info'.
4024 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
4025 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
4026 `info.tdep_info'.
4027 * spu-tdep.c (spu_gdbarch_init): Likewise.
4028 * gdbarch.h: Regenerate.
4029
4030 2017-08-07 Leszek Swirski <leszeks@google.com>
4031
4032 PR symtab/20899
4033 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
4034
4035 2017-08-07 Simon Marchi <simon.marchi@ericsson.com>
4036
4037 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
4038 (gdbsim_open): Rename gdb_argv args object to argv.
4039
4040 2017-08-05 Tom Tromey <tom@tromey.com>
4041
4042 * compile/compile-object-load.c (compile_object_load): Use
4043 gdb::unique_xmalloc_ptr.
4044 * cli/cli-dump.c (scan_filename): Rename from
4045 scan_filename_with_cleanup. Change return type.
4046 (scan_expression): Rename from scan_expression_with_cleanup.
4047 Change return type.
4048 (dump_memory_to_file, dump_value_to_file, restore_command):
4049 Use gdb::unique_xmalloc_ptr. Update.
4050 * cli/cli-cmds.c (find_and_open_script): Use
4051 gdb::unique_xmalloc_ptr.
4052 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
4053 * symmisc.c (maintenance_print_symbols)
4054 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
4055 * symfile.c (symfile_bfd_open, generic_load)
4056 (add_symbol_file_command, remove_symbol_file_command): Use
4057 gdb::unique_xmalloc_ptr.
4058 * source.c (openp): Use gdb::unique_xmalloc_ptr.
4059 * psymtab.c (maintenance_print_psymbols): Use
4060 gdb::unique_xmalloc_ptr.
4061 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
4062 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
4063 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
4064 (reload_shared_libraries_1): Likewise.
4065
4066 2017-08-05 Tom Tromey <tom@tromey.com>
4067
4068 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
4069 (rust_op_vector, rust_set_vector): New typedefs.
4070 (current_parser): New global.
4071 (work_obstack): Change to pointer type. Update all users.
4072 (rust_ast, pstate): Remove globals.
4073 (struct rust_parser): New.
4074 (%union) <params, field_inits>: Change type.
4075 (start, tuple_expr, unit_expr, struct_expr_list, literal)
4076 (field_expr, expr_list, maybe_expr_list, type_list): Update.
4077 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
4078 (convert_params_to_types, convert_params_to_expression): Change
4079 type of "params".
4080 (ast_string): Change type of "fields".
4081 (rust_parse): Make a rust_parser. Remove cleanups.
4082 (rust_lex_tests): Make and install an auto_obstack.
4083
4084 2017-08-04 Yao Qi <yao.qi@linaro.org>
4085
4086 * configure.srv (ipa_x32_linux_regobj): New.
4087 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
4088 instead of X86_TDESC_AVX512.
4089 (initialize_low_tracepoint): Call
4090 init_registers_x32_avx_avx512_linux.
4091
4092 2017-08-04 Yao Qi <yao.qi@linaro.org>
4093
4094 * utils.h (gdb_argv): Add namespace std for nullptr_t.
4095
4096 2017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
4097
4098 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
4099
4100 2017-08-03 Tom Tromey <tom@tromey.com>
4101
4102 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
4103 Remove.
4104 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
4105
4106 2017-08-03 Tom Tromey <tom@tromey.com>
4107
4108 * python/py-param.c (compute_enum_values): Use gdb_argv.
4109
4110 2017-08-03 Tom Tromey <tom@tromey.com>
4111
4112 * utils.h (struct gdb_argv_deleter): New.
4113 (gdb_argv): New class.
4114 * utils.c (gdb_argv::reset): New method.
4115 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
4116 * tracefile.c (tsave_command): Use gdb_argv.
4117 * top.c (new_ui_command): Use gdb_argv.
4118 * symmisc.c (maintenance_print_symbols)
4119 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
4120 * symfile.c (symbol_file_command, generic_load)
4121 (remove_symbol_file_command): Use gdb_argv.
4122 * stack.c (backtrace_command): Use gdb_argv.
4123 * source.c (add_path, show_substitute_path_command)
4124 (unset_substitute_path_command, set_substitute_path_command):
4125 Use gdb_argv.
4126 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
4127 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
4128 * remote.c (extended_remote_run, remote_put_command)
4129 (remote_get_command, remote_delete_command): Use gdb_argv.
4130 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
4131 (gdbsim_open): Use gdb_argv.
4132 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
4133 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
4134 * procfs.c (procfs_info_proc): Use gdb_argv.
4135 * interps.c (interpreter_exec_cmd): Use gdb_argv.
4136 * infrun.c (handle_command): Use gdb_argv.
4137 * inferior.c (add_inferior_command, clone_inferior_command):
4138 Use gdb_argv.
4139 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
4140 * exec.c (exec_file_command): Use gdb_argv.
4141 * cli/cli-cmds.c (alias_command): Use gdb_argv.
4142 * compile/compile.c (build_argc_argv): Use gdb_argv.
4143
4144 2017-08-03 Tom Tromey <tom@tromey.com>
4145
4146 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
4147
4148 2017-08-03 Tom Tromey <tom@tromey.com>
4149
4150 * python/python.c (compute_python_string): Return std::string.
4151 (gdbpy_eval_from_control_command): Update.
4152 (do_start_initialization): Use std::string.
4153 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
4154 xstrprintf.
4155 * python/py-breakpoint.c (local_setattro): Use string_printf, not
4156 xstrprintf.
4157
4158 2017-08-03 Tom Tromey <tom@tromey.com>
4159
4160 * top.h (do_restore_instream_cleanup): Remove.
4161 * top.c (do_restore_instream_cleanup): Remove.
4162 (read_command_file): Use scoped_restore.
4163 * cli/cli-script.c (execute_user_command): Use scoped_restore.
4164
4165 2017-08-03 Tom Tromey <tom@tromey.com>
4166
4167 * cli/cli-script.c (execute_user_command)
4168 (execute_control_command): Use scoped_restore.
4169
4170 2017-08-03 Tom Tromey <tom@tromey.com>
4171
4172 * cli/cli-script.c (do_restore_user_call_depth): Remove.
4173 (execute_user_command): Remove user_call_depth; use
4174 user_args_stack's size instead.
4175
4176 2017-08-03 Tom Tromey <tom@tromey.com>
4177
4178 * top.h (in_user_command): Remove.
4179 * top.c (in_user_command): Remove.
4180 * cli/cli-script.c (do_restore_user_call_depth)
4181 (execute_user_command): Update.
4182
4183 2017-08-03 Tom Tromey <tom@tromey.com>
4184
4185 * valops.c (search_struct_method): Use gdb::byte_vector.
4186 * valarith.c (value_concat): Use std::vector.
4187 * target.c (memory_xfer_partial): Use gdb::byte_vector.
4188 (simple_search_memory): Likewise.
4189 * printcmd.c (find_string_backward): Use gdb::byte_vector.
4190 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
4191 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
4192 * elfread.c (elf_rel_plt_read): Use std::string.
4193 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
4194 * cli/cli-dump.c (restore_section_callback): Use
4195 gdb::byte_vector.
4196
4197 2017-08-03 Tom Tromey <tom@tromey.com>
4198
4199 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
4200
4201 2017-08-03 Tom Tromey <tom@tromey.com>
4202
4203 * tui/tui-regs.c (tui_restore_gdbout): Remove.
4204 (tui_register_format): Use scoped_restore.
4205
4206 2017-08-03 Tom Tromey <tom@tromey.com>
4207
4208 * reverse.c (exec_direction_default): Remove.
4209 (exec_reverse_once): Use scoped_restore.
4210 * remote.c (restore_remote_timeout): Remove.
4211 (remote_flash_erase, remote_flash_write, remote_flash_done)
4212 (readchar, remote_serial_write): Use scoped_restore.
4213 * cli/cli-script.c (struct source_cleanup_lines_args)
4214 (source_cleanup_lines): Remove.
4215 (script_from_file): Use scoped_restore.
4216 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
4217 (source_command): Use scoped_restore.
4218
4219 2017-08-03 Tom Tromey <tom@tromey.com>
4220
4221 * utils.h (make_cleanup_free_so): Remove.
4222 * utils.c (do_free_so, make_cleanup_free_so): Remove.
4223 * solist.h (struct so_deleter): New.
4224 (so_list_up): New typedef.
4225 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
4226
4227 2017-08-03 Tom Tromey <tom@tromey.com>
4228
4229 * utils.h (make_cleanup_restore_current_language): Remove.
4230 * utils.c (do_restore_current_language)
4231 (make_cleanup_restore_current_language): Remove.
4232 * parse.c (parse_exp_in_context_1)
4233 (parse_expression_with_language): Use
4234 scoped_restore_current_language.
4235 * mi/mi-main.c (mi_cmd_execute): Use
4236 scoped_restore_current_language.
4237 * language.h (scoped_restore_current_language): New class.
4238
4239 2017-08-03 Tom Tromey <tom@tromey.com>
4240
4241 * compile/compile.c (cleanup_unlink_file): Remove.
4242 (compile_to_object): Use gdb::unlinker.
4243 (eval_compile_command): Likewise.
4244
4245 2017-08-03 Tom Tromey <tom@tromey.com>
4246
4247 * utils.h (make_cleanup_fclose): Remove.
4248 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
4249
4250 2017-08-03 Tom Tromey <tom@tromey.com>
4251
4252 * top.c (open_terminal_stream): Return gdb_file_up.
4253 (new_ui_command): Update.
4254
4255 2017-08-03 Tom Tromey <tom@tromey.com>
4256
4257 * source.c (print_source_lines_base, forward_search_command)
4258 (reverse_search_command): Use gdb_file_up.
4259
4260 2017-08-03 Tom Tromey <tom@tromey.com>
4261
4262 * fbsd-nat.c (fbsd_find_memory_regions): Update.
4263
4264 2017-08-03 Tom Tromey <tom@tromey.com>
4265
4266 * cli/cli-cmds.c (find_and_open_script): Change return type.
4267 Remove "streamp" and "full_path" parameters.
4268 (source_script_with_search): Update.
4269 * auto-load.c (source_script_file): Update.
4270 * cli/cli-cmds.h (find_and_open_script): Change type.
4271 (open_script): New struct.
4272
4273 2017-08-03 Tom Tromey <tom@tromey.com>
4274
4275 * xml-support.c (xml_fetch_content_from_file): Update.
4276 * ui-file.c (stdio_file::open): Update.
4277 * tracefile-tfile.c (tfile_start): Update.
4278 * remote.c (remote_file_put, remote_file_get): Update.
4279 * nat/linux-procfs.c (linux_proc_get_int)
4280 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
4281 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
4282 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
4283 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
4284 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
4285 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
4286 * linux-nat.c (linux_proc_pending_signals): Update.
4287 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
4288 (file_closer): Remove.
4289 * compile/compile.c (compile_to_object): Update.
4290 * common/filestuff.h (struct gdb_file_deleter): New.
4291 (gdb_file_up): New typedef.
4292 (gdb_fopen_cloexec): Change return type.
4293 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
4294 * cli/cli-dump.c (fopen_with_cleanup): Remove.
4295 (dump_binary_file, restore_binary_file): Update.
4296 * auto-load.c (auto_load_objfile_script_1): Update.
4297
4298 2017-08-03 Tom Tromey <tom@tromey.com>
4299
4300 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
4301 (info_static_tracepoint_markers_command): Likewise.
4302 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
4303 * skip.c (skip_info): Use ui_out_emit_table.
4304 * progspace.c (print_program_space): Use ui_out_emit_table.
4305 * osdata.c (info_osdata): Use ui_out_emit_table.
4306 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
4307 ui_out_emit_table.
4308 * linux-thread-db.c (info_auto_load_libthread_db): Use
4309 ui_out_emit_table.
4310 * inferior.c (print_inferior): Use ui_out_emit_table.
4311 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
4312 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
4313 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
4314 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
4315 * ui-out.h (class ui_out_emit_table): New.
4316
4317 2017-08-02 Maciej W. Rozycki <macro@imgtec.com>
4318
4319 * mips-tdep.c (mips_fpu_type_str): New function.
4320 (mips_dump_tdep): Call it.
4321
4322 2017-08-01 Maciej W. Rozycki <macro@imgtec.com>
4323
4324 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
4325 `->mips_fpu_type'.
4326
4327 2017-07-31 Xavier Roirand <roirand@adacore.com>
4328
4329 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
4330
4331 2017-07-27 Xavier Roirand <roirand@adacore.com>
4332
4333 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
4334
4335 2017-07-26 Yao Qi <yao.qi@linaro.org>
4336
4337 * cli/cli-cmds.c (maintenancechecklist): New variable.
4338 * gdbcmd.h (maintenancechecklist): Declare it.
4339 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
4340 Call i386_linux_read_description with different masks.
4341 * maint.c (maintenance_check_command): New function.
4342 (_initialize_maint_cmds): Call add_prefix_cmd.
4343 * target-descriptions.c (tdesc_reg): override operator != and ==.
4344 (tdesc_type): Likewise.
4345 (tdesc_feature): Likewise.
4346 (target_desc): Likewise.
4347 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
4348 (maintenance_check_xml_descriptions): New function.
4349 (_initialize_target_descriptions) Add command "xml-descriptions".
4350 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
4351
4352 2017-07-26 Yao Qi <yao.qi@linaro.org>
4353
4354 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
4355 Include features/i386/32bit-*.c.
4356 (i386_linux_read_description): Generate target description if it
4357 doesn't exist.
4358 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
4359 functions.
4360 * features/i386/32bit-linux.c: Re-generated.
4361 * features/i386/32bit-sse.c: Likewise.
4362 * target-descriptions.c (print_c_feature::visit): Print code to
4363 set register number if needed.
4364 (print_c_feature) <m_next_regnum>: New field.
4365
4366 2017-07-26 Yao Qi <yao.qi@linaro.org>
4367
4368 * features/Makefile (CFILES): Rename with TDESC_CFILES.
4369 (FEATURE_XMLFILES): New.
4370 (FEATURE_CFILES): New.
4371 New rules.
4372 (clean-cfiles): Remove generated c files.
4373 * features/i386/32bit-avx.c: Generated.
4374 * features/i386/32bit-avx512.c: Generated.
4375 * features/i386/32bit-core.c: Generated.
4376 * features/i386/32bit-linux.c: Generated.
4377 * features/i386/32bit-mpx.c: Generated.
4378 * features/i386/32bit-pkeys.c: Generated.
4379 * features/i386/32bit-sse.c: Generated.
4380 * target-descriptions.c: Include algorithm.
4381 (tdesc_element_visitor): Add method visit_end.
4382 (print_c_tdesc): Implement visit_end.
4383 (print_c_tdesc:: m_filename_after_features): Move it to
4384 protected.
4385 (print_c_feature): New class.
4386 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
4387 name starts with "i386/32bit-".
4388
4389 2017-07-26 Yao Qi <yao.qi@linaro.org>
4390
4391 * target-descriptions.c (tdesc_element_visitor): New class.
4392 (tdesc_element): New class.
4393 (tdesc_reg): Inherit from tdesc_element.
4394 (tdesc_reg::accept): New function.
4395 (tdesc_type): Inherit from tdesc_element.
4396 (tdesc_type::accept): New function.
4397 (tdesc_feature): Inherit from tdesc_element.
4398 (tdesc_feature::accept): New function.
4399 (target_desc): Inherit from tdesc_element.
4400 (target_desc::target_desc): New.
4401 (target_desc::~target_desc): New.
4402 (target_desc::accept): New.
4403 (allocate_target_description): Use new.
4404 (free_target_description): Use delete.
4405 (print_c_tdesc): New class.
4406 (maint_print_c_tdesc_cmd): Adjust.
4407
4408 * features/aarch64.c: Re-generated.
4409 * features/arc-arcompact.c: Re-generated.
4410 * features/arc-v2.c: Re-generated.
4411 * features/arm/arm-with-iwmmxt.c: Re-generated.
4412 * features/arm/arm-with-m.c: Re-generated.
4413 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
4414 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
4415 * features/arm/arm-with-neon.c: Re-generated.
4416 * features/arm/arm-with-vfpv2.c: Re-generated.
4417 * features/arm/arm-with-vfpv3.c: Re-generated.
4418 * features/i386/amd64-avx-avx512.c: Re-generated.
4419 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
4420 * features/i386/amd64-avx.c: Re-generated.
4421 * features/i386/amd64-avx-linux.c: Re-generated.
4422 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
4423 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
4424 * features/i386/amd64-avx-mpx.c: Re-generated.
4425 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
4426 * features/i386/amd64.c: Re-generated.
4427 * features/i386/amd64-linux.c: Re-generated.
4428 * features/i386/amd64-mpx.c: Re-generated.
4429 * features/i386/amd64-mpx-linux.c: Re-generated.
4430 * features/i386/i386-avx-avx512.c: Re-generated.
4431 * features/i386/i386-avx-avx512-linux.c: Re-generated.
4432 * features/i386/i386-avx.c: Re-generated.
4433 * features/i386/i386-avx-linux.c: Re-generated.
4434 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
4435 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
4436 * features/i386/i386-avx-mpx.c: Re-generated.
4437 * features/i386/i386-avx-mpx-linux.c: Re-generated.
4438 * features/i386/i386.c: Re-generated.
4439 * features/i386/i386-linux.c: Re-generated.
4440 * features/i386/i386-mmx.c: Re-generated.
4441 * features/i386/i386-mmx-linux.c: Re-generated.
4442 * features/i386/i386-mpx.c: Re-generated.
4443 * features/i386/i386-mpx-linux.c: Re-generated.
4444 * features/i386/x32-avx-avx512.c: Re-generated.
4445 * features/i386/x32-avx-avx512-linux.c: Re-generated.
4446 * features/i386/x32-avx.c: Re-generated.
4447 * features/i386/x32-avx-linux.c: Re-generated.
4448 * features/i386/x32.c: Re-generated.
4449 * features/i386/x32-linux.c: Re-generated.
4450 * features/microblaze.c: Re-generated.
4451 * features/microblaze-with-stack-protect.c: Re-generated.
4452 * features/mips64-dsp-linux.c: Re-generated.
4453 * features/mips64-linux.c: Re-generated.
4454 * features/mips-dsp-linux.c: Re-generated.
4455 * features/mips-linux.c: Re-generated.
4456 * features/nds32.c: Re-generated.
4457 * features/nios2.c: Re-generated.
4458 * features/nios2-linux.c: Re-generated.
4459 * features/rs6000/powerpc-32.c: Re-generated.
4460 * features/rs6000/powerpc-32l.c: Re-generated.
4461 * features/rs6000/powerpc-403.c: Re-generated.
4462 * features/rs6000/powerpc-403gc.c : Re-generated.
4463 * features/rs6000/powerpc-405.c: Re-generated.
4464 * features/rs6000/powerpc-505.c: Re-generated.
4465 * features/rs6000/powerpc-601.c: Re-generated.
4466 * features/rs6000/powerpc-602.c: Re-generated.
4467 * features/rs6000/powerpc-603.c: Re-generated.
4468 * features/rs6000/powerpc-604.c: Re-generated.
4469 * features/rs6000/powerpc-64.c: Re-generated.
4470 * features/rs6000/powerpc-64l.c: Re-generated.
4471 * features/rs6000/powerpc-7400.c: Re-generated.
4472 * features/rs6000/powerpc-750.c: Re-generated.
4473 * features/rs6000/powerpc-860.c: Re-generated.
4474 * features/rs6000/powerpc-altivec32.c: Re-generated.
4475 * features/rs6000/powerpc-altivec32l.c: Re-generated.
4476 * features/rs6000/powerpc-altivec64.c: Re-generated.
4477 * features/rs6000/powerpc-altivec64l.c: Re-generated.
4478 * features/rs6000/powerpc-cell32l.c: Re-generated.
4479 * features/rs6000/powerpc-cell64l.c: Re-generated.
4480 * features/rs6000/powerpc-e500.c: Re-generated.
4481 * features/rs6000/powerpc-e500l.c: Re-generated.
4482 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
4483 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
4484 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
4485 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
4486 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
4487 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
4488 * features/rs6000/powerpc-vsx32.c: Re-generated.
4489 * features/rs6000/powerpc-vsx32l.c: Re-generated.
4490 * features/rs6000/powerpc-vsx64.c: Re-generated.
4491 * features/rs6000/powerpc-vsx64l.c: Re-generated.
4492 * features/rs6000/rs6000.c: Re-generated.
4493 * features/s390-linux32.c: Re-generated.
4494 * features/s390-linux32v1.c: Re-generated.
4495 * features/s390-linux32v2.c: Re-generated.
4496 * features/s390-linux64.c: Re-generated.
4497 * features/s390-linux64v1.c: Re-generated.
4498 * features/s390-linux64v2.c: Re-generated.
4499 * features/s390-te-linux64.c: Re-generated.
4500 * features/s390-tevx-linux64.c: Re-generated.
4501 * features/s390-vx-linux64.c: Re-generated.
4502 * features/s390x-linux64.c: Re-generated.
4503 * features/s390x-linux64v1.c: Re-generated.
4504 * features/s390x-linux64v2.c: Re-generated.
4505 * features/s390x-te-linux64.c: Re-generated.
4506 * features/s390x-tevx-linux64.c: Re-generated.
4507 * features/s390x-vx-linux64.c: Re-generated.
4508 * features/sparc/sparc32-solaris.c: Re-generated.
4509 * features/sparc/sparc64-solaris.c: Re-generated.
4510 * features/tic6x-c62x.c: Re-generated.
4511 * features/tic6x-c62x-linux.c: Re-generated.
4512 * features/tic6x-c64x.c: Re-generated.
4513 * features/tic6x-c64x-linux.c: Re-generated.
4514 * features/tic6x-c64xp.c: Re-generated.
4515 * features/tic6x-c64xp-linux.c: Re-generated.
4516
4517 2017-07-26 Yao Qi <yao.qi@linaro.org>
4518
4519 * i386-linux-tdep.c (i386_linux_read_description): New function.
4520 (i386_linux_core_read_description): Call
4521 i386_linux_read_description.
4522 * i386-linux-tdep.h (i386_linux_read_description): Declare.
4523 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
4524 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
4525 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
4526 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
4527 * x86-linux-nat.c (x86_linux_read_description): Call
4528 i386_linux_read_description.
4529
4530 2017-07-26 Yao Qi <yao.qi@linaro.org>
4531
4532 * NEWS: Mention it.
4533 * features/Makefile (%.c: %.xml): Pass the xml file name to
4534 command "maint print c-tdesc".
4535 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
4536 name from 'arg'.
4537
4538 2017-07-26 Yao Qi <yao.qi@linaro.org>
4539
4540 * target-descriptions.c (target_desc): Add ctor and dtor. Do
4541 in-class initialization.
4542 (tdesc_create_feature): Call new instead of XCNEW.
4543 (free_target_description): Ue delete.
4544
4545 2017-07-25 John Baldwin <jhb@FreeBSD.org>
4546
4547 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
4548
4549 2017-07-25 Yao Qi <yao.qi@linaro.org>
4550
4551 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
4552 constant.
4553 (amd64_x32_init_abi): Likewise.
4554 * amd64-tdep.h (amd64_init_abi): Update declaration.
4555 (amd64_x32_init_abi): Likewise.
4556
4557 2017-07-25 Yao Qi <yao.qi@linaro.org>
4558
4559 PR tdep/21717
4560 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
4561 condition for FPSCR.
4562 (arm_linux_store_inferior_registers): Likewise.
4563
4564 2017-07-22 Tom Tromey <tom@tromey.com>
4565
4566 * break-catch-syscall.c (struct catch_syscall_inferior_data)
4567 <syscalls_counts>: Now a std::vector.
4568 (get_catch_syscall_inferior_data): Use "new".
4569 (catch_syscall_inferior_data_cleanup): Use "delete".
4570 (insert_catch_syscall, remove_catch_syscall)
4571 (clear_syscall_counts): Update.
4572
4573 2017-07-22 Tom Tromey <tom@tromey.com>
4574
4575 * break-catch-syscall.c (syscall_catchpoint)
4576 <syscalls_to_be_caught>: Now a std::vector<int>
4577 (~syscall_catchpoint): Remove.
4578 (insert_catch_syscall, remove_catch_syscall)
4579 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
4580 (print_mention_catch_syscall, print_recreate_catch_syscall):
4581 Update.
4582 (create_syscall_event_catchpoint): Change type of "filter"
4583 parameter.
4584 (catch_syscall_split_args): Return a std::vector.
4585 (catch_syscall_command_1, catching_syscall_number_1): Update.
4586
4587 2017-07-22 Tom Tromey <tom@tromey.com>
4588
4589 * break-catch-throw.c (struct exception_catchpoint)
4590 <exception_rx>: Now a std::string.
4591 (~exception_catchpoint): Remove.
4592 (print_one_detail_exception_catchpoint): Update.
4593 (handle_gnu_v3_exceptions): Change type of except_rx.
4594 (extract_exception_regexp): Return a std::string.
4595 (catch_exception_command_1): Update.
4596
4597 2017-07-22 Tom Tromey <tom@tromey.com>
4598
4599 * break-catch-sig.c (gdb_signal_type): Remove typedef.
4600 (struct signal_catchpoint) <signals_to_be_caught>: Now a
4601 std::vector.
4602 <catch_all>: Now a bool.
4603 (~signal_catchpoint): Remove.
4604 (signal_catchpoint_insert_location)
4605 (signal_catchpoint_remove_location)
4606 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
4607 (signal_catchpoint_print_mention)
4608 (signal_catchpoint_print_recreate)
4609 (signal_catchpoint_explains_signal): Update.
4610 (create_signal_catchpoint): Change type of "filter" and
4611 "catch_all".
4612 (catch_signal_split_args): Return a std::vector. Change type of
4613 "catch_all".
4614 (catch_signal_command): Update.
4615
4616 2017-07-20 Pedro Alves <palves@redhat.com>
4617
4618 * ada-lang.c (ada_language_defn): Make extern.
4619 (_initialize_ada_language): Remove add_language call.
4620 * c-lang.c (c_language_defn, cplus_language_defn)
4621 (asm_language_defn, minimal_language_defn): Make extern.
4622 (_initialize_c_language): Delete.
4623 * completer.c (compare_cstrings): Delete, moved to utils.h.
4624 * d-lang.c (d_language_defn): Make extern.
4625 (_initialize_d_language): Remove add_language calls.
4626 * defs.h (enum language): Add comment.
4627 * f-lang.c (f_language_defn): Make extern.
4628 (_initialize_f_language): Remove add_language call.
4629 * go-lang.c (go_language_defn): Make extern.
4630 (_initialize_go_language): Remove add_language call.
4631 * language.c: Include <algorithm>.
4632 (languages): Redefine as const array.
4633 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
4634 (set_language_command): Handle "local". Use for-range loop.
4635 (set_language): Remove loop.
4636 (language_enum): Rewrite.
4637 (language_def, language_str): Remove loops.
4638 (add_language): Delete.
4639 (add_set_language_command): New, based on add_languages.
4640 (skip_language_trampoline): Adjust.
4641 (local_language_defn): Delete.
4642 (language_gdbarch_post_init): Adjust.
4643 (_initialize_language): Remove add_language calls. Call
4644 add_set_language_command.
4645 * language.h (add_language): Delete.
4646 (auto_language_defn)
4647 (unknown_language_defn, minimal_language_defn, ada_language_defn)
4648 (asm_language_defn, c_language_defn, cplus_language_defn)
4649 (d_language_defn, f_language_defn, go_language_defn)
4650 (m2_language_defn, objc_language_defn, opencl_language_defn)
4651 (pascal_language_defn, rust_language_defn): Declare.
4652 * m2-lang.c (m2_language_defn): Make extern.
4653 (_initialize_m2_language): Remove add_language call.
4654 * objc-lang.c (objc_language_defn): Make extern.
4655 (_initialize_objc_language): Remove add_language call.
4656 * opencl-lang.c (opencl_language_defn): Make extern.
4657 (_initialize_opencl_language): Remove add_language call.
4658 * p-lang.c (pascal_language_defn): Make extern.
4659 (_initialize_pascal_language): Delete.
4660 * rust-lang.c (rust_language_defn): Make extern.
4661 (_initialize_rust_language): Delete.
4662 * utils.h (compare_cstrings): New static inline function.
4663
4664 2017-07-20 Pedro Alves <palves@redhat.com>
4665
4666 * ada-lang.c (ada_to_fixed_type_1): Adjust.
4667 (get_var_value): Constify parameters.
4668 (get_int_var_value): Change prototype.
4669 (to_fixed_range_type): Adjust.
4670 * ada-lang.h (get_int_var_value): Change prototype.
4671
4672 2017-07-20 Pedro Alves <palves@redhat.com>
4673
4674 * dwarf2read.c (dw2_lookup_symbol): Use
4675 SYMBOL_MATCHES_SEARCH_NAME.
4676 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
4677
4678 2017-07-20 Pedro Alves <palves@redhat.com>
4679
4680 * block.c (block_iter_name_step, block_iter_name_first)
4681 (block_iter_name_next): Delete.
4682 (block_lookup_symbol_primary): Adjust to use
4683 dict_iter_match_first/dict_iter_match_next.
4684 * block.h (block_iter_name_first, block_iter_name_next): Delete
4685 declarations.
4686 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
4687 dict_iter_match_first/dict_iter_match_next.
4688
4689 2017-07-20 Pedro Alves <palves@redhat.com>
4690
4691 * cp-support.c (cp_find_first_component_aux): Add missing case for
4692 end of string.
4693
4694 2017-07-18 David Blaikie <dblaikie@gmail.com>
4695
4696 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
4697 of dwo_cu's dwo_file.
4698
4699 2017-07-18 Yao Qi <yao.qi@linaro.org>
4700
4701 * remote.c (store_registers_using_G): Remove one line comment.
4702
4703 2017-07-18 Yao Qi <yao.qi@linaro.org>
4704
4705 * regcache.c (regcache_cpy): Simplify it.
4706 (regcache::cpy_no_passthrough): Remove it.
4707 * regcache.h (cpy_no_passthrough): Remove it.
4708 (regcache_dup, regcache_cpy): Update comments.
4709
4710 2017-07-18 Pedro Alves <palves@redhat.com>
4711
4712 * remote-sim.c (sim_command_completer): Adjust to work with a
4713 completion_tracker instead of a VEC.
4714
4715 2017-07-17 Pedro Alves <palves@redhat.com>
4716
4717 * completer.c (complete_source_filenames): New function.
4718 (complete_address_and_linespec_locations): New function.
4719 (location_completer): Use complete_address_and_linespec_locations.
4720 (completion_tracker::build_completion_result): Honor the tracker's
4721 request to suppress append.
4722 * completer.h (completion_tracker::suppress_append_ws)
4723 (completion_tracker::set_suppress_append_ws): New methods.
4724 (completion_tracker::m_suppress_append_ws): New field.
4725 (complete_source_filenames): New declaration.
4726 * linespec.c (linespec_complete_what): New.
4727 (struct ls_parser) <complete_what, completion_word,
4728 completion_quote_char, completion_quote_end, completion_tracker>:
4729 New fields.
4730 (string_find_incomplete_keyword_at_end): New.
4731 (linespec_lexer_lex_string): Record quote char. If in completion
4732 mode, don't throw.
4733 (linespec_lexer_consume_token): Advance the completion word point.
4734 (linespec_lexer_peek_token): Save/restore completion info.
4735 (save_stream_and_consume_token): New.
4736 (set_completion_after_number): New.
4737 (linespec_parse_basic): Set what to complete next depending on
4738 token. Handle function and label completions specially.
4739 (parse_linespec): Disable objc shortcut in completion mode. Set
4740 what to complete next depending on token type. Skip keyword if in
4741 completion mode.
4742 (complete_linespec_component, linespec_complete): New.
4743 * linespec.h (linespec_complete): Declare.
4744
4745 2017-07-17 Pedro Alves <palves@redhat.com>
4746
4747 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
4748 Handle 'operator<' / 'operator<<'.
4749
4750 2017-07-17 Pedro Alves <palves@redhat.com>
4751
4752 * completer.c (collect_explicit_location_matches): Handle
4753 MATCH_LABEL.
4754 (convert_explicit_location_to_linespec): New, factored out from
4755 ...
4756 (convert_explicit_location_to_sals): ... this.
4757 (complete_label): New.
4758 (linespec_complete_label, find_label_symbols_in_block): New.
4759 (find_label_symbols): Add completion_mode parameter and adjust to
4760 call find_label_symbols_in_block.
4761 * linespec.h (linespec_complete_label): Declare.
4762
4763 2017-07-17 Pedro Alves <palves@redhat.com>
4764
4765 * ada-lang.c (ada_collect_symbol_completion_matches): Add
4766 complete_symbol_mode parameter.
4767 * cli/cli-cmds.c (complete_command): Get the completion result out
4768 of the handle_brkchars tracker if used a custom word point.
4769 * completer.c: Include "linespec.h".
4770 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
4771 (advance_to_expression_complete_word_point): New.
4772 (completion_tracker::completes_to_completion_word): New.
4773 (complete_files_symbols): Pass down
4774 complete_symbol_mode::EXPRESSION.
4775 (explicit_options, probe_options): New.
4776 (collect_explicit_location_matches): Complete on the
4777 explictit_loc->foo instead of word. Use
4778 linespec_complete_function. Handle MATCH_LINE. Handle offering
4779 keyword and options completions.
4780 (backup_text_ptr): Delete.
4781 (skip_keyword): New.
4782 (complete_explicit_location): Remove 'word' parameter. Add
4783 language, quoted_arg_start and quoted_arg_end parameters.
4784 Rewrite, parsing left to right.
4785 (location_completer): Rewrite.
4786 (location_completer_handle_brkchars): New function.
4787 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
4788 (enum complete_line_internal_reason): Adjust comments.
4789 (completion_tracker::discard_completions): New.
4790 (completer_handle_brkchars_func_for_completer): Handle
4791 location_completer.
4792 (gdb_custom_word_point_brkchars)
4793 (gdb_org_rl_basic_quote_characters): New.
4794 (gdb_completion_word_break_characters_throw)
4795 (completion_find_completion_word): Handle trackers that use a
4796 custom word point.
4797 (completion_tracker::advance_custom_word_point_by): New.
4798 (completion_tracker::build_completion_result): Don't rely on
4799 readline appending the quote char.
4800 (gdb_rl_attempted_completion_function_throw): Handle trackers that
4801 use a custom word point.
4802 (gdb_rl_attempted_completion_function): Restore
4803 rl_basic_quote_characters.
4804 * completer.h (class completion_tracker): Extend intro comment.
4805 (completion_tracker::set_quote_char)
4806 (completion_tracker::quote_char)
4807 (completion_tracker::set_use_custom_word_point)
4808 (completion_tracker::use_custom_word_point)
4809 (completion_tracker::custom_word_point)
4810 (completion_tracker::set_custom_word_point)
4811 (completion_tracker::advance_custom_word_point_by)
4812 (completion_tracker::completes_to_completion_word)
4813 (completion_tracker::discard_completions): New methods.
4814 (completion_tracker::m_quote_char)
4815 (completion_tracker::m_use_custom_word_point)
4816 (completion_tracker::m_custom_word_point): New fields.
4817 (advance_to_expression_complete_word_point): Declare.
4818 * f-lang.c (f_collect_symbol_completion_matches): Add
4819 complete_symbol_mode parameter.
4820 * language.h (struct language_defn)
4821 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
4822 parameter.
4823 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
4824 (linespec_complete_function): New function.
4825 (linespec_lexer_lex_keyword): Adjust.
4826 * linespec.h (linespec_keywords, linespec_complete_function): New
4827 declarations.
4828 * location.c (find_end_quote): New function.
4829 (explicit_location_lex_one): Add explicit_completion_info
4830 parameter. Save quoting info. Don't throw if being called for
4831 completion. Don't handle Ada operators here.
4832 (is_cp_operator, skip_op_false_positives, first_of)
4833 (explicit_location_lex_one_function): New function.
4834 (string_to_explicit_location): Replace 'dont_throw' parameter with
4835 an explicit_completion_info pointer parameter. Handle it. Don't
4836 use explicit_location_lex_one to lex function names. Use
4837 explicit_location_lex_one_function instead.
4838 * location.h (struct explicit_completion_info): New.
4839 (string_to_explicit_location): Replace 'dont_throw' parameter with
4840 an explicit_completion_info pointer parameter.
4841 * symtab.c (default_collect_symbol_completion_matches_break_on):
4842 Add complete_symbol_mode parameter. Handle LINESPEC mode.
4843 (default_collect_symbol_completion_matches)
4844 (collect_symbol_completion_matches): Add complete_symbol_mode
4845 parameter.
4846 (collect_symbol_completion_matches_type): Pass down
4847 complete_symbol_mode::EXPRESSION.
4848 (collect_file_symbol_completion_matches): Add complete_symbol_mode
4849 parameter. Handle LINESPEC mode.
4850 * symtab.h (complete_symbol_mode): New.
4851 (default_collect_symbol_completion_matches_break_on)
4852 (default_collect_symbol_completion_matches)
4853 (collect_symbol_completion_matches)
4854 (collect_file_symbol_completion_matches): Add complete_symbol_mode
4855 parameter.
4856
4857 2017-07-17 Pedro Alves <palves@redhat.com>
4858
4859 * utils.c (enum class strncmp_iw_mode): New.
4860 (strcmp_iw): Rename to ...
4861 (strncmp_iw_with_mode): ... this. Add string2_len and mode
4862 parameters. Handle them.
4863 (strncmp_iw): New.
4864 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
4865 * utils.h (strncmp_iw): Declare.
4866 (strcmp_iw): Move describing comments here.
4867
4868 2017-07-17 Pedro Alves <palves@redhat.com>
4869
4870 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
4871 CP_OPERATOR_STR.
4872 * c-typeprint.c (is_type_conversion_operator): Use
4873 CP_OPERATOR_STR.
4874 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
4875 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
4876 CP_OPERATOR_LEN.
4877 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
4878 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
4879 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
4880 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
4881 CP_OPERATOR_STR.
4882 * location.c: Include "cp-support.h".
4883 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
4884 CP_OPERATOR_STR.
4885 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
4886 CP_OPERATOR_LEN.
4887
4888 2017-07-17 Pedro Alves <palves@redhat.com>
4889
4890 * cli/cli-cmds.c (complete_command): Use a completion tracker
4891 along with completion_find_completion_word for handle_brkchars
4892 phase.
4893 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
4894 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
4895 (struct gdb_rl_completion_word_info): New.
4896 (gdb_rl_find_completion_word): New.
4897 (completion_find_completion_word): New.
4898 * completer.h (completion_find_completion_word): Declare.
4899
4900 2017-07-17 Pedro Alves <palves@redhat.com>
4901
4902 * ada-lang.c (symbol_completion_match): Adjust comments.
4903 (symbol_completion_add): Replace vector parameter with
4904 completion_tracker parameter. Use it.
4905 (ada_make_symbol_completion_list): Rename to...
4906 (ada_collect_symbol_completion_matches): ... this. Add
4907 completion_tracker parameter and use it.
4908 (ada_language_defn): Adjust.
4909 * break-catch-syscall.c (catch_syscall_completer): Adjust
4910 prototype and work with completion_tracker instead of VEC.
4911 * breakpoint.c (condition_completer): Adjust prototype and work
4912 with completion_tracker instead of VEC.
4913 * c-lang.c (c_language_defn, cplus_language_defn)
4914 (asm_language_defn, minimal_language_defn): Adjust to renames.
4915 * cli/cli-cmds.c (complete_command): Rework using
4916 completion_tracker. Catch exceptions when completing.
4917 * cli/cli-decode.c (integer_unlimited_completer)
4918 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
4919 with completion_tracker instead of VEC.
4920 * command.h (struct completion_tracker): Forward declare.
4921 (completer_ftype, completer_handle_brkchars_ftype): Change
4922 types.
4923 (complete_on_cmdlist, complete_on_enum): Adjust.
4924 * completer.c: Include <algorithm>.
4925 (struct gdb_completer_state): New.
4926 (current_completion): New global.
4927 (readline_line_completion_function): Delete.
4928 (noop_completer, filename_completer)
4929 (filename_completer_handle_brkchars, complete_files_symbols)
4930 (linespec_location_completer): Adjust to work with a
4931 completion_tracker instead of a VEC.
4932 (string_or_empty): New.
4933 (collect_explicit_location_matches): Adjust to work with a
4934 completion_tracker instead of a VEC.
4935 (explicit_location_completer): Rename to ...
4936 (complete_explicit_location): ... this and adjust to work with a
4937 completion_tracker instead of a VEC.
4938 (location_completer): Adjust to work with a completion_tracker
4939 instead of a VEC.
4940 (add_struct_fields): Adjust to work with a completion_list instead
4941 of VEC.
4942 (expression_completer): Rename to ...
4943 (complete_expression): ... this and adjust to work with a
4944 completion_tracker instead of a VEC. Use complete_files_symbols.
4945 (expression_completer): Reimplement on top of complete_expression.
4946 (symbol_completer): Adjust to work with a completion_tracker
4947 instead of a VEC.
4948 (enum complete_line_internal_reason): Add describing comments.
4949 (complete_line_internal_normal_command): Adjust to work with a
4950 completion_tracker instead of a VEC.
4951 (complete_line_internal): Rename to ...
4952 (complete_line_internal_1): ... this and adjust to work with a
4953 completion_tracker instead of a VEC. Assert TEXT is NULL in the
4954 handle_brkchars phase.
4955 (new_completion_tracker): Delete.
4956 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
4957 complete_line_internal_1.
4958 (free_completion_tracker): Delete.
4959 (INITIAL_COMPLETION_HTAB_SIZE): New.
4960 (completion_tracker::completion_tracker)
4961 (completion_tracker::~completion_tracker): New.
4962 (maybe_add_completion): Delete.
4963 (completion_tracker::maybe_add_completion)
4964 (completion_tracker::add_completion)
4965 (completion_tracker::add_completions): New.
4966 (throw_max_completions_reached_error): Delete.
4967 (complete_line): Adjust to work with a completion_tracker instead
4968 of a VEC. Don't create a completion_tracker_t or check for max
4969 completions here.
4970 (command_completer, command_completer_handle_brkchars)
4971 (signal_completer, reg_or_group_completer_1)
4972 (reg_or_group_completer, default_completer_handle_brkchars):
4973 Adjust to work with a completion_tracker.
4974 (gdb_completion_word_break_characters_throw): New.
4975 (gdb_completion_word_break_characters): Reimplement.
4976 (line_completion_function): Delete.
4977 (completion_tracker::recompute_lowest_common_denominator)
4978 (expand_preserving_ws)
4979 (completion_tracker::build_completion_result)
4980 (completion_result::completion_result)
4981 (completion_result::completion_result)
4982 (completion_result::~completion_result)
4983 (completion_result::completion_result)
4984 (completion_result::release_match_list, compare_cstrings)
4985 (completion_result::sort_match_list)
4986 (completion_result::reset_match_list)
4987 (gdb_rl_attempted_completion_function_throw)
4988 (gdb_rl_attempted_completion_function): New.
4989 * completer.h (completion_list, struct completion_result)
4990 (class completion_tracker): New.
4991 (complete_line): Add completion_tracker parameter.
4992 (readline_line_completion_function): Delete.
4993 (gdb_rl_attempted_completion_function): New.
4994 (noop_completer, filename_completer, expression_completer)
4995 (location_completer, symbol_completer, command_completer)
4996 (signal_completer, reg_or_group_completer): Update prototypes.
4997 (completion_tracker_t, new_completion_tracker)
4998 (make_cleanup_free_completion_tracker): Delete.
4999 (enum maybe_add_completion_enum): Delete.
5000 (maybe_add_completion): Delete.
5001 (throw_max_completions_reached_error): Delete.
5002 * corefile.c (complete_set_gnutarget): Adjust to work with a
5003 completion_tracker instead of a VEC.
5004 * cp-abi.c (cp_abi_completer): Adjust to work with a
5005 completion_tracker instead of a VEC.
5006 * d-lang.c (d_language_defn): Adjust.
5007 * disasm.c (disassembler_options_completer): Adjust to work with a
5008 completion_tracker instead of a VEC.
5009 * f-lang.c (f_make_symbol_completion_list): Rename to ...
5010 (f_collect_symbol_completion_matches): ... this. Adjust to work
5011 with a completion_tracker instead of a VEC.
5012 (f_language_defn): Adjust.
5013 * go-lang.c (go_language_defn): Adjust.
5014 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
5015 Adjust to work with a completion_tracker instead of a VEC.
5016 * infrun.c (handle_completer): Likewise.
5017 * interps.c (interpreter_completer): Likewise.
5018 * interps.h (interpreter_completer): Likewise.
5019 * language.c (unknown_language_defn, auto_language_defn)
5020 (local_language_defn): Adjust.
5021 * language.h (language_defn::la_make_symbol_completion_list):
5022 Rename to ...
5023 (language_defn::la_collect_symbol_completion_matches): ... this
5024 and adjust to work with a completion_tracker instead of a VEC.
5025 * m2-lang.c (m2_language_defn): Adjust.
5026 * objc-lang.c (objc_language_defn): Adjust.
5027 * opencl-lang.c (opencl_language_defn): Adjust.
5028 * p-lang.c (pascal_language_defn): Adjust.
5029 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
5030 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
5031 with a completion_tracker.
5032 * rust-lang.c (rust_language_defn): Adjust.
5033 * symtab.c (free_completion_list, do_free_completion_list)
5034 (return_val, completion_tracker): Delete.
5035 (completion_list_add_name, completion_list_add_symbol)
5036 (completion_list_add_msymbol, completion_list_objc_symbol)
5037 (completion_list_add_fields, add_symtab_completions): Add
5038 completion_tracker parameter and use it.
5039 (default_make_symbol_completion_list_break_on_1): Rename to...
5040 (default_collect_symbol_completion_matches_break_on): ... this.
5041 Add completion_tracker parameter and use it instead of allocating
5042 a completion tracker here.
5043 (default_make_symbol_completion_list_break_on): Delete old
5044 implementation.
5045 (default_make_symbol_completion_list): Delete.
5046 (default_collect_symbol_completion_matches): New.
5047 (make_symbol_completion_list): Delete.
5048 (collect_symbol_completion_matches): New.
5049 (make_symbol_completion_type): Rename to ...
5050 (collect_symbol_completion_matches_type): ... this. Add
5051 completion_tracker parameter and use it instead of VEC.
5052 (make_file_symbol_completion_list_1): Rename to...
5053 (collect_file_symbol_completion_matches): ... this. Add
5054 completion_tracker parameter and use it instead of VEC.
5055 (make_file_symbol_completion_list): Delete.
5056 (add_filename_to_list): Use completion_list instead of a VEC.
5057 (add_partial_filename_data::list): Now a completion_list.
5058 (make_source_files_completion_list): Work with a completion_list
5059 instead of a VEC.
5060 * symtab.h: Include "completer.h".
5061 (default_make_symbol_completion_list_break_on)
5062 (default_make_symbol_completion_list, make_symbol_completion_list)
5063 (make_symbol_completion_type, make_file_symbol_completion_list)
5064 (make_source_files_completion_list): Delete.
5065 (default_collect_symbol_completion_matches_break_on)
5066 (default_collect_symbol_completion_matches)
5067 (collect_symbol_completion_matches)
5068 (collect_symbol_completion_matches_type)
5069 (collect_file_symbol_completion_matches)
5070 (make_source_files_completion_list): New.
5071 * top.c (init_main): Don't install a rl_completion_entry_function
5072 hook. Install a rl_attempted_completion_function hook instead.
5073 * tui/tui-layout.c (layout_completer): Adjust to work with a
5074 completion_tracker.
5075 * tui/tui-regs.c (tui_reggroup_completer):
5076 * tui/tui-win.c (window_name_completer, focus_completer)
5077 (winheight_completer): Adjust to work with a completion_tracker.
5078 * value.c: Include "completer.h".
5079 (complete_internalvar): Adjust to work with a completion_tracker.
5080 * value.h (complete_internalvar): Likewise.
5081
5082 2017-07-17 Pedro Alves <palves@redhat.com>
5083
5084 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
5085 renames.
5086 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
5087 comments to completer_ftype's declaration.
5088 <completer_handle_brkchars>: Change type to
5089 completer_handle_brkchars_ftype.
5090 * command.h (completer_ftype): Add describing comment and give
5091 names to parameters.
5092 (completer_ftype_void): Rename to ...
5093 (completer_handle_brkchars_ftype) ... this. Add describing comment.
5094 (set_cmd_completer_handle_brkchars): Adjust.
5095 * completer.c (filename_completer_handle_brkchars): New function.
5096 (complete_line_internal_normal_command): New function, factored
5097 out from ...
5098 (complete_line_internal): ... here.
5099 (command_completer_handle_brkchars)
5100 (default_completer_handle_brkchars)
5101 (completer_handle_brkchars_func_for_completer): New functions.
5102 * completer.h (set_gdb_completion_word_break_characters): Delete
5103 declaration.
5104 (completer_handle_brkchars_func_for_completer): New declaration.
5105 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
5106 completer_handle_brkchars_func_for_completer.
5107
5108 2017-07-17 Pedro Alves <palves@redhat.com>
5109
5110 * completer.c (symbol_completer): New function, based on
5111 make_symbol_completion_list_fn.
5112 * completer.h (symbol_completer): New declaration.
5113 * guile/scm-cmd.c (cmdscm_completers): Adjust.
5114 * python/py-cmd.c (completers): Adjust.
5115 * symtab.c (make_symbol_completion_list_fn): Delete.
5116 * symtab.h (make_symbol_completion_list_fn): Delete.
5117 * cli/cli-decode.c (add_cmd): Adjust.
5118
5119 2017-07-17 Pedro Alves <palves@redhat.com>
5120
5121 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
5122 * dwarf2read.c: Include "filename-seen-cache.h".
5123 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
5124 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
5125 * filename-seen-cache.c: New file.
5126 * filename-seen-cache.h: New file.
5127 * symtab.c: Include "filename-seen-cache.h".
5128 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
5129 (create_filename_seen_cache, clear_filename_seen_cache)
5130 (delete_filename_seen_cache, filename_seen): Delete, parts moved
5131 to filename-seen-cache.h/filename-seen-cache.c.
5132 (output_source_filename, sources_info)
5133 (maybe_add_partial_symtab_filename)
5134 (make_source_files_completion_list): Adjust to use
5135 filename_seen_cache.
5136
5137 2017-07-17 Pedro Alves <palves@redhat.com>
5138
5139 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
5140 fields.
5141 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
5142 dwarf2_debug_sections*)): New.
5143 (dwarf2_per_objfile::dwarf2_per_objfile(const
5144 dwarf2_per_objfile&)): Declare as deleted.
5145 (dwarf2_per_objfile::operator=): Declare as deleted.
5146 (dwarf2_per_objfile::dwarf2_per_objfile)
5147 (dwarf2_per_objfile::~dwarf2_per_objfile)
5148 (dwarf2_per_objfile::free_cached_comp_units): New.
5149 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
5150 ctor. Call dwarf2_per_objfile's ctor manually.
5151 (dwarf2_locate_sections): Deleted/refactored as ...
5152 (dwarf2_per_objfile::locate_sections): ... this new method.
5153 (free_cached_comp_units): Defer to
5154 dwarf2_per_objfile::free_cached_comp_units.
5155 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
5156
5157 2017-07-14 Tom Tromey <tom@tromey.com>
5158
5159 PR rust/21764:
5160 * rust-exp.y (convert_ast_to_expression): Add "want_type"
5161 parameter.
5162 <UNOP_SIZEOF>: Split into separate case.
5163 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
5164
5165 2017-07-14 Tom Tromey <tom@tromey.com>
5166
5167 PR rust/21763:
5168 * symtab.c (symbol_matches_domain): Add language_rust to special
5169 case.
5170 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
5171 treat LOC_TYPEDEF symbols as variables.
5172
5173 2017-07-14 Pedro Alves <palves@redhat.com>
5174
5175 * symtab.c (make_file_symbol_completion_list_1): Iterate over
5176 symtabs matching all symtabs with SRCFILE as file name instead of
5177 only considering the first hit, with lookup_symtab.
5178
5179 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
5180
5181 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
5182 operator_name parameters.
5183 (gen_expr): Update function call.
5184
5185 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
5186
5187 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
5188 parameter.
5189 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
5190 Likewise.
5191 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
5192 parameter, use agent_expr::gdbarch instead, update function
5193 calls.
5194 (locexpr_tracepoint_var_ref): Likewise.
5195 (loclist_tracepoint_var_ref): Likewise.
5196 * ax-gdb.c (gen_trace_static_fields): Likewise.
5197 (gen_traced_pop): Likewise.
5198 (gen_frame_args_address): Likewise.
5199 (gen_frame_locals_address): Likewise.
5200 (gen_var_ref): Likewise.
5201 (gen_struct_ref_recursive): Likewise.
5202 (gen_static_field): Likewise.
5203 (gen_maybe_namespace_elt): Likewise.
5204 (gen_expr): Likewise.
5205 (gen_trace_for_var): Likewise.
5206 (gen_trace_for_expr): Likewise.
5207 (gen_trace_for_return_address): Likewise.
5208
5209 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
5210
5211 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
5212 parameter.
5213 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
5214
5215 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
5216
5217 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
5218 from ax, update calls.
5219 (gen_usual_arithmetic): Likewise.
5220 (gen_integral_promotions): Likewise.
5221 (gen_bitfield_ref): Likewise.
5222 (gen_primitive_field): Likewise.
5223 (gen_struct_ref_recursive): Likewise.
5224 (gen_struct_ref): Likewise.
5225 (gen_maybe_namespace_elt): Likewise.
5226 (gen_struct_elt_for_reference): Likewise.
5227 (gen_namespace_elt): Likewise.
5228 (gen_aggregate_elt_ref): Likewise.
5229 (gen_expr): Get gdbarch from ax, update calls.
5230 (gen_expr_binop_rest): Likewise.
5231
5232 2017-07-13 Pedro Alves <palves@redhat.com>
5233
5234 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
5235 as default tdesc.
5236 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
5237 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
5238 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
5239 tdesc_amd64_linux as default tdesc. Get final tdesc from the
5240 tdep.
5241 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
5242 Get final tdesc from the tdep.
5243 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
5244 default tdesc.
5245 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
5246 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
5247 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
5248 Use it as default tdesc.
5249 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
5250 down to amd_init_abi. No longer handle fallback tdesc here.
5251 * amd64-tdep.h (tdesc_x32): Declare.
5252 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
5253 parameter.
5254 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
5255 as default tdesc.
5256
5257 2017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5258
5259 * s390-linux-tdep.c (s390_process_record): Add support for
5260 instructions new in arch12.
5261
5262 2017-07-11 John Baldwin <jhb@FreeBSD.org>
5263
5264 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
5265 PT_GETFSBASE and PT_GETGSBASE.
5266 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
5267 PT_SETGSBASE.
5268
5269 2017-07-11 John Baldwin <jhb@FreeBSD.org>
5270
5271 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
5272 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
5273 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
5274 those rules.
5275 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
5276 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
5277 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
5278 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
5279 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
5280 * features/i386/amd64.xml: Add 64bit-segments.xml.
5281 * features/i386/amd64-avx-avx512.c: Regenerated.
5282 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
5283 * features/i386/amd64-avx-mpx.c: Regenerated.
5284 * features/i386/amd64-avx.c: Regenerated.
5285 * features/i386/amd64-mpx.c: Regenerated.
5286 * features/i386/amd64.c: Regenerated.
5287 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
5288 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
5289 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
5290 * regformats/i386/amd64-avx.dat: Regenerated.
5291 * regformats/i386/amd64-mpx.dat: Regenerated.
5292 * regformats/i386/amd64.dat: Regenerated.
5293
5294 2017-07-10 Yao Qi <yao.qi@linaro.org>
5295
5296 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
5297 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
5298
5299 2017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
5300
5301 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
5302 unsetenv.
5303 * gnulib/aclocal.m4: Regenerate.
5304 * gnulib/config.in: Regenerate.
5305 * gnulib/configure: Regenerate.
5306 * gnulib/import/Makefile.am: Regenerate.
5307 * gnulib/import/Makefile.in: Regenerate.
5308 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
5309 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
5310 * gnulib/import/m4/environ.m4: New file.
5311 * gnulib/import/m4/setenv.m4: New file.
5312 * gnulib/import/setenv.c: New file.
5313 * gnulib/import/unsetenv.c: New file.
5314
5315 2017-07-09 Simon Marchi <simon.marchi@ericsson.com>
5316
5317 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
5318 address when op is DW_OP_addr.
5319
5320 2017-07-09 Tom Tromey <tom@tromey.com>
5321
5322 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
5323 check and apply to outer type.
5324
5325 2017-07-07 John Baldwin <jhb@FreeBSD.org>
5326
5327 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
5328 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
5329 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
5330 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
5331
5332 2017-07-07 John Baldwin <jhb@FreeBSD.org>
5333
5334 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
5335
5336 2017-07-07 John Baldwin <jhb@FreeBSD.org>
5337
5338 * corelow.c (get_core_siginfo): Remove.
5339 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
5340 instead of get_core_siginfo.
5341 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
5342 * gdbarch.h: Re-generate.
5343 * gdbarch.c: Re-generate.
5344 * linux-tdep.c (linux_core_xfer_siginfo): New.
5345 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
5346
5347 2017-07-07 John Baldwin <jhb@FreeBSD.org>
5348
5349 * corelow.c (thread_section_name): Move to ...
5350 * gdbcore.h (thread_section_name): ... here.
5351
5352 2017-07-07 John Baldwin <jhb@FreeBSD.org>
5353
5354 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
5355 (struct siginfo32): New.
5356 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
5357 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
5358 via ptrace(PT_LWPINFO).
5359
5360 2017-07-07 John Baldwin <jhb@FreeBSD.org>
5361
5362 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
5363 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
5364 (fbsd_get_siginfo_type): New.
5365 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
5366 (_initialize_fbsd_tdep): New.
5367
5368 2017-07-06 David Blaikie <dblaikie@gmail.com>
5369
5370 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
5371 a singular dwo_unit*) to support multiple CUs in the same way that
5372 multiple TUs are supported.
5373 (create_cus_hash_table): Replace create_dwo_cu with a function for
5374 parsing multiple CUs from a DWO file.
5375 (open_and_init_dwo_file): Use create_cus_hash_table rather than
5376 create_dwo_cu.
5377 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
5378 htab_find, rather than comparing the signature to a singleton CU in
5379 the dwo_file.
5380
5381 2017-07-06 Pedro Alves <palves@redhat.com>
5382
5383 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
5384
5385 2017-07-04 Pedro Alves <palves@redhat.com>
5386
5387 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
5388 * gdbtypes.h (TYPE_STATIC): Delete.
5389 (struct fn_field) <is_public, is_abstract, is_static, is_final,
5390 is_synchronized, is_native>: Delete.
5391 <dummy>: Bump.
5392 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
5393 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
5394 (TYPE_FN_FIELD_ABSTRACT): Delete.
5395
5396 2017-07-03 Simon Marchi <simon.marchi@ericsson.com>
5397
5398 * buffer.h (buffer_finish): Fix spelling mistakes.
5399
5400 2017-07-01 Eli Zaretskii <eliz@gnu.org>
5401
5402 * .dir-locals.el: Automatically switch to C-style comments in
5403 versions of Emacs that support the feature.
5404
5405 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
5406 Pedro Alves <palves@redhat.com>
5407
5408 PR cli/21688
5409 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
5410 (process_next_line): New variable 'inline_cmd'.
5411 Adjust 'if' clauses for "python", "compile" and "guile" to use
5412 'command_name_equals' and check for '!inline_cmd'.
5413
5414 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
5415
5416 PR cli/21688
5417 * cli/cli-script.c (command_name_equals_not_inline): New function.
5418 (process_next_line): Adjust 'if' clauses for "python", "compile"
5419 and "guile" to use command_name_equals_not_inline.
5420
5421 2017-06-29 Pedro Alves <palves@redhat.com>
5422
5423 * completer.c (expression_completer): Call
5424 linespec_location_completer instead of location_completer.
5425
5426 2017-06-29 Pedro Alves <palves@redhat.com>
5427
5428 * completer.c (expression_completer): Remove code that recomputes
5429 'text' from 'word'.
5430
5431 2017-06-29 Yao Qi <yao.qi@linaro.org>
5432
5433 * regformats/regdat.sh: Generate code with
5434 "ifndef IN_PROCESS_AGENT".
5435
5436 2017-06-28 Pedro Alves <palves@redhat.com>
5437
5438 * command.h: Include "common/scoped_restore.h".
5439
5440 2017-06-28 Yao Qi <yao.qi@linaro.org>
5441
5442 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
5443 instead of obstack_grow.
5444
5445 2017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
5446
5447 PR gdb/21337
5448 * symfile.c (reread_symbols): Call objfiles_changed just before
5449 read_symbols.
5450
5451 2017-06-27 Pedro Alves <palves@redhat.com>
5452
5453 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
5454 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
5455 (completion_list_add_symbol, completion_list_add_msymbol):
5456 ... these new functions.
5457 (add_symtab_completions)
5458 (default_make_symbol_completion_list_break_on_1): Adjust.
5459
5460 2017-06-27 Pedro Alves <palves@redhat.com>
5461
5462 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
5463 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
5464 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
5465 dtor.
5466 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
5467 'storage_obstack' field an auto_obstack. In-class initialize all
5468 non-bitfield fields. Make minsyms_read bool.
5469 * symfile.c (read_symbols): Adjust.
5470
5471 2017-06-27 Alan Hayward <alan.hayward@arm.com>
5472
5473 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
5474 (gdbsim_store_register): Likewise.
5475
5476 2017-06-27 Pedro Alves <palves@redhat.com>
5477
5478 * c-exp.y (name_obstack): Now an auto_obstack.
5479 (yylex): Use auto_obstack::clear.
5480 (c_parse): Use auto_obstack::clear instead of reinitializing and
5481 freeing the obstack.
5482 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
5483 * d-exp.y (name_obstack): Now an auto_obstack.
5484 (yylex): Use auto_obstack::clear.
5485 (d_parse): Use auto_obstack::clear instead of reinitializing and
5486 freeing the obstack.
5487 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
5488 auto_obstack.
5489 * dwarf2read.c (create_addrmap_from_index)
5490 (dwarf2_build_psymtabs_hard)
5491 (update_enumeration_type_from_children): Likewise.
5492 * gdb_obstack.h (auto_obstack): New type.
5493 * go-exp.y (name_obstack): Now an auto_obstack.
5494 (build_packaged_name): Use auto_obstack::clear.
5495 (go_parse): Use auto_obstack::clear instead of reinitializing and
5496 freeing the obstack.
5497 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
5498 auto_obstack.
5499 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
5500 * rust-exp.y (work_obstack): Now an auto_obstack.
5501 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
5502 reinitializing and freeing the obstack.
5503 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
5504 (host_char_to_target): Use auto_obstack.
5505 * utils.h (make_cleanup_obstack_free): Delete declaration.
5506 * valprint.c (generic_emit_char, generic_printstr): Use
5507 auto_obstack.
5508
5509 2017-06-27 Simon Marchi <simon.marchi@ericsson.com>
5510
5511 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
5512 thread.
5513 (darwin_init_thread_list): Don't update dummy thread.
5514 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
5515
5516 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
5517
5518 * record-full.c (netorder16): Remove.
5519
5520 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
5521
5522 * common/diagnostics.h: Define macros for GCC.
5523 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
5524 * common/vec.h: Include diagnostics.h.
5525 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
5526 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
5527 warning.
5528
5529 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
5530
5531 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
5532 New macro.
5533 * ada-lex.l: Ignore deprecated register warnings.
5534
5535 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
5536
5537 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
5538 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
5539
5540 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
5541
5542 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
5543 its own line.
5544
5545 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
5546
5547 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
5548
5549 2017-06-23 Alan Hayward <alan.hayward@arm.com>
5550
5551 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
5552 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
5553 (xtensa_register_read_masked): Likewise.
5554
5555 2017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
5556
5557 * common/environ.c (gdb_environ::unset): Update comment.
5558
5559 2017-06-22 Alan Hayward <alan.hayward@arm.com>
5560
5561 * python/py-unwind.c (pyuw_sniffer): Allocate space for
5562 registers.
5563
5564 2017-06-22 Alan Hayward <alan.hayward@arm.com>
5565
5566 * record-full.c (record_full_exec_insn): Use byte_vector.
5567
5568 2017-06-22 Yao Qi <yao.qi@linaro.org>
5569
5570 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
5571 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
5572
5573 2017-06-22 Alan Hayward <alan.hayward@arm.com>
5574
5575 * remote.c (cached_reg): Move from here...
5576 * regcache.h (cached_reg): ...to here.
5577 * python/py-unwind.c (struct reg_info): Remove.
5578 (cached_frame_info): Use cached_reg_t.
5579 (pyuw_prev_register): Likewise.
5580 (pyuw_sniffer): Use cached_reg_t and allocate registers.
5581 (pyuw_dealloc_cache): Free all registers.
5582
5583 2017-06-22 Pedro Alves <palves@redhat.com>
5584 Simon Marchi <simon.marchi@ericsson.com>
5585
5586 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
5587 warning.
5588 * common/diagnostics.h: New file.
5589
5590 2017-06-22 Pedro Alves <palves@redhat.com>
5591
5592 * common/agent.h: Add include guards.
5593
5594 2017-06-21 Simon Marchi <simon.marchi@ericsson.com>
5595
5596 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
5597 talk about addressable units instead of bytes.
5598
5599 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
5600
5601 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
5602 of '::const_iterator'.
5603
5604 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
5605
5606 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5607 'unittests/environ-selftests.c'.
5608 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
5609 * charset.c (find_charset_names): Declare object 'iconv_env'.
5610 Update code to use 'iconv_env' object. Remove call to
5611 'free_environ'.
5612 * common/environ.c: Include <utility>.
5613 (make_environ): Delete function.
5614 (free_environ): Delete function.
5615 (gdb_environ::clear): New function.
5616 (gdb_environ::operator=): New function.
5617 (gdb_environ::get): Likewise.
5618 (environ_vector): Delete function.
5619 (set_in_environ): Delete function.
5620 (gdb_environ::set): New function.
5621 (unset_in_environ): Delete function.
5622 (gdb_environ::unset): New function.
5623 (gdb_environ::envp): Likewise.
5624 * common/environ.h: Include <vector>.
5625 (struct gdb_environ): Delete; transform into...
5626 (class gdb_environ): ... this class.
5627 (free_environ): Delete prototype.
5628 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
5629 environ_vector): Likewise.
5630 * infcmd.c (run_command_1): Update code to call
5631 'envp' from 'gdb_environ' class.
5632 (environment_info): Update code to call methods from 'gdb_environ'
5633 class.
5634 (unset_environment_command): Likewise.
5635 (path_info): Likewise.
5636 (path_command): Likewise.
5637 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
5638 (inferior::inferior): Initialize 'environment' using the host's
5639 information.
5640 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
5641 Include "environ.h".
5642 (class inferior) <environment>: Change type from 'struct
5643 gdb_environ' to 'gdb_environ'.
5644 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
5645 methods from 'gdb_environ' class.
5646 * solib.c (solib_find_1): Likewise
5647 * unittests/environ-selftests.c: New file.
5648
5649 2017-06-20 Yao Qi <yao.qi@linaro.org>
5650
5651 * features/i386/i386-linux.xml: Exchange the order of including
5652 32bit-linux.xml and 32bit-sse.xml.
5653 * features/i386/i386-linux.c: Regenerated.
5654
5655 2017-06-20 Yao Qi <yao.qi@linaro.org>
5656
5657 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
5658 Delete copy ctor and assignment operator.
5659 (tdesc_type): Likewise.
5660 (tdesc_feature): Likewise.
5661 (tdesc_free_reg): Remove.
5662 (tdesc_create_reg): Use new.
5663 (tdesc_free_type): Remove.
5664 (tdesc_create_vector): Use new.
5665 (tdesc_create_union): Likewise.
5666 (tdesc_create_flags): Likewise.
5667 (tdesc_create_enum): Likewise.
5668 (tdesc_free_feature): Delete.
5669 (free_target_description): Use delete.
5670
5671 2017-06-19 John Baldwin <jhb@FreeBSD.org>
5672
5673 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
5674 registers.
5675
5676 2017-06-19 Pedro Alves <palves@redhat.com>
5677
5678 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
5679 after gdb::unlinker.
5680
5681 2017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
5682
5683 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
5684 gdb_environ to access an environment variable.
5685
5686 2017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
5687
5688 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
5689 gdb_byte*.
5690
5691 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5692
5693 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
5694
5695 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5696
5697 * configure: Re-generate.
5698 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
5699
5700 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5701
5702 * configure: Re-generate.
5703 * warning.m4: Pass -Werror to compiler when checking for
5704 supported warning flags.
5705
5706 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5707
5708 * Makefile.in (COMPILE.pre): Add "-x c++".
5709
5710 2017-06-16 Alan Hayward <alan.hayward@arm.com>
5711 Pedro Alves <palves@redhat.com>
5712 Yao Qi <yao.qi@linaro.org>
5713
5714 * defs.h (RequireLongest): New.
5715 (extract_integer): Declare function template.
5716 (extract_signed_integer): Remove the declaration, but define it
5717 static inline.
5718 (extract_unsigned_integer): Likewise.
5719 (store_integer): Declare function template.
5720 (store_signed_integer): Remove the declaration, but define it
5721 static inline.
5722 (store_unsigned_integer): Likewise.
5723 * findvar.c (extract_integer): New function template.
5724 (extract_signed_integer): Remove.
5725 (extract_unsigned_integer): Remove.
5726 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
5727 instantiations.
5728 (store_integer): New function template.
5729 (store_signed_integer): Remove.
5730 (store_unsigned_integer): Remove.
5731 (store_integer): Explicit instantiations.
5732 * regcache.c (regcache_raw_read_signed): Update.
5733 (regcache::raw_read): New function.
5734 (regcache::raw_read_signed): Remove.
5735 (regcache::raw_read_unsigned): Remove.
5736 (regcache_raw_read_unsigned): Update.
5737 (regcache_raw_write_unsigned): Update.
5738 (regcache::raw_write_signed): Remove.
5739 (regcache::raw_write): New function.
5740 (regcache_cooked_read_signed): Update.
5741 (regcache::raw_write_unsigned): Remove.
5742 (regcache::cooked_read_signed): Remove.
5743 (regcache_cooked_read_unsigned): Update.
5744 (regcache::cooked_read_unsigned): Remove.
5745 (regcache_cooked_write_signed): Update.
5746 (regcache_cooked_write_unsigned): Update.
5747 * regcache.h (regcache) <raw_read_signed>: Remove.
5748 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
5749 <raw_read, raw_write>: New.
5750 <cooked_read_signed, cooked_write_signed>: Remove.
5751 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
5752 <cooked_read, cooked_write>: New.
5753 * sh64-tdep.c (sh64_pseudo_register_read): Update.
5754 (sh64_pseudo_register_write): Update.
5755
5756 2017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
5757
5758 * arc-tdep.c (arc_disassembler_options): New variable.
5759 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
5760 of default_print_insn.
5761 (arc_delayed_print_insn): Set info->section when needed,
5762 use default_print_insn to retrieve a disassembler.
5763
5764 2017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
5765
5766 PR gdb/21574
5767 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
5768 to mention $SHELL and startup-with-shell.
5769
5770 2017-06-14 Max Filippov <jcmvbkbc@gmail.com>
5771
5772 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
5773
5774 2017-06-14 Yao Qi <yao.qi@linaro.org>
5775
5776 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
5777 default_print_insn instead of print_insn_aarch64.
5778 * arm-tdep.c (gdb_print_insn_arm): Call
5779 default_print_insn instead of print_insn_big_arm
5780 and print_insn_little_arm.
5781 * i386-tdep.c (i386_print_insn): Call default_print_insn
5782 instead of print_insn_i386.
5783 * ia64-tdep.c (ia64_print_insn): Call
5784 default_print_insn instead of print_insn_ia64.
5785 * mips-tdep.c (gdb_print_insn_mips): Call
5786 default_print_insn instead of print_insn_big_mips
5787 and print_insn_little_mips.
5788 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
5789 instead of print_insn_spu.
5790
5791 2017-06-14 Pedro Alves <palves@redhat.com>
5792
5793 * ada-lang.c: Include "common/byte-vector.h".
5794 (ada_value_primitive_packed_val): Use gdb::byte_vector.
5795 * charset.c (wchar_iterator::iterate): Resize the vector instead
5796 of reserving it.
5797 * common/byte-vector.h: Include "common/def-vector.h".
5798 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
5799 * cli/cli-dump.c: Include "common/byte-vector.h".
5800 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
5801 * common/byte-vector.h: New file.
5802 * common/def-vector.h: New file.
5803 * common/default-init-alloc.h: New file.
5804 * dwarf2loc.c: Include "common/byte-vector.h".
5805 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
5806 instead of reserving it.
5807 * dwarf2read.c: Include "common/byte-vector.h".
5808 (data_buf::m_vec): Now a gdb::byte_vector.
5809 * gdb_regex.c: Include "common/def-vector.h".
5810 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
5811 * mi/mi-main.c: Include "common/byte-vector.h".
5812 (mi_cmd_data_read_memory): Use gdb::byte_vector.
5813 * printcmd.c: Include "common/byte-vector.h".
5814 (print_scalar_formatted): Use gdb::byte_vector.
5815 * valprint.c: Include "common/byte-vector.h".
5816 (maybe_negate_by_bytes, print_decimal_chars): Use
5817 gdb::byte_vector.
5818
5819 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
5820
5821 * darwin-nat.c: Include "nat/fork-inferior.h".
5822
5823 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
5824
5825 * configure.nat: Factor out Darwin bits that are not
5826 architecture-specific. Add fork-inferior.o.
5827
5828 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
5829
5830 * configure.nat: Factor out AIX bits that are not
5831 architecture-specific. Add fork-inferior.o.
5832
5833 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5834
5835 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
5836 (read_pieced_value, write_pieced_value): ...here. Reduce to
5837 wrappers that just call rw_pieced_value.
5838
5839 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5840
5841 * dwarf2loc.c (write_pieced_value): When writing the data for a
5842 memory piece, use write_memory_with_notification instead of
5843 write_memory.
5844
5845 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5846
5847 * valops.c (read_value_memory): Change embedded_offset to
5848 represent a bit offset instead of a byte offset.
5849 * value.h (read_value_memory): Adjust comment.
5850
5851 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5852
5853 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
5854 dest_offset_bits and source_offset_bits.
5855 (write_pieced_value): Likewise.
5856
5857 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5858
5859 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
5860 given by DW_OP_bit_piece.
5861 (write_pieced_value): Likewise.
5862
5863 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5864
5865 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
5866 some other preparations to the places where sufficient information
5867 is available.
5868 (write_pieced_value): Likewise.
5869
5870 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5871
5872 * dwarf2loc.c (bits_to_bytes): New function.
5873 (read_pieced_value): Fix offset calculations for register pieces
5874 on big-endian targets.
5875 (write_pieced_value): Likewise.
5876
5877 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5878
5879 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
5880 (write_pieced_value): Likewise.
5881
5882 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5883
5884 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
5885 transfer the source value's least significant bits, instead of its
5886 lowest-addressed ones. Rename type_len to max_offset.
5887 (read_pieced_value): Mirror above changes to write_pieced_value as
5888 applicable.
5889
5890 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5891
5892 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
5893 truncate full bytes from dest_offset_bits before using it as an
5894 offset into the buffer.
5895
5896 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5897
5898 * dwarf2loc.c (write_pieced_value): Include transfer size in
5899 byte-wise check.
5900
5901 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5902
5903 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
5904 calculation of this_size.
5905
5906 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5907
5908 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
5909 when targeting a bit-field.
5910 (write_pieced_value): Likewise.
5911
5912 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5913
5914 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
5915 (allocate_piece_closure): Drop addr_size parameter.
5916 (dwarf2_evaluate_loc_desc_full): Adjust call to
5917 allocate_piece_closure.
5918
5919 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5920
5921 PR gdb/21226
5922 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
5923 the LSB end, independent of endianness.
5924
5925 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5926
5927 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
5928 size capping.
5929
5930 2017-06-13 Yao Qi <yao.qi@linaro.org>
5931
5932 * mips-linux-nat.c: Move include features/mips*-linux.c to
5933 mips-linux-tdep.c.
5934 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
5935 to mips-linux-tdep.c.
5936 * mips-linux-tdep.c: Include features/mips*-linux.c
5937 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
5938 functions.
5939 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
5940 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
5941 (tdesc_mips64_dsp_linux): Declare.
5942
5943 2017-06-12 Tom Tromey <tom@tromey.com>
5944
5945 * valprint.h (val_print_type_code_int): Remove.
5946 * valprint.c (generic_val_print_int): Always call
5947 val_print_scalar_formatted.
5948 (val_print_type_code_int): Remove.
5949 * printcmd.c (print_scalar_formatted): Handle options->format==0.
5950 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
5951 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
5952 * ada-valprint.c (ada_val_print_num): Use
5953 val_print_scalar_formatted.
5954
5955 2017-06-12 Tom Tromey <tom@tromey.com>
5956
5957 * printcmd.c (print_scalar_formatted): Unify the two switches.
5958 Don't convert scalars to LONGEST.
5959
5960 2017-06-12 Tom Tromey <tom@tromey.com>
5961
5962 PR exp/16225:
5963 * valprint.h (print_decimal_chars): Update.
5964 * valprint.c (maybe_negate_by_bytes): New function.
5965 (print_decimal_chars): Add "is_signed" argument.
5966 * printcmd.c (print_scalar_formatted): Update.
5967
5968 2017-06-12 Tom Tromey <tom@tromey.com>
5969
5970 PR exp/16225:
5971 * valprint.h (print_binary_chars, print_hex_chars): Update.
5972 * valprint.c (val_print_type_code_int): Update.
5973 (print_binary_chars): Add "zero_pad" argument.
5974 (emit_octal_digit): New function.
5975 (print_octal_chars): Don't zero-pad.
5976 (print_decimal_chars): Likewise.
5977 (print_hex_chars): Add "zero_pad" argument.
5978 * sh64-tdep.c (sh64_do_fp_register): Update.
5979 * regcache.c (regcache::dump): Update.
5980 * printcmd.c (print_scalar_formatted): Update.
5981 * infcmd.c (default_print_one_register_info): Update.
5982
5983 2017-06-12 Pedro Alves <palves@redhat.com>
5984 Alan Hayward <alan.hayward@arm.com>
5985
5986 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
5987 (mips_eabi_push_dummy_call): Rename local 'regsize' to
5988 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
5989 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
5990 Assert that abi_regsize bytes fit in 'ref_valbuf'.
5991
5992 2017-06-12 Pedro Alves <palves@redhat.com>
5993
5994 * dwarf2read.c (mapped_symtab::data): Now a vector of
5995 symtab_index_entry instead of vector of
5996 std::unique_ptr<symtab_index_entry>. All users adjusted to check
5997 whether an element's name is NULL instead of checking whether the
5998 element itself is NULL.
5999 (find_slot): Change return type. Adjust.
6000 (hash_expand, , add_index_entry, uniquify_cu_indices)
6001 (write_hash_table): Adjust.
6002
6003 2017-06-12 Pedro Alves <palves@redhat.com>
6004
6005 * dwarf2read.c (recursively_count_psymbols): New function.
6006 (write_psymtabs_to_index): Call it to compute number of psyms and
6007 pass estimate size of psyms_seen to unordered_set's ctor.
6008
6009 2017-06-12 Pedro Alves <palves@redhat.com>
6010
6011 * dwarf2read.c (write_hash_table): Check if key already exists
6012 before emplacing.
6013
6014 2017-06-12 Pedro Alves <palves@redhat.com>
6015
6016 * dwarf2read.c (data_buf::append_space): Rename to...
6017 (data_buf::grow): ... this, and make private. Adjust all callers.
6018 (data_buf::append_uint): New method.
6019 (add_address_entry, write_one_signatured_type)
6020 (write_psymtabs_to_index): Use it.
6021
6022 2017-06-12 Pedro Alves <palves@redhat.com>
6023
6024 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
6025 (file_write (FILE *, const std::vector<Elem>&)): Delete.
6026 (data_buf::file_write): Call ::fwrite directly.
6027
6028 2017-06-12 Pedro Alves <palves@redhat.com>
6029
6030 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
6031 std::vector::erase.
6032
6033 2017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
6034
6035 Code cleanup: C++ify .gdb_index producer.
6036 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
6037 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
6038 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
6039 (create_strtab, add_string): Remove.
6040 (file_write, data_buf): New.
6041 (struct symtab_index_entry): Use std::vector for cu_indices.
6042 (struct mapped_symtab): Use std::vector for data.
6043 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
6044 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
6045 Remove.
6046 (find_slot): Change return type. Update it to the new data structures.
6047 (hash_expand, add_index_entry): Update it to the new data structures.
6048 (offset_type_compare): Remove.
6049 (uniquify_cu_indices): Update it to the new data structures.
6050 (c_str_view, c_str_view_hasher, vector_hasher): New.
6051 (add_indices_to_cpool): Remove.
6052 (write_hash_table): Update it to the new data structures.
6053 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
6054 (eq_psymtab_cu_index): Remove.
6055 (psym_index_map): New typedef.
6056 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
6057 reference and std::unordered_map for cu_index_htab.
6058 (add_address_entry, add_address_entry_worker, write_address_map)
6059 (write_psymbols): Update it to the new data structures.
6060 (write_obstack): Remove.
6061 (struct signatured_type_index_data): Change types_list to a data_buf
6062 reference and psyms_seen to a std::unordered_set reference.
6063 (write_one_signatured_type, recursively_write_psymbols)
6064 (write_psymtabs_to_index): Update it to the new data structures.
6065
6066 2017-06-11 Simon Marchi <simon.marchi@ericsson.com>
6067
6068 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
6069 separate-debug-file commands.
6070 * symfile.h (separate_debug_file_debug): New global.
6071 * symfile.c (separate_debug_file_debug): New global.
6072 (separate_debug_file_exists, find_separate_debug_file): Add
6073 debug output.
6074 (_initialize_symfile): Add "set debug separate-debug-file"
6075 command.
6076 * build-id.c (build_id_to_debug_bfd,
6077 find_separate_debug_file_by_buildid): Add debug output.
6078
6079 2017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
6080
6081 * gdbarch.sh (displaced_step_free_closure): Remove.
6082 * gdbarch.h, gdbarch.c: Re-generate.
6083 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
6084 displaced_step_free_closure.
6085 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
6086 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
6087 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
6088 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
6089 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
6090 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
6091 * arch-utils.h (simple_displaced_step_free_closure): Remove.
6092 * arch-utils.c (simple_displaced_step_free_closure): Remove.
6093 * infrun.c (displaced_step_clear): Call xfree instead of
6094 gdbarch_displaced_step_free_closure.
6095
6096 2017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
6097
6098 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
6099 NULL".
6100
6101 2017-06-08 Alan Hayward <alan.hayward@arm.com>
6102
6103 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
6104 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
6105 (mn10300_push_dummy_call): Likewise.
6106
6107 2017-06-08 Alan Hayward <alan.hayward@arm.com>
6108
6109 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
6110
6111 2017-06-08 Alan Hayward <alan.hayward@arm.com>
6112
6113 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
6114
6115 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6116
6117 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
6118 able to start inferiors using a shell.
6119 (New remote packets): Announce new packet "QStartupWithShell".
6120 * remote.c: Add PACKET_QStartupWithShell.
6121 (extended_remote_create_inferior): Handle new
6122 PACKET_QStartupWithShell.
6123 (remote_protocol_features) <QStartupWithShell>: New entry for
6124 PACKET_QStartupWithShell.
6125 (_initialize_remote): Call "add_packet_config_cmd" for
6126 QStartupShell.
6127
6128 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6129 Pedro Alves <palves@redhat.com>
6130
6131 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
6132 and "nat/fork-inferior.h".
6133 * common/common-inferior.h: New file, with contents from
6134 "gdb/inferior.h".
6135 * commom/common-utils.c: Include "common-utils.h".
6136 (stringify_argv): New function.
6137 * common/common-utils.h (stringify_argv): New prototype.
6138 * configure.nat: Add "fork-inferior.o" as a dependency for
6139 "*linux*", "fbsd*" and "nbsd*" hosts.
6140 * corefile.c (get_exec_file): Update comment.
6141 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
6142 instead of "startup_inferior".
6143 (darwin_create_inferior): Call "add_thread_silent" after
6144 "fork_inferior".
6145 * fork-child.c: Cleanup unnecessary includes.
6146 (SHELL_FILE): Move to "common/common-fork-child.c".
6147 (environ): Likewise.
6148 (exec_wrapper): Initialize.
6149 (get_exec_wrapper): New function.
6150 (breakup_args): Move to "common/common-fork-child.c"; rename to
6151 "breakup_args_for_exec".
6152 (escape_bang_in_quoted_argument): Move to
6153 "common/common-fork-child.c".
6154 (saved_ui): New variable.
6155 (prefork_hook): New function.
6156 (postfork_hook): Likewise.
6157 (postfork_child_hook): Likewise.
6158 (gdb_startup_inferior): Likewise.
6159 (fork_inferior): Move to "common/common-fork-child.c". Update
6160 function to support gdbserver.
6161 (startup_inferior): Likewise.
6162 * gdbcore.h (get_exec_file): Remove declaration.
6163 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
6164 instead of "startup_inferior". Call "add_thread_silent" after
6165 "fork_inferior".
6166 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
6167 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
6168 instead of "startup_inferior". Call "add_thread_silent" after
6169 "fork_inferior".
6170 * inferior.h: Include "common-inferior.h".
6171 (trace_start_error): Move to "common/common-utils.h".
6172 (trace_start_error_with_name): Likewise.
6173 (fork_inferior): Move prototype to "nat/fork-inferior.h".
6174 (startup_inferior): Likewise.
6175 (gdb_startup_inferior): New prototype.
6176 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
6177 * nat/fork-inferior.h: New file.
6178 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
6179 instead of "startup_inferior". Call "add_thread_silent" after
6180 "fork_inferior".
6181 * target.h (target_terminal_init): Move prototype to
6182 "target/target.h".
6183 (target_terminal_inferior): Likewise.
6184 (target_terminal_ours): Likewise.
6185 * target/target.h (target_terminal_init): New prototype, moved
6186 from "target.h".
6187 (target_terminal_inferior): Likewise.
6188 (target_terminal_ours): Likewise.
6189 * utils.c (gdb_flush_out_err): New function.
6190
6191 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6192
6193 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
6194 * common/common-gdbthread.h: New file, with parts from
6195 "gdb/gdbthread.h".
6196 * gdbthread.h: Include "common-gdbthread.h".
6197 (switch_to_thread): Moved to "common/common-gdbthread.h".
6198
6199 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6200
6201 * Makefile.in (SFILES): Add "common/job-control.c".
6202 (HFILES_NO_SRCDIR): Add "common/job-control.h".
6203 (COMMON_OBS): Add "job-control.o".
6204 * common/job-control.c: New file, with contents from
6205 "gdb/inflow.c".
6206 * common/job-control.h: New file, with contents from "terminal.h".
6207 * fork-child.c: Include "job-control.h".
6208 * inflow.c: Include "job-control.h".
6209 (gdb_setpgid): Move to "common/common-inflow.c".
6210 (_initialize_inflow): Move setting of "job_control" to
6211 "handle_job_control".
6212 * terminal.h (job_control): Moved to "common/common-terminal.h".
6213 (gdb_setpgid): Likewise.
6214 * top.c: Include "job_control.h".
6215 * utils.c: Likewise.
6216 (job_control): Moved to "job-control.c".
6217
6218 2017-06-07 Pedro Alves <palves@redhat.com>
6219
6220 * Makefile.in (SFILES): Add gdb_regex.c.
6221 (COMMON_OBS): Add gdb_regex.o.
6222 * ada-lang.c (ada_add_standard_exceptions)
6223 (ada_add_exceptions_from_frame, name_matches_regex)
6224 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
6225 parameter type to compiled_regex. Adjust.
6226 (ada_exceptions_list): Use compiled_regex.
6227 * break-catch-throw.c (exception_catchpoint::pattern): Now a
6228 std::unique_ptr<compiled_regex>.
6229 (exception_catchpoint::~exception_catchpoint): Remove regfree
6230 call.
6231 (check_status_exception_catchpoint): Adjust to use compiled_regex.
6232 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
6233 * breakpoint.c (solib_catchpoint::compiled): Now a
6234 std::unique_ptr<compiled_regex>.
6235 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
6236 (check_status_catch_solib): Adjust to use compiled_regex.
6237 (add_solib_catchpoint): Adjust to use compiled_regex.
6238 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
6239 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
6240 compiled_regex reference. Adjust to use it.
6241 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
6242 declaration. Include "gdb_regex.h".
6243 (apropos_cmd): Change regex parameter to compiled_regex reference.
6244 * gdb_regex.c: New file.
6245 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
6246 declarations.
6247 (class compiled_regex): New.
6248 * linux-tdep.c: Include "common/gdb_optional.h".
6249 (struct mapping_regexes): New, factored out from
6250 mapping_is_anonymous_p, and adjusted to use compiled_regex.
6251 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
6252 gdb::optional and remove cleanups. Adjust to compiled_regex.
6253 * probe.c: Include "common/gdb_optional.h".
6254 (collect_probes): Use compiled_regex and gdb::optional and remove
6255 cleanups.
6256 * skip.c: Include "common/gdb_optional.h".
6257 (skiplist_entry::compiled_function_regexp): Now a
6258 gdb::optional<compiled_regex>.
6259 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
6260 (free_skiplist_entry): Remove regfree call.
6261 (compile_skip_regexp, skip_rfunction_p): Adjust to use
6262 compiled_regex and gdb::optional.
6263 * symtab.c: Include "common/gdb_optional.h".
6264 (search_symbols): Use compiled_regex and gdb::optional.
6265 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
6266 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
6267 to gdb_regex.c.
6268
6269 2017-06-07 Alan Hayward <alan.hayward@arm.com>
6270
6271 * regcache.c (regcache::save): Avoid buffer use.
6272 (regcache::dump): Likewise.
6273
6274 2017-06-07 Alan Hayward <alan.hayward@arm.com>
6275
6276 * sh-tdep.c (sh_pseudo_register_read): Remove
6277 MAX_REGISTER_SIZE.
6278 (sh_pseudo_register_write): Likewise.
6279 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
6280 (sh64_pseudo_register_write): Likewise
6281
6282 2017-06-07 Alan Hayward <alan.hayward@arm.com>
6283
6284 * aarch64-tdep.c (aarch64_store_return_value): Use
6285 V_REGISTER_SIZE.
6286 (aarch64_pseudo_read_value): Likewise.
6287 (aarch64_pseudo_write): Likewise.
6288
6289 2017-06-06 Yao Qi <yao.qi@linaro.org>
6290
6291 * regformats/regdef.h (set_register_cache): Remove the
6292 declaration.
6293
6294 2017-06-06 Alan Hayward <alan.hayward@arm.com>
6295
6296 * frame.c (frame_unwind_register_signed): Use
6297 frame_unwind_register_value.
6298
6299 2017-06-06 Pedro Alves <palves@redhat.com>
6300
6301 PR breakpoints/21553
6302 * breakpoint.c (create_breakpoints_sal_default)
6303 (init_breakpoint_sal, create_breakpoint_sal): Use
6304 gdb::unique_xmalloc_ptr for string parameters.
6305 (create_breakpoint): Constify 'extra_string' and 'cond_string'
6306 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
6307 (base_breakpoint_create_breakpoints_sal)
6308 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
6309 (strace_marker_create_breakpoints_sal)
6310 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
6311 string parameters.
6312 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
6313 gdb::unique_xmalloc_ptr for string parameters.
6314 (create_breakpoint): Constify 'extra_string' and 'cond_string'
6315 parameters.
6316
6317 2017-06-06 Alan Hayward <alan.hayward@arm.com>
6318
6319 * alpha-tdep.c (alpha_register_to_value): Use
6320 get_frame_register_value.
6321 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
6322
6323 2017-06-06 Alan Hayward <alan.hayward@arm.com>
6324
6325 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
6326 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
6327 (ia64_value_to_register): Likewise.
6328 (ia64_extract_return_value): Likewise.
6329 (ia64_store_return_value): Likewise.
6330 (ia64_push_dummy_call): Likewise.
6331
6332 2017-06-04 Joel Brobecker <brobecker@adacore.com>
6333
6334 GDB 8.0 released.
6335
6336 2017-06-03 Simon Marchi <simon.marchi@ericsson.com>
6337
6338 * x86-linux-nat.c (struct arch_lwp_info): Remove.
6339
6340 2017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
6341
6342 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
6343 parameter.
6344 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
6345
6346 2017-06-02 Simon Marchi <simon.marchi@ericsson.com>
6347
6348 * event-loop.c (poll_timers): Unallocate timer using delete
6349 instead of xfree.
6350
6351 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
6352
6353 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
6354 (struct breakpoint) <~breakpoint>: New.
6355 (struct watchpoint): Inherit from breakpoint.
6356 <~watchpoint>: New.
6357 <base>: Remove.
6358 (struct tracepoint): Inherit from breakpoint.
6359 <base>: Remove.
6360 * breakpoint.c (longjmp_breakpoint_ops): Remove.
6361 (struct longjmp_breakpoint): Inherit from breakpoint.
6362 <~longjmp_breakpoint>: New.
6363 <base>: Remove.
6364 (new_breakpoint_from_type): Remove casts.
6365 (watchpoint_in_thread_scope): Remove reference to base field.
6366 (watchpoint_del_at_next_stop): Likewise.
6367 (update_watchpoint): Likewise.
6368 (watchpoint_check): Likewise.
6369 (bpstat_check_watchpoint): Likewise.
6370 (set_longjmp_breakpoint): Likewise.
6371 (struct fork_catchpoint): Inherit from breakpoint.
6372 <base>: Remove.
6373 (struct solib_catchpoint): Inherit from breakpoint.
6374 <~solib_catchpoint>: New.
6375 <base>: Remove.
6376 (dtor_catch_solib): Change to ...
6377 (solib_catchpoint::~solib_catchpoint): ... this.
6378 (breakpoint_hit_catch_solib): Remove reference to base field.
6379 (add_solib_catchpoint): Likewise.
6380 (create_fork_vfork_event_catchpoint): Likewise.
6381 (struct exec_catchpoint): Inherit from breakpoint.
6382 <~exec_catchpoint>: New.
6383 <base>: Remove.
6384 (dtor_catch_exec): Change to ...
6385 (exec_catchpoint::~exec_catchpoint): ... this.
6386 (dtor_watchpoint): Change to ...
6387 (watchpoint::~watchpoint): ... this.
6388 (watch_command_1): Remove reference to base field.
6389 (catch_exec_command_1): Likewise.
6390 (base_breakpoint_dtor): Change to ...
6391 (breakpoint::~breakpoint): ... this.
6392 (base_breakpoint_ops): Remove dtor field value.
6393 (longjmp_bkpt_dtor): Change to ...
6394 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
6395 (strace_marker_create_breakpoints_sal): Remove reference to base
6396 field.
6397 (delete_breakpoint): Don't manually call breakpoint destructor.
6398 (create_tracepoint_from_upload): Remove reference to base field.
6399 (trace_pass_set_count): Likewise.
6400 (initialize_breakpoint_ops): Don't initialize
6401 momentary_breakpoint_ops, don't set dtors.
6402 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
6403 <~ada_catchpoint>: New.
6404 <base>: Remove.
6405 (create_excep_cond_exprs): Remove reference to base field.
6406 (dtor_exception): Change to ...
6407 (ada_catchpoint::~ada_catchpoint): ... this.
6408 (dtor_catch_exception): Remove.
6409 (dtor_catch_exception_unhandled): Remove.
6410 (dtor_catch_assert): Remove.
6411 (create_ada_exception_catchpoint): Remove reference to base
6412 field.
6413 (initialize_ada_catchpoint_ops): Don't set dtors.
6414 * break-catch-sig.c (struct signal_catchpoint): Inherit from
6415 breakpoint.
6416 <~signal_catchpoint>: New.
6417 <base>: Remove.
6418 (signal_catchpoint_dtor): Change to ...
6419 (signal_catchpoint::~signal_catchpoint): ... this.
6420 (create_signal_catchpoint): Remove reference to base field.
6421 (initialize_signal_catchpoint_ops): Don't set dtor.
6422 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
6423 from breakpoint.
6424 <~syscall_catchpoint>: New.
6425 <base>: Remove.
6426 (dtor_catch_syscall): Change to ...
6427 (syscall_catchpoint::~syscall_catchpoint): ... this.
6428 (create_syscall_event_catchpoint): Remove reference to base
6429 field.
6430 (initialize_syscall_catchpoint_ops): Don't set dtor.
6431 * break-catch-throw.c (struct exception_catchpoint): Inherit
6432 from breakpoint.
6433 <~exception_catchpoint>: New.
6434 <base>: Remove.
6435 (dtor_exception_catchpoint): Change to ...
6436 (exception_catchpoint::~exception_catchpoint): ... this.
6437 (handle_gnu_v3_exceptions): Remove reference to base field.
6438 (initialize_throw_catchpoint_ops): Don't set dtor.
6439 * ctf.c (ctf_get_traceframe_address): Remove reference to base
6440 field.
6441 * remote.c (remote_get_tracepoint_status): Likewise.
6442 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
6443 * tracefile.c (tracefile_fetch_registers): Likewise.
6444 * tracepoint.c (actions_command): Likewise.
6445 (validate_actionline): Likewise.
6446 (tfind_1): Likewise.
6447 (get_traceframe_location): Likewise.
6448 (find_matching_tracepoint_location): Likewise.
6449 (parse_tracepoint_status): Likewise.
6450 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
6451
6452 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
6453
6454 * breakpoint.c (struct longjmp_breakpoint): New struct.
6455 (is_tracepoint_type): Change return type to bool.
6456 (is_longjmp_type): New function.
6457 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
6458 (set_raw_breakpoint_without_location): Use
6459 new_breakpoint_from_type.
6460 (set_raw_breakpoint): Likewise.
6461
6462 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
6463
6464 * breakpoint.c (new_breakpoint_from_type): New function.
6465 (create_breakpoint_sal): Use new_breakpoint_from_type and
6466 unique_ptr.
6467 (create_breakpoint): Likewise.
6468
6469 2017-05-31 Simon Marchi <simon.marchi@ericsson.com>
6470
6471 * memattr.c (mem_info_command): Rename to ...
6472 (info_mem_command): ... this.
6473 (mem_enable_command): Rename to ...
6474 (enable_mem_command): ... this.
6475 (mem_disable_command): Rename to ...
6476 (disable_mem_command): ... this.
6477 (mem_delete_command): Rename to ...
6478 (delete_mem_command): ... this.
6479 (_initialize_mem): Adjust function names.
6480
6481 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
6482
6483 * btrace.c (handle_pt_insn_events): New.
6484 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
6485 STATUS. Split into this and ...
6486 (handle_pt_insn_event_flags): ... this.
6487
6488 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
6489
6490 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
6491 and struct pt_insn.resynced.
6492 * configure: Regenerated.
6493 * config.in: Regenerated.
6494
6495 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6496
6497 * btrace.c (ftrace_find_call_by_number): New function.
6498 (ftrace_new_function): Store objects, not pointers.
6499 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
6500 ftrace_new_gap, ftrace_update_function,
6501 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
6502 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
6503 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
6504 btrace_ends_with_single_insn, btrace_call_get): Account for
6505 btrace_thread_info::functions now storing objects.
6506 * btrace.h (struct btrace_thread_info): Add constructor.
6507 (struct btrace_thread_info) <functions>: Make std::vector.
6508 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
6509 Initialize with default values.
6510 * record-btrace.c (record_btrace_frame_sniffer): Account for
6511 btrace_thread_info::functions now storing objects.
6512
6513 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6514
6515 * btrace.c: Remove typedef bfun_s.
6516 (ftrace_new_gap): Directly add gaps to the list of gaps.
6517 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
6518 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
6519 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
6520 instead of gdb VEC.
6521
6522 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6523
6524 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
6525 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
6526 with btrace_thread_info::next_segment and
6527 btrace_thread_info::prev_segment.
6528 * btrace.h: Remove struct btrace_func_link.
6529 (struct btrace_function): Replace pair of function segment pointers
6530 with pair of indices.
6531 * python/py-record-btrace.c (btpy_call_prev_sibling,
6532 btpy_call_next_sibling): Replace references to
6533 btrace_thread_info::segment with btrace_thread_info::next_segment and
6534 btrace_thread_info::prev_segment.
6535 * record-btrace.c (record_btrace_frame_this_id): Use
6536 btrace_find_call_by_number.
6537
6538 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6539
6540 * btrace.c (ftrace_new_function, ftrace_fixup_level,
6541 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
6542 btrace_insn_next, btrace_insn_prev): Remove references to
6543 btrace_thread_info::flow.
6544 * btrace.h (struct btrace_function): Remove FLOW.
6545
6546 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6547
6548 * btrace.c (ftrace_find_call_by_number): New function.
6549 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
6550 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
6551 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
6552 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
6553 index.
6554 * btrace.h (struct btrace_function): Turn UP into an index.
6555 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
6556 as an index.
6557 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
6558 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
6559 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
6560
6561 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6562
6563 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
6564 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
6565 ftrace_update_function, ftrace_compute_global_level_offset,
6566 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
6567 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
6568 btrace_insn_end, btrace_is_empty): Remove references to
6569 btrace_thread_info::begin and btrace_thread_info::end.
6570 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
6571 (struct btrace_thread_info) <functions>: Adjust comment.
6572 * record-btrace.c (record_btrace_start_replaying): Remove reference to
6573 btrace_thread_info::begin.
6574
6575 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6576
6577 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
6578 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
6579 ftrace_update_function): Remove arguments that implicitly were always
6580 BTINFO->END.
6581 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
6582 Don't pass BTINFO->END.
6583
6584 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6585
6586 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
6587 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
6588 btrace_find_insn_by_number): Replace function segment pointer with
6589 index.
6590 (btrace_insn_cmp): Simplify.
6591 * btrace.h: (struct btrace_insn_iterator) Rename index to
6592 insn_index. Replace function segment pointer with index into function
6593 segment vector.
6594 * record-btrace.c (record_btrace_call_history): Replace function
6595 segment pointer use with index.
6596 (record_btrace_frame_sniffer): Retrieve function call segment through
6597 vector.
6598 (record_btrace_set_replay): Remove defunc't safety check.
6599
6600 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6601
6602 * btrace.c (btrace_ends_with_single_insn): New function.
6603 (btrace_call_get, btrace_call_number, btrace_call_begin,
6604 btrace_call_end, btrace_call_next, btrace_call_prev,
6605 btrace_find_call_by_number): Use index into call segment vector
6606 instead of pointer.
6607 (btrace_call_cmp): Simplify.
6608 * btrace.h (struct btrace_call_iterator): Replace function call segment
6609 pointer with index into vector.
6610 * record-btrace.c (record_btrace_call_history): Use index instead of
6611 pointer.
6612
6613 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6614
6615 * btrace.c (btrace_insn_begin, btrace_insn_end,
6616 btrace_find_insn_by_number): Add btinfo to iterator.
6617 * btrace.h (struct btrace_insn_iterator): Add btinfo.
6618
6619 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6620
6621 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
6622 and save pointers directly.
6623 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
6624 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
6625 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
6626 changed signature of functions.
6627 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
6628 (btrace_fetch): Remove code that adds btrace_function pointers to
6629 vector of btrace_functions.
6630 (btrace_clear): Simplify freeing vector of btrace_functions.
6631
6632 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6633
6634 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
6635 Replace VEC_* with std::vector functions.
6636 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
6637 (struct btrace_thread_info)<functions>: Change type to std::vector.
6638
6639 2017-05-30 Simon Marchi <simon.marchi@ericsson.com>
6640
6641 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
6642 "Removed targets and native configurations" up. Merge duplicate
6643 "New commands" sub-sections. Add "New options" sub-sections.
6644
6645 2017-05-26 Alan Hayward <alan.hayward@arm.com>
6646
6647 * defs.h (copy_integer_to_size): New declaration.
6648 * findvar.c (copy_integer_to_size): New function.
6649 (do_cint_test): New selftest function.
6650 (copy_integer_to_size_test): Likewise.
6651 (_initialize_findvar): Likewise.
6652 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
6653 (mips_fbsd_collect_reg): Use raw_collect_integer.
6654 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
6655 (mips64_fill_gregset): Use raw_collect_integer
6656 (mips64_fill_fpregset): Use raw_supply_integer.
6657 * regcache.c (regcache::raw_supply_integer): New function.
6658 (regcache::raw_collect_integer): Likewise.
6659 * regcache.h: (regcache::raw_supply_integer): New declaration.
6660 (regcache::raw_collect_integer): Likewise.
6661
6662 2017-05-24 Yao Qi <yao.qi@linaro.org>
6663
6664 * Makefile.in (SFILES): Add gdbarch-selftests.c.
6665 (COMMON_OBS): Add gdbarch-selftests.o.
6666 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
6667 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
6668 * gdbarch-selftests.c: New file.
6669 * regcache.h (regcache) <~regcache>: Mark it virtual if
6670 GDB_SELF_TEST.
6671 <raw_write>: Likewise.
6672
6673 2017-05-24 Yao Qi <yao.qi@linaro.org>
6674
6675 * regcache.c (current_regcache): Change it to
6676 regcache::current_regcache.
6677 (regcache_observer_target_changed): Update.
6678 (regcache_thread_ptid_changed): Make it a regcache static
6679 method.
6680 (regcache_thread_ptid_changed): Update.
6681 (class regcache_access): New.
6682 (current_regcache_test): Update.
6683 (_initialize_regcache): Update.
6684 * regcache.h: Include forward_list.
6685 (regcache): Declare regcache_thread_ptid_changed and declare
6686 registers_changed_ptid as friend.
6687
6688 2017-05-24 Yao Qi <yao.qi@linaro.org>
6689
6690 * i387-tdep.c (i387_register_to_value): Use register_size
6691 instead of TYPE_LENGTH.
6692 * m68k-tdep.c (m68k_register_to_value): Likewise.
6693
6694 2017-05-24 Yao Qi <yao.qi@linaro.org>
6695
6696 * i387-tdep.c (i387_convert_register_p): Return false if type
6697 code isn't TYPE_CODE_FLT.
6698
6699 2017-05-24 Yao Qi <yao.qi@linaro.org>
6700
6701 * alpha-tdep.c (alpha_convert_register_p): Return true if type
6702 length is 4.
6703 (alpha_register_to_value): Remove type length check.
6704 (alpha_value_to_register): Likewise.
6705
6706 2017-05-24 Yao Qi <yao.qi@linaro.org>
6707
6708 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
6709 TYPE_CODE_FLT.
6710
6711 2017-05-24 Yao Qi <yao.qi@linaro.org>
6712
6713 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
6714 TYPE_CODE_FLT or not.
6715
6716 2017-05-24 Yao Qi <yao.qi@linaro.org>
6717
6718 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
6719 * avr-tdep.c (avr_gdbarch_init): Likewise.
6720 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
6721 * cris-tdep.c (cris_gdbarch_init): Likewise.
6722 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
6723 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
6724 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
6725 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
6726 * mep-tdep.c (mep_gdbarch_init): Likewise.
6727 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
6728 * mips-tdep.c (mips_gdbarch_init): Likewise.
6729 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
6730 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
6731 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
6732 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
6733 * v850-tdep.c (v850_gdbarch_init): Likewise.
6734
6735 2017-05-24 Yao Qi <yao.qi@linaro.org>
6736
6737 * selftest-arch.c (tests_with_arch): Call registers_changed
6738 and reinit_frame_cache.
6739 * selftest.c (run_self_tests): Likewise.
6740
6741 2017-05-24 Yao Qi <yao.qi@linaro.org>
6742
6743 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
6744 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
6745
6746 2017-05-24 Yao Qi <yao.qi@linaro.org>
6747
6748 * rl78-tdep.c (rl78_gdbarch_init): Don't call
6749 set_gdbarch_print_insn.
6750
6751 2017-05-24 Yao Qi <yao.qi@linaro.org>
6752
6753 * h8300-tdep.c (h8300_gdbarch_init): Don't call
6754 set_gdbarch_print_insn.
6755
6756 2017-05-24 Yao Qi <yao.qi@linaro.org>
6757
6758 * alpha-tdep.c (alpha_gdbarch_init): Don't call
6759 set_gdbarch_print_insn.
6760 * arc-tdep.c (arc_gdbarch_init): Likewise.
6761 * arch-utils.c: include dis-asm.h.
6762 (default_print_insn): New function.
6763 * arch-utils.h (default_print_insn): Declare.
6764 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
6765 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
6766 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
6767 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
6768 * frv-tdep.c (frv_gdbarch_init): Likewise.
6769 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
6770 * gdbarch.sh (print_insn): Use default_print_insn.
6771 * gdbarch.c: Regenerated.
6772 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
6773 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
6774 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
6775 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
6776 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
6777 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
6778 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
6779 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
6780 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
6781 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
6782 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
6783 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
6784 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
6785 * mt-tdep.c (mt_gdbarch_init): Likewise.
6786 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
6787 * nios2-tdep.c (nios2_print_insn): Remove.
6788 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
6789 * rx-tdep.c (rx_gdbarch_init): Likewise.
6790 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
6791 * score-tdep.c (score_print_insn): Remove.
6792 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
6793 * sh-tdep.c (sh_gdbarch_init): Likewise.
6794 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
6795 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
6796 * tic6x-tdep.c (tic6x_print_insn): Remove.
6797 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
6798 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
6799 * v850-tdep.c (v850_gdbarch_init): Likewise.
6800 * vax-tdep.c (vax_gdbarch_init): Likewise.
6801 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
6802 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
6803
6804 2017-05-23 John Baldwin <jhb@FreeBSD.org>
6805
6806 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
6807 (MIPS_FP0_REGNUM): Remove.
6808 (MIPS_FSR_REGNUM): Remove.
6809 (mips_fbsd_supply_fpregs): Use mips_regnum.
6810 (mips_fbsd_supply_gregs): Likewise.
6811 (mips_fbsd_collect_fpregs): Likewise.
6812 (mips_fbsd_collect_gregs): Likewise.
6813
6814 2017-05-23 John Baldwin <jhb@FreeBSD.org>
6815
6816 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
6817 (getpfpregs_supplies): New function.
6818 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
6819 getfpregs_supplies.
6820 (mips_fbsd_store_inferior_registers): Likewise.
6821
6822 2017-05-22 Pedro Alves <palves@redhat.com>
6823
6824 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
6825 maintainer.
6826
6827 2017-05-22 Alan Hayward <alan.hayward@arm.com>
6828
6829 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
6830 (store_register): Likewise.
6831 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
6832 (get_decimal_float_return_value): Likewise.
6833 (do_ppc_sysv_return_value): Likewise.
6834 (ppc64_sysv_abi_push_integer): Likewise.
6835 (ppc64_sysv_abi_push_freg): Likewise.
6836 (ppc64_sysv_abi_return_value_base): Likewise.
6837 (ppc64_sysv_abi_return_value): Likewise.
6838 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
6839 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
6840 * rs6000-nat.c: Likewise.
6841 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
6842 (rs6000_value_to_register): Likewise.
6843 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
6844
6845 2017-05-21 Tom Tromey <tom@tromey.com>
6846
6847 PR rust/21466:
6848 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
6849 arrays as "[T]", not "[T; ]".
6850
6851 2017-05-19 Tom Tromey <tom@tromey.com>
6852
6853 PR rust/21484:
6854 * rust-lang.c (exp_descriptor_rust): New function.
6855 (rust_language_defn): Use it.
6856 * p-lang.c (pascal_language_defn): Update.
6857 * opencl-lang.c (opencl_language_defn): Update.
6858 * objc-lang.c (objc_language_defn): Update.
6859 * m2-lang.c (m2_language_defn): Update.
6860 * language.h (struct language_defn)
6861 <la_watch_location_expression>: New member.
6862 * language.c (unknown_language_defn, auto_language_defn)
6863 (local_language_defn): Update.
6864 * go-lang.c (go_language_defn): Update.
6865 * f-lang.c (f_language_defn): Update.
6866 * d-lang.c (d_language_defn): Update.
6867 * c-lang.h (c_watch_location_expression): Declare.
6868 * c-lang.c (c_watch_location_expression): New function.
6869 (c_language_defn, cplus_language_defn, asm_language_defn)
6870 (minimal_language_defn): Use it.
6871 * breakpoint.c (watch_command_1): Call
6872 la_watch_location_expression.
6873 * ada-lang.c (ada_language_defn): Update.
6874
6875 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6876
6877 PR tui/21482
6878 * gdb_curses.h (NOMACROS): Define.
6879 (NCURSES_NOMACROS): Define.
6880
6881 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6882
6883 PR tui/21482
6884 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
6885 arg to char *.
6886 * tui/tui-wingeneral.c (box_win): Likewise.
6887 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
6888 (tui_show_source_line): Likewise.
6889 (tui_show_exec_info_content): Likewise.
6890
6891 2017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
6892
6893 * sparc-tdep.c (sparc_structure_return_p)
6894 (sparc_arg_on_registers_p): New functions.
6895 (sparc32_store_arguments): Use them.
6896 * sparc64-tdep.c (sparc64_16_byte_align_p)
6897 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
6898 Handle TYPE_CODE_ARRAY.
6899
6900 2017-05-17 Yao Qi <yao.qi@linaro.org>
6901
6902 * cli/cli-decode.c (add_alias_cmd): New function.
6903 * command.h (add_alias_cmd): Declare.
6904 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
6905 instead call add_alias_cmd.
6906
6907 2017-05-17 Pedro Alves <palves@redhat.com>
6908
6909 * Makefile.in (nat_extra_makefile_frag): Rename to ...
6910 (nat_makefile_frag): ... this. All references updated.
6911 * configure.ac: Likewise.
6912 * configure.nat: Likewise. Enhance comments.
6913 * configure: Regenerate.
6914
6915 2017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6916
6917 * procfs.c (procfs_create_inferior): Change prototype to match
6918 definition.
6919
6920 2017-05-13 Eli Zaretskii <eliz@gnu.org>
6921
6922 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
6923 C++ compiler warning.
6924
6925 2017-05-12 Tom Tromey <tom@tromey.com>
6926
6927 PR rust/21483:
6928 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
6929 recurse, just call value_struct_elt directly.
6930
6931 2017-05-12 Tom Tromey <tom@tromey.com>
6932
6933 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
6934 OP_RUST_ARRAY>: Fix.
6935
6936 2017-05-12 Tom Tromey <tom@tromey.com>
6937
6938 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
6939
6940 2017-05-09 Yao Qi <yao.qi@linaro.org>
6941
6942 * regcache.c: Include <forward_list>.
6943 (struct regcache_list): Remove.
6944 (current_regcache): Update.
6945 (get_thread_arch_aspace_regcache): Update for std::forward_list.
6946 (regcache_thread_ptid_changed): Likewise.
6947 (registers_changed_ptid): Likewise.
6948 (current_regcache_size): Likewise.
6949
6950 2017-05-09 Yao Qi <yao.qi@linaro.org>
6951
6952 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
6953 (current_regcache_size): New function.
6954 (current_regcache_test): New function.
6955 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
6956
6957 2017-05-08 Alan Hayward <alan.hayward@arm.com>
6958
6959 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
6960 (print_gp_register_row): Use get_frame_register_value.
6961
6962 2017-05-08 Alan Hayward <alan.hayward@arm.com>
6963
6964 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
6965 (mips_supply_fpregset): Likewise.
6966 (mips64_supply_gregset): Likewise.
6967
6968 2017-05-08 Alan Hayward <alan.hayward@arm.com>
6969
6970 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
6971 regcache->raw_supply_zeroed.
6972
6973 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
6974
6975 * configure.nat: Rearrange 'case' statements to match
6976 host before cpu.
6977
6978 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
6979
6980 * Makefile.in: Remove "@host_makefile_frag@". Add variables
6981 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
6982 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
6983 "@nat_extra_makefile_frag@".
6984 (Makefile): Remove dependency on "@frags@".
6985 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
6986 (data-directory/Makefile): Likewise.
6987 * config/aarch64/linux.mh: Deleted; moved contents to
6988 "gdb/configure.nat".
6989 * config/alpha/alpha-linux.mh: Likewise.
6990 * config/alpha/nbsd.mh: Likewise.
6991 * config/arm/linux.mh: Likewise.
6992 * config/arm/nbsdelf.mh: Likewise.
6993 * config/i386/cygwin.mh: Likewise.
6994 * config/i386/cygwin64.mh: Likewise.
6995 * config/i386/darwin.mh: Likewise.
6996 * config/i386/fbsd.mh: Likewise.
6997 * config/i386/fbsd64.mh: Likewise.
6998 * config/i386/go32.mh: Likewise.
6999 * config/i386/i386gnu.mh: Likewise.
7000 * config/i386/i386sol2.mh: Likewise.
7001 * config/i386/linux.mh: Likewise.
7002 * config/i386/linux64.mh: Likewise.
7003 * config/i386/mingw.mh: Likewise.
7004 * config/i386/mingw64.mh: Likewise.
7005 * config/i386/nbsd64.mh: Likewise.
7006 * config/i386/nbsdelf.mh: Likewise.
7007 * config/i386/nto.mh: Likewise.
7008 * config/i386/obsd.mh: Likewise.
7009 * config/i386/obsd64.mh: Likewise.
7010 * config/i386/sol2-64.mh: Likewise.
7011 * config/ia64/linux.mh: Likewise.
7012 * config/m32r/linux.mh: Likewise.
7013 * config/m68k/linux.mh: Likewise.
7014 * config/m68k/nbsdelf.mh: Likewise.
7015 * config/m68k/obsd.mh: Likewise.
7016 * config/m88k/obsd.mh: Likewise.
7017 * config/mips/fbsd.mh: Likewise.
7018 * config/mips/linux.mh: Likewise.
7019 * config/mips/nbsd.mh: Likewise.
7020 * config/mips/obsd64.mh: Likewise.
7021 * config/pa/linux.mh: Likewise.
7022 * config/pa/nbsd.mh: Likewise.
7023 * config/pa/obsd.mh: Likewise.
7024 * config/powerpc/aix.mh: Likewise.
7025 * config/powerpc/fbsd.mh: Likewise.
7026 * config/powerpc/linux.mh: Likewise.
7027 * config/powerpc/nbsd.mh: Likewise.
7028 * config/powerpc/obsd.mh: Likewise.
7029 * config/powerpc/ppc64-linux.mh: Likewise.
7030 * config/powerpc/spu-linux.mh: Likewise.
7031 * config/s390/linux.mh: Likewise.
7032 * config/sh/nbsd.mh: Likewise.
7033 * config/sparc/fbsd.mh: Likewise.
7034 * config/sparc/linux.mh: Likewise.
7035 * config/sparc/linux64.mh: Likewise.
7036 * config/sparc/nbsd64.mh: Likewise.
7037 * config/sparc/nbsdelf.mh: Likewise.
7038 * config/sparc/obsd64.mh: Likewise.
7039 * config/sparc/sol2.mh: Likewise.
7040 * config/tilegx/linux.mh: Likewise.
7041 * config/vax/nbsdelf.mh: Likewise.
7042 * config/vax/obsd.mh: Likewise.
7043 * config/xtensa/linux.mh: Likewise.
7044 * config/i386/i386gnu.mn: New file, with excerpts from
7045 "config/i386/i386gnu.mh".
7046 * configure: Regenerate.
7047 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
7048 *.mh files under "gdb/config".
7049 * configure.nat: New file, with contents from the
7050 "gdb/config/*/*.mh" files.
7051
7052 2017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
7053
7054 * btrace.c (btrace_clear): Free insn vector.
7055
7056 2017-05-05 Pedro Alves <palves@redhat.com>
7057
7058 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
7059 * configure: Regenerate.
7060
7061 2017-05-04 Pedro Alves <palves@redhat.com>
7062
7063 * Makefile.in (SFILES): Add progspace-and-thread.c.
7064 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
7065 (COMMON_OBS): Add progspace-and-thread.o.
7066 * breakpoint.c: Include "progspace-and-thread.h".
7067 (update_inserted_breakpoint_locations)
7068 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
7069 Use scoped_restore_current_pspace_and_thread.
7070 (create_std_terminate_master_breakpoint): Use
7071 scoped_restore_current_program_space.
7072 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
7073 (print_breakpoint_location): Use
7074 scoped_restore_current_program_space.
7075 (bp_loc_is_permanent): Use
7076 scoped_restore_current_pspace_and_thread.
7077 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
7078 (download_tracepoint_locations): Use
7079 scoped_restore_current_pspace_and_thread.
7080 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
7081 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
7082 (enum step_over_calls_kind): Moved from inferior.h.
7083 (class scoped_restore_current_thread): New class.
7084 * gdbthread.h (make_cleanup_restore_current_thread): Delete
7085 declaration.
7086 (scoped_restore_current_thread): New class.
7087 * infcmd.c: Include "common/gdb_optional.h".
7088 (continue_1, proceed_after_attach): Use
7089 scoped_restore_current_thread.
7090 (notice_new_inferior): Use scoped_restore_current_thread.
7091 * inferior.c: Include "progspace-and-thread.h".
7092 (restore_inferior, save_current_inferior): Delete.
7093 (add_inferior_command, clone_inferior_command): Use
7094 scoped_restore_current_pspace_and_thread.
7095 * inferior.h (scoped_restore_current_inferior): New class.
7096 * infrun.c: Include "progspace-and-thread.h" and
7097 "common/gdb_optional.h".
7098 (follow_fork_inferior): Use
7099 scoped_restore_current_pspace_and_thread.
7100 (scoped_restore_exited_inferior): New class.
7101 (handle_vfork_child_exec_or_exit): Use
7102 scoped_restore_exited_inferior,
7103 scoped_restore_current_pspace_and_thread,
7104 scoped_restore_current_thread and scoped_restore.
7105 (fetch_inferior_event): Use scoped_restore_current_thread.
7106 * linespec.c (decode_line_full, decode_line_1): Use
7107 scoped_restore_current_program_space.
7108 * mi/mi-main.c: Include "progspace-and-thread.h".
7109 (exec_continue): Use scoped_restore_current_thread.
7110 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
7111 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
7112 * proc-service.c (ps_pglobal_lookup): Use
7113 scoped_restore_current_program_space.
7114 * progspace-and-thread.c: New file.
7115 * progspace-and-thread.h: New file.
7116 * progspace.c (release_program_space, clone_program_space): Use
7117 scoped_restore_current_program_space.
7118 (restore_program_space, save_current_program_space)
7119 (save_current_space_and_thread): Delete.
7120 (switch_to_program_space_and_thread): Moved to
7121 progspace-and-thread.c.
7122 * progspace.h (save_current_program_space)
7123 (save_current_space_and_thread): Delete declarations.
7124 (scoped_restore_current_program_space): New class.
7125 * remote.c (remote_btrace_maybe_reopen): Use
7126 scoped_restore_current_thread.
7127 * symtab.c: Include "progspace-and-thread.h".
7128 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
7129 * thread.c (print_thread_info_1): Use
7130 scoped_restore_current_thread.
7131 (struct current_thread_cleanup): Delete.
7132 (do_restore_current_thread_cleanup)
7133 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
7134 (scoped_restore_current_thread::~scoped_restore_current_thread):
7135 ... this new dtor.
7136 (make_cleanup_restore_current_thread): Rename/convert to ...
7137 (scoped_restore_current_thread::scoped_restore_current_thread):
7138 ... this new ctor.
7139 (thread_apply_all_command): Use scoped_restore_current_thread.
7140 (thread_apply_command): Use scoped_restore_current_thread.
7141 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
7142 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
7143
7144 2017-05-04 Pedro Alves <palves@redhat.com>
7145
7146 * thread.c (make_cleanup_restore_current_thread): Move
7147 find_thread_ptid call before the is_stopped call. Assert that the
7148 thread is found. Replace is_stopped call by checking the thread's
7149 state directly. Remove unnecessary NULL-thread check.
7150
7151 2017-05-04 Pedro Alves <palves@redhat.com>
7152
7153 * corelow.c (thread_section_name): New class.
7154 (get_core_register_section, get_core_siginfo): Use it.
7155
7156 2017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
7157
7158 * corelow.c (sniff_core_bfd): Remove extra semicolon.
7159 (get_core_register_section): Remove xfree of NULL pointer.
7160
7161 2017-05-03 Alan Hayward <alan.hayward@arm.com>
7162
7163 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
7164 * regcache.c (regcache::raw_supply_zeroed): New function.
7165 * regcache.h (regcache::raw_supply_zeroed): New declaration.
7166
7167 2017-05-03 Simon Marchi <simon.marchi@ericsson.com>
7168
7169 * gdbarch.sh: Remove commented out definition of
7170 TARGET_CHAR_BIT.
7171 * gdbarch.h: Re-generate.
7172
7173 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
7174
7175 * configure: Regenerate.
7176
7177 2017-05-02 Simon Marchi <simon.marchi@ericsson.com>
7178
7179 * solib-target.c (solib_target_relocate_section_addresses):
7180 Remove num_section_bases, num_bases, segment_bases variables.
7181
7182 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
7183
7184 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
7185
7186 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
7187
7188 * solib-target.c: Include <vector>
7189 (struct lm_info_target) <~lm_info_target>: Remove.
7190 <segment_bases, section_bases>: Change type to
7191 std::vector<CORE_ADDR>.
7192 (library_list_start_segment, library_list_start_section,
7193 library_list_end_library,
7194 solib_target_relocate_section_addresses): Adjust.
7195
7196 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
7197
7198 * gdbarch.sh (software_single_step): Change return type to
7199 std::vector<CORE_ADDR>.
7200 * gdbarch.c, gdbarch.h: Re-generate.
7201 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
7202 Adjust.
7203 (arm_deal_with_atomic_sequence_raw): Adjust.
7204 (thumb_get_next_pcs_raw): Adjust.
7205 (arm_get_next_pcs_raw): Adjust.
7206 (arm_get_next_pcs): Adjust.
7207 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
7208 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
7209 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
7210 (alpha_software_single_step): Adjust.
7211 * alpha-tdep.h (alpha_software_single_step): Adjust.
7212 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
7213 * arm-tdep.c (arm_software_single_step): Adjust.
7214 (arm_breakpoint_kind_from_current_state): Adjust.
7215 * arm-tdep.h (arm_software_single_step): Adjust.
7216 * breakpoint.c (insert_single_step_breakpoint): Adjust.
7217 * cris-tdep.c (cris_software_single_step): Adjust.
7218 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
7219 (micromips_deal_with_atomic_sequence): Adjust.
7220 (deal_with_atomic_sequence): Adjust.
7221 (mips_software_single_step): Adjust.
7222 * mips-tdep.h (mips_software_single_step): Adjust.
7223 * moxie-tdep.c (moxie_software_single_step): Adjust.
7224 * nios2-tdep.c (nios2_software_single_step): Adjust.
7225 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
7226 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
7227 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
7228 * s390-linux-tdep.c (s390_software_single_step): Adjust.
7229 * sparc-tdep.c (sparc_software_single_step): Adjust.
7230 * spu-tdep.c (spu_software_single_step): Adjust.
7231 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
7232
7233 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
7234
7235 * gdbarch.sh: Use semi-colon as field separator instead of colon.
7236 * gdbarch.h: Re-generate.
7237
7238 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
7239
7240 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
7241 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
7242 * python/py-instruction.c, python/py-instruction.h: New file.
7243 * python/py-record.c: Add py-instruction.h include.
7244 (gdbpy_initialize_record): Make gdb.Instruction a super class of
7245 gdb.RecordInstruction.
7246 * python/python-internal.h: Add gdbpy_initialize_instruction
7247 declaration.
7248 * python/python.c (do_start_initialization): Add
7249 gdbpy_initialize_instruction.
7250
7251 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
7252
7253 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
7254 Remove.
7255 (btrace_func_from_recpy_func): New function.
7256 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
7257 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
7258 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
7259 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
7260 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
7261 Also, use new helper functions.
7262 (btpy_list_item): Use new helper functions.
7263 (recpy_bt_function_call_history): Use new type name.
7264 (btpy_call_getset): Remove.
7265 (gdbpy_initialize_btrace): Remove code to initialize
7266 gdb.BtraceFunctionCall.
7267 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
7268 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
7269 recpy_bt_func_prev, recpy_bt_func_next): New export.
7270 * python/py-record.c (recpy_func_type): New static object.
7271 (recpy_func_new, recpy_func_level, recpy_func_symbol,
7272 recpy_func_instructions, recpy_func_up, recpy_func_prev,
7273 recpy_func_next): New function.
7274 (recpy_element_hash, recpy_element_richcompare): Updated comment.
7275 (recpy_func_getset): New static object.
7276 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
7277 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
7278
7279 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
7280
7281 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
7282 (btpy_object, btpy_insn_type, btpy_new): Remove.
7283 (btpy_list_object): Use gdb.RecordInstruction type instead of
7284 gdb.BtraceInstruction type.
7285 (btrace_insn_from_recpy_insn): New function.
7286 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
7287 btpy_new.
7288 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
7289 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
7290 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
7291 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
7292 instead of btpy_object.
7293 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
7294 btpy_insn_data, btpy_insn_decode): Rename to ...
7295 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
7296 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
7297 recpy_bt_insn_decode): This. Also, use new helper functions.
7298 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
7299 recpy_insn_type.
7300 (btpy_insn_getset): Remove.
7301 (gdbpy_initialize_btrace): Remove code to initialize
7302 gdb.BtraceInstruction. Use recpy_element_object.
7303 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
7304 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
7305 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
7306 * python/py-record.c (recpy_insn_type): New static object.
7307 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
7308 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
7309 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
7310 New function.
7311 (recpy_insn_getset): New static object.
7312 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
7313 * python/py-record.h (recpy_element_object): New typedef.
7314 (recpy_insn_type, recpy_insn_new): New export.
7315
7316 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
7317
7318 * py-record-btrace.c (btpy_insn_new): Removed.
7319 (btpy_insn_or_gap_new): New function.
7320 (btpy_insn_error): Removed.
7321 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
7322 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
7323 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
7324 btpy_insn_or_gap_new instead of btpy_insn_new.
7325 (btpy_insn_getset): Remove btpy_insn_error.
7326 * py-record.c (recpy_gap_type): New static object.
7327 (recpy_gap_object): New typedef.
7328 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
7329 recpy_gap_reason_string): New function.
7330 (recpy_gap_getset): New static object.
7331 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
7332 * py-record.h (recpy_gap_new): New export.
7333
7334 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
7335
7336 * python/py-record.c (recpy_ptid): Remove.
7337 (recpy_record_getset): Remove recpy_ptid.
7338
7339 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
7340
7341 * btrace.c (btrace_fetch): Set inferior_ptid.
7342 * python/py-record-btrace.c: Add "py-record.h" include.
7343 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
7344 recpy_bt_end, recpy_bt_instruction_history,
7345 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
7346 in gdb.Record object instead of current ptid.
7347 * python/py-record.c: Include new "py-record.h" file.
7348 (recpy_record_object): Moved to py-record.h.
7349 * python/py-record.h: New file.
7350
7351 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
7352
7353 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
7354 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
7355 indentation.
7356
7357 2017-05-01 Joel Brobecker <brobecker@adacore.com>
7358
7359 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
7360 the past maintainers section.
7361
7362 2017-04-28 Yao Qi <yao.qi@linaro.org>
7363
7364 * infcmd.c (get_return_value): Use regcache ctor, and remove
7365 cleanup.
7366
7367 2017-04-28 Yao Qi <yao.qi@linaro.org>
7368 Pedro Alves <palves@redhat.com>
7369
7370 * regcache.c (regcache::regcache): New tag dispatch ctor.
7371 (do_cooked_read): Moved above.
7372 (regcache_dup): Use the tag dispatch ctor..
7373 * regcache.h (regcache): Declare ctor, delete copy ctor and
7374 assignment operator, remove friend regcache_dup.
7375
7376 2017-04-28 Yao Qi <yao.qi@linaro.org>
7377
7378 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
7379 call method save instead of regcache_cpy.
7380 * regcache.h (struct regcache): Make regcache_dup a friend.
7381
7382 2017-04-28 Yao Qi <yao.qi@linaro.org>
7383
7384 * regcache.c (struct regcache): Move to regcache.h
7385 (regcache::arch): New method.
7386 (regcache_get_ptid): Update.
7387 (get_regcache_arch): Call arch method.
7388 (get_regcache_aspace): Call method aspace.
7389 (register_buffer): Change it to method.
7390 (regcache_save): Change it to regcache::save.
7391 (regcache_restore): Likewise.
7392 (regcache_cpy_no_passthrough): Remove the declaration.
7393 (regcache_cpy): Call methods restore and cpy_no_passthrough.
7394 (regcache_cpy_no_passthrough): Change it to method
7395 cpy_no_passthrough.
7396 (regcache_register_status): Change it to method
7397 get_register_status.
7398 (regcache_invalidate): Change it to method invalidate.
7399 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
7400 (regcache_raw_update): Change it to method raw_update.
7401 (regcache_raw_read): Likewise.
7402 (regcache_raw_read_signed): Likewise.
7403 (regcache_raw_read_unsigned): Likewise.
7404 (regcache_raw_write_signed): Likewise.
7405 (regcache_raw_write_unsigned): Likewise.
7406 (regcache_cooked_read): Likewise.
7407 (regcache_cooked_read_value): Likewise.
7408 (regcache_cooked_read_signed): Likewise.
7409 (regcache_cooked_read_unsigned): Likewise.
7410 (regcache_cooked_write_signed): Likewise.
7411 (regcache_cooked_write_unsigned): Likewise.
7412 (regcache_raw_set_cached_value): Likewise.
7413 (regcache_raw_write): Likewise.
7414 (regcache_cooked_write): Likewise.
7415 (regcache_xfer_part): Likewise.
7416 (regcache_raw_read_part): Likewise.
7417 (regcache_raw_write_part): Likewise.
7418 (regcache_cooked_read_part): Likewise.
7419 (regcache_cooked_write_part): Likewise.
7420 (regcache_raw_supply): Likewise.
7421 (regcache_raw_collect): Likewise.
7422 (regcache_transfer_regset): Likewise.
7423 (regcache_supply_regset): Likewise.
7424 (regcache_collect_regset): Likewise.
7425 (regcache_debug_print_register): Likewise.
7426 (enum regcache_dump_what): Move it to regcache.h.
7427 (regcache_dump): Change it to method dump.
7428 * regcache.h (enum regcache_dump_what): New.
7429 (class regcache): New.
7430 * target.c (target_fetch_registers): Call method
7431 debug_print_register.
7432 (target_store_registers): Likewise.
7433
7434 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7435
7436 * windows-nat.c (struct lm_info_windows): Initialize field.
7437 (windows_make_so): Allocate lm_info_windows with new.
7438 (windows_free_so): Free lm_info_windows with delete.
7439
7440 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7441
7442 * solib-darwin.c (struct lm_info_darwin): Initialize field.
7443 (darwin_current_sos): Allocate lm_info_darwin with new, remove
7444 cleanup.
7445 (darwin_free_so): Free lm_info_darwin with delete.
7446
7447 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7448
7449 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
7450 <l_addr_p>: Change type to bool.
7451 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
7452 (svr4_free_so): Free lm_info_svr4 with delete.
7453 (svr4_copy_library_list): Replace memcpy with call to copy
7454 constructor.
7455 (library_list_start_library, svr4_default_sos): Allocate
7456 lm_info_svr4 with new.
7457
7458 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7459
7460 * solib-target.c (struct lm_info_target): Add destructor,
7461 initialize fields.
7462 <name>: Change type to std::string.
7463 (library_list_start_library): Allocate lm_info_target with new.
7464 (solib_target_free_library_list): Free lm_info_target with
7465 delete.
7466 (solib_target_current_sos): Adapt to std::string.
7467 (solib_target_free_so): Free lm_info_target with delete.
7468
7469 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7470
7471 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
7472 fields.
7473 (frv_current_sos): Allocate lm_info_frv with new.
7474 (frv_relocate_main_executable): Free lm_info_frv with delete,
7475 allocate with new.
7476 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
7477
7478 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7479
7480 * solib-frv.c (struct lm_info_frv): Fix indentation.
7481
7482 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7483
7484 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
7485 map field.
7486 (dsbt_current_sos): Allocate lm_info_dsbt with new.
7487 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
7488 and allocate with new.
7489 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
7490
7491 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7492
7493 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
7494 <filename, member_name>: Change type to std::string.
7495 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
7496 (library_list_start_library): Allocate lm_info_aix with new.
7497 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
7498 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
7499 with copy constructor.
7500
7501 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7502
7503 * solist.h (struct lm_info): Remove.
7504 (struct lm_info_base): New class.
7505 (struct so_list) <lm_info>: Change type to lm_info_base *.
7506 * nto-tdep.c (struct lm_info): Remove.
7507 (lm_addr): Adjust.
7508 * solib-aix.c (struct lm_info): Rename to ...
7509 (struct lm_info_aix): ... this. Extend lm_info_base.
7510 (lm_info_p): Rename to ...
7511 (lm_info_aix_p): ... this, and adjust.
7512 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
7513 solib_aix_parse_libraries, library_list_start_library,
7514 solib_aix_free_library_list, solib_aix_parse_libraries,
7515 solib_aix_get_library_list,
7516 solib_aix_relocate_section_addresses, solib_aix_free_so,
7517 solib_aix_get_section_offsets,
7518 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
7519 Adjust.
7520 (struct solib_aix_inferior_data) <library_list>: Adjust.
7521 * solib-darwin.c (struct lm_info): Rename to ...
7522 (struct lm_info_darwin): ... this. Extend lm_info_base.
7523 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
7524 * solib-dsbt.c (struct lm_info): Rename to ...
7525 (struct lm_info_dsbt): ... this. Extend lm_info_base.
7526 (struct dsbt_info) <main_executable_lm_info): Adjust.
7527 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
7528 dsbt_relocate_section_addresses): Adjust.
7529 * solib-frv.c (struct lm_info): Rename to ...
7530 (struct lm_info_frv): ... this. Extend lm_info_base.
7531 (main_executable_lm_info): Adjust.
7532 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
7533 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
7534 find_canonical_descriptor_in_load_object,
7535 frv_fdpic_find_canonical_descriptor): Adjust.
7536 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
7537 to lm_info_svr4.
7538 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
7539 svr4_clear_so, svr4_copy_library_list,
7540 library_list_start_library, svr4_default_sos, svr4_read_so_list,
7541 svr4_current_sos, svr4_fetch_objfile_link_map,
7542 solist_update_incremental): Adjust.
7543 * solib-svr4.h (struct lm_info_svr4): Move here from
7544 solib-svr4.c.
7545 * solib-target.c (struct lm_info): Rename to ...
7546 (struct lm_info_target): ... this. Extend lm_info_base.
7547 (lm_info_p): Rename to ...
7548 (lm_info_target_p): ... this.
7549 (solib_target_parse_libraries, library_list_start_segment,
7550 library_list_start_section, library_list_start_library,
7551 library_list_end_library, solib_target_free_library_list,
7552 solib_target_current_sos, solib_target_free_so,
7553 solib_target_relocate_section_addresses): Adjust.
7554 * windows-nat.c (struct lm_info): Rename to ...
7555 (struct lm_info_windows): ... this. Extend lm_info_base.
7556 (windows_make_so, handle_load_dll, handle_unload_dll,
7557 windows_xfer_shared_libraries): Adjust.
7558
7559 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7560
7561 * solib-darwin.c (struct darwin_so_list): Remove.
7562 (darwin_current_sos): Allocate an so_list object instead of a
7563 darwin_so_list, separately allocate an lm_info object.
7564 (darwin_free_so): Free lm_info.
7565
7566 2017-04-28 John Baldwin <jhb@FreeBSD.org>
7567
7568 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
7569 with fprintf_filtered.
7570
7571 2017-04-28 Yao Qi <yao.qi@linaro.org>
7572
7573 * regcache.c (regcache::regcache): New function.
7574 (regcache::~regcache): New function.
7575 (regcache_xmalloc_1): Remove.
7576 (regcache_xmalloc): Call new regcache.
7577 (regcache_xfree): Call delete regcache.
7578 (get_thread_arch_aspace_regcache): Call new regcache.
7579
7580 2017-04-28 Yao Qi <yao.qi@linaro.org>
7581
7582 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
7583 lwp instead of ptid_get_lwp.
7584
7585 2017-04-28 Yao Qi <yao.qi@linaro.org>
7586
7587 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
7588 lwp_info instead of getting from inferior_ptid.
7589
7590 2017-04-27 Keith Seitz <keiths@redhat.com>
7591
7592 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
7593 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
7594 (CV_CONVERSION_BADNESS): Define.
7595 (rank_one_type): Remove overly restrictive rvalue reference
7596 rank checks.
7597 Add cv-qualifier checks and subranks for type equality.
7598 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
7599 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
7600 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
7601
7602 2017-04-27 Simon Marchi <simon.marchi@ericsson.com>
7603
7604 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
7605 count when creating the object.
7606
7607 2017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
7608 Ulrich Weigand <uweigand@de.ibm.com>
7609
7610 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
7611 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
7612 is used in AIX.
7613 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
7614 (process_xcoff_symbol): Likewise.
7615 (scan_xcoff_symtab): Likewise.
7616
7617 2017-04-26 Alan Hayward <alan.hayward@arm.com>
7618
7619 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
7620 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
7621 (ia64_access_reg): Use get_frame_register_unsigned.
7622 (ia64_access_rse_reg): Likewise.
7623 (ia64_libunwind_frame_prev_register): Likewise.
7624
7625 2017-04-26 Jiong Wang <jiong.wang@arm.com>
7626
7627 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
7628 * gdbarch.c: Regenerated.
7629 * gdbarch.h: Regenerated.
7630 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
7631 visibility external.
7632 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
7633 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
7634 (enum cfa_how_kind): Move to ...
7635 (struct dwarf2_frame_state_reg_info): Likewise.
7636 (struct dwarf2_frame_state): Likewise.
7637 * dwarf2-frame.h: ... here.
7638 (dwarf2_frame_state_alloc_regs): New declaration.
7639 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
7640 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
7641
7642 2017-04-26 Alan Hayward <alan.hayward@arm.com>
7643
7644 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
7645 regcache_raw_read_unsigned.
7646 (xtensa_pseudo_register_write): Likewise.
7647
7648 2017-04-26 Alan Hayward <alan.hayward@arm.com>
7649
7650 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
7651 (nds32_pseudo_register_write): Likewise.
7652
7653 2017-04-25 Yao Qi <yao.qi@linaro.org>
7654
7655 * regcache.c (struct regcache) <readonly_p>: Change its type
7656 to bool.
7657 (regcache_xmalloc_1): Update parameter type and callers update.
7658
7659 2017-04-25 Yao Qi <yao.qi@linaro.org>
7660
7661 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
7662 set_gdbarch_wchar_bit.
7663 * arm-tdep.c (arm_gdbarch_init): Likewise.
7664
7665 2017-04-25 Pedro Alves <palves@redhat.com>
7666
7667 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
7668 (BothAreRelocatable, memcopy, memmove): Don't define.
7669 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
7670 macros.
7671
7672 2017-04-25 Pedro Alves <palves@redhat.com>
7673
7674 * common/common-defs.h: Include "common/poison.h".
7675 * common/function-view.h: (Not, Or, Requires): Move to traits.h
7676 and adjust.
7677 * common/poison.h: New file.
7678 * common/traits.h: Include <type_traits>.
7679 (Not, Or, Requires): New, moved from common/function-view.h.
7680
7681 2017-04-25 Pedro Alves <palves@redhat.com>
7682
7683 * breakpoint.h (struct breakpoint): In-class initialize all
7684 fields. Make boolean fields "bool".
7685 * breakpoint.c (init_raw_breakpoint_without_location): Remove
7686 memset call and initializations no longer necessary.
7687
7688 2017-04-25 Pedro Alves <palves@redhat.com>
7689
7690 * btrace.c (pt_btrace_insn_flags): Change parameter type to
7691 reference.
7692 (pt_btrace_insn): New function.
7693 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
7694
7695 2017-04-25 Pedro Alves <palves@redhat.com>
7696
7697 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
7698 "base" field and inherit from "bp_location" instead. Add
7699 non-default ctor.
7700 (allocate_location_exception): Use new non-default ctor.
7701 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
7702 (init_bp_location): Convert to ...
7703 (bp_location::bp_location): ... this new ctor, and remove memset
7704 call.
7705 (base_breakpoint_allocate_location): Use the new non-default ctor.
7706 * breakpoint.h (bp_location): Now a class. Declare default and
7707 non-default ctors. In-class initialize all members.
7708 (init_bp_location): Remove declaration.
7709
7710 2017-04-25 Pedro Alves <palves@redhat.com>
7711
7712 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
7713 assignment operator.
7714
7715 2017-04-24 Yao Qi <yao.qi@linaro.org>
7716
7717 * doublest.c (convert_doublest_to_floatformat): Call
7718 floatformat_totalsize_bytes.
7719
7720 2017-04-22 Tom Tromey <tom@tromey.com>
7721
7722 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
7723 ui_out_emit_list.
7724 * stack.c (print_frame): Use ui_out_emit_list.
7725 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
7726 ui_out_emit_list.
7727 * mi/mi-main.c (print_one_inferior)
7728 (mi_cmd_data_list_register_names)
7729 (mi_cmd_data_list_register_values, mi_cmd_list_features)
7730 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
7731 ui_out_emit_list.
7732 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
7733 (mi_output_solib_attribs): Use ui_out_emit_list,
7734 ui_out_emit_tuple.
7735 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
7736 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
7737 (mi_cmd_stack_list_args, list_args_or_locals): Use
7738 ui_out_emit_list.
7739 * disasm.c (do_assembly_only): Use ui_out_emit_list.
7740 * breakpoint.c (print_solib_event, output_thread_groups): Use
7741 ui_out_emit_list.
7742
7743 2017-04-22 Tom Tromey <tom@tromey.com>
7744
7745 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
7746 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
7747 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
7748
7749 2017-04-22 Tom Tromey <tom@tromey.com>
7750
7751 * tracepoint.c (tvariables_info_1)
7752 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
7753
7754 2017-04-22 Tom Tromey <tom@tromey.com>
7755
7756 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
7757 annotate_arg_emitter.
7758 * breakpoint.c (print_mention_watchpoint)
7759 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
7760 * annotate.h (struct annotate_arg_emitter): New.
7761
7762 2017-04-22 Tom Tromey <tom@tromey.com>
7763
7764 * record-btrace.c (record_btrace_insn_history)
7765 (record_btrace_insn_history_range, record_btrace_call_history)
7766 (record_btrace_call_history_range): Use ui_out_emit_tuple.
7767 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
7768 ui_out_emit_tuple.
7769 * stack.c (print_frame_info): Use ui_out_emit_tuple.
7770 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
7771 * skip.c (skip_info): Use ui_out_emit_tuple.
7772 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
7773 * progspace.c (print_program_space): Use ui_out_emit_tuple.
7774 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
7775 * osdata.c (info_osdata): Use ui_out_emit_tuple.
7776 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
7777 ui_out_emit_tuple.
7778 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
7779 (output_register, mi_cmd_data_read_memory)
7780 (mi_cmd_data_read_memory_bytes, mi_load_progress)
7781 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
7782 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
7783 Use ui_out_emit_tuple.
7784 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
7785 ui_out_emit_tuple.
7786 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
7787 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
7788 * linux-thread-db.c (info_auto_load_libthread_db): Use
7789 ui_out_emit_tuple.
7790 * inferior.c (print_inferior): Use ui_out_emit_tuple.
7791 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
7792 * disasm.c (do_mixed_source_and_assembly_deprecated)
7793 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
7794 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
7795 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
7796 * breakpoint.c (print_one_breakpoint_location)
7797 (print_one_breakpoint): Use ui_out_emit_tuple.
7798 * auto-load.c (print_script, info_auto_load_cmd): Use
7799 ui_out_emit_tuple.
7800 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
7801
7802 2017-04-21 Simon Marchi <simon.marchi@ericsson.com>
7803
7804 * thread.c (print_thread_info_1): Remove dead code.
7805
7806 2017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
7807
7808 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
7809 GDB_SELF_TEST.
7810 * arm-tdep.c (selftests::arm_record_test): Likewise.
7811
7812 2017-04-21 Yao Qi <yao.qi@linaro.org>
7813
7814 * regcache.c (regcache_restore): Remove argument 2. Replace
7815 argument 3 with regcache. Get register status from
7816 src->register_status and get register contents from
7817 register_buffer (src, regnum).
7818 (regcache_cpy): Update.
7819
7820 2017-04-19 Pedro Alves <palves@redhat.com>
7821
7822 * gdbthread.h (thread): Add missing closing parenthesis in
7823 comment.
7824
7825 2017-04-19 Pedro Alves <palves@redhat.com>
7826
7827 * common/refcounted-object.h: New file.
7828 * gdbthread.h: Include "common/refcounted-object.h".
7829 (thread_info): Inherit from refcounted_object and add comments.
7830 (thread_info::incref, thread_info::decref)
7831 (thread_info::m_refcount): Delete.
7832 (thread_info::deletable): Use the refcounted_object::refcount()
7833 method.
7834 * inferior.c (current_inferior_): Add comment.
7835 (set_current_inferior): Increment/decrement refcounts.
7836 (prune_inferiors, remove_inferior_command): Skip inferiors marked
7837 not-deletable instead of comparing with the current inferior.
7838 (initialize_inferiors): Increment the initial inferior's refcount.
7839 * inferior.h (struct inferior): Forward declare.
7840 Include "common/refcounted-object.h".
7841 (current_inferior, set_current_inferior): Move declaration to
7842 before struct inferior's definition, and fix comment.
7843 (inferior): Inherit from refcounted_object. Add comments.
7844 * thread.c (switch_to_thread_no_regs): Reference the thread's
7845 inferior pointer directly instead of doing a ptid lookup.
7846 (switch_to_no_thread): New function.
7847 (switch_to_thread(thread_info *)): New function, factored out
7848 from ...
7849 (switch_to_thread(ptid_t)): ... this.
7850 (restore_current_thread): Delete.
7851 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
7852 fields, and add 'inf' field.
7853 (do_restore_current_thread_cleanup): Check whether old->inf is
7854 alive instead of looking up an inferior by ptid. Use
7855 switch_to_thread and switch_to_no_thread.
7856 (restore_current_thread_cleanup_dtor): Use old->inf directly
7857 instead of lookup up an inferior by id. Decref the inferior.
7858 Don't restore 'removable'.
7859 (make_cleanup_restore_current_thread): Same the inferior pointer
7860 in old, instead of the inferior number. Incref the inferior.
7861 Don't save/clear 'removable'.
7862
7863 2017-04-19 Pedro Alves <palves@redhat.com>
7864
7865 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7866 unittests/scoped_restore-selftests.c.
7867 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
7868 * common/scoped_restore.h (scoped_restore_base): Make "class".
7869 (scoped_restore_base::release): New public method.
7870 (scoped_restore_base::scoped_restore_base): New protected ctor.
7871 (scoped_restore_base::m_saved_var): New protected field.
7872 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
7873 scoped_restore_base base class instead of m_saved_var directly.
7874 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
7875 (scoped_restore_tmpl::scoped_restore_tmpl(const
7876 scoped_restore_tmpl<T>&)): Likewise.
7877 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
7878 method.
7879 (scoped_restore_tmpl::saved_var): New method.
7880 (scoped_restore_tmpl::m_saved_var): Delete.
7881 * inferior.h (inferior::detaching): Now a bool.
7882 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
7883 cleanup.
7884 * unittests/scoped_restore-selftests.c: New file.
7885
7886 2017-04-19 Pedro Alves <palves@redhat.com>
7887
7888 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
7889 Re-sort in alphabetic order.
7890
7891 2017-04-18 Pedro Alves <palves@redhat.com>
7892
7893 * xml-support.c (obstack_xml_printf): Delete.
7894 * xml-support.h (obstack_xml_printf): Delete.
7895
7896 2017-04-18 Pedro Alves <palves@redhat.com>
7897
7898 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
7899 vdebug, verror, body_text, start_element, end_element, name,
7900 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
7901 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
7902 is_xinclude>: Make private and add m_ prefix.
7903 (gdb_xml_parser::body_text): New method, based on ...
7904 (gdb_xml_body_text): ... this. Adjust.
7905 (gdb_xml_parser::vdebug): New method, based on ...
7906 (gdb_xml_debug): ... this. Adjust.
7907 (gdb_xml_parser::verror): New method, based on ...
7908 (gdb_xml_error): ... this. Adjust.
7909 (gdb_xml_parser::start_element): New method, based on ...
7910 (gdb_xml_start_element): ... this. Adjust.
7911 (gdb_xml_start_element_wrapper): Defer to
7912 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
7913 (gdb_xml_parser::end_element): New method, based on ...
7914 (gdb_xml_end_element_wrapper): ... this. Adjust.
7915 (gdb_xml_parser::~gdb_xml_parser): Adjust.
7916 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
7917 (gdb_xml_parser::use_dtd): New method, based on ...
7918 (gdb_xml_use_dtd): ... this. Adjust.
7919 (gdb_xml_parser::parse): New method, based on ...
7920 (gdb_xml_parse): ... this. Adjust.
7921 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
7922 (xinclude_start_include): Adjust to call the parser's name method.
7923 (xml_xinclude_default, xml_xinclude_start_doctype)
7924 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
7925 method.
7926 (xml_process_xincludes): Adjust to call parser methods.
7927 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
7928 declarations.
7929
7930 2017-04-18 Pedro Alves <palves@redhat.com>
7931
7932 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
7933 gdb::optional<std::string>.
7934 * xml-support.c: Include <string>.
7935 (scope_level::scope_level(scope_level &&))
7936 (scope_level::~scope_level): Delete.
7937 (scope_level::body): Now a std::string.
7938 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
7939 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
7940 parameter.
7941 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
7942 (xinclude_parsing_data::output): Now a std::string reference.
7943 (xinclude_start_include): Adjust.
7944 (xml_xinclude_default): Adjust.
7945 (xml_process_xincludes): Add 'output' parameter, and return bool.
7946 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
7947 and return bool.
7948 * xml-tdesc.c: Include <unordered_map> and <string>.
7949 (tdesc_xml_cache): Delete.
7950 (tdesc_xml_cache_s): Delete.
7951 (xml_cache): Now an std::unordered_map.
7952 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
7953 (target_fetch_description_xml): Change return type to
7954 gdb::optional<std::string>, and adjust.
7955 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
7956 (target_fetch_description_xml): Change return type to
7957 gdb::optional<std::string>.
7958
7959 2017-04-18 Pedro Alves <palves@redhat.com>
7960
7961 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7962 unittests/optional-selftests.c.
7963 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
7964 * unittests/optional-selftests.c: New file.
7965 * unittests/optional/assignment/1.cc: New file.
7966 * unittests/optional/assignment/2.cc: New file.
7967 * unittests/optional/assignment/3.cc: New file.
7968 * unittests/optional/assignment/4.cc: New file.
7969 * unittests/optional/assignment/5.cc: New file.
7970 * unittests/optional/assignment/6.cc: New file.
7971 * unittests/optional/assignment/7.cc: New file.
7972 * unittests/optional/cons/copy.cc: New file.
7973 * unittests/optional/cons/default.cc: New file.
7974 * unittests/optional/cons/move.cc: New file.
7975 * unittests/optional/cons/value.cc: New file.
7976 * unittests/optional/in_place.cc: New file.
7977 * unittests/optional/observers/1.cc: New file.
7978 * unittests/optional/observers/2.cc: New file.
7979
7980 2017-04-18 Pedro Alves <palves@redhat.com>
7981
7982 * common/gdb_optional.h: Include common/traits.h.
7983 (in_place_t): New type.
7984 (in_place): New constexpr variable.
7985 (optional::optional): Remove member initialization of
7986 m_instantiated.
7987 (optional::optional(in_place_t...)): New constructor.
7988 (optional::~optional): Use reset.
7989 (optional::optional(const optional&)): New.
7990 (optional::optional(const optional&&)): New.
7991 (optional::optional(T &)): New.
7992 (optional::optional(T &&)): New.
7993 (operator::operator=(const optional &)): New.
7994 (operator::operator=(optional &&)): New.
7995 (operator::operator= (const T &))
7996 (operator::operator= (T &&))
7997 (operator::emplace (Args &&... args)): Return a T&. Use reset.
7998 (operator::reset): New.
7999 (operator::m_instantiated):: Add in-class initializer.
8000 * common/traits.h: Include <type_traits>.
8001 (struct And): New types.
8002
8003 2017-04-18 Pedro Alves <palves@redhat.com>
8004
8005 * xml-support.c: Include <vector>.
8006 (scope_level::scope_level(const gdb_xml_element *))
8007 (scope_level::scope_level(scope_level&&)): New.
8008 (scope_level::~scope_level): New.
8009 (scope_level_s): Delete.
8010 (gdb_xml_parser::scopes): Now a std::vector.
8011 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
8012 Use std::vector.
8013 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
8014 scope cleanup code.
8015 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
8016 of the scopes member. Use std::vector::emplace_back.
8017
8018 2017-04-18 Pedro Alves <palves@redhat.com>
8019
8020 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
8021 a bool.
8022 (gdb_xml_end_element): Change type of first parameter.
8023 (gdb_xml_cleanup): Rename to ...
8024 (gdb_xml_parser::~gdb_xml_parser): ... this.
8025 (gdb_xml_create_parser_and_cleanup): Delete with ...
8026 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
8027 to this new ctor.
8028 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
8029 using gdb_xml_create_parser_and_cleanup.
8030 (xinclude_parsing_data): Add ctor/dtor.
8031 (xml_xinclude_cleanup): Delete.
8032 (xml_process_xincludes): Create a local xinclude_parsing_data
8033 instead of heap-allocating one. Create a local gdb_xml_parser
8034 instead of heap-allocating one with
8035 gdb_xml_create_parser_and_cleanup.
8036
8037 2017-04-18 John Baldwin <jhb@FreeBSD.org>
8038
8039 PR threads/20743
8040 * fbsd-nat.c (resume_one_thread_cb): Remove.
8041 (resume_all_threads_cb): Remove.
8042 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
8043 iterate_over_threads.
8044
8045 2017-04-17 Joel Brobecker <brobecker@adacore.com>
8046
8047 * NEWS: Create a new section for the next release branch.
8048 Rename the section of the current branch, now that it has
8049 been cut.
8050
8051 2017-04-17 Joel Brobecker <brobecker@adacore.com>
8052
8053 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
8054 * version.in: Bump version to 8.0.50.DATE-git.
8055
8056 2017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
8057
8058 PR gdb/21385
8059 * windows-nat.c (windows_create_inferior): Declare 'allargs'
8060 independently of the host, and fix build breakage on Cygwin.
8061
8062 2017-04-13 Pedro Alves <palves@redhat.com>
8063
8064 * inferior.c (free_inferior): Convert to ...
8065 (inferior::~inferior): ... this dtor.
8066 (inferior::inferior): New ctor, factored out from ...
8067 (add_inferior_silent): ... here. Allocate the inferior with a new
8068 expression.
8069 (delete_inferior): Call delete instead of free_inferior.
8070 * inferior.h (gdb_environ, continuation): Forward declare.
8071 (inferior): Now a class. Add in-class initialization to all
8072 members. Make boolean fields bool, except 'detaching'.
8073 (inferior::inferior): New explicit ctor.
8074 (inferior::~inferior): New.
8075
8076 2017-04-13 Pedro Alves <palves@redhat.com>
8077
8078 * inferior.c (init_inferior_list): Delete.
8079 * inferior.h (init_inferior_list): Delete.
8080
8081 2017-04-13 Pedro Alves <palves@redhat.com>
8082
8083 PR threads/13217
8084 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
8085 (top level): Call it twice, with different thread sets.
8086
8087 2017-04-13 Pedro Alves <palves@redhat.com>
8088
8089 * thread.c: Include <algorithm>.
8090 (thread_array_cleanup): Delete.
8091 (scoped_inc_dec_ref): New class.
8092 (live_threads_count): New function.
8093 (set_thread_refcount): Delete.
8094 (tp_array_compar_ascending): Now a bool.
8095 (tp_array_compar): Convert to a std::sort comparison function.
8096 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
8097 and live_threads_count.
8098
8099 2017-04-13 Pedro Alves <palves@redhat.com>
8100
8101 * infrun.c (follow_fork_inferior): Also switch the current
8102 inferior.
8103
8104 2017-04-13 Pedro Alves <palves@redhat.com>
8105
8106 * breakpoint.c (watch_command_1): Save watchpoint-frame info
8107 before calling create_internal_breakpoint.
8108
8109 2017-04-13 Pedro Alves <palves@redhat.com>
8110
8111 * fork-child.c (execv_argv): New class.
8112 (breakup_args): Refactored as ...
8113 (execv_argv::init_for_no_shell): .. this method of execv_argv.
8114 Copy arguments to storage and replace separators with NULL
8115 terminators in place.
8116 (escape_bang_in_quoted_argument): Adjust to return bool.
8117 (execv_argv::execv_argv): New ctor.
8118 (execv_argv::init_for_shell): New method, factored out from
8119 fork_inferior. Don't strdup strings into the vector.
8120 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
8121 Remove free_vector_argv call.
8122
8123 2017-04-13 Yao Qi <yao.qi@linaro.org>
8124
8125 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
8126 tdep->rx_psw_type.
8127
8128 2017-04-13 Yao Qi <yao.qi@linaro.org>
8129
8130 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
8131 * rx-tdep.c (rx_gdbarch_init): Likewise.
8132
8133 2017-04-13 Pedro Alves <palves@redhat.com>
8134
8135 * breakpoint.h (struct breakpoint): Reindent.
8136
8137 2017-04-13 Pedro Alves <palves@redhat.com>
8138
8139 * breakpoint.c (bp_location): Rename to ...
8140 (bp_locations): ... this. All references updated.
8141 (bp_location_count): Rename to ...
8142 (bp_locations_count): ... this. All references updated.
8143 (bp_location_placed_address_before_address_max): Rename to ...
8144 (bp_locations_placed_address_before_address_max): ... this. All
8145 references updated.
8146 (bp_location_shadow_len_after_address_max): Rename to ...
8147 (bp_locations_shadow_len_after_address_max): ... this. All
8148 references updated.
8149 (bp_location_compare_addrs): Rename to ...
8150 (bp_locations_compare_addrs): ... this. All references updated.
8151 (bp_location_compare):Rename to ...
8152 (bp_locations_compare): ... this. All references updated.
8153 (bp_location_target_extensions_update): Rename to ...
8154 (bp_locations_target_extensions_update): ... this. All references
8155 updated.
8156
8157 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
8158
8159 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
8160 * common/common.m4: Check headers 'termios.h', 'termio.h' and
8161 'sgtty.h'.
8162 * common/gdb_termios.h: New file, with parts of "terminal.h".
8163 * inflow.c: Include "gdb_termios.h".
8164 * ser-unix.c: Include "gdb_termios.h".
8165 * terminal.h: Move terminal-related defines to
8166 "common/gdb_termios.h".
8167
8168 2017-04-12 Tom Tromey <tom@tromey.com>
8169
8170 * probe.c (parse_probes): Update.
8171 * location.h (delete_event_location): Don't declare.
8172 (event_location_deleter::operator()): Update.
8173 * location.c (event_location_deleter::operator()): Rename from
8174 delete_event_location.
8175 * linespec.h (linespec_result) <location>: Change type to
8176 event_location_up.
8177 * linespec.c (canonicalize_linespec, event_location_to_sals)
8178 (decode_objc): Update.
8179 (linespec_result): Don't call delete_event_location.
8180 * breakpoint.c (create_breakpoints_sal)
8181 (bkpt_probe_create_sals_from_location)
8182 (strace_marker_create_sals_from_location): Update.
8183
8184 2017-04-12 Tom Tromey <tom@tromey.com>
8185
8186 * linespec.h (struct linespec_result): Add constructor and
8187 destructor.
8188 (init_linespec_result, destroy_linespec_result)
8189 (make_cleanup_destroy_linespec_result): Don't declare.
8190 * linespec.c (init_linespec_result): Remove.
8191 (linespec_result::~linespec_result): Rename from
8192 destroy_linespec_result. Update.
8193 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
8194 Remove.
8195 * breakpoint.c (create_breakpoint, break_range_command)
8196 (decode_location_default): Update.
8197 * ax-gdb.c (agent_command_1): Update.
8198
8199 2017-04-12 Tom Tromey <tom@tromey.com>
8200
8201 * remote.c (remote_download_tracepoint): Update.
8202 * python/py-breakpoint.c (bppy_get_location): Update.
8203 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
8204 (gdbscm_breakpoint_location): Update.
8205 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
8206 * breakpoint.h (struct breakpoint) <location, location_range_end>:
8207 Change type to event_location_up.
8208 * breakpoint.c (create_overlay_event_breakpoint)
8209 (create_longjmp_master_breakpoint)
8210 (create_std_terminate_master_breakpoint)
8211 (create_exception_master_breakpoint)
8212 (breakpoint_event_location_empty_p, print_breakpoint_location)
8213 (print_one_breakpoint_location, create_thread_event_breakpoint)
8214 (init_breakpoint_sal, create_breakpoint)
8215 (print_recreate_ranged_breakpoint, break_range_command)
8216 (init_ada_exception_breakpoint, say_where): Update.
8217 (base_breakpoint_dtor): Don't call delete_event_location.
8218 (bkpt_print_recreate, tracepoint_print_recreate)
8219 (dprintf_print_recreate, update_static_tracepoint)
8220 (breakpoint_re_set_default): Update.
8221
8222 2017-04-12 Tom Tromey <tom@tromey.com>
8223
8224 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
8225 type of "to_do". Update.
8226 (compute_stack_depth): Use std::vector.
8227
8228 2017-04-12 Tom Tromey <tom@tromey.com>
8229
8230 * printcmd.c (find_instruction_backward): Use std::vector.
8231
8232 2017-04-12 Tom Tromey <tom@tromey.com>
8233
8234 * symfile.c (objfilep): Remove typedef.
8235 (reread_symbols): Use a std::vector.
8236
8237 2017-04-12 Tom Tromey <tom@tromey.com>
8238
8239 * mi/mi-main.c (exec_direction_forward): Remove.
8240 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
8241 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
8242 scoped_restore.
8243 * guile/guile.c (guile_repl_command, guile_command)
8244 (gdbscm_execute_gdb_command): Use scoped_restore.
8245 * go-exp.y (go_parse): Use scoped_restore.
8246 * d-exp.y (d_parse): Use scoped_restore.
8247 * cli/cli-decode.c (cmd_func): Use scoped_restore.
8248 * c-exp.y (c_parse): Use scoped_restore.
8249
8250 2017-04-12 Tom Tromey <tom@tromey.com>
8251
8252 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
8253 (mi_parse): Update return type.
8254 (mi_parse_free): Remove.
8255 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
8256 (mi_parse::~mi_parse): Rename from mi_parse_free.
8257 (mi_parse_cleanup): Remove.
8258 (mi_parse): Return a unique_ptr. Use new.
8259 * mi/mi-main.c (mi_execute_command): Update.
8260
8261 2017-04-12 Tom Tromey <tom@tromey.com>
8262
8263 * location.c (explicit_location_lex_one): Return a
8264 unique_xmalloc_ptr.
8265 (string_to_explicit_location): Update. Remove cleanups.
8266
8267 2017-04-12 Tom Tromey <tom@tromey.com>
8268
8269 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
8270 (compare_value_and_voffset): Change type. Update.
8271 (compute_vtable_size): Change type of "offset_vec".
8272 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
8273 (gnuv3_get_typeid): Remove extraneous declaration.
8274
8275 2017-04-12 Tom Tromey <tom@tromey.com>
8276
8277 * charset.h (wchar_iterator): Fix comment.
8278
8279 2017-04-12 Tom Tromey <tom@tromey.com>
8280
8281 * charset.c (iconv_wrapper): New class.
8282 (cleanup_iconv): Remove.
8283 (convert_between_encodings): Use it.
8284
8285 2017-04-12 Tom Tromey <tom@tromey.com>
8286
8287 * symfile.h (increment_reading_symtab): Update type.
8288 * symfile.c (decrement_reading_symtab): Remove.
8289 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
8290 * psymtab.c (psymtab_to_symtab): Update.
8291 * dwarf2read.c (dw2_instantiate_symtab): Update.
8292
8293 2017-04-12 Tom Tromey <tom@tromey.com>
8294
8295 * jit.c (struct jit_reader): Declare separately. Add constructor
8296 and destructor. Change type of "handle".
8297 (loaded_jit_reader): Define separately.
8298 (jit_reader_load): Update. New "new".
8299 (jit_reader_unload_command): Use "delete".
8300 * gdb-dlfcn.h (struct dlclose_deleter): New.
8301 (gdb_dlhandle_up): New typedef.
8302 (gdb_dlopen, gdb_dlsym): Update types.
8303 (gdb_dlclose): Remove.
8304 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
8305 (gdb_dlsym): Change type of "handle".
8306 (make_cleanup_dlclose): Remove.
8307 (dlclose_deleter::operator()): Rename from gdb_dlclose.
8308 * compile/compile-c-support.c (load_libcc): Update.
8309
8310 2017-04-12 Tom Tromey <tom@tromey.com>
8311
8312 * symtab.h (find_pcs_for_symtab_line): Change return type.
8313 * symtab.c (find_pcs_for_symtab_line): Change return type.
8314 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
8315 type of "vec". Update.
8316 (ltpy_get_pcs_for_line): Update.
8317 * linespec.c (decode_digits_ordinary): Update.
8318
8319 2017-04-12 Tom Tromey <tom@tromey.com>
8320
8321 * tracepoint.c (actions_command): Update.
8322 * python/python.c (python_command, python_interactive_command):
8323 Update.
8324 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
8325 * guile/guile.c (guile_command): Update.
8326 * defs.h (read_command_lines, read_command_lines_1): Return
8327 command_line_up.
8328 (command_lines_deleter): New struct.
8329 (command_line_up): New typedef.
8330 * compile/compile.c (compile_code_command)
8331 (compile_print_command): Update.
8332 * cli/cli-script.h (get_command_line, copy_command_lines): Return
8333 command_line_up.
8334 (make_cleanup_free_command_lines): Remove.
8335 * cli/cli-script.c (get_command_line, read_command_lines_1)
8336 (copy_command_lines): Return command_line_up.
8337 (while_command, if_command, read_command_lines, define_command)
8338 (document_command): Update.
8339 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
8340 Remove.
8341 * breakpoint.h (breakpoint_set_commands): Change type of
8342 "commands".
8343 * breakpoint.c (breakpoint_set_commands): Change type of
8344 "commands". Update.
8345 (do_map_commands_command, update_dprintf_command_list)
8346 (create_tracepoint_from_upload): Update.
8347
8348 2017-04-12 Tom Tromey <tom@tromey.com>
8349
8350 * tracepoint.c (scope_info): Update.
8351 * spu-tdep.c (spu_catch_start): Update.
8352 * python/python.c (gdbpy_decode_line): Update.
8353 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
8354 * python/py-breakpoint.c (bppy_init): Update.
8355 * probe.c (parse_probes): Update.
8356 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
8357 * location.h (event_location_deleter): New struct.
8358 (event_location_up): New typedef.
8359 (new_linespec_location, new_address_location, new_probe_location)
8360 (new_explicit_location, copy_event_location)
8361 (string_to_event_location, string_to_event_location_basic)
8362 (string_to_explicit_location): Update return type.
8363 (make_cleanup_delete_event_location): Remove.
8364 * location.c (new_linespec_location, new_address_location)
8365 (new_probe_location, new_explicit_location, copy_event_location):
8366 Return event_location_up.
8367 (delete_event_location_cleanup)
8368 (make_cleanup_delete_event_location): Remove.
8369 (string_to_explicit_location, string_to_event_location_basic)
8370 (string_to_event_location): Return event_location_up.
8371 * linespec.c (canonicalize_linespec, event_location_to_sals)
8372 (decode_line_with_current_source)
8373 (decode_line_with_last_displayed, decode_objc): Update.
8374 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
8375 * completer.c (location_completer): Update.
8376 * cli/cli-cmds.c (edit_command, list_command): Update.
8377 * breakpoint.c (create_overlay_event_breakpoint)
8378 (create_longjmp_master_breakpoint)
8379 (create_std_terminate_master_breakpoint)
8380 (create_exception_master_breakpoint)
8381 (create_thread_event_breakpoint): Update.
8382 (init_breakpoint_sal): Update. Remove some dead code.
8383 (create_breakpoint_sal): Change type of "location". Update.
8384 (create_breakpoints_sal, create_breakpoint, break_command_1)
8385 (dprintf_command, break_range_command, until_break_command)
8386 (init_ada_exception_breakpoint)
8387 (strace_marker_create_sals_from_location)
8388 (update_static_tracepoint, trace_command, ftrace_command)
8389 (strace_command, create_tracepoint_from_upload): Update.
8390 * break-catch-throw.c (re_set_exception_catchpoint): Update.
8391 * ax-gdb.c (agent_command_1): Update.
8392
8393 2017-04-12 Pedro Alves <palves@redhat.com>
8394
8395 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
8396 * configure.tgt: Handle i[34567]86-*-go32* and
8397 i[34567]86-*-msdosdjgpp*.
8398 * i386-tdep.c (i386_svr4_reg_to_regnum):
8399 Make extern.
8400 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
8401 i386-go32-tdep.c.
8402 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
8403 * i386-go32-tdep.c: New file.
8404 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
8405 declarations.
8406
8407 2017-04-12 Simon Marchi <simon.marchi@ericsson.com>
8408
8409 * aix-thread.c (pd_status2str): Change return type to const char *.
8410
8411 2017-04-12 Pedro Alves <palves@redhat.com>
8412
8413 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
8414 calls to set_gdbarch_gnu_triplet_regexp.
8415
8416 2017-04-12 Pedro Alves <palves@redhat.com>
8417
8418 PR gdb/21323
8419 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
8420 New enum value.
8421 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
8422 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
8423 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
8424 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
8425 * gdbarch.h, gdbarch.c: Regenerate.
8426 * aarch64-tdep.c (aarch64_gdbarch_init): Override
8427 gdbarch_wchar_bit and gdbarch_wchar_signed.
8428 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
8429 * arm-tdep.c (arm_gdbarch_init): Likewise.
8430 * avr-tdep.c (avr_gdbarch_init): Likewise.
8431 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
8432 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
8433 * i386-tdep.c (i386_go32_init_abi): Likewise.
8434 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
8435 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
8436 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
8437 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
8438 * sh-tdep.c (sh_gdbarch_init): Likewise.
8439 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
8440 * sparc64-tdep.c (sparc64_init_abi): Likewise.
8441 * windows-tdep.c (windows_init_abi): Likewise.
8442 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
8443
8444 2017-04-12 Pedro Alves <palves@redhat.com>
8445
8446 PR c++/21323
8447 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
8448 cplus_primitive_type_char32_t>: New enum values.
8449 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
8450 and cplus_primitive_type_char32_t.
8451 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
8452 32, use the archtecture's built-in type for char16_t and char32_t,
8453 respectively. Otherwise, fallback to init_integer_type as before,
8454 but make the type unsigned, and issue a complaint.
8455 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
8456
8457 2017-04-12 Alan Hayward <alan.hayward@arm.com>
8458
8459 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
8460 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
8461
8462 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
8463
8464 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
8465 'const char *'.
8466
8467 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
8468
8469 * common/common-utils.c (free_vector_argv): New function.
8470 * common/common-utils.h: Include <vector>.
8471 (free_vector_argv): New prototype.
8472 * darwin-nat.c (darwin_create_inferior): Rewrite function
8473 prototype in order to constify "exec_file" and accept a
8474 "std::string" for "allargs".
8475 * fork-child.c: Include <vector>.
8476 (breakup_args): Rewrite function, using C++.
8477 (fork_inferior): Rewrite function header, constify "exec_file_arg"
8478 and accept "std::string" for "allargs". Update the code to
8479 calculate "argv" based on "allargs". Update calls to "exec_fun"
8480 and "execvp".
8481 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
8482 order to constify "exec_file" and accept a "std::string" for
8483 "allargs".
8484 * go32-nat.c (go32_create_inferior): Likewise.
8485 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
8486 * infcmd.c (run_command_1): Constify "exec_file". Use
8487 "std::string" for inferior arguments.
8488 * inferior.h (fork_inferior): Update prototype.
8489 * linux-nat.c (linux_nat_create_inferior): Rewrite function
8490 prototype in order to constify "exec_file" and accept a
8491 "std::string" for "allargs".
8492 * nto-procfs.c (procfs_create_inferior): Likewise.
8493 * procfs.c (procfs_create_inferior): Likewise.
8494 * remote-sim.c (gdbsim_create_inferior): Likewise.
8495 * remote.c (extended_remote_run): Update code to accept
8496 "std::string" as argument.
8497 (extended_remote_create_inferior): Rewrite function prototype in
8498 order to constify "exec_file" and accept a "std::string" for
8499 "allargs".
8500 * rs6000-nat.c (super_create_inferior): Likewise.
8501 (rs6000_create_inferior): Likewise.
8502 * target.h (struct target_ops) <to_create_inferior>: Likewise.
8503 * windows-nat.c (windows_create_inferior): Likewise.
8504
8505 2017-04-11 Pedro Alves <palves@redhat.com>
8506
8507 * thread.c: Fix whitespace throughout.
8508
8509 2017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
8510
8511 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
8512
8513 2017-04-11 Alan Hayward <alan.hayward@arm.com>
8514
8515 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
8516
8517 2017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
8518
8519 PR gdb/21364
8520 * osdata.c (info_osdata): Check if 'type' is an empty string
8521 instead of NULL.
8522
8523 2017-04-10 Pedro Alves <palves@redhat.com>
8524
8525 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
8526 (ptid_to_global_thread_id, in_thread_list)
8527 (do_captured_list_thread_ids, set_resumed, set_running)
8528 (set_executing, set_stop_requested, finish_thread_state)
8529 (validate_registers_access, can_access_registers_ptid)
8530 (print_thread_info_1, switch_to_thread)
8531 (do_restore_current_thread_cleanup)
8532 (make_cleanup_restore_current_thread, thread_command)
8533 (thread_name_command): Use operator== instead of ptid_equal.
8534
8535 2017-04-10 Pedro Alves <palves@redhat.com>
8536
8537 * thread.c (struct current_thread_cleanup) <next>: Delete field.
8538 (current_thread_cleanup_chain): Delete.
8539 (restore_current_thread_cleanup_dtor)
8540 (make_cleanup_restore_current_thread): Remove references to
8541 current_thread_cleanup_chain.
8542
8543 2017-04-10 Alan Hayward <alan.hayward@arm.com>
8544
8545 * msp430-tdep.c (msp430_pseudo_register_read): Never return
8546 REG_UNKNOWN.
8547
8548 2017-04-10 Yao Qi <yao.qi@linaro.org>
8549
8550 PR gdb/19942
8551 * gdbthread.h (thread_info::deletable): New method.
8552 (thread_info::incref): New method.
8553 (thread_info::decref): New method.
8554 (thread_info::refcount): Move it to private.
8555 * infrun.c (save_stop_context): Call inc_refcount.
8556 (release_stop_context_cleanup): Likewise.
8557 * thread.c (set_thread_exited): New function.
8558 (init_thread_list): Delete "tp" only it is deletable, otherwise
8559 call set_thread_exited.
8560 (delete_thread_1): Call set_thread_exited.
8561 (current_thread_cleanup) <inferior_pid>: Remove.
8562 <thread>: New field.
8563 (restore_current_thread_ptid_changed): Removed.
8564 (do_restore_current_thread_cleanup): Adjust.
8565 (restore_current_thread_cleanup_dtor): Don't call
8566 find_thread_ptid.
8567 (set_thread_refcount): Use dec_refcount.
8568 (make_cleanup_restore_current_thread): Adjust.
8569 (thread_apply_all_command): Call inc_refcount.
8570 (_initialize_thread): Don't call
8571 observer_attach_thread_ptid_changed.
8572
8573 2017-04-10 Yao Qi <yao.qi@linaro.org>
8574
8575 * thread.c (delete_thread_1): Hoist code on marking thread as
8576 exited.
8577
8578 2017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8579
8580 * windows-nat.c (windows_detach): Initialize ptid with
8581 minus_one_ptid.
8582
8583 2017-04-07 Simon Marchi <simon.marchi@ericsson.com>
8584
8585 * unittests/ptid-selftests.c: Fix erroneous assert messages.
8586
8587 2017-04-07 Alan Hayward <alan.hayward@arm.com>
8588
8589 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
8590 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
8591 (bfin_pseudo_register_write): Likewise
8592
8593 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
8594
8595 * common/ptid.h (struct ptid): Change to...
8596 (class ptid_t): ... this.
8597 <ptid_t>: New constructors.
8598 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
8599 matches>: New methods.
8600 <make_null, make_minus_one>: New static methods.
8601 <pid>: Rename to...
8602 <m_pid>: ...this.
8603 <lwp>: Rename to...
8604 <m_lwp>: ...this.
8605 <tid>: Rename to...
8606 <m_tid>: ...this.
8607 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
8608 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
8609 as references, move comment to class ptid_t.
8610 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
8611 ptid_t static methods.
8612 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
8613 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
8614 Take ptid arguments as references, implement using ptid_t methods.
8615 * unittests/ptid-selftests.c: New file.
8616 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8617 unittests/ptid-selftests.c.
8618 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
8619
8620 2017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
8621
8622 * python/python.c (python_run_simple_file): Cast mode literal to
8623 non-const char pointer as expected by PyFile_FromString.
8624
8625 2017-04-05 Simon Marchi <simon.marchi@ericsson.com>
8626
8627 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
8628 minus_one_ptid and null_ptid.
8629
8630 2017-04-05 Pedro Alves <palves@redhat.com>
8631
8632 * warning.m4 (build_warnings): Remove -Wno-write-strings.
8633 * configure: Regenerate.
8634
8635 2017-04-05 Pedro Alves <palves@redhat.com>
8636
8637 * ada-exp.y (yyerror): Constify.
8638 * ada-lang.c (bound_name, get_selections)
8639 (ada_variant_discrim_type)
8640 (ada_variant_discrim_name, ada_value_struct_elt)
8641 (ada_lookup_struct_elt_type, is_unchecked_variant)
8642 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
8643 (catch_ada_exception_command_split)
8644 (catch_ada_assert_command_split, catch_assert_command)
8645 (ada_op_name): Constify.
8646 * ada-lang.h (ada_yyerror, get_selections)
8647 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
8648 * arc-tdep.c (arc_print_frame_cache): Constify.
8649 * arm-tdep.c (arm_skip_stub): Constify.
8650 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
8651 (gen_aggregate_elt_ref): Constify.
8652 * bcache.c (print_bcache_statistics): Constify.
8653 * bcache.h (print_bcache_statistics): Constify.
8654 * break-catch-throw.c (catch_exception_command_1):
8655 * breakpoint.c (struct ep_type_description::description):
8656 Constify.
8657 (add_solib_catchpoint): Constify.
8658 (catch_fork_command_1): Add cast.
8659 (add_catch_command): Constify.
8660 * breakpoint.h (add_catch_command, add_solib_catchpoint):
8661 Constify.
8662 * bsd-uthread.c (bsd_uthread_state): Constify.
8663 * buildsym.c (patch_subfile_names): Constify.
8664 * buildsym.h (next_symbol_text_func, patch_subfile_names):
8665 Constify.
8666 * c-exp.y (yyerror): Constify.
8667 (token::oper): Constify.
8668 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
8669 * c-varobj.c (cplus_describe_child): Constify.
8670 * charset.c (find_charset_names): Add cast.
8671 (find_charset_names): Constify array and add const_cast.
8672 * cli/cli-cmds.c (complete_command, cd_command): Constify.
8673 (edit_command): Constify.
8674 * cli/cli-decode.c (lookup_cmd): Constify.
8675 * cli/cli-dump.c (dump_memory_command, dump_value_command):
8676 Constify.
8677 (struct dump_context): Constify.
8678 (add_dump_command, restore_command): Constify.
8679 * cli/cli-script.c (get_command_line): Constify.
8680 * cli/cli-script.h (get_command_line): Constify.
8681 * cli/cli-utils.c (check_for_argument): Constify.
8682 * cli/cli-utils.h (check_for_argument): Constify.
8683 * coff-pe-read.c (struct read_pe_section_data): Constify.
8684 * command.h (lookup_cmd): Constify.
8685 * common/print-utils.c (decimal2str): Constify.
8686 * completer.c (gdb_print_filename): Constify.
8687 * corefile.c (set_gnutarget): Constify.
8688 * cp-name-parser.y (yyerror): Constify.
8689 * cp-valprint.c (cp_print_class_member): Constify.
8690 * cris-tdep.c (cris_register_name, crisv32_register_name):
8691 Constify.
8692 * d-exp.y (yyerror): Constify.
8693 (struct token::oper): Constify.
8694 * d-lang.h (d_yyerror): Constify.
8695 * dbxread.c (struct header_file_location::name): Constify.
8696 (add_old_header_file, add_new_header_file, last_function_name)
8697 (dbx_next_symbol_text, add_bincl_to_list)
8698 (find_corresponding_bincl_psymtab, set_namestring)
8699 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
8700 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
8701 * defs.h (command_line_input, print_address_symbolic)
8702 (deprecated_readline_begin_hook): Constify.
8703 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
8704 Constify.
8705 * event-top.c (handle_line_of_input): Constify and add cast.
8706 * exceptions.c (catch_errors): Constify.
8707 * exceptions.h (catch_errors): Constify.
8708 * expprint.c (print_subexp_standard, op_string, op_name)
8709 (op_name_standard, dump_raw_expression, dump_raw_expression):
8710 * expression.h (op_name, op_string, dump_raw_expression):
8711 Constify.
8712 * f-exp.y (yyerror): Constify.
8713 (struct token::oper): Constify.
8714 (struct f77_boolean_val::name): Constify.
8715 * f-lang.c (f_word_break_characters): Constify.
8716 * f-lang.h (f_yyerror): Constify.
8717 * fork-child.c (fork_inferior): Add cast.
8718 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
8719 (new_variant): Constify.
8720 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
8721 * gdbarch.c: Regenerate.
8722 * gdbcore.h (set_gnutarget): Constify.
8723 * go-exp.y (yyerror): Constify.
8724 (token::oper): Constify.
8725 * go-lang.h (go_yyerror): Constify.
8726 * go32-nat.c (go32_sysinfo): Constify.
8727 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
8728 * guile/scm-cmd.c (cmdscm_function): Constify.
8729 * guile/scm-param.c (pascm_param_value): Constify.
8730 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
8731 (h8300sx_register_name): Constify.
8732 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
8733 Constify.
8734 * ia64-tdep.c (ia64_register_names): Constify.
8735 * infcmd.c (construct_inferior_arguments): Constify.
8736 (path_command, attach_post_wait): Constify.
8737 * language.c (show_range_command, show_case_command)
8738 (unk_lang_error): Constify.
8739 * language.h (language_defn::la_error)
8740 (language_defn::la_name_of_this): Constify.
8741 * linespec.c (decode_line_2): Constify.
8742 * linux-thread-db.c (thread_db_err_str): Constify.
8743 * lm32-tdep.c (lm32_register_name): Constify.
8744 * m2-exp.y (yyerror): Constify.
8745 * m2-lang.h (m2_yyerror): Constify.
8746 * m32r-tdep.c (m32r_register_names): Constify and make static.
8747 * m68hc11-tdep.c (m68hc11_register_names): Constify.
8748 * m88k-tdep.c (m88k_register_name): Constify.
8749 * macroexp.c (appendmem): Constify.
8750 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
8751 (upgrade_type, parse_external, parse_partial_symbols)
8752 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
8753 (new_symbol): Constify.
8754 * memattr.c (mem_info_command): Constify.
8755 * mep-tdep.c (register_name_from_keyword): Constify.
8756 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
8757 Constify.
8758 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
8759 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
8760 * mi/mi-main.c (captured_mi_execute_command): Constify and add
8761 cast.
8762 (mi_execute_async_cli_command): Constify.
8763 * mips-tdep.c (mips_register_name): Constify.
8764 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
8765 (am33_register_name, am33_2_register_name)
8766 * moxie-tdep.c (moxie_register_names): Constify.
8767 * nat/linux-osdata.c (osdata_type): Constify fields.
8768 * nto-tdep.c (nto_parse_redirection): Constify.
8769 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
8770 (lookup_child_selector): Constify.
8771 (objc_methcall::name): Constify.
8772 * objc-lang.h (lookup_objc_class, lookup_child_selector)
8773 (lookup_struct_typedef): Constify.
8774 * objfiles.c (pc_in_section): Constify.
8775 * objfiles.h (pc_in_section): Constify.
8776 * p-exp.y (struct token::oper): Constify.
8777 (yyerror): Constify.
8778 * p-lang.h (pascal_yyerror): Constify.
8779 * parser-defs.h (op_name_standard): Constify.
8780 (op_print::string): Constify.
8781 (exp_descriptor::op_name): Constify.
8782 * printcmd.c (print_address_symbolic): Constify.
8783 * psymtab.c (print_partial_symbols): Constify.
8784 * python/py-breakpoint.c (stop_func): Constify.
8785 (bppy_get_expression): Constify.
8786 * python/py-cmd.c (cmdpy_completer::name): Constify.
8787 (cmdpy_function): Constify.
8788 * python/py-event.c (evpy_add_attribute)
8789 (gdbpy_initialize_event_generic): Constify.
8790 * python/py-event.h (evpy_add_attribute)
8791 (gdbpy_initialize_event_generic): Constify.
8792 * python/py-evts.c (add_new_registry): Constify.
8793 * python/py-finishbreakpoint.c (outofscope_func): Constify.
8794 * python/py-framefilter.c (get_py_iter_from_func): Constify.
8795 * python/py-inferior.c (get_buffer): Add cast.
8796 * python/py-param.c (parm_constant::name): Constify.
8797 * python/py-unwind.c (fprint_frame_id): Constify.
8798 * python/python.c (gdbpy_parameter_value): Constify.
8799 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
8800 * remote.c (memory_packet_config::name): Constify.
8801 (show_packet_config_cmd, remote_write_bytes)
8802 (remote_buffer_add_string):
8803 * reverse.c (exec_reverse_once): Constify.
8804 * rs6000-tdep.c (variant::name, variant::description): Constify.
8805 * rust-exp.y (rustyyerror): Constify.
8806 * rust-lang.c (rust_op_name): Constify.
8807 * rust-lang.h (rustyyerror): Constify.
8808 * serial.h (serial_ops::name): Constify.
8809 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
8810 (sh_sh3e_register_name, sh_sh2e_register_name)
8811 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
8812 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
8813 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
8814 (sh_sh4al_dsp_register_name): Constify.
8815 * sh64-tdep.c (sh64_register_name): Constify.
8816 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
8817 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
8818 * stabsread.c (patch_block_stabs, read_type_number)
8819 (ref_map::stabs, ref_add, process_reference)
8820 (symbol_reference_defined, define_symbol, define_symbol)
8821 (error_type, read_type, read_member_functions, read_cpp_abbrev)
8822 (read_one_struct_field, read_struct_fields, read_baseclasses)
8823 (read_tilde_fields, read_struct_type, read_array_type)
8824 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
8825 (read_huge_number, read_range_type, read_args, common_block_start)
8826 (find_name_end): Constify.
8827 * stabsread.h (common_block_start, define_symbol)
8828 (process_one_symbol, symbol_reference_defined, ref_add):
8829 * symfile.c (get_section_index, add_symbol_file_command):
8830 * symfile.h (get_section_index): Constify.
8831 * target-descriptions.c (tdesc_type::name): Constify.
8832 (tdesc_free_type): Add cast.
8833 * target.c (find_default_run_target):
8834 (add_deprecated_target_alias, find_default_run_target)
8835 (target_announce_detach): Constify.
8836 (do_option): Constify.
8837 * target.h (add_deprecated_target_alias): Constify.
8838 * thread.c (print_thread_info_1): Constify.
8839 * top.c (deprecated_readline_begin_hook, command_line_input):
8840 Constify.
8841 (init_main): Add casts.
8842 * top.h (handle_line_of_input): Constify.
8843 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
8844 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
8845 (tfind_command): Rename to ...
8846 (tfind_command_1): ... this and constify.
8847 (tfind_command): New function.
8848 (tfind_end_command, tfind_start_command): Adjust.
8849 (encode_source_string): Constify.
8850 * tracepoint.h (encode_source_string): Constify.
8851 * tui/tui-data.c (tui_partial_win_by_name): Constify.
8852 * tui/tui-data.h (tui_partial_win_by_name): Constify.
8853 * tui/tui-source.c (tui_set_source_content_nil): Constify.
8854 * tui/tui-source.h (tui_set_source_content_nil): Constify.
8855 * tui/tui-win.c (parse_scrolling_args): Constify.
8856 * tui/tui-windata.c (tui_erase_data_content): Constify.
8857 * tui/tui-windata.h (tui_erase_data_content): Constify.
8858 * tui/tui-winsource.c (tui_erase_source_content): Constify.
8859 * tui/tui.c (tui_enable): Add cast.
8860 * utils.c (defaulted_query): Constify.
8861 (init_page_info): Add cast.
8862 (puts_debug, subset_compare): Constify.
8863 * utils.h (subset_compare): Constify.
8864 * varobj.c (varobj_format_string): Constify.
8865 * varobj.h (varobj_format_string): Constify.
8866 * vax-tdep.c (vax_register_name): Constify.
8867 * windows-nat.c (windows_detach): Constify.
8868 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
8869 * xml-support.c (gdb_xml_end_element): Constify.
8870 * xml-tdesc.c (tdesc_start_reg): Constify.
8871 * xstormy16-tdep.c (xstormy16_register_name): Constify.
8872 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
8873 * xtensa-tdep.h (xtensa_register_t::name): Constify.
8874
8875 2017-04-05 Pedro Alves <palves@redhat.com>
8876
8877 * proc-api.c (struct trans): Constify.
8878 (procfs_note): Constify.
8879 * proc-events.c (struct trans, syscall_table):
8880 * proc-flags.c (struct trans): Constify.
8881 * proc-utils.h (procfs_note): Constify.
8882 * proc-why.c (struct trans): Constify.
8883 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
8884 (procfs_detach): Constify.
8885 * sol-thread.c (struct string_map): Constify.
8886 (td_err_string, td_state_string): Constify.
8887
8888 2017-04-05 Pedro Alves <palves@redhat.com>
8889
8890 * proc-api.c (procfs_filename): Don't initialize
8891 procfs_filename.
8892 (prepare_to_trace): Assume procfs_filename is non-NULL.
8893 (_initialize_proc_api): Give procfs_filename a default value here.
8894
8895 2017-04-05 Pedro Alves <palves@redhat.com>
8896
8897 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
8898 'cond_string' parameter.
8899 (extract_exception_regexp): Constify 'string' parameter.
8900 (catch_exception_command_1): Constify.
8901 * breakpoint.c (init_catchpoint)
8902 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
8903 parameter.
8904 (ep_parse_optional_if_clause, catch_fork_command_1)
8905 (catch_exec_command_1): Constify.
8906 * breakpoint.h (init_catchpoint): Constify 'cond_string'
8907 parameter.
8908 (ep_parse_optional_if_clause): Constify.
8909 * cli/cli-utils.c (remove_trailing_whitespace)
8910 (check_for_argument): Constify.
8911 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
8912 non-const overload.
8913 (check_for_argument): Likewise.
8914
8915 2017-04-05 Pedro Alves <palves@redhat.com>
8916
8917 * event-top.c (command_line_handler): Add cast to execute_command
8918 call.
8919 * record-btrace.c (cmd_record_btrace_bts_start)
8920 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
8921 (cmd_record_btrace_start): Add cast to execute_command call.
8922 * record-full.c (record_full_goto_insn):
8923 * record.c (record_start, record_stop): Add cast to
8924 execute_command_to_string calls.
8925 (cmd_record_start): Add cast to execute_command calls.
8926
8927 2017-04-05 Pedro Alves <palves@redhat.com>
8928
8929 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
8930 static inline function.
8931 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
8932 array and use gdb_PyArg_ParseTupleAndKeywords.
8933 * python/py-cmd.c (cmdpy_init): Likewise.
8934 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
8935 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
8936 (infpy_search_memory): Likewise.
8937 * python/py-objfile.c (objfpy_add_separate_debug_file)
8938 (gdbpy_lookup_objfile): Likewise.
8939 * python/py-symbol.c (gdbpy_lookup_symbol)
8940 (gdbpy_lookup_global_symbol): Likewise.
8941 * python/py-type.c (gdbpy_lookup_type): Likewise.
8942 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
8943 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
8944 Likewise.
8945
8946 2017-04-05 Pedro Alves <palves@redhat.com>
8947
8948 * python/python-internal.h (gdb_PyGetSetDef): New type.
8949 * python/py-block.c (block_object_getset)
8950 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
8951 * python/py-event.c (event_object_getset)
8952 (finish_breakpoint_object_getset): Likewise.
8953 * python/py-inferior.c (inferior_object_getset): Likewise.
8954 * python/py-infthread.c (thread_object_getset): Likewise.
8955 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
8956 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
8957 * python/py-objfile.c (objfile_getset): Likewise.
8958 * python/py-progspace.c (pspace_getset): Likewise.
8959 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
8960 Likewise.
8961 * python/py-record.c (recpy_record_getset): Likewise.
8962 * python/py-symbol.c (symbol_object_getset): Likewise.
8963 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
8964 Likewise.
8965 * python/py-type.c (type_object_getset, field_object_getset):
8966 Likewise.
8967 * python/py-value.c (value_object_getset): Likewise.
8968
8969 2017-04-05 Pedro Alves <palves@redhat.com>
8970
8971 * python/python-internal.h (gdb_PyObject_CallMethod)
8972 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
8973 New functions.
8974 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
8975 (PySys_GetObject, PySys_SetPath): New macros.
8976
8977 2017-04-05 Pedro Alves <palves@redhat.com>
8978
8979 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
8980 info_osdata_command.
8981 * osdata.c (info_osdata_command): Rename to ...
8982 (info_osdata): ... this. Constify 'type' parameter, and remove
8983 the 'from_tty' parameter. Accept NULL TYPE.
8984 (info_osdata_command): New function.
8985 * osdata.h (info_osdata_command): Remove declaration.
8986 (info_osdata): New declaration.
8987
8988 2017-04-05 Pedro Alves <palves@redhat.com>
8989
8990 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
8991 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
8992 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
8993 parameter.
8994 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
8995 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
8996 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
8997 parameter.
8998 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
8999 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
9000 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
9001 (mi_cmd_file_list_exec_source_files)
9002 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
9003 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
9004 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
9005 parameter.
9006 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
9007 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
9008 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
9009 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
9010 (mi_cmd_stack_info_frame): Constify 'command' parameter.
9011 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
9012 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
9013 'command' parameter.
9014 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
9015 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
9016 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
9017 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
9018 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
9019 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
9020 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
9021 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
9022 (mi_cmd_var_set_update_range): Constify 'command' parameter.
9023 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
9024 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
9025 parameter.
9026 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
9027 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
9028 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
9029 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
9030 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
9031 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
9032 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
9033 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
9034 (mi_cmd_data_list_changed_registers)
9035 (mi_cmd_data_write_register_values)
9036 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
9037 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
9038 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
9039 (mi_cmd_list_features, mi_cmd_list_target_features)
9040 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
9041 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
9042 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
9043 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
9044 (mi_cmd_trace_frame_collected): Constify 'command'
9045 parameter.
9046 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
9047 'command' parameter.
9048
9049 2017-04-05 Pedro Alves <palves@redhat.com>
9050
9051 * ada-lang.c (ada_completer_word_break_characters): Now a const
9052 array.
9053 (ada_get_gdb_completer_word_break_characters): Constify.
9054 * completer.c (gdb_completer_command_word_break_characters)
9055 (gdb_completer_file_name_break_characters)
9056 (gdb_completer_quote_characters): Now const arrays.
9057 (get_gdb_completer_quote_characters): Constify.
9058 (set_rl_completer_word_break_characters): New function.
9059 (set_gdb_completion_word_break_characters)
9060 (complete_line_internal): Use it.
9061 * completer.h (get_gdb_completer_quote_characters): Constify.
9062 (set_rl_completer_word_break_characters): Declare.
9063 * f-lang.c (f_word_break_characters): Constify.
9064 * language.c (default_word_break_characters): Constify.
9065 * language.h (language_defn::la_word_break_characters): Constify.
9066 (default_word_break_characters): Constify.
9067 * top.c (init_main): Use set_rl_completer_word_break_characters.
9068
9069 2017-04-05 Pedro Alves <palves@redhat.com>
9070
9071 * aix-thread.c (aix_thread_pid_to_str)
9072 (aix_thread_extra_thread_info): Constify.
9073 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
9074 * bsd-uthread.c (bsd_uthread_extra_thread_info)
9075 (bsd_uthread_pid_to_str): Constify.
9076 * corelow.c (core_pid_to_str): Constify.
9077 * darwin-nat.c (darwin_pid_to_str): Constify.
9078 * fbsd-nat.c (fbsd_pid_to_str): Constify.
9079 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
9080 Constify.
9081 * gnu-nat.c (gnu_pid_to_str): Constify.
9082 * go32-nat.c (go32_pid_to_str): Constify.
9083 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
9084 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
9085 * inferior.c (inferior_pid_to_str): Constify.
9086 * linux-nat.c (linux_nat_pid_to_str): Constify.
9087 * linux-tdep.c (linux_core_pid_to_str): Constify.
9088 * linux-thread-db.c (thread_db_pid_to_str)
9089 (thread_db_extra_thread_info): Constify.
9090 * nto-tdep.c (nto_extra_thread_info): Constify.
9091 * nto-tdep.h (nto_extra_thread_info): Constify.
9092 * obsd-nat.c (obsd_pid_to_str): Constify.
9093 * procfs.c (procfs_pid_to_str): Constify.
9094 * ravenscar-thread.c (ravenscar_extra_thread_info)
9095 (ravenscar_pid_to_str): Constify.
9096 * remote-sim.c (gdbsim_pid_to_str): Constify.
9097 * remote.c (remote_threads_extra_info, remote_pid_to_str):
9098 Constify.
9099 * sol-thread.c (solaris_pid_to_str): Constify.
9100 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
9101 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
9102 * target.c (default_pid_to_str, target_pid_to_str)
9103 (normal_pid_to_str, default_pid_to_str): Constify.
9104 * target.h (target_ops::to_pid_to_str)
9105 (target_ops::to_extra_thread_info): Constify.
9106 (target_pid_to_str, normal_pid_to_str): Constify.
9107 * windows-nat.c (windows_pid_to_str): Constify.
9108 * gdbarch.sh (core_pid_to_str): Constify.
9109 * target-delegates.c: Regenerate.
9110 * gdbarch.h, gdbarch.c: Regenerate.
9111
9112 2017-04-05 Pedro Alves <palves@redhat.com>
9113
9114 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
9115 the memory of the temporary warning_pre_print override.
9116 * utils.c (warning_pre_print): Constify.
9117 * utils.h (warning_pre_print): Constify.
9118
9119 2017-04-05 Pedro Alves <palves@redhat.com>
9120
9121 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
9122 (shell_command): New function.
9123 (make_command): Use std::string.
9124 (init_cli_cmds): Register shell_command instead of shell_escape.
9125
9126 2017-04-05 Pedro Alves <palves@redhat.com>
9127
9128 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
9129 * tracepoint.c (default_collect): Don't initialize.
9130
9131 2017-04-05 Pedro Alves <palves@redhat.com>
9132
9133 * macroexp.c (macro_buffer::shared): Now a bool.
9134 (init_buffer): Update.
9135 (init_shared_buffer): Constify 'addr' parameter.
9136 (substitute_args, expand, macro_expand, macro_expand_next): Remove
9137 casts.
9138
9139 2017-04-05 Pedro Alves <palves@redhat.com>
9140
9141 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
9142 * disasm.c (set_disassembler_options): Constify local.
9143 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
9144
9145 2017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
9146
9147 PR gdb/21352
9148 * tracefile.c (tsave_command): Fix argument parsing for '-r'
9149 option.
9150
9151 2017-04-05 Yao Qi <yao.qi@linaro.org>
9152
9153 * frame.c (frame_unwind_register_unsigned): Call
9154 frame_unwind_register_value.
9155
9156 2017-04-05 Yao Qi <yao.qi@linaro.org>
9157
9158 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
9159 Use gdb_test_multiple, and don't match anchor.
9160
9161 2017-04-05 Pedro Alves <palves@redhat.com>
9162
9163 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
9164 (Write After Approval): Remove Simon Marchi.
9165
9166 2017-04-05 Pedro Alves <palves@redhat.com>
9167
9168 * common/gdb_optional.h (optional::optional): Make constexpr and
9169 initialize m_dummy.
9170
9171 2017-04-04 John Baldwin <jhb@FreeBSD.org>
9172
9173 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
9174 (amd64fbsd_jmp_buf_reg_offset): Remove.
9175 (amd64fbsd_supply_uthread): Remove function.
9176 (amd64fbsd_collect_uthread): Remove function.
9177 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
9178 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
9179 (x86_64-*-freebsd*): Remove bsd-uthread.o.
9180 (fbsd-nat.c): Update comment.
9181 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
9182 (i386fbsd_jmp_buf_reg_offset): Remove.
9183 (i386fbsd_supply_uthread): Remove function.
9184 (i386fbsd_collect_uthread): Remove function.
9185 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
9186
9187 2017-04-04 John Baldwin <jhb@FreeBSD.org>
9188
9189 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
9190 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
9191 * NEWS: Mention that support for FreeBSD/alpha was removed.
9192 * alpha-fbsd-tdep.c: Delete file.
9193 * config/alpha/fbsd.mh: Delete file.
9194 * configure.host: Delete alpha*-*-freebsd* and
9195 alpha*-*-kfreebsd*-gnu.
9196 * configure.tgt: Delete alpha*-*-freebsd* and
9197 alpha*-*-kfreebsd*-gnu.
9198
9199 2017-04-04 John Baldwin <jhb@FreeBSD.org>
9200
9201 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
9202 amd64bsd_store_inferior_registers): Use ptid from regcache.
9203
9204 2017-04-04 Pedro Alves <palves@redhat.com>
9205
9206 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
9207 data fields, make them private and add "m_" prefixes.
9208 (lnp_state_machine::lnp_state_machine): New ctor.
9209 (record_line, check_line_address, handle_set_discriminator)
9210 (handle_set_address, handle_advance_pc, handle_special_opcode)
9211 (handle_advance_line, handle_set_file, handle_negate_stmt)
9212 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
9213 (end_sequence, advance_line): New methods.
9214 (m_gdbarch, m_record_lines_p): New fields.
9215 (lnp_reader_state): Delete.
9216 (dwarf_record_line): Rename to ...
9217 (lnp_state_machine::record_line): ... adjust.
9218 (init_lnp_state_machine): Delete.
9219 (lnp_state_machine::lnp_state_machine): New.
9220 (check_line_address): Rename to ...
9221 (lnp_state_machine::check_line_address): This.
9222 (dwarf_decode_lines_1): Remove reference to "reader_state".
9223 Adjust lnp_state_machine having a non-default ctor. Use bool.
9224 State machine internal state manipulation moved to
9225 lnp_state_machine methods.
9226
9227 2017-04-04 Pedro Alves <palves@redhat.com>
9228
9229 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9230 unittests/offset-type-selftests.c.
9231 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
9232 * common/offset-type.h: New file.
9233 * common/preprocessor.h: New file.
9234 * common/traits.h: New file.
9235 * common/valid-expr.h: New file.
9236 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
9237 sect_offset and cu_offset strong typedefs throughout.
9238 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
9239 typedefs throughout.
9240 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
9241 sect_offset and cu_offset strong typedefs throughout.
9242 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
9243 typedefs throughout.
9244 * gdbtypes.h: Include "common/offset-type.h".
9245 (cu_offset): Now an offset type (strong typedef) instead of a
9246 struct.
9247 (sect_offset): Likewise.
9248 (union call_site_parameter_u): Rename "param_offset" field to
9249 "param_cu_off".
9250 * unittests/offset-type-selftests.c: New file.
9251
9252 2017-04-04 Pedro Alves <palves@redhat.com>
9253
9254 * common/underlying.h: New file.
9255 * dwarf2read.c: Include "common/gdb_optional.h" and
9256 "common/underlying.h".
9257 (dir_index, file_name_index): New types.
9258 (file_entry): Use them.
9259 (file_entry::include): Use to_underlying.
9260 (line_header::add_file_name): Use dir_index.
9261 (read_formatted_entries): Use gdb::optional. Read form before
9262 writting to file_entry.
9263 (dwarf_decode_line_header): Use dir_index.
9264 (lnp_state_machine::current_file): Use to_underlying.
9265 (lnp_state_machine::file): Change type to file_name_index.
9266 (dwarf_record_line): Use to_underlying.
9267 (init_lnp_state_machine): Use file_name_index.
9268 (dwarf_decode_lines_1): Use dir_index and file_name_index.
9269
9270 2017-04-04 Pedro Alves <palves@redhat.com>
9271
9272 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
9273 operator bool, has_value and get methods.
9274
9275 2017-04-04 Pedro Alves <palves@redhat.com>
9276
9277 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
9278 fields.
9279 (line_header): Initialize all data fields. Change type of
9280 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
9281 Change type of include_dirs to std::vector<const char *>. Remove
9282 num_include_dirs, include_dirs_size. Change type of file_names to
9283 std::vector<file_entry>. Remove num_file_names, file_names_size.
9284 (line_header::line_header): New.
9285 (line_header::add_include_dir, line_header::add_file_name): New
9286 methods.
9287 (line_header::include_dir_at): Remove NULL check.
9288 (line_header::file_name_at): Add const overload.
9289 (line_header_up): New unique_ptr typedef.
9290 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
9291 std::vector. Remove free_line_header call.
9292 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
9293 free_line_header call.
9294 (free_cu_line_header): Delete.
9295 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
9296 (setup_type_unit_groups): Use line_header_up instead of cleanups.
9297 Adjust to use std::vector.
9298 (free_line_header): Delete.
9299 (free_line_header_voidp): Use delete.
9300 (add_include_dir): Replace with ...
9301 (line_header::add_include_dir): ... this method. Use std::vector.
9302 (add_file_name): Replace with ...
9303 (line_header::add_file_name): ... this method. Use std::vector.
9304 (add_include_dir_stub): Delete.
9305 (read_formatted_entries): Remove memset.
9306 (dwarf_decode_line_header): Return a line_header_up instead of a
9307 raw pointer. Remove cleanup handling. Pass lambdas to
9308 read_formatted_entries. Adjust to use line_header methods.
9309 (dwarf_decode_lines_1): Adjust to use line_header methods.
9310 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
9311 use std::vector.
9312
9313 2017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
9314
9315 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
9316 instead of struct ptid.
9317
9318 2017-05-04 Alan Hayward <alan.hayward@arm.com>
9319
9320 * frame.c (get_frame_register_bytes): Unwind using value.
9321 (put_frame_register_bytes): Likewise.
9322
9323 2017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
9324
9325 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
9326 aggregate-like.
9327
9328 2017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
9329
9330 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
9331
9332 2017-03-29 Yao Qi <yao.qi@linaro.org>
9333
9334 * gdbthread.h (struct thread_info): Declare constructor and
9335 destructor. Add some in-class member initializers.
9336 * thread.c (free_thread): Remove.
9337 (init_thread_list): Call delete instead of free_thread.
9338 (new_thread): Call thread_info constructor.
9339 (thread_info::thread_info): New function.
9340 (thread_info::~thread_info): New function.
9341 (delete_thread_1): Call delete instead of free_thread.
9342 (make_cleanup_restore_current_thread): Move tp and frame to
9343 inner block.
9344
9345 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
9346
9347 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
9348 (arc_skip_prologue): Likewise.
9349 (arc_make_frame_cache): Likewise.
9350 (arc_pv_get_operand): New function.
9351 (arc_is_in_prologue): Likewise.
9352 (arc_analyze_prologue): Likewise.
9353 (arc_print_frame_cache): Likewise.
9354 (MAX_PROLOGUE_LENGTH): New constant.
9355
9356 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
9357
9358 * configure.tgt: Add arc-insn.o.
9359 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
9360 (dump_arc_instruction_command): New function.
9361 (arc_fprintf_disasm): Likewise.
9362 (arc_disassemble_info): Likewise.
9363 (arc_insn_get_operand_value): Likewise.
9364 (arc_insn_get_operand_value_signed): Likewise.
9365 (arc_insn_get_memory_base_reg): Likewise.
9366 (arc_insn_get_memory_offset): Likewise.
9367 (arc_insn_get_branch_target): Likewise.
9368 (arc_insn_dump): Likewise.
9369 (arc_insn_get_linear_next_pc): Likewise.
9370 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
9371 (arc_disassemble_info): Likewise.
9372 (arc_insn_get_branch_target): Likewise.
9373 (arc_insn_get_linear_next_pc): Likewise.
9374 * NEWS: Mention new "maint print arc arc-instruction".
9375
9376 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
9377
9378 * arc-tdep (maintenance_print_arc_list): New variable.
9379 (maintenance_print_arc_command): New function.
9380
9381 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
9382
9383 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
9384 Add "limm" and "reserved".
9385 (arc_cannot_fetch_register, arc_cannot_store_register): Add
9386 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
9387 * arc-tdep.h (arc_regnum): Likewise.
9388
9389 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
9390
9391 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
9392 for THREADPTR register.
9393 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
9394 register.
9395 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
9396 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
9397 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
9398
9399 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
9400
9401 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
9402 registers above gdbarch_num_regs (gdbarch) as privileged in
9403 call0 ABI.
9404
9405 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
9406
9407 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
9408 for a single specified register or for all registers in
9409 a0_base..a0_base + C0_NREGS range.
9410 (supply_gregset_reg): Call regcache_raw_supply for a single
9411 specified register or for all registers in a0_base..a0_base +
9412 C0_NREGS range.
9413
9414 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
9415
9416 * arch/xtensa.h (C0_NREGS): Add definition.
9417 * xtensa-tdep.c (C0_NREGS): Remove definition.
9418
9419 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
9420
9421 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
9422 Drop xtensa_default_isa initialization.
9423 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
9424
9425 2017-03-27 Pedro Alves <palves@redhat.com>
9426
9427 * dwarf2read.c (file_entry) <dir_index>: Add comment.
9428 (file_entry::include_dir): New method.
9429 (line_header::include_dir_at, line_header::file_name_at): New
9430 methods.
9431 (setup_type_unit_groups, setup_type_unit_groups)
9432 (psymtab_include_file_name): Simplify using the new methods.
9433 (lnp_state_machine) <the_line_header>: New field.
9434 <file>: Add comment.
9435 (lnp_state_machine::current_file): New method.
9436 (dwarf_record_line): Simplify using the new methods.
9437 (init_lnp_state_machine): Initialize the "the_line_header" field.
9438 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
9439 Simplify using the new methods.
9440
9441 2017-03-27 Pedro Alves <palves@redhat.com>
9442
9443 * cp-name-parser.y (make_empty): Delete.
9444 (demangler_special, nested_name, ptr_operator, array_indicator)
9445 (direct_declarator, declarator_1): Use fill_comp instead of
9446 make_empty.
9447
9448 2017-03-27 Pedro Alves <palves@redhat.com>
9449
9450 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
9451 to ATTRIBUTE_PRINTF.
9452 * solib-target.c (library_list_start_list): Print "string" not
9453 "version".
9454 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
9455 gdb_xml_error call.
9456
9457 2017-03-27 Pedro Alves <palves@redhat.com>
9458
9459 * dwarf2read.c (struct file_and_directory): New.
9460 (dwarf2_get_dwz_file): Adjust to use std::string.
9461 (dw2_get_file_names_reader): Adjust to use file_and_directory.
9462 (find_file_and_directory): Adjust to return a file_and_directory
9463 object.
9464 (read_file_scope): Adjust to use file_and_directory. Remove
9465 make_cleanup/do_cleanups calls.
9466 (open_and_init_dwp_file): Adjust to use std::string. Remove
9467 make_cleanup/do_cleanups calls.
9468 * python/python.c (do_start_initialization): Adjust to ldirname
9469 returning a std::string.
9470 * utils.c (ldirname): Now returns a std::string.
9471 * utils.h (ldirname): Change return type to std::string.
9472 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
9473 returning a std::string.
9474 * xml-tdesc.c (file_read_description_xml): Likewise.
9475
9476 2017-03-24 Alan Hayward <alan.hayward@arm.com>
9477
9478 * regcache.c (regcache_debug_print_register): New function.
9479 * regcache.h (regcache_debug_print_register): New declaration.
9480 * target.c (debug_print_register): Remove.
9481 (target_fetch_registers): Call regcache_debug_print_register.
9482 (target_store_registers): Likewise.
9483
9484 2017-03-24 Pádraig Brady <pbrady@fb.com>
9485
9486 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
9487 reference beyond the 'lh->include_dirs' array before accessing to
9488 it.
9489 (psymtab_include_file_name): Likewise.
9490 (dwarf_decode_lines_1): Likewise.
9491 (dwarf_decode_lines): Likewise.
9492 (file_file_name): Likewise.
9493
9494 2017-03-23 Simon Marchi <simon.marchi@ericsson.com>
9495
9496 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
9497 inferior_ptid.
9498 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
9499 ps_lsetfpregs): Likewise.
9500 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
9501 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
9502 ps_lsetfpregs): Likewise.
9503 * target.c (target_fetch_registers, target_store_registers):
9504 Remove asserts.
9505
9506 2017-03-23 Alan Hayward <alan.hayward@arm.com>
9507
9508 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
9509
9510 2017-03-23 Yao Qi <yao.qi@linaro.org>
9511
9512 * aarch64-tdep.c (aarch64_process_record_test): Declare.
9513 (_initialize_aarch64_tdep): Register it.
9514 (aarch64_record_load_store): Handle PRFM instruction.
9515 (aarch64_process_record_test): New function.
9516
9517 2017-03-23 Yao Qi <yao.qi@linaro.org>
9518
9519 * aarch64-tdep.c (aarch64_record_load_store): Fix code
9520 indentation.
9521
9522 2017-03-23 Yao Qi <yao.qi@linaro.org>
9523
9524 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
9525
9526 2017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9527
9528 python/python.c (do_start_initialization): Fix memory leak.
9529
9530 2017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
9531
9532 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
9533 using get_ptrace_pid.
9534 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
9535 inferior_ptid.
9536 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
9537 inferior_ptid instead of pid.
9538
9539 2017-03-22 Yao Qi <yao.qi@linaro.org>
9540
9541 * aarch64-tdep.c: Wrap locally used classes in anonymous
9542 namespace.
9543 * arm-tdep.c: Likewise.
9544 * linespec.c: Likewise.
9545 * ui-out.c: Likewise.
9546
9547 2017-03-22 Jonah Graham <jonah@kichwacoders.com>
9548
9549 PR gdb/19637
9550 * python/lib/gdb/printer/bound_registers.py: Import sys.
9551
9552 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
9553
9554 * windows-nat.c (do_windows_fetch_inferior_registers): Add
9555 windows_thread_info parameter and use it instead of
9556 current_thread.
9557 (windows_fetch_inferior_registers): Don't set current_thread,
9558 pass the thread to do_windows_fetch_inferior_registers. Use
9559 ptid from regcache instead of inferior_ptid.
9560 (do_windows_store_inferior_registers): Add windows_thread_info
9561 parameter and use it instead of current_thread.
9562 (windows_store_inferior_registers): Don't set current_thread,
9563 pass the thread to do_windows_store_inferior_registers. Use
9564 ptid from regcache instead of inferior_ptid.
9565
9566 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
9567
9568 * ser-mingw.c (ser_windows_raw): Remove reference to
9569 struct serial::current_timeout.
9570
9571 2017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
9572
9573 PR tdep/20928
9574 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
9575 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
9576 (sparc64_fsr_type): Fix %fsr decoding.
9577
9578 2017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
9579
9580 * python/py-record-btrace.c (btpy_insn_data): Change return type
9581 for Python 2.
9582
9583 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
9584
9585 * spu-linux-nat.c (spu_fetch_inferior_registers,
9586 spu_store_inferior_registers): Use ptid from regcache, set and
9587 restore inferior_ptid.
9588 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
9589 Likewise.
9590
9591 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
9592
9593 * i386-linux-nat.c (fetch_register, store_register,
9594 i386_linux_fetch_inferior_registers,
9595 i386_linux_store_inferior_registers): Use ptid from regcache.
9596 * ia64-linux-nat.c (ia64_linux_fetch_register,
9597 ia64_linux_store_register): Likewise.
9598 * inf-ptrace.c (inf_ptrace_fetch_register,
9599 inf_ptrace_store_register): Likewise.
9600 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
9601 m32r_linux_store_inferior_registers): Likewise.
9602 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
9603 m68kbsd_store_inferior_registers): Likewise.
9604 * m68k-linux-nat.c (fetch_register, store_register,
9605 m68k_linux_fetch_inferior_registers,
9606 m68k_linux_store_inferior_registers): Likewise.
9607 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
9608 m88kbsd_store_inferior_registers): Likewise.
9609 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
9610 mips_fbsd_store_inferior_registers): Likewise.
9611 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
9612 mips64_linux_regsets_store_registers): Likewise.
9613 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
9614 mipsnbsd_store_inferior_registers): Likewise.
9615 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
9616 mips64obsd_store_inferior_registers): Likewise.
9617 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
9618 Likewise.
9619 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
9620 ppcfbsd_store_inferior_registers): Likewise.
9621 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
9622 ppc_linux_store_inferior_registers): Likewise.
9623 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
9624 ppcnbsd_store_inferior_registers): Likewise.
9625 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
9626 ppcobsd_store_registers): Likewise.
9627 * procfs.c (procfs_fetch_registers, procfs_store_registers):
9628 Likewise.
9629 * ravenscar-thread.c (ravenscar_fetch_registers,
9630 ravenscar_store_registers, ravenscar_prepare_to_store):
9631 Likewise.
9632 * record-btrace.c (record_btrace_fetch_registers,
9633 record_btrace_store_registers, record_btrace_prepare_to_store):
9634 Likewise.
9635 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
9636 Lookup inferior using ptid from regcache, instead of
9637 current_inferior.
9638 * remote.c (remote_fetch_registers, remote_store_registers): Use
9639 ptid from regcache.
9640 * rs6000-nat.c (fetch_register, store_register): Likewise.
9641 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
9642 s390_linux_store_inferior_registers): Likewise.
9643 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
9644 shnbsd_store_inferior_registers): Likewise.
9645 * sol-thread.c (sol_thread_fetch_registers,
9646 sol_thread_store_registers): Likewise.
9647 * sparc-nat.c (sparc_fetch_inferior_registers,
9648 sparc_store_inferior_registers): Likewise.
9649 * tilegx-linux-nat.c (fetch_inferior_registers,
9650 store_inferior_registers): Likewise.
9651 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
9652 vaxbsd_store_inferior_registers): Likewise.
9653 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
9654 store_xtregs): Likewise.
9655
9656 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9657
9658 PR gdb/14441
9659 * NEWS: Mention support for rvalue references in GDB and python.
9660 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
9661 supports both lvalue and rvalue references.
9662
9663 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9664
9665 PR gdb/14441
9666 * gdbtypes.c (rank_one_type): Implement overloading
9667 resolution rules regarding rvalue references.
9668
9669 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9670
9671 PR gdb/14441
9672 * aarch64-tdep.c (aarch64_type_align)
9673 (aarch64_extract_return_value, aarch64_store_return_value): Change
9674 lvalue reference type checks to general reference type checks.
9675 * amd64-tdep.c (amd64_classify): Likewise.
9676 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
9677 Likewise.
9678 * arm-tdep.c (arm_type_align, arm_extract_return_value)
9679 (arm_store_return_value): Likewise.
9680 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
9681 * c-typeprint.c (c_print_type): Likewise.
9682 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
9683 (cplus_number_of_children, cplus_describe_child): Likewise.
9684 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
9685 * completer.c (expression_completer): Likewise.
9686 * cp-support.c (make_symbol_overload_list_adl_namespace):
9687 Likewise.
9688 * darwin-nat-info.c (info_mach_region_command): Likewise.
9689 * dwarf2loc.c (entry_data_value_coerce_ref)
9690 (value_of_dwarf_reg_entry): Likewise.
9691 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
9692 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
9693 Likewise.
9694 * findvar.c (extract_typed_address, store_typed_address):
9695 Likewise.
9696 * gdbtypes.c (rank_one_type): Likewise.
9697 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
9698 * infcall.c (value_arg_coerce): Likewise.
9699 * language.c (pointer_type): Likewise.
9700 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
9701 Likewise.
9702 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
9703 * mn10300-tdep.c (mn10300_type_align): Likewise.
9704 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
9705 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
9706 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
9707 Likewise.
9708 * printcmd.c (print_formatted, x_command): Likewise.
9709 * python/py-type.c (typy_get_composite, typy_template_argument):
9710 Likewise.
9711 * python/py-value.c (valpy_referenced_value)
9712 (valpy_get_dynamic_type, value_has_field): Likewise.
9713 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
9714 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
9715 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
9716 * spu-tdep.c (spu_scalar_value_p): Likewise.
9717 * symtab.c (lookup_symbol_aux): Likewise.
9718 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
9719 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
9720 Likewise.
9721 * valops.c (value_cast_pointers, value_cast)
9722 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
9723 (value_struct_elt, value_struct_elt_bitpos)
9724 (value_find_oload_method_list, find_overload_match)
9725 (value_rtti_indirect_type): Likewise.
9726 * valprint.c (val_print_scalar_type_p, generic_val_print):
9727 Likewise.
9728 * value.c (value_actual_type, value_as_address, unpack_long)
9729 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
9730 (coerce_ref): Likewise.
9731 * varobj.c (varobj_get_value_type): Likewise.
9732
9733 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9734
9735 PR gdb/14441
9736 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
9737 table of constants.
9738 * python/lib/gdb/command/explore.py: Support exploring values
9739 of rvalue reference types.
9740 * python/lib/gdb/types.py: Implement get_basic_type() for
9741 rvalue reference types.
9742 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
9743 constant.
9744 * python/py-value.c (valpy_getitem): Add an rvalue reference
9745 check.
9746 (valpy_reference_value): Add new parameter "refcode".
9747 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
9748 New wrappers for valpy_reference_value().
9749 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
9750 (gdbpy_invoke_xmethod): Likewise.
9751
9752 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9753
9754 PR gdb/14441
9755 * dwarf2read.c (process_die, read_type_die_1): Handle the
9756 DW_TAG_rvalue_reference_type DIE.
9757 (read_tag_reference_type): Add new parameter "refcode".
9758
9759 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9760
9761 PR gdb/14441
9762 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
9763 (c_type_print_modifier, c_type_print_varspec_suffix)
9764 (c_type_print_base): Support printing rvalue reference types.
9765 * c-valprint.c (c_val_print, c_value_print): Support printing
9766 rvalue reference values.
9767
9768 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9769
9770 PR gdb/14441
9771 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
9772 typename.
9773 * cp-support.c (replace_typedefs): Handle
9774 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
9775 * python/py-type.c (typy_lookup_type): Likewise.
9776
9777 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9778
9779 PR gdb/14441
9780 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
9781 * parse.c (insert_type): Change assert statement.
9782 (follow_types): Handle rvalue reference types.
9783 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
9784 constant.
9785
9786 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9787
9788 PR gdb/14441
9789 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
9790 value_ref() interface.
9791 * c-valprint.c (c_value_print): Likewise.
9792 * infcall.c (value_arg_coerce): Likewise.
9793 * python/py-value.c (valpy_reference_value): Likewise.
9794 * valops.c (value_cast, value_reinterpret_cast)
9795 (value_dynamic_cast, typecmp): Likewise.
9796 (value_ref): Parameterize by kind of return value reference type.
9797 * value.h (value_ref): Add new parameter "refcode".
9798
9799 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9800
9801 PR gdb/14441
9802 * dwarf2read.c (read_tag_reference_type): Use
9803 lookup_lvalue_reference_type() instead of lookup_reference_type().
9804 * eval.c (evaluate_subexp_standard): Likewise.
9805 * f-exp.y: Likewise.
9806 * gdbtypes.c (make_reference_type, lookup_reference_type):
9807 Generalize with rvalue reference types.
9808 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
9809 convenience wrappers for lookup_reference_type().
9810 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
9811 reference kind parameter.
9812 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
9813 wrappers for lookup_reference_type().
9814 * guile/scm-type.c (gdbscm_type_reference): Use
9815 lookup_lvalue_reference_type() instead of lookup_reference_type().
9816 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
9817 * parse.c (follow_types): Likewise.
9818 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
9819 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
9820 Likewise.
9821 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
9822 (gdbpy_invoke_xmethod): Likewise.
9823 * stabsread.c: Provide extra argument to make_reference_type()
9824 call.
9825 * valops.c (value_ref, value_rtti_indirect_type): Use
9826 lookup_lvalue_reference_type() instead of lookup_reference_type().
9827
9828 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9829
9830 PR gdb/14441
9831 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
9832 (TYPE_IS_REFERENCE): New macro.
9833 (struct type): Add rvalue_reference_type field.
9834 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
9835
9836 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
9837
9838 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
9839 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
9840 New function definition.
9841 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
9842 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
9843 New function declaration.
9844 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
9845 * mi/mi-interp.h: New file.
9846 * solib.c (info_sharedlibrary_command): Replace for loop with
9847 ALL_SO_LIBS macro
9848 * solib.h (update_solib_list): New function declaration.
9849 (so_list_head): Move macro.
9850 * solist.h (ALL_SO_LIBS): New macro.
9851
9852 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
9853
9854 * infcmd.c (post_create_inferior): Remove unused argument in
9855 call to solib_add.
9856 * remote.c (remote_start_remote): Likewise.
9857 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
9858 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
9859 (enable_break): Likewise.
9860 * solib.c (update_solib_list): Remove unused target argument
9861 and its documentation.
9862 (solib_add): Remove unused target argument. Remove unused
9863 argument in call to update_solib_list.
9864 (info_sharedlibrary_command): Remove unused argument in call
9865 to update_solib_list.
9866 (sharedlibrary_command): Remove unused argument in call to
9867 solib_add.
9868 (handle_solib_event): Likewise.
9869 (reload_shared_libraries): Likewise.
9870 * solib.h (solib_add): Remove unused target argument.
9871
9872 2017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
9873
9874 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
9875 (s390_displaced_step_fixup): Cover relative branches with the
9876 default fixup handling. This fixes lack of support for some
9877 relative branch instructions.
9878
9879 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9880
9881 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
9882 ptid from regcache.
9883
9884 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9885
9886 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
9887 i386_darwin_store_inferior_registers): Use ptid from regcache.
9888
9889 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9890
9891 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
9892 i386bsd_store_inferior_registers): Use ptid from regcache.
9893
9894 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9895
9896 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
9897 hppaobsd_store_registers): Use ptid from regcache.
9898
9899 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9900
9901 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
9902 hppanbsd_store_registers): Use ptid from regcache.
9903
9904 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9905
9906 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
9907 from regcache. Use get_ptrace_pid.
9908
9909 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9910
9911 * corelow.c (get_core_register_section): Use ptid from regcache,
9912 update doc.
9913
9914 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9915
9916 * bsd-uthread.c (bsd_uthread_fetch_registers,
9917 bsd_uthread_store_registers): Use ptid from regcache, set and
9918 restore inferior_ptid.
9919
9920 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9921
9922 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
9923 fetch_fp_regs, store_register, store_regs, store_fp_register,
9924 store_fp_regs): Use ptid from regcache.
9925
9926 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9927
9928 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
9929 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
9930 store_vfp_regs): Use ptid from regcache.
9931
9932 2017-03-17 Pedro Alves <palves@redhat.com>
9933
9934 PR remote/21188
9935 * ser-base.c (ser_base_wait_for): Add comment.
9936 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
9937 version.
9938 * ser-unix.c (hardwire_raw): Remove reference to
9939 scb->current_timeout.
9940 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
9941 (hardwire_ops): Install ser_base_readchar instead of
9942 hardwire_readchar.
9943 * serial.h (struct serial) <current_timeout, timeout_remaining>:
9944 Remove fields.
9945
9946 2017-03-17 Jonah Graham <jonah@kichwacoders.com>
9947
9948 PR gdb/19637
9949 * python/lib/gdb/printer/bound_registers.py: Add support for
9950 Python 3.
9951
9952 2017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
9953
9954 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
9955 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
9956 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
9957 byte_offset to subobj_byte_offset. Fix the handling of
9958 DWARF_VALUE_STACK on big-endian targets when coming via an
9959 implicit pointer.
9960 (dwarf2_evaluate_loc_desc): Adjust call to
9961 dwarf2_evaluate_loc_desc_full.
9962 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
9963 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
9964
9965 2017-03-16 Yao Qi <yao.qi@linaro.org>
9966
9967 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
9968 and REVSH instructions.
9969
9970 2017-03-16 Yao Qi <yao.qi@linaro.org>
9971
9972 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
9973 (arm_record_test): Declare.
9974 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
9975 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
9976 align with the manual.
9977 (thumb_record_misc): Adjust the code order to align with the
9978 manual.
9979 (thumb2_record_decode_insn_handler): Fix instruction matching.
9980 (instruction_reader_thumb): New class.
9981 (arm_record_test): New function.
9982
9983 2017-03-16 Yao Qi <yao.qi@linaro.org>
9984
9985 * arm-tdep.c (abstract_memory_reader): New class.
9986 (instruction_reader): New class.
9987 (extract_arm_insn): Add argument 'reader'. Callers updated.
9988 (decode_insn): Likewise.
9989
9990 2017-03-16 Doug Evans <dje@google.com>
9991
9992 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
9993 member. Change type of TYPE member to SCM. All uses updated.
9994 (lsscm_make_lazy_string_smob): Add assert.
9995 (lsscm_make_lazy_string): Flag bad length values.
9996 (lsscm_elt_type): New function.
9997 (gdbscm_lazy_string_to_value): Rewrite to use
9998 lsscm_safe_lazy_string_to_value.
9999 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
10000 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
10001 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
10002 in incoming type.
10003 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
10004 * guile/scm-type.c (tyscm_scm_to_type): New function.
10005
10006 2017-03-15 Doug Evans <dje@google.com>
10007
10008 PR python/17728, python/18439, python/18779
10009 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
10010 member. Change type of TYPE member to PyObject *. All uses updated.
10011 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
10012 (gdbpy_create_lazy_string_object): Flag bad length values.
10013 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
10014 Handle typedefs in incoming type.
10015 (stpy_lazy_string_elt_type): New function.
10016 (gdbpy_extract_lazy_string): Call it.
10017 * python/py-value.c (valpy_lazy_string): Flag bad length values.
10018 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
10019 typedefs in incoming type.
10020
10021 2017-03-16 Doug Evans <dje@google.com>
10022
10023 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
10024 * guile/scm-type.c (tyscm_scm_to_type): New function.
10025
10026 2017-03-16 Jiong Wang <jiong.wang@arm.com>
10027
10028 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
10029 "ULONGEST" for "skip".
10030
10031 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
10032
10033 PR gdb/21220
10034 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
10035 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
10036 (inf_ptrace_peek_poke): ...here. New function. Now also loop
10037 over ptrace peek/poke until end of buffer or error.
10038
10039 2017-03-14 Simon Marchi <simon.marchi@ericsson.com>
10040
10041 * parse.c (length_of_subexp): Make static.
10042 * parser-defs.h (length_of_subexp): Remove.
10043
10044 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
10045
10046 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
10047 as well.
10048
10049 2017-03-14 Pedro Alves <palves@redhat.com>
10050
10051 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
10052 (main): Use std::unique_ptr. Remove calls to
10053 cp_demangled_name_parse_free.
10054
10055 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
10056
10057 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
10058 alphabsd_store_inferior_registers): Use regcache->ptid instead
10059 of inferior_ptid.
10060
10061 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
10062
10063 * aix-thread.c (aix_thread_fetch_registers,
10064 aix_thread_store_registers): Use regcache->ptid instead of
10065 inferior_ptid.
10066
10067 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
10068
10069 * aarch64-linux-nat.c (fetch_gregs_from_thread,
10070 store_gregs_to_thread, fetch_fpregs_from_thread,
10071 store_fpregs_to_thread): Use regcache->ptid instead of
10072 inferior_ptid.
10073
10074 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
10075
10076 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
10077 amd64_linux_fetch_inferior_registers): Use regcache->ptid
10078 instead of inferior_ptid.
10079
10080 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
10081
10082 * target.c (target_fetch_registers, target_store_registers): Add
10083 assert.
10084
10085 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
10086
10087 * regcache.h (regcache_get_ptid): New function.
10088 * regcache.c (regcache_get_ptid): New function.
10089
10090 2017-03-13 Mark Wielaard <mark@klomp.org>
10091
10092 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
10093
10094 2017-03-10 Keith Seitz <keiths@redhat.com>
10095
10096 PR c++/8218
10097 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
10098
10099 2017-03-08 Pedro Alves <palves@redhat.com>
10100
10101 PR gdb/18360
10102 * infrun.c (start_step_over, do_target_resume, resume)
10103 (restart_threads): Assert we're not resuming a thread that is
10104 meant to be stopped.
10105 (infrun_thread_stop_requested_callback): Delete.
10106 (infrun_thread_stop_requested): If the thread is internally
10107 stopped, queue a pending stop event and clear the thread's
10108 inline-frame state.
10109 (handle_stop_requested): New function.
10110 (handle_syscall_event, handle_inferior_event_1): Use
10111 handle_stop_requested.
10112 (handle_stop_requested): New function.
10113 (handle_signal_stop): Set the thread's stop_signal here instead of
10114 at caller.
10115 (finish_step_over): Clear step over info unconditionally.
10116 (handle_signal_stop): If the user had interrupted the event
10117 thread, consider the stop a random signal.
10118 (handle_signal_stop) <signal arrived while stepping over
10119 breakpoint>: Don't restart threads here.
10120 (stop_waiting): Don't clear step-over info here.
10121
10122 2017-03-08 Pedro Alves <palves@redhat.com>
10123
10124 PR 21206
10125 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
10126 goes to argument 2, not 1.
10127
10128 2017-03-08 Pedro Alves <palves@redhat.com>
10129
10130 PR cli/21218
10131 * top.c (gdb_readline_wrapper): Avoid passing NULL to
10132 display_gdb_prompt.
10133 (command_line_input): Add comment.
10134
10135 2017-03-08 Pedro Alves <palves@redhat.com>
10136
10137 PR tui/21216
10138 * tui/tui-file.c (tui_file::write): New.
10139 * tui/tui-file.h (tui_file): Override "write".
10140 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
10141 factored out from ...
10142 (tui_puts): ... here.
10143 (tui_putc): Use them.
10144 (tui_write): New function.
10145 * tui/tui-io.h (tui_write): Declare.
10146
10147 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
10148
10149 * Makefile.in (SFILES): Replace "environ.c" with
10150 "common/environ.c".
10151 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
10152 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
10153 to...
10154 * common/environ.c: ... here.
10155 * environ.h: Moved to...
10156 * common/environ.h: ... here.
10157
10158 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
10159
10160 * gdbarch.sh (pstring_ptr): New static function.
10161 (gdbarch_disassembler_options): Use it.
10162 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
10163 not valid_disassembler_option->name.
10164 * gdbarch.c: Regenerate.
10165
10166 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
10167
10168 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
10169
10170 2017-03-07 Pedro Alves <palves@redhat.com>
10171
10172 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
10173
10174 2017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
10175
10176 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
10177 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
10178 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
10179 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
10180
10181 2017-03-06 Simon Marchi <simon.marchi@ericsson.com>
10182
10183 * xtensa-linux-nat.c (fetch_gregs): Remove const.
10184
10185 2017-03-03 Simon Marchi <simon.marchi@ericsson.com>
10186
10187 * remote.c (remote_add_target_side_commands): Use range-based
10188 for loop.
10189
10190 2017-03-03 Yao Qi <yao.qi@linaro.org>
10191
10192 PR gdb/21165
10193 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
10194 value is lazy.
10195 * valprint.c (common_val_print): Likewise.
10196
10197 2017-02-28 Peter Bergner <bergner@vnet.ibm.com>
10198
10199 * NEWS: Mention new set/show disassembler-options commands.
10200 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
10201 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
10202 (prospective_options): New static variable.
10203 (gdb_disassembler::gdb_disassembler): Initialize
10204 m_di.disassembler_options.
10205 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
10206 (get_disassembler_options): New function.
10207 (set_disassembler_options): Likewise.
10208 (set_disassembler_options_sfunc): Likewise.
10209 (show_disassembler_options_sfunc): Likewise.
10210 (disassembler_options_completer): Likewise.
10211 (_initialize_disasm): Likewise.
10212 * disasm.h (get_disassembler_options): New prototype.
10213 (set_disassembler_options): Likewise.
10214 * gdbarch.sh (gdbarch_disassembler_options): New variable.
10215 (gdbarch_verify_disassembler_options): Likewise.
10216 * gdbarch.c: Regenerate.
10217 * gdbarch.h: Likewise.
10218 * arm-tdep.c (num_disassembly_options): Delete.
10219 (set_disassembly_style): Likewise.
10220 (arm_disassembler_options): New static variable.
10221 (set_disassembly_style_sfunc): Convert short style name into long
10222 option name. Call set_disassembler_options.
10223 (show_disassembly_style_sfunc): New function.
10224 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
10225 set_gdbarch_verify_disassembler_options.
10226 (_initialize_arm_tdep): Delete regnames variable and update callers.
10227 (arm_disassembler_options): Initialize.
10228 (disasm_options): New variable.
10229 (num_disassembly_options): Rename from this...
10230 (num_disassembly_styles): ...to this. Compute by scanning through
10231 disasm_options.
10232 (valid_disassembly_styles): Initialize using disasm_options.
10233 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
10234 set_arm_regname_option.
10235 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
10236 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
10237 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
10238 set_gdbarch_verify_disassembler_options.
10239 * s390-tdep.c (s390_disassembler_options): New static variable.
10240 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
10241 set_gdbarch_verify_disassembler_options.
10242
10243 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
10244
10245 * remote.c (remote_add_target_side_condition): Remove "struct"
10246 keyword from range-based for loop.
10247
10248 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
10249
10250 * remote.c (remote_add_target_side_condition): Use range-based
10251 for loop. Update comment.
10252
10253 2017-02-27 Yao Qi <yao.qi@linaro.org>
10254
10255 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
10256
10257 2017-02-26 Alan Hayward <alan.hayward@arm.com>
10258
10259 * regcache.c (regcache_raw_update): New function.
10260 (regcache_raw_read): Move code to regcache_raw_update.
10261 * regcache.h (regcache_raw_update): New declaration.
10262 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
10263
10264 2017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
10265
10266 * dwarf2read.c (create_debug_type_hash_table): Initialize
10267 header.signature and header.type_offset_in_tu.
10268
10269 2017-02-24 Pedro Alves <palves@redhat.com>
10270
10271 * symtab.c (make_file_symbol_completion_list_1): Use
10272 add_symtab_completions.
10273
10274 2017-02-24 Alan Hayward <alan.hayward@arm.com>
10275
10276 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
10277
10278 2017-02-24 Alan Hayward <alan.hayward@arm.com>
10279
10280 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
10281 I386_MAX_REGISTER_SIZE.
10282 (i386_pseudo_register_write): Likewise.
10283 (i386_process_record): Likewise.
10284 * i387-tdep.c (i387_supply_xsave): Likewise.
10285 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
10286 (store_register): Likewise.
10287
10288 2017-02-23 Pedro Alves <palves@redhat.com>
10289
10290 * ada-lang.c: Include "common/function-view.h".
10291 (ada_iterate_over_symbols): Adjust to use function_view as
10292 callback type.
10293 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
10294 (ada_make_symbol_completion_list): Use a lambda.
10295 (ada_exc_search_name_matches): Delete.
10296 (name_matches_regex): New.
10297 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
10298 * compile/compile-c-support.c: Include "common/function-view.h".
10299 (print_one_macro): Change prototype to accept a ui_file pointer.
10300 (write_macro_definitions): Use a lambda.
10301 * dwarf2read.c: Include "common/function-view.h".
10302 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
10303 (dw2_expand_symtabs_matching): Adjust to use function_view as
10304 callback type.
10305 * language.h: Include "common/function-view.h".
10306 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
10307 function_view as callback type.
10308 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
10309 * linespec.c: Include "common/function-view.h".
10310 (collect_info::add_symbol): New method.
10311 (struct symbol_and_data_callback, iterate_inline_only, struct
10312 symbol_matcher_data, iterate_name_matcher): Delete.
10313 (iterate_over_all_matching_symtabs): Adjust to use function_view
10314 as callback type and lambdas.
10315 (iterate_over_file_blocks): Adjust to use function_view as
10316 callback type.
10317 (decode_compound_collector): Now a class with private fields.
10318 (decode_compound_collector::release_symbols): New method.
10319 (collect_one_symbol): Rename to...
10320 (decode_compound_collector::operator()): ... this and adjust.
10321 (lookup_prefix_sym): decode_compound_collector construction bits
10322 move to decode_compound_collector ctor. Pass the
10323 decode_compound_collector object directly as callback. Remove
10324 cleanups and use decode_compound_collector::release_symbols
10325 instead.
10326 (symtab_collector): Now a class with private fields.
10327 (symtab_collector::release_symtabs): New method.
10328 (add_symtabs_to_list): Rename to...
10329 (symtab_collector::operator()): ... this and adjust.
10330 (collect_symtabs_from_filename): symtab_collector construction
10331 bits move to symtab_collector ctor. Pass the symtab_collector
10332 object directly as callback. Remove cleanups and use
10333 symtab_collector::release_symtabs instead.
10334 (collect_symbols): Delete.
10335 (add_matching_symbols_to_info): Use lambdas.
10336 * macrocmd.c (print_macro_callback): Delete.
10337 (info_macro_command): Use a lambda.
10338 (info_macros_command): Pass print_macro_definition as callable
10339 directly.
10340 (print_one_macro): Remove 'ignore' parameter.
10341 (macro_list_command): Adjust.
10342 * macrotab.c (macro_for_each_data::fn): Now a function_view.
10343 (macro_for_each_data::user_data): Delete field.
10344 (foreach_macro): Adjust to call the function_view.
10345 (macro_for_each): Adjust to use function_view as callback type.
10346 (foreach_macro_in_scope): Adjust to call the function_view.
10347 (macro_for_each_in_scope): Adjust to use function_view as callback
10348 type.
10349 * macrotab.h: Include "common/function-view.h".
10350 (macro_callback_fn): Declare a prototype instead of a pointer.
10351 Remove "user_data" parameter.
10352 (macro_for_each, macro_for_each_in_scope): Adjust to use
10353 function_view as callback type.
10354 * psymtab.c (partial_map_expand_apply)
10355 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
10356 Adjust to use function_view as callback type and to return bool.
10357 (psym_expand_symtabs_matching): Adjust to use function_view as
10358 callback types.
10359 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
10360 to use function_view as callback type and to return bool.
10361 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
10362 callback types.
10363 * symfile.c (expand_symtabs_matching): Adjust to use function_view
10364 as callback types.
10365 * symfile.h: Include "common/function-view.h".
10366 (expand_symtabs_file_matcher_ftype)
10367 (expand_symtabs_symbol_matcher_ftype)
10368 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
10369 return bool.
10370 (quick_symbol_functions::map_symtabs_matching_filename)
10371 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
10372 function_view as callback type and return bool.
10373 (expand_symtabs_matching): Adjust to use function_view as callback
10374 type.
10375 (maintenance_expand_name_matcher)
10376 (maintenance_expand_file_matcher): Delete.
10377 (maintenance_expand_symtabs): Use lambdas.
10378 * symtab.c (iterate_over_some_symtabs): Adjust to use
10379 function_view as callback types and return bool.
10380 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
10381 of a cleanup.
10382 (lookup_symtab_callback): Delete.
10383 (lookup_symtab): Use a lambda.
10384 (iterate_over_symbols): Adjust to use function_view as callback
10385 type.
10386 (struct search_symbols_data, search_symbols_file_matches)
10387 (search_symbols_name_matches): Delete.
10388 (search_symbols): Use a pair of lambdas.
10389 (struct add_name_data, add_macro_name, symbol_completion_matcher)
10390 (symtab_expansion_callback): Delete.
10391 (default_make_symbol_completion_list_break_on_1): Use lambdas.
10392 * symtab.h: Include "common/function-view.h".
10393 (iterate_over_some_symtabs): Adjust to use function_view as
10394 callback type and return bool.
10395 (iterate_over_symtabs): Adjust to use function_view as callback
10396 type.
10397 (symbol_found_callback_ftype): Remove 'data' parameter and return
10398 bool.
10399 (iterate_over_symbols): Adjust to use function_view as callback
10400 type.
10401
10402 2017-02-23 Pedro Alves <palves@redhat.com>
10403
10404 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
10405 (%.o) <unittests/%.c>: New pattern.
10406 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
10407 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
10408 * common/function-view.h: New file.
10409 * unittests/function-view-selftests.c: New file.
10410 * configure: Regenerate.
10411
10412 2017-02-23 Simon Marchi <simon.marchi@ericsson.com>
10413
10414 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
10415 inferior_ptid.
10416 * go32-nat.c (go32_thread_alive): Likewise.
10417
10418 2017-02-23 Yao Qi <yao.qi@linaro.org>
10419
10420 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
10421 delete.
10422
10423 2017-02-23 Yao Qi <yao.qi@linaro.org>
10424
10425 * varobj.c (varobj_clear_saved_item): Use delete instead of
10426 xfree.
10427 (update_dynamic_varobj_children): Likewise.
10428
10429 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
10430
10431 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
10432
10433 2017-02-21 Simon Marchi <simon.marchi@ericsson.com>
10434
10435 * common/enum-flags.h (enum_flags::enum_flags): Initialize
10436 m_enum_value to 0 in default constructor.
10437
10438 2017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
10439
10440 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
10441 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
10442 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
10443 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
10444 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
10445 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
10446 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
10447 IS_STORE_CONDITIONAL_INSN.
10448
10449 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
10450
10451 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
10452
10453 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10454
10455 * NEWS (Changes since GDB 7.12): Add DWARF-5.
10456
10457 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10458
10459 * dwarf2read.c (skip_one_die, read_attribute_value)
10460 (dwarf2_const_value_attr, dump_die_shallow)
10461 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
10462 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
10463
10464 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10465
10466 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
10467 (dwarf_parse_macro_header): Accept DWARF version 5.
10468 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
10469
10470 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10471
10472 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
10473 DW_AT_GNU_*.
10474 * common/common-exceptions.h (enum errors): Likewise.
10475 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
10476 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
10477 (dwarf_expr_context::execute_stack_op): Likewise.
10478 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
10479 Likewise.
10480 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
10481 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
10482 (show_entry_values_debug, call_site_to_target_addr)
10483 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
10484 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
10485 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
10486 (value_of_dwarf_block_entry, indirect_pieced_value)
10487 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
10488 (disassemble_dwarf_expression): Likewise.
10489 * dwarf2read.c (process_die, inherit_abstract_dies)
10490 (read_call_site_scope): Likewise.
10491 * gdbtypes.h (struct func_type, struct call_site_parameter)
10492 (struct call_site): Likewise.
10493 * stack.c (read_frame_arg): Likewise.
10494 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
10495
10496 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10497
10498 * defs.h (read_unsigned_leb128): New declaration.
10499 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
10500 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
10501 (dwarf2_find_location_expression): Call also
10502 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
10503 * dwarf2loc.h (dwarf2_version): New declaration.
10504 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
10505 rnglists.
10506 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
10507 .debug_rnglists.
10508 (struct dwop_section_names): Add loclists_dwo.
10509 (dwop_section_names): Add .debug_loclists.dwo.
10510 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
10511 (struct dwarf2_per_cu_data): Add dwarf_version.
10512 (struct dwo_sections): Add loclists.
10513 (struct attr_abbrev): Add implicit_const.
10514 (read_indirect_line_string): New declaration.
10515 (read_unsigned_leb128): Delete declaration.
10516 (rcuh_kind): New definition.
10517 (read_and_check_comp_unit_head): Change parameter
10518 is_debug_types_section to section_kind.
10519 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
10520 (read_comp_unit_head): Change parameter abfd to section, add parameter
10521 section_kind. Handle DWARF-5.
10522 (error_check_comp_unit_head): Accept also DWARF version 5.
10523 (read_and_check_comp_unit_head): Change parameter
10524 is_debug_types_section to section_kind.
10525 (read_and_check_type_unit_head): Delete function.
10526 (read_abbrev_offset): Handle DWARF-5.
10527 (create_debug_type_hash_table): Add parameter section_kind. Process
10528 only DW_UT_type. Use signature and type_offset_in_tu from struct
10529 comp_unit_head.
10530 (create_debug_types_hash_table): Update create_debug_type_hash_table
10531 caller.
10532 (create_all_type_units): Call create_debug_type_hash_table.
10533 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
10534 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
10535 caller.
10536 (skip_one_die): Handle DW_FORM_implicit_const.
10537 (dwarf2_rnglists_process): New function.
10538 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
10539 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
10540 (read_attribute_value): Handle DW_FORM_implicit_const,
10541 DW_FORM_line_strp.
10542 (read_attribute): Handle DW_FORM_implicit_const.
10543 (read_indirect_string_at_offset_from): New function from
10544 read_indirect_string_at_offset.
10545 (read_indirect_string_at_offset): Call
10546 read_indirect_string_at_offset_from.
10547 (read_indirect_line_string_at_offset): New function.
10548 (read_indirect_string): New function comment.
10549 (read_indirect_line_string): New function.
10550 (read_unsigned_leb128): Make it global.
10551 (dwarf2_string_attr): Handle DWARF-5.
10552 (add_include_dir_stub, read_formatted_entries): New functions.
10553 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
10554 Handle DWARF-5.
10555 (per_cu_header_read_in): Update read_comp_unit_head caller.
10556 (dwarf2_version): New function.
10557 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
10558 rnglists.
10559 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
10560 fields.
10561
10562 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10563
10564 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
10565
10566 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10567
10568 * dwarf2read.c (dwarf2_ranges_process): New function from
10569 dwarf2_ranges_read.
10570 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
10571 dwarf2_ranges_process.
10572
10573 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10574
10575 * dwarf2read.c (create_debug_type_hash_table): New function from
10576 create_debug_types_hash_table.
10577 (create_debug_types_hash_table): Call create_debug_type_hash_table.
10578 (create_all_type_units, open_and_init_dwo_file): Update
10579 create_debug_types_hash_table callers.
10580
10581 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
10582
10583 PR gdb/16188
10584 * fork-child.c (trace_start_error): Fix thinko. va_end should
10585 refer to 'ap', not 'args'.
10586
10587 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
10588 Pedro Alves <palves@redhat.com>
10589
10590 PR gdb/16188
10591 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
10592 calls succeeded.
10593 * fork-child.c (trace_start_error): New function.
10594 (trace_start_error_with_name): Likewise.
10595 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
10596 * inf-ptrace.c (inf_ptrace_me): Likewise.
10597 * inferior.h (trace_start_error): New prototype.
10598 (trace_start_error_with_name): Likewise.
10599
10600 2017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
10601
10602 PR gdb/21164
10603 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
10604 NULL before using it.
10605 * symmisc.c (maintenance_print_symbols): Likewise.
10606 (maintenance_print_msymbols): Likewise.
10607
10608 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10609
10610 * NEWS: Add record Python bindings entry.
10611
10612 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10613
10614 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
10615 py-record-full.o.
10616 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
10617 * python/py-record-btrace.c, python/py-record-btrace.h,
10618 python/py-record-full.c, python/py-record-full.h: New file.
10619 * python/py-record.c: Add include for py-record-btrace.h and
10620 py-record-full.h.
10621 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
10622 recpy_instruction_history, recpy_function_call_history, recpy_begin,
10623 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
10624 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
10625 New definition.
10626 (gdbpy_initialize_btrace): New export.
10627 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
10628
10629 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10630
10631 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
10632 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
10633 * python/py-record.c: New file.
10634 * python/python-internal.h (gdbpy_start_recording,
10635 gdbpy_current_recording, gdpy_stop_recording,
10636 gdbpy_initialize_record): New export.
10637 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
10638 (python_GdbMethods): Add gdbpy_start_recording,
10639 gdbpy_current_recording and gdbpy_stop_recording.
10640
10641 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10642
10643 * record-btrace.c (record_btrace_record_method): New function.
10644 (init_record_btrace_ops): Initialize to_record_method.
10645 * record-full.c (record_full_record_method): New function.
10646 (init_record_full_ops, init_record_full_core_ops): Add
10647 record_full_record_method.
10648 * record.h (enum record_method): New enum.
10649 * target-debug.h (target_debug_print_enum_record_method: New define.
10650 * target-delegates.c: Regenerate.
10651 * target.c (target_record_method): New function.
10652 * target.h: Include record.h.
10653 (struct target_ops) <to_record_method>: New field.
10654 (target_record_method): New export.
10655
10656 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10657
10658 * record.h (record_start, record_stop): New export.
10659 * record.c (record_start, record_stop): New function.
10660
10661 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10662
10663 * btrace.c (btrace_fetch): Copy function call segments pointer
10664 into a vector.
10665 (btrace_clear): Clear the vector.
10666 (btrace_find_insn_by_number): Use binary search to find the correct
10667 function call segment.
10668 * btrace.h (brace_fun_p): New typedef.
10669 (struct btrace_thread_info) <functions>: New field.
10670
10671 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10672
10673 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
10674 * btrace.c (btrace_decode_error): ... here. New function.
10675 * btrace.h (btrace_decode_error): New export.
10676
10677 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10678
10679 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
10680 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
10681 btrace_find_insn_by_number): Remove special case for gaps.
10682 * btrace.h (btrace_insn_get_error): New export.
10683 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
10684 * record-btrace.c (btrace_insn_history): Print number for gaps.
10685 (record_btrace_info, record_btrace_goto): Handle gaps.
10686
10687 2017-02-14 Tom Tromey <tom@tromey.com>
10688
10689 PR python/13598:
10690 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
10691 event.
10692 * python/py-evts.c (gdbpy_initialize_py_events): Add
10693 before_prompt registry.
10694 * python/py-events.h (events_object) <before_prompt>: New field.
10695
10696 2017-02-14 Markus Metzger <markus.t.metzger@intel.com>
10697
10698 * btrace.c (ftrace_new_switch): Preserve up link and flags.
10699
10700 2017-02-13 Luis Machado <lgustavo@codesourcery.com>
10701
10702 * symfile (_initialize_symfile): Add usage text to the load command's
10703 help text.
10704
10705 2017-02-10 Simon Marchi <simon.marchi@ericsson.com>
10706
10707 * utils.c (defaulted_query): Don't query on secondary UIs.
10708
10709 2017-02-10 Tom Tromey <tom@tromey.com>
10710
10711 * rust-lang.c (rust_get_disr_info): Remove unused variable.
10712
10713 2017-02-10 Tom Tromey <tom@tromey.com>
10714
10715 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
10716 "cleanup" local.
10717 * python/py-type.c (typy_legacy_template_argument): Remove
10718 unnecessary "cleanup" local.
10719
10720 2017-02-10 Tom Tromey <tom@tromey.com>
10721
10722 * python/python.c (do_start_initialization): New function, from
10723 _initialize_python.
10724 (_initialize_python): Call do_start_initialization.
10725 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
10726 goto.
10727
10728 2017-02-10 Tom Tromey <tom@tromey.com>
10729
10730 * python/py-prettyprint.c (pretty_print_one_value): Use
10731 gdbpy_ref.
10732
10733 2017-02-10 Tom Tromey <tom@tromey.com>
10734
10735 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
10736 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
10737 gdbpy_ref.
10738 * python/py-type.c (field_new): Use gdbpy_ref.
10739 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
10740 gdbpy_ref.
10741 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
10742 (py_free_pspace): Likewise.
10743 (pspace_to_pspace_object): Likewise.
10744 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
10745 (py_free_objfile): Likewise.
10746 (objfile_to_objfile_object): Likewise.
10747 * python/py-inferior.c (delete_thread_object): Use
10748 gdbpy_ref.
10749 (infpy_read_memory): Likewise.
10750 (py_free_inferior): Likewise.
10751 * python/py-evtregistry.c (create_eventregistry_object): Use
10752 gdbpy_ref.
10753 * python/py-event.c (create_event_object): Use gdbpy_ref.
10754
10755 2017-02-10 Tom Tromey <tom@tromey.com>
10756
10757 * python/py-ref.h (gdbpy_ref_policy): Now a template.
10758 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
10759 used.
10760 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
10761 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
10762 python/py-exitedevent.c, python/py-finishbreakpoint.c,
10763 python/py-framefilter.c, python/py-function.c,
10764 python/py-inferior.c, python/py-infevents.c,
10765 python/py-linetable.c, python/py-newobjfileevent.c,
10766 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
10767 python/py-signalevent.c, python/py-stopevent.c,
10768 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
10769 python/py-unwind.c, python/py-utils.c, python/py-value.c,
10770 python/py-varobj.c, python/py-xmethods.c, python/python.c,
10771 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
10772
10773 2017-02-10 Tom Tromey <tom@tromey.com>
10774
10775 * ui-out.h (ui_out_emit_type): New class.
10776 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
10777 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
10778 and ui_out_emit_tuple.
10779 (enumerate_locals): Likewise.
10780 (py_mi_print_variables, py_print_locals, py_print_args): Use
10781 ui_out_emit_list.
10782 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
10783 ui_out_emit_list.
10784 * common/gdb_optional.h: New file.
10785
10786 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
10787
10788 * MAINTAINERS (Write After Approval): Update my e-mail address.
10789
10790 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
10791
10792 PR gdb/21122
10793 * breakpoint.c (_initialize_breakpoint): Update the help description
10794 of the 'commands' command to indicate that it takes a list argument.
10795
10796 2017-02-09 Simon Marchi <simon.marchi@ericsson.com>
10797
10798 * interps.c (current_interp_set_logging): Remove "return".
10799
10800 2017-02-09 Gary Benson <gbenson@redhat.com>
10801
10802 * symtab.c (add_symtab_completions): Prevent NULL pointer
10803 dereference.
10804
10805 2017-02-08 Pedro Alves <palves@redhat.com>
10806
10807 * interps.c (interp::interp): Remove reference to quiet_p.
10808 (interp_set): Make static. Remove dead "Switching to" output
10809 code.
10810 (interp_quiet_p, interp_set_quiet): Delete.
10811 (interpreter_exec_cmd): Don't set the interpreter quiet.
10812 * interps.h (interp_quiet_p): Make static.
10813 (class interp) <quiet_p>: Remove field
10814
10815 2017-02-08 Jerome Guitton <guitton@adacore.com>
10816
10817 * cli/cli-decode.c (find_command_name_length): Make it extern.
10818 * cli/cli-decode.h (find_command_name_length): Declare.
10819 * cli/cli-script.c (command_name_equals, line_first_arg):
10820 New functions.
10821 (process_next_line): Use cli-decode to parse command names.
10822 (build_command_line): Make args a constant pointer.
10823
10824 2017-02-08 Jerome Guitton <guitton@adacore.com>
10825
10826 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
10827 Remove case-insensitive search.
10828
10829 2017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
10830
10831 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
10832 at the end of the line. Avoids an ARI warning.
10833
10834 2017-02-06 Luis Machado <lgustavo@codesourcery.com>
10835
10836 * NEWS: Mention support for record/replay of Intel 64 rdrand and
10837 rdseed instructions.
10838 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
10839
10840 2017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
10841
10842 PR tdep/20936
10843 Provide and use sparc32 and sparc64 target description XML files.
10844 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
10845 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
10846 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
10847 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
10848 * features/sparc/sparc32-solaris.xml: New file.
10849 * features/sparc/sparc64-solaris.xml: New file.
10850 * features/sparc/sparc32-solaris.c: Generated.
10851 * features/sparc/sparc64-solaris.c: Generated.
10852 * sparc-tdep.h: Account for differences in target descriptions.
10853 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
10854 (sparc32_register_type): Use target provided registers.
10855 (validate_tdesc_registers): New function.
10856 (sparc32_gdbarch_init): Use tdesc_has_registers.
10857 Set pseudoregister functions.
10858 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
10859 (sparc64_register_type): Use target provided registers.
10860 (sparc64_init_abi): Set pseudoregister functions.
10861
10862 2017-02-03 Tom Tromey <tom@tromey.com>
10863
10864 PR rust/21097:
10865 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
10866 with a single member.
10867
10868 2017-02-03 Pedro Alves <palves@redhat.com>
10869
10870 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
10871 (cli_interp_base::~cli_interp_base): New.
10872 (cli_interp): New struct.
10873 (as_cli_interp): Cast the interp itself to cli_interp.
10874 (cli_interpreter_pre_command_loop): Rename to ...
10875 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
10876 parameter.
10877 (cli_interpreter_init): Rename to ...
10878 (cli_interp::init): ... this. Remove 'self' parameter. Use
10879 boolean. Make extern.
10880 (cli_interpreter_resume): Rename to ...
10881 (cli_interp::resume): ... this. Remove 'data' parameter. Make
10882 extern.
10883 (cli_interpreter_suspend): Rename to ...
10884 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
10885 extern.
10886 (cli_interpreter_exec): Rename to ...
10887 (cli_interp::exec): ... this. Remove 'data' parameter. Make
10888 extern.
10889 (cli_interpreter_supports_command_editing): Rename to ...
10890 (cli_interp_base::supports_command_editing): ... this. Remove
10891 'interp' parameter. Make extern.
10892 (cli_ui_out): Rename to ...
10893 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
10894 Make extern.
10895 (cli_set_logging): Rename to ...
10896 (cli_interp_base::set_logging): ... this. Remove 'interp'
10897 parameter. Make extern.
10898 (cli_interp_procs): Delete.
10899 (cli_interp_factory): Adjust to use "new".
10900 * cli/cli-interp.h: Include "interps.h".
10901 (struct cli_interp_base): New struct.
10902 * interps.c (struct interp): Delete. Fields moved to interps.h.
10903 (interp_new): Delete.
10904 (interp::interp, interp::~interp): New.
10905 (interp_set): Use bool, and return void. Assume the interpreter
10906 has suspend, init and resume methods, and that the all return
10907 void.
10908 (set_top_level_interpreter): interp_set returns void.
10909 (interp_ui_out): Adapt.
10910 (current_interp_set_logging): Adapt.
10911 (interp_data): Delete.
10912 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
10913 (interp_exec): Adapt.
10914 (top_level_interpreter_data): Delete.
10915 * interps.h (interp_init_ftype, interp_resume_ftype)
10916 (interp_suspend_ftype, interp_exec_ftype)
10917 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
10918 (class interp): New.
10919 (interp_new): Delete.
10920 (interp_set): Now returns void. Use bool.
10921 (interp_data, top_level_interpreter_data): Delete.
10922 * mi/mi-common.h: Include interps.h.
10923 (class mi_interp): Inherit from interp. Define a ctor. Declare
10924 init, resume, suspect, exec, interp_ui_out, set_logging and
10925 pre_command_loop methods.
10926 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
10927 (mi_interpreter_init): Rename to ...
10928 (mi_interp::init): ... this. Remove the 'interp' parameter, use
10929 bool, return void and make extern. Adjust.
10930 (mi_interpreter_resume): ... Rename to ...
10931 (mi_interp::resume): ... this. Remove the 'data' parameter,
10932 return void and make extern. Adjust.
10933 (mi_interpreter_suspend): ... Rename to ...
10934 (mi_interp::suspend): ... this. Remove the 'data' parameter,
10935 return void and make extern. Adjust.
10936 (mi_interpreter_exec): ... Rename to ...
10937 (mi_interp::exec): ... this. Remove the 'data' parameter and make
10938 extern. Adjust.
10939 (mi_interpreter_pre_command_loop): ... Rename to ...
10940 (mi_interp::pre_command_loop): ... this. Remove the 'self'
10941 parameter and make extern.
10942 (mi_on_normal_stop_1): Adjust.
10943 (mi_ui_out): Rename to ...
10944 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
10945 parameter and make extern. Adjust.
10946 (mi_set_logging): Rename to ...
10947 (mi_interp::set_logging): ... this. Remove the 'interp'
10948 parameter and make extern. Adjust.
10949 (mi_interp_procs): Delete.
10950 (mi_interp_factory): Adjust to use 'new'.
10951 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
10952 (mi_print_exception, mi_execute_command, mi_load_progress):
10953 Adjust.
10954 * tui/tui-interp.c (tui_interp): New class.
10955 (as_tui_interp): Return a tui_interp pointer.
10956 (tui_on_normal_stop, tui_on_signal_received)
10957 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
10958 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
10959 to use interp::interp_ui_out.
10960 (tui_init): Rename to ...
10961 (tui_interp::init): ... this. Remove the 'self' parameter, use
10962 bool, return void and make extern. Adjust.
10963 (tui_resume): Rename to ...
10964 (tui_interp::resume): ... this. Remove the 'data' parameter,
10965 return void and make extern. Adjust.
10966 (tui_suspend): Rename to ...
10967 (tui_interp::suspend): ... this. Remove the 'data' parameter,
10968 return void and make extern. Adjust.
10969 (tui_ui_out): Rename to ...
10970 (tui_interp::interp_ui_out): ... this. Remove the 'self'
10971 parameter, and make extern. Adjust.
10972 (tui_exec): Rename to ...
10973 (tui_interp::exec): ... this. Remove the 'data' parameter and
10974 make extern.
10975 (tui_interp_procs): Delete.
10976 (tui_interp_factory): Use "new".
10977
10978 2017-02-02 Tom Tromey <tom@tromey.com>
10979
10980 * rust-exp.y (ends_raw_string, space_then_number)
10981 (rust_identifier_start_p): Return bool.
10982 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
10983 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
10984 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
10985 (rust_chartype_p): Return bool.
10986 (val_print_struct, rust_print_struct_def, rust_print_type):
10987 Update.
10988 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
10989 Return bool.
10990
10991 2017-02-02 Tom Tromey <tom@tromey.com>
10992
10993 * rust-lang.c: Reindent.
10994
10995 2017-02-02 Tom Tromey <tom@tromey.com>
10996
10997 * rust-lang.h (rust_crate_for_block): Update.
10998 * rust-lang.c (rust_crate_for_block): Return std::string.
10999 (rust_get_disr_info): Use std:;string, not
11000 gdb::unique_xmalloc_ptr.
11001 * rust-exp.y (crate_name): Update.
11002
11003 2017-02-02 Pedro Alves <palves@redhat.com>
11004
11005 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
11006 field out of gdb_disassembler_test and make it static.
11007
11008 2017-02-02 Pedro Alves <palves@redhat.com>
11009
11010 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
11011 mi1_interp and mi_interp fields.
11012
11013 2017-02-02 Pedro Alves <palves@redhat.com>
11014
11015 * cli/cli-interp.c (struct saved_output_files, saved_output):
11016 Moved from cli/cli-logging.c.
11017 (cli_set_logging): New function.
11018 (cli_interp_procs): Install cli_set_logging.
11019 * cli/cli-interp.h (make_logging_output, cli_set_logging):
11020 Declare.
11021 * cli/cli-logging.c (struct saved_output_files, saved_output):
11022 Moved to cli/cli-interp.c.
11023 (pop_output_files): Don't save outputs here.
11024 (make_logging_output): New function.
11025 (handle_redirections): Don't build tee nor save previous outputs
11026 here.
11027 * interps.c (current_interp_set_logging): Change prototype.
11028 Assume there's always a set_logging_proc method installed.
11029 * interps.h (interp_set_logging_ftype): Change prototype.
11030 (current_interp_set_logging): Change prototype and adjust comment.
11031 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
11032 use make_logging_output.
11033 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
11034 2017-02-02 Pedro Alves <palves@redhat.com>
11035
11036 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
11037 from ...
11038 (set_logging_overwrite): ... here.
11039 (logging_no_redirect_file): Delete.
11040 (set_logging_redirect): Don't handle redirection on the fly.
11041 Instead warn that "logging off" / "logging on" is necessary.
11042 (pop_output_files): Delete references to logging_no_redirect_file.
11043 (show_logging_command): Always speak in terms of what will happen
11044 once logging is reenabled.
11045
11046 2017-02-02 Pedro Alves <palves@redhat.com>
11047
11048 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
11049
11050 2017-02-02 Pedro Alves <palves@redhat.com>
11051
11052 * disasm.c (gdb_pretty_print_insn): Rename to ...
11053 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
11054 Remove gdbarch parameter. Adapt to clear the object's buffers
11055 instead of allocating new buffers, and to print using the object's
11056 gdb_disassembler instead of calling gdb_print_insn.
11057 (dump_insns): Use gdb_pretty_print_disassembler.
11058 * disasm.h (gdb_pretty_print_insn): Delete declaration.
11059 (gdb_pretty_print_disassembler): New class.
11060 * record-btrace.c (btrace_insn_history): Use
11061 gdb_pretty_print_disassembler.
11062
11063 2017-02-02 Pedro Alves <palves@redhat.com>
11064
11065 * ada-lang.c (type_as_string): Use string_file.
11066 * ada-valprint.c (ada_print_floating): Use string_file.
11067 * ada-varobj.c (ada_varobj_scalar_image)
11068 (ada_varobj_get_value_image): Use string_file.
11069 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
11070 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
11071 * breakpoint.c (update_inserted_breakpoint_locations)
11072 (insert_breakpoint_locations, reattach_breakpoints)
11073 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
11074 (print_it_watchpoint): Use string_file.
11075 (save_breakpoints): Use stdio_file.
11076 * c-exp.y (oper): Use string_file.
11077 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
11078 tee_file.
11079 (pop_output_files): Use delete.
11080 (handle_redirections): Use stdio_file and tee_file.
11081 * cli/cli-setshow.c (do_show_command): Use string_file.
11082 * compile/compile-c-support.c (c_compute_program): Use
11083 string_file.
11084 * compile/compile-c-symbols.c (generate_vla_size): Take a
11085 'string_file &' instead of a 'ui_file *'.
11086 (generate_c_for_for_one_variable): Take a 'string_file &' instead
11087 of a 'ui_file *'. Use string_file.
11088 (generate_c_for_variable_locations): Take a 'string_file &'
11089 instead of a 'ui_file *'.
11090 * compile/compile-internal.h (generate_c_for_for_one_variable):
11091 Take a 'string_file &' instead of a 'ui_file *'.
11092 * compile/compile-loc2c.c (push, pushf, unary, binary)
11093 (print_label, pushf_register_address, pushf_register)
11094 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
11095 'ui_file *'. Adjust.
11096 * compile/compile.c (compile_to_object): Use string_file.
11097 * compile/compile.h (compile_dwarf_expr_to_c)
11098 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
11099 'ui_file *'.
11100 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
11101 (replace_typedefs_qualified_name): Use string_file and
11102 obstack_copy0.
11103 * disasm.c (gdb_pretty_print_insn): Use string_file.
11104 (gdb_disassembly): Adjust reference the null_stream global.
11105 (do_ui_file_delete): Delete.
11106 (gdb_insn_length): Use null_stream.
11107 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
11108 * dwarf2loc.c (dwarf2_compile_property_to_c)
11109 (locexpr_generate_c_location, loclist_generate_c_location): Take a
11110 'string_file &' instead of a 'ui_file *'.
11111 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
11112 * dwarf2read.c (do_ui_file_peek_last): Delete.
11113 (dwarf2_compute_name): Use string_file.
11114 * event-top.c (gdb_setup_readline): Use stdio_file.
11115 * gdbarch.sh (verify_gdbarch): Use string_file.
11116 * gdbtypes.c (safe_parse_type): Use null_stream.
11117 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
11118 string_file.
11119 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
11120 'string_file *' instead of a 'ui_file *'.
11121 (gdbscm_arch_disassemble): Use string_file.
11122 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
11123 * guile/scm-ports.c (class ioscm_file_port): Now a class that
11124 inherits from ui_file.
11125 (ioscm_file_port_delete, ioscm_file_port_rewind)
11126 (ioscm_file_port_put): Delete.
11127 (ioscm_file_port_write): Rename to ...
11128 (ioscm_file_port::write): ... this. Remove file_port_magic
11129 checks.
11130 (ioscm_file_port_new): Delete.
11131 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
11132 ui_file_up.
11133 * guile/scm-type.c (tyscm_type_name): Use string_file.
11134 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
11135 Use string_file.
11136 * infcmd.c (print_return_value_1): Use string_file.
11137 * infrun.c (print_target_wait_results): Use string_file.
11138 * language.c (add_language): Use string_file.
11139 * location.c (explicit_to_string_internal): Use string_file.
11140 * main.c (captured_main_1): Use null_file.
11141 * maint.c (maintenance_print_architecture): Use stdio_file.
11142 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
11143 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
11144 event_channel>: Change type to mi_console_file pointer.
11145 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
11146 (mi_console_file_delete): Delete.
11147 (struct mi_console_file): Delete.
11148 (mi_console_file_magic): Delete.
11149 (mi_console_file_new): Delete.
11150 (mi_console_file::mi_console_file): New.
11151 (mi_console_file_delete): Delete.
11152 (mi_console_file_fputs): Delete.
11153 (mi_console_file::write): New.
11154 (mi_console_raw_packet): Delete.
11155 (mi_console_file::flush): New.
11156 (mi_console_file_flush): Delete.
11157 (mi_console_set_raw): Rename to ...
11158 (mi_console_file::set_raw): ... this.
11159 * mi/mi-console.h (class mi_console_file): New class.
11160 (mi_console_file_new, mi_console_set_raw): Delete.
11161 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
11162 (mi_set_logging): Use delete and tee_file. Adjust.
11163 * mi/mi-main.c (output_register): Use string_file.
11164 (mi_cmd_data_evaluate_expression): Use string_file.
11165 (mi_cmd_data_read_memory): Use string_file.
11166 (mi_cmd_execute, print_variable_or_computed): Use string_file.
11167 * mi/mi-out.c (mi_ui_out::main_stream): New.
11168 (mi_ui_out::rewind): Use main_stream and
11169 string_file.
11170 (mi_ui_out::put): Use main_stream and string_file.
11171 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
11172 Allocate a 'string_file' instead.
11173 (mi_out_new): Don't allocate a mem_fileopen stream here.
11174 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
11175 (mi_ui_out::main_stream): Declare method.
11176 * printcmd.c (eval_command): Use string_file.
11177 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
11178 * python/py-arch.c (archpy_disassemble): Use string_file.
11179 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
11180 * python/py-frame.c (frapy_str): Use string_file.
11181 * python/py-framefilter.c (py_print_type, py_print_single_arg):
11182 Use string_file.
11183 * python/py-type.c (typy_str): Use string_file.
11184 * python/py-unwind.c (unwind_infopy_str): Use string_file.
11185 * python/py-value.c (valpy_str): Use string_file.
11186 * record-btrace.c (btrace_insn_history): Use string_file.
11187 * regcache.c (regcache_print): Use stdio_file.
11188 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
11189 * remote.c (escape_buffer): Use string_file.
11190 * rust-lang.c (rust_get_disr_info): Use string_file.
11191 * serial.c (serial_open_ops_1): Use stdio_file.
11192 (do_serial_close): Use delete.
11193 * stack.c (print_frame_arg): Use string_file.
11194 (print_frame_args): Remove local mem_fileopen stream, not used.
11195 (print_frame): Use string_file.
11196 * symmisc.c (maintenance_print_symbols): Use stdio_file.
11197 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
11198 Take a 'string_file *' instead of a 'ui_file *'.
11199 * top.c (new_ui): Use stdio_file and stderr_file.
11200 (free_ui): Use delete.
11201 (execute_command_to_string): Use string_file.
11202 (quit_confirm): Use string_file.
11203 * tracepoint.c (collection_list::append_exp): Use string_file.
11204 * tui/tui-disasm.c (tui_disassemble): Use string_file.
11205 * tui/tui-file.c: Don't include "ui-file.h".
11206 (enum streamtype, struct tui_stream): Delete.
11207 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
11208 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
11209 (tui_file::tui_file): New method.
11210 (tui_file_fputs): Delete.
11211 (tui_file_get_strbuf): Delete.
11212 (tui_file::puts): New method.
11213 (tui_file_adjust_strbuf): Delete.
11214 (tui_file_flush): Delete.
11215 (tui_file::flush): New method.
11216 * tui/tui-file.h: Tweak intro comment.
11217 Include ui-file.h.
11218 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
11219 (tui_file_adjust_strbuf): Delete declarations.
11220 (class tui_file): New class.
11221 * tui/tui-io.c (tui_initialize_io): Use tui_file.
11222 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
11223 (tui_register_format): Use string_stream.
11224 * tui/tui-stack.c (tui_make_status_line): Use string_file.
11225 (tui_get_function_from_frame): Use string_file.
11226 * typeprint.c (type_to_string): Use string_file.
11227 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
11228 (null_stream): New global.
11229 (ui_file_delete): Delete.
11230 (ui_file::ui_file): New.
11231 (null_file_isatty): Delete.
11232 (ui_file::~ui_file): New.
11233 (null_file_rewind): Delete.
11234 (ui_file::printf): New.
11235 (null_file_put): Delete.
11236 (null_file_flush): Delete.
11237 (ui_file::putstr): New.
11238 (null_file_write): Delete.
11239 (ui_file::putstrn): New.
11240 (null_file_read): Delete.
11241 (ui_file::putc): New.
11242 (null_file_fputs): Delete.
11243 (null_file_write_async_safe): Delete.
11244 (ui_file::vprintf): New.
11245 (null_file_delete): Delete.
11246 (null_file::write): New.
11247 (null_file_fseek): Delete.
11248 (null_file::puts): New.
11249 (ui_file_data): Delete.
11250 (null_file::write_async_safe): New.
11251 (gdb_flush, ui_file_isatty): Adjust.
11252 (ui_file_put, ui_file_rewind): Delete.
11253 (ui_file_write): Adjust.
11254 (ui_file_write_for_put): Delete.
11255 (ui_file_write_async_safe, ui_file_read): Adjust.
11256 (ui_file_fseek): Delete.
11257 (fputs_unfiltered): Adjust.
11258 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
11259 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
11260 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
11261 (set_ui_file_data): Delete.
11262 (string_file::~string_file, string_file::write)
11263 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
11264 (do_ui_file_as_string, ui_file_as_string): Delete.
11265 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
11266 (struct mem_file): Delete.
11267 (mem_file_new): Delete.
11268 (stdio_file::stdio_file): New.
11269 (mem_file_delete): Delete.
11270 (stdio_file::stdio_file): New.
11271 (mem_fileopen): Delete.
11272 (stdio_file::~stdio_file): New.
11273 (mem_file_rewind): Delete.
11274 (stdio_file::set_stream): New.
11275 (mem_file_put): Delete.
11276 (stdio_file::open): New.
11277 (mem_file_write): Delete.
11278 (stdio_file_magic, struct stdio_file): Delete.
11279 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
11280 (stdio_file::flush): New.
11281 (stdio_file_read): Rename to ...
11282 (stdio_file::read): ... this. Adjust.
11283 (stdio_file_write): Rename to ...
11284 (stdio_file::write): ... this. Adjust.
11285 (stdio_file_write_async_safe): Rename to ...
11286 (stdio_file::write_async_safe) ... this. Adjust.
11287 (stdio_file_fputs): Rename to ...
11288 (stdio_file::puts) ... this. Adjust.
11289 (stdio_file_isatty): Delete.
11290 (stdio_file_fseek): Delete.
11291 (stdio_file::isatty): New.
11292 (stderr_file_write): Rename to ...
11293 (stderr_file::write) ... this. Adjust.
11294 (stderr_file_fputs): Rename to ...
11295 (stderr_file::puts) ... this. Adjust.
11296 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
11297 (stderr_file::stderr_file): New.
11298 (tee_file_magic): Delete.
11299 (struct tee_file): Delete.
11300 (tee_file::tee_file): New.
11301 (tee_file_new): Delete.
11302 (tee_file::~tee_file): New.
11303 (tee_file_delete): Delete.
11304 (tee_file_flush): Rename to ...
11305 (tee_file::flush): ... this. Adjust.
11306 (tee_file_write): Rename to ...
11307 (tee_file::write): ... this. Adjust.
11308 (tee_file::write_async_safe): New.
11309 (tee_file_fputs): Rename to ...
11310 (tee_file::puts): ... this. Adjust.
11311 (tee_file_isatty): Rename to ...
11312 (tee_file::isatty): ... this. Adjust.
11313 * ui-file.h (struct obstack, struct ui_file): Don't
11314 forward-declare.
11315 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
11316 (ui_file_write_ftype)
11317 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
11318 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
11319 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
11320 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
11321 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
11322 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
11323 (set_ui_file_fseek): Delete.
11324 (ui_file_data, ui_file_delete, ui_file_rewind)
11325 (struct ui_file): New.
11326 (ui_file_up): New.
11327 (class null_file): New.
11328 (null_stream): Declare.
11329 (ui_file_write_for_put, ui_file_put): Delete.
11330 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
11331 Delete.
11332 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
11333 (gdb_fopen, tee_file_new): Delete.
11334 (struct string_file): New.
11335 (struct stdio_file): New.
11336 (stdio_file_up): New.
11337 (struct stderr_file): New.
11338 (class tee_file): New.
11339 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
11340 of a 'ui_file *'. Adjust.
11341 * ui-out.h (class ui_out) <field_stream>: Likewise.
11342 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
11343 (null_stream): Delete.
11344 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
11345 Adjust.
11346 * utils.h (struct ui_file): Delete forward declaration..
11347 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
11348 (error_stream): Take a 'string_file &' instead of a
11349 'ui_file *'.
11350 * varobj.c (varobj_value_get_print_value): Use string_file.
11351 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
11352 * gdbarch.c: Regenerate.
11353
11354 2017-02-02 Pedro Alves <palves@redhat.com>
11355
11356 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
11357 (gdb_pretty_print_insn): ... this. Now a free function. Add back
11358 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
11359 Adjust to call gdb_print_insn instead of
11360 gdb_disassembler::print_insn.
11361 (dump_insns, do_mixed_source_and_assembly_deprecated)
11362 (do_mixed_source_and_assembly, do_assembly_only): Add back a
11363 'gdbarch' parameter. Remove gdb_disassembler parameter.
11364 (gdb_disassembly): Don't allocate a gdb_disassembler here.
11365 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
11366 declaration.
11367 (gdb_pretty_print_insn): Re-add declaration.
11368 * record-btrace.c (btrace_insn_history): Don't allocate a
11369 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
11370
11371 2017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
11372
11373 * disasm.h (gdb_disassembly): Remove file_string parameter.
11374 * disasm.c (gdb_disassembly): Likewise.
11375 * cli/cli-cmds.c (print_disassembly): Adapt.
11376 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
11377 * stack.c (do_gdb_disassembly): Likewise.
11378
11379 2017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
11380
11381 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
11382 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
11383 targets. And if the implicit value is longer than needed, extract
11384 the first bytes instead of the "least significant" ones.
11385
11386 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
11387
11388 * btrace.c (btrace_enable): Do not call btrace_add_pc for
11389 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
11390 (btrace_fetch): Assert can_access_registers_ptid.
11391 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
11392 validate_registers_access.
11393
11394 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
11395
11396 * gdbthread.h (can_access_registers_ptid): New.
11397 * thread.c (can_access_registers_ptid): New.
11398
11399 2017-02-01 Pedro Alves <palves@redhat.com>
11400
11401 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
11402
11403 2017-01-31 Pedro Alves <palves@redhat.com>
11404
11405 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
11406 Fix typos.
11407
11408 2017-01-31 Pedro Alves <palves@redhat.com>
11409
11410 * stack.c (print_frame_args): Remove local mem_fileopen stream,
11411 not used.
11412
11413 2017-01-31 Pedro Alves <palves@redhat.com>
11414
11415 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
11416
11417 2017-01-31 Pedro Alves <palves@redhat.com>
11418
11419 * common/scoped_restore.h
11420 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
11421 change the value's parameter type to T2.
11422 (make_scoped_restore): Likewise.
11423
11424 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
11425 Richard Henderson <rth@redhat.com>
11426
11427 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
11428 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
11429 GS_BASE for older kernels.
11430 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
11431 GS_BASE for older kernels.
11432 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
11433 and GS_BASE to the offset table.
11434 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
11435 system register group.
11436 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
11437 for older kernels.
11438 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
11439 amd64 ABI.
11440 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
11441 AMD64_GSBASE_REGNUM.
11442 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
11443 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
11444 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
11445 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
11446 i386/64bit-segments.xml in those rules.
11447 * features/i386/64bit-segments.xml: New file.
11448 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
11449 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
11450 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
11451 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
11452 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
11453 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
11454 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
11455 * features/i386/amd64-avx-linux.c: Regenerated.
11456 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
11457 * features/i386/amd64-avx-mpx.c: Regenerated.
11458 * features/i386/amd64-avx512-linux.c: Regenerated.
11459 * features/i386/amd64-linux.c: Regenerated.
11460 * features/i386/amd64-mpx-linux.c: Regenerated.
11461 * features/i386/i386-avx-mpx-linux.c: Regenerated.
11462 * features/i386/i386-avx-mpx.c: Regenerated.
11463 * features/i386/x32-avx-linux.c: Regenerated.
11464 * features/i386/x32-avx512-linux.c: Regenerated.
11465 * regformats/i386/amd64-avx-linux.dat: Regenerated.
11466 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
11467 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
11468 * regformats/i386/amd64-linux.dat: Regenerated.
11469 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
11470 * regformats/i386/x32-avx-linux.dat: Regenerated.
11471 * regformats/i386/x32-avx512-linux.dat: Regenerated.
11472 * regformats/i386/x32-linux.dat: Regenerated.
11473
11474 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
11475
11476 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
11477 Set to AMD64_NUM_REGS.
11478
11479 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
11480
11481 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
11482 that checks validity of a register number.
11483
11484 2017-01-27 Kees Cook <keescook@google.com>
11485
11486 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
11487 fetch_fpregs if target has fpa registers.
11488 (arm_linux_store_inferior_registers): Call store_fpregs if target
11489 has fpa registers.
11490
11491 2017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
11492
11493 * cris-tdep.c (cris_gdbarch_init): Remove check for
11494 info.byte_order and force it to BFD_ENDIAN_LITTLE.
11495
11496 2017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
11497
11498 * corelow.c (get_core_register_section): Check for regset
11499 existence before checking for REGSET_VARIABLE_SIZE.
11500
11501 2017-01-26 Yao Qi <yao.qi@linaro.org>
11502 Pedro Alves <palves@redhat.com>
11503
11504 PR gdb/20939
11505 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
11506 call memory_error, save memaddr instead.
11507 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
11508 negative, cal memory_error.
11509 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
11510
11511 2017-01-26 Yao Qi <yao.qi@linaro.org>
11512
11513 * disasm-selftests.c (memory_error_test): New function.
11514 (_initialize_disasm_selftests): Register memory_error_test.
11515
11516 2017-01-26 Yao Qi <yao.qi@linaro.org>
11517
11518 * Makefile.in (SFILES): Add disasm-selftests.c and
11519 selftest-arch.c.
11520 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
11521 * disasm-selftests.c: New file.
11522 * selftest-arch.c: New file.
11523 * selftest-arch.h: New file.
11524
11525 2017-01-26 Yao Qi <yao.qi@linaro.org>
11526
11527 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
11528 to bfd_arch_mep. Don't return 0 if section is not
11529 found. Call print_insn_mep.
11530
11531 2017-01-26 Pedro Alves <palves@redhat.com>
11532 Yao Qi <yao.qi@linaro.org>
11533
11534 * arm-tdep.c: Include "disasm.h".
11535 (gdb_print_insn_arm): Update code to get gdbarch.
11536 * disasm.c (dis_asm_read_memory): Change it to
11537 gdb_disassembler::dis_asm_read_memory.
11538 (dis_asm_memory_error): Likewise.
11539 (dis_asm_print_address): Likewise.
11540 (gdb_pretty_print_insn): Change it to
11541 gdb_disassembler::pretty_print_insn.
11542 (dump_insns): Add one argument gdb_disassemlber. All
11543 callers updated.
11544 (do_mixed_source_and_assembly_deprecated): Likewise.
11545 (do_mixed_source_and_assembly): Likewise.
11546 (do_assembly_only): Likewise.
11547 (gdb_disassembler::gdb_disassembler): New.
11548 (gdb_disassembler::print_insn): New.
11549 * disasm.h (class gdb_disassembler): New.
11550 (gdb_pretty_print_insn): Remove declaration.
11551 (gdb_disassemble_info): Likewise.
11552 * guile/scm-disasm.c (class gdbscm_disassembler): New.
11553 (gdbscm_disasm_read_memory_worker): Update.
11554 (gdbscm_disasm_read_memory): Update.
11555 (gdbscm_disasm_memory_error): Remove.
11556 (gdbscm_disasm_print_address): Remove.
11557 (gdbscm_disassembler::gdbscm_disassembler): New.
11558 (gdbscm_print_insn_from_port): Update.
11559 * mips-tdep.c: Include disasm.h.
11560 (gdb_print_insn_mips): Update code to get gdbarch.
11561 * record-btrace.c (btrace_insn_history): Update.
11562 * spu-tdep.c: Include disasm.h.
11563 (struct spu_dis_asm_data): Remove.
11564 (struct spu_dis_asm_info): New.
11565 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
11566 SPU id.
11567 (gdb_print_insn_spu): Cast disassemble_info to
11568 spu_dis_asm_info.
11569
11570 2017-01-26 Yao Qi <yao.qi@linaro.org>
11571
11572 * disasm.c (do_ui_file_delete): Delete.
11573 (gdb_insn_length): Move code creating stream to ...
11574 * utils.c (null_stream): ... here. New function.
11575 * utils.h (null_stream): Declare.
11576
11577 2017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
11578
11579 * python/py-inferior.c (find_thread_object): Return directly
11580 from the loop. Remove "found" variable.
11581
11582 2017-01-21 Joel Brobecker <brobecker@adacore.com>
11583
11584 GDB 7.12.1 released.
11585
11586 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
11587
11588 * python/py-function.c (fnpy_call): Reorder declarations to have
11589 the gdbpy_enter object declared first.
11590 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
11591
11592 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
11593
11594 PR python/21068
11595 * python/python-internal.h (PyMem_RawMalloc): Define for
11596 Python < 3.4.
11597 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
11598 PyMem_RawMalloc instead of PyMem_Malloc.
11599
11600 2017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
11601 Luis Machado <lgustavo@codesourcery.com>
11602
11603 * NEWS (New commands): Mention flash-erase.
11604 (New MI commands): Mention target-flash-erase.
11605 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
11606 command.
11607 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
11608 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
11609 * target.c (flash_erase_command): New function.
11610 (initialize_targets): Add new flash-erase command.
11611 * target.h (flash_erase_command): New declaration.
11612
11613 2017-01-20 Joel Brobecker <brobecker@adacore.com>
11614
11615 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
11616 HAVE_SYS_PROCFS_H is defined.
11617
11618 2017-01-18 Alan Hayward <alan.hayward@arm.com>
11619
11620 * remote.c (struct cached_reg): Change data into a pointer.
11621 * (stop_reply_dtr): Free data pointers before deleting vector.
11622 (process_stop_reply): Likewise.
11623 (remote_parse_stop_reply): Allocate space for data
11624
11625 2017-01-18 Alan Hayward <alan.hayward@arm.com>
11626
11627 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
11628 MAX_REGISTER_SIZE.
11629 (amd64_pseudo_register_read_value): Likewise.
11630 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
11631 (store_register_using_P): Likewise.
11632 * regcache.c (regcache_xfer_part): Likewise.
11633
11634 2017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
11635
11636 Split real and pseudo registers.
11637 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
11638 (sparc32_pseudo_regnum): New enum.
11639 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
11640 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
11641 (SPARC32_CP0_REGISTERS): New macro.
11642 (sparc32_pseudo_register_name): New function.
11643 (sparc32_register_name): Use sparc32_pseudo_register_name.
11644 (sparc32_pseudo_register_type): New function.
11645 (sparc32_register_type): Use sparc32_pseudo_register_type.
11646 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
11647 pseudo register numbers.
11648 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
11649 (SPARC64_CP0_REGISTERS): New macro.
11650 (sparc64_pseudo_register_name): New function.
11651 (sparc64_register_name): Use sparc64_pseudo_register_name.
11652 (sparc64_pseudo_register_type): New function.
11653 (sparc64_register_type): Use sparc64_pseudo_register_type.
11654 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
11655 pseudo register numbers.
11656 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
11657 sparc64_store_arguments): Handle pseudo register numbers.
11658
11659 2017-01-13 Yao Qi <yao.qi@linaro.org>
11660
11661 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
11662 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
11663 output.
11664 (getpkt_or_notif_sane_1): Likewise.
11665
11666 2017-01-13 Yao Qi <yao.qi@linaro.org>
11667
11668 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
11669 of CC. Pass "-x c++-header" instead of "-x c".
11670
11671 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
11672
11673 * remote.c (remote_can_async_p): Update comment.
11674
11675 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
11676
11677 * linux-nat.c (linux_nat_can_async_p): Update comment.
11678
11679 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
11680
11681 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
11682
11683 2017-01-11 Simon Marchi <simon.marchi@ericsson.com>
11684
11685 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
11686
11687 2017-01-10 Tom Tromey <tom@tromey.com>
11688
11689 * python/py-type.c (typy_legacy_template_argument): Update.
11690 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
11691 ~demangle_parse_info): Declare new members.
11692 (cp_demangled_name_to_comp): Return unique_ptr.
11693 (cp_demangled_name_parse_free)
11694 (make_cleanup_cp_demangled_name_parse_free)
11695 (cp_new_demangle_parse_info): Remove.
11696 * cp-support.c (do_demangled_name_parse_free_cleanup)
11697 (make_cleanup_cp_demangled_name_parse_free): Remove.
11698 (inspect_type, cp_canonicalize_string_full)
11699 (cp_canonicalize_string): Update.
11700 (mangled_name_to_comp): Change return type.
11701 (cp_class_name_from_physname, method_name_from_physname)
11702 (cp_func_name, cp_remove_params): Update.
11703 * cp-name-parser.y (demangle_parse_info): New constructor, from
11704 cp_new_demangle_parse_info.
11705 (~demangle_parse_info): New destructor, from
11706 cp_demangled_name_parse_free.
11707 (cp_merge_demangle_parse_infos): Update.
11708 (cp_demangled_name_to_comp): Change return type.
11709
11710 2017-01-10 Tom Tromey <tom@tromey.com>
11711
11712 * top.c (prevent_dont_repeat): Change return type.
11713 * python/python.c (execute_gdb_command): Use std::string.
11714 Update.
11715 * guile/guile.c (gdbscm_execute_gdb_command): Update.
11716 * command.h (prevent_dont_repeat): Change return type.
11717 * breakpoint.c (bpstat_do_actions_1): Update.
11718
11719 2017-01-10 Tom Tromey <tom@tromey.com>
11720
11721 * value.h (scoped_value_mark::~scoped_value_mark): Call
11722 free_to_mark.
11723 (scoped_value_mark::free_to_mark): New method.
11724 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
11725 scoped_value_mark.
11726
11727 2017-01-10 Tom Tromey <tom@tromey.com>
11728
11729 * python/py-value.c (valpy_dereference, valpy_referenced_value)
11730 (valpy_reference_value, valpy_const_value, valpy_get_address)
11731 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
11732 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
11733 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
11734 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
11735 scoped_value_mark.
11736 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
11737 * value.h (scoped_value_mark): New class.
11738
11739 2017-01-10 Tom Tromey <tom@tromey.com>
11740
11741 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
11742 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
11743 * psymtab.c (discard_psymtabs_upto): Remove.
11744 (make_cleanup_discard_psymtabs): Remove.
11745 (struct psymtab_state): Remove.
11746
11747 2017-01-10 Tom Tromey <tom@tromey.com>
11748
11749 * record-full.c (record_full_save_cleanups): Remove.
11750 (record_full_save): Use gdb::unlinker.
11751 * gcore.c (do_bfd_delete_cleanup): Remove.
11752 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
11753 cleanups.
11754 * dwarf2read.c (unlink_if_set): Remove.
11755 (write_psymtabs_to_index): Use gdb::unlinker.
11756 * common/gdb_unlinker.h: New file.
11757
11758 2017-01-10 Tom Tromey <tom@tromey.com>
11759
11760 * windows-tdep.c (windows_xfer_shared_library): Update.
11761 * windows-nat.c (windows_make_so): Update.
11762 * utils.h (make_cleanup_bfd_unref): Remove.
11763 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
11764 * symfile.h (symfile_bfd_open)
11765 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
11766 * symfile.c (read_symbols, symbol_file_add)
11767 (separate_debug_file_exists): Update.
11768 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
11769 (generic_load, reread_symbols): Update.
11770 * symfile-mem.c (symbol_file_add_from_memory): Update.
11771 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
11772 (spu_symbol_file_add_from_memory): Update.
11773 * solist.h (struct target_so_ops) <bfd_open>: Return
11774 gdb_bfd_ref_ptr.
11775 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
11776 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
11777 gdb_bfd_ref_ptr.
11778 (solib_map_sections, reload_shared_libraries_1): Update.
11779 * solib-svr4.c (enable_break): Update.
11780 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
11781 * solib-frv.c (enable_break2): Update.
11782 * solib-dsbt.c (enable_break): Update.
11783 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
11784 gdb_bfd_ref_ptr.
11785 (darwin_solib_get_all_image_info_addr_at_init): Update.
11786 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
11787 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
11788 * record-full.c (record_full_save): Update.
11789 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
11790 * procfs.c (insert_dbx_link_bpt_in_file): Update.
11791 * minidebug.c (find_separate_debug_file_in_section): Return
11792 gdb_bfd_ref_ptr.
11793 * machoread.c (macho_add_oso_symfile): Change abfd to
11794 gdb_bfd_ref_ptr.
11795 (macho_symfile_read_all_oso): Update.
11796 (macho_check_dsym): Return gdb_bfd_ref_ptr.
11797 (macho_symfile_read): Update.
11798 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
11799 (jit_bfd_try_read_symtab): Update.
11800 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
11801 (gdb_bfd_openw, gdb_bfd_openr_iovec)
11802 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
11803 gdb_bfd_ref_ptr.
11804 (gdb_bfd_ref_policy): New struct.
11805 (gdb_bfd_ref_ptr): New typedef.
11806 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
11807 (gdb_bfd_openw, gdb_bfd_openr_iovec)
11808 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
11809 gdb_bfd_ref_ptr.
11810 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
11811 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
11812 (gcore_command): Update.
11813 * exec.c (exec_file_attach): Update.
11814 * elfread.c (elf_symfile_read): Update.
11815 * dwarf2read.c (dwarf2_get_dwz_file): Update.
11816 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
11817 (open_and_init_dwo_file): Update.
11818 (open_dwp_file): Return gdb_bfd_ref_ptr.
11819 (open_and_init_dwp_file): Update.
11820 * corelow.c (core_open): Update.
11821 * compile/compile-object-load.c (compile_object_load): Update.
11822 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
11823 * coffread.c (coff_symfile_read): Update.
11824 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
11825 gdb_bfd_ref_ptr. Rename.
11826 (dump_bfd_file, restore_command): Update.
11827 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
11828 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
11829 (find_separate_debug_file_by_buildid): Update.
11830
11831 2017-01-10 Tom Tromey <tom@tromey.com>
11832
11833 * common/gdb_ref_ptr.h: New file.
11834 * python/py-ref.h (struct gdbpy_ref_policy): New.
11835 (gdbpy_ref): Now a typedef.
11836
11837 2017-01-10 Tom Tromey <tom@tromey.com>
11838
11839 * utils.h (make_cleanup_htab_delete): Don't declare.
11840 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
11841 Remove.
11842 * linespec.c (decode_compound_collector): Add constructor,
11843 destructor.
11844 (lookup_prefix_sym): Remove cleanup.
11845 (symtab_collector): Add constructor, destructor.
11846 (collect_symtabs_from_filename): Remove cleanup.
11847 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
11848 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
11849 Use htab_up.
11850 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
11851 * dwarf2read.c (dw2_expand_symtabs_matching)
11852 (dw2_map_symbol_filenames, dwarf_decode_macros)
11853 (write_psymtabs_to_index): Use htab_up.
11854 * dwarf2loc.c (func_verify_no_selftailcall)
11855 (call_site_find_chain_1, func_verify_no_selftailcall)
11856 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
11857 std::vector, gdb::unique_xmalloc_ptr.
11858 (call_sitep): Remove typedef.
11859 (dwarf2_locexpr_baton_eval): Remove unused variable.
11860
11861 2017-01-10 Tom Tromey <tom@tromey.com>
11862
11863 * python/python-internal.h (make_cleanup_py_decref)
11864 (make_cleanup_py_xdecref): Don't declare.
11865 * python/py-utils.c (py_decref, make_cleanup_py_decref)
11866 (py_xdecref, make_cleanup_py_xdecref): Remove.
11867
11868 2017-01-10 Tom Tromey <tom@tromey.com>
11869
11870 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
11871 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
11872
11873 2017-01-10 Tom Tromey <tom@tromey.com>
11874
11875 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
11876
11877 2017-01-10 Tom Tromey <tom@tromey.com>
11878
11879 * python/py-utils.c (unicode_to_encoded_string)
11880 (python_string_to_target_string)
11881 (python_string_to_target_python_string)
11882 (python_string_to_host_string, gdbpy_obj_to_string)
11883 (get_addr_from_python): Use gdbpy_ref.
11884
11885 2017-01-10 Tom Tromey <tom@tromey.com>
11886
11887 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
11888 gdbpy_ref.
11889
11890 2017-01-10 Tom Tromey <tom@tromey.com>
11891
11892 * python/python.c (eval_python_command, gdbpy_decode_line)
11893 (gdbpy_run_events, gdbpy_start_type_printers)
11894 (gdbpy_apply_type_printers): Use gdbpy_ref.
11895
11896 2017-01-10 Tom Tromey <tom@tromey.com>
11897
11898 * python/py-param.c (get_doc_string, compute_enum_values): Use
11899 gdbpy_ref.
11900
11901 2017-01-10 Tom Tromey <tom@tromey.com>
11902
11903 * python/py-inferior.c (find_thread_object, build_inferior_list):
11904 Use gdbpy_ref.
11905
11906 2017-01-10 Tom Tromey <tom@tromey.com>
11907
11908 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
11909
11910 2017-01-10 Tom Tromey <tom@tromey.com>
11911
11912 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
11913 gdbpy_ref.
11914
11915 2017-01-10 Tom Tromey <tom@tromey.com>
11916
11917 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
11918 extra incref.
11919 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
11920 Use gdbpy_ref.
11921
11922 2017-01-10 Tom Tromey <tom@tromey.com>
11923
11924 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
11925 gdbpy_ref.
11926
11927 2017-01-10 Tom Tromey <tom@tromey.com>
11928
11929 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
11930 decref results of PyArg_ParseTupleAndKeywords.
11931
11932 2017-01-10 Tom Tromey <tom@tromey.com>
11933
11934 * python/python.c (python_run_simple_file): Use
11935 unique_xmalloc_ptr, gdbpy_ref.
11936
11937 2017-01-10 Tom Tromey <tom@tromey.com>
11938
11939 * python/py-prettyprint.c (print_stack_unless_memory_error)
11940 (print_string_repr, print_children): Use gdbpy_ref.
11941 (dummy_python_frame): New class.
11942 (dummy_python_frame::dummy_python_frame): Rename from
11943 push_dummy_python_frame.
11944 (py_restore_tstate): Remove.
11945
11946 2017-01-10 Tom Tromey <tom@tromey.com>
11947
11948 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
11949
11950 2017-01-10 Tom Tromey <tom@tromey.com>
11951
11952 * python/python.c (ensure_python_env, restore_python_env):
11953 Remove.
11954 * python/python-internal.h (ensure_python_env): Don't declare.
11955 * varobj.h (varobj_ensure_python_env): Don't declare.
11956 * varobj.c (varobj_ensure_python_env): Remove.
11957
11958 2017-01-10 Tom Tromey <tom@tromey.com>
11959
11960 * varobj.c (varobj_value_get_print_value): Use
11961 gdbpy_enter_varobj.
11962
11963 2017-01-10 Tom Tromey <tom@tromey.com>
11964
11965 * python/py-prettyprint.c (print_string_repr, print_children):
11966 Update.
11967 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
11968 of "encoding".
11969 * varobj.c (varobj_value_get_print_value): Update.
11970 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
11971
11972 2017-01-10 Tom Tromey <tom@tromey.com>
11973
11974 * varobj.c (varobj_get_display_hint)
11975 (dynamic_varobj_has_child_method, install_new_value_visualizer)
11976 (varobj_set_visualizer, free_variable): Use
11977 gdbpy_enter_varobj.
11978
11979 2017-01-10 Tom Tromey <tom@tromey.com>
11980
11981 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
11982 (do_finish_initialization): New function. Use gdbpy_ref.
11983 (gdbpy_finish_initialization): Use gdbpy_enter. Call
11984 do_finish_initialization.
11985
11986 2017-01-10 Tom Tromey <tom@tromey.com>
11987
11988 * python/py-param.c (get_set_value, get_show_value): Use
11989 gdbpy_enter, gdbpy_ref.
11990
11991 2017-01-10 Tom Tromey <tom@tromey.com>
11992
11993 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
11994
11995 2017-01-10 Tom Tromey <tom@tromey.com>
11996
11997 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
11998
11999 2017-01-10 Tom Tromey <tom@tromey.com>
12000
12001 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
12002 Use gdbpy_enter_varobj.
12003
12004 2017-01-10 Tom Tromey <tom@tromey.com>
12005
12006 * varobj.c (gdbpy_enter_varobj): New constructor.
12007 * python/python-internal.h (gdbpy_enter_varobj): New class.
12008 * python/py-varobj.c (py_varobj_get_iterator): Use
12009 gdbpy_enter_varobj.
12010
12011 2017-01-10 Tom Tromey <tom@tromey.com>
12012
12013 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
12014 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
12015 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
12016 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
12017 unique_xmalloc_ptr.
12018 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
12019
12020 2017-01-10 Tom Tromey <tom@tromey.com>
12021
12022 * python/py-xmethods.c (invoke_match_method): Use
12023 gdbpy_ref.
12024
12025 2017-01-10 Tom Tromey <tom@tromey.com>
12026
12027 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
12028 gdbpy_enter, gdbpy_ref.
12029
12030 2017-01-10 Tom Tromey <tom@tromey.com>
12031
12032 * python/python.c (python_interactive_command): Use gdbpy_enter.
12033
12034 2017-01-10 Tom Tromey <tom@tromey.com>
12035
12036 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
12037 gdbpy_ref.
12038
12039 2017-01-10 Tom Tromey <tom@tromey.com>
12040
12041 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
12042 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
12043
12044 2017-01-10 Tom Tromey <tom@tromey.com>
12045
12046 * utils.h (htab_deleter): New struct.
12047 (htab_up): New typedef.
12048 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
12049 gdbpy_enter, gdbpy_ref, htab_up.
12050
12051 2017-01-10 Tom Tromey <tom@tromey.com>
12052
12053 * python/py-unwind.c (pending_frame_invalidate): Remove.
12054 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
12055
12056 2017-01-10 Tom Tromey <tom@tromey.com>
12057
12058 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
12059 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
12060
12061 2017-01-10 Tom Tromey <tom@tromey.com>
12062
12063 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
12064
12065 2017-01-10 Tom Tromey <tom@tromey.com>
12066
12067 * python/python.c (gdbpy_eval_from_control_command)
12068 (gdbpy_source_script, gdbpy_run_events)
12069 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
12070 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
12071 gdbpy_enter.
12072
12073 2017-01-10 Tom Tromey <tom@tromey.com>
12074
12075 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
12076
12077 2017-01-10 Tom Tromey <tom@tromey.com>
12078
12079 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
12080
12081 2017-01-10 Tom Tromey <tom@tromey.com>
12082
12083 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
12084 (python_on_inferior_call_pre, python_on_inferior_call_post)
12085 (python_on_memory_change, python_on_register_change)
12086 (python_inferior_exit, python_new_objfile, add_thread_object)
12087 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
12088
12089 2017-01-10 Tom Tromey <tom@tromey.com>
12090
12091 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
12092 (bpfinishpy_handle_exit): Use gdbpy_enter.
12093
12094 2017-01-10 Tom Tromey <tom@tromey.com>
12095
12096 * python/py-cmd.c (cmdpy_destroyer)
12097 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
12098 gdbpy_enter.
12099
12100 2017-01-10 Tom Tromey <tom@tromey.com>
12101
12102 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
12103 gdbpy_enter.
12104 (gdbpy_breakpoint_has_cond): Likewise.
12105
12106 2017-01-10 Tom Tromey <tom@tromey.com>
12107
12108 * python/python.c (gdbpy_enter): New constructor.
12109 (~gdbpy_enter): New destructor.
12110 (restore_python_env, ensure_python_env): Rewrite.
12111 * python/python-internal.h (gdbpy_enter): New class.
12112
12113 2017-01-10 Tom Tromey <tom@tromey.com>
12114
12115 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
12116
12117 2017-01-10 Tom Tromey <tom@tromey.com>
12118
12119 * python/py-value.c (value_has_field, get_field_flag)
12120 (get_field_type, valpy_getitem, convert_value_from_python): Use
12121 gdbpy_ref.
12122
12123 2017-01-10 Tom Tromey <tom@tromey.com>
12124
12125 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
12126 gdbpy_ref.
12127
12128 2017-01-10 Tom Tromey <tom@tromey.com>
12129
12130 * python/py-prettyprint.c (search_pp_list)
12131 (find_pretty_printer_from_objfiles)
12132 (find_pretty_printer_from_progspace)
12133 (find_pretty_printer_from_gdb, find_pretty_printer)
12134 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
12135 gdbpy_ref.
12136
12137 2017-01-10 Tom Tromey <tom@tromey.com>
12138
12139 * python/py-param.c (call_doc_function): Use gdbpy_ref.
12140
12141 2017-01-10 Tom Tromey <tom@tromey.com>
12142
12143 * python/py-linetable.c (build_line_table_tuple_from_pcs)
12144 (ltpy_get_all_source_lines): Use gdbpy_ref.
12145
12146 2017-01-10 Tom Tromey <tom@tromey.com>
12147
12148 * python/py-framefilter.c (extract_sym, extract_value)
12149 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
12150 gdbpy_ref.
12151
12152 2017-01-10 Tom Tromey <tom@tromey.com>
12153
12154 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
12155
12156 2017-01-10 Tom Tromey <tom@tromey.com>
12157
12158 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
12159
12160 2017-01-10 Tom Tromey <tom@tromey.com>
12161
12162 * python/py-function.c (convert_values_to_python, fnpy_init): Use
12163 gdbpy_ref.
12164
12165 2017-01-10 Tom Tromey <tom@tromey.com>
12166
12167 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
12168
12169 2017-01-10 Tom Tromey <tom@tromey.com>
12170
12171 * python/py-type.c (convert_field, make_fielditem, typy_fields)
12172 (typy_range): Use gdbpy_ref.
12173
12174 2017-01-10 Tom Tromey <tom@tromey.com>
12175
12176 * python/py-threadevent.c (create_thread_event_object): Use
12177 gdbpy_ref.
12178 * python/py-stopevent.c (create_stop_event_object): Simplify.
12179 (emit_stop_event): Use gdbpy_ref.
12180 * python/py-signalevent.c (create_signal_event_object): Use
12181 gdbpy_ref.
12182 * python/py-newobjfileevent.c (create_new_objfile_event_object)
12183 (emit_new_objfile_event, create_clear_objfiles_event_object)
12184 (emit_clear_objfiles_event): Use gdbpy_ref.
12185 * python/py-infevents.c (create_inferior_call_event_object)
12186 (create_register_changed_event_object)
12187 (create_memory_changed_event_object, emit_inferior_call_event)
12188 (emit_memory_changed_event, emit_register_changed_event): Use
12189 gdbpy_ref.
12190 * python/py-exitedevent.c (create_exited_event_object)
12191 (emit_exited_event): Use gdbpy_ref.
12192 * python/py-event.h (evpy_emit_event): Remove
12193 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
12194 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
12195 * python/py-continueevent.c (emit_continue_event): Use
12196 gdbpy_ref.
12197 * python/py-breakpoint.c (gdbpy_breakpoint_created)
12198 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
12199 gdbpy_ref.
12200 * python/py-bpevent.c (create_breakpoint_event_object): Use
12201 gdbpy_ref.
12202
12203 2017-01-10 Tom Tromey <tom@tromey.com>
12204
12205 * python/py-ref.h: New file.
12206
12207 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
12208
12209 * cli-out.c (cli_ui_out::do_redirect): Change return type to
12210 void.
12211 * cli-out.h (cli_ui_out::do_redirect): Likewise.
12212 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
12213 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
12214 * ui-out.c (ui_out::redirect): Likewise.
12215 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
12216 * cli/cli-logging.c (set_logging_redirect): Update call site of
12217 ui_out::redirect.
12218 (handle_redirections): Likewise.
12219 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
12220 * top.c (execute_command_to_string): Likewise.
12221 * utils.c (do_ui_out_redirect_pop): Likewise.
12222
12223 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
12224
12225 * stack.c (_initialize_stack): Update "frame" command help message.
12226
12227 2017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
12228
12229 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
12230
12231 2017-01-06 Yao Qi <yao.qi@linaro.org>
12232
12233 * x86-linux-nat.h: Include gdb_proc_service.h.
12234
12235 2017-01-06 Yao Qi <yao.qi@linaro.org>
12236
12237 * ser-base.h: Include serial.h.
12238
12239 2017-01-06 Yao Qi <yao.qi@linaro.org>
12240
12241 * ppc-linux-tdep.h: Include ppc-tdep.h.
12242
12243 2017-01-06 Yao Qi <yao.qi@linaro.org>
12244
12245 * nat/amd64-linux-siginfo.h: Include signal.h.
12246
12247 2017-01-06 Yao Qi <yao.qi@linaro.org>
12248
12249 * nat/aarch64-linux-hw-point.h: Include break-common.h.
12250
12251 2017-01-06 Yao Qi <yao.qi@linaro.org>
12252
12253 * mi/mi-parse.h: Include mi-cmds.h.
12254
12255 2017-01-06 Yao Qi <yao.qi@linaro.org>
12256
12257 * inf-loop.c: Don't include "target.h".
12258 * inf-loop.h: Include it here.
12259
12260 2017-01-06 Yao Qi <yao.qi@linaro.org>
12261
12262 * dfp.h: Include "dboulest.h" and "expression.h".
12263
12264 2017-01-06 Yao Qi <yao.qi@linaro.org>
12265
12266 * ax-gdb.h: Include "ax.h".
12267
12268 2017-01-06 Yao Qi <yao.qi@linaro.org>
12269
12270 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
12271 with nat/gdb_ptrace.h.
12272
12273 2017-01-05 Yao Qi <yao.qi@linaro.org>
12274
12275 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
12276 new line.
12277 (mips64_fbsd_sigframe_init): Likewise.
12278
12279 2017-01-04 John Baldwin <jhb@FreeBSD.org>
12280
12281 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
12282 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
12283
12284 2017-01-04 John Baldwin <jhb@FreeBSD.org>
12285
12286 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
12287 * NEWS: Mention new FreeBSD/mips native configuration.
12288 * config/mips/fbsd.mh: New file.
12289 * configure.host: Add mips*-*-freebsd*.
12290 * mips-fbsd-nat.c: New file.
12291
12292 2017-01-04 John Baldwin <jhb@FreeBSD.org>
12293
12294 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
12295 (ALLDEPFILES): Add mips-fbsd-tdep.c.
12296 * NEWS: Mention new FreeBSD/mips target.
12297 * configure.tgt: Add mips*-*-freebsd*.
12298 * mips-fbsd-tdep.c: New file.
12299 * mips-fbsd-tdep.h: New file.
12300
12301 2017-01-04 Yao Qi <yao.qi@linaro.org>
12302
12303 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
12304 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
12305
12306 2017-01-01 Joel Brobecker <brobecker@adacore.com>
12307
12308 Update copyright year range in all GDB files.
12309
12310 2017-01-01 Joel Brobecker <brobecker@adacore.com>
12311
12312 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
12313
12314 For older changes see ChangeLog-2016.
12315 \f
12316 Local Variables:
12317 mode: change-log
12318 left-margin: 8
12319 fill-column: 74
12320 version-control: never
12321 coding: utf-8
12322 End:
This page took 0.341373 seconds and 3 git commands to generate.