Remove REMOTE_OBS
[deliverable/binutils-gdb.git] / gdb / ChangeLog
1 2017-11-27 Tom Tromey <tom@tromey.com>
2
3 * Makefile.in (REMOTE_OBS): Remove.
4 (SFILES): Remove remote sources.
5 (COMMON_SFILES): Add remote sources.
6 (ALLDEPFILES): Remove dcache.c.
7
8 2017-11-27 Tom Tromey <tom@tromey.com>
9
10 * Makefile.in (SUBDIR_TARGET_SRCS, SUBDIR_TARGET_OBS): New
11 variables.
12 (SFILES): Use SUBDIR_TARGET_SRCS.
13 (COMMON_OBS): Use SUBDIR_TARGET_OBS. Remove waitstatus.o.
14 (CONFIG_SRC_SUBDIR): Add target.
15 (%.o): Remove target rule.
16
17 2017-11-27 Tom Tromey <tom@tromey.com>
18
19 * Makefile.in (COMMON_OBS): Remove filename-seen-cache.o,
20 registry.o, thread-fsm.o, debug.o.
21 (COMMON_SFILES): Add filename-seen-cache.c, registry.c,
22 thread-fsm.c, debug.c.
23
24 2017-11-27 Tom Tromey <tom@tromey.com>
25
26 * Makefile.in (COMMON_SFILES): New.
27 (SFILES): Move some entries to COMMON_SFILES.
28 (COMMON_OBS): Use COMMON_SFILES.
29
30 2017-11-27 Tom Tromey <tom@tromey.com>
31
32 * Makefile.in (YYFILES): Update comment.
33 (YYOBJ): Redefine.
34
35 2017-11-27 Tom Tromey <tom@tromey.com>
36
37 * Makefile.in (SUBDIR_PYTHON_OBS): Redefine.
38 (CONFIG_SRC_SUBDIR): Add python.
39 (%.o): Remove python rule.
40 (python/%.o): New rule.
41 * configure: Rebuild.
42 * configure.ac (CONFIG_OBS): Refer to python/python.o
43
44 2017-11-27 Tom Tromey <tom@tromey.com>
45
46 * configure: Rebuild.
47 * configure.ac (CONFIG_OBS): Refer to guile/guile.o.
48 * Makefile.in (SUBDIR_GUILE_OBS): Redefine.
49 (CONFIG_SRC_SUBDIR): Add guile.
50 (%.o): Remove guile rule.
51
52 2017-11-27 Tom Tromey <tom@tromey.com>
53
54 * Makefile.in (SUBDIR_UNITTESTS_OBS): Redefine.
55 (%.o): Remove unittests rule.
56 (CONFIG_SRC_SUBDIR): Add unittests.
57
58 2017-11-27 Tom Tromey <tom@tromey.com>
59
60 * Makefile.in (SUBDIR_TUI_OBS): Redefine.
61 (CONFIG_SRC_SUBDIR): Add tui.
62 (%.o): Remove tui rule.
63
64 2017-11-27 Tom Tromey <tom@tromey.com>
65
66 * Makefile.in (SUBDIR_GCC_COMPILE_OBS): Redefine.
67 (%.o): Remove compile rule.
68 (CONFIG_SRC_SUBDIR): Add compile.
69
70 2017-11-27 Tom Tromey <tom@tromey.com>
71
72 * Makefile.in (SUBDIR_MI_OBS): Redefine.
73 (%.o): Remove mi rule.
74 (CONFIG_SRC_SUBDIR): Add mi.
75 (COMMON_OBS): Use mi/mi-common.o
76
77 2017-11-27 Tom Tromey <tom@tromey.com>
78
79 * Makefile.in (SUBDIR_CLI_OBS): Redefine.
80 (%.o): Remove cli rule.
81 (CONFIG_SRC_SUBDIR): Add cli.
82
83 2017-11-27 Tom Tromey <tom@tromey.com>
84
85 * configure.ac (CONFIG_SRC_SUBDIR): Don't subst.
86 * configure: Rebuild.
87 * Makefile.in (CONFIG_SRC_SUBDIR): Redefine.
88 (CONFIG_DEP_SUBDIR): New variable.
89 (%.o): Add order-only dependency.
90 ($(CONFIG_DEP_SUBDIR)): New target.
91
92 2017-11-26 Dominik Czarnota <dominik.b.czarnota@gmail.com>
93
94 PR gdb/21945
95 * findcmd.c (_initialize_mem_search): Update find command help
96 text.
97
98 2017-11-26 Simon Marchi <simon.marchi@polymtl.ca>
99
100 * python/python.c (do_start_initialization): Change progname
101 type to gdb::unique_xmalloc_ptr. Release the pointer when using
102 Python 2.
103
104 2017-11-26 Tom Tromey <tom@tromey.com>
105
106 * common/format.h: Add include guards.
107
108 2017-11-26 Tom Tromey <tom@tromey.com>
109
110 * nat/linux-personality.h (class
111 maybe_disable_address_space_randomization): New class.
112 (maybe_disable_address_space_randomization): Don't declare
113 function.
114 * nat/linux-personality.c (restore_personality)
115 (make_disable_asr_cleanup): Remove.
116 (maybe_disable_address_space_randomization): Now a constructor.
117 (~maybe_disable_address_space_randomization): New destructor.
118 * linux-nat.c (linux_nat_create_inferior): Update.
119
120 2017-11-26 Tom Tromey <tom@tromey.com>
121
122 * gcore.c (write_gcore_file_1): Use gdb::unique_xmalloc_ptr.
123
124 2017-11-26 Ulrich Weigand <uweigand@de.ibm.com>
125
126 * spu-tdep.c (spu_software_single_step): Access SPU_LSLR_REGNUM as
127 "cooked" register. Access only first four bytes of branch target
128 registers.
129
130 2017-11-25 Sergio Durigan Junior <sergiodj@redhat.com>
131
132 PR gdb/22491
133 * stap-probe.c (relocate_address): New function.
134 (stap_probe::get_relocated_address): Use 'relocate_address'.
135 (stap_probe::set_semaphore): Use 'relocate_address' and pass
136 'm_sem_addr'.
137 (stap_probe::clear_semaphore): Likewise.
138
139 2017-11-25 Pedro Alves <palves@redhat.com>
140
141 * dictionary.c: Include "safe-ctype.h".
142 * minsyms.c: Include "safe-ctype.h".
143 * minsyms.c (SYMBOL_HASH_NEXT): Use TOLOWER instead of tolower.
144
145 2017-11-25 Pedro Alves <palves@redhat.com>
146
147 * completer.c (complete_line_internal_1): Skip spaces until the
148 start of the command.
149
150 2017-11-24 Pedro Alves <palves@redhat.com>
151
152 * cp-support.c (cp_symbol_name_matches_1): New, factored out from
153 cp_fq_symbol_name_matches. Pass language_cplus to
154 strncmp_with_mode.
155 (cp_fq_symbol_name_matches): Call cp_symbol_name_matches_1.
156 (selftests::test_cp_symbol_name_cmp): New.
157 (_initialize_cp_support): Register "cp_symbol_name_matches"
158 selftests.
159 * language.c (default_symbol_name_matcher): Pass language_minimal
160 to strncmp_iw_with_mode.
161 * utils.c: Include "cp-support.h" and <algorithm>.
162 (valid_identifier_name_char, cp_skip_operator_token, skip_ws)
163 (cp_is_operator): New functions.
164 (strncmp_iw_with_mode): Use them. Add language parameter. Don't
165 skip whitespace in the symbol name when the lookup name doesn't
166 have spaces, and vice versa.
167 (strncmp_iw, strcmp_iw): Pass language to strncmp_iw_with_mode.
168 * utils.h (strncmp_iw_with_mode): Add language parameter.
169
170 2017-11-24 Joel Brobecker <brobecker@adacore.com>
171
172 * ada-lang.c (ada_exception_message_1, ada_exception_message):
173 New functions.
174 (print_it_exception): If available, display the exception
175 message as well.
176 * NEWS: Document new feature.
177
178 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
179
180 * configure.nat <spu-linux>: Add fork-inferior.o to NATDEPFILES.
181
182 2017-11-24 Philipp Rudo <prudo@linux.vnet.ibm.com>
183
184 * dtrace-probe.c (dtrace_probe::build_arg_exprs)
185 (dtrace_probe::is_enabled, dtrace_probe::enable)
186 (dtrace_probe::disable): Remove keyword 'struct' at for-range
187 variable
188 * probe.c (gen_ui_out_table_header_info)
189 (print_ui_out_not_applicables): Remove keyword 'struct' at
190 for-range variable
191
192 2017-11-24 Alan Hayward <alan.hayward@arm.com>
193
194 * configure.tgt: Add arch/aarch64.o
195
196 2017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
197
198 * common/common-utils.h: Include poison.h.
199 (xfree): Remove declaration, add definition with static_assert.
200 * common/common-utils.c (xfree): Remove.
201 * common/poison.h (IsMallocatable): Define.
202 (IsFreeable): Define.
203 (free): Delete for non-freeable types.
204 (xnew): New.
205 (XNEW): Undef and redefine.
206 (xcnew): New.
207 (XCNEW): Undef and redefine.
208 (xdelete): New.
209 (XDELETE): Undef and redefine.
210 (xnewvec): New.
211 (XNEWVEC): Undef and redefine.
212 (xcnewvec): New.
213 (XCNEWVEC): Undef and redefine.
214 (xresizevec): New.
215 (XRESIZEVEC): Undef and redefine.
216 (xdeletevec): New.
217 (XDELETEVEC): Undef and redefine.
218 (xnewvar): New.
219 (XNEWVAR): Undef and redefine.
220 (xcnewvar): New.
221 (XCNEWVAR): Undef and redefine.
222 (xresizevar): New.
223 (XRESIZEVAR): Undef and redefine.
224
225 2017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
226
227 * gdbthread.h (private_thread_info): Define structure type, add
228 virtual pure destructor.
229 (thread_info) <priv>: Change type to unique_ptr.
230 <private_dtor>: Remove.
231 * thread.c (add_thread_with_info): Adjust to use of unique_ptr.
232 (private_thread_info::~private_thread_info): Provide default
233 implementation.
234 (thread_info::~thread_info): Don't call private_dtor nor
235 manually free priv.
236 * aix-thread.c (private_thread_info): Rename to ...
237 (aix_thread_info): ... this.
238 (get_aix_thread_info): New.
239 (sync_threadlists): Adjust.
240 (iter_tid): Adjust.
241 (aix_thread_resume): Adjust.
242 (aix_thread_fetch_registers): Adjust.
243 (aix_thread_store_registers): Adjust.
244 (aix_thread_extra_thread_info): Adjust.
245 * darwin-nat.h (private_thread_info): Rename to ...
246 (darwin_thread_info): ... this.
247 (get_darwin_thread_info): New.
248 * darwin-nat.c (darwin_init_thread_list): Adjust.
249 (darwin_check_new_threads): Adjust.
250 (thread_info_from_private_thread_info): Adjust.
251 * linux-thread-db.c (private_thread_info): Rename to ...
252 (thread_db_thread_info): ... this, initialize fields.
253 (get_thread_db_thread_info): New.
254 <dying>: Change type to bool.
255 (update_thread_state): Adjust to type rename.
256 (record_thread): Adjust to type rename an use of unique_ptr.
257 (thread_db_pid_to_str): Likewise.
258 (thread_db_extra_thread_info): Likewise.
259 (thread_db_thread_handle_to_thread_info): Likewise.
260 (thread_db_get_thread_local_address): Likewise.
261 * nto-tdep.h (private_thread_info): Rename to ...
262 (nto_thread_info): ... this, initialize fields.
263 (get_nto_thread_info): New.
264 <name>: Change type to std::string.
265 * nto-tdep.c (nto_extra_thread_info): Adjust to type rename and
266 use of unique_ptr.
267 * nto-procfs.c (update_thread_private_data_name): Adjust to
268 std::string change, allocate nto_private_thread_info with new.
269 (update_thread_private_data): Adjust to unique_ptr.
270 * remote.c (private_thread_info): Rename to ...
271 (remote_thread_info): ... this, initialize data members with
272 default values.
273 <extra, name>: Change type to std::string.
274 <thread_handle>: Change type to non-pointer.
275 (free_private_thread_info): Remove.
276 (get_private_info_thread): Rename to...
277 (get_remote_thread_info): ... this, change return type, adjust to
278 use of unique_ptr, use remote_thread_info constructor.
279 (remote_add_thread): Adjust.
280 (get_private_info_ptid): Rename to...
281 (get_remote_thread_info): ...this, change return type.
282 (remote_thread_name): Use get_remote_thread_info, adjust to
283 change to std::string.
284 (struct thread_item) <~thread_item>: Remove.
285 <thread_handle>: Make non pointer.
286 (start_thread): Adjust to thread_item::thread_handle type
287 change.
288 (remote_update_thread_list): Adjust to type name change, move
289 strings from temporary to long-lived object instead of
290 duplicating.
291 (remote_threads_extra_info): Use get_remote_thread_info.
292 (process_initial_stop_replies): Likewise.
293 (resume_clear_thread_private_info): Likewise.
294 (remote_resume): Adjust to type name change.
295 (remote_commit_resume): Use get_remote_thread_info.
296 (process_stop_reply): Adjust to type name change.
297 (remote_stopped_by_sw_breakpoint): Use get_remote_thread_info.
298 (remote_stopped_by_hw_breakpoint): Likewise.
299 (remote_stopped_by_watchpoint): Likewise.
300 (remote_stopped_data_address): Likewise.
301 (remote_core_of_thread): Likewise.
302 (remote_thread_handle_to_thread_info): Use
303 get_private_info_thread, adjust to thread_handle field type
304 change.
305
306 2017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
307
308 * remote.c (struct thread_item): Add constructor, disable copy
309 construction and copy assignment, define default move
310 construction and move assignment.
311 <extra, name>: Change type to std::string.
312 <core>: Initialize.
313 <thread_handle>: Make non-pointer.
314 (thread_item_t): Remove typedef.
315 (DEF_VEC_O(thread_item_t)): Remove.
316 (threads_listing_context) <contains_thread>: New method.
317 <remove_thread>: New method.
318 <items>: Change type to std::vector.
319 (clear_threads_listing_context): Remove.
320 (threads_listing_context_remove): Remove.
321 (remote_newthread_step): Use thread_item constructor, adjust to
322 change to std::vector.
323 (start_thread): Use thread_item constructor, adjust to change to
324 std::vector.
325 (end_thread): Adjust to change to std::vector and std::string.
326 (remote_get_threads_with_qthreadinfo): Use thread_item
327 constructor, adjust to std::vector.
328 (remote_update_thread_list): Adjust to change to std::vector and
329 std::string, use threads_listing_context methods.
330 (remove_child_of_pending_fork): Adjust.
331 (remove_new_fork_children): Adjust.
332 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add rsp-low-selftests.c.
333 (SUBDIR_UNITTESTS_OBS): Add rsp-low-selftests.o.
334 * unittests/rsp-low-selftests.c: New file.
335 * common/rsp-low.h: Include common/byte-vector.h.
336 (hex2bin): New overload.
337 * common/rsp-low.c (hex2bin): New overload.
338
339 2017-11-24 Simon Marchi <simon.marchi@ericsson.com>
340
341 * inferior.h (private_inferior): Define structure type, add
342 virtual pure destructor.
343 (inferior) <priv>: Change type to unique_ptr.
344 * inferior.c (private_inferior::~private_inferior): Provide
345 default implementation.
346 (inferior::~inferior): Don't free priv field.
347 (exit_inferior_1): Likewise.
348 * darwin-nat.h (struct darwin_exception_info): Initialize fields.
349 (darwin_exception_info): Remove typedef.
350 (DEF_VEC_O (darwin_thread_t)); Remove.
351 (private_inferior): Rename to ...
352 (darwin_private_inferior): ... this, extend private_inferior.
353 (get_darwin_inferior): New.
354 <threads>: Change type to std::vector of darwin_thread_t pointers.
355 * darwin-nat.c (darwin_check_new_threads): Adjust.
356 (find_inferior_task_it): Adjust.
357 (darwin_find_thread); Adjust.
358 (darwin_suspend_inferior): Adjust.
359 (darwin_resume_inferior): Adjust.
360 (darwin_find_new_inferior): Adjust.
361 (darwin_decode_notify_message): Adjust.
362 (darwin_send_reply): Adjust.
363 (darwin_resume_inferior_threads): Adjust.
364 (darwin_suspend_inferior_threads): Adjust.
365 (darwin_decode_message): Adjust.
366 (darwin_wait): Adjust.
367 (darwin_interrupt): Adjust.
368 (darwin_deallocate_threads): Adjust.
369 (darwin_mourn_inferior): Adjust, don't free private data.
370 (darwin_reply_to_all_pending_messages): Adjust.
371 (darwin_stop_inferior): Adjust.
372 (darwin_setup_exceptions): Adjust.
373 (darwin_kill_inferior): Adjust.
374 (darwin_setup_request_notification): Adjust.
375 (darwin_attach_pid): Adjust.
376 (darwin_init_thread_list): Adjust.
377 (darwin_setup_fake_stop_event): Adjust.
378 (darwin_attach): Adjust.
379 (darwin_detach): Adjust.
380 (darwin_xfer_partial): Adjust.
381 (set_enable_mach_exceptions): Adjust.
382 (darwin_pid_to_exec_file): Adjust.
383 (darwin_get_ada_task_ptid): Adjust.
384 * darwin-nat-info.c (get_task_from_args): Adjust.
385 (info_mach_ports_command): Adjust.
386 (info_mach_region_command): Adjust.
387 (info_mach_exceptions_command): Adjust.
388 * remote.c (private_inferior): Rename to ...
389 (remote_private_inferior): ... this, initialize fields.
390 (get_remote_inferior); New.
391 (remote_commit_resume): Use get_remote_inferior.
392 (check_pending_event_prevents_wildcard_vcont_callback): Likewise.
393
394 2017-11-24 Pedro Alves <palves@redhat.com>
395
396 * NEWS: Mention linespecs and explicit locations, and completion
397 improvements.
398
399 2017-11-24 Yao Qi <yao.qi@linaro.org>
400
401 * regcache.c (regcache::dump): Remove footnote_register_size.
402
403 2017-11-24 Yao Qi <yao.qi@linaro.org>
404
405 * regcache.c (cooked_read_test): Add more test for readonly
406 regcache.
407
408 2017-11-24 Yao Qi <yao.qi@linaro.org>
409
410 * gdbarch-selftests.c (test_target_has_registers): Move it to
411 target.c.
412 (test_target_has_stack): Likewise.
413 (test_target_has_memory): Likewise.
414 (test_target_prepare_to_store): Likewise.
415 (test_target_store_registers): Likewise.
416 (test_target_ops): Likewise.
417 * regcache.c: Include selftest-arch.h and gdbthread.h.
418 (target_ops_no_register): New class.
419 (test_target_fetch_registers): New.
420 (test_target_store_registers): New.
421 (test_target_xfer_partial): New.
422 (readwrite_regcache): New.
423 (cooked_read_test): New.
424 (_initialize_regcache): Register the test.
425 * target.c: (test_target_has_registers): Moved from
426 gdbarch-selftests.c.
427 (test_target_has_stack): Likewise.
428 (test_target_has_memory): Likewise.
429 (test_target_prepare_to_store): Likewise.
430 (test_target_store_registers): Likewise.
431 * target.h (test_target_ops): New class.
432
433 2017-11-24 Alan Hayward <alan.hayward@arm.com>
434
435 * aarch64-tdep.c (_initialize_aarch64_tdep): Add target desc
436 selftest.
437
438 2017-11-24 Alan Hayward <alan.hayward@arm.com>
439
440 * aarch64-tdep.c (_initialize_aarch64_tdep): Remove init.
441 * arch/aarch64.c (aarch64_create_target_description): Create
442 new target description.
443 * features/Makefile: Add new files.
444 * features/aarch64.c: Remove file.
445 * features/aarch64-core.c: New autogenerated file.
446 * features/aarch64-fpu.c: New autogenerated file.
447 * target-descriptions.c (maint_print_c_tdesc_cmd): Check for aarch64.
448
449 2017-11-24 Alan Hayward <alan.hayward@arm.com>
450
451 * Makefile.in: Add new files.
452 * aarch64-linux-nat.c (aarch64_linux_read_description): Call
453 aarch64_read_description.
454 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
455 Call aarch64_read_description.
456 * aarch64-tdep.c (aarch64_read_description): New function.
457 (aarch64_gdbarch_init): Call aarch64_read_description.
458 * aarch64-tdep.h (aarch64_read_description): New function.
459 * arch/aarch64.c: New file.
460 * configure.tgt: Add new files.
461
462 2017-11-24 Yao Qi <yao.qi@linaro.org>
463
464 * mi/mi-main.c (register_changed_p): Update.
465 * value.c (value_contents_bits_eq): Change return type.
466 (value_contents_eq): Likewise.
467 * value.h: Update comments.
468
469 2017-11-24 Yao Qi <yao.qi@linaro.org>
470
471 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Remove
472 local 'changed'. Remove error.
473 (register_changed_p): Change return type to bool.
474
475 2017-11-24 Yao Qi <yao.qi@linaro.org>
476
477 * arch/tic6x.c: New file.
478 * arch/tic6x.h: New file.
479 * features/Makefile (FEATURE_XMLFILES): Add tic6x-c6xp.xml,
480 tic6x-core.xml and tic6x-gp.xml.
481 * features/tic6x-c6xp.c: Generated.
482 * features/tic6x-core.c: Generated.
483 * features/tic6x-gp.c: Generated.
484 * target-descriptions.c (maint_print_c_tdesc_cmd): Match
485 "tic6x-".
486
487 2017-11-23 Simon Marchi <simon.marchi@ericsson.com>
488
489 * mi/mi-main.c (list_available_thread_groups): Change map value
490 type to std::vector.
491
492 2017-11-23 Simon Marchi <simon.marchi@ericsson.com>
493
494 * osdata.c (osdata_end_column, get_osdata): Remove std::move.
495
496 2017-11-23 Simon Marchi <simon.marchi@ericsson.com>
497
498 * varobj.c (struct varobj_dynamic) <children_requested_>: Rename
499 back to...
500 <children_requested>: ... this.
501 (varobj_get_num_children, varobj_update): Adjust.
502
503 2017-11-23 Simon Marchi <simon.marchi@ericsson.com>
504
505 * ada-varobj.c (ada_value_is_changeable_p): Change int to bool where applicable.
506 (ada_value_has_mutated): Likewise.
507 * c-varobj.c (varobj_is_anonymous_child): Likewise.
508 (c_is_path_expr_parent): Likewise.
509 * mi/mi-cmd-var.c (varobj_update_one): Likewise.
510 (mi_cmd_var_set_frozen): Likewise.
511 (mi_cmd_var_update_iter): Likewise.
512 (mi_cmd_var_update): Likewise.
513 * varobj.c (pretty_printing): Likewise.
514 (varobj_enable_pretty_printing): Likewise.
515 (struct varobj_root) <floating, is_valid>: Likewise.
516 (struct varobj_dynamic) <children_requested>: Likewise.
517 (delete_variable): Likewise.
518 (delete_variable_1): Likewise.
519 (install_variable): Likewise.
520 (update_type_if_necessary): Likewise.
521 (install_new_value): Likewise.
522 (value_of_root): Likewise.
523 (is_root_p): Likewise.
524 (varobj_create): Likewise.
525 (varobj_delete): Likewise.
526 (varobj_has_more): Likewise.
527 (varobj_set_frozen): Likewise.
528 (varobj_get_frozen): Likewise.
529 (install_dynamic_child): Likewise.
530 (dynamic_varobj_has_child_method): Likewise.
531 (update_dynamic_varobj_children): Likewise.
532 (varobj_get_num_children): Likewise.
533 (varobj_list_children): Likewise.
534 (is_path_expr_parent): Likewise.
535 (varobj_default_is_path_expr_parent): Likewise.
536 (varobj_is_dynamic_p): Likewise.
537 (varobj_set_value): Likewise.
538 (varobj_value_has_mutated): Likewise.
539 (varobj_update): Likewise.
540 (check_scope): Likewise.
541 (value_of_root_1): Likewise.
542 (varobj_value_get_print_value): Likewise.
543 (varobj_editable_p): Likewise.
544 (varobj_value_is_changeable_p): Likewise.
545 (varobj_floating_p): Likewise.
546 (varobj_default_value_is_changeable_p): Likewise.
547 (varobj_invalidate_iter): Likewise.
548 * varobj.h (struct varobj_update_result) <type_changed,
549 children_changed, changed, value_installed>: Likewise.
550 (struct varobj) <updated, frozen, not_fetched>: Likewise.
551 (struct lang_varobj_ops) <value_is_changeable_p,
552 value_has_mutated, is_path_expr_parent>: Likewise.
553 (varobj_delete): Likewise.
554 (varobj_set_frozen): Likewise.
555 (varobj_get_frozen): Likewise.
556 (varobj_set_value): Likewise.
557 (varobj_update): Likewise.
558 (varobj_editable_p): Likewise.
559 (varobj_floating_p): Likewise.
560 (varobj_has_more): Likewise.
561 (varobj_is_dynamic_p): Likewise.
562 (varobj_default_value_is_changeable_p): Likewise.
563 (varobj_value_is_changeable_p): Likewise.
564 (varobj_is_anonymous_child): Likewise.
565 (varobj_default_is_path_expr_parent): Likewise.
566
567 2017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
568
569 * dtrace-probe.c (struct probe_ops dtrace_probe_ops): Delete.
570 (struct dtrace_probe_arg) <dtrace_probe_arg>: New constructor.
571 <type_str>: Convert to 'std::string'.
572 <expr>: Convert to 'expression_up'.
573 (dtrace_probe_arg_s): Delete type and VEC.
574 (dtrace_probe_enabler_s): Likewise.
575 (struct dtrace_probe): Replace by...
576 (class dtrace_static_probe_ops): ...this and...
577 (class dtrace_probe): ...this.
578 (dtrace_probe_is_linespec): Rename to...
579 (dtrace_static_probe_ops::is_linespec): ...this. Adjust code
580 to reflect change.
581 (dtrace_process_dof_probe): Use 'std::vector' instead of VEC.
582 Adjust code. Create new instance of 'dtrace_probe'.
583 (dtrace_build_arg_exprs): Rename to...
584 (dtrace_probe::build_arg_exprs): ...this. Adjust code to
585 reflect change.
586 (dtrace_get_probes): Rename to...
587 (dtrace_static_probe_ops::get_probes): ...this. Adjust code
588 to reflect change.
589 (dtrace_get_arg): Rename to...
590 (dtrace_probe::get_arg_by_number): ...this. Adjust code to
591 reflect change.
592 (dtrace_probe_is_enabled): Rename to...
593 (dtrace_probe::is_enabled): ...this. Adjust code to reflect
594 change.
595 (dtrace_get_probe_address): Rename to...
596 (dtrace_probe::get_relocated_address): ...this. Adjust code
597 to reflect change.
598 (dtrace_get_probe_argument_count): Rename to...
599 (dtrace_probe::get_argument_count): ...this. Adjust code to
600 reflect change.
601 (dtrace_can_evaluate_probe_arguments): Rename to...
602 (dtrace_probe::can_evaluate_arguments): ...this. Adjust code
603 to reflect change.
604 (dtrace_evaluate_probe_argument): Rename to...
605 (dtrace_probe::evaluate_argument): ...this. Adjust code to
606 reflect change.
607 (dtrace_compile_to_ax): Rename to...
608 (dtrace_probe::compile_to_ax): ...this. Adjust code to
609 reflect change.
610 (dtrace_probe_destroy): Delete.
611 (dtrace_type_name): Rename to...
612 (dtrace_static_probe_ops::type_name): ...this. Adjust code to
613 reflect change.
614 (dtrace_probe::get_static_ops): New method.
615 (dtrace_gen_info_probes_table_header): Rename to...
616 (dtrace_static_probe_ops::gen_info_probes_table_header):
617 ...this. Adjust code to reflect change.
618 (dtrace_gen_info_probes_table_values): Rename to...
619 (dtrace_probe::gen_info_probes_table_values): ...this. Adjust
620 code to reflect change.
621 (dtrace_enable_probe): Rename to...
622 (dtrace_probe::enable_probe): ...this. Adjust code to reflect
623 change.
624 (dtrace_disable_probe): Rename to...
625 (dtrace_probe::disable_probe): ...this. Adjust code to reflect
626 change.
627 (struct probe_ops dtrace_probe_ops): Delete.
628 (info_probes_dtrace_command): Call 'info_probes_for_spops'
629 instead of 'info_probes_for_ops'.
630 (_initialize_dtrace_probe): Use 'all_static_probe_ops' instead
631 of 'all_probe_ops'.
632
633 2017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
634 Simon Marchi <simark@simark.ca>
635
636 * stap-probe.c (struct probe_ops stap_probe_ops): Delete
637 variable.
638 (struct stap_probe_arg) <stap_probe_arg>: New constructor.
639 <aexpr>: Change type to 'expression_up'.
640 (stap_probe_arg_s): Delete type and VEC.
641 (struct stap_probe): Delete. Replace by...
642 (class stap_static_probe_ops): ...this and...
643 (class stap_probe): ...this. Rename variables to add 'm_'
644 prefix. Do not use 'union' for arguments anymore.
645 (stap_get_expected_argument_type): Receive probe name instead
646 of 'struct stap_probe'. Adjust code.
647 (stap_parse_probe_arguments): Rename to...
648 (stap_probe::parse_arguments): ...this. Adjust code to
649 reflect change.
650 (stap_get_probe_address): Rename to...
651 (stap_probe::get_relocated_address): ...this. Adjust code
652 to reflect change.
653 (stap_get_probe_argument_count): Rename to...
654 (stap_probe::get_argument_count): ...this. Adjust code
655 to reflect change.
656 (stap_get_arg): Rename to...
657 (stap_probe::get_arg_by_number'): ...this. Adjust code to
658 reflect change.
659 (can_evaluate_probe_arguments): Rename to...
660 (stap_probe::can_evaluate_arguments): ...this. Adjust code
661 to reflect change.
662 (stap_evaluate_probe_argument): Rename to...
663 (stap_probe::evaluate_argument): ...this. Adjust code
664 to reflect change.
665 (stap_compile_to_ax): Rename to...
666 (stap_probe::compile_to_ax): ...this. Adjust code to
667 reflect change.
668 (stap_probe_destroy): Delete.
669 (stap_modify_semaphore): Adjust comment.
670 (stap_set_semaphore): Rename to...
671 (stap_probe::set_semaphore): ...this. Adjust code to reflect
672 change.
673 (stap_clear_semaphore): Rename to...
674 (stap_probe::clear_semaphore): ...this. Adjust code to
675 reflect change.
676 (stap_probe::get_static_ops): New method.
677 (handle_stap_probe): Adjust code to create instance of
678 'stap_probe'.
679 (stap_get_probes): Rename to...
680 (stap_static_probe_ops::get_probes): ...this. Adjust code to
681 reflect change.
682 (stap_probe_is_linespec): Rename to...
683 (stap_static_probe_ops::is_linespec): ...this. Adjust code to
684 reflect change.
685 (stap_type_name): Rename to...
686 (stap_static_probe_ops::type_name): ...this. Adjust code to
687 reflect change.
688 (stap_gen_info_probes_table_header): Rename to...
689 (stap_static_probe_ops::gen_info_probes_table_header):
690 ...this. Adjust code to reflect change.
691 (stap_gen_info_probes_table_values): Rename to...
692 (stap_probe::gen_info_probes_table_values): ...this. Adjust
693 code to reflect change.
694 (struct probe_ops stap_probe_ops): Delete.
695 (info_probes_stap_command): Use 'info_probes_for_spops'
696 instead of 'info_probes_for_ops'.
697 (_initialize_stap_probe): Use 'all_static_probe_ops' instead
698 of 'all_probe_ops'.
699
700 2017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
701
702 * break-catch-throw.c (fetch_probe_arguments): Use
703 'probe.prob' instead of 'probe.probe'.
704 * breakpoint.c (create_longjmp_master_breakpoint): Call
705 'can_evaluate_arguments' and 'get_relocated_address' methods
706 from probe.
707 (create_exception_master_breakpoint): Likewise.
708 (add_location_to_breakpoint): Use 'sal->prob' instead of
709 'sal->probe'.
710 (bkpt_probe_insert_location): Call 'set_semaphore' method from
711 probe.
712 (bkpt_probe_remove_location): Likewise, for 'clear_semaphore'.
713 * elfread.c (elf_get_probes): Use 'static_probe_ops' instead
714 of 'probe_ops'.
715 (probe_key_free): Call 'delete' on probe.
716 (check_exception_resume): Use 'probe.prob' instead of
717 'probe.probe'.
718 * location.c (string_to_event_location_basic): Call
719 'probe_linespec_to_static_ops'.
720 * probe.c (class any_static_probe_ops): New class.
721 (any_static_probe_ops any_static_probe_ops): New variable.
722 (parse_probes_in_pspace): Receive 'static_probe_ops' as
723 argument. Adjust code to reflect change.
724 (parse_probes): Use 'static_probe_ops' instead of
725 'probe_ops'. Adjust code to reflect change.
726 (find_probes_in_objfile): Call methods to get name and
727 provider from probe.
728 (find_probe_by_pc): Use 'result.prob' instead of
729 'result.probe'. Call 'get_relocated_address' method from
730 probe.
731 (collect_probes): Adjust comment and argument list to receive
732 'static_probe_ops' instead of 'probe_ops'. Adjust code to
733 reflect change. Call necessary methods from probe.
734 (compare_probes): Call methods to get name and provider from
735 probes.
736 (gen_ui_out_table_header_info): Receive 'static_probe_ops'
737 instead of 'probe_ops'. Use 'std::vector' instead of VEC,
738 adjust code accordingly.
739 (print_ui_out_not_applicables): Likewise.
740 (info_probes_for_ops): Rename to...
741 (info_probes_for_spops): ...this. Receive 'static_probe_ops'
742 as argument instead of 'probe_ops'. Adjust code. Call
743 necessary methods from probe.
744 (info_probes_command): Use 'info_probes_for_spops'.
745 (enable_probes_command): Pass correct argument to
746 'collect_probes'. Call methods from probe.
747 (disable_probes_command): Likewise.
748 (get_probe_address): Move to 'any_static_probe_ops::get_address'.
749 (get_probe_argument_count): Move to
750 'any_static_probe_ops::get_argument_count'.
751 (can_evaluate_probe_arguments): Move to
752 'any_static_probe_ops::can_evaluate_arguments'.
753 (evaluate_probe_argument): Move to
754 'any_static_probe_ops::evaluate_argument'.
755 (probe_safe_evaluate_at_pc): Use 'probe.prob' instead of
756 'probe.probe'.
757 (probe_linespec_to_ops): Rename to...
758 (probe_linespec_to_static_ops): ...this. Adjust code.
759 (probe_any_is_linespec): Rename to...
760 (any_static_probe_ops::is_linespec): ...this.
761 (probe_any_get_probes): Rename to...
762 (any_static_probe_ops::get_probes): ...this.
763 (any_static_probe_ops::type_name): New method.
764 (any_static_probe_ops::gen_info_probes_table_header): New
765 method.
766 (compute_probe_arg): Use 'pc_probe.prob' instead of
767 'pc_probe.probe'. Call methods from probe.
768 (compile_probe_arg): Likewise.
769 (std::vector<const probe_ops *> all_probe_ops): Delete.
770 (std::vector<const static_probe_ops *> all_static_probe_ops):
771 New variable.
772 (_initialize_probe): Use 'all_static_probe_ops' instead of
773 'all_probe_ops'.
774 * probe.h (struct info_probe_column) <field_name>: Delete
775 extraneous newline
776 (info_probe_column_s): Delete type and VEC.
777 (struct probe_ops): Delete. Replace with...
778 (class static_probe_ops): ...this and...
779 (clas probe): ...this.
780 (struct bound_probe) <bound_probe>: Delete extraneous
781 newline. Adjust constructor to receive 'probe' instead of
782 'struct probe'.
783 <probe>: Rename to...
784 <prob>: ...this. Delete extraneous newline.
785 <objfile>: Delete extraneous newline.
786 (register_probe_ops): Delete unused prototype.
787 (info_probes_for_ops): Rename to...
788 (info_probes_for_spops): ...this. Adjust comment.
789 (get_probe_address): Move to 'probe::get_address'.
790 (get_probe_argument_count): Move to
791 'probe::get_argument_count'.
792 (can_evaluate_probe_arguments): Move to
793 'probe::can_evaluate_arguments'.
794 (evaluate_probe_argument): Move to 'probe::evaluate_argument'.
795 * solib-svr4.c (struct svr4_info): Adjust comment.
796 (struct probe_and_action) <probe>: Rename to...
797 <prob>: ...this.
798 (register_solib_event_probe): Receive 'probe' instead of
799 'struct probe' as argument. Use 'prob' instead of 'probe'
800 when applicable.
801 (solib_event_probe_action): Call 'get_argument_count' method
802 from probe. Adjust comment.
803 (svr4_handle_solib_event): Adjust comment. Call
804 'evaluate_argument' method from probe.
805 (svr4_create_probe_breakpoints): Call 'get_relocated_address'
806 from probe.
807 (svr4_create_solib_event_breakpoints): Use 'probe' instead of
808 'struct probe'. Call 'can_evaluate_arguments' from probe.
809 * symfile.h: Forward declare 'class probe' instead of 'struct
810 probe'.
811 * symtab.h: Likewise.
812 (struct symtab_and_line) <probe>: Rename to...
813 <prob>: ...this.
814 * tracepoint.c (start_tracing): Use 'prob' when applicable.
815 Call probe methods.
816 (stop_tracing): Likewise.
817
818 2017-11-22 Joel Brobecker <brobecker@adacore.com>
819
820 * ravenscar-thread.c (ravenscar_inferior_created): Remove
821 trailing newline at end of string in call to warning.
822
823 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
824
825 * osdata.h: Include vector isntead of vec.h.
826 (osdata_column_s): Remove typedef.
827 (struct osdata_column): Add constructor.
828 <name, value>: Change type to std::string.
829 (DEF_VEC_O (osdata_column_s)): Remove.
830 (osdata_item_s): Remove typedef.
831 (struct osdata_item) <columns>: Change type to std::vector.
832 (DEF_VEC_O (osdata_item_s)): Remove.
833 (struct osdata): Add constructor.
834 <type>: Change type to std::string.
835 <items>: Change type to std::vector.
836 (osdata_p): Remove typedef.
837 (DEF_VEC_P (osdata_p)): Remove.
838 (osdata_parse): Return a unique_ptr.
839 (osdata_free): Remove.
840 (make_cleanup_osdata_free): Remove.
841 (get_osdata): Return a unique_ptr.
842 (get_osdata_column): Return pointer to std::string, take a
843 reference to osdata_item as parameter.
844 * osdata.c (struct osdata_parsing_data) <osdata>: Change type to
845 unique_ptr.
846 <property_name>: Change type to std::string.
847 (osdata_start_osdata): Allocate osdata with new and adjust.
848 (osdata_start_item): Adjust.
849 (osdata_start_column): Adjust.
850 (osdata_end_column): Adjust.
851 (clear_parsing_data): Remove.
852 (osdata_parse): Return a unique_ptr and adjust, remove cleanup.
853 (osdata_item_clear): Remove.
854 (get_osdata): return a unique_ptr and adjust.
855 (get_osdata_column): Return a pointer to std::string and adjust.
856 (info_osdata): Adjust.
857 * mi/mi-main.c: Include <map>.
858 (free_vector_of_osdata_items): Remove.
859 (list_available_thread_groups): Adjust, use std::map instead of
860 splay tree.
861
862 2017-11-22 Simon Marchi <simon.marchi@ericsson.com>
863
864 * stack.c (iterate_over_block_locals): Add LOC_OPTIMIZED_OUT
865 case in switch.
866
867 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
868
869 * varobj.h (DEF_VEC_P (varobj_p)): Remove.
870
871 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
872
873 * varobj.h (struct varobj_update_result): Add constructor, add
874 move constructor, disable copy and assign, initialize fields.
875 <newobj>: Change type to std::vector.
876 (varobj_update): Return std::vector.
877 * varobj.c (install_dynamic_child): Change VEC parameters to
878 std::vector and adjust.
879 (update_dynamic_varobj_children): Likewise.
880 (varobj_update): Return std::vector and adjust.
881 * mi/mi-cmd-var.c (varobj_update_one): Adjust to vector changes.
882
883 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
884
885 * varobj.h (struct varobj) <parent>: Remove const.
886 <children>: Change type to std::vector.
887 (varobj_list_children): Return std::vector const reference.
888 (varobj_restrict_range): Change parameter type to std::vector
889 const reference.
890 * varobj.c (varobj_has_more): Adjust.
891 (varobj_restrict_range): Change parameter type to std::vector
892 const reference and adjust.
893 (install_dynamic_child): Adjust.
894 (update_dynamic_varobj_children): Adjust.
895 (varobj_list_children): Return std::vector const reference and
896 adjust.
897 (varobj_add_child): Adjust.
898 (update_type_if_necessary): Adjust.
899 (varobj_update): Adjust.
900 (delete_variable_1): Adjust.
901 * ada-varobj.c (ada_value_has_mutated): Adjust.
902 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Adjust.
903
904 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
905
906 * varobj.h (struct varobj): Add constructor and destructor,
907 initialize fields.
908 * varobj.c (struct varobj_root): Initialize fields.
909 (struct varobj_dynamic): Initialize fields.
910 (varobj_create): Use unique_ptr instead of cleanup. Create
911 varobj with new instead of new_root_variable.
912 (delete_variable_1): Free variable with delete instead of
913 free_variable.
914 (create_child_with_value): Create variable with new instead of
915 new_variable.
916 (varobj::varobj): New.
917 (varobj::~varobj): New (body mostly coming from free_variable).
918 (new_variable): Remove.
919 (free_variable): Remove.
920 (do_free_variable_cleanup): Remove.
921 (make_cleanup_free_variable): Remove.
922
923 2017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
924
925 * core-regset.c: Remove file.
926 * Makefile.in (ALLDEPFILES): Remove core-regset.c.
927
928 2017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
929
930 * NEWS: Document use of GNU MPFR.
931 * README: Likewise.
932
933 * Makefile.in (LIBMPFR): Add define.
934 (CLIBS): Add $(LIBMPFR).
935 * configure.ac: Add --with-mpfr configure option.
936 * configure: Regenerate.
937 * config.in: Regenerate.
938
939 * target-float.c [HAVE_LIBMPFR]: Include <mpfr.h>.
940 (class mpfr_float_ops): New type.
941 (mpfr_float_ops::from_target): Two new overloaded functions.
942 (mpfr_float_ops::to_target): Likewise.
943 (mpfr_float_ops::to_string): New function.
944 (mpfr_float_ops::from_string): Likewise.
945 (mpfr_float_ops::to_longest): Likewise.
946 (mpfr_float_ops::from_longest): Likewise.
947 (mpfr_float_ops::from_ulongest): Likewise.
948 (mpfr_float_ops::to_host_double): Likewise.
949 (mpfr_float_ops::from_host_double): Likewise.
950 (mpfr_float_ops::convert): Likewise.
951 (mpfr_float_ops::binop): Likewise.
952 (mpfr_float_ops::compare): Likewise.
953 (get_target_float_ops): Use mpfr_float_ops if available.
954
955 2017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
956
957 * target-float.c: Do not include <math.h>.
958 Include <cmath> and <limits>.
959 (DOUBLEST): Do not define.
960 (class target_float_ops): New type.
961 (class host_float_ops): New templated type.
962 (class decimal_float_ops): New type.
963
964 (floatformat_to_doublest): Rename to ...
965 (host_float_ops<T>::from_target): ... this. Use template type T
966 instead of DOUBLEST. Use C++ math routines. Update recursive calls.
967 (host_float_ops<T>::from_target): New overload using a type argument.
968 (floatformat_from_doublest): Rename to ...
969 (host_float_ops<T>::to_target): ... this. Use template type T
970 instead of DOUBLEST. Use C++ math routines. Update recursive calls.
971 (host_float_ops<T>::to_target): New overload using a type argument.
972 (floatformat_printf_format): New function.
973 (struct printf_length_modifier): New templated type.
974 (floatformat_to_string): Rename to ...
975 (host_float_ops<T>::to_string): ... this. Use type instead of
976 floatformat argument. Use floatformat_printf_format and
977 printf_length_modifier. Remove special handling of invalid numbers,
978 infinities and NaN (moved to target_float_to_string).
979 (struct scanf_length_modifier): New templated type.
980 (floatformat_from_string): Rename to ...
981 (host_float_ops<T>::from_string): ... this. Use type instead of
982 floatformat argument. Use scanf_length_modifier.
983 (floatformat_to_longest): Rename to ...
984 (host_float_ops<T>::to_longest): ... this. Use type instead of
985 floatformat argument. Handle out-of-range values deterministically.
986 (floatformat_from_longest): Rename to ...
987 (host_float_ops<T>::from_longest): ... this. Use type instead of
988 floatformat argument.
989 (floatformat_from_ulongest): Rename to ...
990 (host_float_ops<T>::from_ulongest): ... this. Use type instead of
991 floatformat argument.
992 (floatformat_to_host_double): Rename to ...
993 (host_float_ops<T>::to_host_double): ... this. Use type instead of
994 floatformat argument.
995 (floatformat_from_host_double): Rename to ...
996 (host_float_ops<T>::from_host_double): ... this. Use type instead of
997 floatformat argument.
998 (floatformat_convert): Rename to ...
999 (host_float_ops<T>::convert): ... this. Use type instead of
1000 floatformat arguments. Remove handling of no-op conversions.
1001 (floatformat_binop): Rename to ...
1002 (host_float_ops<T>::binop): ... this. Use type instead of
1003 floatformat arguments.
1004 (floatformat_compare): Rename to ...
1005 (host_float_ops<T>::compare): ... this. Use type instead of
1006 floatformat arguments.
1007
1008 (match_endianness): Use type instead of length/byte_order arguments.
1009 (set_decnumber_context): Likewise.
1010 (decimal_from_number): Likewise. Update calls.
1011 (decimal_to_number): Likewise.
1012 (decimal_is_zero): Likewise. Update calls. Move to earlier in file.
1013 (decimal_float_ops::to_host_double): New dummy function.
1014 (decimal_float_ops::from_host_double): Likewise.
1015 (decimal_to_string): Rename to ...
1016 (decimal_float_ops::to_string): ... this. Use type instead of
1017 length/byte_order arguments. Update calls.
1018 (decimal_from_string): Rename to ...
1019 (decimal_float_ops::from_string): ... this. Use type instead of
1020 length/byte_order arguments. Update calls.
1021 (decimal_from_longest): Rename to ...
1022 (decimal_float_ops::from_longest): ... this. Use type instead of
1023 length/byte_order arguments. Update calls.
1024 (decimal_from_ulongest): Rename to ...
1025 (decimal_float_ops::from_ulongest): ... this. Use type instead of
1026 length/byte_order arguments. Update calls.
1027 (decimal_to_longest): Rename to ...
1028 (decimal_float_ops::to_longest): ... this. Use type instead of
1029 length/byte_order arguments. Update calls.
1030 (decimal_binop): Rename to ...
1031 (decimal_float_ops::binop): ... this. Use type instead of
1032 length/byte_order arguments. Update calls.
1033 (decimal_compare): Rename to ...
1034 (decimal_float_ops::compare): ... this. Use type instead of
1035 length/byte_order arguments. Update calls.
1036 (decimal_convert): Rename to ...
1037 (decimal_float_ops::convert): ... this. Use type instead of
1038 length/byte_order arguments. Update calls.
1039
1040 (target_float_same_category_p): New function.
1041 (target_float_same_format_p): Likewise.
1042 (target_float_format_length): Likewise.
1043 (enum target_float_ops_kind): New type.
1044 (get_target_float_ops_kind): New function.
1045 (get_target_float_ops): Three new overloaded functions.
1046
1047 (target_float_is_zero): Update call.
1048 (target_float_to_string): Add special handling of invalid numbers,
1049 infinities and NaN (moved from floatformat_to_string). Use
1050 target_float_ops callback.
1051 (target_float_from_string): Use target_float_ops callback.
1052 (target_float_to_longest): Likewise.
1053 (target_float_from_longest): Likewise.
1054 (target_float_from_ulongest): Likewise.
1055 (target_float_to_host_double): Likewise.
1056 (target_float_from_host_double): Likewise.
1057 (target_float_convert): Add special case for no-op conversions.
1058 Use target_float_ops callback.
1059 (target_float_binop): Use target_float_ops callback.
1060 (target_float_compare): Likewise.
1061
1062 2017-11-22 Yao Qi <yao.qi@linaro.org>
1063
1064 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use strcpy.
1065
1066 2017-11-22 Yao Qi <yao.qi@linaro.org>
1067
1068 * cli/cli-decode.c (help_list): Use memcpy instead of strncpy.
1069 * cp-namespace.c (cp_lookup_transparent_type_loop): Likewise.
1070
1071 2017-11-21 Jerome Guitton <guitton@adacore.com>
1072
1073 * ravenscar-thread.c (ravenscar_wait): Update inferior ptid
1074 with event ptid from the lower layer before doing the
1075 ravenscar-specific update.
1076
1077 2017-11-21 Joel Brobecker <brobecker@adacore.com>
1078
1079 * ravenscar-thread.c (is_ravenscar_task): Also verify that
1080 the ptid's TID is nonzero.
1081
1082 2017-11-21 Joel Brobecker <brobecker@adacore.com>
1083
1084 * ada-lang.h (ada_get_tcb_types_info): Add declaration.
1085 * ada-tasks.c (ada_get_tcb_types_info): Renames get_tcb_types_info.
1086 Make non-static. Change return type to char *. Adjust code
1087 accordingly. Rewrite the function's documentation.
1088 (read_atcb): Adjust call to get_tcb_types_info accordingly.
1089 * ravenscar-thread.c (ravenscar_inferior_created): Check that
1090 we have enough debugging information in the runtime to support
1091 Ada task debugging before we enable the ravenscar-thread layer.
1092
1093 2017-11-21 Joel Brobecker <brobecker@adacore.com>
1094
1095 * ada-lang.h (ada_get_task_info_from_ptid): Add declaration.
1096 * ada-tasks.c (ada_get_task_info_from_ptid): New function.
1097 * ravenscar-thread.c: Add into comment.
1098 (base_magic_null_ptid): Delete.
1099 (base_ptid): Change documentation.
1100 (ravenscar_active_task): Renames ravenscar_running_thread.
1101 All callers updated throughout.
1102 (is_ravenscar_task, ravenscar_get_thread_base_cpu): New function.
1103 (ravenscar_task_is_currently_active): Likewise.
1104 (get_base_thread_from_ravenscar_task): Ditto.
1105 (ravenscar_update_inferior_ptid): Adjust to handle multiple CPUs.
1106 (ravenscar_runtime_initialized): Likewise.
1107 (get_running_thread_id): Add new parameter "cpu". Adjust
1108 implementation to handle this new parameter.
1109 (ravenscar_fetch_registers): Small adjustment to use
1110 is_ravenscar_task and ravenscar_task_is_currently_active in
1111 order to decide whether to use the target beneath or this
1112 module's arch_ops.
1113 (ravenscar_store_registers, ravenscar_prepare_to_store): Likewise.
1114 (ravenscar_stopped_by_sw_breakpoint): Use
1115 get_base_thread_from_ravenscar_task to get the underlying
1116 thread, rather than using base_ptid.
1117 (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
1118 (ravenscar_stopped_data_address, ravenscar_core_of_thread):
1119 Likewise.
1120 (ravenscar_inferior_created): Do not set base_magic_null_ptid.
1121
1122 2017-11-21 Joel Brobecker <brobecker@adacore.com>
1123
1124 * ada-lang.h (struct ada_task_info) <base_cpu>: New field.
1125 * ada-lang.c (struct atcb_fieldno) <base_cpu>: New field.
1126 (get_tcb_types_info): Set fieldnos.base_cpu.
1127 (read_atcb): Set task_info->base_cpu.
1128 (info_task): Print "Base CPU" info if set by runtime.
1129
1130 2017-11-21 Joel Brobecker <brobecker@adacore.com>
1131
1132 * ravenscar-thread.c (ravenscar_stopped_by_sw_breakpoint)
1133 (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
1134 (ravenscar_stopped_data_address, ravenscar_core_of_thread):
1135 New functions.
1136 (init_ravenscar_thread_ops): Set the to_stopped_by_sw_breakpoint,
1137 to_stopped_by_hw_breakpoint, to_stopped_by_watchpoint,
1138 to_stopped_data_address and to_core_of_thread fields of
1139 ravenscar_ops.
1140
1141 2017-11-21 Ulrich Weigand <uweigand@de.ibm.com>
1142
1143 * ppc-tdep.h (enum powerpc_long_double_abi): New data type.
1144 (struct gdbarch_tdep): New member long_double_abi.
1145 * rs6000-tdep.c (rs6000_gdbarch_init): Initialize long_double_abi
1146 member of tdep struct based on Tag_GNU_Power_ABI_FP attribute.
1147 * ppc-linux-tdep.c (ppc_linux_init_abi): Install long double data
1148 format depending on long_double_abi tdep member.
1149 (ppc_floatformat_for_type): Handle __ibm128 type.
1150
1151 2017-11-20 Simon Marchi <simon.marchi@polymtl.ca>
1152
1153 * darwin-nat.c (set_enable_mach_exceptions): Constify parameter.
1154
1155 2017-11-21 Pedro Alves <palves@redhat.com>
1156
1157 * dwarf2read.c (mapped_index::find_name_components_bounds)
1158 <completion mode, upper bound>: Use std::lower_bound instead of
1159 std::upper_bound.
1160 (test_mapped_index_find_name_component_bounds): Remove incorrect
1161 "t1_fund" from expected symbols.
1162
1163 2017-11-21 Pedro Alves <palves@redhat.com>
1164
1165 * dwarf2read.c (mapped_index::name_components_casing): New field.
1166 (mapped_index) <build_name_components,
1167 find_name_components_bounds): Declare new methods.
1168 (mapped_index::find_name_components_bounds)
1169 (mapped_index::build_name_components): New methods, factored out
1170 from dw2_expand_symtabs_matching_symbol.
1171 (check_find_bounds_finds)
1172 (test_mapped_index_find_name_component_bounds): New.
1173 (run_test): Rename to ...
1174 (test_dw2_expand_symtabs_matching_symbol): ... this.
1175 (run_test): Reimplement.
1176
1177 2017-11-21 Pedro Alves <palves@redhat.com>
1178
1179 * cp-name-parser.y (cp_ident_is_alpha, cp_ident_is_alnum): New.
1180 (symbol_end): Use cp_ident_is_alnum.
1181 (yylex): Use cp_ident_is_alpha and cp_ident_is_alnum.
1182 * dwarf2read.c (make_sort_after_prefix_name): New function.
1183 (dw2_expand_symtabs_matching_symbol): Use it.
1184 (test_symbols): Add more symbols.
1185 (run_test): Add tests.
1186
1187 2017-11-17 Tom Tromey <tom@tromey.com>
1188
1189 * symtab.h (enum symbol_subclass_kind): New.
1190 (struct symbol) <is_cplus_template_function, is_rust_vtable>:
1191 Remove.
1192 <subclass>: New member.
1193 (SYMBOL_IS_CPLUS_TEMPLATE_FUNCTION): Update.
1194 * rust-lang.c (rust_get_trait_object_pointer): Update.
1195 * dwarf2read.c (read_func_scope): Update.
1196 (read_variable): Update.
1197
1198 2017-11-17 Tom Tromey <tom@tromey.com>
1199
1200 * dwarf2read.c (read_func_scope): Update.
1201 * symtab.h (struct template_symbol): Derive from symbol.
1202 <base>: Remove.
1203
1204 2017-11-17 Tom Tromey <tom@tromey.com>
1205
1206 * symtab.h (struct symbol) <is_rust_vtable>: New member.
1207 (struct rust_vtable_symbol): New.
1208 (find_symbol_at_address): Declare.
1209 * symtab.c (find_symbol_at_address): New function.
1210 * symfile.h (struct quick_symbol_functions)
1211 <find_compunit_symtab_by_address>: New member.
1212 * symfile-debug.c (debug_qf_find_compunit_symtab_by_address): New
1213 function.
1214 (debug_sym_quick_functions): Link to
1215 debug_qf_find_compunit_symtab_by_address.
1216 * rust-lang.c (rust_get_trait_object_pointer): New function.
1217 (rust_evaluate_subexp) <case UNOP_IND>: New case. Call
1218 rust_get_trait_object_pointer.
1219 * psymtab.c (psym_relocate): Clear psymbol_map.
1220 (psym_fill_psymbol_map, psym_find_compunit_symtab_by_address): New
1221 functions.
1222 (psym_functions): Link to psym_find_compunit_symtab_by_address.
1223 * objfiles.h (struct objfile) <psymbol_map>: New member.
1224 * dwarf2read.c (dwarf2_gdb_index_functions): Update.
1225 (process_die) <DW_TAG_variable>: New case. Call read_variable.
1226 (rust_containing_type, read_variable): New functions.
1227
1228 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
1229
1230 * common/gdb_vecs.h (DEF_VEC_I (int)): Remove.
1231
1232 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
1233
1234 * common/filestuff.c: Include <algorithm>.
1235 (open_fds): Change type to std::vector<int>.
1236 (do_mark_open_fd): Adjust.
1237 (unmark_fd_no_cloexec): Adjust.
1238 (do_close): Adjust.
1239
1240 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
1241
1242 * breakpoint.c (output_thread_groups): Take an std::vector.
1243 (print_one_breakpoint_location): Adjust.
1244
1245 2017-11-17 Joel Brobecker <brobecker@adacore.com>
1246
1247 * ada-lang.c (resolve_subexp): Add handling of OP_VAR_MSYM_VALUE.
1248 (ada_evaluate_subexp_for_cast): New function.
1249 (ada_evaluate_subexp) <UNOP_CAST>: Replace code by call to
1250 ada_evaluate_subexp_for_cast.
1251 (ada_evaluate_subexp) <nosideret>: Replace code by call to
1252 eval_skip_value.
1253 * eval.c (evaluate_var_value): Make non-static.
1254 (evaluate_var_msym_value, eval_skip_value): Likewise.
1255 * value.h (evaluate_var_value, evaluate_var_msym_value)
1256 (eval_skip_value): Declare.
1257
1258 2017-11-16 Joel Brobecker <brobecker@adacore.com>
1259
1260 * ada-lang.c (ada_value_cast): Remove parameter "noside".
1261 Update all callers.
1262
1263 2017-11-16 Pedro Alves <palves@redhat.com>
1264
1265 * python/py-unwind.c (pyuw_sniffer): Translate
1266 PyExc_KeyboardInterrupt to a GDB Quit exception.
1267
1268 2017-11-16 Pedro Alves <palves@redhat.com>
1269
1270 * infrun.c (resume_cleanups): Delete.
1271 (resume): No longer install a resume_cleanups cleanup nor call
1272 QUIT.
1273 (proceed): Pass the terminal to the inferior.
1274 (keep_going_pass_signal): No longer install a resume_cleanups
1275 cleanup.
1276
1277 2017-11-16 Pedro Alves <palves@redhat.com>
1278
1279 * inf-loop.c (inferior_event_handler): Don't swallow the exception
1280 if the prompt is blocked.
1281
1282 2017-11-16 Pedro Alves <palves@redhat.com>
1283
1284 * breakpoint.c (insert_bp_location): Replace bp_err and
1285 bp_err_message locals by a gdb_exception local.
1286
1287 2017-11-16 Pedro Alves <palves@redhat.com>
1288
1289 * inflow.c (scoped_ignore_sigttou): New class.
1290 (child_terminal_ours_1, new_tty): Use it.
1291
1292 2017-11-16 Ulrich Weigand <uweigand@de.ibm.com>
1293
1294 * target-float.c (decimal_from_number): Add byte_order argument and
1295 call match_endianness. Error if unknown floating-point type.
1296 (decimal_to_number): Add byte_order argument and call match_endianness.
1297 (decimal_from_longest): Update call. Do not call match_endianness.
1298 (decimal_from_ulongest): Likewise.
1299 (decimal_binop): Likewise.
1300 (decimal_is_zero): Likewise.
1301 (decimal_compare): Likewise.
1302 (decimal_convert): Likewise.
1303
1304 2017-11-16 Phil Muldoon <pmuldoon@redhat.com>
1305
1306 * python/python.c (gdbpy_rbreak): New function.
1307 * NEWS: Document Python rbreak feature.
1308
1309 2017-11-16 Yao Qi <yao.qi@linaro.org>
1310
1311 * features/tic6x-c62x.xml: Remove.
1312 * features/tic6x-c64x.xml: Remove.
1313 * features/tic6x-c64xp.xml: Remove.
1314
1315 2017-11-15 John Baldwin <jhb@FreeBSD.org>
1316
1317 * symtab.h: Include <array>.
1318
1319 2017-11-15 John Baldwin <jhb@FreeBSD.org>
1320
1321 * bsd-kvm.c (bsd_kvm_cmd): Constify 'arg'.
1322 (bsd_kvm_proc_cmd): Likewise.
1323
1324 2017-11-15 Simon Marchi <simon.marchi@ericsson.com>
1325
1326 * tui/tui-win.c (window_name_completer): Replace VEC with
1327 std::vector.
1328
1329 2017-11-15 Andrew Cagney <cagney@gnu.org>
1330
1331 * MAINTAINERS: Remove no-longer applicable entries.
1332
1333 2017-11-15 Andrew Cagney <cagney@gnu.org>
1334
1335 * MAINTAINERS: Move self to Past Maintainers.
1336
1337 2017-11-15 Yao Qi <yao.qi@linaro.org>
1338
1339 * features/Makefile (XMLTOC): Remove nios2-linux.xml.
1340 * features/nios2-linux.c: Remove.
1341 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Don't call
1342 initialize_tdesc_nios2_linux.
1343
1344 2017-11-15 Yao Qi <yao.qi@linaro.org>
1345
1346 * m68hc11-tdep.c (M68HC11_NUM_REGS): Change it to
1347 M68HC11_LAST_HARD_REG + 1.
1348
1349 2017-11-14 Paul Carroll <pcarroll@codesourcery.com>
1350
1351 PR gdb/22388
1352 * remote.c (remote_write_bytes_aux, remote_read_bytes_1,
1353 remote_read_bytes, remote_write_qxfer, remote_xfer_partial):
1354 Return TARGET_XFER_EOF if size of returned data is 0.
1355
1356 2017-11-14 Simon Marchi <simon.marchi@ericsson.com>
1357
1358 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1359 memory-map-selftests.c.
1360 (SUBDIR_UNITTESTS_OBS): Add memory-map-selftests.o.
1361 * memory-map.c (memory_map_start_memory): Fix computation of hi
1362 address.
1363 * unittests/memory-map-selftests.c: New file.
1364
1365 2017-11-09 Joel Brobecker <brobecker@adacore.com>
1366
1367 * ada-lang.c: Fix some typos in the general command documenting
1368 how Ada expressions are being evaluated and how their result
1369 is printed.
1370
1371 2017-11-09 Tom Tromey <tom@tromey.com>
1372
1373 * psymtab.c (psymbol_hash): Do not hash string contents.
1374 (psymbol_compare): Add comment.
1375
1376 2017-11-09 Tom Tromey <tom@tromey.com>
1377
1378 * dictionary.c (dict_hash): Move "TKB" check into the "switch".
1379
1380 2017-11-08 Joel Brobecker <brobecker@adacore.com>
1381
1382 * ada-exp.y (write_var_from_sym): Remove parameter
1383 "orig_left_context". Update all callers.
1384
1385 2017-11-08 Simon Marchi <simon.marchi@ericsson.com>
1386
1387 * tracepoint.h (class collection_list) <stringify>: Return
1388 std::vector<std::string>.
1389 (encode_actions_rsp): Change parameters to
1390 std::vector<std::string> *.
1391 * tracepoint.c (collection_list::stringify): Return
1392 std::vector<std::string> and adjust accordingly.
1393 (encode_actions_rsp): Changee parameters to
1394 std::vector<std::string> and adjust accordingly.
1395 * remote.c (free_actions_list),
1396 free_actions_list_cleanup_wrapper): Remove.
1397 (remote_download_tracepoint): Adjust to std::vector.
1398
1399 2017-11-08 Tom Tromey <tom@tromey.com>
1400
1401 * dwarf2read.c (symbolp): Remove typedef.
1402 (read_func_scope): Use std::vector.
1403 (process_structure_scope): Use std::vector.
1404
1405 2017-11-08 Pedro Alves <palves@redhat.com>
1406
1407 * ada-lang.c (ada_make_symbol_completion_list): Use
1408 completion_skip_symbol.
1409 * symtab.c (symbol_is_function_or_method(minimal_symbol*)): New.
1410 (symbol_is_function_or_method(symbol*)): New.
1411 (add_symtab_completions): Add complete_symbol_mode parameter. Use
1412 completion_skip_symbol.
1413 (default_collect_symbol_completion_matches_break_on): Use
1414 completion_skip_symbol. Pass down mode.
1415 (collect_file_symbol_completion_matches): Pass down mode.
1416 * symtab.h (symbol_is_function_or_method): New declarations.
1417 (completion_skip_symbol): New template function.
1418
1419 2017-11-08 Pedro Alves <palves@redhat.com>
1420
1421 * linespec.c (iterate_over_all_matching_symtabs): Add
1422 search_domain parameter. Pass it down to expand_symtabs_matching.
1423 (decode_objc): Request FUNCTIONS_DOMAIN symbols only.
1424 (lookup_prefix_sym): Adjust by passing ALL_DOMAIN as
1425 search_domain.
1426 (add_all_symbol_names_from_pspace): Add search_domain parameter.
1427 Pass it down.
1428 (find_method, find_function_symbols): Request FUNCTIONS_DOMAIN
1429 symbols.
1430 (add_matching_symbols_to_info): Add search_domain parameter. Pass
1431 it down.
1432
1433 2017-11-08 Pedro Alves <palves@redhat.com>
1434
1435 * ada-lang.c (ada_make_symbol_completion_list): Remove text and
1436 text_len locals and don't pass them down.
1437 * symtab.c (completion_list_add_name): Remove
1438 sym_text/sym_text_len parameters and adjust.
1439 (completion_list_add_symbol, completion_list_add_msymbol)
1440 (completion_list_objc_symbol, completion_list_add_fields)
1441 (add_symtab_completions): Likewise.
1442 (default_collect_symbol_completion_matches_break_on)
1443 (collect_file_symbol_completion_matches): Remove sym_text_len
1444 local and don't pass it down.
1445 * symtab.h (completion_list_add_name): Remove
1446 sym_text/sym_text_len parameters.
1447
1448 2017-11-08 Pedro Alves <palves@redhat.com>
1449
1450 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1451 unittests/lookup_name_info-selftests.c.
1452 (SUBDIR_UNITTESTS_OBS): Add lookup_name_info-selftests.o.
1453 * cp-support.c: Include "selftest.h".
1454 (cp_remove_params_1): Rename from cp_remove_params. Add
1455 'require_param' parameter, and handle it.
1456 (cp_remove_params): Reimplement.
1457 (cp_remove_params_if_any): New.
1458 (selftests::quote): New.
1459 (selftests::check_remove_params): New.
1460 (selftests::test_cp_remove_params): New.
1461 (_initialize_cp_support): Install
1462 selftests::test_cp_remove_params.
1463 * cp-support.h (cp_remove_params_if_any): Declare.
1464 * dwarf2read.c :Include "selftest.h".
1465 (dw2_expand_symtabs_matching_symbol): Use
1466 lookup_name_info::make_ignore_params.
1467 (selftests::dw2_expand_symtabs_matching::mock_mapped_index)
1468 (selftests::dw2_expand_symtabs_matching::string_or_null)
1469 (selftests::dw2_expand_symtabs_matching::check_match)
1470 (selftests::dw2_expand_symtabs_matching::test_symbols)
1471 (selftests::dw2_expand_symtabs_matching::run_test): New.
1472 (_initialize_dwarf2_read): Register
1473 selftests::dw2_expand_symtabs_matching::run_test.
1474 * psymtab.c (psym_expand_symtabs_matching): Use
1475 lookup_name_info::make_ignore_params.
1476 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info):
1477 If the lookup name wants to ignore parameters, strip them.
1478 (compare_symbol_name): Remove sym_text/sym_text_len parameters and
1479 code handling '('.
1480 (completion_list_add_name): Don't pass down sym_text/sym_text_len.
1481 (default_collect_symbol_completion_matches_break_on): Don't try to
1482 strip parameters.
1483 * symtab.h (lookup_name_info::lookup_name_info): Add
1484 'ignore_parameters' parameter.
1485 (lookup_name_info::ignore_parameters)
1486 (lookup_name_info::make_ignore_params): New methods.
1487 (lookup_name_info::m_ignore_parameters): New field.
1488 * unittests/lookup_name_info-selftests.c: New file.
1489
1490 2017-11-08 Pedro Alves <palves@redhat.com>
1491
1492 * dwarf2read.c (dw2_expand_marked_cus)
1493 (dw2_expand_symtabs_matching_symbol): Remove forward declarations.
1494 (dw2_expand_symtabs_matching): Move further below.
1495 (dw2_expand_marked_cus): Reindent.
1496
1497 2017-11-08 Pedro Alves <palves@redhat.com>
1498
1499 * dwarf2read.c (byte_swap, MAYBE_SWAP): Move higher up in file.
1500 (struct name_component): New.
1501 (mapped_index::name_components): New field.
1502 (mapped_index::symbol_name_at): New method.
1503 (dwarf2_read_index): Call mapped_index ctor.
1504 (dw2_map_matching_symbols): Add comment about name_components
1505 table.
1506 (dw2_expand_symtabs_matching): Factor part to...
1507 (dw2_expand_symtabs_matching_symbol): ... this new function.
1508 Build name components table, and lookup symbols in it before
1509 calling the name matcher.
1510 (dw2_expand_marked_cus): New, factored out from
1511 dw2_expand_symtabs_matching.
1512 (dwarf2_per_objfile_free): Call the mapped_index's dtor.
1513
1514 2017-11-08 Pedro Alves <palves@redhat.com>
1515
1516 * ada-lang.c (ada_encode): Rename to ..
1517 (ada_encode_1): ... this. Add throw_errors parameter and handle
1518 it.
1519 (ada_encode): Reimplement.
1520 (match_name): Delete, folded into full_name.
1521 (resolve_subexp): No longer pass the encoded name to
1522 ada_lookup_symbol_list.
1523 (should_use_wild_match): Delete.
1524 (name_match_type_from_name): New.
1525 (ada_lookup_simple_minsym): Use lookup_name_info and the
1526 language's symbol_name_matcher_ftype.
1527 (add_symbols_from_enclosing_procs, ada_add_local_symbols)
1528 (ada_add_block_renamings): Adjust to use lookup_name_info.
1529 (ada_lookup_name): New.
1530 (add_nonlocal_symbols, ada_add_all_symbols)
1531 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list)
1532 (ada_iterate_over_symbols): Adjust to use lookup_name_info.
1533 (ada_name_for_lookup): Delete.
1534 (ada_lookup_encoded_symbol): Construct a verbatim name.
1535 (wild_match): Reverse sense of return type. Use bool.
1536 (full_match): Reverse sense of return type. Inline bits of old
1537 match_name here.
1538 (ada_add_block_symbols): Adjust to use lookup_name_info.
1539 (symbol_completion_match): Delete, folded into...
1540 (ada_lookup_name_info::matches): ... .this new method.
1541 (symbol_completion_add): Delete.
1542 (ada_collect_symbol_completion_matches): Add name_match_type
1543 parameter. Adjust to use lookup_name_info and
1544 completion_list_add_name.
1545 (get_var_value, ada_add_global_exceptions): Adjust to use
1546 lookup_name_info.
1547 (ada_get_symbol_name_cmp): Delete.
1548 (do_wild_match, do_full_match): New functions.
1549 (ada_lookup_name_info::ada_lookup_name_info): New method.
1550 (ada_symbol_name_matches, ada_get_symbol_name_matcher): New
1551 functions.
1552 (ada_language_defn): Install ada_get_symbol_name_matcher.
1553 * ada-lex.l (processId): If name starts with '<', copy it
1554 verbatim.
1555 * block.c (block_iter_match_step, block_iter_match_first)
1556 (block_iter_match_next, block_lookup_symbol)
1557 (block_lookup_symbol_primary, block_find_symbol): Adjust to use
1558 lookup_name_info.
1559 * block.h (block_iter_match_first, block_iter_match_next)
1560 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use lookup_name_info.
1561 * c-lang.c (c_language_defn, cplus_language_defn)
1562 (asm_language_defn, minimal_language_defn): Adjust comments to
1563 refer to la_get_symbol_name_matcher.
1564 * completer.c (complete_files_symbols)
1565 (collect_explicit_location_matches, symbol_completer): Pass a
1566 symbol_name_match_type down.
1567 * completer.h (class completion_match, completion_match_result):
1568 New classes.
1569 (completion_tracker::reset_completion_match_result): New method.
1570 (completion_tracker::m_completion_match_result): New field.
1571 * cp-support.c (make_symbol_overload_list_block): Adjust to use
1572 lookup_name_info.
1573 (cp_fq_symbol_name_matches, cp_get_symbol_name_matcher): New
1574 functions.
1575 * cp-support.h (cp_get_symbol_name_matcher): New declaration.
1576 * d-lang.c: Adjust comments to refer to
1577 la_get_symbol_name_matcher.
1578 * dictionary.c (dict_vector) <iter_match_first, iter_match_next>:
1579 Adjust to use lookup_name_info.
1580 (dict_iter_match_first, dict_iter_match_next)
1581 (iter_match_first_hashed, iter_match_next_hashed)
1582 (iter_match_first_linear, iter_match_next_linear): Adjust to work
1583 with a lookup_name_info.
1584 * dictionary.h (dict_iter_match_first, dict_iter_match_next):
1585 Likewise.
1586 * dwarf2read.c (dw2_lookup_symbol): Adjust to use lookup_name_info.
1587 (dw2_map_matching_symbols): Adjust to use symbol_name_match_type.
1588 (gdb_index_symbol_name_matcher): New class.
1589 (dw2_expand_symtabs_matching) Adjust to use lookup_name_info and
1590 gdb_index_symbol_name_matcher. Accept a NULL symbol_matcher.
1591 * f-lang.c (f_collect_symbol_completion_matches): Adjust to work
1592 with a symbol_name_match_type.
1593 (f_language_defn): Adjust comments to refer to
1594 la_get_symbol_name_matcher.
1595 * go-lang.c (go_language_defn): Adjust comments to refer to
1596 la_get_symbol_name_matcher.
1597 * language.c (default_symbol_name_matcher)
1598 (language_get_symbol_name_matcher): New functions.
1599 (unknown_language_defn, auto_language_defn): Adjust comments to
1600 refer to la_get_symbol_name_matcher.
1601 * language.h (symbol_name_cmp_ftype): Delete.
1602 (language_defn) <la_collect_symbol_completion_matches>: Add match
1603 type parameter.
1604 <la_get_symbol_name_cmp>: Delete field.
1605 <la_get_symbol_name_matcher>: New field.
1606 <la_iterate_over_symbols>: Adjust to use lookup_name_info.
1607 (default_symbol_name_matcher, language_get_symbol_name_matcher):
1608 Declare.
1609 * linespec.c (iterate_over_all_matching_symtabs)
1610 (iterate_over_file_blocks): Adjust to use lookup_name_info.
1611 (find_methods): Add language parameter, and use lookup_name_info
1612 and the language's symbol_name_matcher_ftype.
1613 (linespec_complete_function): Adjust.
1614 (lookup_prefix_sym): Use lookup_name_info.
1615 (add_all_symbol_names_from_pspace): Adjust.
1616 (find_superclass_methods): Add language parameter and pass it
1617 down.
1618 (find_method): Pass symbol language down.
1619 (find_linespec_symbols): Don't demangle or Ada encode here.
1620 (search_minsyms_for_name): Add lookup_name_info parameter.
1621 (add_matching_symbols_to_info): Add name_match_type parameter.
1622 Use lookup_name_info.
1623 * m2-lang.c (m2_language_defn): Adjust comments to refer to
1624 la_get_symbol_name_matcher.
1625 * minsyms.c: Include <algorithm>.
1626 (add_minsym_to_demangled_hash_table): Remove table parameter and
1627 add objfile parameter. Use search_name_hash, and add language to
1628 demangled languages vector.
1629 (struct found_minimal_symbols): New struct.
1630 (lookup_minimal_symbol_mangled, lookup_minimal_symbol_demangled):
1631 New functions.
1632 (lookup_minimal_symbol): Adjust to use them. Don't canonicalize
1633 input names here. Use lookup_name_info instead. Lookup up
1634 demangled names once for each language in the demangled names
1635 vector.
1636 (iterate_over_minimal_symbols): Use lookup_name_info. Lookup up
1637 demangled names once for each language in the demangled names
1638 vector.
1639 (build_minimal_symbol_hash_tables): Adjust.
1640 * minsyms.h (iterate_over_minimal_symbols): Adjust to pass down a
1641 lookup_name_info.
1642 * objc-lang.c (objc_language_defn): Adjust comment to refer to
1643 la_get_symbol_name_matcher.
1644 * objfiles.h: Include <vector>.
1645 (objfile_per_bfd_storage) <demangled_hash_languages>: New field.
1646 * opencl-lang.c (opencl_language_defn): Adjust comment to refer to
1647 la_get_symbol_name_matcher.
1648 * p-lang.c (pascal_language_defn): Adjust comment to refer to
1649 la_get_symbol_name_matcher.
1650 * psymtab.c (psym_lookup_symbol): Use lookup_name_info.
1651 (match_partial_symbol): Use symbol_name_match_type,
1652 lookup_name_info and psymbol_name_matches.
1653 (lookup_partial_symbol): Use lookup_name_info.
1654 (map_block): Use symbol_name_match_type and lookup_name_info.
1655 (psym_map_matching_symbols): Use symbol_name_match_type.
1656 (psymbol_name_matches): New.
1657 (recursively_search_psymtabs): Use lookup_name_info and
1658 psymbol_name_matches. Rename 'kind' parameter to 'domain'.
1659 (psym_expand_symtabs_matching): Use lookup_name_info. Rename
1660 'kind' parameter to 'domain'.
1661 * rust-lang.c (rust_language_defn): Adjust comment to refer to
1662 la_get_symbol_name_matcher.
1663 * symfile-debug.c (debug_qf_map_matching_symbols)
1664 (debug_qf_map_matching_symbols): Use symbol_name_match_type.
1665 (debug_qf_expand_symtabs_matching): Use lookup_name_info.
1666 * symfile.c (expand_symtabs_matching): Use lookup_name_info.
1667 * symfile.h (quick_symbol_functions) <map_matching_symbols>:
1668 Adjust to use symbol_name_match_type.
1669 <expand_symtabs_matching>: Adjust to use lookup_name_info.
1670 (expand_symtabs_matching): Adjust to use lookup_name_info.
1671 * symmisc.c (maintenance_expand_symtabs): Use
1672 lookup_name_info::match_any ().
1673 * symtab.c (symbol_matches_search_name): New.
1674 (eq_symbol_entry): Adjust to use lookup_name_info and the
1675 language's matcher.
1676 (demangle_for_lookup_info::demangle_for_lookup_info): New.
1677 (lookup_name_info::match_any): New.
1678 (iterate_over_symbols, search_symbols): Use lookup_name_info.
1679 (compare_symbol_name): Add language, lookup_name_info and
1680 completion_match_result parameters, and use them.
1681 (completion_list_add_name): Make extern. Add language and
1682 lookup_name_info parameters. Use them.
1683 (completion_list_add_symbol, completion_list_add_msymbol)
1684 (completion_list_objc_symbol): Add lookup_name_info parameters and
1685 adjust. Pass down language.
1686 (completion_list_add_fields): Add lookup_name_info parameters and
1687 adjust. Pass down language.
1688 (add_symtab_completions): Add lookup_name_info parameters and
1689 adjust.
1690 (default_collect_symbol_completion_matches_break_on): Add
1691 name_match_type parameter, and use it. Use lookup_name_info.
1692 (default_collect_symbol_completion_matches)
1693 (collect_symbol_completion_matches): Add name_match_type
1694 parameter, and pass it down.
1695 (collect_symbol_completion_matches_type): Adjust.
1696 (collect_file_symbol_completion_matches): Add name_match_type
1697 parameter, and use lookup_name_info.
1698 * symtab.h: Include <string> and "common/gdb_optional.h".
1699 (enum class symbol_name_match_type): New.
1700 (class ada_lookup_name_info): New.
1701 (struct demangle_for_lookup_info): New.
1702 (class lookup_name_info): New.
1703 (symbol_name_matcher_ftype): New.
1704 (SYMBOL_MATCHES_SEARCH_NAME): Use symbol_matches_search_name.
1705 (symbol_matches_search_name): Declare.
1706 (MSYMBOL_MATCHES_SEARCH_NAME): Delete.
1707 (default_collect_symbol_completion_matches)
1708 (collect_symbol_completion_matches)
1709 (collect_file_symbol_completion_matches): Add name_match_type
1710 parameter.
1711 (iterate_over_symbols): Use lookup_name_info.
1712 (completion_list_add_name): Declare.
1713 * utils.c (enum class strncmp_iw_mode): Moved to utils.h.
1714 (strncmp_iw_with_mode): Now extern.
1715 * utils.h (enum class strncmp_iw_mode): Moved from utils.c.
1716 (strncmp_iw_with_mode): Declare.
1717
1718 2017-11-08 Keith Seitz <keiths@redhat.com>
1719 Pedro Alves <palves@redhat.com>
1720
1721 * ada-lang.c (ada_language_defn): Install
1722 default_search_name_hash.
1723 * buildsym.c (struct buildsym_compunit): <language>: New field.
1724 (finish_block_internal): Pass language when creating dictionaries.
1725 (start_buildsym_compunit, start_symtab): New language parameters.
1726 Use them.
1727 (restart_symtab): Pass down compilation unit's language.
1728 * buildsym.h (enum language): Forward declare.
1729 (start_symtab): New 'language' parameter.
1730 * c-lang.c (c_language_defn, cplus_language_defn)
1731 (asm_language_defn, minimal_language_defn): Install
1732 default_search_name_hash.
1733 * coffread.c (coff_start_symtab): Adjust.
1734 * d-lang.c (d_language_defn): Install default_search_name_hash.
1735 * dbxread.c (struct symloc): Add 'pst_language' field.
1736 (PST_LANGUAGE): Define.
1737 (start_psymtab, read_ofile_symtab): Use it.
1738 (process_one_symbol): New 'language' parameter. Pass it down.
1739 * dictionary.c (struct dictionary) <language>: New field.
1740 (DICT_LANGUAGE): Define.
1741 (dict_create_hashed, dict_create_hashed_expandable)
1742 (dict_create_linear, dict_create_linear_expandable): New parameter
1743 'language'. Set the dictionary's language.
1744 (iter_match_first_hashed): Adjust to rename.
1745 (insert_symbol_hashed): Assert we don't see mismatching
1746 languages. Adjust to rename.
1747 (dict_hash): Rename to ...
1748 (default_search_name_hash): ... this and make extern.
1749 * dictionary.h (struct language_defn): Forward declare.
1750 (dict_create_hashed): New parameter 'language'.
1751 * dwarf2read.c (dwarf2_start_symtab): Pass down language.
1752 * f-lang.c (f_language_defn): Install default_search_name_hash.
1753 * go-lang.c (go_language_defn): Install default_search_name_hash.
1754 * jit.c (finalize_symtab): Pass compunit's language to dictionary
1755 creation.
1756 * language.c (unknown_language_defn, auto_language_defn):
1757 * language.h (language_defn::la_search_name_hash): New field.
1758 (default_search_name_hash): Declare.
1759 * m2-lang.c (m2_language_defn): Install default_search_name_hash.
1760 * mdebugread.c (new_block): New parameter 'language'.
1761 * mdebugread.c (parse_symbol): Pass symbol language to block
1762 allocation.
1763 (psymtab_to_symtab_1): Pass down language.
1764 (new_symtab): Pass compunit's language to block allocation.
1765 * objc-lang.c (objc_language_defn): Install
1766 default_search_name_hash.
1767 * opencl-lang.c (opencl_language_defn):
1768 * p-lang.c (pascal_language_defn): Install
1769 default_search_name_hash.
1770 * rust-lang.c (rust_language_defn): Install
1771 default_search_name_hash.
1772 * stabsread.h (enum language): Forward declare.
1773 (process_one_symbol): Add 'language' parameter.
1774 * symtab.c (search_name_hash): New function.
1775 * symtab.h (search_name_hash): Declare.
1776 * xcoffread.c (read_xcoff_symtab): Pass language to start_symtab.
1777
1778 2017-11-08 Pedro Alves <palves@redhat.com>
1779
1780 * cp-name-parser.y (main): Don't initialize extra_chars.
1781
1782 2017-11-07 Tom Tromey <tom@tromey.com>
1783
1784 * event-top.h (command_handler): Constify.
1785 * record-full.c (cmd_record_full_start): Update.
1786 * thread.c (thread_apply_all_command): Update.
1787 * printcmd.c (eval_command): Update.
1788 * mi/mi-main.c (mi_execute_cli_command): Update.
1789 (mi_execute_async_cli_command): Update.
1790 * tui/tui-stack.c (tui_update_command): Update.
1791 * cli/cli-interp.c (safe_execute_command): Constify.
1792 * record.c (record_start): Update.
1793 (record_start, record_stop, cmd_record_start): Update.
1794 * record-btrace.c (cmd_record_btrace_bts_start): Update.
1795 (cmd_record_btrace_pt_start): Update.
1796 (cmd_record_btrace_start): Update.
1797 (cmd_record_btrace_start): Update.
1798 * reverse.c (exec_reverse_once): Update.
1799 * python/python.c (execute_gdb_command): Don't copy the command.
1800 * event-top.c (command_line_handler): Update.
1801 (command_handler): Constify.
1802 * defs.h (deprecated_call_command_hook): Constify.
1803 * cli/cli-script.h (execute_user_command): Constify.
1804 * cli/cli-script.c (execute_user_command): Constify.
1805 (execute_cmd_pre_hook, execute_cmd_post_hook): Constify.
1806 (enum command_control_type): Update.
1807 * main.c (catch_command_errors): Remove non-const overload.
1808 (catch_command_errors_ftype): Remove.
1809 * python/py-cmd.c (cmdpy_function): Constify.
1810 * guile/scm-cmd.c (cmdscm_function): Constify.
1811 * cli/cli-dump.c (call_dump_func): Constify.
1812 * cli/cli-decode.c (do_const_cfunc): Constify.
1813 (do_sfunc): Constify.
1814 (cmd_func): Constify.
1815 * gdbcmd.h (execute_command, execute_command_to_string): Constify.
1816 * top.h (execute_command): Constify.
1817 * top.c (execute_command): Constify.
1818 (execute_command_to_string): Constify.
1819 (deprecated_call_command_hook): Constify.
1820 * command.h (cmd_func): Constify.
1821 * cli/cli-decode.h (struct cmd_list_element) <func>: Constify.
1822
1823 2017-11-07 Tom Tromey <tom@tromey.com>
1824
1825 * ada-lang.c (catch_ada_exception_command): Constify.
1826 (catch_assert_command): Constify.
1827 * break-catch-throw.c (catch_catch_command, catch_throw_command)
1828 (catch_rethrow_command): Constify.
1829 (catch_exception_command_1): Constify.
1830 * breakpoint.h (add_catch_command): Constify.
1831 * break-catch-syscall.c (catch_syscall_command_1): Constify.
1832 (catch_syscall_split_args): Constify.
1833 * break-catch-sig.c (catch_signal_command): Constify.
1834 (catch_signal_split_args): Constify.
1835 * cli/cli-decode.h (struct cmd_list_element) <function>: Use
1836 cmd_const_sfunc_ftype.
1837 * cli/cli-decode.c (add_setshow_cmd_full): Constify.
1838 (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
1839 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
1840 (add_setshow_string_cmd, struct cmd_list_element)
1841 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
1842 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
1843 (add_setshow_zuinteger_unlimited_cmd, add_setshow_zuinteger_cmd):
1844 Constify.
1845 (set_cmd_sfunc): Constify.
1846 (empty_sfunc): Constify.
1847 * command.h (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
1848 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
1849 (add_setshow_string_cmd, add_setshow_string_noescape_cmd)
1850 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
1851 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
1852 (add_setshow_zuinteger_cmd, add_setshow_zuinteger_unlimited_cmd):
1853 Constify.
1854 (set_cmd_sfunc): Constify.
1855 (cmd_sfunc_ftype): Remove.
1856 * compile/compile.c (set_compile_args): Constify.
1857 * infrun.c (set_disable_randomization): Constify.
1858 * infcmd.c (set_args_command, set_cwd_command): Constify.
1859 * breakpoint.c (set_condition_evaluation_mode): Constify.
1860 (add_catch_command): Constify.
1861 (catch_fork_command_1, catch_exec_command_1)
1862 (catch_load_command_1, catch_unload_command_1): Constify.
1863 (catch_load_or_unload): Constify.
1864 * guile/scm-param.c (pascm_set_func): Constify.
1865 (add_setshow_generic): Constify.
1866 * python/py-param.c (get_set_value): Constify.
1867 * top.h (set_verbose): Constify.
1868 * tui/tui-win.c (tui_set_var_cmd): Constify.
1869 * mi/mi-main.c (set_mi_async_command): Constify.
1870 * cli/cli-logging.c (set_logging_overwrite)
1871 (set_logging_redirect): Constify.
1872 * value.c (set_max_value_size): Constify.
1873 * valprint.c (set_input_radix, set_output_radix): Constify.
1874 * utils.c (set_width_command, set_height_command): Constify.
1875 * typeprint.c (set_print_type_methods, set_print_type_typedefs): Constify.
1876 * tracepoint.c (set_disconnected_tracing)
1877 (set_circular_trace_buffer, set_trace_buffer_size)
1878 (set_trace_user, set_trace_notes, set_trace_stop_notes): Constify.
1879 * top.c (set_history_size_command, set_verbose, set_editing)
1880 (set_gdb_datadir, set_history_filename): Constify.
1881 * target.c (set_targetdebug, maint_set_target_async_command)
1882 (maint_set_target_non_stop_command, set_target_permissions)
1883 (set_write_memory_permission): Constify.
1884 (open_target): Constify.
1885 * target-descriptions.c (set_tdesc_filename_cmd): Constify.
1886 * target-dcache.c (set_stack_cache, set_code_cache): Constify.
1887 * symtab.c (set_symbol_cache_size_handler): Constify.
1888 * symfile.c (set_ext_lang_command): Constify.
1889 * symfile-debug.c (set_debug_symfile): Constify.
1890 * source.c (set_directories_command): Constify.
1891 * solib.c (reload_shared_libraries, gdb_sysroot_changed): Constify.
1892 * serial.c (set_parity): Constify.
1893 * rs6000-tdep.c (powerpc_set_soft_float, powerpc_set_vector_abi): Constify.
1894 * remote.c (set_remote_exec_file, set_remotebreak)
1895 (set_remote_protocol_Z_packet_cmd, set_range_stepping): Constify.
1896 * record.c (set_record_insn_history_size)
1897 (set_record_call_history_size): Constify.
1898 * record-full.c (set_record_full_insn_max_num): Constify.
1899 * proc-api.c (set_procfs_trace_cmd, set_procfs_file_cmd): Constify.
1900 * osabi.c (set_osabi): Constify.
1901 * mips-tdep.c (set_mips64_transfers_32bit_regs)
1902 (reinit_frame_cache_sfunc, mips_abi_update): Constify.
1903 * maint.c (maintenance_set_profile_cmd): Constify.
1904 * linux-thread-db.c (set_libthread_db_search_path): Constify.
1905 * language.c (set_language_command, set_range_command)
1906 (set_case_command): Constify.
1907 * infrun.c (set_non_stop, set_observer_mode)
1908 (set_stop_on_solib_events, set_schedlock_func)
1909 (set_exec_direction_func): Constify.
1910 * infcmd.c (set_inferior_tty_command): Constify.
1911 * disasm.c (set_disassembler_options_sfunc): Constify.
1912 * demangle.c (set_demangling_command): Constify.
1913 * dcache.c (set_dcache_size, set_dcache_line_size): Constify.
1914 * cris-tdep.c (set_cris_version, set_cris_mode)
1915 (set_cris_dwarf2_cfi): Constify.
1916 * corefile.c (set_gnutarget_command): Constify.
1917 * charset.c (set_host_charset_sfunc, set_target_charset_sfunc)
1918 (set_target_wide_charset_sfunc): Constify.
1919 * breakpoint.c (update_dprintf_commands): Constify.
1920 * auto-load.c (set_auto_load_dir, set_auto_load_safe_path): Constify.
1921 * arm-tdep.c (set_fp_model_sfunc, arm_set_abi)
1922 (set_disassembly_style_sfunc): Constify.
1923 * arch-utils.c (set_endian, set_architecture): Constify.
1924 * alpha-tdep.c (reinit_frame_cache_sfunc): Constify.
1925 * agent.c (set_can_use_agent): Constify.
1926
1927 2017-11-07 Tom Tromey <tom@tromey.com>
1928
1929 * go32-nat.c (go32_sysinfo, go32_sldt, go32_sgdt, go32_sidt)
1930 (go32_pde, go32_pte, go32_pte_for_address): Constify.
1931 * gnu-nat.c (_parse_bool_arg, show_thread_default_pause_cmd)
1932 (set_thread_default_pause_cmd, set_thread_default_run_cmd)
1933 (show_thread_default_run_cmd, set_thread_default_detach_sc_cmd)
1934 (parse_int_arg, show_thread_default_detach_sc_cmd)
1935 (set_signals_cmd, show_signals_cmd, set_sig_thread_cmd)
1936 (show_sig_thread_cmd, set_stopped_cmd, show_stopped_cmd)
1937 (set_exceptions_cmd, show_exceptions_cmd, set_task_pause_cmd)
1938 (show_task_pause_cmd, set_task_detach_sc_cmd)
1939 (show_task_detach_sc_cmd, set_task_exc_port_cmd)
1940 (set_noninvasive_cmd, set_thread_pause_cmd)
1941 (show_thread_pause_cmd, set_thread_run_cmd, show_thread_run_cmd)
1942 (set_thread_detach_sc_cmd, show_thread_detach_sc_cmd)
1943 (set_thread_exc_port_cmd, thread_takeover_sc_cmd): Constify.
1944 * windows-nat.c (display_selectors): Constify.
1945 * cli/cli-decode.h (struct cmd_list_element) <function>: Remove
1946 non-const "cfunc".
1947 * cli/cli-decode.c (set_cmd_cfunc): Remove non-const overload.
1948 (cmd_cfunc_eq): Likewise.
1949 (struct cmd_list_element): Likewise.
1950 (do_cfunc): Remove.
1951 (cli_user_command_p): Update.
1952 * command.h (add_cmd): Remove non-const overload.
1953 (cmd_cfunc_ftype): Remove typedef.
1954 (cmd_cfunc_eq): Remove non-const overload.
1955 * value.c (show_values): Constify.
1956 * thread.c (thread_apply_all_command): Constify.
1957 * symfile.c (load_command): Constify.
1958 * source.c (directory_command): Constify.
1959 * maint.c (maintenance_internal_error)
1960 (maintenance_demangler_warning, maintenance_space_display)
1961 (maintenance_print_architecture, maintenance_translate_address)
1962 (maintenance_info_selftests, maintenance_internal_warning):
1963 Constify.
1964 * breakpoint.c (disable_trace_command, enable_trace_command):
1965 Constify.
1966 * auto-load.c (info_auto_load_local_gdbinit, add_auto_load_dir):
1967 Constify.
1968 (add_auto_load_safe_path): Constify.
1969 * guile/scm-auto-load.c (info_auto_load_guile_scripts): Constify.
1970 * top.h (show_commands): Constify.
1971 * linux-thread-db.c (info_auto_load_libthread_db): Constify.
1972 * sparc64-tdep.c (adi_examine_command): Constify.
1973 (adi_assign_command): Constify.
1974
1975 2017-11-07 Tom Tromey <tom@tromey.com>
1976
1977 * frame.h (info_locals_command, info_args_command): Constify.
1978 * auto-load.h (auto_load_info_scripts): Constify.
1979 * inferior.h (registers_info): Constify.
1980 * copying.c: Rebuild.
1981 * copying.awk: Constify generated commands.
1982 * auto-load.c (auto_load_info_scripts)
1983 (info_auto_load_gdb_scripts): Constify.
1984 * cli/cli-decode.c (struct cmd_list_element): Take a
1985 cmd_const_cfunc_ftype.
1986 * command.h (add_info): Take a cmd_const_cfunc_ftype.
1987 * tui/tui-win.c (tui_all_windows_info): Constify.
1988 * python/py-auto-load.c (info_auto_load_python_scripts):
1989 Constify.
1990 * cli/cli-cmds.c (show_command): Remove non-const overload.
1991 * tracepoint.c (info_tvariables_command, info_scope_command):
1992 Constify.
1993 (info_static_tracepoint_markers_command): Constify.
1994 * thread.c (info_threads_command): Constify.
1995 (print_thread_info_1): Constify.
1996 * target.c (info_target_command): Constify.
1997 * symtab.c (info_sources_command, info_functions_command)
1998 (info_types_command): Constify.
1999 (info_variables_command): Remove non-const overload.
2000 * symfile.c (info_ext_lang_command): Constify.
2001 * stack.c (info_frame_command, info_locals_command)
2002 (info_args_command): Constify.
2003 (backtrace_command): Remove non-const overload.
2004 * source.c (info_source_command, info_line_command): Constify.
2005 * solib.c (info_sharedlibrary_command): Constify.
2006 * skip.c (info_skip_command): Constify.
2007 * ser-go32.c (info_serial_command): Constify.
2008 * reverse.c (info_bookmarks_command): Constify.
2009 * printcmd.c (info_symbol_command, info_address_command)
2010 (info_display_command): Constify.
2011 * osdata.c (info_osdata_command): Constify.
2012 * objc-lang.c (info_selectors_command, info_classes_command):
2013 Constify.
2014 * nto-procfs.c (procfs_pidlist, procfs_meminfo): Constify.
2015 * memattr.c (info_mem_command): Constify.
2016 * macrocmd.c (info_macro_command, info_macros_command): Constify.
2017 * linux-fork.c (info_checkpoints_command): Constify.
2018 * infrun.c (info_signals_command): Constify.
2019 * inflow.c (info_terminal_command): Constify.
2020 * inferior.c (info_inferiors_command): Constify.
2021 (print_inferior): Constify.
2022 * infcmd.c (info_program_command, info_all_registers_command)
2023 (info_registers_command, info_vector_command)
2024 (info_float_command): Constify.
2025 (registers_info): Constify.
2026 * gnu-nat.c (info_send_rights_cmd, info_recv_rights_cmd)
2027 (info_port_sets_cmd, info_dead_names_cmd, info_port_rights_cmd):
2028 Constify.
2029 * f-valprint.c (info_common_command): Constify.
2030 * dcache.c (info_dcache_command): Constify.
2031 (dcache_info_1): Constify.
2032 * darwin-nat-info.c (info_mach_tasks_command)
2033 (info_mach_task_command, info_mach_ports_command)
2034 (info_mach_port_command, info_mach_threads_command)
2035 (info_mach_thread_command, info_mach_regions_command)
2036 (info_mach_regions_recurse_command, info_mach_region_command)
2037 (info_mach_exceptions_command): Constify.
2038 (get_task_from_args): Constify.
2039 * cp-support.c (info_vtbl_command): Constify.
2040 * breakpoint.c (info_watchpoints_command)
2041 (info_tracepoints_command): Constify.
2042 (info_breakpoints_command): Remove non-const overload.
2043 * avr-tdep.c (avr_io_reg_read_command): Constify.
2044 * auxv.c (info_auxv_command): Constify.
2045 * ada-tasks.c (info_tasks_command): Constify.
2046 (info_task): Constify.
2047 * ada-lang.c (info_exceptions_command): Constify.
2048
2049 2017-11-07 Tom Tromey <tom@tromey.com>
2050
2051 * solib.h (no_shared_libraries): Constify.
2052 * frame.h (return_command): Constify.
2053 * cli/cli-cmds.h (quit_command): Constify.
2054 * top.h (quit_command, execute_command): Constify.
2055 * target.h (flash_erase_command): Constify.
2056 * inferior.h (set_inferior_args, attach_command): Constify.
2057 * tracepoint.h (start_tracing, stop_tracing): Constify.
2058 * breakpoint.h (break_command, tbreak_command)
2059 (hbreak_command_wrapper, thbreak_command_wrapper)
2060 (rbreak_command_wrapper, watch_command_wrapper)
2061 (awatch_command_wrapper, rwatch_command_wrapper)
2062 (get_tracepoint_by_number): Constify.
2063 * symtab.c (info_variables_command, rbreak_command)
2064 (symtab_symbol_info): Constify.
2065 (info_variables_command): Add non-const overload.
2066 * top.c (dont_repeat_command): Constify.
2067 * breakpoint.c (ignore_command, commands_command)
2068 (condition_command, tbreak_command, hbreak_command)
2069 (thbreak_command, clear_command, break_command)
2070 (info_breakpoints_command, watch_command, rwatch_command)
2071 (awatch_command, trace_command, ftrace_command, strace_command)
2072 (trace_pass_command, break_range_command, dprintf_command)
2073 (agent_printf_command, get_tracepoint_by_number)
2074 (watch_maybe_just_location, trace_pass_command): Constify.
2075 (info_breakpoints_command): Add non-const overload.
2076 * tracefile.c (tsave_command): Constify.
2077 * infcmd.c (attach_command, disconnect_command, signal_command)
2078 (queue_signal_command, stepi_command, nexti_command)
2079 (finish_command, next_command, step_command, until_command)
2080 (advance_command, jump_command, continue_command, run_command)
2081 (start_command, starti_command, interrupt_command)
2082 (run_command_1, set_inferior_args, step_1): Constify.
2083 * inferior.c (add_inferior_command, remove_inferior_command)
2084 (clone_inferior_command): Constify.
2085 * linux-fork.c (checkpoint_command, restart_command): Constify.
2086 * windows-nat.c (signal_event_command): Constify.
2087 * guile/guile.c (guile_repl_command, guile_command): Constify.
2088 * printcmd.c (x_command, display_command, printf_command)
2089 (output_command, set_command, call_command, print_command)
2090 (eval_command): Constify.
2091 (non_const_set_command): Remove.
2092 (_initialize_printcmd): Update.
2093 * source.c (forward_search_command, reverse_search_command):
2094 Constify.
2095 * jit.c (jit_reader_load_command, jit_reader_unload_command):
2096 Constify.
2097 * infrun.c (handle_command): Constify.
2098 * memattr.c (mem_command): Constify.
2099 * stack.c (return_command, up_command, up_silently_command)
2100 (down_command, down_silently_command, frame_command)
2101 (backtrace_command, func_command, backtrace_command_1): Constify.
2102 (backtrace_command): Add non-const overload.
2103 * remote-sim.c (simulator_command): Constify.
2104 * exec.c (set_section_command): Constify.
2105 * tracepoint.c (tdump_command, trace_variable_command)
2106 (tstatus_command, tstop_command, tstart_command)
2107 (end_actions_pseudocommand, while_stepping_pseudocommand)
2108 (collect_pseudocommand, teval_pseudocommand, actions_command)
2109 (start_tracing, stop_tracing): Constify.
2110 * value.c (init_if_undefined_command): Constify.
2111 * tui/tui-stack.c (tui_update_command): Constify.
2112 * tui/tui-win.c (tui_refresh_all_command)
2113 (tui_set_tab_width_command, tui_set_win_height_command)
2114 (tui_set_focus_command, tui_scroll_forward_command)
2115 (tui_scroll_backward_command, tui_scroll_left_command)
2116 (tui_scroll_right_command, parse_scrolling_args, tui_set_focus)
2117 (tui_set_win_height): Constify.
2118 * tui/tui-layout.c (tui_layout_command): Constify.
2119 * procfs.c (proc_trace_syscalls, proc_trace_sysentry_cmd)
2120 (proc_trace_sysexit_cmd, proc_untrace_sysentry_cmd)
2121 (proc_untrace_sysexit_cmd): Constify.
2122 * remote.c (threadlist_test_cmd, threadinfo_test_cmd)
2123 (threadset_test_cmd, threadlist_update_test_cmd)
2124 (threadalive_test): Constify.
2125 * objc-lang.c (print_object_command): Constify.
2126 * command.h (add_com): Constify.
2127 * cli/cli-dump.c (restore_command): Constify.
2128 * cli/cli-cmds.c (pwd_command, echo_command, quit_command)
2129 (help_command, complete_command, shell_command, edit_command)
2130 (list_command, disassemble_command, make_command)
2131 (apropos_command, alias_command): Constify.
2132 * cli/cli-script.c (document_command, define_command)
2133 (while_command, if_command, validate_comname): Constify.
2134 * cli/cli-decode.c (struct cmd_list_element): Change type of
2135 "fun".
2136 * target.c (do_monitor_command, flash_erase_command): Constify.
2137 * regcache.c (reg_flush_command): Constify.
2138 * reverse.c (reverse_step, reverse_next, reverse_stepi)
2139 (reverse_nexti, reverse_continue, reverse_finish)
2140 (save_bookmark_command, goto_bookmark_command)
2141 (exec_reverse_once): Constify.
2142 * python/python.c (python_interactive_command, python_command):
2143 Constify.
2144 * typeprint.c (ptype_command, whatis_command, whatis_exp):
2145 Constify.
2146 * solib.c (sharedlibrary_command, no_shared_libraries): Constify.
2147 * gcore.c (gcore_command): Constify.
2148
2149 2017-11-07 Tom Tromey <tom@tromey.com>
2150
2151 * printcmd.c (x_command): Call set_repeat_arguments.
2152 * cli/cli-cmds.c (list_command): Call set_repeat_arguments.
2153 * top.c (repeat_arguments): New global.
2154 (set_repeat_arguments): New function.
2155 (execute_command): Handle repeat_arguments.
2156 (show_commands): Calls set_repeat_arguments.
2157 * command.h (set_repeat_arguments): Declare.
2158
2159 2017-11-07 Tom Tromey <tom@tromey.com>
2160
2161 * stack.c (backtrace_command): Use std::string.
2162 (backtrace_command_1): Make "count_exp" const.
2163
2164 2017-11-07 Tom Tromey <tom@tromey.com>
2165
2166 * source.c (directory_switch, mod_path, add_path): Constify.
2167 * defs.h (add_path, mod_path, directory_switch): Constify.
2168 * mi/mi-cmd-env.c (env_mod_path): Constify.
2169
2170 2017-11-07 Tom Tromey <tom@tromey.com>
2171
2172 * infcmd.c (strip_bg_char): Return gdb::unique_xmalloc_ptr.
2173 (run_command_1, continue_command, step_1, jump_command)
2174 (signal_command, until_command, advance_command, finish_command)
2175 (attach_command): Update.
2176
2177 2017-11-07 Tom Tromey <tom@tromey.com>
2178
2179 * command.h (set_cmd_cfunc): Don't declare.
2180 * cli/cli-decode.c (set_cmd_cfunc): Now static.
2181
2182 2017-11-07 Tom Tromey <tom@tromey.com>
2183
2184 * stack.c (select_frame_command): Constify.
2185 * cli/cli-decode.c (add_com_suppress_notification): Constify.
2186 * command.h (add_com_suppress_notification): Constify.
2187
2188 2017-11-07 Tom Tromey <tom@tromey.com>
2189
2190 * breakpoint.c (stop_command): Constify.
2191 * cli/cli-decode.c (struct cmd_list_element): Constify.
2192 * command.h (add_abbrev_prefix_cmd): Constify.
2193
2194 2017-11-07 Pedro Alves <palves@redhat.com>
2195
2196 * breakpoint.c (extract_bp_kind): New enum.
2197 (extract_bp_num, extract_bp_or_bp_range): New functions, partially
2198 factored out from ...
2199 (extract_bp_number_and_location): ... here.
2200 * cli/cli-utils.c (get_number_trailer): Handle '-$variable'.
2201
2202 2017-11-07 Pedro Alves <palves@redhat.com>
2203
2204 * breakpoint.c (extract_bp_number_and_location): Change return
2205 type to void. Throw error instead of warning.
2206 (enable_disable_command): Adjust.
2207
2208 2017-11-07 Xavier Roirand <roirand@adacore.com>
2209 Pedro Alves <palves@redhat.com>
2210
2211 * breakpoint.c (map_breakpoint_number_range): New, factored out
2212 from ...
2213 (map_breakpoint_numbers): ... here.
2214 (find_location_by_number): Change parameters from string to
2215 breakpoint number and location.
2216 (extract_bp_number_and_location): New function.
2217 (enable_disable_bp_num_loc)
2218 (enable_disable_breakpoint_location_range)
2219 (enable_disable_command): New functions, factored out ...
2220 (enable_command, disable_command): ... these functions, and
2221 adjusted to support ranges.
2222 * NEWS: Document enable/disable breakpoint location range feature.
2223
2224 2017-11-06 Luis Machado <luis.machado@linaro.org>
2225
2226 * MAINTAINERS (Write After Approval): Update my e-mail address.
2227
2228 2017-11-06 Pedro Alves <palves@redhat.com>
2229
2230 * gnu-nat.c (gnu_terminal_init): Delete.
2231 (gnu_target): Don't install gnu_terminal_init.
2232 * inflow.c (child_terminal_init_with_pgrp): Delete, merged with ...
2233 (child_terminal_init): ... this function.
2234
2235 2017-11-06 Pedro Alves <palves@redhat.com>
2236
2237 * common/common.m4 (GDB_AC_COMMON): No longer check termio.h nor
2238 sgtty.h.
2239 * config.in, configure: Regenerate.
2240
2241 2017-11-06 Pedro Alves <palves@redhat.com>
2242
2243 * event-top.c: Check SIGTSTP instead of STOP_SIGNAL thoughout.
2244 (async_init_signals): Adjust.
2245 (handle_stop_sig): Rename to ...
2246 (handle_sigtstp): ... this.
2247 (async_stop_sig): Rename to ...
2248 (async_sigtstp_handler): ... this, and delete STOP_SIGNAL !=
2249 SIGTSTP path.
2250 * event-top.h: Move signal.h include to the top. Check SIGTSTP
2251 instead of STOP_SIGNAL thoughout.
2252 (handle_stop_sig): Rename to ...
2253 (handle_sigtstp): ... this.
2254 * top.c (command_line_input): Replace STOP_SIGNAL -> SIGTSTP.
2255
2256 2017-11-06 Pedro Alves <palves@redhat.com>
2257
2258 * inflow.c (child_terminal_inferior, child_terminal_ours_1): No
2259 longer set flags twice in row.
2260
2261 2017-11-06 Pedro Alves <palves@redhat.com>
2262
2263 * Makefile.in (SER_HARDWIRE): Update comment.
2264 (HFILES_NO_SRCDIR): Remove gdb_termios.h.
2265 * common/gdb_termios.h: Delete file.
2266 * common/job-control.c: Include termios.h and unistd.h instead of
2267 gdb_termios.h.
2268 (gdb_setpgid): Remove HAVE_TERMIOS || TIOCGPGRP preprocessor
2269 check.
2270 (have_job_control): Check HAVE_TERMIOS_H instead of HAVE_TERMIOS.
2271 Remove sgtty code.
2272 * configure.ac: No longer check for termio.h and sgtty.h.
2273 * configure: Regenerate.
2274 * inflow.c: Include termios.h instead of gdb_termios.h. Replace
2275 PROCESS_GROUP_TYPE checks with HAVE_TERMIOS_H checks throughout.
2276 Replace PROCESS_GROUP_TYPE references with pid_t references
2277 throughout.
2278 (gdb_getpgrp): Delete.
2279 (set_initial_gdb_ttystate): Use tcgetpgrp instead of gdb_getpgrp.
2280 (child_terminal_inferior): Remove comment. Remove sgtty code.
2281 (child_terminal_ours_1): Use tcgetpgrp directly instead of
2282 gdb_getpgrp. Use serial_set_tty_state instead aof
2283 serial_noflush_set_tty_state. Remove sgtty code.
2284 * inflow.h: Include unistd.h instead of gdb_termios.h. Replace
2285 PROCESS_GROUP_TYPE check with HAVE_TERMIOS_H check.
2286 (inferior_process_group): Now returns pid_t.
2287 * ser-base.c (ser_base_noflush_set_tty_state): Delete.
2288 * ser-base.h (ser_base_noflush_set_tty_state): Delete.
2289 * ser-event.c (serial_event_ops): Update.
2290 * ser-go32.c (dos_noflush_set_tty_state): Delete.
2291 (dos_ops): Update.
2292 * ser-mingw.c (hardwire_ops, tty_ops, pipe_ops, tcp_ops): Update.
2293 * ser-pipe.c (pipe_ops): Update.
2294 * ser-tcp.c (tcp_ops): Update.
2295 * ser-unix.c: Include termios.h instead of gdb_termios.h. Remove
2296 HAVE_TERMIOS checks.
2297 [HAVE_TERMIO] (struct hardwire_ttystate): Delete.
2298 [HAVE_SGTTY] (struct hardwire_ttystate): Delete.
2299 (get_tty_state, set_tty_state): Drop termio and sgtty code, and
2300 assume termios.
2301 (hardwire_noflush_set_tty_state): Delete.
2302 (hardwire_print_tty_state, hardwire_drain_output)
2303 (hardwire_flush_output, hardwire_flush_input)
2304 (hardwire_send_break, hardwire_raw, hardwire_setbaudrate)
2305 (hardwire_setstopbits, hardwire_setparity): Drop termio and sgtty
2306 code, and assume termios.
2307 (hardwire_ops): Update.
2308 (_initialize_ser_hardwire): Remove HAVE_TERMIOS check.
2309 * serial.c (serial_noflush_set_tty_state): Delete.
2310 * serial.h (serial_noflush_set_tty_state): Delete.
2311 (serial_ops::noflush_set_tty_state): Delete.
2312
2313 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2314
2315 * Makefile.in (SFILES): Remove doublest.c and dfp.c.
2316 (HFILES_NO_SRCDIR): Remove doublest.h and dfp.h.
2317 (COMMON_OBS): Remove doublest.o and dfp.o.
2318 Do not build target-float.c (instead of doublest.c)
2319 with -Wformat-nonliteral.
2320
2321 * doublest.c: Remove file.
2322 * doublest.h: Remove file.
2323 * dfp.c: Remove file.
2324 * dfp.h: Remove file.
2325
2326 * target-float.c: Do not include "doublest.h" and "dfp.h".
2327 (DOUBLEST): Move here from doublest.h.
2328 (enum float_kind): Likewise.
2329 (FLOATFORMAT_CHAR_BIT): Likewise.
2330 (FLOATFORMAT_LARGEST_BYTES): Likewise.
2331 (floatformat_totalsize_bytes): Move here from doublest.c. Make static.
2332 (floatformat_precision): Likewise.
2333 (floatformat_normalize_byteorder, get_field, put_field): Likewise.
2334 (floatformat_is_negative, floatformat_classify, floatformat_mantissa):
2335 Likewise.
2336 (host_float_format, host_double_format, host_long_double_format):
2337 Likewise.
2338 (floatformat_to_string, floatformat_from_string): Likewise.
2339 (floatformat_to_doublest): Likewise. Also, inline the original
2340 convert_floatformat_to_doublest.
2341 (floatformat_from_doublest): Likewise. Also, inline the original
2342 convert_floatformat_from_doublest.
2343
2344 Include "dpd/decimal128.h", "dpd/decimal64.h", and "dpd/decimal32.h".
2345 (MAX_DECIMAL_STRING): Move here from dfp.c.
2346 (match_endianness): Likewise.
2347 (set_decnumber_context, decimal_check_errors): Likewise.
2348 (decimal_from_number, decimal_to_number): Likewise.
2349 (decimal_to_string, decimal_from_string): Likewise. Make static.
2350 (decimal_from_longest, decimal_from_ulongest): Likewise.
2351 (decimal_to_longest): Likewise.
2352 (decimal_binop, decimal_is_zero, decimal_compare): Likewise.
2353 (decimal_convert): Likewise.
2354
2355 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2356
2357 * doublest.c: Do not include "gdbtypes.h".
2358 (extract_typed_floating): Remove.
2359 (store_typed_floating): Remove.
2360 (convert_typed_floating): Remove.
2361 * doublest.h (struct type): Remove.
2362 (DOUBLEST_PRINT_FORMAT): Remove.
2363 (DOUBLEST_SCAN_FORMAT): Remove.
2364 (extract_typed_floating): Remove.
2365 (store_typed_floating): Remove.
2366 (convert_typed_floating): Remove.
2367
2368 * dfp.c (decimal_from_doublest): Remove.
2369 (decimal_to_doublest): Remove.
2370 * dfp.h: Do not include "doublest.h".
2371 (decimal_from_doublest): Remove.
2372 (decimal_to_doublest): Remove.
2373
2374 * value.c: Do not include "doublest.h" and "dfp.h".
2375 (value_as_double): Remove.
2376 (unpack_double): Remove.
2377 (value_from_double): Remove.
2378 (value_from_decfloat): Remove.
2379 * value.h: Do not include "doublest.h".
2380 (value_as_double): Remove.
2381 (unpack_double): Remove.
2382 (value_from_double): Remove.
2383 (value_from_decfloat): Remove.
2384
2385 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2386
2387 * i386-tdep.c: Include "target-float.h". Do not include "doublest.h".
2388 (i386_extract_return_value): Use target_float_convert.
2389 (i386_store_return_value): Likewise.
2390 * i387-tdep.c (i387_register_to_value): Use target_float_convert.
2391 (i387_value_to_register): Likewise.
2392 * ia64-tdep.c: Include "target-float.h". Do not include "doublest.h".
2393 (ia64_register_to_value): Use target_float_convert.
2394 (ia64_value_to_register): Likewise.
2395 (ia64_extract_return_value): Likewise.
2396 (ia64_store_return_value): Likewise.
2397 (ia64_push_dummy_call): Likewise.
2398 * m68k-tdep.c: Include "target-float.h".
2399 (m68k_register_to_value): Use target_float_convert.
2400 (m68k_value_to_register): Likewise.
2401 (m68k_svr4_extract_return_value): Likewise.
2402 (m68k_svr4_store_return_value): Likewise.
2403 * ppc-sysv-tdep.c: Include "target-float.h".
2404 (ppc_sysv_abi_push_dummy_call): Use target_float_convert.
2405 (do_ppc_sysv_return_value): Likewise.
2406 (ppc64_sysv_abi_push_freg): Likewise.
2407 (ppc64_sysv_abi_return_value_base): Likewise.
2408 * rs6000-aix-tdep.c: Include "target-float.h".
2409 (rs6000_push_dummy_call): Use target_float_convert.
2410 (rs6000_return_value): Likewise.
2411 * rs6000-lynx178-tdep.c: Include "target-float.h".
2412 (rs6000_lynx178_push_dummy_call): Use target_float_convert.
2413 (rs6000_lynx178_return_value): Likewise.
2414 * rs6000-tdep.c: Include "target-float.h". Do not include "doublest.h".
2415 (rs6000_register_to_value): Use target_float_convert.
2416 (rs6000_value_to_register): Likewise.
2417 * arm-tdep.c: Include "target-float.h". Do not include "doublest.h".
2418 (arm_extract_return_value): Use target_float_convert.
2419 (arm_store_return_value): Likewise.
2420 * sh-tdep.c: Include "target-float.h". Do not include "doublest.h".
2421 (sh_register_convert_to_virtual): Use target_float_convert.
2422 (sh_register_convert_to_raw): Likewise.
2423 * sh64-tdep.c: Include "target-float.h".
2424 (sh64_extract_return_value): Use target_float_convert.
2425 (sh64_register_convert_to_virtual): Likewise.
2426 (sh64_register_convert_to_raw): Likewise. Fix argument types.
2427
2428 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2429
2430 * target-float.c (floatformat_to_host_double): New function.
2431 (floatformat_from_host_double): Likewise.
2432 (target_float_to_host_double): Likewise.
2433 (target_float_from_host_double): Likewise.
2434 * target-float.h (target_float_to_host_double): Add prototype.
2435 (target_float_from_host_double): Likewise.
2436
2437 * guile/scm-value.c: Include "target-float.h".
2438 (gdbscm_value_to_real): Use target_float_to_host_double.
2439 Handle integer source values via value_as_long.
2440 * guile/scm-math.c: Include "target-float.h". Do not include
2441 "doublest.h", "dfp.h", and "expression.h".
2442 (vlscm_convert_typed_number): Use target_float_from_host_double.
2443 (vlscm_convert_number): Likewise.
2444
2445 * python/py-value.c (valpy_float): Use target_float_to_host_double.
2446 (convert_value_from_python): Use target_float_from_host_double.
2447
2448 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2449
2450 * ada-lang.c (cast_to_fixed): Reimplement in target arithmetic.
2451 (cast_from_fixed): Likewise.
2452 (ada_scaling_type): New function.
2453 (ada_delta): Return value instead of DOUBLEST. Perform target
2454 arithmetic instead of host arithmetic.
2455 (scaling_factor): Rename to ...
2456 (ada_scaling_factor) ... this. Make non-static. Return value instead
2457 of DOUBLEST. Perform target arithmetic instead of host arithmetic.
2458 (ada_fixed_to_float): Remove.
2459 (ada_float_to_fixed): Remove.
2460 * ada-lang.h (ada_fixed_to_float): Remove.
2461 (ada_float_to_fixed): Remove.
2462 (ada_delta): Return value instead of DOUBLEST.
2463 (ada_scaling_factor): Add prototype.
2464
2465 * ada-typeprint.c: Include "target-float.h".
2466 (print_fixed_point_type): Perform target arithmetic instead of
2467 host arithmetic.
2468 * ada-valprint.c: Include "target-float.h".
2469 (ada_val_print_num): Perform target arithmetic instead of
2470 host arithmetic for fixed-point types.
2471
2472 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2473
2474 * target-float.c: Include <math.h>.
2475 (floatformat_binop): New function.
2476 (floatformat_compare): Likewise.
2477 (target_float_binop): Likewise.
2478 (target_float_compare): Likewise.
2479 * target-float.h: Include "expression.h".
2480 (target_float_binop): Add prototype.
2481 (target_float_compare): Likewise.
2482
2483 * valarith.c: Do not include "doublest.h" and "dfp.h".
2484 Include "common/byte-vector.h".
2485 (value_args_as_decimal): Remove, replace by ...
2486 (value_args_as_target_float): ... this function. Handle both
2487 binary and decimal target floating-point formats.
2488 (scalar_binop): Handle both binary and decimal FP using
2489 value_args_as_target_float and target_float_binop.
2490 (value_equal): Handle both binary and decimal FP using
2491 value_args_as_target_float and target_float_compare.
2492 (value_less): Likewise.
2493 (value_pos): Handle all scalar types as simple copy.
2494 (value_neg): Handle all scalar types via BINOP_SUB from 0.
2495 * dfp.c (decimal_binop): Throw error instead of internal_error
2496 when called with an unsupported operation code.
2497
2498 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2499
2500 * target-float.c (target_float_to_string): New function.
2501 (target_float_from_string): New function.
2502 * target-float.h (target_float_to_string): Add prototype.
2503 (target_float_from_string): Add prototype.
2504
2505 * valprint.c: Include "target-float.h". Do not include
2506 "doublest.h" and "dfp.h".
2507 (print_floating): Use target_float_to_string.
2508 * printcmd.c: Include "target-float.h". Do not include "dfp.h".
2509 (printf_floating): Use target_float_to_string.
2510 * i387-tdep.c: Include "target-float.h". Do not include "doublest.h".
2511 (print_i387_value): Use target_float_to_string.
2512 * mips-tdep.c: Include "target-float.h".
2513 (mips_print_fp_register): Use target_float_to_string.
2514 * sh64-tdep.c: Include "target-float.h".
2515 (sh64_do_fp_register): Use target_float_to_string.
2516
2517 * parse.c: Include "target-float.h". Do not include
2518 "doublest.h" and "dfp.h".
2519 (parse_float): Use target_float_from_string.
2520 * stabsread.c: Include "target-float.h". Do not include "doublest.h".
2521 (define_symbol): Use target_float_from_string.
2522 * gdbarch-selftests.c: Include "target-float.h".
2523 (register_to_value_test): Use target_float_from_string.
2524
2525 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2526
2527 * Makefile.c (SFILES): Add target-float.c.
2528 (HFILES_NO_SRCDIR): Add target-float.h.
2529 (COMMON_OBS): Add target-float.o.
2530 * target-float.h: New file.
2531 * target-float.c: New file.
2532
2533 * doublest.c (floatformat_classify): Fix detection of float_zero.
2534
2535 * gdbtypes.c (is_floating_type): New function.
2536 * gdbtypes.h (is_floating_type): Add prototype.
2537
2538 * value.c: Do not include "floatformat.h".
2539 (unpack_double): Use target_float_is_valid.
2540 (is_floating_value): New function.
2541 * value.h (is_floating_value): Add prototype-
2542
2543 * valarith.c: Include "target-float.h".
2544 (value_logical_not): Use target_float_is_zero.
2545
2546 * python/py-value.c: Include "target-float.h".
2547 (valpy_nonzero): Use target_float_is_zero.
2548
2549 2017-11-04 Tom Tromey <tom@tromey.com>
2550
2551 * h8300-tdep.c (h8300_push_dummy_call): Use std::vector.
2552
2553 2017-11-04 Tom Tromey <tom@tromey.com>
2554
2555 * breakpoint.c (set_momentary_breakpoint): Return
2556 breakpoint_up.
2557 (until_break_command): Update.
2558 (new_until_break_fsm): Change argument types to
2559 breakpoint_up.
2560 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
2561 (do_delete_breakpoint_cleanup, make_cleanup_delete_breakpoint):
2562 Remove.
2563 * infcmd.c (finish_forward): Update.
2564 * breakpoint.h (set_momentary_breakpoint)
2565 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
2566 (make_cleanup_delete_breakpoint): Remove.
2567 (struct breakpoint_deleter): New.
2568 (breakpoint_up): New typedef.
2569 * infrun.c (insert_step_resume_breakpoint_at_sal_1): Update.
2570 (insert_exception_resume_breakpoint): Update.
2571 (insert_exception_resume_from_probe): Update.
2572 (insert_longjmp_resume_breakpoint): Update.
2573 * arm-linux-tdep.c (arm_linux_copy_svc): Update.
2574 * elfread.c (elf_gnu_ifunc_resolver_stop): Update.
2575 * infcall.c (call_function_by_hand_dummy): Update
2576
2577 2017-11-04 Tom Tromey <tom@tromey.com>
2578
2579 * c-typeprint.c (c_type_print_base): Use gdb::unique_xmalloc_ptr.
2580
2581 2017-11-04 Tom Tromey <tom@tromey.com>
2582
2583 * linux-tdep.c (linux_core_info_proc_mappings): Use
2584 gdb::def_vector.
2585 (linux_get_siginfo_data): Return gdb::byte_vector. Remove
2586 "size" argument.
2587 (linux_corefile_thread): Update.
2588 (linux_make_corefile_notes): Remove unused variable.
2589
2590 2017-11-04 Tom Tromey <tom@tromey.com>
2591
2592 * ppc-linux-tdep.c (ppc_linux_get_syscall_number): Use
2593 gdb::byte_vector.
2594
2595 2017-11-04 Tom Tromey <tom@tromey.com>
2596
2597 * objfiles.c (do_free_objfile_cleanup): Remove.
2598 * compile/compile-object-load.c (compile_object_load): Update.
2599 * objfiles.h (make_cleanup_free_objfile): Remove.
2600
2601 2017-11-04 Tom Tromey <tom@tromey.com>
2602
2603 * sparc64-tdep.c (do_examine): Use gdb::def_vector.
2604 (adi_read_versions): Change "tags" to "gdb_byte *".
2605 (adi_print_versions): Likewise.
2606
2607 2017-11-04 Tom Tromey <tom@tromey.com>
2608
2609 * breakpoint.c
2610 (scoped_rbreak_breakpoints::scoped_rbreak_breakpoints): Rename
2611 from start_rbreak_breakpoints.
2612 (scoped_rbreak_breakpoints): Rename from end_rbreak_breakpoints.
2613 * breakpoint.h (class scoped_rbreak_breakpoints): New.
2614 (start_rbreak_breakpoints, end_rbreak_breakpoints): Remove.
2615 * symtab.c (do_end_rbreak_breakpoints): Remove.
2616 (rbreak_command): Use scoped_rbreak_breakpoints, std::string.
2617
2618 2017-11-04 Tom Tromey <tom@tromey.com>
2619
2620 * cp-namespace.c (reset_directive_searched): Remove.
2621 (cp_lookup_symbol_via_imports): Use scoped_restore.
2622 * cp-support.c (reset_directive_searched): Remove.
2623 (make_symbol_overload_list_using): Use scoped_restore.
2624 * d-namespace.c (d_lookup_symbol_imports): Use scoped_restore.
2625 (reset_directive_searched): Remove.
2626
2627 2017-11-04 Tom Tromey <tom@tromey.com>
2628
2629 * symfile.c (find_separate_debug_file_by_debuglink): Use
2630 unique_xmalloc_ptr.
2631
2632 2017-11-04 Tom Tromey <tom@tromey.com>
2633
2634 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
2635 type of "info".
2636 (compute_stack_depth): Likewise.
2637 (do_compile_dwarf_expr_to_c): Use std::vector.
2638
2639 2017-11-04 Tom Tromey <tom@tromey.com>
2640
2641 * compile/compile-object-load.c (link_callbacks_einfo): Use
2642 std::string.
2643
2644 2017-11-04 Tom Tromey <tom@tromey.com>
2645
2646 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
2647 Use scoped_free_pendings.
2648 * dbxread.c (dbx_symfile_read, dbx_psymtab_to_symtab_1): Use
2649 scoped_free_pendings.
2650 * xcoffread.c (xcoff_psymtab_to_symtab_1): Use scoped_free_pendings.
2651 (xcoff_initial_scan): Likewise.
2652 * buildsym.c (reset_symtab_globals): Update comment.
2653 (scoped_free_pendings): Rename from really_free_pendings.
2654 (prepare_for_building): Update comment.
2655 (buildsym_init): Likewise.
2656 * buildsym.h (class scoped_free_pendings): New class.
2657 (really_free_pendings): Don't declare.
2658
2659 2017-11-03 Ulrich Weigand <uweigand@de.ibm.com>
2660
2661 * doublest.c (convert_doublest_to_floatformat): Fix uninitialized
2662 output when converting a zero value to a special byteorder format.
2663
2664 2017-11-02 Yao Qi <yao.qi@linaro.org>
2665
2666 * frame.c (do_frame_register_read): Remove aspace.
2667 * jit.c (jit_frame_sniffer): Likwise.
2668 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
2669 * regcache.c (regcache::regcache): Pass nullptr.
2670 (regcache_print): Caller updated.
2671 * regcache.h (regcache::regcache): Remove one constructor
2672 parameter aspace.
2673
2674 2017-11-02 Yao Qi <yao.qi@linaro.org>
2675
2676 * regcache.h (regcache) <m_readonly_p>: Change it to const bool.
2677
2678 2017-11-02 Yao Qi <yao.qi@linaro.org>
2679
2680 * breakpoint.c (insert_single_step_breakpoints): Update.
2681 * frame.c (struct frame_info) <aspace>: Add const.
2682 (frame_save_as_regcache): Add const.
2683 (get_frame_address_space): Return const address_space *.
2684 * frame.h (get_frame_address_space): Update declaration.
2685 * infrun.c (struct step_over_info) <aspace>: Add const.
2686 (set_step_over_info): Make aspace const.
2687 (displaced_step_prepare_throw): Change variable const.
2688 (resume): Likewise.
2689 (proceed): Likewise.
2690 (adjust_pc_after_break): Likewise.
2691 (save_waitstatus): Likewise.
2692 (handle_signal_stop): Likewise.
2693 (keep_going_pass_signal): Likewise.
2694 * jit.c (jit_frame_sniffer): Add const.
2695 * mips-tdep.c (mips_single_step_through_delay): Likewise.
2696 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
2697 * record-full.c (record_full_wait_1): Likewise.
2698 * regcache.c (regcache::regcache): Change parameter to const.
2699 * regcache.h (regcache::regcache): Likewise.
2700 (regcache::aspace): Return const address_space *.
2701 (regcache) <m_aspace>: Add const.
2702
2703 2017-11-02 Yao Qi <yao.qi@linaro.org>
2704
2705 * darwin-nat.c (cancel_breakpoint): Use regcache->aspace ().
2706 * frame.c (create_sentinel_frame): Likewise.
2707 * infrun.c (displaced_step_prepare_throw): Likewise.
2708 (resume): Likewise.
2709 (thread_still_needs_step_over_bp): Likewise.
2710 (proceed): Likewise.
2711 (do_target_wait): Likewise.
2712 (adjust_pc_after_break): Likewise.
2713 (handle_syscall_event): Likewise.
2714 (save_waitstatus): Likewise.
2715 (handle_inferior_event_1): Likewise.
2716 (handle_signal_stop): Likewise.
2717 (keep_going_pass_signal): Likewise.
2718 * linux-nat.c (status_callback): Likewise.
2719 (save_stop_reason): Likewise.
2720 (resume_stopped_resumed_lwps): Likewise.
2721 * record-full.c (record_full_exec_insn): Likewise.
2722 (record_full_wait_1): Likewise.
2723 * regcache.c (get_regcache_aspace): Remove.
2724 * regcache.h (get_regcache_aspace): Remove.
2725
2726 2017-11-02 Yao Qi <yao.qi@linaro.org>
2727
2728 * regcache.c (struct regcache_descr) <nr_raw_registers>: Remove.
2729 (init_regcache_descr): Use gdbarch_num_regs.
2730 (regcache::regcache): Likewise.
2731 (regcache::get_register_status): Likewise.
2732 (regcache::assert_raw_regnum): Likewise.
2733 (regcache::cooked_read): Likewise.
2734 (regcache::cooked_read_value): Likewise.
2735 (regcache::cooked_write): Likewise.
2736 (regcache::dump): Likewise.
2737 (regcache::num_raw_registers): New method.
2738 * regcache.h (class regcache) <num_raw_registers>: New.
2739
2740 2017-11-02 Yao Qi <yao.qi@linaro.org>
2741
2742 * regcache.c (regcache::assert_regnum): New method.
2743 (regcache::invalidate): Call assert_regnum.
2744 (regcache::raw_update): Likewise.
2745 (regcache::raw_write): Likewise.
2746 (regcache::raw_read_part): Likewise.
2747 (regcache::raw_write_part): Likewise.
2748 (regcache::raw_supply): Likewise.
2749 (regcache::raw_supply_integer): Likewise.
2750 (regcache::raw_supply_zeroed): Likewise.
2751 (regcache::raw_collect): Likewise.
2752 (regcache::raw_collect_integer): Likewise.
2753 * regcache.h (regcache::assert_regnum): Declare.
2754
2755 2017-11-02 Yao Qi <yao.qi@linaro.org>
2756
2757 * regcache.c (regcache::dump): Remove code.
2758
2759 2017-11-02 Yao Qi <yao.qi@linaro.org>
2760
2761 * regcache.c (struct regcache_descr) <sizeof_raw_register_status>:
2762 Remove.
2763 <sizeof_cooked_register_status>: Remove.
2764 (init_regcache_descr): Update.
2765 (regcache::regcache): Use nr_cooked_registers and nr_raw_registers.
2766 (regcache::save): Likewise.
2767 (regcache::dump): Likewise.
2768
2769 2017-11-01 James Bowman <james.bowman@ftdichip.com>
2770
2771 * ft32-tdep.c (ft32_fetch_instruction): New function.
2772 (ft32_analyze_prologue): Use ft32_fetch_instruction().
2773
2774 2017-10-31 Simon Marchi <simon.marchi@polymtl.ca>
2775
2776 * cli/cli-script.c (execute_control_command): Rename to ...
2777 (execute_control_command_1): ... this.
2778 (execute_control_command): New function.
2779
2780 2017-10-31 Simon Marchi <simon.marchi@ericsson.com>
2781
2782 * tracepoint.c (tfind_command): Remove const_cast.
2783
2784 2017-10-30 Mike Gulick <mgulick@mathworks.com>
2785
2786 * Makefile.in (HFILES_NO_SRCDIR): Remove reference to gdb.h.
2787
2788 2017-10-30 Simon Marchi <simon.marchi@ericsson.com>
2789
2790 * common/common-utils.h (in_inclusive_range): New function.
2791 * arm-tdep.c (arm_record_extension_space): Use
2792 in_inclusive_range.
2793 (thumb_record_ld_st_reg_offset): Use in_inclusive_range.
2794 * cris-tdep.c (cris_spec_reg_applicable): Use
2795 in_inclusive_range.
2796
2797 2017-10-30 Pedro Alves <palves@redhat.com>
2798 Simon Marchi <simon.marchi@ericsson.com>
2799
2800 * remote.c (remote_set_syscall_catchpoint): Build a std::string
2801 instead of a gdb::unique_xmalloc_ptr, using string_appendf.
2802
2803 2017-10-30 Pedro Alves <palves@redhat.com>
2804
2805 * common/common-utils.c (string_appendf, string_vappendf): New
2806 functions.
2807 * common/common-utils.h (string_appendf, string_vappendf): New
2808 declarations.
2809 * unittests/common-utils-selftests.c (string_appendf_func)
2810 (test_appendf_func, string_vappendf_wrapper, string_appendf_tests)
2811 (string_vappendf_tests): New functions.
2812 (_initialize_common_utils_selftests): Register "string_appendf" and
2813 "string_vappendf tests".
2814
2815 2017-10-30 Pedro Alves <palves@redhat.com>
2816
2817 * unittests/common-utils-selftests.c (format_func): New typedef.
2818 (string_printf_tests, string_vprintf_tests): Tests factored out
2819 and merged to ...
2820 (test_format_func): ... this new function.
2821 (string_printf_tests, string_vprintf_tests): Reimplement on top of
2822 test_format_func.
2823
2824 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
2825
2826 * darwin-nat.c: Remove include of gdb.h.
2827
2828 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
2829
2830 * xtensa-xtregs.c: Fix formatting issues.
2831
2832 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
2833
2834 * xtensa-xtregs.c (xtensa_regtable_t) <name>: Constify.
2835
2836 2017-10-28 Maksim Dzabraev <dzabraew@gmail.com>
2837
2838 PR python/21213
2839 * python/py-infthread.c (thpy_get_inferior): Increment reference
2840 of inferior before returning it.
2841
2842 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
2843
2844 * unittests/common-utils-selftests.c (format): Add
2845 ATTRIBUTE_PRINTF.
2846
2847 2017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
2848
2849 * xml-syscall.c (struct syscall_desc): Add constructor.
2850 <name>: Change type to std::string.
2851 (syscall_desc_up): New typedef.
2852 (syscall_desc_p): Remove typeder.
2853 (DEF_VEC_P(syscall_desc_p)): Remove.
2854 (struct syscall_group_desc): Add constructor.
2855 <name>: Change type to std::string.
2856 <syscalls>: Change type to std::vector.
2857 (syscall_group_desc_up): New typedef.
2858 (syscall_group_desc_p): Remove typedef.
2859 (DEF_VEC_P(syscall_group_desc_p)): Remove.
2860 (struct syscalls_info) <syscalls>: Change type to std::vector of
2861 unique_ptr.
2862 <groups>: Likewise.
2863 <my_gdb_datadir>: Change type to std::string.
2864 (syscalls_info_up): New typedef.
2865 (allocate_syscalls_info): Remove.
2866 (syscalls_info_free_syscalls_desc): Remove.
2867 (syscalls_info_free_syscall_group_desc): Remove.
2868 (free_syscalls_info): Remove.
2869 (make_cleanup_free_syscalls_info): Remove.
2870 (syscall_group_create_syscall_group_desc): Adjust.
2871 (syscall_group_add_syscall): Adjust.
2872 (syscall_create_syscall_desc): Adjust.
2873 (syscall_parse_xml): Adjust, use unique_ptr instead of cleanup.
2874 (init_syscalls_info): Adjust.
2875 (syscall_group_get_group_by_name): Adjust.
2876 (xml_get_syscall_number): Adjust.
2877 (xml_get_syscall_name): Adjust.
2878 (xml_list_of_syscalls): Adjust.
2879 (xml_list_syscalls_by_group): Adjust.
2880 (xml_list_of_groups): Adjust.
2881
2882 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
2883
2884 * probe.h: Don't include gdb_vecs.h.
2885 (DEF_VEC_P (probe_p)): Remove.
2886 (find_probes_in_objfile): Return an std::vector.
2887 * probe.c (find_probes_in_objfile): Likewise.
2888 * breakpoint.c (breakpoint_objfile_data)
2889 <longjmp_probes>: Change type to std::vector.
2890 <exception_probes>: Likewise.
2891 (free_breakpoint_probes): Don't manually free vectors.
2892 (create_longjmp_master_breakpoint): Adjust.
2893 (create_exception_master_breakpoint): Adjust.
2894 * solib-svr4.c (svr4_create_probe_breakpoints): Change
2895 parameter type, adjust.
2896 (svr4_create_solib_event_breakpoints): Adjust.
2897
2898 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
2899
2900 * breakpoint.c (breakpoint_objfile_data): Initialize fields.
2901 (get_breakpoint_objfile_data): Allocate breakpoint_objfile_data
2902 with new.
2903 (free_breakpoint_probes): Rename to ...
2904 (free_breakpoint_objfile_data): ... this, and call delete on
2905 bp_objfile_data..
2906
2907 2017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
2908
2909 * auto-load.c: Don't include gdb_vecs.h, include algorithm.
2910 (loaded_script_ptr): Remove typedef.
2911 (DEF_VEC_P (loaded_script_ptr)): Remove.
2912 (struct collect_matching_scripts_data): Add constructor.
2913 <scripts_p>: Change type to (pointer to) std::vector.
2914 (collect_matching_scripts_data): Adjust.
2915 (sort_scripts_by_name): Make suitable for std::sort.
2916 (print_scripts): Don't sort vector, adjust to std::vector.
2917 (auto_load_info_scripts): Sort vectors, adjust to std::vector.
2918
2919 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
2920
2921 * symfile.c (filename_language): Make struct, not typedef. Add
2922 constructor.
2923 <ext>: Change type to std::string.
2924 (DEF_VEC_O (filename_language)): Remove.
2925 (filename_language_table): Change type to std::vector.
2926 (add_filename_language): Adjust.
2927 (set_ext_lang_command): Adjust.
2928 (info_ext_lang_command): Adjust.
2929 (deduce_language_from_filename): Adjust.
2930 (class scoped_restore_filename_language_table): Remove.
2931 (test_filename_language): Use scoped_restore.
2932 (test_set_ext_lang_command): Use scoped_restore, adjust to
2933 std::vector change.
2934
2935 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
2936
2937 * symfile.c: Include selftest.h.
2938 (class scoped_restore_filename_language_table): New.
2939 (test_filename_language): New test.
2940 (test_set_ext_lang_command): New test.
2941 (_initialize_symfile): Register tests.
2942
2943 2017-10-27 Keith Seitz <keiths@redhat.com>
2944
2945 * breakpoint.c (print_breakpoint_location): Use the symbol saved
2946 in the bp_location, falling back to find_pc_sect_function when
2947 needed.
2948 (add_location_to_breakpoint): Save sal->symbol.
2949 * breakpoint.h (struct bp_location) <symbol>: New field.
2950 * symtab.c (find_function_start_sal): Save the symbol into the SaL.
2951 * symtab.h (struct symtab_and_line) <symbol>: New field.
2952
2953 2017-10-26 Patrick Frants <osscontribute@gmail.com>
2954
2955 PR gdb/13669
2956 * cp-valprint.c (cp_print_value_fields): Use obstack_blank_fast
2957 to rewind obstack.
2958
2959 2017-10-26 Pedro Alves <palves@redhat.com>
2960
2961 * remote.c (remote_async_terminal_ours_p): Delete.
2962 (remote_open_1, remote_terminal_inferior, remote_terminal_ours):
2963 Remove references to 'remote_async_terminal_ours_p'.
2964
2965 2017-10-26 Yao Qi <yao.qi@linaro.org>
2966
2967 * breakpoint.h (regular_breakpoint_inserted_here_p): Remove.
2968
2969 2017-10-26 Yao Qi <yao.qi@linaro.org>
2970
2971 * break-catch-sig.c (signal_catchpoint_breakpoint_hit): Make
2972 aspace const.
2973 * break-catch-syscall.c (breakpoint_hit_catch_syscall):
2974 Likewise.
2975 * breakpoint.c (bpstat_check_location): Remove cast.
2976 (breakpoint_hit_catch_fork): Make aspce const.
2977 (breakpoint_hit_catch_solib): Likewise.
2978 (breakpoint_hit_catch_exec): Likewise.
2979 (breakpoint_hit_ranged_breakpoint): Likewise.
2980 (breakpoint_hit_watchpoint): Likewise.
2981 (base_breakpoint_breakpoint_hit): Likewise.
2982 (bkpt_breakpoint_hit): Likewise.
2983 (dprintf_breakpoint_hit): Likewise.
2984 (tracepoint_breakpoint_hit): Likewise.
2985 * breakpoint.h (breakpoint_ops) <breakpoint_hit>: Likewise.
2986
2987 2017-10-26 Yao Qi <yao.qi@linaro.org>
2988
2989 * breakpoint.c (breakpoint_location_address_match): Change
2990 "struct address_space *" to "const address_space".
2991 (breakpoint_location_address_range_overlap): Likewise.
2992 (breakpoint_here_p): Likewise.
2993 (breakpoint_in_range_p): Likewise.
2994 (moribund_breakpoint_here_p): Likewise.
2995 (bp_location_inserted_here_p): Likewise.
2996 (software_breakpoint_inserted_here_p): Likewise.
2997 (hardware_breakpoint_inserted_here_p): Likewise.
2998 (hardware_watchpoint_inserted_in_range): Likewise.
2999 (bpstat_check_location): Likewise.
3000 (bpstat_stop_status): Likewise.
3001 (breakpoint_address_match): Likewise.
3002 (breakpoint_address_match_range): Likewise.
3003 (breakpoint_location_address_match): Likewise.
3004 (breakpoint_location_address_range_overlap): Likewise.
3005 (insert_single_step_breakpoint): Likewise.
3006 (breakpoint_has_location_inserted_here): Likewise.
3007 (single_step_breakpoint_inserted_here_p): Likewise.
3008 (pc_at_non_inline_function): Likewise.
3009 * breakpoint.h (bpstat_stop_status): Update declaration.
3010 (breakpoint_here_p): Likewise.
3011 (breakpoint_in_range_p): Likewise.
3012 (moribund_breakpoint_here_p): Likewise.
3013 (breakpoint_inserted_here_p): Likewise.
3014 (software_breakpoint_inserted_here_p): Likewise.
3015 (hardware_breakpoint_inserted_here_p): Likewise.
3016 (breakpoint_has_location_inserted_here): Likewise.
3017 (single_step_breakpoint_inserted_here_p): Likewise.
3018 (hardware_watchpoint_inserted_in_range): Likewise.
3019 (breakpoint_address_match): Likewise.
3020 (insert_single_step_breakpoint): Likewise.
3021 (pc_at_non_inline_function): Likewise.
3022 * gdbthread.h (thread_has_single_step_breakpoint_here): Likewise.
3023 * record.c (record_check_stopped_by_breakpoint): Likewise.
3024 * record.h (record_check_stopped_by_breakpoint): Likewise.
3025 * thread.c (thread_has_single_step_breakpoint_here): Likewise.
3026
3027 2017-10-25 Yao Qi <yao.qi@linaro.org>
3028
3029 * aarch32-linux-nat.c (aarch32_gp_regcache_supply): Use
3030 regcache->arch () instead get_regcache_arch.
3031 * aarch64-fbsd-nat.c (aarch64_fbsd_fetch_inferior_registers):
3032 Likewise.
3033 (aarch64_fbsd_store_inferior_registers): Likewise.
3034 * aarch64-linux-nat.c (fetch_gregs_from_thread): Likewise.
3035 (store_gregs_to_thread): Likewise.
3036 (fetch_fpregs_from_thread): Likewise.
3037 (store_fpregs_to_thread): Likewise.
3038 * aarch64-tdep.c (aarch64_extract_return_value): Likewise.
3039 (aarch64_store_return_value): Likewise.
3040 (aarch64_software_single_step): Likewise.
3041 * aix-thread.c (aix_thread_wait): Likewise.
3042 (supply_reg32): Likewise.
3043 (supply_sprs64): Likewise.
3044 (supply_sprs32): Likewise.
3045 (fill_gprs64): Likewise.
3046 (fill_gprs32): Likewise.
3047 (fill_sprs64): Likewise.
3048 (fill_sprs32): Likewise.
3049 (store_regs_user_thread): Likewise.
3050 (store_regs_kernel_thread): Likewise.
3051 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers): Likewise.
3052 (alphabsd_store_inferior_registers): Likewise.
3053 * alpha-tdep.c (alpha_extract_return_value): Likewise.
3054 (alpha_store_return_value): Likewise.
3055 (alpha_deal_with_atomic_sequence): Likewise.
3056 (alpha_next_pc): Likewise.
3057 (alpha_software_single_step): Likewise.
3058 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Likewise.
3059 (amd64bsd_store_inferior_registers): Likewise.
3060 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers):
3061 Likewise.
3062 (amd64_linux_store_inferior_registers): Likewise.
3063 * amd64-nat.c (amd64_supply_native_gregset): Likewise.
3064 (amd64_collect_native_gregset): Likewise.
3065 * amd64-obsd-tdep.c (amd64obsd_supply_uthread): Likewise.
3066 (amd64obsd_collect_uthread): Likewise.
3067 * amd64-tdep.c (amd64_supply_fpregset): Likewise.
3068 (amd64_collect_fpregset): Likewise.
3069 (amd64_supply_fxsave): Likewise.
3070 (amd64_supply_xsave): Likewise.
3071 (amd64_collect_fxsave): Likewise.
3072 (amd64_collect_xsave): Likewise.
3073 * arc-tdep.c (arc_write_pc): Likewise.
3074 * arch-utils.c (default_skip_permanent_breakpoint): Likewise.
3075 * arm-fbsd-nat.c (arm_fbsd_fetch_inferior_registers): Likewise.
3076 (arm_fbsd_store_inferior_registers): Likewise.
3077 * arm-linux-nat.c (fetch_vfp_regs): Likewise.
3078 (store_vfp_regs): Likewise.
3079 (arm_linux_fetch_inferior_registers): Likewise.
3080 (arm_linux_store_inferior_registers): Likewise.
3081 * arm-linux-tdep.c (arm_linux_supply_gregset): Likewise.
3082 (arm_linux_sigreturn_next_pc): Likewise.
3083 (arm_linux_get_next_pcs_syscall_next_pc): Likewise.
3084 * arm-nbsd-nat.c (arm_supply_gregset): Likewise.
3085 (fetch_register): Likewise.
3086 (store_register): Likewise.
3087 * arm-tdep.c (arm_is_thumb): Likewise.
3088 (displaced_in_arm_mode): Likewise.
3089 (bx_write_pc): Likewise.
3090 (arm_get_next_pcs_addr_bits_remove): Likewise.
3091 (arm_software_single_step): Likewise.
3092 (arm_extract_return_value): Likewise.
3093 (arm_store_return_value): Likewise.
3094 (arm_write_pc): Likewise.
3095 * bfin-tdep.c (bfin_extract_return_value): Likewise.
3096 * bsd-uthread.c (bsd_uthread_fetch_registers): Likewise.
3097 (bsd_uthread_store_registers): Likewise.
3098 * core-regset.c (fetch_core_registers): Likewise.
3099 * corelow.c (get_core_registers): Likewise.
3100 * cris-tdep.c (cris_store_return_value): Likewise.
3101 (cris_extract_return_value): Likewise.
3102 (find_step_target): Likewise.
3103 (find_step_target): Likewise.
3104 (cris_software_single_step): Likewise.
3105 * ctf.c (ctf_fetch_registers): Likewise.
3106 * darwin-nat.c (cancel_breakpoint): Likewise.
3107 * fbsd-tdep.c (fbsd_collect_thread_registers): Likewise.
3108 * frv-tdep.c (frv_extract_return_value): Likewise.
3109 * ft32-tdep.c (ft32_store_return_value): Likewise.
3110 (ft32_extract_return_value): Likewise.
3111 * go32-nat.c (fetch_register): Likewise.
3112 (go32_fetch_registers): Likewise.
3113 (go32_store_registers): Likewise.
3114 (store_register): Likewise.
3115 * h8300-tdep.c (h8300_extract_return_value): Likewise.
3116 (h8300_store_return_value): Likewise.
3117 * hppa-linux-nat.c (fetch_register): Likewise.
3118 (store_register): Likewise.
3119 (hppa_linux_fetch_inferior_registers): Likewise.
3120 (hppa_linux_store_inferior_registers): Likewise.
3121 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers): Likewise.
3122 (i386_darwin_store_inferior_registers): Likewise.
3123 * i386-gnu-nat.c (gnu_fetch_registers): Likewise.
3124 (gnu_store_registers): Likewise.
3125 * i386-linux-nat.c (fetch_register): Likewise.
3126 (store_register): Likewise.
3127 (supply_gregset): Likewise.
3128 (fill_gregset): Likewise.
3129 (i386_linux_fetch_inferior_registers): Likewise.
3130 (i386_linux_store_inferior_registers): Likewise.
3131 (i386_linux_resume): Likewise.
3132 * i386-linux-tdep.c (i386_linux_get_syscall_number_from_regcache):
3133 Likewise.
3134 * i386-nto-tdep.c (i386nto_supply_gregset): Likewise.
3135 * i386-obsd-nat.c (i386obsd_supply_pcb): Likewise.
3136 * i386-obsd-tdep.c (i386obsd_supply_uthread): Likewise.
3137 (i386obsd_collect_uthread): Likewise.
3138 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
3139 (i386_supply_gregset): Likewise.
3140 (i386_collect_gregset): Likewise.
3141 (i386_supply_fpregset): Likewise.
3142 (i386_collect_fpregset): Likewise.
3143 (i386_mpx_bd_base): Likewise.
3144 * i386-v4-nat.c (supply_fpregset): Likewise.
3145 (fill_fpregset): Likewise.
3146 * i387-tdep.c (i387_supply_fsave): Likewise.
3147 (i387_collect_fsave): Likewise.
3148 (i387_supply_fxsave): Likewise.
3149 (i387_collect_fxsave): Likewise.
3150 (i387_supply_xsave): Likewise.
3151 (i387_collect_xsave): Likewise.
3152 * ia64-linux-nat.c (ia64_linux_fetch_registers): Likewise.
3153 (ia64_linux_store_registers): Likewise.
3154 * ia64-tdep.c (ia64_access_rse_reg): Likewise.
3155 (ia64_extract_return_value): Likewise.
3156 (ia64_store_return_value): Likewise.
3157 (find_func_descr): Likewise.
3158 * inf-child.c (inf_child_fetch_inferior_registers): Likewise.
3159 * inf-ptrace.c (inf_ptrace_fetch_registers): Likewise.
3160 (inf_ptrace_store_registers): Likewise.
3161 * infrun.c (use_displaced_stepping): Likewise.
3162 (displaced_step_prepare_throw): Likewise.
3163 (resume): Likewise.
3164 (proceed): Likewise.
3165 (do_target_wait): Likewise.
3166 (adjust_pc_after_break): Likewise.
3167 (handle_inferior_event_1): Likewise.
3168 (handle_signal_stop): Likewise.
3169 (save_infcall_suspend_state): Likewise.
3170 (restore_infcall_suspend_state): Likewise.
3171 * iq2000-tdep.c (iq2000_extract_return_value): Likewise.
3172 * jit.c (jit_frame_prev_register): Likewise.
3173 * linux-nat.c (save_stop_reason): Likewise.
3174 (linux_nat_wait_1): Likewise.
3175 (resume_stopped_resumed_lwps): Likewise.
3176 * linux-record.c (record_linux_sockaddr): Likewise.
3177 (record_linux_msghdr): Likewise.
3178 (record_linux_system_call): Likewise.
3179 * linux-tdep.c (linux_collect_thread_registers): Likewise.
3180 * lm32-tdep.c (lm32_extract_return_value): Likewise.
3181 (lm32_store_return_value): Likewise.
3182 * m32c-tdep.c (m32c_read_flg): Likewise.
3183 (m32c_pseudo_register_read): Likewise.
3184 (m32c_pseudo_register_write): Likewise.
3185 * m32r-linux-tdep.c (m32r_linux_supply_gregset): Likewise.
3186 (m32r_linux_collect_gregset): Likewise.
3187 * m32r-tdep.c (m32r_store_return_value): Likewise.
3188 (m32r_extract_return_value): Likewise.
3189 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
3190 (m68kbsd_collect_fpregset): Likewise.
3191 * m68k-bsd-tdep.c (m68kbsd_supply_fpregset): Likewise.
3192 * m68k-linux-nat.c (fetch_register): Likewise.
3193 (old_fetch_inferior_registers): Likewise.
3194 (old_store_inferior_registers): Likewise.
3195 (store_regs): Likewise.
3196 * m68k-tdep.c (m68k_svr4_extract_return_value): Likewise.
3197 (m68k_svr4_store_return_value): Likewise.
3198 * m88k-tdep.c (m88k_store_arguments): Likewise.
3199 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Likewise.
3200 (mi_cmd_data_write_register_values): Likewise.
3201 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers): Likewise.
3202 (mips_fbsd_store_inferior_registers): Likewise.
3203 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Likewise.
3204 (mips_fbsd_supply_gregs): Likewise.
3205 (mips_fbsd_collect_fpregs): Likewise.
3206 (mips_fbsd_collect_gregs): Likewise.
3207 (mips_fbsd_supply_fpregset): Likewise.
3208 (mips_fbsd_collect_fpregset): Likewise.
3209 (mips_fbsd_supply_gregset): Likewise.
3210 (mips_fbsd_collect_gregset): Likewise.
3211 * mips-linux-nat.c (supply_gregset): Likewise.
3212 (fill_gregset): Likewise.
3213 (supply_fpregset): Likewise.
3214 (fill_fpregset): Likewise.
3215 * mips-linux-tdep.c (mips_supply_gregset): Likewise.
3216 (mips_fill_gregset): Likewise.
3217 (mips_supply_fpregset): Likewise.
3218 (mips_fill_fpregset): Likewise.
3219 (mips64_supply_gregset): Likewise.
3220 (micromips_linux_sigframe_validate): Likewise.
3221 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers): Likewise.
3222 (mipsnbsd_fetch_inferior_registers): Likewise.
3223 (mipsnbsd_store_inferior_registers): Likewise.
3224 * mips-nbsd-tdep.c (mipsnbsd_supply_fpregset): Likewise.
3225 (mipsnbsd_supply_gregset): Likewise.
3226 (mipsnbsd_iterate_over_regset_sections): Likewise.
3227 (mipsnbsd_supply_reg): Likewise.
3228 (mipsnbsd_supply_fpreg): Likewise.
3229 * mips-tdep.c (mips_in_frame_stub): Likewise.
3230 (mips_dummy_id): Likewise.
3231 (is_octeon_bbit_op): Likewise.
3232 (micromips_bc1_pc): Likewise.
3233 (extended_mips16_next_pc): Likewise.
3234 (mips16_next_pc): Likewise.
3235 (deal_with_atomic_sequence): Likewise.
3236 * moxie-tdep.c (moxie_process_readu): Likewise.
3237 * nios2-tdep.c (nios2_get_next_pc): Likewise.
3238 * nto-procfs.c (procfs_store_registers): Likewise.
3239 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers): Likewise.
3240 (ppcfbsd_store_inferior_registers): Likewise.
3241 * ppc-linux-nat.c (fetch_vsx_register): Likewise.
3242 (fetch_altivec_register): Likewise.
3243 (get_spe_registers): Likewise.
3244 (fetch_spe_register): Likewise.
3245 (fetch_altivec_registers): Likewise.
3246 (fetch_all_gp_regs): Likewise.
3247 (fetch_all_fp_regs): Likewise.
3248 (store_vsx_register): Likewise.
3249 (store_altivec_register): Likewise.
3250 (set_spe_registers): Likewise.
3251 (store_spe_register): Likewise.
3252 (store_altivec_registers): Likewise.
3253 (store_all_gp_regs): Likewise.
3254 (store_all_fp_regs): Likewise.
3255 * ppc-linux-tdep.c (ppc_linux_supply_gregset): Likewise.
3256 (ppc_linux_collect_gregset): Likewise.
3257 (ppc_canonicalize_syscall): Likewise.
3258 (ppc_linux_record_signal): Likewise.
3259 (ppu2spu_prev_register): Likewise.
3260 * ppc-nbsd-nat.c (ppcnbsd_supply_pcb): Likewise.
3261 * ppc-obsd-nat.c (ppcobsd_fetch_registers): Likewise.
3262 (ppcobsd_store_registers): Likewise.
3263 * ppc-ravenscar-thread.c (ppc_ravenscar_generic_fetch_registers):
3264 Likewise.
3265 (ppc_ravenscar_generic_store_registers): Likewise.
3266 * procfs.c (procfs_fetch_registers): Likewise.
3267 (procfs_store_registers): Likewise.
3268 * ravenscar-thread.c (ravenscar_fetch_registers): Likewise.
3269 (ravenscar_store_registers): Likewise.
3270 (ravenscar_prepare_to_store): Likewise.
3271 * record-btrace.c (record_btrace_fetch_registers): Likewise.
3272 * record-full.c (record_full_wait_1): Likewise.
3273 (record_full_registers_change): Likewise.
3274 (record_full_store_registers): Likewise.
3275 (record_full_core_fetch_registers): Likewise.
3276 (record_full_save): Likewise.
3277 (record_full_goto_insn): Likewise.
3278 * regcache.c (regcache_register_size): Likewise.
3279 (get_regcache_arch): Remove.
3280 (regcache_read_pc): Likewise.
3281 * regcache.h (get_regcache_arch): Remove.
3282 * remote-sim.c (gdbsim_fetch_register): Likewise.
3283 (gdbsim_store_register): Likewise.
3284 * remote.c (fetch_register_using_p): Likewise.
3285 (send_g_packet): Likewise.
3286 (remote_prepare_to_store): Likewise.
3287 (store_registers_using_G): Likewise.
3288 * reverse.c (save_bookmark_command): Likewise.
3289 (goto_bookmark_command): Likewise.
3290 * rs6000-aix-tdep.c (branch_dest): Likewise.
3291 * rs6000-nat.c (rs6000_ptrace64): Likewise.
3292 (fetch_register): Likewise.
3293 * rs6000-tdep.c (ppc_supply_reg): Likewise.
3294 (ppc_collect_reg): Likewise.
3295 (ppc_collect_gregset): Likewise.
3296 (ppc_collect_fpregset): Likewise.
3297 (ppc_collect_vsxregset): Likewise.
3298 (ppc_collect_vrregset): Likewise.
3299 (ppc_displaced_step_hw_singlestep): Likewise.
3300 (rs6000_pseudo_register_read): Likewise.
3301 (rs6000_pseudo_register_write): Likewise.
3302 * s390-linux-nat.c (supply_gregset): Likewise.
3303 (fill_gregset): Likewise.
3304 (s390_linux_fetch_inferior_registers): Likewise.
3305 * s390-linux-tdep.c (s390_write_pc): Likewise.
3306 (s390_software_single_step): Likewise.
3307 (s390_all_but_pc_registers_record): Likewise.
3308 (s390_linux_syscall_record): Likewise.
3309 * sentinel-frame.c (sentinel_frame_prev_arch): Likewise.
3310 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers): Likewise.
3311 (shnbsd_store_inferior_registers): Likewise.
3312 * sh-tdep.c (sh_extract_return_value_nofpu): Likewise.
3313 (sh_extract_return_value_fpu): Likewise.
3314 (sh_store_return_value_nofpu): Likewise.
3315 (sh_corefile_supply_regset): Likewise.
3316 (sh_corefile_collect_regset): Likewise.
3317 * sh64-tdep.c (sh64_extract_return_value): Likewise.
3318 (sh64_store_return_value): Likewise.
3319 * sparc-linux-tdep.c (sparc32_linux_collect_core_fpregset): Likewise.
3320 * sparc-nat.c (sparc_fetch_inferior_registers): Likewise.
3321 (sparc_store_inferior_registers): Likewise.
3322 * sparc-ravenscar-thread.c (register_in_thread_descriptor_p): Likewise.
3323 (sparc_ravenscar_prepare_to_store): Likewise.
3324 * sparc-tdep.c (sparc32_store_arguments): Likewise.
3325 (sparc_analyze_control_transfer): Likewise.
3326 (sparc_step_trap): Likewise.
3327 (sparc_software_single_step): Likewise.
3328 (sparc32_gdbarch_init): Likewise.
3329 (sparc_supply_rwindow): Likewise.
3330 (sparc_collect_rwindow): Likewise.
3331 * sparc64-linux-tdep.c (sparc64_linux_collect_core_fpregset): Likewise.
3332 * sparc64-nbsd-nat.c (sparc64nbsd_supply_gregset): Likewise.
3333 (sparc64nbsd_collect_gregset): Likewise.
3334 (sparc64nbsd_supply_fpregset): Likewise.
3335 (sparc64nbsd_collect_fpregset): Likewise.
3336 * sparc64-tdep.c (sparc64_store_arguments): Likewise.
3337 (sparc64_supply_gregset): Likewise.
3338 (sparc64_collect_gregset): Likewise.
3339 (sparc64_supply_fpregset): Likewise.
3340 (sparc64_collect_fpregset): Likewise.
3341 * spu-linux-nat.c (spu_fetch_inferior_registers): Likewise.
3342 * spu-tdep.c (spu_unwind_sp): Likewise.
3343 (spu2ppu_prev_register): Likewise.
3344 (spu_memory_remove_breakpoint): Likewise.
3345 * stack.c (return_command): Likewise.
3346 * tic6x-tdep.c (tic6x_extract_signed_field): Likewise.
3347 * tracefile-tfile.c (tfile_fetch_registers): Likewise.
3348 * tracefile.c (trace_save_ctf): Likewise.
3349 * windows-nat.c (do_windows_fetch_inferior_registers): Likewise.
3350 (do_windows_store_inferior_registers): Likewise.
3351 (windows_resume): Likewise.
3352 * xtensa-linux-nat.c (fill_gregset): Likewise.
3353 (supply_gregset_reg): Likewise.
3354 * xtensa-tdep.c (xtensa_register_write_masked): Likewise.
3355 (xtensa_register_read_masked): Likewise.
3356 (xtensa_supply_gregset): Likewise.
3357 (xtensa_extract_return_value): Likewise.
3358 (xtensa_store_return_value): Likewise.
3359
3360 2017-10-25 Ulrich Weigand <uweigand@de.ibm.com>
3361
3362 * doublest.c (floatformat_from_string): New function.
3363 * doublest.h (floatformat_from_string): Add prototype.
3364
3365 * std-operator.def (OP_DOUBLE, OP_DECFLOAT): Remove, replace by ...
3366 (OP_FLOAT): ... this.
3367 * expression.h: Do not include "doublest.h".
3368 (union exp_element): Replace doubleconst and decfloatconst by
3369 new element floatconst.
3370 * ada-lang.c (resolve_subexp): Handle OP_FLOAT instead of OP_DOUBLE.
3371 (ada_evaluate_subexp): Likewise.
3372 * eval.c (evaluate_subexp_standard): Handle OP_FLOAT instead of
3373 OP_DOUBLE and OP_DECFLOAT.
3374 * expprint.c (print_subexp_standard): Likewise.
3375 (dump_subexp_body_standard): Likewise.
3376 * breakpoint.c (watchpoint_exp_is_const): Likewise.
3377
3378 * parse.c: Include "dfp.h".
3379 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
3380 (write_exp_elt_floatcst): New function.
3381 (operator_length_standard): Handle OP_FLOAT instead of OP_DOUBLE
3382 and OP_DECFLOAT.
3383 (operator_check_standard): Likewise.
3384 (parse_float): Do not accept suffix. Take type as input. Return bool.
3385 Return target format buffer instead of host DOUBLEST.
3386 Use floatformat_from_string and decimal_from_string to parse
3387 either binary or decimal floating-point types.
3388 (parse_c_float): Remove.
3389 * parser-defs.h: Do not include "doublest.h".
3390 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
3391 (write_exp_elt_floatcst): Add prototype.
3392 (parse_float): Update prototype.
3393 (parse_c_float): Remove.
3394
3395 * c-exp.y: Do not include "dfp.h".
3396 (typed_val_float): Use byte buffer instead of DOUBLEST.
3397 (typed_val_decfloat): Remove.
3398 (DECFLOAT): Remove.
3399 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3400 (parse_number): Update to new parse_float interface.
3401 Parse suffixes and determine type before calling parse_float.
3402 Handle decimal and binary FP types the same way.
3403
3404 * d-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
3405 (FLOAT_LITERAL): Use OP_FLOAT and write_exp_elt_floatcst.
3406 (parse_number): Update to new parse_float interface.
3407 Parse suffixes and determine type before calling parse_float.
3408
3409 * f-exp.y: Replace dval by typed_val_float.
3410 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3411 (parse_number): Use parse_float instead of atof.
3412
3413 * go-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
3414 (parse_go_float): Remove.
3415 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3416 (parse_number): Call parse_float instead of parse_go_float.
3417 Parse suffixes and determine type before calling parse_float.
3418
3419 * p-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
3420 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3421 (parse_number): Update to new parse_float interface.
3422 Parse suffixes and determine type before calling parse_float.
3423
3424 * m2-exp.y: Replace dval by byte buffer val.
3425 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3426 (parse_number): Call parse_float instead of atof.
3427
3428 * rust-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
3429 (lex_number): Call parse_float instead of strtod.
3430 (ast_dliteral): Use OP_FLOAT instead of OP_DOUBLE.
3431 (convert_ast_to_expression): Handle OP_FLOAT instead of OP_DOUBLE.
3432 Use write_exp_elt_floatcst.
3433 (unit_testing): Remove static variable.
3434 (rust_type): Do not check unit_testing.
3435 (rust_lex_tests): Do not set uint_testing. Set up dummy rust_parser.
3436
3437 * ada-exp.y (type_float, type_double): Remove.
3438 (typed_val_float): Use byte buffer instead of DOUBLEST.
3439 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3440 * ada-lex.l (processReal): Use parse_float instead of sscanf.
3441
3442 2017-10-25 Alan Hayward <alan.hayward@arm.com>
3443
3444 * aarch64-tdep.h (enum aarch64_regnum): Remove.
3445 * arch/aarch64.h: New file.
3446
3447 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
3448
3449 * dfp.h (decimal_from_string): Use const reference for argument.
3450 * dfp.c (decimal_from_string): Likewise.
3451
3452 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
3453
3454 * i387-tdep.c (print_i387_value): Use floatformat_to_string.
3455 * sh64-tdep.c (sh64_do_fp_register): Likewise.
3456 * mips-tdep.c (mips_print_fp_register): Likewise.
3457
3458 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
3459
3460 * common/format.h (enum argclass): Replace decfloat_arg by
3461 dec32float_arg, dec64float_arg, and dec128float_arg.
3462 * common/format.c (parse_format_string): Update to return
3463 new decimal float argument classes.
3464
3465 * printcmd.c (printf_decfloat): Rename to ...
3466 (printf_floating): ... this. Add argclass argument, and use it
3467 instead of parsing the format string again. Add support for
3468 binary floating-point values, using floatformat_to_string.
3469 Convert value to the target format if it doesn't already match.
3470 (ui_printf): Call printf_floating instead of printf_decfloat,
3471 also for double_arg / long_double_arg. Pass argclass.
3472
3473 * dfp.c (decimal_to_string): Add format string argument.
3474 * dfp.h (decimal_to_string): Likewise.
3475
3476 * doublest.c (floatformat_to_string): Add format string argument.
3477 * doublest.h (floatformat_to_string): Likewise.
3478
3479 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
3480
3481 * doublest.c (floatformat_precision): New routine.
3482 (floatformat_to_string): Likewise.
3483 * doublest.c (floatformat_to_string): Add prototype.
3484
3485 * printcmd.c (print_scalar_formatted): Only call print_floating
3486 on floating-point types.
3487 * valprint.c: Do not include "floatformat.h".
3488 (generic_val_print_decfloat): Remove.
3489 (generic_val_print): Call generic_val_print_float for both
3490 TYPE_CODE_FLT and TYPE_CODE_DECFLOAT.
3491 (print_floating): Use floatformat_to_string. Handle decimal float.
3492 (print_decimal_floating): Remove, merge into floatformat_to_string.
3493 * value.h (print_decimal_floating): Remove.
3494
3495 * Makefile.in: Do not build doublest.c with -Wformat-nonliteral.
3496
3497 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
3498
3499 * buildsym.c (end_symtab_get_static_block): Use std::stable_sort.
3500
3501 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
3502
3503 * memattr.h: Don't include vec.h.
3504 (struct mem_attrib): Initialize fields.
3505 <unknown>: New static method.
3506 (struct mem_region): Add constructors, operator<, initialize
3507 fields.
3508 * memattr.c: Include algorithm.
3509 (default_mem_attrib, unknown_mem_attrib): Remove.
3510 (user_mem_region_list): New global.
3511 (target_mem_region_list, mem_region_list): Change type to
3512 std::vector<mem_region>.
3513 (mem_use_target): Now a function.
3514 (target_mem_regions_valid): Change type to bool.
3515 (mem_region_lessthan, mem_region_cmp, mem_region_init): Remove.
3516 (require_user_regions): Adjust.
3517 (require_target_regions): Adjust.
3518 (create_mem_region): Adjust.
3519 (lookup_mem_region): Adjust.
3520 (invalidate_target_mem_regions): Adjust.
3521 (mem_clear): Rename to...
3522 (user_mem_clear): ... this, and adjust.
3523 (mem_command): Adjust.
3524 (info_mem_command): Adjust.
3525 (mem_enable, enable_mem_command, mem_disable,
3526 disable_mem_command): Adjust.
3527 (mem_delete): Adjust.
3528 (delete_mem_command): Adjust.
3529 * memory-map.h (parse_memory_map): Return an std::vector.
3530 * memory-map.c (parse_memory_map): Likewise.
3531 (struct memory_map_parsing_data): Add constructor.
3532 <memory_map>: Point to std::vector.
3533 (memory_map_start_memory): Adjust.
3534 (memory_map_end_memory): Adjust.
3535 (memory_map_end_property): Adjust.
3536 (clear_result): Remove.
3537 * remote.c (remote_memory_map): Return an std::vector.
3538 * target-debug.h (target_debug_print_VEC_mem_region_s__p):
3539 Remove.
3540 (target_debug_print_mem_region_vector): New.
3541 * target-delegates.c: Regenerate.
3542 * target.h (mem_region_vector): New typedef.
3543 (to_memory_map): Return mem_region_vector.
3544 (target_memory_map): Return an std::vector.
3545 * target.c (target_memory_map): Return an std::vector.
3546 (flash_erase_command): Adjust.
3547
3548 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
3549
3550 * memory-map.c (struct memory_map_parsing_data) <property_name>:
3551 Change type to std::string.
3552 (memory_map_start_property): Adjust.
3553 (memory_map_end_property): Adjust.
3554
3555 2017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
3556
3557 * infrun.h: Include common/byte-vector.h.
3558 (struct displaced_step_closure): New struct.
3559 (struct buf_displaced_step_closure): New struct.
3560 * infrun.c (displaced_step_closure::~displaced_step_closure):
3561 Provide default implementation.
3562 (displaced_step_clear): Deallocate step closure with delete.
3563 * aarch64-tdep.c (displaced_step_closure): Rename to ...
3564 (aarch64_displaced_step_closure): ... this, extend
3565 displaced_step_closure.
3566 (aarch64_displaced_step_data) <dsc>: Change type to
3567 aarch64_displaced_step_closure.
3568 (aarch64_displaced_step_copy_insn): Adjust to type change, use
3569 unique_ptr.
3570 (aarch64_displaced_step_fixup): Add cast for displaced step
3571 closure.
3572 * amd64-tdep.c (displaced_step_closure): Rename to ...
3573 (amd64_displaced_step_closure): ... this, extend
3574 displaced_step_closure.
3575 <insn_buf>: Change type to std::vector<gdb_byte>.
3576 <max_len>: Remove.
3577 (fixup_riprel): Change type of DSC parameter, adjust to type
3578 change of insn_buf.
3579 (fixup_displaced_copy): Change type of DSC parameter.
3580 (amd64_displaced_step_copy_insn): Instantiate
3581 amd64_displaced_step_closure.
3582 (amd64_displaced_step_fixup): Add cast for closure type, adjust
3583 to type change of insn_buf.
3584 * arm-linux-tdep.c (arm_linux_cleanup_svc): Change type of
3585 parameter DSC.
3586 (arm_linux_copy_svc): Likewise.
3587 (cleanup_kernel_helper_return): Likewise.
3588 (arm_catch_kernel_helper_return): Likewise.
3589 (arm_linux_displaced_step_copy_insn): Instantiate
3590 arm_displaced_step_closure.
3591 * arm-tdep.c (arm_pc_is_thumb): Add cast for closure.
3592 (displaced_read_reg): Change type of parameter DSC.
3593 (branch_write_pc): Likewise.
3594 (load_write_pc): Likewise.
3595 (alu_write_pc): Likewise.
3596 (displaced_write_reg): Likewise.
3597 (arm_copy_unmodified): Likewise.
3598 (thumb_copy_unmodified_32bit): Likewise.
3599 (thumb_copy_unmodified_16bit): Likewise.
3600 (cleanup_preload): Likewise.
3601 (install_preload): Likewise.
3602 (arm_copy_preload): Likewise.
3603 (thumb2_copy_preload): Likewise.
3604 (install_preload_reg): Likewise.
3605 (arm_copy_preload_reg): Likewise.
3606 (cleanup_copro_load_store): Likewise.
3607 (install_copro_load_store): Likewise.
3608 (arm_copy_copro_load_store) Likewise.
3609 (thumb2_copy_copro_load_store): Likewise.
3610 (cleanup_branch): Likewise.
3611 (install_b_bl_blx): Likewise.
3612 (arm_copy_b_bl_blx): Likewise.
3613 (thumb2_copy_b_bl_blx): Likewise.
3614 (thumb_copy_b): Likewise.
3615 (install_bx_blx_reg): Likewise.
3616 (arm_copy_bx_blx_reg): Likewise.
3617 (thumb_copy_bx_blx_reg): Likewise.
3618 (cleanup_alu_imm): Likewise.
3619 (arm_copy_alu_imm): Likewise.
3620 (thumb2_copy_alu_imm): Likewise.
3621 (cleanup_alu_reg): Likewise.
3622 (install_alu_reg): Likewise.
3623 (arm_copy_alu_reg): Likewise.
3624 (thumb_copy_alu_reg): Likewise.
3625 (cleanup_alu_shifted_reg): Likewise.
3626 (install_alu_shifted_reg): Likewise.
3627 (arm_copy_alu_shifted_reg): Likewise.
3628 (cleanup_load): Likewise.
3629 (cleanup_store): Likewise.
3630 (arm_copy_extra_ld_st): Likewise.
3631 (install_load_store): Likewise.
3632 (thumb2_copy_load_literal): Likewise.
3633 (thumb2_copy_load_reg_imm): Likewise.
3634 (arm_copy_ldr_str_ldrb_strb): Likewise.
3635 (cleanup_block_load_all): Likewise.
3636 (cleanup_block_store_pc): Likewise.
3637 (cleanup_block_load_pc): Likewise.
3638 (arm_copy_block_xfer): Likewise.
3639 (thumb2_copy_block_xfer): Likewise.
3640 (cleanup_svc): Likewise.
3641 (install_svc): Likewise.
3642 (arm_copy_svc): Likewise.
3643 (thumb_copy_svc): Likewise.
3644 (arm_copy_undef): Likewise.
3645 (thumb_32bit_copy_undef): Likewise.
3646 (arm_copy_unpred): Likewise.
3647 (arm_decode_misc_memhint_neon): Likewise.
3648 (arm_decode_unconditional): Likewise.
3649 (arm_decode_miscellaneous): Likewise.
3650 (arm_decode_dp_misc): Likewise.
3651 (arm_decode_ld_st_word_ubyte): Likewise.
3652 (arm_decode_media): Likewise.
3653 (arm_decode_b_bl_ldmstm): Likewise.
3654 (arm_decode_ext_reg_ld_st): Likewise.
3655 (thumb2_decode_dp_shift_reg): Likewise.
3656 (thumb2_decode_ext_reg_ld_st): Likewise.
3657 (arm_decode_svc_copro): Likewise.
3658 (thumb2_decode_svc_copro): Likewise.
3659 (install_pc_relative): Likewise.
3660 (thumb_copy_pc_relative_16bit): Likewise.
3661 (thumb_decode_pc_relative_16bit): Likewise.
3662 (thumb_copy_pc_relative_32bit): Likewise.
3663 (thumb_copy_16bit_ldr_literal): Likewise.
3664 (thumb_copy_cbnz_cbz): Likewise.
3665 (thumb2_copy_table_branch): Likewise.
3666 (cleanup_pop_pc_16bit_all): Likewise.
3667 (thumb_copy_pop_pc_16bit): Likewise.
3668 (thumb_process_displaced_16bit_insn): Likewise.
3669 (decode_thumb_32bit_ld_mem_hints): Likewise.
3670 (thumb_process_displaced_32bit_insn): Likewise.
3671 (thumb_process_displaced_insn): Likewise.
3672 (arm_process_displaced_insn): Likewise.
3673 (arm_displaced_init_closure): Likewise.
3674 (arm_displaced_step_fixup): Add cast for closure.
3675 * arm-tdep.h: Include infrun.h.
3676 (displaced_step_closure): Rename to ...
3677 (arm_displaced_step_closure): ... this, extend
3678 displaced_step_closure.
3679 <u::svc::copy_svc_os>: Change type of parameter DSC.
3680 <cleanup>: Likewise.
3681 (arm_process_displaced_insn): Likewise.
3682 (arm_displaced_init_closure): Likewise.
3683 (displaced_read_reg): Likewise.
3684 (displaced_write_reg): Likewise.
3685 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
3686 Adjust.
3687 * i386-tdep.h: Include infrun.h.
3688 (i386_displaced_step_closure): New typedef.
3689 * i386-tdep.c (i386_displaced_step_copy_insn): Use
3690 i386_displaced_step_closure.
3691 (i386_displaced_step_fixup): Adjust.
3692 * rs6000-tdep.c (ppc_displaced_step_closure): New typedef.
3693 (ppc_displaced_step_copy_insn): Use ppc_displaced_step_closure
3694 and unique_ptr.
3695 (ppc_displaced_step_fixup): Adjust.
3696 * s390-linux-tdep.c (s390_displaced_step_closure): New typedef.
3697 (s390_displaced_step_copy_insn): Use s390_displaced_step_closure
3698 and unique_ptr.
3699 (s390_displaced_step_fixup): Adjust.
3700
3701 2017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
3702
3703 * interps.h (interp_resume, interp_suspend, interp_set_temp):
3704 Remove declarations.
3705
3706 2017-10-20 Tom Tromey <tom@tromey.com>
3707
3708 * gdb_bfd.c (struct gdb_bfd_data) <included_bfds>: Now a
3709 std::vector.
3710 (gdb_bfd_record_inclusion): Update.
3711 (bfdp): Remove typedef.
3712
3713 2017-10-20 Tom Tromey <tom@tromey.com>
3714
3715 * gdb_bfd.c (gdb_bfd_ref): Use new.
3716 (struct gdb_bfd_data): Add constructor, destructor, and member
3717 initializers.
3718 (gdb_bfd_unref): Use delete.
3719
3720 2017-10-20 Tom Tromey <tom@tromey.com>
3721
3722 * exec.c (exec_file_attach): Use new_bfd_ref.
3723 * symfile-mem.c (symbol_file_add_from_memory): Use new_bfd_ref.
3724 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
3725 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_fdopenr): Use
3726 new_bfd_ref.
3727 * gdb_bfd.h (new_bfd_ref): New function.
3728
3729 2017-10-20 Pedro Alves <palves@redhat.com>
3730
3731 * main.c (captured_command_loop): Add attribute noinline.
3732
3733 2017-10-19 Simon Marchi <simon.marchi@ericsson.com>
3734
3735 * interps.c (struct interp_factory): Add constructor.
3736 (interp_factory_p): Remove typedef.
3737 (DEF_VEC_P(interp_factory_p)): Remove.
3738 (interpreter_factories): Change type to std::vector.
3739 (interp_factory_register): Adjust.
3740 (interp_lookup): Adjust.
3741 (interpreter_completer): Adjust.
3742
3743 2017-10-19 Tom Tromey <tom@tromey.com>
3744
3745 * break-catch-syscall.c (catch_syscall_completer): Use
3746 std::string, gdb::unique_xmalloc_ptr.
3747
3748 2017-10-19 Tom Tromey <tom@tromey.com>
3749
3750 * infcall.c (call_function_by_hand_dummy): Use std::string.
3751
3752 2017-10-19 Tom Tromey <tom@tromey.com>
3753
3754 * mi/mi-main.c (mi_cmd_execute): Update.
3755 * top.h (prepare_execute_command): Return scoped_value_mark.
3756 * value.h (class scoped_value_mark): Use DISABLE_COPY_AND_ASSIGN.
3757 Add move constructor.
3758 * top.c (prepare_execute_command): Return scoped_value_mark.
3759 (execute_command): Update.
3760
3761 2017-10-19 Pedro Alves <palves@redhat.com>
3762
3763 * xml-support.c (xml_fetch_content_from_file): Check fread's
3764 return.
3765
3766 2017-10-19 Pedro Alves <palves@redhat.com>
3767
3768 * ser-base.c (ser_base_read_error_fd): Delete the file handler if
3769 async.
3770 (handle_error_fd): New function.
3771 (ser_base_async): Add/delete an event loop file handler for
3772 error_fd.
3773
3774 2017-10-19 Pedro Alves <palves@redhat.com>
3775
3776 * xml-support.c (xml_fetch_content_from_file): Don't read in
3777 chunks. Instead use fseek to determine the file's size, and read
3778 it in one go.
3779
3780 2017-11-18 Keith Seitz <keiths@redhat.com>
3781
3782 * c-exp.y (oper): Canonicalize conversion operators of user-defined
3783 types.
3784 Add whitespace to front of type name.
3785
3786 2017-10-18 Keith Seitz <keiths@redhat.com>
3787
3788 * dwarf2read.c (dwarf2_add_typedef): Issue a complaint on unhandled
3789 DW_AT_accessibility.
3790
3791 2017-10-18 Yao Qi <yao.qi@linaro.org>
3792
3793 * features/tic6x-c62x-linux.c: Remove.
3794
3795 2017-10-17 Tom Tromey <tom@tromey.com>
3796
3797 * disasm.c (do_mixed_source_and_assembly_deprecated): Use
3798 gdb::optional, ui_out_emit_list, ui_out_emit_tuple.
3799 (do_mixed_source_and_assembly): Likewise.
3800
3801 2017-10-17 Tom Tromey <tom@tromey.com>
3802
3803 * regcache.c (regcache::xfer_part): Remove assertion.
3804
3805 2017-10-17 Pedro Alves <palves@redhat.com>
3806
3807 * xml-support.c (xml_fetch_content_from_file): Call
3808 unique_ptr::release() instead unique_ptr::get() when passing
3809 through xrealloc.
3810
3811 2017-10-17 Yao Qi <yao.qi@linaro.org>
3812
3813 * regcache.c (regcache::xfer_part): Remove parameters read and
3814 write, add parameter is_raw. All callers are updated.
3815
3816 2017-10-16 Keith Seitz <keiths@redhat.com>
3817
3818 * c-typeprint.c (enum access_specifier): Moved here from
3819 c_type_print_base.
3820 (output_access_specifier): New function.
3821 (c_type_print_base): Consider typedefs when assessing
3822 whether access labels are needed.
3823 Use output_access_specifier as needed.
3824 Output access specifier for typedefs, if needed.
3825 * dwarf2read.c (dwarf2_add_typedef): Record DW_AT_accessibility.
3826 * gdbtypes.h (struct typedef_field) <is_protected, is_private>: New
3827 fields.
3828 (TYPE_TYPEDEF_FIELD_PROTECTED, TYPE_TYPEDEF_FIELD_PRIVATE): New
3829 accessor macros.
3830
3831 2017-10-16 Tom Tromey <tom@tromey.com>
3832
3833 * linux-tdep.c (linux_info_proc, linux_find_memory_regions_full)
3834 (linux_fill_prpsinfo, linux_vsyscall_range_raw): Update.
3835 * target.c (target_fileio_read_stralloc): Update.
3836 * sparc64-tdep.c (adi_is_addr_mapped): Update.
3837 * target.h (target_fileio_read_stralloc): Return
3838 unique_xmalloc_ptr.
3839
3840 2017-10-16 Tom Tromey <tom@tromey.com>
3841
3842 * xml-syscall.c (xml_init_syscalls_info): Update.
3843 * xml-support.c (xinclude_start_include): Update.
3844 (xml_fetch_content_from_file): Return unique_xmalloc_ptr.
3845 * xml-support.h (xml_fetch_another): Return unique_xmalloc_ptr.
3846 (xml_fetch_content_from_file): Likewise.
3847 * osdata.c (get_osdata): Update.
3848 * target.h (target_read_stralloc, target_get_osdata): Return
3849 unique_xmalloc_ptr.
3850 * solib-aix.c (solib_aix_get_library_list): Update.
3851 * solib-target.c (solib_target_current_sos): Update.
3852 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Update.
3853 * xml-tdesc.c (fetch_available_features_from_target): Update.
3854 (target_fetch_description_xml): Update.
3855 (file_read_description_xml): Update.
3856 * remote.c (remote_get_threads_with_qxfer, remote_memory_map)
3857 (remote_traceframe_info, btrace_read_config, remote_read_btrace)
3858 (remote_pid_to_exec_file): Update.
3859 * target.c (target_read_stralloc): Return unique_xmalloc_ptr.
3860 (target_get_osdata): Likewise.
3861
3862 2017-10-16 Tom Tromey <tom@tromey.com>
3863
3864 * remote.c (remote_register_number_and_offset): Use std::vector.
3865 (remote_set_syscall_catchpoint): Use gdb::unique_xmalloc_ptr.
3866 (putpkt_binary): Use gdb::def_vector.
3867 (compare_sections_command): Use gdb::byte_vector.
3868
3869 2017-10-16 Tom Tromey <tom@tromey.com>
3870
3871 * ppc-linux-nat.c (hwdebug_insert_point): Use
3872 gdb::unique_xmalloc_ptr, XDUP.
3873
3874 2017-10-16 Tom Tromey <tom@tromey.com>
3875
3876 * probe.c (parse_probes): Use std::string.
3877 (info_probes_for_ops, enable_probes_command)
3878 (disable_probes_command): Remove cleanups.
3879
3880 2017-10-16 Tom Tromey <tom@tromey.com>
3881
3882 * buildsym.c (block_compar): Remove.
3883 (end_symtab_get_static_block): Use std::vector.
3884
3885 2017-10-16 Simon Marchi <simon.marchi@ericsson.com>
3886
3887 * memrange.h (struct mem_range): Define operator< and operator==.
3888 (mem_range_s): Remove.
3889 (DEF_VEC_O (mem_range_s)): Remove.
3890 (normalize_mem_ranges): Change parameter type to std::vector.
3891 * memrange.c (compare_mem_ranges): Remove.
3892 (normalize_mem_ranges): Change parameter type to std::vector,
3893 adjust to vector change.
3894 * exec.c (section_table_available_memory): Return vector, remove
3895 parameter.
3896 (section_table_read_available_memory): Adjust to std::vector
3897 change.
3898 * remote.c (remote_read_bytes): Adjust to std::vector
3899 change.
3900 * tracepoint.h (traceframe_available_memory): Change parameter
3901 type to std::vector.
3902 * tracepoint.c (traceframe_available_memory): Change parameter
3903 type to std::vector, adjust.
3904 * gdb/mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to
3905 std::vector change.
3906 * gdb/Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3907 unittests/memrange-selftests.c.
3908 (SUBDIR_UNITTESTS_OBS): Add memrange-selftests.o.
3909 * gdb/unittests/memrange-selftests.c: New file.
3910
3911 2017-10-16 Pedro Alves <palves@redhat.com>
3912
3913 * elfread.c (probe_key_free): Rename range-for variable.
3914 * probe.c (parse_probes_in_pspace, find_probes_in_objfile)
3915 (find_probe_by_pc, collect_probes): Rename range-for variable.
3916
3917 2017-10-16 Yao Qi <yao.qi@linaro.org>
3918
3919 * features/Makefile (XMLTOC): Remove tic6x-*.xml.
3920 * features/tic6x-c62x.c: Remove.
3921 * features/tic6x-c64x-linux.c: Remove.
3922 * features/tic6x-c64x.c: Remove.
3923 * features/tic6x-c64xp-linux.c: Remove.
3924 * features/tic6x-c64xp.c: Remove.
3925 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Don't call
3926 initialize_tdesc_tic6x_*_linux functions.
3927 * tic6x-tdep.c (_initialize_tic6x_tdep): Don't call
3928 initialize_tdesc_tic6x_* functions.
3929
3930 2017-10-16 Yao Qi <yao.qi@linaro.org>
3931
3932 * features/Makefile (WHICH): Remove tic6x-c64xp, tic6x-c64x
3933 tic6x-c62x.
3934 * regformats/tic6x-c62x.dat: Remove.
3935 * regformats/tic6x-c64x.dat: Remove.
3936 * regformats/tic6x-c64xp.dat: Remove.
3937
3938 2017-10-15 Simon Marchi <simon.marchi@ericsson.com>
3939
3940 * tracepoint.c (parse_traceframe_info): Return a unique_ptr
3941 (the !HAVE_LIBEXPAT version).
3942
3943 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
3944
3945 * nat/linux-osdata.c (struct pid_pgid_entry) <operator<>: Make
3946 const.
3947
3948 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3949
3950 * target.h: Include tracepoint.h.
3951 (enum trace_find_type): Move to tracepoint.h.
3952 (struct target_ops) <to_traceframe_info>: Return a unique ptr.
3953 * tracepoint.h: Don't include target.h
3954 (enum trace_find_type): Move from target.h.
3955 (parse_traceframe_info): Return a unique ptr.
3956 * tracepoint.c (current_traceframe_info): Change type to unique
3957 ptr.
3958 (free_traceframe_info): Remove.
3959 (clear_traceframe_info): Don't manually free
3960 current_traceframe_info.
3961 (free_result): Remove.
3962 (parse_traceframe_info): Return a unique ptr.
3963 (get_traceframe_info): Adjust to unique ptr.
3964 * ctf.c (ctf_traceframe_info): Return a unique ptr.
3965 * remote.c (remote_traceframe_info): Return a unique ptr.
3966 * tracefile-tfile.c (tfile_traceframe_info): Return a unique
3967 ptr.
3968 * target-debug.h (target_debug_print_traceframe_info_up): New
3969 macro.
3970 * target-delegates.c: Regenerate.
3971
3972 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3973
3974 * memrange.h (struct mem_range): Add constructors.
3975 * tracepoint.h (struct traceframe_info) <memory>: Change type to
3976 std::vector<mem_range>.
3977 * tracepoint.c (free_traceframe_info): Don't manually free
3978 vector.
3979 (traceframe_info_start_memory): Adjust to vector change.
3980 (traceframe_available_memory): Likewise.
3981 * tracefile-tfile.c (build_traceframe_info): Likewise.
3982 * ctf.c (ctf_traceframe_info): Likewise.
3983
3984 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3985
3986 * tracepoint.h (struct traceframe_info) <tvars>: Change type to
3987 std::vector<int>.
3988 * tracepoint.c (free_traceframe_info): Deallocate with delete.
3989 (traceframe_info_start_tvar): Adjust to vector change.
3990 (parse_traceframe_info): Allocate with new.
3991 * ctf.c (ctf_traceframe_info): Allocate with new, adjust to
3992 vector change.
3993 * tracefile-tfile.c (build_traceframe_info): Adjust to vector
3994 change.
3995 tfile_traceframe_info): Allocate with new.
3996 * mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to vector
3997 change.
3998
3999 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4000
4001 * tracepoint.c (traceframe_info): Rename to...
4002 (current_traceframe_info): ...this.
4003 (clear_traceframe_info): Adjust.
4004 (get_traceframe_info): Adjust.
4005
4006 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
4007
4008 * nat/linux-osdata.c: Include algorithm.
4009 (compare_processes): Remove.
4010 (struct pid_pgid_entry): New struct.
4011 (linux_xfer_osdata_processgroups): Use std::vector instead of
4012 XNEWVEC.
4013
4014 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
4015
4016 * objfiles.h: Don't include symfile.h.
4017 (struct partial_symbol): Remove forward-declaration.
4018 (struct objfile) <global_psymbols, static_psymbols>: Change type
4019 to std::vector<partial_symbol *>.
4020 * objfiles.c (objfile::objfile): Don't memset those fields.
4021 (objfile::~objfile): Don't free those fields.
4022 * psympriv.h (struct psymbol_allocation_list): Remove
4023 forward-declaration.
4024 (add_psymbol_to_list): Change psymbol_allocation_list parameter
4025 to std::vector.
4026 (start_psymtab_common): Change parameters to std::vector.
4027 * psymtab.c: Include algorithm.
4028 (require_partial_symbols): Call shrink_to_fit.
4029 (find_pc_sect_psymbol): Adjust to vector change.
4030 (match_partial_symbol): Likewise.
4031 (lookup_partial_symbol): Likewise.
4032 (psym_relocate): Likewise.
4033 (dump_psymtab): Likewise.
4034 (recursively_search_psymtabs): Likewise.
4035 (compare_psymbols): Remove.
4036 (sort_pst_symbols): Adjust to vector change.
4037 (start_psymtab_common): Likewise.
4038 (end_psymtab_common): Likewise.
4039 (psymbol_bcache_full): De-constify return value.
4040 (add_psymbol_to_bcache): Likewise.
4041 (extend_psymbol_list): Remove.
4042 (append_psymbol_to_list): Adjust to vector change.
4043 (add_psymbol_to_list): Likewise.
4044 (init_psymbol_list): Likewise.
4045 (maintenance_info_psymtabs): Likewise.
4046 (maintenance_check_psymtabs): Likewise.
4047 * symfile.h (struct psymbol_allocation_list): Remove.
4048 * symfile.c (reread_symbols): Adjust to vector change.
4049 * dbxread.c (start_psymtab): Change type of parameters.
4050 (dbx_symfile_read): Adjust to vector change.
4051 (read_dbx_symtab): Likewise.
4052 (start_psymtab): Change type of parameters.
4053 * dwarf2read.c (dwarf2_build_psymtabs): Adjust to vector change.
4054 (create_partial_symtab): Likewise.
4055 (add_partial_symbol): Likewise.
4056 (write_one_signatured_type): Likewise.
4057 (recursively_write_psymbols): Likewise.
4058 * mdebugread.c (parse_partial_symbols): Likewise.
4059 * xcoffread.c (xcoff_start_psymtab): Change type of parameters.
4060 (scan_xcoff_symtab): Adjust to vector change.
4061 (xcoff_initial_scan): Likewise.
4062
4063 2017-10-13 Simon Marchi <simon.marchi@ericsson.com>
4064
4065 * ada-typeprint.c (print_dynamic_range_bound): Use std::string.
4066
4067 2017-10-13 Yao Qi <yao.qi@linaro.org>
4068
4069 * features/Makefile: Remove tic6x-*-expedite, add tic6x-expedite.
4070 Remove s390x-*-expedite, add s390x-expedite.
4071
4072 2017-10-13 Yao Qi <yao.qi@linaro.org>
4073
4074 * features/s390-gs-linux64.c: Regenerated.
4075 * features/s390x-gs-linux64.c: Regenerated.
4076
4077 2017-10-13 Tom Tromey <tom@tromey.com>
4078
4079 * compile/compile-object-run.c (do_module_cleanup): Use delete.
4080 * solib.c (update_solib_list, reload_shared_libraries_1): Use
4081 delete.
4082 * symfile.c (symbol_file_add_with_addrs): Use new.
4083 (symbol_file_add_separate): Update comment.
4084 (syms_from_objfile_1, remove_symbol_file_command): Use delete.
4085 * jit.c (jit_object_close_impl): Use new.
4086 (jit_unregister_code): Use delete.
4087 * objfiles.c (objfile::objfile): Rename from allocate_objfile.
4088 (~objfile): Rename from free_objfile.
4089 (free_objfile_separate_debug, do_free_objfile_cleanup)
4090 (free_all_objfiles, objfile_purge_solibs): Use delete.
4091 * objfiles.h (struct objfile): Add constructor and destructor.
4092 Use DISABLE_COPY_AND_ASSIGN. Add initializers to data members.
4093 (allocate_objfile, free_objfile): Don't declare.
4094 (struct objstats): Add initializers.
4095
4096 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
4097
4098 * arch-utils.h (simple_displaced_step_copy_insn): Remove.
4099 * arch-utils.c (simple_displaced_step_copy_insn): Remove.
4100 * gdbarch.sh (displaced_step_copy_insn): Adjust comment.
4101 * gdbarch.h: Regenerate.
4102 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
4103 Adjust comment.
4104 * i386-tdep.c (i386_displaced_step_copy_insn): Adjust comment.
4105 (i386_displaced_step_fixup): Adjust comment.
4106 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Adjust comment.
4107
4108 2017-10-12 Tom Tromey <tom@tromey.com>
4109
4110 * prologue-value.h (pv_area::store_would_trash): Return bool.
4111 (pv_area::find_reg): Likewise.
4112 * prologue-value.c (pv_area::store_would_trash): Return bool.
4113 (pv_area::find_reg): Likewise.
4114
4115 2017-10-12 Tom Tromey <tom@tromey.com>
4116
4117 * s390-linux-tdep.c (s390_store, s390_load)
4118 (s390_check_for_saved, s390_analyze_prologue): Update.
4119 * rx-tdep.c (check_for_saved, rx_analyze_prologue): Update.
4120 * rl78-tdep.c (rl78_analyze_prologue, check_for_saved): Update.
4121 * prologue-value.h (class pv_area): Move from prologue-value.c.
4122 Change names of members. Add constructor, destructor, member
4123 functions.
4124 (make_pv_area, free_pv_area, make_cleanup_free_pv_area)
4125 (pv_area_store, pv_area_fetch, pv_area_store_would_trash)
4126 (pv_area_fetch, pv_area_scan): Don't declare.
4127 * prologue-value.c (struct pv_area::area_entry): Now member of
4128 pv_area.
4129 (struct pv_area): Move to prologue-value.h.
4130 (pv_area::pv_area): Rename from make_pv_area.
4131 (pv_area::~pv_area): Rename from free_pv_area.
4132 (do_free_pv_area_cleanup, make_cleanup_free_pv_area): Remove.
4133 (clear_entries, find_entry, overlaps, store_would_trash, store)
4134 (fetch, find_reg, scan): Now member of pv_area.
4135 Remove "area" argument. Update.
4136 * msp430-tdep.c (check_for_saved, msp430_analyze_prologue):
4137 Update.
4138 * mn10300-tdep.c (push_reg, check_for_saved)
4139 (mn10300_analyze_prologue): Update.
4140 * mep-tdep.c (is_arg_spill, check_for_saved)
4141 (mep_analyze_prologue): Update.
4142 * m32c-tdep.c (m32c_pv_push, m32c_srcdest_fetch)
4143 (m32c_srcdest_store, m32c_pv_enter, m32c_is_arg_spill)
4144 (m32c_is_struct_return, m32c_analyze_prologue): Update.
4145 * arm-tdep.c (thumb_analyze_prologue, arm_analyze_prologue):
4146 Update.
4147 * arc-tdep.c (arc_is_in_prologue, arc_analyze_prologue): Update.
4148 * aarch64-tdep.c (aarch64_analyze_prologue): Update.
4149
4150 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
4151
4152 * linux-nat.h (linux_nat_set_delete_thread): New declaration.
4153 * linux-nat.c (linux_nat_delete_thread): New variable.
4154 (lwp_free): Invoke linux_nat_delete_thread if set.
4155 (linux_nat_set_delete_thread): New function.
4156 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Assign
4157 thread delete callback.
4158 * arm-linux-nat.c (arm_linux_delete_thread): New function.
4159 (_initialize_arm_linux_nat): Assign thread delete callback.
4160 * s390-linux-nat.c (s390_delete_thread): New function.
4161 (_initialize_s390_nat): Assign thread delete callback.
4162 * x86-linux-nat.c (x86_linux_add_target): Likewise.
4163 * nat/aarch64-linux.c (aarch64_linux_delete_thread): New
4164 function.
4165 * nat/aarch64-linux.h (aarch64_linux_delete_thread): New
4166 declaration.
4167 * nat/x86-linux.c (x86_linux_delete_thread): New function.
4168 * nat/x86-linux.h (x86_linux_delete_thread): New declaration.
4169
4170 2017-10-09 Tom Tromey <tom@tromey.com>
4171
4172 * tui/tui-win.c (tui_set_win_height, parse_scrolling_args): Use
4173 std::string.
4174 * tui/tui-layout.c (enum tui_status): Use std::string.
4175
4176 2017-10-11 Tom Tromey <tom@tromey.com>
4177
4178 * gdbthread.h (thread_command): Constify.
4179 * inferior.h (detach_command): Constify.
4180 * top.h (set_history, show_history): Constify.
4181 * arm-tdep.c (set_arm_command, show_arm_command): Constify.
4182 * serial.c (serial_set_cmd, serial_show_cmd): Constify.
4183 * bsd-kvm.c (bsd_kvm_cmd): Constify.
4184 * printcmd.c (set_command): Constify.
4185 (non_const_set_command): New function.
4186 * dcache.c (set_dcache_command, show_dcache_command): Constify.
4187 * breakpoint.c (enable_command, disable_command, delete_command)
4188 (catch_command, tcatch_command, set_breakpoint_cmd)
4189 (show_breakpoint_cmd): Constify.
4190 * macrocmd.c (macro_command): Constify.
4191 * infcmd.c (unset_command, kill_command, detach_command)
4192 (info_proc_cmd): Constify.
4193 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Constify.
4194 * auto-load.c (show_auto_load_cmd, set_auto_load_cmd)
4195 (info_auto_load_cmd): Constify.
4196 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
4197 (unset_tdesc_cmd): Constify.
4198 * ada-lang.c (set_ada_command, show_ada_command)
4199 (maint_set_ada_cmd, maint_show_ada_cmd): Constify.
4200 * guile/guile.c (set_guile_command, show_guile_command)
4201 (info_guile_command): Constify.
4202 * tui/tui-win.c (tui_command, set_tui_cmd, show_tui_cmd):
4203 Constify.
4204 * skip.c (skip_command): Constify.
4205 * compile/compile.c (_initialize_compile): Constify.
4206 * dwarf2read.c (set_dwarf_cmd, show_dwarf_cmd): Constify.
4207 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
4208 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
4209 (maint_btrace_pt_show_cmd): Constify.
4210 * remote.c (set_remote_cmd, show_remote_cmd, remote_command):
4211 Constify.
4212 * python/python.c (user_show_python, user_set_python): Constify.
4213 * mips-tdep.c (set_mips_command, show_mips_command)
4214 (set_mipsfpu_command): Constify.
4215 * record-btrace.c (cmd_record_btrace_start)
4216 (cmd_set_record_btrace, cmd_show_record_btrace)
4217 (cmd_set_record_btrace_bts, cmd_show_record_btrace_bts)
4218 (cmd_set_record_btrace_pt, cmd_show_record_btrace_pt): Constify.
4219 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command):
4220 Constify.
4221 * symfile.c (overlay_command): Constify.
4222 * spu-tdep.c (set_spu_command, show_spu_command): Constify.
4223 * cli/cli-logging.c (set_logging_command, show_logging_command):
4224 Constify.
4225 * cli/cli-dump.c (dump_command, append_command)
4226 (srec_dump_command, ihex_dump_command, verilog_dump_command)
4227 (tekhex_dump_command, binary_dump_command)
4228 (binary_append_command): Constify.
4229 * cli/cli-decode.c (struct cmd_list_element): Change type of
4230 "fun".
4231 * cli/cli-cmds.c (info_command, show_command, set_debug)
4232 (show_debug): Constify.
4233 (show_command): Add non-const overload.
4234 * top.c (set_history, show_history): Constify.
4235 * sh-tdep.c (set_sh_command, show_sh_command): Constify.
4236 * command.h (add_prefix_cmd): Accept a cmd_const_cfunc_ftype.
4237 * target.c (target_command): Constify.
4238 * sparc64-tdep.c (info_adi_command): Constify.
4239 * record-full.c (cmd_record_full_start): Constify.
4240 (set_record_full_command): Constify. Fix typo.
4241 (show_record_full_command): Constify.
4242 * thread.c (thread_command, thread_apply_command): Constify.
4243 * memattr.c (dummy_cmd): Constify.
4244 * value.c (function_command): Constify.
4245 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Constify.
4246 * probe.c (info_probes_command): Constify.
4247 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Constify.
4248 * gnu-nat.c (set_task_cmd, show_task_cmd, set_thread_cmd)
4249 (show_thread_cmd, set_thread_default_cmd)
4250 (show_thread_default_cmd): Constify.
4251 (check_empty): Constify.
4252 * tracepoint.c (tfind_command): Constify.
4253 * cp-support.c (maint_cplus_command): Constify.
4254 * windows-tdep.c (info_w32_command): Constify.
4255 * record.c (cmd_record_start, set_record_command)
4256 (show_record_command, info_record_command, cmd_record_goto):
4257 Constify.
4258 * ravenscar-thread.c (set_ravenscar_command)
4259 (show_ravenscar_command): Constify.
4260 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
4261 Constify.
4262 (add_internal_problem_command): Remove casts.
4263 * arc-tdep.c (maintenance_print_arc_command): Constify.
4264 * valprint.c (set_print, show_print, set_print_raw)
4265 (show_print_raw): Constify.
4266 * maint.c (maintenance_command, maintenance_info_command)
4267 (maintenance_print_command, maintenance_set_cmd)
4268 (maintenance_show_cmd, set_per_command_cmd)
4269 (show_per_command_cmd, maintenance_check_command): Constify.
4270 * language.c (set_check, show_check): Constify.
4271 * typeprint.c (show_print_type, set_print_type): Constify.
4272 * go32-nat.c (go32_info_dos_command): Constify.
4273
4274 2017-10-11 Tom Tromey <tom@tromey.com>
4275
4276 * breakpoint.c (prepare_re_set_context): Remove.
4277 (breakpoint_re_set_one): Update. Don't use cleanups.
4278 (breakpoint_re_set): Use scoped_restore, std::string, and
4279 scoped_restore_current_language.
4280
4281 2017-10-11 Tom Tromey <tom@tromey.com>
4282
4283 * breakpoint.c (commands_command_1): Use std::string.
4284 (cleanup_executing_breakpoints): Remove.
4285 (bpstat_do_actions_1): Use scoped_restore.
4286 (bpstat_check_watchpoint): Use std::string.
4287 (decode_static_tracepoint_spec): Likewise.
4288 (break_range_command): Likewise.
4289 (watch_command_1): Likewise.
4290 (compare_breakpoints): Change argument types.
4291 (clear_command): Use std::vector.
4292 (cleanup_executing_breakpoints): Remove.
4293 (update_global_location_list): Use unique_xmalloc_ptr.
4294 (strace_command): Remove unused declaration.
4295
4296 2017-10-11 John Baldwin <jhb@FreeBSD.org>
4297
4298 * Makefile.in (ALLDEPFILES): Add arm-fbsd-nat.c.
4299 * NEWS: Mention new FreeBSD/arm native configuration.
4300 * configure.host: Add arm*-*-freebsd*.
4301 * configure.nat: Likewise.
4302 * arm-fbsd-nat.c: New file.
4303
4304 2017-10-11 John Baldwin <jhb@FreeBSD.org>
4305
4306 * Makefile.in (ALL_TARGET_OBS): Add arm-fbsd-tdep.o.
4307 (ALLDEPFILES): Add arm-fbsd-tdep.c.
4308 * NEWS: Mention new FreeBSD/arm target.
4309 * configure.tgt: Add arm*-*-freebsd*.
4310 * arm-fbsd-tdep.c: New file.
4311 * arm-fbsd-tdep.h: New file.
4312
4313 2017-10-11 Maciej W. Rozycki <macro@imgtec.com>
4314
4315 * linux-tdep.c (linux_make_corefile_notes): Remove call to
4316 `gdbarch_elfcore_write_linux_prpsinfo'.
4317 * gdbarch.sh (elfcore_write_linux_prpsinfo): Remove architecture
4318 method.
4319 (elf_internal_linux_prpsinfo): Remove declaration.
4320 * gdbarch.h: Regenerate.
4321 * gdbarch.c: Regenerate.
4322
4323 2017-10-11 Maciej W. Rozycki <macro@imgtec.com>
4324
4325 * ppc-linux-tdep.c (ppc_linux_init_abi): Remove call to
4326 `set_gdbarch_elfcore_write_linux_prpsinfo'.
4327
4328 2017-10-11 Pedro Alves <palves@redhat.com>
4329
4330 * breakpoint.c (reattach_breakpoints): Delete.
4331 * breakpoint.h (reattach_breakpoints): Delete.
4332
4333 2017-10-11 Simon Marchi <simon.marchi@ericsson.com>
4334
4335 * symfile.c (registered_sym_fns): Make struct, not typedef.
4336 (DEF_VEC_O (registered_sym_fns)): Remove.
4337 (symtab_fns): Change type to std::vector.
4338 (add_symtab_fns): Adjust.
4339 (find_sym_fns): Adjust.
4340
4341 2017-10-11 Anton Kolesov <Anton.Kolesov@synopsys.com>
4342
4343 * arc-tdep.c (arc_gdbarch_init): Pass proper cpu value to disassembler.
4344 * arc-tdep.h (arc_arch_is_em): New function.
4345 (arc_arch_is_hs): Likewise.
4346
4347 2017-10-11 Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
4348
4349 * macrotab.h (macro_lookup_inclusion): Remove unnecessary
4350 parentheses in the declaration.
4351 (macro_lookup_inclusion): Likewise.
4352 (macro_lookup_definition): Likewise.
4353 * p-lang.h (pascal_builtin_types): Likewise.
4354 * tui/tui-data.c (tui_win_list): Likewise.
4355 * tui/tui-data.h (tui_win_list): Likewise.
4356 * utils.h (make_cleanup_free_section_addr_info): Likewise.
4357
4358 2017-10-11 Mark Rages <markrages@gmail.com>
4359
4360 * target-memory.c (block_boundaries): Fix for block address not
4361 aligned on block size.
4362
4363 2017-10-10 Pedro Alves <palves@redhat.com>
4364 Tom Tromey <tom@tromey.com>
4365
4366 * breakpoint.c (struct captured_breakpoint_query_args)
4367 (do_captured_breakpoint_query, gdb_breakpoint_query): Delete.
4368 (print_breakpoint): New.
4369 * breakpoint.h (print_breakpoint): Declare.
4370 * common/common-exceptions.h (enum return_reason): Remove
4371 references to catch_exceptions.
4372 * exceptions.c (catch_exceptions, catch_exceptions_with_msg):
4373 Delete.
4374 * exceptions.h (catch_exceptions_ftype, catch_exceptions)
4375 (catch_exception_ftype, catch_exceptions_with_msg): Delete.
4376 * gdb.h: Delete.
4377 * gdbthread.h (thread_select): Declare.
4378 * mi/mi-cmd-break.c: Don't include gdb.h.
4379 (breakpoint_notify): Use print_breakpoint.
4380 * mi/mi-cmd-catch.c: Don't include gdb.h.
4381 * mi/mi-interp.c: Don't include gdb.h.
4382 (mi_print_breakpoint_for_event): New.
4383 (mi_breakpoint_created, mi_breakpoint_modified): Use
4384 mi_print_breakpoint_for_event.
4385 * mi/mi-main.c: Don't include gdb.h.
4386 (mi_cmd_thread_select): Parse the global thread ID here. Use
4387 thread_select instead of gdb_thread_select.
4388 (mi_cmd_thread_list_ids): Output "thread-ids" tuple here instead
4389 of using gdb_list_thread_ids.
4390 * remote-fileio.c (do_remote_fileio_request): Change type. Reply
4391 FILEIO_ENOSYS here.
4392 (remote_fileio_request): Use TRY/CATCH instead of
4393 catch_exceptions.
4394 * symfile-mem.c (struct symbol_file_add_from_memory_args)
4395 (symbol_file_add_from_memory_wrapper): Delete.
4396 (add_vsyscall_page): Use TRY/CATCH instead of catch_exceptions.
4397 * thread.c: Don't include gdb.h.
4398 (do_captured_list_thread_ids, gdb_list_thread_ids): Delete.
4399 (thread_alive): Use thread_select.
4400 (do_captured_thread_select): Delete, parts salvaged as ...
4401 (thread_select): ... this new function.
4402 (gdb_thread_select): Delete.
4403
4404 2017-10-10 Pedro Alves <palves@redhat.com>
4405 Tom Tromey <tom@tromey.com>
4406
4407 * breakpoint.c (breakpoint_cond_eval): Change return type to bool
4408 and reverse logic.
4409 (WP_DELETED, WP_VALUE_CHANGED, WP_VALUE_NOT_CHANGED, WP_IGNORE):
4410 No longer macros. Instead ...
4411 (enum wp_check_result): They're now values of this new
4412 enumeration.
4413 (watchpoint_check): Change return type to wp_check_result and
4414 parameter type to bpstat.
4415 (bpstat_check_watchpoint): Use TRY/CATCH instead of catch_errors.
4416 (bpstat_check_breakpoint_conditions): Use TRY/CATCH instead of
4417 catch_errors. Reverse logic of watchpoint_check call.
4418 (breakpoint_re_set_one): Now returns void and takes a breakpoint
4419 pointer as parameter.
4420 (breakpoint_re_set): Use TRY/CATCH instead of catch_errors.
4421 * common/common-exceptions.c (throw_exception_sjlj): Update
4422 comments to avoid mentioning catch_errors.
4423 * exceptions.c (catch_errors): Delete.
4424 * exceptions.h: Update comments to avoid mentioning catch_errors.
4425 (catch_errors_ftype, catch_errors): Delete.
4426 * infrun.c (normal_stop): Use TRY/CATCH instead of catch_errors.
4427 (hook_stop_stub): Delete.
4428 (restore_selected_frame): Change return type to void, and
4429 parameter type to const frame_id &.
4430 (restore_infcall_control_state): Use TRY/CATCH instead of
4431 catch_errors.
4432 * main.c (captured_command_loop): Return void and remove
4433 parameter. Remove references to catch_errors.
4434 (captured_main): Use TRY/CATCH instead of catch_errors.
4435 * objc-lang.c (objc_submethod_helper_data)
4436 (find_objc_msgcall_submethod_helper): Delete.
4437 (find_objc_msgcall_submethod): Use TRY/CATCH instead of
4438 catch_errors.
4439 * record-full.c (record_full_message): Return void.
4440 (record_full_message_args, record_full_message_wrapper): Delete.
4441 (record_full_message_wrapper_safe): Return bool and use TRY/CATCH
4442 instead of catch_errors.
4443 * solib-aix.c (solib_aix_open_symbol_file_object): Change
4444 parameter type to int.
4445 * solib-darwin.c (open_symbol_file_object): Ditto.
4446 * solib-dsbt.c (open_symbol_file_object): Ditto.
4447 * solib-frv.c (open_symbol_file_object): Ditto.
4448 * solib-svr4.c (open_symbol_file_object): Ditto.
4449 * solib-target.c (solib_target_open_symbol_file_object): Ditto.
4450 * solib.c (update_solib_list): Use TRY/CATCH instead of
4451 catch_errors.
4452 * solist.h (struct target_so_ops) <open_symbol_file_object>:
4453 Change type.
4454 * symmisc.c (struct print_symbol_args): Remove.
4455 (dump_symtab_1): Use TRY/CATCH instead of catch_errors.
4456 (print_symbol): Change type.
4457 * windows-nat.c (handle_load_dll, handle_unload_dll): Return void
4458 and remove parameters.
4459 (catch_errors): New.
4460 (get_windows_debug_event): Adjust.
4461
4462 2017-10-09 Tom Tromey <tom@tromey.com>
4463
4464 * mi/mi-main.c (free_splay_tree): Remove.
4465 (list_available_thread_groups): Use splay_tree_up.
4466 * common/gdb_splay_tree.h: New file.
4467
4468 2017-10-09 Tom Tromey <tom@tromey.com>
4469
4470 * mi/mi-main.c (do_nothing): Remove.
4471 (list_available_thread_groups): Update.
4472
4473 2017-10-09 Pedro Alves <palves@redhat.com>
4474
4475 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>: Skip
4476 reading registers when switching context.
4477
4478 2017-10-09 John Baldwin <jhb@FreeBSD.org>
4479
4480 * fbsd-nat.c (fbsd_siginfo_size): Use gdbarch_long_bit.
4481 (fbsd_convert_siginfo): Likewise.
4482 * fbsd-tdep.c (fbsd_core_xfer_siginfo): Likewise.
4483
4484 2017-10-09 Simon Marchi <simon.marchi@polymtl.ca>
4485
4486 * configure.ac (try_guile_versions): Remove guile-2.2.
4487 * configure: Regenerate.
4488
4489 2017-10-09 Tom Tromey <tom@tromey.com>
4490
4491 * Makefile.in (COMPILE.post, POSTCOMPILE): Restore $(basename).
4492 (COMPILE.pre): Use $(CXX).
4493
4494 2017-10-09 Pedro Alves <palves@redhat.com>
4495
4496 * cp-support.c (cp_remove_params): Return a gdb::unique_xmalloc_ptr.
4497 Use bool.
4498 (overload_list_add_symbol): Adjust to use gdb::unique_xmalloc_ptr.
4499 * cp-support.h (cp_remove_params): Now returns a
4500 gdb::unique_xmalloc_ptr.
4501 * dwarf2read.c (find_slot_in_mapped_hash): Now returns bool.
4502 Adjust to cp_remove_params returning a gdb::unique_xmalloc_ptr.
4503 * psymtab.c (psymtab_search_name): Adjust to cp_remove_params
4504 returning a gdb::unique_xmalloc_ptr.
4505 (lookup_partial_symbol): Adjust to use gdb::unique_xmalloc_ptr.
4506 * stack.c (find_frame_funname): Adjust to cp_remove_params
4507 returning a gdb::unique_xmalloc_ptr.
4508
4509 2017-10-08 Tom Tromey <tom@tromey.com>
4510
4511 * dwarf2read.c (dwarf2_get_dwz_file): Use
4512 gdb::unique_xmalloc_ptr.
4513 (find_slot_in_mapped_hash): Likewise.
4514 (dwarf2_physname): Likewise.
4515 (create_dwo_unit_in_dwp_v1): Use std::string.
4516 (create_dwo_unit_in_dwp_v2): Likewise.
4517 (lookup_dwo_cutu): Likewise.
4518 (inherit_abstract_dies): Use std::vector.
4519 (read_array_type): Likewise.
4520 (dwarf_decode_macros): Remove unused declaration.
4521 (unsigned_int_compar): Remove.
4522 (dwarf2_build_psymtabs_hard): Use scoped_restore.
4523 (psymtabs_addrmap_cleanup): Remove.
4524
4525 2017-10-08 Tom Tromey <tom@tromey.com>
4526
4527 * frame-unwind.c (frame_unwind_try_unwinder): Update.
4528 * frame.h (frame_cleanup_after_sniffer): Declare.
4529 (frame_prepare_for_sniffer): Return void.
4530 * frame.c (frame_cleanup_after_sniffer): No longer static. Change
4531 type of argument.
4532 (frame_prepare_for_sniffer): Return void.
4533
4534 2017-10-08 Tom Tromey <tom@tromey.com>
4535
4536 * utils.h (make_cleanup_value_free): Remove.
4537 * utils.c (do_value_free, struct cleanup): Remove.
4538 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full) <DWARF_VALUE_STACK>:
4539 Use gdb_value_up.
4540 * value.h (struct value_deleter): New.
4541 (gdb_value_up): New typedef.
4542
4543 2017-10-08 Tom Tromey <tom@tromey.com>
4544
4545 * symtab.c (free_search_symbols, do_free_search_symbols_cleanup)
4546 (make_cleanup_free_search_symbols): Remove.
4547 (search_symbols): Return std::vector.
4548 (symbol_search::compare_search_syms): Now member of
4549 symbol_search. Change arguments.
4550 (sort_search_symbols_remove_dups): Change arguments. Rewrite.
4551 (symtab_symbol_info, rbreak_command): Update.
4552 * symtab.h (struct symbol_search) <next>: Remove.
4553 Add constructors.
4554 (symbol_search::operator<): New function.
4555 (symbol_search::operator==): New function.
4556 (search_symbols): Remove std::vector.
4557 (free_search_symbols, make_cleanup_free_search_symbols): Remove.
4558 (symbol_search::compare_search_syms): Declare.
4559
4560 2017-10-06 Yao Qi <yao.qi@linaro.org>
4561
4562 * Makefile.in (ALL_64_TARGET_OBS): Replace aarch64-insn.o with
4563 arch/aarch64-insn.o.
4564 Remove one rule.
4565 * configure.tgt: Replace aarch64-insn.o with arch/aarch64-insn.o.
4566
4567 2017-10-06 Yao Qi <yao.qi@linaro.org>
4568
4569 * Makefile.in (ALL_TARGET_OBS): Replace arm.o, arm-get-next-pcs.o,
4570 and arm-linux.o with arch/arm.o, arch/arm-get-next-pcs.o and
4571 arch/arm-linux.o respectively.
4572 * configure.tgt: Likewise.
4573
4574 2017-10-06 Yao Qi <yao.qi@linaro.org>
4575
4576 * Makefile.in (ALL_TARGET_OBS): Rename i386.o to arch/i386.o.
4577 * configure.tgt (i386_tobjs): Replace i386.o with arch/i386.o.
4578
4579 2017-10-06 Pedro Alves <palves@redhat.com>
4580
4581 * windows-nat.c: Include <algorithm>.
4582
4583 2017-10-06 Yao Qi <yao.qi@linaro.org>
4584
4585 * configure.tgt (i386_tobjs): New variable.
4586 (amd64_tobjs): New variable.
4587 Set $cpu_obs and $os_obs.
4588
4589 2017-10-06 Yao Qi <yao.qi@linaro.org>
4590
4591 * Makefile.in (CONFIG_SRC_SUBDIR): New.
4592 (ALL_64_TARGET_OBS): Replace amd64.o with arch/amd64.o.
4593 (clean): Remove object files and dependency files.
4594 (distclean): Remove the directory.
4595 * configure.ac: Invoke AC_CONFIG_COMMANDS.
4596 * configure: Re-generated.
4597 * configure.tgt: Replace amd64.o with arch/amd64.o.
4598
4599 2017-10-05 Jose E. Marchesi <jose.marchesi@oracle.com>
4600
4601 PR build/22188
4602 * arm-tdep.c (arm_decode_misc_memhint_neon): Fix decoding of CPS
4603 and SETEND.
4604
4605 2017-10-05 Pedro Alves <palves@redhat.com>
4606
4607 * linux-nat.c (linux_child_follow_fork): When following the parent
4608 and detaching the child, consult the parent thread's architecture
4609 instead of the child's.
4610
4611 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
4612
4613 * ax.h: Do not include "doublest.h".
4614 (union agent_val): Remove.
4615
4616 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
4617
4618 * dfp.h (MAX_DECIMAL_STRING): Move to dfp.c.
4619 (decimal_to_string): Return std::string object.
4620 (decimal_from_string): Accept std::string object. Return bool.
4621 (decimal_from_integral, decimal_from_doublest): Remove.
4622 (decimal_from_longest): Add prototype.
4623 (decimal_from_ulongest): Likewise.
4624 (decimal_to_longest): Likewise.
4625 (decimal_from_doublest): Likewise.
4626 * dfp.c: Do not include "gdbtypes.h" or "value.h".
4627 (MAX_DECIMAL_STRING): Move here.
4628 (decimal_to_string): Return std::string object.
4629 (decimal_from_string): Accept std::string object. Return bool.
4630 (decimal_from_integral): Remove, replace by ...
4631 (decimal_from_longest, decimal_from_ulongest): ... these new functions.
4632 (decimal_to_longest): New function.
4633 (decimal_from_floating): Remove, replace by ...
4634 (decimal_from_doublest): ... this new function.
4635 (decimal_to_doublest): Update to new decimal_to_string interface.
4636
4637 * value.c (unpack_long): Use decimal_to_longest.
4638 * valops.c (value_cast): Use decimal_from_doublest instead of
4639 decimal_from_floating. Use decimal_from_[u]longest isntead of
4640 decimal_from_integral.
4641 * valarith.c (value_args_as_decimal): Likewise.
4642 * valprint.c (print_decimal_floating): Update to new
4643 decimal_to_string interface.
4644 * printcmd.c (printf_decfloat): Likewise.
4645 * c-exp.y (parse_number): Update to new decimal_from_string interface.
4646
4647 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
4648
4649 * doublest.h: Do not include "floatformat.h". Remove stale comments.
4650 * gdbtypes.c: Include "floatformat.h".
4651 * value.c: Likewise.
4652 * m68k-tdep.c: Likewise.
4653
4654 * findvar.c: Do not include "floatformat.h".
4655 * amd64-darwin-tdep.c: Likewise.
4656 * arm-linux-tdep.c: Likewise.
4657 * i386-darwin-tdep.c: Likewise.
4658 * i387-tdep.c: Likewise.
4659 * m68k-linux-tdep.c: Likewise.
4660 * mep-tdep.c: Likewise.
4661 * mips-tdep.c: Likewise.
4662 * nios2-tdep.c: Likewise.
4663 * s390-linux-tdep.c: Likewise.
4664 * sparc-obsd-tdep.c: Likewise.
4665 * sparc-tdep.c: Likewise.
4666 * sparc64-tdep.c: Likewise.
4667 * spu-tdep.c: Likewise.
4668 * tic6x-tdep.c: Likewise.
4669 * tilegx-tdep.c: Likewise.
4670 * vax-tdep.c: Likewise.
4671 * xstormy16-tdep.c: Likewise.
4672 * xtensa-tdep.c: Likewise.
4673
4674 * top.c: Do not include "doublest.h".
4675 * aarch64-tdep.c: Likewise.
4676 * alpha-tdep.c: Likewise.
4677 * arm-linux-tdep.c: Likewise.
4678 * m68k-linux-tdep.c: Likewise.
4679 * tilegx-tdep.c: Likewise.
4680 * xstormy16-tdep.c: Likewise.
4681
4682 2017-10-05 John Baldwin <jhb@FreeBSD.org>
4683
4684 * mips-fbsd-tdep.c (MIPS_INST_ADDIU_A0_SP_N32): Define.
4685 (mipsn32_fbsd_sigframe): Define.
4686 (mips_fbsd_init_abi): Install mipsn32_fbsd_sigframe unwinder
4687 for FreeBSD/mipsn32.
4688
4689 2017-10-05 John Baldwin <jhb@FreeBSD.org>
4690
4691 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_EHDRFLAGS and
4692 AT_HWCAP.
4693
4694 2017-10-05 Tristan Gingold <tgingold@free.fr>
4695
4696 * MAINTAINERS (Misc): Update my email address.
4697
4698 2017-10-04 Pedro Alves <palves@redhat.com>
4699
4700 * remote.c (get_remote_arch_state): New 'gdbarch' parameter. Use
4701 it instead of target_gdbarch.
4702 (get_remote_state, get_remote_packet_size): Adjust
4703 get_remote_arch_state calls, passing down target_gdbarch
4704 explicitly.
4705 (packet_reg_from_regnum, packet_reg_from_pnum): New parameter
4706 'gdbarch' and use it instead of target_gdbarch.
4707 (get_memory_packet_size): Adjust get_remote_arch_state calls,
4708 passing down target_gdbarch explicitly.
4709 (struct stop_reply) <arch>: New field.
4710 (remote_parse_stop_reply): Use the stopped thread's architecture,
4711 not the current inferior's. Save the architecture in the
4712 stop_reply.
4713 (process_stop_reply): Use the stop reply's architecture.
4714 (process_g_packet, remote_fetch_registers)
4715 (remote_prepare_to_store, store_registers_using_G)
4716 (remote_store_registers): Adjust get_remote_arch_state calls,
4717 using the regcache's architecture.
4718 (remote_get_trace_status): Adjust get_remote_arch_state calls,
4719 passing down target_gdbarch explicitly.
4720 * spu-multiarch.c (spu_thread_architecture): Defer to the target
4721 beneath instead of calling target_gdbarch.
4722 * target.c (default_thread_architecture): Use the specified
4723 inferior's architecture, instead of the current inferior's
4724 architecture (via target_gdbarch).
4725
4726 2017-10-04 Pedro Alves <palves@redhat.com>
4727
4728 * regcache.c (get_thread_arch_regcache): Remove null_ptid special
4729 case.
4730 (regcache_print): Handle !target_has_registers here instead.
4731
4732 2017-10-04 Pedro Alves <palves@redhat.com>
4733
4734 * frame.c (create_test_frame): Delete.
4735 * frame.h (create_test_frame): Delete.
4736 * gdbarch-selftests.c: Include gdbthread.h and target.h.
4737 (class regcache_test): Delete.
4738 (test_target_has_registers, test_target_has_stack)
4739 (test_target_has_memory, test_target_prepare_to_store)
4740 (test_target_store_registers): New functions.
4741 (test_target_ops): New class.
4742 (register_to_value_test): Error out if there's already a
4743 process_stratum (or higher) target pushed. Create a fuller mock
4744 environment, with mock target_ops, inferior, address space, thread
4745 and inferior_ptid.
4746 * progspace.c (struct address_space): Move to ...
4747 * progspace.h (struct address_space): ... here.
4748 * regcache.h (regcache::~regcache, regcache::raw_write)
4749 [GDB_SELF_TEST]: No longer virtual.
4750
4751 2017-10-04 Simon Marchi <simon.marchi@ericsson.com>
4752
4753 * mi/mi-main.c (list_available_thread_groups): Reverse filter logic.
4754
4755 2017-10-04 Pedro Alves <palves@redhat.com>
4756
4757 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Move code
4758 out of 'between TRY and CATCH'.
4759
4760 2017-10-04 Pedro Alves <palves@redhat.com>
4761
4762 * cli/cli-cmds.c (complete_command): Add missing END_CATCH.
4763 * common/common-exceptions.h (TRY): Open an outermost scope.
4764 Expand intro comment.
4765 (CATCH): Reindent.
4766 (END_CATCH): Close the outermost scope.
4767 * completer.c (complete_line_internal): Add missing END_CATCH.
4768
4769 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
4770
4771 * NEWS (Changes since GDB 8.0): Add entry about new
4772 'set-cwd-on-gdbserver' feature.
4773 (New remote packets): Add entry for QSetWorkingDir.
4774 * common/common-inferior.h (set_inferior_cwd): New prototype.
4775 * infcmd.c (set_inferior_cwd): Remove "static".
4776 (show_cwd_command): Expand text to include remote debugging.
4777 * remote.c: Add PACKET_QSetWorkingDir.
4778 (remote_protocol_features) <QSetWorkingDir>: New entry for
4779 PACKET_QSetWorkingDir.
4780 (extended_remote_set_inferior_cwd): New function.
4781 (extended_remote_create_inferior): Call
4782 "extended_remote_set_inferior_cwd".
4783 (_initialize_remote): Call "add_packet_config_cmd" for
4784 QSetWorkingDir.
4785
4786 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
4787
4788 * NEWS (New commands): Mention "set/show cwd".
4789 * cli/cli-cmds.c (_initialize_cli_cmds): Mention "set cwd" on
4790 "cd" command's help text.
4791 * common/common-inferior.h (get_inferior_cwd): New prototype.
4792 * infcmd.c (inferior_cwd_scratch): New global variable.
4793 (set_inferior_cwd): New function.
4794 (get_inferior_cwd): Likewise.
4795 (set_cwd_command): Likewise.
4796 (show_cwd_command): Likewise.
4797 (_initialize_infcmd): Add "set/show cwd" commands.
4798 * inferior.h (class inferior) <cwd>: New field.
4799 * nat/fork-inferior.c: Include "gdb_tilde_expand.h".
4800 (fork_inferior): Change inferior's cwd before its execution.
4801 * windows-nat.c (windows_create_inferior): Pass inferior's cwd
4802 to CreateProcess.
4803
4804 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
4805
4806 * Makefile.in (SFILES): Add gdb_tilde_expand.c.
4807 (HFILES_NO_SRCDIR): Add gdb_tilde_expand.h.
4808 (COMMON_OBS): Add gdb_tilde_expand.o.
4809 * common/gdb_tilde_expand.c: New file.
4810 * common/gdb_tilde_expand.h: Likewise.
4811
4812 2017-10-03 Maciej W. Rozycki <macro@imgtec.com>
4813
4814 * gdbarch.sh (objfile): Remove duplicate declaration.
4815 * gdbarch.h: Regenerate.
4816
4817 2017-10-03 Tom Tromey <tom@tromey.com>
4818
4819 * utils.c (internal_vproblem): Use string_vprintf.
4820
4821 2017-10-03 Tom Tromey <tom@tromey.com>
4822
4823 * printcmd.c (info_symbol_command): Use std::string.
4824
4825 2017-10-03 Tom Tromey <tom@tromey.com>
4826
4827 * top.c (gdb_safe_append_history): Use std::string.
4828
4829 2017-10-03 Tom Tromey <tom@tromey.com>
4830
4831 * event-top.c (stdin_event_handler): Update.
4832 * main.c (captured_main_1): Update.
4833 * top.h (make_delete_ui_cleanup): Remove.
4834 (struct ui): Add constructor and destructor.
4835 (new_ui, delete_ui): Remove.
4836 * top.c (make_delete_ui_cleanup): Remove.
4837 (new_ui_command): Use std::unique_ptr.
4838 (delete_ui_cleanup): Remove.
4839 (ui::ui): Rename from new_ui. Update.
4840 (free_ui): Remove.
4841 (ui::~ui): Rename from delete_ui. Update.
4842
4843 2017-10-03 Tom Tromey <tom@tromey.com>
4844
4845 * symfile.c (load_progress): Use gdb::byte_vector.
4846
4847 2017-10-03 Tom Tromey <tom@tromey.com>
4848
4849 * mi/mi-main.c (mi_cmd_trace_frame_collected): Remove unused
4850 declaration.
4851 * printcmd.c (x_command): Remove unused declaration.
4852 * symfile.c (symbol_file_command): Remove unused declaration.
4853
4854 2017-10-03 Tom Tromey <tom@tromey.com>
4855
4856 * utils.c (internal_vproblem): Use std::string.
4857 (defaulted_query): Likewise.
4858
4859 2017-10-03 Tom Tromey <tom@tromey.com>
4860
4861 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Update.
4862 * top.c (execute_command_to_string): Update.
4863 * utils.c (make_cleanup_restore_page_info): Remove.
4864 (do_restore_page_info_cleanup): Remove.
4865 (set_batch_flag_and_restore_page_info):
4866 New.
4867 (make_cleanup_restore_page_info): Remove.
4868 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
4869 (~set_batch_flag_and_restore_page_info): New
4870 (make_cleanup_restore_uinteger): Remove.
4871 (make_cleanup_restore_integer): Remove.
4872 (struct restore_integer_closure): Remove.
4873 (restore_integer): Remove.
4874 * utils.h (struct set_batch_flag_and_restore_page_info): New
4875 class.
4876 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
4877 (make_cleanup_restore_page_info): Remove.
4878 (make_cleanup_restore_uinteger) Remove.
4879 (make_cleanup_restore_integer) Remove.
4880
4881 2017-10-03 Tom Tromey <tom@tromey.com>
4882
4883 * record-full.h (record_full_gdb_operation_disable_set): Return
4884 scoped_restore_tmpl<int>.
4885 * infrun.c (adjust_pc_after_break): Update.
4886 (handle_signal_stop): Update.
4887 * record-full.c (record_full_gdb_operation_disable_set): Return
4888 scoped_restore_tmpl<int>.
4889 (record_full_wait_1, record_full_insert_breakpoint)
4890 (record_full_remove_breakpoint, record_full_save)
4891 (record_full_goto_insn): Update.
4892
4893 2017-10-02 Tom Tromey <tom@tromey.com>
4894
4895 PR rust/22236:
4896 * rust-lang.c (rust_val_print_str): New function.
4897 (val_print_struct): Call it.
4898 (rust_subscript): Preserve name of slice type.
4899
4900 2017-10-02 Tom Tromey <tom@tromey.com>
4901
4902 * rust-lang.c (rust_subscript): Handle slices in
4903 EVAL_AVOID_SIDE_EFFECTS case.
4904
4905 2017-10-02 Tom Tromey <tom@tromey.com>
4906
4907 * rust-lang.c (rust_slice_type_p): Recognize &str as a slice type.
4908
4909 2017-10-02 Tom Tromey <tom@tromey.com>
4910
4911 * rust-lang.h (rust_slice_type): Add "extern".
4912
4913 2017-10-02 Tom Tromey <tom@tromey.com>
4914 Pedro Alves <palves@redhat.com>
4915
4916 * ada-lang.h (ada_exc_info::operator<): Make const.
4917 (ada_exc_info::operator==): Make const.
4918 * ada-lang.c (ada_exc_info::operator<, ada_exc_info::operator==):
4919 Make const.
4920
4921 2017-09-29 Tom Tromey <tom@tromey.com>
4922
4923 * target.c (read_whatever_is_readable): Change type of "result".
4924 Update.
4925 (free_memory_read_result_vector): Remove.
4926 (read_memory_robust): Change return type. Update.
4927 * mi/mi-main.c (mi_cmd_data_read_memory_bytes): Update. Use
4928 bin2hex, std::string.
4929 * target.h (memory_read_result_s): Remove typedef.
4930 (free_memory_read_result_vector): Remove.
4931 (read_memory_robust): Return std::vector.
4932
4933 2017-09-29 Tom Tromey <tom@tromey.com>
4934
4935 * mi/mi-main.c (captured_mi_execute_command): Use scope_restore.
4936
4937 2017-09-29 Tom Tromey <tom@tromey.com>
4938
4939 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Update.
4940 * ada-lang.h (struct ada_exc_info): Remove typedef. Declare
4941 operator< and operator==.
4942 (ada_exceptions_list): Return a std::vector.
4943 * ada-lang.c (ada_exc_info::operator<): Rename from
4944 compare_ada_exception_info.
4945 (ada_exc_info::operator==): New.
4946 (sort_remove_dups_ada_exceptions_list): Change type of
4947 "exceptions".
4948 (ada_add_standard_exceptions, ada_add_exceptions_from_frame)
4949 (ada_add_global_exceptions): Likewise.
4950 (ada_exceptions_list_1): Return a std::vector.
4951 (ada_exceptions_list): Likewise.
4952
4953 2017-09-29 Tom Tromey <tom@tromey.com>
4954
4955 * mi/mi-main.c (struct print_one_inferior_data) <inferiors>: Now a
4956 'std::set *'.
4957 (print_one_inferior): Update.
4958 (free_vector_of_ints): Remove.
4959 (list_available_thread_groups): Change "ids" to std::set.
4960 (mi_cmd_list_thread_groups): Update.
4961 (struct collect_cores_data) <core>: Now a std::set.
4962 (collect_cores): Update.
4963 (unique): Remove.
4964 (print_one_inferior): Update.
4965
4966 2017-09-29 Tom Tromey <tom@tromey.com>
4967
4968 * mi/mi-main.c (mi_execute_cli_command): Use std::string.
4969 (mi_execute_async_cli_command): Likewise.
4970 (mi_cmd_trace_frame_collected): Use field_fmt.
4971
4972 2017-09-29 Tom Tromey <tom@tromey.com>
4973
4974 * mi/mi-main.c (mi_cmd_data_write_memory_bytes): Use
4975 gdb::byte_vector.
4976
4977 2017-09-29 Tom Tromey <tom@tromey.com>
4978
4979 * mi/mi-parse.c (mi_parse): Remove unused declaration.
4980
4981 2017-09-29 Tom Tromey <tom@tromey.com>
4982
4983 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Don't copy "oarg".
4984
4985 2017-09-29 Tom Tromey <tom@tromey.com>
4986
4987 * varobj.h (varobj_gen_name): Return std::string.
4988 * varobj.c (varobj_gen_name): Return std::string.
4989 * mi/mi-cmd-var.c (mi_cmd_var_create): Use std::string.
4990 (mi_cmd_var_delete): Don't copy "name".
4991
4992 2017-09-29 Tom Tromey <tom@tromey.com>
4993
4994 * mi/mi-cmd-break.c (mi_argv_to_format): Return std::string.
4995 (mi_cmd_break_insert_1): Update.
4996
4997 2017-09-29 Tom Tromey <tom@tromey.com>
4998
4999 * target.h (make_scoped_defer_target_commit_resume): Update.
5000 * target.c (make_scoped_defer_target_commit_resume): Rename from
5001 make_cleanup_defer_target_commit_resume. Return a
5002 scoped_restore.
5003 * infrun.c (proceed): Use make_scoped_defer_target_commit_resume.
5004
5005 2017-09-29 Tom Tromey <tom@tromey.com>
5006
5007 * main.c (captured_main_1): Remove unused declaration.
5008 * spu-multiarch.c (parse_spufs_run): Remove unused declaration.
5009
5010 2017-09-29 Tom Tromey <tom@tromey.com>
5011
5012 * symtab.c (search_symbols): Remove unused outer cleanup.
5013 (make_source_files_completion_list): Remove unused declaration.
5014
5015 2017-09-29 Tom Tromey <tom@tromey.com>
5016
5017 * mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.
5018
5019 2017-09-29 Tom Tromey <tom@tromey.com>
5020
5021 * xstormy16-tdep.c (xstormy16_push_dummy_call): Use
5022 gdb::byte_vector.
5023
5024 2017-09-29 Tom Tromey <tom@tromey.com>
5025
5026 * complaints.c (vcomplaint): Use std::string.
5027
5028 2017-09-29 Tom Tromey <tom@tromey.com>
5029
5030 * tracepoint.c (trace_variable_command): Use std::string.
5031 (encode_actions_1): Remove unused declarations.
5032 (create_tsv_from_upload): Use std::string.
5033
5034 2017-09-29 Tom Tromey <tom@tromey.com>
5035
5036 * cp-support.c (gdb_demangle): Use std::string.
5037
5038 2017-09-29 Tom Tromey <tom@tromey.com>
5039
5040 * stack.c (parse_frame_specification): Use std::string
5041 (info_frame_command): Use gdb::unique_xmalloc_ptr.
5042
5043 2017-09-29 Tom Tromey <tom@tromey.com>
5044
5045 * tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.
5046
5047 2017-09-29 Tom Tromey <tom@tromey.com>
5048
5049 * utils.c (vfprintf_maybe_filtered): Use std::string.
5050 (vfprintf_unfiltered): Likewise.
5051
5052 2017-09-29 Tom Tromey <tom@tromey.com>
5053
5054 * event-top.c (top_level_prompt): Return std::string.
5055 (display_gdb_prompt): Update.
5056
5057 2017-09-29 Tom Tromey <tom@tromey.com>
5058
5059 * unittests/common-utils-selftests.c (format): New function.
5060 (string_vprintf_tests): New function.
5061 (_initialize_common_utils_selftests): Register new tests.
5062 * common/common-utils.c (string_vprintf): New function.
5063 * common/common-utils.h (string_vprintf): Declare.
5064
5065 2017-09-29 Pedro Alves <palves@redhat.com>
5066
5067 * common/rsp-low.c (unpack_varlen_hex): Constify.
5068 * common/rsp-low.h (unpack_varlen_hex): Constify.
5069 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
5070 Constify.
5071 * remote.c (remote_set_permissions, read_ptid)
5072 (remote_current_thread, remote_get_threads_with_qthreadinfo)
5073 (remote_static_tracepoint_marker_at)
5074 (remote_static_tracepoint_markers_by_strid)
5075 (stop_reply_extract_thread, remote_parse_stop_reply): Constify.
5076 * tracepoint.c (parse_trace_status, parse_tracepoint_status)
5077 (parse_tracepoint_definition, parse_tsv_definition)
5078 (parse_static_tracepoint_marker_definition): Constify.
5079 * tracepoint.h (parse_static_tracepoint_marker_definition)
5080 (parse_trace_status, parse_tracepoint_status)
5081 (parse_tracepoint_definition, parse_tsv_definition): Constify.
5082
5083 2017-09-29 Pedro Alves <palves@redhat.com>
5084
5085 * remote.c (target_buf, target_buf_size): Delete.
5086 (remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
5087 Use the connection's packet buffer instead.
5088 All callers adjusted.
5089 (_initialize_remote): Remove references to target_buf and
5090 target_buf_size.
5091
5092 2017-09-28 Pedro Alves <palves@redhat.com>
5093
5094 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5095 unittests/common-utils-selftests.c.
5096 (SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
5097 (COMMON_OBS): Remove utils-selftests.o.
5098 * utils-selftests.c: Move to ...
5099 * unittests/common-utils-selftests.c: ... here and rename self
5100 test to "string_printf".
5101
5102 2017-09-28 Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com> (tiny patch)
5103
5104 * dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
5105 having NULL cus or tus.
5106
5107 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
5108
5109 * arm-tdep.c: (convert_from_extended): Remove.
5110 (convert_to_extended): Likewise.
5111 (arm_extract_return_value): Use convert_typed_floating.
5112 (arm_store_return_value): Likewise.
5113
5114 * sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
5115 * sh-tdep.c: Do not include "floatformat.h".
5116 (sh_littlebyte_bigword_type): New function.
5117 (sh_register_convert_to_virtual): Use convert_typed_floating.
5118 (sh_register_convert_to_raw): Likewise.
5119 * sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
5120 (sh64_littlebyte_bigword_type): New function.
5121 (sh64_extract_return_value): Use convert_typed_floating.
5122 (sh64_register_convert_to_virtual): Likewise.
5123 (sh64_register_convert_to_raw): Likewise.
5124
5125 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
5126
5127 * doublest.h (floatformat_from_type): Move to gdbtypes.h.
5128 * doublest.c (floatformat_from_type): Move to gdbtypes.c.
5129
5130 * gdbtypes.h (union type_specific): Make field floatformat hold
5131 just a single struct floatformat, not an array.
5132 (floatformat_from_type): Move here.
5133 * gdbtypes.c (floatformat_from_type): Move here. Update to
5134 changed TYPE_FLOATFORMAT definition.
5135 (verify_floatformat): Update to changed TYPE_FLOATFORMAT.
5136 (recursive_dump_type): Likewise.
5137 (init_float_type): Install correct floatformat for byte order.
5138 (arch_float_type): Likewise.
5139
5140 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
5141
5142 * gdbtypes.c (init_type): Change incoming argument from
5143 length-in-bytes to length-in-bits. Assert length is a
5144 multiple of TARGET_CHAR_BITS.
5145 (arch_type, arch_flags_type): Likewise.
5146 (init_integer_type): Update call to init_type.
5147 (init_character_type): Likewise.
5148 (init_boolean_type): Likewise.
5149 (init_float_type): Likewise.
5150 (init_decfloat_type): Likewise.
5151 (init_complex_type): Likewise.
5152 (init_pointer_type): Likewise.
5153 (objfile_type): Likewise.
5154 (arch_integer_type): Update call to arch_type.
5155 (arch_character_type): Likewise.
5156 (arch_boolean_type): Likewise.
5157 (arch_float_type): Likewise.
5158 (arch_decfloat_type): Likewise.
5159 (arch_complex_type): Likewise.
5160 (arch_pointer_type): Likewise.
5161 (gdbtypes_post_init): Likewise.
5162
5163 * dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
5164 (read_base_type): Likewise.
5165 * mdebugread.c (basic_type): Likewise.
5166 * stabsread.c (dbx_init_float_type): Likewise.
5167 (rs6000_builtin_type): Likewise.
5168 (read_range_type): Likewise. Also, fix call to init_integer_type
5169 with erroneous length argument.
5170
5171 * ada-lang.c (ada_language_arch_info): Update call to arch_type.
5172 * d-lang.c (build_d_types): Likewise.
5173 * f-lang.c (build_fortran_types): Likewise.
5174 * go-lang.c (build_go_types): Likewise.
5175 * opencl-lang.c (build_opencl_types): Likewise.
5176 * jit.c (finalize_symtab): Likewise.
5177 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
5178 (build_std_type_info_type): Likewise.
5179 * target-descriptions.c (tdesc_gdb_type): Likewise. Also,
5180 update call to arch_flags_type.
5181
5182 * linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
5183 arch_type.
5184 * fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
5185 * windows-tdep.c (windows_get_tlb_type): Likewise.
5186
5187 * avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
5188 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
5189 * m32c-tdep.c (make_types): Likewise.
5190 * rl78-tdep.c (rl78_gdbarch_init): Likewise.
5191 (rl78_psw_type): Update call to arch_flags_type.
5192 * m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
5193 * rx-tdep.c (rx_psw_type): Likewise.
5194 (rx_fpsw_type): Likewise.
5195 * sparc-tdep.c (sparc_psr_type): Likewise.
5196 (sparc_fsr_type): Likewise.
5197 * sparc64-tdep.c (sparc64_pstate_type): Likewise.
5198 (sparc64_ccr_type): Likewise.
5199 (sparc64_fsr_type): Likewise.
5200 (sparc64_fprs_type): Likewise.
5201
5202 2017-09-27 Tom Tromey <tom@tromey.com>
5203
5204 * findcmd.c (find_command): Constify.
5205
5206 2017-09-27 Tom Tromey <tom@tromey.com>
5207
5208 * ada-tasks.c (task_command_1, task_command): Constify.
5209
5210 2017-09-27 Tom Tromey <tom@tromey.com>
5211
5212 * symtab.c (maintenance_print_symbol_cache)
5213 (maintenance_flush_symbol_cache)
5214 (maintenance_print_symbol_cache_statistics): Constify.
5215
5216 2017-09-27 Tom Tromey <tom@tromey.com>
5217
5218 * inferior.c (detach_inferior_command, kill_inferior_command)
5219 (inferior_command): Constify.
5220
5221 2017-09-27 Tom Tromey <tom@tromey.com>
5222
5223 * regcache.c (regcache_print, maintenance_print_registers)
5224 (maintenance_print_raw_registers)
5225 (maintenance_print_cooked_registers)
5226 (maintenance_print_register_groups)
5227 (maintenance_print_remote_registers): Constify.
5228
5229 2017-09-27 Tom Tromey <tom@tromey.com>
5230
5231 * printcmd.c (map_display_numbers, undisplay_command)
5232 (enable_disable_display_command, enable_display_command)
5233 (disable_display_command): Constify.
5234
5235 2017-09-27 Tom Tromey <tom@tromey.com>
5236
5237 * breakpoint.h (delete_command): Don't declare.
5238 * breakpoint.c (delete_command, enable_once_command)
5239 (enable_count_command, enable_delete_command, breakpoint_1)
5240 (maintenance_info_breakpoints, stopin_command, stopat_command)
5241 (delete_command, delete_trace_command, save_breakpoints)
5242 (save_breakpoints_command, save_tracepoints_command): Constify.
5243
5244 2017-09-27 Tom Tromey <tom@tromey.com>
5245
5246 * macrocmd.c (macro_expand_command, macro_expand_once_command)
5247 (skip_ws, extract_identifier, macro_define_command)
5248 (macro_undef_command, macro_list_command): Constify.
5249
5250 2017-09-27 Tom Tromey <tom@tromey.com>
5251
5252 * infcmd.c (environment_info, set_environment_command)
5253 (unset_environment_command, path_info, info_proc_cmd_1)
5254 (info_proc_cmd_mappings, info_proc_cmd_stat)
5255 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
5256 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
5257
5258 2017-09-27 Tom Tromey <tom@tromey.com>
5259
5260 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
5261 Constify.
5262
5263 2017-09-27 Tom Tromey <tom@tromey.com>
5264
5265 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
5266
5267 2017-09-27 Tom Tromey <tom@tromey.com>
5268
5269 * demangle.c (demangle_command): Constify.
5270
5271 2017-09-27 Tom Tromey <tom@tromey.com>
5272
5273 * progspace.c (maintenance_info_program_spaces_command):
5274 Constify.
5275
5276 2017-09-27 Tom Tromey <tom@tromey.com>
5277
5278 * compile/compile.c (check_raw_argument, compile_file_command)
5279 (compile_code_command, compile_print_command): Constify.
5280
5281 2017-09-27 Tom Tromey <tom@tromey.com>
5282
5283 * reggroups.c (maintenance_print_reggroups): Constify.
5284
5285 2017-09-27 Tom Tromey <tom@tromey.com>
5286
5287 * dwarf2read.c (save_gdb_index_command): Constify.
5288
5289 2017-09-27 Tom Tromey <tom@tromey.com>
5290
5291 * stap-probe.c (info_probes_stap_command): Constify.
5292
5293 2017-09-27 Tom Tromey <tom@tromey.com>
5294
5295 * fork-child.c (unset_exec_wrapper_command): Constify.
5296
5297 2017-09-27 Tom Tromey <tom@tromey.com>
5298
5299 * btrace.c (get_uint, get_context_size, no_chunk)
5300 (maint_btrace_packet_history_cmd)
5301 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
5302 (maint_info_btrace_cmd): Constify.
5303
5304 2017-09-27 Tom Tromey <tom@tromey.com>
5305
5306 * reverse.c (delete_bookmark_command): Constify.
5307
5308 2017-09-27 Tom Tromey <tom@tromey.com>
5309
5310 * remote.c (set_memory_packet_size)
5311 (set_memory_write_packet_size, show_memory_write_packet_size)
5312 (set_memory_read_packet_size, show_memory_read_packet_size)
5313 (compare_sections_command, packet_command, remote_put_command)
5314 (remote_get_command, remote_delete_command): Constify.
5315
5316 2017-09-27 Tom Tromey <tom@tromey.com>
5317
5318 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
5319 (set_mipsfpu_double_command, set_mipsfpu_none_command)
5320 (set_mipsfpu_auto_command): Constify.
5321
5322 2017-09-27 Tom Tromey <tom@tromey.com>
5323
5324 * cli/cli-cmds.h (cd_command): Constify.
5325 * cli/cli-cmds.c (cd_command): Constify.
5326
5327 2017-09-27 Tom Tromey <tom@tromey.com>
5328
5329 * thread.c (thread_name_command, thread_find_command): Constify.
5330
5331 2017-09-27 Tom Tromey <tom@tromey.com>
5332
5333 * probe.c (enable_probes_command, disable_probes_command):
5334 Constify.
5335
5336 2017-09-27 Tom Tromey <tom@tromey.com>
5337
5338 * symfile.c (symbol_file_command): Constify.
5339 * gdbcore.h (deprecated_file_changed_hook): Constify.
5340 * exec.c (deprecated_file_changed_hook, exec_file_command)
5341 (file_command): Constify.
5342 * defs.h (symbol_file_command): Constify.
5343
5344 2017-09-27 Tom Tromey <tom@tromey.com>
5345
5346 * remote-fileio.c (set_system_call_allowed)
5347 (show_system_call_allowed): Constify.
5348
5349 2017-09-27 Tom Tromey <tom@tromey.com>
5350
5351 * tracepoint.c (delete_trace_variable_command)
5352 (tfind_end_command, tfind_start_command, tfind_pc_command)
5353 (tfind_tracepoint_command, tfind_line_command)
5354 (tfind_range_command, tfind_outside_command): Constify.
5355
5356 2017-09-27 Tom Tromey <tom@tromey.com>
5357
5358 * ax-gdb.c (maint_agent_printf_command, agent_command)
5359 (agent_eval_command): Constify.
5360
5361 2017-09-27 Tom Tromey <tom@tromey.com>
5362
5363 * tracepoint.c (info_scope_command): Constify.
5364 * python/python.c (gdbpy_decode_line): Constify.
5365 * python/py-breakpoint.c (bppy_init): Constify.
5366 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
5367 * location.h: (new_linespec_location)
5368 (string_to_event_location_basic, string_to_event_location):
5369 Constify.
5370 * location.c (new_linespec_location)
5371 (string_to_event_location_basic, string_to_event_location):
5372 Constify.
5373 * linespec.h (decode_line_with_current_source)
5374 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
5375 * linespec.c (linespec_lex_to_end)
5376 (decode_line_with_current_source)
5377 (decode_line_with_last_displayed): Constify.
5378 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
5379 Constify.
5380 * cli/cli-cmds.c (edit_command, list_command): Constify.
5381 * breakpoint.h (until_break_command, watch_command_wrapper)
5382 (awatch_command_wrapper, rwatch_command_wrapper)
5383 (init_ada_exception_breakpoint): Constify.
5384 * breakpoint.c (break_command_1, dprintf_command)
5385 (break_range_command, watch_command_wrapper)
5386 (rwatch_command_wrapper, awatch_command_wrapper)
5387 (until_break_command, init_ada_exception_breakpoint)
5388 (strace_marker_create_sals_from_location, trace_command)
5389 (ftrace_command, strace_command, struct tracepoint): Constify.
5390 * ax-gdb.c (agent_command_1): Constify.
5391 * ada-lang.c (ada_exception_sal): Constify.
5392
5393 2017-09-27 Tom Tromey <tom@tromey.com>
5394
5395 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
5396 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
5397 (get_context_size, no_chunk, get_insn_history_modifiers)
5398 (cmd_record_insn_history, get_call_history_modifiers)
5399 (cmd_record_call_history): Constify.
5400
5401 2017-09-27 Tom Tromey <tom@tromey.com>
5402
5403 * source.c (show_substitute_path_command)
5404 (unset_substitute_path_command, set_substitute_path_command):
5405 Constify.
5406
5407 2017-09-27 Tom Tromey <tom@tromey.com>
5408
5409 * typeprint.c (maintenance_print_type): Constify.
5410 * maint.c (maintenance_dump_me, maintenance_demangle)
5411 (maintenance_time_display, maintenance_info_sections)
5412 (maintenance_print_statistics, maintenance_deprecate)
5413 (maintenance_undeprecate): Constify.
5414 (maintenance_do_deprecate): Constify. Use std::string.
5415 (maintenance_selftest): Constify.
5416 * gdbtypes.h (maintenance_print_type): Constify.
5417
5418 2017-09-27 Tom Tromey <tom@tromey.com>
5419
5420 * hppa-tdep.c (unwind_command): Constify.
5421
5422 2017-09-27 Tom Tromey <tom@tromey.com>
5423
5424 * target-descriptions.c (unset_tdesc_filename_cmd)
5425 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
5426 Constify.
5427
5428 2017-09-27 Tom Tromey <tom@tromey.com>
5429
5430 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
5431
5432 2017-09-27 Tom Tromey <tom@tromey.com>
5433
5434 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
5435
5436 2017-09-27 Tom Tromey <tom@tromey.com>
5437
5438 * tui/tui-regs.c (tui_reg_command): Constify.
5439
5440 2017-09-27 Tom Tromey <tom@tromey.com>
5441
5442 * skip.c (skip_file_command, skip_function_command)
5443 (skip_enable_command, skip_disable_command, skip_delete_command):
5444 Constify.
5445
5446 2017-09-27 Tom Tromey <tom@tromey.com>
5447
5448 * record-btrace.c (cmd_record_btrace_bts_start)
5449 (cmd_record_btrace_pt_start): Constify.
5450
5451 2017-09-27 Tom Tromey <tom@tromey.com>
5452
5453 * symmisc.c (maintenance_print_symbols)
5454 (maintenance_print_msymbols, maintenance_print_objfiles)
5455 (maintenance_info_symtabs, maintenance_check_symtabs)
5456 (maintenance_expand_symtabs, maintenance_info_line_tables):
5457 Constify.
5458
5459 2017-09-27 Tom Tromey <tom@tromey.com>
5460
5461 * top.c (new_ui_command): Constify.
5462
5463 2017-09-27 Tom Tromey <tom@tromey.com>
5464
5465 * symfile.c (add_symbol_file_command)
5466 (remove_symbol_file_command, list_overlays_command)
5467 (map_overlay_command, unmap_overlay_command)
5468 (overlay_auto_command, overlay_manual_command)
5469 (overlay_off_command, overlay_load_command): Constify.
5470
5471 2017-09-27 Tom Tromey <tom@tromey.com>
5472
5473 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
5474 (info_spu_mailbox_command, info_spu_dma_command)
5475 (info_spu_proxydma_command): Constify.
5476
5477 2017-09-27 Tom Tromey <tom@tromey.com>
5478
5479 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
5480
5481 2017-09-27 Tom Tromey <tom@tromey.com>
5482
5483 * cli/cli-script.c (user_defined_command): Constify.
5484
5485 2017-09-27 Tom Tromey <tom@tromey.com>
5486
5487 * cli/cli-dump.c (dump_memory_command, dump_value_command)
5488 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
5489 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
5490 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
5491 (dump_binary_value, append_binary_memory, append_binary_value):
5492 Constify.
5493 (struct dump_context) <func>: Constify.
5494 (add_dump_command): Update.
5495
5496 2017-09-27 Tom Tromey <tom@tromey.com>
5497
5498 * cli/cli-cmds.c (show_version, show_configuration)
5499 (source_command, show_user): Constify.
5500
5501 2017-09-27 Tom Tromey <tom@tromey.com>
5502
5503 * target.c (maintenance_print_target_stack): Constify.
5504
5505 2017-09-27 Tom Tromey <tom@tromey.com>
5506
5507 * interps.c (interpreter_exec_cmd): Constify.
5508
5509 2017-09-27 Tom Tromey <tom@tromey.com>
5510
5511 * record-full.c (cmd_record_full_restore): Constify.
5512
5513 2017-09-27 Tom Tromey <tom@tromey.com>
5514
5515 * memattr.c (enable_mem_command, disable_mem_command)
5516 (delete_mem_command): Constify.
5517
5518 2017-09-27 Tom Tromey <tom@tromey.com>
5519
5520 * value.c (show_convenience): Constify.
5521
5522 2017-09-27 Tom Tromey <tom@tromey.com>
5523
5524 * gdbcore.h (core_file_command): Update.
5525 * corefile.c (core_file_command): Constify.
5526
5527 2017-09-27 Tom Tromey <tom@tromey.com>
5528
5529 * user-regs.c (maintenance_print_user_registers): Constify.
5530
5531 2017-09-27 Tom Tromey <tom@tromey.com>
5532
5533 * cp-namespace.c (maintenance_cplus_namespace): Constify.
5534
5535 2017-09-27 Tom Tromey <tom@tromey.com>
5536
5537 * cp-support.c (first_component_command): Constify.
5538
5539 2017-09-27 Tom Tromey <tom@tromey.com>
5540
5541 * psymtab.c (maintenance_print_psymbols)
5542 (maintenance_info_psymtabs, maintenance_check_psymtabs):
5543 Constify.
5544
5545 2017-09-27 Tom Tromey <tom@tromey.com>
5546
5547 * windows-tdep.c (display_tib): Constify.
5548
5549 2017-09-27 Tom Tromey <tom@tromey.com>
5550
5551 * linux-fork.c (delete_checkpoint_command)
5552 (detach_checkpoint_command): Constify.
5553
5554 2017-09-27 Tom Tromey <tom@tromey.com>
5555
5556 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
5557
5558 2017-09-27 Tom Tromey <tom@tromey.com>
5559
5560 * arc-tdep.c (dump_arc_instruction_command): Constify.
5561
5562 2017-09-27 Tom Tromey <tom@tromey.com>
5563
5564 * valprint.c (set_radix, show_radix): Constify.
5565
5566 2017-09-27 Tom Tromey <tom@tromey.com>
5567
5568 * dtrace-probe.c (info_probes_dtrace_command): Constify.
5569
5570 2017-09-27 Tom Tromey <tom@tromey.com>
5571
5572 * command.h (not_just_help_class_command): Update.
5573 * cli/cli-decode.h (not_just_help_class_command): Update.
5574 * cli/cli-decode.c (not_just_help_class_command): Constify.
5575
5576 2017-09-27 Tom Tromey <tom@tromey.com>
5577
5578 * gdb_bfd.c (maintenance_info_bfds): Constify.
5579
5580 2017-09-27 Tom Tromey <tom@tromey.com>
5581
5582 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
5583 overloads.
5584 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
5585 (do_const_cfunc): New function.
5586 (cmd_cfunc_eq): New overload.
5587 (cli_user_command_p): Check do_const_cfunc.
5588 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
5589 const_cfunc.
5590 * command.h (add_cmd): Add const overload and no-function
5591 overload.
5592 (set_cmd_cfunc): Add const overload.
5593 (cmd_const_cfunc_ftype): Declare.
5594 (cmd_cfunc_eq): Add const overload.
5595 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
5596 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
5597 overload.
5598
5599 2017-09-27 Tom Tromey <tom@tromey.com>
5600
5601 * macroexp.c (get_next_token_for_substitution): New function.
5602 (substitute_args): Call it. Check for __VA_OPT__.
5603
5604 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
5605 Pedro Alves <palves@redhat.com>
5606
5607 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
5608 producer_is_icc_lt_14.
5609 (producer_is_icc_lt_14): New function.
5610 (check_producer): Add code for checking version of ICC.
5611 (producer_is_icc): Move to producer.c.
5612 (read_structure_type): Restrict ICC workaround to ICC<14.
5613 * producer.c: Include selftest.h.
5614 (producer_is_icc, producer_parsing_tests, _initialize_producer):
5615 New functions.
5616 * producer.h (producer_is_icc): New declaration.
5617
5618 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
5619
5620 * Makefile.in (SFILES): Add producer.c.
5621 (COMMON_OBS): Add producer.o
5622 * amd64-tdep.c (producer.h): Add new include.
5623 * dwarf2read.c (producer.h): Add new include.
5624 * producer.c: New file.
5625 * producer.h: New file.
5626 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
5627 producer.c.
5628 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
5629 producer.h.
5630
5631 2017-09-26 Matthias Klose <doko@ubuntu.com>
5632
5633 * configure.ac: Search ncursesw before ncurses.
5634 Check ncursesw/ncurses.h before ncurses/ncurses.h.
5635 * gdb_curses.h: Include <ncursesw/ncurses.h>
5636 * config.in, configure: Regenerate.
5637
5638 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5639
5640 PR gdb/22185
5641 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
5642 obsolete.
5643 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
5644 Remove i386sol2 support.
5645 * configure.nat <i386sol2>: Remove.
5646 <sol2-64>: Fold into ...
5647 <sol2>: ... this.
5648 Move common settings to default section.
5649 Add sol-thread.o.
5650 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
5651 x86_64-*-solaris2.1[0-9]*>: Rename to ...
5652 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
5653 <i[34567]86-*-solaris*>: Remove.
5654 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
5655
5656 * configure.ac: Remove wctype in libw check.
5657 (_MSE_INT_H): Don't define on Solaris 7-9.
5658 <solaris*>: Remove libthread_db.so.1 check.
5659 * configure: Regenerate.
5660 * config.in: Regenerate.
5661
5662 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
5663 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
5664 (gdb_ps_size_t): Remove.
5665 Use base types in users.
5666 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
5667
5668 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
5669
5670 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5671
5672 PR build/22206
5673 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
5674 (adi_is_addr_mapped): Likewise.
5675 (PSR_ICC): Don't redefine.
5676 (PSR_IMPL): Likewise.
5677
5678 2017-09-25 Tom Tromey <tom@tromey.com>
5679
5680 * regcache.c (regcache::dump): Use string_printf.
5681
5682 2017-09-25 Tom Tromey <tom@tromey.com>
5683
5684 * regcache.c (class regcache_invalidator): New.
5685 (struct register_to_invalidate): Remove.
5686 (make_cleanup_regcache_invalidate): Remove.
5687 (regcache::raw_write): Use regcache_invalidator.
5688
5689 2017-09-25 Tom Tromey <tom@tromey.com>
5690
5691 * spu-tdep.c (spu2ppu_sniffer): Update.
5692 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
5693 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
5694 Remove.
5695 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
5696 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
5697 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
5698 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
5699 (frame_pop): Update.
5700
5701 2017-09-25 Tom Tromey <tom@tromey.com>
5702
5703 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
5704 * regcache.h (regcache_xfree): Don't declare.
5705 * regcache.c (regcache_xfree): Remove.
5706 (do_regcache_xfree): Use delete.
5707 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
5708 * linux-fork.c (free_fork): Use delete.
5709 (fork_save_infrun_state): Likewise.
5710 * jit.c (jit_dealloc_cache): Use delete.
5711 * infrun.c (discard_infcall_suspend_state): Use delete.
5712
5713 2017-09-25 Tom Tromey <tom@tromey.com>
5714
5715 * regcache.h (regcache_xmalloc): Don't declare.
5716 (regcache_raw_set_cached_value): Update comment.
5717 * regcache.c (regcache_xmalloc): Remove.
5718 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
5719 * jit.c (jit_frame_sniffer): Use new.
5720 * frame.c (frame_save_as_regcache): Use new.
5721
5722 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
5723
5724 * NEWS: Advertise support for guarded-storage registers on IBM z.
5725
5726 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
5727
5728 * s390-linux-nat.c (have_regset_gs): New static variable.
5729 (s390_linux_fetch_inferior_registers): Handle guarded-storage
5730 control block and guarded-storage broadcast control regsets.
5731 (s390_read_description): Detect whether the target has
5732 guarded-storage support, return appropriate tdesc.
5733 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
5734 (features/s390x-gs-linux64.c): Likewise.
5735 (struct gdbarch_tdep) <have_gs>: New field.
5736 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
5737 (s390_gsbc_regset): New variables.
5738 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
5739 and s390_gsbc_regset, if applicable.
5740 (s390_core_read_description): Check whether core file was from a
5741 target with guarded-storage support; include appropriate regsets.
5742 (s390_gdbarch_init): Add registers for guarded-storage support.
5743 (_initialize_s390_tdep): Initialize new target descriptions that
5744 include registers for guarded-storage support.
5745 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
5746 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
5747 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
5748 (S390_NUM_REGS): Adjust macro definition.
5749 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
5750 (tdesc_s390x_gs_linux64): New declarations.
5751
5752 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
5753
5754 * features/s390-gs-linux64.xml: New file.
5755 * features/s390-gs.xml: New file.
5756 * features/s390-gsbc.xml: New file.
5757 * features/s390x-gs-linux64.xml: New file.
5758 * features/Makefile (WHICH): Add s390-gs-linux64 and
5759 s390x-gs-linux64.
5760 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
5761 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
5762 * features/s390-gs-linux64.c: New generated file.
5763 * features/s390x-gs-linux64.c: New file.
5764 * regformats/s390-gs-linux64.dat: New file.
5765 * regformats/s390x-gs-linux64.dat: New file.
5766
5767 2017-09-23 Tom Tromey <tom@tromey.com>
5768
5769 * defs.h (make_cleanup_override_quit_handler): Don't declare.
5770
5771 2017-09-22 Tom Tromey <tom@tromey.com>
5772
5773 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
5774 type to scoped_restore_tmpl.
5775 <scoped_input_handler>: Initialize m_quit_handler directly.
5776
5777 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
5778
5779 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
5780 (cd_command): Likewise. Free "current_directory" before
5781 assigning to it.
5782 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
5783 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
5784 * top.c (gdb_dirbuf): Remove global declaration.
5785 * top.h (gdb_dirbuf): Likewise.
5786
5787 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
5788
5789 * gnulib/aclocal.m4: Regenerate.
5790 * gnulib/config.in: Regenerate.
5791 * gnulib/configure: Regenerate.
5792 * gnulib/import/Makefile.am: Regenerate.
5793 * gnulib/import/Makefile.in: Regenerate.
5794 * gnulib/import/assure.h: New file.
5795 * gnulib/import/at-func.c: Likewise
5796 * gnulib/import/chdir-long.c: New file.
5797 * gnulib/import/chdir-long.h: New file.
5798 * gnulib/import/cloexec.c: New file.
5799 * gnulib/import/cloexec.h: New file.
5800 * gnulib/import/close.c: New file.
5801 * gnulib/import/closedir.c: New file.
5802 * gnulib/import/dirent-private.h: New file.
5803 * gnulib/import/dup-safer.c: New file.
5804 * gnulib/import/dup.c: New file.
5805 * gnulib/import/dup2.c: New file.
5806 * gnulib/import/error.c: New file.
5807 * gnulib/import/error.h: New file.
5808 * gnulib/import/exitfail.c: New file.
5809 * gnulib/import/exitfail.h: New file.
5810 * gnulib/import/fchdir.c: New file.
5811 * gnulib/import/fcntl.c: New file.
5812 * gnulib/import/fcntl.in.h: New file.
5813 * gnulib/import/fd-hook.c: New file.
5814 * gnulib/import/fd-hook.h: New file.
5815 * gnulib/import/fd-safer.c: New file.
5816 * gnulib/import/fdopendir.c: New file.
5817 * gnulib/import/filename.h: New file.
5818 * gnulib/import/filenamecat-lgpl.c: New file.
5819 * gnulib/import/filenamecat.h: New file.
5820 * gnulib/import/fstat.c: New file.
5821 * gnulib/import/fstatat.c: New file.
5822 * gnulib/import/getcwd-lgpl.c: New file.
5823 * gnulib/import/getcwd.c: New file.
5824 * gnulib/import/getdtablesize.c: New file.
5825 * gnulib/import/getlogin_r.c: New file.
5826 * gnulib/import/getprogname.c: New file.
5827 * gnulib/import/getprogname.h: New file.
5828 * gnulib/import/gettext.h: New file.
5829 * gnulib/import/glob-libc.h: New file.
5830 * gnulib/import/glob.c: New file.
5831 * gnulib/import/glob.in.h: New file.
5832 * gnulib/import/intprops.h: New file.
5833 * gnulib/import/m4/chdir-long.m4: New file.
5834 * gnulib/import/m4/close.m4: New file.
5835 * gnulib/import/m4/closedir.m4: New file.
5836 * gnulib/import/m4/d-ino.m4: New file.
5837 * gnulib/import/m4/d-type.m4: New file.
5838 * gnulib/import/m4/dup.m4: New file.
5839 * gnulib/import/m4/dup2.m4: New file.
5840 * gnulib/import/m4/error.m4: New file.
5841 * gnulib/import/m4/fchdir.m4: New file.
5842 * gnulib/import/m4/fcntl.m4: New file.
5843 * gnulib/import/m4/fcntl_h.m4: New file.
5844 * gnulib/import/m4/fdopendir.m4: New file.
5845 * gnulib/import/m4/filenamecat.m4: New file.
5846 * gnulib/import/m4/fstat.m4: New file.
5847 * gnulib/import/m4/fstatat.m4: New file.
5848 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
5849 * gnulib/import/m4/getcwd-path-max.m4: New file.
5850 * gnulib/import/m4/getcwd.m4: New file.
5851 * gnulib/import/m4/getdtablesize.m4: New file.
5852 * gnulib/import/m4/getlogin_r.m4: New file.
5853 * gnulib/import/m4/getprogname.m4: New file.
5854 * gnulib/import/m4/glob.m4: New file.
5855 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
5856 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
5857 * gnulib/import/m4/mempcpy.m4: New file.
5858 * gnulib/import/m4/memrchr.m4: New file.
5859 * gnulib/import/m4/mode_t.m4: New file.
5860 * gnulib/import/m4/msvc-inval.m4: New file.
5861 * gnulib/import/m4/msvc-nothrow.m4: New file.
5862 * gnulib/import/m4/open.m4: New file.
5863 * gnulib/import/m4/openat.m4: New file.
5864 * gnulib/import/m4/opendir.m4: New file.
5865 * gnulib/import/m4/readdir.m4: New file.
5866 * gnulib/import/m4/realloc.m4: New file.
5867 * gnulib/import/m4/rewinddir.m4: New file.
5868 * gnulib/import/m4/save-cwd.m4: New file.
5869 * gnulib/import/m4/strdup.m4: New file.
5870 * gnulib/import/m4/strerror.m4: New file.
5871 * gnulib/import/m4/unistd-safer.m4: New file.
5872 * gnulib/import/mempcpy.c: New file.
5873 * gnulib/import/memrchr.c: New file.
5874 * gnulib/import/msvc-inval.c: New file.
5875 * gnulib/import/msvc-inval.h: New file.
5876 * gnulib/import/msvc-nothrow.c: New file.
5877 * gnulib/import/msvc-nothrow.h: New file.
5878 * gnulib/import/open.c: New file.
5879 * gnulib/import/openat-die.c: New file.
5880 * gnulib/import/openat-priv.h: New file.
5881 * gnulib/import/openat-proc.c: New file.
5882 * gnulib/import/openat.c: New file.
5883 * gnulib/import/openat.h: New file.
5884 * gnulib/import/opendir.c: New file.
5885 * gnulib/import/pipe-safer.c: New file.
5886 * gnulib/import/readdir.c: New file.
5887 * gnulib/import/realloc.c: New file.
5888 * gnulib/import/rewinddir.c: New file.
5889 * gnulib/import/save-cwd.c: New file.
5890 * gnulib/import/save-cwd.h: New file.
5891 * gnulib/import/strdup.c: New file.
5892 * gnulib/import/strerror-override.c: New file.
5893 * gnulib/import/strerror-override.h: New file.
5894 * gnulib/import/strerror.c: New file.
5895 * gnulib/import/unistd--.h: New file.
5896 * gnulib/import/unistd-safer.h: New file.
5897 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
5898 "getcwd" and "glob".
5899 * ser-tcp.c: Undefine "close" before redefining it.
5900
5901 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
5902
5903 * guile/scm-value.c (gdbscm_value_address): Initialize address,
5904 get rid of res_val.
5905
5906 2017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5907
5908 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
5909 <sol2,sparc>: Likewise.
5910 <sol2-64,i386>: Likewise.
5911
5912 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
5913 -Wdeprecated-declarations on *-*-solaris*.
5914 * configure: Regenerate.
5915
5916 * procfs.c: Include "nat/inferior.h".
5917 (procfs_info_proc): Fix typo.
5918
5919 2017-09-21 Kevin Buettner <kevinb@redhat.com>
5920
5921 * remote.c (vector): Include.
5922 (struct private_thread_info): Add field, thread_handle.
5923 (free_private_thread_info): Deallocate storage associated with
5924 thread handle.
5925 (get_private_info_thread): Initialize `thread_handle' field.
5926 (struct thread_item): Add field, thread_handle.
5927 (clear_threads_listing_context): Deallocate storage associated
5928 with thread handle.
5929 (start_thread): Add support for "handle" attribute.
5930 (thread_attributes): Add "handle".
5931 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
5932 field.
5933 (remote_update_thread_list): Update thread_handle.
5934 (remote_thread_handle_to_thread_info): New function.
5935 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
5936
5937 2017-09-21 Kevin Buettner <kevinb@redhat.com>
5938
5939 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
5940 function.
5941 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
5942 * python/python-internal.h (thread_object_type): Declare.
5943
5944 2017-09-21 Kevin Buettner <kevinb@redhat.com>
5945
5946 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
5947 (target_thread_handle_to_thread_info): Declare.
5948 * target.c (target_thread_handle_to_thread_info): New function.
5949 * target-delegates.c: Regenerate.
5950 * gdbthread.h (find_thread_by_handle): Declare.
5951 * thread.c (find_thread_by_handle): New function.
5952 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
5953 function.
5954 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
5955
5956 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
5957
5958 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
5959
5960 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
5961
5962 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
5963
5964 2017-09-21 Yao Qi <yao.qi@linaro.org>
5965
5966 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
5967 to gdb_target_obs.
5968
5969 2017-09-20 Tom Tromey <tom@tromey.com>
5970
5971 * breakpoint.c (struct counted_command_line): Remove.
5972 (breakpoint_commands): Update.
5973 (alloc_counted_command_line, incref_counted_command_line)
5974 (decref_counted_command_line, do_cleanup_counted_command_line)
5975 (make_cleanup_decref_counted_command_line): Remove.
5976 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
5977 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
5978 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
5979 (save_breakpoints): Update.
5980 * breakpoint.h (counted_command_line): Now a typedef to
5981 shared_ptr.
5982 (struct breakpoint) <commands>: Now a counted_command_line.
5983 (struct bpstats) <command>: Likewise.
5984
5985 2017-09-20 Tom Tromey <tom@tromey.com>
5986
5987 * breakpoint.c (struct commands_info, do_map_commands_command):
5988 Remove.
5989 (commands_command_1): Update.
5990 (iterate_over_related_breakpoints): Take a function_view.
5991 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
5992 (delete_command): Update.
5993 (map_breakpoint_numbers): Take a function_view.
5994 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
5995 (disable_command): Update.
5996 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
5997 (enable_command): Update.
5998 (struct disp_data, do_enable_breakpoint_disp)
5999 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
6000 (do_map_enable_delete_breakpoint): Remove.
6001 (enable_once_command, enable_count_command, enable_delete_command)
6002 (delete_trace_variable_command): Update.
6003
6004 2017-09-20 Tom Tromey <tom@tromey.com>
6005
6006 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
6007 (bpstat_clear): Use delete.
6008 (bpstats): New constructors.
6009 (bpstat_copy, bpstat_stop_status): Use new.
6010 (dprintf_after_condition_true): Update.
6011 * breakpoint.h (bpstats::bpstats): Add constructors.
6012 (bpstats::~bpstats): Add destructor.
6013
6014 2017-09-20 Pedro Alves <palves@redhat.com>
6015
6016 * eval.c (make_params): Delete, refactored as ...
6017 (class fake_method): ... this new type's ctor.
6018 (fake_method::~fake_method): New.
6019 (evaluate_subexp_standard): Use 'fake_method'.
6020
6021 2017-09-20 Tom Tromey <tom@tromey.com>
6022
6023 * windows-nat.c (get_windows_debug_event, windows_wait)
6024 (do_initial_windows_stuff, windows_attach): Update.
6025 * utils.c (vwarning, internal_vproblem): Update.
6026 (ui_unregister_input_event_handler_cleanup)
6027 (prepare_to_handle_input): Remove.
6028 (class scoped_input_handler): New.
6029 (defaulted_query, prompt_for_continue): Update.
6030 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
6031 Update.
6032 * top.c (undo_terminal_modifications_before_exit): Update.
6033 * target/target.h (target_terminal_init, target_terminal_inferior)
6034 (target_terminal_ours): Don't declare.
6035 (class target_terminal): New.
6036 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
6037 (target_terminal_ours_for_output)
6038 (make_cleanup_restore_target_terminal): Don't declare.
6039 (target_terminal_info): Remove.
6040 * target.c (enum terminal_state, terminal_state): Remove.
6041 (target_terminal::terminal_state): Define.
6042 (target_terminal::init): Rename from target_terminal_init.
6043 (target_terminal::inferior): Rename from
6044 target_terminal_inferior.
6045 (target_terminal::ours): Rename from target_terminal_ours.
6046 (target_terminal::ours_for_output): Rename from
6047 target_terminal_ours_for_output.
6048 (target_terminal::info): New method.
6049 (cleanup_restore_target_terminal)
6050 (make_cleanup_restore_target_terminal): Remove.
6051 * solib.c (handle_solib_event): Update.
6052 * remote.c (remote_serial_quit_handler): Update.
6053 (remote_terminal_inferior, remote_wait_as): Update.
6054 * record-full.c (record_full_wait_1): Update.
6055 * nto-procfs.c (procfs_create_inferior): Update.
6056 * nat/fork-inferior.c (startup_inferior): Update.
6057 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
6058 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
6059 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
6060 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
6061 (mi_breakpoint_created, mi_breakpoint_deleted)
6062 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
6063 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
6064 (mi_user_selected_context_changed, report_initial_inferior):
6065 Update.
6066 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
6067 (linux_nat_terminal_inferior): Update.
6068 * infrun.c (follow_fork_inferior)
6069 (handle_vfork_child_exec_or_exit, do_target_resume)
6070 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
6071 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
6072 Update.
6073 * inflow.c (child_terminal_init, info_terminal_command): Update.
6074 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
6075 (attach_command): Update.
6076 * infcall.c (call_thread_fsm_should_stop): Update.
6077 * gnu-nat.c (gnu_attach): Update.
6078 * extension.c (struct active_ext_lang_state)
6079 (restore_active_ext_lang): Update.
6080 * exceptions.c (print_flush): Update.
6081 * event-top.c (async_enable_stdin, default_quit_handler): Update.
6082 (struct quit_handler_cleanup_data, restore_quit_handler)
6083 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
6084 Remove.
6085 * cp-support.c (gdb_demangle): Update.
6086 * breakpoint.c (update_inserted_breakpoint_locations)
6087 (insert_breakpoint_locations, handle_jit_event)
6088 (disable_breakpoints_in_unloaded_shlib): Update.
6089 * annotate.c (annotate_breakpoints_invalid)
6090 (annotate_frames_invalid): Update.
6091
6092 2017-09-20 Tom Tromey <tom@tromey.com>
6093
6094 * main.c (catch_command_errors): Rename from
6095 catch_command_errors_const.
6096 (captured_main_1): Update.
6097
6098 2017-09-20 Pedro Alves <palves@redhat.com>
6099
6100 * cli/cli-cmds.c (list_command): Use print_sal_location.
6101 (print_sal_location): New function.
6102 (ambiguous_line_spec): Use print_sal_location.
6103 * linespec.c (symbol_to_sal): Record the symbol in the sal.
6104 * symtab.c (find_function_start_sal): Likewise.
6105 * symtab.h (symtab_and_line::symbol): New field.
6106
6107 2017-09-20 Pedro Alves <palves@redhat.com>
6108
6109 * linespec.c (minsym_found): Handle non-text minsyms.
6110 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
6111
6112 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
6113
6114 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
6115 backslash.
6116
6117 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
6118
6119 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
6120 vmovups instead vmovaps.
6121 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
6122
6123 2017-09-19 John Baldwin <jhb@FreeBSD.org>
6124
6125 * NEWS (Changes since GDB 8.0): Add starti.
6126 * infcmd.c (enum run_break): New.
6127 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
6128 case.
6129 (run_command): Use enum run_how.
6130 (start_command): Likewise.
6131 (starti_command): New function.
6132 (RUN_ARGS_HELP): New macro.
6133 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
6134 commands. Add starti command.
6135
6136 2017-09-19 Yao Qi <yao.qi@linaro.org>
6137
6138 * Makefile.in (monitor.o): Remove the rule.
6139
6140 2017-09-19 Yao Qi <yao.qi@linaro.org>
6141
6142 * annotate.h (struct annotate_arg_emitter): Use
6143 DISABLE_COPY_AND_ASSIGN.
6144 * common/refcounted-object.h (refcounted_object): Likewise.
6145 * completer.h (struct completion_result): Likewise.
6146 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
6147 * filename-seen-cache.h (filename_seen_cache): Likewise.
6148 * gdbcore.h (thread_section_name): Likewise.
6149 * gdb_regex.h (compiled_regex): Likewise.
6150 * gdbthread.h (scoped_restore_current_thread): Likewise.
6151 * inferior.h (scoped_restore_current_inferior): Likewise.
6152 * jit.c (jit_reader): Likewise.
6153 * linespec.h (struct linespec_result): Likewise.
6154 * mi/mi-parse.h (struct mi_parse): Likewise.
6155 * nat/fork-inferior.c (execv_argv): Likewise.
6156 * progspace.h (scoped_restore_current_program_space): Likewise.
6157 * python/python-internal.h (class gdbpy_enter): Likewise.
6158 * regcache.h (regcache): Likewise.
6159 * target-descriptions.c (struct tdesc_reg): Likewise.
6160 (struct tdesc_type): Likewise.
6161 (struct tdesc_feature): Likewise.
6162 * ui-out.h (ui_out_emit_type): Likewise.
6163
6164 2017-09-18 Simon Marchi <simon.marchi@ericsson.com>
6165
6166 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
6167 label abort_expression.
6168
6169 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6170
6171 * common/buffer.c (buffer_xml_printf): Adjust.
6172 * common/xml-utils.c (xml_escape_text): Change return type to
6173 std::string, update code accordingly.
6174 * common/xml-utils.h (xml_escape_text): Change return type to
6175 std::string.
6176 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
6177 * windows-tdep.c (windows_xfer_shared_library): Adjust.
6178 * unittests/xml-utils-selftests.c (test_xml_escape_text):
6179 Adjust.
6180
6181 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6182
6183 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
6184 (SUBDIR_UNITTESTS_OBS): Add new object file.
6185 * unittests/xml-utils-selftests.c: New file.
6186
6187 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6188
6189 * common/selftest.h (selftest): New struct/interface.
6190 (register_test): Add name parameter, add new overload.
6191 (run_tests): Add filter parameter.
6192 (for_each_selftest_ftype): New typedef.
6193 (for_each_selftest): New declaration.
6194 * common/selftest.c (tests): Change type to
6195 map<string, unique_ptr<selftest>>.
6196 (simple_selftest): New struct.
6197 (register_test): New function.
6198 (register_test): Add name parameter and use it.
6199 (run_tests): Add filter parameter and use it. Add prints.
6200 Adjust to vector -> map change.
6201 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
6202 registering selftests.
6203 * arm-tdep.c (_initialize_arm_tdep): Likewise.
6204 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
6205 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
6206 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
6207 * findvar.c (_initialize_findvar): Likewise.
6208 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
6209 * maint.c (maintenance_selftest): Update call to run_tests.
6210 (maintenance_info_selftests): New function.
6211 (_initialize_maint_cmds): Register "maintenance info selftests"
6212 command. Update "maintenance selftest" doc.
6213 * regcache.c (_initialize_regcache): Add names when registering
6214 selftests.
6215 * rust-exp.y (_initialize_rust_exp): Likewise.
6216 * selftest-arch.c (gdbarch_selftest): New struct.
6217 (gdbarch_tests): Remove.
6218 (register_test_foreach_arch): Add name parameter. Call
6219 register_test.
6220 (tests_with_arch): Remove, move most content to
6221 gdbarch_selftest::operator().
6222 (_initialize_selftests_foreach_arch): Remove.
6223 * selftest-arch.h (register_test_foreach_arch): Add name
6224 parameter.
6225 (run_tests_with_arch): New declaration.
6226 * utils-selftests.c (_initialize_utils_selftests): Add names
6227 when registering selftests.
6228 * utils.c (_initialize_utils): Likewise.
6229 * unittests/array-view-selftests.c
6230 (_initialize_array_view_selftests): Likewise.
6231 * unittests/environ-selftests.c (_initialize_environ_selftests):
6232 Likewise.
6233 * unittests/function-view-selftests.c
6234 (_initialize_function_view_selftests): Likewise.
6235 * unittests/offset-type-selftests.c
6236 (_initialize_offset_type_selftests): Likewise.
6237 * unittests/optional-selftests.c
6238 (_initialize_optional_selftests): Likewise.
6239 * unittests/scoped_restore-selftests.c
6240 (_initialize_scoped_restore_selftests): Likewise.
6241 * NEWS: Document "maintenance selftest" and "maint info
6242 selftests".
6243
6244 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6245
6246 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
6247 scoped_restore.
6248
6249 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6250
6251 * mi/mi-main.c (mi_load_progress): Make uiout variable
6252 a unique_ptr.
6253
6254 2017-09-15 Pedro Alves <palves@redhat.com>
6255
6256 * compile/compile-c-types.c (convert_enum, convert_int)
6257 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
6258
6259 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6260
6261 * dwarf2read.c (copy_string): Remove.
6262 (parse_macro_definition): Replace copy_string with savestring.
6263
6264 2017-09-15 Yao Qi <yao.qi@linaro.org>
6265
6266 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
6267 gdb_target_obs.
6268 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
6269 Likewise.
6270 (i[34567]86-*-linux*): Likewise.
6271
6272 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
6273
6274 * dwarf2expr.h (dwarf_stack_value): Add constructor.
6275 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
6276 <stack>: Change type to std::vector.
6277 <stack_len, stack_allocated>: Remove.
6278 <grow_stack>: Remove.
6279 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
6280 (dwarf_expr_context::~dwarf_expr_context): Remove.
6281 (dwarf_expr_context::grow_stack): Remove.
6282 (dwarf_expr_context::push): Adjust.
6283 (dwarf_expr_context::pop): Adjust.
6284 (dwarf_expr_context::fetch): Adjust.
6285 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
6286 (dwarf_expr_context::stack_empty_p): Adjust.
6287 (dwarf_expr_context::execute_stack_op): Adjust.
6288
6289 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
6290
6291 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
6292 return type to bool.
6293 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
6294
6295 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
6296
6297 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
6298 Change type to bool.
6299 (dwarf_stack_value) <in_stack_memory>: Likewise.
6300 (dwarf_expr_context) <push_address>: Change parameter type to
6301 bool.
6302 <fetch_in_stack_memory>: Change return type to bool.
6303 <push>: Change parameter type to bool.
6304 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
6305 to bool.
6306 (dwarf_expr_context::push_address): Likewise.
6307 (dwarf_expr_context::fetch_in_stack_memory): Change return type
6308 to bool.
6309 (dwarf_expr_context::execute_stack_op): Adjust.
6310 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
6311
6312 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
6313
6314 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
6315 (struct dwarf_expr_context) <n_pieces>: Remove.
6316 <pieces>: Change type to std::vector.
6317 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
6318 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
6319 pieces.
6320 (dwarf_expr_context::add_piece): Adjust.
6321 * dwarf2loc.c (struct piece_closure): Initialize fields.
6322 <n_pieces>: Remove.
6323 <pieces>: Change type to std::vector.
6324 (allocate_piece_closure): Adjust, change parameter to
6325 std::vector rvalue and std::move it to piece_closure.
6326 (rw_pieced_value): Adjust.
6327 (check_pieced_synthetic_pointer): Adjust.
6328 (indirect_synthetic_pointer): Adjust.
6329 (coerce_pieced_ref): Adjust.
6330 (free_pieced_value_closure): Adjust. Use delete to free
6331 piece_closure.
6332 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
6333 to allocate_piece_closure.
6334 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
6335
6336 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
6337
6338 * probe.h (probe_ops_cp): Remove typedef.
6339 (DEF_VEC_P (probe_ops_cp)): Remove.
6340 (all_probe_ops): Change type to std::vector.
6341 * probe.c (info_probes_for_ops): Adjust to vector change.
6342 (probe_linespec_to_ops): Likewise.
6343 (all_probe_ops): Change type to std::vector.
6344 (_initialize_probe): Adjust to vector change.
6345 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
6346 * elfread.c (elf_get_probes): Likewise.
6347 * stap-probe.c (_initialize_stap_probe): Likewise.
6348
6349 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
6350
6351 * probe.h (struct bound_probe): Define constructors.
6352 * probe.c (bound_probe_s): Remove typedef.
6353 (DEF_VEC_O (bound_probe_s)): Remove VEC.
6354 (collect_probes): Change return type to std::vector, remove
6355 cleanup.
6356 (compare_probes): Return bool, change parameter type. Change
6357 semantic to "less than".
6358 (gen_ui_out_table_header_info): Change parameter to std::vector
6359 and update.
6360 (exists_probe_with_pops): Likewise.
6361 (info_probes_for_ops): Update to std::vector change.
6362 (enable_probes_command): Likewise.
6363 (disable_probes_command): Likewise.
6364
6365 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
6366
6367 * probe.h (struct probe_ops) <get_probes>: Change parameter from
6368 vec to std::vector.
6369 * probe.c (parse_probes_in_pspace): Update.
6370 (find_probes_in_objfile): Update.
6371 (find_probe_by_pc): Update.
6372 (collect_probes): Update.
6373 (probe_any_get_probes): Update.
6374 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
6375 return type to reference to std::vector.
6376 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
6377 std::vector and update.
6378 (dtrace_process_dof): Likewise.
6379 (dtrace_get_probes): Likewise.
6380 * elfread.c (elf_get_probes): Change return type to std::vector,
6381 store an std::vector in bfd_data.
6382 (probe_key_free): Update to std::vector.
6383 * stap-probe.c (handle_stap_probe): Change parameter to
6384 std::vector and update.
6385 (stap_get_probes): Likewise.
6386 * symfile-debug.c (debug_sym_get_probes): Change return type to
6387 std::vector and update.
6388
6389 2017-09-11 Tom Tromey <tom@tromey.com>
6390
6391 * breakpoint.c (program_breakpoint_here_p): Update.
6392 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
6393 from make_show_memory_breakpoints_cleanup. Return a
6394 scoped_restore_tmpl<int>.
6395 (restore_show_memory_breakpoints): Remove.
6396 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
6397 * mem-break.c (memory_validate_breakpoint): Update.
6398 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
6399 (ia64_memory_remove_breakpoint): Update.
6400 (ia64_breakpoint_from_pc): Update.
6401 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
6402 from make_show_memory_breakpoints_cleanup.
6403
6404 2017-09-11 Tom Tromey <tom@tromey.com>
6405
6406 * d-namespace.c (d_lookup_symbol): Use std::string.
6407 (find_symbol_in_baseclass): Likewise.
6408
6409 2017-09-11 Tom Tromey <tom@tromey.com>
6410
6411 * ctf.c (ctf_start): Use std::string.
6412
6413 2017-09-11 Tom Tromey <tom@tromey.com>
6414
6415 * ada-lang.c (is_known_support_routine): Update.
6416 (ada_unhandled_exception_name_addr_from_raise): Update.
6417 * guile/scm-frame.c (gdbscm_frame_name): Update.
6418 * python/py-frame.c (frapy_name): Update.
6419 (frapy_function): Update.
6420 * stack.h (find_frame_funname): Update.
6421 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
6422 (print_frame): Update.
6423
6424 2017-09-11 Tom Tromey <tom@tromey.com>
6425
6426 * findcmd.c (put_bits): Take a gdb::byte_vector.
6427 (parse_find_args): Return gdb::byte_vector. "args" now const.
6428 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
6429 cleanups.
6430 (find_command): Update.
6431
6432 2017-09-11 Tom Tromey <tom@tromey.com>
6433
6434 * cli/cli-script.c (class scoped_restore_hook_in): New.
6435 (clear_hook_in_cleanup): Remove.
6436 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
6437 scoped_restore_hook_in.
6438
6439 2017-09-11 Tom Tromey <tom@tromey.com>
6440
6441 * cli/cli-script.c (restore_interp): Remove.
6442 (read_command_lines): Use scoped_restore_interp.
6443 * interps.c (scoped_restore_interp::set_temp): Rename from
6444 interp_set_temp.
6445 * interps.h (class scoped_restore_interp): New.
6446 (interp_set_temp): Remove.
6447
6448 2017-09-11 Tom Tromey <tom@tromey.com>
6449
6450 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
6451 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
6452 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
6453 scoped_restore.
6454 (mi_cmd_break_insert_1): Update.
6455 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
6456 scoped_restore.
6457
6458 2017-09-11 Tom Tromey <tom@tromey.com>
6459
6460 * demangle.c (demangle_command): Update.
6461 * breakpoint.c (disable_command): Update.
6462 (enable_command): Update.
6463 (find_location_by_number): Make "number" const. Use
6464 get_number_trailer.
6465 * cli/cli-utils.c (extract_arg): Return std::string.
6466 * probe.c (parse_probe_linespec): Update. Change types.
6467 (collect_probes): Take string arguments.
6468 (parse_probe_linespec): Likewise.
6469 (info_probes_for_ops): Update.
6470 (enable_probes_command): Update.
6471 (disable_probes_command): Update.
6472 * break-catch-sig.c (catch_signal_split_args): Update.
6473 * mi/mi-parse.c (mi_parse): Update.
6474
6475 2017-09-11 Tom Tromey <tom@tromey.com>
6476
6477 * language.h (language_enum): Make argument const.
6478 * language.c (language_enum): Make argument const.
6479
6480 2017-09-11 Tom Tromey <tom@tromey.com>
6481
6482 * common/common-utils.h (skip_to_space): Remove macro, redeclare
6483 as function.
6484 (skip_to_space): Rename from skip_to_space_const.
6485 * common/common-utils.c (skip_to_space): New function.
6486 (skip_to_space): Rename from skip_to_space_const.
6487 * cli/cli-utils.h (get_number): Rename from get_number_const.
6488 (extract_arg): Rename from extract_arg_const.
6489 * cli/cli-utils.c (get_number): Rename from get_number_const.
6490 (extract_arg): Rename from extract_arg_const.
6491 (number_or_range_parser::get_number): Use ::get_number.
6492 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
6493 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
6494 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
6495 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
6496 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
6497 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
6498 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
6499 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
6500
6501 2017-09-11 Tom Tromey <tom@tromey.com>
6502
6503 * python/python.c (do_start_initialization): Use
6504 py-event-types.def to initialize types.
6505 Define all object type structures.
6506 * python/python-internal.h: Don't declare event initialization
6507 functions.
6508 * python/py-threadevent.c (thread_event_object_type): Don't
6509 define.
6510 * python/py-stopevent.c (stop_event_object_type): Don't define.
6511 * python/py-signalevent.c (signal_event_object_type): Don't
6512 declare or define.
6513 * python/py-newobjfileevent.c (new_objfile_event_object_type)
6514 (clear_objfiles_event_object_type): Don't declare or define.
6515 * python/py-infevents.c (inferior_call_pre_event_object_type)
6516 (inferior_call_post_event_object_type)
6517 (register_changed_event_object_type)
6518 (memory_changed_event_object_type): Don't declare or define.
6519 * python/py-inferior.c (new_thread_event_object_type)
6520 (new_inferior_event_object_type)
6521 (inferior_deleted_event_object_type): Don't declare or define.
6522 * python/py-exitedevent.c (exited_event_object_type): Don't
6523 declare or define.
6524 * python/py-evts.c (gdbpy_initialize_py_events): Use
6525 py-all-events.def.
6526 * python/py-events.h (thread_event_object_type): Don't declare.
6527 (events_object): Use py-all-events.def.
6528 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
6529 py-event-types.def.
6530 * python/py-event-types.def: New file.
6531 * python/py-continueevent.c (create_continue_event_object): Don't
6532 declare or define.
6533 * python/py-bpevent.c (breakpoint_event_object_type): Don't
6534 declare or define.
6535 * python/py-all-events.def: New file.
6536
6537 2017-09-11 Tom Tromey <tom@tromey.com>
6538
6539 * python/py-threadevent.c (create_thread_event_object): Return
6540 gdbpy_ref.
6541 * python/py-stopevent.h (create_stop_event_object)
6542 (create_breakpoint_event_object, create_signal_event_object):
6543 Update.
6544 * python/py-stopevent.c (create_stop_event_object): Return
6545 gdbpy_ref.
6546 (emit_stop_event): Update.
6547 * python/py-signalevent.c (create_signal_event_object): Return
6548 gdbpy_ref.
6549 * python/py-infevents.c (create_inferior_call_event_object):
6550 Update.
6551 * python/py-event.h (create_event_object)
6552 (create_thread_event_object): Update.
6553 * python/py-event.c (create_event_object): Return gdbpy_ref.
6554 * python/py-continueevent.c: Return gdbpy_ref.
6555 * python/py-bpevent.c (create_breakpoint_event_object): Return
6556 gdbpy_ref.
6557
6558 2017-09-11 Tom Tromey <tom@tromey.com>
6559
6560 PR python/15622:
6561 * NEWS: Add entry.
6562 * python/python.c (do_start_initialization): Initialize new event
6563 types.
6564 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
6565 (gdbpy_initialize_inferior_deleted_event)
6566 (gdbpy_initialize_new_thread_event): Declare.
6567 * python/py-threadevent.c (create_thread_event_object): Add option
6568 "thread" parameter.
6569 * python/py-inferior.c (new_thread_event_object_type)
6570 (new_inferior_event_object_type)
6571 (inferior_deleted_event_object_type): Declare.
6572 (python_new_inferior, python_inferior_deleted): New functions.
6573 (add_thread_object): Emit new_thread event.
6574 (gdbpy_initialize_inferior): Attach new functions to corresponding
6575 observers.
6576 (new_thread, new_inferior, inferior_deleted): Define new event
6577 types.
6578 * python/py-evts.c (gdbpy_initialize_py_events): Add new
6579 registries.
6580 * python/py-events.h (events_object) <new_inferior,
6581 inferior_deleted, new_thread>: New fields.
6582 * python/py-event.h (create_thread_event_breakpoint): Add optional
6583 "thread" parameter.
6584
6585 2017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
6586
6587 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
6588 check current_ui instead.
6589 (internal_vproblem): Likewise.
6590
6591 2017-09-09 Simon Marchi <simon.marchi@ericsson.com>
6592
6593 * thread.c (print_thread_info_1): Remove unnecessary calls to
6594 uiout->is_mi_like_p.
6595
6596 2017-09-09 Tom Tromey <tom@tromey.com>
6597
6598 * namespace.h (add_using_directive): Update.
6599 * namespace.c (add_using_directive): Change type of excludes to
6600 std::vector.
6601 * dwarf2read.c (read_import_statement): Use std::vector.
6602 (read_namespace): Update.
6603 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
6604
6605 2017-09-09 Tom Tromey <tom@tromey.com>
6606
6607 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
6608
6609 2017-09-09 Tom Tromey <tom@tromey.com>
6610
6611 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
6612
6613 2017-09-09 Tom Tromey <tom@tromey.com>
6614
6615 * stack.c (func_command): Use gdb::def_vector.
6616
6617 2017-09-09 Tom Tromey <tom@tromey.com>
6618
6619 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
6620 ui_out_emit_list, ui_out_emit_tuple.
6621 (mi_cmd_var_update): Likewise.
6622
6623 2017-09-09 Tom Tromey <tom@tromey.com>
6624
6625 * mi/mi-interp.c (mi_user_selected_context_changed): Use
6626 ui_out_redirect_pop.
6627 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
6628 ui_out_redirect_pop.
6629 * utils.c (do_ui_out_redirect_pop)
6630 (make_cleanup_ui_out_redirect_pop): Remove.
6631 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
6632 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
6633 * ui-out.h (ui_out_redirect_pop): New class.
6634
6635 2017-09-09 Tom Tromey <tom@tromey.com>
6636
6637 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
6638 (list_available_thread_groups, mi_cmd_list_thread_groups)
6639 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
6640 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
6641 Likewise.
6642
6643 2017-09-09 Tom Tromey <tom@tromey.com>
6644
6645 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
6646 ui_out_emit_tuple.
6647
6648 2017-09-09 Tom Tromey <tom@tromey.com>
6649
6650 * target.c (flash_erase_command): Use ui_out_emit_tuple.
6651 * stack.c (print_frame): Use ui_out_emit_tuple.
6652 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
6653 (info_spu_mailbox_command, info_spu_dma_command)
6654 (info_spu_proxydma_command): Likewise.
6655 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
6656 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
6657 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
6658 ui_out_emit_tuple.
6659 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
6660
6661 2017-09-09 Tom Tromey <tom@tromey.com>
6662
6663 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
6664 (class ui_out_emit_table): Update comment.
6665 * ui-out.c (do_cleanup_table_end)
6666 (make_cleanup_ui_out_table_begin_end): Remove.
6667 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
6668 (info_spu_dma_cmdlist): Likewise.
6669 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
6670 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
6671 ui_out_emit_table.
6672
6673 2017-09-09 Tom Tromey <tom@tromey.com>
6674
6675 * thread.c (print_thread_info_1): Use ui_out_emit_table,
6676 ui_out_emit_list, gdb::optional.
6677
6678 2017-09-09 John Baldwin <jhb@FreeBSD.org>
6679
6680 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
6681 prototype.
6682 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
6683 prototype.
6684 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
6685 prototype.
6686 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
6687 * ada-exp.y: Remove _initialize_ada_exp prototype.
6688 * ada-lang.c: Remove _initialize_ada_language prototype.
6689 * ada-tasks.c: Remove _initialize_tasks prototype.
6690 * addrmap.c: Remove _initialize_addrmap prototype.
6691 * agent.c: Remove _initialize_agent prototype.
6692 * aix-thread.c: Remove _initialize_aix_thread prototype.
6693 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
6694 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
6695 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
6696 prototype.
6697 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
6698 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
6699 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
6700 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
6701 prototype.
6702 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
6703 prototype.
6704 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
6705 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
6706 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
6707 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
6708 prototype.
6709 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
6710 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
6711 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
6712 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
6713 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
6714 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
6715 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
6716 prototype.
6717 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
6718 prototype.
6719 * annotate.c: Remove _initialize_annotate prototype.
6720 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
6721 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
6722 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
6723 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
6724 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
6725 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
6726 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
6727 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
6728 prototype.
6729 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
6730 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
6731 * auto-load.c: Remove _initialize_auto_load prototype.
6732 * auxv.c: Remove _initialize_auxv prototype.
6733 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
6734 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
6735 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
6736 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
6737 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
6738 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
6739 prototype.
6740 * break-catch-throw.c: Remove _initialize_break_catch_throw
6741 prototype.
6742 * breakpoint.c: Remove _initialize_breakpoint prototype.
6743 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
6744 * btrace.c: Remove _initialize_btrace prototype.
6745 * charset.c: Remove _initialize_charset prototype.
6746 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
6747 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
6748 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
6749 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
6750 * cli/cli-script.c: Remove _initialize_cli_script prototype.
6751 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
6752 * coffread.c: Remove _initialize_coffread prototype.
6753 * compile/compile.c: Remove _initialize_compile prototype.
6754 * complaints.c: Remove _initialize_complaints prototype.
6755 * completer.c: Remove _initialize_completer prototype.
6756 * copying.awk: Remove _initialize_copying prototype.
6757 * copying.c: Regenerate.
6758 * core-regset.c: Remove _initialize_core_regset prototype.
6759 * corefile.c: Remove _initialize_core prototype.
6760 * corelow.c: Remove _initialize_corelow prototype.
6761 * cp-abi.c: Remove _initialize_cp_abi prototype.
6762 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
6763 * cp-support.c: Remove _initialize_cp_support prototype.
6764 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
6765 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
6766 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
6767 * ctf.c: Remove _initialize_ctf prototype.
6768 * d-lang.c: Remove _initialize_d_language prototype.
6769 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
6770 prototype.
6771 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
6772 * dbxread.c: Remove _initialize_dbxread prototype.
6773 * dcache.c: Remove _initialize_dcache prototype.
6774 * demangle.c: Remove _initialize_demangler prototype.
6775 * disasm-selftests.c: Remove _initialize_disasm_selftests
6776 prototype.
6777 * disasm.c: Remove _initialize_disasm prototype.
6778 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
6779 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
6780 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
6781 prototype.
6782 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
6783 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
6784 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
6785 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
6786 * elfread.c: Remove _initialize_elfread prototype.
6787 * exec.c: Remove _initialize_exec prototype.
6788 * extension.c: Remove _initialize_extension prototype.
6789 * f-lang.c: Remove _initialize_f_language prototype.
6790 * f-valprint.c: Remove _initialize_f_valprint prototype.
6791 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
6792 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
6793 * filesystem.c: Remove _initialize_filesystem prototype.
6794 * findcmd.c: Remove _initialize_mem_search prototype.
6795 * fork-child.c: Remove _initialize_fork_child prototype.
6796 * frame-base.c: Remove _initialize_frame_base prototype.
6797 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
6798 * frame.c: Remove _initialize_frame prototype.
6799 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
6800 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
6801 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
6802 * gcore.c: Remove _initialize_gcore prototype.
6803 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
6804 * gdbarch.c: Regenerate.
6805 * gdbarch.sh: Remove _initialize_gdbarch prototype.
6806 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
6807 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
6808 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
6809 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
6810 * go-lang.c: Remove _initialize_go_language prototype.
6811 * go32-nat.c: Remove _initialize_go32_nat prototype.
6812 * guile/guile.c: Remove _initialize_guile prototype.
6813 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
6814 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
6815 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
6816 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
6817 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
6818 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
6819 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
6820 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
6821 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
6822 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
6823 prototype.
6824 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
6825 prototype.
6826 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
6827 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
6828 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
6829 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
6830 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
6831 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
6832 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
6833 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
6834 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
6835 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
6836 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
6837 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
6838 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
6839 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
6840 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
6841 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
6842 prototype.
6843 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
6844 prototype.
6845 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
6846 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
6847 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
6848 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
6849 * infcall.c: Remove _initialize_infcall prototype.
6850 * infcmd.c: Remove _initialize_infcmd prototype.
6851 * inferior.c: Remove _initialize_inferiors prototype.
6852 * inflow.c: Remove _initialize_inflow prototype.
6853 * infrun.c: Remove _initialize_infrun prototype.
6854 * interps.c: Remove _initialize_interpreter prototype.
6855 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
6856 * jit.c: Remove _initialize_jit prototype.
6857 * language.c: Remove _initialize_language prototype.
6858 * linux-fork.c: Remove _initialize_linux_fork prototype.
6859 * linux-nat.c: Remove _initialize_linux_nat prototype.
6860 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
6861 * linux-thread-db.c: Remove _initialize_thread_db prototype.
6862 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
6863 * m2-lang.c: Remove _initialize_m2_language prototype.
6864 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
6865 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
6866 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
6867 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
6868 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
6869 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
6870 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
6871 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
6872 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
6873 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
6874 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
6875 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
6876 * machoread.c: Remove _initialize_machoread prototype.
6877 * macrocmd.c: Remove _initialize_macrocmd prototype.
6878 * macroscope.c: Remove _initialize_macroscope prototype.
6879 * maint.c: Remove _initialize_maint_cmds prototype.
6880 * mdebugread.c: Remove _initialize_mdebugread prototype.
6881 * memattr.c: Remove _initialize_mem prototype.
6882 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
6883 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
6884 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
6885 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
6886 * mi/mi-main.c: Remove _initialize_mi_main prototype.
6887 * microblaze-linux-tdep.c: Remove
6888 _initialize_microblaze_linux_tdep prototype.
6889 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
6890 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
6891 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
6892 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
6893 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
6894 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
6895 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
6896 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
6897 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
6898 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
6899 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
6900 prototype.
6901 * mipsread.c: Remove _initialize_mipsread prototype.
6902 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
6903 prototype.
6904 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
6905 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
6906 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
6907 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
6908 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
6909 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
6910 prototype.
6911 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
6912 * nto-procfs.c: Remove _initialize_procfs prototype.
6913 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
6914 * objc-lang.c: Remove _initialize_objc_language prototype.
6915 * objfiles.c: Remove _initialize_objfiles prototype.
6916 * observer.c: Remove observer_test_first_notification_function,
6917 observer_test_second_notification_function,
6918 observer_test_third_notification_function, and
6919 _initialize_observer prototypes.
6920 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
6921 * osabi.c: Remove _initialize_gdb_osabi prototype.
6922 * osdata.c: Remove _initialize_osdata prototype.
6923 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
6924 * parse.c: Remove _initialize_parse prototype.
6925 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
6926 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
6927 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
6928 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
6929 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
6930 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
6931 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
6932 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
6933 * printcmd.c: Remove _initialize_printcmd prototype.
6934 * probe.c: Remove _initialize_probe prototype.
6935 * proc-api.c: Remove _initialize_proc_api prototype.
6936 * proc-events.c: Remove _initialize_proc_events prototype.
6937 * proc-service.c: Remove _initialize_proc_service prototype.
6938 * procfs.c: Remove _initialize_procfs prototype.
6939 * psymtab.c: Remove _initialize_psymtab prototype.
6940 * python/python.c: Remove _initialize_python prototype.
6941 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
6942 * record-btrace.c: Remove _initialize_record_btrace prototype.
6943 * record-full.c: Remove _initialize_record_full prototype.
6944 * record.c: Remove _initialize_record prototype.
6945 * regcache.c: Remove _initialize_regcache prototype.
6946 * reggroups.c: Remove _initialize_reggroup prototype.
6947 * remote-notif.c: Remove _initialize_notif prototype.
6948 * remote-sim.c: Remove _initialize_remote_sim prototype.
6949 * remote.c: Remove _initialize_remote prototype.
6950 * reverse.c: Remove _initialize_reverse prototype.
6951 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
6952 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
6953 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
6954 prototype.
6955 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
6956 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
6957 * rust-exp.y: Remove _initialize_rust_exp prototype.
6958 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
6959 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
6960 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
6961 * score-tdep.c: Remove _initialize_score_tdep prototype.
6962 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
6963 prototype.
6964 * ser-go32.c: Remove _initialize_ser_dos prototype.
6965 * ser-mingw.c: Remove _initialize_ser_windows prototype.
6966 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
6967 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
6968 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
6969 * serial.c: Remove _initialize_serial prototype.
6970 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
6971 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
6972 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
6973 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
6974 * skip.c: Remove _initialize_step_skip prototype.
6975 * sol-thread.c: Remove _initialize_sol_thread prototype.
6976 * solib-aix.c: Remove _initialize_solib_aix prototype.
6977 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
6978 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
6979 * solib-frv.c: Remove _initialize_frv_solib prototype.
6980 * solib-spu.c: Remove _initialize_spu_solib prototype.
6981 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
6982 * solib-target.c: Remove _initialize_solib_target prototype.
6983 * solib.c: Remove _initialize_solib prototype.
6984 * source.c: Remove _initialize_source prototype.
6985 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
6986 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
6987 prototype.
6988 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
6989 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
6990 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
6991 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
6992 prototype.
6993 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
6994 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
6995 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
6996 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
6997 prototype.
6998 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
6999 prototype.
7000 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
7001 prototype.
7002 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
7003 prototype.
7004 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
7005 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
7006 prototype.
7007 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
7008 prototype.
7009 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
7010 prototype.
7011 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
7012 prototype.
7013 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
7014 prototype.
7015 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
7016 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
7017 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
7018 * stabsread.c: Remove _initialize_stabsread prototype.
7019 * stack.c: Remove _initialize_stack prototype.
7020 * stap-probe.c: Remove _initialize_stap_probe prototype.
7021 * std-regs.c: Remove _initialize_frame_reg prototype.
7022 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
7023 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
7024 * symfile.c: Remove _initialize_symfile prototype.
7025 * symmisc.c: Remove _initialize_symmisc prototype.
7026 * symtab.c: Remove _initialize_symtab prototype.
7027 * target-dcache.c: Remove _initialize_target_dcache prototype.
7028 * target-descriptions.c: Remove _initialize_target_descriptions
7029 prototype.
7030 * thread.c: Remove _initialize_thread prototype.
7031 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
7032 prototype.
7033 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
7034 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
7035 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
7036 prototype.
7037 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
7038 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
7039 * tracefile.c: Remove _initialize_tracefile prototype.
7040 * tracepoint.c: Remove _initialize_tracepoint prototype.
7041 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
7042 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
7043 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
7044 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
7045 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
7046 * tui/tui-win.c: Remove _initialize_tui_win prototype.
7047 * tui/tui.c: Remove _initialize_tui prototype.
7048 * typeprint.c: Remove _initialize_typeprint prototype.
7049 * user-regs.c: Remove _initialize_user_regs prototype.
7050 * utils.c: Remove _initialize_utils prototype.
7051 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
7052 * valarith.c: Remove _initialize_valarith prototype.
7053 * valops.c: Remove _initialize_valops prototype.
7054 * valprint.c: Remove _initialize_valprint prototype.
7055 * value.c: Remove _initialize_values prototype.
7056 * varobj.c: Remove _initialize_varobj prototype.
7057 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
7058 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
7059 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
7060 * windows-nat.c: Remove _initialize_windows_nat,
7061 _initialize_check_for_gdb_ini, and _initialize_loadable
7062 prototypes.
7063 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
7064 * xcoffread.c: Remove _initialize_xcoffread prototype.
7065 * xml-support.c: Remove _initialize_xml_support prototype.
7066 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
7067 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
7068 prototype.
7069 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
7070 prototype.
7071 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
7072
7073 2017-09-08 Keith Seitz <keiths@redhat.com>
7074
7075 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
7076 field.
7077
7078 2017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
7079
7080 * f-valprint.c (f_val_print): Remove check for one byte
7081 sized integers. Remove printing of character type.
7082
7083 2017-09-08 Frank Penczek <frank.penczek@intel.com>
7084 Christoph Weinmann <christoph.t.weinmann@intel.com>
7085 Bernhard Heckel <bernhard.heckel@intel.com>
7086
7087 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
7088 to maintain proper indentation when printing pointers/refs.
7089
7090 2017-09-07 Joel Brobecker <brobecker@adacore.com>
7091
7092 GDB 8.0.1 released.
7093
7094 2017-09-07 Joel Brobecker <brobecker@adacore.com>
7095
7096 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
7097
7098 2017-09-05 Tom Tromey <tom@tromey.com>
7099
7100 * parse.c (funcall_chain): Now a std::vector.
7101 (start_arglist, end_arglist): Simplify.
7102 (free_funcalls): Remove.
7103 (parse_exp_in_context_1): Remove cleanup.
7104
7105 2017-09-05 Tom Tromey <tom@tromey.com>
7106
7107 * go-exp.y (go_parse): Don't create a cleanup.
7108
7109 2017-09-05 Tom Tromey <tom@tromey.com>
7110
7111 * d-exp.y (PrimaryExpression): Use std::string.
7112 (d_parse): Don't create a cleanup.
7113
7114 2017-09-05 Tom Tromey <tom@tromey.com>
7115
7116 * utils.c (do_clear_parser_state): Remove.
7117 (make_cleanup_clear_parser_state): Remove.
7118 * p-exp.y (pascal_parse): Use scoped_restore.
7119 * m2-exp.y (m2_parse): Use scoped_restore.
7120 * f-exp.y (f_parse): Use scoped_restore.
7121 * d-exp.y (d_parse): Use scoped_restore.
7122 * c-exp.y (c_parse): Use scoped_restore.
7123 * ada-exp.y (ada_parse): Use scoped_restore.
7124 * utils.h (make_cleanup_clear_parser_state): Remove.
7125
7126 2017-09-06 Keith Seitz <keiths@redhat.com>
7127
7128 * dwarf2read.c (dw2_linkage_name_attr): New function.
7129 (dw2_linkage_name): New function.
7130 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
7131 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
7132 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
7133
7134 2017-09-06 Kamil Rytarowski <n54@gmx.com>
7135
7136 * config/djgpp/djconfig.sh: Correct shell portability issue.
7137
7138 2017-09-06 Kamil Rytarowski <n54@gmx.com>
7139
7140 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
7141
7142 2017-09-06 John Baldwin <jhb@FreeBSD.org>
7143
7144 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
7145 * NEWS: Mention new FreeBSD/mips native configuration.
7146 * configure.host: Add aarch64*-*-freebsd*.
7147 * configure.nat: Likewise.
7148 * aarch64-fbsd-nat.c: New file.
7149
7150 2017-09-06 John Baldwin <jhb@FreeBSD.org>
7151
7152 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
7153 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
7154 * NEWS: Mention new FreeBSD/aarch64 target.
7155 * configure.tgt: Add aarch64*-*-freebsd*.
7156 * aarch64-fbsd-tdep.c: New file.
7157 * aarch64-fbsd-tdep.h: New file.
7158
7159 2017-09-06 Kamil Rytarowski <n54@gmx.com>
7160
7161 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
7162
7163 2017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
7164
7165 * parse.c (find_minsym_type_and_address): Don't relocate addresses
7166 of TLS symbols.
7167
7168 2017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7169
7170 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
7171 call.
7172
7173 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
7174
7175 * infrun.c (follow_exec): Call add_thread after
7176 target_find_description.
7177
7178 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
7179
7180 * infrun.c (handle_inferior_event_1): When exec'ing, read
7181 stop_pc after follow_exec.
7182
7183 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
7184
7185 * remote.c (process_g_packet): Update error message.
7186
7187 2017-09-05 Yao Qi <yao.qi@linaro.org>
7188
7189 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
7190 targets.
7191
7192 2017-09-05 Pedro Alves <palves@redhat.com>
7193
7194 * eval.c (eval_call, evaluate_funcall): New functions, factored
7195 out from ...
7196 (evaluate_subexp_standard): ... this.
7197
7198 2017-09-05 Yao Qi <yao.qi@linaro.org>
7199
7200 * amd64-tdep.c (amd64_target_description): Create target
7201 descriptions.
7202 (_initialize_amd64_tdep): Don't call functions
7203 initialize_tdesc_amd64_*. Add self tests.
7204 * arch/amd64.c (amd64_create_target_description): Add parameter
7205 is_linux. Call set_tdesc_osabi if is_linux is true.
7206 * arch/amd64.h (amd64_create_target_description): Update the
7207 declaration.
7208 * arch/i386.c (i386_create_target_description): Add parameter
7209 is_linux. Call set_tdesc_osabi if is_linux is true.
7210 * arch/i386.h (i386_create_target_description): Update
7211 declaration.
7212 * configure.tgt: Add i386.o to gdb_target_obs.
7213 * features/Makefile (XMLTOC): Remove i386/*.xml.
7214 * features/i386/amd64-avx-avx512.c: Remove.
7215 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
7216 * features/i386/amd64-avx-mpx.c: Remove.
7217 * features/i386/amd64-avx.c: Remove.
7218 * features/i386/amd64-mpx.c: Remove.
7219 * features/i386/amd64.c: Remove.
7220 * features/i386/i386-avx-avx512.c: Remove.
7221 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
7222 * features/i386/i386-avx-mpx.c: Remove.
7223 * features/i386/i386-avx.c: Remove.
7224 * features/i386/i386-mmx.c: Remove.
7225 * features/i386/i386-mpx.c: Remove.
7226 * features/i386/i386.c: Remove.
7227 * i386-tdep.c: Don't include features/i386/i386*.c., include
7228 target-descriptions.h and arch/i386.h.
7229 (i386_target_description): Create target descriptions.
7230 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
7231 functions. Do self tests.
7232
7233 2017-09-05 Yao Qi <yao.qi@linaro.org>
7234
7235 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
7236 * features/i386/amd64-avx-avx512-linux.c: Removed.
7237 * features/i386/amd64-avx-linux.c: Removed.
7238 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
7239 * features/i386/amd64-avx-mpx-linux.c: Removed.
7240 * features/i386/amd64-linux.c: Removed.
7241 * features/i386/amd64-mpx-linux.c: Removed.
7242 * features/i386/x32-avx-avx512-linux.c: Removed.
7243 * features/i386/x32-avx-linux.c: Removed.
7244 * features/i386/x32-linux.c: Removed.
7245
7246 2017-09-05 Yao Qi <yao.qi@linaro.org>
7247
7248 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
7249 features/i386/*.c.
7250 (amd64_linux_read_description): Call
7251 amd64_create_target_description.
7252 * arch/amd64.c: New file.
7253 * arch/amd64.h: New file.
7254 * configure.tgt (x86_64-*-linux*): Append amd64.o.
7255 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
7256
7257 2017-09-05 Yao Qi <yao.qi@linaro.org>
7258
7259 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
7260 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
7261 (amd64_linux_read_description): Create target descriptions.
7262 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
7263 functions. Add unit tests.
7264 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
7265 x32-core.xml.
7266 * features/i386/64bit-avx.c: Generated.
7267 * features/i386/64bit-avx512.c: Generated.
7268 * features/i386/64bit-core.c: Generated.
7269 * features/i386/64bit-linux.c: Generated.
7270 * features/i386/64bit-mpx.c: Generated.
7271 * features/i386/64bit-pkeys.c: Generated.
7272 * features/i386/64bit-segments.c: Generated.
7273 * features/i386/64bit-sse.c: Generated.
7274 * features/i386/x32-core.c: Generated.
7275 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
7276 c files for amd64-linux and x32-linux.
7277
7278 2017-09-05 Yao Qi <yao.qi@linaro.org>
7279
7280 * amd64-linux-tdep.c (amd64_linux_read_description): New
7281 function.
7282 (amd64_linux_core_read_description): Call
7283 amd64_linux_read_description.
7284 (amd64_linux_init_abi): Likewise.
7285 (amd64_x32_linux_init_abi): Likewise.
7286 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
7287 * x86-linux-nat.c (x86_linux_read_description): Call
7288 amd64_linux_read_description.
7289
7290 2017-09-05 Yao Qi <yao.qi@linaro.org>
7291
7292 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
7293 comments.
7294
7295 2017-09-05 Yao Qi <yao.qi@linaro.org>
7296
7297 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
7298 * features/i386/i386-avx-avx512-linux.c: Remove.
7299 * features/i386/i386-avx-linux.c: Remove.
7300 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
7301 * features/i386/i386-avx-mpx-linux.c: Remove.
7302 * features/i386/i386-linux.c: Remove.
7303 * features/i386/i386-mmx-linux.c: Remove.
7304 * features/i386/i386-mpx-linux.c: Remove.
7305
7306 2017-09-05 Yao Qi <yao.qi@linaro.org>
7307
7308 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
7309 (SFILES): Add arch/i386.c.
7310 (HFILES_NO_SRCDIR): Add arch/i386.h.
7311 * arch/i386.c: New file.
7312 * arch/i386.h: New file.
7313 * arch/tdesc.h (allocate_target_description): Declare.
7314 (set_tdesc_architecture): Declare.
7315 (set_tdesc_osabi): Declare.
7316 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
7317 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
7318 include arch/i386.h.
7319 (i386_linux_read_description): Remove code and call
7320 i386_create_target_description.
7321 (set_tdesc_architecture): New function.
7322 (set_tdesc_osabi): New function.
7323 * target-descriptions.h (allocate_target_description): Remove.
7324
7325 2017-09-05 Yao Qi <yao.qi@linaro.org>
7326
7327 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
7328 * target-descriptions.c (tdesc_create_feature): Likewise, and
7329 adjust code.
7330 * features/i386/32bit-avx.c: Re-generated.
7331 * features/i386/32bit-avx512.c: Re-generated.
7332 * features/i386/32bit-core.c: Re-generated.
7333 * features/i386/32bit-linux.c: Re-generated.
7334 * features/i386/32bit-mpx.c: Re-generated.
7335 * features/i386/32bit-pkeys.c: Re-generated.
7336 * features/i386/32bit-sse.c: Re-generated.
7337
7338 2017-09-05 Yao Qi <yao.qi@linaro.org>
7339
7340 * regformats/regdef.h (struct reg): Override operator == and !=.
7341
7342 2017-09-05 Yao Qi <yao.qi@linaro.org>
7343
7344 * arch/tdesc.h: New file.
7345 * regformats/regdat.sh: Generate code using tdesc_create_reg.
7346 * target-descriptions.c: Update comments.
7347 * target-descriptions.h: Include "arch/tdesc.h". Remove the
7348 declarations.
7349 * features/i386/32bit-avx.c: Re-generated.
7350 * features/i386/32bit-avx512.c: Re-generated.
7351 * features/i386/32bit-core.c: Re-generated.
7352 * features/i386/32bit-linux.c: Re-generated.
7353 * features/i386/32bit-mpx.c: Re-generated.
7354 * features/i386/32bit-pkeys.c: Re-generated.
7355 * features/i386/32bit-sse.c: Re-generated.
7356
7357 2017-09-05 Yao Qi <yao.qi@linaro.org>
7358
7359 * regformats/regdat.sh: Update generated code.
7360
7361 2017-09-05 Yao Qi <yao.qi@linaro.org>
7362
7363 * regformats/regdat.sh: Adjust code order.
7364
7365 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
7366
7367 * expprint.c (dump_subexp_body_standard): Use constant format
7368 string in fprintf_filtered call.
7369
7370 2017-09-04 John Baldwin <jhb@FreeBSD.org>
7371
7372 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
7373 NetBSD/i386.
7374 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
7375
7376 2017-09-04 John Baldwin <jhb@FreeBSD.org>
7377
7378 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
7379
7380 2017-09-04 John Baldwin <jhb@FreeBSD.org>
7381
7382 * bsd-kvm.o: Define _KMEMUSER.
7383 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
7384 * configure: Regenerate.
7385
7386 2017-09-04 John Baldwin <jhb@FreeBSD.org>
7387
7388 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
7389 * i386-fbsd-nat.c: Likewise.
7390
7391 2017-09-04 John Baldwin <jhb@FreeBSD.org>
7392
7393 * unittests/array-view-selftests.c: Add include of <array>.
7394
7395 2017-09-04 John Baldwin <jhb@FreeBSD.org>
7396
7397 * spu-tdep.c (flush_ea_cache): Add missing argument to
7398 call_function_by_hand.
7399
7400 2017-09-04 Pedro Alves <palves@redhat.com>
7401
7402 * NEWS (Safer support for debugging with no debug info): New.
7403
7404 2017-09-04 Pedro Alves <palves@redhat.com>
7405
7406 * c-exp.y (function_method, function_method_void): Add current
7407 instance flags to TYPE_INSTANCE.
7408 * dwarf2read.c (check_modifier): New.
7409 (compute_delayed_physnames): Assert that only C++ adds delayed
7410 physnames. Mark fn_fields as const/volatile depending on
7411 physname.
7412 * eval.c (make_params): New type_instance_flags parameter. Use
7413 it as the new type's instance flags.
7414 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
7415 flags element and pass it to make_params.
7416 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
7417 instance flags element.
7418 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
7419 * gdbtypes.h: Include "enum-flags.h".
7420 (type_instance_flags): New enum-flags type.
7421 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
7422 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
7423 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
7424 (follow_type_instance_flags): New function.
7425 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
7426 * parser-defs.h (follow_type_instance_flags): Declare.
7427 * valops.c (value_struct_elt_for_reference): const/volatile must
7428 match too.
7429
7430 2017-09-04 Pedro Alves <palves@redhat.com>
7431
7432 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
7433 function/method scopes; lookup the nested name as a function local
7434 static variable.
7435
7436 2017-09-04 Pedro Alves <palves@redhat.com>
7437
7438 (%type <voidval>): Add function_method.
7439 * c-exp.y (exp): New production for calls with no arguments.
7440 (function_method, function_method_void_or_typelist): New
7441 productions.
7442 (exp): New production for "method()::static_var".
7443 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
7444 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
7445 Handle OP_FUNC_STATIC_VAR.
7446 * parse.c (operator_length_standard):
7447 Handle OP_FUNC_STATIC_VAR.
7448
7449 2017-09-04 Pedro Alves <palves@redhat.com>
7450
7451 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
7452 handling.
7453 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
7454 Ditto.
7455 * parse.c (operator_length_standard, operator_check_standard):
7456 Ditto.
7457 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
7458
7459 2017-09-04 Pedro Alves <palves@redhat.com>
7460
7461 * ax-gdb.c: Include "typeprint.h".
7462 (gen_expr_for_cast): New function.
7463 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
7464 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
7465 type is unknown.
7466 * dwarf2read.c (new_symbol_full): Fallback to int instead of
7467 nodebug_data_symbol.
7468 * eval.c: Include "typeprint.h".
7469 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
7470 Error out if symbol has unknown type.
7471 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
7472 evaluate_subexp_for_cast.
7473 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
7474 OP_VAR_MSYM_VALUE.
7475 (evaluate_subexp_for_cast): New function.
7476 * gdbtypes.c (init_nodebug_var_type): New function.
7477 (objfile_type): Use it to initialize types of variables with no
7478 debug info.
7479 * typeprint.c (error_unknown_type): New.
7480 * typeprint.h (error_unknown_type): New declaration.
7481 * compile/compile-c-types.c (convert_type_basic): Handle
7482 TYPE_CODE_ERROR; warn and fallback to int for variables with
7483 unknown type.
7484
7485 2017-09-04 Pedro Alves <palves@redhat.com>
7486
7487 * eval.c (evaluate_var_value): New function, factored out from ...
7488 (evaluate_subexp_standard): ... here.
7489
7490 2017-09-04 Pedro Alves <palves@redhat.com>
7491
7492 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
7493 Remove useless assignments to 'op'.
7494
7495 2017-09-04 Pedro Alves <palves@redhat.com>
7496
7497 * eval.c (eval_skip_value): New function.
7498 (evaluate_subexp_standard): Use it.
7499
7500 2017-09-04 Pedro Alves <palves@redhat.com>
7501
7502 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
7503 function name from symbol/minsym and pass it to
7504 error_call_unknown_return_type.
7505
7506 2017-09-04 Pedro Alves <palves@redhat.com>
7507
7508 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
7509 * ax-gdb.c (gen_msym_var_ref): New function.
7510 (gen_expr): Handle OP_VAR_MSYM_VALUE.
7511 * eval.c (evaluate_var_msym_value): New function.
7512 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
7513 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
7514 to call_function_by_hand.
7515 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
7516 Handle OP_VAR_MSYM_VALUE.
7517 (union exp_element) <msymbol>: New field.
7518 * minsyms.h (struct type): Forward declare.
7519 (find_minsym_type_and_address): Declare.
7520 * parse.c (write_exp_elt_msym): New function.
7521 (write_exp_msymbol): Delete, refactored as ...
7522 (find_minsym_type_and_address): ... this new function.
7523 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
7524 (operator_length_standard, operator_check_standard): Handle
7525 OP_VAR_MSYM_VALUE.
7526 * std-operator.def (OP_VAR_MSYM_VALUE): New.
7527
7528 2017-09-04 Pedro Alves <palves@redhat.com>
7529
7530 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
7531 TYPE_GNU_IFUNC specially here. Throw error if return type is
7532 unknown.
7533 * ada-typeprint.c (print_func_type): Handle functions with unknown
7534 return type.
7535 * c-typeprint.c (c_type_print_base): Handle functions and methods
7536 with unknown return type.
7537 * compile/compile-c-symbols.c (convert_symbol_bmsym)
7538 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
7539 * compile/compile-c-types.c: Include "objfiles.h".
7540 (convert_func): For functions with unknown return type, warn and
7541 default to int.
7542 * compile/compile-object-run.c (compile_object_run): Adjust call
7543 to call_function_by_hand_dummy.
7544 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
7545 call_function_by_hand.
7546 * eval.c (evaluate_subexp_standard): Adjust calls to
7547 call_function_by_hand. Handle functions and methods with unknown
7548 return type. Pass expect_type to call_function_by_hand.
7549 * f-typeprint.c (f_type_print_base): Handle functions with unknown
7550 return type.
7551 * gcore.c (call_target_sbrk): Adjust call to
7552 call_function_by_hand.
7553 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
7554 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
7555 an integer address type instead of nodebug.
7556 * guile/scm-value.c (gdbscm_value_call): Adjust call to
7557 call_function_by_hand.
7558 * infcall.c (error_call_unknown_return_type): New function.
7559 (call_function_by_hand): New "default_return_type" parameter.
7560 Pass it down.
7561 (call_function_by_hand_dummy): New "default_return_type"
7562 parameter. Use it instead of defaulting to int. If there's no
7563 default and the return type is unknown, throw an error. If
7564 there's a default return type, and the called function has no
7565 debug info, then assume the function is prototyped.
7566 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
7567 New "default_return_type" parameter.
7568 (error_call_unknown_return_type): New declaration.
7569 * linux-fork.c (call_lseek): Cast return type of lseek.
7570 (inferior_call_waitpid, checkpoint_command): Adjust calls to
7571 call_function_by_hand.
7572 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
7573 calls to call_function_by_hand.
7574 * m2-typeprint.c (m2_procedure): Handle functions with unknown
7575 return type.
7576 * objc-lang.c (lookup_objc_class, lookup_child_selector)
7577 (value_nsstring, print_object_command): Adjust calls to
7578 call_function_by_hand.
7579 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
7580 functions with unknown return type.
7581 (pascal_type_print_func_varspec_suffix): New function.
7582 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
7583 TYPE_CODE_METHOD>: Use it.
7584 * python/py-value.c (valpy_call): Adjust call to
7585 call_function_by_hand.
7586 * rust-lang.c (rust_evaluate_funcall): Adjust call to
7587 call_function_by_hand.
7588 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
7589 call_function_by_hand.
7590 * valops.c (value_allocate_space_in_inferior): Adjust call to
7591 call_function_by_hand.
7592 * typeprint.c (type_print_unknown_return_type): New function.
7593 * typeprint.h (type_print_unknown_return_type): New declaration.
7594
7595 2017-09-04 Pedro Alves <palves@redhat.com>
7596
7597 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
7598 types with more than one parameter as prototyped.
7599
7600 2017-09-04 Pedro Alves <palves@redhat.com>
7601
7602 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
7603 (disassemble_command): Use gdb_disassembly_flags instead of bare
7604 int.
7605 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
7606 (dump_insns, do_mixed_source_and_assembly_deprecated)
7607 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
7608 Use gdb_disassembly_flags instead of bare int.
7609 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
7610 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
7611 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
7612 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
7613 (enum gdb_disassembly_flag): ... values of this new enumeration.
7614 (gdb_disassembly_flags): Define.
7615 (gdb_disassembly)
7616 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
7617 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
7618 gdb_disassembly_flags instead of bare int.
7619 * record-btrace.c (btrace_insn_history)
7620 (record_btrace_insn_history, record_btrace_insn_history_range)
7621 (record_btrace_insn_history_from): Use gdb_disassembly_flags
7622 instead of bare int.
7623 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
7624 Use gdb_disassembly_flags instead of bare int.
7625 * target-debug.h (target_debug_print_gdb_disassembly_flags):
7626 Define.
7627 * target-delegates.c: Regenerate.
7628 * target.c (target_insn_history, target_insn_history_from)
7629 (target_insn_history_range): Use gdb_disassembly_flags instead of
7630 bare int.
7631 * target.h: Include "disasm.h".
7632 (struct target_ops) <to_insn_history, to_insn_history_from,
7633 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
7634 int.
7635 (target_insn_history, target_insn_history_from)
7636 (target_insn_history_range): Use gdb_disassembly_flags instead of
7637 bare int.
7638
7639 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
7640
7641 * cli/cli-script.c (build_command_line): For if/while commands,
7642 check whether args is empty.
7643
7644 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
7645
7646 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
7647 (enum command_control_type): Likewise.
7648 (struct command_line): Likewise.
7649 (free_command_lines): Likewise.
7650 (struct command_lines_deleter): Likewise.
7651 (command_line_up): Likewise.
7652 (read_command_lines): Likewise.
7653 (read_command_lines_1): Likewise.
7654 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
7655 (enum command_control_type): Likewise.
7656 (struct command_line): Likewise.
7657 (free_command_lines): Likewise.
7658 (struct command_lines_deleter): Likewise.
7659 (command_line_up): Likewise.
7660 (read_command_lines): Likewise.
7661 (read_command_lines_1): Likewise.
7662 * breakpoint.h: Include cli/cli-script.h.
7663 * extension-priv.h: Likewise.
7664 * gdbcmd.h: Likewise.
7665
7666 2017-09-04 Pedro Alves <palves@redhat.com>
7667
7668 * ada-lang.c (is_known_support_routine): Move sal declaration to
7669 where it is initialized.
7670 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
7671 (parse_breakpoint_sals, decode_static_tracepoint_spec)
7672 (clear_command, update_static_tracepoint): Remove init_sal
7673 references. Move declarations closer to initializations.
7674 * cli/cli-cmds.c (list_command): Move sal declarations closer to
7675 initializations.
7676 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
7677 references. Move sal declarations closer to initializations.
7678 * frame.c (find_frame_sal): Return a symtab_and_line via function
7679 return instead of output parameter. Remove init_sal references.
7680 * frame.h (find_frame_sal): Return a symtab_and_line via function
7681 return instead of output parameter.
7682 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
7683 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
7684 instead of memset.
7685 (gdbscm_find_pc_line): Remove init_sal reference.
7686 * infcall.c (call_function_by_hand_dummy): Remove init_sal
7687 references. Move declarations closer to initializations.
7688 * infcmd.c (set_step_frame): Update. Move declarations closer to
7689 initializations.
7690 (finish_backward): Remove init_sal references. Move declarations
7691 closer to initializations.
7692 * infrun.c (process_event_stop_test, handle_step_into_function)
7693 (insert_hp_step_resume_breakpoint_at_frame)
7694 (insert_step_resume_breakpoint_at_caller): Likewise.
7695 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
7696 (symbol_to_sal): Likewise.
7697 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
7698 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
7699 to its initialization.
7700 * reverse.c (save_bookmark_command): Use new/delete. Remove
7701 init_sal references. Move declarations closer to initializations.
7702 * source.c (get_current_source_symtab_and_line): Remove brace
7703 initialization.
7704 (set_current_source_symtab_and_line): Now takes the sal by const
7705 reference. Remove brace initialization.
7706 (line_info): Remove init_sal reference.
7707 * source.h (set_current_source_symtab_and_line): Now takes a
7708 symtab_and_line via const reference.
7709 * stack.c (set_current_sal_from_frame): Adjust.
7710 (print_frame_info): Adjust.
7711 (get_last_displayed_sal): Return the sal via function return
7712 instead of via output parameter. Simplify.
7713 (frame_info): Adjust.
7714 * stack.h (get_last_displayed_sal): Return the sal via function
7715 return instead of via output parameter.
7716 * symtab.c (init_sal): Delete.
7717 (find_pc_sect_line): Remove init_sal references. Move
7718 declarations closer to initializations.
7719 (find_function_start_sal): Remove init_sal references. Move
7720 declarations closer to initializations.
7721 * symtab.h (struct symtab_and_line): In-class initialize all
7722 fields.
7723 * tracepoint.c (set_traceframe_context)
7724 (print_one_static_tracepoint_marker): Remove init_sal references.
7725 Move declarations closer to initializations.
7726 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
7727 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
7728 declarations closer to initializations.
7729 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
7730 init_sal references. Adjust.
7731
7732 2017-09-04 Pedro Alves <palves@redhat.com>
7733
7734 * ax-gdb.c (agent_command_1): Use range-for.
7735 * break-catch-throw.c (re_set_exception_catchpoint): Update.
7736 * breakpoint.c: Include "common/array-view.h".
7737 (init_breakpoint_sal, create_breakpoint_sal): Change sals
7738 parameter from struct symtabs_and_lines to
7739 array_view<symtab_and_line>. Adjust. Use range-for. Update.
7740 (breakpoint_sals_to_pc): Change sals parameter from struct
7741 symtabs_and_lines to std::vector reference.
7742 (check_fast_tracepoint_sals): Change sals parameter from struct
7743 symtabs_and_lines to std::array_view. Use range-for.
7744 (decode_static_tracepoint_spec): Return a std::vector instead of
7745 symtabs_and_lines. Update.
7746 (create_breakpoint): Update.
7747 (break_range_command, until_break_command, clear_command): Update.
7748 (base_breakpoint_decode_location, bkpt_decode_location)
7749 (bkpt_probe_create_sals_from_location)
7750 (bkpt_probe_decode_location, tracepoint_decode_location)
7751 (tracepoint_probe_decode_location)
7752 (strace_marker_create_sals_from_location): Return a std::vector
7753 instead of symtabs_and_lines.
7754 (strace_marker_create_breakpoints_sal): Update.
7755 (strace_marker_decode_location): Return a std::vector instead of
7756 symtabs_and_lines. Update.
7757 (update_breakpoint_locations): Change struct symtabs_and_lines
7758 parameters to gdb::array_view. Adjust.
7759 (location_to_sals): Return a std::vector instead of
7760 symtabs_and_lines. Update.
7761 (breakpoint_re_set_default): Use std::vector instead of struct
7762 symtabs_and_lines.
7763 (decode_location_default): Return a std::vector instead of
7764 symtabs_and_lines. Update.
7765 * breakpoint.h: Include "common/array-view.h".
7766 (struct breakpoint_ops) <decode_location>: Now returns a
7767 std::vector instead of returning a symtabs_and_lines via output
7768 parameter.
7769 (update_breakpoint_locations): Change sals parameters to use
7770 gdb::array_view.
7771 * cli/cli-cmds.c (edit_command, list_command): Update to use
7772 std::vector and gdb::array_view.
7773 (ambiguous_line_spec): Adjust to use gdb::array_view and
7774 range-for.
7775 (compare_symtabs): Rename to ...
7776 (cmp_symtabs): ... this. Change parameters to symtab_and_line
7777 const reference and adjust.
7778 (filter_sals): Rewrite using std::vector and standard algorithms.
7779 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
7780 (jump_command): Update to use std::vector.
7781 * linespec.c (struct linespec_state) <canonical_names>: Update
7782 comment.
7783 (add_sal_to_sals_basic): Delete.
7784 (add_sal_to_sals, filter_results, convert_results_to_lsals)
7785 (decode_line_2, create_sals_line_offset)
7786 (convert_address_location_to_sals, convert_linespec_to_sals)
7787 (convert_explicit_location_to_sals, parse_linespec)
7788 (event_location_to_sals, decode_line_full, decode_line_1)
7789 (decode_line_with_current_source)
7790 (decode_line_with_last_displayed, decode_objc)
7791 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
7792 (linespec_result::~linespec_result): Adjust to use std::vector
7793 instead of symtabs_and_lines.
7794 * linespec.h (linespec_sals::sals): Now a std::vector.
7795 (struct linespec_result): Use std::vector, bool, and in-class
7796 initialization.
7797 (decode_line_1, decode_line_with_current_source)
7798 (decode_line_with_last_displayed): Return std::vector.
7799 * macrocmd.c (info_macros_command): Use std::vector.
7800 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
7801 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
7802 std::vector.
7803 * probe.h (parse_probes): Return a std::vector.
7804 * python/python.c (gdbpy_decode_line): Use std::vector and
7805 gdb::array_view.
7806 * source.c (select_source_symtab, line_info): Use std::vector.
7807 * stack.c (func_command): Use std::vector.
7808 * symtab.h (struct symtabs_and_lines): Delete.
7809 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
7810
7811 2017-09-04 Pedro Alves <palves@redhat.com>
7812
7813 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7814 unittests/array-view-selftests.c.
7815 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
7816 * common/array-view.h: New file.
7817 * unittests/array-view-selftests.c: New file.
7818
7819 2017-09-04 Pedro Alves <palves@redhat.com>
7820
7821 * cli/cli-cmds.c (edit_command): Pass message to
7822 ambiguous_line_spec.
7823 (list_command): Pass message to ambiguous_line_spec. Say
7824 "first"/"last" instead of "start" and "end" to be consistent with
7825 the manual.
7826 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
7827 them to print formatted message.
7828
7829 2017-09-04 Pedro Alves <palves@redhat.com>
7830
7831 * btrace.c (ftrace_add_pt): Pass btrace_insn to
7832 ftrace_update_insns by reference instead of pointer.
7833
7834 2017-09-04 Yao Qi <yao.qi@linaro.org>
7835
7836 * i386-go32-tdep.c: Include x86-xstate.h.
7837 (i386_go32_init_abi): Call i386_target_description.
7838 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
7839 if xcr0 is X86_XSTATE_X87_MASK.
7840 * i386-tdep.h (tdesc_i386): Remove the declaration.
7841 (tdesc_i386_mmx): Likewise.
7842
7843 2017-09-04 Yao Qi <yao.qi@linaro.org>
7844
7845 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
7846 X86_XSTATE_SSE_MASK instead of 0.
7847
7848 2017-09-04 Yao Qi <yao.qi@linaro.org>
7849
7850 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
7851 i386_target_description.
7852 * i386-fbsd-nat.c (i386fbsd_read_description): Call
7853 i386_target_description.
7854 * i386-tdep.c (i386_gdbarch_init): Likewise.
7855
7856 2017-09-04 Yao Qi <yao.qi@linaro.org>
7857
7858 * amd64-darwin-tdep.c: Include "x86-xstate.h".
7859 (x86_darwin_init_abi_64): Call amd64_target_description.
7860 * amd64-dicos-tdep.c: Likewise.
7861 * amd64-fbsd-nat.c: Likewise.
7862 * amd64-fbsd-tdep.c: Likewise.
7863 * amd64-nbsd-tdep.c: Likewise.
7864 * amd64-obsd-tdep.c: Likewise.
7865 * amd64-sol2-tdep.c: Likewise.
7866 * amd64-windows-tdep.c: Likewise.
7867 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
7868
7869 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
7870
7871 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
7872 (btrace_function) <insn>: Change type to use std::vector.
7873 * btrace.c (ftrace_debug, ftrace_call_num_insn,
7874 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
7875 ftrace_update_insns, ftrace_compute_global_level_offset,
7876 btrace_stitch_bts, btrace_clear, btrace_insn_get,
7877 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
7878 change to std::vector.
7879 (ftrace_update_insns): Adjust to change to std::vector, change
7880 type of INSN parameter.
7881 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
7882 * record-btrace.c (btrace_call_history_insn_range,
7883 btrace_compute_src_line_range,
7884 record_btrace_frame_prev_register): Adjust to change to
7885 std::vector.
7886 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
7887 to change to std::vector.
7888
7889 2017-09-03 Tom Tromey <tom@tromey.com>
7890
7891 * corefile.c (reopen_exec_file): Use std::string.
7892
7893 2017-09-03 Tom Tromey <tom@tromey.com>
7894
7895 * compile/compile.c (compile_register_name_mangled): Return
7896 std::string.
7897 * compile/compile-loc2c.c (pushf_register_address): Update.
7898 (pushf_register): Update.
7899 * compile/compile-c-types.c (convert_array): Update.
7900 * compile/compile-c-symbols.c (generate_vla_size): Update.
7901 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
7902 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
7903 (convert_one_symbol): Update.
7904 (generate_c_for_for_one_variable): Update.
7905 * compile/compile-c-support.c (c_get_range_decl_name): Return a
7906 std::string.
7907 (generate_register_struct): Update.
7908 * compile/compile-internal.h (c_get_range_decl_name): Return a
7909 std::string.
7910 (compile_register_name_mangled): Return std::string.
7911
7912 2017-09-03 Tom Tromey <tom@tromey.com>
7913
7914 * utils.c (perror_string): Return a std::string.
7915 (throw_perror_with_name, perror_warning_with_name): Update.
7916
7917 2017-09-03 Tom Tromey <tom@tromey.com>
7918
7919 * demangle.c (demangle_command): Use std::string,
7920 unique_xmalloc_ptr.
7921
7922 2017-09-03 Tom Tromey <tom@tromey.com>
7923
7924 * cli/cli-setshow.c (do_set_command): Use std::string.
7925
7926 2017-09-03 Tom Tromey <tom@tromey.com>
7927
7928 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
7929
7930 2017-09-03 Tom Tromey <tom@tromey.com>
7931
7932 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
7933
7934 2017-09-03 Tom Tromey <tom@tromey.com>
7935
7936 * mi/mi-cmd-env.c (env_execute_cli_command): Use
7937 gdb::unique_xmalloc_ptr.
7938
7939 2017-09-03 Tom Tromey <tom@tromey.com>
7940
7941 * thread.c (print_thread_info_1): Use string_printf.
7942 (thread_apply_command, thread_apply_all_command): Use
7943 std::string.
7944
7945 2017-09-03 Tom Tromey <tom@tromey.com>
7946
7947 * valprint.c (val_print_string): Update.
7948 * gdbcore.h (memory_error_message): Return std::string.
7949 * corefile.c (memory_error_message): Return std::string.
7950 (memory_error): Update.
7951 * breakpoint.c (insert_bp_location): Update.
7952
7953 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
7954
7955 * target/waitstatus.h (target_waitstatus_to_string): Change
7956 return type to std::string.
7957 * target/waitstatus.c (target_waitstatus_to_string): Return
7958 std::string.
7959 * target.h (target_waitstatus_to_string): Remove declaration.
7960 * infrun.c (resume, clear_proceed_status_thread,
7961 print_target_wait_results, do_target_wait, save_waitstatus,
7962 stop_all_threads): Adjust.
7963 * record-btrace.c (record_btrace_wait): Adjust.
7964 * target-debug.h
7965 (target_debug_print_struct_target_waitstatus_p): Adjust.
7966
7967 2017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
7968
7969 PR gdb/22046
7970 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
7971 detection.
7972
7973 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
7974
7975 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
7976 for setting/unsetting environment variables on the remote target.
7977 (New remote packets): Add entries for QEnvironmentHexEncoded,
7978 QEnvironmentUnset and QEnvironmentReset.
7979 * common/environ.c (gdb_environ::operator=): Extend method to
7980 handle m_user_set_env_list and m_user_unset_env_list.
7981 (gdb_environ::clear): Likewise.
7982 (match_var_in_string): Change type of first parameter from 'char
7983 *' to 'const char *'.
7984 (gdb_environ::set): Extend method to handle
7985 m_user_set_env_list and m_user_unset_env_list.
7986 (gdb_environ::unset): Likewise.
7987 (gdb_environ::clear_user_set_env): New method.
7988 (gdb_environ::user_set_envp): Likewise.
7989 (gdb_environ::user_unset_envp): Likewise.
7990 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
7991 m_user_unset_env_list on move constructor/assignment.
7992 (unset): Add new default parameter 'update_unset_list = true'.
7993 (clear_user_set_env): New method.
7994 (user_set_envp): Likewise.
7995 (user_unset_envp): Likewise.
7996 (m_user_set_env_list): New std::set.
7997 (m_user_unset_env_list): Likewise.
7998 * common/rsp-low.c (hex2str): New function.
7999 (bin2hex): New overload for bin2hex function.
8000 * common/rsp-low.c (hex2str): New prototype.
8001 (str2hex): New overload prototype.
8002 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
8003 QEnvironmentUnset and QEnvironmentReset.
8004 (remote_protocol_features): Add QEnvironmentHexEncoded,
8005 QEnvironmentUnset and QEnvironmentReset packets.
8006 (send_environment_packet): New function.
8007 (extended_remote_environment_support): Likewise.
8008 (extended_remote_create_inferior): Call
8009 extended_remote_environment_support.
8010 (_initialize_remote): Add QEnvironmentHexEncoded,
8011 QEnvironmentUnset and QEnvironmentReset packet configs.
8012 * unittests/environ-selftests.c (gdb_selftest_env_var):
8013 New variable.
8014 (test_vector_initialization): New function.
8015 (test_init_from_host_environ): Likewise.
8016 (test_reinit_from_host_environ): Likewise.
8017 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
8018 Likewise.
8019 (test_unset_set_empty_vector): Likewise.
8020 (test_vector_clear): Likewise.
8021 (test_std_move): Likewise.
8022 (test_move_constructor):
8023 (test_self_move): Likewise.
8024 (test_set_unset_reset): Likewise.
8025 (run_tests): Rewrite in terms of the functions above.
8026
8027 2017-08-31 Weimin Pan <weimin.pan@oracle.com>
8028
8029 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
8030 (adi_available): Use a temp variable of type CORE_ADDR as argument
8031 3 when calling target_auxv_search.
8032 (adi_normalize_address): Use masks and xor operators to calculate
8033 normalized address.
8034 (adi_read_versions, adi_write_versions, adi_print_versions)
8035 (do_examine, do_assign): Use paddress.
8036
8037 2017-08-29 John Baldwin <jhb@FreeBSD.org>
8038
8039 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
8040 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
8041 out of loop and add supply of FIR.
8042 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
8043 add collect of FIR.
8044
8045 2017-08-28 Simon Marchi <simon.marchi@ericsson.com>
8046
8047 PR gdb/21827
8048 * cli/cli-script.c (define_command): Don't convert command name
8049 to lower case.
8050
8051 2017-08-25 Joel Brobecker <brobecker@adacore.com>
8052
8053 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
8054 Update all callers accordingly. Remove all code blocks handling
8055 the case where DISPP is not NULL.
8056
8057 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
8058
8059 PR symtab/22003
8060 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
8061 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
8062 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
8063
8064 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
8065
8066 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
8067 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
8068 (read_comp_units_from_section): New parameter abbrev_section, use
8069 read_and_check_comp_unit_head, allocate signatured_type if needed.
8070 (create_all_comp_units): Update read_comp_units_from_section caller.
8071
8072 2017-08-23 Pedro Alves <palves@redhat.com>
8073
8074 PR remote/21852
8075 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
8076 to null_ptid and switch to thread without reading the registers
8077 after adding the inferior.
8078
8079 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
8080
8081 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
8082 compile-gcc.
8083 * compile/compile.c (compile_gcc, show_compile_gcc): New.
8084 (compile_to_object): Implement compile_gcc.
8085 (_initialize_compile): Install "set compile-gcc". Initialize
8086 compile_gcc.
8087
8088 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
8089
8090 * compile/compile.c (compile_to_object): Conditionally call
8091 set_verbose. Conditionally call compile or compile_v0.
8092
8093 2017-08-07 Weimin Pan <weimin.pan@oracle.com>
8094
8095 * sparc64-tdep.h: (adi_normalize_address): New export.
8096 * sparc-nat.h: (open_adi_tag_fd): New export.
8097 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
8098 * sparc64-linux-tdep.c:
8099 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
8100 (sparc64_linux_handle_segmentation_fault): New function.
8101 (sparc64_linux_init_abi): Register
8102 sparc64_linux_handle_segmentation_fault
8103 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
8104 (sparc64_addr_bits_remove): New function.
8105 (sparc64_init_abi): Register sparc64_addr_bits_remove.
8106 (MAX_PROC_NAME_SIZE): New macro.
8107 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
8108 (sparc64adilist): New variable.
8109 (adi_proc_list): New variable.
8110 (find_adi_info): New function.
8111 (add_adi_info): New function.
8112 (get_adi_info_proc): New function.
8113 (get_adi_info): New function.
8114 (info_adi_command): New function.
8115 (read_maps_entry): New function.
8116 (adi_available): New function.
8117 (adi_normalize_address): New function.
8118 (adi_align_address): New function.
8119 (adi_convert_byte_count): New function.
8120 (adi_tag_fd): New function.
8121 (adi_is_addr_mapped): New function.
8122 (adi_read_versions): New function.
8123 (adi_write_versions): New function.
8124 (adi_print_versions): New function.
8125 (do_examine): New function.
8126 (do_assign): New function.
8127 (adi_examine_command): New function.
8128 (adi_assign_command): New function.
8129 (_initialize_sparc64_adi_tdep): New function.
8130
8131 2017-08-22 Simon Marchi <simon.marchi@ericsson.com>
8132
8133 * breakpoint.c (breakpoints_info): Rename to ...
8134 (info_breakpoints_command): ... this.
8135 (watchpoints_info): Rename to ...
8136 (info_watchpoints_command): ... this.
8137 (tracepoints_info): Rename to ...
8138 (info_tracepoints_command): ... this.
8139 (_initialize_breakpoint): Adjust.
8140 * dcache.c (dcache_info): Rename to ...
8141 (info_display_command): ... this.
8142 (_initialize_dcache): Adjust.
8143 * frame.h (args_info): Rename to ...
8144 (info_args_command): ... this.
8145 (locals_info): Rename to ...
8146 (info_locals_command): ... this.
8147 * infcmd.c (nofp_registers_info): Rename to ...
8148 (info_registers_command): ... this.
8149 (float_info): Rename to ...
8150 (info_float_command): ... this.
8151 (program_info): Rename to ...
8152 (info_program_command): ... this.
8153 (all_registers_info): Rename to ...
8154 (info_all_registers_command): ... this.
8155 (vector_info): Rename to ...
8156 (info_vector_command): ... this.
8157 (float_info): Rename to ...
8158 (info_float_command): ... this.
8159 (_initialize_infcmd): Adjust.
8160 * inferior.h (term_info): Rename to ...
8161 (info_terminal_command): ... this.
8162 * inflow.c (term_info): Rename to ...
8163 (info_terminal_command): ... this.
8164 (_initialize_inflow): Adjust.
8165 * infrun.c (signals_info): Rename to ...
8166 (info_signals_command): ... this.
8167 (_initialize_infrun): Adjust.
8168 * objc-lang.c (classes_info): Rename to ...
8169 (info_classes_command): ... this.
8170 (selectors_info): Rename to ...
8171 (info_selectors_command): ... this.
8172 (_initialize_objc_language): Adjust.
8173 * printcmd.c (sym_info): Rename to ...
8174 (info_symbol_command): ... this.
8175 (address_info): Rename to ...
8176 (info_address_command): ... this.
8177 (display_info): Rename to ...
8178 (info_display_command): ... this.
8179 (_initialize_printcmd): Adjust.
8180 * reverse.c (bookmarks_info): Rename to ...
8181 (info_breakpoints_command): ... this.
8182 (_initialize_reverse): Adjust.
8183 * ser-go32.c (dos_info): Rename to ...
8184 (info_serial_command): ... this.
8185 (_initialize_ser_dos): Adjust.
8186 * skip.c (skip_info): Rename to ...
8187 (info_skip_command): ... this.
8188 (_initialize_step_skip): Adjust.
8189 * source.c (line_info): Rename to ...
8190 (info_line_command): ... this.
8191 (source_info): Rename to ...
8192 (info_source_command)
8193 * stack.c (frame_info): Rename to ...
8194 (info_frame_command): ... this.
8195 (locals_info): Rename to ...
8196 (info_locals_command): ... this.
8197 (args_info): Rename to ...
8198 (info_args_command): ... this.
8199 (_initialize_stack): Adjust.
8200 * symtab.c (sources_info): Rename to ...
8201 (info_sources_command): ... this.
8202 (variables_info): Rename to ...
8203 (info_variables_command): ... this.
8204 (functions_info): Rename to ...
8205 (info_functions_command): ... this.
8206 (types_info): Rename to ...
8207 (info_types_command): ... this.
8208 (_initialize_symtab): Adjust.
8209 * target.c (target_info): Rename to ...
8210 (info_target_command): ... this.
8211 (initialize_targets): Adjust.
8212 * tracepoint.c (tvariables_info): Rename to ...
8213 (info_tvariables_command): ... this.
8214 (scope_info): Rename to ...
8215 (info_scope_command): ... this.
8216 (trace_dump_actions): Adjust.
8217 (_initialize_tracepoint): Adjust.
8218
8219 2017-08-22 Tom Tromey <tom@tromey.com>
8220
8221 * breakpoint.h (install_breakpoint): Update.
8222 * breakpoint.c (add_solib_catchpoint): Update.
8223 (install_breakpoint): Change argument to a std::unique_ptr.
8224 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
8225 (create_breakpoint_sal, create_breakpoint): Update.
8226 (watch_command_1, catch_exec_command_1)
8227 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
8228 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
8229 Return the breakpoint.
8230 (set_raw_breakpoint_without_location, set_raw_breakpoint)
8231 (new_single_step_breakpoint): Update.
8232 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
8233 std::unique_ptr.
8234 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
8235 std::unique_ptr.
8236 * break-catch-sig.c (create_signal_catchpoint): Use
8237 std::unique_ptr.
8238 * ada-lang.c (create_ada_exception_catchpoint): Use
8239 std::unique_ptr.
8240
8241 2017-08-22 Tom Tromey <tom@tromey.com>
8242
8243 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
8244
8245 2017-08-22 Tom Tromey <tom@tromey.com>
8246
8247 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
8248 (lookup_partial_symbol): Update.
8249
8250 2017-08-22 Tom Tromey <tom@tromey.com>
8251
8252 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
8253 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
8254 (find_and_open_source, symtab_to_fullname): Update.
8255 * psymtab.c (psymtab_to_fullname): Update.
8256
8257 2017-08-22 Tom Tromey <tom@tromey.com>
8258
8259 * exec.c (exec_file_attach): Update.
8260 * linux-thread-db.c (try_thread_db_load): Update.
8261 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
8262 * utils.c (gdb_realpath): Change return type.
8263 (gdb_realpath_keepfile): Update.
8264 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
8265 (_initialize_utils): Register the new self test.
8266 * source.c (openp): Update.
8267 (find_and_open_source): Update.
8268 * nto-tdep.c (nto_find_and_open_solib): Update.
8269 * main.c (set_gdb_data_directory): Update.
8270 (captured_main_1): Update.
8271 * dwarf2read.c (dwarf2_get_dwz_file): Update
8272 (dw2_map_symbol_filenames): Update.
8273 * auto-load.c (auto_load_safe_path_vec_update): Update.
8274 (filename_is_in_auto_load_safe_path_vec): Change type of
8275 "filename_realp".
8276 (auto_load_objfile_script): Update.
8277 (file_is_auto_load_safe): Update. Use std::string.
8278 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
8279
8280 2017-08-22 Tom Tromey <tom@tromey.com>
8281
8282 * utils.c (gdb_realpath_keepfile): Return a
8283 gdb::unique_xmalloc_ptr.
8284 * exec.c (exec_file_attach): Update.
8285 * utils.h (gdb_realpath_keepfile): Return a
8286 gdb::unique_xmalloc_ptr.
8287
8288 2017-08-22 Tom Tromey <tom@tromey.com>
8289
8290 * compile/compile.c (compile_file_command): Use
8291 gdb::unique_xmalloc_ptr, std::string.
8292 * utils.c (gdb_abspath): Change return type.
8293 * source.c (openp): Update.
8294 * objfiles.c (allocate_objfile): Update.
8295 * main.c (set_gdb_data_directory): Update.
8296 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
8297
8298 2017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
8299
8300 * cli-cmds.c (list_commands): List actual code around more than
8301 one location.
8302
8303 2017-08-21 John Baldwin <jhb@FreeBSD.org>
8304
8305 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
8306
8307 2017-08-21 Pedro Alves <palves@redhat.com>
8308
8309 PR gdb/19487
8310 * c-exp.y (variable production): Handle function aliases.
8311 * minsyms.c (msymbol_is_text): New function.
8312 * minsyms.h (msymbol_is_text): Declare.
8313 * symtab.c (find_function_alias_target): New function.
8314 * symtab.h (find_function_alias_target): Declare.
8315
8316 2017-08-21 Pedro Alves <palves@redhat.com>
8317
8318 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
8319 typedefs.
8320 * typeprint.c (whatis_exp): If handling "whatis", and expression
8321 is OP_TYPE, strip one typedef level. Otherwise don't strip
8322 typedefs here.
8323 * valops.c (value_cast): Save "to" type before resolving
8324 stubs/typedefs. Use that type as resulting value's type.
8325
8326 2017-08-18 Tom Tromey <tom@tromey.com>
8327 Pedro Alves <palves@redhat.com>
8328
8329 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
8330 * sol-thread.c (sol_thread_resume, sol_thread_wait)
8331 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
8332 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
8333 * proc-service.c (ps_xfer_memory): Use scoped_restore.
8334 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
8335 (linux_get_siginfo_data): Add "thread" argument. Use
8336 scoped_restore.
8337 * linux-nat.c (linux_child_follow_fork)
8338 (check_stopped_by_watchpoint): Use scoped_restore.
8339 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
8340 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
8341 (restore_inferior_ptid, save_inferior_ptid): Remove.
8342 * btrace.c (btrace_fetch): Use scoped_restore.
8343 * bsd-uthread.c (bsd_uthread_fetch_registers)
8344 (bsd_uthread_store_registers): Use scoped_restore.
8345 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
8346 scoped_restore.
8347 * aix-thread.c (aix_thread_resume, aix_thread_wait)
8348 (aix_thread_xfer_partial): Use scoped_restore.
8349 * inferior.h (save_inferior_ptid): Remove.
8350
8351 2017-08-18 Yao Qi <yao.qi@linaro.org>
8352
8353 PR tdep/21818
8354 * arm-tdep.c (gdb_print_insn_arm): Mark
8355 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
8356
8357 2017-08-18 Yao Qi <yao.qi@linaro.org>
8358
8359 * NEWS: Mention GDBserver's new option "--selftest".
8360 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
8361 * selftest.c: Move it to common/selftest.c.
8362 * selftest.h: Move it to common/selftest.h.
8363 * selftest-arch.c (reset): New function.
8364 (tests_with_arch): Call reset.
8365
8366 2017-08-18 Yao Qi <yao.qi@linaro.org>
8367
8368 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
8369 instead of exception_fprintf and printf_filtered.
8370
8371 2017-08-18 Yao Qi <yao.qi@linaro.org>
8372
8373 * selftest.c (register_self_test): Rename it to
8374 selftests::register_test.
8375 (run_self_tests): selftest::run_tests.
8376 * selftest.h: Update declarations.
8377 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
8378 selftests::register_test_foreach_arch.
8379 * selftest-arch.h: Update declaration.
8380 * aarch64-tdep.c: Update.
8381 * arm-tdep.c: Likewise.
8382 * disasm-selftests.c: Likewise.
8383 * dwarf2loc.c: Likewise.
8384 * dwarf2-frame.c: Likewise.
8385 * findvar.c: Likewise.
8386 * gdbarch-selftests.c: Likewise.
8387 * maint.c (maintenance_selftest): Likewise.
8388 * regcache.c: Likewise.
8389 * rust-exp.y: Likewise.
8390 * selftest-arch.c: Likewise.
8391 * unittests/environ-selftests.c: Likewise.
8392 * unittests/function-view-selftests.c: Likewise.
8393 * unittests/offset-type-selftests.c: Likewise.
8394 * unittests/optional-selftests.c: Likewise.
8395 * unittests/scoped_restore-selftests.c: Likewise.
8396 * utils-selftests.c: Likewise.
8397
8398 2017-08-17 Pedro Alves <palves@redhat.com>
8399
8400 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
8401 local.
8402
8403 2017-08-17 Pedro Alves <palves@redhat.com>
8404
8405 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
8406 field.
8407 (reset_die_in_process): Delete, replaced by ...
8408 (process_die_scope): ... this new class. Make it responsible for
8409 freeing cu->line_header too.
8410 (process_die): Use process_die_scope.
8411 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
8412 cu->line_header_die_owner. Don't release the line header if it's
8413 owned by the CU.
8414 (setup_type_unit_groups): Make the CU/DIE own the line header.
8415 Don't release the line header here.
8416
8417 2017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
8418
8419 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
8420
8421 2017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
8422
8423 * NEWS: Mention new shortcuts for nexti and stepi in TUI
8424 Single-Key mode
8425
8426 2017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
8427
8428 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
8429 mode command list.
8430
8431 2017-08-15 Stafford Horne <shorne@gmail.com>
8432
8433 * MAINTAINERS (Write After Approval): Add Stafford Horne.
8434
8435 2017-08-15 Stafford Horne <shorne@gmail.com>
8436
8437 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
8438
8439 2017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
8440
8441 PR gdb/21954
8442 * infcmd.c (unset_environment_command): Use the 'clear' method on
8443 the environment instead of resetting it.
8444
8445 2017-08-15 John Baldwin <jhb@FreeBSD.org>
8446
8447 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
8448 platforms.
8449
8450 2017-08-14 Tom Tromey <tom@tromey.com>
8451
8452 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
8453 (print_binary_chars): Likewise.
8454 (BITS_IN_BYTES): Remove.
8455
8456 2017-08-14 Tom Tromey <tom@tromey.com>
8457
8458 PR gdb/21675
8459 * valprint.c (LOW_ZERO): Change value to 034.
8460 (print_octal_chars): Add static_asserts for octal constants.
8461 * printcmd.c (print_scalar_formatted): Add 'd' case.
8462
8463 2017-08-11 Tom Tromey <tom@tromey.com>
8464
8465 * symfile.c (add_symbol_file_command): Use std::vector.
8466
8467 2017-08-14 Tom Tromey <tom@tromey.com>
8468
8469 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
8470 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
8471 std::move.
8472 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
8473
8474 2017-08-11 Pedro Alves <palves@redhat.com>
8475
8476 * infrun.c (process_event_stop_test): Adjust
8477 function_name_is_marked_for_skip call.
8478 * skip.c: Include <list>.
8479 (skiplist_entry): Make it a class with private fields, and
8480 getters/setters.
8481 (skiplist_entry_chain): Delete.
8482 (skiplist_entries): New.
8483 (skiplist_entry_count): Delete.
8484 (highest_skiplist_entry_num): New.
8485 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
8486 (add_skiplist_entry): Delete.
8487 (skiplist_entry::skiplist_entry): New.
8488 (skiplist_entry::add_entry): New.
8489 (skip_file_command, skip_function): Adjust.
8490 (compile_skip_regexp): Delete.
8491 (skip_command): Don't compile regexp here. Adjust to use
8492 skiplist_entry::add_entry.
8493 (skip_info): Adjust to use range-for and getters.
8494 (skip_enable_command, skip_disable_command): Adjust to use
8495 range-for and setters.
8496 (skip_delete_command): Adjust to use std::list.
8497 (add_skiplist_entry): Delete.
8498 (skip_file_p): Delete, refactored as ...
8499 (skiplist_entry::do_skip_file_p): ... this new method.
8500 (skip_gfile_p): Delete, refactored as ...
8501 (skiplist_entry::do_gskip_file_p): ... this new method.
8502 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
8503 (skiplist_entry::skip_function_p): ... this new method.
8504 (function_name_is_marked_for_skip): Now returns bool, and takes
8505 the function sal by const reference. Adjust to use range-for and
8506 skiplist_entry methods.
8507 (_initialize_step_skip): Remove references to
8508 skiplist_entry_chain, skiplist_entry_count.
8509 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
8510 takes the function sal by const reference.
8511
8512 2017-08-11 Yao Qi <yao.qi@linaro.org>
8513
8514 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
8515 (dwarf2_frame_cache): Remove reset_cache_cleanup.
8516 (dwarf2_frame_cache):
8517 * frame-unwind.c (frame_unwind_try_unwinder): Catch
8518 RETURN_MASK_ALL and set *this_case to NULL.
8519 * frame-unwind.h: Update comments.
8520
8521 2017-08-11 Yao Qi <yao.qi@linaro.org>
8522
8523 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
8524 (dwarf2_frame_state_copy_regs): Remove.
8525 (dwarf2_frame_state_free_regs): Remove.
8526 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
8527 (dwarf2_restore_rule): Call method .alloc_regs instead of
8528 dwarf2_frame_state_alloc_regs.
8529 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
8530 constructor. Call std::move.
8531 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
8532 (dwarf2_frame_cache): Likewise.
8533
8534 [GDB_SELF_TEST]: Include selftest.h and
8535 selftest-arch.h.
8536 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
8537 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
8538 execute_cfa_program_test.
8539
8540 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
8541 copy ctor, assignment operator, move assignment.
8542 <alloc_regs>: New method.
8543 <swap>: New method.
8544 (struct dwarf2_frame_state): Delete dtor.
8545 (dwarf2_frame_state_alloc_regs): Remove declaration.
8546 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
8547 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
8548
8549 2017-08-11 Yao Qi <yao.qi@linaro.org>
8550
8551 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
8552 (dwarf2_frame_state::dwarf2_frame_state): New.
8553 (dwarf2_frame_state::~dwarf2_frame_state): New.
8554 (dwarf2_fetch_cfa_info): Update.
8555 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
8556 rather than a pointer. Update code.
8557 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
8558 dtor.
8559 <data_align, code_align, retaddr_column>: Change them to const.
8560 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
8561 to bool.
8562
8563 2017-08-11 Yao Qi <yao.qi@linaro.org>
8564
8565 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
8566 <loc.exp>: New field.
8567 * dwarf2-frame.c (execute_cfa_program): Update.
8568 (dwarf2_frame_prev_register): Update.
8569
8570 2017-08-10 Pedro Alves <palves@redhat.com>
8571
8572 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
8573
8574 2017-08-09 John Baldwin <jhb@FreeBSD.org>
8575
8576 * fbsd-nat.c (struct fbsd_fork_info): Remove.
8577 (fbsd_pending_children): Use std::list.
8578 (fbsd_remember_child): Likewise.
8579 (fbsd_is_child_pending): Likewise.
8580 (fbsd_pending_vfork_done): Use std::forward_list.
8581 (fbsd_add_vfork_done): Likewise.
8582 (fbsd_is_vfork_done_pending): Likewise.
8583 (fbsd_next_vfork_done): Likewise.
8584
8585 2017-08-09 John Baldwin <jhb@FreeBSD.org>
8586
8587 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
8588 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
8589 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
8590 for `mapfilename'.
8591 (fbsd_xfer_partial): Use gdb::byte_vector.
8592 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
8593
8594 2017-08-09 John Baldwin <jhb@FreeBSD.org>
8595
8596 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
8597 "filestuff.h".
8598 (fbsd_find_memory_regions): Fix `mapfile' initialization.
8599
8600 2017-08-09 Tom Tromey <tom@tromey.com>
8601
8602 * skip.c (skiplist_entry): New constructor.
8603 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
8604 (skiplist_entry::file_is_glob): Now bool.
8605 (skiplist_entry::file, skiplist_entry::function): Now
8606 std::string.
8607 (make_skip_entry): Return a unique_ptr. Use new.
8608 (free_skiplist_entry, free_skiplist_entry_cleanup)
8609 (make_free_skiplist_entry_cleanup): Remove.
8610 (skip_command, skip_disable_command, add_skiplist_entry)
8611 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
8612 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
8613 (function_name_is_marked_for_skip): Update.
8614 (skip_delete_command): Update. Use delete.
8615
8616 2017-08-09 Jiong Wang <jiong.wang@arm.com>
8617
8618 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
8619 (aarch64_linux_core_read_description): New function.
8620 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
8621
8622 2017-08-09 Pedro Alves <palves@redhat.com>
8623
8624 * cp-name-parser.y (cp_comp_to_string): Return a
8625 gdb::unique_xmalloc_ptr<char>.
8626 * cp-support.c (replace_typedefs_qualified_name)
8627 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
8628 (cp_canonicalize_string_full): Use op= instead of explicit
8629 convertion.
8630 (cp_class_name_from_physname, method_name_from_physname)
8631 (cp_func_name, cp_remove_params): Adjust to use
8632 gdb::unique_xmalloc_ptr<char>.
8633 * cp-support.h (cp_comp_to_string): Return a
8634 gdb::unique_xmalloc_ptr<char>.
8635 * python/py-type.c (typy_lookup_type): Adjust to use
8636 gdb::unique_xmalloc_ptr<char>.
8637
8638 2017-08-09 H.J. Lu <hongjiu.lu@intel.com>
8639
8640 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
8641
8642 2017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
8643 Yao Qi <yao.qi@linaro.org>
8644
8645 * cp-support.c (cp_canonicalize_string_full): Use
8646 gdb::unique_xmalloc_ptr<char>.
8647 (cp_canonicalize_string): Likewise.
8648
8649 2017-08-09 Yao Qi <yao.qi@linaro.org>
8650
8651 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
8652 * regformats/i386/amd64-avx-avx512.dat: Remove.
8653 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
8654 * regformats/i386/amd64-avx-mpx.dat:Remove.
8655 * regformats/i386/amd64-avx.dat: Remove.
8656 * regformats/i386/amd64-mpx.dat: Remove.
8657 * regformats/i386/i386-avx-avx512.dat: Remove.
8658 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
8659 * regformats/i386/i386-avx-mpx.dat: Remove.
8660 * regformats/i386/i386-mmx.dat: Remove.
8661 * regformats/i386/i386-mpx.dat: Remove.
8662
8663 2017-08-09 Yao Qi <yao.qi@linaro.org>
8664
8665 * amd64-tdep.h (tdesc_x32): Remove the declaration.
8666 * amd64-tdep.c: Don't include features/i386/x32*.c.
8667 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
8668 functions.
8669 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
8670 and i386/x32-avx-avx512.
8671 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
8672 and i386/x32.xml.
8673 * features/i386/x32-avx-avx512.c: Removed.
8674 * features/i386/x32-avx-avx512.xml: Removed.
8675 * features/i386/x32-avx.c: Removed.
8676 * features/i386/x32-avx.xml: Removed.
8677 * features/i386/x32.c: Removed.
8678 * features/i386/x32.xml: Removed.
8679 * regformats/i386/x32-avx-avx512.dat: Removed.
8680 * regformats/i386/x32-avx.dat: Removed.
8681 * regformats/i386/x32.dat: Removed.
8682
8683 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
8684
8685 PR breakpoints/21886
8686 * mem-break.c (default_memory_insert_breakpoint): Use
8687 `->placed_address' rather than `->reqstd_address' for the
8688 breakpoint location.
8689
8690 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
8691
8692 * arch-utils.c (default_print_insn): Remove arch/mach/endian
8693 assertions.
8694
8695 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
8696
8697 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
8698 a union of `tdep_info', `tdesc_data' and `id'.
8699 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
8700 rather than `info.tdep_info'.
8701 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
8702 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
8703 * i386-tdep.c (i386_gdbarch_init): Likewise.
8704 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
8705 * mips-tdep.c (mips_gdbarch_init): Likewise.
8706 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
8707 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
8708 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
8709 `info.tdep_info'.
8710 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
8711 `info.tdep_info'.
8712 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
8713 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
8714 `info.tdep_info'.
8715 * spu-tdep.c (spu_gdbarch_init): Likewise.
8716 * gdbarch.h: Regenerate.
8717
8718 2017-08-07 Leszek Swirski <leszeks@google.com>
8719
8720 PR symtab/20899
8721 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
8722
8723 2017-08-07 Simon Marchi <simon.marchi@ericsson.com>
8724
8725 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
8726 (gdbsim_open): Rename gdb_argv args object to argv.
8727
8728 2017-08-05 Tom Tromey <tom@tromey.com>
8729
8730 * compile/compile-object-load.c (compile_object_load): Use
8731 gdb::unique_xmalloc_ptr.
8732 * cli/cli-dump.c (scan_filename): Rename from
8733 scan_filename_with_cleanup. Change return type.
8734 (scan_expression): Rename from scan_expression_with_cleanup.
8735 Change return type.
8736 (dump_memory_to_file, dump_value_to_file, restore_command):
8737 Use gdb::unique_xmalloc_ptr. Update.
8738 * cli/cli-cmds.c (find_and_open_script): Use
8739 gdb::unique_xmalloc_ptr.
8740 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
8741 * symmisc.c (maintenance_print_symbols)
8742 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
8743 * symfile.c (symfile_bfd_open, generic_load)
8744 (add_symbol_file_command, remove_symbol_file_command): Use
8745 gdb::unique_xmalloc_ptr.
8746 * source.c (openp): Use gdb::unique_xmalloc_ptr.
8747 * psymtab.c (maintenance_print_psymbols): Use
8748 gdb::unique_xmalloc_ptr.
8749 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
8750 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
8751 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
8752 (reload_shared_libraries_1): Likewise.
8753
8754 2017-08-05 Tom Tromey <tom@tromey.com>
8755
8756 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
8757 (rust_op_vector, rust_set_vector): New typedefs.
8758 (current_parser): New global.
8759 (work_obstack): Change to pointer type. Update all users.
8760 (rust_ast, pstate): Remove globals.
8761 (struct rust_parser): New.
8762 (%union) <params, field_inits>: Change type.
8763 (start, tuple_expr, unit_expr, struct_expr_list, literal)
8764 (field_expr, expr_list, maybe_expr_list, type_list): Update.
8765 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
8766 (convert_params_to_types, convert_params_to_expression): Change
8767 type of "params".
8768 (ast_string): Change type of "fields".
8769 (rust_parse): Make a rust_parser. Remove cleanups.
8770 (rust_lex_tests): Make and install an auto_obstack.
8771
8772 2017-08-04 Yao Qi <yao.qi@linaro.org>
8773
8774 * configure.srv (ipa_x32_linux_regobj): New.
8775 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
8776 instead of X86_TDESC_AVX512.
8777 (initialize_low_tracepoint): Call
8778 init_registers_x32_avx_avx512_linux.
8779
8780 2017-08-04 Yao Qi <yao.qi@linaro.org>
8781
8782 * utils.h (gdb_argv): Add namespace std for nullptr_t.
8783
8784 2017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
8785
8786 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
8787
8788 2017-08-03 Tom Tromey <tom@tromey.com>
8789
8790 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
8791 Remove.
8792 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
8793
8794 2017-08-03 Tom Tromey <tom@tromey.com>
8795
8796 * python/py-param.c (compute_enum_values): Use gdb_argv.
8797
8798 2017-08-03 Tom Tromey <tom@tromey.com>
8799
8800 * utils.h (struct gdb_argv_deleter): New.
8801 (gdb_argv): New class.
8802 * utils.c (gdb_argv::reset): New method.
8803 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
8804 * tracefile.c (tsave_command): Use gdb_argv.
8805 * top.c (new_ui_command): Use gdb_argv.
8806 * symmisc.c (maintenance_print_symbols)
8807 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
8808 * symfile.c (symbol_file_command, generic_load)
8809 (remove_symbol_file_command): Use gdb_argv.
8810 * stack.c (backtrace_command): Use gdb_argv.
8811 * source.c (add_path, show_substitute_path_command)
8812 (unset_substitute_path_command, set_substitute_path_command):
8813 Use gdb_argv.
8814 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
8815 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
8816 * remote.c (extended_remote_run, remote_put_command)
8817 (remote_get_command, remote_delete_command): Use gdb_argv.
8818 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
8819 (gdbsim_open): Use gdb_argv.
8820 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
8821 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
8822 * procfs.c (procfs_info_proc): Use gdb_argv.
8823 * interps.c (interpreter_exec_cmd): Use gdb_argv.
8824 * infrun.c (handle_command): Use gdb_argv.
8825 * inferior.c (add_inferior_command, clone_inferior_command):
8826 Use gdb_argv.
8827 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
8828 * exec.c (exec_file_command): Use gdb_argv.
8829 * cli/cli-cmds.c (alias_command): Use gdb_argv.
8830 * compile/compile.c (build_argc_argv): Use gdb_argv.
8831
8832 2017-08-03 Tom Tromey <tom@tromey.com>
8833
8834 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
8835
8836 2017-08-03 Tom Tromey <tom@tromey.com>
8837
8838 * python/python.c (compute_python_string): Return std::string.
8839 (gdbpy_eval_from_control_command): Update.
8840 (do_start_initialization): Use std::string.
8841 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
8842 xstrprintf.
8843 * python/py-breakpoint.c (local_setattro): Use string_printf, not
8844 xstrprintf.
8845
8846 2017-08-03 Tom Tromey <tom@tromey.com>
8847
8848 * top.h (do_restore_instream_cleanup): Remove.
8849 * top.c (do_restore_instream_cleanup): Remove.
8850 (read_command_file): Use scoped_restore.
8851 * cli/cli-script.c (execute_user_command): Use scoped_restore.
8852
8853 2017-08-03 Tom Tromey <tom@tromey.com>
8854
8855 * cli/cli-script.c (execute_user_command)
8856 (execute_control_command): Use scoped_restore.
8857
8858 2017-08-03 Tom Tromey <tom@tromey.com>
8859
8860 * cli/cli-script.c (do_restore_user_call_depth): Remove.
8861 (execute_user_command): Remove user_call_depth; use
8862 user_args_stack's size instead.
8863
8864 2017-08-03 Tom Tromey <tom@tromey.com>
8865
8866 * top.h (in_user_command): Remove.
8867 * top.c (in_user_command): Remove.
8868 * cli/cli-script.c (do_restore_user_call_depth)
8869 (execute_user_command): Update.
8870
8871 2017-08-03 Tom Tromey <tom@tromey.com>
8872
8873 * valops.c (search_struct_method): Use gdb::byte_vector.
8874 * valarith.c (value_concat): Use std::vector.
8875 * target.c (memory_xfer_partial): Use gdb::byte_vector.
8876 (simple_search_memory): Likewise.
8877 * printcmd.c (find_string_backward): Use gdb::byte_vector.
8878 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
8879 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
8880 * elfread.c (elf_rel_plt_read): Use std::string.
8881 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
8882 * cli/cli-dump.c (restore_section_callback): Use
8883 gdb::byte_vector.
8884
8885 2017-08-03 Tom Tromey <tom@tromey.com>
8886
8887 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
8888
8889 2017-08-03 Tom Tromey <tom@tromey.com>
8890
8891 * tui/tui-regs.c (tui_restore_gdbout): Remove.
8892 (tui_register_format): Use scoped_restore.
8893
8894 2017-08-03 Tom Tromey <tom@tromey.com>
8895
8896 * reverse.c (exec_direction_default): Remove.
8897 (exec_reverse_once): Use scoped_restore.
8898 * remote.c (restore_remote_timeout): Remove.
8899 (remote_flash_erase, remote_flash_write, remote_flash_done)
8900 (readchar, remote_serial_write): Use scoped_restore.
8901 * cli/cli-script.c (struct source_cleanup_lines_args)
8902 (source_cleanup_lines): Remove.
8903 (script_from_file): Use scoped_restore.
8904 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
8905 (source_command): Use scoped_restore.
8906
8907 2017-08-03 Tom Tromey <tom@tromey.com>
8908
8909 * utils.h (make_cleanup_free_so): Remove.
8910 * utils.c (do_free_so, make_cleanup_free_so): Remove.
8911 * solist.h (struct so_deleter): New.
8912 (so_list_up): New typedef.
8913 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
8914
8915 2017-08-03 Tom Tromey <tom@tromey.com>
8916
8917 * utils.h (make_cleanup_restore_current_language): Remove.
8918 * utils.c (do_restore_current_language)
8919 (make_cleanup_restore_current_language): Remove.
8920 * parse.c (parse_exp_in_context_1)
8921 (parse_expression_with_language): Use
8922 scoped_restore_current_language.
8923 * mi/mi-main.c (mi_cmd_execute): Use
8924 scoped_restore_current_language.
8925 * language.h (scoped_restore_current_language): New class.
8926
8927 2017-08-03 Tom Tromey <tom@tromey.com>
8928
8929 * compile/compile.c (cleanup_unlink_file): Remove.
8930 (compile_to_object): Use gdb::unlinker.
8931 (eval_compile_command): Likewise.
8932
8933 2017-08-03 Tom Tromey <tom@tromey.com>
8934
8935 * utils.h (make_cleanup_fclose): Remove.
8936 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
8937
8938 2017-08-03 Tom Tromey <tom@tromey.com>
8939
8940 * top.c (open_terminal_stream): Return gdb_file_up.
8941 (new_ui_command): Update.
8942
8943 2017-08-03 Tom Tromey <tom@tromey.com>
8944
8945 * source.c (print_source_lines_base, forward_search_command)
8946 (reverse_search_command): Use gdb_file_up.
8947
8948 2017-08-03 Tom Tromey <tom@tromey.com>
8949
8950 * fbsd-nat.c (fbsd_find_memory_regions): Update.
8951
8952 2017-08-03 Tom Tromey <tom@tromey.com>
8953
8954 * cli/cli-cmds.c (find_and_open_script): Change return type.
8955 Remove "streamp" and "full_path" parameters.
8956 (source_script_with_search): Update.
8957 * auto-load.c (source_script_file): Update.
8958 * cli/cli-cmds.h (find_and_open_script): Change type.
8959 (open_script): New struct.
8960
8961 2017-08-03 Tom Tromey <tom@tromey.com>
8962
8963 * xml-support.c (xml_fetch_content_from_file): Update.
8964 * ui-file.c (stdio_file::open): Update.
8965 * tracefile-tfile.c (tfile_start): Update.
8966 * remote.c (remote_file_put, remote_file_get): Update.
8967 * nat/linux-procfs.c (linux_proc_get_int)
8968 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
8969 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
8970 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
8971 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
8972 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
8973 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
8974 * linux-nat.c (linux_proc_pending_signals): Update.
8975 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
8976 (file_closer): Remove.
8977 * compile/compile.c (compile_to_object): Update.
8978 * common/filestuff.h (struct gdb_file_deleter): New.
8979 (gdb_file_up): New typedef.
8980 (gdb_fopen_cloexec): Change return type.
8981 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
8982 * cli/cli-dump.c (fopen_with_cleanup): Remove.
8983 (dump_binary_file, restore_binary_file): Update.
8984 * auto-load.c (auto_load_objfile_script_1): Update.
8985
8986 2017-08-03 Tom Tromey <tom@tromey.com>
8987
8988 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
8989 (info_static_tracepoint_markers_command): Likewise.
8990 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
8991 * skip.c (skip_info): Use ui_out_emit_table.
8992 * progspace.c (print_program_space): Use ui_out_emit_table.
8993 * osdata.c (info_osdata): Use ui_out_emit_table.
8994 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
8995 ui_out_emit_table.
8996 * linux-thread-db.c (info_auto_load_libthread_db): Use
8997 ui_out_emit_table.
8998 * inferior.c (print_inferior): Use ui_out_emit_table.
8999 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
9000 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
9001 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
9002 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
9003 * ui-out.h (class ui_out_emit_table): New.
9004
9005 2017-08-02 Maciej W. Rozycki <macro@imgtec.com>
9006
9007 * mips-tdep.c (mips_fpu_type_str): New function.
9008 (mips_dump_tdep): Call it.
9009
9010 2017-08-01 Maciej W. Rozycki <macro@imgtec.com>
9011
9012 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
9013 `->mips_fpu_type'.
9014
9015 2017-07-31 Xavier Roirand <roirand@adacore.com>
9016
9017 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
9018
9019 2017-07-27 Xavier Roirand <roirand@adacore.com>
9020
9021 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
9022
9023 2017-07-26 Yao Qi <yao.qi@linaro.org>
9024
9025 * cli/cli-cmds.c (maintenancechecklist): New variable.
9026 * gdbcmd.h (maintenancechecklist): Declare it.
9027 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
9028 Call i386_linux_read_description with different masks.
9029 * maint.c (maintenance_check_command): New function.
9030 (_initialize_maint_cmds): Call add_prefix_cmd.
9031 * target-descriptions.c (tdesc_reg): override operator != and ==.
9032 (tdesc_type): Likewise.
9033 (tdesc_feature): Likewise.
9034 (target_desc): Likewise.
9035 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
9036 (maintenance_check_xml_descriptions): New function.
9037 (_initialize_target_descriptions) Add command "xml-descriptions".
9038 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
9039
9040 2017-07-26 Yao Qi <yao.qi@linaro.org>
9041
9042 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
9043 Include features/i386/32bit-*.c.
9044 (i386_linux_read_description): Generate target description if it
9045 doesn't exist.
9046 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
9047 functions.
9048 * features/i386/32bit-linux.c: Re-generated.
9049 * features/i386/32bit-sse.c: Likewise.
9050 * target-descriptions.c (print_c_feature::visit): Print code to
9051 set register number if needed.
9052 (print_c_feature) <m_next_regnum>: New field.
9053
9054 2017-07-26 Yao Qi <yao.qi@linaro.org>
9055
9056 * features/Makefile (CFILES): Rename with TDESC_CFILES.
9057 (FEATURE_XMLFILES): New.
9058 (FEATURE_CFILES): New.
9059 New rules.
9060 (clean-cfiles): Remove generated c files.
9061 * features/i386/32bit-avx.c: Generated.
9062 * features/i386/32bit-avx512.c: Generated.
9063 * features/i386/32bit-core.c: Generated.
9064 * features/i386/32bit-linux.c: Generated.
9065 * features/i386/32bit-mpx.c: Generated.
9066 * features/i386/32bit-pkeys.c: Generated.
9067 * features/i386/32bit-sse.c: Generated.
9068 * target-descriptions.c: Include algorithm.
9069 (tdesc_element_visitor): Add method visit_end.
9070 (print_c_tdesc): Implement visit_end.
9071 (print_c_tdesc:: m_filename_after_features): Move it to
9072 protected.
9073 (print_c_feature): New class.
9074 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
9075 name starts with "i386/32bit-".
9076
9077 2017-07-26 Yao Qi <yao.qi@linaro.org>
9078
9079 * target-descriptions.c (tdesc_element_visitor): New class.
9080 (tdesc_element): New class.
9081 (tdesc_reg): Inherit from tdesc_element.
9082 (tdesc_reg::accept): New function.
9083 (tdesc_type): Inherit from tdesc_element.
9084 (tdesc_type::accept): New function.
9085 (tdesc_feature): Inherit from tdesc_element.
9086 (tdesc_feature::accept): New function.
9087 (target_desc): Inherit from tdesc_element.
9088 (target_desc::target_desc): New.
9089 (target_desc::~target_desc): New.
9090 (target_desc::accept): New.
9091 (allocate_target_description): Use new.
9092 (free_target_description): Use delete.
9093 (print_c_tdesc): New class.
9094 (maint_print_c_tdesc_cmd): Adjust.
9095
9096 * features/aarch64.c: Re-generated.
9097 * features/arc-arcompact.c: Re-generated.
9098 * features/arc-v2.c: Re-generated.
9099 * features/arm/arm-with-iwmmxt.c: Re-generated.
9100 * features/arm/arm-with-m.c: Re-generated.
9101 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
9102 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
9103 * features/arm/arm-with-neon.c: Re-generated.
9104 * features/arm/arm-with-vfpv2.c: Re-generated.
9105 * features/arm/arm-with-vfpv3.c: Re-generated.
9106 * features/i386/amd64-avx-avx512.c: Re-generated.
9107 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
9108 * features/i386/amd64-avx.c: Re-generated.
9109 * features/i386/amd64-avx-linux.c: Re-generated.
9110 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
9111 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
9112 * features/i386/amd64-avx-mpx.c: Re-generated.
9113 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
9114 * features/i386/amd64.c: Re-generated.
9115 * features/i386/amd64-linux.c: Re-generated.
9116 * features/i386/amd64-mpx.c: Re-generated.
9117 * features/i386/amd64-mpx-linux.c: Re-generated.
9118 * features/i386/i386-avx-avx512.c: Re-generated.
9119 * features/i386/i386-avx-avx512-linux.c: Re-generated.
9120 * features/i386/i386-avx.c: Re-generated.
9121 * features/i386/i386-avx-linux.c: Re-generated.
9122 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
9123 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
9124 * features/i386/i386-avx-mpx.c: Re-generated.
9125 * features/i386/i386-avx-mpx-linux.c: Re-generated.
9126 * features/i386/i386.c: Re-generated.
9127 * features/i386/i386-linux.c: Re-generated.
9128 * features/i386/i386-mmx.c: Re-generated.
9129 * features/i386/i386-mmx-linux.c: Re-generated.
9130 * features/i386/i386-mpx.c: Re-generated.
9131 * features/i386/i386-mpx-linux.c: Re-generated.
9132 * features/i386/x32-avx-avx512.c: Re-generated.
9133 * features/i386/x32-avx-avx512-linux.c: Re-generated.
9134 * features/i386/x32-avx.c: Re-generated.
9135 * features/i386/x32-avx-linux.c: Re-generated.
9136 * features/i386/x32.c: Re-generated.
9137 * features/i386/x32-linux.c: Re-generated.
9138 * features/microblaze.c: Re-generated.
9139 * features/microblaze-with-stack-protect.c: Re-generated.
9140 * features/mips64-dsp-linux.c: Re-generated.
9141 * features/mips64-linux.c: Re-generated.
9142 * features/mips-dsp-linux.c: Re-generated.
9143 * features/mips-linux.c: Re-generated.
9144 * features/nds32.c: Re-generated.
9145 * features/nios2.c: Re-generated.
9146 * features/nios2-linux.c: Re-generated.
9147 * features/rs6000/powerpc-32.c: Re-generated.
9148 * features/rs6000/powerpc-32l.c: Re-generated.
9149 * features/rs6000/powerpc-403.c: Re-generated.
9150 * features/rs6000/powerpc-403gc.c : Re-generated.
9151 * features/rs6000/powerpc-405.c: Re-generated.
9152 * features/rs6000/powerpc-505.c: Re-generated.
9153 * features/rs6000/powerpc-601.c: Re-generated.
9154 * features/rs6000/powerpc-602.c: Re-generated.
9155 * features/rs6000/powerpc-603.c: Re-generated.
9156 * features/rs6000/powerpc-604.c: Re-generated.
9157 * features/rs6000/powerpc-64.c: Re-generated.
9158 * features/rs6000/powerpc-64l.c: Re-generated.
9159 * features/rs6000/powerpc-7400.c: Re-generated.
9160 * features/rs6000/powerpc-750.c: Re-generated.
9161 * features/rs6000/powerpc-860.c: Re-generated.
9162 * features/rs6000/powerpc-altivec32.c: Re-generated.
9163 * features/rs6000/powerpc-altivec32l.c: Re-generated.
9164 * features/rs6000/powerpc-altivec64.c: Re-generated.
9165 * features/rs6000/powerpc-altivec64l.c: Re-generated.
9166 * features/rs6000/powerpc-cell32l.c: Re-generated.
9167 * features/rs6000/powerpc-cell64l.c: Re-generated.
9168 * features/rs6000/powerpc-e500.c: Re-generated.
9169 * features/rs6000/powerpc-e500l.c: Re-generated.
9170 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
9171 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
9172 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
9173 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
9174 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
9175 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
9176 * features/rs6000/powerpc-vsx32.c: Re-generated.
9177 * features/rs6000/powerpc-vsx32l.c: Re-generated.
9178 * features/rs6000/powerpc-vsx64.c: Re-generated.
9179 * features/rs6000/powerpc-vsx64l.c: Re-generated.
9180 * features/rs6000/rs6000.c: Re-generated.
9181 * features/s390-linux32.c: Re-generated.
9182 * features/s390-linux32v1.c: Re-generated.
9183 * features/s390-linux32v2.c: Re-generated.
9184 * features/s390-linux64.c: Re-generated.
9185 * features/s390-linux64v1.c: Re-generated.
9186 * features/s390-linux64v2.c: Re-generated.
9187 * features/s390-te-linux64.c: Re-generated.
9188 * features/s390-tevx-linux64.c: Re-generated.
9189 * features/s390-vx-linux64.c: Re-generated.
9190 * features/s390x-linux64.c: Re-generated.
9191 * features/s390x-linux64v1.c: Re-generated.
9192 * features/s390x-linux64v2.c: Re-generated.
9193 * features/s390x-te-linux64.c: Re-generated.
9194 * features/s390x-tevx-linux64.c: Re-generated.
9195 * features/s390x-vx-linux64.c: Re-generated.
9196 * features/sparc/sparc32-solaris.c: Re-generated.
9197 * features/sparc/sparc64-solaris.c: Re-generated.
9198 * features/tic6x-c62x.c: Re-generated.
9199 * features/tic6x-c62x-linux.c: Re-generated.
9200 * features/tic6x-c64x.c: Re-generated.
9201 * features/tic6x-c64x-linux.c: Re-generated.
9202 * features/tic6x-c64xp.c: Re-generated.
9203 * features/tic6x-c64xp-linux.c: Re-generated.
9204
9205 2017-07-26 Yao Qi <yao.qi@linaro.org>
9206
9207 * i386-linux-tdep.c (i386_linux_read_description): New function.
9208 (i386_linux_core_read_description): Call
9209 i386_linux_read_description.
9210 * i386-linux-tdep.h (i386_linux_read_description): Declare.
9211 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
9212 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
9213 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
9214 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
9215 * x86-linux-nat.c (x86_linux_read_description): Call
9216 i386_linux_read_description.
9217
9218 2017-07-26 Yao Qi <yao.qi@linaro.org>
9219
9220 * NEWS: Mention it.
9221 * features/Makefile (%.c: %.xml): Pass the xml file name to
9222 command "maint print c-tdesc".
9223 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
9224 name from 'arg'.
9225
9226 2017-07-26 Yao Qi <yao.qi@linaro.org>
9227
9228 * target-descriptions.c (target_desc): Add ctor and dtor. Do
9229 in-class initialization.
9230 (tdesc_create_feature): Call new instead of XCNEW.
9231 (free_target_description): Ue delete.
9232
9233 2017-07-25 John Baldwin <jhb@FreeBSD.org>
9234
9235 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
9236
9237 2017-07-25 Yao Qi <yao.qi@linaro.org>
9238
9239 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
9240 constant.
9241 (amd64_x32_init_abi): Likewise.
9242 * amd64-tdep.h (amd64_init_abi): Update declaration.
9243 (amd64_x32_init_abi): Likewise.
9244
9245 2017-07-25 Yao Qi <yao.qi@linaro.org>
9246
9247 PR tdep/21717
9248 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
9249 condition for FPSCR.
9250 (arm_linux_store_inferior_registers): Likewise.
9251
9252 2017-07-22 Tom Tromey <tom@tromey.com>
9253
9254 * break-catch-syscall.c (struct catch_syscall_inferior_data)
9255 <syscalls_counts>: Now a std::vector.
9256 (get_catch_syscall_inferior_data): Use "new".
9257 (catch_syscall_inferior_data_cleanup): Use "delete".
9258 (insert_catch_syscall, remove_catch_syscall)
9259 (clear_syscall_counts): Update.
9260
9261 2017-07-22 Tom Tromey <tom@tromey.com>
9262
9263 * break-catch-syscall.c (syscall_catchpoint)
9264 <syscalls_to_be_caught>: Now a std::vector<int>
9265 (~syscall_catchpoint): Remove.
9266 (insert_catch_syscall, remove_catch_syscall)
9267 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
9268 (print_mention_catch_syscall, print_recreate_catch_syscall):
9269 Update.
9270 (create_syscall_event_catchpoint): Change type of "filter"
9271 parameter.
9272 (catch_syscall_split_args): Return a std::vector.
9273 (catch_syscall_command_1, catching_syscall_number_1): Update.
9274
9275 2017-07-22 Tom Tromey <tom@tromey.com>
9276
9277 * break-catch-throw.c (struct exception_catchpoint)
9278 <exception_rx>: Now a std::string.
9279 (~exception_catchpoint): Remove.
9280 (print_one_detail_exception_catchpoint): Update.
9281 (handle_gnu_v3_exceptions): Change type of except_rx.
9282 (extract_exception_regexp): Return a std::string.
9283 (catch_exception_command_1): Update.
9284
9285 2017-07-22 Tom Tromey <tom@tromey.com>
9286
9287 * break-catch-sig.c (gdb_signal_type): Remove typedef.
9288 (struct signal_catchpoint) <signals_to_be_caught>: Now a
9289 std::vector.
9290 <catch_all>: Now a bool.
9291 (~signal_catchpoint): Remove.
9292 (signal_catchpoint_insert_location)
9293 (signal_catchpoint_remove_location)
9294 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
9295 (signal_catchpoint_print_mention)
9296 (signal_catchpoint_print_recreate)
9297 (signal_catchpoint_explains_signal): Update.
9298 (create_signal_catchpoint): Change type of "filter" and
9299 "catch_all".
9300 (catch_signal_split_args): Return a std::vector. Change type of
9301 "catch_all".
9302 (catch_signal_command): Update.
9303
9304 2017-07-20 Pedro Alves <palves@redhat.com>
9305
9306 * ada-lang.c (ada_language_defn): Make extern.
9307 (_initialize_ada_language): Remove add_language call.
9308 * c-lang.c (c_language_defn, cplus_language_defn)
9309 (asm_language_defn, minimal_language_defn): Make extern.
9310 (_initialize_c_language): Delete.
9311 * completer.c (compare_cstrings): Delete, moved to utils.h.
9312 * d-lang.c (d_language_defn): Make extern.
9313 (_initialize_d_language): Remove add_language calls.
9314 * defs.h (enum language): Add comment.
9315 * f-lang.c (f_language_defn): Make extern.
9316 (_initialize_f_language): Remove add_language call.
9317 * go-lang.c (go_language_defn): Make extern.
9318 (_initialize_go_language): Remove add_language call.
9319 * language.c: Include <algorithm>.
9320 (languages): Redefine as const array.
9321 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
9322 (set_language_command): Handle "local". Use for-range loop.
9323 (set_language): Remove loop.
9324 (language_enum): Rewrite.
9325 (language_def, language_str): Remove loops.
9326 (add_language): Delete.
9327 (add_set_language_command): New, based on add_languages.
9328 (skip_language_trampoline): Adjust.
9329 (local_language_defn): Delete.
9330 (language_gdbarch_post_init): Adjust.
9331 (_initialize_language): Remove add_language calls. Call
9332 add_set_language_command.
9333 * language.h (add_language): Delete.
9334 (auto_language_defn)
9335 (unknown_language_defn, minimal_language_defn, ada_language_defn)
9336 (asm_language_defn, c_language_defn, cplus_language_defn)
9337 (d_language_defn, f_language_defn, go_language_defn)
9338 (m2_language_defn, objc_language_defn, opencl_language_defn)
9339 (pascal_language_defn, rust_language_defn): Declare.
9340 * m2-lang.c (m2_language_defn): Make extern.
9341 (_initialize_m2_language): Remove add_language call.
9342 * objc-lang.c (objc_language_defn): Make extern.
9343 (_initialize_objc_language): Remove add_language call.
9344 * opencl-lang.c (opencl_language_defn): Make extern.
9345 (_initialize_opencl_language): Remove add_language call.
9346 * p-lang.c (pascal_language_defn): Make extern.
9347 (_initialize_pascal_language): Delete.
9348 * rust-lang.c (rust_language_defn): Make extern.
9349 (_initialize_rust_language): Delete.
9350 * utils.h (compare_cstrings): New static inline function.
9351
9352 2017-07-20 Pedro Alves <palves@redhat.com>
9353
9354 * ada-lang.c (ada_to_fixed_type_1): Adjust.
9355 (get_var_value): Constify parameters.
9356 (get_int_var_value): Change prototype.
9357 (to_fixed_range_type): Adjust.
9358 * ada-lang.h (get_int_var_value): Change prototype.
9359
9360 2017-07-20 Pedro Alves <palves@redhat.com>
9361
9362 * dwarf2read.c (dw2_lookup_symbol): Use
9363 SYMBOL_MATCHES_SEARCH_NAME.
9364 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
9365
9366 2017-07-20 Pedro Alves <palves@redhat.com>
9367
9368 * block.c (block_iter_name_step, block_iter_name_first)
9369 (block_iter_name_next): Delete.
9370 (block_lookup_symbol_primary): Adjust to use
9371 dict_iter_match_first/dict_iter_match_next.
9372 * block.h (block_iter_name_first, block_iter_name_next): Delete
9373 declarations.
9374 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
9375 dict_iter_match_first/dict_iter_match_next.
9376
9377 2017-07-20 Pedro Alves <palves@redhat.com>
9378
9379 * cp-support.c (cp_find_first_component_aux): Add missing case for
9380 end of string.
9381
9382 2017-07-18 David Blaikie <dblaikie@gmail.com>
9383
9384 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
9385 of dwo_cu's dwo_file.
9386
9387 2017-07-18 Yao Qi <yao.qi@linaro.org>
9388
9389 * remote.c (store_registers_using_G): Remove one line comment.
9390
9391 2017-07-18 Yao Qi <yao.qi@linaro.org>
9392
9393 * regcache.c (regcache_cpy): Simplify it.
9394 (regcache::cpy_no_passthrough): Remove it.
9395 * regcache.h (cpy_no_passthrough): Remove it.
9396 (regcache_dup, regcache_cpy): Update comments.
9397
9398 2017-07-18 Pedro Alves <palves@redhat.com>
9399
9400 * remote-sim.c (sim_command_completer): Adjust to work with a
9401 completion_tracker instead of a VEC.
9402
9403 2017-07-17 Pedro Alves <palves@redhat.com>
9404
9405 * completer.c (complete_source_filenames): New function.
9406 (complete_address_and_linespec_locations): New function.
9407 (location_completer): Use complete_address_and_linespec_locations.
9408 (completion_tracker::build_completion_result): Honor the tracker's
9409 request to suppress append.
9410 * completer.h (completion_tracker::suppress_append_ws)
9411 (completion_tracker::set_suppress_append_ws): New methods.
9412 (completion_tracker::m_suppress_append_ws): New field.
9413 (complete_source_filenames): New declaration.
9414 * linespec.c (linespec_complete_what): New.
9415 (struct ls_parser) <complete_what, completion_word,
9416 completion_quote_char, completion_quote_end, completion_tracker>:
9417 New fields.
9418 (string_find_incomplete_keyword_at_end): New.
9419 (linespec_lexer_lex_string): Record quote char. If in completion
9420 mode, don't throw.
9421 (linespec_lexer_consume_token): Advance the completion word point.
9422 (linespec_lexer_peek_token): Save/restore completion info.
9423 (save_stream_and_consume_token): New.
9424 (set_completion_after_number): New.
9425 (linespec_parse_basic): Set what to complete next depending on
9426 token. Handle function and label completions specially.
9427 (parse_linespec): Disable objc shortcut in completion mode. Set
9428 what to complete next depending on token type. Skip keyword if in
9429 completion mode.
9430 (complete_linespec_component, linespec_complete): New.
9431 * linespec.h (linespec_complete): Declare.
9432
9433 2017-07-17 Pedro Alves <palves@redhat.com>
9434
9435 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
9436 Handle 'operator<' / 'operator<<'.
9437
9438 2017-07-17 Pedro Alves <palves@redhat.com>
9439
9440 * completer.c (collect_explicit_location_matches): Handle
9441 MATCH_LABEL.
9442 (convert_explicit_location_to_linespec): New, factored out from
9443 ...
9444 (convert_explicit_location_to_sals): ... this.
9445 (complete_label): New.
9446 (linespec_complete_label, find_label_symbols_in_block): New.
9447 (find_label_symbols): Add completion_mode parameter and adjust to
9448 call find_label_symbols_in_block.
9449 * linespec.h (linespec_complete_label): Declare.
9450
9451 2017-07-17 Pedro Alves <palves@redhat.com>
9452
9453 * ada-lang.c (ada_collect_symbol_completion_matches): Add
9454 complete_symbol_mode parameter.
9455 * cli/cli-cmds.c (complete_command): Get the completion result out
9456 of the handle_brkchars tracker if used a custom word point.
9457 * completer.c: Include "linespec.h".
9458 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
9459 (advance_to_expression_complete_word_point): New.
9460 (completion_tracker::completes_to_completion_word): New.
9461 (complete_files_symbols): Pass down
9462 complete_symbol_mode::EXPRESSION.
9463 (explicit_options, probe_options): New.
9464 (collect_explicit_location_matches): Complete on the
9465 explictit_loc->foo instead of word. Use
9466 linespec_complete_function. Handle MATCH_LINE. Handle offering
9467 keyword and options completions.
9468 (backup_text_ptr): Delete.
9469 (skip_keyword): New.
9470 (complete_explicit_location): Remove 'word' parameter. Add
9471 language, quoted_arg_start and quoted_arg_end parameters.
9472 Rewrite, parsing left to right.
9473 (location_completer): Rewrite.
9474 (location_completer_handle_brkchars): New function.
9475 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
9476 (enum complete_line_internal_reason): Adjust comments.
9477 (completion_tracker::discard_completions): New.
9478 (completer_handle_brkchars_func_for_completer): Handle
9479 location_completer.
9480 (gdb_custom_word_point_brkchars)
9481 (gdb_org_rl_basic_quote_characters): New.
9482 (gdb_completion_word_break_characters_throw)
9483 (completion_find_completion_word): Handle trackers that use a
9484 custom word point.
9485 (completion_tracker::advance_custom_word_point_by): New.
9486 (completion_tracker::build_completion_result): Don't rely on
9487 readline appending the quote char.
9488 (gdb_rl_attempted_completion_function_throw): Handle trackers that
9489 use a custom word point.
9490 (gdb_rl_attempted_completion_function): Restore
9491 rl_basic_quote_characters.
9492 * completer.h (class completion_tracker): Extend intro comment.
9493 (completion_tracker::set_quote_char)
9494 (completion_tracker::quote_char)
9495 (completion_tracker::set_use_custom_word_point)
9496 (completion_tracker::use_custom_word_point)
9497 (completion_tracker::custom_word_point)
9498 (completion_tracker::set_custom_word_point)
9499 (completion_tracker::advance_custom_word_point_by)
9500 (completion_tracker::completes_to_completion_word)
9501 (completion_tracker::discard_completions): New methods.
9502 (completion_tracker::m_quote_char)
9503 (completion_tracker::m_use_custom_word_point)
9504 (completion_tracker::m_custom_word_point): New fields.
9505 (advance_to_expression_complete_word_point): Declare.
9506 * f-lang.c (f_collect_symbol_completion_matches): Add
9507 complete_symbol_mode parameter.
9508 * language.h (struct language_defn)
9509 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
9510 parameter.
9511 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
9512 (linespec_complete_function): New function.
9513 (linespec_lexer_lex_keyword): Adjust.
9514 * linespec.h (linespec_keywords, linespec_complete_function): New
9515 declarations.
9516 * location.c (find_end_quote): New function.
9517 (explicit_location_lex_one): Add explicit_completion_info
9518 parameter. Save quoting info. Don't throw if being called for
9519 completion. Don't handle Ada operators here.
9520 (is_cp_operator, skip_op_false_positives, first_of)
9521 (explicit_location_lex_one_function): New function.
9522 (string_to_explicit_location): Replace 'dont_throw' parameter with
9523 an explicit_completion_info pointer parameter. Handle it. Don't
9524 use explicit_location_lex_one to lex function names. Use
9525 explicit_location_lex_one_function instead.
9526 * location.h (struct explicit_completion_info): New.
9527 (string_to_explicit_location): Replace 'dont_throw' parameter with
9528 an explicit_completion_info pointer parameter.
9529 * symtab.c (default_collect_symbol_completion_matches_break_on):
9530 Add complete_symbol_mode parameter. Handle LINESPEC mode.
9531 (default_collect_symbol_completion_matches)
9532 (collect_symbol_completion_matches): Add complete_symbol_mode
9533 parameter.
9534 (collect_symbol_completion_matches_type): Pass down
9535 complete_symbol_mode::EXPRESSION.
9536 (collect_file_symbol_completion_matches): Add complete_symbol_mode
9537 parameter. Handle LINESPEC mode.
9538 * symtab.h (complete_symbol_mode): New.
9539 (default_collect_symbol_completion_matches_break_on)
9540 (default_collect_symbol_completion_matches)
9541 (collect_symbol_completion_matches)
9542 (collect_file_symbol_completion_matches): Add complete_symbol_mode
9543 parameter.
9544
9545 2017-07-17 Pedro Alves <palves@redhat.com>
9546
9547 * utils.c (enum class strncmp_iw_mode): New.
9548 (strcmp_iw): Rename to ...
9549 (strncmp_iw_with_mode): ... this. Add string2_len and mode
9550 parameters. Handle them.
9551 (strncmp_iw): New.
9552 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
9553 * utils.h (strncmp_iw): Declare.
9554 (strcmp_iw): Move describing comments here.
9555
9556 2017-07-17 Pedro Alves <palves@redhat.com>
9557
9558 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
9559 CP_OPERATOR_STR.
9560 * c-typeprint.c (is_type_conversion_operator): Use
9561 CP_OPERATOR_STR.
9562 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
9563 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
9564 CP_OPERATOR_LEN.
9565 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
9566 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
9567 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
9568 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
9569 CP_OPERATOR_STR.
9570 * location.c: Include "cp-support.h".
9571 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
9572 CP_OPERATOR_STR.
9573 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
9574 CP_OPERATOR_LEN.
9575
9576 2017-07-17 Pedro Alves <palves@redhat.com>
9577
9578 * cli/cli-cmds.c (complete_command): Use a completion tracker
9579 along with completion_find_completion_word for handle_brkchars
9580 phase.
9581 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
9582 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
9583 (struct gdb_rl_completion_word_info): New.
9584 (gdb_rl_find_completion_word): New.
9585 (completion_find_completion_word): New.
9586 * completer.h (completion_find_completion_word): Declare.
9587
9588 2017-07-17 Pedro Alves <palves@redhat.com>
9589
9590 * ada-lang.c (symbol_completion_match): Adjust comments.
9591 (symbol_completion_add): Replace vector parameter with
9592 completion_tracker parameter. Use it.
9593 (ada_make_symbol_completion_list): Rename to...
9594 (ada_collect_symbol_completion_matches): ... this. Add
9595 completion_tracker parameter and use it.
9596 (ada_language_defn): Adjust.
9597 * break-catch-syscall.c (catch_syscall_completer): Adjust
9598 prototype and work with completion_tracker instead of VEC.
9599 * breakpoint.c (condition_completer): Adjust prototype and work
9600 with completion_tracker instead of VEC.
9601 * c-lang.c (c_language_defn, cplus_language_defn)
9602 (asm_language_defn, minimal_language_defn): Adjust to renames.
9603 * cli/cli-cmds.c (complete_command): Rework using
9604 completion_tracker. Catch exceptions when completing.
9605 * cli/cli-decode.c (integer_unlimited_completer)
9606 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
9607 with completion_tracker instead of VEC.
9608 * command.h (struct completion_tracker): Forward declare.
9609 (completer_ftype, completer_handle_brkchars_ftype): Change
9610 types.
9611 (complete_on_cmdlist, complete_on_enum): Adjust.
9612 * completer.c: Include <algorithm>.
9613 (struct gdb_completer_state): New.
9614 (current_completion): New global.
9615 (readline_line_completion_function): Delete.
9616 (noop_completer, filename_completer)
9617 (filename_completer_handle_brkchars, complete_files_symbols)
9618 (linespec_location_completer): Adjust to work with a
9619 completion_tracker instead of a VEC.
9620 (string_or_empty): New.
9621 (collect_explicit_location_matches): Adjust to work with a
9622 completion_tracker instead of a VEC.
9623 (explicit_location_completer): Rename to ...
9624 (complete_explicit_location): ... this and adjust to work with a
9625 completion_tracker instead of a VEC.
9626 (location_completer): Adjust to work with a completion_tracker
9627 instead of a VEC.
9628 (add_struct_fields): Adjust to work with a completion_list instead
9629 of VEC.
9630 (expression_completer): Rename to ...
9631 (complete_expression): ... this and adjust to work with a
9632 completion_tracker instead of a VEC. Use complete_files_symbols.
9633 (expression_completer): Reimplement on top of complete_expression.
9634 (symbol_completer): Adjust to work with a completion_tracker
9635 instead of a VEC.
9636 (enum complete_line_internal_reason): Add describing comments.
9637 (complete_line_internal_normal_command): Adjust to work with a
9638 completion_tracker instead of a VEC.
9639 (complete_line_internal): Rename to ...
9640 (complete_line_internal_1): ... this and adjust to work with a
9641 completion_tracker instead of a VEC. Assert TEXT is NULL in the
9642 handle_brkchars phase.
9643 (new_completion_tracker): Delete.
9644 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
9645 complete_line_internal_1.
9646 (free_completion_tracker): Delete.
9647 (INITIAL_COMPLETION_HTAB_SIZE): New.
9648 (completion_tracker::completion_tracker)
9649 (completion_tracker::~completion_tracker): New.
9650 (maybe_add_completion): Delete.
9651 (completion_tracker::maybe_add_completion)
9652 (completion_tracker::add_completion)
9653 (completion_tracker::add_completions): New.
9654 (throw_max_completions_reached_error): Delete.
9655 (complete_line): Adjust to work with a completion_tracker instead
9656 of a VEC. Don't create a completion_tracker_t or check for max
9657 completions here.
9658 (command_completer, command_completer_handle_brkchars)
9659 (signal_completer, reg_or_group_completer_1)
9660 (reg_or_group_completer, default_completer_handle_brkchars):
9661 Adjust to work with a completion_tracker.
9662 (gdb_completion_word_break_characters_throw): New.
9663 (gdb_completion_word_break_characters): Reimplement.
9664 (line_completion_function): Delete.
9665 (completion_tracker::recompute_lowest_common_denominator)
9666 (expand_preserving_ws)
9667 (completion_tracker::build_completion_result)
9668 (completion_result::completion_result)
9669 (completion_result::completion_result)
9670 (completion_result::~completion_result)
9671 (completion_result::completion_result)
9672 (completion_result::release_match_list, compare_cstrings)
9673 (completion_result::sort_match_list)
9674 (completion_result::reset_match_list)
9675 (gdb_rl_attempted_completion_function_throw)
9676 (gdb_rl_attempted_completion_function): New.
9677 * completer.h (completion_list, struct completion_result)
9678 (class completion_tracker): New.
9679 (complete_line): Add completion_tracker parameter.
9680 (readline_line_completion_function): Delete.
9681 (gdb_rl_attempted_completion_function): New.
9682 (noop_completer, filename_completer, expression_completer)
9683 (location_completer, symbol_completer, command_completer)
9684 (signal_completer, reg_or_group_completer): Update prototypes.
9685 (completion_tracker_t, new_completion_tracker)
9686 (make_cleanup_free_completion_tracker): Delete.
9687 (enum maybe_add_completion_enum): Delete.
9688 (maybe_add_completion): Delete.
9689 (throw_max_completions_reached_error): Delete.
9690 * corefile.c (complete_set_gnutarget): Adjust to work with a
9691 completion_tracker instead of a VEC.
9692 * cp-abi.c (cp_abi_completer): Adjust to work with a
9693 completion_tracker instead of a VEC.
9694 * d-lang.c (d_language_defn): Adjust.
9695 * disasm.c (disassembler_options_completer): Adjust to work with a
9696 completion_tracker instead of a VEC.
9697 * f-lang.c (f_make_symbol_completion_list): Rename to ...
9698 (f_collect_symbol_completion_matches): ... this. Adjust to work
9699 with a completion_tracker instead of a VEC.
9700 (f_language_defn): Adjust.
9701 * go-lang.c (go_language_defn): Adjust.
9702 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
9703 Adjust to work with a completion_tracker instead of a VEC.
9704 * infrun.c (handle_completer): Likewise.
9705 * interps.c (interpreter_completer): Likewise.
9706 * interps.h (interpreter_completer): Likewise.
9707 * language.c (unknown_language_defn, auto_language_defn)
9708 (local_language_defn): Adjust.
9709 * language.h (language_defn::la_make_symbol_completion_list):
9710 Rename to ...
9711 (language_defn::la_collect_symbol_completion_matches): ... this
9712 and adjust to work with a completion_tracker instead of a VEC.
9713 * m2-lang.c (m2_language_defn): Adjust.
9714 * objc-lang.c (objc_language_defn): Adjust.
9715 * opencl-lang.c (opencl_language_defn): Adjust.
9716 * p-lang.c (pascal_language_defn): Adjust.
9717 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
9718 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
9719 with a completion_tracker.
9720 * rust-lang.c (rust_language_defn): Adjust.
9721 * symtab.c (free_completion_list, do_free_completion_list)
9722 (return_val, completion_tracker): Delete.
9723 (completion_list_add_name, completion_list_add_symbol)
9724 (completion_list_add_msymbol, completion_list_objc_symbol)
9725 (completion_list_add_fields, add_symtab_completions): Add
9726 completion_tracker parameter and use it.
9727 (default_make_symbol_completion_list_break_on_1): Rename to...
9728 (default_collect_symbol_completion_matches_break_on): ... this.
9729 Add completion_tracker parameter and use it instead of allocating
9730 a completion tracker here.
9731 (default_make_symbol_completion_list_break_on): Delete old
9732 implementation.
9733 (default_make_symbol_completion_list): Delete.
9734 (default_collect_symbol_completion_matches): New.
9735 (make_symbol_completion_list): Delete.
9736 (collect_symbol_completion_matches): New.
9737 (make_symbol_completion_type): Rename to ...
9738 (collect_symbol_completion_matches_type): ... this. Add
9739 completion_tracker parameter and use it instead of VEC.
9740 (make_file_symbol_completion_list_1): Rename to...
9741 (collect_file_symbol_completion_matches): ... this. Add
9742 completion_tracker parameter and use it instead of VEC.
9743 (make_file_symbol_completion_list): Delete.
9744 (add_filename_to_list): Use completion_list instead of a VEC.
9745 (add_partial_filename_data::list): Now a completion_list.
9746 (make_source_files_completion_list): Work with a completion_list
9747 instead of a VEC.
9748 * symtab.h: Include "completer.h".
9749 (default_make_symbol_completion_list_break_on)
9750 (default_make_symbol_completion_list, make_symbol_completion_list)
9751 (make_symbol_completion_type, make_file_symbol_completion_list)
9752 (make_source_files_completion_list): Delete.
9753 (default_collect_symbol_completion_matches_break_on)
9754 (default_collect_symbol_completion_matches)
9755 (collect_symbol_completion_matches)
9756 (collect_symbol_completion_matches_type)
9757 (collect_file_symbol_completion_matches)
9758 (make_source_files_completion_list): New.
9759 * top.c (init_main): Don't install a rl_completion_entry_function
9760 hook. Install a rl_attempted_completion_function hook instead.
9761 * tui/tui-layout.c (layout_completer): Adjust to work with a
9762 completion_tracker.
9763 * tui/tui-regs.c (tui_reggroup_completer):
9764 * tui/tui-win.c (window_name_completer, focus_completer)
9765 (winheight_completer): Adjust to work with a completion_tracker.
9766 * value.c: Include "completer.h".
9767 (complete_internalvar): Adjust to work with a completion_tracker.
9768 * value.h (complete_internalvar): Likewise.
9769
9770 2017-07-17 Pedro Alves <palves@redhat.com>
9771
9772 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
9773 renames.
9774 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
9775 comments to completer_ftype's declaration.
9776 <completer_handle_brkchars>: Change type to
9777 completer_handle_brkchars_ftype.
9778 * command.h (completer_ftype): Add describing comment and give
9779 names to parameters.
9780 (completer_ftype_void): Rename to ...
9781 (completer_handle_brkchars_ftype) ... this. Add describing comment.
9782 (set_cmd_completer_handle_brkchars): Adjust.
9783 * completer.c (filename_completer_handle_brkchars): New function.
9784 (complete_line_internal_normal_command): New function, factored
9785 out from ...
9786 (complete_line_internal): ... here.
9787 (command_completer_handle_brkchars)
9788 (default_completer_handle_brkchars)
9789 (completer_handle_brkchars_func_for_completer): New functions.
9790 * completer.h (set_gdb_completion_word_break_characters): Delete
9791 declaration.
9792 (completer_handle_brkchars_func_for_completer): New declaration.
9793 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
9794 completer_handle_brkchars_func_for_completer.
9795
9796 2017-07-17 Pedro Alves <palves@redhat.com>
9797
9798 * completer.c (symbol_completer): New function, based on
9799 make_symbol_completion_list_fn.
9800 * completer.h (symbol_completer): New declaration.
9801 * guile/scm-cmd.c (cmdscm_completers): Adjust.
9802 * python/py-cmd.c (completers): Adjust.
9803 * symtab.c (make_symbol_completion_list_fn): Delete.
9804 * symtab.h (make_symbol_completion_list_fn): Delete.
9805 * cli/cli-decode.c (add_cmd): Adjust.
9806
9807 2017-07-17 Pedro Alves <palves@redhat.com>
9808
9809 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
9810 * dwarf2read.c: Include "filename-seen-cache.h".
9811 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
9812 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
9813 * filename-seen-cache.c: New file.
9814 * filename-seen-cache.h: New file.
9815 * symtab.c: Include "filename-seen-cache.h".
9816 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
9817 (create_filename_seen_cache, clear_filename_seen_cache)
9818 (delete_filename_seen_cache, filename_seen): Delete, parts moved
9819 to filename-seen-cache.h/filename-seen-cache.c.
9820 (output_source_filename, sources_info)
9821 (maybe_add_partial_symtab_filename)
9822 (make_source_files_completion_list): Adjust to use
9823 filename_seen_cache.
9824
9825 2017-07-17 Pedro Alves <palves@redhat.com>
9826
9827 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
9828 fields.
9829 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
9830 dwarf2_debug_sections*)): New.
9831 (dwarf2_per_objfile::dwarf2_per_objfile(const
9832 dwarf2_per_objfile&)): Declare as deleted.
9833 (dwarf2_per_objfile::operator=): Declare as deleted.
9834 (dwarf2_per_objfile::dwarf2_per_objfile)
9835 (dwarf2_per_objfile::~dwarf2_per_objfile)
9836 (dwarf2_per_objfile::free_cached_comp_units): New.
9837 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
9838 ctor. Call dwarf2_per_objfile's ctor manually.
9839 (dwarf2_locate_sections): Deleted/refactored as ...
9840 (dwarf2_per_objfile::locate_sections): ... this new method.
9841 (free_cached_comp_units): Defer to
9842 dwarf2_per_objfile::free_cached_comp_units.
9843 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
9844
9845 2017-07-14 Tom Tromey <tom@tromey.com>
9846
9847 PR rust/21764:
9848 * rust-exp.y (convert_ast_to_expression): Add "want_type"
9849 parameter.
9850 <UNOP_SIZEOF>: Split into separate case.
9851 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
9852
9853 2017-07-14 Tom Tromey <tom@tromey.com>
9854
9855 PR rust/21763:
9856 * symtab.c (symbol_matches_domain): Add language_rust to special
9857 case.
9858 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
9859 treat LOC_TYPEDEF symbols as variables.
9860
9861 2017-07-14 Pedro Alves <palves@redhat.com>
9862
9863 * symtab.c (make_file_symbol_completion_list_1): Iterate over
9864 symtabs matching all symtabs with SRCFILE as file name instead of
9865 only considering the first hit, with lookup_symtab.
9866
9867 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
9868
9869 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
9870 operator_name parameters.
9871 (gen_expr): Update function call.
9872
9873 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
9874
9875 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
9876 parameter.
9877 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
9878 Likewise.
9879 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
9880 parameter, use agent_expr::gdbarch instead, update function
9881 calls.
9882 (locexpr_tracepoint_var_ref): Likewise.
9883 (loclist_tracepoint_var_ref): Likewise.
9884 * ax-gdb.c (gen_trace_static_fields): Likewise.
9885 (gen_traced_pop): Likewise.
9886 (gen_frame_args_address): Likewise.
9887 (gen_frame_locals_address): Likewise.
9888 (gen_var_ref): Likewise.
9889 (gen_struct_ref_recursive): Likewise.
9890 (gen_static_field): Likewise.
9891 (gen_maybe_namespace_elt): Likewise.
9892 (gen_expr): Likewise.
9893 (gen_trace_for_var): Likewise.
9894 (gen_trace_for_expr): Likewise.
9895 (gen_trace_for_return_address): Likewise.
9896
9897 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
9898
9899 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
9900 parameter.
9901 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
9902
9903 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
9904
9905 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
9906 from ax, update calls.
9907 (gen_usual_arithmetic): Likewise.
9908 (gen_integral_promotions): Likewise.
9909 (gen_bitfield_ref): Likewise.
9910 (gen_primitive_field): Likewise.
9911 (gen_struct_ref_recursive): Likewise.
9912 (gen_struct_ref): Likewise.
9913 (gen_maybe_namespace_elt): Likewise.
9914 (gen_struct_elt_for_reference): Likewise.
9915 (gen_namespace_elt): Likewise.
9916 (gen_aggregate_elt_ref): Likewise.
9917 (gen_expr): Get gdbarch from ax, update calls.
9918 (gen_expr_binop_rest): Likewise.
9919
9920 2017-07-13 Pedro Alves <palves@redhat.com>
9921
9922 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
9923 as default tdesc.
9924 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
9925 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
9926 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
9927 tdesc_amd64_linux as default tdesc. Get final tdesc from the
9928 tdep.
9929 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
9930 Get final tdesc from the tdep.
9931 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
9932 default tdesc.
9933 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
9934 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
9935 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
9936 Use it as default tdesc.
9937 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
9938 down to amd_init_abi. No longer handle fallback tdesc here.
9939 * amd64-tdep.h (tdesc_x32): Declare.
9940 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
9941 parameter.
9942 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
9943 as default tdesc.
9944
9945 2017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9946
9947 * s390-linux-tdep.c (s390_process_record): Add support for
9948 instructions new in arch12.
9949
9950 2017-07-11 John Baldwin <jhb@FreeBSD.org>
9951
9952 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
9953 PT_GETFSBASE and PT_GETGSBASE.
9954 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
9955 PT_SETGSBASE.
9956
9957 2017-07-11 John Baldwin <jhb@FreeBSD.org>
9958
9959 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
9960 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
9961 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
9962 those rules.
9963 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
9964 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
9965 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
9966 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
9967 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
9968 * features/i386/amd64.xml: Add 64bit-segments.xml.
9969 * features/i386/amd64-avx-avx512.c: Regenerated.
9970 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
9971 * features/i386/amd64-avx-mpx.c: Regenerated.
9972 * features/i386/amd64-avx.c: Regenerated.
9973 * features/i386/amd64-mpx.c: Regenerated.
9974 * features/i386/amd64.c: Regenerated.
9975 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
9976 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
9977 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
9978 * regformats/i386/amd64-avx.dat: Regenerated.
9979 * regformats/i386/amd64-mpx.dat: Regenerated.
9980 * regformats/i386/amd64.dat: Regenerated.
9981
9982 2017-07-10 Yao Qi <yao.qi@linaro.org>
9983
9984 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
9985 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
9986
9987 2017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
9988
9989 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
9990 unsetenv.
9991 * gnulib/aclocal.m4: Regenerate.
9992 * gnulib/config.in: Regenerate.
9993 * gnulib/configure: Regenerate.
9994 * gnulib/import/Makefile.am: Regenerate.
9995 * gnulib/import/Makefile.in: Regenerate.
9996 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
9997 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
9998 * gnulib/import/m4/environ.m4: New file.
9999 * gnulib/import/m4/setenv.m4: New file.
10000 * gnulib/import/setenv.c: New file.
10001 * gnulib/import/unsetenv.c: New file.
10002
10003 2017-07-09 Simon Marchi <simon.marchi@ericsson.com>
10004
10005 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
10006 address when op is DW_OP_addr.
10007
10008 2017-07-09 Tom Tromey <tom@tromey.com>
10009
10010 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
10011 check and apply to outer type.
10012
10013 2017-07-07 John Baldwin <jhb@FreeBSD.org>
10014
10015 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
10016 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
10017 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
10018 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
10019
10020 2017-07-07 John Baldwin <jhb@FreeBSD.org>
10021
10022 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
10023
10024 2017-07-07 John Baldwin <jhb@FreeBSD.org>
10025
10026 * corelow.c (get_core_siginfo): Remove.
10027 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
10028 instead of get_core_siginfo.
10029 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
10030 * gdbarch.h: Re-generate.
10031 * gdbarch.c: Re-generate.
10032 * linux-tdep.c (linux_core_xfer_siginfo): New.
10033 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
10034
10035 2017-07-07 John Baldwin <jhb@FreeBSD.org>
10036
10037 * corelow.c (thread_section_name): Move to ...
10038 * gdbcore.h (thread_section_name): ... here.
10039
10040 2017-07-07 John Baldwin <jhb@FreeBSD.org>
10041
10042 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
10043 (struct siginfo32): New.
10044 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
10045 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
10046 via ptrace(PT_LWPINFO).
10047
10048 2017-07-07 John Baldwin <jhb@FreeBSD.org>
10049
10050 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
10051 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
10052 (fbsd_get_siginfo_type): New.
10053 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
10054 (_initialize_fbsd_tdep): New.
10055
10056 2017-07-06 David Blaikie <dblaikie@gmail.com>
10057
10058 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
10059 a singular dwo_unit*) to support multiple CUs in the same way that
10060 multiple TUs are supported.
10061 (create_cus_hash_table): Replace create_dwo_cu with a function for
10062 parsing multiple CUs from a DWO file.
10063 (open_and_init_dwo_file): Use create_cus_hash_table rather than
10064 create_dwo_cu.
10065 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
10066 htab_find, rather than comparing the signature to a singleton CU in
10067 the dwo_file.
10068
10069 2017-07-06 Pedro Alves <palves@redhat.com>
10070
10071 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
10072
10073 2017-07-04 Pedro Alves <palves@redhat.com>
10074
10075 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
10076 * gdbtypes.h (TYPE_STATIC): Delete.
10077 (struct fn_field) <is_public, is_abstract, is_static, is_final,
10078 is_synchronized, is_native>: Delete.
10079 <dummy>: Bump.
10080 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
10081 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
10082 (TYPE_FN_FIELD_ABSTRACT): Delete.
10083
10084 2017-07-03 Simon Marchi <simon.marchi@ericsson.com>
10085
10086 * buffer.h (buffer_finish): Fix spelling mistakes.
10087
10088 2017-07-01 Eli Zaretskii <eliz@gnu.org>
10089
10090 * .dir-locals.el: Automatically switch to C-style comments in
10091 versions of Emacs that support the feature.
10092
10093 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
10094 Pedro Alves <palves@redhat.com>
10095
10096 PR cli/21688
10097 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
10098 (process_next_line): New variable 'inline_cmd'.
10099 Adjust 'if' clauses for "python", "compile" and "guile" to use
10100 'command_name_equals' and check for '!inline_cmd'.
10101
10102 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
10103
10104 PR cli/21688
10105 * cli/cli-script.c (command_name_equals_not_inline): New function.
10106 (process_next_line): Adjust 'if' clauses for "python", "compile"
10107 and "guile" to use command_name_equals_not_inline.
10108
10109 2017-06-29 Pedro Alves <palves@redhat.com>
10110
10111 * completer.c (expression_completer): Call
10112 linespec_location_completer instead of location_completer.
10113
10114 2017-06-29 Pedro Alves <palves@redhat.com>
10115
10116 * completer.c (expression_completer): Remove code that recomputes
10117 'text' from 'word'.
10118
10119 2017-06-29 Yao Qi <yao.qi@linaro.org>
10120
10121 * regformats/regdat.sh: Generate code with
10122 "ifndef IN_PROCESS_AGENT".
10123
10124 2017-06-28 Pedro Alves <palves@redhat.com>
10125
10126 * command.h: Include "common/scoped_restore.h".
10127
10128 2017-06-28 Yao Qi <yao.qi@linaro.org>
10129
10130 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
10131 instead of obstack_grow.
10132
10133 2017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
10134
10135 PR gdb/21337
10136 * symfile.c (reread_symbols): Call objfiles_changed just before
10137 read_symbols.
10138
10139 2017-06-27 Pedro Alves <palves@redhat.com>
10140
10141 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
10142 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
10143 (completion_list_add_symbol, completion_list_add_msymbol):
10144 ... these new functions.
10145 (add_symtab_completions)
10146 (default_make_symbol_completion_list_break_on_1): Adjust.
10147
10148 2017-06-27 Pedro Alves <palves@redhat.com>
10149
10150 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
10151 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
10152 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
10153 dtor.
10154 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
10155 'storage_obstack' field an auto_obstack. In-class initialize all
10156 non-bitfield fields. Make minsyms_read bool.
10157 * symfile.c (read_symbols): Adjust.
10158
10159 2017-06-27 Alan Hayward <alan.hayward@arm.com>
10160
10161 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
10162 (gdbsim_store_register): Likewise.
10163
10164 2017-06-27 Pedro Alves <palves@redhat.com>
10165
10166 * c-exp.y (name_obstack): Now an auto_obstack.
10167 (yylex): Use auto_obstack::clear.
10168 (c_parse): Use auto_obstack::clear instead of reinitializing and
10169 freeing the obstack.
10170 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
10171 * d-exp.y (name_obstack): Now an auto_obstack.
10172 (yylex): Use auto_obstack::clear.
10173 (d_parse): Use auto_obstack::clear instead of reinitializing and
10174 freeing the obstack.
10175 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
10176 auto_obstack.
10177 * dwarf2read.c (create_addrmap_from_index)
10178 (dwarf2_build_psymtabs_hard)
10179 (update_enumeration_type_from_children): Likewise.
10180 * gdb_obstack.h (auto_obstack): New type.
10181 * go-exp.y (name_obstack): Now an auto_obstack.
10182 (build_packaged_name): Use auto_obstack::clear.
10183 (go_parse): Use auto_obstack::clear instead of reinitializing and
10184 freeing the obstack.
10185 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
10186 auto_obstack.
10187 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
10188 * rust-exp.y (work_obstack): Now an auto_obstack.
10189 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
10190 reinitializing and freeing the obstack.
10191 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
10192 (host_char_to_target): Use auto_obstack.
10193 * utils.h (make_cleanup_obstack_free): Delete declaration.
10194 * valprint.c (generic_emit_char, generic_printstr): Use
10195 auto_obstack.
10196
10197 2017-06-27 Simon Marchi <simon.marchi@ericsson.com>
10198
10199 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
10200 thread.
10201 (darwin_init_thread_list): Don't update dummy thread.
10202 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
10203
10204 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
10205
10206 * record-full.c (netorder16): Remove.
10207
10208 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
10209
10210 * common/diagnostics.h: Define macros for GCC.
10211 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
10212 * common/vec.h: Include diagnostics.h.
10213 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
10214 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
10215 warning.
10216
10217 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
10218
10219 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
10220 New macro.
10221 * ada-lex.l: Ignore deprecated register warnings.
10222
10223 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
10224
10225 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
10226 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
10227
10228 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
10229
10230 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
10231 its own line.
10232
10233 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
10234
10235 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
10236
10237 2017-06-23 Alan Hayward <alan.hayward@arm.com>
10238
10239 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
10240 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
10241 (xtensa_register_read_masked): Likewise.
10242
10243 2017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
10244
10245 * common/environ.c (gdb_environ::unset): Update comment.
10246
10247 2017-06-22 Alan Hayward <alan.hayward@arm.com>
10248
10249 * python/py-unwind.c (pyuw_sniffer): Allocate space for
10250 registers.
10251
10252 2017-06-22 Alan Hayward <alan.hayward@arm.com>
10253
10254 * record-full.c (record_full_exec_insn): Use byte_vector.
10255
10256 2017-06-22 Yao Qi <yao.qi@linaro.org>
10257
10258 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
10259 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
10260
10261 2017-06-22 Alan Hayward <alan.hayward@arm.com>
10262
10263 * remote.c (cached_reg): Move from here...
10264 * regcache.h (cached_reg): ...to here.
10265 * python/py-unwind.c (struct reg_info): Remove.
10266 (cached_frame_info): Use cached_reg_t.
10267 (pyuw_prev_register): Likewise.
10268 (pyuw_sniffer): Use cached_reg_t and allocate registers.
10269 (pyuw_dealloc_cache): Free all registers.
10270
10271 2017-06-22 Pedro Alves <palves@redhat.com>
10272 Simon Marchi <simon.marchi@ericsson.com>
10273
10274 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
10275 warning.
10276 * common/diagnostics.h: New file.
10277
10278 2017-06-22 Pedro Alves <palves@redhat.com>
10279
10280 * common/agent.h: Add include guards.
10281
10282 2017-06-21 Simon Marchi <simon.marchi@ericsson.com>
10283
10284 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
10285 talk about addressable units instead of bytes.
10286
10287 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
10288
10289 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
10290 of '::const_iterator'.
10291
10292 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
10293
10294 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10295 'unittests/environ-selftests.c'.
10296 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
10297 * charset.c (find_charset_names): Declare object 'iconv_env'.
10298 Update code to use 'iconv_env' object. Remove call to
10299 'free_environ'.
10300 * common/environ.c: Include <utility>.
10301 (make_environ): Delete function.
10302 (free_environ): Delete function.
10303 (gdb_environ::clear): New function.
10304 (gdb_environ::operator=): New function.
10305 (gdb_environ::get): Likewise.
10306 (environ_vector): Delete function.
10307 (set_in_environ): Delete function.
10308 (gdb_environ::set): New function.
10309 (unset_in_environ): Delete function.
10310 (gdb_environ::unset): New function.
10311 (gdb_environ::envp): Likewise.
10312 * common/environ.h: Include <vector>.
10313 (struct gdb_environ): Delete; transform into...
10314 (class gdb_environ): ... this class.
10315 (free_environ): Delete prototype.
10316 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
10317 environ_vector): Likewise.
10318 * infcmd.c (run_command_1): Update code to call
10319 'envp' from 'gdb_environ' class.
10320 (environment_info): Update code to call methods from 'gdb_environ'
10321 class.
10322 (unset_environment_command): Likewise.
10323 (path_info): Likewise.
10324 (path_command): Likewise.
10325 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
10326 (inferior::inferior): Initialize 'environment' using the host's
10327 information.
10328 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
10329 Include "environ.h".
10330 (class inferior) <environment>: Change type from 'struct
10331 gdb_environ' to 'gdb_environ'.
10332 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
10333 methods from 'gdb_environ' class.
10334 * solib.c (solib_find_1): Likewise
10335 * unittests/environ-selftests.c: New file.
10336
10337 2017-06-20 Yao Qi <yao.qi@linaro.org>
10338
10339 * features/i386/i386-linux.xml: Exchange the order of including
10340 32bit-linux.xml and 32bit-sse.xml.
10341 * features/i386/i386-linux.c: Regenerated.
10342
10343 2017-06-20 Yao Qi <yao.qi@linaro.org>
10344
10345 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
10346 Delete copy ctor and assignment operator.
10347 (tdesc_type): Likewise.
10348 (tdesc_feature): Likewise.
10349 (tdesc_free_reg): Remove.
10350 (tdesc_create_reg): Use new.
10351 (tdesc_free_type): Remove.
10352 (tdesc_create_vector): Use new.
10353 (tdesc_create_union): Likewise.
10354 (tdesc_create_flags): Likewise.
10355 (tdesc_create_enum): Likewise.
10356 (tdesc_free_feature): Delete.
10357 (free_target_description): Use delete.
10358
10359 2017-06-19 John Baldwin <jhb@FreeBSD.org>
10360
10361 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
10362 registers.
10363
10364 2017-06-19 Pedro Alves <palves@redhat.com>
10365
10366 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
10367 after gdb::unlinker.
10368
10369 2017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
10370
10371 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
10372 gdb_environ to access an environment variable.
10373
10374 2017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
10375
10376 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
10377 gdb_byte*.
10378
10379 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
10380
10381 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
10382
10383 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
10384
10385 * configure: Re-generate.
10386 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
10387
10388 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
10389
10390 * configure: Re-generate.
10391 * warning.m4: Pass -Werror to compiler when checking for
10392 supported warning flags.
10393
10394 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
10395
10396 * Makefile.in (COMPILE.pre): Add "-x c++".
10397
10398 2017-06-16 Alan Hayward <alan.hayward@arm.com>
10399 Pedro Alves <palves@redhat.com>
10400 Yao Qi <yao.qi@linaro.org>
10401
10402 * defs.h (RequireLongest): New.
10403 (extract_integer): Declare function template.
10404 (extract_signed_integer): Remove the declaration, but define it
10405 static inline.
10406 (extract_unsigned_integer): Likewise.
10407 (store_integer): Declare function template.
10408 (store_signed_integer): Remove the declaration, but define it
10409 static inline.
10410 (store_unsigned_integer): Likewise.
10411 * findvar.c (extract_integer): New function template.
10412 (extract_signed_integer): Remove.
10413 (extract_unsigned_integer): Remove.
10414 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
10415 instantiations.
10416 (store_integer): New function template.
10417 (store_signed_integer): Remove.
10418 (store_unsigned_integer): Remove.
10419 (store_integer): Explicit instantiations.
10420 * regcache.c (regcache_raw_read_signed): Update.
10421 (regcache::raw_read): New function.
10422 (regcache::raw_read_signed): Remove.
10423 (regcache::raw_read_unsigned): Remove.
10424 (regcache_raw_read_unsigned): Update.
10425 (regcache_raw_write_unsigned): Update.
10426 (regcache::raw_write_signed): Remove.
10427 (regcache::raw_write): New function.
10428 (regcache_cooked_read_signed): Update.
10429 (regcache::raw_write_unsigned): Remove.
10430 (regcache::cooked_read_signed): Remove.
10431 (regcache_cooked_read_unsigned): Update.
10432 (regcache::cooked_read_unsigned): Remove.
10433 (regcache_cooked_write_signed): Update.
10434 (regcache_cooked_write_unsigned): Update.
10435 * regcache.h (regcache) <raw_read_signed>: Remove.
10436 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
10437 <raw_read, raw_write>: New.
10438 <cooked_read_signed, cooked_write_signed>: Remove.
10439 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
10440 <cooked_read, cooked_write>: New.
10441 * sh64-tdep.c (sh64_pseudo_register_read): Update.
10442 (sh64_pseudo_register_write): Update.
10443
10444 2017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
10445
10446 * arc-tdep.c (arc_disassembler_options): New variable.
10447 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
10448 of default_print_insn.
10449 (arc_delayed_print_insn): Set info->section when needed,
10450 use default_print_insn to retrieve a disassembler.
10451
10452 2017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
10453
10454 PR gdb/21574
10455 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
10456 to mention $SHELL and startup-with-shell.
10457
10458 2017-06-14 Max Filippov <jcmvbkbc@gmail.com>
10459
10460 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
10461
10462 2017-06-14 Yao Qi <yao.qi@linaro.org>
10463
10464 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
10465 default_print_insn instead of print_insn_aarch64.
10466 * arm-tdep.c (gdb_print_insn_arm): Call
10467 default_print_insn instead of print_insn_big_arm
10468 and print_insn_little_arm.
10469 * i386-tdep.c (i386_print_insn): Call default_print_insn
10470 instead of print_insn_i386.
10471 * ia64-tdep.c (ia64_print_insn): Call
10472 default_print_insn instead of print_insn_ia64.
10473 * mips-tdep.c (gdb_print_insn_mips): Call
10474 default_print_insn instead of print_insn_big_mips
10475 and print_insn_little_mips.
10476 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
10477 instead of print_insn_spu.
10478
10479 2017-06-14 Pedro Alves <palves@redhat.com>
10480
10481 * ada-lang.c: Include "common/byte-vector.h".
10482 (ada_value_primitive_packed_val): Use gdb::byte_vector.
10483 * charset.c (wchar_iterator::iterate): Resize the vector instead
10484 of reserving it.
10485 * common/byte-vector.h: Include "common/def-vector.h".
10486 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
10487 * cli/cli-dump.c: Include "common/byte-vector.h".
10488 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
10489 * common/byte-vector.h: New file.
10490 * common/def-vector.h: New file.
10491 * common/default-init-alloc.h: New file.
10492 * dwarf2loc.c: Include "common/byte-vector.h".
10493 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
10494 instead of reserving it.
10495 * dwarf2read.c: Include "common/byte-vector.h".
10496 (data_buf::m_vec): Now a gdb::byte_vector.
10497 * gdb_regex.c: Include "common/def-vector.h".
10498 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
10499 * mi/mi-main.c: Include "common/byte-vector.h".
10500 (mi_cmd_data_read_memory): Use gdb::byte_vector.
10501 * printcmd.c: Include "common/byte-vector.h".
10502 (print_scalar_formatted): Use gdb::byte_vector.
10503 * valprint.c: Include "common/byte-vector.h".
10504 (maybe_negate_by_bytes, print_decimal_chars): Use
10505 gdb::byte_vector.
10506
10507 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
10508
10509 * darwin-nat.c: Include "nat/fork-inferior.h".
10510
10511 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
10512
10513 * configure.nat: Factor out Darwin bits that are not
10514 architecture-specific. Add fork-inferior.o.
10515
10516 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
10517
10518 * configure.nat: Factor out AIX bits that are not
10519 architecture-specific. Add fork-inferior.o.
10520
10521 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10522
10523 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
10524 (read_pieced_value, write_pieced_value): ...here. Reduce to
10525 wrappers that just call rw_pieced_value.
10526
10527 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10528
10529 * dwarf2loc.c (write_pieced_value): When writing the data for a
10530 memory piece, use write_memory_with_notification instead of
10531 write_memory.
10532
10533 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10534
10535 * valops.c (read_value_memory): Change embedded_offset to
10536 represent a bit offset instead of a byte offset.
10537 * value.h (read_value_memory): Adjust comment.
10538
10539 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10540
10541 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
10542 dest_offset_bits and source_offset_bits.
10543 (write_pieced_value): Likewise.
10544
10545 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10546
10547 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
10548 given by DW_OP_bit_piece.
10549 (write_pieced_value): Likewise.
10550
10551 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10552
10553 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
10554 some other preparations to the places where sufficient information
10555 is available.
10556 (write_pieced_value): Likewise.
10557
10558 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10559
10560 * dwarf2loc.c (bits_to_bytes): New function.
10561 (read_pieced_value): Fix offset calculations for register pieces
10562 on big-endian targets.
10563 (write_pieced_value): Likewise.
10564
10565 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10566
10567 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
10568 (write_pieced_value): Likewise.
10569
10570 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10571
10572 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
10573 transfer the source value's least significant bits, instead of its
10574 lowest-addressed ones. Rename type_len to max_offset.
10575 (read_pieced_value): Mirror above changes to write_pieced_value as
10576 applicable.
10577
10578 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10579
10580 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
10581 truncate full bytes from dest_offset_bits before using it as an
10582 offset into the buffer.
10583
10584 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10585
10586 * dwarf2loc.c (write_pieced_value): Include transfer size in
10587 byte-wise check.
10588
10589 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10590
10591 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
10592 calculation of this_size.
10593
10594 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10595
10596 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
10597 when targeting a bit-field.
10598 (write_pieced_value): Likewise.
10599
10600 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10601
10602 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
10603 (allocate_piece_closure): Drop addr_size parameter.
10604 (dwarf2_evaluate_loc_desc_full): Adjust call to
10605 allocate_piece_closure.
10606
10607 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10608
10609 PR gdb/21226
10610 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
10611 the LSB end, independent of endianness.
10612
10613 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10614
10615 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
10616 size capping.
10617
10618 2017-06-13 Yao Qi <yao.qi@linaro.org>
10619
10620 * mips-linux-nat.c: Move include features/mips*-linux.c to
10621 mips-linux-tdep.c.
10622 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
10623 to mips-linux-tdep.c.
10624 * mips-linux-tdep.c: Include features/mips*-linux.c
10625 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
10626 functions.
10627 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
10628 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
10629 (tdesc_mips64_dsp_linux): Declare.
10630
10631 2017-06-12 Tom Tromey <tom@tromey.com>
10632
10633 * valprint.h (val_print_type_code_int): Remove.
10634 * valprint.c (generic_val_print_int): Always call
10635 val_print_scalar_formatted.
10636 (val_print_type_code_int): Remove.
10637 * printcmd.c (print_scalar_formatted): Handle options->format==0.
10638 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
10639 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
10640 * ada-valprint.c (ada_val_print_num): Use
10641 val_print_scalar_formatted.
10642
10643 2017-06-12 Tom Tromey <tom@tromey.com>
10644
10645 * printcmd.c (print_scalar_formatted): Unify the two switches.
10646 Don't convert scalars to LONGEST.
10647
10648 2017-06-12 Tom Tromey <tom@tromey.com>
10649
10650 PR exp/16225:
10651 * valprint.h (print_decimal_chars): Update.
10652 * valprint.c (maybe_negate_by_bytes): New function.
10653 (print_decimal_chars): Add "is_signed" argument.
10654 * printcmd.c (print_scalar_formatted): Update.
10655
10656 2017-06-12 Tom Tromey <tom@tromey.com>
10657
10658 PR exp/16225:
10659 * valprint.h (print_binary_chars, print_hex_chars): Update.
10660 * valprint.c (val_print_type_code_int): Update.
10661 (print_binary_chars): Add "zero_pad" argument.
10662 (emit_octal_digit): New function.
10663 (print_octal_chars): Don't zero-pad.
10664 (print_decimal_chars): Likewise.
10665 (print_hex_chars): Add "zero_pad" argument.
10666 * sh64-tdep.c (sh64_do_fp_register): Update.
10667 * regcache.c (regcache::dump): Update.
10668 * printcmd.c (print_scalar_formatted): Update.
10669 * infcmd.c (default_print_one_register_info): Update.
10670
10671 2017-06-12 Pedro Alves <palves@redhat.com>
10672 Alan Hayward <alan.hayward@arm.com>
10673
10674 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
10675 (mips_eabi_push_dummy_call): Rename local 'regsize' to
10676 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
10677 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
10678 Assert that abi_regsize bytes fit in 'ref_valbuf'.
10679
10680 2017-06-12 Pedro Alves <palves@redhat.com>
10681
10682 * dwarf2read.c (mapped_symtab::data): Now a vector of
10683 symtab_index_entry instead of vector of
10684 std::unique_ptr<symtab_index_entry>. All users adjusted to check
10685 whether an element's name is NULL instead of checking whether the
10686 element itself is NULL.
10687 (find_slot): Change return type. Adjust.
10688 (hash_expand, , add_index_entry, uniquify_cu_indices)
10689 (write_hash_table): Adjust.
10690
10691 2017-06-12 Pedro Alves <palves@redhat.com>
10692
10693 * dwarf2read.c (recursively_count_psymbols): New function.
10694 (write_psymtabs_to_index): Call it to compute number of psyms and
10695 pass estimate size of psyms_seen to unordered_set's ctor.
10696
10697 2017-06-12 Pedro Alves <palves@redhat.com>
10698
10699 * dwarf2read.c (write_hash_table): Check if key already exists
10700 before emplacing.
10701
10702 2017-06-12 Pedro Alves <palves@redhat.com>
10703
10704 * dwarf2read.c (data_buf::append_space): Rename to...
10705 (data_buf::grow): ... this, and make private. Adjust all callers.
10706 (data_buf::append_uint): New method.
10707 (add_address_entry, write_one_signatured_type)
10708 (write_psymtabs_to_index): Use it.
10709
10710 2017-06-12 Pedro Alves <palves@redhat.com>
10711
10712 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
10713 (file_write (FILE *, const std::vector<Elem>&)): Delete.
10714 (data_buf::file_write): Call ::fwrite directly.
10715
10716 2017-06-12 Pedro Alves <palves@redhat.com>
10717
10718 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
10719 std::vector::erase.
10720
10721 2017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
10722
10723 Code cleanup: C++ify .gdb_index producer.
10724 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
10725 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
10726 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
10727 (create_strtab, add_string): Remove.
10728 (file_write, data_buf): New.
10729 (struct symtab_index_entry): Use std::vector for cu_indices.
10730 (struct mapped_symtab): Use std::vector for data.
10731 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
10732 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
10733 Remove.
10734 (find_slot): Change return type. Update it to the new data structures.
10735 (hash_expand, add_index_entry): Update it to the new data structures.
10736 (offset_type_compare): Remove.
10737 (uniquify_cu_indices): Update it to the new data structures.
10738 (c_str_view, c_str_view_hasher, vector_hasher): New.
10739 (add_indices_to_cpool): Remove.
10740 (write_hash_table): Update it to the new data structures.
10741 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
10742 (eq_psymtab_cu_index): Remove.
10743 (psym_index_map): New typedef.
10744 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
10745 reference and std::unordered_map for cu_index_htab.
10746 (add_address_entry, add_address_entry_worker, write_address_map)
10747 (write_psymbols): Update it to the new data structures.
10748 (write_obstack): Remove.
10749 (struct signatured_type_index_data): Change types_list to a data_buf
10750 reference and psyms_seen to a std::unordered_set reference.
10751 (write_one_signatured_type, recursively_write_psymbols)
10752 (write_psymtabs_to_index): Update it to the new data structures.
10753
10754 2017-06-11 Simon Marchi <simon.marchi@ericsson.com>
10755
10756 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
10757 separate-debug-file commands.
10758 * symfile.h (separate_debug_file_debug): New global.
10759 * symfile.c (separate_debug_file_debug): New global.
10760 (separate_debug_file_exists, find_separate_debug_file): Add
10761 debug output.
10762 (_initialize_symfile): Add "set debug separate-debug-file"
10763 command.
10764 * build-id.c (build_id_to_debug_bfd,
10765 find_separate_debug_file_by_buildid): Add debug output.
10766
10767 2017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
10768
10769 * gdbarch.sh (displaced_step_free_closure): Remove.
10770 * gdbarch.h, gdbarch.c: Re-generate.
10771 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
10772 displaced_step_free_closure.
10773 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
10774 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
10775 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
10776 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
10777 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
10778 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
10779 * arch-utils.h (simple_displaced_step_free_closure): Remove.
10780 * arch-utils.c (simple_displaced_step_free_closure): Remove.
10781 * infrun.c (displaced_step_clear): Call xfree instead of
10782 gdbarch_displaced_step_free_closure.
10783
10784 2017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
10785
10786 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
10787 NULL".
10788
10789 2017-06-08 Alan Hayward <alan.hayward@arm.com>
10790
10791 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
10792 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
10793 (mn10300_push_dummy_call): Likewise.
10794
10795 2017-06-08 Alan Hayward <alan.hayward@arm.com>
10796
10797 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
10798
10799 2017-06-08 Alan Hayward <alan.hayward@arm.com>
10800
10801 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
10802
10803 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
10804
10805 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
10806 able to start inferiors using a shell.
10807 (New remote packets): Announce new packet "QStartupWithShell".
10808 * remote.c: Add PACKET_QStartupWithShell.
10809 (extended_remote_create_inferior): Handle new
10810 PACKET_QStartupWithShell.
10811 (remote_protocol_features) <QStartupWithShell>: New entry for
10812 PACKET_QStartupWithShell.
10813 (_initialize_remote): Call "add_packet_config_cmd" for
10814 QStartupShell.
10815
10816 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
10817 Pedro Alves <palves@redhat.com>
10818
10819 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
10820 and "nat/fork-inferior.h".
10821 * common/common-inferior.h: New file, with contents from
10822 "gdb/inferior.h".
10823 * commom/common-utils.c: Include "common-utils.h".
10824 (stringify_argv): New function.
10825 * common/common-utils.h (stringify_argv): New prototype.
10826 * configure.nat: Add "fork-inferior.o" as a dependency for
10827 "*linux*", "fbsd*" and "nbsd*" hosts.
10828 * corefile.c (get_exec_file): Update comment.
10829 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
10830 instead of "startup_inferior".
10831 (darwin_create_inferior): Call "add_thread_silent" after
10832 "fork_inferior".
10833 * fork-child.c: Cleanup unnecessary includes.
10834 (SHELL_FILE): Move to "common/common-fork-child.c".
10835 (environ): Likewise.
10836 (exec_wrapper): Initialize.
10837 (get_exec_wrapper): New function.
10838 (breakup_args): Move to "common/common-fork-child.c"; rename to
10839 "breakup_args_for_exec".
10840 (escape_bang_in_quoted_argument): Move to
10841 "common/common-fork-child.c".
10842 (saved_ui): New variable.
10843 (prefork_hook): New function.
10844 (postfork_hook): Likewise.
10845 (postfork_child_hook): Likewise.
10846 (gdb_startup_inferior): Likewise.
10847 (fork_inferior): Move to "common/common-fork-child.c". Update
10848 function to support gdbserver.
10849 (startup_inferior): Likewise.
10850 * gdbcore.h (get_exec_file): Remove declaration.
10851 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
10852 instead of "startup_inferior". Call "add_thread_silent" after
10853 "fork_inferior".
10854 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
10855 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
10856 instead of "startup_inferior". Call "add_thread_silent" after
10857 "fork_inferior".
10858 * inferior.h: Include "common-inferior.h".
10859 (trace_start_error): Move to "common/common-utils.h".
10860 (trace_start_error_with_name): Likewise.
10861 (fork_inferior): Move prototype to "nat/fork-inferior.h".
10862 (startup_inferior): Likewise.
10863 (gdb_startup_inferior): New prototype.
10864 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
10865 * nat/fork-inferior.h: New file.
10866 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
10867 instead of "startup_inferior". Call "add_thread_silent" after
10868 "fork_inferior".
10869 * target.h (target_terminal_init): Move prototype to
10870 "target/target.h".
10871 (target_terminal_inferior): Likewise.
10872 (target_terminal_ours): Likewise.
10873 * target/target.h (target_terminal_init): New prototype, moved
10874 from "target.h".
10875 (target_terminal_inferior): Likewise.
10876 (target_terminal_ours): Likewise.
10877 * utils.c (gdb_flush_out_err): New function.
10878
10879 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
10880
10881 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
10882 * common/common-gdbthread.h: New file, with parts from
10883 "gdb/gdbthread.h".
10884 * gdbthread.h: Include "common-gdbthread.h".
10885 (switch_to_thread): Moved to "common/common-gdbthread.h".
10886
10887 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
10888
10889 * Makefile.in (SFILES): Add "common/job-control.c".
10890 (HFILES_NO_SRCDIR): Add "common/job-control.h".
10891 (COMMON_OBS): Add "job-control.o".
10892 * common/job-control.c: New file, with contents from
10893 "gdb/inflow.c".
10894 * common/job-control.h: New file, with contents from "terminal.h".
10895 * fork-child.c: Include "job-control.h".
10896 * inflow.c: Include "job-control.h".
10897 (gdb_setpgid): Move to "common/common-inflow.c".
10898 (_initialize_inflow): Move setting of "job_control" to
10899 "handle_job_control".
10900 * terminal.h (job_control): Moved to "common/common-terminal.h".
10901 (gdb_setpgid): Likewise.
10902 * top.c: Include "job_control.h".
10903 * utils.c: Likewise.
10904 (job_control): Moved to "job-control.c".
10905
10906 2017-06-07 Pedro Alves <palves@redhat.com>
10907
10908 * Makefile.in (SFILES): Add gdb_regex.c.
10909 (COMMON_OBS): Add gdb_regex.o.
10910 * ada-lang.c (ada_add_standard_exceptions)
10911 (ada_add_exceptions_from_frame, name_matches_regex)
10912 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
10913 parameter type to compiled_regex. Adjust.
10914 (ada_exceptions_list): Use compiled_regex.
10915 * break-catch-throw.c (exception_catchpoint::pattern): Now a
10916 std::unique_ptr<compiled_regex>.
10917 (exception_catchpoint::~exception_catchpoint): Remove regfree
10918 call.
10919 (check_status_exception_catchpoint): Adjust to use compiled_regex.
10920 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
10921 * breakpoint.c (solib_catchpoint::compiled): Now a
10922 std::unique_ptr<compiled_regex>.
10923 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
10924 (check_status_catch_solib): Adjust to use compiled_regex.
10925 (add_solib_catchpoint): Adjust to use compiled_regex.
10926 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
10927 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
10928 compiled_regex reference. Adjust to use it.
10929 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
10930 declaration. Include "gdb_regex.h".
10931 (apropos_cmd): Change regex parameter to compiled_regex reference.
10932 * gdb_regex.c: New file.
10933 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
10934 declarations.
10935 (class compiled_regex): New.
10936 * linux-tdep.c: Include "common/gdb_optional.h".
10937 (struct mapping_regexes): New, factored out from
10938 mapping_is_anonymous_p, and adjusted to use compiled_regex.
10939 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
10940 gdb::optional and remove cleanups. Adjust to compiled_regex.
10941 * probe.c: Include "common/gdb_optional.h".
10942 (collect_probes): Use compiled_regex and gdb::optional and remove
10943 cleanups.
10944 * skip.c: Include "common/gdb_optional.h".
10945 (skiplist_entry::compiled_function_regexp): Now a
10946 gdb::optional<compiled_regex>.
10947 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
10948 (free_skiplist_entry): Remove regfree call.
10949 (compile_skip_regexp, skip_rfunction_p): Adjust to use
10950 compiled_regex and gdb::optional.
10951 * symtab.c: Include "common/gdb_optional.h".
10952 (search_symbols): Use compiled_regex and gdb::optional.
10953 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
10954 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
10955 to gdb_regex.c.
10956
10957 2017-06-07 Alan Hayward <alan.hayward@arm.com>
10958
10959 * regcache.c (regcache::save): Avoid buffer use.
10960 (regcache::dump): Likewise.
10961
10962 2017-06-07 Alan Hayward <alan.hayward@arm.com>
10963
10964 * sh-tdep.c (sh_pseudo_register_read): Remove
10965 MAX_REGISTER_SIZE.
10966 (sh_pseudo_register_write): Likewise.
10967 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
10968 (sh64_pseudo_register_write): Likewise
10969
10970 2017-06-07 Alan Hayward <alan.hayward@arm.com>
10971
10972 * aarch64-tdep.c (aarch64_store_return_value): Use
10973 V_REGISTER_SIZE.
10974 (aarch64_pseudo_read_value): Likewise.
10975 (aarch64_pseudo_write): Likewise.
10976
10977 2017-06-06 Yao Qi <yao.qi@linaro.org>
10978
10979 * regformats/regdef.h (set_register_cache): Remove the
10980 declaration.
10981
10982 2017-06-06 Alan Hayward <alan.hayward@arm.com>
10983
10984 * frame.c (frame_unwind_register_signed): Use
10985 frame_unwind_register_value.
10986
10987 2017-06-06 Pedro Alves <palves@redhat.com>
10988
10989 PR breakpoints/21553
10990 * breakpoint.c (create_breakpoints_sal_default)
10991 (init_breakpoint_sal, create_breakpoint_sal): Use
10992 gdb::unique_xmalloc_ptr for string parameters.
10993 (create_breakpoint): Constify 'extra_string' and 'cond_string'
10994 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
10995 (base_breakpoint_create_breakpoints_sal)
10996 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
10997 (strace_marker_create_breakpoints_sal)
10998 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
10999 string parameters.
11000 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
11001 gdb::unique_xmalloc_ptr for string parameters.
11002 (create_breakpoint): Constify 'extra_string' and 'cond_string'
11003 parameters.
11004
11005 2017-06-06 Alan Hayward <alan.hayward@arm.com>
11006
11007 * alpha-tdep.c (alpha_register_to_value): Use
11008 get_frame_register_value.
11009 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
11010
11011 2017-06-06 Alan Hayward <alan.hayward@arm.com>
11012
11013 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
11014 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
11015 (ia64_value_to_register): Likewise.
11016 (ia64_extract_return_value): Likewise.
11017 (ia64_store_return_value): Likewise.
11018 (ia64_push_dummy_call): Likewise.
11019
11020 2017-06-04 Joel Brobecker <brobecker@adacore.com>
11021
11022 GDB 8.0 released.
11023
11024 2017-06-03 Simon Marchi <simon.marchi@ericsson.com>
11025
11026 * x86-linux-nat.c (struct arch_lwp_info): Remove.
11027
11028 2017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
11029
11030 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
11031 parameter.
11032 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
11033
11034 2017-06-02 Simon Marchi <simon.marchi@ericsson.com>
11035
11036 * event-loop.c (poll_timers): Unallocate timer using delete
11037 instead of xfree.
11038
11039 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
11040
11041 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
11042 (struct breakpoint) <~breakpoint>: New.
11043 (struct watchpoint): Inherit from breakpoint.
11044 <~watchpoint>: New.
11045 <base>: Remove.
11046 (struct tracepoint): Inherit from breakpoint.
11047 <base>: Remove.
11048 * breakpoint.c (longjmp_breakpoint_ops): Remove.
11049 (struct longjmp_breakpoint): Inherit from breakpoint.
11050 <~longjmp_breakpoint>: New.
11051 <base>: Remove.
11052 (new_breakpoint_from_type): Remove casts.
11053 (watchpoint_in_thread_scope): Remove reference to base field.
11054 (watchpoint_del_at_next_stop): Likewise.
11055 (update_watchpoint): Likewise.
11056 (watchpoint_check): Likewise.
11057 (bpstat_check_watchpoint): Likewise.
11058 (set_longjmp_breakpoint): Likewise.
11059 (struct fork_catchpoint): Inherit from breakpoint.
11060 <base>: Remove.
11061 (struct solib_catchpoint): Inherit from breakpoint.
11062 <~solib_catchpoint>: New.
11063 <base>: Remove.
11064 (dtor_catch_solib): Change to ...
11065 (solib_catchpoint::~solib_catchpoint): ... this.
11066 (breakpoint_hit_catch_solib): Remove reference to base field.
11067 (add_solib_catchpoint): Likewise.
11068 (create_fork_vfork_event_catchpoint): Likewise.
11069 (struct exec_catchpoint): Inherit from breakpoint.
11070 <~exec_catchpoint>: New.
11071 <base>: Remove.
11072 (dtor_catch_exec): Change to ...
11073 (exec_catchpoint::~exec_catchpoint): ... this.
11074 (dtor_watchpoint): Change to ...
11075 (watchpoint::~watchpoint): ... this.
11076 (watch_command_1): Remove reference to base field.
11077 (catch_exec_command_1): Likewise.
11078 (base_breakpoint_dtor): Change to ...
11079 (breakpoint::~breakpoint): ... this.
11080 (base_breakpoint_ops): Remove dtor field value.
11081 (longjmp_bkpt_dtor): Change to ...
11082 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
11083 (strace_marker_create_breakpoints_sal): Remove reference to base
11084 field.
11085 (delete_breakpoint): Don't manually call breakpoint destructor.
11086 (create_tracepoint_from_upload): Remove reference to base field.
11087 (trace_pass_set_count): Likewise.
11088 (initialize_breakpoint_ops): Don't initialize
11089 momentary_breakpoint_ops, don't set dtors.
11090 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
11091 <~ada_catchpoint>: New.
11092 <base>: Remove.
11093 (create_excep_cond_exprs): Remove reference to base field.
11094 (dtor_exception): Change to ...
11095 (ada_catchpoint::~ada_catchpoint): ... this.
11096 (dtor_catch_exception): Remove.
11097 (dtor_catch_exception_unhandled): Remove.
11098 (dtor_catch_assert): Remove.
11099 (create_ada_exception_catchpoint): Remove reference to base
11100 field.
11101 (initialize_ada_catchpoint_ops): Don't set dtors.
11102 * break-catch-sig.c (struct signal_catchpoint): Inherit from
11103 breakpoint.
11104 <~signal_catchpoint>: New.
11105 <base>: Remove.
11106 (signal_catchpoint_dtor): Change to ...
11107 (signal_catchpoint::~signal_catchpoint): ... this.
11108 (create_signal_catchpoint): Remove reference to base field.
11109 (initialize_signal_catchpoint_ops): Don't set dtor.
11110 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
11111 from breakpoint.
11112 <~syscall_catchpoint>: New.
11113 <base>: Remove.
11114 (dtor_catch_syscall): Change to ...
11115 (syscall_catchpoint::~syscall_catchpoint): ... this.
11116 (create_syscall_event_catchpoint): Remove reference to base
11117 field.
11118 (initialize_syscall_catchpoint_ops): Don't set dtor.
11119 * break-catch-throw.c (struct exception_catchpoint): Inherit
11120 from breakpoint.
11121 <~exception_catchpoint>: New.
11122 <base>: Remove.
11123 (dtor_exception_catchpoint): Change to ...
11124 (exception_catchpoint::~exception_catchpoint): ... this.
11125 (handle_gnu_v3_exceptions): Remove reference to base field.
11126 (initialize_throw_catchpoint_ops): Don't set dtor.
11127 * ctf.c (ctf_get_traceframe_address): Remove reference to base
11128 field.
11129 * remote.c (remote_get_tracepoint_status): Likewise.
11130 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
11131 * tracefile.c (tracefile_fetch_registers): Likewise.
11132 * tracepoint.c (actions_command): Likewise.
11133 (validate_actionline): Likewise.
11134 (tfind_1): Likewise.
11135 (get_traceframe_location): Likewise.
11136 (find_matching_tracepoint_location): Likewise.
11137 (parse_tracepoint_status): Likewise.
11138 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
11139
11140 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
11141
11142 * breakpoint.c (struct longjmp_breakpoint): New struct.
11143 (is_tracepoint_type): Change return type to bool.
11144 (is_longjmp_type): New function.
11145 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
11146 (set_raw_breakpoint_without_location): Use
11147 new_breakpoint_from_type.
11148 (set_raw_breakpoint): Likewise.
11149
11150 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
11151
11152 * breakpoint.c (new_breakpoint_from_type): New function.
11153 (create_breakpoint_sal): Use new_breakpoint_from_type and
11154 unique_ptr.
11155 (create_breakpoint): Likewise.
11156
11157 2017-05-31 Simon Marchi <simon.marchi@ericsson.com>
11158
11159 * memattr.c (mem_info_command): Rename to ...
11160 (info_mem_command): ... this.
11161 (mem_enable_command): Rename to ...
11162 (enable_mem_command): ... this.
11163 (mem_disable_command): Rename to ...
11164 (disable_mem_command): ... this.
11165 (mem_delete_command): Rename to ...
11166 (delete_mem_command): ... this.
11167 (_initialize_mem): Adjust function names.
11168
11169 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
11170
11171 * btrace.c (handle_pt_insn_events): New.
11172 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
11173 STATUS. Split into this and ...
11174 (handle_pt_insn_event_flags): ... this.
11175
11176 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
11177
11178 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
11179 and struct pt_insn.resynced.
11180 * configure: Regenerated.
11181 * config.in: Regenerated.
11182
11183 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11184
11185 * btrace.c (ftrace_find_call_by_number): New function.
11186 (ftrace_new_function): Store objects, not pointers.
11187 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
11188 ftrace_new_gap, ftrace_update_function,
11189 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
11190 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
11191 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
11192 btrace_ends_with_single_insn, btrace_call_get): Account for
11193 btrace_thread_info::functions now storing objects.
11194 * btrace.h (struct btrace_thread_info): Add constructor.
11195 (struct btrace_thread_info) <functions>: Make std::vector.
11196 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
11197 Initialize with default values.
11198 * record-btrace.c (record_btrace_frame_sniffer): Account for
11199 btrace_thread_info::functions now storing objects.
11200
11201 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11202
11203 * btrace.c: Remove typedef bfun_s.
11204 (ftrace_new_gap): Directly add gaps to the list of gaps.
11205 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
11206 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
11207 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
11208 instead of gdb VEC.
11209
11210 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11211
11212 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
11213 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
11214 with btrace_thread_info::next_segment and
11215 btrace_thread_info::prev_segment.
11216 * btrace.h: Remove struct btrace_func_link.
11217 (struct btrace_function): Replace pair of function segment pointers
11218 with pair of indices.
11219 * python/py-record-btrace.c (btpy_call_prev_sibling,
11220 btpy_call_next_sibling): Replace references to
11221 btrace_thread_info::segment with btrace_thread_info::next_segment and
11222 btrace_thread_info::prev_segment.
11223 * record-btrace.c (record_btrace_frame_this_id): Use
11224 btrace_find_call_by_number.
11225
11226 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11227
11228 * btrace.c (ftrace_new_function, ftrace_fixup_level,
11229 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
11230 btrace_insn_next, btrace_insn_prev): Remove references to
11231 btrace_thread_info::flow.
11232 * btrace.h (struct btrace_function): Remove FLOW.
11233
11234 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11235
11236 * btrace.c (ftrace_find_call_by_number): New function.
11237 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
11238 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
11239 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
11240 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
11241 index.
11242 * btrace.h (struct btrace_function): Turn UP into an index.
11243 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
11244 as an index.
11245 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
11246 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
11247 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
11248
11249 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11250
11251 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
11252 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
11253 ftrace_update_function, ftrace_compute_global_level_offset,
11254 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
11255 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
11256 btrace_insn_end, btrace_is_empty): Remove references to
11257 btrace_thread_info::begin and btrace_thread_info::end.
11258 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
11259 (struct btrace_thread_info) <functions>: Adjust comment.
11260 * record-btrace.c (record_btrace_start_replaying): Remove reference to
11261 btrace_thread_info::begin.
11262
11263 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11264
11265 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
11266 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
11267 ftrace_update_function): Remove arguments that implicitly were always
11268 BTINFO->END.
11269 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
11270 Don't pass BTINFO->END.
11271
11272 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11273
11274 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
11275 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
11276 btrace_find_insn_by_number): Replace function segment pointer with
11277 index.
11278 (btrace_insn_cmp): Simplify.
11279 * btrace.h: (struct btrace_insn_iterator) Rename index to
11280 insn_index. Replace function segment pointer with index into function
11281 segment vector.
11282 * record-btrace.c (record_btrace_call_history): Replace function
11283 segment pointer use with index.
11284 (record_btrace_frame_sniffer): Retrieve function call segment through
11285 vector.
11286 (record_btrace_set_replay): Remove defunc't safety check.
11287
11288 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11289
11290 * btrace.c (btrace_ends_with_single_insn): New function.
11291 (btrace_call_get, btrace_call_number, btrace_call_begin,
11292 btrace_call_end, btrace_call_next, btrace_call_prev,
11293 btrace_find_call_by_number): Use index into call segment vector
11294 instead of pointer.
11295 (btrace_call_cmp): Simplify.
11296 * btrace.h (struct btrace_call_iterator): Replace function call segment
11297 pointer with index into vector.
11298 * record-btrace.c (record_btrace_call_history): Use index instead of
11299 pointer.
11300
11301 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11302
11303 * btrace.c (btrace_insn_begin, btrace_insn_end,
11304 btrace_find_insn_by_number): Add btinfo to iterator.
11305 * btrace.h (struct btrace_insn_iterator): Add btinfo.
11306
11307 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11308
11309 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
11310 and save pointers directly.
11311 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
11312 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
11313 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
11314 changed signature of functions.
11315 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
11316 (btrace_fetch): Remove code that adds btrace_function pointers to
11317 vector of btrace_functions.
11318 (btrace_clear): Simplify freeing vector of btrace_functions.
11319
11320 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11321
11322 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
11323 Replace VEC_* with std::vector functions.
11324 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
11325 (struct btrace_thread_info)<functions>: Change type to std::vector.
11326
11327 2017-05-30 Simon Marchi <simon.marchi@ericsson.com>
11328
11329 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
11330 "Removed targets and native configurations" up. Merge duplicate
11331 "New commands" sub-sections. Add "New options" sub-sections.
11332
11333 2017-05-26 Alan Hayward <alan.hayward@arm.com>
11334
11335 * defs.h (copy_integer_to_size): New declaration.
11336 * findvar.c (copy_integer_to_size): New function.
11337 (do_cint_test): New selftest function.
11338 (copy_integer_to_size_test): Likewise.
11339 (_initialize_findvar): Likewise.
11340 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
11341 (mips_fbsd_collect_reg): Use raw_collect_integer.
11342 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
11343 (mips64_fill_gregset): Use raw_collect_integer
11344 (mips64_fill_fpregset): Use raw_supply_integer.
11345 * regcache.c (regcache::raw_supply_integer): New function.
11346 (regcache::raw_collect_integer): Likewise.
11347 * regcache.h: (regcache::raw_supply_integer): New declaration.
11348 (regcache::raw_collect_integer): Likewise.
11349
11350 2017-05-24 Yao Qi <yao.qi@linaro.org>
11351
11352 * Makefile.in (SFILES): Add gdbarch-selftests.c.
11353 (COMMON_OBS): Add gdbarch-selftests.o.
11354 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
11355 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
11356 * gdbarch-selftests.c: New file.
11357 * regcache.h (regcache) <~regcache>: Mark it virtual if
11358 GDB_SELF_TEST.
11359 <raw_write>: Likewise.
11360
11361 2017-05-24 Yao Qi <yao.qi@linaro.org>
11362
11363 * regcache.c (current_regcache): Change it to
11364 regcache::current_regcache.
11365 (regcache_observer_target_changed): Update.
11366 (regcache_thread_ptid_changed): Make it a regcache static
11367 method.
11368 (regcache_thread_ptid_changed): Update.
11369 (class regcache_access): New.
11370 (current_regcache_test): Update.
11371 (_initialize_regcache): Update.
11372 * regcache.h: Include forward_list.
11373 (regcache): Declare regcache_thread_ptid_changed and declare
11374 registers_changed_ptid as friend.
11375
11376 2017-05-24 Yao Qi <yao.qi@linaro.org>
11377
11378 * i387-tdep.c (i387_register_to_value): Use register_size
11379 instead of TYPE_LENGTH.
11380 * m68k-tdep.c (m68k_register_to_value): Likewise.
11381
11382 2017-05-24 Yao Qi <yao.qi@linaro.org>
11383
11384 * i387-tdep.c (i387_convert_register_p): Return false if type
11385 code isn't TYPE_CODE_FLT.
11386
11387 2017-05-24 Yao Qi <yao.qi@linaro.org>
11388
11389 * alpha-tdep.c (alpha_convert_register_p): Return true if type
11390 length is 4.
11391 (alpha_register_to_value): Remove type length check.
11392 (alpha_value_to_register): Likewise.
11393
11394 2017-05-24 Yao Qi <yao.qi@linaro.org>
11395
11396 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
11397 TYPE_CODE_FLT.
11398
11399 2017-05-24 Yao Qi <yao.qi@linaro.org>
11400
11401 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
11402 TYPE_CODE_FLT or not.
11403
11404 2017-05-24 Yao Qi <yao.qi@linaro.org>
11405
11406 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
11407 * avr-tdep.c (avr_gdbarch_init): Likewise.
11408 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
11409 * cris-tdep.c (cris_gdbarch_init): Likewise.
11410 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
11411 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
11412 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
11413 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
11414 * mep-tdep.c (mep_gdbarch_init): Likewise.
11415 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
11416 * mips-tdep.c (mips_gdbarch_init): Likewise.
11417 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
11418 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
11419 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
11420 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
11421 * v850-tdep.c (v850_gdbarch_init): Likewise.
11422
11423 2017-05-24 Yao Qi <yao.qi@linaro.org>
11424
11425 * selftest-arch.c (tests_with_arch): Call registers_changed
11426 and reinit_frame_cache.
11427 * selftest.c (run_self_tests): Likewise.
11428
11429 2017-05-24 Yao Qi <yao.qi@linaro.org>
11430
11431 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
11432 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
11433
11434 2017-05-24 Yao Qi <yao.qi@linaro.org>
11435
11436 * rl78-tdep.c (rl78_gdbarch_init): Don't call
11437 set_gdbarch_print_insn.
11438
11439 2017-05-24 Yao Qi <yao.qi@linaro.org>
11440
11441 * h8300-tdep.c (h8300_gdbarch_init): Don't call
11442 set_gdbarch_print_insn.
11443
11444 2017-05-24 Yao Qi <yao.qi@linaro.org>
11445
11446 * alpha-tdep.c (alpha_gdbarch_init): Don't call
11447 set_gdbarch_print_insn.
11448 * arc-tdep.c (arc_gdbarch_init): Likewise.
11449 * arch-utils.c: include dis-asm.h.
11450 (default_print_insn): New function.
11451 * arch-utils.h (default_print_insn): Declare.
11452 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
11453 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
11454 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
11455 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
11456 * frv-tdep.c (frv_gdbarch_init): Likewise.
11457 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
11458 * gdbarch.sh (print_insn): Use default_print_insn.
11459 * gdbarch.c: Regenerated.
11460 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
11461 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
11462 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
11463 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
11464 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
11465 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
11466 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
11467 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
11468 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
11469 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
11470 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
11471 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
11472 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
11473 * mt-tdep.c (mt_gdbarch_init): Likewise.
11474 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
11475 * nios2-tdep.c (nios2_print_insn): Remove.
11476 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
11477 * rx-tdep.c (rx_gdbarch_init): Likewise.
11478 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
11479 * score-tdep.c (score_print_insn): Remove.
11480 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
11481 * sh-tdep.c (sh_gdbarch_init): Likewise.
11482 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
11483 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
11484 * tic6x-tdep.c (tic6x_print_insn): Remove.
11485 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
11486 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
11487 * v850-tdep.c (v850_gdbarch_init): Likewise.
11488 * vax-tdep.c (vax_gdbarch_init): Likewise.
11489 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
11490 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
11491
11492 2017-05-23 John Baldwin <jhb@FreeBSD.org>
11493
11494 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
11495 (MIPS_FP0_REGNUM): Remove.
11496 (MIPS_FSR_REGNUM): Remove.
11497 (mips_fbsd_supply_fpregs): Use mips_regnum.
11498 (mips_fbsd_supply_gregs): Likewise.
11499 (mips_fbsd_collect_fpregs): Likewise.
11500 (mips_fbsd_collect_gregs): Likewise.
11501
11502 2017-05-23 John Baldwin <jhb@FreeBSD.org>
11503
11504 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
11505 (getpfpregs_supplies): New function.
11506 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
11507 getfpregs_supplies.
11508 (mips_fbsd_store_inferior_registers): Likewise.
11509
11510 2017-05-22 Pedro Alves <palves@redhat.com>
11511
11512 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
11513 maintainer.
11514
11515 2017-05-22 Alan Hayward <alan.hayward@arm.com>
11516
11517 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
11518 (store_register): Likewise.
11519 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
11520 (get_decimal_float_return_value): Likewise.
11521 (do_ppc_sysv_return_value): Likewise.
11522 (ppc64_sysv_abi_push_integer): Likewise.
11523 (ppc64_sysv_abi_push_freg): Likewise.
11524 (ppc64_sysv_abi_return_value_base): Likewise.
11525 (ppc64_sysv_abi_return_value): Likewise.
11526 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
11527 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
11528 * rs6000-nat.c: Likewise.
11529 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
11530 (rs6000_value_to_register): Likewise.
11531 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
11532
11533 2017-05-21 Tom Tromey <tom@tromey.com>
11534
11535 PR rust/21466:
11536 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
11537 arrays as "[T]", not "[T; ]".
11538
11539 2017-05-19 Tom Tromey <tom@tromey.com>
11540
11541 PR rust/21484:
11542 * rust-lang.c (exp_descriptor_rust): New function.
11543 (rust_language_defn): Use it.
11544 * p-lang.c (pascal_language_defn): Update.
11545 * opencl-lang.c (opencl_language_defn): Update.
11546 * objc-lang.c (objc_language_defn): Update.
11547 * m2-lang.c (m2_language_defn): Update.
11548 * language.h (struct language_defn)
11549 <la_watch_location_expression>: New member.
11550 * language.c (unknown_language_defn, auto_language_defn)
11551 (local_language_defn): Update.
11552 * go-lang.c (go_language_defn): Update.
11553 * f-lang.c (f_language_defn): Update.
11554 * d-lang.c (d_language_defn): Update.
11555 * c-lang.h (c_watch_location_expression): Declare.
11556 * c-lang.c (c_watch_location_expression): New function.
11557 (c_language_defn, cplus_language_defn, asm_language_defn)
11558 (minimal_language_defn): Use it.
11559 * breakpoint.c (watch_command_1): Call
11560 la_watch_location_expression.
11561 * ada-lang.c (ada_language_defn): Update.
11562
11563 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11564
11565 PR tui/21482
11566 * gdb_curses.h (NOMACROS): Define.
11567 (NCURSES_NOMACROS): Define.
11568
11569 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11570
11571 PR tui/21482
11572 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
11573 arg to char *.
11574 * tui/tui-wingeneral.c (box_win): Likewise.
11575 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
11576 (tui_show_source_line): Likewise.
11577 (tui_show_exec_info_content): Likewise.
11578
11579 2017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
11580
11581 * sparc-tdep.c (sparc_structure_return_p)
11582 (sparc_arg_on_registers_p): New functions.
11583 (sparc32_store_arguments): Use them.
11584 * sparc64-tdep.c (sparc64_16_byte_align_p)
11585 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
11586 Handle TYPE_CODE_ARRAY.
11587
11588 2017-05-17 Yao Qi <yao.qi@linaro.org>
11589
11590 * cli/cli-decode.c (add_alias_cmd): New function.
11591 * command.h (add_alias_cmd): Declare.
11592 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
11593 instead call add_alias_cmd.
11594
11595 2017-05-17 Pedro Alves <palves@redhat.com>
11596
11597 * Makefile.in (nat_extra_makefile_frag): Rename to ...
11598 (nat_makefile_frag): ... this. All references updated.
11599 * configure.ac: Likewise.
11600 * configure.nat: Likewise. Enhance comments.
11601 * configure: Regenerate.
11602
11603 2017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11604
11605 * procfs.c (procfs_create_inferior): Change prototype to match
11606 definition.
11607
11608 2017-05-13 Eli Zaretskii <eliz@gnu.org>
11609
11610 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
11611 C++ compiler warning.
11612
11613 2017-05-12 Tom Tromey <tom@tromey.com>
11614
11615 PR rust/21483:
11616 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
11617 recurse, just call value_struct_elt directly.
11618
11619 2017-05-12 Tom Tromey <tom@tromey.com>
11620
11621 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
11622 OP_RUST_ARRAY>: Fix.
11623
11624 2017-05-12 Tom Tromey <tom@tromey.com>
11625
11626 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
11627
11628 2017-05-09 Yao Qi <yao.qi@linaro.org>
11629
11630 * regcache.c: Include <forward_list>.
11631 (struct regcache_list): Remove.
11632 (current_regcache): Update.
11633 (get_thread_arch_aspace_regcache): Update for std::forward_list.
11634 (regcache_thread_ptid_changed): Likewise.
11635 (registers_changed_ptid): Likewise.
11636 (current_regcache_size): Likewise.
11637
11638 2017-05-09 Yao Qi <yao.qi@linaro.org>
11639
11640 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
11641 (current_regcache_size): New function.
11642 (current_regcache_test): New function.
11643 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
11644
11645 2017-05-08 Alan Hayward <alan.hayward@arm.com>
11646
11647 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
11648 (print_gp_register_row): Use get_frame_register_value.
11649
11650 2017-05-08 Alan Hayward <alan.hayward@arm.com>
11651
11652 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
11653 (mips_supply_fpregset): Likewise.
11654 (mips64_supply_gregset): Likewise.
11655
11656 2017-05-08 Alan Hayward <alan.hayward@arm.com>
11657
11658 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
11659 regcache->raw_supply_zeroed.
11660
11661 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
11662
11663 * configure.nat: Rearrange 'case' statements to match
11664 host before cpu.
11665
11666 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
11667
11668 * Makefile.in: Remove "@host_makefile_frag@". Add variables
11669 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
11670 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
11671 "@nat_extra_makefile_frag@".
11672 (Makefile): Remove dependency on "@frags@".
11673 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
11674 (data-directory/Makefile): Likewise.
11675 * config/aarch64/linux.mh: Deleted; moved contents to
11676 "gdb/configure.nat".
11677 * config/alpha/alpha-linux.mh: Likewise.
11678 * config/alpha/nbsd.mh: Likewise.
11679 * config/arm/linux.mh: Likewise.
11680 * config/arm/nbsdelf.mh: Likewise.
11681 * config/i386/cygwin.mh: Likewise.
11682 * config/i386/cygwin64.mh: Likewise.
11683 * config/i386/darwin.mh: Likewise.
11684 * config/i386/fbsd.mh: Likewise.
11685 * config/i386/fbsd64.mh: Likewise.
11686 * config/i386/go32.mh: Likewise.
11687 * config/i386/i386gnu.mh: Likewise.
11688 * config/i386/i386sol2.mh: Likewise.
11689 * config/i386/linux.mh: Likewise.
11690 * config/i386/linux64.mh: Likewise.
11691 * config/i386/mingw.mh: Likewise.
11692 * config/i386/mingw64.mh: Likewise.
11693 * config/i386/nbsd64.mh: Likewise.
11694 * config/i386/nbsdelf.mh: Likewise.
11695 * config/i386/nto.mh: Likewise.
11696 * config/i386/obsd.mh: Likewise.
11697 * config/i386/obsd64.mh: Likewise.
11698 * config/i386/sol2-64.mh: Likewise.
11699 * config/ia64/linux.mh: Likewise.
11700 * config/m32r/linux.mh: Likewise.
11701 * config/m68k/linux.mh: Likewise.
11702 * config/m68k/nbsdelf.mh: Likewise.
11703 * config/m68k/obsd.mh: Likewise.
11704 * config/m88k/obsd.mh: Likewise.
11705 * config/mips/fbsd.mh: Likewise.
11706 * config/mips/linux.mh: Likewise.
11707 * config/mips/nbsd.mh: Likewise.
11708 * config/mips/obsd64.mh: Likewise.
11709 * config/pa/linux.mh: Likewise.
11710 * config/pa/nbsd.mh: Likewise.
11711 * config/pa/obsd.mh: Likewise.
11712 * config/powerpc/aix.mh: Likewise.
11713 * config/powerpc/fbsd.mh: Likewise.
11714 * config/powerpc/linux.mh: Likewise.
11715 * config/powerpc/nbsd.mh: Likewise.
11716 * config/powerpc/obsd.mh: Likewise.
11717 * config/powerpc/ppc64-linux.mh: Likewise.
11718 * config/powerpc/spu-linux.mh: Likewise.
11719 * config/s390/linux.mh: Likewise.
11720 * config/sh/nbsd.mh: Likewise.
11721 * config/sparc/fbsd.mh: Likewise.
11722 * config/sparc/linux.mh: Likewise.
11723 * config/sparc/linux64.mh: Likewise.
11724 * config/sparc/nbsd64.mh: Likewise.
11725 * config/sparc/nbsdelf.mh: Likewise.
11726 * config/sparc/obsd64.mh: Likewise.
11727 * config/sparc/sol2.mh: Likewise.
11728 * config/tilegx/linux.mh: Likewise.
11729 * config/vax/nbsdelf.mh: Likewise.
11730 * config/vax/obsd.mh: Likewise.
11731 * config/xtensa/linux.mh: Likewise.
11732 * config/i386/i386gnu.mn: New file, with excerpts from
11733 "config/i386/i386gnu.mh".
11734 * configure: Regenerate.
11735 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
11736 *.mh files under "gdb/config".
11737 * configure.nat: New file, with contents from the
11738 "gdb/config/*/*.mh" files.
11739
11740 2017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
11741
11742 * btrace.c (btrace_clear): Free insn vector.
11743
11744 2017-05-05 Pedro Alves <palves@redhat.com>
11745
11746 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
11747 * configure: Regenerate.
11748
11749 2017-05-04 Pedro Alves <palves@redhat.com>
11750
11751 * Makefile.in (SFILES): Add progspace-and-thread.c.
11752 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
11753 (COMMON_OBS): Add progspace-and-thread.o.
11754 * breakpoint.c: Include "progspace-and-thread.h".
11755 (update_inserted_breakpoint_locations)
11756 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
11757 Use scoped_restore_current_pspace_and_thread.
11758 (create_std_terminate_master_breakpoint): Use
11759 scoped_restore_current_program_space.
11760 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
11761 (print_breakpoint_location): Use
11762 scoped_restore_current_program_space.
11763 (bp_loc_is_permanent): Use
11764 scoped_restore_current_pspace_and_thread.
11765 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
11766 (download_tracepoint_locations): Use
11767 scoped_restore_current_pspace_and_thread.
11768 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
11769 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
11770 (enum step_over_calls_kind): Moved from inferior.h.
11771 (class scoped_restore_current_thread): New class.
11772 * gdbthread.h (make_cleanup_restore_current_thread): Delete
11773 declaration.
11774 (scoped_restore_current_thread): New class.
11775 * infcmd.c: Include "common/gdb_optional.h".
11776 (continue_1, proceed_after_attach): Use
11777 scoped_restore_current_thread.
11778 (notice_new_inferior): Use scoped_restore_current_thread.
11779 * inferior.c: Include "progspace-and-thread.h".
11780 (restore_inferior, save_current_inferior): Delete.
11781 (add_inferior_command, clone_inferior_command): Use
11782 scoped_restore_current_pspace_and_thread.
11783 * inferior.h (scoped_restore_current_inferior): New class.
11784 * infrun.c: Include "progspace-and-thread.h" and
11785 "common/gdb_optional.h".
11786 (follow_fork_inferior): Use
11787 scoped_restore_current_pspace_and_thread.
11788 (scoped_restore_exited_inferior): New class.
11789 (handle_vfork_child_exec_or_exit): Use
11790 scoped_restore_exited_inferior,
11791 scoped_restore_current_pspace_and_thread,
11792 scoped_restore_current_thread and scoped_restore.
11793 (fetch_inferior_event): Use scoped_restore_current_thread.
11794 * linespec.c (decode_line_full, decode_line_1): Use
11795 scoped_restore_current_program_space.
11796 * mi/mi-main.c: Include "progspace-and-thread.h".
11797 (exec_continue): Use scoped_restore_current_thread.
11798 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
11799 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
11800 * proc-service.c (ps_pglobal_lookup): Use
11801 scoped_restore_current_program_space.
11802 * progspace-and-thread.c: New file.
11803 * progspace-and-thread.h: New file.
11804 * progspace.c (release_program_space, clone_program_space): Use
11805 scoped_restore_current_program_space.
11806 (restore_program_space, save_current_program_space)
11807 (save_current_space_and_thread): Delete.
11808 (switch_to_program_space_and_thread): Moved to
11809 progspace-and-thread.c.
11810 * progspace.h (save_current_program_space)
11811 (save_current_space_and_thread): Delete declarations.
11812 (scoped_restore_current_program_space): New class.
11813 * remote.c (remote_btrace_maybe_reopen): Use
11814 scoped_restore_current_thread.
11815 * symtab.c: Include "progspace-and-thread.h".
11816 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
11817 * thread.c (print_thread_info_1): Use
11818 scoped_restore_current_thread.
11819 (struct current_thread_cleanup): Delete.
11820 (do_restore_current_thread_cleanup)
11821 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
11822 (scoped_restore_current_thread::~scoped_restore_current_thread):
11823 ... this new dtor.
11824 (make_cleanup_restore_current_thread): Rename/convert to ...
11825 (scoped_restore_current_thread::scoped_restore_current_thread):
11826 ... this new ctor.
11827 (thread_apply_all_command): Use scoped_restore_current_thread.
11828 (thread_apply_command): Use scoped_restore_current_thread.
11829 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
11830 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
11831
11832 2017-05-04 Pedro Alves <palves@redhat.com>
11833
11834 * thread.c (make_cleanup_restore_current_thread): Move
11835 find_thread_ptid call before the is_stopped call. Assert that the
11836 thread is found. Replace is_stopped call by checking the thread's
11837 state directly. Remove unnecessary NULL-thread check.
11838
11839 2017-05-04 Pedro Alves <palves@redhat.com>
11840
11841 * corelow.c (thread_section_name): New class.
11842 (get_core_register_section, get_core_siginfo): Use it.
11843
11844 2017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
11845
11846 * corelow.c (sniff_core_bfd): Remove extra semicolon.
11847 (get_core_register_section): Remove xfree of NULL pointer.
11848
11849 2017-05-03 Alan Hayward <alan.hayward@arm.com>
11850
11851 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
11852 * regcache.c (regcache::raw_supply_zeroed): New function.
11853 * regcache.h (regcache::raw_supply_zeroed): New declaration.
11854
11855 2017-05-03 Simon Marchi <simon.marchi@ericsson.com>
11856
11857 * gdbarch.sh: Remove commented out definition of
11858 TARGET_CHAR_BIT.
11859 * gdbarch.h: Re-generate.
11860
11861 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
11862
11863 * configure: Regenerate.
11864
11865 2017-05-02 Simon Marchi <simon.marchi@ericsson.com>
11866
11867 * solib-target.c (solib_target_relocate_section_addresses):
11868 Remove num_section_bases, num_bases, segment_bases variables.
11869
11870 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
11871
11872 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
11873
11874 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
11875
11876 * solib-target.c: Include <vector>
11877 (struct lm_info_target) <~lm_info_target>: Remove.
11878 <segment_bases, section_bases>: Change type to
11879 std::vector<CORE_ADDR>.
11880 (library_list_start_segment, library_list_start_section,
11881 library_list_end_library,
11882 solib_target_relocate_section_addresses): Adjust.
11883
11884 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
11885
11886 * gdbarch.sh (software_single_step): Change return type to
11887 std::vector<CORE_ADDR>.
11888 * gdbarch.c, gdbarch.h: Re-generate.
11889 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
11890 Adjust.
11891 (arm_deal_with_atomic_sequence_raw): Adjust.
11892 (thumb_get_next_pcs_raw): Adjust.
11893 (arm_get_next_pcs_raw): Adjust.
11894 (arm_get_next_pcs): Adjust.
11895 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
11896 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
11897 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
11898 (alpha_software_single_step): Adjust.
11899 * alpha-tdep.h (alpha_software_single_step): Adjust.
11900 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
11901 * arm-tdep.c (arm_software_single_step): Adjust.
11902 (arm_breakpoint_kind_from_current_state): Adjust.
11903 * arm-tdep.h (arm_software_single_step): Adjust.
11904 * breakpoint.c (insert_single_step_breakpoint): Adjust.
11905 * cris-tdep.c (cris_software_single_step): Adjust.
11906 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
11907 (micromips_deal_with_atomic_sequence): Adjust.
11908 (deal_with_atomic_sequence): Adjust.
11909 (mips_software_single_step): Adjust.
11910 * mips-tdep.h (mips_software_single_step): Adjust.
11911 * moxie-tdep.c (moxie_software_single_step): Adjust.
11912 * nios2-tdep.c (nios2_software_single_step): Adjust.
11913 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
11914 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
11915 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
11916 * s390-linux-tdep.c (s390_software_single_step): Adjust.
11917 * sparc-tdep.c (sparc_software_single_step): Adjust.
11918 * spu-tdep.c (spu_software_single_step): Adjust.
11919 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
11920
11921 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
11922
11923 * gdbarch.sh: Use semi-colon as field separator instead of colon.
11924 * gdbarch.h: Re-generate.
11925
11926 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
11927
11928 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
11929 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
11930 * python/py-instruction.c, python/py-instruction.h: New file.
11931 * python/py-record.c: Add py-instruction.h include.
11932 (gdbpy_initialize_record): Make gdb.Instruction a super class of
11933 gdb.RecordInstruction.
11934 * python/python-internal.h: Add gdbpy_initialize_instruction
11935 declaration.
11936 * python/python.c (do_start_initialization): Add
11937 gdbpy_initialize_instruction.
11938
11939 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
11940
11941 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
11942 Remove.
11943 (btrace_func_from_recpy_func): New function.
11944 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
11945 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
11946 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
11947 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
11948 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
11949 Also, use new helper functions.
11950 (btpy_list_item): Use new helper functions.
11951 (recpy_bt_function_call_history): Use new type name.
11952 (btpy_call_getset): Remove.
11953 (gdbpy_initialize_btrace): Remove code to initialize
11954 gdb.BtraceFunctionCall.
11955 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
11956 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
11957 recpy_bt_func_prev, recpy_bt_func_next): New export.
11958 * python/py-record.c (recpy_func_type): New static object.
11959 (recpy_func_new, recpy_func_level, recpy_func_symbol,
11960 recpy_func_instructions, recpy_func_up, recpy_func_prev,
11961 recpy_func_next): New function.
11962 (recpy_element_hash, recpy_element_richcompare): Updated comment.
11963 (recpy_func_getset): New static object.
11964 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
11965 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
11966
11967 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
11968
11969 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
11970 (btpy_object, btpy_insn_type, btpy_new): Remove.
11971 (btpy_list_object): Use gdb.RecordInstruction type instead of
11972 gdb.BtraceInstruction type.
11973 (btrace_insn_from_recpy_insn): New function.
11974 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
11975 btpy_new.
11976 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
11977 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
11978 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
11979 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
11980 instead of btpy_object.
11981 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
11982 btpy_insn_data, btpy_insn_decode): Rename to ...
11983 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
11984 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
11985 recpy_bt_insn_decode): This. Also, use new helper functions.
11986 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
11987 recpy_insn_type.
11988 (btpy_insn_getset): Remove.
11989 (gdbpy_initialize_btrace): Remove code to initialize
11990 gdb.BtraceInstruction. Use recpy_element_object.
11991 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
11992 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
11993 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
11994 * python/py-record.c (recpy_insn_type): New static object.
11995 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
11996 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
11997 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
11998 New function.
11999 (recpy_insn_getset): New static object.
12000 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
12001 * python/py-record.h (recpy_element_object): New typedef.
12002 (recpy_insn_type, recpy_insn_new): New export.
12003
12004 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12005
12006 * py-record-btrace.c (btpy_insn_new): Removed.
12007 (btpy_insn_or_gap_new): New function.
12008 (btpy_insn_error): Removed.
12009 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
12010 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
12011 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
12012 btpy_insn_or_gap_new instead of btpy_insn_new.
12013 (btpy_insn_getset): Remove btpy_insn_error.
12014 * py-record.c (recpy_gap_type): New static object.
12015 (recpy_gap_object): New typedef.
12016 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
12017 recpy_gap_reason_string): New function.
12018 (recpy_gap_getset): New static object.
12019 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
12020 * py-record.h (recpy_gap_new): New export.
12021
12022 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12023
12024 * python/py-record.c (recpy_ptid): Remove.
12025 (recpy_record_getset): Remove recpy_ptid.
12026
12027 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12028
12029 * btrace.c (btrace_fetch): Set inferior_ptid.
12030 * python/py-record-btrace.c: Add "py-record.h" include.
12031 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
12032 recpy_bt_end, recpy_bt_instruction_history,
12033 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
12034 in gdb.Record object instead of current ptid.
12035 * python/py-record.c: Include new "py-record.h" file.
12036 (recpy_record_object): Moved to py-record.h.
12037 * python/py-record.h: New file.
12038
12039 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12040
12041 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
12042 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
12043 indentation.
12044
12045 2017-05-01 Joel Brobecker <brobecker@adacore.com>
12046
12047 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
12048 the past maintainers section.
12049
12050 2017-04-28 Yao Qi <yao.qi@linaro.org>
12051
12052 * infcmd.c (get_return_value): Use regcache ctor, and remove
12053 cleanup.
12054
12055 2017-04-28 Yao Qi <yao.qi@linaro.org>
12056 Pedro Alves <palves@redhat.com>
12057
12058 * regcache.c (regcache::regcache): New tag dispatch ctor.
12059 (do_cooked_read): Moved above.
12060 (regcache_dup): Use the tag dispatch ctor..
12061 * regcache.h (regcache): Declare ctor, delete copy ctor and
12062 assignment operator, remove friend regcache_dup.
12063
12064 2017-04-28 Yao Qi <yao.qi@linaro.org>
12065
12066 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
12067 call method save instead of regcache_cpy.
12068 * regcache.h (struct regcache): Make regcache_dup a friend.
12069
12070 2017-04-28 Yao Qi <yao.qi@linaro.org>
12071
12072 * regcache.c (struct regcache): Move to regcache.h
12073 (regcache::arch): New method.
12074 (regcache_get_ptid): Update.
12075 (get_regcache_arch): Call arch method.
12076 (get_regcache_aspace): Call method aspace.
12077 (register_buffer): Change it to method.
12078 (regcache_save): Change it to regcache::save.
12079 (regcache_restore): Likewise.
12080 (regcache_cpy_no_passthrough): Remove the declaration.
12081 (regcache_cpy): Call methods restore and cpy_no_passthrough.
12082 (regcache_cpy_no_passthrough): Change it to method
12083 cpy_no_passthrough.
12084 (regcache_register_status): Change it to method
12085 get_register_status.
12086 (regcache_invalidate): Change it to method invalidate.
12087 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
12088 (regcache_raw_update): Change it to method raw_update.
12089 (regcache_raw_read): Likewise.
12090 (regcache_raw_read_signed): Likewise.
12091 (regcache_raw_read_unsigned): Likewise.
12092 (regcache_raw_write_signed): Likewise.
12093 (regcache_raw_write_unsigned): Likewise.
12094 (regcache_cooked_read): Likewise.
12095 (regcache_cooked_read_value): Likewise.
12096 (regcache_cooked_read_signed): Likewise.
12097 (regcache_cooked_read_unsigned): Likewise.
12098 (regcache_cooked_write_signed): Likewise.
12099 (regcache_cooked_write_unsigned): Likewise.
12100 (regcache_raw_set_cached_value): Likewise.
12101 (regcache_raw_write): Likewise.
12102 (regcache_cooked_write): Likewise.
12103 (regcache_xfer_part): Likewise.
12104 (regcache_raw_read_part): Likewise.
12105 (regcache_raw_write_part): Likewise.
12106 (regcache_cooked_read_part): Likewise.
12107 (regcache_cooked_write_part): Likewise.
12108 (regcache_raw_supply): Likewise.
12109 (regcache_raw_collect): Likewise.
12110 (regcache_transfer_regset): Likewise.
12111 (regcache_supply_regset): Likewise.
12112 (regcache_collect_regset): Likewise.
12113 (regcache_debug_print_register): Likewise.
12114 (enum regcache_dump_what): Move it to regcache.h.
12115 (regcache_dump): Change it to method dump.
12116 * regcache.h (enum regcache_dump_what): New.
12117 (class regcache): New.
12118 * target.c (target_fetch_registers): Call method
12119 debug_print_register.
12120 (target_store_registers): Likewise.
12121
12122 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12123
12124 * windows-nat.c (struct lm_info_windows): Initialize field.
12125 (windows_make_so): Allocate lm_info_windows with new.
12126 (windows_free_so): Free lm_info_windows with delete.
12127
12128 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12129
12130 * solib-darwin.c (struct lm_info_darwin): Initialize field.
12131 (darwin_current_sos): Allocate lm_info_darwin with new, remove
12132 cleanup.
12133 (darwin_free_so): Free lm_info_darwin with delete.
12134
12135 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12136
12137 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
12138 <l_addr_p>: Change type to bool.
12139 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
12140 (svr4_free_so): Free lm_info_svr4 with delete.
12141 (svr4_copy_library_list): Replace memcpy with call to copy
12142 constructor.
12143 (library_list_start_library, svr4_default_sos): Allocate
12144 lm_info_svr4 with new.
12145
12146 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12147
12148 * solib-target.c (struct lm_info_target): Add destructor,
12149 initialize fields.
12150 <name>: Change type to std::string.
12151 (library_list_start_library): Allocate lm_info_target with new.
12152 (solib_target_free_library_list): Free lm_info_target with
12153 delete.
12154 (solib_target_current_sos): Adapt to std::string.
12155 (solib_target_free_so): Free lm_info_target with delete.
12156
12157 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12158
12159 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
12160 fields.
12161 (frv_current_sos): Allocate lm_info_frv with new.
12162 (frv_relocate_main_executable): Free lm_info_frv with delete,
12163 allocate with new.
12164 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
12165
12166 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12167
12168 * solib-frv.c (struct lm_info_frv): Fix indentation.
12169
12170 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12171
12172 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
12173 map field.
12174 (dsbt_current_sos): Allocate lm_info_dsbt with new.
12175 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
12176 and allocate with new.
12177 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
12178
12179 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12180
12181 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
12182 <filename, member_name>: Change type to std::string.
12183 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
12184 (library_list_start_library): Allocate lm_info_aix with new.
12185 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
12186 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
12187 with copy constructor.
12188
12189 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12190
12191 * solist.h (struct lm_info): Remove.
12192 (struct lm_info_base): New class.
12193 (struct so_list) <lm_info>: Change type to lm_info_base *.
12194 * nto-tdep.c (struct lm_info): Remove.
12195 (lm_addr): Adjust.
12196 * solib-aix.c (struct lm_info): Rename to ...
12197 (struct lm_info_aix): ... this. Extend lm_info_base.
12198 (lm_info_p): Rename to ...
12199 (lm_info_aix_p): ... this, and adjust.
12200 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
12201 solib_aix_parse_libraries, library_list_start_library,
12202 solib_aix_free_library_list, solib_aix_parse_libraries,
12203 solib_aix_get_library_list,
12204 solib_aix_relocate_section_addresses, solib_aix_free_so,
12205 solib_aix_get_section_offsets,
12206 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
12207 Adjust.
12208 (struct solib_aix_inferior_data) <library_list>: Adjust.
12209 * solib-darwin.c (struct lm_info): Rename to ...
12210 (struct lm_info_darwin): ... this. Extend lm_info_base.
12211 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
12212 * solib-dsbt.c (struct lm_info): Rename to ...
12213 (struct lm_info_dsbt): ... this. Extend lm_info_base.
12214 (struct dsbt_info) <main_executable_lm_info): Adjust.
12215 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
12216 dsbt_relocate_section_addresses): Adjust.
12217 * solib-frv.c (struct lm_info): Rename to ...
12218 (struct lm_info_frv): ... this. Extend lm_info_base.
12219 (main_executable_lm_info): Adjust.
12220 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
12221 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
12222 find_canonical_descriptor_in_load_object,
12223 frv_fdpic_find_canonical_descriptor): Adjust.
12224 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
12225 to lm_info_svr4.
12226 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
12227 svr4_clear_so, svr4_copy_library_list,
12228 library_list_start_library, svr4_default_sos, svr4_read_so_list,
12229 svr4_current_sos, svr4_fetch_objfile_link_map,
12230 solist_update_incremental): Adjust.
12231 * solib-svr4.h (struct lm_info_svr4): Move here from
12232 solib-svr4.c.
12233 * solib-target.c (struct lm_info): Rename to ...
12234 (struct lm_info_target): ... this. Extend lm_info_base.
12235 (lm_info_p): Rename to ...
12236 (lm_info_target_p): ... this.
12237 (solib_target_parse_libraries, library_list_start_segment,
12238 library_list_start_section, library_list_start_library,
12239 library_list_end_library, solib_target_free_library_list,
12240 solib_target_current_sos, solib_target_free_so,
12241 solib_target_relocate_section_addresses): Adjust.
12242 * windows-nat.c (struct lm_info): Rename to ...
12243 (struct lm_info_windows): ... this. Extend lm_info_base.
12244 (windows_make_so, handle_load_dll, handle_unload_dll,
12245 windows_xfer_shared_libraries): Adjust.
12246
12247 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12248
12249 * solib-darwin.c (struct darwin_so_list): Remove.
12250 (darwin_current_sos): Allocate an so_list object instead of a
12251 darwin_so_list, separately allocate an lm_info object.
12252 (darwin_free_so): Free lm_info.
12253
12254 2017-04-28 John Baldwin <jhb@FreeBSD.org>
12255
12256 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
12257 with fprintf_filtered.
12258
12259 2017-04-28 Yao Qi <yao.qi@linaro.org>
12260
12261 * regcache.c (regcache::regcache): New function.
12262 (regcache::~regcache): New function.
12263 (regcache_xmalloc_1): Remove.
12264 (regcache_xmalloc): Call new regcache.
12265 (regcache_xfree): Call delete regcache.
12266 (get_thread_arch_aspace_regcache): Call new regcache.
12267
12268 2017-04-28 Yao Qi <yao.qi@linaro.org>
12269
12270 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
12271 lwp instead of ptid_get_lwp.
12272
12273 2017-04-28 Yao Qi <yao.qi@linaro.org>
12274
12275 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
12276 lwp_info instead of getting from inferior_ptid.
12277
12278 2017-04-27 Keith Seitz <keiths@redhat.com>
12279
12280 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
12281 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
12282 (CV_CONVERSION_BADNESS): Define.
12283 (rank_one_type): Remove overly restrictive rvalue reference
12284 rank checks.
12285 Add cv-qualifier checks and subranks for type equality.
12286 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
12287 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
12288 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
12289
12290 2017-04-27 Simon Marchi <simon.marchi@ericsson.com>
12291
12292 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
12293 count when creating the object.
12294
12295 2017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
12296 Ulrich Weigand <uweigand@de.ibm.com>
12297
12298 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
12299 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
12300 is used in AIX.
12301 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
12302 (process_xcoff_symbol): Likewise.
12303 (scan_xcoff_symtab): Likewise.
12304
12305 2017-04-26 Alan Hayward <alan.hayward@arm.com>
12306
12307 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
12308 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
12309 (ia64_access_reg): Use get_frame_register_unsigned.
12310 (ia64_access_rse_reg): Likewise.
12311 (ia64_libunwind_frame_prev_register): Likewise.
12312
12313 2017-04-26 Jiong Wang <jiong.wang@arm.com>
12314
12315 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
12316 * gdbarch.c: Regenerated.
12317 * gdbarch.h: Regenerated.
12318 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
12319 visibility external.
12320 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
12321 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
12322 (enum cfa_how_kind): Move to ...
12323 (struct dwarf2_frame_state_reg_info): Likewise.
12324 (struct dwarf2_frame_state): Likewise.
12325 * dwarf2-frame.h: ... here.
12326 (dwarf2_frame_state_alloc_regs): New declaration.
12327 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
12328 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
12329
12330 2017-04-26 Alan Hayward <alan.hayward@arm.com>
12331
12332 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
12333 regcache_raw_read_unsigned.
12334 (xtensa_pseudo_register_write): Likewise.
12335
12336 2017-04-26 Alan Hayward <alan.hayward@arm.com>
12337
12338 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
12339 (nds32_pseudo_register_write): Likewise.
12340
12341 2017-04-25 Yao Qi <yao.qi@linaro.org>
12342
12343 * regcache.c (struct regcache) <readonly_p>: Change its type
12344 to bool.
12345 (regcache_xmalloc_1): Update parameter type and callers update.
12346
12347 2017-04-25 Yao Qi <yao.qi@linaro.org>
12348
12349 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
12350 set_gdbarch_wchar_bit.
12351 * arm-tdep.c (arm_gdbarch_init): Likewise.
12352
12353 2017-04-25 Pedro Alves <palves@redhat.com>
12354
12355 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
12356 (BothAreRelocatable, memcopy, memmove): Don't define.
12357 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
12358 macros.
12359
12360 2017-04-25 Pedro Alves <palves@redhat.com>
12361
12362 * common/common-defs.h: Include "common/poison.h".
12363 * common/function-view.h: (Not, Or, Requires): Move to traits.h
12364 and adjust.
12365 * common/poison.h: New file.
12366 * common/traits.h: Include <type_traits>.
12367 (Not, Or, Requires): New, moved from common/function-view.h.
12368
12369 2017-04-25 Pedro Alves <palves@redhat.com>
12370
12371 * breakpoint.h (struct breakpoint): In-class initialize all
12372 fields. Make boolean fields "bool".
12373 * breakpoint.c (init_raw_breakpoint_without_location): Remove
12374 memset call and initializations no longer necessary.
12375
12376 2017-04-25 Pedro Alves <palves@redhat.com>
12377
12378 * btrace.c (pt_btrace_insn_flags): Change parameter type to
12379 reference.
12380 (pt_btrace_insn): New function.
12381 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
12382
12383 2017-04-25 Pedro Alves <palves@redhat.com>
12384
12385 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
12386 "base" field and inherit from "bp_location" instead. Add
12387 non-default ctor.
12388 (allocate_location_exception): Use new non-default ctor.
12389 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
12390 (init_bp_location): Convert to ...
12391 (bp_location::bp_location): ... this new ctor, and remove memset
12392 call.
12393 (base_breakpoint_allocate_location): Use the new non-default ctor.
12394 * breakpoint.h (bp_location): Now a class. Declare default and
12395 non-default ctors. In-class initialize all members.
12396 (init_bp_location): Remove declaration.
12397
12398 2017-04-25 Pedro Alves <palves@redhat.com>
12399
12400 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
12401 assignment operator.
12402
12403 2017-04-24 Yao Qi <yao.qi@linaro.org>
12404
12405 * doublest.c (convert_doublest_to_floatformat): Call
12406 floatformat_totalsize_bytes.
12407
12408 2017-04-22 Tom Tromey <tom@tromey.com>
12409
12410 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
12411 ui_out_emit_list.
12412 * stack.c (print_frame): Use ui_out_emit_list.
12413 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
12414 ui_out_emit_list.
12415 * mi/mi-main.c (print_one_inferior)
12416 (mi_cmd_data_list_register_names)
12417 (mi_cmd_data_list_register_values, mi_cmd_list_features)
12418 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
12419 ui_out_emit_list.
12420 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
12421 (mi_output_solib_attribs): Use ui_out_emit_list,
12422 ui_out_emit_tuple.
12423 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
12424 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
12425 (mi_cmd_stack_list_args, list_args_or_locals): Use
12426 ui_out_emit_list.
12427 * disasm.c (do_assembly_only): Use ui_out_emit_list.
12428 * breakpoint.c (print_solib_event, output_thread_groups): Use
12429 ui_out_emit_list.
12430
12431 2017-04-22 Tom Tromey <tom@tromey.com>
12432
12433 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
12434 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
12435 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
12436
12437 2017-04-22 Tom Tromey <tom@tromey.com>
12438
12439 * tracepoint.c (tvariables_info_1)
12440 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
12441
12442 2017-04-22 Tom Tromey <tom@tromey.com>
12443
12444 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
12445 annotate_arg_emitter.
12446 * breakpoint.c (print_mention_watchpoint)
12447 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
12448 * annotate.h (struct annotate_arg_emitter): New.
12449
12450 2017-04-22 Tom Tromey <tom@tromey.com>
12451
12452 * record-btrace.c (record_btrace_insn_history)
12453 (record_btrace_insn_history_range, record_btrace_call_history)
12454 (record_btrace_call_history_range): Use ui_out_emit_tuple.
12455 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
12456 ui_out_emit_tuple.
12457 * stack.c (print_frame_info): Use ui_out_emit_tuple.
12458 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
12459 * skip.c (skip_info): Use ui_out_emit_tuple.
12460 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
12461 * progspace.c (print_program_space): Use ui_out_emit_tuple.
12462 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
12463 * osdata.c (info_osdata): Use ui_out_emit_tuple.
12464 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
12465 ui_out_emit_tuple.
12466 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
12467 (output_register, mi_cmd_data_read_memory)
12468 (mi_cmd_data_read_memory_bytes, mi_load_progress)
12469 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
12470 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
12471 Use ui_out_emit_tuple.
12472 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
12473 ui_out_emit_tuple.
12474 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
12475 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
12476 * linux-thread-db.c (info_auto_load_libthread_db): Use
12477 ui_out_emit_tuple.
12478 * inferior.c (print_inferior): Use ui_out_emit_tuple.
12479 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
12480 * disasm.c (do_mixed_source_and_assembly_deprecated)
12481 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
12482 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
12483 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
12484 * breakpoint.c (print_one_breakpoint_location)
12485 (print_one_breakpoint): Use ui_out_emit_tuple.
12486 * auto-load.c (print_script, info_auto_load_cmd): Use
12487 ui_out_emit_tuple.
12488 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
12489
12490 2017-04-21 Simon Marchi <simon.marchi@ericsson.com>
12491
12492 * thread.c (print_thread_info_1): Remove dead code.
12493
12494 2017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12495
12496 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
12497 GDB_SELF_TEST.
12498 * arm-tdep.c (selftests::arm_record_test): Likewise.
12499
12500 2017-04-21 Yao Qi <yao.qi@linaro.org>
12501
12502 * regcache.c (regcache_restore): Remove argument 2. Replace
12503 argument 3 with regcache. Get register status from
12504 src->register_status and get register contents from
12505 register_buffer (src, regnum).
12506 (regcache_cpy): Update.
12507
12508 2017-04-19 Pedro Alves <palves@redhat.com>
12509
12510 * gdbthread.h (thread): Add missing closing parenthesis in
12511 comment.
12512
12513 2017-04-19 Pedro Alves <palves@redhat.com>
12514
12515 * common/refcounted-object.h: New file.
12516 * gdbthread.h: Include "common/refcounted-object.h".
12517 (thread_info): Inherit from refcounted_object and add comments.
12518 (thread_info::incref, thread_info::decref)
12519 (thread_info::m_refcount): Delete.
12520 (thread_info::deletable): Use the refcounted_object::refcount()
12521 method.
12522 * inferior.c (current_inferior_): Add comment.
12523 (set_current_inferior): Increment/decrement refcounts.
12524 (prune_inferiors, remove_inferior_command): Skip inferiors marked
12525 not-deletable instead of comparing with the current inferior.
12526 (initialize_inferiors): Increment the initial inferior's refcount.
12527 * inferior.h (struct inferior): Forward declare.
12528 Include "common/refcounted-object.h".
12529 (current_inferior, set_current_inferior): Move declaration to
12530 before struct inferior's definition, and fix comment.
12531 (inferior): Inherit from refcounted_object. Add comments.
12532 * thread.c (switch_to_thread_no_regs): Reference the thread's
12533 inferior pointer directly instead of doing a ptid lookup.
12534 (switch_to_no_thread): New function.
12535 (switch_to_thread(thread_info *)): New function, factored out
12536 from ...
12537 (switch_to_thread(ptid_t)): ... this.
12538 (restore_current_thread): Delete.
12539 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
12540 fields, and add 'inf' field.
12541 (do_restore_current_thread_cleanup): Check whether old->inf is
12542 alive instead of looking up an inferior by ptid. Use
12543 switch_to_thread and switch_to_no_thread.
12544 (restore_current_thread_cleanup_dtor): Use old->inf directly
12545 instead of lookup up an inferior by id. Decref the inferior.
12546 Don't restore 'removable'.
12547 (make_cleanup_restore_current_thread): Same the inferior pointer
12548 in old, instead of the inferior number. Incref the inferior.
12549 Don't save/clear 'removable'.
12550
12551 2017-04-19 Pedro Alves <palves@redhat.com>
12552
12553 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12554 unittests/scoped_restore-selftests.c.
12555 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
12556 * common/scoped_restore.h (scoped_restore_base): Make "class".
12557 (scoped_restore_base::release): New public method.
12558 (scoped_restore_base::scoped_restore_base): New protected ctor.
12559 (scoped_restore_base::m_saved_var): New protected field.
12560 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
12561 scoped_restore_base base class instead of m_saved_var directly.
12562 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
12563 (scoped_restore_tmpl::scoped_restore_tmpl(const
12564 scoped_restore_tmpl<T>&)): Likewise.
12565 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
12566 method.
12567 (scoped_restore_tmpl::saved_var): New method.
12568 (scoped_restore_tmpl::m_saved_var): Delete.
12569 * inferior.h (inferior::detaching): Now a bool.
12570 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
12571 cleanup.
12572 * unittests/scoped_restore-selftests.c: New file.
12573
12574 2017-04-19 Pedro Alves <palves@redhat.com>
12575
12576 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
12577 Re-sort in alphabetic order.
12578
12579 2017-04-18 Pedro Alves <palves@redhat.com>
12580
12581 * xml-support.c (obstack_xml_printf): Delete.
12582 * xml-support.h (obstack_xml_printf): Delete.
12583
12584 2017-04-18 Pedro Alves <palves@redhat.com>
12585
12586 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
12587 vdebug, verror, body_text, start_element, end_element, name,
12588 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
12589 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
12590 is_xinclude>: Make private and add m_ prefix.
12591 (gdb_xml_parser::body_text): New method, based on ...
12592 (gdb_xml_body_text): ... this. Adjust.
12593 (gdb_xml_parser::vdebug): New method, based on ...
12594 (gdb_xml_debug): ... this. Adjust.
12595 (gdb_xml_parser::verror): New method, based on ...
12596 (gdb_xml_error): ... this. Adjust.
12597 (gdb_xml_parser::start_element): New method, based on ...
12598 (gdb_xml_start_element): ... this. Adjust.
12599 (gdb_xml_start_element_wrapper): Defer to
12600 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
12601 (gdb_xml_parser::end_element): New method, based on ...
12602 (gdb_xml_end_element_wrapper): ... this. Adjust.
12603 (gdb_xml_parser::~gdb_xml_parser): Adjust.
12604 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
12605 (gdb_xml_parser::use_dtd): New method, based on ...
12606 (gdb_xml_use_dtd): ... this. Adjust.
12607 (gdb_xml_parser::parse): New method, based on ...
12608 (gdb_xml_parse): ... this. Adjust.
12609 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
12610 (xinclude_start_include): Adjust to call the parser's name method.
12611 (xml_xinclude_default, xml_xinclude_start_doctype)
12612 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
12613 method.
12614 (xml_process_xincludes): Adjust to call parser methods.
12615 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
12616 declarations.
12617
12618 2017-04-18 Pedro Alves <palves@redhat.com>
12619
12620 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
12621 gdb::optional<std::string>.
12622 * xml-support.c: Include <string>.
12623 (scope_level::scope_level(scope_level &&))
12624 (scope_level::~scope_level): Delete.
12625 (scope_level::body): Now a std::string.
12626 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
12627 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
12628 parameter.
12629 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
12630 (xinclude_parsing_data::output): Now a std::string reference.
12631 (xinclude_start_include): Adjust.
12632 (xml_xinclude_default): Adjust.
12633 (xml_process_xincludes): Add 'output' parameter, and return bool.
12634 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
12635 and return bool.
12636 * xml-tdesc.c: Include <unordered_map> and <string>.
12637 (tdesc_xml_cache): Delete.
12638 (tdesc_xml_cache_s): Delete.
12639 (xml_cache): Now an std::unordered_map.
12640 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
12641 (target_fetch_description_xml): Change return type to
12642 gdb::optional<std::string>, and adjust.
12643 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
12644 (target_fetch_description_xml): Change return type to
12645 gdb::optional<std::string>.
12646
12647 2017-04-18 Pedro Alves <palves@redhat.com>
12648
12649 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12650 unittests/optional-selftests.c.
12651 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
12652 * unittests/optional-selftests.c: New file.
12653 * unittests/optional/assignment/1.cc: New file.
12654 * unittests/optional/assignment/2.cc: New file.
12655 * unittests/optional/assignment/3.cc: New file.
12656 * unittests/optional/assignment/4.cc: New file.
12657 * unittests/optional/assignment/5.cc: New file.
12658 * unittests/optional/assignment/6.cc: New file.
12659 * unittests/optional/assignment/7.cc: New file.
12660 * unittests/optional/cons/copy.cc: New file.
12661 * unittests/optional/cons/default.cc: New file.
12662 * unittests/optional/cons/move.cc: New file.
12663 * unittests/optional/cons/value.cc: New file.
12664 * unittests/optional/in_place.cc: New file.
12665 * unittests/optional/observers/1.cc: New file.
12666 * unittests/optional/observers/2.cc: New file.
12667
12668 2017-04-18 Pedro Alves <palves@redhat.com>
12669
12670 * common/gdb_optional.h: Include common/traits.h.
12671 (in_place_t): New type.
12672 (in_place): New constexpr variable.
12673 (optional::optional): Remove member initialization of
12674 m_instantiated.
12675 (optional::optional(in_place_t...)): New constructor.
12676 (optional::~optional): Use reset.
12677 (optional::optional(const optional&)): New.
12678 (optional::optional(const optional&&)): New.
12679 (optional::optional(T &)): New.
12680 (optional::optional(T &&)): New.
12681 (operator::operator=(const optional &)): New.
12682 (operator::operator=(optional &&)): New.
12683 (operator::operator= (const T &))
12684 (operator::operator= (T &&))
12685 (operator::emplace (Args &&... args)): Return a T&. Use reset.
12686 (operator::reset): New.
12687 (operator::m_instantiated):: Add in-class initializer.
12688 * common/traits.h: Include <type_traits>.
12689 (struct And): New types.
12690
12691 2017-04-18 Pedro Alves <palves@redhat.com>
12692
12693 * xml-support.c: Include <vector>.
12694 (scope_level::scope_level(const gdb_xml_element *))
12695 (scope_level::scope_level(scope_level&&)): New.
12696 (scope_level::~scope_level): New.
12697 (scope_level_s): Delete.
12698 (gdb_xml_parser::scopes): Now a std::vector.
12699 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
12700 Use std::vector.
12701 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
12702 scope cleanup code.
12703 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
12704 of the scopes member. Use std::vector::emplace_back.
12705
12706 2017-04-18 Pedro Alves <palves@redhat.com>
12707
12708 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
12709 a bool.
12710 (gdb_xml_end_element): Change type of first parameter.
12711 (gdb_xml_cleanup): Rename to ...
12712 (gdb_xml_parser::~gdb_xml_parser): ... this.
12713 (gdb_xml_create_parser_and_cleanup): Delete with ...
12714 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
12715 to this new ctor.
12716 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
12717 using gdb_xml_create_parser_and_cleanup.
12718 (xinclude_parsing_data): Add ctor/dtor.
12719 (xml_xinclude_cleanup): Delete.
12720 (xml_process_xincludes): Create a local xinclude_parsing_data
12721 instead of heap-allocating one. Create a local gdb_xml_parser
12722 instead of heap-allocating one with
12723 gdb_xml_create_parser_and_cleanup.
12724
12725 2017-04-18 John Baldwin <jhb@FreeBSD.org>
12726
12727 PR threads/20743
12728 * fbsd-nat.c (resume_one_thread_cb): Remove.
12729 (resume_all_threads_cb): Remove.
12730 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
12731 iterate_over_threads.
12732
12733 2017-04-17 Joel Brobecker <brobecker@adacore.com>
12734
12735 * NEWS: Create a new section for the next release branch.
12736 Rename the section of the current branch, now that it has
12737 been cut.
12738
12739 2017-04-17 Joel Brobecker <brobecker@adacore.com>
12740
12741 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
12742 * version.in: Bump version to 8.0.50.DATE-git.
12743
12744 2017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
12745
12746 PR gdb/21385
12747 * windows-nat.c (windows_create_inferior): Declare 'allargs'
12748 independently of the host, and fix build breakage on Cygwin.
12749
12750 2017-04-13 Pedro Alves <palves@redhat.com>
12751
12752 * inferior.c (free_inferior): Convert to ...
12753 (inferior::~inferior): ... this dtor.
12754 (inferior::inferior): New ctor, factored out from ...
12755 (add_inferior_silent): ... here. Allocate the inferior with a new
12756 expression.
12757 (delete_inferior): Call delete instead of free_inferior.
12758 * inferior.h (gdb_environ, continuation): Forward declare.
12759 (inferior): Now a class. Add in-class initialization to all
12760 members. Make boolean fields bool, except 'detaching'.
12761 (inferior::inferior): New explicit ctor.
12762 (inferior::~inferior): New.
12763
12764 2017-04-13 Pedro Alves <palves@redhat.com>
12765
12766 * inferior.c (init_inferior_list): Delete.
12767 * inferior.h (init_inferior_list): Delete.
12768
12769 2017-04-13 Pedro Alves <palves@redhat.com>
12770
12771 PR threads/13217
12772 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
12773 (top level): Call it twice, with different thread sets.
12774
12775 2017-04-13 Pedro Alves <palves@redhat.com>
12776
12777 * thread.c: Include <algorithm>.
12778 (thread_array_cleanup): Delete.
12779 (scoped_inc_dec_ref): New class.
12780 (live_threads_count): New function.
12781 (set_thread_refcount): Delete.
12782 (tp_array_compar_ascending): Now a bool.
12783 (tp_array_compar): Convert to a std::sort comparison function.
12784 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
12785 and live_threads_count.
12786
12787 2017-04-13 Pedro Alves <palves@redhat.com>
12788
12789 * infrun.c (follow_fork_inferior): Also switch the current
12790 inferior.
12791
12792 2017-04-13 Pedro Alves <palves@redhat.com>
12793
12794 * breakpoint.c (watch_command_1): Save watchpoint-frame info
12795 before calling create_internal_breakpoint.
12796
12797 2017-04-13 Pedro Alves <palves@redhat.com>
12798
12799 * fork-child.c (execv_argv): New class.
12800 (breakup_args): Refactored as ...
12801 (execv_argv::init_for_no_shell): .. this method of execv_argv.
12802 Copy arguments to storage and replace separators with NULL
12803 terminators in place.
12804 (escape_bang_in_quoted_argument): Adjust to return bool.
12805 (execv_argv::execv_argv): New ctor.
12806 (execv_argv::init_for_shell): New method, factored out from
12807 fork_inferior. Don't strdup strings into the vector.
12808 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
12809 Remove free_vector_argv call.
12810
12811 2017-04-13 Yao Qi <yao.qi@linaro.org>
12812
12813 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
12814 tdep->rx_psw_type.
12815
12816 2017-04-13 Yao Qi <yao.qi@linaro.org>
12817
12818 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
12819 * rx-tdep.c (rx_gdbarch_init): Likewise.
12820
12821 2017-04-13 Pedro Alves <palves@redhat.com>
12822
12823 * breakpoint.h (struct breakpoint): Reindent.
12824
12825 2017-04-13 Pedro Alves <palves@redhat.com>
12826
12827 * breakpoint.c (bp_location): Rename to ...
12828 (bp_locations): ... this. All references updated.
12829 (bp_location_count): Rename to ...
12830 (bp_locations_count): ... this. All references updated.
12831 (bp_location_placed_address_before_address_max): Rename to ...
12832 (bp_locations_placed_address_before_address_max): ... this. All
12833 references updated.
12834 (bp_location_shadow_len_after_address_max): Rename to ...
12835 (bp_locations_shadow_len_after_address_max): ... this. All
12836 references updated.
12837 (bp_location_compare_addrs): Rename to ...
12838 (bp_locations_compare_addrs): ... this. All references updated.
12839 (bp_location_compare):Rename to ...
12840 (bp_locations_compare): ... this. All references updated.
12841 (bp_location_target_extensions_update): Rename to ...
12842 (bp_locations_target_extensions_update): ... this. All references
12843 updated.
12844
12845 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
12846
12847 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
12848 * common/common.m4: Check headers 'termios.h', 'termio.h' and
12849 'sgtty.h'.
12850 * common/gdb_termios.h: New file, with parts of "terminal.h".
12851 * inflow.c: Include "gdb_termios.h".
12852 * ser-unix.c: Include "gdb_termios.h".
12853 * terminal.h: Move terminal-related defines to
12854 "common/gdb_termios.h".
12855
12856 2017-04-12 Tom Tromey <tom@tromey.com>
12857
12858 * probe.c (parse_probes): Update.
12859 * location.h (delete_event_location): Don't declare.
12860 (event_location_deleter::operator()): Update.
12861 * location.c (event_location_deleter::operator()): Rename from
12862 delete_event_location.
12863 * linespec.h (linespec_result) <location>: Change type to
12864 event_location_up.
12865 * linespec.c (canonicalize_linespec, event_location_to_sals)
12866 (decode_objc): Update.
12867 (linespec_result): Don't call delete_event_location.
12868 * breakpoint.c (create_breakpoints_sal)
12869 (bkpt_probe_create_sals_from_location)
12870 (strace_marker_create_sals_from_location): Update.
12871
12872 2017-04-12 Tom Tromey <tom@tromey.com>
12873
12874 * linespec.h (struct linespec_result): Add constructor and
12875 destructor.
12876 (init_linespec_result, destroy_linespec_result)
12877 (make_cleanup_destroy_linespec_result): Don't declare.
12878 * linespec.c (init_linespec_result): Remove.
12879 (linespec_result::~linespec_result): Rename from
12880 destroy_linespec_result. Update.
12881 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
12882 Remove.
12883 * breakpoint.c (create_breakpoint, break_range_command)
12884 (decode_location_default): Update.
12885 * ax-gdb.c (agent_command_1): Update.
12886
12887 2017-04-12 Tom Tromey <tom@tromey.com>
12888
12889 * remote.c (remote_download_tracepoint): Update.
12890 * python/py-breakpoint.c (bppy_get_location): Update.
12891 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
12892 (gdbscm_breakpoint_location): Update.
12893 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
12894 * breakpoint.h (struct breakpoint) <location, location_range_end>:
12895 Change type to event_location_up.
12896 * breakpoint.c (create_overlay_event_breakpoint)
12897 (create_longjmp_master_breakpoint)
12898 (create_std_terminate_master_breakpoint)
12899 (create_exception_master_breakpoint)
12900 (breakpoint_event_location_empty_p, print_breakpoint_location)
12901 (print_one_breakpoint_location, create_thread_event_breakpoint)
12902 (init_breakpoint_sal, create_breakpoint)
12903 (print_recreate_ranged_breakpoint, break_range_command)
12904 (init_ada_exception_breakpoint, say_where): Update.
12905 (base_breakpoint_dtor): Don't call delete_event_location.
12906 (bkpt_print_recreate, tracepoint_print_recreate)
12907 (dprintf_print_recreate, update_static_tracepoint)
12908 (breakpoint_re_set_default): Update.
12909
12910 2017-04-12 Tom Tromey <tom@tromey.com>
12911
12912 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
12913 type of "to_do". Update.
12914 (compute_stack_depth): Use std::vector.
12915
12916 2017-04-12 Tom Tromey <tom@tromey.com>
12917
12918 * printcmd.c (find_instruction_backward): Use std::vector.
12919
12920 2017-04-12 Tom Tromey <tom@tromey.com>
12921
12922 * symfile.c (objfilep): Remove typedef.
12923 (reread_symbols): Use a std::vector.
12924
12925 2017-04-12 Tom Tromey <tom@tromey.com>
12926
12927 * mi/mi-main.c (exec_direction_forward): Remove.
12928 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
12929 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
12930 scoped_restore.
12931 * guile/guile.c (guile_repl_command, guile_command)
12932 (gdbscm_execute_gdb_command): Use scoped_restore.
12933 * go-exp.y (go_parse): Use scoped_restore.
12934 * d-exp.y (d_parse): Use scoped_restore.
12935 * cli/cli-decode.c (cmd_func): Use scoped_restore.
12936 * c-exp.y (c_parse): Use scoped_restore.
12937
12938 2017-04-12 Tom Tromey <tom@tromey.com>
12939
12940 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
12941 (mi_parse): Update return type.
12942 (mi_parse_free): Remove.
12943 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
12944 (mi_parse::~mi_parse): Rename from mi_parse_free.
12945 (mi_parse_cleanup): Remove.
12946 (mi_parse): Return a unique_ptr. Use new.
12947 * mi/mi-main.c (mi_execute_command): Update.
12948
12949 2017-04-12 Tom Tromey <tom@tromey.com>
12950
12951 * location.c (explicit_location_lex_one): Return a
12952 unique_xmalloc_ptr.
12953 (string_to_explicit_location): Update. Remove cleanups.
12954
12955 2017-04-12 Tom Tromey <tom@tromey.com>
12956
12957 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
12958 (compare_value_and_voffset): Change type. Update.
12959 (compute_vtable_size): Change type of "offset_vec".
12960 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
12961 (gnuv3_get_typeid): Remove extraneous declaration.
12962
12963 2017-04-12 Tom Tromey <tom@tromey.com>
12964
12965 * charset.h (wchar_iterator): Fix comment.
12966
12967 2017-04-12 Tom Tromey <tom@tromey.com>
12968
12969 * charset.c (iconv_wrapper): New class.
12970 (cleanup_iconv): Remove.
12971 (convert_between_encodings): Use it.
12972
12973 2017-04-12 Tom Tromey <tom@tromey.com>
12974
12975 * symfile.h (increment_reading_symtab): Update type.
12976 * symfile.c (decrement_reading_symtab): Remove.
12977 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
12978 * psymtab.c (psymtab_to_symtab): Update.
12979 * dwarf2read.c (dw2_instantiate_symtab): Update.
12980
12981 2017-04-12 Tom Tromey <tom@tromey.com>
12982
12983 * jit.c (struct jit_reader): Declare separately. Add constructor
12984 and destructor. Change type of "handle".
12985 (loaded_jit_reader): Define separately.
12986 (jit_reader_load): Update. New "new".
12987 (jit_reader_unload_command): Use "delete".
12988 * gdb-dlfcn.h (struct dlclose_deleter): New.
12989 (gdb_dlhandle_up): New typedef.
12990 (gdb_dlopen, gdb_dlsym): Update types.
12991 (gdb_dlclose): Remove.
12992 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
12993 (gdb_dlsym): Change type of "handle".
12994 (make_cleanup_dlclose): Remove.
12995 (dlclose_deleter::operator()): Rename from gdb_dlclose.
12996 * compile/compile-c-support.c (load_libcc): Update.
12997
12998 2017-04-12 Tom Tromey <tom@tromey.com>
12999
13000 * symtab.h (find_pcs_for_symtab_line): Change return type.
13001 * symtab.c (find_pcs_for_symtab_line): Change return type.
13002 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
13003 type of "vec". Update.
13004 (ltpy_get_pcs_for_line): Update.
13005 * linespec.c (decode_digits_ordinary): Update.
13006
13007 2017-04-12 Tom Tromey <tom@tromey.com>
13008
13009 * tracepoint.c (actions_command): Update.
13010 * python/python.c (python_command, python_interactive_command):
13011 Update.
13012 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
13013 * guile/guile.c (guile_command): Update.
13014 * defs.h (read_command_lines, read_command_lines_1): Return
13015 command_line_up.
13016 (command_lines_deleter): New struct.
13017 (command_line_up): New typedef.
13018 * compile/compile.c (compile_code_command)
13019 (compile_print_command): Update.
13020 * cli/cli-script.h (get_command_line, copy_command_lines): Return
13021 command_line_up.
13022 (make_cleanup_free_command_lines): Remove.
13023 * cli/cli-script.c (get_command_line, read_command_lines_1)
13024 (copy_command_lines): Return command_line_up.
13025 (while_command, if_command, read_command_lines, define_command)
13026 (document_command): Update.
13027 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
13028 Remove.
13029 * breakpoint.h (breakpoint_set_commands): Change type of
13030 "commands".
13031 * breakpoint.c (breakpoint_set_commands): Change type of
13032 "commands". Update.
13033 (do_map_commands_command, update_dprintf_command_list)
13034 (create_tracepoint_from_upload): Update.
13035
13036 2017-04-12 Tom Tromey <tom@tromey.com>
13037
13038 * tracepoint.c (scope_info): Update.
13039 * spu-tdep.c (spu_catch_start): Update.
13040 * python/python.c (gdbpy_decode_line): Update.
13041 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
13042 * python/py-breakpoint.c (bppy_init): Update.
13043 * probe.c (parse_probes): Update.
13044 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
13045 * location.h (event_location_deleter): New struct.
13046 (event_location_up): New typedef.
13047 (new_linespec_location, new_address_location, new_probe_location)
13048 (new_explicit_location, copy_event_location)
13049 (string_to_event_location, string_to_event_location_basic)
13050 (string_to_explicit_location): Update return type.
13051 (make_cleanup_delete_event_location): Remove.
13052 * location.c (new_linespec_location, new_address_location)
13053 (new_probe_location, new_explicit_location, copy_event_location):
13054 Return event_location_up.
13055 (delete_event_location_cleanup)
13056 (make_cleanup_delete_event_location): Remove.
13057 (string_to_explicit_location, string_to_event_location_basic)
13058 (string_to_event_location): Return event_location_up.
13059 * linespec.c (canonicalize_linespec, event_location_to_sals)
13060 (decode_line_with_current_source)
13061 (decode_line_with_last_displayed, decode_objc): Update.
13062 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
13063 * completer.c (location_completer): Update.
13064 * cli/cli-cmds.c (edit_command, list_command): Update.
13065 * breakpoint.c (create_overlay_event_breakpoint)
13066 (create_longjmp_master_breakpoint)
13067 (create_std_terminate_master_breakpoint)
13068 (create_exception_master_breakpoint)
13069 (create_thread_event_breakpoint): Update.
13070 (init_breakpoint_sal): Update. Remove some dead code.
13071 (create_breakpoint_sal): Change type of "location". Update.
13072 (create_breakpoints_sal, create_breakpoint, break_command_1)
13073 (dprintf_command, break_range_command, until_break_command)
13074 (init_ada_exception_breakpoint)
13075 (strace_marker_create_sals_from_location)
13076 (update_static_tracepoint, trace_command, ftrace_command)
13077 (strace_command, create_tracepoint_from_upload): Update.
13078 * break-catch-throw.c (re_set_exception_catchpoint): Update.
13079 * ax-gdb.c (agent_command_1): Update.
13080
13081 2017-04-12 Pedro Alves <palves@redhat.com>
13082
13083 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
13084 * configure.tgt: Handle i[34567]86-*-go32* and
13085 i[34567]86-*-msdosdjgpp*.
13086 * i386-tdep.c (i386_svr4_reg_to_regnum):
13087 Make extern.
13088 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
13089 i386-go32-tdep.c.
13090 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
13091 * i386-go32-tdep.c: New file.
13092 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
13093 declarations.
13094
13095 2017-04-12 Simon Marchi <simon.marchi@ericsson.com>
13096
13097 * aix-thread.c (pd_status2str): Change return type to const char *.
13098
13099 2017-04-12 Pedro Alves <palves@redhat.com>
13100
13101 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
13102 calls to set_gdbarch_gnu_triplet_regexp.
13103
13104 2017-04-12 Pedro Alves <palves@redhat.com>
13105
13106 PR gdb/21323
13107 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
13108 New enum value.
13109 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
13110 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
13111 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
13112 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
13113 * gdbarch.h, gdbarch.c: Regenerate.
13114 * aarch64-tdep.c (aarch64_gdbarch_init): Override
13115 gdbarch_wchar_bit and gdbarch_wchar_signed.
13116 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
13117 * arm-tdep.c (arm_gdbarch_init): Likewise.
13118 * avr-tdep.c (avr_gdbarch_init): Likewise.
13119 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
13120 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
13121 * i386-tdep.c (i386_go32_init_abi): Likewise.
13122 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
13123 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
13124 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
13125 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
13126 * sh-tdep.c (sh_gdbarch_init): Likewise.
13127 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
13128 * sparc64-tdep.c (sparc64_init_abi): Likewise.
13129 * windows-tdep.c (windows_init_abi): Likewise.
13130 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
13131
13132 2017-04-12 Pedro Alves <palves@redhat.com>
13133
13134 PR c++/21323
13135 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
13136 cplus_primitive_type_char32_t>: New enum values.
13137 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
13138 and cplus_primitive_type_char32_t.
13139 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
13140 32, use the archtecture's built-in type for char16_t and char32_t,
13141 respectively. Otherwise, fallback to init_integer_type as before,
13142 but make the type unsigned, and issue a complaint.
13143 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
13144
13145 2017-04-12 Alan Hayward <alan.hayward@arm.com>
13146
13147 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
13148 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
13149
13150 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
13151
13152 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
13153 'const char *'.
13154
13155 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
13156
13157 * common/common-utils.c (free_vector_argv): New function.
13158 * common/common-utils.h: Include <vector>.
13159 (free_vector_argv): New prototype.
13160 * darwin-nat.c (darwin_create_inferior): Rewrite function
13161 prototype in order to constify "exec_file" and accept a
13162 "std::string" for "allargs".
13163 * fork-child.c: Include <vector>.
13164 (breakup_args): Rewrite function, using C++.
13165 (fork_inferior): Rewrite function header, constify "exec_file_arg"
13166 and accept "std::string" for "allargs". Update the code to
13167 calculate "argv" based on "allargs". Update calls to "exec_fun"
13168 and "execvp".
13169 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
13170 order to constify "exec_file" and accept a "std::string" for
13171 "allargs".
13172 * go32-nat.c (go32_create_inferior): Likewise.
13173 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
13174 * infcmd.c (run_command_1): Constify "exec_file". Use
13175 "std::string" for inferior arguments.
13176 * inferior.h (fork_inferior): Update prototype.
13177 * linux-nat.c (linux_nat_create_inferior): Rewrite function
13178 prototype in order to constify "exec_file" and accept a
13179 "std::string" for "allargs".
13180 * nto-procfs.c (procfs_create_inferior): Likewise.
13181 * procfs.c (procfs_create_inferior): Likewise.
13182 * remote-sim.c (gdbsim_create_inferior): Likewise.
13183 * remote.c (extended_remote_run): Update code to accept
13184 "std::string" as argument.
13185 (extended_remote_create_inferior): Rewrite function prototype in
13186 order to constify "exec_file" and accept a "std::string" for
13187 "allargs".
13188 * rs6000-nat.c (super_create_inferior): Likewise.
13189 (rs6000_create_inferior): Likewise.
13190 * target.h (struct target_ops) <to_create_inferior>: Likewise.
13191 * windows-nat.c (windows_create_inferior): Likewise.
13192
13193 2017-04-11 Pedro Alves <palves@redhat.com>
13194
13195 * thread.c: Fix whitespace throughout.
13196
13197 2017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
13198
13199 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
13200
13201 2017-04-11 Alan Hayward <alan.hayward@arm.com>
13202
13203 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
13204
13205 2017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
13206
13207 PR gdb/21364
13208 * osdata.c (info_osdata): Check if 'type' is an empty string
13209 instead of NULL.
13210
13211 2017-04-10 Pedro Alves <palves@redhat.com>
13212
13213 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
13214 (ptid_to_global_thread_id, in_thread_list)
13215 (do_captured_list_thread_ids, set_resumed, set_running)
13216 (set_executing, set_stop_requested, finish_thread_state)
13217 (validate_registers_access, can_access_registers_ptid)
13218 (print_thread_info_1, switch_to_thread)
13219 (do_restore_current_thread_cleanup)
13220 (make_cleanup_restore_current_thread, thread_command)
13221 (thread_name_command): Use operator== instead of ptid_equal.
13222
13223 2017-04-10 Pedro Alves <palves@redhat.com>
13224
13225 * thread.c (struct current_thread_cleanup) <next>: Delete field.
13226 (current_thread_cleanup_chain): Delete.
13227 (restore_current_thread_cleanup_dtor)
13228 (make_cleanup_restore_current_thread): Remove references to
13229 current_thread_cleanup_chain.
13230
13231 2017-04-10 Alan Hayward <alan.hayward@arm.com>
13232
13233 * msp430-tdep.c (msp430_pseudo_register_read): Never return
13234 REG_UNKNOWN.
13235
13236 2017-04-10 Yao Qi <yao.qi@linaro.org>
13237
13238 PR gdb/19942
13239 * gdbthread.h (thread_info::deletable): New method.
13240 (thread_info::incref): New method.
13241 (thread_info::decref): New method.
13242 (thread_info::refcount): Move it to private.
13243 * infrun.c (save_stop_context): Call inc_refcount.
13244 (release_stop_context_cleanup): Likewise.
13245 * thread.c (set_thread_exited): New function.
13246 (init_thread_list): Delete "tp" only it is deletable, otherwise
13247 call set_thread_exited.
13248 (delete_thread_1): Call set_thread_exited.
13249 (current_thread_cleanup) <inferior_pid>: Remove.
13250 <thread>: New field.
13251 (restore_current_thread_ptid_changed): Removed.
13252 (do_restore_current_thread_cleanup): Adjust.
13253 (restore_current_thread_cleanup_dtor): Don't call
13254 find_thread_ptid.
13255 (set_thread_refcount): Use dec_refcount.
13256 (make_cleanup_restore_current_thread): Adjust.
13257 (thread_apply_all_command): Call inc_refcount.
13258 (_initialize_thread): Don't call
13259 observer_attach_thread_ptid_changed.
13260
13261 2017-04-10 Yao Qi <yao.qi@linaro.org>
13262
13263 * thread.c (delete_thread_1): Hoist code on marking thread as
13264 exited.
13265
13266 2017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
13267
13268 * windows-nat.c (windows_detach): Initialize ptid with
13269 minus_one_ptid.
13270
13271 2017-04-07 Simon Marchi <simon.marchi@ericsson.com>
13272
13273 * unittests/ptid-selftests.c: Fix erroneous assert messages.
13274
13275 2017-04-07 Alan Hayward <alan.hayward@arm.com>
13276
13277 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
13278 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
13279 (bfin_pseudo_register_write): Likewise
13280
13281 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
13282
13283 * common/ptid.h (struct ptid): Change to...
13284 (class ptid_t): ... this.
13285 <ptid_t>: New constructors.
13286 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
13287 matches>: New methods.
13288 <make_null, make_minus_one>: New static methods.
13289 <pid>: Rename to...
13290 <m_pid>: ...this.
13291 <lwp>: Rename to...
13292 <m_lwp>: ...this.
13293 <tid>: Rename to...
13294 <m_tid>: ...this.
13295 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
13296 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
13297 as references, move comment to class ptid_t.
13298 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
13299 ptid_t static methods.
13300 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
13301 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
13302 Take ptid arguments as references, implement using ptid_t methods.
13303 * unittests/ptid-selftests.c: New file.
13304 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13305 unittests/ptid-selftests.c.
13306 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
13307
13308 2017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
13309
13310 * python/python.c (python_run_simple_file): Cast mode literal to
13311 non-const char pointer as expected by PyFile_FromString.
13312
13313 2017-04-05 Simon Marchi <simon.marchi@ericsson.com>
13314
13315 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
13316 minus_one_ptid and null_ptid.
13317
13318 2017-04-05 Pedro Alves <palves@redhat.com>
13319
13320 * warning.m4 (build_warnings): Remove -Wno-write-strings.
13321 * configure: Regenerate.
13322
13323 2017-04-05 Pedro Alves <palves@redhat.com>
13324
13325 * ada-exp.y (yyerror): Constify.
13326 * ada-lang.c (bound_name, get_selections)
13327 (ada_variant_discrim_type)
13328 (ada_variant_discrim_name, ada_value_struct_elt)
13329 (ada_lookup_struct_elt_type, is_unchecked_variant)
13330 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
13331 (catch_ada_exception_command_split)
13332 (catch_ada_assert_command_split, catch_assert_command)
13333 (ada_op_name): Constify.
13334 * ada-lang.h (ada_yyerror, get_selections)
13335 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
13336 * arc-tdep.c (arc_print_frame_cache): Constify.
13337 * arm-tdep.c (arm_skip_stub): Constify.
13338 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
13339 (gen_aggregate_elt_ref): Constify.
13340 * bcache.c (print_bcache_statistics): Constify.
13341 * bcache.h (print_bcache_statistics): Constify.
13342 * break-catch-throw.c (catch_exception_command_1):
13343 * breakpoint.c (struct ep_type_description::description):
13344 Constify.
13345 (add_solib_catchpoint): Constify.
13346 (catch_fork_command_1): Add cast.
13347 (add_catch_command): Constify.
13348 * breakpoint.h (add_catch_command, add_solib_catchpoint):
13349 Constify.
13350 * bsd-uthread.c (bsd_uthread_state): Constify.
13351 * buildsym.c (patch_subfile_names): Constify.
13352 * buildsym.h (next_symbol_text_func, patch_subfile_names):
13353 Constify.
13354 * c-exp.y (yyerror): Constify.
13355 (token::oper): Constify.
13356 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
13357 * c-varobj.c (cplus_describe_child): Constify.
13358 * charset.c (find_charset_names): Add cast.
13359 (find_charset_names): Constify array and add const_cast.
13360 * cli/cli-cmds.c (complete_command, cd_command): Constify.
13361 (edit_command): Constify.
13362 * cli/cli-decode.c (lookup_cmd): Constify.
13363 * cli/cli-dump.c (dump_memory_command, dump_value_command):
13364 Constify.
13365 (struct dump_context): Constify.
13366 (add_dump_command, restore_command): Constify.
13367 * cli/cli-script.c (get_command_line): Constify.
13368 * cli/cli-script.h (get_command_line): Constify.
13369 * cli/cli-utils.c (check_for_argument): Constify.
13370 * cli/cli-utils.h (check_for_argument): Constify.
13371 * coff-pe-read.c (struct read_pe_section_data): Constify.
13372 * command.h (lookup_cmd): Constify.
13373 * common/print-utils.c (decimal2str): Constify.
13374 * completer.c (gdb_print_filename): Constify.
13375 * corefile.c (set_gnutarget): Constify.
13376 * cp-name-parser.y (yyerror): Constify.
13377 * cp-valprint.c (cp_print_class_member): Constify.
13378 * cris-tdep.c (cris_register_name, crisv32_register_name):
13379 Constify.
13380 * d-exp.y (yyerror): Constify.
13381 (struct token::oper): Constify.
13382 * d-lang.h (d_yyerror): Constify.
13383 * dbxread.c (struct header_file_location::name): Constify.
13384 (add_old_header_file, add_new_header_file, last_function_name)
13385 (dbx_next_symbol_text, add_bincl_to_list)
13386 (find_corresponding_bincl_psymtab, set_namestring)
13387 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
13388 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
13389 * defs.h (command_line_input, print_address_symbolic)
13390 (deprecated_readline_begin_hook): Constify.
13391 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
13392 Constify.
13393 * event-top.c (handle_line_of_input): Constify and add cast.
13394 * exceptions.c (catch_errors): Constify.
13395 * exceptions.h (catch_errors): Constify.
13396 * expprint.c (print_subexp_standard, op_string, op_name)
13397 (op_name_standard, dump_raw_expression, dump_raw_expression):
13398 * expression.h (op_name, op_string, dump_raw_expression):
13399 Constify.
13400 * f-exp.y (yyerror): Constify.
13401 (struct token::oper): Constify.
13402 (struct f77_boolean_val::name): Constify.
13403 * f-lang.c (f_word_break_characters): Constify.
13404 * f-lang.h (f_yyerror): Constify.
13405 * fork-child.c (fork_inferior): Add cast.
13406 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
13407 (new_variant): Constify.
13408 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
13409 * gdbarch.c: Regenerate.
13410 * gdbcore.h (set_gnutarget): Constify.
13411 * go-exp.y (yyerror): Constify.
13412 (token::oper): Constify.
13413 * go-lang.h (go_yyerror): Constify.
13414 * go32-nat.c (go32_sysinfo): Constify.
13415 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
13416 * guile/scm-cmd.c (cmdscm_function): Constify.
13417 * guile/scm-param.c (pascm_param_value): Constify.
13418 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
13419 (h8300sx_register_name): Constify.
13420 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
13421 Constify.
13422 * ia64-tdep.c (ia64_register_names): Constify.
13423 * infcmd.c (construct_inferior_arguments): Constify.
13424 (path_command, attach_post_wait): Constify.
13425 * language.c (show_range_command, show_case_command)
13426 (unk_lang_error): Constify.
13427 * language.h (language_defn::la_error)
13428 (language_defn::la_name_of_this): Constify.
13429 * linespec.c (decode_line_2): Constify.
13430 * linux-thread-db.c (thread_db_err_str): Constify.
13431 * lm32-tdep.c (lm32_register_name): Constify.
13432 * m2-exp.y (yyerror): Constify.
13433 * m2-lang.h (m2_yyerror): Constify.
13434 * m32r-tdep.c (m32r_register_names): Constify and make static.
13435 * m68hc11-tdep.c (m68hc11_register_names): Constify.
13436 * m88k-tdep.c (m88k_register_name): Constify.
13437 * macroexp.c (appendmem): Constify.
13438 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
13439 (upgrade_type, parse_external, parse_partial_symbols)
13440 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
13441 (new_symbol): Constify.
13442 * memattr.c (mem_info_command): Constify.
13443 * mep-tdep.c (register_name_from_keyword): Constify.
13444 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
13445 Constify.
13446 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
13447 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
13448 * mi/mi-main.c (captured_mi_execute_command): Constify and add
13449 cast.
13450 (mi_execute_async_cli_command): Constify.
13451 * mips-tdep.c (mips_register_name): Constify.
13452 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
13453 (am33_register_name, am33_2_register_name)
13454 * moxie-tdep.c (moxie_register_names): Constify.
13455 * nat/linux-osdata.c (osdata_type): Constify fields.
13456 * nto-tdep.c (nto_parse_redirection): Constify.
13457 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
13458 (lookup_child_selector): Constify.
13459 (objc_methcall::name): Constify.
13460 * objc-lang.h (lookup_objc_class, lookup_child_selector)
13461 (lookup_struct_typedef): Constify.
13462 * objfiles.c (pc_in_section): Constify.
13463 * objfiles.h (pc_in_section): Constify.
13464 * p-exp.y (struct token::oper): Constify.
13465 (yyerror): Constify.
13466 * p-lang.h (pascal_yyerror): Constify.
13467 * parser-defs.h (op_name_standard): Constify.
13468 (op_print::string): Constify.
13469 (exp_descriptor::op_name): Constify.
13470 * printcmd.c (print_address_symbolic): Constify.
13471 * psymtab.c (print_partial_symbols): Constify.
13472 * python/py-breakpoint.c (stop_func): Constify.
13473 (bppy_get_expression): Constify.
13474 * python/py-cmd.c (cmdpy_completer::name): Constify.
13475 (cmdpy_function): Constify.
13476 * python/py-event.c (evpy_add_attribute)
13477 (gdbpy_initialize_event_generic): Constify.
13478 * python/py-event.h (evpy_add_attribute)
13479 (gdbpy_initialize_event_generic): Constify.
13480 * python/py-evts.c (add_new_registry): Constify.
13481 * python/py-finishbreakpoint.c (outofscope_func): Constify.
13482 * python/py-framefilter.c (get_py_iter_from_func): Constify.
13483 * python/py-inferior.c (get_buffer): Add cast.
13484 * python/py-param.c (parm_constant::name): Constify.
13485 * python/py-unwind.c (fprint_frame_id): Constify.
13486 * python/python.c (gdbpy_parameter_value): Constify.
13487 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
13488 * remote.c (memory_packet_config::name): Constify.
13489 (show_packet_config_cmd, remote_write_bytes)
13490 (remote_buffer_add_string):
13491 * reverse.c (exec_reverse_once): Constify.
13492 * rs6000-tdep.c (variant::name, variant::description): Constify.
13493 * rust-exp.y (rustyyerror): Constify.
13494 * rust-lang.c (rust_op_name): Constify.
13495 * rust-lang.h (rustyyerror): Constify.
13496 * serial.h (serial_ops::name): Constify.
13497 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
13498 (sh_sh3e_register_name, sh_sh2e_register_name)
13499 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
13500 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
13501 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
13502 (sh_sh4al_dsp_register_name): Constify.
13503 * sh64-tdep.c (sh64_register_name): Constify.
13504 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
13505 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
13506 * stabsread.c (patch_block_stabs, read_type_number)
13507 (ref_map::stabs, ref_add, process_reference)
13508 (symbol_reference_defined, define_symbol, define_symbol)
13509 (error_type, read_type, read_member_functions, read_cpp_abbrev)
13510 (read_one_struct_field, read_struct_fields, read_baseclasses)
13511 (read_tilde_fields, read_struct_type, read_array_type)
13512 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
13513 (read_huge_number, read_range_type, read_args, common_block_start)
13514 (find_name_end): Constify.
13515 * stabsread.h (common_block_start, define_symbol)
13516 (process_one_symbol, symbol_reference_defined, ref_add):
13517 * symfile.c (get_section_index, add_symbol_file_command):
13518 * symfile.h (get_section_index): Constify.
13519 * target-descriptions.c (tdesc_type::name): Constify.
13520 (tdesc_free_type): Add cast.
13521 * target.c (find_default_run_target):
13522 (add_deprecated_target_alias, find_default_run_target)
13523 (target_announce_detach): Constify.
13524 (do_option): Constify.
13525 * target.h (add_deprecated_target_alias): Constify.
13526 * thread.c (print_thread_info_1): Constify.
13527 * top.c (deprecated_readline_begin_hook, command_line_input):
13528 Constify.
13529 (init_main): Add casts.
13530 * top.h (handle_line_of_input): Constify.
13531 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
13532 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
13533 (tfind_command): Rename to ...
13534 (tfind_command_1): ... this and constify.
13535 (tfind_command): New function.
13536 (tfind_end_command, tfind_start_command): Adjust.
13537 (encode_source_string): Constify.
13538 * tracepoint.h (encode_source_string): Constify.
13539 * tui/tui-data.c (tui_partial_win_by_name): Constify.
13540 * tui/tui-data.h (tui_partial_win_by_name): Constify.
13541 * tui/tui-source.c (tui_set_source_content_nil): Constify.
13542 * tui/tui-source.h (tui_set_source_content_nil): Constify.
13543 * tui/tui-win.c (parse_scrolling_args): Constify.
13544 * tui/tui-windata.c (tui_erase_data_content): Constify.
13545 * tui/tui-windata.h (tui_erase_data_content): Constify.
13546 * tui/tui-winsource.c (tui_erase_source_content): Constify.
13547 * tui/tui.c (tui_enable): Add cast.
13548 * utils.c (defaulted_query): Constify.
13549 (init_page_info): Add cast.
13550 (puts_debug, subset_compare): Constify.
13551 * utils.h (subset_compare): Constify.
13552 * varobj.c (varobj_format_string): Constify.
13553 * varobj.h (varobj_format_string): Constify.
13554 * vax-tdep.c (vax_register_name): Constify.
13555 * windows-nat.c (windows_detach): Constify.
13556 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
13557 * xml-support.c (gdb_xml_end_element): Constify.
13558 * xml-tdesc.c (tdesc_start_reg): Constify.
13559 * xstormy16-tdep.c (xstormy16_register_name): Constify.
13560 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
13561 * xtensa-tdep.h (xtensa_register_t::name): Constify.
13562
13563 2017-04-05 Pedro Alves <palves@redhat.com>
13564
13565 * proc-api.c (struct trans): Constify.
13566 (procfs_note): Constify.
13567 * proc-events.c (struct trans, syscall_table):
13568 * proc-flags.c (struct trans): Constify.
13569 * proc-utils.h (procfs_note): Constify.
13570 * proc-why.c (struct trans): Constify.
13571 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
13572 (procfs_detach): Constify.
13573 * sol-thread.c (struct string_map): Constify.
13574 (td_err_string, td_state_string): Constify.
13575
13576 2017-04-05 Pedro Alves <palves@redhat.com>
13577
13578 * proc-api.c (procfs_filename): Don't initialize
13579 procfs_filename.
13580 (prepare_to_trace): Assume procfs_filename is non-NULL.
13581 (_initialize_proc_api): Give procfs_filename a default value here.
13582
13583 2017-04-05 Pedro Alves <palves@redhat.com>
13584
13585 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
13586 'cond_string' parameter.
13587 (extract_exception_regexp): Constify 'string' parameter.
13588 (catch_exception_command_1): Constify.
13589 * breakpoint.c (init_catchpoint)
13590 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
13591 parameter.
13592 (ep_parse_optional_if_clause, catch_fork_command_1)
13593 (catch_exec_command_1): Constify.
13594 * breakpoint.h (init_catchpoint): Constify 'cond_string'
13595 parameter.
13596 (ep_parse_optional_if_clause): Constify.
13597 * cli/cli-utils.c (remove_trailing_whitespace)
13598 (check_for_argument): Constify.
13599 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
13600 non-const overload.
13601 (check_for_argument): Likewise.
13602
13603 2017-04-05 Pedro Alves <palves@redhat.com>
13604
13605 * event-top.c (command_line_handler): Add cast to execute_command
13606 call.
13607 * record-btrace.c (cmd_record_btrace_bts_start)
13608 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
13609 (cmd_record_btrace_start): Add cast to execute_command call.
13610 * record-full.c (record_full_goto_insn):
13611 * record.c (record_start, record_stop): Add cast to
13612 execute_command_to_string calls.
13613 (cmd_record_start): Add cast to execute_command calls.
13614
13615 2017-04-05 Pedro Alves <palves@redhat.com>
13616
13617 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
13618 static inline function.
13619 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
13620 array and use gdb_PyArg_ParseTupleAndKeywords.
13621 * python/py-cmd.c (cmdpy_init): Likewise.
13622 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
13623 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
13624 (infpy_search_memory): Likewise.
13625 * python/py-objfile.c (objfpy_add_separate_debug_file)
13626 (gdbpy_lookup_objfile): Likewise.
13627 * python/py-symbol.c (gdbpy_lookup_symbol)
13628 (gdbpy_lookup_global_symbol): Likewise.
13629 * python/py-type.c (gdbpy_lookup_type): Likewise.
13630 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
13631 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
13632 Likewise.
13633
13634 2017-04-05 Pedro Alves <palves@redhat.com>
13635
13636 * python/python-internal.h (gdb_PyGetSetDef): New type.
13637 * python/py-block.c (block_object_getset)
13638 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
13639 * python/py-event.c (event_object_getset)
13640 (finish_breakpoint_object_getset): Likewise.
13641 * python/py-inferior.c (inferior_object_getset): Likewise.
13642 * python/py-infthread.c (thread_object_getset): Likewise.
13643 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
13644 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
13645 * python/py-objfile.c (objfile_getset): Likewise.
13646 * python/py-progspace.c (pspace_getset): Likewise.
13647 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
13648 Likewise.
13649 * python/py-record.c (recpy_record_getset): Likewise.
13650 * python/py-symbol.c (symbol_object_getset): Likewise.
13651 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
13652 Likewise.
13653 * python/py-type.c (type_object_getset, field_object_getset):
13654 Likewise.
13655 * python/py-value.c (value_object_getset): Likewise.
13656
13657 2017-04-05 Pedro Alves <palves@redhat.com>
13658
13659 * python/python-internal.h (gdb_PyObject_CallMethod)
13660 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
13661 New functions.
13662 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
13663 (PySys_GetObject, PySys_SetPath): New macros.
13664
13665 2017-04-05 Pedro Alves <palves@redhat.com>
13666
13667 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
13668 info_osdata_command.
13669 * osdata.c (info_osdata_command): Rename to ...
13670 (info_osdata): ... this. Constify 'type' parameter, and remove
13671 the 'from_tty' parameter. Accept NULL TYPE.
13672 (info_osdata_command): New function.
13673 * osdata.h (info_osdata_command): Remove declaration.
13674 (info_osdata): New declaration.
13675
13676 2017-04-05 Pedro Alves <palves@redhat.com>
13677
13678 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
13679 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
13680 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
13681 parameter.
13682 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
13683 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
13684 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
13685 parameter.
13686 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
13687 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
13688 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
13689 (mi_cmd_file_list_exec_source_files)
13690 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
13691 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
13692 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
13693 parameter.
13694 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
13695 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
13696 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
13697 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
13698 (mi_cmd_stack_info_frame): Constify 'command' parameter.
13699 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
13700 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
13701 'command' parameter.
13702 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
13703 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
13704 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
13705 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
13706 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
13707 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
13708 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
13709 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
13710 (mi_cmd_var_set_update_range): Constify 'command' parameter.
13711 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
13712 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
13713 parameter.
13714 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
13715 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
13716 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
13717 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
13718 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
13719 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
13720 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
13721 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
13722 (mi_cmd_data_list_changed_registers)
13723 (mi_cmd_data_write_register_values)
13724 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
13725 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
13726 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
13727 (mi_cmd_list_features, mi_cmd_list_target_features)
13728 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
13729 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
13730 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
13731 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
13732 (mi_cmd_trace_frame_collected): Constify 'command'
13733 parameter.
13734 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
13735 'command' parameter.
13736
13737 2017-04-05 Pedro Alves <palves@redhat.com>
13738
13739 * ada-lang.c (ada_completer_word_break_characters): Now a const
13740 array.
13741 (ada_get_gdb_completer_word_break_characters): Constify.
13742 * completer.c (gdb_completer_command_word_break_characters)
13743 (gdb_completer_file_name_break_characters)
13744 (gdb_completer_quote_characters): Now const arrays.
13745 (get_gdb_completer_quote_characters): Constify.
13746 (set_rl_completer_word_break_characters): New function.
13747 (set_gdb_completion_word_break_characters)
13748 (complete_line_internal): Use it.
13749 * completer.h (get_gdb_completer_quote_characters): Constify.
13750 (set_rl_completer_word_break_characters): Declare.
13751 * f-lang.c (f_word_break_characters): Constify.
13752 * language.c (default_word_break_characters): Constify.
13753 * language.h (language_defn::la_word_break_characters): Constify.
13754 (default_word_break_characters): Constify.
13755 * top.c (init_main): Use set_rl_completer_word_break_characters.
13756
13757 2017-04-05 Pedro Alves <palves@redhat.com>
13758
13759 * aix-thread.c (aix_thread_pid_to_str)
13760 (aix_thread_extra_thread_info): Constify.
13761 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
13762 * bsd-uthread.c (bsd_uthread_extra_thread_info)
13763 (bsd_uthread_pid_to_str): Constify.
13764 * corelow.c (core_pid_to_str): Constify.
13765 * darwin-nat.c (darwin_pid_to_str): Constify.
13766 * fbsd-nat.c (fbsd_pid_to_str): Constify.
13767 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
13768 Constify.
13769 * gnu-nat.c (gnu_pid_to_str): Constify.
13770 * go32-nat.c (go32_pid_to_str): Constify.
13771 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
13772 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
13773 * inferior.c (inferior_pid_to_str): Constify.
13774 * linux-nat.c (linux_nat_pid_to_str): Constify.
13775 * linux-tdep.c (linux_core_pid_to_str): Constify.
13776 * linux-thread-db.c (thread_db_pid_to_str)
13777 (thread_db_extra_thread_info): Constify.
13778 * nto-tdep.c (nto_extra_thread_info): Constify.
13779 * nto-tdep.h (nto_extra_thread_info): Constify.
13780 * obsd-nat.c (obsd_pid_to_str): Constify.
13781 * procfs.c (procfs_pid_to_str): Constify.
13782 * ravenscar-thread.c (ravenscar_extra_thread_info)
13783 (ravenscar_pid_to_str): Constify.
13784 * remote-sim.c (gdbsim_pid_to_str): Constify.
13785 * remote.c (remote_threads_extra_info, remote_pid_to_str):
13786 Constify.
13787 * sol-thread.c (solaris_pid_to_str): Constify.
13788 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
13789 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
13790 * target.c (default_pid_to_str, target_pid_to_str)
13791 (normal_pid_to_str, default_pid_to_str): Constify.
13792 * target.h (target_ops::to_pid_to_str)
13793 (target_ops::to_extra_thread_info): Constify.
13794 (target_pid_to_str, normal_pid_to_str): Constify.
13795 * windows-nat.c (windows_pid_to_str): Constify.
13796 * gdbarch.sh (core_pid_to_str): Constify.
13797 * target-delegates.c: Regenerate.
13798 * gdbarch.h, gdbarch.c: Regenerate.
13799
13800 2017-04-05 Pedro Alves <palves@redhat.com>
13801
13802 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
13803 the memory of the temporary warning_pre_print override.
13804 * utils.c (warning_pre_print): Constify.
13805 * utils.h (warning_pre_print): Constify.
13806
13807 2017-04-05 Pedro Alves <palves@redhat.com>
13808
13809 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
13810 (shell_command): New function.
13811 (make_command): Use std::string.
13812 (init_cli_cmds): Register shell_command instead of shell_escape.
13813
13814 2017-04-05 Pedro Alves <palves@redhat.com>
13815
13816 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
13817 * tracepoint.c (default_collect): Don't initialize.
13818
13819 2017-04-05 Pedro Alves <palves@redhat.com>
13820
13821 * macroexp.c (macro_buffer::shared): Now a bool.
13822 (init_buffer): Update.
13823 (init_shared_buffer): Constify 'addr' parameter.
13824 (substitute_args, expand, macro_expand, macro_expand_next): Remove
13825 casts.
13826
13827 2017-04-05 Pedro Alves <palves@redhat.com>
13828
13829 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
13830 * disasm.c (set_disassembler_options): Constify local.
13831 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
13832
13833 2017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
13834
13835 PR gdb/21352
13836 * tracefile.c (tsave_command): Fix argument parsing for '-r'
13837 option.
13838
13839 2017-04-05 Yao Qi <yao.qi@linaro.org>
13840
13841 * frame.c (frame_unwind_register_unsigned): Call
13842 frame_unwind_register_value.
13843
13844 2017-04-05 Yao Qi <yao.qi@linaro.org>
13845
13846 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
13847 Use gdb_test_multiple, and don't match anchor.
13848
13849 2017-04-05 Pedro Alves <palves@redhat.com>
13850
13851 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
13852 (Write After Approval): Remove Simon Marchi.
13853
13854 2017-04-05 Pedro Alves <palves@redhat.com>
13855
13856 * common/gdb_optional.h (optional::optional): Make constexpr and
13857 initialize m_dummy.
13858
13859 2017-04-04 John Baldwin <jhb@FreeBSD.org>
13860
13861 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
13862 (amd64fbsd_jmp_buf_reg_offset): Remove.
13863 (amd64fbsd_supply_uthread): Remove function.
13864 (amd64fbsd_collect_uthread): Remove function.
13865 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
13866 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
13867 (x86_64-*-freebsd*): Remove bsd-uthread.o.
13868 (fbsd-nat.c): Update comment.
13869 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
13870 (i386fbsd_jmp_buf_reg_offset): Remove.
13871 (i386fbsd_supply_uthread): Remove function.
13872 (i386fbsd_collect_uthread): Remove function.
13873 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
13874
13875 2017-04-04 John Baldwin <jhb@FreeBSD.org>
13876
13877 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
13878 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
13879 * NEWS: Mention that support for FreeBSD/alpha was removed.
13880 * alpha-fbsd-tdep.c: Delete file.
13881 * config/alpha/fbsd.mh: Delete file.
13882 * configure.host: Delete alpha*-*-freebsd* and
13883 alpha*-*-kfreebsd*-gnu.
13884 * configure.tgt: Delete alpha*-*-freebsd* and
13885 alpha*-*-kfreebsd*-gnu.
13886
13887 2017-04-04 John Baldwin <jhb@FreeBSD.org>
13888
13889 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
13890 amd64bsd_store_inferior_registers): Use ptid from regcache.
13891
13892 2017-04-04 Pedro Alves <palves@redhat.com>
13893
13894 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
13895 data fields, make them private and add "m_" prefixes.
13896 (lnp_state_machine::lnp_state_machine): New ctor.
13897 (record_line, check_line_address, handle_set_discriminator)
13898 (handle_set_address, handle_advance_pc, handle_special_opcode)
13899 (handle_advance_line, handle_set_file, handle_negate_stmt)
13900 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
13901 (end_sequence, advance_line): New methods.
13902 (m_gdbarch, m_record_lines_p): New fields.
13903 (lnp_reader_state): Delete.
13904 (dwarf_record_line): Rename to ...
13905 (lnp_state_machine::record_line): ... adjust.
13906 (init_lnp_state_machine): Delete.
13907 (lnp_state_machine::lnp_state_machine): New.
13908 (check_line_address): Rename to ...
13909 (lnp_state_machine::check_line_address): This.
13910 (dwarf_decode_lines_1): Remove reference to "reader_state".
13911 Adjust lnp_state_machine having a non-default ctor. Use bool.
13912 State machine internal state manipulation moved to
13913 lnp_state_machine methods.
13914
13915 2017-04-04 Pedro Alves <palves@redhat.com>
13916
13917 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13918 unittests/offset-type-selftests.c.
13919 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
13920 * common/offset-type.h: New file.
13921 * common/preprocessor.h: New file.
13922 * common/traits.h: New file.
13923 * common/valid-expr.h: New file.
13924 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
13925 sect_offset and cu_offset strong typedefs throughout.
13926 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
13927 typedefs throughout.
13928 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
13929 sect_offset and cu_offset strong typedefs throughout.
13930 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
13931 typedefs throughout.
13932 * gdbtypes.h: Include "common/offset-type.h".
13933 (cu_offset): Now an offset type (strong typedef) instead of a
13934 struct.
13935 (sect_offset): Likewise.
13936 (union call_site_parameter_u): Rename "param_offset" field to
13937 "param_cu_off".
13938 * unittests/offset-type-selftests.c: New file.
13939
13940 2017-04-04 Pedro Alves <palves@redhat.com>
13941
13942 * common/underlying.h: New file.
13943 * dwarf2read.c: Include "common/gdb_optional.h" and
13944 "common/underlying.h".
13945 (dir_index, file_name_index): New types.
13946 (file_entry): Use them.
13947 (file_entry::include): Use to_underlying.
13948 (line_header::add_file_name): Use dir_index.
13949 (read_formatted_entries): Use gdb::optional. Read form before
13950 writting to file_entry.
13951 (dwarf_decode_line_header): Use dir_index.
13952 (lnp_state_machine::current_file): Use to_underlying.
13953 (lnp_state_machine::file): Change type to file_name_index.
13954 (dwarf_record_line): Use to_underlying.
13955 (init_lnp_state_machine): Use file_name_index.
13956 (dwarf_decode_lines_1): Use dir_index and file_name_index.
13957
13958 2017-04-04 Pedro Alves <palves@redhat.com>
13959
13960 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
13961 operator bool, has_value and get methods.
13962
13963 2017-04-04 Pedro Alves <palves@redhat.com>
13964
13965 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
13966 fields.
13967 (line_header): Initialize all data fields. Change type of
13968 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
13969 Change type of include_dirs to std::vector<const char *>. Remove
13970 num_include_dirs, include_dirs_size. Change type of file_names to
13971 std::vector<file_entry>. Remove num_file_names, file_names_size.
13972 (line_header::line_header): New.
13973 (line_header::add_include_dir, line_header::add_file_name): New
13974 methods.
13975 (line_header::include_dir_at): Remove NULL check.
13976 (line_header::file_name_at): Add const overload.
13977 (line_header_up): New unique_ptr typedef.
13978 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
13979 std::vector. Remove free_line_header call.
13980 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
13981 free_line_header call.
13982 (free_cu_line_header): Delete.
13983 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
13984 (setup_type_unit_groups): Use line_header_up instead of cleanups.
13985 Adjust to use std::vector.
13986 (free_line_header): Delete.
13987 (free_line_header_voidp): Use delete.
13988 (add_include_dir): Replace with ...
13989 (line_header::add_include_dir): ... this method. Use std::vector.
13990 (add_file_name): Replace with ...
13991 (line_header::add_file_name): ... this method. Use std::vector.
13992 (add_include_dir_stub): Delete.
13993 (read_formatted_entries): Remove memset.
13994 (dwarf_decode_line_header): Return a line_header_up instead of a
13995 raw pointer. Remove cleanup handling. Pass lambdas to
13996 read_formatted_entries. Adjust to use line_header methods.
13997 (dwarf_decode_lines_1): Adjust to use line_header methods.
13998 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
13999 use std::vector.
14000
14001 2017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
14002
14003 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
14004 instead of struct ptid.
14005
14006 2017-05-04 Alan Hayward <alan.hayward@arm.com>
14007
14008 * frame.c (get_frame_register_bytes): Unwind using value.
14009 (put_frame_register_bytes): Likewise.
14010
14011 2017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
14012
14013 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
14014 aggregate-like.
14015
14016 2017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
14017
14018 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
14019
14020 2017-03-29 Yao Qi <yao.qi@linaro.org>
14021
14022 * gdbthread.h (struct thread_info): Declare constructor and
14023 destructor. Add some in-class member initializers.
14024 * thread.c (free_thread): Remove.
14025 (init_thread_list): Call delete instead of free_thread.
14026 (new_thread): Call thread_info constructor.
14027 (thread_info::thread_info): New function.
14028 (thread_info::~thread_info): New function.
14029 (delete_thread_1): Call delete instead of free_thread.
14030 (make_cleanup_restore_current_thread): Move tp and frame to
14031 inner block.
14032
14033 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
14034
14035 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
14036 (arc_skip_prologue): Likewise.
14037 (arc_make_frame_cache): Likewise.
14038 (arc_pv_get_operand): New function.
14039 (arc_is_in_prologue): Likewise.
14040 (arc_analyze_prologue): Likewise.
14041 (arc_print_frame_cache): Likewise.
14042 (MAX_PROLOGUE_LENGTH): New constant.
14043
14044 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
14045
14046 * configure.tgt: Add arc-insn.o.
14047 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
14048 (dump_arc_instruction_command): New function.
14049 (arc_fprintf_disasm): Likewise.
14050 (arc_disassemble_info): Likewise.
14051 (arc_insn_get_operand_value): Likewise.
14052 (arc_insn_get_operand_value_signed): Likewise.
14053 (arc_insn_get_memory_base_reg): Likewise.
14054 (arc_insn_get_memory_offset): Likewise.
14055 (arc_insn_get_branch_target): Likewise.
14056 (arc_insn_dump): Likewise.
14057 (arc_insn_get_linear_next_pc): Likewise.
14058 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
14059 (arc_disassemble_info): Likewise.
14060 (arc_insn_get_branch_target): Likewise.
14061 (arc_insn_get_linear_next_pc): Likewise.
14062 * NEWS: Mention new "maint print arc arc-instruction".
14063
14064 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
14065
14066 * arc-tdep (maintenance_print_arc_list): New variable.
14067 (maintenance_print_arc_command): New function.
14068
14069 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
14070
14071 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
14072 Add "limm" and "reserved".
14073 (arc_cannot_fetch_register, arc_cannot_store_register): Add
14074 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
14075 * arc-tdep.h (arc_regnum): Likewise.
14076
14077 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14078
14079 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
14080 for THREADPTR register.
14081 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
14082 register.
14083 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
14084 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
14085 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
14086
14087 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14088
14089 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
14090 registers above gdbarch_num_regs (gdbarch) as privileged in
14091 call0 ABI.
14092
14093 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14094
14095 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
14096 for a single specified register or for all registers in
14097 a0_base..a0_base + C0_NREGS range.
14098 (supply_gregset_reg): Call regcache_raw_supply for a single
14099 specified register or for all registers in a0_base..a0_base +
14100 C0_NREGS range.
14101
14102 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14103
14104 * arch/xtensa.h (C0_NREGS): Add definition.
14105 * xtensa-tdep.c (C0_NREGS): Remove definition.
14106
14107 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14108
14109 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
14110 Drop xtensa_default_isa initialization.
14111 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
14112
14113 2017-03-27 Pedro Alves <palves@redhat.com>
14114
14115 * dwarf2read.c (file_entry) <dir_index>: Add comment.
14116 (file_entry::include_dir): New method.
14117 (line_header::include_dir_at, line_header::file_name_at): New
14118 methods.
14119 (setup_type_unit_groups, setup_type_unit_groups)
14120 (psymtab_include_file_name): Simplify using the new methods.
14121 (lnp_state_machine) <the_line_header>: New field.
14122 <file>: Add comment.
14123 (lnp_state_machine::current_file): New method.
14124 (dwarf_record_line): Simplify using the new methods.
14125 (init_lnp_state_machine): Initialize the "the_line_header" field.
14126 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
14127 Simplify using the new methods.
14128
14129 2017-03-27 Pedro Alves <palves@redhat.com>
14130
14131 * cp-name-parser.y (make_empty): Delete.
14132 (demangler_special, nested_name, ptr_operator, array_indicator)
14133 (direct_declarator, declarator_1): Use fill_comp instead of
14134 make_empty.
14135
14136 2017-03-27 Pedro Alves <palves@redhat.com>
14137
14138 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
14139 to ATTRIBUTE_PRINTF.
14140 * solib-target.c (library_list_start_list): Print "string" not
14141 "version".
14142 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
14143 gdb_xml_error call.
14144
14145 2017-03-27 Pedro Alves <palves@redhat.com>
14146
14147 * dwarf2read.c (struct file_and_directory): New.
14148 (dwarf2_get_dwz_file): Adjust to use std::string.
14149 (dw2_get_file_names_reader): Adjust to use file_and_directory.
14150 (find_file_and_directory): Adjust to return a file_and_directory
14151 object.
14152 (read_file_scope): Adjust to use file_and_directory. Remove
14153 make_cleanup/do_cleanups calls.
14154 (open_and_init_dwp_file): Adjust to use std::string. Remove
14155 make_cleanup/do_cleanups calls.
14156 * python/python.c (do_start_initialization): Adjust to ldirname
14157 returning a std::string.
14158 * utils.c (ldirname): Now returns a std::string.
14159 * utils.h (ldirname): Change return type to std::string.
14160 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
14161 returning a std::string.
14162 * xml-tdesc.c (file_read_description_xml): Likewise.
14163
14164 2017-03-24 Alan Hayward <alan.hayward@arm.com>
14165
14166 * regcache.c (regcache_debug_print_register): New function.
14167 * regcache.h (regcache_debug_print_register): New declaration.
14168 * target.c (debug_print_register): Remove.
14169 (target_fetch_registers): Call regcache_debug_print_register.
14170 (target_store_registers): Likewise.
14171
14172 2017-03-24 Pádraig Brady <pbrady@fb.com>
14173
14174 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
14175 reference beyond the 'lh->include_dirs' array before accessing to
14176 it.
14177 (psymtab_include_file_name): Likewise.
14178 (dwarf_decode_lines_1): Likewise.
14179 (dwarf_decode_lines): Likewise.
14180 (file_file_name): Likewise.
14181
14182 2017-03-23 Simon Marchi <simon.marchi@ericsson.com>
14183
14184 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
14185 inferior_ptid.
14186 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
14187 ps_lsetfpregs): Likewise.
14188 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
14189 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
14190 ps_lsetfpregs): Likewise.
14191 * target.c (target_fetch_registers, target_store_registers):
14192 Remove asserts.
14193
14194 2017-03-23 Alan Hayward <alan.hayward@arm.com>
14195
14196 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
14197
14198 2017-03-23 Yao Qi <yao.qi@linaro.org>
14199
14200 * aarch64-tdep.c (aarch64_process_record_test): Declare.
14201 (_initialize_aarch64_tdep): Register it.
14202 (aarch64_record_load_store): Handle PRFM instruction.
14203 (aarch64_process_record_test): New function.
14204
14205 2017-03-23 Yao Qi <yao.qi@linaro.org>
14206
14207 * aarch64-tdep.c (aarch64_record_load_store): Fix code
14208 indentation.
14209
14210 2017-03-23 Yao Qi <yao.qi@linaro.org>
14211
14212 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
14213
14214 2017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
14215
14216 python/python.c (do_start_initialization): Fix memory leak.
14217
14218 2017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
14219
14220 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
14221 using get_ptrace_pid.
14222 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
14223 inferior_ptid.
14224 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
14225 inferior_ptid instead of pid.
14226
14227 2017-03-22 Yao Qi <yao.qi@linaro.org>
14228
14229 * aarch64-tdep.c: Wrap locally used classes in anonymous
14230 namespace.
14231 * arm-tdep.c: Likewise.
14232 * linespec.c: Likewise.
14233 * ui-out.c: Likewise.
14234
14235 2017-03-22 Jonah Graham <jonah@kichwacoders.com>
14236
14237 PR gdb/19637
14238 * python/lib/gdb/printer/bound_registers.py: Import sys.
14239
14240 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
14241
14242 * windows-nat.c (do_windows_fetch_inferior_registers): Add
14243 windows_thread_info parameter and use it instead of
14244 current_thread.
14245 (windows_fetch_inferior_registers): Don't set current_thread,
14246 pass the thread to do_windows_fetch_inferior_registers. Use
14247 ptid from regcache instead of inferior_ptid.
14248 (do_windows_store_inferior_registers): Add windows_thread_info
14249 parameter and use it instead of current_thread.
14250 (windows_store_inferior_registers): Don't set current_thread,
14251 pass the thread to do_windows_store_inferior_registers. Use
14252 ptid from regcache instead of inferior_ptid.
14253
14254 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
14255
14256 * ser-mingw.c (ser_windows_raw): Remove reference to
14257 struct serial::current_timeout.
14258
14259 2017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
14260
14261 PR tdep/20928
14262 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
14263 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
14264 (sparc64_fsr_type): Fix %fsr decoding.
14265
14266 2017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
14267
14268 * python/py-record-btrace.c (btpy_insn_data): Change return type
14269 for Python 2.
14270
14271 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
14272
14273 * spu-linux-nat.c (spu_fetch_inferior_registers,
14274 spu_store_inferior_registers): Use ptid from regcache, set and
14275 restore inferior_ptid.
14276 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
14277 Likewise.
14278
14279 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
14280
14281 * i386-linux-nat.c (fetch_register, store_register,
14282 i386_linux_fetch_inferior_registers,
14283 i386_linux_store_inferior_registers): Use ptid from regcache.
14284 * ia64-linux-nat.c (ia64_linux_fetch_register,
14285 ia64_linux_store_register): Likewise.
14286 * inf-ptrace.c (inf_ptrace_fetch_register,
14287 inf_ptrace_store_register): Likewise.
14288 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
14289 m32r_linux_store_inferior_registers): Likewise.
14290 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
14291 m68kbsd_store_inferior_registers): Likewise.
14292 * m68k-linux-nat.c (fetch_register, store_register,
14293 m68k_linux_fetch_inferior_registers,
14294 m68k_linux_store_inferior_registers): Likewise.
14295 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
14296 m88kbsd_store_inferior_registers): Likewise.
14297 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
14298 mips_fbsd_store_inferior_registers): Likewise.
14299 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
14300 mips64_linux_regsets_store_registers): Likewise.
14301 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
14302 mipsnbsd_store_inferior_registers): Likewise.
14303 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
14304 mips64obsd_store_inferior_registers): Likewise.
14305 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
14306 Likewise.
14307 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
14308 ppcfbsd_store_inferior_registers): Likewise.
14309 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
14310 ppc_linux_store_inferior_registers): Likewise.
14311 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
14312 ppcnbsd_store_inferior_registers): Likewise.
14313 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
14314 ppcobsd_store_registers): Likewise.
14315 * procfs.c (procfs_fetch_registers, procfs_store_registers):
14316 Likewise.
14317 * ravenscar-thread.c (ravenscar_fetch_registers,
14318 ravenscar_store_registers, ravenscar_prepare_to_store):
14319 Likewise.
14320 * record-btrace.c (record_btrace_fetch_registers,
14321 record_btrace_store_registers, record_btrace_prepare_to_store):
14322 Likewise.
14323 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
14324 Lookup inferior using ptid from regcache, instead of
14325 current_inferior.
14326 * remote.c (remote_fetch_registers, remote_store_registers): Use
14327 ptid from regcache.
14328 * rs6000-nat.c (fetch_register, store_register): Likewise.
14329 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
14330 s390_linux_store_inferior_registers): Likewise.
14331 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
14332 shnbsd_store_inferior_registers): Likewise.
14333 * sol-thread.c (sol_thread_fetch_registers,
14334 sol_thread_store_registers): Likewise.
14335 * sparc-nat.c (sparc_fetch_inferior_registers,
14336 sparc_store_inferior_registers): Likewise.
14337 * tilegx-linux-nat.c (fetch_inferior_registers,
14338 store_inferior_registers): Likewise.
14339 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
14340 vaxbsd_store_inferior_registers): Likewise.
14341 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
14342 store_xtregs): Likewise.
14343
14344 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14345
14346 PR gdb/14441
14347 * NEWS: Mention support for rvalue references in GDB and python.
14348 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
14349 supports both lvalue and rvalue references.
14350
14351 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14352
14353 PR gdb/14441
14354 * gdbtypes.c (rank_one_type): Implement overloading
14355 resolution rules regarding rvalue references.
14356
14357 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14358
14359 PR gdb/14441
14360 * aarch64-tdep.c (aarch64_type_align)
14361 (aarch64_extract_return_value, aarch64_store_return_value): Change
14362 lvalue reference type checks to general reference type checks.
14363 * amd64-tdep.c (amd64_classify): Likewise.
14364 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
14365 Likewise.
14366 * arm-tdep.c (arm_type_align, arm_extract_return_value)
14367 (arm_store_return_value): Likewise.
14368 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
14369 * c-typeprint.c (c_print_type): Likewise.
14370 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
14371 (cplus_number_of_children, cplus_describe_child): Likewise.
14372 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
14373 * completer.c (expression_completer): Likewise.
14374 * cp-support.c (make_symbol_overload_list_adl_namespace):
14375 Likewise.
14376 * darwin-nat-info.c (info_mach_region_command): Likewise.
14377 * dwarf2loc.c (entry_data_value_coerce_ref)
14378 (value_of_dwarf_reg_entry): Likewise.
14379 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
14380 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
14381 Likewise.
14382 * findvar.c (extract_typed_address, store_typed_address):
14383 Likewise.
14384 * gdbtypes.c (rank_one_type): Likewise.
14385 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
14386 * infcall.c (value_arg_coerce): Likewise.
14387 * language.c (pointer_type): Likewise.
14388 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
14389 Likewise.
14390 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
14391 * mn10300-tdep.c (mn10300_type_align): Likewise.
14392 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
14393 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
14394 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
14395 Likewise.
14396 * printcmd.c (print_formatted, x_command): Likewise.
14397 * python/py-type.c (typy_get_composite, typy_template_argument):
14398 Likewise.
14399 * python/py-value.c (valpy_referenced_value)
14400 (valpy_get_dynamic_type, value_has_field): Likewise.
14401 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
14402 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
14403 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
14404 * spu-tdep.c (spu_scalar_value_p): Likewise.
14405 * symtab.c (lookup_symbol_aux): Likewise.
14406 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
14407 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
14408 Likewise.
14409 * valops.c (value_cast_pointers, value_cast)
14410 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
14411 (value_struct_elt, value_struct_elt_bitpos)
14412 (value_find_oload_method_list, find_overload_match)
14413 (value_rtti_indirect_type): Likewise.
14414 * valprint.c (val_print_scalar_type_p, generic_val_print):
14415 Likewise.
14416 * value.c (value_actual_type, value_as_address, unpack_long)
14417 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
14418 (coerce_ref): Likewise.
14419 * varobj.c (varobj_get_value_type): Likewise.
14420
14421 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14422
14423 PR gdb/14441
14424 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
14425 table of constants.
14426 * python/lib/gdb/command/explore.py: Support exploring values
14427 of rvalue reference types.
14428 * python/lib/gdb/types.py: Implement get_basic_type() for
14429 rvalue reference types.
14430 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
14431 constant.
14432 * python/py-value.c (valpy_getitem): Add an rvalue reference
14433 check.
14434 (valpy_reference_value): Add new parameter "refcode".
14435 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
14436 New wrappers for valpy_reference_value().
14437 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
14438 (gdbpy_invoke_xmethod): Likewise.
14439
14440 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14441
14442 PR gdb/14441
14443 * dwarf2read.c (process_die, read_type_die_1): Handle the
14444 DW_TAG_rvalue_reference_type DIE.
14445 (read_tag_reference_type): Add new parameter "refcode".
14446
14447 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14448
14449 PR gdb/14441
14450 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
14451 (c_type_print_modifier, c_type_print_varspec_suffix)
14452 (c_type_print_base): Support printing rvalue reference types.
14453 * c-valprint.c (c_val_print, c_value_print): Support printing
14454 rvalue reference values.
14455
14456 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14457
14458 PR gdb/14441
14459 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
14460 typename.
14461 * cp-support.c (replace_typedefs): Handle
14462 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
14463 * python/py-type.c (typy_lookup_type): Likewise.
14464
14465 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14466
14467 PR gdb/14441
14468 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
14469 * parse.c (insert_type): Change assert statement.
14470 (follow_types): Handle rvalue reference types.
14471 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
14472 constant.
14473
14474 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14475
14476 PR gdb/14441
14477 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
14478 value_ref() interface.
14479 * c-valprint.c (c_value_print): Likewise.
14480 * infcall.c (value_arg_coerce): Likewise.
14481 * python/py-value.c (valpy_reference_value): Likewise.
14482 * valops.c (value_cast, value_reinterpret_cast)
14483 (value_dynamic_cast, typecmp): Likewise.
14484 (value_ref): Parameterize by kind of return value reference type.
14485 * value.h (value_ref): Add new parameter "refcode".
14486
14487 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14488
14489 PR gdb/14441
14490 * dwarf2read.c (read_tag_reference_type): Use
14491 lookup_lvalue_reference_type() instead of lookup_reference_type().
14492 * eval.c (evaluate_subexp_standard): Likewise.
14493 * f-exp.y: Likewise.
14494 * gdbtypes.c (make_reference_type, lookup_reference_type):
14495 Generalize with rvalue reference types.
14496 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
14497 convenience wrappers for lookup_reference_type().
14498 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
14499 reference kind parameter.
14500 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
14501 wrappers for lookup_reference_type().
14502 * guile/scm-type.c (gdbscm_type_reference): Use
14503 lookup_lvalue_reference_type() instead of lookup_reference_type().
14504 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
14505 * parse.c (follow_types): Likewise.
14506 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
14507 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
14508 Likewise.
14509 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
14510 (gdbpy_invoke_xmethod): Likewise.
14511 * stabsread.c: Provide extra argument to make_reference_type()
14512 call.
14513 * valops.c (value_ref, value_rtti_indirect_type): Use
14514 lookup_lvalue_reference_type() instead of lookup_reference_type().
14515
14516 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14517
14518 PR gdb/14441
14519 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
14520 (TYPE_IS_REFERENCE): New macro.
14521 (struct type): Add rvalue_reference_type field.
14522 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
14523
14524 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
14525
14526 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
14527 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
14528 New function definition.
14529 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
14530 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
14531 New function declaration.
14532 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
14533 * mi/mi-interp.h: New file.
14534 * solib.c (info_sharedlibrary_command): Replace for loop with
14535 ALL_SO_LIBS macro
14536 * solib.h (update_solib_list): New function declaration.
14537 (so_list_head): Move macro.
14538 * solist.h (ALL_SO_LIBS): New macro.
14539
14540 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
14541
14542 * infcmd.c (post_create_inferior): Remove unused argument in
14543 call to solib_add.
14544 * remote.c (remote_start_remote): Likewise.
14545 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
14546 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
14547 (enable_break): Likewise.
14548 * solib.c (update_solib_list): Remove unused target argument
14549 and its documentation.
14550 (solib_add): Remove unused target argument. Remove unused
14551 argument in call to update_solib_list.
14552 (info_sharedlibrary_command): Remove unused argument in call
14553 to update_solib_list.
14554 (sharedlibrary_command): Remove unused argument in call to
14555 solib_add.
14556 (handle_solib_event): Likewise.
14557 (reload_shared_libraries): Likewise.
14558 * solib.h (solib_add): Remove unused target argument.
14559
14560 2017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
14561
14562 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
14563 (s390_displaced_step_fixup): Cover relative branches with the
14564 default fixup handling. This fixes lack of support for some
14565 relative branch instructions.
14566
14567 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14568
14569 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
14570 ptid from regcache.
14571
14572 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14573
14574 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
14575 i386_darwin_store_inferior_registers): Use ptid from regcache.
14576
14577 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14578
14579 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
14580 i386bsd_store_inferior_registers): Use ptid from regcache.
14581
14582 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14583
14584 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
14585 hppaobsd_store_registers): Use ptid from regcache.
14586
14587 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14588
14589 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
14590 hppanbsd_store_registers): Use ptid from regcache.
14591
14592 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14593
14594 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
14595 from regcache. Use get_ptrace_pid.
14596
14597 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14598
14599 * corelow.c (get_core_register_section): Use ptid from regcache,
14600 update doc.
14601
14602 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14603
14604 * bsd-uthread.c (bsd_uthread_fetch_registers,
14605 bsd_uthread_store_registers): Use ptid from regcache, set and
14606 restore inferior_ptid.
14607
14608 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14609
14610 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
14611 fetch_fp_regs, store_register, store_regs, store_fp_register,
14612 store_fp_regs): Use ptid from regcache.
14613
14614 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14615
14616 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
14617 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
14618 store_vfp_regs): Use ptid from regcache.
14619
14620 2017-03-17 Pedro Alves <palves@redhat.com>
14621
14622 PR remote/21188
14623 * ser-base.c (ser_base_wait_for): Add comment.
14624 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
14625 version.
14626 * ser-unix.c (hardwire_raw): Remove reference to
14627 scb->current_timeout.
14628 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
14629 (hardwire_ops): Install ser_base_readchar instead of
14630 hardwire_readchar.
14631 * serial.h (struct serial) <current_timeout, timeout_remaining>:
14632 Remove fields.
14633
14634 2017-03-17 Jonah Graham <jonah@kichwacoders.com>
14635
14636 PR gdb/19637
14637 * python/lib/gdb/printer/bound_registers.py: Add support for
14638 Python 3.
14639
14640 2017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
14641
14642 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
14643 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
14644 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
14645 byte_offset to subobj_byte_offset. Fix the handling of
14646 DWARF_VALUE_STACK on big-endian targets when coming via an
14647 implicit pointer.
14648 (dwarf2_evaluate_loc_desc): Adjust call to
14649 dwarf2_evaluate_loc_desc_full.
14650 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
14651 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
14652
14653 2017-03-16 Yao Qi <yao.qi@linaro.org>
14654
14655 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
14656 and REVSH instructions.
14657
14658 2017-03-16 Yao Qi <yao.qi@linaro.org>
14659
14660 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
14661 (arm_record_test): Declare.
14662 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
14663 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
14664 align with the manual.
14665 (thumb_record_misc): Adjust the code order to align with the
14666 manual.
14667 (thumb2_record_decode_insn_handler): Fix instruction matching.
14668 (instruction_reader_thumb): New class.
14669 (arm_record_test): New function.
14670
14671 2017-03-16 Yao Qi <yao.qi@linaro.org>
14672
14673 * arm-tdep.c (abstract_memory_reader): New class.
14674 (instruction_reader): New class.
14675 (extract_arm_insn): Add argument 'reader'. Callers updated.
14676 (decode_insn): Likewise.
14677
14678 2017-03-16 Doug Evans <dje@google.com>
14679
14680 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
14681 member. Change type of TYPE member to SCM. All uses updated.
14682 (lsscm_make_lazy_string_smob): Add assert.
14683 (lsscm_make_lazy_string): Flag bad length values.
14684 (lsscm_elt_type): New function.
14685 (gdbscm_lazy_string_to_value): Rewrite to use
14686 lsscm_safe_lazy_string_to_value.
14687 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
14688 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
14689 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
14690 in incoming type.
14691 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
14692 * guile/scm-type.c (tyscm_scm_to_type): New function.
14693
14694 2017-03-15 Doug Evans <dje@google.com>
14695
14696 PR python/17728, python/18439, python/18779
14697 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
14698 member. Change type of TYPE member to PyObject *. All uses updated.
14699 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
14700 (gdbpy_create_lazy_string_object): Flag bad length values.
14701 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
14702 Handle typedefs in incoming type.
14703 (stpy_lazy_string_elt_type): New function.
14704 (gdbpy_extract_lazy_string): Call it.
14705 * python/py-value.c (valpy_lazy_string): Flag bad length values.
14706 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
14707 typedefs in incoming type.
14708
14709 2017-03-16 Doug Evans <dje@google.com>
14710
14711 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
14712 * guile/scm-type.c (tyscm_scm_to_type): New function.
14713
14714 2017-03-16 Jiong Wang <jiong.wang@arm.com>
14715
14716 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
14717 "ULONGEST" for "skip".
14718
14719 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
14720
14721 PR gdb/21220
14722 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
14723 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
14724 (inf_ptrace_peek_poke): ...here. New function. Now also loop
14725 over ptrace peek/poke until end of buffer or error.
14726
14727 2017-03-14 Simon Marchi <simon.marchi@ericsson.com>
14728
14729 * parse.c (length_of_subexp): Make static.
14730 * parser-defs.h (length_of_subexp): Remove.
14731
14732 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
14733
14734 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
14735 as well.
14736
14737 2017-03-14 Pedro Alves <palves@redhat.com>
14738
14739 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
14740 (main): Use std::unique_ptr. Remove calls to
14741 cp_demangled_name_parse_free.
14742
14743 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
14744
14745 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
14746 alphabsd_store_inferior_registers): Use regcache->ptid instead
14747 of inferior_ptid.
14748
14749 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
14750
14751 * aix-thread.c (aix_thread_fetch_registers,
14752 aix_thread_store_registers): Use regcache->ptid instead of
14753 inferior_ptid.
14754
14755 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
14756
14757 * aarch64-linux-nat.c (fetch_gregs_from_thread,
14758 store_gregs_to_thread, fetch_fpregs_from_thread,
14759 store_fpregs_to_thread): Use regcache->ptid instead of
14760 inferior_ptid.
14761
14762 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
14763
14764 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
14765 amd64_linux_fetch_inferior_registers): Use regcache->ptid
14766 instead of inferior_ptid.
14767
14768 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
14769
14770 * target.c (target_fetch_registers, target_store_registers): Add
14771 assert.
14772
14773 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
14774
14775 * regcache.h (regcache_get_ptid): New function.
14776 * regcache.c (regcache_get_ptid): New function.
14777
14778 2017-03-13 Mark Wielaard <mark@klomp.org>
14779
14780 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
14781
14782 2017-03-10 Keith Seitz <keiths@redhat.com>
14783
14784 PR c++/8218
14785 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
14786
14787 2017-03-08 Pedro Alves <palves@redhat.com>
14788
14789 PR gdb/18360
14790 * infrun.c (start_step_over, do_target_resume, resume)
14791 (restart_threads): Assert we're not resuming a thread that is
14792 meant to be stopped.
14793 (infrun_thread_stop_requested_callback): Delete.
14794 (infrun_thread_stop_requested): If the thread is internally
14795 stopped, queue a pending stop event and clear the thread's
14796 inline-frame state.
14797 (handle_stop_requested): New function.
14798 (handle_syscall_event, handle_inferior_event_1): Use
14799 handle_stop_requested.
14800 (handle_stop_requested): New function.
14801 (handle_signal_stop): Set the thread's stop_signal here instead of
14802 at caller.
14803 (finish_step_over): Clear step over info unconditionally.
14804 (handle_signal_stop): If the user had interrupted the event
14805 thread, consider the stop a random signal.
14806 (handle_signal_stop) <signal arrived while stepping over
14807 breakpoint>: Don't restart threads here.
14808 (stop_waiting): Don't clear step-over info here.
14809
14810 2017-03-08 Pedro Alves <palves@redhat.com>
14811
14812 PR 21206
14813 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
14814 goes to argument 2, not 1.
14815
14816 2017-03-08 Pedro Alves <palves@redhat.com>
14817
14818 PR cli/21218
14819 * top.c (gdb_readline_wrapper): Avoid passing NULL to
14820 display_gdb_prompt.
14821 (command_line_input): Add comment.
14822
14823 2017-03-08 Pedro Alves <palves@redhat.com>
14824
14825 PR tui/21216
14826 * tui/tui-file.c (tui_file::write): New.
14827 * tui/tui-file.h (tui_file): Override "write".
14828 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
14829 factored out from ...
14830 (tui_puts): ... here.
14831 (tui_putc): Use them.
14832 (tui_write): New function.
14833 * tui/tui-io.h (tui_write): Declare.
14834
14835 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
14836
14837 * Makefile.in (SFILES): Replace "environ.c" with
14838 "common/environ.c".
14839 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
14840 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
14841 to...
14842 * common/environ.c: ... here.
14843 * environ.h: Moved to...
14844 * common/environ.h: ... here.
14845
14846 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
14847
14848 * gdbarch.sh (pstring_ptr): New static function.
14849 (gdbarch_disassembler_options): Use it.
14850 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
14851 not valid_disassembler_option->name.
14852 * gdbarch.c: Regenerate.
14853
14854 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
14855
14856 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
14857
14858 2017-03-07 Pedro Alves <palves@redhat.com>
14859
14860 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
14861
14862 2017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
14863
14864 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
14865 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
14866 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
14867 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
14868
14869 2017-03-06 Simon Marchi <simon.marchi@ericsson.com>
14870
14871 * xtensa-linux-nat.c (fetch_gregs): Remove const.
14872
14873 2017-03-03 Simon Marchi <simon.marchi@ericsson.com>
14874
14875 * remote.c (remote_add_target_side_commands): Use range-based
14876 for loop.
14877
14878 2017-03-03 Yao Qi <yao.qi@linaro.org>
14879
14880 PR gdb/21165
14881 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
14882 value is lazy.
14883 * valprint.c (common_val_print): Likewise.
14884
14885 2017-02-28 Peter Bergner <bergner@vnet.ibm.com>
14886
14887 * NEWS: Mention new set/show disassembler-options commands.
14888 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
14889 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
14890 (prospective_options): New static variable.
14891 (gdb_disassembler::gdb_disassembler): Initialize
14892 m_di.disassembler_options.
14893 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
14894 (get_disassembler_options): New function.
14895 (set_disassembler_options): Likewise.
14896 (set_disassembler_options_sfunc): Likewise.
14897 (show_disassembler_options_sfunc): Likewise.
14898 (disassembler_options_completer): Likewise.
14899 (_initialize_disasm): Likewise.
14900 * disasm.h (get_disassembler_options): New prototype.
14901 (set_disassembler_options): Likewise.
14902 * gdbarch.sh (gdbarch_disassembler_options): New variable.
14903 (gdbarch_verify_disassembler_options): Likewise.
14904 * gdbarch.c: Regenerate.
14905 * gdbarch.h: Likewise.
14906 * arm-tdep.c (num_disassembly_options): Delete.
14907 (set_disassembly_style): Likewise.
14908 (arm_disassembler_options): New static variable.
14909 (set_disassembly_style_sfunc): Convert short style name into long
14910 option name. Call set_disassembler_options.
14911 (show_disassembly_style_sfunc): New function.
14912 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
14913 set_gdbarch_verify_disassembler_options.
14914 (_initialize_arm_tdep): Delete regnames variable and update callers.
14915 (arm_disassembler_options): Initialize.
14916 (disasm_options): New variable.
14917 (num_disassembly_options): Rename from this...
14918 (num_disassembly_styles): ...to this. Compute by scanning through
14919 disasm_options.
14920 (valid_disassembly_styles): Initialize using disasm_options.
14921 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
14922 set_arm_regname_option.
14923 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
14924 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
14925 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
14926 set_gdbarch_verify_disassembler_options.
14927 * s390-tdep.c (s390_disassembler_options): New static variable.
14928 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
14929 set_gdbarch_verify_disassembler_options.
14930
14931 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
14932
14933 * remote.c (remote_add_target_side_condition): Remove "struct"
14934 keyword from range-based for loop.
14935
14936 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
14937
14938 * remote.c (remote_add_target_side_condition): Use range-based
14939 for loop. Update comment.
14940
14941 2017-02-27 Yao Qi <yao.qi@linaro.org>
14942
14943 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
14944
14945 2017-02-26 Alan Hayward <alan.hayward@arm.com>
14946
14947 * regcache.c (regcache_raw_update): New function.
14948 (regcache_raw_read): Move code to regcache_raw_update.
14949 * regcache.h (regcache_raw_update): New declaration.
14950 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
14951
14952 2017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
14953
14954 * dwarf2read.c (create_debug_type_hash_table): Initialize
14955 header.signature and header.type_offset_in_tu.
14956
14957 2017-02-24 Pedro Alves <palves@redhat.com>
14958
14959 * symtab.c (make_file_symbol_completion_list_1): Use
14960 add_symtab_completions.
14961
14962 2017-02-24 Alan Hayward <alan.hayward@arm.com>
14963
14964 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
14965
14966 2017-02-24 Alan Hayward <alan.hayward@arm.com>
14967
14968 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
14969 I386_MAX_REGISTER_SIZE.
14970 (i386_pseudo_register_write): Likewise.
14971 (i386_process_record): Likewise.
14972 * i387-tdep.c (i387_supply_xsave): Likewise.
14973 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
14974 (store_register): Likewise.
14975
14976 2017-02-23 Pedro Alves <palves@redhat.com>
14977
14978 * ada-lang.c: Include "common/function-view.h".
14979 (ada_iterate_over_symbols): Adjust to use function_view as
14980 callback type.
14981 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
14982 (ada_make_symbol_completion_list): Use a lambda.
14983 (ada_exc_search_name_matches): Delete.
14984 (name_matches_regex): New.
14985 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
14986 * compile/compile-c-support.c: Include "common/function-view.h".
14987 (print_one_macro): Change prototype to accept a ui_file pointer.
14988 (write_macro_definitions): Use a lambda.
14989 * dwarf2read.c: Include "common/function-view.h".
14990 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
14991 (dw2_expand_symtabs_matching): Adjust to use function_view as
14992 callback type.
14993 * language.h: Include "common/function-view.h".
14994 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
14995 function_view as callback type.
14996 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
14997 * linespec.c: Include "common/function-view.h".
14998 (collect_info::add_symbol): New method.
14999 (struct symbol_and_data_callback, iterate_inline_only, struct
15000 symbol_matcher_data, iterate_name_matcher): Delete.
15001 (iterate_over_all_matching_symtabs): Adjust to use function_view
15002 as callback type and lambdas.
15003 (iterate_over_file_blocks): Adjust to use function_view as
15004 callback type.
15005 (decode_compound_collector): Now a class with private fields.
15006 (decode_compound_collector::release_symbols): New method.
15007 (collect_one_symbol): Rename to...
15008 (decode_compound_collector::operator()): ... this and adjust.
15009 (lookup_prefix_sym): decode_compound_collector construction bits
15010 move to decode_compound_collector ctor. Pass the
15011 decode_compound_collector object directly as callback. Remove
15012 cleanups and use decode_compound_collector::release_symbols
15013 instead.
15014 (symtab_collector): Now a class with private fields.
15015 (symtab_collector::release_symtabs): New method.
15016 (add_symtabs_to_list): Rename to...
15017 (symtab_collector::operator()): ... this and adjust.
15018 (collect_symtabs_from_filename): symtab_collector construction
15019 bits move to symtab_collector ctor. Pass the symtab_collector
15020 object directly as callback. Remove cleanups and use
15021 symtab_collector::release_symtabs instead.
15022 (collect_symbols): Delete.
15023 (add_matching_symbols_to_info): Use lambdas.
15024 * macrocmd.c (print_macro_callback): Delete.
15025 (info_macro_command): Use a lambda.
15026 (info_macros_command): Pass print_macro_definition as callable
15027 directly.
15028 (print_one_macro): Remove 'ignore' parameter.
15029 (macro_list_command): Adjust.
15030 * macrotab.c (macro_for_each_data::fn): Now a function_view.
15031 (macro_for_each_data::user_data): Delete field.
15032 (foreach_macro): Adjust to call the function_view.
15033 (macro_for_each): Adjust to use function_view as callback type.
15034 (foreach_macro_in_scope): Adjust to call the function_view.
15035 (macro_for_each_in_scope): Adjust to use function_view as callback
15036 type.
15037 * macrotab.h: Include "common/function-view.h".
15038 (macro_callback_fn): Declare a prototype instead of a pointer.
15039 Remove "user_data" parameter.
15040 (macro_for_each, macro_for_each_in_scope): Adjust to use
15041 function_view as callback type.
15042 * psymtab.c (partial_map_expand_apply)
15043 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
15044 Adjust to use function_view as callback type and to return bool.
15045 (psym_expand_symtabs_matching): Adjust to use function_view as
15046 callback types.
15047 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
15048 to use function_view as callback type and to return bool.
15049 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
15050 callback types.
15051 * symfile.c (expand_symtabs_matching): Adjust to use function_view
15052 as callback types.
15053 * symfile.h: Include "common/function-view.h".
15054 (expand_symtabs_file_matcher_ftype)
15055 (expand_symtabs_symbol_matcher_ftype)
15056 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
15057 return bool.
15058 (quick_symbol_functions::map_symtabs_matching_filename)
15059 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
15060 function_view as callback type and return bool.
15061 (expand_symtabs_matching): Adjust to use function_view as callback
15062 type.
15063 (maintenance_expand_name_matcher)
15064 (maintenance_expand_file_matcher): Delete.
15065 (maintenance_expand_symtabs): Use lambdas.
15066 * symtab.c (iterate_over_some_symtabs): Adjust to use
15067 function_view as callback types and return bool.
15068 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
15069 of a cleanup.
15070 (lookup_symtab_callback): Delete.
15071 (lookup_symtab): Use a lambda.
15072 (iterate_over_symbols): Adjust to use function_view as callback
15073 type.
15074 (struct search_symbols_data, search_symbols_file_matches)
15075 (search_symbols_name_matches): Delete.
15076 (search_symbols): Use a pair of lambdas.
15077 (struct add_name_data, add_macro_name, symbol_completion_matcher)
15078 (symtab_expansion_callback): Delete.
15079 (default_make_symbol_completion_list_break_on_1): Use lambdas.
15080 * symtab.h: Include "common/function-view.h".
15081 (iterate_over_some_symtabs): Adjust to use function_view as
15082 callback type and return bool.
15083 (iterate_over_symtabs): Adjust to use function_view as callback
15084 type.
15085 (symbol_found_callback_ftype): Remove 'data' parameter and return
15086 bool.
15087 (iterate_over_symbols): Adjust to use function_view as callback
15088 type.
15089
15090 2017-02-23 Pedro Alves <palves@redhat.com>
15091
15092 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
15093 (%.o) <unittests/%.c>: New pattern.
15094 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
15095 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
15096 * common/function-view.h: New file.
15097 * unittests/function-view-selftests.c: New file.
15098 * configure: Regenerate.
15099
15100 2017-02-23 Simon Marchi <simon.marchi@ericsson.com>
15101
15102 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
15103 inferior_ptid.
15104 * go32-nat.c (go32_thread_alive): Likewise.
15105
15106 2017-02-23 Yao Qi <yao.qi@linaro.org>
15107
15108 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
15109 delete.
15110
15111 2017-02-23 Yao Qi <yao.qi@linaro.org>
15112
15113 * varobj.c (varobj_clear_saved_item): Use delete instead of
15114 xfree.
15115 (update_dynamic_varobj_children): Likewise.
15116
15117 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
15118
15119 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
15120
15121 2017-02-21 Simon Marchi <simon.marchi@ericsson.com>
15122
15123 * common/enum-flags.h (enum_flags::enum_flags): Initialize
15124 m_enum_value to 0 in default constructor.
15125
15126 2017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
15127
15128 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
15129 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
15130 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
15131 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
15132 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
15133 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
15134 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
15135 IS_STORE_CONDITIONAL_INSN.
15136
15137 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
15138
15139 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
15140
15141 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15142
15143 * NEWS (Changes since GDB 7.12): Add DWARF-5.
15144
15145 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15146
15147 * dwarf2read.c (skip_one_die, read_attribute_value)
15148 (dwarf2_const_value_attr, dump_die_shallow)
15149 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
15150 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
15151
15152 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15153
15154 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
15155 (dwarf_parse_macro_header): Accept DWARF version 5.
15156 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
15157
15158 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15159
15160 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
15161 DW_AT_GNU_*.
15162 * common/common-exceptions.h (enum errors): Likewise.
15163 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
15164 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
15165 (dwarf_expr_context::execute_stack_op): Likewise.
15166 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
15167 Likewise.
15168 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
15169 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
15170 (show_entry_values_debug, call_site_to_target_addr)
15171 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
15172 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
15173 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
15174 (value_of_dwarf_block_entry, indirect_pieced_value)
15175 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
15176 (disassemble_dwarf_expression): Likewise.
15177 * dwarf2read.c (process_die, inherit_abstract_dies)
15178 (read_call_site_scope): Likewise.
15179 * gdbtypes.h (struct func_type, struct call_site_parameter)
15180 (struct call_site): Likewise.
15181 * stack.c (read_frame_arg): Likewise.
15182 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
15183
15184 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15185
15186 * defs.h (read_unsigned_leb128): New declaration.
15187 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
15188 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
15189 (dwarf2_find_location_expression): Call also
15190 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
15191 * dwarf2loc.h (dwarf2_version): New declaration.
15192 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
15193 rnglists.
15194 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
15195 .debug_rnglists.
15196 (struct dwop_section_names): Add loclists_dwo.
15197 (dwop_section_names): Add .debug_loclists.dwo.
15198 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
15199 (struct dwarf2_per_cu_data): Add dwarf_version.
15200 (struct dwo_sections): Add loclists.
15201 (struct attr_abbrev): Add implicit_const.
15202 (read_indirect_line_string): New declaration.
15203 (read_unsigned_leb128): Delete declaration.
15204 (rcuh_kind): New definition.
15205 (read_and_check_comp_unit_head): Change parameter
15206 is_debug_types_section to section_kind.
15207 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
15208 (read_comp_unit_head): Change parameter abfd to section, add parameter
15209 section_kind. Handle DWARF-5.
15210 (error_check_comp_unit_head): Accept also DWARF version 5.
15211 (read_and_check_comp_unit_head): Change parameter
15212 is_debug_types_section to section_kind.
15213 (read_and_check_type_unit_head): Delete function.
15214 (read_abbrev_offset): Handle DWARF-5.
15215 (create_debug_type_hash_table): Add parameter section_kind. Process
15216 only DW_UT_type. Use signature and type_offset_in_tu from struct
15217 comp_unit_head.
15218 (create_debug_types_hash_table): Update create_debug_type_hash_table
15219 caller.
15220 (create_all_type_units): Call create_debug_type_hash_table.
15221 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
15222 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
15223 caller.
15224 (skip_one_die): Handle DW_FORM_implicit_const.
15225 (dwarf2_rnglists_process): New function.
15226 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
15227 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
15228 (read_attribute_value): Handle DW_FORM_implicit_const,
15229 DW_FORM_line_strp.
15230 (read_attribute): Handle DW_FORM_implicit_const.
15231 (read_indirect_string_at_offset_from): New function from
15232 read_indirect_string_at_offset.
15233 (read_indirect_string_at_offset): Call
15234 read_indirect_string_at_offset_from.
15235 (read_indirect_line_string_at_offset): New function.
15236 (read_indirect_string): New function comment.
15237 (read_indirect_line_string): New function.
15238 (read_unsigned_leb128): Make it global.
15239 (dwarf2_string_attr): Handle DWARF-5.
15240 (add_include_dir_stub, read_formatted_entries): New functions.
15241 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
15242 Handle DWARF-5.
15243 (per_cu_header_read_in): Update read_comp_unit_head caller.
15244 (dwarf2_version): New function.
15245 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
15246 rnglists.
15247 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
15248 fields.
15249
15250 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15251
15252 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
15253
15254 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15255
15256 * dwarf2read.c (dwarf2_ranges_process): New function from
15257 dwarf2_ranges_read.
15258 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
15259 dwarf2_ranges_process.
15260
15261 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15262
15263 * dwarf2read.c (create_debug_type_hash_table): New function from
15264 create_debug_types_hash_table.
15265 (create_debug_types_hash_table): Call create_debug_type_hash_table.
15266 (create_all_type_units, open_and_init_dwo_file): Update
15267 create_debug_types_hash_table callers.
15268
15269 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
15270
15271 PR gdb/16188
15272 * fork-child.c (trace_start_error): Fix thinko. va_end should
15273 refer to 'ap', not 'args'.
15274
15275 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
15276 Pedro Alves <palves@redhat.com>
15277
15278 PR gdb/16188
15279 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
15280 calls succeeded.
15281 * fork-child.c (trace_start_error): New function.
15282 (trace_start_error_with_name): Likewise.
15283 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
15284 * inf-ptrace.c (inf_ptrace_me): Likewise.
15285 * inferior.h (trace_start_error): New prototype.
15286 (trace_start_error_with_name): Likewise.
15287
15288 2017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
15289
15290 PR gdb/21164
15291 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
15292 NULL before using it.
15293 * symmisc.c (maintenance_print_symbols): Likewise.
15294 (maintenance_print_msymbols): Likewise.
15295
15296 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15297
15298 * NEWS: Add record Python bindings entry.
15299
15300 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15301
15302 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
15303 py-record-full.o.
15304 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
15305 * python/py-record-btrace.c, python/py-record-btrace.h,
15306 python/py-record-full.c, python/py-record-full.h: New file.
15307 * python/py-record.c: Add include for py-record-btrace.h and
15308 py-record-full.h.
15309 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
15310 recpy_instruction_history, recpy_function_call_history, recpy_begin,
15311 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
15312 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
15313 New definition.
15314 (gdbpy_initialize_btrace): New export.
15315 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
15316
15317 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15318
15319 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
15320 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
15321 * python/py-record.c: New file.
15322 * python/python-internal.h (gdbpy_start_recording,
15323 gdbpy_current_recording, gdpy_stop_recording,
15324 gdbpy_initialize_record): New export.
15325 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
15326 (python_GdbMethods): Add gdbpy_start_recording,
15327 gdbpy_current_recording and gdbpy_stop_recording.
15328
15329 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15330
15331 * record-btrace.c (record_btrace_record_method): New function.
15332 (init_record_btrace_ops): Initialize to_record_method.
15333 * record-full.c (record_full_record_method): New function.
15334 (init_record_full_ops, init_record_full_core_ops): Add
15335 record_full_record_method.
15336 * record.h (enum record_method): New enum.
15337 * target-debug.h (target_debug_print_enum_record_method: New define.
15338 * target-delegates.c: Regenerate.
15339 * target.c (target_record_method): New function.
15340 * target.h: Include record.h.
15341 (struct target_ops) <to_record_method>: New field.
15342 (target_record_method): New export.
15343
15344 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15345
15346 * record.h (record_start, record_stop): New export.
15347 * record.c (record_start, record_stop): New function.
15348
15349 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15350
15351 * btrace.c (btrace_fetch): Copy function call segments pointer
15352 into a vector.
15353 (btrace_clear): Clear the vector.
15354 (btrace_find_insn_by_number): Use binary search to find the correct
15355 function call segment.
15356 * btrace.h (brace_fun_p): New typedef.
15357 (struct btrace_thread_info) <functions>: New field.
15358
15359 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15360
15361 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
15362 * btrace.c (btrace_decode_error): ... here. New function.
15363 * btrace.h (btrace_decode_error): New export.
15364
15365 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15366
15367 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
15368 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
15369 btrace_find_insn_by_number): Remove special case for gaps.
15370 * btrace.h (btrace_insn_get_error): New export.
15371 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
15372 * record-btrace.c (btrace_insn_history): Print number for gaps.
15373 (record_btrace_info, record_btrace_goto): Handle gaps.
15374
15375 2017-02-14 Tom Tromey <tom@tromey.com>
15376
15377 PR python/13598:
15378 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
15379 event.
15380 * python/py-evts.c (gdbpy_initialize_py_events): Add
15381 before_prompt registry.
15382 * python/py-events.h (events_object) <before_prompt>: New field.
15383
15384 2017-02-14 Markus Metzger <markus.t.metzger@intel.com>
15385
15386 * btrace.c (ftrace_new_switch): Preserve up link and flags.
15387
15388 2017-02-13 Luis Machado <lgustavo@codesourcery.com>
15389
15390 * symfile (_initialize_symfile): Add usage text to the load command's
15391 help text.
15392
15393 2017-02-10 Simon Marchi <simon.marchi@ericsson.com>
15394
15395 * utils.c (defaulted_query): Don't query on secondary UIs.
15396
15397 2017-02-10 Tom Tromey <tom@tromey.com>
15398
15399 * rust-lang.c (rust_get_disr_info): Remove unused variable.
15400
15401 2017-02-10 Tom Tromey <tom@tromey.com>
15402
15403 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
15404 "cleanup" local.
15405 * python/py-type.c (typy_legacy_template_argument): Remove
15406 unnecessary "cleanup" local.
15407
15408 2017-02-10 Tom Tromey <tom@tromey.com>
15409
15410 * python/python.c (do_start_initialization): New function, from
15411 _initialize_python.
15412 (_initialize_python): Call do_start_initialization.
15413 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
15414 goto.
15415
15416 2017-02-10 Tom Tromey <tom@tromey.com>
15417
15418 * python/py-prettyprint.c (pretty_print_one_value): Use
15419 gdbpy_ref.
15420
15421 2017-02-10 Tom Tromey <tom@tromey.com>
15422
15423 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
15424 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
15425 gdbpy_ref.
15426 * python/py-type.c (field_new): Use gdbpy_ref.
15427 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
15428 gdbpy_ref.
15429 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
15430 (py_free_pspace): Likewise.
15431 (pspace_to_pspace_object): Likewise.
15432 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
15433 (py_free_objfile): Likewise.
15434 (objfile_to_objfile_object): Likewise.
15435 * python/py-inferior.c (delete_thread_object): Use
15436 gdbpy_ref.
15437 (infpy_read_memory): Likewise.
15438 (py_free_inferior): Likewise.
15439 * python/py-evtregistry.c (create_eventregistry_object): Use
15440 gdbpy_ref.
15441 * python/py-event.c (create_event_object): Use gdbpy_ref.
15442
15443 2017-02-10 Tom Tromey <tom@tromey.com>
15444
15445 * python/py-ref.h (gdbpy_ref_policy): Now a template.
15446 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
15447 used.
15448 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
15449 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
15450 python/py-exitedevent.c, python/py-finishbreakpoint.c,
15451 python/py-framefilter.c, python/py-function.c,
15452 python/py-inferior.c, python/py-infevents.c,
15453 python/py-linetable.c, python/py-newobjfileevent.c,
15454 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
15455 python/py-signalevent.c, python/py-stopevent.c,
15456 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
15457 python/py-unwind.c, python/py-utils.c, python/py-value.c,
15458 python/py-varobj.c, python/py-xmethods.c, python/python.c,
15459 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
15460
15461 2017-02-10 Tom Tromey <tom@tromey.com>
15462
15463 * ui-out.h (ui_out_emit_type): New class.
15464 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
15465 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
15466 and ui_out_emit_tuple.
15467 (enumerate_locals): Likewise.
15468 (py_mi_print_variables, py_print_locals, py_print_args): Use
15469 ui_out_emit_list.
15470 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
15471 ui_out_emit_list.
15472 * common/gdb_optional.h: New file.
15473
15474 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
15475
15476 * MAINTAINERS (Write After Approval): Update my e-mail address.
15477
15478 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
15479
15480 PR gdb/21122
15481 * breakpoint.c (_initialize_breakpoint): Update the help description
15482 of the 'commands' command to indicate that it takes a list argument.
15483
15484 2017-02-09 Simon Marchi <simon.marchi@ericsson.com>
15485
15486 * interps.c (current_interp_set_logging): Remove "return".
15487
15488 2017-02-09 Gary Benson <gbenson@redhat.com>
15489
15490 * symtab.c (add_symtab_completions): Prevent NULL pointer
15491 dereference.
15492
15493 2017-02-08 Pedro Alves <palves@redhat.com>
15494
15495 * interps.c (interp::interp): Remove reference to quiet_p.
15496 (interp_set): Make static. Remove dead "Switching to" output
15497 code.
15498 (interp_quiet_p, interp_set_quiet): Delete.
15499 (interpreter_exec_cmd): Don't set the interpreter quiet.
15500 * interps.h (interp_quiet_p): Make static.
15501 (class interp) <quiet_p>: Remove field
15502
15503 2017-02-08 Jerome Guitton <guitton@adacore.com>
15504
15505 * cli/cli-decode.c (find_command_name_length): Make it extern.
15506 * cli/cli-decode.h (find_command_name_length): Declare.
15507 * cli/cli-script.c (command_name_equals, line_first_arg):
15508 New functions.
15509 (process_next_line): Use cli-decode to parse command names.
15510 (build_command_line): Make args a constant pointer.
15511
15512 2017-02-08 Jerome Guitton <guitton@adacore.com>
15513
15514 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
15515 Remove case-insensitive search.
15516
15517 2017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
15518
15519 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
15520 at the end of the line. Avoids an ARI warning.
15521
15522 2017-02-06 Luis Machado <lgustavo@codesourcery.com>
15523
15524 * NEWS: Mention support for record/replay of Intel 64 rdrand and
15525 rdseed instructions.
15526 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
15527
15528 2017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
15529
15530 PR tdep/20936
15531 Provide and use sparc32 and sparc64 target description XML files.
15532 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
15533 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
15534 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
15535 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
15536 * features/sparc/sparc32-solaris.xml: New file.
15537 * features/sparc/sparc64-solaris.xml: New file.
15538 * features/sparc/sparc32-solaris.c: Generated.
15539 * features/sparc/sparc64-solaris.c: Generated.
15540 * sparc-tdep.h: Account for differences in target descriptions.
15541 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
15542 (sparc32_register_type): Use target provided registers.
15543 (validate_tdesc_registers): New function.
15544 (sparc32_gdbarch_init): Use tdesc_has_registers.
15545 Set pseudoregister functions.
15546 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
15547 (sparc64_register_type): Use target provided registers.
15548 (sparc64_init_abi): Set pseudoregister functions.
15549
15550 2017-02-03 Tom Tromey <tom@tromey.com>
15551
15552 PR rust/21097:
15553 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
15554 with a single member.
15555
15556 2017-02-03 Pedro Alves <palves@redhat.com>
15557
15558 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
15559 (cli_interp_base::~cli_interp_base): New.
15560 (cli_interp): New struct.
15561 (as_cli_interp): Cast the interp itself to cli_interp.
15562 (cli_interpreter_pre_command_loop): Rename to ...
15563 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
15564 parameter.
15565 (cli_interpreter_init): Rename to ...
15566 (cli_interp::init): ... this. Remove 'self' parameter. Use
15567 boolean. Make extern.
15568 (cli_interpreter_resume): Rename to ...
15569 (cli_interp::resume): ... this. Remove 'data' parameter. Make
15570 extern.
15571 (cli_interpreter_suspend): Rename to ...
15572 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
15573 extern.
15574 (cli_interpreter_exec): Rename to ...
15575 (cli_interp::exec): ... this. Remove 'data' parameter. Make
15576 extern.
15577 (cli_interpreter_supports_command_editing): Rename to ...
15578 (cli_interp_base::supports_command_editing): ... this. Remove
15579 'interp' parameter. Make extern.
15580 (cli_ui_out): Rename to ...
15581 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
15582 Make extern.
15583 (cli_set_logging): Rename to ...
15584 (cli_interp_base::set_logging): ... this. Remove 'interp'
15585 parameter. Make extern.
15586 (cli_interp_procs): Delete.
15587 (cli_interp_factory): Adjust to use "new".
15588 * cli/cli-interp.h: Include "interps.h".
15589 (struct cli_interp_base): New struct.
15590 * interps.c (struct interp): Delete. Fields moved to interps.h.
15591 (interp_new): Delete.
15592 (interp::interp, interp::~interp): New.
15593 (interp_set): Use bool, and return void. Assume the interpreter
15594 has suspend, init and resume methods, and that the all return
15595 void.
15596 (set_top_level_interpreter): interp_set returns void.
15597 (interp_ui_out): Adapt.
15598 (current_interp_set_logging): Adapt.
15599 (interp_data): Delete.
15600 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
15601 (interp_exec): Adapt.
15602 (top_level_interpreter_data): Delete.
15603 * interps.h (interp_init_ftype, interp_resume_ftype)
15604 (interp_suspend_ftype, interp_exec_ftype)
15605 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
15606 (class interp): New.
15607 (interp_new): Delete.
15608 (interp_set): Now returns void. Use bool.
15609 (interp_data, top_level_interpreter_data): Delete.
15610 * mi/mi-common.h: Include interps.h.
15611 (class mi_interp): Inherit from interp. Define a ctor. Declare
15612 init, resume, suspect, exec, interp_ui_out, set_logging and
15613 pre_command_loop methods.
15614 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
15615 (mi_interpreter_init): Rename to ...
15616 (mi_interp::init): ... this. Remove the 'interp' parameter, use
15617 bool, return void and make extern. Adjust.
15618 (mi_interpreter_resume): ... Rename to ...
15619 (mi_interp::resume): ... this. Remove the 'data' parameter,
15620 return void and make extern. Adjust.
15621 (mi_interpreter_suspend): ... Rename to ...
15622 (mi_interp::suspend): ... this. Remove the 'data' parameter,
15623 return void and make extern. Adjust.
15624 (mi_interpreter_exec): ... Rename to ...
15625 (mi_interp::exec): ... this. Remove the 'data' parameter and make
15626 extern. Adjust.
15627 (mi_interpreter_pre_command_loop): ... Rename to ...
15628 (mi_interp::pre_command_loop): ... this. Remove the 'self'
15629 parameter and make extern.
15630 (mi_on_normal_stop_1): Adjust.
15631 (mi_ui_out): Rename to ...
15632 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
15633 parameter and make extern. Adjust.
15634 (mi_set_logging): Rename to ...
15635 (mi_interp::set_logging): ... this. Remove the 'interp'
15636 parameter and make extern. Adjust.
15637 (mi_interp_procs): Delete.
15638 (mi_interp_factory): Adjust to use 'new'.
15639 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
15640 (mi_print_exception, mi_execute_command, mi_load_progress):
15641 Adjust.
15642 * tui/tui-interp.c (tui_interp): New class.
15643 (as_tui_interp): Return a tui_interp pointer.
15644 (tui_on_normal_stop, tui_on_signal_received)
15645 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
15646 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
15647 to use interp::interp_ui_out.
15648 (tui_init): Rename to ...
15649 (tui_interp::init): ... this. Remove the 'self' parameter, use
15650 bool, return void and make extern. Adjust.
15651 (tui_resume): Rename to ...
15652 (tui_interp::resume): ... this. Remove the 'data' parameter,
15653 return void and make extern. Adjust.
15654 (tui_suspend): Rename to ...
15655 (tui_interp::suspend): ... this. Remove the 'data' parameter,
15656 return void and make extern. Adjust.
15657 (tui_ui_out): Rename to ...
15658 (tui_interp::interp_ui_out): ... this. Remove the 'self'
15659 parameter, and make extern. Adjust.
15660 (tui_exec): Rename to ...
15661 (tui_interp::exec): ... this. Remove the 'data' parameter and
15662 make extern.
15663 (tui_interp_procs): Delete.
15664 (tui_interp_factory): Use "new".
15665
15666 2017-02-02 Tom Tromey <tom@tromey.com>
15667
15668 * rust-exp.y (ends_raw_string, space_then_number)
15669 (rust_identifier_start_p): Return bool.
15670 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
15671 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
15672 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
15673 (rust_chartype_p): Return bool.
15674 (val_print_struct, rust_print_struct_def, rust_print_type):
15675 Update.
15676 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
15677 Return bool.
15678
15679 2017-02-02 Tom Tromey <tom@tromey.com>
15680
15681 * rust-lang.c: Reindent.
15682
15683 2017-02-02 Tom Tromey <tom@tromey.com>
15684
15685 * rust-lang.h (rust_crate_for_block): Update.
15686 * rust-lang.c (rust_crate_for_block): Return std::string.
15687 (rust_get_disr_info): Use std:;string, not
15688 gdb::unique_xmalloc_ptr.
15689 * rust-exp.y (crate_name): Update.
15690
15691 2017-02-02 Pedro Alves <palves@redhat.com>
15692
15693 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
15694 field out of gdb_disassembler_test and make it static.
15695
15696 2017-02-02 Pedro Alves <palves@redhat.com>
15697
15698 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
15699 mi1_interp and mi_interp fields.
15700
15701 2017-02-02 Pedro Alves <palves@redhat.com>
15702
15703 * cli/cli-interp.c (struct saved_output_files, saved_output):
15704 Moved from cli/cli-logging.c.
15705 (cli_set_logging): New function.
15706 (cli_interp_procs): Install cli_set_logging.
15707 * cli/cli-interp.h (make_logging_output, cli_set_logging):
15708 Declare.
15709 * cli/cli-logging.c (struct saved_output_files, saved_output):
15710 Moved to cli/cli-interp.c.
15711 (pop_output_files): Don't save outputs here.
15712 (make_logging_output): New function.
15713 (handle_redirections): Don't build tee nor save previous outputs
15714 here.
15715 * interps.c (current_interp_set_logging): Change prototype.
15716 Assume there's always a set_logging_proc method installed.
15717 * interps.h (interp_set_logging_ftype): Change prototype.
15718 (current_interp_set_logging): Change prototype and adjust comment.
15719 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
15720 use make_logging_output.
15721 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
15722 2017-02-02 Pedro Alves <palves@redhat.com>
15723
15724 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
15725 from ...
15726 (set_logging_overwrite): ... here.
15727 (logging_no_redirect_file): Delete.
15728 (set_logging_redirect): Don't handle redirection on the fly.
15729 Instead warn that "logging off" / "logging on" is necessary.
15730 (pop_output_files): Delete references to logging_no_redirect_file.
15731 (show_logging_command): Always speak in terms of what will happen
15732 once logging is reenabled.
15733
15734 2017-02-02 Pedro Alves <palves@redhat.com>
15735
15736 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
15737
15738 2017-02-02 Pedro Alves <palves@redhat.com>
15739
15740 * disasm.c (gdb_pretty_print_insn): Rename to ...
15741 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
15742 Remove gdbarch parameter. Adapt to clear the object's buffers
15743 instead of allocating new buffers, and to print using the object's
15744 gdb_disassembler instead of calling gdb_print_insn.
15745 (dump_insns): Use gdb_pretty_print_disassembler.
15746 * disasm.h (gdb_pretty_print_insn): Delete declaration.
15747 (gdb_pretty_print_disassembler): New class.
15748 * record-btrace.c (btrace_insn_history): Use
15749 gdb_pretty_print_disassembler.
15750
15751 2017-02-02 Pedro Alves <palves@redhat.com>
15752
15753 * ada-lang.c (type_as_string): Use string_file.
15754 * ada-valprint.c (ada_print_floating): Use string_file.
15755 * ada-varobj.c (ada_varobj_scalar_image)
15756 (ada_varobj_get_value_image): Use string_file.
15757 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
15758 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
15759 * breakpoint.c (update_inserted_breakpoint_locations)
15760 (insert_breakpoint_locations, reattach_breakpoints)
15761 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
15762 (print_it_watchpoint): Use string_file.
15763 (save_breakpoints): Use stdio_file.
15764 * c-exp.y (oper): Use string_file.
15765 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
15766 tee_file.
15767 (pop_output_files): Use delete.
15768 (handle_redirections): Use stdio_file and tee_file.
15769 * cli/cli-setshow.c (do_show_command): Use string_file.
15770 * compile/compile-c-support.c (c_compute_program): Use
15771 string_file.
15772 * compile/compile-c-symbols.c (generate_vla_size): Take a
15773 'string_file &' instead of a 'ui_file *'.
15774 (generate_c_for_for_one_variable): Take a 'string_file &' instead
15775 of a 'ui_file *'. Use string_file.
15776 (generate_c_for_variable_locations): Take a 'string_file &'
15777 instead of a 'ui_file *'.
15778 * compile/compile-internal.h (generate_c_for_for_one_variable):
15779 Take a 'string_file &' instead of a 'ui_file *'.
15780 * compile/compile-loc2c.c (push, pushf, unary, binary)
15781 (print_label, pushf_register_address, pushf_register)
15782 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
15783 'ui_file *'. Adjust.
15784 * compile/compile.c (compile_to_object): Use string_file.
15785 * compile/compile.h (compile_dwarf_expr_to_c)
15786 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
15787 'ui_file *'.
15788 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
15789 (replace_typedefs_qualified_name): Use string_file and
15790 obstack_copy0.
15791 * disasm.c (gdb_pretty_print_insn): Use string_file.
15792 (gdb_disassembly): Adjust reference the null_stream global.
15793 (do_ui_file_delete): Delete.
15794 (gdb_insn_length): Use null_stream.
15795 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
15796 * dwarf2loc.c (dwarf2_compile_property_to_c)
15797 (locexpr_generate_c_location, loclist_generate_c_location): Take a
15798 'string_file &' instead of a 'ui_file *'.
15799 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
15800 * dwarf2read.c (do_ui_file_peek_last): Delete.
15801 (dwarf2_compute_name): Use string_file.
15802 * event-top.c (gdb_setup_readline): Use stdio_file.
15803 * gdbarch.sh (verify_gdbarch): Use string_file.
15804 * gdbtypes.c (safe_parse_type): Use null_stream.
15805 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
15806 string_file.
15807 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
15808 'string_file *' instead of a 'ui_file *'.
15809 (gdbscm_arch_disassemble): Use string_file.
15810 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
15811 * guile/scm-ports.c (class ioscm_file_port): Now a class that
15812 inherits from ui_file.
15813 (ioscm_file_port_delete, ioscm_file_port_rewind)
15814 (ioscm_file_port_put): Delete.
15815 (ioscm_file_port_write): Rename to ...
15816 (ioscm_file_port::write): ... this. Remove file_port_magic
15817 checks.
15818 (ioscm_file_port_new): Delete.
15819 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
15820 ui_file_up.
15821 * guile/scm-type.c (tyscm_type_name): Use string_file.
15822 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
15823 Use string_file.
15824 * infcmd.c (print_return_value_1): Use string_file.
15825 * infrun.c (print_target_wait_results): Use string_file.
15826 * language.c (add_language): Use string_file.
15827 * location.c (explicit_to_string_internal): Use string_file.
15828 * main.c (captured_main_1): Use null_file.
15829 * maint.c (maintenance_print_architecture): Use stdio_file.
15830 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
15831 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
15832 event_channel>: Change type to mi_console_file pointer.
15833 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
15834 (mi_console_file_delete): Delete.
15835 (struct mi_console_file): Delete.
15836 (mi_console_file_magic): Delete.
15837 (mi_console_file_new): Delete.
15838 (mi_console_file::mi_console_file): New.
15839 (mi_console_file_delete): Delete.
15840 (mi_console_file_fputs): Delete.
15841 (mi_console_file::write): New.
15842 (mi_console_raw_packet): Delete.
15843 (mi_console_file::flush): New.
15844 (mi_console_file_flush): Delete.
15845 (mi_console_set_raw): Rename to ...
15846 (mi_console_file::set_raw): ... this.
15847 * mi/mi-console.h (class mi_console_file): New class.
15848 (mi_console_file_new, mi_console_set_raw): Delete.
15849 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
15850 (mi_set_logging): Use delete and tee_file. Adjust.
15851 * mi/mi-main.c (output_register): Use string_file.
15852 (mi_cmd_data_evaluate_expression): Use string_file.
15853 (mi_cmd_data_read_memory): Use string_file.
15854 (mi_cmd_execute, print_variable_or_computed): Use string_file.
15855 * mi/mi-out.c (mi_ui_out::main_stream): New.
15856 (mi_ui_out::rewind): Use main_stream and
15857 string_file.
15858 (mi_ui_out::put): Use main_stream and string_file.
15859 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
15860 Allocate a 'string_file' instead.
15861 (mi_out_new): Don't allocate a mem_fileopen stream here.
15862 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
15863 (mi_ui_out::main_stream): Declare method.
15864 * printcmd.c (eval_command): Use string_file.
15865 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
15866 * python/py-arch.c (archpy_disassemble): Use string_file.
15867 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
15868 * python/py-frame.c (frapy_str): Use string_file.
15869 * python/py-framefilter.c (py_print_type, py_print_single_arg):
15870 Use string_file.
15871 * python/py-type.c (typy_str): Use string_file.
15872 * python/py-unwind.c (unwind_infopy_str): Use string_file.
15873 * python/py-value.c (valpy_str): Use string_file.
15874 * record-btrace.c (btrace_insn_history): Use string_file.
15875 * regcache.c (regcache_print): Use stdio_file.
15876 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
15877 * remote.c (escape_buffer): Use string_file.
15878 * rust-lang.c (rust_get_disr_info): Use string_file.
15879 * serial.c (serial_open_ops_1): Use stdio_file.
15880 (do_serial_close): Use delete.
15881 * stack.c (print_frame_arg): Use string_file.
15882 (print_frame_args): Remove local mem_fileopen stream, not used.
15883 (print_frame): Use string_file.
15884 * symmisc.c (maintenance_print_symbols): Use stdio_file.
15885 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
15886 Take a 'string_file *' instead of a 'ui_file *'.
15887 * top.c (new_ui): Use stdio_file and stderr_file.
15888 (free_ui): Use delete.
15889 (execute_command_to_string): Use string_file.
15890 (quit_confirm): Use string_file.
15891 * tracepoint.c (collection_list::append_exp): Use string_file.
15892 * tui/tui-disasm.c (tui_disassemble): Use string_file.
15893 * tui/tui-file.c: Don't include "ui-file.h".
15894 (enum streamtype, struct tui_stream): Delete.
15895 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
15896 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
15897 (tui_file::tui_file): New method.
15898 (tui_file_fputs): Delete.
15899 (tui_file_get_strbuf): Delete.
15900 (tui_file::puts): New method.
15901 (tui_file_adjust_strbuf): Delete.
15902 (tui_file_flush): Delete.
15903 (tui_file::flush): New method.
15904 * tui/tui-file.h: Tweak intro comment.
15905 Include ui-file.h.
15906 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
15907 (tui_file_adjust_strbuf): Delete declarations.
15908 (class tui_file): New class.
15909 * tui/tui-io.c (tui_initialize_io): Use tui_file.
15910 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
15911 (tui_register_format): Use string_stream.
15912 * tui/tui-stack.c (tui_make_status_line): Use string_file.
15913 (tui_get_function_from_frame): Use string_file.
15914 * typeprint.c (type_to_string): Use string_file.
15915 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
15916 (null_stream): New global.
15917 (ui_file_delete): Delete.
15918 (ui_file::ui_file): New.
15919 (null_file_isatty): Delete.
15920 (ui_file::~ui_file): New.
15921 (null_file_rewind): Delete.
15922 (ui_file::printf): New.
15923 (null_file_put): Delete.
15924 (null_file_flush): Delete.
15925 (ui_file::putstr): New.
15926 (null_file_write): Delete.
15927 (ui_file::putstrn): New.
15928 (null_file_read): Delete.
15929 (ui_file::putc): New.
15930 (null_file_fputs): Delete.
15931 (null_file_write_async_safe): Delete.
15932 (ui_file::vprintf): New.
15933 (null_file_delete): Delete.
15934 (null_file::write): New.
15935 (null_file_fseek): Delete.
15936 (null_file::puts): New.
15937 (ui_file_data): Delete.
15938 (null_file::write_async_safe): New.
15939 (gdb_flush, ui_file_isatty): Adjust.
15940 (ui_file_put, ui_file_rewind): Delete.
15941 (ui_file_write): Adjust.
15942 (ui_file_write_for_put): Delete.
15943 (ui_file_write_async_safe, ui_file_read): Adjust.
15944 (ui_file_fseek): Delete.
15945 (fputs_unfiltered): Adjust.
15946 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
15947 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
15948 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
15949 (set_ui_file_data): Delete.
15950 (string_file::~string_file, string_file::write)
15951 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
15952 (do_ui_file_as_string, ui_file_as_string): Delete.
15953 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
15954 (struct mem_file): Delete.
15955 (mem_file_new): Delete.
15956 (stdio_file::stdio_file): New.
15957 (mem_file_delete): Delete.
15958 (stdio_file::stdio_file): New.
15959 (mem_fileopen): Delete.
15960 (stdio_file::~stdio_file): New.
15961 (mem_file_rewind): Delete.
15962 (stdio_file::set_stream): New.
15963 (mem_file_put): Delete.
15964 (stdio_file::open): New.
15965 (mem_file_write): Delete.
15966 (stdio_file_magic, struct stdio_file): Delete.
15967 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
15968 (stdio_file::flush): New.
15969 (stdio_file_read): Rename to ...
15970 (stdio_file::read): ... this. Adjust.
15971 (stdio_file_write): Rename to ...
15972 (stdio_file::write): ... this. Adjust.
15973 (stdio_file_write_async_safe): Rename to ...
15974 (stdio_file::write_async_safe) ... this. Adjust.
15975 (stdio_file_fputs): Rename to ...
15976 (stdio_file::puts) ... this. Adjust.
15977 (stdio_file_isatty): Delete.
15978 (stdio_file_fseek): Delete.
15979 (stdio_file::isatty): New.
15980 (stderr_file_write): Rename to ...
15981 (stderr_file::write) ... this. Adjust.
15982 (stderr_file_fputs): Rename to ...
15983 (stderr_file::puts) ... this. Adjust.
15984 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
15985 (stderr_file::stderr_file): New.
15986 (tee_file_magic): Delete.
15987 (struct tee_file): Delete.
15988 (tee_file::tee_file): New.
15989 (tee_file_new): Delete.
15990 (tee_file::~tee_file): New.
15991 (tee_file_delete): Delete.
15992 (tee_file_flush): Rename to ...
15993 (tee_file::flush): ... this. Adjust.
15994 (tee_file_write): Rename to ...
15995 (tee_file::write): ... this. Adjust.
15996 (tee_file::write_async_safe): New.
15997 (tee_file_fputs): Rename to ...
15998 (tee_file::puts): ... this. Adjust.
15999 (tee_file_isatty): Rename to ...
16000 (tee_file::isatty): ... this. Adjust.
16001 * ui-file.h (struct obstack, struct ui_file): Don't
16002 forward-declare.
16003 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
16004 (ui_file_write_ftype)
16005 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
16006 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
16007 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
16008 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
16009 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
16010 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
16011 (set_ui_file_fseek): Delete.
16012 (ui_file_data, ui_file_delete, ui_file_rewind)
16013 (struct ui_file): New.
16014 (ui_file_up): New.
16015 (class null_file): New.
16016 (null_stream): Declare.
16017 (ui_file_write_for_put, ui_file_put): Delete.
16018 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
16019 Delete.
16020 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
16021 (gdb_fopen, tee_file_new): Delete.
16022 (struct string_file): New.
16023 (struct stdio_file): New.
16024 (stdio_file_up): New.
16025 (struct stderr_file): New.
16026 (class tee_file): New.
16027 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
16028 of a 'ui_file *'. Adjust.
16029 * ui-out.h (class ui_out) <field_stream>: Likewise.
16030 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
16031 (null_stream): Delete.
16032 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
16033 Adjust.
16034 * utils.h (struct ui_file): Delete forward declaration..
16035 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
16036 (error_stream): Take a 'string_file &' instead of a
16037 'ui_file *'.
16038 * varobj.c (varobj_value_get_print_value): Use string_file.
16039 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
16040 * gdbarch.c: Regenerate.
16041
16042 2017-02-02 Pedro Alves <palves@redhat.com>
16043
16044 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
16045 (gdb_pretty_print_insn): ... this. Now a free function. Add back
16046 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
16047 Adjust to call gdb_print_insn instead of
16048 gdb_disassembler::print_insn.
16049 (dump_insns, do_mixed_source_and_assembly_deprecated)
16050 (do_mixed_source_and_assembly, do_assembly_only): Add back a
16051 'gdbarch' parameter. Remove gdb_disassembler parameter.
16052 (gdb_disassembly): Don't allocate a gdb_disassembler here.
16053 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
16054 declaration.
16055 (gdb_pretty_print_insn): Re-add declaration.
16056 * record-btrace.c (btrace_insn_history): Don't allocate a
16057 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
16058
16059 2017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
16060
16061 * disasm.h (gdb_disassembly): Remove file_string parameter.
16062 * disasm.c (gdb_disassembly): Likewise.
16063 * cli/cli-cmds.c (print_disassembly): Adapt.
16064 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
16065 * stack.c (do_gdb_disassembly): Likewise.
16066
16067 2017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
16068
16069 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
16070 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
16071 targets. And if the implicit value is longer than needed, extract
16072 the first bytes instead of the "least significant" ones.
16073
16074 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
16075
16076 * btrace.c (btrace_enable): Do not call btrace_add_pc for
16077 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
16078 (btrace_fetch): Assert can_access_registers_ptid.
16079 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
16080 validate_registers_access.
16081
16082 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
16083
16084 * gdbthread.h (can_access_registers_ptid): New.
16085 * thread.c (can_access_registers_ptid): New.
16086
16087 2017-02-01 Pedro Alves <palves@redhat.com>
16088
16089 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
16090
16091 2017-01-31 Pedro Alves <palves@redhat.com>
16092
16093 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
16094 Fix typos.
16095
16096 2017-01-31 Pedro Alves <palves@redhat.com>
16097
16098 * stack.c (print_frame_args): Remove local mem_fileopen stream,
16099 not used.
16100
16101 2017-01-31 Pedro Alves <palves@redhat.com>
16102
16103 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
16104
16105 2017-01-31 Pedro Alves <palves@redhat.com>
16106
16107 * common/scoped_restore.h
16108 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
16109 change the value's parameter type to T2.
16110 (make_scoped_restore): Likewise.
16111
16112 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
16113 Richard Henderson <rth@redhat.com>
16114
16115 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
16116 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
16117 GS_BASE for older kernels.
16118 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
16119 GS_BASE for older kernels.
16120 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
16121 and GS_BASE to the offset table.
16122 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
16123 system register group.
16124 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
16125 for older kernels.
16126 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
16127 amd64 ABI.
16128 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
16129 AMD64_GSBASE_REGNUM.
16130 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
16131 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
16132 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
16133 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
16134 i386/64bit-segments.xml in those rules.
16135 * features/i386/64bit-segments.xml: New file.
16136 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
16137 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
16138 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
16139 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
16140 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
16141 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
16142 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
16143 * features/i386/amd64-avx-linux.c: Regenerated.
16144 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
16145 * features/i386/amd64-avx-mpx.c: Regenerated.
16146 * features/i386/amd64-avx512-linux.c: Regenerated.
16147 * features/i386/amd64-linux.c: Regenerated.
16148 * features/i386/amd64-mpx-linux.c: Regenerated.
16149 * features/i386/i386-avx-mpx-linux.c: Regenerated.
16150 * features/i386/i386-avx-mpx.c: Regenerated.
16151 * features/i386/x32-avx-linux.c: Regenerated.
16152 * features/i386/x32-avx512-linux.c: Regenerated.
16153 * regformats/i386/amd64-avx-linux.dat: Regenerated.
16154 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
16155 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
16156 * regformats/i386/amd64-linux.dat: Regenerated.
16157 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
16158 * regformats/i386/x32-avx-linux.dat: Regenerated.
16159 * regformats/i386/x32-avx512-linux.dat: Regenerated.
16160 * regformats/i386/x32-linux.dat: Regenerated.
16161
16162 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
16163
16164 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
16165 Set to AMD64_NUM_REGS.
16166
16167 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
16168
16169 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
16170 that checks validity of a register number.
16171
16172 2017-01-27 Kees Cook <keescook@google.com>
16173
16174 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
16175 fetch_fpregs if target has fpa registers.
16176 (arm_linux_store_inferior_registers): Call store_fpregs if target
16177 has fpa registers.
16178
16179 2017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
16180
16181 * cris-tdep.c (cris_gdbarch_init): Remove check for
16182 info.byte_order and force it to BFD_ENDIAN_LITTLE.
16183
16184 2017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
16185
16186 * corelow.c (get_core_register_section): Check for regset
16187 existence before checking for REGSET_VARIABLE_SIZE.
16188
16189 2017-01-26 Yao Qi <yao.qi@linaro.org>
16190 Pedro Alves <palves@redhat.com>
16191
16192 PR gdb/20939
16193 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
16194 call memory_error, save memaddr instead.
16195 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
16196 negative, cal memory_error.
16197 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
16198
16199 2017-01-26 Yao Qi <yao.qi@linaro.org>
16200
16201 * disasm-selftests.c (memory_error_test): New function.
16202 (_initialize_disasm_selftests): Register memory_error_test.
16203
16204 2017-01-26 Yao Qi <yao.qi@linaro.org>
16205
16206 * Makefile.in (SFILES): Add disasm-selftests.c and
16207 selftest-arch.c.
16208 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
16209 * disasm-selftests.c: New file.
16210 * selftest-arch.c: New file.
16211 * selftest-arch.h: New file.
16212
16213 2017-01-26 Yao Qi <yao.qi@linaro.org>
16214
16215 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
16216 to bfd_arch_mep. Don't return 0 if section is not
16217 found. Call print_insn_mep.
16218
16219 2017-01-26 Pedro Alves <palves@redhat.com>
16220 Yao Qi <yao.qi@linaro.org>
16221
16222 * arm-tdep.c: Include "disasm.h".
16223 (gdb_print_insn_arm): Update code to get gdbarch.
16224 * disasm.c (dis_asm_read_memory): Change it to
16225 gdb_disassembler::dis_asm_read_memory.
16226 (dis_asm_memory_error): Likewise.
16227 (dis_asm_print_address): Likewise.
16228 (gdb_pretty_print_insn): Change it to
16229 gdb_disassembler::pretty_print_insn.
16230 (dump_insns): Add one argument gdb_disassemlber. All
16231 callers updated.
16232 (do_mixed_source_and_assembly_deprecated): Likewise.
16233 (do_mixed_source_and_assembly): Likewise.
16234 (do_assembly_only): Likewise.
16235 (gdb_disassembler::gdb_disassembler): New.
16236 (gdb_disassembler::print_insn): New.
16237 * disasm.h (class gdb_disassembler): New.
16238 (gdb_pretty_print_insn): Remove declaration.
16239 (gdb_disassemble_info): Likewise.
16240 * guile/scm-disasm.c (class gdbscm_disassembler): New.
16241 (gdbscm_disasm_read_memory_worker): Update.
16242 (gdbscm_disasm_read_memory): Update.
16243 (gdbscm_disasm_memory_error): Remove.
16244 (gdbscm_disasm_print_address): Remove.
16245 (gdbscm_disassembler::gdbscm_disassembler): New.
16246 (gdbscm_print_insn_from_port): Update.
16247 * mips-tdep.c: Include disasm.h.
16248 (gdb_print_insn_mips): Update code to get gdbarch.
16249 * record-btrace.c (btrace_insn_history): Update.
16250 * spu-tdep.c: Include disasm.h.
16251 (struct spu_dis_asm_data): Remove.
16252 (struct spu_dis_asm_info): New.
16253 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
16254 SPU id.
16255 (gdb_print_insn_spu): Cast disassemble_info to
16256 spu_dis_asm_info.
16257
16258 2017-01-26 Yao Qi <yao.qi@linaro.org>
16259
16260 * disasm.c (do_ui_file_delete): Delete.
16261 (gdb_insn_length): Move code creating stream to ...
16262 * utils.c (null_stream): ... here. New function.
16263 * utils.h (null_stream): Declare.
16264
16265 2017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
16266
16267 * python/py-inferior.c (find_thread_object): Return directly
16268 from the loop. Remove "found" variable.
16269
16270 2017-01-21 Joel Brobecker <brobecker@adacore.com>
16271
16272 GDB 7.12.1 released.
16273
16274 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
16275
16276 * python/py-function.c (fnpy_call): Reorder declarations to have
16277 the gdbpy_enter object declared first.
16278 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
16279
16280 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
16281
16282 PR python/21068
16283 * python/python-internal.h (PyMem_RawMalloc): Define for
16284 Python < 3.4.
16285 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
16286 PyMem_RawMalloc instead of PyMem_Malloc.
16287
16288 2017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
16289 Luis Machado <lgustavo@codesourcery.com>
16290
16291 * NEWS (New commands): Mention flash-erase.
16292 (New MI commands): Mention target-flash-erase.
16293 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
16294 command.
16295 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
16296 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
16297 * target.c (flash_erase_command): New function.
16298 (initialize_targets): Add new flash-erase command.
16299 * target.h (flash_erase_command): New declaration.
16300
16301 2017-01-20 Joel Brobecker <brobecker@adacore.com>
16302
16303 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
16304 HAVE_SYS_PROCFS_H is defined.
16305
16306 2017-01-18 Alan Hayward <alan.hayward@arm.com>
16307
16308 * remote.c (struct cached_reg): Change data into a pointer.
16309 * (stop_reply_dtr): Free data pointers before deleting vector.
16310 (process_stop_reply): Likewise.
16311 (remote_parse_stop_reply): Allocate space for data
16312
16313 2017-01-18 Alan Hayward <alan.hayward@arm.com>
16314
16315 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
16316 MAX_REGISTER_SIZE.
16317 (amd64_pseudo_register_read_value): Likewise.
16318 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
16319 (store_register_using_P): Likewise.
16320 * regcache.c (regcache_xfer_part): Likewise.
16321
16322 2017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
16323
16324 Split real and pseudo registers.
16325 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
16326 (sparc32_pseudo_regnum): New enum.
16327 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
16328 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
16329 (SPARC32_CP0_REGISTERS): New macro.
16330 (sparc32_pseudo_register_name): New function.
16331 (sparc32_register_name): Use sparc32_pseudo_register_name.
16332 (sparc32_pseudo_register_type): New function.
16333 (sparc32_register_type): Use sparc32_pseudo_register_type.
16334 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
16335 pseudo register numbers.
16336 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
16337 (SPARC64_CP0_REGISTERS): New macro.
16338 (sparc64_pseudo_register_name): New function.
16339 (sparc64_register_name): Use sparc64_pseudo_register_name.
16340 (sparc64_pseudo_register_type): New function.
16341 (sparc64_register_type): Use sparc64_pseudo_register_type.
16342 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
16343 pseudo register numbers.
16344 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
16345 sparc64_store_arguments): Handle pseudo register numbers.
16346
16347 2017-01-13 Yao Qi <yao.qi@linaro.org>
16348
16349 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
16350 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
16351 output.
16352 (getpkt_or_notif_sane_1): Likewise.
16353
16354 2017-01-13 Yao Qi <yao.qi@linaro.org>
16355
16356 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
16357 of CC. Pass "-x c++-header" instead of "-x c".
16358
16359 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
16360
16361 * remote.c (remote_can_async_p): Update comment.
16362
16363 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
16364
16365 * linux-nat.c (linux_nat_can_async_p): Update comment.
16366
16367 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
16368
16369 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
16370
16371 2017-01-11 Simon Marchi <simon.marchi@ericsson.com>
16372
16373 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
16374
16375 2017-01-10 Tom Tromey <tom@tromey.com>
16376
16377 * python/py-type.c (typy_legacy_template_argument): Update.
16378 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
16379 ~demangle_parse_info): Declare new members.
16380 (cp_demangled_name_to_comp): Return unique_ptr.
16381 (cp_demangled_name_parse_free)
16382 (make_cleanup_cp_demangled_name_parse_free)
16383 (cp_new_demangle_parse_info): Remove.
16384 * cp-support.c (do_demangled_name_parse_free_cleanup)
16385 (make_cleanup_cp_demangled_name_parse_free): Remove.
16386 (inspect_type, cp_canonicalize_string_full)
16387 (cp_canonicalize_string): Update.
16388 (mangled_name_to_comp): Change return type.
16389 (cp_class_name_from_physname, method_name_from_physname)
16390 (cp_func_name, cp_remove_params): Update.
16391 * cp-name-parser.y (demangle_parse_info): New constructor, from
16392 cp_new_demangle_parse_info.
16393 (~demangle_parse_info): New destructor, from
16394 cp_demangled_name_parse_free.
16395 (cp_merge_demangle_parse_infos): Update.
16396 (cp_demangled_name_to_comp): Change return type.
16397
16398 2017-01-10 Tom Tromey <tom@tromey.com>
16399
16400 * top.c (prevent_dont_repeat): Change return type.
16401 * python/python.c (execute_gdb_command): Use std::string.
16402 Update.
16403 * guile/guile.c (gdbscm_execute_gdb_command): Update.
16404 * command.h (prevent_dont_repeat): Change return type.
16405 * breakpoint.c (bpstat_do_actions_1): Update.
16406
16407 2017-01-10 Tom Tromey <tom@tromey.com>
16408
16409 * value.h (scoped_value_mark::~scoped_value_mark): Call
16410 free_to_mark.
16411 (scoped_value_mark::free_to_mark): New method.
16412 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
16413 scoped_value_mark.
16414
16415 2017-01-10 Tom Tromey <tom@tromey.com>
16416
16417 * python/py-value.c (valpy_dereference, valpy_referenced_value)
16418 (valpy_reference_value, valpy_const_value, valpy_get_address)
16419 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
16420 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
16421 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
16422 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
16423 scoped_value_mark.
16424 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
16425 * value.h (scoped_value_mark): New class.
16426
16427 2017-01-10 Tom Tromey <tom@tromey.com>
16428
16429 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
16430 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
16431 * psymtab.c (discard_psymtabs_upto): Remove.
16432 (make_cleanup_discard_psymtabs): Remove.
16433 (struct psymtab_state): Remove.
16434
16435 2017-01-10 Tom Tromey <tom@tromey.com>
16436
16437 * record-full.c (record_full_save_cleanups): Remove.
16438 (record_full_save): Use gdb::unlinker.
16439 * gcore.c (do_bfd_delete_cleanup): Remove.
16440 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
16441 cleanups.
16442 * dwarf2read.c (unlink_if_set): Remove.
16443 (write_psymtabs_to_index): Use gdb::unlinker.
16444 * common/gdb_unlinker.h: New file.
16445
16446 2017-01-10 Tom Tromey <tom@tromey.com>
16447
16448 * windows-tdep.c (windows_xfer_shared_library): Update.
16449 * windows-nat.c (windows_make_so): Update.
16450 * utils.h (make_cleanup_bfd_unref): Remove.
16451 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
16452 * symfile.h (symfile_bfd_open)
16453 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
16454 * symfile.c (read_symbols, symbol_file_add)
16455 (separate_debug_file_exists): Update.
16456 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
16457 (generic_load, reread_symbols): Update.
16458 * symfile-mem.c (symbol_file_add_from_memory): Update.
16459 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
16460 (spu_symbol_file_add_from_memory): Update.
16461 * solist.h (struct target_so_ops) <bfd_open>: Return
16462 gdb_bfd_ref_ptr.
16463 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
16464 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
16465 gdb_bfd_ref_ptr.
16466 (solib_map_sections, reload_shared_libraries_1): Update.
16467 * solib-svr4.c (enable_break): Update.
16468 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
16469 * solib-frv.c (enable_break2): Update.
16470 * solib-dsbt.c (enable_break): Update.
16471 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
16472 gdb_bfd_ref_ptr.
16473 (darwin_solib_get_all_image_info_addr_at_init): Update.
16474 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
16475 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
16476 * record-full.c (record_full_save): Update.
16477 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
16478 * procfs.c (insert_dbx_link_bpt_in_file): Update.
16479 * minidebug.c (find_separate_debug_file_in_section): Return
16480 gdb_bfd_ref_ptr.
16481 * machoread.c (macho_add_oso_symfile): Change abfd to
16482 gdb_bfd_ref_ptr.
16483 (macho_symfile_read_all_oso): Update.
16484 (macho_check_dsym): Return gdb_bfd_ref_ptr.
16485 (macho_symfile_read): Update.
16486 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
16487 (jit_bfd_try_read_symtab): Update.
16488 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
16489 (gdb_bfd_openw, gdb_bfd_openr_iovec)
16490 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
16491 gdb_bfd_ref_ptr.
16492 (gdb_bfd_ref_policy): New struct.
16493 (gdb_bfd_ref_ptr): New typedef.
16494 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
16495 (gdb_bfd_openw, gdb_bfd_openr_iovec)
16496 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
16497 gdb_bfd_ref_ptr.
16498 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
16499 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
16500 (gcore_command): Update.
16501 * exec.c (exec_file_attach): Update.
16502 * elfread.c (elf_symfile_read): Update.
16503 * dwarf2read.c (dwarf2_get_dwz_file): Update.
16504 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
16505 (open_and_init_dwo_file): Update.
16506 (open_dwp_file): Return gdb_bfd_ref_ptr.
16507 (open_and_init_dwp_file): Update.
16508 * corelow.c (core_open): Update.
16509 * compile/compile-object-load.c (compile_object_load): Update.
16510 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
16511 * coffread.c (coff_symfile_read): Update.
16512 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
16513 gdb_bfd_ref_ptr. Rename.
16514 (dump_bfd_file, restore_command): Update.
16515 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
16516 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
16517 (find_separate_debug_file_by_buildid): Update.
16518
16519 2017-01-10 Tom Tromey <tom@tromey.com>
16520
16521 * common/gdb_ref_ptr.h: New file.
16522 * python/py-ref.h (struct gdbpy_ref_policy): New.
16523 (gdbpy_ref): Now a typedef.
16524
16525 2017-01-10 Tom Tromey <tom@tromey.com>
16526
16527 * utils.h (make_cleanup_htab_delete): Don't declare.
16528 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
16529 Remove.
16530 * linespec.c (decode_compound_collector): Add constructor,
16531 destructor.
16532 (lookup_prefix_sym): Remove cleanup.
16533 (symtab_collector): Add constructor, destructor.
16534 (collect_symtabs_from_filename): Remove cleanup.
16535 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
16536 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
16537 Use htab_up.
16538 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
16539 * dwarf2read.c (dw2_expand_symtabs_matching)
16540 (dw2_map_symbol_filenames, dwarf_decode_macros)
16541 (write_psymtabs_to_index): Use htab_up.
16542 * dwarf2loc.c (func_verify_no_selftailcall)
16543 (call_site_find_chain_1, func_verify_no_selftailcall)
16544 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
16545 std::vector, gdb::unique_xmalloc_ptr.
16546 (call_sitep): Remove typedef.
16547 (dwarf2_locexpr_baton_eval): Remove unused variable.
16548
16549 2017-01-10 Tom Tromey <tom@tromey.com>
16550
16551 * python/python-internal.h (make_cleanup_py_decref)
16552 (make_cleanup_py_xdecref): Don't declare.
16553 * python/py-utils.c (py_decref, make_cleanup_py_decref)
16554 (py_xdecref, make_cleanup_py_xdecref): Remove.
16555
16556 2017-01-10 Tom Tromey <tom@tromey.com>
16557
16558 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
16559 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
16560
16561 2017-01-10 Tom Tromey <tom@tromey.com>
16562
16563 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
16564
16565 2017-01-10 Tom Tromey <tom@tromey.com>
16566
16567 * python/py-utils.c (unicode_to_encoded_string)
16568 (python_string_to_target_string)
16569 (python_string_to_target_python_string)
16570 (python_string_to_host_string, gdbpy_obj_to_string)
16571 (get_addr_from_python): Use gdbpy_ref.
16572
16573 2017-01-10 Tom Tromey <tom@tromey.com>
16574
16575 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
16576 gdbpy_ref.
16577
16578 2017-01-10 Tom Tromey <tom@tromey.com>
16579
16580 * python/python.c (eval_python_command, gdbpy_decode_line)
16581 (gdbpy_run_events, gdbpy_start_type_printers)
16582 (gdbpy_apply_type_printers): Use gdbpy_ref.
16583
16584 2017-01-10 Tom Tromey <tom@tromey.com>
16585
16586 * python/py-param.c (get_doc_string, compute_enum_values): Use
16587 gdbpy_ref.
16588
16589 2017-01-10 Tom Tromey <tom@tromey.com>
16590
16591 * python/py-inferior.c (find_thread_object, build_inferior_list):
16592 Use gdbpy_ref.
16593
16594 2017-01-10 Tom Tromey <tom@tromey.com>
16595
16596 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
16597
16598 2017-01-10 Tom Tromey <tom@tromey.com>
16599
16600 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
16601 gdbpy_ref.
16602
16603 2017-01-10 Tom Tromey <tom@tromey.com>
16604
16605 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
16606 extra incref.
16607 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
16608 Use gdbpy_ref.
16609
16610 2017-01-10 Tom Tromey <tom@tromey.com>
16611
16612 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
16613 gdbpy_ref.
16614
16615 2017-01-10 Tom Tromey <tom@tromey.com>
16616
16617 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
16618 decref results of PyArg_ParseTupleAndKeywords.
16619
16620 2017-01-10 Tom Tromey <tom@tromey.com>
16621
16622 * python/python.c (python_run_simple_file): Use
16623 unique_xmalloc_ptr, gdbpy_ref.
16624
16625 2017-01-10 Tom Tromey <tom@tromey.com>
16626
16627 * python/py-prettyprint.c (print_stack_unless_memory_error)
16628 (print_string_repr, print_children): Use gdbpy_ref.
16629 (dummy_python_frame): New class.
16630 (dummy_python_frame::dummy_python_frame): Rename from
16631 push_dummy_python_frame.
16632 (py_restore_tstate): Remove.
16633
16634 2017-01-10 Tom Tromey <tom@tromey.com>
16635
16636 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
16637
16638 2017-01-10 Tom Tromey <tom@tromey.com>
16639
16640 * python/python.c (ensure_python_env, restore_python_env):
16641 Remove.
16642 * python/python-internal.h (ensure_python_env): Don't declare.
16643 * varobj.h (varobj_ensure_python_env): Don't declare.
16644 * varobj.c (varobj_ensure_python_env): Remove.
16645
16646 2017-01-10 Tom Tromey <tom@tromey.com>
16647
16648 * varobj.c (varobj_value_get_print_value): Use
16649 gdbpy_enter_varobj.
16650
16651 2017-01-10 Tom Tromey <tom@tromey.com>
16652
16653 * python/py-prettyprint.c (print_string_repr, print_children):
16654 Update.
16655 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
16656 of "encoding".
16657 * varobj.c (varobj_value_get_print_value): Update.
16658 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
16659
16660 2017-01-10 Tom Tromey <tom@tromey.com>
16661
16662 * varobj.c (varobj_get_display_hint)
16663 (dynamic_varobj_has_child_method, install_new_value_visualizer)
16664 (varobj_set_visualizer, free_variable): Use
16665 gdbpy_enter_varobj.
16666
16667 2017-01-10 Tom Tromey <tom@tromey.com>
16668
16669 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
16670 (do_finish_initialization): New function. Use gdbpy_ref.
16671 (gdbpy_finish_initialization): Use gdbpy_enter. Call
16672 do_finish_initialization.
16673
16674 2017-01-10 Tom Tromey <tom@tromey.com>
16675
16676 * python/py-param.c (get_set_value, get_show_value): Use
16677 gdbpy_enter, gdbpy_ref.
16678
16679 2017-01-10 Tom Tromey <tom@tromey.com>
16680
16681 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
16682
16683 2017-01-10 Tom Tromey <tom@tromey.com>
16684
16685 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
16686
16687 2017-01-10 Tom Tromey <tom@tromey.com>
16688
16689 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
16690 Use gdbpy_enter_varobj.
16691
16692 2017-01-10 Tom Tromey <tom@tromey.com>
16693
16694 * varobj.c (gdbpy_enter_varobj): New constructor.
16695 * python/python-internal.h (gdbpy_enter_varobj): New class.
16696 * python/py-varobj.c (py_varobj_get_iterator): Use
16697 gdbpy_enter_varobj.
16698
16699 2017-01-10 Tom Tromey <tom@tromey.com>
16700
16701 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
16702 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
16703 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
16704 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
16705 unique_xmalloc_ptr.
16706 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
16707
16708 2017-01-10 Tom Tromey <tom@tromey.com>
16709
16710 * python/py-xmethods.c (invoke_match_method): Use
16711 gdbpy_ref.
16712
16713 2017-01-10 Tom Tromey <tom@tromey.com>
16714
16715 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
16716 gdbpy_enter, gdbpy_ref.
16717
16718 2017-01-10 Tom Tromey <tom@tromey.com>
16719
16720 * python/python.c (python_interactive_command): Use gdbpy_enter.
16721
16722 2017-01-10 Tom Tromey <tom@tromey.com>
16723
16724 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
16725 gdbpy_ref.
16726
16727 2017-01-10 Tom Tromey <tom@tromey.com>
16728
16729 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
16730 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
16731
16732 2017-01-10 Tom Tromey <tom@tromey.com>
16733
16734 * utils.h (htab_deleter): New struct.
16735 (htab_up): New typedef.
16736 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
16737 gdbpy_enter, gdbpy_ref, htab_up.
16738
16739 2017-01-10 Tom Tromey <tom@tromey.com>
16740
16741 * python/py-unwind.c (pending_frame_invalidate): Remove.
16742 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
16743
16744 2017-01-10 Tom Tromey <tom@tromey.com>
16745
16746 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
16747 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
16748
16749 2017-01-10 Tom Tromey <tom@tromey.com>
16750
16751 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
16752
16753 2017-01-10 Tom Tromey <tom@tromey.com>
16754
16755 * python/python.c (gdbpy_eval_from_control_command)
16756 (gdbpy_source_script, gdbpy_run_events)
16757 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
16758 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
16759 gdbpy_enter.
16760
16761 2017-01-10 Tom Tromey <tom@tromey.com>
16762
16763 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
16764
16765 2017-01-10 Tom Tromey <tom@tromey.com>
16766
16767 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
16768
16769 2017-01-10 Tom Tromey <tom@tromey.com>
16770
16771 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
16772 (python_on_inferior_call_pre, python_on_inferior_call_post)
16773 (python_on_memory_change, python_on_register_change)
16774 (python_inferior_exit, python_new_objfile, add_thread_object)
16775 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
16776
16777 2017-01-10 Tom Tromey <tom@tromey.com>
16778
16779 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
16780 (bpfinishpy_handle_exit): Use gdbpy_enter.
16781
16782 2017-01-10 Tom Tromey <tom@tromey.com>
16783
16784 * python/py-cmd.c (cmdpy_destroyer)
16785 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
16786 gdbpy_enter.
16787
16788 2017-01-10 Tom Tromey <tom@tromey.com>
16789
16790 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
16791 gdbpy_enter.
16792 (gdbpy_breakpoint_has_cond): Likewise.
16793
16794 2017-01-10 Tom Tromey <tom@tromey.com>
16795
16796 * python/python.c (gdbpy_enter): New constructor.
16797 (~gdbpy_enter): New destructor.
16798 (restore_python_env, ensure_python_env): Rewrite.
16799 * python/python-internal.h (gdbpy_enter): New class.
16800
16801 2017-01-10 Tom Tromey <tom@tromey.com>
16802
16803 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
16804
16805 2017-01-10 Tom Tromey <tom@tromey.com>
16806
16807 * python/py-value.c (value_has_field, get_field_flag)
16808 (get_field_type, valpy_getitem, convert_value_from_python): Use
16809 gdbpy_ref.
16810
16811 2017-01-10 Tom Tromey <tom@tromey.com>
16812
16813 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
16814 gdbpy_ref.
16815
16816 2017-01-10 Tom Tromey <tom@tromey.com>
16817
16818 * python/py-prettyprint.c (search_pp_list)
16819 (find_pretty_printer_from_objfiles)
16820 (find_pretty_printer_from_progspace)
16821 (find_pretty_printer_from_gdb, find_pretty_printer)
16822 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
16823 gdbpy_ref.
16824
16825 2017-01-10 Tom Tromey <tom@tromey.com>
16826
16827 * python/py-param.c (call_doc_function): Use gdbpy_ref.
16828
16829 2017-01-10 Tom Tromey <tom@tromey.com>
16830
16831 * python/py-linetable.c (build_line_table_tuple_from_pcs)
16832 (ltpy_get_all_source_lines): Use gdbpy_ref.
16833
16834 2017-01-10 Tom Tromey <tom@tromey.com>
16835
16836 * python/py-framefilter.c (extract_sym, extract_value)
16837 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
16838 gdbpy_ref.
16839
16840 2017-01-10 Tom Tromey <tom@tromey.com>
16841
16842 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
16843
16844 2017-01-10 Tom Tromey <tom@tromey.com>
16845
16846 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
16847
16848 2017-01-10 Tom Tromey <tom@tromey.com>
16849
16850 * python/py-function.c (convert_values_to_python, fnpy_init): Use
16851 gdbpy_ref.
16852
16853 2017-01-10 Tom Tromey <tom@tromey.com>
16854
16855 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
16856
16857 2017-01-10 Tom Tromey <tom@tromey.com>
16858
16859 * python/py-type.c (convert_field, make_fielditem, typy_fields)
16860 (typy_range): Use gdbpy_ref.
16861
16862 2017-01-10 Tom Tromey <tom@tromey.com>
16863
16864 * python/py-threadevent.c (create_thread_event_object): Use
16865 gdbpy_ref.
16866 * python/py-stopevent.c (create_stop_event_object): Simplify.
16867 (emit_stop_event): Use gdbpy_ref.
16868 * python/py-signalevent.c (create_signal_event_object): Use
16869 gdbpy_ref.
16870 * python/py-newobjfileevent.c (create_new_objfile_event_object)
16871 (emit_new_objfile_event, create_clear_objfiles_event_object)
16872 (emit_clear_objfiles_event): Use gdbpy_ref.
16873 * python/py-infevents.c (create_inferior_call_event_object)
16874 (create_register_changed_event_object)
16875 (create_memory_changed_event_object, emit_inferior_call_event)
16876 (emit_memory_changed_event, emit_register_changed_event): Use
16877 gdbpy_ref.
16878 * python/py-exitedevent.c (create_exited_event_object)
16879 (emit_exited_event): Use gdbpy_ref.
16880 * python/py-event.h (evpy_emit_event): Remove
16881 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
16882 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
16883 * python/py-continueevent.c (emit_continue_event): Use
16884 gdbpy_ref.
16885 * python/py-breakpoint.c (gdbpy_breakpoint_created)
16886 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
16887 gdbpy_ref.
16888 * python/py-bpevent.c (create_breakpoint_event_object): Use
16889 gdbpy_ref.
16890
16891 2017-01-10 Tom Tromey <tom@tromey.com>
16892
16893 * python/py-ref.h: New file.
16894
16895 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
16896
16897 * cli-out.c (cli_ui_out::do_redirect): Change return type to
16898 void.
16899 * cli-out.h (cli_ui_out::do_redirect): Likewise.
16900 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
16901 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
16902 * ui-out.c (ui_out::redirect): Likewise.
16903 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
16904 * cli/cli-logging.c (set_logging_redirect): Update call site of
16905 ui_out::redirect.
16906 (handle_redirections): Likewise.
16907 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
16908 * top.c (execute_command_to_string): Likewise.
16909 * utils.c (do_ui_out_redirect_pop): Likewise.
16910
16911 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
16912
16913 * stack.c (_initialize_stack): Update "frame" command help message.
16914
16915 2017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
16916
16917 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
16918
16919 2017-01-06 Yao Qi <yao.qi@linaro.org>
16920
16921 * x86-linux-nat.h: Include gdb_proc_service.h.
16922
16923 2017-01-06 Yao Qi <yao.qi@linaro.org>
16924
16925 * ser-base.h: Include serial.h.
16926
16927 2017-01-06 Yao Qi <yao.qi@linaro.org>
16928
16929 * ppc-linux-tdep.h: Include ppc-tdep.h.
16930
16931 2017-01-06 Yao Qi <yao.qi@linaro.org>
16932
16933 * nat/amd64-linux-siginfo.h: Include signal.h.
16934
16935 2017-01-06 Yao Qi <yao.qi@linaro.org>
16936
16937 * nat/aarch64-linux-hw-point.h: Include break-common.h.
16938
16939 2017-01-06 Yao Qi <yao.qi@linaro.org>
16940
16941 * mi/mi-parse.h: Include mi-cmds.h.
16942
16943 2017-01-06 Yao Qi <yao.qi@linaro.org>
16944
16945 * inf-loop.c: Don't include "target.h".
16946 * inf-loop.h: Include it here.
16947
16948 2017-01-06 Yao Qi <yao.qi@linaro.org>
16949
16950 * dfp.h: Include "dboulest.h" and "expression.h".
16951
16952 2017-01-06 Yao Qi <yao.qi@linaro.org>
16953
16954 * ax-gdb.h: Include "ax.h".
16955
16956 2017-01-06 Yao Qi <yao.qi@linaro.org>
16957
16958 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
16959 with nat/gdb_ptrace.h.
16960
16961 2017-01-05 Yao Qi <yao.qi@linaro.org>
16962
16963 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
16964 new line.
16965 (mips64_fbsd_sigframe_init): Likewise.
16966
16967 2017-01-04 John Baldwin <jhb@FreeBSD.org>
16968
16969 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
16970 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
16971
16972 2017-01-04 John Baldwin <jhb@FreeBSD.org>
16973
16974 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
16975 * NEWS: Mention new FreeBSD/mips native configuration.
16976 * config/mips/fbsd.mh: New file.
16977 * configure.host: Add mips*-*-freebsd*.
16978 * mips-fbsd-nat.c: New file.
16979
16980 2017-01-04 John Baldwin <jhb@FreeBSD.org>
16981
16982 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
16983 (ALLDEPFILES): Add mips-fbsd-tdep.c.
16984 * NEWS: Mention new FreeBSD/mips target.
16985 * configure.tgt: Add mips*-*-freebsd*.
16986 * mips-fbsd-tdep.c: New file.
16987 * mips-fbsd-tdep.h: New file.
16988
16989 2017-01-04 Yao Qi <yao.qi@linaro.org>
16990
16991 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
16992 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
16993
16994 2017-01-01 Joel Brobecker <brobecker@adacore.com>
16995
16996 Update copyright year range in all GDB files.
16997
16998 2017-01-01 Joel Brobecker <brobecker@adacore.com>
16999
17000 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
17001
17002 For older changes see ChangeLog-2016.
17003 \f
17004 Local Variables:
17005 mode: change-log
17006 left-margin: 8
17007 fill-column: 74
17008 version-control: never
17009 coding: utf-8
17010 End:
This page took 0.35499 seconds and 5 git commands to generate.