Update find command help and search memory docs
[deliverable/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
ee9a09e9
DC
12017-11-26 Dominik Czarnota <dominik.b.czarnota@gmail.com>
2
3 PR gdb/21945
4 * findcmd.c (_initialize_mem_search): Update find command help
5 text.
6
e8e7d10c
SM
72017-11-26 Simon Marchi <simon.marchi@polymtl.ca>
8
9 * python/python.c (do_start_initialization): Change progname
10 type to gdb::unique_xmalloc_ptr. Release the pointer when using
11 Python 2.
12
6a997029
TT
132017-11-26 Tom Tromey <tom@tromey.com>
14
15 * common/format.h: Add include guards.
16
41272101
TT
172017-11-26 Tom Tromey <tom@tromey.com>
18
19 * nat/linux-personality.h (class
20 maybe_disable_address_space_randomization): New class.
21 (maybe_disable_address_space_randomization): Don't declare
22 function.
23 * nat/linux-personality.c (restore_personality)
24 (make_disable_asr_cleanup): Remove.
25 (maybe_disable_address_space_randomization): Now a constructor.
26 (~maybe_disable_address_space_randomization): New destructor.
27 * linux-nat.c (linux_nat_create_inferior): Update.
28
44287fd8
TT
292017-11-26 Tom Tromey <tom@tromey.com>
30
31 * gcore.c (write_gcore_file_1): Use gdb::unique_xmalloc_ptr.
32
5ffd2cb7
UW
332017-11-26 Ulrich Weigand <uweigand@de.ibm.com>
34
35 * spu-tdep.c (spu_software_single_step): Access SPU_LSLR_REGNUM as
36 "cooked" register. Access only first four bytes of branch target
37 registers.
38
0e5457dc
SDJ
392017-11-25 Sergio Durigan Junior <sergiodj@redhat.com>
40
41 PR gdb/22491
42 * stap-probe.c (relocate_address): New function.
43 (stap_probe::get_relocated_address): Use 'relocate_address'.
44 (stap_probe::set_semaphore): Use 'relocate_address' and pass
45 'm_sem_addr'.
46 (stap_probe::clear_semaphore): Likewise.
47
deeeba55
PA
482017-11-25 Pedro Alves <palves@redhat.com>
49
50 * dictionary.c: Include "safe-ctype.h".
51 * minsyms.c: Include "safe-ctype.h".
52 * minsyms.c (SYMBOL_HASH_NEXT): Use TOLOWER instead of tolower.
53
a81aaca0
PA
542017-11-25 Pedro Alves <palves@redhat.com>
55
56 * completer.c (complete_line_internal_1): Skip spaces until the
57 start of the command.
58
0662b6a7
PA
592017-11-24 Pedro Alves <palves@redhat.com>
60
61 * cp-support.c (cp_symbol_name_matches_1): New, factored out from
62 cp_fq_symbol_name_matches. Pass language_cplus to
63 strncmp_with_mode.
64 (cp_fq_symbol_name_matches): Call cp_symbol_name_matches_1.
65 (selftests::test_cp_symbol_name_cmp): New.
66 (_initialize_cp_support): Register "cp_symbol_name_matches"
67 selftests.
68 * language.c (default_symbol_name_matcher): Pass language_minimal
69 to strncmp_iw_with_mode.
70 * utils.c: Include "cp-support.h" and <algorithm>.
71 (valid_identifier_name_char, cp_skip_operator_token, skip_ws)
72 (cp_is_operator): New functions.
73 (strncmp_iw_with_mode): Use them. Add language parameter. Don't
74 skip whitespace in the symbol name when the lookup name doesn't
75 have spaces, and vice versa.
76 (strncmp_iw, strcmp_iw): Pass language to strncmp_iw_with_mode.
77 * utils.h (strncmp_iw_with_mode): Add language parameter.
78
e547c119
JB
792017-11-24 Joel Brobecker <brobecker@adacore.com>
80
81 * ada-lang.c (ada_exception_message_1, ada_exception_message):
82 New functions.
83 (print_it_exception): If available, display the exception
84 message as well.
85 * NEWS: Document new feature.
86
d7fcdff9
UW
872017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
88
89 * configure.nat <spu-linux>: Add fork-inferior.o to NATDEPFILES.
90
30649c14
PR
912017-11-24 Philipp Rudo <prudo@linux.vnet.ibm.com>
92
93 * dtrace-probe.c (dtrace_probe::build_arg_exprs)
94 (dtrace_probe::is_enabled, dtrace_probe::enable)
95 (dtrace_probe::disable): Remove keyword 'struct' at for-range
96 variable
97 * probe.c (gen_ui_out_table_header_info)
98 (print_ui_out_not_applicables): Remove keyword 'struct' at
99 for-range variable
100
7696f5c9
AH
1012017-11-24 Alan Hayward <alan.hayward@arm.com>
102
103 * configure.tgt: Add arch/aarch64.o
104
8172f16b
SM
1052017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
106
107 * common/common-utils.h: Include poison.h.
108 (xfree): Remove declaration, add definition with static_assert.
109 * common/common-utils.c (xfree): Remove.
110 * common/poison.h (IsMallocatable): Define.
111 (IsFreeable): Define.
112 (free): Delete for non-freeable types.
113 (xnew): New.
114 (XNEW): Undef and redefine.
115 (xcnew): New.
116 (XCNEW): Undef and redefine.
117 (xdelete): New.
118 (XDELETE): Undef and redefine.
119 (xnewvec): New.
120 (XNEWVEC): Undef and redefine.
121 (xcnewvec): New.
122 (XCNEWVEC): Undef and redefine.
123 (xresizevec): New.
124 (XRESIZEVEC): Undef and redefine.
125 (xdeletevec): New.
126 (XDELETEVEC): Undef and redefine.
127 (xnewvar): New.
128 (XNEWVAR): Undef and redefine.
129 (xcnewvar): New.
130 (XCNEWVAR): Undef and redefine.
131 (xresizevar): New.
132 (XRESIZEVAR): Undef and redefine.
133
7aabaf9d
SM
1342017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
135
136 * gdbthread.h (private_thread_info): Define structure type, add
137 virtual pure destructor.
138 (thread_info) <priv>: Change type to unique_ptr.
139 <private_dtor>: Remove.
140 * thread.c (add_thread_with_info): Adjust to use of unique_ptr.
141 (private_thread_info::~private_thread_info): Provide default
142 implementation.
143 (thread_info::~thread_info): Don't call private_dtor nor
144 manually free priv.
145 * aix-thread.c (private_thread_info): Rename to ...
146 (aix_thread_info): ... this.
147 (get_aix_thread_info): New.
148 (sync_threadlists): Adjust.
149 (iter_tid): Adjust.
150 (aix_thread_resume): Adjust.
151 (aix_thread_fetch_registers): Adjust.
152 (aix_thread_store_registers): Adjust.
153 (aix_thread_extra_thread_info): Adjust.
154 * darwin-nat.h (private_thread_info): Rename to ...
155 (darwin_thread_info): ... this.
156 (get_darwin_thread_info): New.
157 * darwin-nat.c (darwin_init_thread_list): Adjust.
158 (darwin_check_new_threads): Adjust.
159 (thread_info_from_private_thread_info): Adjust.
160 * linux-thread-db.c (private_thread_info): Rename to ...
161 (thread_db_thread_info): ... this, initialize fields.
162 (get_thread_db_thread_info): New.
163 <dying>: Change type to bool.
164 (update_thread_state): Adjust to type rename.
165 (record_thread): Adjust to type rename an use of unique_ptr.
166 (thread_db_pid_to_str): Likewise.
167 (thread_db_extra_thread_info): Likewise.
168 (thread_db_thread_handle_to_thread_info): Likewise.
169 (thread_db_get_thread_local_address): Likewise.
170 * nto-tdep.h (private_thread_info): Rename to ...
171 (nto_thread_info): ... this, initialize fields.
172 (get_nto_thread_info): New.
173 <name>: Change type to std::string.
174 * nto-tdep.c (nto_extra_thread_info): Adjust to type rename and
175 use of unique_ptr.
176 * nto-procfs.c (update_thread_private_data_name): Adjust to
177 std::string change, allocate nto_private_thread_info with new.
178 (update_thread_private_data): Adjust to unique_ptr.
179 * remote.c (private_thread_info): Rename to ...
180 (remote_thread_info): ... this, initialize data members with
181 default values.
182 <extra, name>: Change type to std::string.
183 <thread_handle>: Change type to non-pointer.
184 (free_private_thread_info): Remove.
185 (get_private_info_thread): Rename to...
186 (get_remote_thread_info): ... this, change return type, adjust to
187 use of unique_ptr, use remote_thread_info constructor.
188 (remote_add_thread): Adjust.
189 (get_private_info_ptid): Rename to...
190 (get_remote_thread_info): ...this, change return type.
191 (remote_thread_name): Use get_remote_thread_info, adjust to
192 change to std::string.
193 (struct thread_item) <~thread_item>: Remove.
194 <thread_handle>: Make non pointer.
195 (start_thread): Adjust to thread_item::thread_handle type
196 change.
197 (remote_update_thread_list): Adjust to type name change, move
198 strings from temporary to long-lived object instead of
199 duplicating.
200 (remote_threads_extra_info): Use get_remote_thread_info.
201 (process_initial_stop_replies): Likewise.
202 (resume_clear_thread_private_info): Likewise.
203 (remote_resume): Adjust to type name change.
204 (remote_commit_resume): Use get_remote_thread_info.
205 (process_stop_reply): Adjust to type name change.
206 (remote_stopped_by_sw_breakpoint): Use get_remote_thread_info.
207 (remote_stopped_by_hw_breakpoint): Likewise.
208 (remote_stopped_by_watchpoint): Likewise.
209 (remote_stopped_data_address): Likewise.
210 (remote_core_of_thread): Likewise.
211 (remote_thread_handle_to_thread_info): Use
212 get_private_info_thread, adjust to thread_handle field type
213 change.
214
21fe1c75
SM
2152017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
216
217 * remote.c (struct thread_item): Add constructor, disable copy
218 construction and copy assignment, define default move
219 construction and move assignment.
220 <extra, name>: Change type to std::string.
221 <core>: Initialize.
222 <thread_handle>: Make non-pointer.
223 (thread_item_t): Remove typedef.
224 (DEF_VEC_O(thread_item_t)): Remove.
225 (threads_listing_context) <contains_thread>: New method.
226 <remove_thread>: New method.
227 <items>: Change type to std::vector.
228 (clear_threads_listing_context): Remove.
229 (threads_listing_context_remove): Remove.
230 (remote_newthread_step): Use thread_item constructor, adjust to
231 change to std::vector.
232 (start_thread): Use thread_item constructor, adjust to change to
233 std::vector.
234 (end_thread): Adjust to change to std::vector and std::string.
235 (remote_get_threads_with_qthreadinfo): Use thread_item
236 constructor, adjust to std::vector.
237 (remote_update_thread_list): Adjust to change to std::vector and
238 std::string, use threads_listing_context methods.
239 (remove_child_of_pending_fork): Adjust.
240 (remove_new_fork_children): Adjust.
241 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add rsp-low-selftests.c.
242 (SUBDIR_UNITTESTS_OBS): Add rsp-low-selftests.o.
243 * unittests/rsp-low-selftests.c: New file.
244 * common/rsp-low.h: Include common/byte-vector.h.
245 (hex2bin): New overload.
246 * common/rsp-low.c (hex2bin): New overload.
247
089354bb
SM
2482017-11-24 Simon Marchi <simon.marchi@ericsson.com>
249
250 * inferior.h (private_inferior): Define structure type, add
251 virtual pure destructor.
252 (inferior) <priv>: Change type to unique_ptr.
253 * inferior.c (private_inferior::~private_inferior): Provide
254 default implementation.
255 (inferior::~inferior): Don't free priv field.
256 (exit_inferior_1): Likewise.
257 * darwin-nat.h (struct darwin_exception_info): Initialize fields.
258 (darwin_exception_info): Remove typedef.
259 (DEF_VEC_O (darwin_thread_t)); Remove.
260 (private_inferior): Rename to ...
261 (darwin_private_inferior): ... this, extend private_inferior.
262 (get_darwin_inferior): New.
263 <threads>: Change type to std::vector of darwin_thread_t pointers.
264 * darwin-nat.c (darwin_check_new_threads): Adjust.
265 (find_inferior_task_it): Adjust.
266 (darwin_find_thread); Adjust.
267 (darwin_suspend_inferior): Adjust.
268 (darwin_resume_inferior): Adjust.
269 (darwin_find_new_inferior): Adjust.
270 (darwin_decode_notify_message): Adjust.
271 (darwin_send_reply): Adjust.
272 (darwin_resume_inferior_threads): Adjust.
273 (darwin_suspend_inferior_threads): Adjust.
274 (darwin_decode_message): Adjust.
275 (darwin_wait): Adjust.
276 (darwin_interrupt): Adjust.
277 (darwin_deallocate_threads): Adjust.
278 (darwin_mourn_inferior): Adjust, don't free private data.
279 (darwin_reply_to_all_pending_messages): Adjust.
280 (darwin_stop_inferior): Adjust.
281 (darwin_setup_exceptions): Adjust.
282 (darwin_kill_inferior): Adjust.
283 (darwin_setup_request_notification): Adjust.
284 (darwin_attach_pid): Adjust.
285 (darwin_init_thread_list): Adjust.
286 (darwin_setup_fake_stop_event): Adjust.
287 (darwin_attach): Adjust.
288 (darwin_detach): Adjust.
289 (darwin_xfer_partial): Adjust.
290 (set_enable_mach_exceptions): Adjust.
291 (darwin_pid_to_exec_file): Adjust.
292 (darwin_get_ada_task_ptid): Adjust.
293 * darwin-nat-info.c (get_task_from_args): Adjust.
294 (info_mach_ports_command): Adjust.
295 (info_mach_region_command): Adjust.
296 (info_mach_exceptions_command): Adjust.
297 * remote.c (private_inferior): Rename to ...
298 (remote_private_inferior): ... this, initialize fields.
299 (get_remote_inferior); New.
300 (remote_commit_resume): Use get_remote_inferior.
301 (check_pending_event_prevents_wildcard_vcont_callback): Likewise.
302
d044bac8
PA
3032017-11-24 Pedro Alves <palves@redhat.com>
304
305 * NEWS: Mention linespecs and explicit locations, and completion
306 improvements.
307
e8d58cba
YQ
3082017-11-24 Yao Qi <yao.qi@linaro.org>
309
310 * regcache.c (regcache::dump): Remove footnote_register_size.
311
a63f2d2f
YQ
3122017-11-24 Yao Qi <yao.qi@linaro.org>
313
314 * regcache.c (cooked_read_test): Add more test for readonly
315 regcache.
316
1b30aaa5
YQ
3172017-11-24 Yao Qi <yao.qi@linaro.org>
318
319 * gdbarch-selftests.c (test_target_has_registers): Move it to
320 target.c.
321 (test_target_has_stack): Likewise.
322 (test_target_has_memory): Likewise.
323 (test_target_prepare_to_store): Likewise.
324 (test_target_store_registers): Likewise.
325 (test_target_ops): Likewise.
326 * regcache.c: Include selftest-arch.h and gdbthread.h.
327 (target_ops_no_register): New class.
328 (test_target_fetch_registers): New.
329 (test_target_store_registers): New.
330 (test_target_xfer_partial): New.
331 (readwrite_regcache): New.
332 (cooked_read_test): New.
333 (_initialize_regcache): Register the test.
334 * target.c: (test_target_has_registers): Moved from
335 gdbarch-selftests.c.
336 (test_target_has_stack): Likewise.
337 (test_target_has_memory): Likewise.
338 (test_target_prepare_to_store): Likewise.
339 (test_target_store_registers): Likewise.
340 * target.h (test_target_ops): New class.
341
6654d750
AH
3422017-11-24 Alan Hayward <alan.hayward@arm.com>
343
344 * aarch64-tdep.c (_initialize_aarch64_tdep): Add target desc
345 selftest.
346
49bdb7ee
AH
3472017-11-24 Alan Hayward <alan.hayward@arm.com>
348
349 * aarch64-tdep.c (_initialize_aarch64_tdep): Remove init.
350 * arch/aarch64.c (aarch64_create_target_description): Create
351 new target description.
352 * features/Makefile: Add new files.
353 * features/aarch64.c: Remove file.
354 * features/aarch64-core.c: New autogenerated file.
355 * features/aarch64-fpu.c: New autogenerated file.
356 * target-descriptions.c (maint_print_c_tdesc_cmd): Check for aarch64.
da434ccb
AH
357
3582017-11-24 Alan Hayward <alan.hayward@arm.com>
359
360 * Makefile.in: Add new files.
361 * aarch64-linux-nat.c (aarch64_linux_read_description): Call
362 aarch64_read_description.
363 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
364 Call aarch64_read_description.
365 * aarch64-tdep.c (aarch64_read_description): New function.
366 (aarch64_gdbarch_init): Call aarch64_read_description.
367 * aarch64-tdep.h (aarch64_read_description): New function.
368 * arch/aarch64.c: New file.
369 * configure.tgt: Add new files.
370
98ead37e
YQ
3712017-11-24 Yao Qi <yao.qi@linaro.org>
372
373 * mi/mi-main.c (register_changed_p): Update.
374 * value.c (value_contents_bits_eq): Change return type.
375 (value_contents_eq): Likewise.
376 * value.h: Update comments.
377
62ad7ce7
YQ
3782017-11-24 Yao Qi <yao.qi@linaro.org>
379
380 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Remove
381 local 'changed'. Remove error.
382 (register_changed_p): Change return type to bool.
383
506fe5f4
YQ
3842017-11-24 Yao Qi <yao.qi@linaro.org>
385
386 * arch/tic6x.c: New file.
387 * arch/tic6x.h: New file.
388 * features/Makefile (FEATURE_XMLFILES): Add tic6x-c6xp.xml,
389 tic6x-core.xml and tic6x-gp.xml.
390 * features/tic6x-c6xp.c: Generated.
391 * features/tic6x-core.c: Generated.
392 * features/tic6x-gp.c: Generated.
393 * target-descriptions.c (maint_print_c_tdesc_cmd): Match
394 "tic6x-".
395
00ea2e2a
SM
3962017-11-23 Simon Marchi <simon.marchi@ericsson.com>
397
398 * mi/mi-main.c (list_available_thread_groups): Change map value
399 type to std::vector.
400
f45e2a77
SM
4012017-11-23 Simon Marchi <simon.marchi@ericsson.com>
402
403 * osdata.c (osdata_end_column, get_osdata): Remove std::move.
404
bd046f64
SM
4052017-11-23 Simon Marchi <simon.marchi@ericsson.com>
406
407 * varobj.c (struct varobj_dynamic) <children_requested_>: Rename
408 back to...
409 <children_requested>: ... this.
410 (varobj_get_num_children, varobj_update): Adjust.
411
4c37490d
SM
4122017-11-23 Simon Marchi <simon.marchi@ericsson.com>
413
414 * ada-varobj.c (ada_value_is_changeable_p): Change int to bool where applicable.
415 (ada_value_has_mutated): Likewise.
416 * c-varobj.c (varobj_is_anonymous_child): Likewise.
417 (c_is_path_expr_parent): Likewise.
418 * mi/mi-cmd-var.c (varobj_update_one): Likewise.
419 (mi_cmd_var_set_frozen): Likewise.
420 (mi_cmd_var_update_iter): Likewise.
421 (mi_cmd_var_update): Likewise.
422 * varobj.c (pretty_printing): Likewise.
423 (varobj_enable_pretty_printing): Likewise.
424 (struct varobj_root) <floating, is_valid>: Likewise.
425 (struct varobj_dynamic) <children_requested>: Likewise.
426 (delete_variable): Likewise.
427 (delete_variable_1): Likewise.
428 (install_variable): Likewise.
429 (update_type_if_necessary): Likewise.
430 (install_new_value): Likewise.
431 (value_of_root): Likewise.
432 (is_root_p): Likewise.
433 (varobj_create): Likewise.
434 (varobj_delete): Likewise.
435 (varobj_has_more): Likewise.
436 (varobj_set_frozen): Likewise.
437 (varobj_get_frozen): Likewise.
438 (install_dynamic_child): Likewise.
439 (dynamic_varobj_has_child_method): Likewise.
440 (update_dynamic_varobj_children): Likewise.
441 (varobj_get_num_children): Likewise.
442 (varobj_list_children): Likewise.
443 (is_path_expr_parent): Likewise.
444 (varobj_default_is_path_expr_parent): Likewise.
445 (varobj_is_dynamic_p): Likewise.
446 (varobj_set_value): Likewise.
447 (varobj_value_has_mutated): Likewise.
448 (varobj_update): Likewise.
449 (check_scope): Likewise.
450 (value_of_root_1): Likewise.
451 (varobj_value_get_print_value): Likewise.
452 (varobj_editable_p): Likewise.
453 (varobj_value_is_changeable_p): Likewise.
454 (varobj_floating_p): Likewise.
455 (varobj_default_value_is_changeable_p): Likewise.
456 (varobj_invalidate_iter): Likewise.
457 * varobj.h (struct varobj_update_result) <type_changed,
458 children_changed, changed, value_installed>: Likewise.
459 (struct varobj) <updated, frozen, not_fetched>: Likewise.
460 (struct lang_varobj_ops) <value_is_changeable_p,
461 value_has_mutated, is_path_expr_parent>: Likewise.
462 (varobj_delete): Likewise.
463 (varobj_set_frozen): Likewise.
464 (varobj_get_frozen): Likewise.
465 (varobj_set_value): Likewise.
466 (varobj_update): Likewise.
467 (varobj_editable_p): Likewise.
468 (varobj_floating_p): Likewise.
469 (varobj_has_more): Likewise.
470 (varobj_is_dynamic_p): Likewise.
471 (varobj_default_value_is_changeable_p): Likewise.
472 (varobj_value_is_changeable_p): Likewise.
473 (varobj_is_anonymous_child): Likewise.
474 (varobj_default_is_path_expr_parent): Likewise.
475
9c23b42f
SDJ
4762017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
477
478 * dtrace-probe.c (struct probe_ops dtrace_probe_ops): Delete.
479 (struct dtrace_probe_arg) <dtrace_probe_arg>: New constructor.
480 <type_str>: Convert to 'std::string'.
481 <expr>: Convert to 'expression_up'.
482 (dtrace_probe_arg_s): Delete type and VEC.
483 (dtrace_probe_enabler_s): Likewise.
484 (struct dtrace_probe): Replace by...
485 (class dtrace_static_probe_ops): ...this and...
486 (class dtrace_probe): ...this.
487 (dtrace_probe_is_linespec): Rename to...
488 (dtrace_static_probe_ops::is_linespec): ...this. Adjust code
489 to reflect change.
490 (dtrace_process_dof_probe): Use 'std::vector' instead of VEC.
491 Adjust code. Create new instance of 'dtrace_probe'.
492 (dtrace_build_arg_exprs): Rename to...
493 (dtrace_probe::build_arg_exprs): ...this. Adjust code to
494 reflect change.
495 (dtrace_get_probes): Rename to...
496 (dtrace_static_probe_ops::get_probes): ...this. Adjust code
497 to reflect change.
498 (dtrace_get_arg): Rename to...
499 (dtrace_probe::get_arg_by_number): ...this. Adjust code to
500 reflect change.
501 (dtrace_probe_is_enabled): Rename to...
502 (dtrace_probe::is_enabled): ...this. Adjust code to reflect
503 change.
504 (dtrace_get_probe_address): Rename to...
505 (dtrace_probe::get_relocated_address): ...this. Adjust code
506 to reflect change.
507 (dtrace_get_probe_argument_count): Rename to...
508 (dtrace_probe::get_argument_count): ...this. Adjust code to
509 reflect change.
510 (dtrace_can_evaluate_probe_arguments): Rename to...
511 (dtrace_probe::can_evaluate_arguments): ...this. Adjust code
512 to reflect change.
513 (dtrace_evaluate_probe_argument): Rename to...
514 (dtrace_probe::evaluate_argument): ...this. Adjust code to
515 reflect change.
516 (dtrace_compile_to_ax): Rename to...
517 (dtrace_probe::compile_to_ax): ...this. Adjust code to
518 reflect change.
519 (dtrace_probe_destroy): Delete.
520 (dtrace_type_name): Rename to...
521 (dtrace_static_probe_ops::type_name): ...this. Adjust code to
522 reflect change.
523 (dtrace_probe::get_static_ops): New method.
524 (dtrace_gen_info_probes_table_header): Rename to...
525 (dtrace_static_probe_ops::gen_info_probes_table_header):
526 ...this. Adjust code to reflect change.
527 (dtrace_gen_info_probes_table_values): Rename to...
528 (dtrace_probe::gen_info_probes_table_values): ...this. Adjust
529 code to reflect change.
530 (dtrace_enable_probe): Rename to...
531 (dtrace_probe::enable_probe): ...this. Adjust code to reflect
532 change.
533 (dtrace_disable_probe): Rename to...
534 (dtrace_probe::disable_probe): ...this. Adjust code to reflect
535 change.
536 (struct probe_ops dtrace_probe_ops): Delete.
537 (info_probes_dtrace_command): Call 'info_probes_for_spops'
538 instead of 'info_probes_for_ops'.
539 (_initialize_dtrace_probe): Use 'all_static_probe_ops' instead
540 of 'all_probe_ops'.
541
0e9ae10f
SDJ
5422017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
543 Simon Marchi <simark@simark.ca>
544
545 * stap-probe.c (struct probe_ops stap_probe_ops): Delete
546 variable.
547 (struct stap_probe_arg) <stap_probe_arg>: New constructor.
548 <aexpr>: Change type to 'expression_up'.
549 (stap_probe_arg_s): Delete type and VEC.
550 (struct stap_probe): Delete. Replace by...
551 (class stap_static_probe_ops): ...this and...
552 (class stap_probe): ...this. Rename variables to add 'm_'
553 prefix. Do not use 'union' for arguments anymore.
554 (stap_get_expected_argument_type): Receive probe name instead
555 of 'struct stap_probe'. Adjust code.
556 (stap_parse_probe_arguments): Rename to...
557 (stap_probe::parse_arguments): ...this. Adjust code to
558 reflect change.
559 (stap_get_probe_address): Rename to...
560 (stap_probe::get_relocated_address): ...this. Adjust code
561 to reflect change.
562 (stap_get_probe_argument_count): Rename to...
563 (stap_probe::get_argument_count): ...this. Adjust code
564 to reflect change.
565 (stap_get_arg): Rename to...
566 (stap_probe::get_arg_by_number'): ...this. Adjust code to
567 reflect change.
568 (can_evaluate_probe_arguments): Rename to...
569 (stap_probe::can_evaluate_arguments): ...this. Adjust code
570 to reflect change.
571 (stap_evaluate_probe_argument): Rename to...
572 (stap_probe::evaluate_argument): ...this. Adjust code
573 to reflect change.
574 (stap_compile_to_ax): Rename to...
575 (stap_probe::compile_to_ax): ...this. Adjust code to
576 reflect change.
577 (stap_probe_destroy): Delete.
578 (stap_modify_semaphore): Adjust comment.
579 (stap_set_semaphore): Rename to...
580 (stap_probe::set_semaphore): ...this. Adjust code to reflect
581 change.
582 (stap_clear_semaphore): Rename to...
583 (stap_probe::clear_semaphore): ...this. Adjust code to
584 reflect change.
585 (stap_probe::get_static_ops): New method.
586 (handle_stap_probe): Adjust code to create instance of
587 'stap_probe'.
588 (stap_get_probes): Rename to...
589 (stap_static_probe_ops::get_probes): ...this. Adjust code to
590 reflect change.
591 (stap_probe_is_linespec): Rename to...
592 (stap_static_probe_ops::is_linespec): ...this. Adjust code to
593 reflect change.
594 (stap_type_name): Rename to...
595 (stap_static_probe_ops::type_name): ...this. Adjust code to
596 reflect change.
597 (stap_gen_info_probes_table_header): Rename to...
598 (stap_static_probe_ops::gen_info_probes_table_header):
599 ...this. Adjust code to reflect change.
600 (stap_gen_info_probes_table_values): Rename to...
601 (stap_probe::gen_info_probes_table_values): ...this. Adjust
602 code to reflect change.
603 (struct probe_ops stap_probe_ops): Delete.
604 (info_probes_stap_command): Use 'info_probes_for_spops'
605 instead of 'info_probes_for_ops'.
606 (_initialize_stap_probe): Use 'all_static_probe_ops' instead
607 of 'all_probe_ops'.
608
935676c9
SDJ
6092017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
610
611 * break-catch-throw.c (fetch_probe_arguments): Use
612 'probe.prob' instead of 'probe.probe'.
613 * breakpoint.c (create_longjmp_master_breakpoint): Call
614 'can_evaluate_arguments' and 'get_relocated_address' methods
615 from probe.
616 (create_exception_master_breakpoint): Likewise.
617 (add_location_to_breakpoint): Use 'sal->prob' instead of
618 'sal->probe'.
619 (bkpt_probe_insert_location): Call 'set_semaphore' method from
620 probe.
621 (bkpt_probe_remove_location): Likewise, for 'clear_semaphore'.
622 * elfread.c (elf_get_probes): Use 'static_probe_ops' instead
623 of 'probe_ops'.
624 (probe_key_free): Call 'delete' on probe.
625 (check_exception_resume): Use 'probe.prob' instead of
626 'probe.probe'.
627 * location.c (string_to_event_location_basic): Call
628 'probe_linespec_to_static_ops'.
629 * probe.c (class any_static_probe_ops): New class.
630 (any_static_probe_ops any_static_probe_ops): New variable.
631 (parse_probes_in_pspace): Receive 'static_probe_ops' as
632 argument. Adjust code to reflect change.
633 (parse_probes): Use 'static_probe_ops' instead of
634 'probe_ops'. Adjust code to reflect change.
635 (find_probes_in_objfile): Call methods to get name and
636 provider from probe.
637 (find_probe_by_pc): Use 'result.prob' instead of
638 'result.probe'. Call 'get_relocated_address' method from
639 probe.
640 (collect_probes): Adjust comment and argument list to receive
641 'static_probe_ops' instead of 'probe_ops'. Adjust code to
642 reflect change. Call necessary methods from probe.
643 (compare_probes): Call methods to get name and provider from
644 probes.
645 (gen_ui_out_table_header_info): Receive 'static_probe_ops'
646 instead of 'probe_ops'. Use 'std::vector' instead of VEC,
647 adjust code accordingly.
648 (print_ui_out_not_applicables): Likewise.
649 (info_probes_for_ops): Rename to...
650 (info_probes_for_spops): ...this. Receive 'static_probe_ops'
651 as argument instead of 'probe_ops'. Adjust code. Call
652 necessary methods from probe.
653 (info_probes_command): Use 'info_probes_for_spops'.
654 (enable_probes_command): Pass correct argument to
655 'collect_probes'. Call methods from probe.
656 (disable_probes_command): Likewise.
657 (get_probe_address): Move to 'any_static_probe_ops::get_address'.
658 (get_probe_argument_count): Move to
659 'any_static_probe_ops::get_argument_count'.
660 (can_evaluate_probe_arguments): Move to
661 'any_static_probe_ops::can_evaluate_arguments'.
662 (evaluate_probe_argument): Move to
663 'any_static_probe_ops::evaluate_argument'.
664 (probe_safe_evaluate_at_pc): Use 'probe.prob' instead of
665 'probe.probe'.
666 (probe_linespec_to_ops): Rename to...
667 (probe_linespec_to_static_ops): ...this. Adjust code.
668 (probe_any_is_linespec): Rename to...
669 (any_static_probe_ops::is_linespec): ...this.
670 (probe_any_get_probes): Rename to...
671 (any_static_probe_ops::get_probes): ...this.
672 (any_static_probe_ops::type_name): New method.
673 (any_static_probe_ops::gen_info_probes_table_header): New
674 method.
675 (compute_probe_arg): Use 'pc_probe.prob' instead of
676 'pc_probe.probe'. Call methods from probe.
677 (compile_probe_arg): Likewise.
678 (std::vector<const probe_ops *> all_probe_ops): Delete.
679 (std::vector<const static_probe_ops *> all_static_probe_ops):
680 New variable.
681 (_initialize_probe): Use 'all_static_probe_ops' instead of
682 'all_probe_ops'.
683 * probe.h (struct info_probe_column) <field_name>: Delete
684 extraneous newline
685 (info_probe_column_s): Delete type and VEC.
686 (struct probe_ops): Delete. Replace with...
687 (class static_probe_ops): ...this and...
688 (clas probe): ...this.
689 (struct bound_probe) <bound_probe>: Delete extraneous
690 newline. Adjust constructor to receive 'probe' instead of
691 'struct probe'.
692 <probe>: Rename to...
693 <prob>: ...this. Delete extraneous newline.
694 <objfile>: Delete extraneous newline.
695 (register_probe_ops): Delete unused prototype.
696 (info_probes_for_ops): Rename to...
697 (info_probes_for_spops): ...this. Adjust comment.
698 (get_probe_address): Move to 'probe::get_address'.
699 (get_probe_argument_count): Move to
700 'probe::get_argument_count'.
701 (can_evaluate_probe_arguments): Move to
702 'probe::can_evaluate_arguments'.
703 (evaluate_probe_argument): Move to 'probe::evaluate_argument'.
704 * solib-svr4.c (struct svr4_info): Adjust comment.
705 (struct probe_and_action) <probe>: Rename to...
706 <prob>: ...this.
707 (register_solib_event_probe): Receive 'probe' instead of
708 'struct probe' as argument. Use 'prob' instead of 'probe'
709 when applicable.
710 (solib_event_probe_action): Call 'get_argument_count' method
711 from probe. Adjust comment.
712 (svr4_handle_solib_event): Adjust comment. Call
713 'evaluate_argument' method from probe.
714 (svr4_create_probe_breakpoints): Call 'get_relocated_address'
715 from probe.
716 (svr4_create_solib_event_breakpoints): Use 'probe' instead of
717 'struct probe'. Call 'can_evaluate_arguments' from probe.
718 * symfile.h: Forward declare 'class probe' instead of 'struct
719 probe'.
720 * symtab.h: Likewise.
721 (struct symtab_and_line) <probe>: Rename to...
722 <prob>: ...this.
723 * tracepoint.c (start_tracing): Use 'prob' when applicable.
724 Call probe methods.
725 (stop_tracing): Likewise.
726
8f6cb6c3
JB
7272017-11-22 Joel Brobecker <brobecker@adacore.com>
728
729 * ravenscar-thread.c (ravenscar_inferior_created): Remove
730 trailing newline at end of string in call to warning.
731
479f8de1
SM
7322017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
733
734 * osdata.h: Include vector isntead of vec.h.
735 (osdata_column_s): Remove typedef.
736 (struct osdata_column): Add constructor.
737 <name, value>: Change type to std::string.
738 (DEF_VEC_O (osdata_column_s)): Remove.
739 (osdata_item_s): Remove typedef.
740 (struct osdata_item) <columns>: Change type to std::vector.
741 (DEF_VEC_O (osdata_item_s)): Remove.
742 (struct osdata): Add constructor.
743 <type>: Change type to std::string.
744 <items>: Change type to std::vector.
745 (osdata_p): Remove typedef.
746 (DEF_VEC_P (osdata_p)): Remove.
747 (osdata_parse): Return a unique_ptr.
748 (osdata_free): Remove.
749 (make_cleanup_osdata_free): Remove.
750 (get_osdata): Return a unique_ptr.
751 (get_osdata_column): Return pointer to std::string, take a
752 reference to osdata_item as parameter.
753 * osdata.c (struct osdata_parsing_data) <osdata>: Change type to
754 unique_ptr.
755 <property_name>: Change type to std::string.
756 (osdata_start_osdata): Allocate osdata with new and adjust.
757 (osdata_start_item): Adjust.
758 (osdata_start_column): Adjust.
759 (osdata_end_column): Adjust.
760 (clear_parsing_data): Remove.
761 (osdata_parse): Return a unique_ptr and adjust, remove cleanup.
762 (osdata_item_clear): Remove.
763 (get_osdata): return a unique_ptr and adjust.
764 (get_osdata_column): Return a pointer to std::string and adjust.
765 (info_osdata): Adjust.
766 * mi/mi-main.c: Include <map>.
767 (free_vector_of_osdata_items): Remove.
768 (list_available_thread_groups): Adjust, use std::map instead of
769 splay tree.
770
41bd68f5
SM
7712017-11-22 Simon Marchi <simon.marchi@ericsson.com>
772
773 * stack.c (iterate_over_block_locals): Add LOC_OPTIMIZED_OUT
774 case in switch.
775
7e2fd2f4
SM
7762017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
777
778 * varobj.h (DEF_VEC_P (varobj_p)): Remove.
779
0604393c
SM
7802017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
781
782 * varobj.h (struct varobj_update_result): Add constructor, add
783 move constructor, disable copy and assign, initialize fields.
784 <newobj>: Change type to std::vector.
785 (varobj_update): Return std::vector.
786 * varobj.c (install_dynamic_child): Change VEC parameters to
787 std::vector and adjust.
788 (update_dynamic_varobj_children): Likewise.
789 (varobj_update): Return std::vector and adjust.
790 * mi/mi-cmd-var.c (varobj_update_one): Adjust to vector changes.
791
ddf0ea08
SM
7922017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
793
794 * varobj.h (struct varobj) <parent>: Remove const.
795 <children>: Change type to std::vector.
796 (varobj_list_children): Return std::vector const reference.
797 (varobj_restrict_range): Change parameter type to std::vector
798 const reference.
799 * varobj.c (varobj_has_more): Adjust.
800 (varobj_restrict_range): Change parameter type to std::vector
801 const reference and adjust.
802 (install_dynamic_child): Adjust.
803 (update_dynamic_varobj_children): Adjust.
804 (varobj_list_children): Return std::vector const reference and
805 adjust.
806 (varobj_add_child): Adjust.
807 (update_type_if_necessary): Adjust.
808 (varobj_update): Adjust.
809 (delete_variable_1): Adjust.
810 * ada-varobj.c (ada_value_has_mutated): Adjust.
811 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Adjust.
812
9e5b9d2b
SM
8132017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
814
815 * varobj.h (struct varobj): Add constructor and destructor,
816 initialize fields.
817 * varobj.c (struct varobj_root): Initialize fields.
818 (struct varobj_dynamic): Initialize fields.
819 (varobj_create): Use unique_ptr instead of cleanup. Create
820 varobj with new instead of new_root_variable.
821 (delete_variable_1): Free variable with delete instead of
822 free_variable.
823 (create_child_with_value): Create variable with new instead of
824 new_variable.
825 (varobj::varobj): New.
826 (varobj::~varobj): New (body mostly coming from free_variable).
827 (new_variable): Remove.
828 (free_variable): Remove.
829 (do_free_variable_cleanup): Remove.
830 (make_cleanup_free_variable): Remove.
831
fc35dab1
UW
8322017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
833
834 * core-regset.c: Remove file.
835 * Makefile.in (ALLDEPFILES): Remove core-regset.c.
836
2400729e
UW
8372017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
838
839 * NEWS: Document use of GNU MPFR.
840 * README: Likewise.
841
842 * Makefile.in (LIBMPFR): Add define.
843 (CLIBS): Add $(LIBMPFR).
844 * configure.ac: Add --with-mpfr configure option.
845 * configure: Regenerate.
846 * config.in: Regenerate.
847
848 * target-float.c [HAVE_LIBMPFR]: Include <mpfr.h>.
849 (class mpfr_float_ops): New type.
850 (mpfr_float_ops::from_target): Two new overloaded functions.
851 (mpfr_float_ops::to_target): Likewise.
852 (mpfr_float_ops::to_string): New function.
853 (mpfr_float_ops::from_string): Likewise.
854 (mpfr_float_ops::to_longest): Likewise.
855 (mpfr_float_ops::from_longest): Likewise.
856 (mpfr_float_ops::from_ulongest): Likewise.
857 (mpfr_float_ops::to_host_double): Likewise.
858 (mpfr_float_ops::from_host_double): Likewise.
859 (mpfr_float_ops::convert): Likewise.
860 (mpfr_float_ops::binop): Likewise.
861 (mpfr_float_ops::compare): Likewise.
862 (get_target_float_ops): Use mpfr_float_ops if available.
863
7a26362d
UW
8642017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
865
866 * target-float.c: Do not include <math.h>.
867 Include <cmath> and <limits>.
868 (DOUBLEST): Do not define.
869 (class target_float_ops): New type.
870 (class host_float_ops): New templated type.
871 (class decimal_float_ops): New type.
872
873 (floatformat_to_doublest): Rename to ...
874 (host_float_ops<T>::from_target): ... this. Use template type T
875 instead of DOUBLEST. Use C++ math routines. Update recursive calls.
876 (host_float_ops<T>::from_target): New overload using a type argument.
877 (floatformat_from_doublest): Rename to ...
878 (host_float_ops<T>::to_target): ... this. Use template type T
879 instead of DOUBLEST. Use C++ math routines. Update recursive calls.
880 (host_float_ops<T>::to_target): New overload using a type argument.
881 (floatformat_printf_format): New function.
882 (struct printf_length_modifier): New templated type.
883 (floatformat_to_string): Rename to ...
884 (host_float_ops<T>::to_string): ... this. Use type instead of
885 floatformat argument. Use floatformat_printf_format and
886 printf_length_modifier. Remove special handling of invalid numbers,
887 infinities and NaN (moved to target_float_to_string).
888 (struct scanf_length_modifier): New templated type.
889 (floatformat_from_string): Rename to ...
890 (host_float_ops<T>::from_string): ... this. Use type instead of
891 floatformat argument. Use scanf_length_modifier.
892 (floatformat_to_longest): Rename to ...
893 (host_float_ops<T>::to_longest): ... this. Use type instead of
894 floatformat argument. Handle out-of-range values deterministically.
895 (floatformat_from_longest): Rename to ...
896 (host_float_ops<T>::from_longest): ... this. Use type instead of
897 floatformat argument.
898 (floatformat_from_ulongest): Rename to ...
899 (host_float_ops<T>::from_ulongest): ... this. Use type instead of
900 floatformat argument.
901 (floatformat_to_host_double): Rename to ...
902 (host_float_ops<T>::to_host_double): ... this. Use type instead of
903 floatformat argument.
904 (floatformat_from_host_double): Rename to ...
905 (host_float_ops<T>::from_host_double): ... this. Use type instead of
906 floatformat argument.
907 (floatformat_convert): Rename to ...
908 (host_float_ops<T>::convert): ... this. Use type instead of
909 floatformat arguments. Remove handling of no-op conversions.
910 (floatformat_binop): Rename to ...
911 (host_float_ops<T>::binop): ... this. Use type instead of
912 floatformat arguments.
913 (floatformat_compare): Rename to ...
914 (host_float_ops<T>::compare): ... this. Use type instead of
915 floatformat arguments.
916
917 (match_endianness): Use type instead of length/byte_order arguments.
918 (set_decnumber_context): Likewise.
919 (decimal_from_number): Likewise. Update calls.
920 (decimal_to_number): Likewise.
921 (decimal_is_zero): Likewise. Update calls. Move to earlier in file.
922 (decimal_float_ops::to_host_double): New dummy function.
923 (decimal_float_ops::from_host_double): Likewise.
924 (decimal_to_string): Rename to ...
925 (decimal_float_ops::to_string): ... this. Use type instead of
926 length/byte_order arguments. Update calls.
927 (decimal_from_string): Rename to ...
928 (decimal_float_ops::from_string): ... this. Use type instead of
929 length/byte_order arguments. Update calls.
930 (decimal_from_longest): Rename to ...
931 (decimal_float_ops::from_longest): ... this. Use type instead of
932 length/byte_order arguments. Update calls.
933 (decimal_from_ulongest): Rename to ...
934 (decimal_float_ops::from_ulongest): ... this. Use type instead of
935 length/byte_order arguments. Update calls.
936 (decimal_to_longest): Rename to ...
937 (decimal_float_ops::to_longest): ... this. Use type instead of
938 length/byte_order arguments. Update calls.
939 (decimal_binop): Rename to ...
940 (decimal_float_ops::binop): ... this. Use type instead of
941 length/byte_order arguments. Update calls.
942 (decimal_compare): Rename to ...
943 (decimal_float_ops::compare): ... this. Use type instead of
944 length/byte_order arguments. Update calls.
945 (decimal_convert): Rename to ...
946 (decimal_float_ops::convert): ... this. Use type instead of
947 length/byte_order arguments. Update calls.
948
949 (target_float_same_category_p): New function.
950 (target_float_same_format_p): Likewise.
951 (target_float_format_length): Likewise.
952 (enum target_float_ops_kind): New type.
953 (get_target_float_ops_kind): New function.
954 (get_target_float_ops): Three new overloaded functions.
955
956 (target_float_is_zero): Update call.
957 (target_float_to_string): Add special handling of invalid numbers,
958 infinities and NaN (moved from floatformat_to_string). Use
959 target_float_ops callback.
960 (target_float_from_string): Use target_float_ops callback.
961 (target_float_to_longest): Likewise.
962 (target_float_from_longest): Likewise.
963 (target_float_from_ulongest): Likewise.
964 (target_float_to_host_double): Likewise.
965 (target_float_from_host_double): Likewise.
966 (target_float_convert): Add special case for no-op conversions.
967 Use target_float_ops callback.
968 (target_float_binop): Use target_float_ops callback.
969 (target_float_compare): Likewise.
970
a9f26f60
YQ
9712017-11-22 Yao Qi <yao.qi@linaro.org>
972
973 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use strcpy.
974
29f9a567
YQ
9752017-11-22 Yao Qi <yao.qi@linaro.org>
976
977 * cli/cli-decode.c (help_list): Use memcpy instead of strncpy.
978 * cp-namespace.c (cp_lookup_transparent_type_loop): Likewise.
979
3b1b69bf
JG
9802017-11-21 Jerome Guitton <guitton@adacore.com>
981
982 * ravenscar-thread.c (ravenscar_wait): Update inferior ptid
983 with event ptid from the lower layer before doing the
984 ravenscar-specific update.
985
54aa6c67
JB
9862017-11-21 Joel Brobecker <brobecker@adacore.com>
987
988 * ravenscar-thread.c (is_ravenscar_task): Also verify that
989 the ptid's TID is nonzero.
990
cf3fbed4
JB
9912017-11-21 Joel Brobecker <brobecker@adacore.com>
992
993 * ada-lang.h (ada_get_tcb_types_info): Add declaration.
994 * ada-tasks.c (ada_get_tcb_types_info): Renames get_tcb_types_info.
995 Make non-static. Change return type to char *. Adjust code
996 accordingly. Rewrite the function's documentation.
997 (read_atcb): Adjust call to get_tcb_types_info accordingly.
998 * ravenscar-thread.c (ravenscar_inferior_created): Check that
999 we have enough debugging information in the runtime to support
1000 Ada task debugging before we enable the ravenscar-thread layer.
1001
9edcc12f
JB
10022017-11-21 Joel Brobecker <brobecker@adacore.com>
1003
1004 * ada-lang.h (ada_get_task_info_from_ptid): Add declaration.
1005 * ada-tasks.c (ada_get_task_info_from_ptid): New function.
1006 * ravenscar-thread.c: Add into comment.
1007 (base_magic_null_ptid): Delete.
1008 (base_ptid): Change documentation.
1009 (ravenscar_active_task): Renames ravenscar_running_thread.
1010 All callers updated throughout.
1011 (is_ravenscar_task, ravenscar_get_thread_base_cpu): New function.
1012 (ravenscar_task_is_currently_active): Likewise.
1013 (get_base_thread_from_ravenscar_task): Ditto.
1014 (ravenscar_update_inferior_ptid): Adjust to handle multiple CPUs.
1015 (ravenscar_runtime_initialized): Likewise.
1016 (get_running_thread_id): Add new parameter "cpu". Adjust
1017 implementation to handle this new parameter.
1018 (ravenscar_fetch_registers): Small adjustment to use
1019 is_ravenscar_task and ravenscar_task_is_currently_active in
1020 order to decide whether to use the target beneath or this
1021 module's arch_ops.
1022 (ravenscar_store_registers, ravenscar_prepare_to_store): Likewise.
1023 (ravenscar_stopped_by_sw_breakpoint): Use
1024 get_base_thread_from_ravenscar_task to get the underlying
1025 thread, rather than using base_ptid.
1026 (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
1027 (ravenscar_stopped_data_address, ravenscar_core_of_thread):
1028 Likewise.
1029 (ravenscar_inferior_created): Do not set base_magic_null_ptid.
1030
65d40437
JB
10312017-11-21 Joel Brobecker <brobecker@adacore.com>
1032
1033 * ada-lang.h (struct ada_task_info) <base_cpu>: New field.
1034 * ada-lang.c (struct atcb_fieldno) <base_cpu>: New field.
1035 (get_tcb_types_info): Set fieldnos.base_cpu.
1036 (read_atcb): Set task_info->base_cpu.
1037 (info_task): Print "Base CPU" info if set by runtime.
1038
e02544b2
JB
10392017-11-21 Joel Brobecker <brobecker@adacore.com>
1040
1041 * ravenscar-thread.c (ravenscar_stopped_by_sw_breakpoint)
1042 (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
1043 (ravenscar_stopped_data_address, ravenscar_core_of_thread):
1044 New functions.
1045 (init_ravenscar_thread_ops): Set the to_stopped_by_sw_breakpoint,
1046 to_stopped_by_hw_breakpoint, to_stopped_by_watchpoint,
1047 to_stopped_data_address and to_core_of_thread fields of
1048 ravenscar_ops.
1049
ed0f4273
UW
10502017-11-21 Ulrich Weigand <uweigand@de.ibm.com>
1051
1052 * ppc-tdep.h (enum powerpc_long_double_abi): New data type.
1053 (struct gdbarch_tdep): New member long_double_abi.
1054 * rs6000-tdep.c (rs6000_gdbarch_init): Initialize long_double_abi
1055 member of tdep struct based on Tag_GNU_Power_ABI_FP attribute.
1056 * ppc-linux-tdep.c (ppc_linux_init_abi): Install long double data
1057 format depending on long_double_abi tdep member.
1058 (ppc_floatformat_for_type): Handle __ibm128 type.
1059
0fc76421
SM
10602017-11-20 Simon Marchi <simon.marchi@polymtl.ca>
1061
1062 * darwin-nat.c (set_enable_mach_exceptions): Constify parameter.
1063
e6b2f5ef
PA
10642017-11-21 Pedro Alves <palves@redhat.com>
1065
1066 * dwarf2read.c (mapped_index::find_name_components_bounds)
1067 <completion mode, upper bound>: Use std::lower_bound instead of
1068 std::upper_bound.
1069 (test_mapped_index_find_name_component_bounds): Remove incorrect
1070 "t1_fund" from expected symbols.
1071
5c58de74
PA
10722017-11-21 Pedro Alves <palves@redhat.com>
1073
1074 * dwarf2read.c (mapped_index::name_components_casing): New field.
1075 (mapped_index) <build_name_components,
1076 find_name_components_bounds): Declare new methods.
1077 (mapped_index::find_name_components_bounds)
1078 (mapped_index::build_name_components): New methods, factored out
1079 from dw2_expand_symtabs_matching_symbol.
1080 (check_find_bounds_finds)
1081 (test_mapped_index_find_name_component_bounds): New.
1082 (run_test): Rename to ...
1083 (test_dw2_expand_symtabs_matching_symbol): ... this.
1084 (run_test): Reimplement.
1085
e1ef7d7a
PA
10862017-11-21 Pedro Alves <palves@redhat.com>
1087
1088 * cp-name-parser.y (cp_ident_is_alpha, cp_ident_is_alnum): New.
1089 (symbol_end): Use cp_ident_is_alnum.
1090 (yylex): Use cp_ident_is_alpha and cp_ident_is_alnum.
1091 * dwarf2read.c (make_sort_after_prefix_name): New function.
1092 (dw2_expand_symtabs_matching_symbol): Use it.
1093 (test_symbols): Add more symbols.
1094 (run_test): Add tests.
1095
cf724bc9
TT
10962017-11-17 Tom Tromey <tom@tromey.com>
1097
1098 * symtab.h (enum symbol_subclass_kind): New.
1099 (struct symbol) <is_cplus_template_function, is_rust_vtable>:
1100 Remove.
1101 <subclass>: New member.
1102 (SYMBOL_IS_CPLUS_TEMPLATE_FUNCTION): Update.
1103 * rust-lang.c (rust_get_trait_object_pointer): Update.
1104 * dwarf2read.c (read_func_scope): Update.
1105 (read_variable): Update.
1106
68e745e3
TT
11072017-11-17 Tom Tromey <tom@tromey.com>
1108
1109 * dwarf2read.c (read_func_scope): Update.
1110 * symtab.h (struct template_symbol): Derive from symbol.
1111 <base>: Remove.
1112
71a3c369
TT
11132017-11-17 Tom Tromey <tom@tromey.com>
1114
1115 * symtab.h (struct symbol) <is_rust_vtable>: New member.
1116 (struct rust_vtable_symbol): New.
1117 (find_symbol_at_address): Declare.
1118 * symtab.c (find_symbol_at_address): New function.
1119 * symfile.h (struct quick_symbol_functions)
1120 <find_compunit_symtab_by_address>: New member.
1121 * symfile-debug.c (debug_qf_find_compunit_symtab_by_address): New
1122 function.
1123 (debug_sym_quick_functions): Link to
1124 debug_qf_find_compunit_symtab_by_address.
1125 * rust-lang.c (rust_get_trait_object_pointer): New function.
1126 (rust_evaluate_subexp) <case UNOP_IND>: New case. Call
1127 rust_get_trait_object_pointer.
1128 * psymtab.c (psym_relocate): Clear psymbol_map.
1129 (psym_fill_psymbol_map, psym_find_compunit_symtab_by_address): New
1130 functions.
1131 (psym_functions): Link to psym_find_compunit_symtab_by_address.
1132 * objfiles.h (struct objfile) <psymbol_map>: New member.
1133 * dwarf2read.c (dwarf2_gdb_index_functions): Update.
1134 (process_die) <DW_TAG_variable>: New case. Call read_variable.
1135 (rust_containing_type, read_variable): New functions.
1136
7468702d
SM
11372017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
1138
1139 * common/gdb_vecs.h (DEF_VEC_I (int)): Remove.
1140
37269bc9
SM
11412017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
1142
1143 * common/filestuff.c: Include <algorithm>.
1144 (open_fds): Change type to std::vector<int>.
1145 (do_mark_open_fd): Adjust.
1146 (unmark_fd_no_cloexec): Adjust.
1147 (do_close): Adjust.
1148
5c632425
SM
11492017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
1150
1151 * breakpoint.c (output_thread_groups): Take an std::vector.
1152 (print_one_breakpoint_location): Adjust.
1153
ced9779b
JB
11542017-11-17 Joel Brobecker <brobecker@adacore.com>
1155
1156 * ada-lang.c (resolve_subexp): Add handling of OP_VAR_MSYM_VALUE.
1157 (ada_evaluate_subexp_for_cast): New function.
1158 (ada_evaluate_subexp) <UNOP_CAST>: Replace code by call to
1159 ada_evaluate_subexp_for_cast.
1160 (ada_evaluate_subexp) <nosideret>: Replace code by call to
1161 eval_skip_value.
1162 * eval.c (evaluate_var_value): Make non-static.
1163 (evaluate_var_msym_value, eval_skip_value): Likewise.
1164 * value.h (evaluate_var_value, evaluate_var_msym_value)
1165 (eval_skip_value): Declare.
1166
b7e22850
JB
11672017-11-16 Joel Brobecker <brobecker@adacore.com>
1168
1169 * ada-lang.c (ada_value_cast): Remove parameter "noside".
1170 Update all callers.
1171
9ccabccd
PA
11722017-11-16 Pedro Alves <palves@redhat.com>
1173
1174 * python/py-unwind.c (pyuw_sniffer): Translate
1175 PyExc_KeyboardInterrupt to a GDB Quit exception.
1176
d930703d
PA
11772017-11-16 Pedro Alves <palves@redhat.com>
1178
1179 * infrun.c (resume_cleanups): Delete.
1180 (resume): No longer install a resume_cleanups cleanup nor call
1181 QUIT.
1182 (proceed): Pass the terminal to the inferior.
1183 (keep_going_pass_signal): No longer install a resume_cleanups
1184 cleanup.
1185
38dc2859
PA
11862017-11-16 Pedro Alves <palves@redhat.com>
1187
1188 * inf-loop.c (inferior_event_handler): Don't swallow the exception
1189 if the prompt is blocked.
1190
688fca4f
PA
11912017-11-16 Pedro Alves <palves@redhat.com>
1192
1193 * breakpoint.c (insert_bp_location): Replace bp_err and
1194 bp_err_message locals by a gdb_exception local.
1195
e2c33ac7
PA
11962017-11-16 Pedro Alves <palves@redhat.com>
1197
1198 * inflow.c (scoped_ignore_sigttou): New class.
1199 (child_terminal_ours_1, new_tty): Use it.
1200
d7236961
UW
12012017-11-16 Ulrich Weigand <uweigand@de.ibm.com>
1202
1203 * target-float.c (decimal_from_number): Add byte_order argument and
1204 call match_endianness. Error if unknown floating-point type.
1205 (decimal_to_number): Add byte_order argument and call match_endianness.
1206 (decimal_from_longest): Update call. Do not call match_endianness.
1207 (decimal_from_ulongest): Likewise.
1208 (decimal_binop): Likewise.
1209 (decimal_is_zero): Likewise.
1210 (decimal_compare): Likewise.
1211 (decimal_convert): Likewise.
1212
d8ae99a7
PM
12132017-11-16 Phil Muldoon <pmuldoon@redhat.com>
1214
1215 * python/python.c (gdbpy_rbreak): New function.
1216 * NEWS: Document Python rbreak feature.
1217
c632b645
YQ
12182017-11-16 Yao Qi <yao.qi@linaro.org>
1219
1220 * features/tic6x-c62x.xml: Remove.
1221 * features/tic6x-c64x.xml: Remove.
1222 * features/tic6x-c64xp.xml: Remove.
1223
a014b87a
JB
12242017-11-15 John Baldwin <jhb@FreeBSD.org>
1225
1226 * symtab.h: Include <array>.
1227
94765011
JB
12282017-11-15 John Baldwin <jhb@FreeBSD.org>
1229
1230 * bsd-kvm.c (bsd_kvm_cmd): Constify 'arg'.
1231 (bsd_kvm_proc_cmd): Likewise.
1232
625ad440
SM
12332017-11-15 Simon Marchi <simon.marchi@ericsson.com>
1234
1235 * tui/tui-win.c (window_name_completer): Replace VEC with
1236 std::vector.
1237
c0c11fa9
AC
12382017-11-15 Andrew Cagney <cagney@gnu.org>
1239
1240 * MAINTAINERS: Remove no-longer applicable entries.
1241
34a7ebaf
AC
12422017-11-15 Andrew Cagney <cagney@gnu.org>
1243
1244 * MAINTAINERS: Move self to Past Maintainers.
1245
5334ef39
YQ
12462017-11-15 Yao Qi <yao.qi@linaro.org>
1247
1248 * features/Makefile (XMLTOC): Remove nios2-linux.xml.
1249 * features/nios2-linux.c: Remove.
1250 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Don't call
1251 initialize_tdesc_nios2_linux.
1252
a714b0d6
YQ
12532017-11-15 Yao Qi <yao.qi@linaro.org>
1254
1255 * m68hc11-tdep.c (M68HC11_NUM_REGS): Change it to
1256 M68HC11_LAST_HARD_REG + 1.
1257
92ffd475
PC
12582017-11-14 Paul Carroll <pcarroll@codesourcery.com>
1259
1260 PR gdb/22388
1261 * remote.c (remote_write_bytes_aux, remote_read_bytes_1,
1262 remote_read_bytes, remote_write_qxfer, remote_xfer_partial):
1263 Return TARGET_XFER_EOF if size of returned data is 0.
1264
07431908
SM
12652017-11-14 Simon Marchi <simon.marchi@ericsson.com>
1266
1267 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1268 memory-map-selftests.c.
1269 (SUBDIR_UNITTESTS_OBS): Add memory-map-selftests.o.
1270 * memory-map.c (memory_map_start_memory): Fix computation of hi
1271 address.
1272 * unittests/memory-map-selftests.c: New file.
1273
31432a67
JB
12742017-11-09 Joel Brobecker <brobecker@adacore.com>
1275
1276 * ada-lang.c: Fix some typos in the general command documenting
1277 how Ada expressions are being evaluated and how their result
1278 is printed.
1279
e793c052
TT
12802017-11-09 Tom Tromey <tom@tromey.com>
1281
1282 * psymtab.c (psymbol_hash): Do not hash string contents.
1283 (psymbol_compare): Add comment.
1284
7e8835c5
TT
12852017-11-09 Tom Tromey <tom@tromey.com>
1286
1287 * dictionary.c (dict_hash): Move "TKB" check into the "switch".
1288
286acbb5
JB
12892017-11-08 Joel Brobecker <brobecker@adacore.com>
1290
1291 * ada-exp.y (write_var_from_sym): Remove parameter
1292 "orig_left_context". Update all callers.
1293
b44ec619
SM
12942017-11-08 Simon Marchi <simon.marchi@ericsson.com>
1295
1296 * tracepoint.h (class collection_list) <stringify>: Return
1297 std::vector<std::string>.
1298 (encode_actions_rsp): Change parameters to
1299 std::vector<std::string> *.
1300 * tracepoint.c (collection_list::stringify): Return
1301 std::vector<std::string> and adjust accordingly.
1302 (encode_actions_rsp): Changee parameters to
1303 std::vector<std::string> and adjust accordingly.
1304 * remote.c (free_actions_list),
1305 free_actions_list_cleanup_wrapper): Remove.
1306 (remote_download_tracepoint): Adjust to std::vector.
1307
2f4732b0
TT
13082017-11-08 Tom Tromey <tom@tromey.com>
1309
1310 * dwarf2read.c (symbolp): Remove typedef.
1311 (read_func_scope): Use std::vector.
1312 (process_structure_scope): Use std::vector.
1313
f9d67a22
PA
13142017-11-08 Pedro Alves <palves@redhat.com>
1315
1316 * ada-lang.c (ada_make_symbol_completion_list): Use
1317 completion_skip_symbol.
1318 * symtab.c (symbol_is_function_or_method(minimal_symbol*)): New.
1319 (symbol_is_function_or_method(symbol*)): New.
1320 (add_symtab_completions): Add complete_symbol_mode parameter. Use
1321 completion_skip_symbol.
1322 (default_collect_symbol_completion_matches_break_on): Use
1323 completion_skip_symbol. Pass down mode.
1324 (collect_file_symbol_completion_matches): Pass down mode.
1325 * symtab.h (symbol_is_function_or_method): New declarations.
1326 (completion_skip_symbol): New template function.
1327
56d87ef7
PA
13282017-11-08 Pedro Alves <palves@redhat.com>
1329
1330 * linespec.c (iterate_over_all_matching_symtabs): Add
1331 search_domain parameter. Pass it down to expand_symtabs_matching.
1332 (decode_objc): Request FUNCTIONS_DOMAIN symbols only.
1333 (lookup_prefix_sym): Adjust by passing ALL_DOMAIN as
1334 search_domain.
1335 (add_all_symbol_names_from_pspace): Add search_domain parameter.
1336 Pass it down.
1337 (find_method, find_function_symbols): Request FUNCTIONS_DOMAIN
1338 symbols.
1339 (add_matching_symbols_to_info): Add search_domain parameter. Pass
1340 it down.
1341
1b026119
PA
13422017-11-08 Pedro Alves <palves@redhat.com>
1343
1344 * ada-lang.c (ada_make_symbol_completion_list): Remove text and
1345 text_len locals and don't pass them down.
1346 * symtab.c (completion_list_add_name): Remove
1347 sym_text/sym_text_len parameters and adjust.
1348 (completion_list_add_symbol, completion_list_add_msymbol)
1349 (completion_list_objc_symbol, completion_list_add_fields)
1350 (add_symtab_completions): Likewise.
1351 (default_collect_symbol_completion_matches_break_on)
1352 (collect_file_symbol_completion_matches): Remove sym_text_len
1353 local and don't pass it down.
1354 * symtab.h (completion_list_add_name): Remove
1355 sym_text/sym_text_len parameters.
1356
c62446b1
PA
13572017-11-08 Pedro Alves <palves@redhat.com>
1358
1359 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1360 unittests/lookup_name_info-selftests.c.
1361 (SUBDIR_UNITTESTS_OBS): Add lookup_name_info-selftests.o.
1362 * cp-support.c: Include "selftest.h".
1363 (cp_remove_params_1): Rename from cp_remove_params. Add
1364 'require_param' parameter, and handle it.
1365 (cp_remove_params): Reimplement.
1366 (cp_remove_params_if_any): New.
1367 (selftests::quote): New.
1368 (selftests::check_remove_params): New.
1369 (selftests::test_cp_remove_params): New.
1370 (_initialize_cp_support): Install
1371 selftests::test_cp_remove_params.
1372 * cp-support.h (cp_remove_params_if_any): Declare.
1373 * dwarf2read.c :Include "selftest.h".
1374 (dw2_expand_symtabs_matching_symbol): Use
1375 lookup_name_info::make_ignore_params.
1376 (selftests::dw2_expand_symtabs_matching::mock_mapped_index)
1377 (selftests::dw2_expand_symtabs_matching::string_or_null)
1378 (selftests::dw2_expand_symtabs_matching::check_match)
1379 (selftests::dw2_expand_symtabs_matching::test_symbols)
1380 (selftests::dw2_expand_symtabs_matching::run_test): New.
1381 (_initialize_dwarf2_read): Register
1382 selftests::dw2_expand_symtabs_matching::run_test.
1383 * psymtab.c (psym_expand_symtabs_matching): Use
1384 lookup_name_info::make_ignore_params.
1385 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info):
1386 If the lookup name wants to ignore parameters, strip them.
1387 (compare_symbol_name): Remove sym_text/sym_text_len parameters and
1388 code handling '('.
1389 (completion_list_add_name): Don't pass down sym_text/sym_text_len.
1390 (default_collect_symbol_completion_matches_break_on): Don't try to
1391 strip parameters.
1392 * symtab.h (lookup_name_info::lookup_name_info): Add
1393 'ignore_parameters' parameter.
1394 (lookup_name_info::ignore_parameters)
1395 (lookup_name_info::make_ignore_params): New methods.
1396 (lookup_name_info::m_ignore_parameters): New field.
1397 * unittests/lookup_name_info-selftests.c: New file.
1398
61920122
PA
13992017-11-08 Pedro Alves <palves@redhat.com>
1400
1401 * dwarf2read.c (dw2_expand_marked_cus)
1402 (dw2_expand_symtabs_matching_symbol): Remove forward declarations.
1403 (dw2_expand_symtabs_matching): Move further below.
1404 (dw2_expand_marked_cus): Reindent.
1405
3f563c84
PA
14062017-11-08 Pedro Alves <palves@redhat.com>
1407
1408 * dwarf2read.c (byte_swap, MAYBE_SWAP): Move higher up in file.
1409 (struct name_component): New.
1410 (mapped_index::name_components): New field.
1411 (mapped_index::symbol_name_at): New method.
1412 (dwarf2_read_index): Call mapped_index ctor.
1413 (dw2_map_matching_symbols): Add comment about name_components
1414 table.
1415 (dw2_expand_symtabs_matching): Factor part to...
1416 (dw2_expand_symtabs_matching_symbol): ... this new function.
1417 Build name components table, and lookup symbols in it before
1418 calling the name matcher.
1419 (dw2_expand_marked_cus): New, factored out from
1420 dw2_expand_symtabs_matching.
1421 (dwarf2_per_objfile_free): Call the mapped_index's dtor.
1422
b5ec771e
PA
14232017-11-08 Pedro Alves <palves@redhat.com>
1424
1425 * ada-lang.c (ada_encode): Rename to ..
1426 (ada_encode_1): ... this. Add throw_errors parameter and handle
1427 it.
1428 (ada_encode): Reimplement.
1429 (match_name): Delete, folded into full_name.
1430 (resolve_subexp): No longer pass the encoded name to
1431 ada_lookup_symbol_list.
1432 (should_use_wild_match): Delete.
1433 (name_match_type_from_name): New.
1434 (ada_lookup_simple_minsym): Use lookup_name_info and the
1435 language's symbol_name_matcher_ftype.
1436 (add_symbols_from_enclosing_procs, ada_add_local_symbols)
1437 (ada_add_block_renamings): Adjust to use lookup_name_info.
1438 (ada_lookup_name): New.
1439 (add_nonlocal_symbols, ada_add_all_symbols)
1440 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list)
1441 (ada_iterate_over_symbols): Adjust to use lookup_name_info.
1442 (ada_name_for_lookup): Delete.
1443 (ada_lookup_encoded_symbol): Construct a verbatim name.
1444 (wild_match): Reverse sense of return type. Use bool.
1445 (full_match): Reverse sense of return type. Inline bits of old
1446 match_name here.
1447 (ada_add_block_symbols): Adjust to use lookup_name_info.
1448 (symbol_completion_match): Delete, folded into...
1449 (ada_lookup_name_info::matches): ... .this new method.
1450 (symbol_completion_add): Delete.
1451 (ada_collect_symbol_completion_matches): Add name_match_type
1452 parameter. Adjust to use lookup_name_info and
1453 completion_list_add_name.
1454 (get_var_value, ada_add_global_exceptions): Adjust to use
1455 lookup_name_info.
1456 (ada_get_symbol_name_cmp): Delete.
1457 (do_wild_match, do_full_match): New functions.
1458 (ada_lookup_name_info::ada_lookup_name_info): New method.
1459 (ada_symbol_name_matches, ada_get_symbol_name_matcher): New
1460 functions.
1461 (ada_language_defn): Install ada_get_symbol_name_matcher.
1462 * ada-lex.l (processId): If name starts with '<', copy it
1463 verbatim.
1464 * block.c (block_iter_match_step, block_iter_match_first)
1465 (block_iter_match_next, block_lookup_symbol)
1466 (block_lookup_symbol_primary, block_find_symbol): Adjust to use
1467 lookup_name_info.
1468 * block.h (block_iter_match_first, block_iter_match_next)
1469 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use lookup_name_info.
1470 * c-lang.c (c_language_defn, cplus_language_defn)
1471 (asm_language_defn, minimal_language_defn): Adjust comments to
1472 refer to la_get_symbol_name_matcher.
1473 * completer.c (complete_files_symbols)
1474 (collect_explicit_location_matches, symbol_completer): Pass a
1475 symbol_name_match_type down.
1476 * completer.h (class completion_match, completion_match_result):
1477 New classes.
1478 (completion_tracker::reset_completion_match_result): New method.
1479 (completion_tracker::m_completion_match_result): New field.
1480 * cp-support.c (make_symbol_overload_list_block): Adjust to use
1481 lookup_name_info.
1482 (cp_fq_symbol_name_matches, cp_get_symbol_name_matcher): New
1483 functions.
1484 * cp-support.h (cp_get_symbol_name_matcher): New declaration.
1485 * d-lang.c: Adjust comments to refer to
1486 la_get_symbol_name_matcher.
1487 * dictionary.c (dict_vector) <iter_match_first, iter_match_next>:
1488 Adjust to use lookup_name_info.
1489 (dict_iter_match_first, dict_iter_match_next)
1490 (iter_match_first_hashed, iter_match_next_hashed)
1491 (iter_match_first_linear, iter_match_next_linear): Adjust to work
1492 with a lookup_name_info.
1493 * dictionary.h (dict_iter_match_first, dict_iter_match_next):
1494 Likewise.
1495 * dwarf2read.c (dw2_lookup_symbol): Adjust to use lookup_name_info.
1496 (dw2_map_matching_symbols): Adjust to use symbol_name_match_type.
1497 (gdb_index_symbol_name_matcher): New class.
1498 (dw2_expand_symtabs_matching) Adjust to use lookup_name_info and
1499 gdb_index_symbol_name_matcher. Accept a NULL symbol_matcher.
1500 * f-lang.c (f_collect_symbol_completion_matches): Adjust to work
1501 with a symbol_name_match_type.
1502 (f_language_defn): Adjust comments to refer to
1503 la_get_symbol_name_matcher.
1504 * go-lang.c (go_language_defn): Adjust comments to refer to
1505 la_get_symbol_name_matcher.
1506 * language.c (default_symbol_name_matcher)
1507 (language_get_symbol_name_matcher): New functions.
1508 (unknown_language_defn, auto_language_defn): Adjust comments to
1509 refer to la_get_symbol_name_matcher.
1510 * language.h (symbol_name_cmp_ftype): Delete.
1511 (language_defn) <la_collect_symbol_completion_matches>: Add match
1512 type parameter.
1513 <la_get_symbol_name_cmp>: Delete field.
1514 <la_get_symbol_name_matcher>: New field.
1515 <la_iterate_over_symbols>: Adjust to use lookup_name_info.
1516 (default_symbol_name_matcher, language_get_symbol_name_matcher):
1517 Declare.
1518 * linespec.c (iterate_over_all_matching_symtabs)
1519 (iterate_over_file_blocks): Adjust to use lookup_name_info.
1520 (find_methods): Add language parameter, and use lookup_name_info
1521 and the language's symbol_name_matcher_ftype.
1522 (linespec_complete_function): Adjust.
1523 (lookup_prefix_sym): Use lookup_name_info.
1524 (add_all_symbol_names_from_pspace): Adjust.
1525 (find_superclass_methods): Add language parameter and pass it
1526 down.
1527 (find_method): Pass symbol language down.
1528 (find_linespec_symbols): Don't demangle or Ada encode here.
1529 (search_minsyms_for_name): Add lookup_name_info parameter.
1530 (add_matching_symbols_to_info): Add name_match_type parameter.
1531 Use lookup_name_info.
1532 * m2-lang.c (m2_language_defn): Adjust comments to refer to
1533 la_get_symbol_name_matcher.
1534 * minsyms.c: Include <algorithm>.
1535 (add_minsym_to_demangled_hash_table): Remove table parameter and
1536 add objfile parameter. Use search_name_hash, and add language to
1537 demangled languages vector.
1538 (struct found_minimal_symbols): New struct.
1539 (lookup_minimal_symbol_mangled, lookup_minimal_symbol_demangled):
1540 New functions.
1541 (lookup_minimal_symbol): Adjust to use them. Don't canonicalize
1542 input names here. Use lookup_name_info instead. Lookup up
1543 demangled names once for each language in the demangled names
1544 vector.
1545 (iterate_over_minimal_symbols): Use lookup_name_info. Lookup up
1546 demangled names once for each language in the demangled names
1547 vector.
1548 (build_minimal_symbol_hash_tables): Adjust.
1549 * minsyms.h (iterate_over_minimal_symbols): Adjust to pass down a
1550 lookup_name_info.
1551 * objc-lang.c (objc_language_defn): Adjust comment to refer to
1552 la_get_symbol_name_matcher.
1553 * objfiles.h: Include <vector>.
1554 (objfile_per_bfd_storage) <demangled_hash_languages>: New field.
1555 * opencl-lang.c (opencl_language_defn): Adjust comment to refer to
1556 la_get_symbol_name_matcher.
1557 * p-lang.c (pascal_language_defn): Adjust comment to refer to
1558 la_get_symbol_name_matcher.
1559 * psymtab.c (psym_lookup_symbol): Use lookup_name_info.
1560 (match_partial_symbol): Use symbol_name_match_type,
1561 lookup_name_info and psymbol_name_matches.
1562 (lookup_partial_symbol): Use lookup_name_info.
1563 (map_block): Use symbol_name_match_type and lookup_name_info.
1564 (psym_map_matching_symbols): Use symbol_name_match_type.
1565 (psymbol_name_matches): New.
1566 (recursively_search_psymtabs): Use lookup_name_info and
1567 psymbol_name_matches. Rename 'kind' parameter to 'domain'.
1568 (psym_expand_symtabs_matching): Use lookup_name_info. Rename
1569 'kind' parameter to 'domain'.
1570 * rust-lang.c (rust_language_defn): Adjust comment to refer to
1571 la_get_symbol_name_matcher.
1572 * symfile-debug.c (debug_qf_map_matching_symbols)
1573 (debug_qf_map_matching_symbols): Use symbol_name_match_type.
1574 (debug_qf_expand_symtabs_matching): Use lookup_name_info.
1575 * symfile.c (expand_symtabs_matching): Use lookup_name_info.
1576 * symfile.h (quick_symbol_functions) <map_matching_symbols>:
1577 Adjust to use symbol_name_match_type.
1578 <expand_symtabs_matching>: Adjust to use lookup_name_info.
1579 (expand_symtabs_matching): Adjust to use lookup_name_info.
1580 * symmisc.c (maintenance_expand_symtabs): Use
1581 lookup_name_info::match_any ().
1582 * symtab.c (symbol_matches_search_name): New.
1583 (eq_symbol_entry): Adjust to use lookup_name_info and the
1584 language's matcher.
1585 (demangle_for_lookup_info::demangle_for_lookup_info): New.
1586 (lookup_name_info::match_any): New.
1587 (iterate_over_symbols, search_symbols): Use lookup_name_info.
1588 (compare_symbol_name): Add language, lookup_name_info and
1589 completion_match_result parameters, and use them.
1590 (completion_list_add_name): Make extern. Add language and
1591 lookup_name_info parameters. Use them.
1592 (completion_list_add_symbol, completion_list_add_msymbol)
1593 (completion_list_objc_symbol): Add lookup_name_info parameters and
1594 adjust. Pass down language.
1595 (completion_list_add_fields): Add lookup_name_info parameters and
1596 adjust. Pass down language.
1597 (add_symtab_completions): Add lookup_name_info parameters and
1598 adjust.
1599 (default_collect_symbol_completion_matches_break_on): Add
1600 name_match_type parameter, and use it. Use lookup_name_info.
1601 (default_collect_symbol_completion_matches)
1602 (collect_symbol_completion_matches): Add name_match_type
1603 parameter, and pass it down.
1604 (collect_symbol_completion_matches_type): Adjust.
1605 (collect_file_symbol_completion_matches): Add name_match_type
1606 parameter, and use lookup_name_info.
1607 * symtab.h: Include <string> and "common/gdb_optional.h".
1608 (enum class symbol_name_match_type): New.
1609 (class ada_lookup_name_info): New.
1610 (struct demangle_for_lookup_info): New.
1611 (class lookup_name_info): New.
1612 (symbol_name_matcher_ftype): New.
1613 (SYMBOL_MATCHES_SEARCH_NAME): Use symbol_matches_search_name.
1614 (symbol_matches_search_name): Declare.
1615 (MSYMBOL_MATCHES_SEARCH_NAME): Delete.
1616 (default_collect_symbol_completion_matches)
1617 (collect_symbol_completion_matches)
1618 (collect_file_symbol_completion_matches): Add name_match_type
1619 parameter.
1620 (iterate_over_symbols): Use lookup_name_info.
1621 (completion_list_add_name): Declare.
1622 * utils.c (enum class strncmp_iw_mode): Moved to utils.h.
1623 (strncmp_iw_with_mode): Now extern.
1624 * utils.h (enum class strncmp_iw_mode): Moved from utils.c.
1625 (strncmp_iw_with_mode): Declare.
1626
5ffa0793
PA
16272017-11-08 Keith Seitz <keiths@redhat.com>
1628 Pedro Alves <palves@redhat.com>
1629
1630 * ada-lang.c (ada_language_defn): Install
1631 default_search_name_hash.
1632 * buildsym.c (struct buildsym_compunit): <language>: New field.
1633 (finish_block_internal): Pass language when creating dictionaries.
1634 (start_buildsym_compunit, start_symtab): New language parameters.
1635 Use them.
1636 (restart_symtab): Pass down compilation unit's language.
1637 * buildsym.h (enum language): Forward declare.
1638 (start_symtab): New 'language' parameter.
1639 * c-lang.c (c_language_defn, cplus_language_defn)
1640 (asm_language_defn, minimal_language_defn): Install
1641 default_search_name_hash.
1642 * coffread.c (coff_start_symtab): Adjust.
1643 * d-lang.c (d_language_defn): Install default_search_name_hash.
1644 * dbxread.c (struct symloc): Add 'pst_language' field.
1645 (PST_LANGUAGE): Define.
1646 (start_psymtab, read_ofile_symtab): Use it.
1647 (process_one_symbol): New 'language' parameter. Pass it down.
1648 * dictionary.c (struct dictionary) <language>: New field.
1649 (DICT_LANGUAGE): Define.
1650 (dict_create_hashed, dict_create_hashed_expandable)
1651 (dict_create_linear, dict_create_linear_expandable): New parameter
1652 'language'. Set the dictionary's language.
1653 (iter_match_first_hashed): Adjust to rename.
1654 (insert_symbol_hashed): Assert we don't see mismatching
1655 languages. Adjust to rename.
1656 (dict_hash): Rename to ...
1657 (default_search_name_hash): ... this and make extern.
1658 * dictionary.h (struct language_defn): Forward declare.
1659 (dict_create_hashed): New parameter 'language'.
1660 * dwarf2read.c (dwarf2_start_symtab): Pass down language.
1661 * f-lang.c (f_language_defn): Install default_search_name_hash.
1662 * go-lang.c (go_language_defn): Install default_search_name_hash.
1663 * jit.c (finalize_symtab): Pass compunit's language to dictionary
1664 creation.
1665 * language.c (unknown_language_defn, auto_language_defn):
1666 * language.h (language_defn::la_search_name_hash): New field.
1667 (default_search_name_hash): Declare.
1668 * m2-lang.c (m2_language_defn): Install default_search_name_hash.
1669 * mdebugread.c (new_block): New parameter 'language'.
1670 * mdebugread.c (parse_symbol): Pass symbol language to block
1671 allocation.
1672 (psymtab_to_symtab_1): Pass down language.
1673 (new_symtab): Pass compunit's language to block allocation.
1674 * objc-lang.c (objc_language_defn): Install
1675 default_search_name_hash.
1676 * opencl-lang.c (opencl_language_defn):
1677 * p-lang.c (pascal_language_defn): Install
1678 default_search_name_hash.
1679 * rust-lang.c (rust_language_defn): Install
1680 default_search_name_hash.
1681 * stabsread.h (enum language): Forward declare.
1682 (process_one_symbol): Add 'language' parameter.
1683 * symtab.c (search_name_hash): New function.
1684 * symtab.h (search_name_hash): Declare.
1685 * xcoffread.c (read_xcoff_symtab): Pass language to start_symtab.
1686
2a1dde5d
PA
16872017-11-08 Pedro Alves <palves@redhat.com>
1688
1689 * cp-name-parser.y (main): Don't initialize extra_chars.
1690
95a6b0a1
TT
16912017-11-07 Tom Tromey <tom@tromey.com>
1692
1693 * event-top.h (command_handler): Constify.
1694 * record-full.c (cmd_record_full_start): Update.
1695 * thread.c (thread_apply_all_command): Update.
1696 * printcmd.c (eval_command): Update.
1697 * mi/mi-main.c (mi_execute_cli_command): Update.
1698 (mi_execute_async_cli_command): Update.
1699 * tui/tui-stack.c (tui_update_command): Update.
1700 * cli/cli-interp.c (safe_execute_command): Constify.
1701 * record.c (record_start): Update.
1702 (record_start, record_stop, cmd_record_start): Update.
1703 * record-btrace.c (cmd_record_btrace_bts_start): Update.
1704 (cmd_record_btrace_pt_start): Update.
1705 (cmd_record_btrace_start): Update.
1706 (cmd_record_btrace_start): Update.
1707 * reverse.c (exec_reverse_once): Update.
1708 * python/python.c (execute_gdb_command): Don't copy the command.
1709 * event-top.c (command_line_handler): Update.
1710 (command_handler): Constify.
1711 * defs.h (deprecated_call_command_hook): Constify.
1712 * cli/cli-script.h (execute_user_command): Constify.
1713 * cli/cli-script.c (execute_user_command): Constify.
1714 (execute_cmd_pre_hook, execute_cmd_post_hook): Constify.
1715 (enum command_control_type): Update.
1716 * main.c (catch_command_errors): Remove non-const overload.
1717 (catch_command_errors_ftype): Remove.
1718 * python/py-cmd.c (cmdpy_function): Constify.
1719 * guile/scm-cmd.c (cmdscm_function): Constify.
1720 * cli/cli-dump.c (call_dump_func): Constify.
1721 * cli/cli-decode.c (do_const_cfunc): Constify.
1722 (do_sfunc): Constify.
1723 (cmd_func): Constify.
1724 * gdbcmd.h (execute_command, execute_command_to_string): Constify.
1725 * top.h (execute_command): Constify.
1726 * top.c (execute_command): Constify.
1727 (execute_command_to_string): Constify.
1728 (deprecated_call_command_hook): Constify.
1729 * command.h (cmd_func): Constify.
1730 * cli/cli-decode.h (struct cmd_list_element) <func>: Constify.
1731
eb4c3f4a
TT
17322017-11-07 Tom Tromey <tom@tromey.com>
1733
1734 * ada-lang.c (catch_ada_exception_command): Constify.
1735 (catch_assert_command): Constify.
1736 * break-catch-throw.c (catch_catch_command, catch_throw_command)
1737 (catch_rethrow_command): Constify.
1738 (catch_exception_command_1): Constify.
1739 * breakpoint.h (add_catch_command): Constify.
1740 * break-catch-syscall.c (catch_syscall_command_1): Constify.
1741 (catch_syscall_split_args): Constify.
1742 * break-catch-sig.c (catch_signal_command): Constify.
1743 (catch_signal_split_args): Constify.
1744 * cli/cli-decode.h (struct cmd_list_element) <function>: Use
1745 cmd_const_sfunc_ftype.
1746 * cli/cli-decode.c (add_setshow_cmd_full): Constify.
1747 (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
1748 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
1749 (add_setshow_string_cmd, struct cmd_list_element)
1750 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
1751 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
1752 (add_setshow_zuinteger_unlimited_cmd, add_setshow_zuinteger_cmd):
1753 Constify.
1754 (set_cmd_sfunc): Constify.
1755 (empty_sfunc): Constify.
1756 * command.h (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
1757 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
1758 (add_setshow_string_cmd, add_setshow_string_noescape_cmd)
1759 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
1760 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
1761 (add_setshow_zuinteger_cmd, add_setshow_zuinteger_unlimited_cmd):
1762 Constify.
1763 (set_cmd_sfunc): Constify.
1764 (cmd_sfunc_ftype): Remove.
1765 * compile/compile.c (set_compile_args): Constify.
1766 * infrun.c (set_disable_randomization): Constify.
1767 * infcmd.c (set_args_command, set_cwd_command): Constify.
1768 * breakpoint.c (set_condition_evaluation_mode): Constify.
1769 (add_catch_command): Constify.
1770 (catch_fork_command_1, catch_exec_command_1)
1771 (catch_load_command_1, catch_unload_command_1): Constify.
1772 (catch_load_or_unload): Constify.
1773 * guile/scm-param.c (pascm_set_func): Constify.
1774 (add_setshow_generic): Constify.
1775 * python/py-param.c (get_set_value): Constify.
1776 * top.h (set_verbose): Constify.
1777 * tui/tui-win.c (tui_set_var_cmd): Constify.
1778 * mi/mi-main.c (set_mi_async_command): Constify.
1779 * cli/cli-logging.c (set_logging_overwrite)
1780 (set_logging_redirect): Constify.
1781 * value.c (set_max_value_size): Constify.
1782 * valprint.c (set_input_radix, set_output_radix): Constify.
1783 * utils.c (set_width_command, set_height_command): Constify.
1784 * typeprint.c (set_print_type_methods, set_print_type_typedefs): Constify.
1785 * tracepoint.c (set_disconnected_tracing)
1786 (set_circular_trace_buffer, set_trace_buffer_size)
1787 (set_trace_user, set_trace_notes, set_trace_stop_notes): Constify.
1788 * top.c (set_history_size_command, set_verbose, set_editing)
1789 (set_gdb_datadir, set_history_filename): Constify.
1790 * target.c (set_targetdebug, maint_set_target_async_command)
1791 (maint_set_target_non_stop_command, set_target_permissions)
1792 (set_write_memory_permission): Constify.
1793 (open_target): Constify.
1794 * target-descriptions.c (set_tdesc_filename_cmd): Constify.
1795 * target-dcache.c (set_stack_cache, set_code_cache): Constify.
1796 * symtab.c (set_symbol_cache_size_handler): Constify.
1797 * symfile.c (set_ext_lang_command): Constify.
1798 * symfile-debug.c (set_debug_symfile): Constify.
1799 * source.c (set_directories_command): Constify.
1800 * solib.c (reload_shared_libraries, gdb_sysroot_changed): Constify.
1801 * serial.c (set_parity): Constify.
1802 * rs6000-tdep.c (powerpc_set_soft_float, powerpc_set_vector_abi): Constify.
1803 * remote.c (set_remote_exec_file, set_remotebreak)
1804 (set_remote_protocol_Z_packet_cmd, set_range_stepping): Constify.
1805 * record.c (set_record_insn_history_size)
1806 (set_record_call_history_size): Constify.
1807 * record-full.c (set_record_full_insn_max_num): Constify.
1808 * proc-api.c (set_procfs_trace_cmd, set_procfs_file_cmd): Constify.
1809 * osabi.c (set_osabi): Constify.
1810 * mips-tdep.c (set_mips64_transfers_32bit_regs)
1811 (reinit_frame_cache_sfunc, mips_abi_update): Constify.
1812 * maint.c (maintenance_set_profile_cmd): Constify.
1813 * linux-thread-db.c (set_libthread_db_search_path): Constify.
1814 * language.c (set_language_command, set_range_command)
1815 (set_case_command): Constify.
1816 * infrun.c (set_non_stop, set_observer_mode)
1817 (set_stop_on_solib_events, set_schedlock_func)
1818 (set_exec_direction_func): Constify.
1819 * infcmd.c (set_inferior_tty_command): Constify.
1820 * disasm.c (set_disassembler_options_sfunc): Constify.
1821 * demangle.c (set_demangling_command): Constify.
1822 * dcache.c (set_dcache_size, set_dcache_line_size): Constify.
1823 * cris-tdep.c (set_cris_version, set_cris_mode)
1824 (set_cris_dwarf2_cfi): Constify.
1825 * corefile.c (set_gnutarget_command): Constify.
1826 * charset.c (set_host_charset_sfunc, set_target_charset_sfunc)
1827 (set_target_wide_charset_sfunc): Constify.
1828 * breakpoint.c (update_dprintf_commands): Constify.
1829 * auto-load.c (set_auto_load_dir, set_auto_load_safe_path): Constify.
1830 * arm-tdep.c (set_fp_model_sfunc, arm_set_abi)
1831 (set_disassembly_style_sfunc): Constify.
1832 * arch-utils.c (set_endian, set_architecture): Constify.
1833 * alpha-tdep.c (reinit_frame_cache_sfunc): Constify.
1834 * agent.c (set_can_use_agent): Constify.
1835
5fed81ff
TT
18362017-11-07 Tom Tromey <tom@tromey.com>
1837
1838 * go32-nat.c (go32_sysinfo, go32_sldt, go32_sgdt, go32_sidt)
1839 (go32_pde, go32_pte, go32_pte_for_address): Constify.
1840 * gnu-nat.c (_parse_bool_arg, show_thread_default_pause_cmd)
1841 (set_thread_default_pause_cmd, set_thread_default_run_cmd)
1842 (show_thread_default_run_cmd, set_thread_default_detach_sc_cmd)
1843 (parse_int_arg, show_thread_default_detach_sc_cmd)
1844 (set_signals_cmd, show_signals_cmd, set_sig_thread_cmd)
1845 (show_sig_thread_cmd, set_stopped_cmd, show_stopped_cmd)
1846 (set_exceptions_cmd, show_exceptions_cmd, set_task_pause_cmd)
1847 (show_task_pause_cmd, set_task_detach_sc_cmd)
1848 (show_task_detach_sc_cmd, set_task_exc_port_cmd)
1849 (set_noninvasive_cmd, set_thread_pause_cmd)
1850 (show_thread_pause_cmd, set_thread_run_cmd, show_thread_run_cmd)
1851 (set_thread_detach_sc_cmd, show_thread_detach_sc_cmd)
1852 (set_thread_exc_port_cmd, thread_takeover_sc_cmd): Constify.
1853 * windows-nat.c (display_selectors): Constify.
1854 * cli/cli-decode.h (struct cmd_list_element) <function>: Remove
1855 non-const "cfunc".
1856 * cli/cli-decode.c (set_cmd_cfunc): Remove non-const overload.
1857 (cmd_cfunc_eq): Likewise.
1858 (struct cmd_list_element): Likewise.
1859 (do_cfunc): Remove.
1860 (cli_user_command_p): Update.
1861 * command.h (add_cmd): Remove non-const overload.
1862 (cmd_cfunc_ftype): Remove typedef.
1863 (cmd_cfunc_eq): Remove non-const overload.
1864 * value.c (show_values): Constify.
1865 * thread.c (thread_apply_all_command): Constify.
1866 * symfile.c (load_command): Constify.
1867 * source.c (directory_command): Constify.
1868 * maint.c (maintenance_internal_error)
1869 (maintenance_demangler_warning, maintenance_space_display)
1870 (maintenance_print_architecture, maintenance_translate_address)
1871 (maintenance_info_selftests, maintenance_internal_warning):
1872 Constify.
1873 * breakpoint.c (disable_trace_command, enable_trace_command):
1874 Constify.
1875 * auto-load.c (info_auto_load_local_gdbinit, add_auto_load_dir):
1876 Constify.
1877 (add_auto_load_safe_path): Constify.
1878 * guile/scm-auto-load.c (info_auto_load_guile_scripts): Constify.
1879 * top.h (show_commands): Constify.
1880 * linux-thread-db.c (info_auto_load_libthread_db): Constify.
1881 * sparc64-tdep.c (adi_examine_command): Constify.
1882 (adi_assign_command): Constify.
1883
1d12d88f
TT
18842017-11-07 Tom Tromey <tom@tromey.com>
1885
1886 * frame.h (info_locals_command, info_args_command): Constify.
1887 * auto-load.h (auto_load_info_scripts): Constify.
1888 * inferior.h (registers_info): Constify.
1889 * copying.c: Rebuild.
1890 * copying.awk: Constify generated commands.
1891 * auto-load.c (auto_load_info_scripts)
1892 (info_auto_load_gdb_scripts): Constify.
1893 * cli/cli-decode.c (struct cmd_list_element): Take a
1894 cmd_const_cfunc_ftype.
1895 * command.h (add_info): Take a cmd_const_cfunc_ftype.
1896 * tui/tui-win.c (tui_all_windows_info): Constify.
1897 * python/py-auto-load.c (info_auto_load_python_scripts):
1898 Constify.
1899 * cli/cli-cmds.c (show_command): Remove non-const overload.
1900 * tracepoint.c (info_tvariables_command, info_scope_command):
1901 Constify.
1902 (info_static_tracepoint_markers_command): Constify.
1903 * thread.c (info_threads_command): Constify.
1904 (print_thread_info_1): Constify.
1905 * target.c (info_target_command): Constify.
1906 * symtab.c (info_sources_command, info_functions_command)
1907 (info_types_command): Constify.
1908 (info_variables_command): Remove non-const overload.
1909 * symfile.c (info_ext_lang_command): Constify.
1910 * stack.c (info_frame_command, info_locals_command)
1911 (info_args_command): Constify.
1912 (backtrace_command): Remove non-const overload.
1913 * source.c (info_source_command, info_line_command): Constify.
1914 * solib.c (info_sharedlibrary_command): Constify.
1915 * skip.c (info_skip_command): Constify.
1916 * ser-go32.c (info_serial_command): Constify.
1917 * reverse.c (info_bookmarks_command): Constify.
1918 * printcmd.c (info_symbol_command, info_address_command)
1919 (info_display_command): Constify.
1920 * osdata.c (info_osdata_command): Constify.
1921 * objc-lang.c (info_selectors_command, info_classes_command):
1922 Constify.
1923 * nto-procfs.c (procfs_pidlist, procfs_meminfo): Constify.
1924 * memattr.c (info_mem_command): Constify.
1925 * macrocmd.c (info_macro_command, info_macros_command): Constify.
1926 * linux-fork.c (info_checkpoints_command): Constify.
1927 * infrun.c (info_signals_command): Constify.
1928 * inflow.c (info_terminal_command): Constify.
1929 * inferior.c (info_inferiors_command): Constify.
1930 (print_inferior): Constify.
1931 * infcmd.c (info_program_command, info_all_registers_command)
1932 (info_registers_command, info_vector_command)
1933 (info_float_command): Constify.
1934 (registers_info): Constify.
1935 * gnu-nat.c (info_send_rights_cmd, info_recv_rights_cmd)
1936 (info_port_sets_cmd, info_dead_names_cmd, info_port_rights_cmd):
1937 Constify.
1938 * f-valprint.c (info_common_command): Constify.
1939 * dcache.c (info_dcache_command): Constify.
1940 (dcache_info_1): Constify.
1941 * darwin-nat-info.c (info_mach_tasks_command)
1942 (info_mach_task_command, info_mach_ports_command)
1943 (info_mach_port_command, info_mach_threads_command)
1944 (info_mach_thread_command, info_mach_regions_command)
1945 (info_mach_regions_recurse_command, info_mach_region_command)
1946 (info_mach_exceptions_command): Constify.
1947 (get_task_from_args): Constify.
1948 * cp-support.c (info_vtbl_command): Constify.
1949 * breakpoint.c (info_watchpoints_command)
1950 (info_tracepoints_command): Constify.
1951 (info_breakpoints_command): Remove non-const overload.
1952 * avr-tdep.c (avr_io_reg_read_command): Constify.
1953 * auxv.c (info_auxv_command): Constify.
1954 * ada-tasks.c (info_tasks_command): Constify.
1955 (info_task): Constify.
1956 * ada-lang.c (info_exceptions_command): Constify.
1957
0b39b52e
TT
19582017-11-07 Tom Tromey <tom@tromey.com>
1959
1960 * solib.h (no_shared_libraries): Constify.
1961 * frame.h (return_command): Constify.
1962 * cli/cli-cmds.h (quit_command): Constify.
1963 * top.h (quit_command, execute_command): Constify.
1964 * target.h (flash_erase_command): Constify.
1965 * inferior.h (set_inferior_args, attach_command): Constify.
1966 * tracepoint.h (start_tracing, stop_tracing): Constify.
1967 * breakpoint.h (break_command, tbreak_command)
1968 (hbreak_command_wrapper, thbreak_command_wrapper)
1969 (rbreak_command_wrapper, watch_command_wrapper)
1970 (awatch_command_wrapper, rwatch_command_wrapper)
1971 (get_tracepoint_by_number): Constify.
1972 * symtab.c (info_variables_command, rbreak_command)
1973 (symtab_symbol_info): Constify.
1974 (info_variables_command): Add non-const overload.
1975 * top.c (dont_repeat_command): Constify.
1976 * breakpoint.c (ignore_command, commands_command)
1977 (condition_command, tbreak_command, hbreak_command)
1978 (thbreak_command, clear_command, break_command)
1979 (info_breakpoints_command, watch_command, rwatch_command)
1980 (awatch_command, trace_command, ftrace_command, strace_command)
1981 (trace_pass_command, break_range_command, dprintf_command)
1982 (agent_printf_command, get_tracepoint_by_number)
1983 (watch_maybe_just_location, trace_pass_command): Constify.
1984 (info_breakpoints_command): Add non-const overload.
1985 * tracefile.c (tsave_command): Constify.
1986 * infcmd.c (attach_command, disconnect_command, signal_command)
1987 (queue_signal_command, stepi_command, nexti_command)
1988 (finish_command, next_command, step_command, until_command)
1989 (advance_command, jump_command, continue_command, run_command)
1990 (start_command, starti_command, interrupt_command)
1991 (run_command_1, set_inferior_args, step_1): Constify.
1992 * inferior.c (add_inferior_command, remove_inferior_command)
1993 (clone_inferior_command): Constify.
1994 * linux-fork.c (checkpoint_command, restart_command): Constify.
1995 * windows-nat.c (signal_event_command): Constify.
1996 * guile/guile.c (guile_repl_command, guile_command): Constify.
1997 * printcmd.c (x_command, display_command, printf_command)
1998 (output_command, set_command, call_command, print_command)
1999 (eval_command): Constify.
2000 (non_const_set_command): Remove.
2001 (_initialize_printcmd): Update.
2002 * source.c (forward_search_command, reverse_search_command):
2003 Constify.
2004 * jit.c (jit_reader_load_command, jit_reader_unload_command):
2005 Constify.
2006 * infrun.c (handle_command): Constify.
2007 * memattr.c (mem_command): Constify.
2008 * stack.c (return_command, up_command, up_silently_command)
2009 (down_command, down_silently_command, frame_command)
2010 (backtrace_command, func_command, backtrace_command_1): Constify.
2011 (backtrace_command): Add non-const overload.
2012 * remote-sim.c (simulator_command): Constify.
2013 * exec.c (set_section_command): Constify.
2014 * tracepoint.c (tdump_command, trace_variable_command)
2015 (tstatus_command, tstop_command, tstart_command)
2016 (end_actions_pseudocommand, while_stepping_pseudocommand)
2017 (collect_pseudocommand, teval_pseudocommand, actions_command)
2018 (start_tracing, stop_tracing): Constify.
2019 * value.c (init_if_undefined_command): Constify.
2020 * tui/tui-stack.c (tui_update_command): Constify.
2021 * tui/tui-win.c (tui_refresh_all_command)
2022 (tui_set_tab_width_command, tui_set_win_height_command)
2023 (tui_set_focus_command, tui_scroll_forward_command)
2024 (tui_scroll_backward_command, tui_scroll_left_command)
2025 (tui_scroll_right_command, parse_scrolling_args, tui_set_focus)
2026 (tui_set_win_height): Constify.
2027 * tui/tui-layout.c (tui_layout_command): Constify.
2028 * procfs.c (proc_trace_syscalls, proc_trace_sysentry_cmd)
2029 (proc_trace_sysexit_cmd, proc_untrace_sysentry_cmd)
2030 (proc_untrace_sysexit_cmd): Constify.
2031 * remote.c (threadlist_test_cmd, threadinfo_test_cmd)
2032 (threadset_test_cmd, threadlist_update_test_cmd)
2033 (threadalive_test): Constify.
2034 * objc-lang.c (print_object_command): Constify.
2035 * command.h (add_com): Constify.
2036 * cli/cli-dump.c (restore_command): Constify.
2037 * cli/cli-cmds.c (pwd_command, echo_command, quit_command)
2038 (help_command, complete_command, shell_command, edit_command)
2039 (list_command, disassemble_command, make_command)
2040 (apropos_command, alias_command): Constify.
2041 * cli/cli-script.c (document_command, define_command)
2042 (while_command, if_command, validate_comname): Constify.
2043 * cli/cli-decode.c (struct cmd_list_element): Change type of
2044 "fun".
2045 * target.c (do_monitor_command, flash_erase_command): Constify.
2046 * regcache.c (reg_flush_command): Constify.
2047 * reverse.c (reverse_step, reverse_next, reverse_stepi)
2048 (reverse_nexti, reverse_continue, reverse_finish)
2049 (save_bookmark_command, goto_bookmark_command)
2050 (exec_reverse_once): Constify.
2051 * python/python.c (python_interactive_command, python_command):
2052 Constify.
2053 * typeprint.c (ptype_command, whatis_command, whatis_exp):
2054 Constify.
2055 * solib.c (sharedlibrary_command, no_shared_libraries): Constify.
2056 * gcore.c (gcore_command): Constify.
2057
85c4be7c
TT
20582017-11-07 Tom Tromey <tom@tromey.com>
2059
2060 * printcmd.c (x_command): Call set_repeat_arguments.
2061 * cli/cli-cmds.c (list_command): Call set_repeat_arguments.
2062 * top.c (repeat_arguments): New global.
2063 (set_repeat_arguments): New function.
2064 (execute_command): Handle repeat_arguments.
2065 (show_commands): Calls set_repeat_arguments.
2066 * command.h (set_repeat_arguments): Declare.
2067
022643b4
TT
20682017-11-07 Tom Tromey <tom@tromey.com>
2069
2070 * stack.c (backtrace_command): Use std::string.
2071 (backtrace_command_1): Make "count_exp" const.
2072
5614fb77
TT
20732017-11-07 Tom Tromey <tom@tromey.com>
2074
2075 * source.c (directory_switch, mod_path, add_path): Constify.
2076 * defs.h (add_path, mod_path, directory_switch): Constify.
2077 * mi/mi-cmd-env.c (env_mod_path): Constify.
2078
6be9a197
TT
20792017-11-07 Tom Tromey <tom@tromey.com>
2080
2081 * infcmd.c (strip_bg_char): Return gdb::unique_xmalloc_ptr.
2082 (run_command_1, continue_command, step_1, jump_command)
2083 (signal_command, until_command, advance_command, finish_command)
2084 (attach_command): Update.
2085
c2252c0d
TT
20862017-11-07 Tom Tromey <tom@tromey.com>
2087
2088 * command.h (set_cmd_cfunc): Don't declare.
2089 * cli/cli-decode.c (set_cmd_cfunc): Now static.
2090
1ee870c5
TT
20912017-11-07 Tom Tromey <tom@tromey.com>
2092
2093 * stack.c (select_frame_command): Constify.
2094 * cli/cli-decode.c (add_com_suppress_notification): Constify.
2095 * command.h (add_com_suppress_notification): Constify.
2096
ee7ddd71
TT
20972017-11-07 Tom Tromey <tom@tromey.com>
2098
2099 * breakpoint.c (stop_command): Constify.
2100 * cli/cli-decode.c (struct cmd_list_element): Constify.
2101 * command.h (add_abbrev_prefix_cmd): Constify.
2102
95e95a6d
PA
21032017-11-07 Pedro Alves <palves@redhat.com>
2104
2105 * breakpoint.c (extract_bp_kind): New enum.
2106 (extract_bp_num, extract_bp_or_bp_range): New functions, partially
2107 factored out from ...
2108 (extract_bp_number_and_location): ... here.
2109 * cli/cli-utils.c (get_number_trailer): Handle '-$variable'.
2110
cc638e86
PA
21112017-11-07 Pedro Alves <palves@redhat.com>
2112
2113 * breakpoint.c (extract_bp_number_and_location): Change return
2114 type to void. Throw error instead of warning.
2115 (enable_disable_command): Adjust.
2116
d0fe4701
XR
21172017-11-07 Xavier Roirand <roirand@adacore.com>
2118 Pedro Alves <palves@redhat.com>
2119
2120 * breakpoint.c (map_breakpoint_number_range): New, factored out
2121 from ...
2122 (map_breakpoint_numbers): ... here.
2123 (find_location_by_number): Change parameters from string to
2124 breakpoint number and location.
2125 (extract_bp_number_and_location): New function.
2126 (enable_disable_bp_num_loc)
2127 (enable_disable_breakpoint_location_range)
2128 (enable_disable_command): New functions, factored out ...
2129 (enable_command, disable_command): ... these functions, and
2130 adjusted to support ranges.
2131 * NEWS: Document enable/disable breakpoint location range feature.
2132
635dc5b2
LM
21332017-11-06 Luis Machado <luis.machado@linaro.org>
2134
2135 * MAINTAINERS (Write After Approval): Update my e-mail address.
2136
556e5da5
PA
21372017-11-06 Pedro Alves <palves@redhat.com>
2138
2139 * gnu-nat.c (gnu_terminal_init): Delete.
2140 (gnu_target): Don't install gnu_terminal_init.
2141 * inflow.c (child_terminal_init_with_pgrp): Delete, merged with ...
2142 (child_terminal_init): ... this function.
2143
d1928160
PA
21442017-11-06 Pedro Alves <palves@redhat.com>
2145
2146 * common/common.m4 (GDB_AC_COMMON): No longer check termio.h nor
2147 sgtty.h.
2148 * config.in, configure: Regenerate.
2149
6aa899ce
PA
21502017-11-06 Pedro Alves <palves@redhat.com>
2151
2152 * event-top.c: Check SIGTSTP instead of STOP_SIGNAL thoughout.
2153 (async_init_signals): Adjust.
2154 (handle_stop_sig): Rename to ...
2155 (handle_sigtstp): ... this.
2156 (async_stop_sig): Rename to ...
2157 (async_sigtstp_handler): ... this, and delete STOP_SIGNAL !=
2158 SIGTSTP path.
2159 * event-top.h: Move signal.h include to the top. Check SIGTSTP
2160 instead of STOP_SIGNAL thoughout.
2161 (handle_stop_sig): Rename to ...
2162 (handle_sigtstp): ... this.
2163 * top.c (command_line_input): Replace STOP_SIGNAL -> SIGTSTP.
2164
a94799ac
PA
21652017-11-06 Pedro Alves <palves@redhat.com>
2166
2167 * inflow.c (child_terminal_inferior, child_terminal_ours_1): No
2168 longer set flags twice in row.
2169
726e1356
PA
21702017-11-06 Pedro Alves <palves@redhat.com>
2171
2172 * Makefile.in (SER_HARDWIRE): Update comment.
2173 (HFILES_NO_SRCDIR): Remove gdb_termios.h.
2174 * common/gdb_termios.h: Delete file.
2175 * common/job-control.c: Include termios.h and unistd.h instead of
2176 gdb_termios.h.
2177 (gdb_setpgid): Remove HAVE_TERMIOS || TIOCGPGRP preprocessor
2178 check.
2179 (have_job_control): Check HAVE_TERMIOS_H instead of HAVE_TERMIOS.
2180 Remove sgtty code.
2181 * configure.ac: No longer check for termio.h and sgtty.h.
2182 * configure: Regenerate.
2183 * inflow.c: Include termios.h instead of gdb_termios.h. Replace
2184 PROCESS_GROUP_TYPE checks with HAVE_TERMIOS_H checks throughout.
2185 Replace PROCESS_GROUP_TYPE references with pid_t references
2186 throughout.
2187 (gdb_getpgrp): Delete.
2188 (set_initial_gdb_ttystate): Use tcgetpgrp instead of gdb_getpgrp.
2189 (child_terminal_inferior): Remove comment. Remove sgtty code.
2190 (child_terminal_ours_1): Use tcgetpgrp directly instead of
2191 gdb_getpgrp. Use serial_set_tty_state instead aof
2192 serial_noflush_set_tty_state. Remove sgtty code.
2193 * inflow.h: Include unistd.h instead of gdb_termios.h. Replace
2194 PROCESS_GROUP_TYPE check with HAVE_TERMIOS_H check.
2195 (inferior_process_group): Now returns pid_t.
2196 * ser-base.c (ser_base_noflush_set_tty_state): Delete.
2197 * ser-base.h (ser_base_noflush_set_tty_state): Delete.
2198 * ser-event.c (serial_event_ops): Update.
2199 * ser-go32.c (dos_noflush_set_tty_state): Delete.
2200 (dos_ops): Update.
2201 * ser-mingw.c (hardwire_ops, tty_ops, pipe_ops, tcp_ops): Update.
2202 * ser-pipe.c (pipe_ops): Update.
2203 * ser-tcp.c (tcp_ops): Update.
2204 * ser-unix.c: Include termios.h instead of gdb_termios.h. Remove
2205 HAVE_TERMIOS checks.
2206 [HAVE_TERMIO] (struct hardwire_ttystate): Delete.
2207 [HAVE_SGTTY] (struct hardwire_ttystate): Delete.
2208 (get_tty_state, set_tty_state): Drop termio and sgtty code, and
2209 assume termios.
2210 (hardwire_noflush_set_tty_state): Delete.
2211 (hardwire_print_tty_state, hardwire_drain_output)
2212 (hardwire_flush_output, hardwire_flush_input)
2213 (hardwire_send_break, hardwire_raw, hardwire_setbaudrate)
2214 (hardwire_setstopbits, hardwire_setparity): Drop termio and sgtty
2215 code, and assume termios.
2216 (hardwire_ops): Update.
2217 (_initialize_ser_hardwire): Remove HAVE_TERMIOS check.
2218 * serial.c (serial_noflush_set_tty_state): Delete.
2219 * serial.h (serial_noflush_set_tty_state): Delete.
2220 (serial_ops::noflush_set_tty_state): Delete.
2221
1cfb73db
UW
22222017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2223
2224 * Makefile.in (SFILES): Remove doublest.c and dfp.c.
2225 (HFILES_NO_SRCDIR): Remove doublest.h and dfp.h.
2226 (COMMON_OBS): Remove doublest.o and dfp.o.
2227 Do not build target-float.c (instead of doublest.c)
2228 with -Wformat-nonliteral.
2229
2230 * doublest.c: Remove file.
2231 * doublest.h: Remove file.
2232 * dfp.c: Remove file.
2233 * dfp.h: Remove file.
2234
2235 * target-float.c: Do not include "doublest.h" and "dfp.h".
2236 (DOUBLEST): Move here from doublest.h.
2237 (enum float_kind): Likewise.
2238 (FLOATFORMAT_CHAR_BIT): Likewise.
2239 (FLOATFORMAT_LARGEST_BYTES): Likewise.
2240 (floatformat_totalsize_bytes): Move here from doublest.c. Make static.
2241 (floatformat_precision): Likewise.
2242 (floatformat_normalize_byteorder, get_field, put_field): Likewise.
2243 (floatformat_is_negative, floatformat_classify, floatformat_mantissa):
2244 Likewise.
2245 (host_float_format, host_double_format, host_long_double_format):
2246 Likewise.
2247 (floatformat_to_string, floatformat_from_string): Likewise.
2248 (floatformat_to_doublest): Likewise. Also, inline the original
2249 convert_floatformat_to_doublest.
2250 (floatformat_from_doublest): Likewise. Also, inline the original
2251 convert_floatformat_from_doublest.
2252
2253 Include "dpd/decimal128.h", "dpd/decimal64.h", and "dpd/decimal32.h".
2254 (MAX_DECIMAL_STRING): Move here from dfp.c.
2255 (match_endianness): Likewise.
2256 (set_decnumber_context, decimal_check_errors): Likewise.
2257 (decimal_from_number, decimal_to_number): Likewise.
2258 (decimal_to_string, decimal_from_string): Likewise. Make static.
2259 (decimal_from_longest, decimal_from_ulongest): Likewise.
2260 (decimal_to_longest): Likewise.
2261 (decimal_binop, decimal_is_zero, decimal_compare): Likewise.
2262 (decimal_convert): Likewise.
2263
b07e9c46
UW
22642017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2265
2266 * doublest.c: Do not include "gdbtypes.h".
2267 (extract_typed_floating): Remove.
2268 (store_typed_floating): Remove.
2269 (convert_typed_floating): Remove.
2270 * doublest.h (struct type): Remove.
2271 (DOUBLEST_PRINT_FORMAT): Remove.
2272 (DOUBLEST_SCAN_FORMAT): Remove.
2273 (extract_typed_floating): Remove.
2274 (store_typed_floating): Remove.
2275 (convert_typed_floating): Remove.
2276
2277 * dfp.c (decimal_from_doublest): Remove.
2278 (decimal_to_doublest): Remove.
2279 * dfp.h: Do not include "doublest.h".
2280 (decimal_from_doublest): Remove.
2281 (decimal_to_doublest): Remove.
2282
2283 * value.c: Do not include "doublest.h" and "dfp.h".
2284 (value_as_double): Remove.
2285 (unpack_double): Remove.
2286 (value_from_double): Remove.
2287 (value_from_decfloat): Remove.
2288 * value.h: Do not include "doublest.h".
2289 (value_as_double): Remove.
2290 (unpack_double): Remove.
2291 (value_from_double): Remove.
2292 (value_from_decfloat): Remove.
2293
3b2ca824
UW
22942017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2295
2296 * i386-tdep.c: Include "target-float.h". Do not include "doublest.h".
2297 (i386_extract_return_value): Use target_float_convert.
2298 (i386_store_return_value): Likewise.
2299 * i387-tdep.c (i387_register_to_value): Use target_float_convert.
2300 (i387_value_to_register): Likewise.
2301 * ia64-tdep.c: Include "target-float.h". Do not include "doublest.h".
2302 (ia64_register_to_value): Use target_float_convert.
2303 (ia64_value_to_register): Likewise.
2304 (ia64_extract_return_value): Likewise.
2305 (ia64_store_return_value): Likewise.
2306 (ia64_push_dummy_call): Likewise.
2307 * m68k-tdep.c: Include "target-float.h".
2308 (m68k_register_to_value): Use target_float_convert.
2309 (m68k_value_to_register): Likewise.
2310 (m68k_svr4_extract_return_value): Likewise.
2311 (m68k_svr4_store_return_value): Likewise.
2312 * ppc-sysv-tdep.c: Include "target-float.h".
2313 (ppc_sysv_abi_push_dummy_call): Use target_float_convert.
2314 (do_ppc_sysv_return_value): Likewise.
2315 (ppc64_sysv_abi_push_freg): Likewise.
2316 (ppc64_sysv_abi_return_value_base): Likewise.
2317 * rs6000-aix-tdep.c: Include "target-float.h".
2318 (rs6000_push_dummy_call): Use target_float_convert.
2319 (rs6000_return_value): Likewise.
2320 * rs6000-lynx178-tdep.c: Include "target-float.h".
2321 (rs6000_lynx178_push_dummy_call): Use target_float_convert.
2322 (rs6000_lynx178_return_value): Likewise.
2323 * rs6000-tdep.c: Include "target-float.h". Do not include "doublest.h".
2324 (rs6000_register_to_value): Use target_float_convert.
2325 (rs6000_value_to_register): Likewise.
2326 * arm-tdep.c: Include "target-float.h". Do not include "doublest.h".
2327 (arm_extract_return_value): Use target_float_convert.
2328 (arm_store_return_value): Likewise.
2329 * sh-tdep.c: Include "target-float.h". Do not include "doublest.h".
2330 (sh_register_convert_to_virtual): Use target_float_convert.
2331 (sh_register_convert_to_raw): Likewise.
2332 * sh64-tdep.c: Include "target-float.h".
2333 (sh64_extract_return_value): Use target_float_convert.
2334 (sh64_register_convert_to_virtual): Likewise.
2335 (sh64_register_convert_to_raw): Likewise. Fix argument types.
2336
14ad9311
UW
23372017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2338
2339 * target-float.c (floatformat_to_host_double): New function.
2340 (floatformat_from_host_double): Likewise.
2341 (target_float_to_host_double): Likewise.
2342 (target_float_from_host_double): Likewise.
2343 * target-float.h (target_float_to_host_double): Add prototype.
2344 (target_float_from_host_double): Likewise.
2345
2346 * guile/scm-value.c: Include "target-float.h".
2347 (gdbscm_value_to_real): Use target_float_to_host_double.
2348 Handle integer source values via value_as_long.
2349 * guile/scm-math.c: Include "target-float.h". Do not include
2350 "doublest.h", "dfp.h", and "expression.h".
2351 (vlscm_convert_typed_number): Use target_float_from_host_double.
2352 (vlscm_convert_number): Likewise.
2353
2354 * python/py-value.c (valpy_float): Use target_float_to_host_double.
2355 (convert_value_from_python): Use target_float_from_host_double.
2356
50eff16b
UW
23572017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2358
2359 * ada-lang.c (cast_to_fixed): Reimplement in target arithmetic.
2360 (cast_from_fixed): Likewise.
2361 (ada_scaling_type): New function.
2362 (ada_delta): Return value instead of DOUBLEST. Perform target
2363 arithmetic instead of host arithmetic.
2364 (scaling_factor): Rename to ...
2365 (ada_scaling_factor) ... this. Make non-static. Return value instead
2366 of DOUBLEST. Perform target arithmetic instead of host arithmetic.
2367 (ada_fixed_to_float): Remove.
2368 (ada_float_to_fixed): Remove.
2369 * ada-lang.h (ada_fixed_to_float): Remove.
2370 (ada_float_to_fixed): Remove.
2371 (ada_delta): Return value instead of DOUBLEST.
2372 (ada_scaling_factor): Add prototype.
2373
2374 * ada-typeprint.c: Include "target-float.h".
2375 (print_fixed_point_type): Perform target arithmetic instead of
2376 host arithmetic.
2377 * ada-valprint.c: Include "target-float.h".
2378 (ada_val_print_num): Perform target arithmetic instead of
2379 host arithmetic for fixed-point types.
2380
66c02b9e
UW
23812017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2382
2383 * target-float.c: Include <math.h>.
2384 (floatformat_binop): New function.
2385 (floatformat_compare): Likewise.
2386 (target_float_binop): Likewise.
2387 (target_float_compare): Likewise.
2388 * target-float.h: Include "expression.h".
2389 (target_float_binop): Add prototype.
2390 (target_float_compare): Likewise.
2391
2392 * valarith.c: Do not include "doublest.h" and "dfp.h".
2393 Include "common/byte-vector.h".
2394 (value_args_as_decimal): Remove, replace by ...
2395 (value_args_as_target_float): ... this function. Handle both
2396 binary and decimal target floating-point formats.
2397 (scalar_binop): Handle both binary and decimal FP using
2398 value_args_as_target_float and target_float_binop.
2399 (value_equal): Handle both binary and decimal FP using
2400 value_args_as_target_float and target_float_compare.
2401 (value_less): Likewise.
2402 (value_pos): Handle all scalar types as simple copy.
2403 (value_neg): Handle all scalar types via BINOP_SUB from 0.
2404 * dfp.c (decimal_binop): Throw error instead of internal_error
2405 when called with an unsupported operation code.
2406
f69fdf9b
UW
24072017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2408
2409 * target-float.c (target_float_to_string): New function.
2410 (target_float_from_string): New function.
2411 * target-float.h (target_float_to_string): Add prototype.
2412 (target_float_from_string): Add prototype.
2413
2414 * valprint.c: Include "target-float.h". Do not include
2415 "doublest.h" and "dfp.h".
2416 (print_floating): Use target_float_to_string.
2417 * printcmd.c: Include "target-float.h". Do not include "dfp.h".
2418 (printf_floating): Use target_float_to_string.
2419 * i387-tdep.c: Include "target-float.h". Do not include "doublest.h".
2420 (print_i387_value): Use target_float_to_string.
2421 * mips-tdep.c: Include "target-float.h".
2422 (mips_print_fp_register): Use target_float_to_string.
2423 * sh64-tdep.c: Include "target-float.h".
2424 (sh64_do_fp_register): Use target_float_to_string.
2425
2426 * parse.c: Include "target-float.h". Do not include
2427 "doublest.h" and "dfp.h".
2428 (parse_float): Use target_float_from_string.
2429 * stabsread.c: Include "target-float.h". Do not include "doublest.h".
2430 (define_symbol): Use target_float_from_string.
2431 * gdbarch-selftests.c: Include "target-float.h".
2432 (register_to_value_test): Use target_float_from_string.
2433
70100014
UW
24342017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2435
2436 * Makefile.c (SFILES): Add target-float.c.
2437 (HFILES_NO_SRCDIR): Add target-float.h.
2438 (COMMON_OBS): Add target-float.o.
2439 * target-float.h: New file.
2440 * target-float.c: New file.
2441
2442 * doublest.c (floatformat_classify): Fix detection of float_zero.
2443
2444 * gdbtypes.c (is_floating_type): New function.
2445 * gdbtypes.h (is_floating_type): Add prototype.
2446
2447 * value.c: Do not include "floatformat.h".
2448 (unpack_double): Use target_float_is_valid.
2449 (is_floating_value): New function.
2450 * value.h (is_floating_value): Add prototype-
2451
2452 * valarith.c: Include "target-float.h".
2453 (value_logical_not): Use target_float_is_zero.
2454
2455 * python/py-value.c: Include "target-float.h".
2456 (valpy_nonzero): Use target_float_is_zero.
2457
ab4b1c46
TT
24582017-11-04 Tom Tromey <tom@tromey.com>
2459
2460 * h8300-tdep.c (h8300_push_dummy_call): Use std::vector.
2461
454dafbd
TT
24622017-11-04 Tom Tromey <tom@tromey.com>
2463
2464 * breakpoint.c (set_momentary_breakpoint): Return
2465 breakpoint_up.
2466 (until_break_command): Update.
2467 (new_until_break_fsm): Change argument types to
2468 breakpoint_up.
2469 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
2470 (do_delete_breakpoint_cleanup, make_cleanup_delete_breakpoint):
2471 Remove.
2472 * infcmd.c (finish_forward): Update.
2473 * breakpoint.h (set_momentary_breakpoint)
2474 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
2475 (make_cleanup_delete_breakpoint): Remove.
2476 (struct breakpoint_deleter): New.
2477 (breakpoint_up): New typedef.
2478 * infrun.c (insert_step_resume_breakpoint_at_sal_1): Update.
2479 (insert_exception_resume_breakpoint): Update.
2480 (insert_exception_resume_from_probe): Update.
2481 (insert_longjmp_resume_breakpoint): Update.
2482 * arm-linux-tdep.c (arm_linux_copy_svc): Update.
2483 * elfread.c (elf_gnu_ifunc_resolver_stop): Update.
2484 * infcall.c (call_function_by_hand_dummy): Update
2485
331b71e5
TT
24862017-11-04 Tom Tromey <tom@tromey.com>
2487
2488 * c-typeprint.c (c_type_print_base): Use gdb::unique_xmalloc_ptr.
2489
9f584b37
TT
24902017-11-04 Tom Tromey <tom@tromey.com>
2491
2492 * linux-tdep.c (linux_core_info_proc_mappings): Use
2493 gdb::def_vector.
2494 (linux_get_siginfo_data): Return gdb::byte_vector. Remove
2495 "size" argument.
2496 (linux_corefile_thread): Update.
2497 (linux_make_corefile_notes): Remove unused variable.
2498
779bc38e
TT
24992017-11-04 Tom Tromey <tom@tromey.com>
2500
2501 * ppc-linux-tdep.c (ppc_linux_get_syscall_number): Use
2502 gdb::byte_vector.
2503
ed2b3126
TT
25042017-11-04 Tom Tromey <tom@tromey.com>
2505
2506 * objfiles.c (do_free_objfile_cleanup): Remove.
2507 * compile/compile-object-load.c (compile_object_load): Update.
2508 * objfiles.h (make_cleanup_free_objfile): Remove.
2509
7f6743fd
TT
25102017-11-04 Tom Tromey <tom@tromey.com>
2511
2512 * sparc64-tdep.c (do_examine): Use gdb::def_vector.
2513 (adi_read_versions): Change "tags" to "gdb_byte *".
2514 (adi_print_versions): Likewise.
2515
c80049d3
TT
25162017-11-04 Tom Tromey <tom@tromey.com>
2517
2518 * breakpoint.c
2519 (scoped_rbreak_breakpoints::scoped_rbreak_breakpoints): Rename
2520 from start_rbreak_breakpoints.
2521 (scoped_rbreak_breakpoints): Rename from end_rbreak_breakpoints.
2522 * breakpoint.h (class scoped_rbreak_breakpoints): New.
2523 (start_rbreak_breakpoints, end_rbreak_breakpoints): Remove.
2524 * symtab.c (do_end_rbreak_breakpoints): Remove.
2525 (rbreak_command): Use scoped_rbreak_breakpoints, std::string.
2526
167b0be1
TT
25272017-11-04 Tom Tromey <tom@tromey.com>
2528
2529 * cp-namespace.c (reset_directive_searched): Remove.
2530 (cp_lookup_symbol_via_imports): Use scoped_restore.
2531 * cp-support.c (reset_directive_searched): Remove.
2532 (make_symbol_overload_list_using): Use scoped_restore.
2533 * d-namespace.c (d_lookup_symbol_imports): Use scoped_restore.
2534 (reset_directive_searched): Remove.
2535
5eae7aea
TT
25362017-11-04 Tom Tromey <tom@tromey.com>
2537
2538 * symfile.c (find_separate_debug_file_by_debuglink): Use
2539 unique_xmalloc_ptr.
2540
c6bcad5f
TT
25412017-11-04 Tom Tromey <tom@tromey.com>
2542
2543 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
2544 type of "info".
2545 (compute_stack_depth): Likewise.
2546 (do_compile_dwarf_expr_to_c): Use std::vector.
2547
20dcd8ca
TT
25482017-11-04 Tom Tromey <tom@tromey.com>
2549
2550 * compile/compile-object-load.c (link_callbacks_einfo): Use
2551 std::string.
2552
33c7c59d
TT
25532017-11-04 Tom Tromey <tom@tromey.com>
2554
2555 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
2556 Use scoped_free_pendings.
2557 * dbxread.c (dbx_symfile_read, dbx_psymtab_to_symtab_1): Use
2558 scoped_free_pendings.
2559 * xcoffread.c (xcoff_psymtab_to_symtab_1): Use scoped_free_pendings.
2560 (xcoff_initial_scan): Likewise.
2561 * buildsym.c (reset_symtab_globals): Update comment.
2562 (scoped_free_pendings): Rename from really_free_pendings.
2563 (prepare_for_building): Update comment.
2564 (buildsym_init): Likewise.
2565 * buildsym.h (class scoped_free_pendings): New class.
2566 (really_free_pendings): Don't declare.
2567
67fa57cf
UW
25682017-11-03 Ulrich Weigand <uweigand@de.ibm.com>
2569
2570 * doublest.c (convert_doublest_to_floatformat): Fix uninitialized
2571 output when converting a zero value to a special byteorder format.
2572
f26ae15b
YQ
25732017-11-02 Yao Qi <yao.qi@linaro.org>
2574
2575 * frame.c (do_frame_register_read): Remove aspace.
2576 * jit.c (jit_frame_sniffer): Likwise.
2577 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
2578 * regcache.c (regcache::regcache): Pass nullptr.
2579 (regcache_print): Caller updated.
2580 * regcache.h (regcache::regcache): Remove one constructor
2581 parameter aspace.
2582
6c6e9412
YQ
25832017-11-02 Yao Qi <yao.qi@linaro.org>
2584
2585 * regcache.h (regcache) <m_readonly_p>: Change it to const bool.
2586
8b86c959
YQ
25872017-11-02 Yao Qi <yao.qi@linaro.org>
2588
2589 * breakpoint.c (insert_single_step_breakpoints): Update.
2590 * frame.c (struct frame_info) <aspace>: Add const.
2591 (frame_save_as_regcache): Add const.
2592 (get_frame_address_space): Return const address_space *.
2593 * frame.h (get_frame_address_space): Update declaration.
2594 * infrun.c (struct step_over_info) <aspace>: Add const.
2595 (set_step_over_info): Make aspace const.
2596 (displaced_step_prepare_throw): Change variable const.
2597 (resume): Likewise.
2598 (proceed): Likewise.
2599 (adjust_pc_after_break): Likewise.
2600 (save_waitstatus): Likewise.
2601 (handle_signal_stop): Likewise.
2602 (keep_going_pass_signal): Likewise.
2603 * jit.c (jit_frame_sniffer): Add const.
2604 * mips-tdep.c (mips_single_step_through_delay): Likewise.
2605 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
2606 * record-full.c (record_full_wait_1): Likewise.
2607 * regcache.c (regcache::regcache): Change parameter to const.
2608 * regcache.h (regcache::regcache): Likewise.
2609 (regcache::aspace): Return const address_space *.
2610 (regcache) <m_aspace>: Add const.
2611
a01bda52
YQ
26122017-11-02 Yao Qi <yao.qi@linaro.org>
2613
2614 * darwin-nat.c (cancel_breakpoint): Use regcache->aspace ().
2615 * frame.c (create_sentinel_frame): Likewise.
2616 * infrun.c (displaced_step_prepare_throw): Likewise.
2617 (resume): Likewise.
2618 (thread_still_needs_step_over_bp): Likewise.
2619 (proceed): Likewise.
2620 (do_target_wait): Likewise.
2621 (adjust_pc_after_break): Likewise.
2622 (handle_syscall_event): Likewise.
2623 (save_waitstatus): Likewise.
2624 (handle_inferior_event_1): Likewise.
2625 (handle_signal_stop): Likewise.
2626 (keep_going_pass_signal): Likewise.
2627 * linux-nat.c (status_callback): Likewise.
2628 (save_stop_reason): Likewise.
2629 (resume_stopped_resumed_lwps): Likewise.
2630 * record-full.c (record_full_exec_insn): Likewise.
2631 (record_full_wait_1): Likewise.
2632 * regcache.c (get_regcache_aspace): Remove.
2633 * regcache.h (get_regcache_aspace): Remove.
2634
d999647b
YQ
26352017-11-02 Yao Qi <yao.qi@linaro.org>
2636
2637 * regcache.c (struct regcache_descr) <nr_raw_registers>: Remove.
2638 (init_regcache_descr): Use gdbarch_num_regs.
2639 (regcache::regcache): Likewise.
2640 (regcache::get_register_status): Likewise.
2641 (regcache::assert_raw_regnum): Likewise.
2642 (regcache::cooked_read): Likewise.
2643 (regcache::cooked_read_value): Likewise.
2644 (regcache::cooked_write): Likewise.
2645 (regcache::dump): Likewise.
2646 (regcache::num_raw_registers): New method.
2647 * regcache.h (class regcache) <num_raw_registers>: New.
2648
4e888c28
YQ
26492017-11-02 Yao Qi <yao.qi@linaro.org>
2650
2651 * regcache.c (regcache::assert_regnum): New method.
2652 (regcache::invalidate): Call assert_regnum.
2653 (regcache::raw_update): Likewise.
2654 (regcache::raw_write): Likewise.
2655 (regcache::raw_read_part): Likewise.
2656 (regcache::raw_write_part): Likewise.
2657 (regcache::raw_supply): Likewise.
2658 (regcache::raw_supply_integer): Likewise.
2659 (regcache::raw_supply_zeroed): Likewise.
2660 (regcache::raw_collect): Likewise.
2661 (regcache::raw_collect_integer): Likewise.
2662 * regcache.h (regcache::assert_regnum): Declare.
2663
2e1b49b3
YQ
26642017-11-02 Yao Qi <yao.qi@linaro.org>
2665
2666 * regcache.c (regcache::dump): Remove code.
2667
6c5218df
YQ
26682017-11-02 Yao Qi <yao.qi@linaro.org>
2669
2670 * regcache.c (struct regcache_descr) <sizeof_raw_register_status>:
2671 Remove.
2672 <sizeof_cooked_register_status>: Remove.
2673 (init_regcache_descr): Update.
2674 (regcache::regcache): Use nr_cooked_registers and nr_raw_registers.
2675 (regcache::save): Likewise.
2676 (regcache::dump): Likewise.
2677
dcc31d28
JB
26782017-11-01 James Bowman <james.bowman@ftdichip.com>
2679
2680 * ft32-tdep.c (ft32_fetch_instruction): New function.
2681 (ft32_analyze_prologue): Use ft32_fetch_instruction().
2682
3a87ae65
SM
26832017-10-31 Simon Marchi <simon.marchi@polymtl.ca>
2684
2685 * cli/cli-script.c (execute_control_command): Rename to ...
2686 (execute_control_command_1): ... this.
2687 (execute_control_command): New function.
2688
09b847f3
SM
26892017-10-31 Simon Marchi <simon.marchi@ericsson.com>
2690
2691 * tracepoint.c (tfind_command): Remove const_cast.
2692
f871c485
MG
26932017-10-30 Mike Gulick <mgulick@mathworks.com>
2694
2695 * Makefile.in (HFILES_NO_SRCDIR): Remove reference to gdb.h.
2696
b020ff80
SM
26972017-10-30 Simon Marchi <simon.marchi@ericsson.com>
2698
2699 * common/common-utils.h (in_inclusive_range): New function.
2700 * arm-tdep.c (arm_record_extension_space): Use
2701 in_inclusive_range.
2702 (thumb_record_ld_st_reg_offset): Use in_inclusive_range.
2703 * cris-tdep.c (cris_spec_reg_applicable): Use
2704 in_inclusive_range.
2705
1b81856f
PA
27062017-10-30 Pedro Alves <palves@redhat.com>
2707 Simon Marchi <simon.marchi@ericsson.com>
2708
2709 * remote.c (remote_set_syscall_catchpoint): Build a std::string
2710 instead of a gdb::unique_xmalloc_ptr, using string_appendf.
2711
31b833b3
PA
27122017-10-30 Pedro Alves <palves@redhat.com>
2713
2714 * common/common-utils.c (string_appendf, string_vappendf): New
2715 functions.
2716 * common/common-utils.h (string_appendf, string_vappendf): New
2717 declarations.
2718 * unittests/common-utils-selftests.c (string_appendf_func)
2719 (test_appendf_func, string_vappendf_wrapper, string_appendf_tests)
2720 (string_vappendf_tests): New functions.
2721 (_initialize_common_utils_selftests): Register "string_appendf" and
2722 "string_vappendf tests".
2723
4a250334
PA
27242017-10-30 Pedro Alves <palves@redhat.com>
2725
2726 * unittests/common-utils-selftests.c (format_func): New typedef.
2727 (string_printf_tests, string_vprintf_tests): Tests factored out
2728 and merged to ...
2729 (test_format_func): ... this new function.
2730 (string_printf_tests, string_vprintf_tests): Reimplement on top of
2731 test_format_func.
2732
16c5c17e
SM
27332017-10-29 Simon Marchi <simon.marchi@ericsson.com>
2734
2735 * darwin-nat.c: Remove include of gdb.h.
2736
7ca51576
SM
27372017-10-29 Simon Marchi <simon.marchi@ericsson.com>
2738
2739 * xtensa-xtregs.c: Fix formatting issues.
2740
c1342859
SM
27412017-10-29 Simon Marchi <simon.marchi@ericsson.com>
2742
2743 * xtensa-xtregs.c (xtensa_regtable_t) <name>: Constify.
2744
484d8d36
MD
27452017-10-28 Maksim Dzabraev <dzabraew@gmail.com>
2746
2747 PR python/21213
2748 * python/py-infthread.c (thpy_get_inferior): Increment reference
2749 of inferior before returning it.
2750
b5540b5f
SM
27512017-10-27 Simon Marchi <simon.marchi@ericsson.com>
2752
2753 * unittests/common-utils-selftests.c (format): Add
2754 ATTRIBUTE_PRINTF.
2755
5a9dcda1
SM
27562017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
2757
2758 * xml-syscall.c (struct syscall_desc): Add constructor.
2759 <name>: Change type to std::string.
2760 (syscall_desc_up): New typedef.
2761 (syscall_desc_p): Remove typeder.
2762 (DEF_VEC_P(syscall_desc_p)): Remove.
2763 (struct syscall_group_desc): Add constructor.
2764 <name>: Change type to std::string.
2765 <syscalls>: Change type to std::vector.
2766 (syscall_group_desc_up): New typedef.
2767 (syscall_group_desc_p): Remove typedef.
2768 (DEF_VEC_P(syscall_group_desc_p)): Remove.
2769 (struct syscalls_info) <syscalls>: Change type to std::vector of
2770 unique_ptr.
2771 <groups>: Likewise.
2772 <my_gdb_datadir>: Change type to std::string.
2773 (syscalls_info_up): New typedef.
2774 (allocate_syscalls_info): Remove.
2775 (syscalls_info_free_syscalls_desc): Remove.
2776 (syscalls_info_free_syscall_group_desc): Remove.
2777 (free_syscalls_info): Remove.
2778 (make_cleanup_free_syscalls_info): Remove.
2779 (syscall_group_create_syscall_group_desc): Adjust.
2780 (syscall_group_add_syscall): Adjust.
2781 (syscall_create_syscall_desc): Adjust.
2782 (syscall_parse_xml): Adjust, use unique_ptr instead of cleanup.
2783 (init_syscalls_info): Adjust.
2784 (syscall_group_get_group_by_name): Adjust.
2785 (xml_get_syscall_number): Adjust.
2786 (xml_get_syscall_name): Adjust.
2787 (xml_list_of_syscalls): Adjust.
2788 (xml_list_syscalls_by_group): Adjust.
2789 (xml_list_of_groups): Adjust.
2790
45461e0d
SM
27912017-10-27 Simon Marchi <simon.marchi@ericsson.com>
2792
2793 * probe.h: Don't include gdb_vecs.h.
2794 (DEF_VEC_P (probe_p)): Remove.
2795 (find_probes_in_objfile): Return an std::vector.
2796 * probe.c (find_probes_in_objfile): Likewise.
2797 * breakpoint.c (breakpoint_objfile_data)
2798 <longjmp_probes>: Change type to std::vector.
2799 <exception_probes>: Likewise.
2800 (free_breakpoint_probes): Don't manually free vectors.
2801 (create_longjmp_master_breakpoint): Adjust.
2802 (create_exception_master_breakpoint): Adjust.
2803 * solib-svr4.c (svr4_create_probe_breakpoints): Change
2804 parameter type, adjust.
2805 (svr4_create_solib_event_breakpoints): Adjust.
2806
43dce439
SM
28072017-10-27 Simon Marchi <simon.marchi@ericsson.com>
2808
2809 * breakpoint.c (breakpoint_objfile_data): Initialize fields.
2810 (get_breakpoint_objfile_data): Allocate breakpoint_objfile_data
2811 with new.
2812 (free_breakpoint_probes): Rename to ...
2813 (free_breakpoint_objfile_data): ... this, and call delete on
2814 bp_objfile_data..
2815
6a1b9516
SM
28162017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
2817
2818 * auto-load.c: Don't include gdb_vecs.h, include algorithm.
2819 (loaded_script_ptr): Remove typedef.
2820 (DEF_VEC_P (loaded_script_ptr)): Remove.
2821 (struct collect_matching_scripts_data): Add constructor.
2822 <scripts_p>: Change type to (pointer to) std::vector.
2823 (collect_matching_scripts_data): Adjust.
2824 (sort_scripts_by_name): Make suitable for std::sort.
2825 (print_scripts): Don't sort vector, adjust to std::vector.
2826 (auto_load_info_scripts): Sort vectors, adjust to std::vector.
2827
593e3209
SM
28282017-10-27 Simon Marchi <simon.marchi@ericsson.com>
2829
2830 * symfile.c (filename_language): Make struct, not typedef. Add
2831 constructor.
2832 <ext>: Change type to std::string.
2833 (DEF_VEC_O (filename_language)): Remove.
2834 (filename_language_table): Change type to std::vector.
2835 (add_filename_language): Adjust.
2836 (set_ext_lang_command): Adjust.
2837 (info_ext_lang_command): Adjust.
2838 (deduce_language_from_filename): Adjust.
2839 (class scoped_restore_filename_language_table): Remove.
2840 (test_filename_language): Use scoped_restore.
2841 (test_set_ext_lang_command): Use scoped_restore, adjust to
2842 std::vector change.
2843
32fa66eb
SM
28442017-10-27 Simon Marchi <simon.marchi@ericsson.com>
2845
2846 * symfile.c: Include selftest.h.
2847 (class scoped_restore_filename_language_table): New.
2848 (test_filename_language): New test.
2849 (test_set_ext_lang_command): New test.
2850 (_initialize_symfile): Register tests.
2851
4a27f119
KS
28522017-10-27 Keith Seitz <keiths@redhat.com>
2853
2854 * breakpoint.c (print_breakpoint_location): Use the symbol saved
2855 in the bp_location, falling back to find_pc_sect_function when
2856 needed.
2857 (add_location_to_breakpoint): Save sal->symbol.
2858 * breakpoint.h (struct bp_location) <symbol>: New field.
2859 * symtab.c (find_function_start_sal): Save the symbol into the SaL.
2860 * symtab.h (struct symtab_and_line) <symbol>: New field.
2861
a43f3893
PF
28622017-10-26 Patrick Frants <osscontribute@gmail.com>
2863
7453e6b2 2864 PR gdb/13669
a43f3893
PF
2865 * cp-valprint.c (cp_print_value_fields): Use obstack_blank_fast
2866 to rewind obstack.
2867
23cc4e1b
PA
28682017-10-26 Pedro Alves <palves@redhat.com>
2869
2870 * remote.c (remote_async_terminal_ours_p): Delete.
2871 (remote_open_1, remote_terminal_inferior, remote_terminal_ours):
2872 Remove references to 'remote_async_terminal_ours_p'.
2873
6abc18bb
YQ
28742017-10-26 Yao Qi <yao.qi@linaro.org>
2875
2876 * breakpoint.h (regular_breakpoint_inserted_here_p): Remove.
2877
bd522513
YQ
28782017-10-26 Yao Qi <yao.qi@linaro.org>
2879
2880 * break-catch-sig.c (signal_catchpoint_breakpoint_hit): Make
2881 aspace const.
2882 * break-catch-syscall.c (breakpoint_hit_catch_syscall):
2883 Likewise.
2884 * breakpoint.c (bpstat_check_location): Remove cast.
2885 (breakpoint_hit_catch_fork): Make aspce const.
2886 (breakpoint_hit_catch_solib): Likewise.
2887 (breakpoint_hit_catch_exec): Likewise.
2888 (breakpoint_hit_ranged_breakpoint): Likewise.
2889 (breakpoint_hit_watchpoint): Likewise.
2890 (base_breakpoint_breakpoint_hit): Likewise.
2891 (bkpt_breakpoint_hit): Likewise.
2892 (dprintf_breakpoint_hit): Likewise.
2893 (tracepoint_breakpoint_hit): Likewise.
2894 * breakpoint.h (breakpoint_ops) <breakpoint_hit>: Likewise.
2895
accd0bcd
YQ
28962017-10-26 Yao Qi <yao.qi@linaro.org>
2897
2898 * breakpoint.c (breakpoint_location_address_match): Change
2899 "struct address_space *" to "const address_space".
2900 (breakpoint_location_address_range_overlap): Likewise.
2901 (breakpoint_here_p): Likewise.
2902 (breakpoint_in_range_p): Likewise.
2903 (moribund_breakpoint_here_p): Likewise.
2904 (bp_location_inserted_here_p): Likewise.
2905 (software_breakpoint_inserted_here_p): Likewise.
2906 (hardware_breakpoint_inserted_here_p): Likewise.
2907 (hardware_watchpoint_inserted_in_range): Likewise.
2908 (bpstat_check_location): Likewise.
2909 (bpstat_stop_status): Likewise.
2910 (breakpoint_address_match): Likewise.
2911 (breakpoint_address_match_range): Likewise.
2912 (breakpoint_location_address_match): Likewise.
2913 (breakpoint_location_address_range_overlap): Likewise.
2914 (insert_single_step_breakpoint): Likewise.
2915 (breakpoint_has_location_inserted_here): Likewise.
2916 (single_step_breakpoint_inserted_here_p): Likewise.
2917 (pc_at_non_inline_function): Likewise.
2918 * breakpoint.h (bpstat_stop_status): Update declaration.
2919 (breakpoint_here_p): Likewise.
2920 (breakpoint_in_range_p): Likewise.
2921 (moribund_breakpoint_here_p): Likewise.
2922 (breakpoint_inserted_here_p): Likewise.
2923 (software_breakpoint_inserted_here_p): Likewise.
2924 (hardware_breakpoint_inserted_here_p): Likewise.
2925 (breakpoint_has_location_inserted_here): Likewise.
2926 (single_step_breakpoint_inserted_here_p): Likewise.
2927 (hardware_watchpoint_inserted_in_range): Likewise.
2928 (breakpoint_address_match): Likewise.
2929 (insert_single_step_breakpoint): Likewise.
2930 (pc_at_non_inline_function): Likewise.
2931 * gdbthread.h (thread_has_single_step_breakpoint_here): Likewise.
2932 * record.c (record_check_stopped_by_breakpoint): Likewise.
2933 * record.h (record_check_stopped_by_breakpoint): Likewise.
2934 * thread.c (thread_has_single_step_breakpoint_here): Likewise.
2935
ac7936df
YQ
29362017-10-25 Yao Qi <yao.qi@linaro.org>
2937
2938 * aarch32-linux-nat.c (aarch32_gp_regcache_supply): Use
2939 regcache->arch () instead get_regcache_arch.
2940 * aarch64-fbsd-nat.c (aarch64_fbsd_fetch_inferior_registers):
2941 Likewise.
2942 (aarch64_fbsd_store_inferior_registers): Likewise.
2943 * aarch64-linux-nat.c (fetch_gregs_from_thread): Likewise.
2944 (store_gregs_to_thread): Likewise.
2945 (fetch_fpregs_from_thread): Likewise.
2946 (store_fpregs_to_thread): Likewise.
2947 * aarch64-tdep.c (aarch64_extract_return_value): Likewise.
2948 (aarch64_store_return_value): Likewise.
2949 (aarch64_software_single_step): Likewise.
2950 * aix-thread.c (aix_thread_wait): Likewise.
2951 (supply_reg32): Likewise.
2952 (supply_sprs64): Likewise.
2953 (supply_sprs32): Likewise.
2954 (fill_gprs64): Likewise.
2955 (fill_gprs32): Likewise.
2956 (fill_sprs64): Likewise.
2957 (fill_sprs32): Likewise.
2958 (store_regs_user_thread): Likewise.
2959 (store_regs_kernel_thread): Likewise.
2960 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers): Likewise.
2961 (alphabsd_store_inferior_registers): Likewise.
2962 * alpha-tdep.c (alpha_extract_return_value): Likewise.
2963 (alpha_store_return_value): Likewise.
2964 (alpha_deal_with_atomic_sequence): Likewise.
2965 (alpha_next_pc): Likewise.
2966 (alpha_software_single_step): Likewise.
2967 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Likewise.
2968 (amd64bsd_store_inferior_registers): Likewise.
2969 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers):
2970 Likewise.
2971 (amd64_linux_store_inferior_registers): Likewise.
2972 * amd64-nat.c (amd64_supply_native_gregset): Likewise.
2973 (amd64_collect_native_gregset): Likewise.
2974 * amd64-obsd-tdep.c (amd64obsd_supply_uthread): Likewise.
2975 (amd64obsd_collect_uthread): Likewise.
2976 * amd64-tdep.c (amd64_supply_fpregset): Likewise.
2977 (amd64_collect_fpregset): Likewise.
2978 (amd64_supply_fxsave): Likewise.
2979 (amd64_supply_xsave): Likewise.
2980 (amd64_collect_fxsave): Likewise.
2981 (amd64_collect_xsave): Likewise.
2982 * arc-tdep.c (arc_write_pc): Likewise.
2983 * arch-utils.c (default_skip_permanent_breakpoint): Likewise.
2984 * arm-fbsd-nat.c (arm_fbsd_fetch_inferior_registers): Likewise.
2985 (arm_fbsd_store_inferior_registers): Likewise.
2986 * arm-linux-nat.c (fetch_vfp_regs): Likewise.
2987 (store_vfp_regs): Likewise.
2988 (arm_linux_fetch_inferior_registers): Likewise.
2989 (arm_linux_store_inferior_registers): Likewise.
2990 * arm-linux-tdep.c (arm_linux_supply_gregset): Likewise.
2991 (arm_linux_sigreturn_next_pc): Likewise.
2992 (arm_linux_get_next_pcs_syscall_next_pc): Likewise.
2993 * arm-nbsd-nat.c (arm_supply_gregset): Likewise.
2994 (fetch_register): Likewise.
2995 (store_register): Likewise.
2996 * arm-tdep.c (arm_is_thumb): Likewise.
2997 (displaced_in_arm_mode): Likewise.
2998 (bx_write_pc): Likewise.
2999 (arm_get_next_pcs_addr_bits_remove): Likewise.
3000 (arm_software_single_step): Likewise.
3001 (arm_extract_return_value): Likewise.
3002 (arm_store_return_value): Likewise.
3003 (arm_write_pc): Likewise.
3004 * bfin-tdep.c (bfin_extract_return_value): Likewise.
3005 * bsd-uthread.c (bsd_uthread_fetch_registers): Likewise.
3006 (bsd_uthread_store_registers): Likewise.
3007 * core-regset.c (fetch_core_registers): Likewise.
3008 * corelow.c (get_core_registers): Likewise.
3009 * cris-tdep.c (cris_store_return_value): Likewise.
3010 (cris_extract_return_value): Likewise.
3011 (find_step_target): Likewise.
3012 (find_step_target): Likewise.
3013 (cris_software_single_step): Likewise.
3014 * ctf.c (ctf_fetch_registers): Likewise.
3015 * darwin-nat.c (cancel_breakpoint): Likewise.
3016 * fbsd-tdep.c (fbsd_collect_thread_registers): Likewise.
3017 * frv-tdep.c (frv_extract_return_value): Likewise.
3018 * ft32-tdep.c (ft32_store_return_value): Likewise.
3019 (ft32_extract_return_value): Likewise.
3020 * go32-nat.c (fetch_register): Likewise.
3021 (go32_fetch_registers): Likewise.
3022 (go32_store_registers): Likewise.
3023 (store_register): Likewise.
3024 * h8300-tdep.c (h8300_extract_return_value): Likewise.
3025 (h8300_store_return_value): Likewise.
3026 * hppa-linux-nat.c (fetch_register): Likewise.
3027 (store_register): Likewise.
3028 (hppa_linux_fetch_inferior_registers): Likewise.
3029 (hppa_linux_store_inferior_registers): Likewise.
3030 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers): Likewise.
3031 (i386_darwin_store_inferior_registers): Likewise.
3032 * i386-gnu-nat.c (gnu_fetch_registers): Likewise.
3033 (gnu_store_registers): Likewise.
3034 * i386-linux-nat.c (fetch_register): Likewise.
3035 (store_register): Likewise.
3036 (supply_gregset): Likewise.
3037 (fill_gregset): Likewise.
3038 (i386_linux_fetch_inferior_registers): Likewise.
3039 (i386_linux_store_inferior_registers): Likewise.
3040 (i386_linux_resume): Likewise.
3041 * i386-linux-tdep.c (i386_linux_get_syscall_number_from_regcache):
3042 Likewise.
3043 * i386-nto-tdep.c (i386nto_supply_gregset): Likewise.
3044 * i386-obsd-nat.c (i386obsd_supply_pcb): Likewise.
3045 * i386-obsd-tdep.c (i386obsd_supply_uthread): Likewise.
3046 (i386obsd_collect_uthread): Likewise.
3047 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
3048 (i386_supply_gregset): Likewise.
3049 (i386_collect_gregset): Likewise.
3050 (i386_supply_fpregset): Likewise.
3051 (i386_collect_fpregset): Likewise.
3052 (i386_mpx_bd_base): Likewise.
3053 * i386-v4-nat.c (supply_fpregset): Likewise.
3054 (fill_fpregset): Likewise.
3055 * i387-tdep.c (i387_supply_fsave): Likewise.
3056 (i387_collect_fsave): Likewise.
3057 (i387_supply_fxsave): Likewise.
3058 (i387_collect_fxsave): Likewise.
3059 (i387_supply_xsave): Likewise.
3060 (i387_collect_xsave): Likewise.
3061 * ia64-linux-nat.c (ia64_linux_fetch_registers): Likewise.
3062 (ia64_linux_store_registers): Likewise.
3063 * ia64-tdep.c (ia64_access_rse_reg): Likewise.
3064 (ia64_extract_return_value): Likewise.
3065 (ia64_store_return_value): Likewise.
3066 (find_func_descr): Likewise.
3067 * inf-child.c (inf_child_fetch_inferior_registers): Likewise.
3068 * inf-ptrace.c (inf_ptrace_fetch_registers): Likewise.
3069 (inf_ptrace_store_registers): Likewise.
3070 * infrun.c (use_displaced_stepping): Likewise.
3071 (displaced_step_prepare_throw): Likewise.
3072 (resume): Likewise.
3073 (proceed): Likewise.
3074 (do_target_wait): Likewise.
3075 (adjust_pc_after_break): Likewise.
3076 (handle_inferior_event_1): Likewise.
3077 (handle_signal_stop): Likewise.
3078 (save_infcall_suspend_state): Likewise.
3079 (restore_infcall_suspend_state): Likewise.
3080 * iq2000-tdep.c (iq2000_extract_return_value): Likewise.
3081 * jit.c (jit_frame_prev_register): Likewise.
3082 * linux-nat.c (save_stop_reason): Likewise.
3083 (linux_nat_wait_1): Likewise.
3084 (resume_stopped_resumed_lwps): Likewise.
3085 * linux-record.c (record_linux_sockaddr): Likewise.
3086 (record_linux_msghdr): Likewise.
3087 (record_linux_system_call): Likewise.
3088 * linux-tdep.c (linux_collect_thread_registers): Likewise.
3089 * lm32-tdep.c (lm32_extract_return_value): Likewise.
3090 (lm32_store_return_value): Likewise.
3091 * m32c-tdep.c (m32c_read_flg): Likewise.
3092 (m32c_pseudo_register_read): Likewise.
3093 (m32c_pseudo_register_write): Likewise.
3094 * m32r-linux-tdep.c (m32r_linux_supply_gregset): Likewise.
3095 (m32r_linux_collect_gregset): Likewise.
3096 * m32r-tdep.c (m32r_store_return_value): Likewise.
3097 (m32r_extract_return_value): Likewise.
3098 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
3099 (m68kbsd_collect_fpregset): Likewise.
3100 * m68k-bsd-tdep.c (m68kbsd_supply_fpregset): Likewise.
3101 * m68k-linux-nat.c (fetch_register): Likewise.
3102 (old_fetch_inferior_registers): Likewise.
3103 (old_store_inferior_registers): Likewise.
3104 (store_regs): Likewise.
3105 * m68k-tdep.c (m68k_svr4_extract_return_value): Likewise.
3106 (m68k_svr4_store_return_value): Likewise.
3107 * m88k-tdep.c (m88k_store_arguments): Likewise.
3108 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Likewise.
3109 (mi_cmd_data_write_register_values): Likewise.
3110 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers): Likewise.
3111 (mips_fbsd_store_inferior_registers): Likewise.
3112 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Likewise.
3113 (mips_fbsd_supply_gregs): Likewise.
3114 (mips_fbsd_collect_fpregs): Likewise.
3115 (mips_fbsd_collect_gregs): Likewise.
3116 (mips_fbsd_supply_fpregset): Likewise.
3117 (mips_fbsd_collect_fpregset): Likewise.
3118 (mips_fbsd_supply_gregset): Likewise.
3119 (mips_fbsd_collect_gregset): Likewise.
3120 * mips-linux-nat.c (supply_gregset): Likewise.
3121 (fill_gregset): Likewise.
3122 (supply_fpregset): Likewise.
3123 (fill_fpregset): Likewise.
3124 * mips-linux-tdep.c (mips_supply_gregset): Likewise.
3125 (mips_fill_gregset): Likewise.
3126 (mips_supply_fpregset): Likewise.
3127 (mips_fill_fpregset): Likewise.
3128 (mips64_supply_gregset): Likewise.
3129 (micromips_linux_sigframe_validate): Likewise.
3130 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers): Likewise.
3131 (mipsnbsd_fetch_inferior_registers): Likewise.
3132 (mipsnbsd_store_inferior_registers): Likewise.
3133 * mips-nbsd-tdep.c (mipsnbsd_supply_fpregset): Likewise.
3134 (mipsnbsd_supply_gregset): Likewise.
3135 (mipsnbsd_iterate_over_regset_sections): Likewise.
3136 (mipsnbsd_supply_reg): Likewise.
3137 (mipsnbsd_supply_fpreg): Likewise.
3138 * mips-tdep.c (mips_in_frame_stub): Likewise.
3139 (mips_dummy_id): Likewise.
3140 (is_octeon_bbit_op): Likewise.
3141 (micromips_bc1_pc): Likewise.
3142 (extended_mips16_next_pc): Likewise.
3143 (mips16_next_pc): Likewise.
3144 (deal_with_atomic_sequence): Likewise.
3145 * moxie-tdep.c (moxie_process_readu): Likewise.
3146 * nios2-tdep.c (nios2_get_next_pc): Likewise.
3147 * nto-procfs.c (procfs_store_registers): Likewise.
3148 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers): Likewise.
3149 (ppcfbsd_store_inferior_registers): Likewise.
3150 * ppc-linux-nat.c (fetch_vsx_register): Likewise.
3151 (fetch_altivec_register): Likewise.
3152 (get_spe_registers): Likewise.
3153 (fetch_spe_register): Likewise.
3154 (fetch_altivec_registers): Likewise.
3155 (fetch_all_gp_regs): Likewise.
3156 (fetch_all_fp_regs): Likewise.
3157 (store_vsx_register): Likewise.
3158 (store_altivec_register): Likewise.
3159 (set_spe_registers): Likewise.
3160 (store_spe_register): Likewise.
3161 (store_altivec_registers): Likewise.
3162 (store_all_gp_regs): Likewise.
3163 (store_all_fp_regs): Likewise.
3164 * ppc-linux-tdep.c (ppc_linux_supply_gregset): Likewise.
3165 (ppc_linux_collect_gregset): Likewise.
3166 (ppc_canonicalize_syscall): Likewise.
3167 (ppc_linux_record_signal): Likewise.
3168 (ppu2spu_prev_register): Likewise.
3169 * ppc-nbsd-nat.c (ppcnbsd_supply_pcb): Likewise.
3170 * ppc-obsd-nat.c (ppcobsd_fetch_registers): Likewise.
3171 (ppcobsd_store_registers): Likewise.
3172 * ppc-ravenscar-thread.c (ppc_ravenscar_generic_fetch_registers):
3173 Likewise.
3174 (ppc_ravenscar_generic_store_registers): Likewise.
3175 * procfs.c (procfs_fetch_registers): Likewise.
3176 (procfs_store_registers): Likewise.
3177 * ravenscar-thread.c (ravenscar_fetch_registers): Likewise.
3178 (ravenscar_store_registers): Likewise.
3179 (ravenscar_prepare_to_store): Likewise.
3180 * record-btrace.c (record_btrace_fetch_registers): Likewise.
3181 * record-full.c (record_full_wait_1): Likewise.
3182 (record_full_registers_change): Likewise.
3183 (record_full_store_registers): Likewise.
3184 (record_full_core_fetch_registers): Likewise.
3185 (record_full_save): Likewise.
3186 (record_full_goto_insn): Likewise.
3187 * regcache.c (regcache_register_size): Likewise.
3188 (get_regcache_arch): Remove.
3189 (regcache_read_pc): Likewise.
3190 * regcache.h (get_regcache_arch): Remove.
3191 * remote-sim.c (gdbsim_fetch_register): Likewise.
3192 (gdbsim_store_register): Likewise.
3193 * remote.c (fetch_register_using_p): Likewise.
3194 (send_g_packet): Likewise.
3195 (remote_prepare_to_store): Likewise.
3196 (store_registers_using_G): Likewise.
3197 * reverse.c (save_bookmark_command): Likewise.
3198 (goto_bookmark_command): Likewise.
3199 * rs6000-aix-tdep.c (branch_dest): Likewise.
3200 * rs6000-nat.c (rs6000_ptrace64): Likewise.
3201 (fetch_register): Likewise.
3202 * rs6000-tdep.c (ppc_supply_reg): Likewise.
3203 (ppc_collect_reg): Likewise.
3204 (ppc_collect_gregset): Likewise.
3205 (ppc_collect_fpregset): Likewise.
3206 (ppc_collect_vsxregset): Likewise.
3207 (ppc_collect_vrregset): Likewise.
3208 (ppc_displaced_step_hw_singlestep): Likewise.
3209 (rs6000_pseudo_register_read): Likewise.
3210 (rs6000_pseudo_register_write): Likewise.
3211 * s390-linux-nat.c (supply_gregset): Likewise.
3212 (fill_gregset): Likewise.
3213 (s390_linux_fetch_inferior_registers): Likewise.
3214 * s390-linux-tdep.c (s390_write_pc): Likewise.
3215 (s390_software_single_step): Likewise.
3216 (s390_all_but_pc_registers_record): Likewise.
3217 (s390_linux_syscall_record): Likewise.
3218 * sentinel-frame.c (sentinel_frame_prev_arch): Likewise.
3219 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers): Likewise.
3220 (shnbsd_store_inferior_registers): Likewise.
3221 * sh-tdep.c (sh_extract_return_value_nofpu): Likewise.
3222 (sh_extract_return_value_fpu): Likewise.
3223 (sh_store_return_value_nofpu): Likewise.
3224 (sh_corefile_supply_regset): Likewise.
3225 (sh_corefile_collect_regset): Likewise.
3226 * sh64-tdep.c (sh64_extract_return_value): Likewise.
3227 (sh64_store_return_value): Likewise.
3228 * sparc-linux-tdep.c (sparc32_linux_collect_core_fpregset): Likewise.
3229 * sparc-nat.c (sparc_fetch_inferior_registers): Likewise.
3230 (sparc_store_inferior_registers): Likewise.
3231 * sparc-ravenscar-thread.c (register_in_thread_descriptor_p): Likewise.
3232 (sparc_ravenscar_prepare_to_store): Likewise.
3233 * sparc-tdep.c (sparc32_store_arguments): Likewise.
3234 (sparc_analyze_control_transfer): Likewise.
3235 (sparc_step_trap): Likewise.
3236 (sparc_software_single_step): Likewise.
3237 (sparc32_gdbarch_init): Likewise.
3238 (sparc_supply_rwindow): Likewise.
3239 (sparc_collect_rwindow): Likewise.
3240 * sparc64-linux-tdep.c (sparc64_linux_collect_core_fpregset): Likewise.
3241 * sparc64-nbsd-nat.c (sparc64nbsd_supply_gregset): Likewise.
3242 (sparc64nbsd_collect_gregset): Likewise.
3243 (sparc64nbsd_supply_fpregset): Likewise.
3244 (sparc64nbsd_collect_fpregset): Likewise.
3245 * sparc64-tdep.c (sparc64_store_arguments): Likewise.
3246 (sparc64_supply_gregset): Likewise.
3247 (sparc64_collect_gregset): Likewise.
3248 (sparc64_supply_fpregset): Likewise.
3249 (sparc64_collect_fpregset): Likewise.
3250 * spu-linux-nat.c (spu_fetch_inferior_registers): Likewise.
3251 * spu-tdep.c (spu_unwind_sp): Likewise.
3252 (spu2ppu_prev_register): Likewise.
3253 (spu_memory_remove_breakpoint): Likewise.
3254 * stack.c (return_command): Likewise.
3255 * tic6x-tdep.c (tic6x_extract_signed_field): Likewise.
3256 * tracefile-tfile.c (tfile_fetch_registers): Likewise.
3257 * tracefile.c (trace_save_ctf): Likewise.
3258 * windows-nat.c (do_windows_fetch_inferior_registers): Likewise.
3259 (do_windows_store_inferior_registers): Likewise.
3260 (windows_resume): Likewise.
3261 * xtensa-linux-nat.c (fill_gregset): Likewise.
3262 (supply_gregset_reg): Likewise.
3263 * xtensa-tdep.c (xtensa_register_write_masked): Likewise.
3264 (xtensa_register_read_masked): Likewise.
3265 (xtensa_supply_gregset): Likewise.
3266 (xtensa_extract_return_value): Likewise.
3267 (xtensa_store_return_value): Likewise.
3268
edd079d9
UW
32692017-10-25 Ulrich Weigand <uweigand@de.ibm.com>
3270
3271 * doublest.c (floatformat_from_string): New function.
3272 * doublest.h (floatformat_from_string): Add prototype.
3273
3274 * std-operator.def (OP_DOUBLE, OP_DECFLOAT): Remove, replace by ...
3275 (OP_FLOAT): ... this.
3276 * expression.h: Do not include "doublest.h".
3277 (union exp_element): Replace doubleconst and decfloatconst by
3278 new element floatconst.
3279 * ada-lang.c (resolve_subexp): Handle OP_FLOAT instead of OP_DOUBLE.
3280 (ada_evaluate_subexp): Likewise.
3281 * eval.c (evaluate_subexp_standard): Handle OP_FLOAT instead of
3282 OP_DOUBLE and OP_DECFLOAT.
3283 * expprint.c (print_subexp_standard): Likewise.
3284 (dump_subexp_body_standard): Likewise.
3285 * breakpoint.c (watchpoint_exp_is_const): Likewise.
3286
3287 * parse.c: Include "dfp.h".
3288 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
3289 (write_exp_elt_floatcst): New function.
3290 (operator_length_standard): Handle OP_FLOAT instead of OP_DOUBLE
3291 and OP_DECFLOAT.
3292 (operator_check_standard): Likewise.
3293 (parse_float): Do not accept suffix. Take type as input. Return bool.
3294 Return target format buffer instead of host DOUBLEST.
3295 Use floatformat_from_string and decimal_from_string to parse
3296 either binary or decimal floating-point types.
3297 (parse_c_float): Remove.
3298 * parser-defs.h: Do not include "doublest.h".
3299 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
3300 (write_exp_elt_floatcst): Add prototype.
3301 (parse_float): Update prototype.
3302 (parse_c_float): Remove.
3303
3304 * c-exp.y: Do not include "dfp.h".
3305 (typed_val_float): Use byte buffer instead of DOUBLEST.
3306 (typed_val_decfloat): Remove.
3307 (DECFLOAT): Remove.
3308 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3309 (parse_number): Update to new parse_float interface.
3310 Parse suffixes and determine type before calling parse_float.
3311 Handle decimal and binary FP types the same way.
3312
3313 * d-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
3314 (FLOAT_LITERAL): Use OP_FLOAT and write_exp_elt_floatcst.
3315 (parse_number): Update to new parse_float interface.
3316 Parse suffixes and determine type before calling parse_float.
3317
3318 * f-exp.y: Replace dval by typed_val_float.
3319 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3320 (parse_number): Use parse_float instead of atof.
3321
3322 * go-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
3323 (parse_go_float): Remove.
3324 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3325 (parse_number): Call parse_float instead of parse_go_float.
3326 Parse suffixes and determine type before calling parse_float.
3327
3328 * p-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
3329 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3330 (parse_number): Update to new parse_float interface.
3331 Parse suffixes and determine type before calling parse_float.
3332
3333 * m2-exp.y: Replace dval by byte buffer val.
3334 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3335 (parse_number): Call parse_float instead of atof.
3336
3337 * rust-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
3338 (lex_number): Call parse_float instead of strtod.
3339 (ast_dliteral): Use OP_FLOAT instead of OP_DOUBLE.
3340 (convert_ast_to_expression): Handle OP_FLOAT instead of OP_DOUBLE.
3341 Use write_exp_elt_floatcst.
3342 (unit_testing): Remove static variable.
3343 (rust_type): Do not check unit_testing.
3344 (rust_lex_tests): Do not set uint_testing. Set up dummy rust_parser.
3345
3346 * ada-exp.y (type_float, type_double): Remove.
3347 (typed_val_float): Use byte buffer instead of DOUBLEST.
3348 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3349 * ada-lex.l (processReal): Use parse_float instead of sscanf.
3350
cc628f3d
AH
33512017-10-25 Alan Hayward <alan.hayward@arm.com>
3352
3353 * aarch64-tdep.h (enum aarch64_regnum): Remove.
3354 * arch/aarch64.h: New file.
3355
09a7c6aa
UW
33562017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
3357
3358 * dfp.h (decimal_from_string): Use const reference for argument.
3359 * dfp.c (decimal_from_string): Likewise.
3360
8ba0dd51
UW
33612017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
3362
3363 * i387-tdep.c (print_i387_value): Use floatformat_to_string.
3364 * sh64-tdep.c (sh64_do_fp_register): Likewise.
3365 * mips-tdep.c (mips_print_fp_register): Likewise.
3366
16e812b2
UW
33672017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
3368
3369 * common/format.h (enum argclass): Replace decfloat_arg by
3370 dec32float_arg, dec64float_arg, and dec128float_arg.
3371 * common/format.c (parse_format_string): Update to return
3372 new decimal float argument classes.
3373
3374 * printcmd.c (printf_decfloat): Rename to ...
3375 (printf_floating): ... this. Add argclass argument, and use it
3376 instead of parsing the format string again. Add support for
3377 binary floating-point values, using floatformat_to_string.
3378 Convert value to the target format if it doesn't already match.
3379 (ui_printf): Call printf_floating instead of printf_decfloat,
3380 also for double_arg / long_double_arg. Pass argclass.
3381
3382 * dfp.c (decimal_to_string): Add format string argument.
3383 * dfp.h (decimal_to_string): Likewise.
3384
3385 * doublest.c (floatformat_to_string): Add format string argument.
3386 * doublest.h (floatformat_to_string): Likewise.
3387
fdf0cbc2
UW
33882017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
3389
3390 * doublest.c (floatformat_precision): New routine.
3391 (floatformat_to_string): Likewise.
3392 * doublest.c (floatformat_to_string): Add prototype.
3393
3394 * printcmd.c (print_scalar_formatted): Only call print_floating
3395 on floating-point types.
3396 * valprint.c: Do not include "floatformat.h".
3397 (generic_val_print_decfloat): Remove.
3398 (generic_val_print): Call generic_val_print_float for both
3399 TYPE_CODE_FLT and TYPE_CODE_DECFLOAT.
3400 (print_floating): Use floatformat_to_string. Handle decimal float.
3401 (print_decimal_floating): Remove, merge into floatformat_to_string.
3402 * value.h (print_decimal_floating): Remove.
3403
3404 * Makefile.in: Do not build doublest.c with -Wformat-nonliteral.
3405
5033013f
UW
34062017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
3407
3408 * buildsym.c (end_symtab_get_static_block): Use std::stable_sort.
3409
a664f67e
SM
34102017-10-21 Simon Marchi <simon.marchi@ericsson.com>
3411
3412 * memattr.h: Don't include vec.h.
3413 (struct mem_attrib): Initialize fields.
3414 <unknown>: New static method.
3415 (struct mem_region): Add constructors, operator<, initialize
3416 fields.
3417 * memattr.c: Include algorithm.
3418 (default_mem_attrib, unknown_mem_attrib): Remove.
3419 (user_mem_region_list): New global.
3420 (target_mem_region_list, mem_region_list): Change type to
3421 std::vector<mem_region>.
3422 (mem_use_target): Now a function.
3423 (target_mem_regions_valid): Change type to bool.
3424 (mem_region_lessthan, mem_region_cmp, mem_region_init): Remove.
3425 (require_user_regions): Adjust.
3426 (require_target_regions): Adjust.
3427 (create_mem_region): Adjust.
3428 (lookup_mem_region): Adjust.
3429 (invalidate_target_mem_regions): Adjust.
3430 (mem_clear): Rename to...
3431 (user_mem_clear): ... this, and adjust.
3432 (mem_command): Adjust.
3433 (info_mem_command): Adjust.
3434 (mem_enable, enable_mem_command, mem_disable,
3435 disable_mem_command): Adjust.
3436 (mem_delete): Adjust.
3437 (delete_mem_command): Adjust.
3438 * memory-map.h (parse_memory_map): Return an std::vector.
3439 * memory-map.c (parse_memory_map): Likewise.
3440 (struct memory_map_parsing_data): Add constructor.
3441 <memory_map>: Point to std::vector.
3442 (memory_map_start_memory): Adjust.
3443 (memory_map_end_memory): Adjust.
3444 (memory_map_end_property): Adjust.
3445 (clear_result): Remove.
3446 * remote.c (remote_memory_map): Return an std::vector.
3447 * target-debug.h (target_debug_print_VEC_mem_region_s__p):
3448 Remove.
3449 (target_debug_print_mem_region_vector): New.
3450 * target-delegates.c: Regenerate.
3451 * target.h (mem_region_vector): New typedef.
3452 (to_memory_map): Return mem_region_vector.
3453 (target_memory_map): Return an std::vector.
3454 * target.c (target_memory_map): Return an std::vector.
3455 (flash_erase_command): Adjust.
3456
6e17c565
SM
34572017-10-21 Simon Marchi <simon.marchi@ericsson.com>
3458
3459 * memory-map.c (struct memory_map_parsing_data) <property_name>:
3460 Change type to std::string.
3461 (memory_map_start_property): Adjust.
3462 (memory_map_end_property): Adjust.
3463
cfba9872
SM
34642017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
3465
3466 * infrun.h: Include common/byte-vector.h.
3467 (struct displaced_step_closure): New struct.
3468 (struct buf_displaced_step_closure): New struct.
3469 * infrun.c (displaced_step_closure::~displaced_step_closure):
3470 Provide default implementation.
3471 (displaced_step_clear): Deallocate step closure with delete.
3472 * aarch64-tdep.c (displaced_step_closure): Rename to ...
3473 (aarch64_displaced_step_closure): ... this, extend
3474 displaced_step_closure.
3475 (aarch64_displaced_step_data) <dsc>: Change type to
3476 aarch64_displaced_step_closure.
3477 (aarch64_displaced_step_copy_insn): Adjust to type change, use
3478 unique_ptr.
3479 (aarch64_displaced_step_fixup): Add cast for displaced step
3480 closure.
3481 * amd64-tdep.c (displaced_step_closure): Rename to ...
3482 (amd64_displaced_step_closure): ... this, extend
3483 displaced_step_closure.
3484 <insn_buf>: Change type to std::vector<gdb_byte>.
3485 <max_len>: Remove.
3486 (fixup_riprel): Change type of DSC parameter, adjust to type
3487 change of insn_buf.
3488 (fixup_displaced_copy): Change type of DSC parameter.
3489 (amd64_displaced_step_copy_insn): Instantiate
3490 amd64_displaced_step_closure.
3491 (amd64_displaced_step_fixup): Add cast for closure type, adjust
3492 to type change of insn_buf.
3493 * arm-linux-tdep.c (arm_linux_cleanup_svc): Change type of
3494 parameter DSC.
3495 (arm_linux_copy_svc): Likewise.
3496 (cleanup_kernel_helper_return): Likewise.
3497 (arm_catch_kernel_helper_return): Likewise.
3498 (arm_linux_displaced_step_copy_insn): Instantiate
3499 arm_displaced_step_closure.
3500 * arm-tdep.c (arm_pc_is_thumb): Add cast for closure.
3501 (displaced_read_reg): Change type of parameter DSC.
3502 (branch_write_pc): Likewise.
3503 (load_write_pc): Likewise.
3504 (alu_write_pc): Likewise.
3505 (displaced_write_reg): Likewise.
3506 (arm_copy_unmodified): Likewise.
3507 (thumb_copy_unmodified_32bit): Likewise.
3508 (thumb_copy_unmodified_16bit): Likewise.
3509 (cleanup_preload): Likewise.
3510 (install_preload): Likewise.
3511 (arm_copy_preload): Likewise.
3512 (thumb2_copy_preload): Likewise.
3513 (install_preload_reg): Likewise.
3514 (arm_copy_preload_reg): Likewise.
3515 (cleanup_copro_load_store): Likewise.
3516 (install_copro_load_store): Likewise.
3517 (arm_copy_copro_load_store) Likewise.
3518 (thumb2_copy_copro_load_store): Likewise.
3519 (cleanup_branch): Likewise.
3520 (install_b_bl_blx): Likewise.
3521 (arm_copy_b_bl_blx): Likewise.
3522 (thumb2_copy_b_bl_blx): Likewise.
3523 (thumb_copy_b): Likewise.
3524 (install_bx_blx_reg): Likewise.
3525 (arm_copy_bx_blx_reg): Likewise.
3526 (thumb_copy_bx_blx_reg): Likewise.
3527 (cleanup_alu_imm): Likewise.
3528 (arm_copy_alu_imm): Likewise.
3529 (thumb2_copy_alu_imm): Likewise.
3530 (cleanup_alu_reg): Likewise.
3531 (install_alu_reg): Likewise.
3532 (arm_copy_alu_reg): Likewise.
3533 (thumb_copy_alu_reg): Likewise.
3534 (cleanup_alu_shifted_reg): Likewise.
3535 (install_alu_shifted_reg): Likewise.
3536 (arm_copy_alu_shifted_reg): Likewise.
3537 (cleanup_load): Likewise.
3538 (cleanup_store): Likewise.
3539 (arm_copy_extra_ld_st): Likewise.
3540 (install_load_store): Likewise.
3541 (thumb2_copy_load_literal): Likewise.
3542 (thumb2_copy_load_reg_imm): Likewise.
3543 (arm_copy_ldr_str_ldrb_strb): Likewise.
3544 (cleanup_block_load_all): Likewise.
3545 (cleanup_block_store_pc): Likewise.
3546 (cleanup_block_load_pc): Likewise.
3547 (arm_copy_block_xfer): Likewise.
3548 (thumb2_copy_block_xfer): Likewise.
3549 (cleanup_svc): Likewise.
3550 (install_svc): Likewise.
3551 (arm_copy_svc): Likewise.
3552 (thumb_copy_svc): Likewise.
3553 (arm_copy_undef): Likewise.
3554 (thumb_32bit_copy_undef): Likewise.
3555 (arm_copy_unpred): Likewise.
3556 (arm_decode_misc_memhint_neon): Likewise.
3557 (arm_decode_unconditional): Likewise.
3558 (arm_decode_miscellaneous): Likewise.
3559 (arm_decode_dp_misc): Likewise.
3560 (arm_decode_ld_st_word_ubyte): Likewise.
3561 (arm_decode_media): Likewise.
3562 (arm_decode_b_bl_ldmstm): Likewise.
3563 (arm_decode_ext_reg_ld_st): Likewise.
3564 (thumb2_decode_dp_shift_reg): Likewise.
3565 (thumb2_decode_ext_reg_ld_st): Likewise.
3566 (arm_decode_svc_copro): Likewise.
3567 (thumb2_decode_svc_copro): Likewise.
3568 (install_pc_relative): Likewise.
3569 (thumb_copy_pc_relative_16bit): Likewise.
3570 (thumb_decode_pc_relative_16bit): Likewise.
3571 (thumb_copy_pc_relative_32bit): Likewise.
3572 (thumb_copy_16bit_ldr_literal): Likewise.
3573 (thumb_copy_cbnz_cbz): Likewise.
3574 (thumb2_copy_table_branch): Likewise.
3575 (cleanup_pop_pc_16bit_all): Likewise.
3576 (thumb_copy_pop_pc_16bit): Likewise.
3577 (thumb_process_displaced_16bit_insn): Likewise.
3578 (decode_thumb_32bit_ld_mem_hints): Likewise.
3579 (thumb_process_displaced_32bit_insn): Likewise.
3580 (thumb_process_displaced_insn): Likewise.
3581 (arm_process_displaced_insn): Likewise.
3582 (arm_displaced_init_closure): Likewise.
3583 (arm_displaced_step_fixup): Add cast for closure.
3584 * arm-tdep.h: Include infrun.h.
3585 (displaced_step_closure): Rename to ...
3586 (arm_displaced_step_closure): ... this, extend
3587 displaced_step_closure.
3588 <u::svc::copy_svc_os>: Change type of parameter DSC.
3589 <cleanup>: Likewise.
3590 (arm_process_displaced_insn): Likewise.
3591 (arm_displaced_init_closure): Likewise.
3592 (displaced_read_reg): Likewise.
3593 (displaced_write_reg): Likewise.
3594 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
3595 Adjust.
3596 * i386-tdep.h: Include infrun.h.
3597 (i386_displaced_step_closure): New typedef.
3598 * i386-tdep.c (i386_displaced_step_copy_insn): Use
3599 i386_displaced_step_closure.
3600 (i386_displaced_step_fixup): Adjust.
3601 * rs6000-tdep.c (ppc_displaced_step_closure): New typedef.
3602 (ppc_displaced_step_copy_insn): Use ppc_displaced_step_closure
3603 and unique_ptr.
3604 (ppc_displaced_step_fixup): Adjust.
3605 * s390-linux-tdep.c (s390_displaced_step_closure): New typedef.
3606 (s390_displaced_step_copy_insn): Use s390_displaced_step_closure
3607 and unique_ptr.
3608 (s390_displaced_step_fixup): Adjust.
3609
b392b304
SM
36102017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
3611
3612 * interps.h (interp_resume, interp_suspend, interp_set_temp):
3613 Remove declarations.
3614
d5833c62
TT
36152017-10-20 Tom Tromey <tom@tromey.com>
3616
3617 * gdb_bfd.c (struct gdb_bfd_data) <included_bfds>: Now a
3618 std::vector.
3619 (gdb_bfd_record_inclusion): Update.
3620 (bfdp): Remove typedef.
3621
06d5bbc8
TT
36222017-10-20 Tom Tromey <tom@tromey.com>
3623
3624 * gdb_bfd.c (gdb_bfd_ref): Use new.
3625 (struct gdb_bfd_data): Add constructor, destructor, and member
3626 initializers.
3627 (gdb_bfd_unref): Use delete.
3628
2712ce2e
TT
36292017-10-20 Tom Tromey <tom@tromey.com>
3630
3631 * exec.c (exec_file_attach): Use new_bfd_ref.
3632 * symfile-mem.c (symbol_file_add_from_memory): Use new_bfd_ref.
3633 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
3634 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_fdopenr): Use
3635 new_bfd_ref.
3636 * gdb_bfd.h (new_bfd_ref): New function.
3637
fcc8fb2f
PA
36382017-10-20 Pedro Alves <palves@redhat.com>
3639
3640 * main.c (captured_command_loop): Add attribute noinline.
3641
4c2287b0
SM
36422017-10-19 Simon Marchi <simon.marchi@ericsson.com>
3643
3644 * interps.c (struct interp_factory): Add constructor.
3645 (interp_factory_p): Remove typedef.
3646 (DEF_VEC_P(interp_factory_p)): Remove.
3647 (interpreter_factories): Change type to std::vector.
3648 (interp_factory_register): Adjust.
3649 (interp_lookup): Adjust.
3650 (interpreter_completer): Adjust.
3651
3d415c26
TT
36522017-10-19 Tom Tromey <tom@tromey.com>
3653
3654 * break-catch-syscall.c (catch_syscall_completer): Use
3655 std::string, gdb::unique_xmalloc_ptr.
3656
395423c4
TT
36572017-10-19 Tom Tromey <tom@tromey.com>
3658
3659 * infcall.c (call_function_by_hand_dummy): Use std::string.
3660
54f70bc1
TT
36612017-10-19 Tom Tromey <tom@tromey.com>
3662
3663 * mi/mi-main.c (mi_cmd_execute): Update.
3664 * top.h (prepare_execute_command): Return scoped_value_mark.
3665 * value.h (class scoped_value_mark): Use DISABLE_COPY_AND_ASSIGN.
3666 Add move constructor.
3667 * top.c (prepare_execute_command): Return scoped_value_mark.
3668 (execute_command): Update.
3669
63929e84
PA
36702017-10-19 Pedro Alves <palves@redhat.com>
3671
3672 * xml-support.c (xml_fetch_content_from_file): Check fread's
3673 return.
3674
a75868f5
PA
36752017-10-19 Pedro Alves <palves@redhat.com>
3676
3677 * ser-base.c (ser_base_read_error_fd): Delete the file handler if
3678 async.
3679 (handle_error_fd): New function.
3680 (ser_base_async): Add/delete an event loop file handler for
3681 error_fd.
3682
2edf834e
PA
36832017-10-19 Pedro Alves <palves@redhat.com>
3684
3685 * xml-support.c (xml_fetch_content_from_file): Don't read in
3686 chunks. Instead use fseek to determine the file's size, and read
3687 it in one go.
3688
c8ba13ad
KS
36892017-11-18 Keith Seitz <keiths@redhat.com>
3690
3691 * c-exp.y (oper): Canonicalize conversion operators of user-defined
3692 types.
3693 Add whitespace to front of type name.
3694
37534686
KS
36952017-10-18 Keith Seitz <keiths@redhat.com>
3696
3697 * dwarf2read.c (dwarf2_add_typedef): Issue a complaint on unhandled
3698 DW_AT_accessibility.
3699
28c7c158
YQ
37002017-10-18 Yao Qi <yao.qi@linaro.org>
3701
3702 * features/tic6x-c62x-linux.c: Remove.
3703
30f0b101
TT
37042017-10-17 Tom Tromey <tom@tromey.com>
3705
3706 * disasm.c (do_mixed_source_and_assembly_deprecated): Use
3707 gdb::optional, ui_out_emit_list, ui_out_emit_tuple.
3708 (do_mixed_source_and_assembly): Likewise.
3709
57e12da9
TT
37102017-10-17 Tom Tromey <tom@tromey.com>
3711
3712 * regcache.c (regcache::xfer_part): Remove assertion.
3713
7b700999
PA
37142017-10-17 Pedro Alves <palves@redhat.com>
3715
3716 * xml-support.c (xml_fetch_content_from_file): Call
3717 unique_ptr::release() instead unique_ptr::get() when passing
3718 through xrealloc.
3719
d3037ba6
YQ
37202017-10-17 Yao Qi <yao.qi@linaro.org>
3721
3722 * regcache.c (regcache::xfer_part): Remove parameters read and
3723 write, add parameter is_raw. All callers are updated.
3724
83d5a34d
KS
37252017-10-16 Keith Seitz <keiths@redhat.com>
3726
3727 * c-typeprint.c (enum access_specifier): Moved here from
3728 c_type_print_base.
3729 (output_access_specifier): New function.
3730 (c_type_print_base): Consider typedefs when assessing
3731 whether access labels are needed.
3732 Use output_access_specifier as needed.
3733 Output access specifier for typedefs, if needed.
3734 * dwarf2read.c (dwarf2_add_typedef): Record DW_AT_accessibility.
3735 * gdbtypes.h (struct typedef_field) <is_protected, is_private>: New
3736 fields.
3737 (TYPE_TYPEDEF_FIELD_PROTECTED, TYPE_TYPEDEF_FIELD_PRIVATE): New
3738 accessor macros.
3739
87028b87
TT
37402017-10-16 Tom Tromey <tom@tromey.com>
3741
3742 * linux-tdep.c (linux_info_proc, linux_find_memory_regions_full)
3743 (linux_fill_prpsinfo, linux_vsyscall_range_raw): Update.
3744 * target.c (target_fileio_read_stralloc): Update.
3745 * sparc64-tdep.c (adi_is_addr_mapped): Update.
3746 * target.h (target_fileio_read_stralloc): Return
3747 unique_xmalloc_ptr.
3748
b7b030ad
TT
37492017-10-16 Tom Tromey <tom@tromey.com>
3750
3751 * xml-syscall.c (xml_init_syscalls_info): Update.
3752 * xml-support.c (xinclude_start_include): Update.
3753 (xml_fetch_content_from_file): Return unique_xmalloc_ptr.
3754 * xml-support.h (xml_fetch_another): Return unique_xmalloc_ptr.
3755 (xml_fetch_content_from_file): Likewise.
3756 * osdata.c (get_osdata): Update.
3757 * target.h (target_read_stralloc, target_get_osdata): Return
3758 unique_xmalloc_ptr.
3759 * solib-aix.c (solib_aix_get_library_list): Update.
3760 * solib-target.c (solib_target_current_sos): Update.
3761 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Update.
3762 * xml-tdesc.c (fetch_available_features_from_target): Update.
3763 (target_fetch_description_xml): Update.
3764 (file_read_description_xml): Update.
3765 * remote.c (remote_get_threads_with_qxfer, remote_memory_map)
3766 (remote_traceframe_info, btrace_read_config, remote_read_btrace)
3767 (remote_pid_to_exec_file): Update.
3768 * target.c (target_read_stralloc): Return unique_xmalloc_ptr.
3769 (target_get_osdata): Likewise.
3770
b80406ac
TT
37712017-10-16 Tom Tromey <tom@tromey.com>
3772
3773 * remote.c (remote_register_number_and_offset): Use std::vector.
3774 (remote_set_syscall_catchpoint): Use gdb::unique_xmalloc_ptr.
3775 (putpkt_binary): Use gdb::def_vector.
3776 (compare_sections_command): Use gdb::byte_vector.
3777
a90ecff8
TT
37782017-10-16 Tom Tromey <tom@tromey.com>
3779
3780 * ppc-linux-nat.c (hwdebug_insert_point): Use
3781 gdb::unique_xmalloc_ptr, XDUP.
3782
2dc0e219
TT
37832017-10-16 Tom Tromey <tom@tromey.com>
3784
3785 * probe.c (parse_probes): Use std::string.
3786 (info_probes_for_ops, enable_probes_command)
3787 (disable_probes_command): Remove cleanups.
3788
b05628f0
TT
37892017-10-16 Tom Tromey <tom@tromey.com>
3790
3791 * buildsym.c (block_compar): Remove.
3792 (end_symtab_get_static_block): Use std::vector.
3793
a79b1bc6
SM
37942017-10-16 Simon Marchi <simon.marchi@ericsson.com>
3795
3796 * memrange.h (struct mem_range): Define operator< and operator==.
3797 (mem_range_s): Remove.
3798 (DEF_VEC_O (mem_range_s)): Remove.
3799 (normalize_mem_ranges): Change parameter type to std::vector.
3800 * memrange.c (compare_mem_ranges): Remove.
3801 (normalize_mem_ranges): Change parameter type to std::vector,
3802 adjust to vector change.
3803 * exec.c (section_table_available_memory): Return vector, remove
3804 parameter.
3805 (section_table_read_available_memory): Adjust to std::vector
3806 change.
3807 * remote.c (remote_read_bytes): Adjust to std::vector
3808 change.
3809 * tracepoint.h (traceframe_available_memory): Change parameter
3810 type to std::vector.
3811 * tracepoint.c (traceframe_available_memory): Change parameter
3812 type to std::vector, adjust.
3813 * gdb/mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to
3814 std::vector change.
3815 * gdb/Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3816 unittests/memrange-selftests.c.
3817 (SUBDIR_UNITTESTS_OBS): Add memrange-selftests.o.
3818 * gdb/unittests/memrange-selftests.c: New file.
3819
63f0e930
PA
38202017-10-16 Pedro Alves <palves@redhat.com>
3821
3822 * elfread.c (probe_key_free): Rename range-for variable.
3823 * probe.c (parse_probes_in_pspace, find_probes_in_objfile)
3824 (find_probe_by_pc, collect_probes): Rename range-for variable.
3825
c40c7bfc
YQ
38262017-10-16 Yao Qi <yao.qi@linaro.org>
3827
3828 * features/Makefile (XMLTOC): Remove tic6x-*.xml.
3829 * features/tic6x-c62x.c: Remove.
3830 * features/tic6x-c64x-linux.c: Remove.
3831 * features/tic6x-c64x.c: Remove.
3832 * features/tic6x-c64xp-linux.c: Remove.
3833 * features/tic6x-c64xp.c: Remove.
3834 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Don't call
3835 initialize_tdesc_tic6x_*_linux functions.
3836 * tic6x-tdep.c (_initialize_tic6x_tdep): Don't call
3837 initialize_tdesc_tic6x_* functions.
3838
df27ae6a
YQ
38392017-10-16 Yao Qi <yao.qi@linaro.org>
3840
3841 * features/Makefile (WHICH): Remove tic6x-c64xp, tic6x-c64x
3842 tic6x-c62x.
3843 * regformats/tic6x-c62x.dat: Remove.
3844 * regformats/tic6x-c64x.dat: Remove.
3845 * regformats/tic6x-c64xp.dat: Remove.
3846
86766165
SM
38472017-10-15 Simon Marchi <simon.marchi@ericsson.com>
3848
3849 * tracepoint.c (parse_traceframe_info): Return a unique_ptr
3850 (the !HAVE_LIBEXPAT version).
3851
824dfcc3
SM
38522017-10-14 Simon Marchi <simon.marchi@ericsson.com>
3853
3854 * nat/linux-osdata.c (struct pid_pgid_entry) <operator<>: Make
3855 const.
3856
2098b393
SM
38572017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3858
3859 * target.h: Include tracepoint.h.
3860 (enum trace_find_type): Move to tracepoint.h.
3861 (struct target_ops) <to_traceframe_info>: Return a unique ptr.
3862 * tracepoint.h: Don't include target.h
3863 (enum trace_find_type): Move from target.h.
3864 (parse_traceframe_info): Return a unique ptr.
3865 * tracepoint.c (current_traceframe_info): Change type to unique
3866 ptr.
3867 (free_traceframe_info): Remove.
3868 (clear_traceframe_info): Don't manually free
3869 current_traceframe_info.
3870 (free_result): Remove.
3871 (parse_traceframe_info): Return a unique ptr.
3872 (get_traceframe_info): Adjust to unique ptr.
3873 * ctf.c (ctf_traceframe_info): Return a unique ptr.
3874 * remote.c (remote_traceframe_info): Return a unique ptr.
3875 * tracefile-tfile.c (tfile_traceframe_info): Return a unique
3876 ptr.
3877 * target-debug.h (target_debug_print_traceframe_info_up): New
3878 macro.
3879 * target-delegates.c: Regenerate.
3880
4cdd21a8
SM
38812017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3882
3883 * memrange.h (struct mem_range): Add constructors.
3884 * tracepoint.h (struct traceframe_info) <memory>: Change type to
3885 std::vector<mem_range>.
3886 * tracepoint.c (free_traceframe_info): Don't manually free
3887 vector.
3888 (traceframe_info_start_memory): Adjust to vector change.
3889 (traceframe_available_memory): Likewise.
3890 * tracefile-tfile.c (build_traceframe_info): Likewise.
3891 * ctf.c (ctf_traceframe_info): Likewise.
3892
d0d292a2
SM
38932017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3894
3895 * tracepoint.h (struct traceframe_info) <tvars>: Change type to
3896 std::vector<int>.
3897 * tracepoint.c (free_traceframe_info): Deallocate with delete.
3898 (traceframe_info_start_tvar): Adjust to vector change.
3899 (parse_traceframe_info): Allocate with new.
3900 * ctf.c (ctf_traceframe_info): Allocate with new, adjust to
3901 vector change.
3902 * tracefile-tfile.c (build_traceframe_info): Adjust to vector
3903 change.
3904 tfile_traceframe_info): Allocate with new.
3905 * mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to vector
3906 change.
3907
8d3c73ef
SM
39082017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3909
3910 * tracepoint.c (traceframe_info): Rename to...
3911 (current_traceframe_info): ...this.
3912 (clear_traceframe_info): Adjust.
3913 (get_traceframe_info): Adjust.
3914
b129dcac
SM
39152017-10-14 Simon Marchi <simon.marchi@ericsson.com>
3916
3917 * nat/linux-osdata.c: Include algorithm.
3918 (compare_processes): Remove.
3919 (struct pid_pgid_entry): New struct.
3920 (linux_xfer_osdata_processgroups): Use std::vector instead of
3921 XNEWVEC.
3922
af5bf4ad
SM
39232017-10-14 Simon Marchi <simon.marchi@ericsson.com>
3924
3925 * objfiles.h: Don't include symfile.h.
3926 (struct partial_symbol): Remove forward-declaration.
3927 (struct objfile) <global_psymbols, static_psymbols>: Change type
3928 to std::vector<partial_symbol *>.
3929 * objfiles.c (objfile::objfile): Don't memset those fields.
3930 (objfile::~objfile): Don't free those fields.
3931 * psympriv.h (struct psymbol_allocation_list): Remove
3932 forward-declaration.
3933 (add_psymbol_to_list): Change psymbol_allocation_list parameter
3934 to std::vector.
3935 (start_psymtab_common): Change parameters to std::vector.
3936 * psymtab.c: Include algorithm.
3937 (require_partial_symbols): Call shrink_to_fit.
3938 (find_pc_sect_psymbol): Adjust to vector change.
3939 (match_partial_symbol): Likewise.
3940 (lookup_partial_symbol): Likewise.
3941 (psym_relocate): Likewise.
3942 (dump_psymtab): Likewise.
3943 (recursively_search_psymtabs): Likewise.
3944 (compare_psymbols): Remove.
3945 (sort_pst_symbols): Adjust to vector change.
3946 (start_psymtab_common): Likewise.
3947 (end_psymtab_common): Likewise.
3948 (psymbol_bcache_full): De-constify return value.
3949 (add_psymbol_to_bcache): Likewise.
3950 (extend_psymbol_list): Remove.
3951 (append_psymbol_to_list): Adjust to vector change.
3952 (add_psymbol_to_list): Likewise.
3953 (init_psymbol_list): Likewise.
3954 (maintenance_info_psymtabs): Likewise.
3955 (maintenance_check_psymtabs): Likewise.
3956 * symfile.h (struct psymbol_allocation_list): Remove.
3957 * symfile.c (reread_symbols): Adjust to vector change.
3958 * dbxread.c (start_psymtab): Change type of parameters.
3959 (dbx_symfile_read): Adjust to vector change.
3960 (read_dbx_symtab): Likewise.
3961 (start_psymtab): Change type of parameters.
3962 * dwarf2read.c (dwarf2_build_psymtabs): Adjust to vector change.
3963 (create_partial_symtab): Likewise.
3964 (add_partial_symbol): Likewise.
3965 (write_one_signatured_type): Likewise.
3966 (recursively_write_psymbols): Likewise.
3967 * mdebugread.c (parse_partial_symbols): Likewise.
3968 * xcoffread.c (xcoff_start_psymtab): Change type of parameters.
3969 (scan_xcoff_symtab): Adjust to vector change.
3970 (xcoff_initial_scan): Likewise.
3971
3ec5942f
SM
39722017-10-13 Simon Marchi <simon.marchi@ericsson.com>
3973
3974 * ada-typeprint.c (print_dynamic_range_bound): Use std::string.
3975
2399fe6a
YQ
39762017-10-13 Yao Qi <yao.qi@linaro.org>
3977
3978 * features/Makefile: Remove tic6x-*-expedite, add tic6x-expedite.
3979 Remove s390x-*-expedite, add s390x-expedite.
3980
4bf3f4a8
YQ
39812017-10-13 Yao Qi <yao.qi@linaro.org>
3982
3983 * features/s390-gs-linux64.c: Regenerated.
3984 * features/s390x-gs-linux64.c: Regenerated.
3985
9e86da07
TT
39862017-10-13 Tom Tromey <tom@tromey.com>
3987
3988 * compile/compile-object-run.c (do_module_cleanup): Use delete.
3989 * solib.c (update_solib_list, reload_shared_libraries_1): Use
3990 delete.
3991 * symfile.c (symbol_file_add_with_addrs): Use new.
3992 (symbol_file_add_separate): Update comment.
3993 (syms_from_objfile_1, remove_symbol_file_command): Use delete.
3994 * jit.c (jit_object_close_impl): Use new.
3995 (jit_unregister_code): Use delete.
3996 * objfiles.c (objfile::objfile): Rename from allocate_objfile.
3997 (~objfile): Rename from free_objfile.
3998 (free_objfile_separate_debug, do_free_objfile_cleanup)
3999 (free_all_objfiles, objfile_purge_solibs): Use delete.
4000 * objfiles.h (struct objfile): Add constructor and destructor.
4001 Use DISABLE_COPY_AND_ASSIGN. Add initializers to data members.
4002 (allocate_objfile, free_objfile): Don't declare.
4003 (struct objstats): Add initializers.
4004
c2508e90
SM
40052017-10-12 Simon Marchi <simon.marchi@ericsson.com>
4006
4007 * arch-utils.h (simple_displaced_step_copy_insn): Remove.
4008 * arch-utils.c (simple_displaced_step_copy_insn): Remove.
4009 * gdbarch.sh (displaced_step_copy_insn): Adjust comment.
4010 * gdbarch.h: Regenerate.
4011 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
4012 Adjust comment.
4013 * i386-tdep.c (i386_displaced_step_copy_insn): Adjust comment.
4014 (i386_displaced_step_fixup): Adjust comment.
4015 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Adjust comment.
4016
a900ff72
TT
40172017-10-12 Tom Tromey <tom@tromey.com>
4018
4019 * prologue-value.h (pv_area::store_would_trash): Return bool.
4020 (pv_area::find_reg): Likewise.
4021 * prologue-value.c (pv_area::store_would_trash): Return bool.
4022 (pv_area::find_reg): Likewise.
4023
f7b7ed97
TT
40242017-10-12 Tom Tromey <tom@tromey.com>
4025
4026 * s390-linux-tdep.c (s390_store, s390_load)
4027 (s390_check_for_saved, s390_analyze_prologue): Update.
4028 * rx-tdep.c (check_for_saved, rx_analyze_prologue): Update.
4029 * rl78-tdep.c (rl78_analyze_prologue, check_for_saved): Update.
4030 * prologue-value.h (class pv_area): Move from prologue-value.c.
4031 Change names of members. Add constructor, destructor, member
4032 functions.
4033 (make_pv_area, free_pv_area, make_cleanup_free_pv_area)
4034 (pv_area_store, pv_area_fetch, pv_area_store_would_trash)
4035 (pv_area_fetch, pv_area_scan): Don't declare.
4036 * prologue-value.c (struct pv_area::area_entry): Now member of
4037 pv_area.
4038 (struct pv_area): Move to prologue-value.h.
4039 (pv_area::pv_area): Rename from make_pv_area.
4040 (pv_area::~pv_area): Rename from free_pv_area.
4041 (do_free_pv_area_cleanup, make_cleanup_free_pv_area): Remove.
4042 (clear_entries, find_entry, overlaps, store_would_trash, store)
4043 (fetch, find_reg, scan): Now member of pv_area.
4044 Remove "area" argument. Update.
4045 * msp430-tdep.c (check_for_saved, msp430_analyze_prologue):
4046 Update.
4047 * mn10300-tdep.c (push_reg, check_for_saved)
4048 (mn10300_analyze_prologue): Update.
4049 * mep-tdep.c (is_arg_spill, check_for_saved)
4050 (mep_analyze_prologue): Update.
4051 * m32c-tdep.c (m32c_pv_push, m32c_srcdest_fetch)
4052 (m32c_srcdest_store, m32c_pv_enter, m32c_is_arg_spill)
4053 (m32c_is_struct_return, m32c_analyze_prologue): Update.
4054 * arm-tdep.c (thumb_analyze_prologue, arm_analyze_prologue):
4055 Update.
4056 * arc-tdep.c (arc_is_in_prologue, arc_analyze_prologue): Update.
4057 * aarch64-tdep.c (aarch64_analyze_prologue): Update.
4058
466eecee
SM
40592017-10-12 Simon Marchi <simon.marchi@ericsson.com>
4060
4061 * linux-nat.h (linux_nat_set_delete_thread): New declaration.
4062 * linux-nat.c (linux_nat_delete_thread): New variable.
4063 (lwp_free): Invoke linux_nat_delete_thread if set.
4064 (linux_nat_set_delete_thread): New function.
4065 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Assign
4066 thread delete callback.
4067 * arm-linux-nat.c (arm_linux_delete_thread): New function.
4068 (_initialize_arm_linux_nat): Assign thread delete callback.
4069 * s390-linux-nat.c (s390_delete_thread): New function.
4070 (_initialize_s390_nat): Assign thread delete callback.
4071 * x86-linux-nat.c (x86_linux_add_target): Likewise.
4072 * nat/aarch64-linux.c (aarch64_linux_delete_thread): New
4073 function.
4074 * nat/aarch64-linux.h (aarch64_linux_delete_thread): New
4075 declaration.
4076 * nat/x86-linux.c (x86_linux_delete_thread): New function.
4077 * nat/x86-linux.h (x86_linux_delete_thread): New declaration.
4078
f71c8822
TT
40792017-10-09 Tom Tromey <tom@tromey.com>
4080
4081 * tui/tui-win.c (tui_set_win_height, parse_scrolling_args): Use
4082 std::string.
4083 * tui/tui-layout.c (enum tui_status): Use std::string.
4084
981a3fb3
TT
40852017-10-11 Tom Tromey <tom@tromey.com>
4086
4087 * gdbthread.h (thread_command): Constify.
4088 * inferior.h (detach_command): Constify.
4089 * top.h (set_history, show_history): Constify.
4090 * arm-tdep.c (set_arm_command, show_arm_command): Constify.
4091 * serial.c (serial_set_cmd, serial_show_cmd): Constify.
4092 * bsd-kvm.c (bsd_kvm_cmd): Constify.
4093 * printcmd.c (set_command): Constify.
4094 (non_const_set_command): New function.
4095 * dcache.c (set_dcache_command, show_dcache_command): Constify.
4096 * breakpoint.c (enable_command, disable_command, delete_command)
4097 (catch_command, tcatch_command, set_breakpoint_cmd)
4098 (show_breakpoint_cmd): Constify.
4099 * macrocmd.c (macro_command): Constify.
4100 * infcmd.c (unset_command, kill_command, detach_command)
4101 (info_proc_cmd): Constify.
4102 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Constify.
4103 * auto-load.c (show_auto_load_cmd, set_auto_load_cmd)
4104 (info_auto_load_cmd): Constify.
4105 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
4106 (unset_tdesc_cmd): Constify.
4107 * ada-lang.c (set_ada_command, show_ada_command)
4108 (maint_set_ada_cmd, maint_show_ada_cmd): Constify.
4109 * guile/guile.c (set_guile_command, show_guile_command)
4110 (info_guile_command): Constify.
4111 * tui/tui-win.c (tui_command, set_tui_cmd, show_tui_cmd):
4112 Constify.
4113 * skip.c (skip_command): Constify.
4114 * compile/compile.c (_initialize_compile): Constify.
4115 * dwarf2read.c (set_dwarf_cmd, show_dwarf_cmd): Constify.
4116 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
4117 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
4118 (maint_btrace_pt_show_cmd): Constify.
4119 * remote.c (set_remote_cmd, show_remote_cmd, remote_command):
4120 Constify.
4121 * python/python.c (user_show_python, user_set_python): Constify.
4122 * mips-tdep.c (set_mips_command, show_mips_command)
4123 (set_mipsfpu_command): Constify.
4124 * record-btrace.c (cmd_record_btrace_start)
4125 (cmd_set_record_btrace, cmd_show_record_btrace)
4126 (cmd_set_record_btrace_bts, cmd_show_record_btrace_bts)
4127 (cmd_set_record_btrace_pt, cmd_show_record_btrace_pt): Constify.
4128 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command):
4129 Constify.
4130 * symfile.c (overlay_command): Constify.
4131 * spu-tdep.c (set_spu_command, show_spu_command): Constify.
4132 * cli/cli-logging.c (set_logging_command, show_logging_command):
4133 Constify.
4134 * cli/cli-dump.c (dump_command, append_command)
4135 (srec_dump_command, ihex_dump_command, verilog_dump_command)
4136 (tekhex_dump_command, binary_dump_command)
4137 (binary_append_command): Constify.
4138 * cli/cli-decode.c (struct cmd_list_element): Change type of
4139 "fun".
4140 * cli/cli-cmds.c (info_command, show_command, set_debug)
4141 (show_debug): Constify.
4142 (show_command): Add non-const overload.
4143 * top.c (set_history, show_history): Constify.
4144 * sh-tdep.c (set_sh_command, show_sh_command): Constify.
4145 * command.h (add_prefix_cmd): Accept a cmd_const_cfunc_ftype.
4146 * target.c (target_command): Constify.
4147 * sparc64-tdep.c (info_adi_command): Constify.
4148 * record-full.c (cmd_record_full_start): Constify.
4149 (set_record_full_command): Constify. Fix typo.
4150 (show_record_full_command): Constify.
4151 * thread.c (thread_command, thread_apply_command): Constify.
4152 * memattr.c (dummy_cmd): Constify.
4153 * value.c (function_command): Constify.
4154 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Constify.
4155 * probe.c (info_probes_command): Constify.
4156 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Constify.
4157 * gnu-nat.c (set_task_cmd, show_task_cmd, set_thread_cmd)
4158 (show_thread_cmd, set_thread_default_cmd)
4159 (show_thread_default_cmd): Constify.
4160 (check_empty): Constify.
4161 * tracepoint.c (tfind_command): Constify.
4162 * cp-support.c (maint_cplus_command): Constify.
4163 * windows-tdep.c (info_w32_command): Constify.
4164 * record.c (cmd_record_start, set_record_command)
4165 (show_record_command, info_record_command, cmd_record_goto):
4166 Constify.
4167 * ravenscar-thread.c (set_ravenscar_command)
4168 (show_ravenscar_command): Constify.
4169 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
4170 Constify.
4171 (add_internal_problem_command): Remove casts.
4172 * arc-tdep.c (maintenance_print_arc_command): Constify.
4173 * valprint.c (set_print, show_print, set_print_raw)
4174 (show_print_raw): Constify.
4175 * maint.c (maintenance_command, maintenance_info_command)
4176 (maintenance_print_command, maintenance_set_cmd)
4177 (maintenance_show_cmd, set_per_command_cmd)
4178 (show_per_command_cmd, maintenance_check_command): Constify.
4179 * language.c (set_check, show_check): Constify.
4180 * typeprint.c (show_print_type, set_print_type): Constify.
4181 * go32-nat.c (go32_info_dos_command): Constify.
4182
fdf44873
TT
41832017-10-11 Tom Tromey <tom@tromey.com>
4184
4185 * breakpoint.c (prepare_re_set_context): Remove.
4186 (breakpoint_re_set_one): Update. Don't use cleanups.
4187 (breakpoint_re_set): Use scoped_restore, std::string, and
4188 scoped_restore_current_language.
4189
81b1e71c
TT
41902017-10-11 Tom Tromey <tom@tromey.com>
4191
4192 * breakpoint.c (commands_command_1): Use std::string.
4193 (cleanup_executing_breakpoints): Remove.
4194 (bpstat_do_actions_1): Use scoped_restore.
4195 (bpstat_check_watchpoint): Use std::string.
4196 (decode_static_tracepoint_spec): Likewise.
4197 (break_range_command): Likewise.
4198 (watch_command_1): Likewise.
4199 (compare_breakpoints): Change argument types.
4200 (clear_command): Use std::vector.
4201 (cleanup_executing_breakpoints): Remove.
4202 (update_global_location_list): Use unique_xmalloc_ptr.
4203 (strace_command): Remove unused declaration.
4204
4f9d9906
JB
42052017-10-11 John Baldwin <jhb@FreeBSD.org>
4206
4207 * Makefile.in (ALLDEPFILES): Add arm-fbsd-nat.c.
4208 * NEWS: Mention new FreeBSD/arm native configuration.
4209 * configure.host: Add arm*-*-freebsd*.
4210 * configure.nat: Likewise.
4211 * arm-fbsd-nat.c: New file.
4212
7176dfd2
JB
42132017-10-11 John Baldwin <jhb@FreeBSD.org>
4214
4215 * Makefile.in (ALL_TARGET_OBS): Add arm-fbsd-tdep.o.
4216 (ALLDEPFILES): Add arm-fbsd-tdep.c.
4217 * NEWS: Mention new FreeBSD/arm target.
4218 * configure.tgt: Add arm*-*-freebsd*.
4219 * arm-fbsd-tdep.c: New file.
4220 * arm-fbsd-tdep.h: New file.
4221
fe220226
MR
42222017-10-11 Maciej W. Rozycki <macro@imgtec.com>
4223
4224 * linux-tdep.c (linux_make_corefile_notes): Remove call to
4225 `gdbarch_elfcore_write_linux_prpsinfo'.
4226 * gdbarch.sh (elfcore_write_linux_prpsinfo): Remove architecture
4227 method.
4228 (elf_internal_linux_prpsinfo): Remove declaration.
4229 * gdbarch.h: Regenerate.
4230 * gdbarch.c: Regenerate.
4231
a2f63b2e
MR
42322017-10-11 Maciej W. Rozycki <macro@imgtec.com>
4233
4234 * ppc-linux-tdep.c (ppc_linux_init_abi): Remove call to
4235 `set_gdbarch_elfcore_write_linux_prpsinfo'.
4236
458ca1d0
PA
42372017-10-11 Pedro Alves <palves@redhat.com>
4238
4239 * breakpoint.c (reattach_breakpoints): Delete.
4240 * breakpoint.h (reattach_breakpoints): Delete.
4241
905014d7
SM
42422017-10-11 Simon Marchi <simon.marchi@ericsson.com>
4243
4244 * symfile.c (registered_sym_fns): Make struct, not typedef.
4245 (DEF_VEC_O (registered_sym_fns)): Remove.
4246 (symtab_fns): Change type to std::vector.
4247 (add_symtab_fns): Adjust.
4248 (find_sym_fns): Adjust.
4249
56d704da
AK
42502017-10-11 Anton Kolesov <Anton.Kolesov@synopsys.com>
4251
4252 * arc-tdep.c (arc_gdbarch_init): Pass proper cpu value to disassembler.
4253 * arc-tdep.h (arc_arch_is_em): New function.
4254 (arc_arch_is_hs): Likewise.
4255
7fa29be9
EB
42562017-10-11 Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
4257
4258 * macrotab.h (macro_lookup_inclusion): Remove unnecessary
4259 parentheses in the declaration.
4260 (macro_lookup_inclusion): Likewise.
4261 (macro_lookup_definition): Likewise.
4262 * p-lang.h (pascal_builtin_types): Likewise.
4263 * tui/tui-data.c (tui_win_list): Likewise.
4264 * tui/tui-data.h (tui_win_list): Likewise.
4265 * utils.h (make_cleanup_free_section_addr_info): Likewise.
4266
d9b477e3
KB
42672017-10-11 Mark Rages <markrages@gmail.com>
4268
4269 * target-memory.c (block_boundaries): Fix for block address not
4270 aligned on block size.
4271
65630365
PA
42722017-10-10 Pedro Alves <palves@redhat.com>
4273 Tom Tromey <tom@tromey.com>
4274
4275 * breakpoint.c (struct captured_breakpoint_query_args)
4276 (do_captured_breakpoint_query, gdb_breakpoint_query): Delete.
4277 (print_breakpoint): New.
4278 * breakpoint.h (print_breakpoint): Declare.
4279 * common/common-exceptions.h (enum return_reason): Remove
4280 references to catch_exceptions.
4281 * exceptions.c (catch_exceptions, catch_exceptions_with_msg):
4282 Delete.
4283 * exceptions.h (catch_exceptions_ftype, catch_exceptions)
4284 (catch_exception_ftype, catch_exceptions_with_msg): Delete.
4285 * gdb.h: Delete.
4286 * gdbthread.h (thread_select): Declare.
4287 * mi/mi-cmd-break.c: Don't include gdb.h.
4288 (breakpoint_notify): Use print_breakpoint.
4289 * mi/mi-cmd-catch.c: Don't include gdb.h.
4290 * mi/mi-interp.c: Don't include gdb.h.
4291 (mi_print_breakpoint_for_event): New.
4292 (mi_breakpoint_created, mi_breakpoint_modified): Use
4293 mi_print_breakpoint_for_event.
4294 * mi/mi-main.c: Don't include gdb.h.
4295 (mi_cmd_thread_select): Parse the global thread ID here. Use
4296 thread_select instead of gdb_thread_select.
4297 (mi_cmd_thread_list_ids): Output "thread-ids" tuple here instead
4298 of using gdb_list_thread_ids.
4299 * remote-fileio.c (do_remote_fileio_request): Change type. Reply
4300 FILEIO_ENOSYS here.
4301 (remote_fileio_request): Use TRY/CATCH instead of
4302 catch_exceptions.
4303 * symfile-mem.c (struct symbol_file_add_from_memory_args)
4304 (symbol_file_add_from_memory_wrapper): Delete.
4305 (add_vsyscall_page): Use TRY/CATCH instead of catch_exceptions.
4306 * thread.c: Don't include gdb.h.
4307 (do_captured_list_thread_ids, gdb_list_thread_ids): Delete.
4308 (thread_alive): Use thread_select.
4309 (do_captured_thread_select): Delete, parts salvaged as ...
4310 (thread_select): ... this new function.
4311 (gdb_thread_select): Delete.
4312
bf469271
PA
43132017-10-10 Pedro Alves <palves@redhat.com>
4314 Tom Tromey <tom@tromey.com>
4315
4316 * breakpoint.c (breakpoint_cond_eval): Change return type to bool
4317 and reverse logic.
4318 (WP_DELETED, WP_VALUE_CHANGED, WP_VALUE_NOT_CHANGED, WP_IGNORE):
4319 No longer macros. Instead ...
4320 (enum wp_check_result): They're now values of this new
4321 enumeration.
4322 (watchpoint_check): Change return type to wp_check_result and
4323 parameter type to bpstat.
4324 (bpstat_check_watchpoint): Use TRY/CATCH instead of catch_errors.
4325 (bpstat_check_breakpoint_conditions): Use TRY/CATCH instead of
4326 catch_errors. Reverse logic of watchpoint_check call.
4327 (breakpoint_re_set_one): Now returns void and takes a breakpoint
4328 pointer as parameter.
4329 (breakpoint_re_set): Use TRY/CATCH instead of catch_errors.
4330 * common/common-exceptions.c (throw_exception_sjlj): Update
4331 comments to avoid mentioning catch_errors.
4332 * exceptions.c (catch_errors): Delete.
4333 * exceptions.h: Update comments to avoid mentioning catch_errors.
4334 (catch_errors_ftype, catch_errors): Delete.
4335 * infrun.c (normal_stop): Use TRY/CATCH instead of catch_errors.
4336 (hook_stop_stub): Delete.
4337 (restore_selected_frame): Change return type to void, and
4338 parameter type to const frame_id &.
4339 (restore_infcall_control_state): Use TRY/CATCH instead of
4340 catch_errors.
4341 * main.c (captured_command_loop): Return void and remove
4342 parameter. Remove references to catch_errors.
4343 (captured_main): Use TRY/CATCH instead of catch_errors.
4344 * objc-lang.c (objc_submethod_helper_data)
4345 (find_objc_msgcall_submethod_helper): Delete.
4346 (find_objc_msgcall_submethod): Use TRY/CATCH instead of
4347 catch_errors.
4348 * record-full.c (record_full_message): Return void.
4349 (record_full_message_args, record_full_message_wrapper): Delete.
4350 (record_full_message_wrapper_safe): Return bool and use TRY/CATCH
4351 instead of catch_errors.
4352 * solib-aix.c (solib_aix_open_symbol_file_object): Change
4353 parameter type to int.
4354 * solib-darwin.c (open_symbol_file_object): Ditto.
4355 * solib-dsbt.c (open_symbol_file_object): Ditto.
4356 * solib-frv.c (open_symbol_file_object): Ditto.
4357 * solib-svr4.c (open_symbol_file_object): Ditto.
4358 * solib-target.c (solib_target_open_symbol_file_object): Ditto.
4359 * solib.c (update_solib_list): Use TRY/CATCH instead of
4360 catch_errors.
4361 * solist.h (struct target_so_ops) <open_symbol_file_object>:
4362 Change type.
4363 * symmisc.c (struct print_symbol_args): Remove.
4364 (dump_symtab_1): Use TRY/CATCH instead of catch_errors.
4365 (print_symbol): Change type.
4366 * windows-nat.c (handle_load_dll, handle_unload_dll): Return void
4367 and remove parameters.
4368 (catch_errors): New.
4369 (get_windows_debug_event): Adjust.
4370
1a56bfa5
TT
43712017-10-09 Tom Tromey <tom@tromey.com>
4372
4373 * mi/mi-main.c (free_splay_tree): Remove.
4374 (list_available_thread_groups): Use splay_tree_up.
4375 * common/gdb_splay_tree.h: New file.
4376
0c478e2d
TT
43772017-10-09 Tom Tromey <tom@tromey.com>
4378
4379 * mi/mi-main.c (do_nothing): Remove.
4380 (list_available_thread_groups): Update.
4381
cbd2b4e3
PA
43822017-10-09 Pedro Alves <palves@redhat.com>
4383
4384 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>: Skip
4385 reading registers when switching context.
4386
a181c0bf
JB
43872017-10-09 John Baldwin <jhb@FreeBSD.org>
4388
4389 * fbsd-nat.c (fbsd_siginfo_size): Use gdbarch_long_bit.
4390 (fbsd_convert_siginfo): Likewise.
4391 * fbsd-tdep.c (fbsd_core_xfer_siginfo): Likewise.
4392
6e66f753
SM
43932017-10-09 Simon Marchi <simon.marchi@polymtl.ca>
4394
4395 * configure.ac (try_guile_versions): Remove guile-2.2.
4396 * configure: Regenerate.
4397
890e9790
TT
43982017-10-09 Tom Tromey <tom@tromey.com>
4399
4400 * Makefile.in (COMPILE.post, POSTCOMPILE): Restore $(basename).
4401 (COMPILE.pre): Use $(CXX).
4402
109483d9
PA
44032017-10-09 Pedro Alves <palves@redhat.com>
4404
4405 * cp-support.c (cp_remove_params): Return a gdb::unique_xmalloc_ptr.
4406 Use bool.
4407 (overload_list_add_symbol): Adjust to use gdb::unique_xmalloc_ptr.
4408 * cp-support.h (cp_remove_params): Now returns a
4409 gdb::unique_xmalloc_ptr.
4410 * dwarf2read.c (find_slot_in_mapped_hash): Now returns bool.
4411 Adjust to cp_remove_params returning a gdb::unique_xmalloc_ptr.
4412 * psymtab.c (psymtab_search_name): Adjust to cp_remove_params
4413 returning a gdb::unique_xmalloc_ptr.
4414 (lookup_partial_symbol): Adjust to use gdb::unique_xmalloc_ptr.
4415 * stack.c (find_frame_funname): Adjust to cp_remove_params
4416 returning a gdb::unique_xmalloc_ptr.
4417
791afaa2
TT
44182017-10-08 Tom Tromey <tom@tromey.com>
4419
4420 * dwarf2read.c (dwarf2_get_dwz_file): Use
4421 gdb::unique_xmalloc_ptr.
4422 (find_slot_in_mapped_hash): Likewise.
4423 (dwarf2_physname): Likewise.
4424 (create_dwo_unit_in_dwp_v1): Use std::string.
4425 (create_dwo_unit_in_dwp_v2): Likewise.
4426 (lookup_dwo_cutu): Likewise.
4427 (inherit_abstract_dies): Use std::vector.
4428 (read_array_type): Likewise.
4429 (dwarf_decode_macros): Remove unused declaration.
4430 (unsigned_int_compar): Remove.
4431 (dwarf2_build_psymtabs_hard): Use scoped_restore.
4432 (psymtabs_addrmap_cleanup): Remove.
4433
30a9c02f
TT
44342017-10-08 Tom Tromey <tom@tromey.com>
4435
4436 * frame-unwind.c (frame_unwind_try_unwinder): Update.
4437 * frame.h (frame_cleanup_after_sniffer): Declare.
4438 (frame_prepare_for_sniffer): Return void.
4439 * frame.c (frame_cleanup_after_sniffer): No longer static. Change
4440 type of argument.
4441 (frame_prepare_for_sniffer): Return void.
4442
757325a3
TT
44432017-10-08 Tom Tromey <tom@tromey.com>
4444
4445 * utils.h (make_cleanup_value_free): Remove.
4446 * utils.c (do_value_free, struct cleanup): Remove.
4447 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full) <DWARF_VALUE_STACK>:
4448 Use gdb_value_up.
4449 * value.h (struct value_deleter): New.
4450 (gdb_value_up): New typedef.
4451
b9c04fb2
TT
44522017-10-08 Tom Tromey <tom@tromey.com>
4453
4454 * symtab.c (free_search_symbols, do_free_search_symbols_cleanup)
4455 (make_cleanup_free_search_symbols): Remove.
4456 (search_symbols): Return std::vector.
4457 (symbol_search::compare_search_syms): Now member of
4458 symbol_search. Change arguments.
4459 (sort_search_symbols_remove_dups): Change arguments. Rewrite.
4460 (symtab_symbol_info, rbreak_command): Update.
4461 * symtab.h (struct symbol_search) <next>: Remove.
4462 Add constructors.
4463 (symbol_search::operator<): New function.
4464 (symbol_search::operator==): New function.
4465 (search_symbols): Remove std::vector.
4466 (free_search_symbols, make_cleanup_free_search_symbols): Remove.
4467 (symbol_search::compare_search_syms): Declare.
4468
0d28b0a5
YQ
44692017-10-06 Yao Qi <yao.qi@linaro.org>
4470
4471 * Makefile.in (ALL_64_TARGET_OBS): Replace aarch64-insn.o with
4472 arch/aarch64-insn.o.
4473 Remove one rule.
4474 * configure.tgt: Replace aarch64-insn.o with arch/aarch64-insn.o.
4475
71917808
YQ
44762017-10-06 Yao Qi <yao.qi@linaro.org>
4477
4478 * Makefile.in (ALL_TARGET_OBS): Replace arm.o, arm-get-next-pcs.o,
4479 and arm-linux.o with arch/arm.o, arch/arm-get-next-pcs.o and
4480 arch/arm-linux.o respectively.
4481 * configure.tgt: Likewise.
4482
2081b2b2
YQ
44832017-10-06 Yao Qi <yao.qi@linaro.org>
4484
4485 * Makefile.in (ALL_TARGET_OBS): Rename i386.o to arch/i386.o.
4486 * configure.tgt (i386_tobjs): Replace i386.o with arch/i386.o.
4487
a1b85d28
PA
44882017-10-06 Pedro Alves <palves@redhat.com>
4489
4490 * windows-nat.c: Include <algorithm>.
4491
d97987e2
YQ
44922017-10-06 Yao Qi <yao.qi@linaro.org>
4493
4494 * configure.tgt (i386_tobjs): New variable.
4495 (amd64_tobjs): New variable.
4496 Set $cpu_obs and $os_obs.
4497
f38307f5
YQ
44982017-10-06 Yao Qi <yao.qi@linaro.org>
4499
4500 * Makefile.in (CONFIG_SRC_SUBDIR): New.
4501 (ALL_64_TARGET_OBS): Replace amd64.o with arch/amd64.o.
4502 (clean): Remove object files and dependency files.
4503 (distclean): Remove the directory.
4504 * configure.ac: Invoke AC_CONFIG_COMMANDS.
4505 * configure: Re-generated.
4506 * configure.tgt: Replace amd64.o with arch/amd64.o.
4507
2f924de6
JM
45082017-10-05 Jose E. Marchesi <jose.marchesi@oracle.com>
4509
4510 PR build/22188
4511 * arm-tdep.c (arm_decode_misc_memhint_neon): Fix decoding of CPS
4512 and SETEND.
4513
2fd9d7ca
PA
45142017-10-05 Pedro Alves <palves@redhat.com>
4515
4516 * linux-nat.c (linux_child_follow_fork): When following the parent
4517 and detaching the child, consult the parent thread's architecture
4518 instead of the child's.
4519
d13b8493
UW
45202017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
4521
4522 * ax.h: Do not include "doublest.h".
4523 (union agent_val): Remove.
4524
3b4b2f16
UW
45252017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
4526
4527 * dfp.h (MAX_DECIMAL_STRING): Move to dfp.c.
4528 (decimal_to_string): Return std::string object.
4529 (decimal_from_string): Accept std::string object. Return bool.
4530 (decimal_from_integral, decimal_from_doublest): Remove.
4531 (decimal_from_longest): Add prototype.
4532 (decimal_from_ulongest): Likewise.
4533 (decimal_to_longest): Likewise.
4534 (decimal_from_doublest): Likewise.
4535 * dfp.c: Do not include "gdbtypes.h" or "value.h".
4536 (MAX_DECIMAL_STRING): Move here.
4537 (decimal_to_string): Return std::string object.
4538 (decimal_from_string): Accept std::string object. Return bool.
4539 (decimal_from_integral): Remove, replace by ...
4540 (decimal_from_longest, decimal_from_ulongest): ... these new functions.
4541 (decimal_to_longest): New function.
4542 (decimal_from_floating): Remove, replace by ...
4543 (decimal_from_doublest): ... this new function.
4544 (decimal_to_doublest): Update to new decimal_to_string interface.
4545
4546 * value.c (unpack_long): Use decimal_to_longest.
4547 * valops.c (value_cast): Use decimal_from_doublest instead of
4548 decimal_from_floating. Use decimal_from_[u]longest isntead of
4549 decimal_from_integral.
4550 * valarith.c (value_args_as_decimal): Likewise.
4551 * valprint.c (print_decimal_floating): Update to new
4552 decimal_to_string interface.
4553 * printcmd.c (printf_decfloat): Likewise.
4554 * c-exp.y (parse_number): Update to new decimal_from_string interface.
4555
1841ee5d
UW
45562017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
4557
4558 * doublest.h: Do not include "floatformat.h". Remove stale comments.
4559 * gdbtypes.c: Include "floatformat.h".
4560 * value.c: Likewise.
4561 * m68k-tdep.c: Likewise.
4562
4563 * findvar.c: Do not include "floatformat.h".
4564 * amd64-darwin-tdep.c: Likewise.
4565 * arm-linux-tdep.c: Likewise.
4566 * i386-darwin-tdep.c: Likewise.
4567 * i387-tdep.c: Likewise.
4568 * m68k-linux-tdep.c: Likewise.
4569 * mep-tdep.c: Likewise.
4570 * mips-tdep.c: Likewise.
4571 * nios2-tdep.c: Likewise.
4572 * s390-linux-tdep.c: Likewise.
4573 * sparc-obsd-tdep.c: Likewise.
4574 * sparc-tdep.c: Likewise.
4575 * sparc64-tdep.c: Likewise.
4576 * spu-tdep.c: Likewise.
4577 * tic6x-tdep.c: Likewise.
4578 * tilegx-tdep.c: Likewise.
4579 * vax-tdep.c: Likewise.
4580 * xstormy16-tdep.c: Likewise.
4581 * xtensa-tdep.c: Likewise.
4582
4583 * top.c: Do not include "doublest.h".
4584 * aarch64-tdep.c: Likewise.
4585 * alpha-tdep.c: Likewise.
4586 * arm-linux-tdep.c: Likewise.
4587 * m68k-linux-tdep.c: Likewise.
4588 * tilegx-tdep.c: Likewise.
4589 * xstormy16-tdep.c: Likewise.
4590
a80a6471
JB
45912017-10-05 John Baldwin <jhb@FreeBSD.org>
4592
4593 * mips-fbsd-tdep.c (MIPS_INST_ADDIU_A0_SP_N32): Define.
4594 (mipsn32_fbsd_sigframe): Define.
4595 (mips_fbsd_init_abi): Install mipsn32_fbsd_sigframe unwinder
4596 for FreeBSD/mipsn32.
4597
12c4bd7f
JB
45982017-10-05 John Baldwin <jhb@FreeBSD.org>
4599
4600 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_EHDRFLAGS and
4601 AT_HWCAP.
4602
c91933e9
TG
46032017-10-05 Tristan Gingold <tgingold@free.fr>
4604
4605 * MAINTAINERS (Misc): Update my email address.
4606
5cd63fda
PA
46072017-10-04 Pedro Alves <palves@redhat.com>
4608
4609 * remote.c (get_remote_arch_state): New 'gdbarch' parameter. Use
4610 it instead of target_gdbarch.
4611 (get_remote_state, get_remote_packet_size): Adjust
4612 get_remote_arch_state calls, passing down target_gdbarch
4613 explicitly.
4614 (packet_reg_from_regnum, packet_reg_from_pnum): New parameter
4615 'gdbarch' and use it instead of target_gdbarch.
4616 (get_memory_packet_size): Adjust get_remote_arch_state calls,
4617 passing down target_gdbarch explicitly.
4618 (struct stop_reply) <arch>: New field.
4619 (remote_parse_stop_reply): Use the stopped thread's architecture,
4620 not the current inferior's. Save the architecture in the
4621 stop_reply.
4622 (process_stop_reply): Use the stop reply's architecture.
4623 (process_g_packet, remote_fetch_registers)
4624 (remote_prepare_to_store, store_registers_using_G)
4625 (remote_store_registers): Adjust get_remote_arch_state calls,
4626 using the regcache's architecture.
4627 (remote_get_trace_status): Adjust get_remote_arch_state calls,
4628 passing down target_gdbarch explicitly.
4629 * spu-multiarch.c (spu_thread_architecture): Defer to the target
4630 beneath instead of calling target_gdbarch.
4631 * target.c (default_thread_architecture): Use the specified
4632 inferior's architecture, instead of the current inferior's
4633 architecture (via target_gdbarch).
4634
ed4227b7
PA
46352017-10-04 Pedro Alves <palves@redhat.com>
4636
4637 * regcache.c (get_thread_arch_regcache): Remove null_ptid special
4638 case.
4639 (regcache_print): Handle !target_has_registers here instead.
4640
55b11ddf
PA
46412017-10-04 Pedro Alves <palves@redhat.com>
4642
4643 * frame.c (create_test_frame): Delete.
4644 * frame.h (create_test_frame): Delete.
4645 * gdbarch-selftests.c: Include gdbthread.h and target.h.
4646 (class regcache_test): Delete.
4647 (test_target_has_registers, test_target_has_stack)
4648 (test_target_has_memory, test_target_prepare_to_store)
4649 (test_target_store_registers): New functions.
4650 (test_target_ops): New class.
4651 (register_to_value_test): Error out if there's already a
4652 process_stratum (or higher) target pushed. Create a fuller mock
4653 environment, with mock target_ops, inferior, address space, thread
4654 and inferior_ptid.
4655 * progspace.c (struct address_space): Move to ...
4656 * progspace.h (struct address_space): ... here.
4657 * regcache.h (regcache::~regcache, regcache::raw_write)
4658 [GDB_SELF_TEST]: No longer virtual.
4659
4c71c105
SM
46602017-10-04 Simon Marchi <simon.marchi@ericsson.com>
4661
4662 * mi/mi-main.c (list_available_thread_groups): Reverse filter logic.
4663
73dcd72d
PA
46642017-10-04 Pedro Alves <palves@redhat.com>
4665
4666 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Move code
4667 out of 'between TRY and CATCH'.
4668
44704526
PA
46692017-10-04 Pedro Alves <palves@redhat.com>
4670
4671 * cli/cli-cmds.c (complete_command): Add missing END_CATCH.
4672 * common/common-exceptions.h (TRY): Open an outermost scope.
4673 Expand intro comment.
4674 (CATCH): Reindent.
4675 (END_CATCH): Close the outermost scope.
4676 * completer.c (complete_line_internal): Add missing END_CATCH.
4677
bc3b087d
SDJ
46782017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
4679
4680 * NEWS (Changes since GDB 8.0): Add entry about new
4681 'set-cwd-on-gdbserver' feature.
4682 (New remote packets): Add entry for QSetWorkingDir.
4683 * common/common-inferior.h (set_inferior_cwd): New prototype.
4684 * infcmd.c (set_inferior_cwd): Remove "static".
4685 (show_cwd_command): Expand text to include remote debugging.
4686 * remote.c: Add PACKET_QSetWorkingDir.
4687 (remote_protocol_features) <QSetWorkingDir>: New entry for
4688 PACKET_QSetWorkingDir.
4689 (extended_remote_set_inferior_cwd): New function.
4690 (extended_remote_create_inferior): Call
4691 "extended_remote_set_inferior_cwd".
4692 (_initialize_remote): Call "add_packet_config_cmd" for
4693 QSetWorkingDir.
4694
d092c5a2
SDJ
46952017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
4696
4697 * NEWS (New commands): Mention "set/show cwd".
4698 * cli/cli-cmds.c (_initialize_cli_cmds): Mention "set cwd" on
4699 "cd" command's help text.
4700 * common/common-inferior.h (get_inferior_cwd): New prototype.
4701 * infcmd.c (inferior_cwd_scratch): New global variable.
4702 (set_inferior_cwd): New function.
4703 (get_inferior_cwd): Likewise.
4704 (set_cwd_command): Likewise.
4705 (show_cwd_command): Likewise.
4706 (_initialize_infcmd): Add "set/show cwd" commands.
4707 * inferior.h (class inferior) <cwd>: New field.
4708 * nat/fork-inferior.c: Include "gdb_tilde_expand.h".
4709 (fork_inferior): Change inferior's cwd before its execution.
4710 * windows-nat.c (windows_create_inferior): Pass inferior's cwd
4711 to CreateProcess.
4712
7da0a886
SDJ
47132017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
4714
4715 * Makefile.in (SFILES): Add gdb_tilde_expand.c.
4716 (HFILES_NO_SRCDIR): Add gdb_tilde_expand.h.
4717 (COMMON_OBS): Add gdb_tilde_expand.o.
4718 * common/gdb_tilde_expand.c: New file.
4719 * common/gdb_tilde_expand.h: Likewise.
4720
db8dd160
MR
47212017-10-03 Maciej W. Rozycki <macro@imgtec.com>
4722
4723 * gdbarch.sh (objfile): Remove duplicate declaration.
4724 * gdbarch.h: Regenerate.
4725
f8bfbf22
TT
47262017-10-03 Tom Tromey <tom@tromey.com>
4727
4728 * utils.c (internal_vproblem): Use string_vprintf.
4729
5178ed48
TT
47302017-10-03 Tom Tromey <tom@tromey.com>
4731
4732 * printcmd.c (info_symbol_command): Use std::string.
4733
8cff8730
TT
47342017-10-03 Tom Tromey <tom@tromey.com>
4735
4736 * top.c (gdb_safe_append_history): Use std::string.
4737
895b8f30
TT
47382017-10-03 Tom Tromey <tom@tromey.com>
4739
4740 * event-top.c (stdin_event_handler): Update.
4741 * main.c (captured_main_1): Update.
4742 * top.h (make_delete_ui_cleanup): Remove.
4743 (struct ui): Add constructor and destructor.
4744 (new_ui, delete_ui): Remove.
4745 * top.c (make_delete_ui_cleanup): Remove.
4746 (new_ui_command): Use std::unique_ptr.
4747 (delete_ui_cleanup): Remove.
4748 (ui::ui): Rename from new_ui. Update.
4749 (free_ui): Remove.
4750 (ui::~ui): Rename from delete_ui. Update.
4751
0efef640
TT
47522017-10-03 Tom Tromey <tom@tromey.com>
4753
4754 * symfile.c (load_progress): Use gdb::byte_vector.
4755
245ad7d3
TT
47562017-10-03 Tom Tromey <tom@tromey.com>
4757
4758 * mi/mi-main.c (mi_cmd_trace_frame_collected): Remove unused
4759 declaration.
4760 * printcmd.c (x_command): Remove unused declaration.
4761 * symfile.c (symbol_file_command): Remove unused declaration.
4762
e05550d7
TT
47632017-10-03 Tom Tromey <tom@tromey.com>
4764
4765 * utils.c (internal_vproblem): Use std::string.
4766 (defaulted_query): Likewise.
4767
b95de2b7
TT
47682017-10-03 Tom Tromey <tom@tromey.com>
4769
4770 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Update.
4771 * top.c (execute_command_to_string): Update.
4772 * utils.c (make_cleanup_restore_page_info): Remove.
4773 (do_restore_page_info_cleanup): Remove.
4774 (set_batch_flag_and_restore_page_info):
4775 New.
4776 (make_cleanup_restore_page_info): Remove.
4777 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
4778 (~set_batch_flag_and_restore_page_info): New
4779 (make_cleanup_restore_uinteger): Remove.
4780 (make_cleanup_restore_integer): Remove.
4781 (struct restore_integer_closure): Remove.
4782 (restore_integer): Remove.
4783 * utils.h (struct set_batch_flag_and_restore_page_info): New
4784 class.
4785 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
4786 (make_cleanup_restore_page_info): Remove.
4787 (make_cleanup_restore_uinteger) Remove.
4788 (make_cleanup_restore_integer) Remove.
4789
07036511
TT
47902017-10-03 Tom Tromey <tom@tromey.com>
4791
4792 * record-full.h (record_full_gdb_operation_disable_set): Return
4793 scoped_restore_tmpl<int>.
4794 * infrun.c (adjust_pc_after_break): Update.
4795 (handle_signal_stop): Update.
4796 * record-full.c (record_full_gdb_operation_disable_set): Return
4797 scoped_restore_tmpl<int>.
4798 (record_full_wait_1, record_full_insert_breakpoint)
4799 (record_full_remove_breakpoint, record_full_save)
4800 (record_full_goto_insn): Update.
4801
45320ffa
TT
48022017-10-02 Tom Tromey <tom@tromey.com>
4803
4804 PR rust/22236:
4805 * rust-lang.c (rust_val_print_str): New function.
4806 (val_print_struct): Call it.
4807 (rust_subscript): Preserve name of slice type.
4808
b3e3859b
TT
48092017-10-02 Tom Tromey <tom@tromey.com>
4810
4811 * rust-lang.c (rust_subscript): Handle slices in
4812 EVAL_AVOID_SIDE_EFFECTS case.
4813
01af5e0d
TT
48142017-10-02 Tom Tromey <tom@tromey.com>
4815
4816 * rust-lang.c (rust_slice_type_p): Recognize &str as a slice type.
4817
888e3ddb
TT
48182017-10-02 Tom Tromey <tom@tromey.com>
4819
4820 * rust-lang.h (rust_slice_type): Add "extern".
4821
cc536b21
PA
48222017-10-02 Tom Tromey <tom@tromey.com>
4823 Pedro Alves <palves@redhat.com>
4824
4825 * ada-lang.h (ada_exc_info::operator<): Make const.
4826 (ada_exc_info::operator==): Make const.
4827 * ada-lang.c (ada_exc_info::operator<, ada_exc_info::operator==):
4828 Make const.
4829
386c8614
TT
48302017-09-29 Tom Tromey <tom@tromey.com>
4831
4832 * target.c (read_whatever_is_readable): Change type of "result".
4833 Update.
4834 (free_memory_read_result_vector): Remove.
4835 (read_memory_robust): Change return type. Update.
4836 * mi/mi-main.c (mi_cmd_data_read_memory_bytes): Update. Use
4837 bin2hex, std::string.
4838 * target.h (memory_read_result_s): Remove typedef.
4839 (free_memory_read_result_vector): Remove.
4840 (read_memory_robust): Return std::vector.
4841
789c4b5e
TT
48422017-09-29 Tom Tromey <tom@tromey.com>
4843
4844 * mi/mi-main.c (captured_mi_execute_command): Use scope_restore.
4845
ab816a27
TT
48462017-09-29 Tom Tromey <tom@tromey.com>
4847
4848 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Update.
4849 * ada-lang.h (struct ada_exc_info): Remove typedef. Declare
4850 operator< and operator==.
4851 (ada_exceptions_list): Return a std::vector.
4852 * ada-lang.c (ada_exc_info::operator<): Rename from
4853 compare_ada_exception_info.
4854 (ada_exc_info::operator==): New.
4855 (sort_remove_dups_ada_exceptions_list): Change type of
4856 "exceptions".
4857 (ada_add_standard_exceptions, ada_add_exceptions_from_frame)
4858 (ada_add_global_exceptions): Likewise.
4859 (ada_exceptions_list_1): Return a std::vector.
4860 (ada_exceptions_list): Likewise.
4861
52f9abe4
TT
48622017-09-29 Tom Tromey <tom@tromey.com>
4863
4864 * mi/mi-main.c (struct print_one_inferior_data) <inferiors>: Now a
4865 'std::set *'.
4866 (print_one_inferior): Update.
4867 (free_vector_of_ints): Remove.
4868 (list_available_thread_groups): Change "ids" to std::set.
4869 (mi_cmd_list_thread_groups): Update.
4870 (struct collect_cores_data) <core>: Now a std::set.
4871 (collect_cores): Update.
4872 (unique): Remove.
4873 (print_one_inferior): Update.
4874
dcd5ddcc
TT
48752017-09-29 Tom Tromey <tom@tromey.com>
4876
4877 * mi/mi-main.c (mi_execute_cli_command): Use std::string.
4878 (mi_execute_async_cli_command): Likewise.
4879 (mi_cmd_trace_frame_collected): Use field_fmt.
4880
45d288cc
TT
48812017-09-29 Tom Tromey <tom@tromey.com>
4882
4883 * mi/mi-main.c (mi_cmd_data_write_memory_bytes): Use
4884 gdb::byte_vector.
4885
6afe2f4a
TT
48862017-09-29 Tom Tromey <tom@tromey.com>
4887
4888 * mi/mi-parse.c (mi_parse): Remove unused declaration.
4889
9813429a
TT
48902017-09-29 Tom Tromey <tom@tromey.com>
4891
4892 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Don't copy "oarg".
4893
2d6960b4
TT
48942017-09-29 Tom Tromey <tom@tromey.com>
4895
4896 * varobj.h (varobj_gen_name): Return std::string.
4897 * varobj.c (varobj_gen_name): Return std::string.
4898 * mi/mi-cmd-var.c (mi_cmd_var_create): Use std::string.
4899 (mi_cmd_var_delete): Don't copy "name".
4900
784c453a
TT
49012017-09-29 Tom Tromey <tom@tromey.com>
4902
4903 * mi/mi-cmd-break.c (mi_argv_to_format): Return std::string.
4904 (mi_cmd_break_insert_1): Update.
4905
a9bc57b9
TT
49062017-09-29 Tom Tromey <tom@tromey.com>
4907
4908 * target.h (make_scoped_defer_target_commit_resume): Update.
4909 * target.c (make_scoped_defer_target_commit_resume): Rename from
4910 make_cleanup_defer_target_commit_resume. Return a
4911 scoped_restore.
4912 * infrun.c (proceed): Use make_scoped_defer_target_commit_resume.
4913
9754d8c4
TT
49142017-09-29 Tom Tromey <tom@tromey.com>
4915
4916 * main.c (captured_main_1): Remove unused declaration.
4917 * spu-multiarch.c (parse_spufs_run): Remove unused declaration.
4918
99ef965c
TT
49192017-09-29 Tom Tromey <tom@tromey.com>
4920
4921 * symtab.c (search_symbols): Remove unused outer cleanup.
4922 (make_source_files_completion_list): Remove unused declaration.
4923
42518ba7
TT
49242017-09-29 Tom Tromey <tom@tromey.com>
4925
4926 * mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.
4927
726b2169
TT
49282017-09-29 Tom Tromey <tom@tromey.com>
4929
4930 * xstormy16-tdep.c (xstormy16_push_dummy_call): Use
4931 gdb::byte_vector.
4932
55b06432
TT
49332017-09-29 Tom Tromey <tom@tromey.com>
4934
4935 * complaints.c (vcomplaint): Use std::string.
4936
8abcee91
TT
49372017-09-29 Tom Tromey <tom@tromey.com>
4938
4939 * tracepoint.c (trace_variable_command): Use std::string.
4940 (encode_actions_1): Remove unused declarations.
4941 (create_tsv_from_upload): Use std::string.
4942
6ad94bc7
TT
49432017-09-29 Tom Tromey <tom@tromey.com>
4944
4945 * cp-support.c (gdb_demangle): Use std::string.
4946
2003f3d8
TT
49472017-09-29 Tom Tromey <tom@tromey.com>
4948
4949 * stack.c (parse_frame_specification): Use std::string
4950 (info_frame_command): Use gdb::unique_xmalloc_ptr.
4951
8f8accb5
TT
49522017-09-29 Tom Tromey <tom@tromey.com>
4953
4954 * tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.
4955
200aa7b1
TT
49562017-09-29 Tom Tromey <tom@tromey.com>
4957
4958 * utils.c (vfprintf_maybe_filtered): Use std::string.
4959 (vfprintf_unfiltered): Likewise.
4960
606aae8a
TT
49612017-09-29 Tom Tromey <tom@tromey.com>
4962
4963 * event-top.c (top_level_prompt): Return std::string.
4964 (display_gdb_prompt): Update.
4965
bd413795
TT
49662017-09-29 Tom Tromey <tom@tromey.com>
4967
4968 * unittests/common-utils-selftests.c (format): New function.
4969 (string_vprintf_tests): New function.
4970 (_initialize_common_utils_selftests): Register new tests.
4971 * common/common-utils.c (string_vprintf): New function.
4972 * common/common-utils.h (string_vprintf): Declare.
4973
256642e8
PA
49742017-09-29 Pedro Alves <palves@redhat.com>
4975
4976 * common/rsp-low.c (unpack_varlen_hex): Constify.
4977 * common/rsp-low.h (unpack_varlen_hex): Constify.
4978 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
4979 Constify.
4980 * remote.c (remote_set_permissions, read_ptid)
4981 (remote_current_thread, remote_get_threads_with_qthreadinfo)
4982 (remote_static_tracepoint_marker_at)
4983 (remote_static_tracepoint_markers_by_strid)
4984 (stop_reply_extract_thread, remote_parse_stop_reply): Constify.
4985 * tracepoint.c (parse_trace_status, parse_tracepoint_status)
4986 (parse_tracepoint_definition, parse_tsv_definition)
4987 (parse_static_tracepoint_marker_definition): Constify.
4988 * tracepoint.h (parse_static_tracepoint_marker_definition)
4989 (parse_trace_status, parse_tracepoint_status)
4990 (parse_tracepoint_definition, parse_tsv_definition): Constify.
4991
b6bb3468
PA
49922017-09-29 Pedro Alves <palves@redhat.com>
4993
4994 * remote.c (target_buf, target_buf_size): Delete.
4995 (remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
4996 Use the connection's packet buffer instead.
4997 All callers adjusted.
4998 (_initialize_remote): Remove references to target_buf and
4999 target_buf_size.
5000
b2f8eb7a
PA
50012017-09-28 Pedro Alves <palves@redhat.com>
5002
5003 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5004 unittests/common-utils-selftests.c.
5005 (SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
5006 (COMMON_OBS): Remove utils-selftests.o.
5007 * utils-selftests.c: Move to ...
5008 * unittests/common-utils-selftests.c: ... here and rename self
5009 test to "string_printf".
5010
08302ed2
DE
50112017-09-28 Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com> (tiny patch)
5012
5013 * dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
5014 having NULL cus or tus.
5015
96a5a1d3
UW
50162017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
5017
5018 * arm-tdep.c: (convert_from_extended): Remove.
5019 (convert_to_extended): Likewise.
5020 (arm_extract_return_value): Use convert_typed_floating.
5021 (arm_store_return_value): Likewise.
5022
5023 * sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
5024 * sh-tdep.c: Do not include "floatformat.h".
5025 (sh_littlebyte_bigword_type): New function.
5026 (sh_register_convert_to_virtual): Use convert_typed_floating.
5027 (sh_register_convert_to_raw): Likewise.
5028 * sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
5029 (sh64_littlebyte_bigword_type): New function.
5030 (sh64_extract_return_value): Use convert_typed_floating.
5031 (sh64_register_convert_to_virtual): Likewise.
5032 (sh64_register_convert_to_raw): Likewise.
5033
0db7851f
UW
50342017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
5035
5036 * doublest.h (floatformat_from_type): Move to gdbtypes.h.
5037 * doublest.c (floatformat_from_type): Move to gdbtypes.c.
5038
5039 * gdbtypes.h (union type_specific): Make field floatformat hold
5040 just a single struct floatformat, not an array.
5041 (floatformat_from_type): Move here.
5042 * gdbtypes.c (floatformat_from_type): Move here. Update to
5043 changed TYPE_FLOATFORMAT definition.
5044 (verify_floatformat): Update to changed TYPE_FLOATFORMAT.
5045 (recursive_dump_type): Likewise.
5046 (init_float_type): Install correct floatformat for byte order.
5047 (arch_float_type): Likewise.
5048
77b7c781
UW
50492017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
5050
5051 * gdbtypes.c (init_type): Change incoming argument from
5052 length-in-bytes to length-in-bits. Assert length is a
5053 multiple of TARGET_CHAR_BITS.
5054 (arch_type, arch_flags_type): Likewise.
5055 (init_integer_type): Update call to init_type.
5056 (init_character_type): Likewise.
5057 (init_boolean_type): Likewise.
5058 (init_float_type): Likewise.
5059 (init_decfloat_type): Likewise.
5060 (init_complex_type): Likewise.
5061 (init_pointer_type): Likewise.
5062 (objfile_type): Likewise.
5063 (arch_integer_type): Update call to arch_type.
5064 (arch_character_type): Likewise.
5065 (arch_boolean_type): Likewise.
5066 (arch_float_type): Likewise.
5067 (arch_decfloat_type): Likewise.
5068 (arch_complex_type): Likewise.
5069 (arch_pointer_type): Likewise.
5070 (gdbtypes_post_init): Likewise.
5071
5072 * dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
5073 (read_base_type): Likewise.
5074 * mdebugread.c (basic_type): Likewise.
5075 * stabsread.c (dbx_init_float_type): Likewise.
5076 (rs6000_builtin_type): Likewise.
5077 (read_range_type): Likewise. Also, fix call to init_integer_type
5078 with erroneous length argument.
5079
5080 * ada-lang.c (ada_language_arch_info): Update call to arch_type.
5081 * d-lang.c (build_d_types): Likewise.
5082 * f-lang.c (build_fortran_types): Likewise.
5083 * go-lang.c (build_go_types): Likewise.
5084 * opencl-lang.c (build_opencl_types): Likewise.
5085 * jit.c (finalize_symtab): Likewise.
5086 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
5087 (build_std_type_info_type): Likewise.
5088 * target-descriptions.c (tdesc_gdb_type): Likewise. Also,
5089 update call to arch_flags_type.
5090
5091 * linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
5092 arch_type.
5093 * fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
5094 * windows-tdep.c (windows_get_tlb_type): Likewise.
5095
5096 * avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
5097 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
5098 * m32c-tdep.c (make_types): Likewise.
5099 * rl78-tdep.c (rl78_gdbarch_init): Likewise.
5100 (rl78_psw_type): Update call to arch_flags_type.
5101 * m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
5102 * rx-tdep.c (rx_psw_type): Likewise.
5103 (rx_fpsw_type): Likewise.
5104 * sparc-tdep.c (sparc_psr_type): Likewise.
5105 (sparc_fsr_type): Likewise.
5106 * sparc64-tdep.c (sparc64_pstate_type): Likewise.
5107 (sparc64_ccr_type): Likewise.
5108 (sparc64_fsr_type): Likewise.
5109 (sparc64_fprs_type): Likewise.
5110
f21b4d5c
TT
51112017-09-27 Tom Tromey <tom@tromey.com>
5112
5113 * findcmd.c (find_command): Constify.
5114
643c2ffa
TT
51152017-09-27 Tom Tromey <tom@tromey.com>
5116
5117 * ada-tasks.c (task_command_1, task_command): Constify.
5118
510e5e56
TT
51192017-09-27 Tom Tromey <tom@tromey.com>
5120
5121 * symtab.c (maintenance_print_symbol_cache)
5122 (maintenance_flush_symbol_cache)
5123 (maintenance_print_symbol_cache_statistics): Constify.
5124
e503b191
TT
51252017-09-27 Tom Tromey <tom@tromey.com>
5126
5127 * inferior.c (detach_inferior_command, kill_inferior_command)
5128 (inferior_command): Constify.
5129
4e001312
TT
51302017-09-27 Tom Tromey <tom@tromey.com>
5131
5132 * regcache.c (regcache_print, maintenance_print_registers)
5133 (maintenance_print_raw_registers)
5134 (maintenance_print_cooked_registers)
5135 (maintenance_print_register_groups)
5136 (maintenance_print_remote_registers): Constify.
5137
77763700
TT
51382017-09-27 Tom Tromey <tom@tromey.com>
5139
5140 * printcmd.c (map_display_numbers, undisplay_command)
5141 (enable_disable_display_command, enable_display_command)
5142 (disable_display_command): Constify.
5143
4495129a
TT
51442017-09-27 Tom Tromey <tom@tromey.com>
5145
5146 * breakpoint.h (delete_command): Don't declare.
5147 * breakpoint.c (delete_command, enable_once_command)
5148 (enable_count_command, enable_delete_command, breakpoint_1)
5149 (maintenance_info_breakpoints, stopin_command, stopat_command)
5150 (delete_command, delete_trace_command, save_breakpoints)
5151 (save_breakpoints_command, save_tracepoints_command): Constify.
5152
3088cf40
TT
51532017-09-27 Tom Tromey <tom@tromey.com>
5154
5155 * macrocmd.c (macro_expand_command, macro_expand_once_command)
5156 (skip_ws, extract_identifier, macro_define_command)
5157 (macro_undef_command, macro_list_command): Constify.
5158
69f476a3
TT
51592017-09-27 Tom Tromey <tom@tromey.com>
5160
5161 * infcmd.c (environment_info, set_environment_command)
5162 (unset_environment_command, path_info, info_proc_cmd_1)
5163 (info_proc_cmd_mappings, info_proc_cmd_stat)
5164 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
5165 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
5166
c4a3e68e
TT
51672017-09-27 Tom Tromey <tom@tromey.com>
5168
5169 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
5170 Constify.
5171
c9d31bd6
TT
51722017-09-27 Tom Tromey <tom@tromey.com>
5173
5174 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
5175
1f3f85eb
TT
51762017-09-27 Tom Tromey <tom@tromey.com>
5177
5178 * demangle.c (demangle_command): Constify.
5179
9c504b5d
TT
51802017-09-27 Tom Tromey <tom@tromey.com>
5181
5182 * progspace.c (maintenance_info_program_spaces_command):
5183 Constify.
5184
6663cf91
TT
51852017-09-27 Tom Tromey <tom@tromey.com>
5186
5187 * compile/compile.c (check_raw_argument, compile_file_command)
5188 (compile_code_command, compile_print_command): Constify.
5189
34e5fa26
TT
51902017-09-27 Tom Tromey <tom@tromey.com>
5191
5192 * reggroups.c (maintenance_print_reggroups): Constify.
5193
8384c356
TT
51942017-09-27 Tom Tromey <tom@tromey.com>
5195
5196 * dwarf2read.c (save_gdb_index_command): Constify.
5197
884beb0c
TT
51982017-09-27 Tom Tromey <tom@tromey.com>
5199
5200 * stap-probe.c (info_probes_stap_command): Constify.
5201
e0b2930c
TT
52022017-09-27 Tom Tromey <tom@tromey.com>
5203
5204 * fork-child.c (unset_exec_wrapper_command): Constify.
5205
f938677d
TT
52062017-09-27 Tom Tromey <tom@tromey.com>
5207
5208 * btrace.c (get_uint, get_context_size, no_chunk)
5209 (maint_btrace_packet_history_cmd)
5210 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
5211 (maint_info_btrace_cmd): Constify.
5212
8949cb87
TT
52132017-09-27 Tom Tromey <tom@tromey.com>
5214
5215 * reverse.c (delete_bookmark_command): Constify.
5216
ac88e2de
TT
52172017-09-27 Tom Tromey <tom@tromey.com>
5218
5219 * remote.c (set_memory_packet_size)
5220 (set_memory_write_packet_size, show_memory_write_packet_size)
5221 (set_memory_read_packet_size, show_memory_read_packet_size)
5222 (compare_sections_command, packet_command, remote_put_command)
5223 (remote_get_command, remote_delete_command): Constify.
5224
bd4c9dfe
TT
52252017-09-27 Tom Tromey <tom@tromey.com>
5226
5227 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
5228 (set_mipsfpu_double_command, set_mipsfpu_none_command)
5229 (set_mipsfpu_auto_command): Constify.
5230
5e93d4c6
TT
52312017-09-27 Tom Tromey <tom@tromey.com>
5232
5233 * cli/cli-cmds.h (cd_command): Constify.
5234 * cli/cli-cmds.c (cd_command): Constify.
5235
fc41a75b
TT
52362017-09-27 Tom Tromey <tom@tromey.com>
5237
5238 * thread.c (thread_name_command, thread_find_command): Constify.
5239
67810076
TT
52402017-09-27 Tom Tromey <tom@tromey.com>
5241
5242 * probe.c (enable_probes_command, disable_probes_command):
5243 Constify.
5244
1d8b34a7
TT
52452017-09-27 Tom Tromey <tom@tromey.com>
5246
5247 * symfile.c (symbol_file_command): Constify.
5248 * gdbcore.h (deprecated_file_changed_hook): Constify.
5249 * exec.c (deprecated_file_changed_hook, exec_file_command)
5250 (file_command): Constify.
5251 * defs.h (symbol_file_command): Constify.
5252
442019e1
TT
52532017-09-27 Tom Tromey <tom@tromey.com>
5254
5255 * remote-fileio.c (set_system_call_allowed)
5256 (show_system_call_allowed): Constify.
5257
2983f7cb
TT
52582017-09-27 Tom Tromey <tom@tromey.com>
5259
5260 * tracepoint.c (delete_trace_variable_command)
5261 (tfind_end_command, tfind_start_command, tfind_pc_command)
5262 (tfind_tracepoint_command, tfind_line_command)
5263 (tfind_range_command, tfind_outside_command): Constify.
5264
4fd41b24
TT
52652017-09-27 Tom Tromey <tom@tromey.com>
5266
5267 * ax-gdb.c (maint_agent_printf_command, agent_command)
5268 (agent_eval_command): Constify.
5269
f2fc3015
TT
52702017-09-27 Tom Tromey <tom@tromey.com>
5271
5272 * tracepoint.c (info_scope_command): Constify.
5273 * python/python.c (gdbpy_decode_line): Constify.
5274 * python/py-breakpoint.c (bppy_init): Constify.
5275 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
5276 * location.h: (new_linespec_location)
5277 (string_to_event_location_basic, string_to_event_location):
5278 Constify.
5279 * location.c (new_linespec_location)
5280 (string_to_event_location_basic, string_to_event_location):
5281 Constify.
5282 * linespec.h (decode_line_with_current_source)
5283 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
5284 * linespec.c (linespec_lex_to_end)
5285 (decode_line_with_current_source)
5286 (decode_line_with_last_displayed): Constify.
5287 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
5288 Constify.
5289 * cli/cli-cmds.c (edit_command, list_command): Constify.
5290 * breakpoint.h (until_break_command, watch_command_wrapper)
5291 (awatch_command_wrapper, rwatch_command_wrapper)
5292 (init_ada_exception_breakpoint): Constify.
5293 * breakpoint.c (break_command_1, dprintf_command)
5294 (break_range_command, watch_command_wrapper)
5295 (rwatch_command_wrapper, awatch_command_wrapper)
5296 (until_break_command, init_ada_exception_breakpoint)
5297 (strace_marker_create_sals_from_location, trace_command)
5298 (ftrace_command, strace_command, struct tracepoint): Constify.
5299 * ax-gdb.c (agent_command_1): Constify.
5300 * ada-lang.c (ada_exception_sal): Constify.
5301
8c2f95f4
TT
53022017-09-27 Tom Tromey <tom@tromey.com>
5303
5304 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
5305 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
5306 (get_context_size, no_chunk, get_insn_history_modifiers)
5307 (cmd_record_insn_history, get_call_history_modifiers)
5308 (cmd_record_call_history): Constify.
5309
a0d65762
TT
53102017-09-27 Tom Tromey <tom@tromey.com>
5311
5312 * source.c (show_substitute_path_command)
5313 (unset_substitute_path_command, set_substitute_path_command):
5314 Constify.
5315
58971144
TT
53162017-09-27 Tom Tromey <tom@tromey.com>
5317
5318 * typeprint.c (maintenance_print_type): Constify.
5319 * maint.c (maintenance_dump_me, maintenance_demangle)
5320 (maintenance_time_display, maintenance_info_sections)
5321 (maintenance_print_statistics, maintenance_deprecate)
5322 (maintenance_undeprecate): Constify.
5323 (maintenance_do_deprecate): Constify. Use std::string.
5324 (maintenance_selftest): Constify.
5325 * gdbtypes.h (maintenance_print_type): Constify.
5326
c482f52c
TT
53272017-09-27 Tom Tromey <tom@tromey.com>
5328
5329 * hppa-tdep.c (unwind_command): Constify.
5330
e100df1a
TT
53312017-09-27 Tom Tromey <tom@tromey.com>
5332
5333 * target-descriptions.c (unset_tdesc_filename_cmd)
5334 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
5335 Constify.
5336
31d56ade
TT
53372017-09-27 Tom Tromey <tom@tromey.com>
5338
5339 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
5340
b961da0b
TT
53412017-09-27 Tom Tromey <tom@tromey.com>
5342
5343 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
5344
e2d8ae16
TT
53452017-09-27 Tom Tromey <tom@tromey.com>
5346
5347 * tui/tui-regs.c (tui_reg_command): Constify.
5348
863779b0
TT
53492017-09-27 Tom Tromey <tom@tromey.com>
5350
5351 * skip.c (skip_file_command, skip_function_command)
5352 (skip_enable_command, skip_disable_command, skip_delete_command):
5353 Constify.
5354
cdb34d4a
TT
53552017-09-27 Tom Tromey <tom@tromey.com>
5356
5357 * record-btrace.c (cmd_record_btrace_bts_start)
5358 (cmd_record_btrace_pt_start): Constify.
5359
e99c83e7
TT
53602017-09-27 Tom Tromey <tom@tromey.com>
5361
5362 * symmisc.c (maintenance_print_symbols)
5363 (maintenance_print_msymbols, maintenance_print_objfiles)
5364 (maintenance_info_symtabs, maintenance_check_symtabs)
5365 (maintenance_expand_symtabs, maintenance_info_line_tables):
5366 Constify.
5367
32faf971
TT
53682017-09-27 Tom Tromey <tom@tromey.com>
5369
5370 * top.c (new_ui_command): Constify.
5371
2cf311eb
TT
53722017-09-27 Tom Tromey <tom@tromey.com>
5373
5374 * symfile.c (add_symbol_file_command)
5375 (remove_symbol_file_command, list_overlays_command)
5376 (map_overlay_command, unmap_overlay_command)
5377 (overlay_auto_command, overlay_manual_command)
5378 (overlay_off_command, overlay_load_command): Constify.
5379
e6738699
TT
53802017-09-27 Tom Tromey <tom@tromey.com>
5381
5382 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
5383 (info_spu_mailbox_command, info_spu_dma_command)
5384 (info_spu_proxydma_command): Constify.
5385
aa360cd5
TT
53862017-09-27 Tom Tromey <tom@tromey.com>
5387
5388 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
5389
898241a5
TT
53902017-09-27 Tom Tromey <tom@tromey.com>
5391
5392 * cli/cli-script.c (user_defined_command): Constify.
5393
2d0ac106
TT
53942017-09-27 Tom Tromey <tom@tromey.com>
5395
5396 * cli/cli-dump.c (dump_memory_command, dump_value_command)
5397 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
5398 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
5399 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
5400 (dump_binary_value, append_binary_memory, append_binary_value):
5401 Constify.
5402 (struct dump_context) <func>: Constify.
5403 (add_dump_command): Update.
5404
dede02ce
TT
54052017-09-27 Tom Tromey <tom@tromey.com>
5406
5407 * cli/cli-cmds.c (show_version, show_configuration)
5408 (source_command, show_user): Constify.
5409
d3cb6b99
TT
54102017-09-27 Tom Tromey <tom@tromey.com>
5411
5412 * target.c (maintenance_print_target_stack): Constify.
5413
1970a12f
TT
54142017-09-27 Tom Tromey <tom@tromey.com>
5415
5416 * interps.c (interpreter_exec_cmd): Constify.
5417
41243651
TT
54182017-09-27 Tom Tromey <tom@tromey.com>
5419
5420 * record-full.c (cmd_record_full_restore): Constify.
5421
4465d9db
TT
54222017-09-27 Tom Tromey <tom@tromey.com>
5423
5424 * memattr.c (enable_mem_command, disable_mem_command)
5425 (delete_mem_command): Constify.
5426
ad25e423
TT
54272017-09-27 Tom Tromey <tom@tromey.com>
5428
5429 * value.c (show_convenience): Constify.
5430
d64097b1
TT
54312017-09-27 Tom Tromey <tom@tromey.com>
5432
5433 * gdbcore.h (core_file_command): Update.
5434 * corefile.c (core_file_command): Constify.
5435
4d4589ef
TT
54362017-09-27 Tom Tromey <tom@tromey.com>
5437
5438 * user-regs.c (maintenance_print_user_registers): Constify.
5439
32a7bf17
TT
54402017-09-27 Tom Tromey <tom@tromey.com>
5441
5442 * cp-namespace.c (maintenance_cplus_namespace): Constify.
5443
4a475551
TT
54442017-09-27 Tom Tromey <tom@tromey.com>
5445
5446 * cp-support.c (first_component_command): Constify.
5447
990b9f9f
TT
54482017-09-27 Tom Tromey <tom@tromey.com>
5449
5450 * psymtab.c (maintenance_print_psymbols)
5451 (maintenance_info_psymtabs, maintenance_check_psymtabs):
5452 Constify.
5453
c281872e
TT
54542017-09-27 Tom Tromey <tom@tromey.com>
5455
5456 * windows-tdep.c (display_tib): Constify.
5457
5b64bf74
TT
54582017-09-27 Tom Tromey <tom@tromey.com>
5459
5460 * linux-fork.c (delete_checkpoint_command)
5461 (detach_checkpoint_command): Constify.
5462
4ada038f
TT
54632017-09-27 Tom Tromey <tom@tromey.com>
5464
5465 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
5466
57f5a81b
TT
54672017-09-27 Tom Tromey <tom@tromey.com>
5468
5469 * arc-tdep.c (dump_arc_instruction_command): Constify.
5470
b0a8e6c4
TT
54712017-09-27 Tom Tromey <tom@tromey.com>
5472
5473 * valprint.c (set_radix, show_radix): Constify.
5474
8d97dc1c
TT
54752017-09-27 Tom Tromey <tom@tromey.com>
5476
5477 * dtrace-probe.c (info_probes_dtrace_command): Constify.
5478
eb7c454d
TT
54792017-09-27 Tom Tromey <tom@tromey.com>
5480
5481 * command.h (not_just_help_class_command): Update.
5482 * cli/cli-decode.h (not_just_help_class_command): Update.
5483 * cli/cli-decode.c (not_just_help_class_command): Constify.
5484
e4e33335
TT
54852017-09-27 Tom Tromey <tom@tromey.com>
5486
5487 * gdb_bfd.c (maintenance_info_bfds): Constify.
5488
0450cc4c
TT
54892017-09-27 Tom Tromey <tom@tromey.com>
5490
5491 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
5492 overloads.
5493 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
5494 (do_const_cfunc): New function.
5495 (cmd_cfunc_eq): New overload.
5496 (cli_user_command_p): Check do_const_cfunc.
5497 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
5498 const_cfunc.
5499 * command.h (add_cmd): Add const overload and no-function
5500 overload.
5501 (set_cmd_cfunc): Add const overload.
5502 (cmd_const_cfunc_ftype): Declare.
5503 (cmd_cfunc_eq): Add const overload.
5504 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
5505 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
5506 overload.
5507
a9bbfbd8
TT
55082017-09-27 Tom Tromey <tom@tromey.com>
5509
5510 * macroexp.c (get_next_token_for_substitution): New function.
5511 (substitute_args): Call it. Check for __VA_OPT__.
5512
5230b05a
WT
55132017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
5514 Pedro Alves <palves@redhat.com>
5515
5516 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
5517 producer_is_icc_lt_14.
5518 (producer_is_icc_lt_14): New function.
5519 (check_producer): Add code for checking version of ICC.
5520 (producer_is_icc): Move to producer.c.
5521 (read_structure_type): Restrict ICC workaround to ICC<14.
5522 * producer.c: Include selftest.h.
5523 (producer_is_icc, producer_parsing_tests, _initialize_producer):
5524 New functions.
5525 * producer.h (producer_is_icc): New declaration.
5526
b32b108a
WT
55272017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
5528
5529 * Makefile.in (SFILES): Add producer.c.
5530 (COMMON_OBS): Add producer.o
5531 * amd64-tdep.c (producer.h): Add new include.
5532 * dwarf2read.c (producer.h): Add new include.
5533 * producer.c: New file.
5534 * producer.h: New file.
5535 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
5536 producer.c.
5537 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
5538 producer.h.
5539
5007d765
MK
55402017-09-26 Matthias Klose <doko@ubuntu.com>
5541
5542 * configure.ac: Search ncursesw before ncurses.
5543 Check ncursesw/ncurses.h before ncurses/ncurses.h.
5544 * gdb_curses.h: Include <ncursesw/ncurses.h>
5545 * config.in, configure: Regenerate.
5546
281c4447
RO
55472017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5548
5549 PR gdb/22185
5550 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
5551 obsolete.
5552 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
5553 Remove i386sol2 support.
5554 * configure.nat <i386sol2>: Remove.
5555 <sol2-64>: Fold into ...
5556 <sol2>: ... this.
5557 Move common settings to default section.
5558 Add sol-thread.o.
5559 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
5560 x86_64-*-solaris2.1[0-9]*>: Rename to ...
5561 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
5562 <i[34567]86-*-solaris*>: Remove.
5563 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
5564
5565 * configure.ac: Remove wctype in libw check.
5566 (_MSE_INT_H): Don't define on Solaris 7-9.
5567 <solaris*>: Remove libthread_db.so.1 check.
5568 * configure: Regenerate.
5569 * config.in: Regenerate.
5570
5571 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
5572 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
5573 (gdb_ps_size_t): Remove.
5574 Use base types in users.
5575 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
5576
5577 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
5578
39b06c20
RO
55792017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5580
5581 PR build/22206
5582 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
5583 (adi_is_addr_mapped): Likewise.
5584 (PSR_ICC): Don't redefine.
5585 (PSR_IMPL): Likewise.
5586
6c3e20f1
TT
55872017-09-25 Tom Tromey <tom@tromey.com>
5588
5589 * regcache.c (regcache::dump): Use string_printf.
5590
b292235f
TT
55912017-09-25 Tom Tromey <tom@tromey.com>
5592
5593 * regcache.c (class regcache_invalidator): New.
5594 (struct register_to_invalidate): Remove.
5595 (make_cleanup_regcache_invalidate): Remove.
5596 (regcache::raw_write): Use regcache_invalidator.
5597
9ac86b52
TT
55982017-09-25 Tom Tromey <tom@tromey.com>
5599
5600 * spu-tdep.c (spu2ppu_sniffer): Update.
5601 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
5602 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
5603 Remove.
5604 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
5605 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
5606 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
5607 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
5608 (frame_pop): Update.
5609
c0e383c6
TT
56102017-09-25 Tom Tromey <tom@tromey.com>
5611
5612 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
5613 * regcache.h (regcache_xfree): Don't declare.
5614 * regcache.c (regcache_xfree): Remove.
5615 (do_regcache_xfree): Use delete.
5616 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
5617 * linux-fork.c (free_fork): Use delete.
5618 (fork_save_infrun_state): Likewise.
5619 * jit.c (jit_dealloc_cache): Use delete.
5620 * infrun.c (discard_infcall_suspend_state): Use delete.
5621
791199cc
TT
56222017-09-25 Tom Tromey <tom@tromey.com>
5623
5624 * regcache.h (regcache_xmalloc): Don't declare.
5625 (regcache_raw_set_cached_value): Update comment.
5626 * regcache.c (regcache_xmalloc): Remove.
5627 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
5628 * jit.c (jit_frame_sniffer): Use new.
5629 * frame.c (frame_save_as_regcache): Use new.
5630
289e23aa
AA
56312017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
5632
5633 * NEWS: Advertise support for guarded-storage registers on IBM z.
5634
1b63490c
AA
56352017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
5636
5637 * s390-linux-nat.c (have_regset_gs): New static variable.
5638 (s390_linux_fetch_inferior_registers): Handle guarded-storage
5639 control block and guarded-storage broadcast control regsets.
5640 (s390_read_description): Detect whether the target has
5641 guarded-storage support, return appropriate tdesc.
5642 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
5643 (features/s390x-gs-linux64.c): Likewise.
5644 (struct gdbarch_tdep) <have_gs>: New field.
5645 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
5646 (s390_gsbc_regset): New variables.
5647 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
5648 and s390_gsbc_regset, if applicable.
5649 (s390_core_read_description): Check whether core file was from a
5650 target with guarded-storage support; include appropriate regsets.
5651 (s390_gdbarch_init): Add registers for guarded-storage support.
5652 (_initialize_s390_tdep): Initialize new target descriptions that
5653 include registers for guarded-storage support.
5654 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
5655 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
5656 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
5657 (S390_NUM_REGS): Adjust macro definition.
5658 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
5659 (tdesc_s390x_gs_linux64): New declarations.
5660
96235dc1
AA
56612017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
5662
5663 * features/s390-gs-linux64.xml: New file.
5664 * features/s390-gs.xml: New file.
5665 * features/s390-gsbc.xml: New file.
5666 * features/s390x-gs-linux64.xml: New file.
5667 * features/Makefile (WHICH): Add s390-gs-linux64 and
5668 s390x-gs-linux64.
5669 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
5670 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
5671 * features/s390-gs-linux64.c: New generated file.
5672 * features/s390x-gs-linux64.c: New file.
5673 * regformats/s390-gs-linux64.dat: New file.
5674 * regformats/s390x-gs-linux64.dat: New file.
5675
b4a7c699
TT
56762017-09-23 Tom Tromey <tom@tromey.com>
5677
5678 * defs.h (make_cleanup_override_quit_handler): Don't declare.
5679
c2f97536
TT
56802017-09-22 Tom Tromey <tom@tromey.com>
5681
5682 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
5683 type to scoped_restore_tmpl.
5684 <scoped_input_handler>: Initialize m_quit_handler directly.
5685
43573013
SDJ
56862017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
5687
5688 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
5689 (cd_command): Likewise. Free "current_directory" before
5690 assigning to it.
5691 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
5692 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
5693 * top.c (gdb_dirbuf): Remove global declaration.
5694 * top.h (gdb_dirbuf): Likewise.
5695
6ec2e0f5
SDJ
56962017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
5697
5698 * gnulib/aclocal.m4: Regenerate.
5699 * gnulib/config.in: Regenerate.
5700 * gnulib/configure: Regenerate.
5701 * gnulib/import/Makefile.am: Regenerate.
5702 * gnulib/import/Makefile.in: Regenerate.
5703 * gnulib/import/assure.h: New file.
5704 * gnulib/import/at-func.c: Likewise
5705 * gnulib/import/chdir-long.c: New file.
5706 * gnulib/import/chdir-long.h: New file.
5707 * gnulib/import/cloexec.c: New file.
5708 * gnulib/import/cloexec.h: New file.
5709 * gnulib/import/close.c: New file.
5710 * gnulib/import/closedir.c: New file.
5711 * gnulib/import/dirent-private.h: New file.
5712 * gnulib/import/dup-safer.c: New file.
5713 * gnulib/import/dup.c: New file.
5714 * gnulib/import/dup2.c: New file.
5715 * gnulib/import/error.c: New file.
5716 * gnulib/import/error.h: New file.
5717 * gnulib/import/exitfail.c: New file.
5718 * gnulib/import/exitfail.h: New file.
5719 * gnulib/import/fchdir.c: New file.
5720 * gnulib/import/fcntl.c: New file.
5721 * gnulib/import/fcntl.in.h: New file.
5722 * gnulib/import/fd-hook.c: New file.
5723 * gnulib/import/fd-hook.h: New file.
5724 * gnulib/import/fd-safer.c: New file.
5725 * gnulib/import/fdopendir.c: New file.
5726 * gnulib/import/filename.h: New file.
5727 * gnulib/import/filenamecat-lgpl.c: New file.
5728 * gnulib/import/filenamecat.h: New file.
5729 * gnulib/import/fstat.c: New file.
5730 * gnulib/import/fstatat.c: New file.
5731 * gnulib/import/getcwd-lgpl.c: New file.
5732 * gnulib/import/getcwd.c: New file.
5733 * gnulib/import/getdtablesize.c: New file.
5734 * gnulib/import/getlogin_r.c: New file.
5735 * gnulib/import/getprogname.c: New file.
5736 * gnulib/import/getprogname.h: New file.
5737 * gnulib/import/gettext.h: New file.
5738 * gnulib/import/glob-libc.h: New file.
5739 * gnulib/import/glob.c: New file.
5740 * gnulib/import/glob.in.h: New file.
5741 * gnulib/import/intprops.h: New file.
5742 * gnulib/import/m4/chdir-long.m4: New file.
5743 * gnulib/import/m4/close.m4: New file.
5744 * gnulib/import/m4/closedir.m4: New file.
5745 * gnulib/import/m4/d-ino.m4: New file.
5746 * gnulib/import/m4/d-type.m4: New file.
5747 * gnulib/import/m4/dup.m4: New file.
5748 * gnulib/import/m4/dup2.m4: New file.
5749 * gnulib/import/m4/error.m4: New file.
5750 * gnulib/import/m4/fchdir.m4: New file.
5751 * gnulib/import/m4/fcntl.m4: New file.
5752 * gnulib/import/m4/fcntl_h.m4: New file.
5753 * gnulib/import/m4/fdopendir.m4: New file.
5754 * gnulib/import/m4/filenamecat.m4: New file.
5755 * gnulib/import/m4/fstat.m4: New file.
5756 * gnulib/import/m4/fstatat.m4: New file.
5757 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
5758 * gnulib/import/m4/getcwd-path-max.m4: New file.
5759 * gnulib/import/m4/getcwd.m4: New file.
5760 * gnulib/import/m4/getdtablesize.m4: New file.
5761 * gnulib/import/m4/getlogin_r.m4: New file.
5762 * gnulib/import/m4/getprogname.m4: New file.
5763 * gnulib/import/m4/glob.m4: New file.
5764 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
5765 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
5766 * gnulib/import/m4/mempcpy.m4: New file.
5767 * gnulib/import/m4/memrchr.m4: New file.
5768 * gnulib/import/m4/mode_t.m4: New file.
5769 * gnulib/import/m4/msvc-inval.m4: New file.
5770 * gnulib/import/m4/msvc-nothrow.m4: New file.
5771 * gnulib/import/m4/open.m4: New file.
5772 * gnulib/import/m4/openat.m4: New file.
5773 * gnulib/import/m4/opendir.m4: New file.
5774 * gnulib/import/m4/readdir.m4: New file.
5775 * gnulib/import/m4/realloc.m4: New file.
5776 * gnulib/import/m4/rewinddir.m4: New file.
5777 * gnulib/import/m4/save-cwd.m4: New file.
5778 * gnulib/import/m4/strdup.m4: New file.
5779 * gnulib/import/m4/strerror.m4: New file.
5780 * gnulib/import/m4/unistd-safer.m4: New file.
5781 * gnulib/import/mempcpy.c: New file.
5782 * gnulib/import/memrchr.c: New file.
5783 * gnulib/import/msvc-inval.c: New file.
5784 * gnulib/import/msvc-inval.h: New file.
5785 * gnulib/import/msvc-nothrow.c: New file.
5786 * gnulib/import/msvc-nothrow.h: New file.
5787 * gnulib/import/open.c: New file.
5788 * gnulib/import/openat-die.c: New file.
5789 * gnulib/import/openat-priv.h: New file.
5790 * gnulib/import/openat-proc.c: New file.
5791 * gnulib/import/openat.c: New file.
5792 * gnulib/import/openat.h: New file.
5793 * gnulib/import/opendir.c: New file.
5794 * gnulib/import/pipe-safer.c: New file.
5795 * gnulib/import/readdir.c: New file.
5796 * gnulib/import/realloc.c: New file.
5797 * gnulib/import/rewinddir.c: New file.
5798 * gnulib/import/save-cwd.c: New file.
5799 * gnulib/import/save-cwd.h: New file.
5800 * gnulib/import/strdup.c: New file.
5801 * gnulib/import/strerror-override.c: New file.
5802 * gnulib/import/strerror-override.h: New file.
5803 * gnulib/import/strerror.c: New file.
5804 * gnulib/import/unistd--.h: New file.
5805 * gnulib/import/unistd-safer.h: New file.
5806 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
5807 "getcwd" and "glob".
5808 * ser-tcp.c: Undefine "close" before redefining it.
5809
432ae719
SM
58102017-09-21 Simon Marchi <simon.marchi@ericsson.com>
5811
5812 * guile/scm-value.c (gdbscm_value_address): Initialize address,
5813 get rid of res_val.
5814
4fa7574e
RO
58152017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5816
5817 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
5818 <sol2,sparc>: Likewise.
5819 <sol2-64,i386>: Likewise.
5820
5821 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
5822 -Wdeprecated-declarations on *-*-solaris*.
5823 * configure: Regenerate.
5824
5825 * procfs.c: Include "nat/inferior.h".
5826 (procfs_info_proc): Fix typo.
5827
f6327dcb
KB
58282017-09-21 Kevin Buettner <kevinb@redhat.com>
5829
5830 * remote.c (vector): Include.
5831 (struct private_thread_info): Add field, thread_handle.
5832 (free_private_thread_info): Deallocate storage associated with
5833 thread handle.
5834 (get_private_info_thread): Initialize `thread_handle' field.
5835 (struct thread_item): Add field, thread_handle.
5836 (clear_threads_listing_context): Deallocate storage associated
5837 with thread handle.
5838 (start_thread): Add support for "handle" attribute.
5839 (thread_attributes): Add "handle".
5840 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
5841 field.
5842 (remote_update_thread_list): Update thread_handle.
5843 (remote_thread_handle_to_thread_info): New function.
5844 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
5845
fbbe5337
KB
58462017-09-21 Kevin Buettner <kevinb@redhat.com>
5847
5848 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
5849 function.
5850 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
5851 * python/python-internal.h (thread_object_type): Declare.
5852
e04ee09e
KB
58532017-09-21 Kevin Buettner <kevinb@redhat.com>
5854
5855 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
5856 (target_thread_handle_to_thread_info): Declare.
5857 * target.c (target_thread_handle_to_thread_info): New function.
5858 * target-delegates.c: Regenerate.
5859 * gdbthread.h (find_thread_by_handle): Declare.
5860 * thread.c (find_thread_by_handle): New function.
5861 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
5862 function.
5863 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
5864
1e5b66ed
SM
58652017-09-21 Simon Marchi <simon.marchi@ericsson.com>
5866
5867 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
5868
ebe48ba0
SM
58692017-09-21 Simon Marchi <simon.marchi@ericsson.com>
5870
5871 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
5872
0a0bf5dc
YQ
58732017-09-21 Yao Qi <yao.qi@linaro.org>
5874
5875 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
5876 to gdb_target_obs.
5877
d1b0a7bf
TT
58782017-09-20 Tom Tromey <tom@tromey.com>
5879
5880 * breakpoint.c (struct counted_command_line): Remove.
5881 (breakpoint_commands): Update.
5882 (alloc_counted_command_line, incref_counted_command_line)
5883 (decref_counted_command_line, do_cleanup_counted_command_line)
5884 (make_cleanup_decref_counted_command_line): Remove.
5885 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
5886 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
5887 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
5888 (save_breakpoints): Update.
5889 * breakpoint.h (counted_command_line): Now a typedef to
5890 shared_ptr.
5891 (struct breakpoint) <commands>: Now a counted_command_line.
5892 (struct bpstats) <command>: Likewise.
5893
48649e1b
TT
58942017-09-20 Tom Tromey <tom@tromey.com>
5895
5896 * breakpoint.c (struct commands_info, do_map_commands_command):
5897 Remove.
5898 (commands_command_1): Update.
5899 (iterate_over_related_breakpoints): Take a function_view.
5900 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
5901 (delete_command): Update.
5902 (map_breakpoint_numbers): Take a function_view.
5903 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
5904 (disable_command): Update.
5905 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
5906 (enable_command): Update.
5907 (struct disp_data, do_enable_breakpoint_disp)
5908 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
5909 (do_map_enable_delete_breakpoint): Remove.
5910 (enable_once_command, enable_count_command, enable_delete_command)
5911 (delete_trace_variable_command): Update.
5912
04afa70c
TT
59132017-09-20 Tom Tromey <tom@tromey.com>
5914
5915 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
5916 (bpstat_clear): Use delete.
5917 (bpstats): New constructors.
5918 (bpstat_copy, bpstat_stop_status): Use new.
5919 (dprintf_after_condition_true): Update.
5920 * breakpoint.h (bpstats::bpstats): Add constructors.
5921 (bpstats::~bpstats): Add destructor.
5922
c83833f4
PA
59232017-09-20 Pedro Alves <palves@redhat.com>
5924
5925 * eval.c (make_params): Delete, refactored as ...
5926 (class fake_method): ... this new type's ctor.
5927 (fake_method::~fake_method): New.
5928 (evaluate_subexp_standard): Use 'fake_method'.
5929
223ffa71
TT
59302017-09-20 Tom Tromey <tom@tromey.com>
5931
5932 * windows-nat.c (get_windows_debug_event, windows_wait)
5933 (do_initial_windows_stuff, windows_attach): Update.
5934 * utils.c (vwarning, internal_vproblem): Update.
5935 (ui_unregister_input_event_handler_cleanup)
5936 (prepare_to_handle_input): Remove.
5937 (class scoped_input_handler): New.
5938 (defaulted_query, prompt_for_continue): Update.
5939 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
5940 Update.
5941 * top.c (undo_terminal_modifications_before_exit): Update.
5942 * target/target.h (target_terminal_init, target_terminal_inferior)
5943 (target_terminal_ours): Don't declare.
5944 (class target_terminal): New.
5945 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
5946 (target_terminal_ours_for_output)
5947 (make_cleanup_restore_target_terminal): Don't declare.
5948 (target_terminal_info): Remove.
5949 * target.c (enum terminal_state, terminal_state): Remove.
5950 (target_terminal::terminal_state): Define.
5951 (target_terminal::init): Rename from target_terminal_init.
5952 (target_terminal::inferior): Rename from
5953 target_terminal_inferior.
5954 (target_terminal::ours): Rename from target_terminal_ours.
5955 (target_terminal::ours_for_output): Rename from
5956 target_terminal_ours_for_output.
5957 (target_terminal::info): New method.
5958 (cleanup_restore_target_terminal)
5959 (make_cleanup_restore_target_terminal): Remove.
5960 * solib.c (handle_solib_event): Update.
5961 * remote.c (remote_serial_quit_handler): Update.
5962 (remote_terminal_inferior, remote_wait_as): Update.
5963 * record-full.c (record_full_wait_1): Update.
5964 * nto-procfs.c (procfs_create_inferior): Update.
5965 * nat/fork-inferior.c (startup_inferior): Update.
5966 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
5967 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
5968 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
5969 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
5970 (mi_breakpoint_created, mi_breakpoint_deleted)
5971 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
5972 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
5973 (mi_user_selected_context_changed, report_initial_inferior):
5974 Update.
5975 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
5976 (linux_nat_terminal_inferior): Update.
5977 * infrun.c (follow_fork_inferior)
5978 (handle_vfork_child_exec_or_exit, do_target_resume)
5979 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
5980 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
5981 Update.
5982 * inflow.c (child_terminal_init, info_terminal_command): Update.
5983 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
5984 (attach_command): Update.
5985 * infcall.c (call_thread_fsm_should_stop): Update.
5986 * gnu-nat.c (gnu_attach): Update.
5987 * extension.c (struct active_ext_lang_state)
5988 (restore_active_ext_lang): Update.
5989 * exceptions.c (print_flush): Update.
5990 * event-top.c (async_enable_stdin, default_quit_handler): Update.
5991 (struct quit_handler_cleanup_data, restore_quit_handler)
5992 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
5993 Remove.
5994 * cp-support.c (gdb_demangle): Update.
5995 * breakpoint.c (update_inserted_breakpoint_locations)
5996 (insert_breakpoint_locations, handle_jit_event)
5997 (disable_breakpoints_in_unloaded_shlib): Update.
5998 * annotate.c (annotate_breakpoints_invalid)
5999 (annotate_frames_invalid): Update.
6000
013af3fc
TT
60012017-09-20 Tom Tromey <tom@tromey.com>
6002
6003 * main.c (catch_command_errors): Rename from
6004 catch_command_errors_const.
6005 (captured_main_1): Update.
6006
06871ae8
PA
60072017-09-20 Pedro Alves <palves@redhat.com>
6008
6009 * cli/cli-cmds.c (list_command): Use print_sal_location.
6010 (print_sal_location): New function.
6011 (ambiguous_line_spec): Use print_sal_location.
6012 * linespec.c (symbol_to_sal): Record the symbol in the sal.
6013 * symtab.c (find_function_start_sal): Likewise.
6014 * symtab.h (symtab_and_line::symbol): New field.
6015
e5f25bc5
PA
60162017-09-20 Pedro Alves <palves@redhat.com>
6017
6018 * linespec.c (minsym_found): Handle non-text minsyms.
6019 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
6020
1b7fa39e
WT
60212017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
6022
6023 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
6024 backslash.
6025
37dd0825
WT
60262017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
6027
6028 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
6029 vmovups instead vmovaps.
6030 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
6031
4e5a4f58
JB
60322017-09-19 John Baldwin <jhb@FreeBSD.org>
6033
6034 * NEWS (Changes since GDB 8.0): Add starti.
6035 * infcmd.c (enum run_break): New.
6036 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
6037 case.
6038 (run_command): Use enum run_how.
6039 (start_command): Likewise.
6040 (starti_command): New function.
6041 (RUN_ARGS_HELP): New macro.
6042 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
6043 commands. Add starti command.
6044
aa70c9f1
YQ
60452017-09-19 Yao Qi <yao.qi@linaro.org>
6046
6047 * Makefile.in (monitor.o): Remove the rule.
6048
d6541620
YQ
60492017-09-19 Yao Qi <yao.qi@linaro.org>
6050
6051 * annotate.h (struct annotate_arg_emitter): Use
6052 DISABLE_COPY_AND_ASSIGN.
6053 * common/refcounted-object.h (refcounted_object): Likewise.
6054 * completer.h (struct completion_result): Likewise.
6055 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
6056 * filename-seen-cache.h (filename_seen_cache): Likewise.
6057 * gdbcore.h (thread_section_name): Likewise.
6058 * gdb_regex.h (compiled_regex): Likewise.
6059 * gdbthread.h (scoped_restore_current_thread): Likewise.
6060 * inferior.h (scoped_restore_current_inferior): Likewise.
6061 * jit.c (jit_reader): Likewise.
6062 * linespec.h (struct linespec_result): Likewise.
6063 * mi/mi-parse.h (struct mi_parse): Likewise.
6064 * nat/fork-inferior.c (execv_argv): Likewise.
6065 * progspace.h (scoped_restore_current_program_space): Likewise.
6066 * python/python-internal.h (class gdbpy_enter): Likewise.
6067 * regcache.h (regcache): Likewise.
6068 * target-descriptions.c (struct tdesc_reg): Likewise.
6069 (struct tdesc_type): Likewise.
6070 (struct tdesc_feature): Likewise.
6071 * ui-out.h (ui_out_emit_type): Likewise.
6072
0615127c
SM
60732017-09-18 Simon Marchi <simon.marchi@ericsson.com>
6074
6075 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
6076 label abort_expression.
6077
5e187554
SM
60782017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6079
6080 * common/buffer.c (buffer_xml_printf): Adjust.
6081 * common/xml-utils.c (xml_escape_text): Change return type to
6082 std::string, update code accordingly.
6083 * common/xml-utils.h (xml_escape_text): Change return type to
6084 std::string.
6085 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
6086 * windows-tdep.c (windows_xfer_shared_library): Adjust.
6087 * unittests/xml-utils-selftests.c (test_xml_escape_text):
6088 Adjust.
6089
c3d7b541
SM
60902017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6091
6092 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
6093 (SUBDIR_UNITTESTS_OBS): Add new object file.
6094 * unittests/xml-utils-selftests.c: New file.
6095
1526853e
SM
60962017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6097
6098 * common/selftest.h (selftest): New struct/interface.
6099 (register_test): Add name parameter, add new overload.
6100 (run_tests): Add filter parameter.
6101 (for_each_selftest_ftype): New typedef.
6102 (for_each_selftest): New declaration.
6103 * common/selftest.c (tests): Change type to
6104 map<string, unique_ptr<selftest>>.
6105 (simple_selftest): New struct.
6106 (register_test): New function.
6107 (register_test): Add name parameter and use it.
6108 (run_tests): Add filter parameter and use it. Add prints.
6109 Adjust to vector -> map change.
6110 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
6111 registering selftests.
6112 * arm-tdep.c (_initialize_arm_tdep): Likewise.
6113 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
6114 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
6115 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
6116 * findvar.c (_initialize_findvar): Likewise.
6117 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
6118 * maint.c (maintenance_selftest): Update call to run_tests.
6119 (maintenance_info_selftests): New function.
6120 (_initialize_maint_cmds): Register "maintenance info selftests"
6121 command. Update "maintenance selftest" doc.
6122 * regcache.c (_initialize_regcache): Add names when registering
6123 selftests.
6124 * rust-exp.y (_initialize_rust_exp): Likewise.
6125 * selftest-arch.c (gdbarch_selftest): New struct.
6126 (gdbarch_tests): Remove.
6127 (register_test_foreach_arch): Add name parameter. Call
6128 register_test.
6129 (tests_with_arch): Remove, move most content to
6130 gdbarch_selftest::operator().
6131 (_initialize_selftests_foreach_arch): Remove.
6132 * selftest-arch.h (register_test_foreach_arch): Add name
6133 parameter.
6134 (run_tests_with_arch): New declaration.
6135 * utils-selftests.c (_initialize_utils_selftests): Add names
6136 when registering selftests.
6137 * utils.c (_initialize_utils): Likewise.
6138 * unittests/array-view-selftests.c
6139 (_initialize_array_view_selftests): Likewise.
6140 * unittests/environ-selftests.c (_initialize_environ_selftests):
6141 Likewise.
6142 * unittests/function-view-selftests.c
6143 (_initialize_function_view_selftests): Likewise.
6144 * unittests/offset-type-selftests.c
6145 (_initialize_offset_type_selftests): Likewise.
6146 * unittests/optional-selftests.c
6147 (_initialize_optional_selftests): Likewise.
6148 * unittests/scoped_restore-selftests.c
6149 (_initialize_scoped_restore_selftests): Likewise.
6150 * NEWS: Document "maintenance selftest" and "maint info
6151 selftests".
6152
5846367a
SM
61532017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6154
6155 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
6156 scoped_restore.
6157
bd77e8ff
SM
61582017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6159
6160 * mi/mi-main.c (mi_load_progress): Make uiout variable
6161 a unique_ptr.
6162
26a67918
PA
61632017-09-15 Pedro Alves <palves@redhat.com>
6164
6165 * compile/compile-c-types.c (convert_enum, convert_int)
6166 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
6167
3f8a7804
SM
61682017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6169
6170 * dwarf2read.c (copy_string): Remove.
6171 (parse_macro_definition): Replace copy_string with savestring.
6172
8d200706
YQ
61732017-09-15 Yao Qi <yao.qi@linaro.org>
6174
6175 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
6176 gdb_target_obs.
6177 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
6178 Likewise.
6179 (i[34567]86-*-linux*): Likewise.
6180
d185219d
SM
61812017-09-14 Simon Marchi <simon.marchi@ericsson.com>
6182
6183 * dwarf2expr.h (dwarf_stack_value): Add constructor.
6184 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
6185 <stack>: Change type to std::vector.
6186 <stack_len, stack_allocated>: Remove.
6187 <grow_stack>: Remove.
6188 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
6189 (dwarf_expr_context::~dwarf_expr_context): Remove.
6190 (dwarf_expr_context::grow_stack): Remove.
6191 (dwarf_expr_context::push): Adjust.
6192 (dwarf_expr_context::pop): Adjust.
6193 (dwarf_expr_context::fetch): Adjust.
6194 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
6195 (dwarf_expr_context::stack_empty_p): Adjust.
6196 (dwarf_expr_context::execute_stack_op): Adjust.
6197
eccd80d6
SM
61982017-09-14 Simon Marchi <simon.marchi@ericsson.com>
6199
6200 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
6201 return type to bool.
6202 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
6203
69009882
SM
62042017-09-14 Simon Marchi <simon.marchi@ericsson.com>
6205
6206 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
6207 Change type to bool.
6208 (dwarf_stack_value) <in_stack_memory>: Likewise.
6209 (dwarf_expr_context) <push_address>: Change parameter type to
6210 bool.
6211 <fetch_in_stack_memory>: Change return type to bool.
6212 <push>: Change parameter type to bool.
6213 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
6214 to bool.
6215 (dwarf_expr_context::push_address): Likewise.
6216 (dwarf_expr_context::fetch_in_stack_memory): Change return type
6217 to bool.
6218 (dwarf_expr_context::execute_stack_op): Adjust.
6219 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
6220
1e467161
SM
62212017-09-14 Simon Marchi <simon.marchi@ericsson.com>
6222
6223 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
6224 (struct dwarf_expr_context) <n_pieces>: Remove.
6225 <pieces>: Change type to std::vector.
6226 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
6227 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
6228 pieces.
6229 (dwarf_expr_context::add_piece): Adjust.
6230 * dwarf2loc.c (struct piece_closure): Initialize fields.
6231 <n_pieces>: Remove.
6232 <pieces>: Change type to std::vector.
6233 (allocate_piece_closure): Adjust, change parameter to
6234 std::vector rvalue and std::move it to piece_closure.
6235 (rw_pieced_value): Adjust.
6236 (check_pieced_synthetic_pointer): Adjust.
6237 (indirect_synthetic_pointer): Adjust.
6238 (coerce_pieced_ref): Adjust.
6239 (free_pieced_value_closure): Adjust. Use delete to free
6240 piece_closure.
6241 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
6242 to allocate_piece_closure.
6243 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
6244
0782db84
SM
62452017-09-12 Simon Marchi <simon.marchi@ericsson.com>
6246
6247 * probe.h (probe_ops_cp): Remove typedef.
6248 (DEF_VEC_P (probe_ops_cp)): Remove.
6249 (all_probe_ops): Change type to std::vector.
6250 * probe.c (info_probes_for_ops): Adjust to vector change.
6251 (probe_linespec_to_ops): Likewise.
6252 (all_probe_ops): Change type to std::vector.
6253 (_initialize_probe): Adjust to vector change.
6254 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
6255 * elfread.c (elf_get_probes): Likewise.
6256 * stap-probe.c (_initialize_stap_probe): Likewise.
6257
1eac6bea
SM
62582017-09-12 Simon Marchi <simon.marchi@ericsson.com>
6259
6260 * probe.h (struct bound_probe): Define constructors.
6261 * probe.c (bound_probe_s): Remove typedef.
6262 (DEF_VEC_O (bound_probe_s)): Remove VEC.
6263 (collect_probes): Change return type to std::vector, remove
6264 cleanup.
6265 (compare_probes): Return bool, change parameter type. Change
6266 semantic to "less than".
6267 (gen_ui_out_table_header_info): Change parameter to std::vector
6268 and update.
6269 (exists_probe_with_pops): Likewise.
6270 (info_probes_for_ops): Update to std::vector change.
6271 (enable_probes_command): Likewise.
6272 (disable_probes_command): Likewise.
6273
aaa63a31
SM
62742017-09-12 Simon Marchi <simon.marchi@ericsson.com>
6275
6276 * probe.h (struct probe_ops) <get_probes>: Change parameter from
6277 vec to std::vector.
6278 * probe.c (parse_probes_in_pspace): Update.
6279 (find_probes_in_objfile): Update.
6280 (find_probe_by_pc): Update.
6281 (collect_probes): Update.
6282 (probe_any_get_probes): Update.
6283 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
6284 return type to reference to std::vector.
6285 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
6286 std::vector and update.
6287 (dtrace_process_dof): Likewise.
6288 (dtrace_get_probes): Likewise.
6289 * elfread.c (elf_get_probes): Change return type to std::vector,
6290 store an std::vector in bfd_data.
6291 (probe_key_free): Update to std::vector.
6292 * stap-probe.c (handle_stap_probe): Change parameter to
6293 std::vector and update.
6294 (stap_get_probes): Likewise.
6295 * symfile-debug.c (debug_sym_get_probes): Change return type to
6296 std::vector and update.
6297
cb85b21b
TT
62982017-09-11 Tom Tromey <tom@tromey.com>
6299
6300 * breakpoint.c (program_breakpoint_here_p): Update.
6301 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
6302 from make_show_memory_breakpoints_cleanup. Return a
6303 scoped_restore_tmpl<int>.
6304 (restore_show_memory_breakpoints): Remove.
6305 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
6306 * mem-break.c (memory_validate_breakpoint): Update.
6307 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
6308 (ia64_memory_remove_breakpoint): Update.
6309 (ia64_breakpoint_from_pc): Update.
6310 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
6311 from make_show_memory_breakpoints_cleanup.
6312
8fbc99ef
TT
63132017-09-11 Tom Tromey <tom@tromey.com>
6314
6315 * d-namespace.c (d_lookup_symbol): Use std::string.
6316 (find_symbol_in_baseclass): Likewise.
6317
50feb4bd
TT
63182017-09-11 Tom Tromey <tom@tromey.com>
6319
6320 * ctf.c (ctf_start): Use std::string.
6321
c6dc63a1
TT
63222017-09-11 Tom Tromey <tom@tromey.com>
6323
6324 * ada-lang.c (is_known_support_routine): Update.
6325 (ada_unhandled_exception_name_addr_from_raise): Update.
6326 * guile/scm-frame.c (gdbscm_frame_name): Update.
6327 * python/py-frame.c (frapy_name): Update.
6328 (frapy_function): Update.
6329 * stack.h (find_frame_funname): Update.
6330 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
6331 (print_frame): Update.
6332
d6b9b80f
TT
63332017-09-11 Tom Tromey <tom@tromey.com>
6334
6335 * findcmd.c (put_bits): Take a gdb::byte_vector.
6336 (parse_find_args): Return gdb::byte_vector. "args" now const.
6337 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
6338 cleanups.
6339 (find_command): Update.
6340
a9921622
TT
63412017-09-11 Tom Tromey <tom@tromey.com>
6342
6343 * cli/cli-script.c (class scoped_restore_hook_in): New.
6344 (clear_hook_in_cleanup): Remove.
6345 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
6346 scoped_restore_hook_in.
6347
be0d7abb
TT
63482017-09-11 Tom Tromey <tom@tromey.com>
6349
6350 * cli/cli-script.c (restore_interp): Remove.
6351 (read_command_lines): Use scoped_restore_interp.
6352 * interps.c (scoped_restore_interp::set_temp): Rename from
6353 interp_set_temp.
6354 * interps.h (class scoped_restore_interp): New.
6355 (interp_set_temp): Remove.
6356
00f675ff
TT
63572017-09-11 Tom Tromey <tom@tromey.com>
6358
6359 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
6360 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
6361 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
6362 scoped_restore.
6363 (mi_cmd_break_insert_1): Update.
6364 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
6365 scoped_restore.
6366
cb791d59
TT
63672017-09-11 Tom Tromey <tom@tromey.com>
6368
6369 * demangle.c (demangle_command): Update.
6370 * breakpoint.c (disable_command): Update.
6371 (enable_command): Update.
6372 (find_location_by_number): Make "number" const. Use
6373 get_number_trailer.
6374 * cli/cli-utils.c (extract_arg): Return std::string.
6375 * probe.c (parse_probe_linespec): Update. Change types.
6376 (collect_probes): Take string arguments.
6377 (parse_probe_linespec): Likewise.
6378 (info_probes_for_ops): Update.
6379 (enable_probes_command): Update.
6380 (disable_probes_command): Update.
6381 * break-catch-sig.c (catch_signal_split_args): Update.
6382 * mi/mi-parse.c (mi_parse): Update.
6383
2039bd9f
TT
63842017-09-11 Tom Tromey <tom@tromey.com>
6385
6386 * language.h (language_enum): Make argument const.
6387 * language.c (language_enum): Make argument const.
6388
f1735a53
TT
63892017-09-11 Tom Tromey <tom@tromey.com>
6390
6391 * common/common-utils.h (skip_to_space): Remove macro, redeclare
6392 as function.
6393 (skip_to_space): Rename from skip_to_space_const.
6394 * common/common-utils.c (skip_to_space): New function.
6395 (skip_to_space): Rename from skip_to_space_const.
6396 * cli/cli-utils.h (get_number): Rename from get_number_const.
6397 (extract_arg): Rename from extract_arg_const.
6398 * cli/cli-utils.c (get_number): Rename from get_number_const.
6399 (extract_arg): Rename from extract_arg_const.
6400 (number_or_range_parser::get_number): Use ::get_number.
6401 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
6402 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
6403 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
6404 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
6405 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
6406 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
6407 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
6408 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
6409
7d221d74
TT
64102017-09-11 Tom Tromey <tom@tromey.com>
6411
6412 * python/python.c (do_start_initialization): Use
6413 py-event-types.def to initialize types.
6414 Define all object type structures.
6415 * python/python-internal.h: Don't declare event initialization
6416 functions.
6417 * python/py-threadevent.c (thread_event_object_type): Don't
6418 define.
6419 * python/py-stopevent.c (stop_event_object_type): Don't define.
6420 * python/py-signalevent.c (signal_event_object_type): Don't
6421 declare or define.
6422 * python/py-newobjfileevent.c (new_objfile_event_object_type)
6423 (clear_objfiles_event_object_type): Don't declare or define.
6424 * python/py-infevents.c (inferior_call_pre_event_object_type)
6425 (inferior_call_post_event_object_type)
6426 (register_changed_event_object_type)
6427 (memory_changed_event_object_type): Don't declare or define.
6428 * python/py-inferior.c (new_thread_event_object_type)
6429 (new_inferior_event_object_type)
6430 (inferior_deleted_event_object_type): Don't declare or define.
6431 * python/py-exitedevent.c (exited_event_object_type): Don't
6432 declare or define.
6433 * python/py-evts.c (gdbpy_initialize_py_events): Use
6434 py-all-events.def.
6435 * python/py-events.h (thread_event_object_type): Don't declare.
6436 (events_object): Use py-all-events.def.
6437 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
6438 py-event-types.def.
6439 * python/py-event-types.def: New file.
6440 * python/py-continueevent.c (create_continue_event_object): Don't
6441 declare or define.
6442 * python/py-bpevent.c (breakpoint_event_object_type): Don't
6443 declare or define.
6444 * python/py-all-events.def: New file.
6445
35c61a1d
TT
64462017-09-11 Tom Tromey <tom@tromey.com>
6447
6448 * python/py-threadevent.c (create_thread_event_object): Return
6449 gdbpy_ref.
6450 * python/py-stopevent.h (create_stop_event_object)
6451 (create_breakpoint_event_object, create_signal_event_object):
6452 Update.
6453 * python/py-stopevent.c (create_stop_event_object): Return
6454 gdbpy_ref.
6455 (emit_stop_event): Update.
6456 * python/py-signalevent.c (create_signal_event_object): Return
6457 gdbpy_ref.
6458 * python/py-infevents.c (create_inferior_call_event_object):
6459 Update.
6460 * python/py-event.h (create_event_object)
6461 (create_thread_event_object): Update.
6462 * python/py-event.c (create_event_object): Return gdbpy_ref.
6463 * python/py-continueevent.c: Return gdbpy_ref.
6464 * python/py-bpevent.c (create_breakpoint_event_object): Return
6465 gdbpy_ref.
6466
7c96f8c1
TT
64672017-09-11 Tom Tromey <tom@tromey.com>
6468
6469 PR python/15622:
6470 * NEWS: Add entry.
6471 * python/python.c (do_start_initialization): Initialize new event
6472 types.
6473 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
6474 (gdbpy_initialize_inferior_deleted_event)
6475 (gdbpy_initialize_new_thread_event): Declare.
6476 * python/py-threadevent.c (create_thread_event_object): Add option
6477 "thread" parameter.
6478 * python/py-inferior.c (new_thread_event_object_type)
6479 (new_inferior_event_object_type)
6480 (inferior_deleted_event_object_type): Declare.
6481 (python_new_inferior, python_inferior_deleted): New functions.
6482 (add_thread_object): Emit new_thread event.
6483 (gdbpy_initialize_inferior): Attach new functions to corresponding
6484 observers.
6485 (new_thread, new_inferior, inferior_deleted): Define new event
6486 types.
6487 * python/py-evts.c (gdbpy_initialize_py_events): Add new
6488 registries.
6489 * python/py-events.h (events_object) <new_inferior,
6490 inferior_deleted, new_thread>: New fields.
6491 * python/py-event.h (create_thread_event_breakpoint): Add optional
6492 "thread" parameter.
6493
72542b8e
AB
64942017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
6495
6496 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
6497 check current_ui instead.
6498 (internal_vproblem): Likewise.
6499
0d64823e
SM
65002017-09-09 Simon Marchi <simon.marchi@ericsson.com>
6501
6502 * thread.c (print_thread_info_1): Remove unnecessary calls to
6503 uiout->is_mi_like_p.
6504
eb1e02fd
TT
65052017-09-09 Tom Tromey <tom@tromey.com>
6506
6507 * namespace.h (add_using_directive): Update.
6508 * namespace.c (add_using_directive): Change type of excludes to
6509 std::vector.
6510 * dwarf2read.c (read_import_statement): Use std::vector.
6511 (read_namespace): Update.
6512 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
6513
0fc21fd8
TT
65142017-09-09 Tom Tromey <tom@tromey.com>
6515
6516 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
6517
49663d05
TT
65182017-09-09 Tom Tromey <tom@tromey.com>
6519
6520 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
6521
0b868b60
TT
65222017-09-09 Tom Tromey <tom@tromey.com>
6523
6524 * stack.c (func_command): Use gdb::def_vector.
6525
c0470d48
TT
65262017-09-09 Tom Tromey <tom@tromey.com>
6527
6528 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
6529 ui_out_emit_list, ui_out_emit_tuple.
6530 (mi_cmd_var_update): Likewise.
6531
ca5909c7
TT
65322017-09-09 Tom Tromey <tom@tromey.com>
6533
6534 * mi/mi-interp.c (mi_user_selected_context_changed): Use
6535 ui_out_redirect_pop.
6536 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
6537 ui_out_redirect_pop.
6538 * utils.c (do_ui_out_redirect_pop)
6539 (make_cleanup_ui_out_redirect_pop): Remove.
6540 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
6541 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
6542 * ui-out.h (ui_out_redirect_pop): New class.
6543
e6a2252a
TT
65442017-09-09 Tom Tromey <tom@tromey.com>
6545
6546 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
6547 (list_available_thread_groups, mi_cmd_list_thread_groups)
6548 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
6549 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
6550 Likewise.
6551
393702cd
TT
65522017-09-09 Tom Tromey <tom@tromey.com>
6553
6554 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
6555 ui_out_emit_tuple.
6556
76f9c9cf
TT
65572017-09-09 Tom Tromey <tom@tromey.com>
6558
6559 * target.c (flash_erase_command): Use ui_out_emit_tuple.
6560 * stack.c (print_frame): Use ui_out_emit_tuple.
6561 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
6562 (info_spu_mailbox_command, info_spu_dma_command)
6563 (info_spu_proxydma_command): Likewise.
6564 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
6565 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
6566 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
6567 ui_out_emit_tuple.
6568 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
6569
dc9fe180
TT
65702017-09-09 Tom Tromey <tom@tromey.com>
6571
6572 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
6573 (class ui_out_emit_table): Update comment.
6574 * ui-out.c (do_cleanup_table_end)
6575 (make_cleanup_ui_out_table_begin_end): Remove.
6576 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
6577 (info_spu_dma_cmdlist): Likewise.
6578 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
6579 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
6580 ui_out_emit_table.
6581
f8cc3da6
TT
65822017-09-09 Tom Tromey <tom@tromey.com>
6583
6584 * thread.c (print_thread_info_1): Use ui_out_emit_table,
6585 ui_out_emit_list, gdb::optional.
6586
481695ed
JB
65872017-09-09 John Baldwin <jhb@FreeBSD.org>
6588
6589 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
6590 prototype.
6591 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
6592 prototype.
6593 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
6594 prototype.
6595 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
6596 * ada-exp.y: Remove _initialize_ada_exp prototype.
6597 * ada-lang.c: Remove _initialize_ada_language prototype.
6598 * ada-tasks.c: Remove _initialize_tasks prototype.
6599 * addrmap.c: Remove _initialize_addrmap prototype.
6600 * agent.c: Remove _initialize_agent prototype.
6601 * aix-thread.c: Remove _initialize_aix_thread prototype.
6602 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
6603 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
6604 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
6605 prototype.
6606 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
6607 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
6608 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
6609 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
6610 prototype.
6611 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
6612 prototype.
6613 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
6614 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
6615 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
6616 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
6617 prototype.
6618 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
6619 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
6620 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
6621 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
6622 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
6623 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
6624 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
6625 prototype.
6626 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
6627 prototype.
6628 * annotate.c: Remove _initialize_annotate prototype.
6629 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
6630 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
6631 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
6632 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
6633 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
6634 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
6635 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
6636 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
6637 prototype.
6638 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
6639 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
6640 * auto-load.c: Remove _initialize_auto_load prototype.
6641 * auxv.c: Remove _initialize_auxv prototype.
6642 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
6643 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
6644 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
6645 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
6646 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
6647 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
6648 prototype.
6649 * break-catch-throw.c: Remove _initialize_break_catch_throw
6650 prototype.
6651 * breakpoint.c: Remove _initialize_breakpoint prototype.
6652 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
6653 * btrace.c: Remove _initialize_btrace prototype.
6654 * charset.c: Remove _initialize_charset prototype.
6655 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
6656 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
6657 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
6658 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
6659 * cli/cli-script.c: Remove _initialize_cli_script prototype.
6660 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
6661 * coffread.c: Remove _initialize_coffread prototype.
6662 * compile/compile.c: Remove _initialize_compile prototype.
6663 * complaints.c: Remove _initialize_complaints prototype.
6664 * completer.c: Remove _initialize_completer prototype.
6665 * copying.awk: Remove _initialize_copying prototype.
6666 * copying.c: Regenerate.
6667 * core-regset.c: Remove _initialize_core_regset prototype.
6668 * corefile.c: Remove _initialize_core prototype.
6669 * corelow.c: Remove _initialize_corelow prototype.
6670 * cp-abi.c: Remove _initialize_cp_abi prototype.
6671 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
6672 * cp-support.c: Remove _initialize_cp_support prototype.
6673 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
6674 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
6675 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
6676 * ctf.c: Remove _initialize_ctf prototype.
6677 * d-lang.c: Remove _initialize_d_language prototype.
6678 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
6679 prototype.
6680 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
6681 * dbxread.c: Remove _initialize_dbxread prototype.
6682 * dcache.c: Remove _initialize_dcache prototype.
6683 * demangle.c: Remove _initialize_demangler prototype.
6684 * disasm-selftests.c: Remove _initialize_disasm_selftests
6685 prototype.
6686 * disasm.c: Remove _initialize_disasm prototype.
6687 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
6688 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
6689 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
6690 prototype.
6691 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
6692 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
6693 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
6694 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
6695 * elfread.c: Remove _initialize_elfread prototype.
6696 * exec.c: Remove _initialize_exec prototype.
6697 * extension.c: Remove _initialize_extension prototype.
6698 * f-lang.c: Remove _initialize_f_language prototype.
6699 * f-valprint.c: Remove _initialize_f_valprint prototype.
6700 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
6701 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
6702 * filesystem.c: Remove _initialize_filesystem prototype.
6703 * findcmd.c: Remove _initialize_mem_search prototype.
6704 * fork-child.c: Remove _initialize_fork_child prototype.
6705 * frame-base.c: Remove _initialize_frame_base prototype.
6706 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
6707 * frame.c: Remove _initialize_frame prototype.
6708 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
6709 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
6710 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
6711 * gcore.c: Remove _initialize_gcore prototype.
6712 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
6713 * gdbarch.c: Regenerate.
6714 * gdbarch.sh: Remove _initialize_gdbarch prototype.
6715 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
6716 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
6717 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
6718 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
6719 * go-lang.c: Remove _initialize_go_language prototype.
6720 * go32-nat.c: Remove _initialize_go32_nat prototype.
6721 * guile/guile.c: Remove _initialize_guile prototype.
6722 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
6723 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
6724 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
6725 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
6726 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
6727 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
6728 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
6729 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
6730 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
6731 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
6732 prototype.
6733 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
6734 prototype.
6735 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
6736 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
6737 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
6738 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
6739 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
6740 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
6741 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
6742 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
6743 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
6744 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
6745 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
6746 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
6747 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
6748 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
6749 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
6750 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
6751 prototype.
6752 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
6753 prototype.
6754 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
6755 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
6756 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
6757 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
6758 * infcall.c: Remove _initialize_infcall prototype.
6759 * infcmd.c: Remove _initialize_infcmd prototype.
6760 * inferior.c: Remove _initialize_inferiors prototype.
6761 * inflow.c: Remove _initialize_inflow prototype.
6762 * infrun.c: Remove _initialize_infrun prototype.
6763 * interps.c: Remove _initialize_interpreter prototype.
6764 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
6765 * jit.c: Remove _initialize_jit prototype.
6766 * language.c: Remove _initialize_language prototype.
6767 * linux-fork.c: Remove _initialize_linux_fork prototype.
6768 * linux-nat.c: Remove _initialize_linux_nat prototype.
6769 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
6770 * linux-thread-db.c: Remove _initialize_thread_db prototype.
6771 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
6772 * m2-lang.c: Remove _initialize_m2_language prototype.
6773 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
6774 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
6775 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
6776 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
6777 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
6778 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
6779 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
6780 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
6781 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
6782 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
6783 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
6784 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
6785 * machoread.c: Remove _initialize_machoread prototype.
6786 * macrocmd.c: Remove _initialize_macrocmd prototype.
6787 * macroscope.c: Remove _initialize_macroscope prototype.
6788 * maint.c: Remove _initialize_maint_cmds prototype.
6789 * mdebugread.c: Remove _initialize_mdebugread prototype.
6790 * memattr.c: Remove _initialize_mem prototype.
6791 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
6792 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
6793 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
6794 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
6795 * mi/mi-main.c: Remove _initialize_mi_main prototype.
6796 * microblaze-linux-tdep.c: Remove
6797 _initialize_microblaze_linux_tdep prototype.
6798 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
6799 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
6800 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
6801 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
6802 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
6803 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
6804 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
6805 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
6806 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
6807 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
6808 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
6809 prototype.
6810 * mipsread.c: Remove _initialize_mipsread prototype.
6811 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
6812 prototype.
6813 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
6814 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
6815 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
6816 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
6817 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
6818 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
6819 prototype.
6820 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
6821 * nto-procfs.c: Remove _initialize_procfs prototype.
6822 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
6823 * objc-lang.c: Remove _initialize_objc_language prototype.
6824 * objfiles.c: Remove _initialize_objfiles prototype.
6825 * observer.c: Remove observer_test_first_notification_function,
6826 observer_test_second_notification_function,
6827 observer_test_third_notification_function, and
6828 _initialize_observer prototypes.
6829 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
6830 * osabi.c: Remove _initialize_gdb_osabi prototype.
6831 * osdata.c: Remove _initialize_osdata prototype.
6832 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
6833 * parse.c: Remove _initialize_parse prototype.
6834 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
6835 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
6836 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
6837 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
6838 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
6839 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
6840 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
6841 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
6842 * printcmd.c: Remove _initialize_printcmd prototype.
6843 * probe.c: Remove _initialize_probe prototype.
6844 * proc-api.c: Remove _initialize_proc_api prototype.
6845 * proc-events.c: Remove _initialize_proc_events prototype.
6846 * proc-service.c: Remove _initialize_proc_service prototype.
6847 * procfs.c: Remove _initialize_procfs prototype.
6848 * psymtab.c: Remove _initialize_psymtab prototype.
6849 * python/python.c: Remove _initialize_python prototype.
6850 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
6851 * record-btrace.c: Remove _initialize_record_btrace prototype.
6852 * record-full.c: Remove _initialize_record_full prototype.
6853 * record.c: Remove _initialize_record prototype.
6854 * regcache.c: Remove _initialize_regcache prototype.
6855 * reggroups.c: Remove _initialize_reggroup prototype.
6856 * remote-notif.c: Remove _initialize_notif prototype.
6857 * remote-sim.c: Remove _initialize_remote_sim prototype.
6858 * remote.c: Remove _initialize_remote prototype.
6859 * reverse.c: Remove _initialize_reverse prototype.
6860 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
6861 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
6862 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
6863 prototype.
6864 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
6865 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
6866 * rust-exp.y: Remove _initialize_rust_exp prototype.
6867 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
6868 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
6869 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
6870 * score-tdep.c: Remove _initialize_score_tdep prototype.
6871 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
6872 prototype.
6873 * ser-go32.c: Remove _initialize_ser_dos prototype.
6874 * ser-mingw.c: Remove _initialize_ser_windows prototype.
6875 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
6876 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
6877 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
6878 * serial.c: Remove _initialize_serial prototype.
6879 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
6880 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
6881 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
6882 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
6883 * skip.c: Remove _initialize_step_skip prototype.
6884 * sol-thread.c: Remove _initialize_sol_thread prototype.
6885 * solib-aix.c: Remove _initialize_solib_aix prototype.
6886 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
6887 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
6888 * solib-frv.c: Remove _initialize_frv_solib prototype.
6889 * solib-spu.c: Remove _initialize_spu_solib prototype.
6890 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
6891 * solib-target.c: Remove _initialize_solib_target prototype.
6892 * solib.c: Remove _initialize_solib prototype.
6893 * source.c: Remove _initialize_source prototype.
6894 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
6895 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
6896 prototype.
6897 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
6898 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
6899 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
6900 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
6901 prototype.
6902 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
6903 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
6904 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
6905 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
6906 prototype.
6907 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
6908 prototype.
6909 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
6910 prototype.
6911 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
6912 prototype.
6913 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
6914 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
6915 prototype.
6916 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
6917 prototype.
6918 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
6919 prototype.
6920 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
6921 prototype.
6922 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
6923 prototype.
6924 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
6925 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
6926 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
6927 * stabsread.c: Remove _initialize_stabsread prototype.
6928 * stack.c: Remove _initialize_stack prototype.
6929 * stap-probe.c: Remove _initialize_stap_probe prototype.
6930 * std-regs.c: Remove _initialize_frame_reg prototype.
6931 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
6932 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
6933 * symfile.c: Remove _initialize_symfile prototype.
6934 * symmisc.c: Remove _initialize_symmisc prototype.
6935 * symtab.c: Remove _initialize_symtab prototype.
6936 * target-dcache.c: Remove _initialize_target_dcache prototype.
6937 * target-descriptions.c: Remove _initialize_target_descriptions
6938 prototype.
6939 * thread.c: Remove _initialize_thread prototype.
6940 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
6941 prototype.
6942 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
6943 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
6944 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
6945 prototype.
6946 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
6947 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
6948 * tracefile.c: Remove _initialize_tracefile prototype.
6949 * tracepoint.c: Remove _initialize_tracepoint prototype.
6950 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
6951 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
6952 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
6953 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
6954 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
6955 * tui/tui-win.c: Remove _initialize_tui_win prototype.
6956 * tui/tui.c: Remove _initialize_tui prototype.
6957 * typeprint.c: Remove _initialize_typeprint prototype.
6958 * user-regs.c: Remove _initialize_user_regs prototype.
6959 * utils.c: Remove _initialize_utils prototype.
6960 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
6961 * valarith.c: Remove _initialize_valarith prototype.
6962 * valops.c: Remove _initialize_valops prototype.
6963 * valprint.c: Remove _initialize_valprint prototype.
6964 * value.c: Remove _initialize_values prototype.
6965 * varobj.c: Remove _initialize_varobj prototype.
6966 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
6967 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
6968 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
6969 * windows-nat.c: Remove _initialize_windows_nat,
6970 _initialize_check_for_gdb_ini, and _initialize_loadable
6971 prototypes.
6972 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
6973 * xcoffread.c: Remove _initialize_xcoffread prototype.
6974 * xml-support.c: Remove _initialize_xml_support prototype.
6975 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
6976 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
6977 prototype.
6978 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
6979 prototype.
6980 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
6981
a611b5cb
KS
69822017-09-08 Keith Seitz <keiths@redhat.com>
6983
6984 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
6985 field.
6986
469412dd
CW
69872017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
6988
6989 * f-valprint.c (f_val_print): Remove check for one byte
6990 sized integers. Remove printing of character type.
6991
a5ad232b
FP
69922017-09-08 Frank Penczek <frank.penczek@intel.com>
6993 Christoph Weinmann <christoph.t.weinmann@intel.com>
6994 Bernhard Heckel <bernhard.heckel@intel.com>
6995
6996 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
6997 to maintain proper indentation when printing pointers/refs.
6998
e5014227
JB
69992017-09-07 Joel Brobecker <brobecker@adacore.com>
7000
7001 GDB 8.0.1 released.
7002
63c99141
JB
70032017-09-07 Joel Brobecker <brobecker@adacore.com>
7004
7005 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
7006
69c1e056
TT
70072017-09-05 Tom Tromey <tom@tromey.com>
7008
7009 * parse.c (funcall_chain): Now a std::vector.
7010 (start_arglist, end_arglist): Simplify.
7011 (free_funcalls): Remove.
7012 (parse_exp_in_context_1): Remove cleanup.
7013
fef704bf
TT
70142017-09-05 Tom Tromey <tom@tromey.com>
7015
7016 * go-exp.y (go_parse): Don't create a cleanup.
7017
5613c585
TT
70182017-09-05 Tom Tromey <tom@tromey.com>
7019
7020 * d-exp.y (PrimaryExpression): Use std::string.
7021 (d_parse): Don't create a cleanup.
7022
eae49211
TT
70232017-09-05 Tom Tromey <tom@tromey.com>
7024
7025 * utils.c (do_clear_parser_state): Remove.
7026 (make_cleanup_clear_parser_state): Remove.
7027 * p-exp.y (pascal_parse): Use scoped_restore.
7028 * m2-exp.y (m2_parse): Use scoped_restore.
7029 * f-exp.y (f_parse): Use scoped_restore.
7030 * d-exp.y (d_parse): Use scoped_restore.
7031 * c-exp.y (c_parse): Use scoped_restore.
7032 * ada-exp.y (ada_parse): Use scoped_restore.
7033 * utils.h (make_cleanup_clear_parser_state): Remove.
7034
73b9be8b
KS
70352017-09-06 Keith Seitz <keiths@redhat.com>
7036
7037 * dwarf2read.c (dw2_linkage_name_attr): New function.
7038 (dw2_linkage_name): New function.
7039 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
7040 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
7041 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
7042
a102602b
KR
70432017-09-06 Kamil Rytarowski <n54@gmx.com>
7044
7045 * config/djgpp/djconfig.sh: Correct shell portability issue.
7046
28ad437d
KR
70472017-09-06 Kamil Rytarowski <n54@gmx.com>
7048
7049 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
7050
351787dd
JB
70512017-09-06 John Baldwin <jhb@FreeBSD.org>
7052
7053 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
7054 * NEWS: Mention new FreeBSD/mips native configuration.
7055 * configure.host: Add aarch64*-*-freebsd*.
7056 * configure.nat: Likewise.
7057 * aarch64-fbsd-nat.c: New file.
7058
c0f84956
JB
70592017-09-06 John Baldwin <jhb@FreeBSD.org>
7060
7061 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
7062 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
7063 * NEWS: Mention new FreeBSD/aarch64 target.
7064 * configure.tgt: Add aarch64*-*-freebsd*.
7065 * aarch64-fbsd-tdep.c: New file.
7066 * aarch64-fbsd-tdep.h: New file.
7067
7610297a
KR
70682017-09-06 Kamil Rytarowski <n54@gmx.com>
7069
7070 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
7071
fbd1b771
JK
70722017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
7073
7074 * parse.c (find_minsym_type_and_address): Don't relocate addresses
7075 of TLS symbols.
7076
5ca79eae
PW
70772017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7078
7079 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
7080 call.
7081
bf93d7ba
SM
70822017-09-05 Simon Marchi <simon.marchi@ericsson.com>
7083
7084 * infrun.c (follow_exec): Call add_thread after
7085 target_find_description.
7086
1bb7c059
SM
70872017-09-05 Simon Marchi <simon.marchi@ericsson.com>
7088
7089 * infrun.c (handle_inferior_event_1): When exec'ing, read
7090 stop_pc after follow_exec.
7091
fc809827
SM
70922017-09-05 Simon Marchi <simon.marchi@ericsson.com>
7093
7094 * remote.c (process_g_packet): Update error message.
7095
d2fcdd85
YQ
70962017-09-05 Yao Qi <yao.qi@linaro.org>
7097
7098 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
7099 targets.
7100
e69570ee
PA
71012017-09-05 Pedro Alves <palves@redhat.com>
7102
7103 * eval.c (eval_call, evaluate_funcall): New functions, factored
7104 out from ...
7105 (evaluate_subexp_standard): ... this.
7106
22916b07
YQ
71072017-09-05 Yao Qi <yao.qi@linaro.org>
7108
7109 * amd64-tdep.c (amd64_target_description): Create target
7110 descriptions.
7111 (_initialize_amd64_tdep): Don't call functions
7112 initialize_tdesc_amd64_*. Add self tests.
7113 * arch/amd64.c (amd64_create_target_description): Add parameter
7114 is_linux. Call set_tdesc_osabi if is_linux is true.
7115 * arch/amd64.h (amd64_create_target_description): Update the
7116 declaration.
7117 * arch/i386.c (i386_create_target_description): Add parameter
7118 is_linux. Call set_tdesc_osabi if is_linux is true.
7119 * arch/i386.h (i386_create_target_description): Update
7120 declaration.
7121 * configure.tgt: Add i386.o to gdb_target_obs.
7122 * features/Makefile (XMLTOC): Remove i386/*.xml.
7123 * features/i386/amd64-avx-avx512.c: Remove.
7124 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
7125 * features/i386/amd64-avx-mpx.c: Remove.
7126 * features/i386/amd64-avx.c: Remove.
7127 * features/i386/amd64-mpx.c: Remove.
7128 * features/i386/amd64.c: Remove.
7129 * features/i386/i386-avx-avx512.c: Remove.
7130 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
7131 * features/i386/i386-avx-mpx.c: Remove.
7132 * features/i386/i386-avx.c: Remove.
7133 * features/i386/i386-mmx.c: Remove.
7134 * features/i386/i386-mpx.c: Remove.
7135 * features/i386/i386.c: Remove.
7136 * i386-tdep.c: Don't include features/i386/i386*.c., include
7137 target-descriptions.h and arch/i386.h.
7138 (i386_target_description): Create target descriptions.
7139 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
7140 functions. Do self tests.
7141
0854b7b1
YQ
71422017-09-05 Yao Qi <yao.qi@linaro.org>
7143
7144 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
7145 * features/i386/amd64-avx-avx512-linux.c: Removed.
7146 * features/i386/amd64-avx-linux.c: Removed.
7147 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
7148 * features/i386/amd64-avx-mpx-linux.c: Removed.
7149 * features/i386/amd64-linux.c: Removed.
7150 * features/i386/amd64-mpx-linux.c: Removed.
7151 * features/i386/x32-avx-avx512-linux.c: Removed.
7152 * features/i386/x32-avx-linux.c: Removed.
7153 * features/i386/x32-linux.c: Removed.
7154
b4570e4b
YQ
71552017-09-05 Yao Qi <yao.qi@linaro.org>
7156
7157 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
7158 features/i386/*.c.
7159 (amd64_linux_read_description): Call
7160 amd64_create_target_description.
7161 * arch/amd64.c: New file.
7162 * arch/amd64.h: New file.
7163 * configure.tgt (x86_64-*-linux*): Append amd64.o.
7164 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
7165
6c73f67f
YQ
71662017-09-05 Yao Qi <yao.qi@linaro.org>
7167
7168 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
7169 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
7170 (amd64_linux_read_description): Create target descriptions.
7171 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
7172 functions. Add unit tests.
7173 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
7174 x32-core.xml.
7175 * features/i386/64bit-avx.c: Generated.
7176 * features/i386/64bit-avx512.c: Generated.
7177 * features/i386/64bit-core.c: Generated.
7178 * features/i386/64bit-linux.c: Generated.
7179 * features/i386/64bit-mpx.c: Generated.
7180 * features/i386/64bit-pkeys.c: Generated.
7181 * features/i386/64bit-segments.c: Generated.
7182 * features/i386/64bit-sse.c: Generated.
7183 * features/i386/x32-core.c: Generated.
7184 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
7185 c files for amd64-linux and x32-linux.
7186
9d3d478b
YQ
71872017-09-05 Yao Qi <yao.qi@linaro.org>
7188
7189 * amd64-linux-tdep.c (amd64_linux_read_description): New
7190 function.
7191 (amd64_linux_core_read_description): Call
7192 amd64_linux_read_description.
7193 (amd64_linux_init_abi): Likewise.
7194 (amd64_x32_linux_init_abi): Likewise.
7195 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
7196 * x86-linux-nat.c (x86_linux_read_description): Call
7197 amd64_linux_read_description.
7198
b9f1d50f
YQ
71992017-09-05 Yao Qi <yao.qi@linaro.org>
7200
7201 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
7202 comments.
7203
188c9e6d
YQ
72042017-09-05 Yao Qi <yao.qi@linaro.org>
7205
7206 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
7207 * features/i386/i386-avx-avx512-linux.c: Remove.
7208 * features/i386/i386-avx-linux.c: Remove.
7209 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
7210 * features/i386/i386-avx-mpx-linux.c: Remove.
7211 * features/i386/i386-linux.c: Remove.
7212 * features/i386/i386-mmx-linux.c: Remove.
7213 * features/i386/i386-mpx-linux.c: Remove.
7214
5f035c07
YQ
72152017-09-05 Yao Qi <yao.qi@linaro.org>
7216
7217 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
7218 (SFILES): Add arch/i386.c.
7219 (HFILES_NO_SRCDIR): Add arch/i386.h.
7220 * arch/i386.c: New file.
7221 * arch/i386.h: New file.
7222 * arch/tdesc.h (allocate_target_description): Declare.
7223 (set_tdesc_architecture): Declare.
7224 (set_tdesc_osabi): Declare.
7225 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
7226 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
7227 include arch/i386.h.
7228 (i386_linux_read_description): Remove code and call
7229 i386_create_target_description.
7230 (set_tdesc_architecture): New function.
7231 (set_tdesc_osabi): New function.
7232 * target-descriptions.h (allocate_target_description): Remove.
7233
0abe8a89
YQ
72342017-09-05 Yao Qi <yao.qi@linaro.org>
7235
7236 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
7237 * target-descriptions.c (tdesc_create_feature): Likewise, and
7238 adjust code.
7239 * features/i386/32bit-avx.c: Re-generated.
7240 * features/i386/32bit-avx512.c: Re-generated.
7241 * features/i386/32bit-core.c: Re-generated.
7242 * features/i386/32bit-linux.c: Re-generated.
7243 * features/i386/32bit-mpx.c: Re-generated.
7244 * features/i386/32bit-pkeys.c: Re-generated.
7245 * features/i386/32bit-sse.c: Re-generated.
7246
0a188386
YQ
72472017-09-05 Yao Qi <yao.qi@linaro.org>
7248
7249 * regformats/regdef.h (struct reg): Override operator == and !=.
7250
f49ff000
YQ
72512017-09-05 Yao Qi <yao.qi@linaro.org>
7252
7253 * arch/tdesc.h: New file.
7254 * regformats/regdat.sh: Generate code using tdesc_create_reg.
7255 * target-descriptions.c: Update comments.
7256 * target-descriptions.h: Include "arch/tdesc.h". Remove the
7257 declarations.
7258 * features/i386/32bit-avx.c: Re-generated.
7259 * features/i386/32bit-avx512.c: Re-generated.
7260 * features/i386/32bit-core.c: Re-generated.
7261 * features/i386/32bit-linux.c: Re-generated.
7262 * features/i386/32bit-mpx.c: Re-generated.
7263 * features/i386/32bit-pkeys.c: Re-generated.
7264 * features/i386/32bit-sse.c: Re-generated.
7265
f7000548
YQ
72662017-09-05 Yao Qi <yao.qi@linaro.org>
7267
7268 * regformats/regdat.sh: Update generated code.
7269
c9a5e2a5
YQ
72702017-09-05 Yao Qi <yao.qi@linaro.org>
7271
7272 * regformats/regdat.sh: Adjust code order.
7273
d6b687ac
SM
72742017-09-05 Simon Marchi <simon.marchi@ericsson.com>
7275
7276 * expprint.c (dump_subexp_body_standard): Use constant format
7277 string in fprintf_filtered call.
7278
a379bfd0
JB
72792017-09-04 John Baldwin <jhb@FreeBSD.org>
7280
7281 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
7282 NetBSD/i386.
7283 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
7284
f7efc967
JB
72852017-09-04 John Baldwin <jhb@FreeBSD.org>
7286
7287 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
7288
c49fbc6c
JB
72892017-09-04 John Baldwin <jhb@FreeBSD.org>
7290
7291 * bsd-kvm.o: Define _KMEMUSER.
7292 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
7293 * configure: Regenerate.
7294
26562e73
JB
72952017-09-04 John Baldwin <jhb@FreeBSD.org>
7296
7297 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
7298 * i386-fbsd-nat.c: Likewise.
7299
31cf1487
JB
73002017-09-04 John Baldwin <jhb@FreeBSD.org>
7301
7302 * unittests/array-view-selftests.c: Add include of <array>.
7303
5b9f8a7c
JB
73042017-09-04 John Baldwin <jhb@FreeBSD.org>
7305
7306 * spu-tdep.c (flush_ea_cache): Add missing argument to
7307 call_function_by_hand.
7308
d69cf9b2
PA
73092017-09-04 Pedro Alves <palves@redhat.com>
7310
7311 * NEWS (Safer support for debugging with no debug info): New.
7312
3693fdb3
PA
73132017-09-04 Pedro Alves <palves@redhat.com>
7314
7315 * c-exp.y (function_method, function_method_void): Add current
7316 instance flags to TYPE_INSTANCE.
7317 * dwarf2read.c (check_modifier): New.
7318 (compute_delayed_physnames): Assert that only C++ adds delayed
7319 physnames. Mark fn_fields as const/volatile depending on
7320 physname.
7321 * eval.c (make_params): New type_instance_flags parameter. Use
7322 it as the new type's instance flags.
7323 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
7324 flags element and pass it to make_params.
7325 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
7326 instance flags element.
7327 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
7328 * gdbtypes.h: Include "enum-flags.h".
7329 (type_instance_flags): New enum-flags type.
7330 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
7331 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
7332 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
7333 (follow_type_instance_flags): New function.
7334 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
7335 * parser-defs.h (follow_type_instance_flags): Declare.
7336 * valops.c (value_struct_elt_for_reference): const/volatile must
7337 match too.
7338
e68cb8e0
PA
73392017-09-04 Pedro Alves <palves@redhat.com>
7340
7341 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
7342 function/method scopes; lookup the nested name as a function local
7343 static variable.
7344
858be34c
PA
73452017-09-04 Pedro Alves <palves@redhat.com>
7346
7347 (%type <voidval>): Add function_method.
7348 * c-exp.y (exp): New production for calls with no arguments.
7349 (function_method, function_method_void_or_typelist): New
7350 productions.
7351 (exp): New production for "method()::static_var".
7352 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
7353 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
7354 Handle OP_FUNC_STATIC_VAR.
7355 * parse.c (operator_length_standard):
7356 Handle OP_FUNC_STATIC_VAR.
7357
dd5901a6
PA
73582017-09-04 Pedro Alves <palves@redhat.com>
7359
7360 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
7361 handling.
7362 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
7363 Ditto.
7364 * parse.c (operator_length_standard, operator_check_standard):
7365 Ditto.
7366 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
7367
46a4882b
PA
73682017-09-04 Pedro Alves <palves@redhat.com>
7369
7370 * ax-gdb.c: Include "typeprint.h".
7371 (gen_expr_for_cast): New function.
7372 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
7373 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
7374 type is unknown.
7375 * dwarf2read.c (new_symbol_full): Fallback to int instead of
7376 nodebug_data_symbol.
7377 * eval.c: Include "typeprint.h".
7378 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
7379 Error out if symbol has unknown type.
7380 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
7381 evaluate_subexp_for_cast.
7382 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
7383 OP_VAR_MSYM_VALUE.
7384 (evaluate_subexp_for_cast): New function.
7385 * gdbtypes.c (init_nodebug_var_type): New function.
7386 (objfile_type): Use it to initialize types of variables with no
7387 debug info.
7388 * typeprint.c (error_unknown_type): New.
7389 * typeprint.h (error_unknown_type): New declaration.
7390 * compile/compile-c-types.c (convert_type_basic): Handle
7391 TYPE_CODE_ERROR; warn and fallback to int for variables with
7392 unknown type.
7393
fe13dfec
PA
73942017-09-04 Pedro Alves <palves@redhat.com>
7395
7396 * eval.c (evaluate_var_value): New function, factored out from ...
7397 (evaluate_subexp_standard): ... here.
7398
d008ee21
PA
73992017-09-04 Pedro Alves <palves@redhat.com>
7400
7401 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
7402 Remove useless assignments to 'op'.
7403
827d0c51
PA
74042017-09-04 Pedro Alves <palves@redhat.com>
7405
7406 * eval.c (eval_skip_value): New function.
7407 (evaluate_subexp_standard): Use it.
7408
2c5a2be1
PA
74092017-09-04 Pedro Alves <palves@redhat.com>
7410
7411 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
7412 function name from symbol/minsym and pass it to
7413 error_call_unknown_return_type.
7414
74ea4be4
PA
74152017-09-04 Pedro Alves <palves@redhat.com>
7416
7417 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
7418 * ax-gdb.c (gen_msym_var_ref): New function.
7419 (gen_expr): Handle OP_VAR_MSYM_VALUE.
7420 * eval.c (evaluate_var_msym_value): New function.
7421 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
7422 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
7423 to call_function_by_hand.
7424 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
7425 Handle OP_VAR_MSYM_VALUE.
7426 (union exp_element) <msymbol>: New field.
7427 * minsyms.h (struct type): Forward declare.
7428 (find_minsym_type_and_address): Declare.
7429 * parse.c (write_exp_elt_msym): New function.
7430 (write_exp_msymbol): Delete, refactored as ...
7431 (find_minsym_type_and_address): ... this new function.
7432 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
7433 (operator_length_standard, operator_check_standard): Handle
7434 OP_VAR_MSYM_VALUE.
7435 * std-operator.def (OP_VAR_MSYM_VALUE): New.
7436
7022349d
PA
74372017-09-04 Pedro Alves <palves@redhat.com>
7438
7439 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
7440 TYPE_GNU_IFUNC specially here. Throw error if return type is
7441 unknown.
7442 * ada-typeprint.c (print_func_type): Handle functions with unknown
7443 return type.
7444 * c-typeprint.c (c_type_print_base): Handle functions and methods
7445 with unknown return type.
7446 * compile/compile-c-symbols.c (convert_symbol_bmsym)
7447 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
7448 * compile/compile-c-types.c: Include "objfiles.h".
7449 (convert_func): For functions with unknown return type, warn and
7450 default to int.
7451 * compile/compile-object-run.c (compile_object_run): Adjust call
7452 to call_function_by_hand_dummy.
7453 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
7454 call_function_by_hand.
7455 * eval.c (evaluate_subexp_standard): Adjust calls to
7456 call_function_by_hand. Handle functions and methods with unknown
7457 return type. Pass expect_type to call_function_by_hand.
7458 * f-typeprint.c (f_type_print_base): Handle functions with unknown
7459 return type.
7460 * gcore.c (call_target_sbrk): Adjust call to
7461 call_function_by_hand.
7462 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
7463 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
7464 an integer address type instead of nodebug.
7465 * guile/scm-value.c (gdbscm_value_call): Adjust call to
7466 call_function_by_hand.
7467 * infcall.c (error_call_unknown_return_type): New function.
7468 (call_function_by_hand): New "default_return_type" parameter.
7469 Pass it down.
7470 (call_function_by_hand_dummy): New "default_return_type"
7471 parameter. Use it instead of defaulting to int. If there's no
7472 default and the return type is unknown, throw an error. If
7473 there's a default return type, and the called function has no
7474 debug info, then assume the function is prototyped.
7475 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
7476 New "default_return_type" parameter.
7477 (error_call_unknown_return_type): New declaration.
7478 * linux-fork.c (call_lseek): Cast return type of lseek.
7479 (inferior_call_waitpid, checkpoint_command): Adjust calls to
7480 call_function_by_hand.
7481 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
7482 calls to call_function_by_hand.
7483 * m2-typeprint.c (m2_procedure): Handle functions with unknown
7484 return type.
7485 * objc-lang.c (lookup_objc_class, lookup_child_selector)
7486 (value_nsstring, print_object_command): Adjust calls to
7487 call_function_by_hand.
7488 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
7489 functions with unknown return type.
7490 (pascal_type_print_func_varspec_suffix): New function.
7491 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
7492 TYPE_CODE_METHOD>: Use it.
7493 * python/py-value.c (valpy_call): Adjust call to
7494 call_function_by_hand.
7495 * rust-lang.c (rust_evaluate_funcall): Adjust call to
7496 call_function_by_hand.
7497 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
7498 call_function_by_hand.
7499 * valops.c (value_allocate_space_in_inferior): Adjust call to
7500 call_function_by_hand.
7501 * typeprint.c (type_print_unknown_return_type): New function.
7502 * typeprint.h (type_print_unknown_return_type): New declaration.
7503
54990598
PA
75042017-09-04 Pedro Alves <palves@redhat.com>
7505
7506 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
7507 types with more than one parameter as prototyped.
7508
9a24775b
PA
75092017-09-04 Pedro Alves <palves@redhat.com>
7510
7511 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
7512 (disassemble_command): Use gdb_disassembly_flags instead of bare
7513 int.
7514 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
7515 (dump_insns, do_mixed_source_and_assembly_deprecated)
7516 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
7517 Use gdb_disassembly_flags instead of bare int.
7518 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
7519 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
7520 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
7521 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
7522 (enum gdb_disassembly_flag): ... values of this new enumeration.
7523 (gdb_disassembly_flags): Define.
7524 (gdb_disassembly)
7525 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
7526 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
7527 gdb_disassembly_flags instead of bare int.
7528 * record-btrace.c (btrace_insn_history)
7529 (record_btrace_insn_history, record_btrace_insn_history_range)
7530 (record_btrace_insn_history_from): Use gdb_disassembly_flags
7531 instead of bare int.
7532 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
7533 Use gdb_disassembly_flags instead of bare int.
7534 * target-debug.h (target_debug_print_gdb_disassembly_flags):
7535 Define.
7536 * target-delegates.c: Regenerate.
7537 * target.c (target_insn_history, target_insn_history_from)
7538 (target_insn_history_range): Use gdb_disassembly_flags instead of
7539 bare int.
7540 * target.h: Include "disasm.h".
7541 (struct target_ops) <to_insn_history, to_insn_history_from,
7542 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
7543 int.
7544 (target_insn_history, target_insn_history_from)
7545 (target_insn_history_range): Use gdb_disassembly_flags instead of
7546 bare int.
7547
80a65e9b
SM
75482017-09-04 Simon Marchi <simon.marchi@ericsson.com>
7549
7550 * cli/cli-script.c (build_command_line): For if/while commands,
7551 check whether args is empty.
7552
6b66338c
SM
75532017-09-04 Simon Marchi <simon.marchi@ericsson.com>
7554
7555 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
7556 (enum command_control_type): Likewise.
7557 (struct command_line): Likewise.
7558 (free_command_lines): Likewise.
7559 (struct command_lines_deleter): Likewise.
7560 (command_line_up): Likewise.
7561 (read_command_lines): Likewise.
7562 (read_command_lines_1): Likewise.
7563 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
7564 (enum command_control_type): Likewise.
7565 (struct command_line): Likewise.
7566 (free_command_lines): Likewise.
7567 (struct command_lines_deleter): Likewise.
7568 (command_line_up): Likewise.
7569 (read_command_lines): Likewise.
7570 (read_command_lines_1): Likewise.
7571 * breakpoint.h: Include cli/cli-script.h.
7572 * extension-priv.h: Likewise.
7573 * gdbcmd.h: Likewise.
7574
51abb421
PA
75752017-09-04 Pedro Alves <palves@redhat.com>
7576
7577 * ada-lang.c (is_known_support_routine): Move sal declaration to
7578 where it is initialized.
7579 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
7580 (parse_breakpoint_sals, decode_static_tracepoint_spec)
7581 (clear_command, update_static_tracepoint): Remove init_sal
7582 references. Move declarations closer to initializations.
7583 * cli/cli-cmds.c (list_command): Move sal declarations closer to
7584 initializations.
7585 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
7586 references. Move sal declarations closer to initializations.
7587 * frame.c (find_frame_sal): Return a symtab_and_line via function
7588 return instead of output parameter. Remove init_sal references.
7589 * frame.h (find_frame_sal): Return a symtab_and_line via function
7590 return instead of output parameter.
7591 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
7592 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
7593 instead of memset.
7594 (gdbscm_find_pc_line): Remove init_sal reference.
7595 * infcall.c (call_function_by_hand_dummy): Remove init_sal
7596 references. Move declarations closer to initializations.
7597 * infcmd.c (set_step_frame): Update. Move declarations closer to
7598 initializations.
7599 (finish_backward): Remove init_sal references. Move declarations
7600 closer to initializations.
7601 * infrun.c (process_event_stop_test, handle_step_into_function)
7602 (insert_hp_step_resume_breakpoint_at_frame)
7603 (insert_step_resume_breakpoint_at_caller): Likewise.
7604 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
7605 (symbol_to_sal): Likewise.
7606 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
7607 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
7608 to its initialization.
7609 * reverse.c (save_bookmark_command): Use new/delete. Remove
7610 init_sal references. Move declarations closer to initializations.
7611 * source.c (get_current_source_symtab_and_line): Remove brace
7612 initialization.
7613 (set_current_source_symtab_and_line): Now takes the sal by const
7614 reference. Remove brace initialization.
7615 (line_info): Remove init_sal reference.
7616 * source.h (set_current_source_symtab_and_line): Now takes a
7617 symtab_and_line via const reference.
7618 * stack.c (set_current_sal_from_frame): Adjust.
7619 (print_frame_info): Adjust.
7620 (get_last_displayed_sal): Return the sal via function return
7621 instead of via output parameter. Simplify.
7622 (frame_info): Adjust.
7623 * stack.h (get_last_displayed_sal): Return the sal via function
7624 return instead of via output parameter.
7625 * symtab.c (init_sal): Delete.
7626 (find_pc_sect_line): Remove init_sal references. Move
7627 declarations closer to initializations.
7628 (find_function_start_sal): Remove init_sal references. Move
7629 declarations closer to initializations.
7630 * symtab.h (struct symtab_and_line): In-class initialize all
7631 fields.
7632 * tracepoint.c (set_traceframe_context)
7633 (print_one_static_tracepoint_marker): Remove init_sal references.
7634 Move declarations closer to initializations.
7635 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
7636 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
7637 declarations closer to initializations.
7638 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
7639 init_sal references. Adjust.
7640
6c5b2ebe
PA
76412017-09-04 Pedro Alves <palves@redhat.com>
7642
7643 * ax-gdb.c (agent_command_1): Use range-for.
7644 * break-catch-throw.c (re_set_exception_catchpoint): Update.
7645 * breakpoint.c: Include "common/array-view.h".
7646 (init_breakpoint_sal, create_breakpoint_sal): Change sals
7647 parameter from struct symtabs_and_lines to
7648 array_view<symtab_and_line>. Adjust. Use range-for. Update.
7649 (breakpoint_sals_to_pc): Change sals parameter from struct
7650 symtabs_and_lines to std::vector reference.
7651 (check_fast_tracepoint_sals): Change sals parameter from struct
7652 symtabs_and_lines to std::array_view. Use range-for.
7653 (decode_static_tracepoint_spec): Return a std::vector instead of
7654 symtabs_and_lines. Update.
7655 (create_breakpoint): Update.
7656 (break_range_command, until_break_command, clear_command): Update.
7657 (base_breakpoint_decode_location, bkpt_decode_location)
7658 (bkpt_probe_create_sals_from_location)
7659 (bkpt_probe_decode_location, tracepoint_decode_location)
7660 (tracepoint_probe_decode_location)
7661 (strace_marker_create_sals_from_location): Return a std::vector
7662 instead of symtabs_and_lines.
7663 (strace_marker_create_breakpoints_sal): Update.
7664 (strace_marker_decode_location): Return a std::vector instead of
7665 symtabs_and_lines. Update.
7666 (update_breakpoint_locations): Change struct symtabs_and_lines
7667 parameters to gdb::array_view. Adjust.
7668 (location_to_sals): Return a std::vector instead of
7669 symtabs_and_lines. Update.
7670 (breakpoint_re_set_default): Use std::vector instead of struct
7671 symtabs_and_lines.
7672 (decode_location_default): Return a std::vector instead of
7673 symtabs_and_lines. Update.
7674 * breakpoint.h: Include "common/array-view.h".
7675 (struct breakpoint_ops) <decode_location>: Now returns a
7676 std::vector instead of returning a symtabs_and_lines via output
7677 parameter.
7678 (update_breakpoint_locations): Change sals parameters to use
7679 gdb::array_view.
7680 * cli/cli-cmds.c (edit_command, list_command): Update to use
7681 std::vector and gdb::array_view.
7682 (ambiguous_line_spec): Adjust to use gdb::array_view and
7683 range-for.
7684 (compare_symtabs): Rename to ...
7685 (cmp_symtabs): ... this. Change parameters to symtab_and_line
7686 const reference and adjust.
7687 (filter_sals): Rewrite using std::vector and standard algorithms.
7688 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
7689 (jump_command): Update to use std::vector.
7690 * linespec.c (struct linespec_state) <canonical_names>: Update
7691 comment.
7692 (add_sal_to_sals_basic): Delete.
7693 (add_sal_to_sals, filter_results, convert_results_to_lsals)
7694 (decode_line_2, create_sals_line_offset)
7695 (convert_address_location_to_sals, convert_linespec_to_sals)
7696 (convert_explicit_location_to_sals, parse_linespec)
7697 (event_location_to_sals, decode_line_full, decode_line_1)
7698 (decode_line_with_current_source)
7699 (decode_line_with_last_displayed, decode_objc)
7700 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
7701 (linespec_result::~linespec_result): Adjust to use std::vector
7702 instead of symtabs_and_lines.
7703 * linespec.h (linespec_sals::sals): Now a std::vector.
7704 (struct linespec_result): Use std::vector, bool, and in-class
7705 initialization.
7706 (decode_line_1, decode_line_with_current_source)
7707 (decode_line_with_last_displayed): Return std::vector.
7708 * macrocmd.c (info_macros_command): Use std::vector.
7709 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
7710 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
7711 std::vector.
7712 * probe.h (parse_probes): Return a std::vector.
7713 * python/python.c (gdbpy_decode_line): Use std::vector and
7714 gdb::array_view.
7715 * source.c (select_source_symtab, line_info): Use std::vector.
7716 * stack.c (func_command): Use std::vector.
7717 * symtab.h (struct symtabs_and_lines): Delete.
7718 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
7719
7c44b49c
PA
77202017-09-04 Pedro Alves <palves@redhat.com>
7721
7722 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7723 unittests/array-view-selftests.c.
7724 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
7725 * common/array-view.h: New file.
7726 * unittests/array-view-selftests.c: New file.
7727
e439fa14
PA
77282017-09-04 Pedro Alves <palves@redhat.com>
7729
7730 * cli/cli-cmds.c (edit_command): Pass message to
7731 ambiguous_line_spec.
7732 (list_command): Pass message to ambiguous_line_spec. Say
7733 "first"/"last" instead of "start" and "end" to be consistent with
7734 the manual.
7735 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
7736 them to print formatted message.
7737
7525b645
PA
77382017-09-04 Pedro Alves <palves@redhat.com>
7739
7740 * btrace.c (ftrace_add_pt): Pass btrace_insn to
7741 ftrace_update_insns by reference instead of pointer.
7742
badc0020
YQ
77432017-09-04 Yao Qi <yao.qi@linaro.org>
7744
7745 * i386-go32-tdep.c: Include x86-xstate.h.
7746 (i386_go32_init_abi): Call i386_target_description.
7747 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
7748 if xcr0 is X86_XSTATE_X87_MASK.
7749 * i386-tdep.h (tdesc_i386): Remove the declaration.
7750 (tdesc_i386_mmx): Likewise.
7751
d78bdb54
YQ
77522017-09-04 Yao Qi <yao.qi@linaro.org>
7753
7754 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
7755 X86_XSTATE_SSE_MASK instead of 0.
7756
ca1fa5ee
YQ
77572017-09-04 Yao Qi <yao.qi@linaro.org>
7758
7759 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
7760 i386_target_description.
7761 * i386-fbsd-nat.c (i386fbsd_read_description): Call
7762 i386_target_description.
7763 * i386-tdep.c (i386_gdbarch_init): Likewise.
7764
2434b019
YQ
77652017-09-04 Yao Qi <yao.qi@linaro.org>
7766
7767 * amd64-darwin-tdep.c: Include "x86-xstate.h".
7768 (x86_darwin_init_abi_64): Call amd64_target_description.
7769 * amd64-dicos-tdep.c: Likewise.
7770 * amd64-fbsd-nat.c: Likewise.
7771 * amd64-fbsd-tdep.c: Likewise.
7772 * amd64-nbsd-tdep.c: Likewise.
7773 * amd64-obsd-tdep.c: Likewise.
7774 * amd64-sol2-tdep.c: Likewise.
7775 * amd64-windows-tdep.c: Likewise.
7776 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
7777
0860c437
SM
77782017-09-04 Simon Marchi <simon.marchi@ericsson.com>
7779
7780 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
7781 (btrace_function) <insn>: Change type to use std::vector.
7782 * btrace.c (ftrace_debug, ftrace_call_num_insn,
7783 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
7784 ftrace_update_insns, ftrace_compute_global_level_offset,
7785 btrace_stitch_bts, btrace_clear, btrace_insn_get,
7786 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
7787 change to std::vector.
7788 (ftrace_update_insns): Adjust to change to std::vector, change
7789 type of INSN parameter.
7790 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
7791 * record-btrace.c (btrace_call_history_insn_range,
7792 btrace_compute_src_line_range,
7793 record_btrace_frame_prev_register): Adjust to change to
7794 std::vector.
7795 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
7796 to change to std::vector.
7797
0638b7f9
TT
77982017-09-03 Tom Tromey <tom@tromey.com>
7799
7800 * corefile.c (reopen_exec_file): Use std::string.
7801
8f84fb0e
TT
78022017-09-03 Tom Tromey <tom@tromey.com>
7803
7804 * compile/compile.c (compile_register_name_mangled): Return
7805 std::string.
7806 * compile/compile-loc2c.c (pushf_register_address): Update.
7807 (pushf_register): Update.
7808 * compile/compile-c-types.c (convert_array): Update.
7809 * compile/compile-c-symbols.c (generate_vla_size): Update.
7810 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
7811 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
7812 (convert_one_symbol): Update.
7813 (generate_c_for_for_one_variable): Update.
7814 * compile/compile-c-support.c (c_get_range_decl_name): Return a
7815 std::string.
7816 (generate_register_struct): Update.
7817 * compile/compile-internal.h (c_get_range_decl_name): Return a
7818 std::string.
7819 (compile_register_name_mangled): Return std::string.
7820
18e9961f
TT
78212017-09-03 Tom Tromey <tom@tromey.com>
7822
7823 * utils.c (perror_string): Return a std::string.
7824 (throw_perror_with_name, perror_warning_with_name): Update.
7825
45343786
TT
78262017-09-03 Tom Tromey <tom@tromey.com>
7827
7828 * demangle.c (demangle_command): Use std::string,
7829 unique_xmalloc_ptr.
7830
b57af503
TT
78312017-09-03 Tom Tromey <tom@tromey.com>
7832
7833 * cli/cli-setshow.c (do_set_command): Use std::string.
7834
6eecf35f
TT
78352017-09-03 Tom Tromey <tom@tromey.com>
7836
7837 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
7838
56496dd4
TT
78392017-09-03 Tom Tromey <tom@tromey.com>
7840
7841 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
7842
e91a1fa7
TT
78432017-09-03 Tom Tromey <tom@tromey.com>
7844
7845 * mi/mi-cmd-env.c (env_execute_cli_command): Use
7846 gdb::unique_xmalloc_ptr.
7847
7ffd83d7
TT
78482017-09-03 Tom Tromey <tom@tromey.com>
7849
7850 * thread.c (print_thread_info_1): Use string_printf.
7851 (thread_apply_command, thread_apply_all_command): Use
7852 std::string.
7853
1ccbe998
TT
78542017-09-03 Tom Tromey <tom@tromey.com>
7855
7856 * valprint.c (val_print_string): Update.
7857 * gdbcore.h (memory_error_message): Return std::string.
7858 * corefile.c (memory_error_message): Return std::string.
7859 (memory_error): Update.
7860 * breakpoint.c (insert_bp_location): Update.
7861
23fdd69e
SM
78622017-09-03 Simon Marchi <simon.marchi@ericsson.com>
7863
7864 * target/waitstatus.h (target_waitstatus_to_string): Change
7865 return type to std::string.
7866 * target/waitstatus.c (target_waitstatus_to_string): Return
7867 std::string.
7868 * target.h (target_waitstatus_to_string): Remove declaration.
7869 * infrun.c (resume, clear_proceed_status_thread,
7870 print_target_wait_results, do_target_wait, save_waitstatus,
7871 stop_all_threads): Adjust.
7872 * record-btrace.c (record_btrace_wait): Adjust.
7873 * target-debug.h
7874 (target_debug_print_struct_target_waitstatus_p): Adjust.
7875
5c811d30
JK
78762017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
7877
7878 PR gdb/22046
7879 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
7880 detection.
7881
0a2dde4a
SDJ
78822017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
7883
7884 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
7885 for setting/unsetting environment variables on the remote target.
7886 (New remote packets): Add entries for QEnvironmentHexEncoded,
7887 QEnvironmentUnset and QEnvironmentReset.
7888 * common/environ.c (gdb_environ::operator=): Extend method to
7889 handle m_user_set_env_list and m_user_unset_env_list.
7890 (gdb_environ::clear): Likewise.
7891 (match_var_in_string): Change type of first parameter from 'char
7892 *' to 'const char *'.
7893 (gdb_environ::set): Extend method to handle
7894 m_user_set_env_list and m_user_unset_env_list.
7895 (gdb_environ::unset): Likewise.
7896 (gdb_environ::clear_user_set_env): New method.
7897 (gdb_environ::user_set_envp): Likewise.
7898 (gdb_environ::user_unset_envp): Likewise.
7899 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
7900 m_user_unset_env_list on move constructor/assignment.
7901 (unset): Add new default parameter 'update_unset_list = true'.
7902 (clear_user_set_env): New method.
7903 (user_set_envp): Likewise.
7904 (user_unset_envp): Likewise.
7905 (m_user_set_env_list): New std::set.
7906 (m_user_unset_env_list): Likewise.
7907 * common/rsp-low.c (hex2str): New function.
7908 (bin2hex): New overload for bin2hex function.
7909 * common/rsp-low.c (hex2str): New prototype.
7910 (str2hex): New overload prototype.
7911 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
7912 QEnvironmentUnset and QEnvironmentReset.
7913 (remote_protocol_features): Add QEnvironmentHexEncoded,
7914 QEnvironmentUnset and QEnvironmentReset packets.
7915 (send_environment_packet): New function.
7916 (extended_remote_environment_support): Likewise.
7917 (extended_remote_create_inferior): Call
7918 extended_remote_environment_support.
7919 (_initialize_remote): Add QEnvironmentHexEncoded,
7920 QEnvironmentUnset and QEnvironmentReset packet configs.
7921 * unittests/environ-selftests.c (gdb_selftest_env_var):
7922 New variable.
7923 (test_vector_initialization): New function.
7924 (test_init_from_host_environ): Likewise.
7925 (test_reinit_from_host_environ): Likewise.
7926 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
7927 Likewise.
7928 (test_unset_set_empty_vector): Likewise.
7929 (test_vector_clear): Likewise.
7930 (test_std_move): Likewise.
7931 (test_move_constructor):
7932 (test_self_move): Likewise.
7933 (test_set_unset_reset): Likewise.
7934 (run_tests): Rewrite in terms of the functions above.
7935
654670a4
WP
79362017-08-31 Weimin Pan <weimin.pan@oracle.com>
7937
7938 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
7939 (adi_available): Use a temp variable of type CORE_ADDR as argument
7940 3 when calling target_auxv_search.
7941 (adi_normalize_address): Use masks and xor operators to calculate
7942 normalized address.
7943 (adi_read_versions, adi_write_versions, adi_print_versions)
7944 (do_examine, do_assign): Use paddress.
7945
7755ddb7
JB
79462017-08-29 John Baldwin <jhb@FreeBSD.org>
7947
7948 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
7949 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
7950 out of loop and add supply of FIR.
7951 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
7952 add collect of FIR.
7953
fd437cbc
SM
79542017-08-28 Simon Marchi <simon.marchi@ericsson.com>
7955
3804a343 7956 PR gdb/21827
fd437cbc
SM
7957 * cli/cli-script.c (define_command): Don't convert command name
7958 to lower case.
7959
988f6b3d
JB
79602017-08-25 Joel Brobecker <brobecker@adacore.com>
7961
7962 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
7963 Update all callers accordingly. Remove all code blocks handling
7964 the case where DISPP is not NULL.
7965
663c44ac
JK
79662017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
7967
7968 PR symtab/22003
7969 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
7970 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
7971 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
7972
f1902523
JK
79732017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
7974
7975 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
7976 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
7977 (read_comp_units_from_section): New parameter abbrev_section, use
7978 read_and_check_comp_unit_head, allocate signatured_type if needed.
7979 (create_all_comp_units): Update read_comp_units_from_section caller.
7980
87215ad1
SDJ
79812017-08-23 Pedro Alves <palves@redhat.com>
7982
7983 PR remote/21852
7984 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
7985 to null_ptid and switch to thread without reading the registers
7986 after adding the inferior.
7987
6e41ddec
JK
79882017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
7989
7990 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
7991 compile-gcc.
7992 * compile/compile.c (compile_gcc, show_compile_gcc): New.
7993 (compile_to_object): Implement compile_gcc.
7994 (_initialize_compile): Install "set compile-gcc". Initialize
7995 compile_gcc.
7996
e68c32d5
JK
79972017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
7998
7999 * compile/compile.c (compile_to_object): Conditionally call
8000 set_verbose. Conditionally call compile or compile_v0.
8001
58afddc6
WP
80022017-08-07 Weimin Pan <weimin.pan@oracle.com>
8003
8004 * sparc64-tdep.h: (adi_normalize_address): New export.
8005 * sparc-nat.h: (open_adi_tag_fd): New export.
8006 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
8007 * sparc64-linux-tdep.c:
8008 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
8009 (sparc64_linux_handle_segmentation_fault): New function.
8010 (sparc64_linux_init_abi): Register
8011 sparc64_linux_handle_segmentation_fault
8012 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
8013 (sparc64_addr_bits_remove): New function.
8014 (sparc64_init_abi): Register sparc64_addr_bits_remove.
8015 (MAX_PROC_NAME_SIZE): New macro.
8016 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
8017 (sparc64adilist): New variable.
8018 (adi_proc_list): New variable.
8019 (find_adi_info): New function.
8020 (add_adi_info): New function.
8021 (get_adi_info_proc): New function.
8022 (get_adi_info): New function.
8023 (info_adi_command): New function.
8024 (read_maps_entry): New function.
8025 (adi_available): New function.
8026 (adi_normalize_address): New function.
8027 (adi_align_address): New function.
8028 (adi_convert_byte_count): New function.
8029 (adi_tag_fd): New function.
8030 (adi_is_addr_mapped): New function.
8031 (adi_read_versions): New function.
8032 (adi_write_versions): New function.
8033 (adi_print_versions): New function.
8034 (do_examine): New function.
8035 (do_assign): New function.
8036 (adi_examine_command): New function.
8037 (adi_assign_command): New function.
8038 (_initialize_sparc64_adi_tdep): New function.
8039
11db9430
SM
80402017-08-22 Simon Marchi <simon.marchi@ericsson.com>
8041
8042 * breakpoint.c (breakpoints_info): Rename to ...
8043 (info_breakpoints_command): ... this.
8044 (watchpoints_info): Rename to ...
8045 (info_watchpoints_command): ... this.
8046 (tracepoints_info): Rename to ...
8047 (info_tracepoints_command): ... this.
8048 (_initialize_breakpoint): Adjust.
8049 * dcache.c (dcache_info): Rename to ...
8050 (info_display_command): ... this.
8051 (_initialize_dcache): Adjust.
8052 * frame.h (args_info): Rename to ...
8053 (info_args_command): ... this.
8054 (locals_info): Rename to ...
8055 (info_locals_command): ... this.
8056 * infcmd.c (nofp_registers_info): Rename to ...
8057 (info_registers_command): ... this.
8058 (float_info): Rename to ...
8059 (info_float_command): ... this.
8060 (program_info): Rename to ...
8061 (info_program_command): ... this.
8062 (all_registers_info): Rename to ...
8063 (info_all_registers_command): ... this.
8064 (vector_info): Rename to ...
8065 (info_vector_command): ... this.
8066 (float_info): Rename to ...
8067 (info_float_command): ... this.
8068 (_initialize_infcmd): Adjust.
8069 * inferior.h (term_info): Rename to ...
8070 (info_terminal_command): ... this.
8071 * inflow.c (term_info): Rename to ...
8072 (info_terminal_command): ... this.
8073 (_initialize_inflow): Adjust.
8074 * infrun.c (signals_info): Rename to ...
8075 (info_signals_command): ... this.
8076 (_initialize_infrun): Adjust.
8077 * objc-lang.c (classes_info): Rename to ...
8078 (info_classes_command): ... this.
8079 (selectors_info): Rename to ...
8080 (info_selectors_command): ... this.
8081 (_initialize_objc_language): Adjust.
8082 * printcmd.c (sym_info): Rename to ...
8083 (info_symbol_command): ... this.
8084 (address_info): Rename to ...
8085 (info_address_command): ... this.
8086 (display_info): Rename to ...
8087 (info_display_command): ... this.
8088 (_initialize_printcmd): Adjust.
8089 * reverse.c (bookmarks_info): Rename to ...
8090 (info_breakpoints_command): ... this.
8091 (_initialize_reverse): Adjust.
8092 * ser-go32.c (dos_info): Rename to ...
8093 (info_serial_command): ... this.
8094 (_initialize_ser_dos): Adjust.
8095 * skip.c (skip_info): Rename to ...
8096 (info_skip_command): ... this.
8097 (_initialize_step_skip): Adjust.
8098 * source.c (line_info): Rename to ...
8099 (info_line_command): ... this.
8100 (source_info): Rename to ...
8101 (info_source_command)
8102 * stack.c (frame_info): Rename to ...
8103 (info_frame_command): ... this.
8104 (locals_info): Rename to ...
8105 (info_locals_command): ... this.
8106 (args_info): Rename to ...
8107 (info_args_command): ... this.
8108 (_initialize_stack): Adjust.
8109 * symtab.c (sources_info): Rename to ...
8110 (info_sources_command): ... this.
8111 (variables_info): Rename to ...
8112 (info_variables_command): ... this.
8113 (functions_info): Rename to ...
8114 (info_functions_command): ... this.
8115 (types_info): Rename to ...
8116 (info_types_command): ... this.
8117 (_initialize_symtab): Adjust.
8118 * target.c (target_info): Rename to ...
8119 (info_target_command): ... this.
8120 (initialize_targets): Adjust.
8121 * tracepoint.c (tvariables_info): Rename to ...
8122 (info_tvariables_command): ... this.
8123 (scope_info): Rename to ...
8124 (info_scope_command): ... this.
8125 (trace_dump_actions): Adjust.
8126 (_initialize_tracepoint): Adjust.
8127
b270e6f9
TT
81282017-08-22 Tom Tromey <tom@tromey.com>
8129
8130 * breakpoint.h (install_breakpoint): Update.
8131 * breakpoint.c (add_solib_catchpoint): Update.
8132 (install_breakpoint): Change argument to a std::unique_ptr.
8133 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
8134 (create_breakpoint_sal, create_breakpoint): Update.
8135 (watch_command_1, catch_exec_command_1)
8136 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
8137 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
8138 Return the breakpoint.
8139 (set_raw_breakpoint_without_location, set_raw_breakpoint)
8140 (new_single_step_breakpoint): Update.
8141 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
8142 std::unique_ptr.
8143 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
8144 std::unique_ptr.
8145 * break-catch-sig.c (create_signal_catchpoint): Use
8146 std::unique_ptr.
8147 * ada-lang.c (create_ada_exception_catchpoint): Use
8148 std::unique_ptr.
8149
36bd8eaa
TT
81502017-08-22 Tom Tromey <tom@tromey.com>
8151
8152 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
8153
56f37645
TT
81542017-08-22 Tom Tromey <tom@tromey.com>
8155
8156 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
8157 (lookup_partial_symbol): Update.
8158
0b581c69
TT
81592017-08-22 Tom Tromey <tom@tromey.com>
8160
8161 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
8162 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
8163 (find_and_open_source, symtab_to_fullname): Update.
8164 * psymtab.c (psymtab_to_fullname): Update.
8165
14278e1f
TT
81662017-08-22 Tom Tromey <tom@tromey.com>
8167
8168 * exec.c (exec_file_attach): Update.
8169 * linux-thread-db.c (try_thread_db_load): Update.
8170 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
8171 * utils.c (gdb_realpath): Change return type.
8172 (gdb_realpath_keepfile): Update.
8173 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
8174 (_initialize_utils): Register the new self test.
8175 * source.c (openp): Update.
8176 (find_and_open_source): Update.
8177 * nto-tdep.c (nto_find_and_open_solib): Update.
8178 * main.c (set_gdb_data_directory): Update.
8179 (captured_main_1): Update.
8180 * dwarf2read.c (dwarf2_get_dwz_file): Update
8181 (dw2_map_symbol_filenames): Update.
8182 * auto-load.c (auto_load_safe_path_vec_update): Update.
8183 (filename_is_in_auto_load_safe_path_vec): Change type of
8184 "filename_realp".
8185 (auto_load_objfile_script): Update.
8186 (file_is_auto_load_safe): Update. Use std::string.
8187 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
8188
4971c9a7
TT
81892017-08-22 Tom Tromey <tom@tromey.com>
8190
8191 * utils.c (gdb_realpath_keepfile): Return a
8192 gdb::unique_xmalloc_ptr.
8193 * exec.c (exec_file_attach): Update.
8194 * utils.h (gdb_realpath_keepfile): Return a
8195 gdb::unique_xmalloc_ptr.
8196
e3e41d58
TT
81972017-08-22 Tom Tromey <tom@tromey.com>
8198
8199 * compile/compile.c (compile_file_command): Use
8200 gdb::unique_xmalloc_ptr, std::string.
8201 * utils.c (gdb_abspath): Change return type.
8202 * source.c (openp): Update.
8203 * objfiles.c (allocate_objfile): Update.
8204 * main.c (set_gdb_data_directory): Update.
8205 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
8206
0d999a6e
ZZ
82072017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
8208
8209 * cli-cmds.c (list_commands): List actual code around more than
8210 one location.
8211
329d5e7e
JB
82122017-08-21 John Baldwin <jhb@FreeBSD.org>
8213
8214 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
8215
bf223d3e
PA
82162017-08-21 Pedro Alves <palves@redhat.com>
8217
8218 PR gdb/19487
8219 * c-exp.y (variable production): Handle function aliases.
8220 * minsyms.c (msymbol_is_text): New function.
8221 * minsyms.h (msymbol_is_text): Declare.
8222 * symtab.c (find_function_alias_target): New function.
8223 * symtab.h (find_function_alias_target): Declare.
8224
c973d0aa
PA
82252017-08-21 Pedro Alves <palves@redhat.com>
8226
8227 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
8228 typedefs.
8229 * typeprint.c (whatis_exp): If handling "whatis", and expression
8230 is OP_TYPE, strip one typedef level. Otherwise don't strip
8231 typedefs here.
8232 * valops.c (value_cast): Save "to" type before resolving
8233 stubs/typedefs. Use that type as resulting value's type.
8234
2989a365
TT
82352017-08-18 Tom Tromey <tom@tromey.com>
8236 Pedro Alves <palves@redhat.com>
8237
8238 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
8239 * sol-thread.c (sol_thread_resume, sol_thread_wait)
8240 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
8241 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
8242 * proc-service.c (ps_xfer_memory): Use scoped_restore.
8243 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
8244 (linux_get_siginfo_data): Add "thread" argument. Use
8245 scoped_restore.
8246 * linux-nat.c (linux_child_follow_fork)
8247 (check_stopped_by_watchpoint): Use scoped_restore.
8248 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
8249 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
8250 (restore_inferior_ptid, save_inferior_ptid): Remove.
8251 * btrace.c (btrace_fetch): Use scoped_restore.
8252 * bsd-uthread.c (bsd_uthread_fetch_registers)
8253 (bsd_uthread_store_registers): Use scoped_restore.
8254 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
8255 scoped_restore.
8256 * aix-thread.c (aix_thread_resume, aix_thread_wait)
8257 (aix_thread_xfer_partial): Use scoped_restore.
8258 * inferior.h (save_inferior_ptid): Remove.
8259
e60eb288
YQ
82602017-08-18 Yao Qi <yao.qi@linaro.org>
8261
8262 PR tdep/21818
8263 * arm-tdep.c (gdb_print_insn_arm): Mark
8264 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
8265
6d580b63
YQ
82662017-08-18 Yao Qi <yao.qi@linaro.org>
8267
8268 * NEWS: Mention GDBserver's new option "--selftest".
8269 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
8270 * selftest.c: Move it to common/selftest.c.
8271 * selftest.h: Move it to common/selftest.h.
8272 * selftest-arch.c (reset): New function.
8273 (tests_with_arch): Call reset.
8274
86dcbf50
YQ
82752017-08-18 Yao Qi <yao.qi@linaro.org>
8276
8277 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
8278 instead of exception_fprintf and printf_filtered.
8279
7649770c
YQ
82802017-08-18 Yao Qi <yao.qi@linaro.org>
8281
8282 * selftest.c (register_self_test): Rename it to
8283 selftests::register_test.
8284 (run_self_tests): selftest::run_tests.
8285 * selftest.h: Update declarations.
8286 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
8287 selftests::register_test_foreach_arch.
8288 * selftest-arch.h: Update declaration.
8289 * aarch64-tdep.c: Update.
8290 * arm-tdep.c: Likewise.
8291 * disasm-selftests.c: Likewise.
8292 * dwarf2loc.c: Likewise.
8293 * dwarf2-frame.c: Likewise.
8294 * findvar.c: Likewise.
8295 * gdbarch-selftests.c: Likewise.
8296 * maint.c (maintenance_selftest): Likewise.
8297 * regcache.c: Likewise.
8298 * rust-exp.y: Likewise.
8299 * selftest-arch.c: Likewise.
8300 * unittests/environ-selftests.c: Likewise.
8301 * unittests/function-view-selftests.c: Likewise.
8302 * unittests/offset-type-selftests.c: Likewise.
8303 * unittests/optional-selftests.c: Likewise.
8304 * unittests/scoped_restore-selftests.c: Likewise.
8305 * utils-selftests.c: Likewise.
8306
b0cba12e
PA
83072017-08-17 Pedro Alves <palves@redhat.com>
8308
8309 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
8310 local.
8311
4c8aa72d
PA
83122017-08-17 Pedro Alves <palves@redhat.com>
8313
8314 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
8315 field.
8316 (reset_die_in_process): Delete, replaced by ...
8317 (process_die_scope): ... this new class. Make it responsible for
8318 freeing cu->line_header too.
8319 (process_die): Use process_die_scope.
8320 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
8321 cu->line_header_die_owner. Don't release the line header if it's
8322 owned by the CU.
8323 (setup_type_unit_groups): Make the CU/DIE own the line header.
8324 Don't release the line header here.
8325
ba713918
AL
83262017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
8327
8328 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
8329
44d0fb3a
RK
83302017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
8331
8332 * NEWS: Mention new shortcuts for nexti and stepi in TUI
8333 Single-Key mode
8334
a5afdb16
RK
83352017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
8336
8337 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
8338 mode command list.
8339
47613aeb
SH
83402017-08-15 Stafford Horne <shorne@gmail.com>
8341
8342 * MAINTAINERS (Write After Approval): Add Stafford Horne.
8343
9c3cc999
SH
83442017-08-15 Stafford Horne <shorne@gmail.com>
8345
8346 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
8347
206726fb
SDJ
83482017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
8349
8350 PR gdb/21954
8351 * infcmd.c (unset_environment_command): Use the 'clear' method on
8352 the environment instead of resetting it.
8353
0335ac6d
JB
83542017-08-15 John Baldwin <jhb@FreeBSD.org>
8355
8356 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
8357 platforms.
8358
d3abe1c8
TT
83592017-08-14 Tom Tromey <tom@tromey.com>
8360
8361 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
8362 (print_binary_chars): Likewise.
8363 (BITS_IN_BYTES): Remove.
8364
d6382fff
TT
83652017-08-14 Tom Tromey <tom@tromey.com>
8366
8367 PR gdb/21675
8368 * valprint.c (LOW_ZERO): Change value to 034.
8369 (print_octal_chars): Add static_asserts for octal constants.
8370 * printcmd.c (print_scalar_formatted): Add 'd' case.
8371
f978cb06
TT
83722017-08-11 Tom Tromey <tom@tromey.com>
8373
8374 * symfile.c (add_symbol_file_command): Use std::vector.
8375
2f5404b3
TT
83762017-08-14 Tom Tromey <tom@tromey.com>
8377
8378 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
8379 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
8380 std::move.
8381 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
8382
de7985c3
PA
83832017-08-11 Pedro Alves <palves@redhat.com>
8384
8385 * infrun.c (process_event_stop_test): Adjust
8386 function_name_is_marked_for_skip call.
8387 * skip.c: Include <list>.
8388 (skiplist_entry): Make it a class with private fields, and
8389 getters/setters.
8390 (skiplist_entry_chain): Delete.
8391 (skiplist_entries): New.
8392 (skiplist_entry_count): Delete.
8393 (highest_skiplist_entry_num): New.
8394 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
8395 (add_skiplist_entry): Delete.
8396 (skiplist_entry::skiplist_entry): New.
8397 (skiplist_entry::add_entry): New.
8398 (skip_file_command, skip_function): Adjust.
8399 (compile_skip_regexp): Delete.
8400 (skip_command): Don't compile regexp here. Adjust to use
8401 skiplist_entry::add_entry.
8402 (skip_info): Adjust to use range-for and getters.
8403 (skip_enable_command, skip_disable_command): Adjust to use
8404 range-for and setters.
8405 (skip_delete_command): Adjust to use std::list.
8406 (add_skiplist_entry): Delete.
8407 (skip_file_p): Delete, refactored as ...
8408 (skiplist_entry::do_skip_file_p): ... this new method.
8409 (skip_gfile_p): Delete, refactored as ...
8410 (skiplist_entry::do_gskip_file_p): ... this new method.
8411 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
8412 (skiplist_entry::skip_function_p): ... this new method.
8413 (function_name_is_marked_for_skip): Now returns bool, and takes
8414 the function sal by const reference. Adjust to use range-for and
8415 skiplist_entry methods.
8416 (_initialize_step_skip): Remove references to
8417 skiplist_entry_chain, skiplist_entry_count.
8418 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
8419 takes the function sal by const reference.
8420
be7d3cd5
YQ
84212017-08-11 Yao Qi <yao.qi@linaro.org>
8422
8423 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
8424 (dwarf2_frame_cache): Remove reset_cache_cleanup.
8425 (dwarf2_frame_cache):
8426 * frame-unwind.c (frame_unwind_try_unwinder): Catch
8427 RETURN_MASK_ALL and set *this_case to NULL.
8428 * frame-unwind.h: Update comments.
8429
1c90d9f0
YQ
84302017-08-11 Yao Qi <yao.qi@linaro.org>
8431
8432 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
8433 (dwarf2_frame_state_copy_regs): Remove.
8434 (dwarf2_frame_state_free_regs): Remove.
8435 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
8436 (dwarf2_restore_rule): Call method .alloc_regs instead of
8437 dwarf2_frame_state_alloc_regs.
8438 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
8439 constructor. Call std::move.
8440 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
8441 (dwarf2_frame_cache): Likewise.
8442
8443 [GDB_SELF_TEST]: Include selftest.h and
8444 selftest-arch.h.
8445 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
8446 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
8447 execute_cfa_program_test.
8448
8449 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
8450 copy ctor, assignment operator, move assignment.
8451 <alloc_regs>: New method.
8452 <swap>: New method.
8453 (struct dwarf2_frame_state): Delete dtor.
8454 (dwarf2_frame_state_alloc_regs): Remove declaration.
8455 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
8456 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
8457
afe37d6b
YQ
84582017-08-11 Yao Qi <yao.qi@linaro.org>
8459
8460 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
8461 (dwarf2_frame_state::dwarf2_frame_state): New.
8462 (dwarf2_frame_state::~dwarf2_frame_state): New.
8463 (dwarf2_fetch_cfa_info): Update.
8464 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
8465 rather than a pointer. Update code.
8466 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
8467 dtor.
8468 <data_align, code_align, retaddr_column>: Change them to const.
8469 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
8470 to bool.
8471
b348037f
YQ
84722017-08-11 Yao Qi <yao.qi@linaro.org>
8473
8474 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
8475 <loc.exp>: New field.
8476 * dwarf2-frame.c (execute_cfa_program): Update.
8477 (dwarf2_frame_prev_register): Update.
8478
e7c9de26
PA
84792017-08-10 Pedro Alves <palves@redhat.com>
8480
8481 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
8482
e8c6b620
JB
84832017-08-09 John Baldwin <jhb@FreeBSD.org>
8484
8485 * fbsd-nat.c (struct fbsd_fork_info): Remove.
8486 (fbsd_pending_children): Use std::list.
8487 (fbsd_remember_child): Likewise.
8488 (fbsd_is_child_pending): Likewise.
8489 (fbsd_pending_vfork_done): Use std::forward_list.
8490 (fbsd_add_vfork_done): Likewise.
8491 (fbsd_is_vfork_done_pending): Likewise.
8492 (fbsd_next_vfork_done): Likewise.
8493
e4a26669
JB
84942017-08-09 John Baldwin <jhb@FreeBSD.org>
8495
8496 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
8497 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
8498 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
8499 for `mapfilename'.
8500 (fbsd_xfer_partial): Use gdb::byte_vector.
af3881e6 8501 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
e4a26669 8502
142311d3
JB
85032017-08-09 John Baldwin <jhb@FreeBSD.org>
8504
8505 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
8506 "filestuff.h".
8507 (fbsd_find_memory_regions): Fix `mapfile' initialization.
8508
42fa2e0e
TT
85092017-08-09 Tom Tromey <tom@tromey.com>
8510
8511 * skip.c (skiplist_entry): New constructor.
8512 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
8513 (skiplist_entry::file_is_glob): Now bool.
8514 (skiplist_entry::file, skiplist_entry::function): Now
8515 std::string.
8516 (make_skip_entry): Return a unique_ptr. Use new.
8517 (free_skiplist_entry, free_skiplist_entry_cleanup)
8518 (make_free_skiplist_entry_cleanup): Remove.
8519 (skip_command, skip_disable_command, add_skiplist_entry)
8520 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
8521 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
8522 (function_name_is_marked_for_skip): Update.
8523 (skip_delete_command): Update. Use delete.
8524
cd3af38d
JW
85252017-08-09 Jiong Wang <jiong.wang@arm.com>
8526
8527 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
8528 (aarch64_linux_core_read_description): New function.
8529 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
8530
29592bde
PA
85312017-08-09 Pedro Alves <palves@redhat.com>
8532
8533 * cp-name-parser.y (cp_comp_to_string): Return a
8534 gdb::unique_xmalloc_ptr<char>.
8535 * cp-support.c (replace_typedefs_qualified_name)
8536 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
8537 (cp_canonicalize_string_full): Use op= instead of explicit
8538 convertion.
8539 (cp_class_name_from_physname, method_name_from_physname)
8540 (cp_func_name, cp_remove_params): Adjust to use
8541 gdb::unique_xmalloc_ptr<char>.
8542 * cp-support.h (cp_comp_to_string): Return a
8543 gdb::unique_xmalloc_ptr<char>.
8544 * python/py-type.c (typy_lookup_type): Adjust to use
8545 gdb::unique_xmalloc_ptr<char>.
8546
b3340438
L
85472017-08-09 H.J. Lu <hongjiu.lu@intel.com>
8548
8549 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
8550
e88e8651
YQ
85512017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
8552 Yao Qi <yao.qi@linaro.org>
8553
8554 * cp-support.c (cp_canonicalize_string_full): Use
8555 gdb::unique_xmalloc_ptr<char>.
8556 (cp_canonicalize_string): Likewise.
8557
f5a29eb0
YQ
85582017-08-09 Yao Qi <yao.qi@linaro.org>
8559
8560 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
8561 * regformats/i386/amd64-avx-avx512.dat: Remove.
8562 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
8563 * regformats/i386/amd64-avx-mpx.dat:Remove.
8564 * regformats/i386/amd64-avx.dat: Remove.
8565 * regformats/i386/amd64-mpx.dat: Remove.
8566 * regformats/i386/i386-avx-avx512.dat: Remove.
8567 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
8568 * regformats/i386/i386-avx-mpx.dat: Remove.
8569 * regformats/i386/i386-mmx.dat: Remove.
8570 * regformats/i386/i386-mpx.dat: Remove.
8571
57757c2f
YQ
85722017-08-09 Yao Qi <yao.qi@linaro.org>
8573
8574 * amd64-tdep.h (tdesc_x32): Remove the declaration.
8575 * amd64-tdep.c: Don't include features/i386/x32*.c.
8576 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
8577 functions.
8578 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
8579 and i386/x32-avx-avx512.
8580 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
8581 and i386/x32.xml.
8582 * features/i386/x32-avx-avx512.c: Removed.
8583 * features/i386/x32-avx-avx512.xml: Removed.
8584 * features/i386/x32-avx.c: Removed.
8585 * features/i386/x32-avx.xml: Removed.
8586 * features/i386/x32.c: Removed.
8587 * features/i386/x32.xml: Removed.
8588 * regformats/i386/x32-avx-avx512.dat: Removed.
8589 * regformats/i386/x32-avx.dat: Removed.
8590 * regformats/i386/x32.dat: Removed.
8591
ba7b109b
MR
85922017-08-07 Maciej W. Rozycki <macro@imgtec.com>
8593
8594 PR breakpoints/21886
8595 * mem-break.c (default_memory_insert_breakpoint): Use
8596 `->placed_address' rather than `->reqstd_address' for the
8597 breakpoint location.
8598
e347efc3
MR
85992017-08-07 Maciej W. Rozycki <macro@imgtec.com>
8600
8601 * arch-utils.c (default_print_insn): Remove arch/mach/endian
8602 assertions.
8603
0dba2a6c
MR
86042017-08-07 Maciej W. Rozycki <macro@imgtec.com>
8605
8606 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
8607 a union of `tdep_info', `tdesc_data' and `id'.
8608 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
8609 rather than `info.tdep_info'.
8610 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
8611 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
8612 * i386-tdep.c (i386_gdbarch_init): Likewise.
8613 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
8614 * mips-tdep.c (mips_gdbarch_init): Likewise.
8615 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
8616 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
8617 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
8618 `info.tdep_info'.
8619 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
8620 `info.tdep_info'.
8621 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
8622 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
8623 `info.tdep_info'.
8624 * spu-tdep.c (spu_gdbarch_init): Likewise.
8625 * gdbarch.h: Regenerate.
8626
16eb6b2d
LS
86272017-08-07 Leszek Swirski <leszeks@google.com>
8628
7b005726 8629 PR symtab/20899
16eb6b2d
LS
8630 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
8631
74cbb09e
SM
86322017-08-07 Simon Marchi <simon.marchi@ericsson.com>
8633
8634 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
8635 (gdbsim_open): Rename gdb_argv args object to argv.
8636
ee0c3293
TT
86372017-08-05 Tom Tromey <tom@tromey.com>
8638
8639 * compile/compile-object-load.c (compile_object_load): Use
8640 gdb::unique_xmalloc_ptr.
8641 * cli/cli-dump.c (scan_filename): Rename from
8642 scan_filename_with_cleanup. Change return type.
8643 (scan_expression): Rename from scan_expression_with_cleanup.
8644 Change return type.
8645 (dump_memory_to_file, dump_value_to_file, restore_command):
8646 Use gdb::unique_xmalloc_ptr. Update.
8647 * cli/cli-cmds.c (find_and_open_script): Use
8648 gdb::unique_xmalloc_ptr.
8649 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
8650 * symmisc.c (maintenance_print_symbols)
8651 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
8652 * symfile.c (symfile_bfd_open, generic_load)
8653 (add_symbol_file_command, remove_symbol_file_command): Use
8654 gdb::unique_xmalloc_ptr.
8655 * source.c (openp): Use gdb::unique_xmalloc_ptr.
8656 * psymtab.c (maintenance_print_psymbols): Use
8657 gdb::unique_xmalloc_ptr.
8658 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
8659 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
8660 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
8661 (reload_shared_libraries_1): Likewise.
8662
3232fabd
TT
86632017-08-05 Tom Tromey <tom@tromey.com>
8664
8665 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
8666 (rust_op_vector, rust_set_vector): New typedefs.
8667 (current_parser): New global.
8668 (work_obstack): Change to pointer type. Update all users.
8669 (rust_ast, pstate): Remove globals.
8670 (struct rust_parser): New.
8671 (%union) <params, field_inits>: Change type.
8672 (start, tuple_expr, unit_expr, struct_expr_list, literal)
8673 (field_expr, expr_list, maybe_expr_list, type_list): Update.
8674 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
8675 (convert_params_to_types, convert_params_to_expression): Change
8676 type of "params".
8677 (ast_string): Change type of "fields".
8678 (rust_parse): Make a rust_parser. Remove cleanups.
8679 (rust_lex_tests): Make and install an auto_obstack.
8680
f02fd774
YQ
86812017-08-04 Yao Qi <yao.qi@linaro.org>
8682
8683 * configure.srv (ipa_x32_linux_regobj): New.
8684 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
8685 instead of X86_TDESC_AVX512.
8686 (initialize_low_tracepoint): Call
8687 init_registers_x32_avx_avx512_linux.
8688
91975afd
YQ
86892017-08-04 Yao Qi <yao.qi@linaro.org>
8690
8691 * utils.h (gdb_argv): Add namespace std for nullptr_t.
8692
2331fa3a
RK
86932017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
8694
8695 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
8696
744e4fe1
TT
86972017-08-03 Tom Tromey <tom@tromey.com>
8698
8699 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
8700 Remove.
8701 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
8702
1c034b67
TT
87032017-08-03 Tom Tromey <tom@tromey.com>
8704
8705 * python/py-param.c (compute_enum_values): Use gdb_argv.
8706
773a1edc
TT
87072017-08-03 Tom Tromey <tom@tromey.com>
8708
8709 * utils.h (struct gdb_argv_deleter): New.
8710 (gdb_argv): New class.
8711 * utils.c (gdb_argv::reset): New method.
8712 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
8713 * tracefile.c (tsave_command): Use gdb_argv.
8714 * top.c (new_ui_command): Use gdb_argv.
8715 * symmisc.c (maintenance_print_symbols)
8716 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
8717 * symfile.c (symbol_file_command, generic_load)
8718 (remove_symbol_file_command): Use gdb_argv.
8719 * stack.c (backtrace_command): Use gdb_argv.
8720 * source.c (add_path, show_substitute_path_command)
8721 (unset_substitute_path_command, set_substitute_path_command):
8722 Use gdb_argv.
8723 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
8724 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
8725 * remote.c (extended_remote_run, remote_put_command)
8726 (remote_get_command, remote_delete_command): Use gdb_argv.
8727 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
8728 (gdbsim_open): Use gdb_argv.
8729 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
8730 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
8731 * procfs.c (procfs_info_proc): Use gdb_argv.
8732 * interps.c (interpreter_exec_cmd): Use gdb_argv.
8733 * infrun.c (handle_command): Use gdb_argv.
8734 * inferior.c (add_inferior_command, clone_inferior_command):
8735 Use gdb_argv.
8736 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
8737 * exec.c (exec_file_command): Use gdb_argv.
8738 * cli/cli-cmds.c (alias_command): Use gdb_argv.
8739 * compile/compile.c (build_argc_argv): Use gdb_argv.
8740
0d50bde3
TT
87412017-08-03 Tom Tromey <tom@tromey.com>
8742
8743 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
8744
7f968c89
TT
87452017-08-03 Tom Tromey <tom@tromey.com>
8746
8747 * python/python.c (compute_python_string): Return std::string.
8748 (gdbpy_eval_from_control_command): Update.
8749 (do_start_initialization): Use std::string.
8750 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
8751 xstrprintf.
8752 * python/py-breakpoint.c (local_setattro): Use string_printf, not
8753 xstrprintf.
8754
3c9ebddd
TT
87552017-08-03 Tom Tromey <tom@tromey.com>
8756
8757 * top.h (do_restore_instream_cleanup): Remove.
8758 * top.c (do_restore_instream_cleanup): Remove.
8759 (read_command_file): Use scoped_restore.
8760 * cli/cli-script.c (execute_user_command): Use scoped_restore.
8761
b51b225e
TT
87622017-08-03 Tom Tromey <tom@tromey.com>
8763
8764 * cli/cli-script.c (execute_user_command)
8765 (execute_control_command): Use scoped_restore.
8766
ac991630
TT
87672017-08-03 Tom Tromey <tom@tromey.com>
8768
8769 * cli/cli-script.c (do_restore_user_call_depth): Remove.
8770 (execute_user_command): Remove user_call_depth; use
8771 user_args_stack's size instead.
8772
898e0c8e
TT
87732017-08-03 Tom Tromey <tom@tromey.com>
8774
8775 * top.h (in_user_command): Remove.
8776 * top.c (in_user_command): Remove.
8777 * cli/cli-script.c (do_restore_user_call_depth)
8778 (execute_user_command): Update.
8779
26fcd5d7
TT
87802017-08-03 Tom Tromey <tom@tromey.com>
8781
8782 * valops.c (search_struct_method): Use gdb::byte_vector.
8783 * valarith.c (value_concat): Use std::vector.
8784 * target.c (memory_xfer_partial): Use gdb::byte_vector.
8785 (simple_search_memory): Likewise.
8786 * printcmd.c (find_string_backward): Use gdb::byte_vector.
8787 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
8788 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
8789 * elfread.c (elf_rel_plt_read): Use std::string.
8790 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
8791 * cli/cli-dump.c (restore_section_callback): Use
8792 gdb::byte_vector.
8793
7c218e6c
TT
87942017-08-03 Tom Tromey <tom@tromey.com>
8795
8796 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
8797
31b68d4a
TT
87982017-08-03 Tom Tromey <tom@tromey.com>
8799
8800 * tui/tui-regs.c (tui_restore_gdbout): Remove.
8801 (tui_register_format): Use scoped_restore.
8802
2ec845e7
TT
88032017-08-03 Tom Tromey <tom@tromey.com>
8804
8805 * reverse.c (exec_direction_default): Remove.
8806 (exec_reverse_once): Use scoped_restore.
8807 * remote.c (restore_remote_timeout): Remove.
8808 (remote_flash_erase, remote_flash_write, remote_flash_done)
8809 (readchar, remote_serial_write): Use scoped_restore.
8810 * cli/cli-script.c (struct source_cleanup_lines_args)
8811 (source_cleanup_lines): Remove.
8812 (script_from_file): Use scoped_restore.
8813 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
8814 (source_command): Use scoped_restore.
8815
b3bc8453
TT
88162017-08-03 Tom Tromey <tom@tromey.com>
8817
8818 * utils.h (make_cleanup_free_so): Remove.
8819 * utils.c (do_free_so, make_cleanup_free_so): Remove.
8820 * solist.h (struct so_deleter): New.
8821 (so_list_up): New typedef.
8822 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
8823
e3ad2841
TT
88242017-08-03 Tom Tromey <tom@tromey.com>
8825
8826 * utils.h (make_cleanup_restore_current_language): Remove.
8827 * utils.c (do_restore_current_language)
8828 (make_cleanup_restore_current_language): Remove.
8829 * parse.c (parse_exp_in_context_1)
8830 (parse_expression_with_language): Use
8831 scoped_restore_current_language.
8832 * mi/mi-main.c (mi_cmd_execute): Use
8833 scoped_restore_current_language.
8834 * language.h (scoped_restore_current_language): New class.
8835
b80cf838
TT
88362017-08-03 Tom Tromey <tom@tromey.com>
8837
8838 * compile/compile.c (cleanup_unlink_file): Remove.
8839 (compile_to_object): Use gdb::unlinker.
8840 (eval_compile_command): Likewise.
8841
fad0444a
TT
88422017-08-03 Tom Tromey <tom@tromey.com>
8843
8844 * utils.h (make_cleanup_fclose): Remove.
8845 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
8846
6e7bc05c
TT
88472017-08-03 Tom Tromey <tom@tromey.com>
8848
8849 * top.c (open_terminal_stream): Return gdb_file_up.
8850 (new_ui_command): Update.
8851
4a45905b
TT
88522017-08-03 Tom Tromey <tom@tromey.com>
8853
8854 * source.c (print_source_lines_base, forward_search_command)
8855 (reverse_search_command): Use gdb_file_up.
8856
7cd06d6e
TT
88572017-08-03 Tom Tromey <tom@tromey.com>
8858
8859 * fbsd-nat.c (fbsd_find_memory_regions): Update.
8860
ed166945
TT
88612017-08-03 Tom Tromey <tom@tromey.com>
8862
8863 * cli/cli-cmds.c (find_and_open_script): Change return type.
8864 Remove "streamp" and "full_path" parameters.
8865 (source_script_with_search): Update.
8866 * auto-load.c (source_script_file): Update.
8867 * cli/cli-cmds.h (find_and_open_script): Change type.
8868 (open_script): New struct.
8869
d419f42d
TT
88702017-08-03 Tom Tromey <tom@tromey.com>
8871
8872 * xml-support.c (xml_fetch_content_from_file): Update.
8873 * ui-file.c (stdio_file::open): Update.
8874 * tracefile-tfile.c (tfile_start): Update.
8875 * remote.c (remote_file_put, remote_file_get): Update.
8876 * nat/linux-procfs.c (linux_proc_get_int)
8877 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
8878 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
8879 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
8880 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
8881 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
8882 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
8883 * linux-nat.c (linux_proc_pending_signals): Update.
8884 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
8885 (file_closer): Remove.
8886 * compile/compile.c (compile_to_object): Update.
8887 * common/filestuff.h (struct gdb_file_deleter): New.
8888 (gdb_file_up): New typedef.
8889 (gdb_fopen_cloexec): Change return type.
8890 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
8891 * cli/cli-dump.c (fopen_with_cleanup): Remove.
8892 (dump_binary_file, restore_binary_file): Update.
8893 * auto-load.c (auto_load_objfile_script_1): Update.
8894
4a2b031d
TT
88952017-08-03 Tom Tromey <tom@tromey.com>
8896
8897 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
8898 (info_static_tracepoint_markers_command): Likewise.
8899 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
8900 * skip.c (skip_info): Use ui_out_emit_table.
8901 * progspace.c (print_program_space): Use ui_out_emit_table.
8902 * osdata.c (info_osdata): Use ui_out_emit_table.
8903 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
8904 ui_out_emit_table.
8905 * linux-thread-db.c (info_auto_load_libthread_db): Use
8906 ui_out_emit_table.
8907 * inferior.c (print_inferior): Use ui_out_emit_table.
8908 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
8909 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
8910 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
8911 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
8912 * ui-out.h (class ui_out_emit_table): New.
8913
a4f320fd
MR
89142017-08-02 Maciej W. Rozycki <macro@imgtec.com>
8915
8916 * mips-tdep.c (mips_fpu_type_str): New function.
8917 (mips_dump_tdep): Call it.
8918
a2f1f308
MR
89192017-08-01 Maciej W. Rozycki <macro@imgtec.com>
8920
8921 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
8922 `->mips_fpu_type'.
8923
7e5ed83b
XR
89242017-07-31 Xavier Roirand <roirand@adacore.com>
8925
8926 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
8927
4c9dc811
XR
89282017-07-27 Xavier Roirand <roirand@adacore.com>
8929
8930 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
8931
27d41eac
YQ
89322017-07-26 Yao Qi <yao.qi@linaro.org>
8933
8934 * cli/cli-cmds.c (maintenancechecklist): New variable.
8935 * gdbcmd.h (maintenancechecklist): Declare it.
8936 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
8937 Call i386_linux_read_description with different masks.
8938 * maint.c (maintenance_check_command): New function.
8939 (_initialize_maint_cmds): Call add_prefix_cmd.
8940 * target-descriptions.c (tdesc_reg): override operator != and ==.
8941 (tdesc_type): Likewise.
8942 (tdesc_feature): Likewise.
8943 (target_desc): Likewise.
8944 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
8945 (maintenance_check_xml_descriptions): New function.
8946 (_initialize_target_descriptions) Add command "xml-descriptions".
8947 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
8948
ea03d0d3
YQ
89492017-07-26 Yao Qi <yao.qi@linaro.org>
8950
8951 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
8952 Include features/i386/32bit-*.c.
8953 (i386_linux_read_description): Generate target description if it
8954 doesn't exist.
8955 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
8956 functions.
8957 * features/i386/32bit-linux.c: Re-generated.
8958 * features/i386/32bit-sse.c: Likewise.
8959 * target-descriptions.c (print_c_feature::visit): Print code to
8960 set register number if needed.
8961 (print_c_feature) <m_next_regnum>: New field.
8962
25aa13e5
YQ
89632017-07-26 Yao Qi <yao.qi@linaro.org>
8964
8965 * features/Makefile (CFILES): Rename with TDESC_CFILES.
8966 (FEATURE_XMLFILES): New.
8967 (FEATURE_CFILES): New.
8968 New rules.
8969 (clean-cfiles): Remove generated c files.
8970 * features/i386/32bit-avx.c: Generated.
8971 * features/i386/32bit-avx512.c: Generated.
8972 * features/i386/32bit-core.c: Generated.
8973 * features/i386/32bit-linux.c: Generated.
8974 * features/i386/32bit-mpx.c: Generated.
8975 * features/i386/32bit-pkeys.c: Generated.
8976 * features/i386/32bit-sse.c: Generated.
8977 * target-descriptions.c: Include algorithm.
8978 (tdesc_element_visitor): Add method visit_end.
8979 (print_c_tdesc): Implement visit_end.
8980 (print_c_tdesc:: m_filename_after_features): Move it to
8981 protected.
8982 (print_c_feature): New class.
8983 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
8984 name starts with "i386/32bit-".
8985
6eb1e6a8
YQ
89862017-07-26 Yao Qi <yao.qi@linaro.org>
8987
8988 * target-descriptions.c (tdesc_element_visitor): New class.
8989 (tdesc_element): New class.
8990 (tdesc_reg): Inherit from tdesc_element.
8991 (tdesc_reg::accept): New function.
8992 (tdesc_type): Inherit from tdesc_element.
8993 (tdesc_type::accept): New function.
8994 (tdesc_feature): Inherit from tdesc_element.
8995 (tdesc_feature::accept): New function.
8996 (target_desc): Inherit from tdesc_element.
8997 (target_desc::target_desc): New.
8998 (target_desc::~target_desc): New.
8999 (target_desc::accept): New.
9000 (allocate_target_description): Use new.
9001 (free_target_description): Use delete.
9002 (print_c_tdesc): New class.
9003 (maint_print_c_tdesc_cmd): Adjust.
9004
9005 * features/aarch64.c: Re-generated.
9006 * features/arc-arcompact.c: Re-generated.
9007 * features/arc-v2.c: Re-generated.
9008 * features/arm/arm-with-iwmmxt.c: Re-generated.
9009 * features/arm/arm-with-m.c: Re-generated.
9010 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
9011 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
9012 * features/arm/arm-with-neon.c: Re-generated.
9013 * features/arm/arm-with-vfpv2.c: Re-generated.
9014 * features/arm/arm-with-vfpv3.c: Re-generated.
9015 * features/i386/amd64-avx-avx512.c: Re-generated.
9016 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
9017 * features/i386/amd64-avx.c: Re-generated.
9018 * features/i386/amd64-avx-linux.c: Re-generated.
9019 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
9020 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
9021 * features/i386/amd64-avx-mpx.c: Re-generated.
9022 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
9023 * features/i386/amd64.c: Re-generated.
9024 * features/i386/amd64-linux.c: Re-generated.
9025 * features/i386/amd64-mpx.c: Re-generated.
9026 * features/i386/amd64-mpx-linux.c: Re-generated.
9027 * features/i386/i386-avx-avx512.c: Re-generated.
9028 * features/i386/i386-avx-avx512-linux.c: Re-generated.
9029 * features/i386/i386-avx.c: Re-generated.
9030 * features/i386/i386-avx-linux.c: Re-generated.
9031 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
9032 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
9033 * features/i386/i386-avx-mpx.c: Re-generated.
9034 * features/i386/i386-avx-mpx-linux.c: Re-generated.
9035 * features/i386/i386.c: Re-generated.
9036 * features/i386/i386-linux.c: Re-generated.
9037 * features/i386/i386-mmx.c: Re-generated.
9038 * features/i386/i386-mmx-linux.c: Re-generated.
9039 * features/i386/i386-mpx.c: Re-generated.
9040 * features/i386/i386-mpx-linux.c: Re-generated.
9041 * features/i386/x32-avx-avx512.c: Re-generated.
9042 * features/i386/x32-avx-avx512-linux.c: Re-generated.
9043 * features/i386/x32-avx.c: Re-generated.
9044 * features/i386/x32-avx-linux.c: Re-generated.
9045 * features/i386/x32.c: Re-generated.
9046 * features/i386/x32-linux.c: Re-generated.
9047 * features/microblaze.c: Re-generated.
9048 * features/microblaze-with-stack-protect.c: Re-generated.
9049 * features/mips64-dsp-linux.c: Re-generated.
9050 * features/mips64-linux.c: Re-generated.
9051 * features/mips-dsp-linux.c: Re-generated.
9052 * features/mips-linux.c: Re-generated.
9053 * features/nds32.c: Re-generated.
9054 * features/nios2.c: Re-generated.
9055 * features/nios2-linux.c: Re-generated.
9056 * features/rs6000/powerpc-32.c: Re-generated.
9057 * features/rs6000/powerpc-32l.c: Re-generated.
9058 * features/rs6000/powerpc-403.c: Re-generated.
9059 * features/rs6000/powerpc-403gc.c : Re-generated.
9060 * features/rs6000/powerpc-405.c: Re-generated.
9061 * features/rs6000/powerpc-505.c: Re-generated.
9062 * features/rs6000/powerpc-601.c: Re-generated.
9063 * features/rs6000/powerpc-602.c: Re-generated.
9064 * features/rs6000/powerpc-603.c: Re-generated.
9065 * features/rs6000/powerpc-604.c: Re-generated.
9066 * features/rs6000/powerpc-64.c: Re-generated.
9067 * features/rs6000/powerpc-64l.c: Re-generated.
9068 * features/rs6000/powerpc-7400.c: Re-generated.
9069 * features/rs6000/powerpc-750.c: Re-generated.
9070 * features/rs6000/powerpc-860.c: Re-generated.
9071 * features/rs6000/powerpc-altivec32.c: Re-generated.
9072 * features/rs6000/powerpc-altivec32l.c: Re-generated.
9073 * features/rs6000/powerpc-altivec64.c: Re-generated.
9074 * features/rs6000/powerpc-altivec64l.c: Re-generated.
9075 * features/rs6000/powerpc-cell32l.c: Re-generated.
9076 * features/rs6000/powerpc-cell64l.c: Re-generated.
9077 * features/rs6000/powerpc-e500.c: Re-generated.
9078 * features/rs6000/powerpc-e500l.c: Re-generated.
9079 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
9080 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
9081 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
9082 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
9083 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
9084 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
9085 * features/rs6000/powerpc-vsx32.c: Re-generated.
9086 * features/rs6000/powerpc-vsx32l.c: Re-generated.
9087 * features/rs6000/powerpc-vsx64.c: Re-generated.
9088 * features/rs6000/powerpc-vsx64l.c: Re-generated.
9089 * features/rs6000/rs6000.c: Re-generated.
9090 * features/s390-linux32.c: Re-generated.
9091 * features/s390-linux32v1.c: Re-generated.
9092 * features/s390-linux32v2.c: Re-generated.
9093 * features/s390-linux64.c: Re-generated.
9094 * features/s390-linux64v1.c: Re-generated.
9095 * features/s390-linux64v2.c: Re-generated.
9096 * features/s390-te-linux64.c: Re-generated.
9097 * features/s390-tevx-linux64.c: Re-generated.
9098 * features/s390-vx-linux64.c: Re-generated.
9099 * features/s390x-linux64.c: Re-generated.
9100 * features/s390x-linux64v1.c: Re-generated.
9101 * features/s390x-linux64v2.c: Re-generated.
9102 * features/s390x-te-linux64.c: Re-generated.
9103 * features/s390x-tevx-linux64.c: Re-generated.
9104 * features/s390x-vx-linux64.c: Re-generated.
9105 * features/sparc/sparc32-solaris.c: Re-generated.
9106 * features/sparc/sparc64-solaris.c: Re-generated.
9107 * features/tic6x-c62x.c: Re-generated.
9108 * features/tic6x-c62x-linux.c: Re-generated.
9109 * features/tic6x-c64x.c: Re-generated.
9110 * features/tic6x-c64x-linux.c: Re-generated.
9111 * features/tic6x-c64xp.c: Re-generated.
9112 * features/tic6x-c64xp-linux.c: Re-generated.
9113
35b4818d
YQ
91142017-07-26 Yao Qi <yao.qi@linaro.org>
9115
9116 * i386-linux-tdep.c (i386_linux_read_description): New function.
9117 (i386_linux_core_read_description): Call
9118 i386_linux_read_description.
9119 * i386-linux-tdep.h (i386_linux_read_description): Declare.
9120 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
9121 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
9122 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
9123 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
9124 * x86-linux-nat.c (x86_linux_read_description): Call
9125 i386_linux_read_description.
9126
8e2141c6
YQ
91272017-07-26 Yao Qi <yao.qi@linaro.org>
9128
9129 * NEWS: Mention it.
9130 * features/Makefile (%.c: %.xml): Pass the xml file name to
9131 command "maint print c-tdesc".
9132 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
9133 name from 'arg'.
9134
b468ff4c
YQ
91352017-07-26 Yao Qi <yao.qi@linaro.org>
9136
9137 * target-descriptions.c (target_desc): Add ctor and dtor. Do
9138 in-class initialization.
9139 (tdesc_create_feature): Call new instead of XCNEW.
9140 (free_target_description): Ue delete.
9141
b9c0e1b4
JB
91422017-07-25 John Baldwin <jhb@FreeBSD.org>
9143
9144 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
9145
a04b5337
YQ
91462017-07-25 Yao Qi <yao.qi@linaro.org>
9147
9148 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
9149 constant.
9150 (amd64_x32_init_abi): Likewise.
9151 * amd64-tdep.h (amd64_init_abi): Update declaration.
9152 (amd64_x32_init_abi): Likewise.
9153
02ad7fc2
YQ
91542017-07-25 Yao Qi <yao.qi@linaro.org>
9155
9156 PR tdep/21717
9157 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
9158 condition for FPSCR.
9159 (arm_linux_store_inferior_registers): Likewise.
9160
b6f48cb0
TT
91612017-07-22 Tom Tromey <tom@tromey.com>
9162
9163 * break-catch-syscall.c (struct catch_syscall_inferior_data)
9164 <syscalls_counts>: Now a std::vector.
9165 (get_catch_syscall_inferior_data): Use "new".
9166 (catch_syscall_inferior_data_cleanup): Use "delete".
9167 (insert_catch_syscall, remove_catch_syscall)
9168 (clear_syscall_counts): Update.
9169
e12c9b7a
TT
91702017-07-22 Tom Tromey <tom@tromey.com>
9171
9172 * break-catch-syscall.c (syscall_catchpoint)
9173 <syscalls_to_be_caught>: Now a std::vector<int>
9174 (~syscall_catchpoint): Remove.
9175 (insert_catch_syscall, remove_catch_syscall)
9176 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
9177 (print_mention_catch_syscall, print_recreate_catch_syscall):
9178 Update.
9179 (create_syscall_event_catchpoint): Change type of "filter"
9180 parameter.
9181 (catch_syscall_split_args): Return a std::vector.
9182 (catch_syscall_command_1, catching_syscall_number_1): Update.
9183
4fa8aeac
TT
91842017-07-22 Tom Tromey <tom@tromey.com>
9185
9186 * break-catch-throw.c (struct exception_catchpoint)
9187 <exception_rx>: Now a std::string.
9188 (~exception_catchpoint): Remove.
9189 (print_one_detail_exception_catchpoint): Update.
9190 (handle_gnu_v3_exceptions): Change type of except_rx.
9191 (extract_exception_regexp): Return a std::string.
9192 (catch_exception_command_1): Update.
9193
f746a154
TT
91942017-07-22 Tom Tromey <tom@tromey.com>
9195
9196 * break-catch-sig.c (gdb_signal_type): Remove typedef.
9197 (struct signal_catchpoint) <signals_to_be_caught>: Now a
9198 std::vector.
9199 <catch_all>: Now a bool.
9200 (~signal_catchpoint): Remove.
9201 (signal_catchpoint_insert_location)
9202 (signal_catchpoint_remove_location)
9203 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
9204 (signal_catchpoint_print_mention)
9205 (signal_catchpoint_print_recreate)
9206 (signal_catchpoint_explains_signal): Update.
9207 (create_signal_catchpoint): Change type of "filter" and
9208 "catch_all".
9209 (catch_signal_split_args): Return a std::vector. Change type of
9210 "catch_all".
9211 (catch_signal_command): Update.
9212
47e77640
PA
92132017-07-20 Pedro Alves <palves@redhat.com>
9214
9215 * ada-lang.c (ada_language_defn): Make extern.
9216 (_initialize_ada_language): Remove add_language call.
9217 * c-lang.c (c_language_defn, cplus_language_defn)
9218 (asm_language_defn, minimal_language_defn): Make extern.
9219 (_initialize_c_language): Delete.
9220 * completer.c (compare_cstrings): Delete, moved to utils.h.
9221 * d-lang.c (d_language_defn): Make extern.
9222 (_initialize_d_language): Remove add_language calls.
9223 * defs.h (enum language): Add comment.
9224 * f-lang.c (f_language_defn): Make extern.
9225 (_initialize_f_language): Remove add_language call.
9226 * go-lang.c (go_language_defn): Make extern.
9227 (_initialize_go_language): Remove add_language call.
9228 * language.c: Include <algorithm>.
9229 (languages): Redefine as const array.
9230 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
9231 (set_language_command): Handle "local". Use for-range loop.
9232 (set_language): Remove loop.
9233 (language_enum): Rewrite.
9234 (language_def, language_str): Remove loops.
9235 (add_language): Delete.
9236 (add_set_language_command): New, based on add_languages.
9237 (skip_language_trampoline): Adjust.
9238 (local_language_defn): Delete.
9239 (language_gdbarch_post_init): Adjust.
9240 (_initialize_language): Remove add_language calls. Call
9241 add_set_language_command.
9242 * language.h (add_language): Delete.
9243 (auto_language_defn)
9244 (unknown_language_defn, minimal_language_defn, ada_language_defn)
9245 (asm_language_defn, c_language_defn, cplus_language_defn)
9246 (d_language_defn, f_language_defn, go_language_defn)
9247 (m2_language_defn, objc_language_defn, opencl_language_defn)
9248 (pascal_language_defn, rust_language_defn): Declare.
9249 * m2-lang.c (m2_language_defn): Make extern.
9250 (_initialize_m2_language): Remove add_language call.
9251 * objc-lang.c (objc_language_defn): Make extern.
9252 (_initialize_objc_language): Remove add_language call.
9253 * opencl-lang.c (opencl_language_defn): Make extern.
9254 (_initialize_opencl_language): Remove add_language call.
9255 * p-lang.c (pascal_language_defn): Make extern.
9256 (_initialize_pascal_language): Delete.
9257 * rust-lang.c (rust_language_defn): Make extern.
9258 (_initialize_rust_language): Delete.
9259 * utils.h (compare_cstrings): New static inline function.
9260
edb0c9cb
PA
92612017-07-20 Pedro Alves <palves@redhat.com>
9262
9263 * ada-lang.c (ada_to_fixed_type_1): Adjust.
9264 (get_var_value): Constify parameters.
9265 (get_int_var_value): Change prototype.
9266 (to_fixed_range_type): Adjust.
9267 * ada-lang.h (get_int_var_value): Change prototype.
9268
a778f165
PA
92692017-07-20 Pedro Alves <palves@redhat.com>
9270
9271 * dwarf2read.c (dw2_lookup_symbol): Use
9272 SYMBOL_MATCHES_SEARCH_NAME.
9273 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
9274
42edd901
PA
92752017-07-20 Pedro Alves <palves@redhat.com>
9276
9277 * block.c (block_iter_name_step, block_iter_name_first)
9278 (block_iter_name_next): Delete.
9279 (block_lookup_symbol_primary): Adjust to use
9280 dict_iter_match_first/dict_iter_match_next.
9281 * block.h (block_iter_name_first, block_iter_name_next): Delete
9282 declarations.
9283 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
9284 dict_iter_match_first/dict_iter_match_next.
9285
cf325299
PA
92862017-07-20 Pedro Alves <palves@redhat.com>
9287
9288 * cp-support.c (cp_find_first_component_aux): Add missing case for
9289 end of string.
9290
c5ed0576
DB
92912017-07-18 David Blaikie <dblaikie@gmail.com>
9292
9293 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
9294 of dwo_cu's dwo_file.
9295
27841e76
YQ
92962017-07-18 Yao Qi <yao.qi@linaro.org>
9297
9298 * remote.c (store_registers_using_G): Remove one line comment.
9299
cfb7e58b
YQ
93002017-07-18 Yao Qi <yao.qi@linaro.org>
9301
9302 * regcache.c (regcache_cpy): Simplify it.
9303 (regcache::cpy_no_passthrough): Remove it.
9304 * regcache.h (cpy_no_passthrough): Remove it.
9305 (regcache_dup, regcache_cpy): Update comments.
9306
386535dd
PA
93072017-07-18 Pedro Alves <palves@redhat.com>
9308
9309 * remote-sim.c (sim_command_completer): Adjust to work with a
9310 completion_tracker instead of a VEC.
9311
c45ec17c
PA
93122017-07-17 Pedro Alves <palves@redhat.com>
9313
9314 * completer.c (complete_source_filenames): New function.
9315 (complete_address_and_linespec_locations): New function.
9316 (location_completer): Use complete_address_and_linespec_locations.
9317 (completion_tracker::build_completion_result): Honor the tracker's
9318 request to suppress append.
9319 * completer.h (completion_tracker::suppress_append_ws)
9320 (completion_tracker::set_suppress_append_ws): New methods.
9321 (completion_tracker::m_suppress_append_ws): New field.
9322 (complete_source_filenames): New declaration.
9323 * linespec.c (linespec_complete_what): New.
9324 (struct ls_parser) <complete_what, completion_word,
9325 completion_quote_char, completion_quote_end, completion_tracker>:
9326 New fields.
9327 (string_find_incomplete_keyword_at_end): New.
9328 (linespec_lexer_lex_string): Record quote char. If in completion
9329 mode, don't throw.
9330 (linespec_lexer_consume_token): Advance the completion word point.
9331 (linespec_lexer_peek_token): Save/restore completion info.
9332 (save_stream_and_consume_token): New.
9333 (set_completion_after_number): New.
9334 (linespec_parse_basic): Set what to complete next depending on
9335 token. Handle function and label completions specially.
9336 (parse_linespec): Disable objc shortcut in completion mode. Set
9337 what to complete next depending on token type. Skip keyword if in
9338 completion mode.
9339 (complete_linespec_component, linespec_complete): New.
9340 * linespec.h (linespec_complete): Declare.
9341
be966d42
PA
93422017-07-17 Pedro Alves <palves@redhat.com>
9343
9344 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
9345 Handle 'operator<' / 'operator<<'.
9346
a2459270
PA
93472017-07-17 Pedro Alves <palves@redhat.com>
9348
9349 * completer.c (collect_explicit_location_matches): Handle
9350 MATCH_LABEL.
9351 (convert_explicit_location_to_linespec): New, factored out from
9352 ...
9353 (convert_explicit_location_to_sals): ... this.
9354 (complete_label): New.
9355 (linespec_complete_label, find_label_symbols_in_block): New.
9356 (find_label_symbols): Add completion_mode parameter and adjust to
9357 call find_label_symbols_in_block.
9358 * linespec.h (linespec_complete_label): Declare.
9359
c6756f62
PA
93602017-07-17 Pedro Alves <palves@redhat.com>
9361
9362 * ada-lang.c (ada_collect_symbol_completion_matches): Add
9363 complete_symbol_mode parameter.
9364 * cli/cli-cmds.c (complete_command): Get the completion result out
9365 of the handle_brkchars tracker if used a custom word point.
9366 * completer.c: Include "linespec.h".
9367 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
9368 (advance_to_expression_complete_word_point): New.
9369 (completion_tracker::completes_to_completion_word): New.
9370 (complete_files_symbols): Pass down
9371 complete_symbol_mode::EXPRESSION.
9372 (explicit_options, probe_options): New.
9373 (collect_explicit_location_matches): Complete on the
9374 explictit_loc->foo instead of word. Use
9375 linespec_complete_function. Handle MATCH_LINE. Handle offering
9376 keyword and options completions.
9377 (backup_text_ptr): Delete.
9378 (skip_keyword): New.
9379 (complete_explicit_location): Remove 'word' parameter. Add
9380 language, quoted_arg_start and quoted_arg_end parameters.
9381 Rewrite, parsing left to right.
9382 (location_completer): Rewrite.
9383 (location_completer_handle_brkchars): New function.
9384 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
9385 (enum complete_line_internal_reason): Adjust comments.
9386 (completion_tracker::discard_completions): New.
9387 (completer_handle_brkchars_func_for_completer): Handle
9388 location_completer.
9389 (gdb_custom_word_point_brkchars)
9390 (gdb_org_rl_basic_quote_characters): New.
9391 (gdb_completion_word_break_characters_throw)
9392 (completion_find_completion_word): Handle trackers that use a
9393 custom word point.
9394 (completion_tracker::advance_custom_word_point_by): New.
9395 (completion_tracker::build_completion_result): Don't rely on
9396 readline appending the quote char.
9397 (gdb_rl_attempted_completion_function_throw): Handle trackers that
9398 use a custom word point.
9399 (gdb_rl_attempted_completion_function): Restore
9400 rl_basic_quote_characters.
9401 * completer.h (class completion_tracker): Extend intro comment.
9402 (completion_tracker::set_quote_char)
9403 (completion_tracker::quote_char)
9404 (completion_tracker::set_use_custom_word_point)
9405 (completion_tracker::use_custom_word_point)
9406 (completion_tracker::custom_word_point)
9407 (completion_tracker::set_custom_word_point)
9408 (completion_tracker::advance_custom_word_point_by)
9409 (completion_tracker::completes_to_completion_word)
9410 (completion_tracker::discard_completions): New methods.
9411 (completion_tracker::m_quote_char)
9412 (completion_tracker::m_use_custom_word_point)
9413 (completion_tracker::m_custom_word_point): New fields.
9414 (advance_to_expression_complete_word_point): Declare.
9415 * f-lang.c (f_collect_symbol_completion_matches): Add
9416 complete_symbol_mode parameter.
9417 * language.h (struct language_defn)
9418 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
9419 parameter.
9420 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
9421 (linespec_complete_function): New function.
9422 (linespec_lexer_lex_keyword): Adjust.
9423 * linespec.h (linespec_keywords, linespec_complete_function): New
9424 declarations.
9425 * location.c (find_end_quote): New function.
9426 (explicit_location_lex_one): Add explicit_completion_info
9427 parameter. Save quoting info. Don't throw if being called for
9428 completion. Don't handle Ada operators here.
9429 (is_cp_operator, skip_op_false_positives, first_of)
9430 (explicit_location_lex_one_function): New function.
9431 (string_to_explicit_location): Replace 'dont_throw' parameter with
9432 an explicit_completion_info pointer parameter. Handle it. Don't
9433 use explicit_location_lex_one to lex function names. Use
9434 explicit_location_lex_one_function instead.
9435 * location.h (struct explicit_completion_info): New.
9436 (string_to_explicit_location): Replace 'dont_throw' parameter with
9437 an explicit_completion_info pointer parameter.
9438 * symtab.c (default_collect_symbol_completion_matches_break_on):
9439 Add complete_symbol_mode parameter. Handle LINESPEC mode.
9440 (default_collect_symbol_completion_matches)
9441 (collect_symbol_completion_matches): Add complete_symbol_mode
9442 parameter.
9443 (collect_symbol_completion_matches_type): Pass down
9444 complete_symbol_mode::EXPRESSION.
9445 (collect_file_symbol_completion_matches): Add complete_symbol_mode
9446 parameter. Handle LINESPEC mode.
9447 * symtab.h (complete_symbol_mode): New.
9448 (default_collect_symbol_completion_matches_break_on)
9449 (default_collect_symbol_completion_matches)
9450 (collect_symbol_completion_matches)
9451 (collect_file_symbol_completion_matches): Add complete_symbol_mode
9452 parameter.
9453
1d550c82
PA
94542017-07-17 Pedro Alves <palves@redhat.com>
9455
9456 * utils.c (enum class strncmp_iw_mode): New.
9457 (strcmp_iw): Rename to ...
9458 (strncmp_iw_with_mode): ... this. Add string2_len and mode
9459 parameters. Handle them.
9460 (strncmp_iw): New.
9461 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
9462 * utils.h (strncmp_iw): Declare.
9463 (strcmp_iw): Move describing comments here.
9464
8090b426
PA
94652017-07-17 Pedro Alves <palves@redhat.com>
9466
9467 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
9468 CP_OPERATOR_STR.
9469 * c-typeprint.c (is_type_conversion_operator): Use
9470 CP_OPERATOR_STR.
9471 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
9472 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
9473 CP_OPERATOR_LEN.
9474 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
9475 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
9476 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
9477 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
9478 CP_OPERATOR_STR.
9479 * location.c: Include "cp-support.h".
9480 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
9481 CP_OPERATOR_STR.
9482 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
9483 CP_OPERATOR_LEN.
9484
6a2c1b87
PA
94852017-07-17 Pedro Alves <palves@redhat.com>
9486
9487 * cli/cli-cmds.c (complete_command): Use a completion tracker
9488 along with completion_find_completion_word for handle_brkchars
9489 phase.
9490 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
9491 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
9492 (struct gdb_rl_completion_word_info): New.
9493 (gdb_rl_find_completion_word): New.
9494 (completion_find_completion_word): New.
9495 * completer.h (completion_find_completion_word): Declare.
9496
eb3ff9a5
PA
94972017-07-17 Pedro Alves <palves@redhat.com>
9498
9499 * ada-lang.c (symbol_completion_match): Adjust comments.
9500 (symbol_completion_add): Replace vector parameter with
9501 completion_tracker parameter. Use it.
9502 (ada_make_symbol_completion_list): Rename to...
9503 (ada_collect_symbol_completion_matches): ... this. Add
9504 completion_tracker parameter and use it.
9505 (ada_language_defn): Adjust.
9506 * break-catch-syscall.c (catch_syscall_completer): Adjust
9507 prototype and work with completion_tracker instead of VEC.
9508 * breakpoint.c (condition_completer): Adjust prototype and work
9509 with completion_tracker instead of VEC.
9510 * c-lang.c (c_language_defn, cplus_language_defn)
9511 (asm_language_defn, minimal_language_defn): Adjust to renames.
9512 * cli/cli-cmds.c (complete_command): Rework using
9513 completion_tracker. Catch exceptions when completing.
9514 * cli/cli-decode.c (integer_unlimited_completer)
9515 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
9516 with completion_tracker instead of VEC.
9517 * command.h (struct completion_tracker): Forward declare.
9518 (completer_ftype, completer_handle_brkchars_ftype): Change
9519 types.
9520 (complete_on_cmdlist, complete_on_enum): Adjust.
9521 * completer.c: Include <algorithm>.
9522 (struct gdb_completer_state): New.
9523 (current_completion): New global.
9524 (readline_line_completion_function): Delete.
9525 (noop_completer, filename_completer)
9526 (filename_completer_handle_brkchars, complete_files_symbols)
9527 (linespec_location_completer): Adjust to work with a
9528 completion_tracker instead of a VEC.
9529 (string_or_empty): New.
9530 (collect_explicit_location_matches): Adjust to work with a
9531 completion_tracker instead of a VEC.
9532 (explicit_location_completer): Rename to ...
9533 (complete_explicit_location): ... this and adjust to work with a
9534 completion_tracker instead of a VEC.
9535 (location_completer): Adjust to work with a completion_tracker
9536 instead of a VEC.
9537 (add_struct_fields): Adjust to work with a completion_list instead
9538 of VEC.
9539 (expression_completer): Rename to ...
9540 (complete_expression): ... this and adjust to work with a
9541 completion_tracker instead of a VEC. Use complete_files_symbols.
9542 (expression_completer): Reimplement on top of complete_expression.
9543 (symbol_completer): Adjust to work with a completion_tracker
9544 instead of a VEC.
9545 (enum complete_line_internal_reason): Add describing comments.
9546 (complete_line_internal_normal_command): Adjust to work with a
9547 completion_tracker instead of a VEC.
9548 (complete_line_internal): Rename to ...
9549 (complete_line_internal_1): ... this and adjust to work with a
9550 completion_tracker instead of a VEC. Assert TEXT is NULL in the
9551 handle_brkchars phase.
9552 (new_completion_tracker): Delete.
9553 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
9554 complete_line_internal_1.
9555 (free_completion_tracker): Delete.
9556 (INITIAL_COMPLETION_HTAB_SIZE): New.
9557 (completion_tracker::completion_tracker)
9558 (completion_tracker::~completion_tracker): New.
9559 (maybe_add_completion): Delete.
9560 (completion_tracker::maybe_add_completion)
9561 (completion_tracker::add_completion)
9562 (completion_tracker::add_completions): New.
9563 (throw_max_completions_reached_error): Delete.
9564 (complete_line): Adjust to work with a completion_tracker instead
9565 of a VEC. Don't create a completion_tracker_t or check for max
9566 completions here.
9567 (command_completer, command_completer_handle_brkchars)
9568 (signal_completer, reg_or_group_completer_1)
9569 (reg_or_group_completer, default_completer_handle_brkchars):
9570 Adjust to work with a completion_tracker.
9571 (gdb_completion_word_break_characters_throw): New.
9572 (gdb_completion_word_break_characters): Reimplement.
9573 (line_completion_function): Delete.
9574 (completion_tracker::recompute_lowest_common_denominator)
9575 (expand_preserving_ws)
9576 (completion_tracker::build_completion_result)
9577 (completion_result::completion_result)
9578 (completion_result::completion_result)
9579 (completion_result::~completion_result)
9580 (completion_result::completion_result)
9581 (completion_result::release_match_list, compare_cstrings)
9582 (completion_result::sort_match_list)
9583 (completion_result::reset_match_list)
9584 (gdb_rl_attempted_completion_function_throw)
9585 (gdb_rl_attempted_completion_function): New.
9586 * completer.h (completion_list, struct completion_result)
9587 (class completion_tracker): New.
9588 (complete_line): Add completion_tracker parameter.
9589 (readline_line_completion_function): Delete.
9590 (gdb_rl_attempted_completion_function): New.
9591 (noop_completer, filename_completer, expression_completer)
9592 (location_completer, symbol_completer, command_completer)
9593 (signal_completer, reg_or_group_completer): Update prototypes.
9594 (completion_tracker_t, new_completion_tracker)
9595 (make_cleanup_free_completion_tracker): Delete.
9596 (enum maybe_add_completion_enum): Delete.
9597 (maybe_add_completion): Delete.
9598 (throw_max_completions_reached_error): Delete.
9599 * corefile.c (complete_set_gnutarget): Adjust to work with a
9600 completion_tracker instead of a VEC.
9601 * cp-abi.c (cp_abi_completer): Adjust to work with a
9602 completion_tracker instead of a VEC.
9603 * d-lang.c (d_language_defn): Adjust.
9604 * disasm.c (disassembler_options_completer): Adjust to work with a
9605 completion_tracker instead of a VEC.
9606 * f-lang.c (f_make_symbol_completion_list): Rename to ...
9607 (f_collect_symbol_completion_matches): ... this. Adjust to work
9608 with a completion_tracker instead of a VEC.
9609 (f_language_defn): Adjust.
9610 * go-lang.c (go_language_defn): Adjust.
9611 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
9612 Adjust to work with a completion_tracker instead of a VEC.
9613 * infrun.c (handle_completer): Likewise.
9614 * interps.c (interpreter_completer): Likewise.
9615 * interps.h (interpreter_completer): Likewise.
9616 * language.c (unknown_language_defn, auto_language_defn)
9617 (local_language_defn): Adjust.
9618 * language.h (language_defn::la_make_symbol_completion_list):
9619 Rename to ...
9620 (language_defn::la_collect_symbol_completion_matches): ... this
9621 and adjust to work with a completion_tracker instead of a VEC.
9622 * m2-lang.c (m2_language_defn): Adjust.
9623 * objc-lang.c (objc_language_defn): Adjust.
9624 * opencl-lang.c (opencl_language_defn): Adjust.
9625 * p-lang.c (pascal_language_defn): Adjust.
9626 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
9627 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
9628 with a completion_tracker.
9629 * rust-lang.c (rust_language_defn): Adjust.
9630 * symtab.c (free_completion_list, do_free_completion_list)
9631 (return_val, completion_tracker): Delete.
9632 (completion_list_add_name, completion_list_add_symbol)
9633 (completion_list_add_msymbol, completion_list_objc_symbol)
9634 (completion_list_add_fields, add_symtab_completions): Add
9635 completion_tracker parameter and use it.
9636 (default_make_symbol_completion_list_break_on_1): Rename to...
9637 (default_collect_symbol_completion_matches_break_on): ... this.
9638 Add completion_tracker parameter and use it instead of allocating
9639 a completion tracker here.
9640 (default_make_symbol_completion_list_break_on): Delete old
9641 implementation.
9642 (default_make_symbol_completion_list): Delete.
9643 (default_collect_symbol_completion_matches): New.
9644 (make_symbol_completion_list): Delete.
9645 (collect_symbol_completion_matches): New.
9646 (make_symbol_completion_type): Rename to ...
9647 (collect_symbol_completion_matches_type): ... this. Add
9648 completion_tracker parameter and use it instead of VEC.
9649 (make_file_symbol_completion_list_1): Rename to...
9650 (collect_file_symbol_completion_matches): ... this. Add
9651 completion_tracker parameter and use it instead of VEC.
9652 (make_file_symbol_completion_list): Delete.
9653 (add_filename_to_list): Use completion_list instead of a VEC.
9654 (add_partial_filename_data::list): Now a completion_list.
9655 (make_source_files_completion_list): Work with a completion_list
9656 instead of a VEC.
9657 * symtab.h: Include "completer.h".
9658 (default_make_symbol_completion_list_break_on)
9659 (default_make_symbol_completion_list, make_symbol_completion_list)
9660 (make_symbol_completion_type, make_file_symbol_completion_list)
9661 (make_source_files_completion_list): Delete.
9662 (default_collect_symbol_completion_matches_break_on)
9663 (default_collect_symbol_completion_matches)
9664 (collect_symbol_completion_matches)
9665 (collect_symbol_completion_matches_type)
9666 (collect_file_symbol_completion_matches)
9667 (make_source_files_completion_list): New.
9668 * top.c (init_main): Don't install a rl_completion_entry_function
9669 hook. Install a rl_attempted_completion_function hook instead.
9670 * tui/tui-layout.c (layout_completer): Adjust to work with a
9671 completion_tracker.
9672 * tui/tui-regs.c (tui_reggroup_completer):
9673 * tui/tui-win.c (window_name_completer, focus_completer)
9674 (winheight_completer): Adjust to work with a completion_tracker.
9675 * value.c: Include "completer.h".
9676 (complete_internalvar): Adjust to work with a completion_tracker.
9677 * value.h (complete_internalvar): Likewise.
9678
6e1dbf8c
PA
96792017-07-17 Pedro Alves <palves@redhat.com>
9680
9681 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
9682 renames.
9683 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
9684 comments to completer_ftype's declaration.
9685 <completer_handle_brkchars>: Change type to
9686 completer_handle_brkchars_ftype.
9687 * command.h (completer_ftype): Add describing comment and give
9688 names to parameters.
9689 (completer_ftype_void): Rename to ...
9690 (completer_handle_brkchars_ftype) ... this. Add describing comment.
9691 (set_cmd_completer_handle_brkchars): Adjust.
9692 * completer.c (filename_completer_handle_brkchars): New function.
9693 (complete_line_internal_normal_command): New function, factored
9694 out from ...
9695 (complete_line_internal): ... here.
9696 (command_completer_handle_brkchars)
9697 (default_completer_handle_brkchars)
9698 (completer_handle_brkchars_func_for_completer): New functions.
9699 * completer.h (set_gdb_completion_word_break_characters): Delete
9700 declaration.
9701 (completer_handle_brkchars_func_for_completer): New declaration.
9702 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
9703 completer_handle_brkchars_func_for_completer.
9704
78b13106
PA
97052017-07-17 Pedro Alves <palves@redhat.com>
9706
9707 * completer.c (symbol_completer): New function, based on
9708 make_symbol_completion_list_fn.
9709 * completer.h (symbol_completer): New declaration.
9710 * guile/scm-cmd.c (cmdscm_completers): Adjust.
9711 * python/py-cmd.c (completers): Adjust.
9712 * symtab.c (make_symbol_completion_list_fn): Delete.
9713 * symtab.h (make_symbol_completion_list_fn): Delete.
9714 * cli/cli-decode.c (add_cmd): Adjust.
9715
bbf2f4df
PA
97162017-07-17 Pedro Alves <palves@redhat.com>
9717
9718 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
9719 * dwarf2read.c: Include "filename-seen-cache.h".
9720 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
9721 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
9722 * filename-seen-cache.c: New file.
9723 * filename-seen-cache.h: New file.
9724 * symtab.c: Include "filename-seen-cache.h".
9725 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
9726 (create_filename_seen_cache, clear_filename_seen_cache)
9727 (delete_filename_seen_cache, filename_seen): Delete, parts moved
9728 to filename-seen-cache.h/filename-seen-cache.c.
9729 (output_source_filename, sources_info)
9730 (maybe_add_partial_symtab_filename)
9731 (make_source_files_completion_list): Adjust to use
9732 filename_seen_cache.
9733
330cdd98
PA
97342017-07-17 Pedro Alves <palves@redhat.com>
9735
9736 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
9737 fields.
9738 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
9739 dwarf2_debug_sections*)): New.
9740 (dwarf2_per_objfile::dwarf2_per_objfile(const
9741 dwarf2_per_objfile&)): Declare as deleted.
9742 (dwarf2_per_objfile::operator=): Declare as deleted.
9743 (dwarf2_per_objfile::dwarf2_per_objfile)
9744 (dwarf2_per_objfile::~dwarf2_per_objfile)
9745 (dwarf2_per_objfile::free_cached_comp_units): New.
9746 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
9747 ctor. Call dwarf2_per_objfile's ctor manually.
9748 (dwarf2_locate_sections): Deleted/refactored as ...
9749 (dwarf2_per_objfile::locate_sections): ... this new method.
9750 (free_cached_comp_units): Defer to
9751 dwarf2_per_objfile::free_cached_comp_units.
9752 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
9753
8880f2a9
TT
97542017-07-14 Tom Tromey <tom@tromey.com>
9755
9756 PR rust/21764:
9757 * rust-exp.y (convert_ast_to_expression): Add "want_type"
9758 parameter.
9759 <UNOP_SIZEOF>: Split into separate case.
9760 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
9761
65547233
TT
97622017-07-14 Tom Tromey <tom@tromey.com>
9763
9764 PR rust/21763:
9765 * symtab.c (symbol_matches_domain): Add language_rust to special
9766 case.
9767 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
9768 treat LOC_TYPEDEF symbols as variables.
9769
8f14146e
PA
97702017-07-14 Pedro Alves <palves@redhat.com>
9771
9772 * symtab.c (make_file_symbol_completion_list_1): Iterate over
9773 symtabs matching all symtabs with SRCFILE as file name instead of
9774 only considering the first hit, with lookup_symtab.
9775
2347965c
SM
97762017-07-14 Simon Marchi <simon.marchi@ericsson.com>
9777
9778 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
9779 operator_name parameters.
9780 (gen_expr): Update function call.
9781
40f4af28
SM
97822017-07-14 Simon Marchi <simon.marchi@ericsson.com>
9783
9784 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
9785 parameter.
9786 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
9787 Likewise.
9788 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
9789 parameter, use agent_expr::gdbarch instead, update function
9790 calls.
9791 (locexpr_tracepoint_var_ref): Likewise.
9792 (loclist_tracepoint_var_ref): Likewise.
9793 * ax-gdb.c (gen_trace_static_fields): Likewise.
9794 (gen_traced_pop): Likewise.
9795 (gen_frame_args_address): Likewise.
9796 (gen_frame_locals_address): Likewise.
9797 (gen_var_ref): Likewise.
9798 (gen_struct_ref_recursive): Likewise.
9799 (gen_static_field): Likewise.
9800 (gen_maybe_namespace_elt): Likewise.
9801 (gen_expr): Likewise.
9802 (gen_trace_for_var): Likewise.
9803 (gen_trace_for_expr): Likewise.
9804 (gen_trace_for_return_address): Likewise.
9805
053f8057
SM
98062017-07-14 Simon Marchi <simon.marchi@ericsson.com>
9807
9808 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
9809 parameter.
9810 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
9811
6661ad48
SM
98122017-07-14 Simon Marchi <simon.marchi@ericsson.com>
9813
9814 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
9815 from ax, update calls.
9816 (gen_usual_arithmetic): Likewise.
9817 (gen_integral_promotions): Likewise.
9818 (gen_bitfield_ref): Likewise.
9819 (gen_primitive_field): Likewise.
9820 (gen_struct_ref_recursive): Likewise.
9821 (gen_struct_ref): Likewise.
9822 (gen_maybe_namespace_elt): Likewise.
9823 (gen_struct_elt_for_reference): Likewise.
9824 (gen_namespace_elt): Likewise.
9825 (gen_aggregate_elt_ref): Likewise.
9826 (gen_expr): Get gdbarch from ax, update calls.
9827 (gen_expr_binop_rest): Likewise.
9828
c55a47e7
PA
98292017-07-13 Pedro Alves <palves@redhat.com>
9830
9831 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
9832 as default tdesc.
9833 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
9834 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
9835 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
9836 tdesc_amd64_linux as default tdesc. Get final tdesc from the
9837 tdep.
9838 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
9839 Get final tdesc from the tdep.
9840 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
9841 default tdesc.
9842 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
9843 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
9844 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
9845 Use it as default tdesc.
9846 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
9847 down to amd_init_abi. No longer handle fallback tdesc here.
9848 * amd64-tdep.h (tdesc_x32): Declare.
9849 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
9850 parameter.
9851 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
9852 as default tdesc.
9853
55efceab
AA
98542017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9855
9856 * s390-linux-tdep.c (s390_process_record): Add support for
9857 instructions new in arch12.
9858
0aa37b65
JB
98592017-07-11 John Baldwin <jhb@FreeBSD.org>
9860
9861 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
9862 PT_GETFSBASE and PT_GETGSBASE.
9863 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
9864 PT_SETGSBASE.
9865
48aeef91
JB
98662017-07-11 John Baldwin <jhb@FreeBSD.org>
9867
9868 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
9869 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
9870 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
9871 those rules.
9872 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
9873 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
9874 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
9875 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
9876 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
9877 * features/i386/amd64.xml: Add 64bit-segments.xml.
9878 * features/i386/amd64-avx-avx512.c: Regenerated.
9879 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
9880 * features/i386/amd64-avx-mpx.c: Regenerated.
9881 * features/i386/amd64-avx.c: Regenerated.
9882 * features/i386/amd64-mpx.c: Regenerated.
9883 * features/i386/amd64.c: Regenerated.
9884 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
9885 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
9886 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
9887 * regformats/i386/amd64-avx.dat: Regenerated.
9888 * regformats/i386/amd64-mpx.dat: Regenerated.
9889 * regformats/i386/amd64.dat: Regenerated.
9890
77c501bc
YQ
98912017-07-10 Yao Qi <yao.qi@linaro.org>
9892
9893 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
9894 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
9895
6dc8d757
AK
98962017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
9897
9898 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
9899 unsetenv.
9900 * gnulib/aclocal.m4: Regenerate.
9901 * gnulib/config.in: Regenerate.
9902 * gnulib/configure: Regenerate.
9903 * gnulib/import/Makefile.am: Regenerate.
9904 * gnulib/import/Makefile.in: Regenerate.
9905 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
9906 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
9907 * gnulib/import/m4/environ.m4: New file.
9908 * gnulib/import/m4/setenv.m4: New file.
9909 * gnulib/import/setenv.c: New file.
9910 * gnulib/import/unsetenv.c: New file.
9911
266934d1
SM
99122017-07-09 Simon Marchi <simon.marchi@ericsson.com>
9913
9914 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
9915 address when op is DW_OP_addr.
9916
03278692
TT
99172017-07-09 Tom Tromey <tom@tromey.com>
9918
9919 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
9920 check and apply to outer type.
9921
4b654465
JB
99222017-07-07 John Baldwin <jhb@FreeBSD.org>
9923
9924 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
9925 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
9926 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
9927 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
9928
2af9fc44
JB
99292017-07-07 John Baldwin <jhb@FreeBSD.org>
9930
9931 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
9932
382b69bb
JB
99332017-07-07 John Baldwin <jhb@FreeBSD.org>
9934
9935 * corelow.c (get_core_siginfo): Remove.
9936 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
9937 instead of get_core_siginfo.
9938 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
9939 * gdbarch.h: Re-generate.
9940 * gdbarch.c: Re-generate.
9941 * linux-tdep.c (linux_core_xfer_siginfo): New.
9942 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
9943
6e5eab33
JB
99442017-07-07 John Baldwin <jhb@FreeBSD.org>
9945
9946 * corelow.c (thread_section_name): Move to ...
9947 * gdbcore.h (thread_section_name): ... here.
9948
929edea9
JB
99492017-07-07 John Baldwin <jhb@FreeBSD.org>
9950
9951 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
9952 (struct siginfo32): New.
9953 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
9954 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
9955 via ptrace(PT_LWPINFO).
9956
762c974a
JB
99572017-07-07 John Baldwin <jhb@FreeBSD.org>
9958
9959 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
9960 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
9961 (fbsd_get_siginfo_type): New.
9962 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
9963 (_initialize_fbsd_tdep): New.
9964
33c5cd75
DB
99652017-07-06 David Blaikie <dblaikie@gmail.com>
9966
9967 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
9968 a singular dwo_unit*) to support multiple CUs in the same way that
9969 multiple TUs are supported.
9970 (create_cus_hash_table): Replace create_dwo_cu with a function for
9971 parsing multiple CUs from a DWO file.
9972 (open_and_init_dwo_file): Use create_cus_hash_table rather than
9973 create_dwo_cu.
9974 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
9975 htab_find, rather than comparing the signature to a singleton CU in
9976 the dwo_file.
9977
8455d262
PA
99782017-07-06 Pedro Alves <palves@redhat.com>
9979
9980 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
9981
4da3eb35
PA
99822017-07-04 Pedro Alves <palves@redhat.com>
9983
9984 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
9985 * gdbtypes.h (TYPE_STATIC): Delete.
9986 (struct fn_field) <is_public, is_abstract, is_static, is_final,
9987 is_synchronized, is_native>: Delete.
9988 <dummy>: Bump.
9989 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
9990 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
9991 (TYPE_FN_FIELD_ABSTRACT): Delete.
9992
5bfd255c
SM
99932017-07-03 Simon Marchi <simon.marchi@ericsson.com>
9994
9995 * buffer.h (buffer_finish): Fix spelling mistakes.
9996
25c54127
EZ
99972017-07-01 Eli Zaretskii <eliz@gnu.org>
9998
9999 * .dir-locals.el: Automatically switch to C-style comments in
10000 versions of Emacs that support the feature.
10001
dc4bde35
SDJ
100022017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
10003 Pedro Alves <palves@redhat.com>
10004
10005 PR cli/21688
10006 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
10007 (process_next_line): New variable 'inline_cmd'.
10008 Adjust 'if' clauses for "python", "compile" and "guile" to use
10009 'command_name_equals' and check for '!inline_cmd'.
10010
51ed89aa
SDJ
100112017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
10012
10013 PR cli/21688
10014 * cli/cli-script.c (command_name_equals_not_inline): New function.
10015 (process_next_line): Adjust 'if' clauses for "python", "compile"
10016 and "guile" to use command_name_equals_not_inline.
10017
eb17d413
PA
100182017-06-29 Pedro Alves <palves@redhat.com>
10019
10020 * completer.c (expression_completer): Call
10021 linespec_location_completer instead of location_completer.
10022
195bcdd5
PA
100232017-06-29 Pedro Alves <palves@redhat.com>
10024
10025 * completer.c (expression_completer): Remove code that recomputes
10026 'text' from 'word'.
10027
adc764e7
YQ
100282017-06-29 Yao Qi <yao.qi@linaro.org>
10029
10030 * regformats/regdat.sh: Generate code with
10031 "ifndef IN_PROCESS_AGENT".
10032
6e75794e
PA
100332017-06-28 Pedro Alves <palves@redhat.com>
10034
10035 * command.h: Include "common/scoped_restore.h".
10036
bc491f2e
YQ
100372017-06-28 Yao Qi <yao.qi@linaro.org>
10038
10039 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
10040 instead of obstack_grow.
10041
41664b45
DG
100422017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
10043
10044 PR gdb/21337
10045 * symfile.c (reread_symbols): Call objfiles_changed just before
10046 read_symbols.
10047
6da67eb1
PA
100482017-06-27 Pedro Alves <palves@redhat.com>
10049
10050 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
10051 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
10052 (completion_list_add_symbol, completion_list_add_msymbol):
10053 ... these new functions.
10054 (add_symtab_completions)
10055 (default_make_symbol_completion_list_break_on_1): Adjust.
10056
23732b1e
PA
100572017-06-27 Pedro Alves <palves@redhat.com>
10058
10059 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
10060 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
10061 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
10062 dtor.
10063 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
10064 'storage_obstack' field an auto_obstack. In-class initialize all
10065 non-bitfield fields. Make minsyms_read bool.
10066 * symfile.c (read_symbols): Adjust.
10067
a4d1e79a
AH
100682017-06-27 Alan Hayward <alan.hayward@arm.com>
10069
10070 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
10071 (gdbsim_store_register): Likewise.
10072
8268c778
PA
100732017-06-27 Pedro Alves <palves@redhat.com>
10074
10075 * c-exp.y (name_obstack): Now an auto_obstack.
10076 (yylex): Use auto_obstack::clear.
10077 (c_parse): Use auto_obstack::clear instead of reinitializing and
10078 freeing the obstack.
10079 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
10080 * d-exp.y (name_obstack): Now an auto_obstack.
10081 (yylex): Use auto_obstack::clear.
10082 (d_parse): Use auto_obstack::clear instead of reinitializing and
10083 freeing the obstack.
10084 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
10085 auto_obstack.
10086 * dwarf2read.c (create_addrmap_from_index)
10087 (dwarf2_build_psymtabs_hard)
10088 (update_enumeration_type_from_children): Likewise.
10089 * gdb_obstack.h (auto_obstack): New type.
10090 * go-exp.y (name_obstack): Now an auto_obstack.
10091 (build_packaged_name): Use auto_obstack::clear.
10092 (go_parse): Use auto_obstack::clear instead of reinitializing and
10093 freeing the obstack.
10094 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
10095 auto_obstack.
10096 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
10097 * rust-exp.y (work_obstack): Now an auto_obstack.
10098 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
10099 reinitializing and freeing the obstack.
10100 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
10101 (host_char_to_target): Use auto_obstack.
10102 * utils.h (make_cleanup_obstack_free): Delete declaration.
10103 * valprint.c (generic_emit_char, generic_printstr): Use
10104 auto_obstack.
10105
db665f42
SM
101062017-06-27 Simon Marchi <simon.marchi@ericsson.com>
10107
10108 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
10109 thread.
10110 (darwin_init_thread_list): Don't update dummy thread.
10111 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
10112
873c0814
SM
101132017-06-26 Simon Marchi <simon.marchi@ericsson.com>
10114
10115 * record-full.c (netorder16): Remove.
10116
8b5a7a6e
SM
101172017-06-26 Simon Marchi <simon.marchi@ericsson.com>
10118
10119 * common/diagnostics.h: Define macros for GCC.
10120 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
10121 * common/vec.h: Include diagnostics.h.
10122 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
10123 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
10124 warning.
10125
d1435379
SM
101262017-06-26 Simon Marchi <simon.marchi@ericsson.com>
10127
10128 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
10129 New macro.
10130 * ada-lex.l: Ignore deprecated register warnings.
10131
cc75e0fd
SM
101322017-06-25 Simon Marchi <simon.marchi@ericsson.com>
10133
10134 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
10135 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
10136
07809eaf
SM
101372017-06-25 Simon Marchi <simon.marchi@ericsson.com>
10138
10139 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
10140 its own line.
10141
f076f034
SM
101422017-06-25 Simon Marchi <simon.marchi@ericsson.com>
10143
10144 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
10145
0dd5cbc5
AH
101462017-06-23 Alan Hayward <alan.hayward@arm.com>
10147
10148 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
10149 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
10150 (xtensa_register_read_masked): Likewise.
10151
d4c6ce5b
SDJ
101522017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
10153
10154 * common/environ.c (gdb_environ::unset): Update comment.
10155
16892a03
AH
101562017-06-22 Alan Hayward <alan.hayward@arm.com>
10157
10158 * python/py-unwind.c (pyuw_sniffer): Allocate space for
10159 registers.
10160
d7dcbefc
AH
101612017-06-22 Alan Hayward <alan.hayward@arm.com>
10162
10163 * record-full.c (record_full_exec_insn): Use byte_vector.
10164
b30ff123
YQ
101652017-06-22 Yao Qi <yao.qi@linaro.org>
10166
10167 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
10168 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
10169
4fa847d7
AH
101702017-06-22 Alan Hayward <alan.hayward@arm.com>
10171
10172 * remote.c (cached_reg): Move from here...
10173 * regcache.h (cached_reg): ...to here.
10174 * python/py-unwind.c (struct reg_info): Remove.
10175 (cached_frame_info): Use cached_reg_t.
10176 (pyuw_prev_register): Likewise.
10177 (pyuw_sniffer): Use cached_reg_t and allocate registers.
10178 (pyuw_dealloc_cache): Free all registers.
10179
f4906a9a
PA
101802017-06-22 Pedro Alves <palves@redhat.com>
10181 Simon Marchi <simon.marchi@ericsson.com>
10182
10183 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
10184 warning.
10185 * common/diagnostics.h: New file.
10186
b45a1208
PA
101872017-06-22 Pedro Alves <palves@redhat.com>
10188
10189 * common/agent.h: Add include guards.
10190
e4da2c61
SM
101912017-06-21 Simon Marchi <simon.marchi@ericsson.com>
10192
10193 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
10194 talk about addressable units instead of bytes.
10195
96160d60
SDJ
101962017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
10197
10198 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
10199 of '::const_iterator'.
10200
9a6c7d9c
SDJ
102012017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
10202
10203 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10204 'unittests/environ-selftests.c'.
10205 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
10206 * charset.c (find_charset_names): Declare object 'iconv_env'.
10207 Update code to use 'iconv_env' object. Remove call to
10208 'free_environ'.
10209 * common/environ.c: Include <utility>.
10210 (make_environ): Delete function.
10211 (free_environ): Delete function.
10212 (gdb_environ::clear): New function.
10213 (gdb_environ::operator=): New function.
10214 (gdb_environ::get): Likewise.
10215 (environ_vector): Delete function.
10216 (set_in_environ): Delete function.
10217 (gdb_environ::set): New function.
10218 (unset_in_environ): Delete function.
10219 (gdb_environ::unset): New function.
10220 (gdb_environ::envp): Likewise.
10221 * common/environ.h: Include <vector>.
10222 (struct gdb_environ): Delete; transform into...
10223 (class gdb_environ): ... this class.
10224 (free_environ): Delete prototype.
10225 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
10226 environ_vector): Likewise.
10227 * infcmd.c (run_command_1): Update code to call
10228 'envp' from 'gdb_environ' class.
10229 (environment_info): Update code to call methods from 'gdb_environ'
10230 class.
10231 (unset_environment_command): Likewise.
10232 (path_info): Likewise.
10233 (path_command): Likewise.
10234 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
10235 (inferior::inferior): Initialize 'environment' using the host's
10236 information.
10237 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
10238 Include "environ.h".
10239 (class inferior) <environment>: Change type from 'struct
10240 gdb_environ' to 'gdb_environ'.
10241 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
10242 methods from 'gdb_environ' class.
10243 * solib.c (solib_find_1): Likewise
10244 * unittests/environ-selftests.c: New file.
10245
75c554cf
YQ
102462017-06-20 Yao Qi <yao.qi@linaro.org>
10247
10248 * features/i386/i386-linux.xml: Exchange the order of including
10249 32bit-linux.xml and 32bit-sse.xml.
10250 * features/i386/i386-linux.c: Regenerated.
10251
72ddacb7
YQ
102522017-06-20 Yao Qi <yao.qi@linaro.org>
10253
10254 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
10255 Delete copy ctor and assignment operator.
10256 (tdesc_type): Likewise.
10257 (tdesc_feature): Likewise.
10258 (tdesc_free_reg): Remove.
10259 (tdesc_create_reg): Use new.
10260 (tdesc_free_type): Remove.
10261 (tdesc_create_vector): Use new.
10262 (tdesc_create_union): Likewise.
10263 (tdesc_create_flags): Likewise.
10264 (tdesc_create_enum): Likewise.
10265 (tdesc_free_feature): Delete.
10266 (free_target_description): Use delete.
10267
325c9fd4
JB
102682017-06-19 John Baldwin <jhb@FreeBSD.org>
10269
10270 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
10271 registers.
10272
16b7a719
PA
102732017-06-19 Pedro Alves <palves@redhat.com>
10274
10275 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
10276 after gdb::unlinker.
10277
1c8e01c9
SDJ
102782017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
10279
10280 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
10281 gdb_environ to access an environment variable.
10282
ffce45d2
TP
102832017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
10284
10285 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
10286 gdb_byte*.
10287
1d4fbac9
SM
102882017-06-17 Simon Marchi <simon.marchi@ericsson.com>
10289
10290 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
10291
8465943a
SM
102922017-06-17 Simon Marchi <simon.marchi@ericsson.com>
10293
10294 * configure: Re-generate.
10295 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
10296
3e019bdc
SM
102972017-06-17 Simon Marchi <simon.marchi@ericsson.com>
10298
10299 * configure: Re-generate.
10300 * warning.m4: Pass -Werror to compiler when checking for
10301 supported warning flags.
10302
cf0dd6f0
SM
103032017-06-17 Simon Marchi <simon.marchi@ericsson.com>
10304
10305 * Makefile.in (COMPILE.pre): Add "-x c++".
10306
6f98355c
YQ
103072017-06-16 Alan Hayward <alan.hayward@arm.com>
10308 Pedro Alves <palves@redhat.com>
10309 Yao Qi <yao.qi@linaro.org>
10310
10311 * defs.h (RequireLongest): New.
10312 (extract_integer): Declare function template.
10313 (extract_signed_integer): Remove the declaration, but define it
10314 static inline.
10315 (extract_unsigned_integer): Likewise.
10316 (store_integer): Declare function template.
10317 (store_signed_integer): Remove the declaration, but define it
10318 static inline.
10319 (store_unsigned_integer): Likewise.
10320 * findvar.c (extract_integer): New function template.
10321 (extract_signed_integer): Remove.
10322 (extract_unsigned_integer): Remove.
10323 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
10324 instantiations.
10325 (store_integer): New function template.
10326 (store_signed_integer): Remove.
10327 (store_unsigned_integer): Remove.
10328 (store_integer): Explicit instantiations.
10329 * regcache.c (regcache_raw_read_signed): Update.
10330 (regcache::raw_read): New function.
10331 (regcache::raw_read_signed): Remove.
10332 (regcache::raw_read_unsigned): Remove.
10333 (regcache_raw_read_unsigned): Update.
10334 (regcache_raw_write_unsigned): Update.
10335 (regcache::raw_write_signed): Remove.
10336 (regcache::raw_write): New function.
10337 (regcache_cooked_read_signed): Update.
10338 (regcache::raw_write_unsigned): Remove.
10339 (regcache::cooked_read_signed): Remove.
10340 (regcache_cooked_read_unsigned): Update.
10341 (regcache::cooked_read_unsigned): Remove.
10342 (regcache_cooked_write_signed): Update.
10343 (regcache_cooked_write_unsigned): Update.
10344 * regcache.h (regcache) <raw_read_signed>: Remove.
10345 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
10346 <raw_read, raw_write>: New.
10347 <cooked_read_signed, cooked_write_signed>: Remove.
10348 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
10349 <cooked_read, cooked_write>: New.
10350 * sh64-tdep.c (sh64_pseudo_register_read): Update.
10351 (sh64_pseudo_register_write): Update.
10352
a87dc45a
AK
103532017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
10354
10355 * arc-tdep.c (arc_disassembler_options): New variable.
10356 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
10357 of default_print_insn.
10358 (arc_delayed_print_insn): Set info->section when needed,
10359 use default_print_insn to retrieve a disassembler.
10360
45159d6a
SDJ
103612017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
10362
10363 PR gdb/21574
10364 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
10365 to mention $SHELL and startup-with-shell.
10366
b46c4cf0
MF
103672017-06-14 Max Filippov <jcmvbkbc@gmail.com>
10368
10369 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
10370
6394c606
YQ
103712017-06-14 Yao Qi <yao.qi@linaro.org>
10372
10373 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
10374 default_print_insn instead of print_insn_aarch64.
10375 * arm-tdep.c (gdb_print_insn_arm): Call
10376 default_print_insn instead of print_insn_big_arm
10377 and print_insn_little_arm.
10378 * i386-tdep.c (i386_print_insn): Call default_print_insn
10379 instead of print_insn_i386.
10380 * ia64-tdep.c (ia64_print_insn): Call
10381 default_print_insn instead of print_insn_ia64.
10382 * mips-tdep.c (gdb_print_insn_mips): Call
10383 default_print_insn instead of print_insn_big_mips
10384 and print_insn_little_mips.
10385 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
10386 instead of print_insn_spu.
10387
d5722aa2
PA
103882017-06-14 Pedro Alves <palves@redhat.com>
10389
10390 * ada-lang.c: Include "common/byte-vector.h".
10391 (ada_value_primitive_packed_val): Use gdb::byte_vector.
10392 * charset.c (wchar_iterator::iterate): Resize the vector instead
10393 of reserving it.
10394 * common/byte-vector.h: Include "common/def-vector.h".
10395 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
10396 * cli/cli-dump.c: Include "common/byte-vector.h".
10397 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
10398 * common/byte-vector.h: New file.
10399 * common/def-vector.h: New file.
10400 * common/default-init-alloc.h: New file.
10401 * dwarf2loc.c: Include "common/byte-vector.h".
10402 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
10403 instead of reserving it.
10404 * dwarf2read.c: Include "common/byte-vector.h".
10405 (data_buf::m_vec): Now a gdb::byte_vector.
10406 * gdb_regex.c: Include "common/def-vector.h".
10407 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
10408 * mi/mi-main.c: Include "common/byte-vector.h".
10409 (mi_cmd_data_read_memory): Use gdb::byte_vector.
10410 * printcmd.c: Include "common/byte-vector.h".
10411 (print_scalar_formatted): Use gdb::byte_vector.
10412 * valprint.c: Include "common/byte-vector.h".
10413 (maybe_negate_by_bytes, print_decimal_chars): Use
10414 gdb::byte_vector.
10415
01ec7a27
SM
104162017-06-13 Simon Marchi <simon.marchi@ericsson.com>
10417
10418 * darwin-nat.c: Include "nat/fork-inferior.h".
10419
848d9074
SM
104202017-06-13 Simon Marchi <simon.marchi@ericsson.com>
10421
10422 * configure.nat: Factor out Darwin bits that are not
10423 architecture-specific. Add fork-inferior.o.
10424
3b912944
SM
104252017-06-13 Simon Marchi <simon.marchi@ericsson.com>
10426
10427 * configure.nat: Factor out AIX bits that are not
10428 architecture-specific. Add fork-inferior.o.
10429
55acdf22
AA
104302017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10431
10432 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
10433 (read_pieced_value, write_pieced_value): ...here. Reduce to
10434 wrappers that just call rw_pieced_value.
10435
f65e2044
AA
104362017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10437
10438 * dwarf2loc.c (write_pieced_value): When writing the data for a
10439 memory piece, use write_memory_with_notification instead of
10440 write_memory.
10441
23f945bf
AA
104422017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10443
10444 * valops.c (read_value_memory): Change embedded_offset to
10445 represent a bit offset instead of a byte offset.
10446 * value.h (read_value_memory): Adjust comment.
10447
f236533e
AA
104482017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10449
10450 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
10451 dest_offset_bits and source_offset_bits.
10452 (write_pieced_value): Likewise.
10453
65d84b76
AA
104542017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10455
10456 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
10457 given by DW_OP_bit_piece.
10458 (write_pieced_value): Likewise.
10459
242d31ab
AA
104602017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10461
10462 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
10463 some other preparations to the places where sufficient information
10464 is available.
10465 (write_pieced_value): Likewise.
10466
03c8af18
AA
104672017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10468
10469 * dwarf2loc.c (bits_to_bytes): New function.
10470 (read_pieced_value): Fix offset calculations for register pieces
10471 on big-endian targets.
10472 (write_pieced_value): Likewise.
10473
840989c1
AA
104742017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10475
10476 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
10477 (write_pieced_value): Likewise.
10478
359b19bb
AA
104792017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10480
10481 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
10482 transfer the source value's least significant bits, instead of its
10483 lowest-addressed ones. Rename type_len to max_offset.
10484 (read_pieced_value): Mirror above changes to write_pieced_value as
10485 applicable.
10486
07c9ca3b
AA
104872017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10488
10489 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
10490 truncate full bytes from dest_offset_bits before using it as an
10491 offset into the buffer.
10492
f1cc9874
AA
104932017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10494
10495 * dwarf2loc.c (write_pieced_value): Include transfer size in
10496 byte-wise check.
10497
cdaac320
AA
104982017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10499
10500 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
10501 calculation of this_size.
10502
af547a96
AA
105032017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10504
10505 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
10506 when targeting a bit-field.
10507 (write_pieced_value): Likewise.
10508
ddd7882a
AA
105092017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10510
10511 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
10512 (allocate_piece_closure): Drop addr_size parameter.
10513 (dwarf2_evaluate_loc_desc_full): Adjust call to
10514 allocate_piece_closure.
10515
e9352324
AA
105162017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10517
10518 PR gdb/21226
10519 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
10520 the LSB end, independent of endianness.
10521
d5d1163e
AA
105222017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10523
10524 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
10525 size capping.
10526
032bb6ea
YQ
105272017-06-13 Yao Qi <yao.qi@linaro.org>
10528
10529 * mips-linux-nat.c: Move include features/mips*-linux.c to
10530 mips-linux-tdep.c.
10531 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
10532 to mips-linux-tdep.c.
10533 * mips-linux-tdep.c: Include features/mips*-linux.c
10534 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
10535 functions.
10536 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
10537 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
10538 (tdesc_mips64_dsp_linux): Declare.
10539
f12f6bad
TT
105402017-06-12 Tom Tromey <tom@tromey.com>
10541
10542 * valprint.h (val_print_type_code_int): Remove.
10543 * valprint.c (generic_val_print_int): Always call
10544 val_print_scalar_formatted.
10545 (val_print_type_code_int): Remove.
10546 * printcmd.c (print_scalar_formatted): Handle options->format==0.
10547 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
10548 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
10549 * ada-valprint.c (ada_val_print_num): Use
10550 val_print_scalar_formatted.
10551
d9109c80
TT
105522017-06-12 Tom Tromey <tom@tromey.com>
10553
10554 * printcmd.c (print_scalar_formatted): Unify the two switches.
10555 Don't convert scalars to LONGEST.
10556
4ac0cb1c
TT
105572017-06-12 Tom Tromey <tom@tromey.com>
10558
10559 PR exp/16225:
10560 * valprint.h (print_decimal_chars): Update.
10561 * valprint.c (maybe_negate_by_bytes): New function.
10562 (print_decimal_chars): Add "is_signed" argument.
10563 * printcmd.c (print_scalar_formatted): Update.
10564
30a25466
TT
105652017-06-12 Tom Tromey <tom@tromey.com>
10566
10567 PR exp/16225:
10568 * valprint.h (print_binary_chars, print_hex_chars): Update.
10569 * valprint.c (val_print_type_code_int): Update.
10570 (print_binary_chars): Add "zero_pad" argument.
10571 (emit_octal_digit): New function.
10572 (print_octal_chars): Don't zero-pad.
10573 (print_decimal_chars): Likewise.
10574 (print_hex_chars): Add "zero_pad" argument.
10575 * sh64-tdep.c (sh64_do_fp_register): Update.
10576 * regcache.c (regcache::dump): Update.
10577 * printcmd.c (print_scalar_formatted): Update.
10578 * infcmd.c (default_print_one_register_info): Update.
10579
b3464d03
PA
105802017-06-12 Pedro Alves <palves@redhat.com>
10581 Alan Hayward <alan.hayward@arm.com>
10582
10583 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
10584 (mips_eabi_push_dummy_call): Rename local 'regsize' to
10585 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
10586 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
10587 Assert that abi_regsize bytes fit in 'ref_valbuf'.
10588
4b76cda9
PA
105892017-06-12 Pedro Alves <palves@redhat.com>
10590
10591 * dwarf2read.c (mapped_symtab::data): Now a vector of
10592 symtab_index_entry instead of vector of
10593 std::unique_ptr<symtab_index_entry>. All users adjusted to check
10594 whether an element's name is NULL instead of checking whether the
10595 element itself is NULL.
10596 (find_slot): Change return type. Adjust.
10597 (hash_expand, , add_index_entry, uniquify_cu_indices)
10598 (write_hash_table): Adjust.
10599
e8f8bcb3
PA
106002017-06-12 Pedro Alves <palves@redhat.com>
10601
10602 * dwarf2read.c (recursively_count_psymbols): New function.
10603 (write_psymtabs_to_index): Call it to compute number of psyms and
10604 pass estimate size of psyms_seen to unordered_set's ctor.
10605
70a1152b
PA
106062017-06-12 Pedro Alves <palves@redhat.com>
10607
10608 * dwarf2read.c (write_hash_table): Check if key already exists
10609 before emplacing.
10610
c2f134ac
PA
106112017-06-12 Pedro Alves <palves@redhat.com>
10612
10613 * dwarf2read.c (data_buf::append_space): Rename to...
10614 (data_buf::grow): ... this, and make private. Adjust all callers.
10615 (data_buf::append_uint): New method.
10616 (add_address_entry, write_one_signatured_type)
10617 (write_psymtabs_to_index): Use it.
10618
a81e6d4d
PA
106192017-06-12 Pedro Alves <palves@redhat.com>
10620
10621 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
10622 (file_write (FILE *, const std::vector<Elem>&)): Delete.
10623 (data_buf::file_write): Call ::fwrite directly.
10624
6fd931f2
PA
106252017-06-12 Pedro Alves <palves@redhat.com>
10626
10627 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
10628 std::vector::erase.
10629
bc8f2430
JK
106302017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
10631
10632 Code cleanup: C++ify .gdb_index producer.
10633 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
10634 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
10635 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
10636 (create_strtab, add_string): Remove.
10637 (file_write, data_buf): New.
10638 (struct symtab_index_entry): Use std::vector for cu_indices.
10639 (struct mapped_symtab): Use std::vector for data.
10640 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
10641 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
10642 Remove.
10643 (find_slot): Change return type. Update it to the new data structures.
10644 (hash_expand, add_index_entry): Update it to the new data structures.
10645 (offset_type_compare): Remove.
10646 (uniquify_cu_indices): Update it to the new data structures.
10647 (c_str_view, c_str_view_hasher, vector_hasher): New.
10648 (add_indices_to_cpool): Remove.
10649 (write_hash_table): Update it to the new data structures.
10650 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
10651 (eq_psymtab_cu_index): Remove.
10652 (psym_index_map): New typedef.
10653 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
10654 reference and std::unordered_map for cu_index_htab.
10655 (add_address_entry, add_address_entry_worker, write_address_map)
10656 (write_psymbols): Update it to the new data structures.
10657 (write_obstack): Remove.
10658 (struct signatured_type_index_data): Change types_list to a data_buf
10659 reference and psyms_seen to a std::unordered_set reference.
10660 (write_one_signatured_type, recursively_write_psymbols)
10661 (write_psymtabs_to_index): Update it to the new data structures.
10662
c4dcb155
SM
106632017-06-11 Simon Marchi <simon.marchi@ericsson.com>
10664
10665 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
10666 separate-debug-file commands.
10667 * symfile.h (separate_debug_file_debug): New global.
10668 * symfile.c (separate_debug_file_debug): New global.
10669 (separate_debug_file_exists, find_separate_debug_file): Add
10670 debug output.
10671 (_initialize_symfile): Add "set debug separate-debug-file"
10672 command.
10673 * build-id.c (build_id_to_debug_bfd,
10674 find_separate_debug_file_by_buildid): Add debug output.
10675
6d45d4b4
SM
106762017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
10677
10678 * gdbarch.sh (displaced_step_free_closure): Remove.
10679 * gdbarch.h, gdbarch.c: Re-generate.
10680 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
10681 displaced_step_free_closure.
10682 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
10683 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
10684 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
10685 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
10686 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
10687 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
10688 * arch-utils.h (simple_displaced_step_free_closure): Remove.
10689 * arch-utils.c (simple_displaced_step_free_closure): Remove.
10690 * infrun.c (displaced_step_clear): Call xfree instead of
10691 gdbarch_displaced_step_free_closure.
10692
2f91880f
SDJ
106932017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
10694
10695 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
10696 NULL".
10697
b8b6e72f
AH
106982017-06-08 Alan Hayward <alan.hayward@arm.com>
10699
10700 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
10701 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
10702 (mn10300_push_dummy_call): Likewise.
10703
5369082e
AH
107042017-06-08 Alan Hayward <alan.hayward@arm.com>
10705
10706 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
10707
ff4ca5ac
AH
107082017-06-08 Alan Hayward <alan.hayward@arm.com>
10709
10710 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
10711
aefd8b33
SDJ
107122017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
10713
10714 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
10715 able to start inferiors using a shell.
10716 (New remote packets): Announce new packet "QStartupWithShell".
10717 * remote.c: Add PACKET_QStartupWithShell.
10718 (extended_remote_create_inferior): Handle new
10719 PACKET_QStartupWithShell.
10720 (remote_protocol_features) <QStartupWithShell>: New entry for
10721 PACKET_QStartupWithShell.
10722 (_initialize_remote): Call "add_packet_config_cmd" for
10723 QStartupShell.
10724
2090129c
SDJ
107252017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
10726 Pedro Alves <palves@redhat.com>
10727
10728 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
10729 and "nat/fork-inferior.h".
10730 * common/common-inferior.h: New file, with contents from
10731 "gdb/inferior.h".
10732 * commom/common-utils.c: Include "common-utils.h".
10733 (stringify_argv): New function.
10734 * common/common-utils.h (stringify_argv): New prototype.
10735 * configure.nat: Add "fork-inferior.o" as a dependency for
10736 "*linux*", "fbsd*" and "nbsd*" hosts.
10737 * corefile.c (get_exec_file): Update comment.
10738 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
10739 instead of "startup_inferior".
10740 (darwin_create_inferior): Call "add_thread_silent" after
10741 "fork_inferior".
10742 * fork-child.c: Cleanup unnecessary includes.
10743 (SHELL_FILE): Move to "common/common-fork-child.c".
10744 (environ): Likewise.
10745 (exec_wrapper): Initialize.
10746 (get_exec_wrapper): New function.
10747 (breakup_args): Move to "common/common-fork-child.c"; rename to
10748 "breakup_args_for_exec".
10749 (escape_bang_in_quoted_argument): Move to
10750 "common/common-fork-child.c".
10751 (saved_ui): New variable.
10752 (prefork_hook): New function.
10753 (postfork_hook): Likewise.
10754 (postfork_child_hook): Likewise.
10755 (gdb_startup_inferior): Likewise.
10756 (fork_inferior): Move to "common/common-fork-child.c". Update
10757 function to support gdbserver.
10758 (startup_inferior): Likewise.
10759 * gdbcore.h (get_exec_file): Remove declaration.
10760 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
10761 instead of "startup_inferior". Call "add_thread_silent" after
10762 "fork_inferior".
10763 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
10764 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
10765 instead of "startup_inferior". Call "add_thread_silent" after
10766 "fork_inferior".
10767 * inferior.h: Include "common-inferior.h".
10768 (trace_start_error): Move to "common/common-utils.h".
10769 (trace_start_error_with_name): Likewise.
10770 (fork_inferior): Move prototype to "nat/fork-inferior.h".
10771 (startup_inferior): Likewise.
10772 (gdb_startup_inferior): New prototype.
10773 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
10774 * nat/fork-inferior.h: New file.
10775 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
10776 instead of "startup_inferior". Call "add_thread_silent" after
10777 "fork_inferior".
10778 * target.h (target_terminal_init): Move prototype to
10779 "target/target.h".
10780 (target_terminal_inferior): Likewise.
10781 (target_terminal_ours): Likewise.
10782 * target/target.h (target_terminal_init): New prototype, moved
10783 from "target.h".
10784 (target_terminal_inferior): Likewise.
10785 (target_terminal_ours): Likewise.
10786 * utils.c (gdb_flush_out_err): New function.
10787
043a4934
SDJ
107882017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
10789
10790 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
10791 * common/common-gdbthread.h: New file, with parts from
10792 "gdb/gdbthread.h".
10793 * gdbthread.h: Include "common-gdbthread.h".
10794 (switch_to_thread): Moved to "common/common-gdbthread.h".
10795
15652511
SDJ
107962017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
10797
10798 * Makefile.in (SFILES): Add "common/job-control.c".
10799 (HFILES_NO_SRCDIR): Add "common/job-control.h".
10800 (COMMON_OBS): Add "job-control.o".
10801 * common/job-control.c: New file, with contents from
10802 "gdb/inflow.c".
10803 * common/job-control.h: New file, with contents from "terminal.h".
10804 * fork-child.c: Include "job-control.h".
10805 * inflow.c: Include "job-control.h".
10806 (gdb_setpgid): Move to "common/common-inflow.c".
10807 (_initialize_inflow): Move setting of "job_control" to
10808 "handle_job_control".
10809 * terminal.h (job_control): Moved to "common/common-terminal.h".
10810 (gdb_setpgid): Likewise.
10811 * top.c: Include "job_control.h".
10812 * utils.c: Likewise.
10813 (job_control): Moved to "job-control.c".
10814
2d7cc5c7
PA
108152017-06-07 Pedro Alves <palves@redhat.com>
10816
10817 * Makefile.in (SFILES): Add gdb_regex.c.
10818 (COMMON_OBS): Add gdb_regex.o.
10819 * ada-lang.c (ada_add_standard_exceptions)
10820 (ada_add_exceptions_from_frame, name_matches_regex)
10821 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
10822 parameter type to compiled_regex. Adjust.
10823 (ada_exceptions_list): Use compiled_regex.
10824 * break-catch-throw.c (exception_catchpoint::pattern): Now a
10825 std::unique_ptr<compiled_regex>.
10826 (exception_catchpoint::~exception_catchpoint): Remove regfree
10827 call.
10828 (check_status_exception_catchpoint): Adjust to use compiled_regex.
10829 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
10830 * breakpoint.c (solib_catchpoint::compiled): Now a
10831 std::unique_ptr<compiled_regex>.
10832 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
10833 (check_status_catch_solib): Adjust to use compiled_regex.
10834 (add_solib_catchpoint): Adjust to use compiled_regex.
10835 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
10836 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
10837 compiled_regex reference. Adjust to use it.
10838 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
10839 declaration. Include "gdb_regex.h".
10840 (apropos_cmd): Change regex parameter to compiled_regex reference.
10841 * gdb_regex.c: New file.
10842 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
10843 declarations.
10844 (class compiled_regex): New.
10845 * linux-tdep.c: Include "common/gdb_optional.h".
10846 (struct mapping_regexes): New, factored out from
10847 mapping_is_anonymous_p, and adjusted to use compiled_regex.
10848 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
10849 gdb::optional and remove cleanups. Adjust to compiled_regex.
10850 * probe.c: Include "common/gdb_optional.h".
10851 (collect_probes): Use compiled_regex and gdb::optional and remove
10852 cleanups.
10853 * skip.c: Include "common/gdb_optional.h".
10854 (skiplist_entry::compiled_function_regexp): Now a
10855 gdb::optional<compiled_regex>.
10856 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
10857 (free_skiplist_entry): Remove regfree call.
10858 (compile_skip_regexp, skip_rfunction_p): Adjust to use
10859 compiled_regex and gdb::optional.
10860 * symtab.c: Include "common/gdb_optional.h".
10861 (search_symbols): Use compiled_regex and gdb::optional.
10862 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
10863 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
10864 to gdb_regex.c.
10865
50d6adef
AH
108662017-06-07 Alan Hayward <alan.hayward@arm.com>
10867
10868 * regcache.c (regcache::save): Avoid buffer use.
10869 (regcache::dump): Likewise.
10870
4a8a33c8
AH
108712017-06-07 Alan Hayward <alan.hayward@arm.com>
10872
10873 * sh-tdep.c (sh_pseudo_register_read): Remove
10874 MAX_REGISTER_SIZE.
10875 (sh_pseudo_register_write): Likewise.
10876 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
10877 (sh64_pseudo_register_write): Likewise
10878
d1be909e
AH
108792017-06-07 Alan Hayward <alan.hayward@arm.com>
10880
10881 * aarch64-tdep.c (aarch64_store_return_value): Use
10882 V_REGISTER_SIZE.
10883 (aarch64_pseudo_read_value): Likewise.
10884 (aarch64_pseudo_write): Likewise.
10885
f4a65042
YQ
108862017-06-06 Yao Qi <yao.qi@linaro.org>
10887
10888 * regformats/regdef.h (set_register_cache): Remove the
10889 declaration.
10890
9f7fb0aa
AH
108912017-06-06 Alan Hayward <alan.hayward@arm.com>
10892
10893 * frame.c (frame_unwind_register_signed): Use
10894 frame_unwind_register_value.
10895
e1e01040
PA
108962017-06-06 Pedro Alves <palves@redhat.com>
10897
10898 PR breakpoints/21553
10899 * breakpoint.c (create_breakpoints_sal_default)
10900 (init_breakpoint_sal, create_breakpoint_sal): Use
10901 gdb::unique_xmalloc_ptr for string parameters.
10902 (create_breakpoint): Constify 'extra_string' and 'cond_string'
10903 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
10904 (base_breakpoint_create_breakpoints_sal)
10905 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
10906 (strace_marker_create_breakpoints_sal)
10907 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
10908 string parameters.
10909 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
10910 gdb::unique_xmalloc_ptr for string parameters.
10911 (create_breakpoint): Constify 'extra_string' and 'cond_string'
10912 parameters.
10913
fbe654c8
AH
109142017-06-06 Alan Hayward <alan.hayward@arm.com>
10915
10916 * alpha-tdep.c (alpha_register_to_value): Use
10917 get_frame_register_value.
10918 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
10919
ae0d01d6
AH
109202017-06-06 Alan Hayward <alan.hayward@arm.com>
10921
10922 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
10923 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
10924 (ia64_value_to_register): Likewise.
10925 (ia64_extract_return_value): Likewise.
10926 (ia64_store_return_value): Likewise.
10927 (ia64_push_dummy_call): Likewise.
10928
49cf576c
JB
109292017-06-04 Joel Brobecker <brobecker@adacore.com>
10930
10931 GDB 8.0 released.
10932
26b6a6ab
SM
109332017-06-03 Simon Marchi <simon.marchi@ericsson.com>
10934
10935 * x86-linux-nat.c (struct arch_lwp_info): Remove.
10936
22827c51
SM
109372017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
10938
10939 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
10940 parameter.
10941 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
10942
0e05cf3a
SM
109432017-06-02 Simon Marchi <simon.marchi@ericsson.com>
10944
10945 * event-loop.c (poll_timers): Unallocate timer using delete
10946 instead of xfree.
10947
c1fc2657
SM
109482017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
10949
10950 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
10951 (struct breakpoint) <~breakpoint>: New.
10952 (struct watchpoint): Inherit from breakpoint.
10953 <~watchpoint>: New.
10954 <base>: Remove.
10955 (struct tracepoint): Inherit from breakpoint.
10956 <base>: Remove.
10957 * breakpoint.c (longjmp_breakpoint_ops): Remove.
10958 (struct longjmp_breakpoint): Inherit from breakpoint.
10959 <~longjmp_breakpoint>: New.
10960 <base>: Remove.
10961 (new_breakpoint_from_type): Remove casts.
10962 (watchpoint_in_thread_scope): Remove reference to base field.
10963 (watchpoint_del_at_next_stop): Likewise.
10964 (update_watchpoint): Likewise.
10965 (watchpoint_check): Likewise.
10966 (bpstat_check_watchpoint): Likewise.
10967 (set_longjmp_breakpoint): Likewise.
10968 (struct fork_catchpoint): Inherit from breakpoint.
10969 <base>: Remove.
10970 (struct solib_catchpoint): Inherit from breakpoint.
10971 <~solib_catchpoint>: New.
10972 <base>: Remove.
10973 (dtor_catch_solib): Change to ...
10974 (solib_catchpoint::~solib_catchpoint): ... this.
10975 (breakpoint_hit_catch_solib): Remove reference to base field.
10976 (add_solib_catchpoint): Likewise.
10977 (create_fork_vfork_event_catchpoint): Likewise.
10978 (struct exec_catchpoint): Inherit from breakpoint.
10979 <~exec_catchpoint>: New.
10980 <base>: Remove.
10981 (dtor_catch_exec): Change to ...
10982 (exec_catchpoint::~exec_catchpoint): ... this.
10983 (dtor_watchpoint): Change to ...
10984 (watchpoint::~watchpoint): ... this.
10985 (watch_command_1): Remove reference to base field.
10986 (catch_exec_command_1): Likewise.
10987 (base_breakpoint_dtor): Change to ...
10988 (breakpoint::~breakpoint): ... this.
10989 (base_breakpoint_ops): Remove dtor field value.
10990 (longjmp_bkpt_dtor): Change to ...
10991 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
10992 (strace_marker_create_breakpoints_sal): Remove reference to base
10993 field.
10994 (delete_breakpoint): Don't manually call breakpoint destructor.
10995 (create_tracepoint_from_upload): Remove reference to base field.
10996 (trace_pass_set_count): Likewise.
10997 (initialize_breakpoint_ops): Don't initialize
10998 momentary_breakpoint_ops, don't set dtors.
10999 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
11000 <~ada_catchpoint>: New.
11001 <base>: Remove.
11002 (create_excep_cond_exprs): Remove reference to base field.
11003 (dtor_exception): Change to ...
11004 (ada_catchpoint::~ada_catchpoint): ... this.
11005 (dtor_catch_exception): Remove.
11006 (dtor_catch_exception_unhandled): Remove.
11007 (dtor_catch_assert): Remove.
11008 (create_ada_exception_catchpoint): Remove reference to base
11009 field.
11010 (initialize_ada_catchpoint_ops): Don't set dtors.
11011 * break-catch-sig.c (struct signal_catchpoint): Inherit from
11012 breakpoint.
11013 <~signal_catchpoint>: New.
11014 <base>: Remove.
11015 (signal_catchpoint_dtor): Change to ...
11016 (signal_catchpoint::~signal_catchpoint): ... this.
11017 (create_signal_catchpoint): Remove reference to base field.
11018 (initialize_signal_catchpoint_ops): Don't set dtor.
11019 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
11020 from breakpoint.
11021 <~syscall_catchpoint>: New.
11022 <base>: Remove.
11023 (dtor_catch_syscall): Change to ...
11024 (syscall_catchpoint::~syscall_catchpoint): ... this.
11025 (create_syscall_event_catchpoint): Remove reference to base
11026 field.
11027 (initialize_syscall_catchpoint_ops): Don't set dtor.
11028 * break-catch-throw.c (struct exception_catchpoint): Inherit
11029 from breakpoint.
11030 <~exception_catchpoint>: New.
11031 <base>: Remove.
11032 (dtor_exception_catchpoint): Change to ...
11033 (exception_catchpoint::~exception_catchpoint): ... this.
11034 (handle_gnu_v3_exceptions): Remove reference to base field.
11035 (initialize_throw_catchpoint_ops): Don't set dtor.
11036 * ctf.c (ctf_get_traceframe_address): Remove reference to base
11037 field.
11038 * remote.c (remote_get_tracepoint_status): Likewise.
11039 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
11040 * tracefile.c (tracefile_fetch_registers): Likewise.
11041 * tracepoint.c (actions_command): Likewise.
11042 (validate_actionline): Likewise.
11043 (tfind_1): Likewise.
11044 (get_traceframe_location): Likewise.
11045 (find_matching_tracepoint_location): Likewise.
11046 (parse_tracepoint_status): Likewise.
11047 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
11048
3b0871f4
SM
110492017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
11050
11051 * breakpoint.c (struct longjmp_breakpoint): New struct.
11052 (is_tracepoint_type): Change return type to bool.
11053 (is_longjmp_type): New function.
11054 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
11055 (set_raw_breakpoint_without_location): Use
11056 new_breakpoint_from_type.
11057 (set_raw_breakpoint): Likewise.
11058
a5e364af
SM
110592017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
11060
11061 * breakpoint.c (new_breakpoint_from_type): New function.
11062 (create_breakpoint_sal): Use new_breakpoint_from_type and
11063 unique_ptr.
11064 (create_breakpoint): Likewise.
11065
ae3b3f34
SM
110662017-05-31 Simon Marchi <simon.marchi@ericsson.com>
11067
11068 * memattr.c (mem_info_command): Rename to ...
11069 (info_mem_command): ... this.
11070 (mem_enable_command): Rename to ...
11071 (enable_mem_command): ... this.
11072 (mem_disable_command): Rename to ...
11073 (disable_mem_command): ... this.
11074 (mem_delete_command): Rename to ...
11075 (delete_mem_command): ... this.
11076 (_initialize_mem): Adjust function names.
11077
13ace077
MM
110782017-05-31 Markus Metzger <markus.t.metzger@intel.com>
11079
11080 * btrace.c (handle_pt_insn_events): New.
11081 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
11082 STATUS. Split into this and ...
11083 (handle_pt_insn_event_flags): ... this.
11084
c56ccc05
MM
110852017-05-31 Markus Metzger <markus.t.metzger@intel.com>
11086
11087 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
11088 and struct pt_insn.resynced.
11089 * configure: Regenerated.
11090 * config.in: Regenerated.
11091
08c3f6d2
TW
110922017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11093
11094 * btrace.c (ftrace_find_call_by_number): New function.
11095 (ftrace_new_function): Store objects, not pointers.
11096 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
11097 ftrace_new_gap, ftrace_update_function,
11098 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
11099 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
11100 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
11101 btrace_ends_with_single_insn, btrace_call_get): Account for
11102 btrace_thread_info::functions now storing objects.
11103 * btrace.h (struct btrace_thread_info): Add constructor.
11104 (struct btrace_thread_info) <functions>: Make std::vector.
11105 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
11106 Initialize with default values.
11107 * record-btrace.c (record_btrace_frame_sniffer): Account for
11108 btrace_thread_info::functions now storing objects.
11109
8ffd39f2
TW
111102017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11111
11112 * btrace.c: Remove typedef bfun_s.
11113 (ftrace_new_gap): Directly add gaps to the list of gaps.
11114 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
11115 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
11116 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
11117 instead of gdb VEC.
11118
4aeb0dfc
TW
111192017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11120
11121 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
11122 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
11123 with btrace_thread_info::next_segment and
11124 btrace_thread_info::prev_segment.
11125 * btrace.h: Remove struct btrace_func_link.
11126 (struct btrace_function): Replace pair of function segment pointers
11127 with pair of indices.
11128 * python/py-record-btrace.c (btpy_call_prev_sibling,
11129 btpy_call_next_sibling): Replace references to
11130 btrace_thread_info::segment with btrace_thread_info::next_segment and
11131 btrace_thread_info::prev_segment.
11132 * record-btrace.c (record_btrace_frame_this_id): Use
11133 btrace_find_call_by_number.
11134
eb8f2b9c
TW
111352017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11136
11137 * btrace.c (ftrace_new_function, ftrace_fixup_level,
11138 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
11139 btrace_insn_next, btrace_insn_prev): Remove references to
11140 btrace_thread_info::flow.
11141 * btrace.h (struct btrace_function): Remove FLOW.
11142
42bfe59e
TW
111432017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11144
11145 * btrace.c (ftrace_find_call_by_number): New function.
11146 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
11147 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
11148 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
11149 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
11150 index.
11151 * btrace.h (struct btrace_function): Turn UP into an index.
11152 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
11153 as an index.
11154 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
11155 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
11156 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
11157
b54b03bd
TW
111582017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11159
11160 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
11161 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
11162 ftrace_update_function, ftrace_compute_global_level_offset,
11163 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
11164 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
11165 btrace_insn_end, btrace_is_empty): Remove references to
11166 btrace_thread_info::begin and btrace_thread_info::end.
11167 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
11168 (struct btrace_thread_info) <functions>: Adjust comment.
11169 * record-btrace.c (record_btrace_start_replaying): Remove reference to
11170 btrace_thread_info::begin.
11171
8286623c
TW
111722017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11173
11174 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
11175 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
11176 ftrace_update_function): Remove arguments that implicitly were always
11177 BTINFO->END.
11178 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
11179 Don't pass BTINFO->END.
11180
a0f1b963
TW
111812017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11182
11183 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
11184 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
11185 btrace_find_insn_by_number): Replace function segment pointer with
11186 index.
11187 (btrace_insn_cmp): Simplify.
11188 * btrace.h: (struct btrace_insn_iterator) Rename index to
11189 insn_index. Replace function segment pointer with index into function
11190 segment vector.
11191 * record-btrace.c (record_btrace_call_history): Replace function
11192 segment pointer use with index.
11193 (record_btrace_frame_sniffer): Retrieve function call segment through
11194 vector.
11195 (record_btrace_set_replay): Remove defunc't safety check.
11196
f158f208
TW
111972017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11198
11199 * btrace.c (btrace_ends_with_single_insn): New function.
11200 (btrace_call_get, btrace_call_number, btrace_call_begin,
11201 btrace_call_end, btrace_call_next, btrace_call_prev,
11202 btrace_find_call_by_number): Use index into call segment vector
11203 instead of pointer.
11204 (btrace_call_cmp): Simplify.
11205 * btrace.h (struct btrace_call_iterator): Replace function call segment
11206 pointer with index into vector.
11207 * record-btrace.c (record_btrace_call_history): Use index instead of
11208 pointer.
11209
521103fd
TW
112102017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11211
11212 * btrace.c (btrace_insn_begin, btrace_insn_end,
11213 btrace_find_insn_by_number): Add btinfo to iterator.
11214 * btrace.h (struct btrace_insn_iterator): Add btinfo.
11215
17b89b34
TW
112162017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11217
11218 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
11219 and save pointers directly.
11220 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
11221 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
11222 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
11223 changed signature of functions.
11224 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
11225 (btrace_fetch): Remove code that adds btrace_function pointers to
11226 vector of btrace_functions.
11227 (btrace_clear): Simplify freeing vector of btrace_functions.
11228
2b51eddc
TW
112292017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11230
11231 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
11232 Replace VEC_* with std::vector functions.
11233 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
11234 (struct btrace_thread_info)<functions>: Change type to std::vector.
11235
db6be0d5
SM
112362017-05-30 Simon Marchi <simon.marchi@ericsson.com>
11237
11238 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
11239 "Removed targets and native configurations" up. Merge duplicate
11240 "New commands" sub-sections. Add "New options" sub-sections.
11241
b057297a
AH
112422017-05-26 Alan Hayward <alan.hayward@arm.com>
11243
11244 * defs.h (copy_integer_to_size): New declaration.
11245 * findvar.c (copy_integer_to_size): New function.
11246 (do_cint_test): New selftest function.
11247 (copy_integer_to_size_test): Likewise.
11248 (_initialize_findvar): Likewise.
11249 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
11250 (mips_fbsd_collect_reg): Use raw_collect_integer.
11251 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
11252 (mips64_fill_gregset): Use raw_collect_integer
11253 (mips64_fill_fpregset): Use raw_supply_integer.
11254 * regcache.c (regcache::raw_supply_integer): New function.
11255 (regcache::raw_collect_integer): Likewise.
11256 * regcache.h: (regcache::raw_supply_integer): New declaration.
11257 (regcache::raw_collect_integer): Likewise.
11258
b77b02a5
YQ
112592017-05-24 Yao Qi <yao.qi@linaro.org>
11260
11261 * Makefile.in (SFILES): Add gdbarch-selftests.c.
11262 (COMMON_OBS): Add gdbarch-selftests.o.
11263 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
11264 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
11265 * gdbarch-selftests.c: New file.
11266 * regcache.h (regcache) <~regcache>: Mark it virtual if
11267 GDB_SELF_TEST.
11268 <raw_write>: Likewise.
11269
e521e87e
YQ
112702017-05-24 Yao Qi <yao.qi@linaro.org>
11271
11272 * regcache.c (current_regcache): Change it to
11273 regcache::current_regcache.
11274 (regcache_observer_target_changed): Update.
11275 (regcache_thread_ptid_changed): Make it a regcache static
11276 method.
11277 (regcache_thread_ptid_changed): Update.
11278 (class regcache_access): New.
11279 (current_regcache_test): Update.
11280 (_initialize_regcache): Update.
11281 * regcache.h: Include forward_list.
11282 (regcache): Declare regcache_thread_ptid_changed and declare
11283 registers_changed_ptid as friend.
11284
d8e07dda
YQ
112852017-05-24 Yao Qi <yao.qi@linaro.org>
11286
11287 * i387-tdep.c (i387_register_to_value): Use register_size
11288 instead of TYPE_LENGTH.
11289 * m68k-tdep.c (m68k_register_to_value): Likewise.
11290
8c8f9122
YQ
112912017-05-24 Yao Qi <yao.qi@linaro.org>
11292
11293 * i387-tdep.c (i387_convert_register_p): Return false if type
11294 code isn't TYPE_CODE_FLT.
11295
68fce50f
YQ
112962017-05-24 Yao Qi <yao.qi@linaro.org>
11297
11298 * alpha-tdep.c (alpha_convert_register_p): Return true if type
11299 length is 4.
11300 (alpha_register_to_value): Remove type length check.
11301 (alpha_value_to_register): Likewise.
11302
88954b49
YQ
113032017-05-24 Yao Qi <yao.qi@linaro.org>
11304
11305 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
11306 TYPE_CODE_FLT.
11307
e3ec9b69
YQ
113082017-05-24 Yao Qi <yao.qi@linaro.org>
11309
11310 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
11311 TYPE_CODE_FLT or not.
11312
cdd238da
YQ
113132017-05-24 Yao Qi <yao.qi@linaro.org>
11314
11315 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
11316 * avr-tdep.c (avr_gdbarch_init): Likewise.
11317 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
11318 * cris-tdep.c (cris_gdbarch_init): Likewise.
11319 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
11320 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
11321 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
11322 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
11323 * mep-tdep.c (mep_gdbarch_init): Likewise.
11324 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
11325 * mips-tdep.c (mips_gdbarch_init): Likewise.
11326 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
11327 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
11328 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
11329 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
11330 * v850-tdep.c (v850_gdbarch_init): Likewise.
11331
7a3929c4
YQ
113322017-05-24 Yao Qi <yao.qi@linaro.org>
11333
11334 * selftest-arch.c (tests_with_arch): Call registers_changed
11335 and reinit_frame_cache.
11336 * selftest.c (run_self_tests): Likewise.
11337
f4985dba
YQ
113382017-05-24 Yao Qi <yao.qi@linaro.org>
11339
11340 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
11341 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
11342
ab20fa4a
YQ
113432017-05-24 Yao Qi <yao.qi@linaro.org>
11344
11345 * rl78-tdep.c (rl78_gdbarch_init): Don't call
11346 set_gdbarch_print_insn.
11347
f532ab94
YQ
113482017-05-24 Yao Qi <yao.qi@linaro.org>
11349
11350 * h8300-tdep.c (h8300_gdbarch_init): Don't call
11351 set_gdbarch_print_insn.
11352
39503f82
YQ
113532017-05-24 Yao Qi <yao.qi@linaro.org>
11354
11355 * alpha-tdep.c (alpha_gdbarch_init): Don't call
11356 set_gdbarch_print_insn.
11357 * arc-tdep.c (arc_gdbarch_init): Likewise.
11358 * arch-utils.c: include dis-asm.h.
11359 (default_print_insn): New function.
11360 * arch-utils.h (default_print_insn): Declare.
11361 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
11362 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
11363 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
11364 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
11365 * frv-tdep.c (frv_gdbarch_init): Likewise.
11366 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
11367 * gdbarch.sh (print_insn): Use default_print_insn.
11368 * gdbarch.c: Regenerated.
11369 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
11370 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
11371 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
11372 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
11373 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
11374 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
11375 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
11376 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
11377 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
11378 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
11379 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
11380 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
11381 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
11382 * mt-tdep.c (mt_gdbarch_init): Likewise.
11383 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
11384 * nios2-tdep.c (nios2_print_insn): Remove.
11385 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
11386 * rx-tdep.c (rx_gdbarch_init): Likewise.
11387 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
11388 * score-tdep.c (score_print_insn): Remove.
11389 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
11390 * sh-tdep.c (sh_gdbarch_init): Likewise.
11391 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
11392 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
11393 * tic6x-tdep.c (tic6x_print_insn): Remove.
11394 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
11395 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
11396 * v850-tdep.c (v850_gdbarch_init): Likewise.
11397 * vax-tdep.c (vax_gdbarch_init): Likewise.
11398 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
11399 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
11400
f7241d4f
JB
114012017-05-23 John Baldwin <jhb@FreeBSD.org>
11402
11403 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
11404 (MIPS_FP0_REGNUM): Remove.
11405 (MIPS_FSR_REGNUM): Remove.
11406 (mips_fbsd_supply_fpregs): Use mips_regnum.
11407 (mips_fbsd_supply_gregs): Likewise.
11408 (mips_fbsd_collect_fpregs): Likewise.
11409 (mips_fbsd_collect_gregs): Likewise.
11410
d489d81d
JB
114112017-05-23 John Baldwin <jhb@FreeBSD.org>
11412
11413 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
11414 (getpfpregs_supplies): New function.
11415 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
11416 getfpregs_supplies.
11417 (mips_fbsd_store_inferior_registers): Likewise.
11418
e11b3cdc
PA
114192017-05-22 Pedro Alves <palves@redhat.com>
11420
11421 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
11422 maintainer.
11423
0f068fb5
AH
114242017-05-22 Alan Hayward <alan.hayward@arm.com>
11425
11426 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
11427 (store_register): Likewise.
11428 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
11429 (get_decimal_float_return_value): Likewise.
11430 (do_ppc_sysv_return_value): Likewise.
11431 (ppc64_sysv_abi_push_integer): Likewise.
11432 (ppc64_sysv_abi_push_freg): Likewise.
11433 (ppc64_sysv_abi_return_value_base): Likewise.
11434 (ppc64_sysv_abi_return_value): Likewise.
11435 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
11436 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
11437 * rs6000-nat.c: Likewise.
11438 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
11439 (rs6000_value_to_register): Likewise.
11440 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
11441
e6cf65f2
TT
114422017-05-21 Tom Tromey <tom@tromey.com>
11443
11444 PR rust/21466:
11445 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
11446 arrays as "[T]", not "[T; ]".
11447
43cc5389
TT
114482017-05-19 Tom Tromey <tom@tromey.com>
11449
11450 PR rust/21484:
11451 * rust-lang.c (exp_descriptor_rust): New function.
11452 (rust_language_defn): Use it.
11453 * p-lang.c (pascal_language_defn): Update.
11454 * opencl-lang.c (opencl_language_defn): Update.
11455 * objc-lang.c (objc_language_defn): Update.
11456 * m2-lang.c (m2_language_defn): Update.
11457 * language.h (struct language_defn)
11458 <la_watch_location_expression>: New member.
11459 * language.c (unknown_language_defn, auto_language_defn)
11460 (local_language_defn): Update.
11461 * go-lang.c (go_language_defn): Update.
11462 * f-lang.c (f_language_defn): Update.
11463 * d-lang.c (d_language_defn): Update.
11464 * c-lang.h (c_watch_location_expression): Declare.
11465 * c-lang.c (c_watch_location_expression): New function.
11466 (c_language_defn, cplus_language_defn, asm_language_defn)
11467 (minimal_language_defn): Use it.
11468 * breakpoint.c (watch_command_1): Call
11469 la_watch_location_expression.
11470 * ada-lang.c (ada_language_defn): Update.
11471
7a6e7fcc
RO
114722017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11473
6e7e1744
RO
11474 PR tui/21482
11475 * gdb_curses.h (NOMACROS): Define.
11476 (NCURSES_NOMACROS): Define.
11477
114782017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11479
11480 PR tui/21482
7a6e7fcc
RO
11481 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
11482 arg to char *.
11483 * tui/tui-wingeneral.c (box_win): Likewise.
11484 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
11485 (tui_show_source_line): Likewise.
11486 (tui_show_exec_info_content): Likewise.
11487
1933fd8e
VM
114882017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
11489
11490 * sparc-tdep.c (sparc_structure_return_p)
11491 (sparc_arg_on_registers_p): New functions.
11492 (sparc32_store_arguments): Use them.
11493 * sparc64-tdep.c (sparc64_16_byte_align_p)
11494 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
11495 Handle TYPE_CODE_ARRAY.
11496
21873064
YQ
114972017-05-17 Yao Qi <yao.qi@linaro.org>
11498
11499 * cli/cli-decode.c (add_alias_cmd): New function.
11500 * command.h (add_alias_cmd): Declare.
11501 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
11502 instead call add_alias_cmd.
11503
2b351b19
PA
115042017-05-17 Pedro Alves <palves@redhat.com>
11505
11506 * Makefile.in (nat_extra_makefile_frag): Rename to ...
11507 (nat_makefile_frag): ... this. All references updated.
11508 * configure.ac: Likewise.
11509 * configure.nat: Likewise. Enhance comments.
11510 * configure: Regenerate.
11511
5f2ad7a3
RO
115122017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11513
11514 * procfs.c (procfs_create_inferior): Change prototype to match
11515 definition.
11516
adf3dde5
EZ
115172017-05-13 Eli Zaretskii <eliz@gnu.org>
11518
11519 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
11520 C++ compiler warning.
11521
6830f270
TT
115222017-05-12 Tom Tromey <tom@tromey.com>
11523
11524 PR rust/21483:
11525 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
11526 recurse, just call value_struct_elt directly.
11527
68f2f2e3
TT
115282017-05-12 Tom Tromey <tom@tromey.com>
11529
11530 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
11531 OP_RUST_ARRAY>: Fix.
11532
256afbc2
TT
115332017-05-12 Tom Tromey <tom@tromey.com>
11534
11535 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
11536
94bb8dfe
YQ
115372017-05-09 Yao Qi <yao.qi@linaro.org>
11538
11539 * regcache.c: Include <forward_list>.
11540 (struct regcache_list): Remove.
11541 (current_regcache): Update.
11542 (get_thread_arch_aspace_regcache): Update for std::forward_list.
11543 (regcache_thread_ptid_changed): Likewise.
11544 (registers_changed_ptid): Likewise.
11545 (current_regcache_size): Likewise.
11546
8248946c
YQ
115472017-05-09 Yao Qi <yao.qi@linaro.org>
11548
11549 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
11550 (current_regcache_size): New function.
11551 (current_regcache_test): New function.
11552 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
11553
313c5961
AH
115542017-05-08 Alan Hayward <alan.hayward@arm.com>
11555
11556 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
11557 (print_gp_register_row): Use get_frame_register_value.
11558
27bfc1d1
AH
115592017-05-08 Alan Hayward <alan.hayward@arm.com>
11560
11561 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
11562 (mips_supply_fpregset): Likewise.
11563 (mips64_supply_gregset): Likewise.
11564
146e6c5c
AH
115652017-05-08 Alan Hayward <alan.hayward@arm.com>
11566
11567 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
11568 regcache->raw_supply_zeroed.
11569
e50f25ec
SDJ
115702017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
11571
11572 * configure.nat: Rearrange 'case' statements to match
11573 host before cpu.
11574
21ea5acd
SDJ
115752017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
11576
11577 * Makefile.in: Remove "@host_makefile_frag@". Add variables
11578 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
11579 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
11580 "@nat_extra_makefile_frag@".
11581 (Makefile): Remove dependency on "@frags@".
11582 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
11583 (data-directory/Makefile): Likewise.
11584 * config/aarch64/linux.mh: Deleted; moved contents to
11585 "gdb/configure.nat".
11586 * config/alpha/alpha-linux.mh: Likewise.
11587 * config/alpha/nbsd.mh: Likewise.
11588 * config/arm/linux.mh: Likewise.
11589 * config/arm/nbsdelf.mh: Likewise.
11590 * config/i386/cygwin.mh: Likewise.
11591 * config/i386/cygwin64.mh: Likewise.
11592 * config/i386/darwin.mh: Likewise.
11593 * config/i386/fbsd.mh: Likewise.
11594 * config/i386/fbsd64.mh: Likewise.
11595 * config/i386/go32.mh: Likewise.
11596 * config/i386/i386gnu.mh: Likewise.
11597 * config/i386/i386sol2.mh: Likewise.
11598 * config/i386/linux.mh: Likewise.
11599 * config/i386/linux64.mh: Likewise.
11600 * config/i386/mingw.mh: Likewise.
11601 * config/i386/mingw64.mh: Likewise.
11602 * config/i386/nbsd64.mh: Likewise.
11603 * config/i386/nbsdelf.mh: Likewise.
11604 * config/i386/nto.mh: Likewise.
11605 * config/i386/obsd.mh: Likewise.
11606 * config/i386/obsd64.mh: Likewise.
11607 * config/i386/sol2-64.mh: Likewise.
11608 * config/ia64/linux.mh: Likewise.
11609 * config/m32r/linux.mh: Likewise.
11610 * config/m68k/linux.mh: Likewise.
11611 * config/m68k/nbsdelf.mh: Likewise.
11612 * config/m68k/obsd.mh: Likewise.
11613 * config/m88k/obsd.mh: Likewise.
11614 * config/mips/fbsd.mh: Likewise.
11615 * config/mips/linux.mh: Likewise.
11616 * config/mips/nbsd.mh: Likewise.
11617 * config/mips/obsd64.mh: Likewise.
11618 * config/pa/linux.mh: Likewise.
11619 * config/pa/nbsd.mh: Likewise.
11620 * config/pa/obsd.mh: Likewise.
11621 * config/powerpc/aix.mh: Likewise.
11622 * config/powerpc/fbsd.mh: Likewise.
11623 * config/powerpc/linux.mh: Likewise.
11624 * config/powerpc/nbsd.mh: Likewise.
11625 * config/powerpc/obsd.mh: Likewise.
11626 * config/powerpc/ppc64-linux.mh: Likewise.
11627 * config/powerpc/spu-linux.mh: Likewise.
11628 * config/s390/linux.mh: Likewise.
11629 * config/sh/nbsd.mh: Likewise.
11630 * config/sparc/fbsd.mh: Likewise.
11631 * config/sparc/linux.mh: Likewise.
11632 * config/sparc/linux64.mh: Likewise.
11633 * config/sparc/nbsd64.mh: Likewise.
11634 * config/sparc/nbsdelf.mh: Likewise.
11635 * config/sparc/obsd64.mh: Likewise.
11636 * config/sparc/sol2.mh: Likewise.
11637 * config/tilegx/linux.mh: Likewise.
11638 * config/vax/nbsdelf.mh: Likewise.
11639 * config/vax/obsd.mh: Likewise.
11640 * config/xtensa/linux.mh: Likewise.
11641 * config/i386/i386gnu.mn: New file, with excerpts from
11642 "config/i386/i386gnu.mh".
11643 * configure: Regenerate.
11644 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
11645 *.mh files under "gdb/config".
11646 * configure.nat: New file, with contents from the
11647 "gdb/config/*/*.mh" files.
11648
7ed1acaf
TW
116492017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
11650
11651 * btrace.c (btrace_clear): Free insn vector.
11652
e13cb306
PA
116532017-05-05 Pedro Alves <palves@redhat.com>
11654
11655 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
11656 * configure: Regenerate.
11657
5ed8105e
PA
116582017-05-04 Pedro Alves <palves@redhat.com>
11659
11660 * Makefile.in (SFILES): Add progspace-and-thread.c.
11661 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
11662 (COMMON_OBS): Add progspace-and-thread.o.
11663 * breakpoint.c: Include "progspace-and-thread.h".
11664 (update_inserted_breakpoint_locations)
11665 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
11666 Use scoped_restore_current_pspace_and_thread.
11667 (create_std_terminate_master_breakpoint): Use
11668 scoped_restore_current_program_space.
11669 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
11670 (print_breakpoint_location): Use
11671 scoped_restore_current_program_space.
11672 (bp_loc_is_permanent): Use
11673 scoped_restore_current_pspace_and_thread.
11674 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
11675 (download_tracepoint_locations): Use
11676 scoped_restore_current_pspace_and_thread.
11677 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
11678 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
11679 (enum step_over_calls_kind): Moved from inferior.h.
11680 (class scoped_restore_current_thread): New class.
11681 * gdbthread.h (make_cleanup_restore_current_thread): Delete
11682 declaration.
11683 (scoped_restore_current_thread): New class.
11684 * infcmd.c: Include "common/gdb_optional.h".
11685 (continue_1, proceed_after_attach): Use
11686 scoped_restore_current_thread.
11687 (notice_new_inferior): Use scoped_restore_current_thread.
11688 * inferior.c: Include "progspace-and-thread.h".
11689 (restore_inferior, save_current_inferior): Delete.
11690 (add_inferior_command, clone_inferior_command): Use
11691 scoped_restore_current_pspace_and_thread.
11692 * inferior.h (scoped_restore_current_inferior): New class.
11693 * infrun.c: Include "progspace-and-thread.h" and
11694 "common/gdb_optional.h".
11695 (follow_fork_inferior): Use
11696 scoped_restore_current_pspace_and_thread.
11697 (scoped_restore_exited_inferior): New class.
11698 (handle_vfork_child_exec_or_exit): Use
11699 scoped_restore_exited_inferior,
11700 scoped_restore_current_pspace_and_thread,
11701 scoped_restore_current_thread and scoped_restore.
11702 (fetch_inferior_event): Use scoped_restore_current_thread.
11703 * linespec.c (decode_line_full, decode_line_1): Use
11704 scoped_restore_current_program_space.
11705 * mi/mi-main.c: Include "progspace-and-thread.h".
11706 (exec_continue): Use scoped_restore_current_thread.
11707 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
11708 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
11709 * proc-service.c (ps_pglobal_lookup): Use
11710 scoped_restore_current_program_space.
11711 * progspace-and-thread.c: New file.
11712 * progspace-and-thread.h: New file.
11713 * progspace.c (release_program_space, clone_program_space): Use
11714 scoped_restore_current_program_space.
11715 (restore_program_space, save_current_program_space)
11716 (save_current_space_and_thread): Delete.
11717 (switch_to_program_space_and_thread): Moved to
11718 progspace-and-thread.c.
11719 * progspace.h (save_current_program_space)
11720 (save_current_space_and_thread): Delete declarations.
11721 (scoped_restore_current_program_space): New class.
11722 * remote.c (remote_btrace_maybe_reopen): Use
11723 scoped_restore_current_thread.
11724 * symtab.c: Include "progspace-and-thread.h".
11725 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
11726 * thread.c (print_thread_info_1): Use
11727 scoped_restore_current_thread.
11728 (struct current_thread_cleanup): Delete.
11729 (do_restore_current_thread_cleanup)
11730 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
11731 (scoped_restore_current_thread::~scoped_restore_current_thread):
11732 ... this new dtor.
11733 (make_cleanup_restore_current_thread): Rename/convert to ...
11734 (scoped_restore_current_thread::scoped_restore_current_thread):
11735 ... this new ctor.
11736 (thread_apply_all_command): Use scoped_restore_current_thread.
11737 (thread_apply_command): Use scoped_restore_current_thread.
11738 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
11739 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
11740
f6223dbb
PA
117412017-05-04 Pedro Alves <palves@redhat.com>
11742
11743 * thread.c (make_cleanup_restore_current_thread): Move
11744 find_thread_ptid call before the is_stopped call. Assert that the
11745 thread is found. Replace is_stopped call by checking the thread's
11746 state directly. Remove unnecessary NULL-thread check.
11747
3c3ae77e
PA
117482017-05-04 Pedro Alves <palves@redhat.com>
11749
11750 * corelow.c (thread_section_name): New class.
11751 (get_core_register_section, get_core_siginfo): Use it.
11752
45eba0ab
AA
117532017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
11754
11755 * corelow.c (sniff_core_bfd): Remove extra semicolon.
11756 (get_core_register_section): Remove xfree of NULL pointer.
11757
f81fdd35
AH
117582017-05-03 Alan Hayward <alan.hayward@arm.com>
11759
11760 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
11761 * regcache.c (regcache::raw_supply_zeroed): New function.
11762 * regcache.h (regcache::raw_supply_zeroed): New declaration.
11763
35837774
SM
117642017-05-03 Simon Marchi <simon.marchi@ericsson.com>
11765
11766 * gdbarch.sh: Remove commented out definition of
11767 TARGET_CHAR_BIT.
11768 * gdbarch.h: Re-generate.
11769
c94fee56
SDJ
117702017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
11771
11772 * configure: Regenerate.
11773
d17f7b36
SM
117742017-05-02 Simon Marchi <simon.marchi@ericsson.com>
11775
11776 * solib-target.c (solib_target_relocate_section_addresses):
11777 Remove num_section_bases, num_bases, segment_bases variables.
11778
b560ebd6
SM
117792017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
11780
11781 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
11782
f2f46dfc
SM
117832017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
11784
11785 * solib-target.c: Include <vector>
11786 (struct lm_info_target) <~lm_info_target>: Remove.
11787 <segment_bases, section_bases>: Change type to
11788 std::vector<CORE_ADDR>.
11789 (library_list_start_segment, library_list_start_section,
11790 library_list_end_library,
11791 solib_target_relocate_section_addresses): Adjust.
11792
a0ff9e1a
SM
117932017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
11794
11795 * gdbarch.sh (software_single_step): Change return type to
11796 std::vector<CORE_ADDR>.
11797 * gdbarch.c, gdbarch.h: Re-generate.
11798 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
11799 Adjust.
11800 (arm_deal_with_atomic_sequence_raw): Adjust.
11801 (thumb_get_next_pcs_raw): Adjust.
11802 (arm_get_next_pcs_raw): Adjust.
11803 (arm_get_next_pcs): Adjust.
11804 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
11805 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
11806 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
11807 (alpha_software_single_step): Adjust.
11808 * alpha-tdep.h (alpha_software_single_step): Adjust.
11809 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
11810 * arm-tdep.c (arm_software_single_step): Adjust.
11811 (arm_breakpoint_kind_from_current_state): Adjust.
11812 * arm-tdep.h (arm_software_single_step): Adjust.
11813 * breakpoint.c (insert_single_step_breakpoint): Adjust.
11814 * cris-tdep.c (cris_software_single_step): Adjust.
11815 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
11816 (micromips_deal_with_atomic_sequence): Adjust.
11817 (deal_with_atomic_sequence): Adjust.
11818 (mips_software_single_step): Adjust.
11819 * mips-tdep.h (mips_software_single_step): Adjust.
11820 * moxie-tdep.c (moxie_software_single_step): Adjust.
11821 * nios2-tdep.c (nios2_software_single_step): Adjust.
11822 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
11823 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
11824 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
11825 * s390-linux-tdep.c (s390_software_single_step): Adjust.
11826 * sparc-tdep.c (sparc_software_single_step): Adjust.
11827 * spu-tdep.c (spu_software_single_step): Adjust.
11828 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
11829
ea480a30
SM
118302017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
11831
11832 * gdbarch.sh: Use semi-colon as field separator instead of colon.
11833 * gdbarch.h: Re-generate.
11834
d050f7d7
TW
118352017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
11836
11837 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
11838 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
11839 * python/py-instruction.c, python/py-instruction.h: New file.
11840 * python/py-record.c: Add py-instruction.h include.
11841 (gdbpy_initialize_record): Make gdb.Instruction a super class of
11842 gdb.RecordInstruction.
11843 * python/python-internal.h: Add gdbpy_initialize_instruction
11844 declaration.
11845 * python/python.c (do_start_initialization): Add
11846 gdbpy_initialize_instruction.
11847
14f819c8
TW
118482017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
11849
11850 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
11851 Remove.
11852 (btrace_func_from_recpy_func): New function.
11853 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
11854 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
11855 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
11856 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
11857 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
11858 Also, use new helper functions.
11859 (btpy_list_item): Use new helper functions.
11860 (recpy_bt_function_call_history): Use new type name.
11861 (btpy_call_getset): Remove.
11862 (gdbpy_initialize_btrace): Remove code to initialize
11863 gdb.BtraceFunctionCall.
11864 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
11865 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
11866 recpy_bt_func_prev, recpy_bt_func_next): New export.
11867 * python/py-record.c (recpy_func_type): New static object.
11868 (recpy_func_new, recpy_func_level, recpy_func_symbol,
11869 recpy_func_instructions, recpy_func_up, recpy_func_prev,
11870 recpy_func_next): New function.
11871 (recpy_element_hash, recpy_element_richcompare): Updated comment.
11872 (recpy_func_getset): New static object.
11873 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
11874 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
11875
0ed5da75
TW
118762017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
11877
11878 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
11879 (btpy_object, btpy_insn_type, btpy_new): Remove.
11880 (btpy_list_object): Use gdb.RecordInstruction type instead of
11881 gdb.BtraceInstruction type.
11882 (btrace_insn_from_recpy_insn): New function.
11883 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
11884 btpy_new.
11885 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
11886 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
11887 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
11888 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
11889 instead of btpy_object.
11890 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
11891 btpy_insn_data, btpy_insn_decode): Rename to ...
11892 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
11893 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
11894 recpy_bt_insn_decode): This. Also, use new helper functions.
11895 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
11896 recpy_insn_type.
11897 (btpy_insn_getset): Remove.
11898 (gdbpy_initialize_btrace): Remove code to initialize
11899 gdb.BtraceInstruction. Use recpy_element_object.
11900 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
11901 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
11902 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
11903 * python/py-record.c (recpy_insn_type): New static object.
11904 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
11905 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
11906 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
11907 New function.
11908 (recpy_insn_getset): New static object.
11909 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
11910 * python/py-record.h (recpy_element_object): New typedef.
11911 (recpy_insn_type, recpy_insn_new): New export.
11912
913aeadd
TW
119132017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
11914
11915 * py-record-btrace.c (btpy_insn_new): Removed.
11916 (btpy_insn_or_gap_new): New function.
11917 (btpy_insn_error): Removed.
11918 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
11919 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
11920 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
11921 btpy_insn_or_gap_new instead of btpy_insn_new.
11922 (btpy_insn_getset): Remove btpy_insn_error.
11923 * py-record.c (recpy_gap_type): New static object.
11924 (recpy_gap_object): New typedef.
11925 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
11926 recpy_gap_reason_string): New function.
11927 (recpy_gap_getset): New static object.
11928 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
11929 * py-record.h (recpy_gap_new): New export.
11930
a3be24ad
TW
119312017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
11932
11933 * python/py-record.c (recpy_ptid): Remove.
11934 (recpy_record_getset): Remove recpy_ptid.
11935
ae20e79a
TW
119362017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
11937
11938 * btrace.c (btrace_fetch): Set inferior_ptid.
11939 * python/py-record-btrace.c: Add "py-record.h" include.
11940 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
11941 recpy_bt_end, recpy_bt_instruction_history,
11942 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
11943 in gdb.Record object instead of current ptid.
11944 * python/py-record.c: Include new "py-record.h" file.
11945 (recpy_record_object): Moved to py-record.h.
11946 * python/py-record.h: New file.
11947
8d0050ea
TW
119482017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
11949
11950 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
11951 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
11952 indentation.
11953
3f380b50
JB
119542017-05-01 Joel Brobecker <brobecker@adacore.com>
11955
11956 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
11957 the past maintainers section.
11958
07495424
YQ
119592017-04-28 Yao Qi <yao.qi@linaro.org>
11960
11961 * infcmd.c (get_return_value): Use regcache ctor, and remove
11962 cleanup.
11963
deb1fa3e
YQ
119642017-04-28 Yao Qi <yao.qi@linaro.org>
11965 Pedro Alves <palves@redhat.com>
11966
11967 * regcache.c (regcache::regcache): New tag dispatch ctor.
11968 (do_cooked_read): Moved above.
11969 (regcache_dup): Use the tag dispatch ctor..
11970 * regcache.h (regcache): Declare ctor, delete copy ctor and
11971 assignment operator, remove friend regcache_dup.
11972
b421c83c
YQ
119732017-04-28 Yao Qi <yao.qi@linaro.org>
11974
11975 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
11976 call method save instead of regcache_cpy.
11977 * regcache.h (struct regcache): Make regcache_dup a friend.
11978
ef79d9a3
YQ
119792017-04-28 Yao Qi <yao.qi@linaro.org>
11980
11981 * regcache.c (struct regcache): Move to regcache.h
11982 (regcache::arch): New method.
11983 (regcache_get_ptid): Update.
11984 (get_regcache_arch): Call arch method.
11985 (get_regcache_aspace): Call method aspace.
11986 (register_buffer): Change it to method.
11987 (regcache_save): Change it to regcache::save.
11988 (regcache_restore): Likewise.
11989 (regcache_cpy_no_passthrough): Remove the declaration.
11990 (regcache_cpy): Call methods restore and cpy_no_passthrough.
11991 (regcache_cpy_no_passthrough): Change it to method
11992 cpy_no_passthrough.
11993 (regcache_register_status): Change it to method
11994 get_register_status.
11995 (regcache_invalidate): Change it to method invalidate.
11996 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
11997 (regcache_raw_update): Change it to method raw_update.
11998 (regcache_raw_read): Likewise.
11999 (regcache_raw_read_signed): Likewise.
12000 (regcache_raw_read_unsigned): Likewise.
12001 (regcache_raw_write_signed): Likewise.
12002 (regcache_raw_write_unsigned): Likewise.
12003 (regcache_cooked_read): Likewise.
12004 (regcache_cooked_read_value): Likewise.
12005 (regcache_cooked_read_signed): Likewise.
12006 (regcache_cooked_read_unsigned): Likewise.
12007 (regcache_cooked_write_signed): Likewise.
12008 (regcache_cooked_write_unsigned): Likewise.
12009 (regcache_raw_set_cached_value): Likewise.
12010 (regcache_raw_write): Likewise.
12011 (regcache_cooked_write): Likewise.
12012 (regcache_xfer_part): Likewise.
12013 (regcache_raw_read_part): Likewise.
12014 (regcache_raw_write_part): Likewise.
12015 (regcache_cooked_read_part): Likewise.
12016 (regcache_cooked_write_part): Likewise.
12017 (regcache_raw_supply): Likewise.
12018 (regcache_raw_collect): Likewise.
12019 (regcache_transfer_regset): Likewise.
12020 (regcache_supply_regset): Likewise.
12021 (regcache_collect_regset): Likewise.
12022 (regcache_debug_print_register): Likewise.
12023 (enum regcache_dump_what): Move it to regcache.h.
12024 (regcache_dump): Change it to method dump.
12025 * regcache.h (enum regcache_dump_what): New.
12026 (class regcache): New.
12027 * target.c (target_fetch_registers): Call method
12028 debug_print_register.
12029 (target_store_registers): Likewise.
12030
f8fdb78e
SM
120312017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12032
12033 * windows-nat.c (struct lm_info_windows): Initialize field.
12034 (windows_make_so): Allocate lm_info_windows with new.
12035 (windows_free_so): Free lm_info_windows with delete.
12036
9ccbfd7b
SM
120372017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12038
12039 * solib-darwin.c (struct lm_info_darwin): Initialize field.
12040 (darwin_current_sos): Allocate lm_info_darwin with new, remove
12041 cleanup.
12042 (darwin_free_so): Free lm_info_darwin with delete.
12043
76e75227
SM
120442017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12045
12046 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
12047 <l_addr_p>: Change type to bool.
12048 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
12049 (svr4_free_so): Free lm_info_svr4 with delete.
12050 (svr4_copy_library_list): Replace memcpy with call to copy
12051 constructor.
12052 (library_list_start_library, svr4_default_sos): Allocate
12053 lm_info_svr4 with new.
12054
51046d9e
SM
120552017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12056
12057 * solib-target.c (struct lm_info_target): Add destructor,
12058 initialize fields.
12059 <name>: Change type to std::string.
12060 (library_list_start_library): Allocate lm_info_target with new.
12061 (solib_target_free_library_list): Free lm_info_target with
12062 delete.
12063 (solib_target_current_sos): Adapt to std::string.
12064 (solib_target_free_so): Free lm_info_target with delete.
12065
4023ae76
SM
120662017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12067
12068 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
12069 fields.
12070 (frv_current_sos): Allocate lm_info_frv with new.
12071 (frv_relocate_main_executable): Free lm_info_frv with delete,
12072 allocate with new.
12073 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
12074
af43057b
SM
120752017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12076
12077 * solib-frv.c (struct lm_info_frv): Fix indentation.
12078
b0911207
SM
120792017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12080
12081 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
12082 map field.
12083 (dsbt_current_sos): Allocate lm_info_dsbt with new.
12084 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
12085 and allocate with new.
12086 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
12087
6c401f72
SM
120882017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12089
12090 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
12091 <filename, member_name>: Change type to std::string.
12092 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
12093 (library_list_start_library): Allocate lm_info_aix with new.
12094 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
12095 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
12096 with copy constructor.
12097
d0e449a1
SM
120982017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12099
12100 * solist.h (struct lm_info): Remove.
12101 (struct lm_info_base): New class.
12102 (struct so_list) <lm_info>: Change type to lm_info_base *.
12103 * nto-tdep.c (struct lm_info): Remove.
12104 (lm_addr): Adjust.
12105 * solib-aix.c (struct lm_info): Rename to ...
12106 (struct lm_info_aix): ... this. Extend lm_info_base.
12107 (lm_info_p): Rename to ...
12108 (lm_info_aix_p): ... this, and adjust.
12109 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
12110 solib_aix_parse_libraries, library_list_start_library,
12111 solib_aix_free_library_list, solib_aix_parse_libraries,
12112 solib_aix_get_library_list,
12113 solib_aix_relocate_section_addresses, solib_aix_free_so,
12114 solib_aix_get_section_offsets,
12115 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
12116 Adjust.
12117 (struct solib_aix_inferior_data) <library_list>: Adjust.
12118 * solib-darwin.c (struct lm_info): Rename to ...
12119 (struct lm_info_darwin): ... this. Extend lm_info_base.
12120 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
12121 * solib-dsbt.c (struct lm_info): Rename to ...
12122 (struct lm_info_dsbt): ... this. Extend lm_info_base.
12123 (struct dsbt_info) <main_executable_lm_info): Adjust.
12124 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
12125 dsbt_relocate_section_addresses): Adjust.
12126 * solib-frv.c (struct lm_info): Rename to ...
12127 (struct lm_info_frv): ... this. Extend lm_info_base.
12128 (main_executable_lm_info): Adjust.
12129 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
12130 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
12131 find_canonical_descriptor_in_load_object,
12132 frv_fdpic_find_canonical_descriptor): Adjust.
12133 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
12134 to lm_info_svr4.
12135 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
12136 svr4_clear_so, svr4_copy_library_list,
12137 library_list_start_library, svr4_default_sos, svr4_read_so_list,
12138 svr4_current_sos, svr4_fetch_objfile_link_map,
12139 solist_update_incremental): Adjust.
12140 * solib-svr4.h (struct lm_info_svr4): Move here from
12141 solib-svr4.c.
12142 * solib-target.c (struct lm_info): Rename to ...
12143 (struct lm_info_target): ... this. Extend lm_info_base.
12144 (lm_info_p): Rename to ...
12145 (lm_info_target_p): ... this.
12146 (solib_target_parse_libraries, library_list_start_segment,
12147 library_list_start_section, library_list_start_library,
12148 library_list_end_library, solib_target_free_library_list,
12149 solib_target_current_sos, solib_target_free_so,
12150 solib_target_relocate_section_addresses): Adjust.
12151 * windows-nat.c (struct lm_info): Rename to ...
12152 (struct lm_info_windows): ... this. Extend lm_info_base.
12153 (windows_make_so, handle_load_dll, handle_unload_dll,
12154 windows_xfer_shared_libraries): Adjust.
12155
434a4023
SM
121562017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12157
12158 * solib-darwin.c (struct darwin_so_list): Remove.
12159 (darwin_current_sos): Allocate an so_list object instead of a
12160 darwin_so_list, separately allocate an lm_info object.
12161 (darwin_free_so): Free lm_info.
12162
428544e8
JB
121632017-04-28 John Baldwin <jhb@FreeBSD.org>
12164
12165 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
12166 with fprintf_filtered.
12167
4621115f
YQ
121682017-04-28 Yao Qi <yao.qi@linaro.org>
12169
12170 * regcache.c (regcache::regcache): New function.
12171 (regcache::~regcache): New function.
12172 (regcache_xmalloc_1): Remove.
12173 (regcache_xmalloc): Call new regcache.
12174 (regcache_xfree): Call delete regcache.
12175 (get_thread_arch_aspace_regcache): Call new regcache.
12176
339053c2
YQ
121772017-04-28 Yao Qi <yao.qi@linaro.org>
12178
12179 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
12180 lwp instead of ptid_get_lwp.
12181
7974a605
YQ
121822017-04-28 Yao Qi <yao.qi@linaro.org>
12183
12184 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
12185 lwp_info instead of getting from inferior_ptid.
12186
e15c3eb4
KS
121872017-04-27 Keith Seitz <keiths@redhat.com>
12188
12189 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
12190 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
12191 (CV_CONVERSION_BADNESS): Define.
12192 (rank_one_type): Remove overly restrictive rvalue reference
12193 rank checks.
12194 Add cv-qualifier checks and subranks for type equality.
12195 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
12196 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
12197 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
12198
72bc1d24
SM
121992017-04-27 Simon Marchi <simon.marchi@ericsson.com>
12200
12201 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
12202 count when creating the object.
12203
55bcecda
UW
122042017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
12205 Ulrich Weigand <uweigand@de.ibm.com>
12206
12207 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
12208 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
12209 is used in AIX.
12210 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
12211 (process_xcoff_symbol): Likewise.
12212 (scan_xcoff_symtab): Likewise.
12213
5c99fcf8
AH
122142017-04-26 Alan Hayward <alan.hayward@arm.com>
12215
12216 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
12217 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
12218 (ia64_access_reg): Use get_frame_register_unsigned.
12219 (ia64_access_rse_reg): Likewise.
12220 (ia64_libunwind_frame_prev_register): Likewise.
12221
b41c5a85
JW
122222017-04-26 Jiong Wang <jiong.wang@arm.com>
12223
12224 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
12225 * gdbarch.c: Regenerated.
12226 * gdbarch.h: Regenerated.
12227 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
12228 visibility external.
12229 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
12230 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
12231 (enum cfa_how_kind): Move to ...
12232 (struct dwarf2_frame_state_reg_info): Likewise.
12233 (struct dwarf2_frame_state): Likewise.
12234 * dwarf2-frame.h: ... here.
12235 (dwarf2_frame_state_alloc_regs): New declaration.
12236 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
12237 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
12238
c185f580
AH
122392017-04-26 Alan Hayward <alan.hayward@arm.com>
12240
12241 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
12242 regcache_raw_read_unsigned.
12243 (xtensa_pseudo_register_write): Likewise.
12244
19c45594
AH
122452017-04-26 Alan Hayward <alan.hayward@arm.com>
12246
12247 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
12248 (nds32_pseudo_register_write): Likewise.
12249
4658f12e
YQ
122502017-04-25 Yao Qi <yao.qi@linaro.org>
12251
12252 * regcache.c (struct regcache) <readonly_p>: Change its type
12253 to bool.
12254 (regcache_xmalloc_1): Update parameter type and callers update.
12255
d581dda8
YQ
122562017-04-25 Yao Qi <yao.qi@linaro.org>
12257
12258 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
12259 set_gdbarch_wchar_bit.
12260 * arm-tdep.c (arm_gdbarch_init): Likewise.
12261
debed3db
PA
122622017-04-25 Pedro Alves <palves@redhat.com>
12263
12264 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
12265 (BothAreRelocatable, memcopy, memmove): Don't define.
12266 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
12267 macros.
12268
b0b92aeb
PA
122692017-04-25 Pedro Alves <palves@redhat.com>
12270
12271 * common/common-defs.h: Include "common/poison.h".
12272 * common/function-view.h: (Not, Or, Requires): Move to traits.h
12273 and adjust.
12274 * common/poison.h: New file.
12275 * common/traits.h: Include <type_traits>.
12276 (Not, Or, Requires): New, moved from common/function-view.h.
12277
16c4d54a
PA
122782017-04-25 Pedro Alves <palves@redhat.com>
12279
12280 * breakpoint.h (struct breakpoint): In-class initialize all
12281 fields. Make boolean fields "bool".
12282 * breakpoint.c (init_raw_breakpoint_without_location): Remove
12283 memset call and initializations no longer necessary.
12284
b5c36682
PA
122852017-04-25 Pedro Alves <palves@redhat.com>
12286
12287 * btrace.c (pt_btrace_insn_flags): Change parameter type to
12288 reference.
12289 (pt_btrace_insn): New function.
12290 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
12291
5625a286
PA
122922017-04-25 Pedro Alves <palves@redhat.com>
12293
12294 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
12295 "base" field and inherit from "bp_location" instead. Add
12296 non-default ctor.
12297 (allocate_location_exception): Use new non-default ctor.
12298 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
12299 (init_bp_location): Convert to ...
12300 (bp_location::bp_location): ... this new ctor, and remove memset
12301 call.
12302 (base_breakpoint_allocate_location): Use the new non-default ctor.
12303 * breakpoint.h (bp_location): Now a class. Declare default and
12304 non-default ctors. In-class initialize all members.
12305 (init_bp_location): Remove declaration.
12306
23bcc18f
PA
123072017-04-25 Pedro Alves <palves@redhat.com>
12308
12309 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
12310 assignment operator.
12311
e1ba3053
YQ
123122017-04-24 Yao Qi <yao.qi@linaro.org>
12313
12314 * doublest.c (convert_doublest_to_floatformat): Call
12315 floatformat_totalsize_bytes.
12316
10f489e5
TT
123172017-04-22 Tom Tromey <tom@tromey.com>
12318
12319 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
12320 ui_out_emit_list.
12321 * stack.c (print_frame): Use ui_out_emit_list.
12322 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
12323 ui_out_emit_list.
12324 * mi/mi-main.c (print_one_inferior)
12325 (mi_cmd_data_list_register_names)
12326 (mi_cmd_data_list_register_values, mi_cmd_list_features)
12327 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
12328 ui_out_emit_list.
12329 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
12330 (mi_output_solib_attribs): Use ui_out_emit_list,
12331 ui_out_emit_tuple.
12332 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
12333 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
12334 (mi_cmd_stack_list_args, list_args_or_locals): Use
12335 ui_out_emit_list.
12336 * disasm.c (do_assembly_only): Use ui_out_emit_list.
12337 * breakpoint.c (print_solib_event, output_thread_groups): Use
12338 ui_out_emit_list.
12339
0092b74d
TT
123402017-04-22 Tom Tromey <tom@tromey.com>
12341
12342 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
12343 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
12344 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
12345
a14a62dd
TT
123462017-04-22 Tom Tromey <tom@tromey.com>
12347
12348 * tracepoint.c (tvariables_info_1)
12349 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
12350
46b9c129
TT
123512017-04-22 Tom Tromey <tom@tromey.com>
12352
12353 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
12354 annotate_arg_emitter.
12355 * breakpoint.c (print_mention_watchpoint)
12356 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
12357 * annotate.h (struct annotate_arg_emitter): New.
12358
2e783024
TT
123592017-04-22 Tom Tromey <tom@tromey.com>
12360
12361 * record-btrace.c (record_btrace_insn_history)
12362 (record_btrace_insn_history_range, record_btrace_call_history)
12363 (record_btrace_call_history_range): Use ui_out_emit_tuple.
12364 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
12365 ui_out_emit_tuple.
12366 * stack.c (print_frame_info): Use ui_out_emit_tuple.
12367 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
12368 * skip.c (skip_info): Use ui_out_emit_tuple.
12369 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
12370 * progspace.c (print_program_space): Use ui_out_emit_tuple.
12371 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
12372 * osdata.c (info_osdata): Use ui_out_emit_tuple.
12373 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
12374 ui_out_emit_tuple.
12375 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
12376 (output_register, mi_cmd_data_read_memory)
12377 (mi_cmd_data_read_memory_bytes, mi_load_progress)
12378 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
12379 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
12380 Use ui_out_emit_tuple.
12381 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
12382 ui_out_emit_tuple.
12383 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
12384 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
12385 * linux-thread-db.c (info_auto_load_libthread_db): Use
12386 ui_out_emit_tuple.
12387 * inferior.c (print_inferior): Use ui_out_emit_tuple.
12388 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
12389 * disasm.c (do_mixed_source_and_assembly_deprecated)
12390 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
12391 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
12392 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
12393 * breakpoint.c (print_one_breakpoint_location)
12394 (print_one_breakpoint): Use ui_out_emit_tuple.
12395 * auto-load.c (print_script, info_auto_load_cmd): Use
12396 ui_out_emit_tuple.
12397 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
12398
9be21bb4
SM
123992017-04-21 Simon Marchi <simon.marchi@ericsson.com>
12400
12401 * thread.c (print_thread_info_1): Remove dead code.
12402
0d4c07af
JK
124032017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12404
12405 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
12406 GDB_SELF_TEST.
12407 * arm-tdep.c (selftests::arm_record_test): Likewise.
12408
4daf993d
YQ
124092017-04-21 Yao Qi <yao.qi@linaro.org>
12410
12411 * regcache.c (regcache_restore): Remove argument 2. Replace
12412 argument 3 with regcache. Get register status from
12413 src->register_status and get register contents from
12414 register_buffer (src, regnum).
12415 (regcache_cpy): Update.
12416
a6c21d4a
PA
124172017-04-19 Pedro Alves <palves@redhat.com>
12418
12419 * gdbthread.h (thread): Add missing closing parenthesis in
12420 comment.
12421
3a3fd0fd
PA
124222017-04-19 Pedro Alves <palves@redhat.com>
12423
12424 * common/refcounted-object.h: New file.
12425 * gdbthread.h: Include "common/refcounted-object.h".
12426 (thread_info): Inherit from refcounted_object and add comments.
12427 (thread_info::incref, thread_info::decref)
12428 (thread_info::m_refcount): Delete.
12429 (thread_info::deletable): Use the refcounted_object::refcount()
12430 method.
12431 * inferior.c (current_inferior_): Add comment.
12432 (set_current_inferior): Increment/decrement refcounts.
12433 (prune_inferiors, remove_inferior_command): Skip inferiors marked
12434 not-deletable instead of comparing with the current inferior.
12435 (initialize_inferiors): Increment the initial inferior's refcount.
12436 * inferior.h (struct inferior): Forward declare.
12437 Include "common/refcounted-object.h".
12438 (current_inferior, set_current_inferior): Move declaration to
12439 before struct inferior's definition, and fix comment.
12440 (inferior): Inherit from refcounted_object. Add comments.
12441 * thread.c (switch_to_thread_no_regs): Reference the thread's
12442 inferior pointer directly instead of doing a ptid lookup.
12443 (switch_to_no_thread): New function.
12444 (switch_to_thread(thread_info *)): New function, factored out
12445 from ...
12446 (switch_to_thread(ptid_t)): ... this.
12447 (restore_current_thread): Delete.
12448 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
12449 fields, and add 'inf' field.
12450 (do_restore_current_thread_cleanup): Check whether old->inf is
12451 alive instead of looking up an inferior by ptid. Use
12452 switch_to_thread and switch_to_no_thread.
12453 (restore_current_thread_cleanup_dtor): Use old->inf directly
12454 instead of lookup up an inferior by id. Decref the inferior.
12455 Don't restore 'removable'.
12456 (make_cleanup_restore_current_thread): Same the inferior pointer
12457 in old, instead of the inferior number. Incref the inferior.
12458 Don't save/clear 'removable'.
12459
9bcb1f16
PA
124602017-04-19 Pedro Alves <palves@redhat.com>
12461
12462 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12463 unittests/scoped_restore-selftests.c.
12464 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
12465 * common/scoped_restore.h (scoped_restore_base): Make "class".
12466 (scoped_restore_base::release): New public method.
12467 (scoped_restore_base::scoped_restore_base): New protected ctor.
12468 (scoped_restore_base::m_saved_var): New protected field.
12469 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
12470 scoped_restore_base base class instead of m_saved_var directly.
12471 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
12472 (scoped_restore_tmpl::scoped_restore_tmpl(const
12473 scoped_restore_tmpl<T>&)): Likewise.
12474 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
12475 method.
12476 (scoped_restore_tmpl::saved_var): New method.
12477 (scoped_restore_tmpl::m_saved_var): Delete.
12478 * inferior.h (inferior::detaching): Now a bool.
12479 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
12480 cleanup.
12481 * unittests/scoped_restore-selftests.c: New file.
12482
26fcd539
PA
124832017-04-19 Pedro Alves <palves@redhat.com>
12484
12485 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
12486 Re-sort in alphabetic order.
12487
fdd243b0
PA
124882017-04-18 Pedro Alves <palves@redhat.com>
12489
12490 * xml-support.c (obstack_xml_printf): Delete.
12491 * xml-support.h (obstack_xml_printf): Delete.
12492
4895cde2
PA
124932017-04-18 Pedro Alves <palves@redhat.com>
12494
12495 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
12496 vdebug, verror, body_text, start_element, end_element, name,
12497 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
12498 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
12499 is_xinclude>: Make private and add m_ prefix.
12500 (gdb_xml_parser::body_text): New method, based on ...
12501 (gdb_xml_body_text): ... this. Adjust.
12502 (gdb_xml_parser::vdebug): New method, based on ...
12503 (gdb_xml_debug): ... this. Adjust.
12504 (gdb_xml_parser::verror): New method, based on ...
12505 (gdb_xml_error): ... this. Adjust.
12506 (gdb_xml_parser::start_element): New method, based on ...
12507 (gdb_xml_start_element): ... this. Adjust.
12508 (gdb_xml_start_element_wrapper): Defer to
12509 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
12510 (gdb_xml_parser::end_element): New method, based on ...
12511 (gdb_xml_end_element_wrapper): ... this. Adjust.
12512 (gdb_xml_parser::~gdb_xml_parser): Adjust.
12513 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
12514 (gdb_xml_parser::use_dtd): New method, based on ...
12515 (gdb_xml_use_dtd): ... this. Adjust.
12516 (gdb_xml_parser::parse): New method, based on ...
12517 (gdb_xml_parse): ... this. Adjust.
12518 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
12519 (xinclude_start_include): Adjust to call the parser's name method.
12520 (xml_xinclude_default, xml_xinclude_start_doctype)
12521 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
12522 method.
12523 (xml_process_xincludes): Adjust to call parser methods.
12524 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
12525 declarations.
12526
bd8a901f
PA
125272017-04-18 Pedro Alves <palves@redhat.com>
12528
12529 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
12530 gdb::optional<std::string>.
12531 * xml-support.c: Include <string>.
12532 (scope_level::scope_level(scope_level &&))
12533 (scope_level::~scope_level): Delete.
12534 (scope_level::body): Now a std::string.
12535 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
12536 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
12537 parameter.
12538 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
12539 (xinclude_parsing_data::output): Now a std::string reference.
12540 (xinclude_start_include): Adjust.
12541 (xml_xinclude_default): Adjust.
12542 (xml_process_xincludes): Add 'output' parameter, and return bool.
12543 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
12544 and return bool.
12545 * xml-tdesc.c: Include <unordered_map> and <string>.
12546 (tdesc_xml_cache): Delete.
12547 (tdesc_xml_cache_s): Delete.
12548 (xml_cache): Now an std::unordered_map.
12549 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
12550 (target_fetch_description_xml): Change return type to
12551 gdb::optional<std::string>, and adjust.
12552 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
12553 (target_fetch_description_xml): Change return type to
12554 gdb::optional<std::string>.
12555
d35d1958
PA
125562017-04-18 Pedro Alves <palves@redhat.com>
12557
12558 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12559 unittests/optional-selftests.c.
12560 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
12561 * unittests/optional-selftests.c: New file.
12562 * unittests/optional/assignment/1.cc: New file.
12563 * unittests/optional/assignment/2.cc: New file.
12564 * unittests/optional/assignment/3.cc: New file.
12565 * unittests/optional/assignment/4.cc: New file.
12566 * unittests/optional/assignment/5.cc: New file.
12567 * unittests/optional/assignment/6.cc: New file.
12568 * unittests/optional/assignment/7.cc: New file.
12569 * unittests/optional/cons/copy.cc: New file.
12570 * unittests/optional/cons/default.cc: New file.
12571 * unittests/optional/cons/move.cc: New file.
12572 * unittests/optional/cons/value.cc: New file.
12573 * unittests/optional/in_place.cc: New file.
12574 * unittests/optional/observers/1.cc: New file.
12575 * unittests/optional/observers/2.cc: New file.
12576
22796e97
PA
125772017-04-18 Pedro Alves <palves@redhat.com>
12578
12579 * common/gdb_optional.h: Include common/traits.h.
12580 (in_place_t): New type.
12581 (in_place): New constexpr variable.
12582 (optional::optional): Remove member initialization of
12583 m_instantiated.
12584 (optional::optional(in_place_t...)): New constructor.
12585 (optional::~optional): Use reset.
12586 (optional::optional(const optional&)): New.
12587 (optional::optional(const optional&&)): New.
12588 (optional::optional(T &)): New.
12589 (optional::optional(T &&)): New.
12590 (operator::operator=(const optional &)): New.
12591 (operator::operator=(optional &&)): New.
12592 (operator::operator= (const T &))
12593 (operator::operator= (T &&))
12594 (operator::emplace (Args &&... args)): Return a T&. Use reset.
12595 (operator::reset): New.
12596 (operator::m_instantiated):: Add in-class initializer.
12597 * common/traits.h: Include <type_traits>.
12598 (struct And): New types.
12599
a7fc9b61
PA
126002017-04-18 Pedro Alves <palves@redhat.com>
12601
12602 * xml-support.c: Include <vector>.
12603 (scope_level::scope_level(const gdb_xml_element *))
12604 (scope_level::scope_level(scope_level&&)): New.
12605 (scope_level::~scope_level): New.
12606 (scope_level_s): Delete.
12607 (gdb_xml_parser::scopes): Now a std::vector.
12608 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
12609 Use std::vector.
12610 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
12611 scope cleanup code.
12612 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
12613 of the scopes member. Use std::vector::emplace_back.
12614
010151c9
PA
126152017-04-18 Pedro Alves <palves@redhat.com>
12616
12617 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
12618 a bool.
12619 (gdb_xml_end_element): Change type of first parameter.
12620 (gdb_xml_cleanup): Rename to ...
12621 (gdb_xml_parser::~gdb_xml_parser): ... this.
12622 (gdb_xml_create_parser_and_cleanup): Delete with ...
12623 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
12624 to this new ctor.
12625 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
12626 using gdb_xml_create_parser_and_cleanup.
12627 (xinclude_parsing_data): Add ctor/dtor.
12628 (xml_xinclude_cleanup): Delete.
12629 (xml_process_xincludes): Create a local xinclude_parsing_data
12630 instead of heap-allocating one. Create a local gdb_xml_parser
12631 instead of heap-allocating one with
12632 gdb_xml_create_parser_and_cleanup.
12633
d56060f0
JB
126342017-04-18 John Baldwin <jhb@FreeBSD.org>
12635
12636 PR threads/20743
12637 * fbsd-nat.c (resume_one_thread_cb): Remove.
12638 (resume_all_threads_cb): Remove.
12639 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
12640 iterate_over_threads.
12641
305d16a9
JB
126422017-04-17 Joel Brobecker <brobecker@adacore.com>
12643
12644 * NEWS: Create a new section for the next release branch.
12645 Rename the section of the current branch, now that it has
12646 been cut.
12647
8bb57231
JB
126482017-04-17 Joel Brobecker <brobecker@adacore.com>
12649
12650 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
12651 * version.in: Bump version to 8.0.50.DATE-git.
12652
096c92dd
SDJ
126532017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
12654
12655 PR gdb/21385
12656 * windows-nat.c (windows_create_inferior): Declare 'allargs'
12657 independently of the host, and fix build breakage on Cygwin.
12658
0550c955
PA
126592017-04-13 Pedro Alves <palves@redhat.com>
12660
12661 * inferior.c (free_inferior): Convert to ...
12662 (inferior::~inferior): ... this dtor.
12663 (inferior::inferior): New ctor, factored out from ...
12664 (add_inferior_silent): ... here. Allocate the inferior with a new
12665 expression.
12666 (delete_inferior): Call delete instead of free_inferior.
12667 * inferior.h (gdb_environ, continuation): Forward declare.
12668 (inferior): Now a class. Add in-class initialization to all
12669 members. Make boolean fields bool, except 'detaching'.
12670 (inferior::inferior): New explicit ctor.
12671 (inferior::~inferior): New.
12672
e3d60dfc
PA
126732017-04-13 Pedro Alves <palves@redhat.com>
12674
12675 * inferior.c (init_inferior_list): Delete.
12676 * inferior.h (init_inferior_list): Delete.
12677
5fd69d0a
PA
126782017-04-13 Pedro Alves <palves@redhat.com>
12679
12680 PR threads/13217
12681 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
12682 (top level): Call it twice, with different thread sets.
12683
c6609450
PA
126842017-04-13 Pedro Alves <palves@redhat.com>
12685
12686 * thread.c: Include <algorithm>.
12687 (thread_array_cleanup): Delete.
12688 (scoped_inc_dec_ref): New class.
12689 (live_threads_count): New function.
12690 (set_thread_refcount): Delete.
12691 (tp_array_compar_ascending): Now a bool.
12692 (tp_array_compar): Convert to a std::sort comparison function.
12693 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
12694 and live_threads_count.
12695
2a00d7ce
PA
126962017-04-13 Pedro Alves <palves@redhat.com>
12697
12698 * infrun.c (follow_fork_inferior): Also switch the current
12699 inferior.
12700
441d7c93
PA
127012017-04-13 Pedro Alves <palves@redhat.com>
12702
12703 * breakpoint.c (watch_command_1): Save watchpoint-frame info
12704 before calling create_internal_breakpoint.
12705
808480f6
PA
127062017-04-13 Pedro Alves <palves@redhat.com>
12707
12708 * fork-child.c (execv_argv): New class.
12709 (breakup_args): Refactored as ...
12710 (execv_argv::init_for_no_shell): .. this method of execv_argv.
12711 Copy arguments to storage and replace separators with NULL
12712 terminators in place.
12713 (escape_bang_in_quoted_argument): Adjust to return bool.
12714 (execv_argv::execv_argv): New ctor.
12715 (execv_argv::init_for_shell): New method, factored out from
12716 fork_inferior. Don't strdup strings into the vector.
12717 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
12718 Remove free_vector_argv call.
12719
ad3d022a
YQ
127202017-04-13 Yao Qi <yao.qi@linaro.org>
12721
12722 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
12723 tdep->rx_psw_type.
12724
e6ddc3bf
YQ
127252017-04-13 Yao Qi <yao.qi@linaro.org>
12726
12727 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
12728 * rx-tdep.c (rx_gdbarch_init): Likewise.
12729
bfb8cf90
PA
127302017-04-13 Pedro Alves <palves@redhat.com>
12731
12732 * breakpoint.h (struct breakpoint): Reindent.
12733
f5336ca5
PA
127342017-04-13 Pedro Alves <palves@redhat.com>
12735
12736 * breakpoint.c (bp_location): Rename to ...
12737 (bp_locations): ... this. All references updated.
12738 (bp_location_count): Rename to ...
12739 (bp_locations_count): ... this. All references updated.
12740 (bp_location_placed_address_before_address_max): Rename to ...
12741 (bp_locations_placed_address_before_address_max): ... this. All
12742 references updated.
12743 (bp_location_shadow_len_after_address_max): Rename to ...
12744 (bp_locations_shadow_len_after_address_max): ... this. All
12745 references updated.
12746 (bp_location_compare_addrs): Rename to ...
12747 (bp_locations_compare_addrs): ... this. All references updated.
12748 (bp_location_compare):Rename to ...
12749 (bp_locations_compare): ... this. All references updated.
12750 (bp_location_target_extensions_update): Rename to ...
12751 (bp_locations_target_extensions_update): ... this. All references
12752 updated.
12753
be628ab8
SDJ
127542017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
12755
12756 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
12757 * common/common.m4: Check headers 'termios.h', 'termio.h' and
12758 'sgtty.h'.
12759 * common/gdb_termios.h: New file, with parts of "terminal.h".
12760 * inflow.c: Include "gdb_termios.h".
12761 * ser-unix.c: Include "gdb_termios.h".
12762 * terminal.h: Move terminal-related defines to
12763 "common/gdb_termios.h".
12764
8e9e35b1
TT
127652017-04-12 Tom Tromey <tom@tromey.com>
12766
12767 * probe.c (parse_probes): Update.
12768 * location.h (delete_event_location): Don't declare.
12769 (event_location_deleter::operator()): Update.
12770 * location.c (event_location_deleter::operator()): Rename from
12771 delete_event_location.
12772 * linespec.h (linespec_result) <location>: Change type to
12773 event_location_up.
12774 * linespec.c (canonicalize_linespec, event_location_to_sals)
12775 (decode_objc): Update.
12776 (linespec_result): Don't call delete_event_location.
12777 * breakpoint.c (create_breakpoints_sal)
12778 (bkpt_probe_create_sals_from_location)
12779 (strace_marker_create_sals_from_location): Update.
12780
16e802b9
TT
127812017-04-12 Tom Tromey <tom@tromey.com>
12782
12783 * linespec.h (struct linespec_result): Add constructor and
12784 destructor.
12785 (init_linespec_result, destroy_linespec_result)
12786 (make_cleanup_destroy_linespec_result): Don't declare.
12787 * linespec.c (init_linespec_result): Remove.
12788 (linespec_result::~linespec_result): Rename from
12789 destroy_linespec_result. Update.
12790 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
12791 Remove.
12792 * breakpoint.c (create_breakpoint, break_range_command)
12793 (decode_location_default): Update.
12794 * ax-gdb.c (agent_command_1): Update.
12795
d28cd78a
TT
127962017-04-12 Tom Tromey <tom@tromey.com>
12797
12798 * remote.c (remote_download_tracepoint): Update.
12799 * python/py-breakpoint.c (bppy_get_location): Update.
12800 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
12801 (gdbscm_breakpoint_location): Update.
12802 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
12803 * breakpoint.h (struct breakpoint) <location, location_range_end>:
12804 Change type to event_location_up.
12805 * breakpoint.c (create_overlay_event_breakpoint)
12806 (create_longjmp_master_breakpoint)
12807 (create_std_terminate_master_breakpoint)
12808 (create_exception_master_breakpoint)
12809 (breakpoint_event_location_empty_p, print_breakpoint_location)
12810 (print_one_breakpoint_location, create_thread_event_breakpoint)
12811 (init_breakpoint_sal, create_breakpoint)
12812 (print_recreate_ranged_breakpoint, break_range_command)
12813 (init_ada_exception_breakpoint, say_where): Update.
12814 (base_breakpoint_dtor): Don't call delete_event_location.
12815 (bkpt_print_recreate, tracepoint_print_recreate)
12816 (dprintf_print_recreate, update_static_tracepoint)
12817 (breakpoint_re_set_default): Update.
12818
711799d5
TT
128192017-04-12 Tom Tromey <tom@tromey.com>
12820
12821 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
12822 type of "to_do". Update.
12823 (compute_stack_depth): Use std::vector.
12824
52d214d3
TT
128252017-04-12 Tom Tromey <tom@tromey.com>
12826
12827 * printcmd.c (find_instruction_backward): Use std::vector.
12828
4c404b8b
TT
128292017-04-12 Tom Tromey <tom@tromey.com>
12830
12831 * symfile.c (objfilep): Remove typedef.
12832 (reread_symbols): Use a std::vector.
12833
156d9eab
TT
128342017-04-12 Tom Tromey <tom@tromey.com>
12835
12836 * mi/mi-main.c (exec_direction_forward): Remove.
12837 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
12838 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
12839 scoped_restore.
12840 * guile/guile.c (guile_repl_command, guile_command)
12841 (gdbscm_execute_gdb_command): Use scoped_restore.
12842 * go-exp.y (go_parse): Use scoped_restore.
12843 * d-exp.y (d_parse): Use scoped_restore.
12844 * cli/cli-decode.c (cmd_func): Use scoped_restore.
12845 * c-exp.y (c_parse): Use scoped_restore.
12846
4d89769a
TT
128472017-04-12 Tom Tromey <tom@tromey.com>
12848
12849 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
12850 (mi_parse): Update return type.
12851 (mi_parse_free): Remove.
12852 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
12853 (mi_parse::~mi_parse): Rename from mi_parse_free.
12854 (mi_parse_cleanup): Remove.
12855 (mi_parse): Return a unique_ptr. Use new.
12856 * mi/mi-main.c (mi_execute_command): Update.
12857
4b217cc7
TT
128582017-04-12 Tom Tromey <tom@tromey.com>
12859
12860 * location.c (explicit_location_lex_one): Return a
12861 unique_xmalloc_ptr.
12862 (string_to_explicit_location): Update. Remove cleanups.
12863
59d3651b
TT
128642017-04-12 Tom Tromey <tom@tromey.com>
12865
12866 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
12867 (compare_value_and_voffset): Change type. Update.
12868 (compute_vtable_size): Change type of "offset_vec".
12869 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
12870 (gnuv3_get_typeid): Remove extraneous declaration.
12871
b24b0d6c
TT
128722017-04-12 Tom Tromey <tom@tromey.com>
12873
12874 * charset.h (wchar_iterator): Fix comment.
12875
80a3b8c5
TT
128762017-04-12 Tom Tromey <tom@tromey.com>
12877
12878 * charset.c (iconv_wrapper): New class.
12879 (cleanup_iconv): Remove.
12880 (convert_between_encodings): Use it.
12881
c83dd867
TT
128822017-04-12 Tom Tromey <tom@tromey.com>
12883
12884 * symfile.h (increment_reading_symtab): Update type.
12885 * symfile.c (decrement_reading_symtab): Remove.
12886 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
12887 * psymtab.c (psymtab_to_symtab): Update.
12888 * dwarf2read.c (dw2_instantiate_symtab): Update.
12889
0e8621a0
TT
128902017-04-12 Tom Tromey <tom@tromey.com>
12891
12892 * jit.c (struct jit_reader): Declare separately. Add constructor
12893 and destructor. Change type of "handle".
12894 (loaded_jit_reader): Define separately.
12895 (jit_reader_load): Update. New "new".
12896 (jit_reader_unload_command): Use "delete".
12897 * gdb-dlfcn.h (struct dlclose_deleter): New.
12898 (gdb_dlhandle_up): New typedef.
12899 (gdb_dlopen, gdb_dlsym): Update types.
12900 (gdb_dlclose): Remove.
12901 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
12902 (gdb_dlsym): Change type of "handle".
12903 (make_cleanup_dlclose): Remove.
12904 (dlclose_deleter::operator()): Rename from gdb_dlclose.
12905 * compile/compile-c-support.c (load_libcc): Update.
12906
67d89901
TT
129072017-04-12 Tom Tromey <tom@tromey.com>
12908
12909 * symtab.h (find_pcs_for_symtab_line): Change return type.
12910 * symtab.c (find_pcs_for_symtab_line): Change return type.
12911 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
12912 type of "vec". Update.
12913 (ltpy_get_pcs_for_line): Update.
12914 * linespec.c (decode_digits_ordinary): Update.
12915
93921405
TT
129162017-04-12 Tom Tromey <tom@tromey.com>
12917
12918 * tracepoint.c (actions_command): Update.
12919 * python/python.c (python_command, python_interactive_command):
12920 Update.
12921 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
12922 * guile/guile.c (guile_command): Update.
12923 * defs.h (read_command_lines, read_command_lines_1): Return
12924 command_line_up.
12925 (command_lines_deleter): New struct.
12926 (command_line_up): New typedef.
12927 * compile/compile.c (compile_code_command)
12928 (compile_print_command): Update.
12929 * cli/cli-script.h (get_command_line, copy_command_lines): Return
12930 command_line_up.
12931 (make_cleanup_free_command_lines): Remove.
12932 * cli/cli-script.c (get_command_line, read_command_lines_1)
12933 (copy_command_lines): Return command_line_up.
12934 (while_command, if_command, read_command_lines, define_command)
12935 (document_command): Update.
12936 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
12937 Remove.
12938 * breakpoint.h (breakpoint_set_commands): Change type of
12939 "commands".
12940 * breakpoint.c (breakpoint_set_commands): Change type of
12941 "commands". Update.
12942 (do_map_commands_command, update_dprintf_command_list)
12943 (create_tracepoint_from_upload): Update.
12944
ffc2605c
TT
129452017-04-12 Tom Tromey <tom@tromey.com>
12946
12947 * tracepoint.c (scope_info): Update.
12948 * spu-tdep.c (spu_catch_start): Update.
12949 * python/python.c (gdbpy_decode_line): Update.
12950 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
12951 * python/py-breakpoint.c (bppy_init): Update.
12952 * probe.c (parse_probes): Update.
12953 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
12954 * location.h (event_location_deleter): New struct.
12955 (event_location_up): New typedef.
12956 (new_linespec_location, new_address_location, new_probe_location)
12957 (new_explicit_location, copy_event_location)
12958 (string_to_event_location, string_to_event_location_basic)
12959 (string_to_explicit_location): Update return type.
12960 (make_cleanup_delete_event_location): Remove.
12961 * location.c (new_linespec_location, new_address_location)
12962 (new_probe_location, new_explicit_location, copy_event_location):
12963 Return event_location_up.
12964 (delete_event_location_cleanup)
12965 (make_cleanup_delete_event_location): Remove.
12966 (string_to_explicit_location, string_to_event_location_basic)
12967 (string_to_event_location): Return event_location_up.
12968 * linespec.c (canonicalize_linespec, event_location_to_sals)
12969 (decode_line_with_current_source)
12970 (decode_line_with_last_displayed, decode_objc): Update.
12971 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
12972 * completer.c (location_completer): Update.
12973 * cli/cli-cmds.c (edit_command, list_command): Update.
12974 * breakpoint.c (create_overlay_event_breakpoint)
12975 (create_longjmp_master_breakpoint)
12976 (create_std_terminate_master_breakpoint)
12977 (create_exception_master_breakpoint)
12978 (create_thread_event_breakpoint): Update.
12979 (init_breakpoint_sal): Update. Remove some dead code.
12980 (create_breakpoint_sal): Change type of "location". Update.
12981 (create_breakpoints_sal, create_breakpoint, break_command_1)
12982 (dprintf_command, break_range_command, until_break_command)
12983 (init_ada_exception_breakpoint)
12984 (strace_marker_create_sals_from_location)
12985 (update_static_tracepoint, trace_command, ftrace_command)
12986 (strace_command, create_tracepoint_from_upload): Update.
12987 * break-catch-throw.c (re_set_exception_catchpoint): Update.
12988 * ax-gdb.c (agent_command_1): Update.
12989
8f10c932
PA
129902017-04-12 Pedro Alves <palves@redhat.com>
12991
12992 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
12993 * configure.tgt: Handle i[34567]86-*-go32* and
12994 i[34567]86-*-msdosdjgpp*.
12995 * i386-tdep.c (i386_svr4_reg_to_regnum):
12996 Make extern.
12997 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
12998 i386-go32-tdep.c.
12999 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
13000 * i386-go32-tdep.c: New file.
13001 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
13002 declarations.
13003
0a31ccfb
SM
130042017-04-12 Simon Marchi <simon.marchi@ericsson.com>
13005
13006 * aix-thread.c (pd_status2str): Change return type to const char *.
13007
e9bb3fbb
PA
130082017-04-12 Pedro Alves <palves@redhat.com>
13009
13010 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
13011 calls to set_gdbarch_gnu_triplet_regexp.
13012
53375380
PA
130132017-04-12 Pedro Alves <palves@redhat.com>
13014
13015 PR gdb/21323
13016 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
13017 New enum value.
13018 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
13019 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
13020 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
13021 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
13022 * gdbarch.h, gdbarch.c: Regenerate.
13023 * aarch64-tdep.c (aarch64_gdbarch_init): Override
13024 gdbarch_wchar_bit and gdbarch_wchar_signed.
13025 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
13026 * arm-tdep.c (arm_gdbarch_init): Likewise.
13027 * avr-tdep.c (avr_gdbarch_init): Likewise.
13028 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
13029 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
13030 * i386-tdep.c (i386_go32_init_abi): Likewise.
13031 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
13032 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
13033 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
13034 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
13035 * sh-tdep.c (sh_gdbarch_init): Likewise.
13036 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
13037 * sparc64-tdep.c (sparc64_init_abi): Likewise.
13038 * windows-tdep.c (windows_init_abi): Likewise.
13039 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
13040
53e710ac
PA
130412017-04-12 Pedro Alves <palves@redhat.com>
13042
13043 PR c++/21323
13044 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
13045 cplus_primitive_type_char32_t>: New enum values.
13046 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
13047 and cplus_primitive_type_char32_t.
13048 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
13049 32, use the archtecture's built-in type for char16_t and char32_t,
13050 respectively. Otherwise, fallback to init_integer_type as before,
13051 but make the type unsigned, and issue a complaint.
13052 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
13053
ab0538b8
AH
130542017-04-12 Alan Hayward <alan.hayward@arm.com>
13055
5e0e0422 13056 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
ab0538b8
AH
13057 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
13058
5430098f
SDJ
130592017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
13060
13061 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
13062 'const char *'.
13063
7c5ded6a
SDJ
130642017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
13065
13066 * common/common-utils.c (free_vector_argv): New function.
13067 * common/common-utils.h: Include <vector>.
13068 (free_vector_argv): New prototype.
13069 * darwin-nat.c (darwin_create_inferior): Rewrite function
13070 prototype in order to constify "exec_file" and accept a
13071 "std::string" for "allargs".
13072 * fork-child.c: Include <vector>.
13073 (breakup_args): Rewrite function, using C++.
13074 (fork_inferior): Rewrite function header, constify "exec_file_arg"
13075 and accept "std::string" for "allargs". Update the code to
13076 calculate "argv" based on "allargs". Update calls to "exec_fun"
13077 and "execvp".
13078 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
13079 order to constify "exec_file" and accept a "std::string" for
13080 "allargs".
13081 * go32-nat.c (go32_create_inferior): Likewise.
13082 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
13083 * infcmd.c (run_command_1): Constify "exec_file". Use
13084 "std::string" for inferior arguments.
13085 * inferior.h (fork_inferior): Update prototype.
13086 * linux-nat.c (linux_nat_create_inferior): Rewrite function
13087 prototype in order to constify "exec_file" and accept a
13088 "std::string" for "allargs".
13089 * nto-procfs.c (procfs_create_inferior): Likewise.
13090 * procfs.c (procfs_create_inferior): Likewise.
13091 * remote-sim.c (gdbsim_create_inferior): Likewise.
13092 * remote.c (extended_remote_run): Update code to accept
13093 "std::string" as argument.
13094 (extended_remote_create_inferior): Rewrite function prototype in
13095 order to constify "exec_file" and accept a "std::string" for
13096 "allargs".
13097 * rs6000-nat.c (super_create_inferior): Likewise.
13098 (rs6000_create_inferior): Likewise.
13099 * target.h (struct target_ops) <to_create_inferior>: Likewise.
13100 * windows-nat.c (windows_create_inferior): Likewise.
13101
ae0eee42
PA
131022017-04-11 Pedro Alves <palves@redhat.com>
13103
13104 * thread.c: Fix whitespace throughout.
13105
a6acac06
PR
131062017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
13107
13108 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
13109
64403bd1
AH
131102017-04-11 Alan Hayward <alan.hayward@arm.com>
13111
13112 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
13113
a5bef50f
SDJ
131142017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
13115
13116 PR gdb/21364
13117 * osdata.c (info_osdata): Check if 'type' is an empty string
13118 instead of NULL.
13119
9295a5a9
PA
131202017-04-10 Pedro Alves <palves@redhat.com>
13121
13122 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
13123 (ptid_to_global_thread_id, in_thread_list)
13124 (do_captured_list_thread_ids, set_resumed, set_running)
13125 (set_executing, set_stop_requested, finish_thread_state)
13126 (validate_registers_access, can_access_registers_ptid)
13127 (print_thread_info_1, switch_to_thread)
13128 (do_restore_current_thread_cleanup)
13129 (make_cleanup_restore_current_thread, thread_command)
13130 (thread_name_command): Use operator== instead of ptid_equal.
13131
996812e3
PA
131322017-04-10 Pedro Alves <palves@redhat.com>
13133
13134 * thread.c (struct current_thread_cleanup) <next>: Delete field.
13135 (current_thread_cleanup_chain): Delete.
13136 (restore_current_thread_cleanup_dtor)
13137 (make_cleanup_restore_current_thread): Remove references to
13138 current_thread_cleanup_chain.
13139
845b344f
AH
131402017-04-10 Alan Hayward <alan.hayward@arm.com>
13141
13142 * msp430-tdep.c (msp430_pseudo_register_read): Never return
13143 REG_UNKNOWN.
13144
803bdfe4
YQ
131452017-04-10 Yao Qi <yao.qi@linaro.org>
13146
13147 PR gdb/19942
13148 * gdbthread.h (thread_info::deletable): New method.
13149 (thread_info::incref): New method.
13150 (thread_info::decref): New method.
13151 (thread_info::refcount): Move it to private.
13152 * infrun.c (save_stop_context): Call inc_refcount.
13153 (release_stop_context_cleanup): Likewise.
13154 * thread.c (set_thread_exited): New function.
13155 (init_thread_list): Delete "tp" only it is deletable, otherwise
13156 call set_thread_exited.
13157 (delete_thread_1): Call set_thread_exited.
13158 (current_thread_cleanup) <inferior_pid>: Remove.
13159 <thread>: New field.
13160 (restore_current_thread_ptid_changed): Removed.
13161 (do_restore_current_thread_cleanup): Adjust.
13162 (restore_current_thread_cleanup_dtor): Don't call
13163 find_thread_ptid.
13164 (set_thread_refcount): Use dec_refcount.
13165 (make_cleanup_restore_current_thread): Adjust.
13166 (thread_apply_all_command): Call inc_refcount.
13167 (_initialize_thread): Don't call
13168 observer_attach_thread_ptid_changed.
13169
8c25b497
YQ
131702017-04-10 Yao Qi <yao.qi@linaro.org>
13171
13172 * thread.c (delete_thread_1): Hoist code on marking thread as
13173 exited.
13174
8473b447
SM
131752017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
13176
13177 * windows-nat.c (windows_detach): Initialize ptid with
13178 minus_one_ptid.
13179
6670ec13
SM
131802017-04-07 Simon Marchi <simon.marchi@ericsson.com>
13181
13182 * unittests/ptid-selftests.c: Fix erroneous assert messages.
13183
ba2f91bb
AH
131842017-04-07 Alan Hayward <alan.hayward@arm.com>
13185
13186 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
13187 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
13188 (bfin_pseudo_register_write): Likewise
13189
436252de
SM
131902017-04-06 Simon Marchi <simon.marchi@ericsson.com>
13191
13192 * common/ptid.h (struct ptid): Change to...
13193 (class ptid_t): ... this.
13194 <ptid_t>: New constructors.
13195 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
13196 matches>: New methods.
13197 <make_null, make_minus_one>: New static methods.
13198 <pid>: Rename to...
13199 <m_pid>: ...this.
13200 <lwp>: Rename to...
13201 <m_lwp>: ...this.
13202 <tid>: Rename to...
13203 <m_tid>: ...this.
13204 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
13205 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
13206 as references, move comment to class ptid_t.
13207 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
13208 ptid_t static methods.
13209 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
13210 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
13211 Take ptid arguments as references, implement using ptid_t methods.
13212 * unittests/ptid-selftests.c: New file.
13213 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13214 unittests/ptid-selftests.c.
13215 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
13216
0dedf377
TP
132172017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
13218
13219 * python/python.c (python_run_simple_file): Cast mode literal to
13220 non-const char pointer as expected by PyFile_FromString.
13221
4e9868d4
SM
132222017-04-05 Simon Marchi <simon.marchi@ericsson.com>
13223
13224 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
13225 minus_one_ptid and null_ptid.
13226
9bf2a700
PA
132272017-04-05 Pedro Alves <palves@redhat.com>
13228
13229 * warning.m4 (build_warnings): Remove -Wno-write-strings.
13230 * configure: Regenerate.
13231
a121b7c1
PA
132322017-04-05 Pedro Alves <palves@redhat.com>
13233
13234 * ada-exp.y (yyerror): Constify.
13235 * ada-lang.c (bound_name, get_selections)
13236 (ada_variant_discrim_type)
13237 (ada_variant_discrim_name, ada_value_struct_elt)
13238 (ada_lookup_struct_elt_type, is_unchecked_variant)
13239 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
13240 (catch_ada_exception_command_split)
13241 (catch_ada_assert_command_split, catch_assert_command)
13242 (ada_op_name): Constify.
13243 * ada-lang.h (ada_yyerror, get_selections)
13244 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
13245 * arc-tdep.c (arc_print_frame_cache): Constify.
13246 * arm-tdep.c (arm_skip_stub): Constify.
13247 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
13248 (gen_aggregate_elt_ref): Constify.
13249 * bcache.c (print_bcache_statistics): Constify.
13250 * bcache.h (print_bcache_statistics): Constify.
13251 * break-catch-throw.c (catch_exception_command_1):
13252 * breakpoint.c (struct ep_type_description::description):
13253 Constify.
13254 (add_solib_catchpoint): Constify.
13255 (catch_fork_command_1): Add cast.
13256 (add_catch_command): Constify.
13257 * breakpoint.h (add_catch_command, add_solib_catchpoint):
13258 Constify.
13259 * bsd-uthread.c (bsd_uthread_state): Constify.
13260 * buildsym.c (patch_subfile_names): Constify.
13261 * buildsym.h (next_symbol_text_func, patch_subfile_names):
13262 Constify.
13263 * c-exp.y (yyerror): Constify.
13264 (token::oper): Constify.
13265 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
13266 * c-varobj.c (cplus_describe_child): Constify.
13267 * charset.c (find_charset_names): Add cast.
13268 (find_charset_names): Constify array and add const_cast.
13269 * cli/cli-cmds.c (complete_command, cd_command): Constify.
13270 (edit_command): Constify.
13271 * cli/cli-decode.c (lookup_cmd): Constify.
13272 * cli/cli-dump.c (dump_memory_command, dump_value_command):
13273 Constify.
13274 (struct dump_context): Constify.
13275 (add_dump_command, restore_command): Constify.
13276 * cli/cli-script.c (get_command_line): Constify.
13277 * cli/cli-script.h (get_command_line): Constify.
13278 * cli/cli-utils.c (check_for_argument): Constify.
13279 * cli/cli-utils.h (check_for_argument): Constify.
13280 * coff-pe-read.c (struct read_pe_section_data): Constify.
13281 * command.h (lookup_cmd): Constify.
13282 * common/print-utils.c (decimal2str): Constify.
13283 * completer.c (gdb_print_filename): Constify.
13284 * corefile.c (set_gnutarget): Constify.
13285 * cp-name-parser.y (yyerror): Constify.
13286 * cp-valprint.c (cp_print_class_member): Constify.
13287 * cris-tdep.c (cris_register_name, crisv32_register_name):
13288 Constify.
13289 * d-exp.y (yyerror): Constify.
13290 (struct token::oper): Constify.
13291 * d-lang.h (d_yyerror): Constify.
13292 * dbxread.c (struct header_file_location::name): Constify.
13293 (add_old_header_file, add_new_header_file, last_function_name)
13294 (dbx_next_symbol_text, add_bincl_to_list)
13295 (find_corresponding_bincl_psymtab, set_namestring)
13296 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
13297 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
13298 * defs.h (command_line_input, print_address_symbolic)
13299 (deprecated_readline_begin_hook): Constify.
13300 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
13301 Constify.
13302 * event-top.c (handle_line_of_input): Constify and add cast.
13303 * exceptions.c (catch_errors): Constify.
13304 * exceptions.h (catch_errors): Constify.
13305 * expprint.c (print_subexp_standard, op_string, op_name)
13306 (op_name_standard, dump_raw_expression, dump_raw_expression):
13307 * expression.h (op_name, op_string, dump_raw_expression):
13308 Constify.
13309 * f-exp.y (yyerror): Constify.
13310 (struct token::oper): Constify.
13311 (struct f77_boolean_val::name): Constify.
13312 * f-lang.c (f_word_break_characters): Constify.
13313 * f-lang.h (f_yyerror): Constify.
13314 * fork-child.c (fork_inferior): Add cast.
13315 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
13316 (new_variant): Constify.
13317 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
13318 * gdbarch.c: Regenerate.
13319 * gdbcore.h (set_gnutarget): Constify.
13320 * go-exp.y (yyerror): Constify.
13321 (token::oper): Constify.
13322 * go-lang.h (go_yyerror): Constify.
13323 * go32-nat.c (go32_sysinfo): Constify.
13324 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
13325 * guile/scm-cmd.c (cmdscm_function): Constify.
13326 * guile/scm-param.c (pascm_param_value): Constify.
13327 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
13328 (h8300sx_register_name): Constify.
13329 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
13330 Constify.
13331 * ia64-tdep.c (ia64_register_names): Constify.
13332 * infcmd.c (construct_inferior_arguments): Constify.
13333 (path_command, attach_post_wait): Constify.
13334 * language.c (show_range_command, show_case_command)
13335 (unk_lang_error): Constify.
13336 * language.h (language_defn::la_error)
13337 (language_defn::la_name_of_this): Constify.
13338 * linespec.c (decode_line_2): Constify.
13339 * linux-thread-db.c (thread_db_err_str): Constify.
13340 * lm32-tdep.c (lm32_register_name): Constify.
13341 * m2-exp.y (yyerror): Constify.
13342 * m2-lang.h (m2_yyerror): Constify.
13343 * m32r-tdep.c (m32r_register_names): Constify and make static.
13344 * m68hc11-tdep.c (m68hc11_register_names): Constify.
13345 * m88k-tdep.c (m88k_register_name): Constify.
13346 * macroexp.c (appendmem): Constify.
13347 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
13348 (upgrade_type, parse_external, parse_partial_symbols)
13349 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
13350 (new_symbol): Constify.
13351 * memattr.c (mem_info_command): Constify.
13352 * mep-tdep.c (register_name_from_keyword): Constify.
13353 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
13354 Constify.
13355 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
13356 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
13357 * mi/mi-main.c (captured_mi_execute_command): Constify and add
13358 cast.
13359 (mi_execute_async_cli_command): Constify.
13360 * mips-tdep.c (mips_register_name): Constify.
13361 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
13362 (am33_register_name, am33_2_register_name)
13363 * moxie-tdep.c (moxie_register_names): Constify.
13364 * nat/linux-osdata.c (osdata_type): Constify fields.
13365 * nto-tdep.c (nto_parse_redirection): Constify.
13366 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
13367 (lookup_child_selector): Constify.
13368 (objc_methcall::name): Constify.
13369 * objc-lang.h (lookup_objc_class, lookup_child_selector)
13370 (lookup_struct_typedef): Constify.
13371 * objfiles.c (pc_in_section): Constify.
13372 * objfiles.h (pc_in_section): Constify.
13373 * p-exp.y (struct token::oper): Constify.
13374 (yyerror): Constify.
13375 * p-lang.h (pascal_yyerror): Constify.
13376 * parser-defs.h (op_name_standard): Constify.
13377 (op_print::string): Constify.
13378 (exp_descriptor::op_name): Constify.
13379 * printcmd.c (print_address_symbolic): Constify.
13380 * psymtab.c (print_partial_symbols): Constify.
13381 * python/py-breakpoint.c (stop_func): Constify.
13382 (bppy_get_expression): Constify.
13383 * python/py-cmd.c (cmdpy_completer::name): Constify.
13384 (cmdpy_function): Constify.
13385 * python/py-event.c (evpy_add_attribute)
13386 (gdbpy_initialize_event_generic): Constify.
13387 * python/py-event.h (evpy_add_attribute)
13388 (gdbpy_initialize_event_generic): Constify.
13389 * python/py-evts.c (add_new_registry): Constify.
13390 * python/py-finishbreakpoint.c (outofscope_func): Constify.
13391 * python/py-framefilter.c (get_py_iter_from_func): Constify.
13392 * python/py-inferior.c (get_buffer): Add cast.
13393 * python/py-param.c (parm_constant::name): Constify.
13394 * python/py-unwind.c (fprint_frame_id): Constify.
13395 * python/python.c (gdbpy_parameter_value): Constify.
13396 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
13397 * remote.c (memory_packet_config::name): Constify.
13398 (show_packet_config_cmd, remote_write_bytes)
13399 (remote_buffer_add_string):
13400 * reverse.c (exec_reverse_once): Constify.
13401 * rs6000-tdep.c (variant::name, variant::description): Constify.
13402 * rust-exp.y (rustyyerror): Constify.
13403 * rust-lang.c (rust_op_name): Constify.
13404 * rust-lang.h (rustyyerror): Constify.
13405 * serial.h (serial_ops::name): Constify.
13406 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
13407 (sh_sh3e_register_name, sh_sh2e_register_name)
13408 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
13409 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
13410 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
13411 (sh_sh4al_dsp_register_name): Constify.
13412 * sh64-tdep.c (sh64_register_name): Constify.
13413 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
13414 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
13415 * stabsread.c (patch_block_stabs, read_type_number)
13416 (ref_map::stabs, ref_add, process_reference)
13417 (symbol_reference_defined, define_symbol, define_symbol)
13418 (error_type, read_type, read_member_functions, read_cpp_abbrev)
13419 (read_one_struct_field, read_struct_fields, read_baseclasses)
13420 (read_tilde_fields, read_struct_type, read_array_type)
13421 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
13422 (read_huge_number, read_range_type, read_args, common_block_start)
13423 (find_name_end): Constify.
13424 * stabsread.h (common_block_start, define_symbol)
13425 (process_one_symbol, symbol_reference_defined, ref_add):
13426 * symfile.c (get_section_index, add_symbol_file_command):
13427 * symfile.h (get_section_index): Constify.
13428 * target-descriptions.c (tdesc_type::name): Constify.
13429 (tdesc_free_type): Add cast.
13430 * target.c (find_default_run_target):
13431 (add_deprecated_target_alias, find_default_run_target)
13432 (target_announce_detach): Constify.
13433 (do_option): Constify.
13434 * target.h (add_deprecated_target_alias): Constify.
13435 * thread.c (print_thread_info_1): Constify.
13436 * top.c (deprecated_readline_begin_hook, command_line_input):
13437 Constify.
13438 (init_main): Add casts.
13439 * top.h (handle_line_of_input): Constify.
13440 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
13441 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
13442 (tfind_command): Rename to ...
13443 (tfind_command_1): ... this and constify.
13444 (tfind_command): New function.
13445 (tfind_end_command, tfind_start_command): Adjust.
13446 (encode_source_string): Constify.
13447 * tracepoint.h (encode_source_string): Constify.
13448 * tui/tui-data.c (tui_partial_win_by_name): Constify.
13449 * tui/tui-data.h (tui_partial_win_by_name): Constify.
13450 * tui/tui-source.c (tui_set_source_content_nil): Constify.
13451 * tui/tui-source.h (tui_set_source_content_nil): Constify.
13452 * tui/tui-win.c (parse_scrolling_args): Constify.
13453 * tui/tui-windata.c (tui_erase_data_content): Constify.
13454 * tui/tui-windata.h (tui_erase_data_content): Constify.
13455 * tui/tui-winsource.c (tui_erase_source_content): Constify.
13456 * tui/tui.c (tui_enable): Add cast.
13457 * utils.c (defaulted_query): Constify.
13458 (init_page_info): Add cast.
13459 (puts_debug, subset_compare): Constify.
13460 * utils.h (subset_compare): Constify.
13461 * varobj.c (varobj_format_string): Constify.
13462 * varobj.h (varobj_format_string): Constify.
13463 * vax-tdep.c (vax_register_name): Constify.
13464 * windows-nat.c (windows_detach): Constify.
13465 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
13466 * xml-support.c (gdb_xml_end_element): Constify.
13467 * xml-tdesc.c (tdesc_start_reg): Constify.
13468 * xstormy16-tdep.c (xstormy16_register_name): Constify.
13469 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
13470 * xtensa-tdep.h (xtensa_register_t::name): Constify.
13471
995816ba
PA
134722017-04-05 Pedro Alves <palves@redhat.com>
13473
13474 * proc-api.c (struct trans): Constify.
13475 (procfs_note): Constify.
13476 * proc-events.c (struct trans, syscall_table):
13477 * proc-flags.c (struct trans): Constify.
13478 * proc-utils.h (procfs_note): Constify.
13479 * proc-why.c (struct trans): Constify.
13480 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
13481 (procfs_detach): Constify.
13482 * sol-thread.c (struct string_map): Constify.
13483 (td_err_string, td_state_string): Constify.
13484
3e83a920
PA
134852017-04-05 Pedro Alves <palves@redhat.com>
13486
13487 * proc-api.c (procfs_filename): Don't initialize
13488 procfs_filename.
13489 (prepare_to_trace): Assume procfs_filename is non-NULL.
13490 (_initialize_proc_api): Give procfs_filename a default value here.
13491
63160a43
PA
134922017-04-05 Pedro Alves <palves@redhat.com>
13493
13494 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
13495 'cond_string' parameter.
13496 (extract_exception_regexp): Constify 'string' parameter.
13497 (catch_exception_command_1): Constify.
13498 * breakpoint.c (init_catchpoint)
13499 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
13500 parameter.
13501 (ep_parse_optional_if_clause, catch_fork_command_1)
13502 (catch_exec_command_1): Constify.
13503 * breakpoint.h (init_catchpoint): Constify 'cond_string'
13504 parameter.
13505 (ep_parse_optional_if_clause): Constify.
13506 * cli/cli-utils.c (remove_trailing_whitespace)
13507 (check_for_argument): Constify.
13508 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
13509 non-const overload.
13510 (check_for_argument): Likewise.
13511
9b2eba3d
PA
135122017-04-05 Pedro Alves <palves@redhat.com>
13513
13514 * event-top.c (command_line_handler): Add cast to execute_command
13515 call.
13516 * record-btrace.c (cmd_record_btrace_bts_start)
13517 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
13518 (cmd_record_btrace_start): Add cast to execute_command call.
13519 * record-full.c (record_full_goto_insn):
13520 * record.c (record_start, record_stop): Add cast to
13521 execute_command_to_string calls.
13522 (cmd_record_start): Add cast to execute_command calls.
13523
2adadf51
PA
135242017-04-05 Pedro Alves <palves@redhat.com>
13525
13526 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
13527 static inline function.
13528 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
13529 array and use gdb_PyArg_ParseTupleAndKeywords.
13530 * python/py-cmd.c (cmdpy_init): Likewise.
13531 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
13532 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
13533 (infpy_search_memory): Likewise.
13534 * python/py-objfile.c (objfpy_add_separate_debug_file)
13535 (gdbpy_lookup_objfile): Likewise.
13536 * python/py-symbol.c (gdbpy_lookup_symbol)
13537 (gdbpy_lookup_global_symbol): Likewise.
13538 * python/py-type.c (gdbpy_lookup_type): Likewise.
13539 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
13540 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
13541 Likewise.
13542
0d1f4ceb
PA
135432017-04-05 Pedro Alves <palves@redhat.com>
13544
13545 * python/python-internal.h (gdb_PyGetSetDef): New type.
13546 * python/py-block.c (block_object_getset)
13547 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
13548 * python/py-event.c (event_object_getset)
13549 (finish_breakpoint_object_getset): Likewise.
13550 * python/py-inferior.c (inferior_object_getset): Likewise.
13551 * python/py-infthread.c (thread_object_getset): Likewise.
13552 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
13553 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
13554 * python/py-objfile.c (objfile_getset): Likewise.
13555 * python/py-progspace.c (pspace_getset): Likewise.
13556 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
13557 Likewise.
13558 * python/py-record.c (recpy_record_getset): Likewise.
13559 * python/py-symbol.c (symbol_object_getset): Likewise.
13560 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
13561 Likewise.
13562 * python/py-type.c (type_object_getset, field_object_getset):
13563 Likewise.
13564 * python/py-value.c (value_object_getset): Likewise.
13565
4d759979
PA
135662017-04-05 Pedro Alves <palves@redhat.com>
13567
13568 * python/python-internal.h (gdb_PyObject_CallMethod)
13569 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
13570 New functions.
13571 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
13572 (PySys_GetObject, PySys_SetPath): New macros.
13573
fdf9e36f
PA
135742017-04-05 Pedro Alves <palves@redhat.com>
13575
13576 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
13577 info_osdata_command.
13578 * osdata.c (info_osdata_command): Rename to ...
13579 (info_osdata): ... this. Constify 'type' parameter, and remove
13580 the 'from_tty' parameter. Accept NULL TYPE.
13581 (info_osdata_command): New function.
13582 * osdata.h (info_osdata_command): Remove declaration.
13583 (info_osdata): New declaration.
13584
9f33b8b7
PA
135852017-04-05 Pedro Alves <palves@redhat.com>
13586
13587 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
13588 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
13589 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
13590 parameter.
13591 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
13592 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
13593 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
13594 parameter.
13595 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
13596 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
13597 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
13598 (mi_cmd_file_list_exec_source_files)
13599 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
13600 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
13601 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
13602 parameter.
13603 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
13604 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
13605 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
13606 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
13607 (mi_cmd_stack_info_frame): Constify 'command' parameter.
13608 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
13609 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
13610 'command' parameter.
13611 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
13612 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
13613 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
13614 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
13615 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
13616 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
13617 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
13618 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
13619 (mi_cmd_var_set_update_range): Constify 'command' parameter.
13620 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
13621 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
13622 parameter.
13623 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
13624 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
13625 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
13626 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
13627 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
13628 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
13629 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
13630 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
13631 (mi_cmd_data_list_changed_registers)
13632 (mi_cmd_data_write_register_values)
13633 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
13634 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
13635 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
13636 (mi_cmd_list_features, mi_cmd_list_target_features)
13637 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
13638 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
13639 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
13640 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
13641 (mi_cmd_trace_frame_collected): Constify 'command'
13642 parameter.
13643 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
13644 'command' parameter.
13645
67cb5b2d
PA
136462017-04-05 Pedro Alves <palves@redhat.com>
13647
13648 * ada-lang.c (ada_completer_word_break_characters): Now a const
13649 array.
13650 (ada_get_gdb_completer_word_break_characters): Constify.
13651 * completer.c (gdb_completer_command_word_break_characters)
13652 (gdb_completer_file_name_break_characters)
13653 (gdb_completer_quote_characters): Now const arrays.
13654 (get_gdb_completer_quote_characters): Constify.
13655 (set_rl_completer_word_break_characters): New function.
13656 (set_gdb_completion_word_break_characters)
13657 (complete_line_internal): Use it.
13658 * completer.h (get_gdb_completer_quote_characters): Constify.
13659 (set_rl_completer_word_break_characters): Declare.
13660 * f-lang.c (f_word_break_characters): Constify.
13661 * language.c (default_word_break_characters): Constify.
13662 * language.h (language_defn::la_word_break_characters): Constify.
13663 (default_word_break_characters): Constify.
13664 * top.c (init_main): Use set_rl_completer_word_break_characters.
13665
7a114964
PA
136662017-04-05 Pedro Alves <palves@redhat.com>
13667
13668 * aix-thread.c (aix_thread_pid_to_str)
13669 (aix_thread_extra_thread_info): Constify.
13670 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
13671 * bsd-uthread.c (bsd_uthread_extra_thread_info)
13672 (bsd_uthread_pid_to_str): Constify.
13673 * corelow.c (core_pid_to_str): Constify.
13674 * darwin-nat.c (darwin_pid_to_str): Constify.
13675 * fbsd-nat.c (fbsd_pid_to_str): Constify.
13676 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
13677 Constify.
13678 * gnu-nat.c (gnu_pid_to_str): Constify.
13679 * go32-nat.c (go32_pid_to_str): Constify.
13680 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
13681 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
13682 * inferior.c (inferior_pid_to_str): Constify.
13683 * linux-nat.c (linux_nat_pid_to_str): Constify.
13684 * linux-tdep.c (linux_core_pid_to_str): Constify.
13685 * linux-thread-db.c (thread_db_pid_to_str)
13686 (thread_db_extra_thread_info): Constify.
13687 * nto-tdep.c (nto_extra_thread_info): Constify.
13688 * nto-tdep.h (nto_extra_thread_info): Constify.
13689 * obsd-nat.c (obsd_pid_to_str): Constify.
13690 * procfs.c (procfs_pid_to_str): Constify.
13691 * ravenscar-thread.c (ravenscar_extra_thread_info)
13692 (ravenscar_pid_to_str): Constify.
13693 * remote-sim.c (gdbsim_pid_to_str): Constify.
13694 * remote.c (remote_threads_extra_info, remote_pid_to_str):
13695 Constify.
13696 * sol-thread.c (solaris_pid_to_str): Constify.
13697 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
13698 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
13699 * target.c (default_pid_to_str, target_pid_to_str)
13700 (normal_pid_to_str, default_pid_to_str): Constify.
13701 * target.h (target_ops::to_pid_to_str)
13702 (target_ops::to_extra_thread_info): Constify.
13703 (target_pid_to_str, normal_pid_to_str): Constify.
13704 * windows-nat.c (windows_pid_to_str): Constify.
13705 * gdbarch.sh (core_pid_to_str): Constify.
13706 * target-delegates.c: Regenerate.
13707 * gdbarch.h, gdbarch.c: Regenerate.
13708
69bbf465
PA
137092017-04-05 Pedro Alves <palves@redhat.com>
13710
13711 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
13712 the memory of the temporary warning_pre_print override.
13713 * utils.c (warning_pre_print): Constify.
13714 * utils.h (warning_pre_print): Constify.
13715
be47f9e8
PA
137162017-04-05 Pedro Alves <palves@redhat.com>
13717
13718 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
13719 (shell_command): New function.
13720 (make_command): Use std::string.
13721 (init_cli_cmds): Register shell_command instead of shell_escape.
13722
bde6261a
PA
137232017-04-05 Pedro Alves <palves@redhat.com>
13724
13725 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
13726 * tracepoint.c (default_collect): Don't initialize.
13727
b38ef47f
PA
137282017-04-05 Pedro Alves <palves@redhat.com>
13729
13730 * macroexp.c (macro_buffer::shared): Now a bool.
13731 (init_buffer): Update.
13732 (init_shared_buffer): Constify 'addr' parameter.
13733 (substitute_args, expand, macro_expand, macro_expand_next): Remove
13734 casts.
13735
f995bbe8
PA
137362017-04-05 Pedro Alves <palves@redhat.com>
13737
13738 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
13739 * disasm.c (set_disassembler_options): Constify local.
13740 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
13741
4a596fe2
SDJ
137422017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
13743
13744 PR gdb/21352
13745 * tracefile.c (tsave_command): Fix argument parsing for '-r'
13746 option.
13747
2cad08ea
YQ
137482017-04-05 Yao Qi <yao.qi@linaro.org>
13749
13750 * frame.c (frame_unwind_register_unsigned): Call
13751 frame_unwind_register_value.
13752
55a98976
YQ
137532017-04-05 Yao Qi <yao.qi@linaro.org>
13754
13755 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
13756 Use gdb_test_multiple, and don't match anchor.
13757
4ac40124
PA
137582017-04-05 Pedro Alves <palves@redhat.com>
13759
13760 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
13761 (Write After Approval): Remove Simon Marchi.
13762
c053b654
PA
137632017-04-05 Pedro Alves <palves@redhat.com>
13764
13765 * common/gdb_optional.h (optional::optional): Make constexpr and
13766 initialize m_dummy.
13767
4c7bf4f9
JB
137682017-04-04 John Baldwin <jhb@FreeBSD.org>
13769
13770 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
13771 (amd64fbsd_jmp_buf_reg_offset): Remove.
13772 (amd64fbsd_supply_uthread): Remove function.
13773 (amd64fbsd_collect_uthread): Remove function.
13774 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
13775 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
13776 (x86_64-*-freebsd*): Remove bsd-uthread.o.
13777 (fbsd-nat.c): Update comment.
13778 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
13779 (i386fbsd_jmp_buf_reg_offset): Remove.
13780 (i386fbsd_supply_uthread): Remove function.
13781 (i386fbsd_collect_uthread): Remove function.
13782 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
13783
1e1a8bef
JB
137842017-04-04 John Baldwin <jhb@FreeBSD.org>
13785
13786 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
13787 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
13788 * NEWS: Mention that support for FreeBSD/alpha was removed.
13789 * alpha-fbsd-tdep.c: Delete file.
13790 * config/alpha/fbsd.mh: Delete file.
13791 * configure.host: Delete alpha*-*-freebsd* and
13792 alpha*-*-kfreebsd*-gnu.
13793 * configure.tgt: Delete alpha*-*-freebsd* and
13794 alpha*-*-kfreebsd*-gnu.
13795
49907934
JB
137962017-04-04 John Baldwin <jhb@FreeBSD.org>
13797
13798 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
13799 amd64bsd_store_inferior_registers): Use ptid from regcache.
13800
6f77053d
PA
138012017-04-04 Pedro Alves <palves@redhat.com>
13802
13803 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
13804 data fields, make them private and add "m_" prefixes.
13805 (lnp_state_machine::lnp_state_machine): New ctor.
13806 (record_line, check_line_address, handle_set_discriminator)
13807 (handle_set_address, handle_advance_pc, handle_special_opcode)
13808 (handle_advance_line, handle_set_file, handle_negate_stmt)
13809 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
13810 (end_sequence, advance_line): New methods.
13811 (m_gdbarch, m_record_lines_p): New fields.
13812 (lnp_reader_state): Delete.
13813 (dwarf_record_line): Rename to ...
13814 (lnp_state_machine::record_line): ... adjust.
13815 (init_lnp_state_machine): Delete.
13816 (lnp_state_machine::lnp_state_machine): New.
13817 (check_line_address): Rename to ...
13818 (lnp_state_machine::check_line_address): This.
13819 (dwarf_decode_lines_1): Remove reference to "reader_state".
13820 Adjust lnp_state_machine having a non-default ctor. Use bool.
13821 State machine internal state manipulation moved to
13822 lnp_state_machine methods.
13823
9c541725
PA
138242017-04-04 Pedro Alves <palves@redhat.com>
13825
13826 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13827 unittests/offset-type-selftests.c.
13828 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
13829 * common/offset-type.h: New file.
13830 * common/preprocessor.h: New file.
13831 * common/traits.h: New file.
13832 * common/valid-expr.h: New file.
13833 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
13834 sect_offset and cu_offset strong typedefs throughout.
13835 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
13836 typedefs throughout.
13837 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
13838 sect_offset and cu_offset strong typedefs throughout.
13839 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
13840 typedefs throughout.
13841 * gdbtypes.h: Include "common/offset-type.h".
13842 (cu_offset): Now an offset type (strong typedef) instead of a
13843 struct.
13844 (sect_offset): Likewise.
13845 (union call_site_parameter_u): Rename "param_offset" field to
13846 "param_cu_off".
13847 * unittests/offset-type-selftests.c: New file.
13848
ecfb656c
PA
138492017-04-04 Pedro Alves <palves@redhat.com>
13850
13851 * common/underlying.h: New file.
13852 * dwarf2read.c: Include "common/gdb_optional.h" and
13853 "common/underlying.h".
13854 (dir_index, file_name_index): New types.
13855 (file_entry): Use them.
13856 (file_entry::include): Use to_underlying.
13857 (line_header::add_file_name): Use dir_index.
13858 (read_formatted_entries): Use gdb::optional. Read form before
13859 writting to file_entry.
13860 (dwarf_decode_line_header): Use dir_index.
13861 (lnp_state_machine::current_file): Use to_underlying.
13862 (lnp_state_machine::file): Change type to file_name_index.
13863 (dwarf_record_line): Use to_underlying.
13864 (init_lnp_state_machine): Use file_name_index.
13865 (dwarf_decode_lines_1): Use dir_index and file_name_index.
13866
d194f1fe
PA
138672017-04-04 Pedro Alves <palves@redhat.com>
13868
13869 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
13870 operator bool, has_value and get methods.
13871
fff8551c
PA
138722017-04-04 Pedro Alves <palves@redhat.com>
13873
13874 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
13875 fields.
13876 (line_header): Initialize all data fields. Change type of
13877 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
13878 Change type of include_dirs to std::vector<const char *>. Remove
13879 num_include_dirs, include_dirs_size. Change type of file_names to
13880 std::vector<file_entry>. Remove num_file_names, file_names_size.
13881 (line_header::line_header): New.
13882 (line_header::add_include_dir, line_header::add_file_name): New
13883 methods.
13884 (line_header::include_dir_at): Remove NULL check.
13885 (line_header::file_name_at): Add const overload.
13886 (line_header_up): New unique_ptr typedef.
13887 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
13888 std::vector. Remove free_line_header call.
13889 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
13890 free_line_header call.
13891 (free_cu_line_header): Delete.
13892 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
13893 (setup_type_unit_groups): Use line_header_up instead of cleanups.
13894 Adjust to use std::vector.
13895 (free_line_header): Delete.
13896 (free_line_header_voidp): Use delete.
13897 (add_include_dir): Replace with ...
13898 (line_header::add_include_dir): ... this method. Use std::vector.
13899 (add_file_name): Replace with ...
13900 (line_header::add_file_name): ... this method. Use std::vector.
13901 (add_include_dir_stub): Delete.
13902 (read_formatted_entries): Remove memset.
13903 (dwarf_decode_line_header): Return a line_header_up instead of a
13904 raw pointer. Remove cleanup handling. Pass lambdas to
13905 read_formatted_entries. Adjust to use line_header methods.
13906 (dwarf_decode_lines_1): Adjust to use line_header methods.
13907 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
13908 use std::vector.
13909
d62a8ae2
SM
139102017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
13911
13912 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
13913 instead of struct ptid.
13914
db3a1dc7
AH
139152017-05-04 Alan Hayward <alan.hayward@arm.com>
13916
13917 * frame.c (get_frame_register_bytes): Unwind using value.
13918 (put_frame_register_bytes): Likewise.
13919
b1b45502
IB
139202017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
13921
13922 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
13923 aggregate-like.
13924
ec13808e
JK
139252017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
13926
13927 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
13928
12316564
YQ
139292017-03-29 Yao Qi <yao.qi@linaro.org>
13930
13931 * gdbthread.h (struct thread_info): Declare constructor and
13932 destructor. Add some in-class member initializers.
13933 * thread.c (free_thread): Remove.
13934 (init_thread_list): Call delete instead of free_thread.
13935 (new_thread): Call thread_info constructor.
13936 (thread_info::thread_info): New function.
13937 (thread_info::~thread_info): New function.
13938 (delete_thread_1): Call delete instead of free_thread.
13939 (make_cleanup_restore_current_thread): Move tp and frame to
13940 inner block.
13941
fe5f7374
AK
139422017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
13943
13944 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
13945 (arc_skip_prologue): Likewise.
13946 (arc_make_frame_cache): Likewise.
13947 (arc_pv_get_operand): New function.
13948 (arc_is_in_prologue): Likewise.
13949 (arc_analyze_prologue): Likewise.
13950 (arc_print_frame_cache): Likewise.
13951 (MAX_PROLOGUE_LENGTH): New constant.
13952
eea78757
AK
139532017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
13954
13955 * configure.tgt: Add arc-insn.o.
13956 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
13957 (dump_arc_instruction_command): New function.
13958 (arc_fprintf_disasm): Likewise.
13959 (arc_disassemble_info): Likewise.
13960 (arc_insn_get_operand_value): Likewise.
13961 (arc_insn_get_operand_value_signed): Likewise.
13962 (arc_insn_get_memory_base_reg): Likewise.
13963 (arc_insn_get_memory_offset): Likewise.
13964 (arc_insn_get_branch_target): Likewise.
13965 (arc_insn_dump): Likewise.
13966 (arc_insn_get_linear_next_pc): Likewise.
13967 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
13968 (arc_disassemble_info): Likewise.
13969 (arc_insn_get_branch_target): Likewise.
13970 (arc_insn_get_linear_next_pc): Likewise.
13971 * NEWS: Mention new "maint print arc arc-instruction".
13972
3be78afd
AK
139732017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
13974
13975 * arc-tdep (maintenance_print_arc_list): New variable.
13976 (maintenance_print_arc_command): New function.
13977
296ec4fa
AK
139782017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
13979
13980 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
13981 Add "limm" and "reserved".
13982 (arc_cannot_fetch_register, arc_cannot_store_register): Add
13983 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
13984 * arc-tdep.h (arc_regnum): Likewise.
13985
f74f865e
MF
139862017-03-27 Max Filippov <jcmvbkbc@gmail.com>
13987
13988 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
13989 for THREADPTR register.
13990 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
13991 register.
13992 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
13993 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
13994 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
13995
0d0bf81a
MF
139962017-03-27 Max Filippov <jcmvbkbc@gmail.com>
13997
13998 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
13999 registers above gdbarch_num_regs (gdbarch) as privileged in
14000 call0 ABI.
14001
0ce4291e
MF
140022017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14003
14004 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
14005 for a single specified register or for all registers in
14006 a0_base..a0_base + C0_NREGS range.
14007 (supply_gregset_reg): Call regcache_raw_supply for a single
14008 specified register or for all registers in a0_base..a0_base +
14009 C0_NREGS range.
14010
c56054f9
MF
140112017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14012
14013 * arch/xtensa.h (C0_NREGS): Add definition.
14014 * xtensa-tdep.c (C0_NREGS): Remove definition.
14015
a4398628
MF
140162017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14017
14018 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
14019 Drop xtensa_default_isa initialization.
14020 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
14021
8c43009f
PA
140222017-03-27 Pedro Alves <palves@redhat.com>
14023
14024 * dwarf2read.c (file_entry) <dir_index>: Add comment.
14025 (file_entry::include_dir): New method.
14026 (line_header::include_dir_at, line_header::file_name_at): New
14027 methods.
14028 (setup_type_unit_groups, setup_type_unit_groups)
14029 (psymtab_include_file_name): Simplify using the new methods.
14030 (lnp_state_machine) <the_line_header>: New field.
14031 <file>: Add comment.
14032 (lnp_state_machine::current_file): New method.
14033 (dwarf_record_line): Simplify using the new methods.
14034 (init_lnp_state_machine): Initialize the "the_line_header" field.
14035 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
14036 Simplify using the new methods.
14037
a7e80b9e
PA
140382017-03-27 Pedro Alves <palves@redhat.com>
14039
14040 * cp-name-parser.y (make_empty): Delete.
14041 (demangler_special, nested_name, ptr_operator, array_indicator)
14042 (direct_declarator, declarator_1): Use fill_comp instead of
14043 make_empty.
14044
21047726
PA
140452017-03-27 Pedro Alves <palves@redhat.com>
14046
14047 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
14048 to ATTRIBUTE_PRINTF.
14049 * solib-target.c (library_list_start_list): Print "string" not
14050 "version".
14051 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
14052 gdb_xml_error call.
14053
d721ba37
PA
140542017-03-27 Pedro Alves <palves@redhat.com>
14055
14056 * dwarf2read.c (struct file_and_directory): New.
14057 (dwarf2_get_dwz_file): Adjust to use std::string.
14058 (dw2_get_file_names_reader): Adjust to use file_and_directory.
14059 (find_file_and_directory): Adjust to return a file_and_directory
14060 object.
14061 (read_file_scope): Adjust to use file_and_directory. Remove
14062 make_cleanup/do_cleanups calls.
14063 (open_and_init_dwp_file): Adjust to use std::string. Remove
14064 make_cleanup/do_cleanups calls.
14065 * python/python.c (do_start_initialization): Adjust to ldirname
14066 returning a std::string.
14067 * utils.c (ldirname): Now returns a std::string.
14068 * utils.h (ldirname): Change return type to std::string.
14069 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
14070 returning a std::string.
14071 * xml-tdesc.c (file_read_description_xml): Likewise.
14072
ed771251
AH
140732017-03-24 Alan Hayward <alan.hayward@arm.com>
14074
14075 * regcache.c (regcache_debug_print_register): New function.
14076 * regcache.h (regcache_debug_print_register): New declaration.
14077 * target.c (debug_print_register): Remove.
14078 (target_fetch_registers): Call regcache_debug_print_register.
14079 (target_store_registers): Likewise.
14080
568c1b9f
PB
140812017-03-24 Pádraig Brady <pbrady@fb.com>
14082
14083 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
14084 reference beyond the 'lh->include_dirs' array before accessing to
14085 it.
14086 (psymtab_include_file_name): Likewise.
14087 (dwarf_decode_lines_1): Likewise.
14088 (dwarf_decode_lines): Likewise.
14089 (file_file_name): Likewise.
14090
3e00d44f
SM
140912017-03-23 Simon Marchi <simon.marchi@ericsson.com>
14092
14093 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
14094 inferior_ptid.
14095 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
14096 ps_lsetfpregs): Likewise.
14097 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
14098 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
14099 ps_lsetfpregs): Likewise.
14100 * target.c (target_fetch_registers, target_store_registers):
14101 Remove asserts.
14102
077ae656
AH
141032017-03-23 Alan Hayward <alan.hayward@arm.com>
14104
14105 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
14106
1e2b521d
YQ
141072017-03-23 Yao Qi <yao.qi@linaro.org>
14108
14109 * aarch64-tdep.c (aarch64_process_record_test): Declare.
14110 (_initialize_aarch64_tdep): Register it.
14111 (aarch64_record_load_store): Handle PRFM instruction.
14112 (aarch64_process_record_test): New function.
14113
33877125
YQ
141142017-03-23 Yao Qi <yao.qi@linaro.org>
14115
14116 * aarch64-tdep.c (aarch64_record_load_store): Fix code
14117 indentation.
14118
a0eef940
YQ
141192017-03-23 Yao Qi <yao.qi@linaro.org>
14120
14121 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
14122
3f2a3564
PR
141232017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
14124
14125 python/python.c (do_start_initialization): Fix memory leak.
14126
b67aeab0
SM
141272017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
14128
14129 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
14130 using get_ptrace_pid.
14131 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
14132 inferior_ptid.
14133 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
14134 inferior_ptid instead of pid.
14135
ffdbe864
YQ
141362017-03-22 Yao Qi <yao.qi@linaro.org>
14137
14138 * aarch64-tdep.c: Wrap locally used classes in anonymous
14139 namespace.
14140 * arm-tdep.c: Likewise.
14141 * linespec.c: Likewise.
14142 * ui-out.c: Likewise.
14143
9d736fbf
JG
141442017-03-22 Jonah Graham <jonah@kichwacoders.com>
14145
14146 PR gdb/19637
14147 * python/lib/gdb/printer/bound_registers.py: Import sys.
14148
3de88e9a
SM
141492017-03-21 Simon Marchi <simon.marchi@ericsson.com>
14150
14151 * windows-nat.c (do_windows_fetch_inferior_registers): Add
14152 windows_thread_info parameter and use it instead of
14153 current_thread.
14154 (windows_fetch_inferior_registers): Don't set current_thread,
14155 pass the thread to do_windows_fetch_inferior_registers. Use
14156 ptid from regcache instead of inferior_ptid.
14157 (do_windows_store_inferior_registers): Add windows_thread_info
14158 parameter and use it instead of current_thread.
14159 (windows_store_inferior_registers): Don't set current_thread,
14160 pass the thread to do_windows_store_inferior_registers. Use
14161 ptid from regcache instead of inferior_ptid.
14162
0e7b8f61
SM
141632017-03-21 Simon Marchi <simon.marchi@ericsson.com>
14164
14165 * ser-mingw.c (ser_windows_raw): Remove reference to
14166 struct serial::current_timeout.
14167
5badf10a
IR
141682017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
14169
14170 PR tdep/20928
14171 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
14172 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
14173 (sparc64_fsr_type): Fix %fsr decoding.
14174
cee59b3f
TW
141752017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
14176
14177 * python/py-record-btrace.c (btpy_insn_data): Change return type
14178 for Python 2.
14179
639a9038
SM
141802017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
14181
14182 * spu-linux-nat.c (spu_fetch_inferior_registers,
14183 spu_store_inferior_registers): Use ptid from regcache, set and
14184 restore inferior_ptid.
14185 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
14186 Likewise.
14187
bcc0c096
SM
141882017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
14189
14190 * i386-linux-nat.c (fetch_register, store_register,
14191 i386_linux_fetch_inferior_registers,
14192 i386_linux_store_inferior_registers): Use ptid from regcache.
14193 * ia64-linux-nat.c (ia64_linux_fetch_register,
14194 ia64_linux_store_register): Likewise.
14195 * inf-ptrace.c (inf_ptrace_fetch_register,
14196 inf_ptrace_store_register): Likewise.
14197 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
14198 m32r_linux_store_inferior_registers): Likewise.
14199 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
14200 m68kbsd_store_inferior_registers): Likewise.
14201 * m68k-linux-nat.c (fetch_register, store_register,
14202 m68k_linux_fetch_inferior_registers,
14203 m68k_linux_store_inferior_registers): Likewise.
14204 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
14205 m88kbsd_store_inferior_registers): Likewise.
14206 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
14207 mips_fbsd_store_inferior_registers): Likewise.
14208 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
14209 mips64_linux_regsets_store_registers): Likewise.
14210 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
14211 mipsnbsd_store_inferior_registers): Likewise.
14212 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
14213 mips64obsd_store_inferior_registers): Likewise.
14214 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
14215 Likewise.
14216 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
14217 ppcfbsd_store_inferior_registers): Likewise.
14218 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
14219 ppc_linux_store_inferior_registers): Likewise.
14220 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
14221 ppcnbsd_store_inferior_registers): Likewise.
14222 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
14223 ppcobsd_store_registers): Likewise.
14224 * procfs.c (procfs_fetch_registers, procfs_store_registers):
14225 Likewise.
14226 * ravenscar-thread.c (ravenscar_fetch_registers,
14227 ravenscar_store_registers, ravenscar_prepare_to_store):
14228 Likewise.
14229 * record-btrace.c (record_btrace_fetch_registers,
14230 record_btrace_store_registers, record_btrace_prepare_to_store):
14231 Likewise.
14232 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
14233 Lookup inferior using ptid from regcache, instead of
14234 current_inferior.
14235 * remote.c (remote_fetch_registers, remote_store_registers): Use
14236 ptid from regcache.
14237 * rs6000-nat.c (fetch_register, store_register): Likewise.
14238 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
14239 s390_linux_store_inferior_registers): Likewise.
14240 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
14241 shnbsd_store_inferior_registers): Likewise.
14242 * sol-thread.c (sol_thread_fetch_registers,
14243 sol_thread_store_registers): Likewise.
14244 * sparc-nat.c (sparc_fetch_inferior_registers,
14245 sparc_store_inferior_registers): Likewise.
14246 * tilegx-linux-nat.c (fetch_inferior_registers,
14247 store_inferior_registers): Likewise.
14248 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
14249 vaxbsd_store_inferior_registers): Likewise.
14250 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
14251 store_xtregs): Likewise.
14252
c0f55cc6
AV
142532017-03-20 Artemiy Volkov <artemiyv@acm.org>
14254
14255 PR gdb/14441
14256 * NEWS: Mention support for rvalue references in GDB and python.
14257 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
14258 supports both lvalue and rvalue references.
14259
15c0a2a9
AV
142602017-03-20 Artemiy Volkov <artemiyv@acm.org>
14261
14262 PR gdb/14441
14263 * gdbtypes.c (rank_one_type): Implement overloading
14264 resolution rules regarding rvalue references.
14265
aa006118
AV
142662017-03-20 Artemiy Volkov <artemiyv@acm.org>
14267
14268 PR gdb/14441
14269 * aarch64-tdep.c (aarch64_type_align)
14270 (aarch64_extract_return_value, aarch64_store_return_value): Change
14271 lvalue reference type checks to general reference type checks.
14272 * amd64-tdep.c (amd64_classify): Likewise.
14273 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
14274 Likewise.
14275 * arm-tdep.c (arm_type_align, arm_extract_return_value)
14276 (arm_store_return_value): Likewise.
14277 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
14278 * c-typeprint.c (c_print_type): Likewise.
14279 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
14280 (cplus_number_of_children, cplus_describe_child): Likewise.
14281 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
14282 * completer.c (expression_completer): Likewise.
14283 * cp-support.c (make_symbol_overload_list_adl_namespace):
14284 Likewise.
14285 * darwin-nat-info.c (info_mach_region_command): Likewise.
14286 * dwarf2loc.c (entry_data_value_coerce_ref)
14287 (value_of_dwarf_reg_entry): Likewise.
14288 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
14289 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
14290 Likewise.
14291 * findvar.c (extract_typed_address, store_typed_address):
14292 Likewise.
14293 * gdbtypes.c (rank_one_type): Likewise.
14294 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
14295 * infcall.c (value_arg_coerce): Likewise.
14296 * language.c (pointer_type): Likewise.
14297 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
14298 Likewise.
14299 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
14300 * mn10300-tdep.c (mn10300_type_align): Likewise.
14301 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
14302 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
14303 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
14304 Likewise.
14305 * printcmd.c (print_formatted, x_command): Likewise.
14306 * python/py-type.c (typy_get_composite, typy_template_argument):
14307 Likewise.
14308 * python/py-value.c (valpy_referenced_value)
14309 (valpy_get_dynamic_type, value_has_field): Likewise.
14310 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
14311 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
14312 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
14313 * spu-tdep.c (spu_scalar_value_p): Likewise.
14314 * symtab.c (lookup_symbol_aux): Likewise.
14315 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
14316 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
14317 Likewise.
14318 * valops.c (value_cast_pointers, value_cast)
14319 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
14320 (value_struct_elt, value_struct_elt_bitpos)
14321 (value_find_oload_method_list, find_overload_match)
14322 (value_rtti_indirect_type): Likewise.
14323 * valprint.c (val_print_scalar_type_p, generic_val_print):
14324 Likewise.
14325 * value.c (value_actual_type, value_as_address, unpack_long)
14326 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
14327 (coerce_ref): Likewise.
14328 * varobj.c (varobj_get_value_type): Likewise.
14329
3fcf899d
AV
143302017-03-20 Artemiy Volkov <artemiyv@acm.org>
14331
14332 PR gdb/14441
14333 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
14334 table of constants.
14335 * python/lib/gdb/command/explore.py: Support exploring values
14336 of rvalue reference types.
14337 * python/lib/gdb/types.py: Implement get_basic_type() for
14338 rvalue reference types.
14339 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
14340 constant.
14341 * python/py-value.c (valpy_getitem): Add an rvalue reference
14342 check.
14343 (valpy_reference_value): Add new parameter "refcode".
14344 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
14345 New wrappers for valpy_reference_value().
14346 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
14347 (gdbpy_invoke_xmethod): Likewise.
14348
4297a3f0
AV
143492017-03-20 Artemiy Volkov <artemiyv@acm.org>
14350
14351 PR gdb/14441
14352 * dwarf2read.c (process_die, read_type_die_1): Handle the
14353 DW_TAG_rvalue_reference_type DIE.
14354 (read_tag_reference_type): Add new parameter "refcode".
14355
e1cb3213
AV
143562017-03-20 Artemiy Volkov <artemiyv@acm.org>
14357
14358 PR gdb/14441
14359 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
14360 (c_type_print_modifier, c_type_print_varspec_suffix)
14361 (c_type_print_base): Support printing rvalue reference types.
14362 * c-valprint.c (c_val_print, c_value_print): Support printing
14363 rvalue reference values.
14364
e4347c89
AV
143652017-03-20 Artemiy Volkov <artemiyv@acm.org>
14366
14367 PR gdb/14441
14368 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
14369 typename.
14370 * cp-support.c (replace_typedefs): Handle
14371 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
14372 * python/py-type.c (typy_lookup_type): Likewise.
14373
53cc15f5
AV
143742017-03-20 Artemiy Volkov <artemiyv@acm.org>
14375
14376 PR gdb/14441
14377 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
14378 * parse.c (insert_type): Change assert statement.
14379 (follow_types): Handle rvalue reference types.
14380 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
14381 constant.
14382
a65cfae5
AV
143832017-03-20 Artemiy Volkov <artemiyv@acm.org>
14384
14385 PR gdb/14441
14386 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
14387 value_ref() interface.
14388 * c-valprint.c (c_value_print): Likewise.
14389 * infcall.c (value_arg_coerce): Likewise.
14390 * python/py-value.c (valpy_reference_value): Likewise.
14391 * valops.c (value_cast, value_reinterpret_cast)
14392 (value_dynamic_cast, typecmp): Likewise.
14393 (value_ref): Parameterize by kind of return value reference type.
14394 * value.h (value_ref): Add new parameter "refcode".
14395
3b224330
AV
143962017-03-20 Artemiy Volkov <artemiyv@acm.org>
14397
14398 PR gdb/14441
14399 * dwarf2read.c (read_tag_reference_type): Use
14400 lookup_lvalue_reference_type() instead of lookup_reference_type().
14401 * eval.c (evaluate_subexp_standard): Likewise.
14402 * f-exp.y: Likewise.
14403 * gdbtypes.c (make_reference_type, lookup_reference_type):
14404 Generalize with rvalue reference types.
14405 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
14406 convenience wrappers for lookup_reference_type().
14407 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
14408 reference kind parameter.
14409 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
14410 wrappers for lookup_reference_type().
14411 * guile/scm-type.c (gdbscm_type_reference): Use
14412 lookup_lvalue_reference_type() instead of lookup_reference_type().
14413 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
14414 * parse.c (follow_types): Likewise.
14415 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
14416 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
14417 Likewise.
14418 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
14419 (gdbpy_invoke_xmethod): Likewise.
14420 * stabsread.c: Provide extra argument to make_reference_type()
14421 call.
14422 * valops.c (value_ref, value_rtti_indirect_type): Use
14423 lookup_lvalue_reference_type() instead of lookup_reference_type().
14424
f9aeb8d4
AV
144252017-03-20 Artemiy Volkov <artemiyv@acm.org>
14426
14427 PR gdb/14441
14428 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
14429 (TYPE_IS_REFERENCE): New macro.
14430 (struct type): Add rvalue_reference_type field.
14431 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
14432
51457a05
MAL
144332017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
14434
14435 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
14436 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
14437 New function definition.
14438 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
14439 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
14440 New function declaration.
14441 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
14442 * mi/mi-interp.h: New file.
14443 * solib.c (info_sharedlibrary_command): Replace for loop with
14444 ALL_SO_LIBS macro
14445 * solib.h (update_solib_list): New function declaration.
14446 (so_list_head): Move macro.
14447 * solist.h (ALL_SO_LIBS): New macro.
14448
e696b3ad
MAL
144492017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
14450
14451 * infcmd.c (post_create_inferior): Remove unused argument in
14452 call to solib_add.
14453 * remote.c (remote_start_remote): Likewise.
14454 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
14455 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
14456 (enable_break): Likewise.
14457 * solib.c (update_solib_list): Remove unused target argument
14458 and its documentation.
14459 (solib_add): Remove unused target argument. Remove unused
14460 argument in call to update_solib_list.
14461 (info_sharedlibrary_command): Remove unused argument in call
14462 to update_solib_list.
14463 (sharedlibrary_command): Remove unused argument in call to
14464 solib_add.
14465 (handle_solib_event): Likewise.
14466 (reload_shared_libraries): Likewise.
14467 * solib.h (solib_add): Remove unused target argument.
14468
dcb84eda
AA
144692017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
14470
14471 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
14472 (s390_displaced_step_fixup): Cover relative branches with the
14473 default fixup handling. This fixes lack of support for some
14474 relative branch instructions.
14475
d9cb6cdc
SM
144762017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14477
14478 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
14479 ptid from regcache.
14480
1afaf9f4
SM
144812017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14482
14483 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
14484 i386_darwin_store_inferior_registers): Use ptid from regcache.
14485
aac12e24
SM
144862017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14487
14488 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
14489 i386bsd_store_inferior_registers): Use ptid from regcache.
14490
bbe1eef1
SM
144912017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14492
14493 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
14494 hppaobsd_store_registers): Use ptid from regcache.
14495
10799020
SM
144962017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14497
14498 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
14499 hppanbsd_store_registers): Use ptid from regcache.
14500
00204cf7
SM
145012017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14502
14503 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
14504 from regcache. Use get_ptrace_pid.
14505
11a33714
SM
145062017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14507
14508 * corelow.c (get_core_register_section): Use ptid from regcache,
14509 update doc.
14510
317cd492
SM
145112017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14512
14513 * bsd-uthread.c (bsd_uthread_fetch_registers,
14514 bsd_uthread_store_registers): Use ptid from regcache, set and
14515 restore inferior_ptid.
14516
9ac8a7c2
SM
145172017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14518
14519 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
14520 fetch_fp_regs, store_register, store_regs, store_fp_register,
14521 store_fp_regs): Use ptid from regcache.
14522
4ac4bb6a
SM
145232017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14524
14525 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
14526 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
14527 store_vfp_regs): Use ptid from regcache.
14528
9bcbdca8
PA
145292017-03-17 Pedro Alves <palves@redhat.com>
14530
14531 PR remote/21188
14532 * ser-base.c (ser_base_wait_for): Add comment.
14533 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
14534 version.
14535 * ser-unix.c (hardwire_raw): Remove reference to
14536 scb->current_timeout.
14537 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
14538 (hardwire_ops): Install ser_base_readchar instead of
14539 hardwire_readchar.
14540 * serial.h (struct serial) <current_timeout, timeout_remaining>:
14541 Remove fields.
14542
7503099f
JG
145432017-03-17 Jonah Graham <jonah@kichwacoders.com>
14544
14545 PR gdb/19637
14546 * python/lib/gdb/printer/bound_registers.py: Add support for
14547 Python 3.
14548
7942e96e
AA
145492017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
14550
14551 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
14552 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
14553 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
14554 byte_offset to subobj_byte_offset. Fix the handling of
14555 DWARF_VALUE_STACK on big-endian targets when coming via an
14556 implicit pointer.
14557 (dwarf2_evaluate_loc_desc): Adjust call to
14558 dwarf2_evaluate_loc_desc_full.
14559 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
14560 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
14561
ba14f379
YQ
145622017-03-16 Yao Qi <yao.qi@linaro.org>
14563
14564 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
14565 and REVSH instructions.
14566
b121eeb9
YQ
145672017-03-16 Yao Qi <yao.qi@linaro.org>
14568
14569 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
14570 (arm_record_test): Declare.
14571 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
14572 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
14573 align with the manual.
14574 (thumb_record_misc): Adjust the code order to align with the
14575 manual.
14576 (thumb2_record_decode_insn_handler): Fix instruction matching.
14577 (instruction_reader_thumb): New class.
14578 (arm_record_test): New function.
14579
728a7913
YQ
145802017-03-16 Yao Qi <yao.qi@linaro.org>
14581
14582 * arm-tdep.c (abstract_memory_reader): New class.
14583 (instruction_reader): New class.
14584 (extract_arm_insn): Add argument 'reader'. Callers updated.
14585 (decode_insn): Likewise.
14586
34b43320
DE
145872017-03-16 Doug Evans <dje@google.com>
14588
a7c0469f
DE
14589 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
14590 member. Change type of TYPE member to SCM. All uses updated.
14591 (lsscm_make_lazy_string_smob): Add assert.
14592 (lsscm_make_lazy_string): Flag bad length values.
14593 (lsscm_elt_type): New function.
14594 (gdbscm_lazy_string_to_value): Rewrite to use
14595 lsscm_safe_lazy_string_to_value.
14596 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
14597 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
14598 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
14599 in incoming type.
14600 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
14601 * guile/scm-type.c (tyscm_scm_to_type): New function.
14602
146032017-03-15 Doug Evans <dje@google.com>
14604
34b43320
DE
14605 PR python/17728, python/18439, python/18779
14606 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
14607 member. Change type of TYPE member to PyObject *. All uses updated.
14608 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
14609 (gdbpy_create_lazy_string_object): Flag bad length values.
14610 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
14611 Handle typedefs in incoming type.
14612 (stpy_lazy_string_elt_type): New function.
14613 (gdbpy_extract_lazy_string): Call it.
14614 * python/py-value.c (valpy_lazy_string): Flag bad length values.
14615 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
14616 typedefs in incoming type.
14617
a3a5fecc
DE
146182017-03-16 Doug Evans <dje@google.com>
14619
14620 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
14621 * guile/scm-type.c (tyscm_scm_to_type): New function.
14622
28f1c605
JW
146232017-03-16 Jiong Wang <jiong.wang@arm.com>
14624
14625 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
14626 "ULONGEST" for "skip".
14627
87c336f6
AA
146282017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
14629
14630 PR gdb/21220
14631 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
14632 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
14633 (inf_ptrace_peek_poke): ...here. New function. Now also loop
14634 over ptrace peek/poke until end of buffer or error.
14635
cf81cf60
SM
146362017-03-14 Simon Marchi <simon.marchi@ericsson.com>
14637
14638 * parse.c (length_of_subexp): Make static.
14639 * parser-defs.h (length_of_subexp): Remove.
14640
a379284a
AA
146412017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
14642
14643 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
14644 as well.
14645
8a6200ba
PA
146462017-03-14 Pedro Alves <palves@redhat.com>
14647
14648 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
14649 (main): Use std::unique_ptr. Remove calls to
14650 cp_demangled_name_parse_free.
14651
f79ec206
SM
146522017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
14653
14654 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
14655 alphabsd_store_inferior_registers): Use regcache->ptid instead
14656 of inferior_ptid.
14657
edb5fb00
SM
146582017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
14659
14660 * aix-thread.c (aix_thread_fetch_registers,
14661 aix_thread_store_registers): Use regcache->ptid instead of
14662 inferior_ptid.
14663
55119686
SM
146642017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
14665
14666 * aarch64-linux-nat.c (fetch_gregs_from_thread,
14667 store_gregs_to_thread, fetch_fpregs_from_thread,
14668 store_fpregs_to_thread): Use regcache->ptid instead of
14669 inferior_ptid.
14670
6a06fbb7
SM
146712017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
14672
14673 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
14674 amd64_linux_fetch_inferior_registers): Use regcache->ptid
14675 instead of inferior_ptid.
14676
c6386875
SM
146772017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
14678
14679 * target.c (target_fetch_registers, target_store_registers): Add
14680 assert.
14681
ddaaf0fb
SM
146822017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
14683
14684 * regcache.h (regcache_get_ptid): New function.
14685 * regcache.c (regcache_get_ptid): New function.
14686
b9da89d1 146872017-03-13 Mark Wielaard <mark@klomp.org>
14688
14689 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
14690
5f4d1085
KS
146912017-03-10 Keith Seitz <keiths@redhat.com>
14692
14693 PR c++/8218
14694 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
14695
c65d6b55
PA
146962017-03-08 Pedro Alves <palves@redhat.com>
14697
14698 PR gdb/18360
14699 * infrun.c (start_step_over, do_target_resume, resume)
14700 (restart_threads): Assert we're not resuming a thread that is
14701 meant to be stopped.
14702 (infrun_thread_stop_requested_callback): Delete.
14703 (infrun_thread_stop_requested): If the thread is internally
14704 stopped, queue a pending stop event and clear the thread's
14705 inline-frame state.
14706 (handle_stop_requested): New function.
14707 (handle_syscall_event, handle_inferior_event_1): Use
14708 handle_stop_requested.
14709 (handle_stop_requested): New function.
14710 (handle_signal_stop): Set the thread's stop_signal here instead of
14711 at caller.
14712 (finish_step_over): Clear step over info unconditionally.
14713 (handle_signal_stop): If the user had interrupted the event
14714 thread, consider the stop a random signal.
14715 (handle_signal_stop) <signal arrived while stepping over
14716 breakpoint>: Don't restart threads here.
14717 (stop_waiting): Don't clear step-over info here.
14718
15c22686
PA
147192017-03-08 Pedro Alves <palves@redhat.com>
14720
14721 PR 21206
14722 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
14723 goes to argument 2, not 1.
14724
6e5d74e7
PA
147252017-03-08 Pedro Alves <palves@redhat.com>
14726
14727 PR cli/21218
14728 * top.c (gdb_readline_wrapper): Avoid passing NULL to
14729 display_gdb_prompt.
14730 (command_line_input): Add comment.
14731
9753a2f6
PA
147322017-03-08 Pedro Alves <palves@redhat.com>
14733
14734 PR tui/21216
14735 * tui/tui-file.c (tui_file::write): New.
14736 * tui/tui-file.h (tui_file): Override "write".
14737 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
14738 factored out from ...
14739 (tui_puts): ... here.
14740 (tui_putc): Use them.
14741 (tui_write): New function.
14742 * tui/tui-io.h (tui_write): Declare.
14743
1672e0d9
SDJ
147442017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
14745
14746 * Makefile.in (SFILES): Replace "environ.c" with
14747 "common/environ.c".
14748 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
14749 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
14750 to...
14751 * common/environ.c: ... here.
14752 * environ.h: Moved to...
14753 * common/environ.h: ... here.
14754
f7bb4e3a
PB
147552017-03-07 Peter Bergner <bergner@vnet.ibm.com>
14756
14757 * gdbarch.sh (pstring_ptr): New static function.
14758 (gdbarch_disassembler_options): Use it.
14759 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
14760 not valid_disassembler_option->name.
14761 * gdbarch.c: Regenerate.
14762
e45ced6c
PB
147632017-03-07 Peter Bergner <bergner@vnet.ibm.com>
14764
14765 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
14766
5f6fd321
PA
147672017-03-07 Pedro Alves <palves@redhat.com>
14768
14769 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
14770
6dbb839a 147712017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
4a612d6f
WT
14772
14773 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
14774 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
14775 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
6dbb839a 14776 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
4a612d6f 14777
d274ecf4
SM
147782017-03-06 Simon Marchi <simon.marchi@ericsson.com>
14779
14780 * xtensa-linux-nat.c (fetch_gregs): Remove const.
14781
df97be55
SM
147822017-03-03 Simon Marchi <simon.marchi@ericsson.com>
14783
14784 * remote.c (remote_add_target_side_commands): Use range-based
14785 for loop.
14786
7d45f3df
YQ
147872017-03-03 Yao Qi <yao.qi@linaro.org>
14788
14789 PR gdb/21165
14790 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
14791 value is lazy.
14792 * valprint.c (common_val_print): Likewise.
14793
65b48a81
PB
147942017-02-28 Peter Bergner <bergner@vnet.ibm.com>
14795
14796 * NEWS: Mention new set/show disassembler-options commands.
14797 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
14798 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
14799 (prospective_options): New static variable.
14800 (gdb_disassembler::gdb_disassembler): Initialize
14801 m_di.disassembler_options.
14802 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
14803 (get_disassembler_options): New function.
14804 (set_disassembler_options): Likewise.
14805 (set_disassembler_options_sfunc): Likewise.
14806 (show_disassembler_options_sfunc): Likewise.
14807 (disassembler_options_completer): Likewise.
14808 (_initialize_disasm): Likewise.
14809 * disasm.h (get_disassembler_options): New prototype.
14810 (set_disassembler_options): Likewise.
14811 * gdbarch.sh (gdbarch_disassembler_options): New variable.
14812 (gdbarch_verify_disassembler_options): Likewise.
14813 * gdbarch.c: Regenerate.
14814 * gdbarch.h: Likewise.
14815 * arm-tdep.c (num_disassembly_options): Delete.
14816 (set_disassembly_style): Likewise.
14817 (arm_disassembler_options): New static variable.
14818 (set_disassembly_style_sfunc): Convert short style name into long
14819 option name. Call set_disassembler_options.
14820 (show_disassembly_style_sfunc): New function.
14821 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
14822 set_gdbarch_verify_disassembler_options.
14823 (_initialize_arm_tdep): Delete regnames variable and update callers.
14824 (arm_disassembler_options): Initialize.
14825 (disasm_options): New variable.
14826 (num_disassembly_options): Rename from this...
14827 (num_disassembly_styles): ...to this. Compute by scanning through
14828 disasm_options.
14829 (valid_disassembly_styles): Initialize using disasm_options.
14830 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
14831 set_arm_regname_option.
14832 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
14833 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
14834 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
14835 set_gdbarch_verify_disassembler_options.
14836 * s390-tdep.c (s390_disassembler_options): New static variable.
14837 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
14838 set_gdbarch_verify_disassembler_options.
14839
d538e36d
SM
148402017-02-27 Simon Marchi <simon.marchi@ericsson.com>
14841
14842 * remote.c (remote_add_target_side_condition): Remove "struct"
14843 keyword from range-based for loop.
14844
83621223
SM
148452017-02-27 Simon Marchi <simon.marchi@ericsson.com>
14846
14847 * remote.c (remote_add_target_side_condition): Use range-based
14848 for loop. Update comment.
14849
2123df0e
YQ
148502017-02-27 Yao Qi <yao.qi@linaro.org>
14851
14852 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
14853
8e368124
AH
148542017-02-26 Alan Hayward <alan.hayward@arm.com>
14855
14856 * regcache.c (regcache_raw_update): New function.
14857 (regcache_raw_read): Move code to regcache_raw_update.
14858 * regcache.h (regcache_raw_update): New declaration.
14859 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
14860
a49dd8dd
JK
148612017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
14862
14863 * dwarf2read.c (create_debug_type_hash_table): Initialize
14864 header.signature and header.type_offset_in_tu.
14865
34e4bae9
PA
148662017-02-24 Pedro Alves <palves@redhat.com>
14867
14868 * symtab.c (make_file_symbol_completion_list_1): Use
14869 add_symtab_completions.
14870
b0e4b369
AH
148712017-02-24 Alan Hayward <alan.hayward@arm.com>
14872
14873 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
14874
975c21ab
AH
148752017-02-24 Alan Hayward <alan.hayward@arm.com>
14876
14877 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
14878 I386_MAX_REGISTER_SIZE.
14879 (i386_pseudo_register_write): Likewise.
14880 (i386_process_record): Likewise.
14881 * i387-tdep.c (i387_supply_xsave): Likewise.
14882 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
14883 (store_register): Likewise.
14884
14bc53a8
PA
148852017-02-23 Pedro Alves <palves@redhat.com>
14886
14887 * ada-lang.c: Include "common/function-view.h".
14888 (ada_iterate_over_symbols): Adjust to use function_view as
14889 callback type.
14890 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
14891 (ada_make_symbol_completion_list): Use a lambda.
14892 (ada_exc_search_name_matches): Delete.
14893 (name_matches_regex): New.
14894 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
14895 * compile/compile-c-support.c: Include "common/function-view.h".
14896 (print_one_macro): Change prototype to accept a ui_file pointer.
14897 (write_macro_definitions): Use a lambda.
14898 * dwarf2read.c: Include "common/function-view.h".
14899 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
14900 (dw2_expand_symtabs_matching): Adjust to use function_view as
14901 callback type.
14902 * language.h: Include "common/function-view.h".
14903 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
14904 function_view as callback type.
14905 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
14906 * linespec.c: Include "common/function-view.h".
14907 (collect_info::add_symbol): New method.
14908 (struct symbol_and_data_callback, iterate_inline_only, struct
14909 symbol_matcher_data, iterate_name_matcher): Delete.
14910 (iterate_over_all_matching_symtabs): Adjust to use function_view
14911 as callback type and lambdas.
14912 (iterate_over_file_blocks): Adjust to use function_view as
14913 callback type.
14914 (decode_compound_collector): Now a class with private fields.
14915 (decode_compound_collector::release_symbols): New method.
14916 (collect_one_symbol): Rename to...
14917 (decode_compound_collector::operator()): ... this and adjust.
14918 (lookup_prefix_sym): decode_compound_collector construction bits
14919 move to decode_compound_collector ctor. Pass the
14920 decode_compound_collector object directly as callback. Remove
14921 cleanups and use decode_compound_collector::release_symbols
14922 instead.
14923 (symtab_collector): Now a class with private fields.
14924 (symtab_collector::release_symtabs): New method.
14925 (add_symtabs_to_list): Rename to...
14926 (symtab_collector::operator()): ... this and adjust.
14927 (collect_symtabs_from_filename): symtab_collector construction
14928 bits move to symtab_collector ctor. Pass the symtab_collector
14929 object directly as callback. Remove cleanups and use
14930 symtab_collector::release_symtabs instead.
14931 (collect_symbols): Delete.
14932 (add_matching_symbols_to_info): Use lambdas.
14933 * macrocmd.c (print_macro_callback): Delete.
14934 (info_macro_command): Use a lambda.
14935 (info_macros_command): Pass print_macro_definition as callable
14936 directly.
14937 (print_one_macro): Remove 'ignore' parameter.
14938 (macro_list_command): Adjust.
14939 * macrotab.c (macro_for_each_data::fn): Now a function_view.
14940 (macro_for_each_data::user_data): Delete field.
14941 (foreach_macro): Adjust to call the function_view.
14942 (macro_for_each): Adjust to use function_view as callback type.
14943 (foreach_macro_in_scope): Adjust to call the function_view.
14944 (macro_for_each_in_scope): Adjust to use function_view as callback
14945 type.
14946 * macrotab.h: Include "common/function-view.h".
14947 (macro_callback_fn): Declare a prototype instead of a pointer.
14948 Remove "user_data" parameter.
14949 (macro_for_each, macro_for_each_in_scope): Adjust to use
14950 function_view as callback type.
14951 * psymtab.c (partial_map_expand_apply)
14952 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
14953 Adjust to use function_view as callback type and to return bool.
14954 (psym_expand_symtabs_matching): Adjust to use function_view as
14955 callback types.
14956 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
14957 to use function_view as callback type and to return bool.
14958 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
14959 callback types.
14960 * symfile.c (expand_symtabs_matching): Adjust to use function_view
14961 as callback types.
14962 * symfile.h: Include "common/function-view.h".
14963 (expand_symtabs_file_matcher_ftype)
14964 (expand_symtabs_symbol_matcher_ftype)
14965 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
14966 return bool.
14967 (quick_symbol_functions::map_symtabs_matching_filename)
14968 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
14969 function_view as callback type and return bool.
14970 (expand_symtabs_matching): Adjust to use function_view as callback
14971 type.
14972 (maintenance_expand_name_matcher)
14973 (maintenance_expand_file_matcher): Delete.
14974 (maintenance_expand_symtabs): Use lambdas.
14975 * symtab.c (iterate_over_some_symtabs): Adjust to use
14976 function_view as callback types and return bool.
14977 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
14978 of a cleanup.
14979 (lookup_symtab_callback): Delete.
14980 (lookup_symtab): Use a lambda.
14981 (iterate_over_symbols): Adjust to use function_view as callback
14982 type.
14983 (struct search_symbols_data, search_symbols_file_matches)
14984 (search_symbols_name_matches): Delete.
14985 (search_symbols): Use a pair of lambdas.
14986 (struct add_name_data, add_macro_name, symbol_completion_matcher)
14987 (symtab_expansion_callback): Delete.
14988 (default_make_symbol_completion_list_break_on_1): Use lambdas.
14989 * symtab.h: Include "common/function-view.h".
14990 (iterate_over_some_symtabs): Adjust to use function_view as
14991 callback type and return bool.
14992 (iterate_over_symtabs): Adjust to use function_view as callback
14993 type.
14994 (symbol_found_callback_ftype): Remove 'data' parameter and return
14995 bool.
14996 (iterate_over_symbols): Adjust to use function_view as callback
14997 type.
14998
07e253aa
PA
149992017-02-23 Pedro Alves <palves@redhat.com>
15000
15001 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
15002 (%.o) <unittests/%.c>: New pattern.
15003 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
15004 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
15005 * common/function-view.h: New file.
15006 * unittests/function-view-selftests.c: New file.
15007 * configure: Regenerate.
15008
8eaf5320
SM
150092017-02-23 Simon Marchi <simon.marchi@ericsson.com>
15010
15011 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
15012 inferior_ptid.
15013 * go32-nat.c (go32_thread_alive): Likewise.
15014
38768751
YQ
150152017-02-23 Yao Qi <yao.qi@linaro.org>
15016
15017 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
15018 delete.
15019
0a8beaba
YQ
150202017-02-23 Yao Qi <yao.qi@linaro.org>
15021
15022 * varobj.c (varobj_clear_saved_item): Use delete instead of
15023 xfree.
15024 (update_dynamic_varobj_children): Likewise.
15025
58fdfd2c
JK
150262017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
15027
15028 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
15029
1b90b139
SM
150302017-02-21 Simon Marchi <simon.marchi@ericsson.com>
15031
15032 * common/enum-flags.h (enum_flags::enum_flags): Initialize
15033 m_enum_value to 0 in default constructor.
15034
2039d74e
EBM
150352017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
15036
15037 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
15038 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
15039 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
15040 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
15041 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
15042 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
15043 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
15044 IS_STORE_CONDITIONAL_INSN.
15045
7814882a
JK
150462017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
15047
15048 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
15049
0ae60b63
JK
150502017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15051
15052 * NEWS (Changes since GDB 7.12): Add DWARF-5.
15053
0224619f
JK
150542017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15055
15056 * dwarf2read.c (skip_one_die, read_attribute_value)
15057 (dwarf2_const_value_attr, dump_die_shallow)
15058 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
15059 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
15060
0af92d60
JK
150612017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15062
15063 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
15064 (dwarf_parse_macro_header): Accept DWARF version 5.
15065 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
15066
216f72a1
JK
150672017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15068
15069 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
15070 DW_AT_GNU_*.
15071 * common/common-exceptions.h (enum errors): Likewise.
15072 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
15073 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
15074 (dwarf_expr_context::execute_stack_op): Likewise.
15075 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
15076 Likewise.
15077 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
15078 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
15079 (show_entry_values_debug, call_site_to_target_addr)
15080 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
15081 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
15082 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
15083 (value_of_dwarf_block_entry, indirect_pieced_value)
15084 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
15085 (disassemble_dwarf_expression): Likewise.
15086 * dwarf2read.c (process_die, inherit_abstract_dies)
15087 (read_call_site_scope): Likewise.
15088 * gdbtypes.h (struct func_type, struct call_site_parameter)
15089 (struct call_site): Likewise.
15090 * stack.c (read_frame_arg): Likewise.
15091 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
15092
43988095
JK
150932017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15094
15095 * defs.h (read_unsigned_leb128): New declaration.
15096 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
15097 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
15098 (dwarf2_find_location_expression): Call also
15099 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
15100 * dwarf2loc.h (dwarf2_version): New declaration.
15101 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
15102 rnglists.
15103 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
15104 .debug_rnglists.
15105 (struct dwop_section_names): Add loclists_dwo.
15106 (dwop_section_names): Add .debug_loclists.dwo.
15107 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
15108 (struct dwarf2_per_cu_data): Add dwarf_version.
15109 (struct dwo_sections): Add loclists.
15110 (struct attr_abbrev): Add implicit_const.
15111 (read_indirect_line_string): New declaration.
15112 (read_unsigned_leb128): Delete declaration.
15113 (rcuh_kind): New definition.
15114 (read_and_check_comp_unit_head): Change parameter
15115 is_debug_types_section to section_kind.
15116 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
15117 (read_comp_unit_head): Change parameter abfd to section, add parameter
15118 section_kind. Handle DWARF-5.
15119 (error_check_comp_unit_head): Accept also DWARF version 5.
15120 (read_and_check_comp_unit_head): Change parameter
15121 is_debug_types_section to section_kind.
15122 (read_and_check_type_unit_head): Delete function.
15123 (read_abbrev_offset): Handle DWARF-5.
15124 (create_debug_type_hash_table): Add parameter section_kind. Process
15125 only DW_UT_type. Use signature and type_offset_in_tu from struct
15126 comp_unit_head.
15127 (create_debug_types_hash_table): Update create_debug_type_hash_table
15128 caller.
15129 (create_all_type_units): Call create_debug_type_hash_table.
15130 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
15131 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
15132 caller.
15133 (skip_one_die): Handle DW_FORM_implicit_const.
15134 (dwarf2_rnglists_process): New function.
15135 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
15136 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
15137 (read_attribute_value): Handle DW_FORM_implicit_const,
15138 DW_FORM_line_strp.
15139 (read_attribute): Handle DW_FORM_implicit_const.
15140 (read_indirect_string_at_offset_from): New function from
15141 read_indirect_string_at_offset.
15142 (read_indirect_string_at_offset): Call
15143 read_indirect_string_at_offset_from.
15144 (read_indirect_line_string_at_offset): New function.
15145 (read_indirect_string): New function comment.
15146 (read_indirect_line_string): New function.
15147 (read_unsigned_leb128): Make it global.
15148 (dwarf2_string_attr): Handle DWARF-5.
15149 (add_include_dir_stub, read_formatted_entries): New functions.
15150 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
15151 Handle DWARF-5.
15152 (per_cu_header_read_in): Update read_comp_unit_head caller.
15153 (dwarf2_version): New function.
15154 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
15155 rnglists.
15156 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
15157 fields.
15158
22d2f3ab
JK
151592017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15160
15161 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
15162
5f46c5a5
JK
151632017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15164
15165 * dwarf2read.c (dwarf2_ranges_process): New function from
15166 dwarf2_ranges_read.
15167 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
15168 dwarf2_ranges_process.
15169
78d4d2c5
JK
151702017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15171
15172 * dwarf2read.c (create_debug_type_hash_table): New function from
15173 create_debug_types_hash_table.
15174 (create_debug_types_hash_table): Call create_debug_type_hash_table.
15175 (create_all_type_units, open_and_init_dwo_file): Update
15176 create_debug_types_hash_table callers.
15177
1b076f25
SDJ
151782017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
15179
15180 PR gdb/16188
15181 * fork-child.c (trace_start_error): Fix thinko. va_end should
15182 refer to 'ap', not 'args'.
15183
0db8980c
SDJ
151842017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
15185 Pedro Alves <palves@redhat.com>
15186
15187 PR gdb/16188
15188 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
15189 calls succeeded.
15190 * fork-child.c (trace_start_error): New function.
15191 (trace_start_error_with_name): Likewise.
15192 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
15193 * inf-ptrace.c (inf_ptrace_me): Likewise.
15194 * inferior.h (trace_start_error): New prototype.
15195 (trace_start_error_with_name): Likewise.
15196
99e8a4f9
SDJ
151972017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
15198
15199 PR gdb/21164
15200 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
15201 NULL before using it.
15202 * symmisc.c (maintenance_print_symbols): Likewise.
15203 (maintenance_print_msymbols): Likewise.
15204
4e746bb6
TW
152052017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15206
15207 * NEWS: Add record Python bindings entry.
15208
152092017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15210
15211 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
15212 py-record-full.o.
15213 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
15214 * python/py-record-btrace.c, python/py-record-btrace.h,
15215 python/py-record-full.c, python/py-record-full.h: New file.
15216 * python/py-record.c: Add include for py-record-btrace.h and
15217 py-record-full.h.
15218 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
15219 recpy_instruction_history, recpy_function_call_history, recpy_begin,
15220 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
15221 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
15222 New definition.
15223 (gdbpy_initialize_btrace): New export.
15224 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
15225
152262017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15227
15228 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
15229 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
15230 * python/py-record.c: New file.
15231 * python/python-internal.h (gdbpy_start_recording,
15232 gdbpy_current_recording, gdpy_stop_recording,
15233 gdbpy_initialize_record): New export.
15234 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
15235 (python_GdbMethods): Add gdbpy_start_recording,
15236 gdbpy_current_recording and gdbpy_stop_recording.
15237
152382017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15239
15240 * record-btrace.c (record_btrace_record_method): New function.
15241 (init_record_btrace_ops): Initialize to_record_method.
15242 * record-full.c (record_full_record_method): New function.
15243 (init_record_full_ops, init_record_full_core_ops): Add
15244 record_full_record_method.
15245 * record.h (enum record_method): New enum.
15246 * target-debug.h (target_debug_print_enum_record_method: New define.
15247 * target-delegates.c: Regenerate.
15248 * target.c (target_record_method): New function.
15249 * target.h: Include record.h.
15250 (struct target_ops) <to_record_method>: New field.
15251 (target_record_method): New export.
15252
152532017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15254
15255 * record.h (record_start, record_stop): New export.
15256 * record.c (record_start, record_stop): New function.
15257
152582017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15259
15260 * btrace.c (btrace_fetch): Copy function call segments pointer
15261 into a vector.
15262 (btrace_clear): Clear the vector.
15263 (btrace_find_insn_by_number): Use binary search to find the correct
15264 function call segment.
15265 * btrace.h (brace_fun_p): New typedef.
15266 (struct btrace_thread_info) <functions>: New field.
15267
152682017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15269
15270 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
15271 * btrace.c (btrace_decode_error): ... here. New function.
15272 * btrace.h (btrace_decode_error): New export.
15273
152742017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15275
15276 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
15277 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
15278 btrace_find_insn_by_number): Remove special case for gaps.
15279 * btrace.h (btrace_insn_get_error): New export.
15280 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
15281 * record-btrace.c (btrace_insn_history): Print number for gaps.
15282 (record_btrace_info, record_btrace_goto): Handle gaps.
15283
3f77c769
TT
152842017-02-14 Tom Tromey <tom@tromey.com>
15285
15286 PR python/13598:
15287 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
15288 event.
15289 * python/py-evts.c (gdbpy_initialize_py_events): Add
15290 before_prompt registry.
15291 * python/py-events.h (events_object) <before_prompt>: New field.
15292
4c2c7ac6
MM
152932017-02-14 Markus Metzger <markus.t.metzger@intel.com>
15294
15295 * btrace.c (ftrace_new_switch): Preserve up link and flags.
15296
5cf30ebf
LM
152972017-02-13 Luis Machado <lgustavo@codesourcery.com>
15298
15299 * symfile (_initialize_symfile): Add usage text to the load command's
15300 help text.
15301
26a06916
SM
153022017-02-10 Simon Marchi <simon.marchi@ericsson.com>
15303
15304 * utils.c (defaulted_query): Don't query on secondary UIs.
15305
0b145e37
TT
153062017-02-10 Tom Tromey <tom@tromey.com>
15307
15308 * rust-lang.c (rust_get_disr_info): Remove unused variable.
15309
2d8365c4
TT
153102017-02-10 Tom Tromey <tom@tromey.com>
15311
15312 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
15313 "cleanup" local.
15314 * python/py-type.c (typy_legacy_template_argument): Remove
15315 unnecessary "cleanup" local.
15316
2bb8f231
TT
153172017-02-10 Tom Tromey <tom@tromey.com>
15318
15319 * python/python.c (do_start_initialization): New function, from
15320 _initialize_python.
15321 (_initialize_python): Call do_start_initialization.
15322 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
15323 goto.
15324
1bdfaf42
TT
153252017-02-10 Tom Tromey <tom@tromey.com>
15326
15327 * python/py-prettyprint.c (pretty_print_one_value): Use
15328 gdbpy_ref.
15329
88b6faea
TT
153302017-02-10 Tom Tromey <tom@tromey.com>
15331
15332 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
15333 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
15334 gdbpy_ref.
15335 * python/py-type.c (field_new): Use gdbpy_ref.
15336 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
15337 gdbpy_ref.
15338 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
15339 (py_free_pspace): Likewise.
15340 (pspace_to_pspace_object): Likewise.
15341 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
15342 (py_free_objfile): Likewise.
15343 (objfile_to_objfile_object): Likewise.
15344 * python/py-inferior.c (delete_thread_object): Use
15345 gdbpy_ref.
15346 (infpy_read_memory): Likewise.
15347 (py_free_inferior): Likewise.
15348 * python/py-evtregistry.c (create_eventregistry_object): Use
15349 gdbpy_ref.
15350 * python/py-event.c (create_event_object): Use gdbpy_ref.
15351
7780f186
TT
153522017-02-10 Tom Tromey <tom@tromey.com>
15353
15354 * python/py-ref.h (gdbpy_ref_policy): Now a template.
15355 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
15356 used.
15357 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
15358 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
15359 python/py-exitedevent.c, python/py-finishbreakpoint.c,
15360 python/py-framefilter.c, python/py-function.c,
15361 python/py-inferior.c, python/py-infevents.c,
15362 python/py-linetable.c, python/py-newobjfileevent.c,
15363 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
15364 python/py-signalevent.c, python/py-stopevent.c,
15365 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
15366 python/py-unwind.c, python/py-utils.c, python/py-value.c,
15367 python/py-varobj.c, python/py-xmethods.c, python/python.c,
15368 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
15369
d4b0bb18
TT
153702017-02-10 Tom Tromey <tom@tromey.com>
15371
15372 * ui-out.h (ui_out_emit_type): New class.
15373 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
15374 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
15375 and ui_out_emit_tuple.
15376 (enumerate_locals): Likewise.
15377 (py_mi_print_variables, py_print_locals, py_print_args): Use
15378 ui_out_emit_list.
15379 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
15380 ui_out_emit_list.
15381 * common/gdb_optional.h: New file.
15382
f67f945c
MG
153832017-02-10 Martin Galvan <martingalvan@sourceware.org>
15384
15385 * MAINTAINERS (Write After Approval): Update my e-mail address.
15386
18da0c51
MG
153872017-02-10 Martin Galvan <martingalvan@sourceware.org>
15388
15389 PR gdb/21122
15390 * breakpoint.c (_initialize_breakpoint): Update the help description
15391 of the 'commands' command to indicate that it takes a list argument.
15392
62c14536
SM
153932017-02-09 Simon Marchi <simon.marchi@ericsson.com>
15394
15395 * interps.c (current_interp_set_logging): Remove "return".
15396
ff6fa247
GB
153972017-02-09 Gary Benson <gbenson@redhat.com>
15398
15399 * symtab.c (add_symtab_completions): Prevent NULL pointer
15400 dereference.
15401
a474bd8e
PA
154022017-02-08 Pedro Alves <palves@redhat.com>
15403
15404 * interps.c (interp::interp): Remove reference to quiet_p.
15405 (interp_set): Make static. Remove dead "Switching to" output
15406 code.
15407 (interp_quiet_p, interp_set_quiet): Delete.
15408 (interpreter_exec_cmd): Don't set the interpreter quiet.
15409 * interps.h (interp_quiet_p): Make static.
15410 (class interp) <quiet_p>: Remove field
15411
3d7b173c
JG
154122017-02-08 Jerome Guitton <guitton@adacore.com>
15413
604c4576
JG
15414 * cli/cli-decode.c (find_command_name_length): Make it extern.
15415 * cli/cli-decode.h (find_command_name_length): Declare.
15416 * cli/cli-script.c (command_name_equals, line_first_arg):
15417 New functions.
15418 (process_next_line): Use cli-decode to parse command names.
15419 (build_command_line): Make args a constant pointer.
15420
154212017-02-08 Jerome Guitton <guitton@adacore.com>
6dbb839a 15422
3d7b173c
JG
15423 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
15424 Remove case-insensitive search.
15425
1291063d
JM
154262017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
15427
15428 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
15429 at the end of the line. Avoids an ARI warning.
15430
20b477a7
LM
154312017-02-06 Luis Machado <lgustavo@codesourcery.com>
15432
15433 * NEWS: Mention support for record/replay of Intel 64 rdrand and
15434 rdseed instructions.
15435 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
15436
3f7b46f2
IR
154372017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
15438
15439 PR tdep/20936
15440 Provide and use sparc32 and sparc64 target description XML files.
15441 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
15442 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
15443 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
15444 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
15445 * features/sparc/sparc32-solaris.xml: New file.
15446 * features/sparc/sparc64-solaris.xml: New file.
15447 * features/sparc/sparc32-solaris.c: Generated.
15448 * features/sparc/sparc64-solaris.c: Generated.
15449 * sparc-tdep.h: Account for differences in target descriptions.
15450 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
15451 (sparc32_register_type): Use target provided registers.
15452 (validate_tdesc_registers): New function.
15453 (sparc32_gdbarch_init): Use tdesc_has_registers.
15454 Set pseudoregister functions.
15455 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
15456 (sparc64_register_type): Use target provided registers.
15457 (sparc64_init_abi): Set pseudoregister functions.
15458
f0fd41c1
TT
154592017-02-03 Tom Tromey <tom@tromey.com>
15460
15461 PR rust/21097:
15462 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
15463 with a single member.
15464
d6f9b0fb
PA
154652017-02-03 Pedro Alves <palves@redhat.com>
15466
15467 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
15468 (cli_interp_base::~cli_interp_base): New.
15469 (cli_interp): New struct.
15470 (as_cli_interp): Cast the interp itself to cli_interp.
15471 (cli_interpreter_pre_command_loop): Rename to ...
15472 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
15473 parameter.
15474 (cli_interpreter_init): Rename to ...
15475 (cli_interp::init): ... this. Remove 'self' parameter. Use
15476 boolean. Make extern.
15477 (cli_interpreter_resume): Rename to ...
15478 (cli_interp::resume): ... this. Remove 'data' parameter. Make
15479 extern.
15480 (cli_interpreter_suspend): Rename to ...
15481 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
15482 extern.
15483 (cli_interpreter_exec): Rename to ...
15484 (cli_interp::exec): ... this. Remove 'data' parameter. Make
15485 extern.
15486 (cli_interpreter_supports_command_editing): Rename to ...
15487 (cli_interp_base::supports_command_editing): ... this. Remove
15488 'interp' parameter. Make extern.
15489 (cli_ui_out): Rename to ...
15490 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
15491 Make extern.
15492 (cli_set_logging): Rename to ...
15493 (cli_interp_base::set_logging): ... this. Remove 'interp'
15494 parameter. Make extern.
15495 (cli_interp_procs): Delete.
15496 (cli_interp_factory): Adjust to use "new".
15497 * cli/cli-interp.h: Include "interps.h".
15498 (struct cli_interp_base): New struct.
15499 * interps.c (struct interp): Delete. Fields moved to interps.h.
15500 (interp_new): Delete.
15501 (interp::interp, interp::~interp): New.
15502 (interp_set): Use bool, and return void. Assume the interpreter
15503 has suspend, init and resume methods, and that the all return
15504 void.
15505 (set_top_level_interpreter): interp_set returns void.
15506 (interp_ui_out): Adapt.
15507 (current_interp_set_logging): Adapt.
15508 (interp_data): Delete.
15509 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
15510 (interp_exec): Adapt.
15511 (top_level_interpreter_data): Delete.
15512 * interps.h (interp_init_ftype, interp_resume_ftype)
15513 (interp_suspend_ftype, interp_exec_ftype)
15514 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
15515 (class interp): New.
15516 (interp_new): Delete.
15517 (interp_set): Now returns void. Use bool.
15518 (interp_data, top_level_interpreter_data): Delete.
15519 * mi/mi-common.h: Include interps.h.
15520 (class mi_interp): Inherit from interp. Define a ctor. Declare
15521 init, resume, suspect, exec, interp_ui_out, set_logging and
15522 pre_command_loop methods.
15523 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
15524 (mi_interpreter_init): Rename to ...
15525 (mi_interp::init): ... this. Remove the 'interp' parameter, use
15526 bool, return void and make extern. Adjust.
15527 (mi_interpreter_resume): ... Rename to ...
15528 (mi_interp::resume): ... this. Remove the 'data' parameter,
15529 return void and make extern. Adjust.
15530 (mi_interpreter_suspend): ... Rename to ...
15531 (mi_interp::suspend): ... this. Remove the 'data' parameter,
15532 return void and make extern. Adjust.
15533 (mi_interpreter_exec): ... Rename to ...
15534 (mi_interp::exec): ... this. Remove the 'data' parameter and make
15535 extern. Adjust.
15536 (mi_interpreter_pre_command_loop): ... Rename to ...
15537 (mi_interp::pre_command_loop): ... this. Remove the 'self'
15538 parameter and make extern.
15539 (mi_on_normal_stop_1): Adjust.
15540 (mi_ui_out): Rename to ...
15541 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
15542 parameter and make extern. Adjust.
15543 (mi_set_logging): Rename to ...
15544 (mi_interp::set_logging): ... this. Remove the 'interp'
15545 parameter and make extern. Adjust.
15546 (mi_interp_procs): Delete.
15547 (mi_interp_factory): Adjust to use 'new'.
15548 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
15549 (mi_print_exception, mi_execute_command, mi_load_progress):
15550 Adjust.
15551 * tui/tui-interp.c (tui_interp): New class.
15552 (as_tui_interp): Return a tui_interp pointer.
15553 (tui_on_normal_stop, tui_on_signal_received)
15554 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
15555 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
15556 to use interp::interp_ui_out.
15557 (tui_init): Rename to ...
15558 (tui_interp::init): ... this. Remove the 'self' parameter, use
15559 bool, return void and make extern. Adjust.
15560 (tui_resume): Rename to ...
15561 (tui_interp::resume): ... this. Remove the 'data' parameter,
15562 return void and make extern. Adjust.
15563 (tui_suspend): Rename to ...
15564 (tui_interp::suspend): ... this. Remove the 'data' parameter,
15565 return void and make extern. Adjust.
15566 (tui_ui_out): Rename to ...
15567 (tui_interp::interp_ui_out): ... this. Remove the 'self'
15568 parameter, and make extern. Adjust.
15569 (tui_exec): Rename to ...
15570 (tui_interp::exec): ... this. Remove the 'data' parameter and
15571 make extern.
15572 (tui_interp_procs): Delete.
15573 (tui_interp_factory): Use "new".
15574
65c40c95
TT
155752017-02-02 Tom Tromey <tom@tromey.com>
15576
15577 * rust-exp.y (ends_raw_string, space_then_number)
15578 (rust_identifier_start_p): Return bool.
15579 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
15580 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
15581 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
15582 (rust_chartype_p): Return bool.
15583 (val_print_struct, rust_print_struct_def, rust_print_type):
15584 Update.
15585 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
15586 Return bool.
15587
b50f188d
TT
155882017-02-02 Tom Tromey <tom@tromey.com>
15589
15590 * rust-lang.c: Reindent.
15591
03c85b11
TT
155922017-02-02 Tom Tromey <tom@tromey.com>
15593
15594 * rust-lang.h (rust_crate_for_block): Update.
15595 * rust-lang.c (rust_crate_for_block): Return std::string.
15596 (rust_get_disr_info): Use std:;string, not
15597 gdb::unique_xmalloc_ptr.
15598 * rust-exp.y (crate_name): Update.
15599
9b6da501
PA
156002017-02-02 Pedro Alves <palves@redhat.com>
15601
15602 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
15603 field out of gdb_disassembler_test and make it static.
15604
ec4cb20b
PA
156052017-02-02 Pedro Alves <palves@redhat.com>
15606
15607 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
15608 mi1_interp and mi_interp fields.
15609
5be5dbf0
PA
156102017-02-02 Pedro Alves <palves@redhat.com>
15611
616268b6
PA
15612 * cli/cli-interp.c (struct saved_output_files, saved_output):
15613 Moved from cli/cli-logging.c.
15614 (cli_set_logging): New function.
15615 (cli_interp_procs): Install cli_set_logging.
15616 * cli/cli-interp.h (make_logging_output, cli_set_logging):
15617 Declare.
15618 * cli/cli-logging.c (struct saved_output_files, saved_output):
15619 Moved to cli/cli-interp.c.
15620 (pop_output_files): Don't save outputs here.
15621 (make_logging_output): New function.
15622 (handle_redirections): Don't build tee nor save previous outputs
15623 here.
15624 * interps.c (current_interp_set_logging): Change prototype.
15625 Assume there's always a set_logging_proc method installed.
15626 * interps.h (interp_set_logging_ftype): Change prototype.
15627 (current_interp_set_logging): Change prototype and adjust comment.
15628 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
15629 use make_logging_output.
15630 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
156312017-02-02 Pedro Alves <palves@redhat.com>
15632
5be5dbf0
PA
15633 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
15634 from ...
15635 (set_logging_overwrite): ... here.
15636 (logging_no_redirect_file): Delete.
15637 (set_logging_redirect): Don't handle redirection on the fly.
15638 Instead warn that "logging off" / "logging on" is necessary.
15639 (pop_output_files): Delete references to logging_no_redirect_file.
15640 (show_logging_command): Always speak in terms of what will happen
15641 once logging is reenabled.
15642
c99cc448
PA
156432017-02-02 Pedro Alves <palves@redhat.com>
15644
15645 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
15646
8b172ce7
PA
156472017-02-02 Pedro Alves <palves@redhat.com>
15648
15649 * disasm.c (gdb_pretty_print_insn): Rename to ...
15650 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
15651 Remove gdbarch parameter. Adapt to clear the object's buffers
15652 instead of allocating new buffers, and to print using the object's
15653 gdb_disassembler instead of calling gdb_print_insn.
15654 (dump_insns): Use gdb_pretty_print_disassembler.
15655 * disasm.h (gdb_pretty_print_insn): Delete declaration.
15656 (gdb_pretty_print_disassembler): New class.
15657 * record-btrace.c (btrace_insn_history): Use
15658 gdb_pretty_print_disassembler.
15659
d7e74731
PA
156602017-02-02 Pedro Alves <palves@redhat.com>
15661
15662 * ada-lang.c (type_as_string): Use string_file.
15663 * ada-valprint.c (ada_print_floating): Use string_file.
15664 * ada-varobj.c (ada_varobj_scalar_image)
15665 (ada_varobj_get_value_image): Use string_file.
15666 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
15667 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
15668 * breakpoint.c (update_inserted_breakpoint_locations)
15669 (insert_breakpoint_locations, reattach_breakpoints)
15670 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
15671 (print_it_watchpoint): Use string_file.
15672 (save_breakpoints): Use stdio_file.
15673 * c-exp.y (oper): Use string_file.
15674 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
15675 tee_file.
15676 (pop_output_files): Use delete.
15677 (handle_redirections): Use stdio_file and tee_file.
15678 * cli/cli-setshow.c (do_show_command): Use string_file.
15679 * compile/compile-c-support.c (c_compute_program): Use
15680 string_file.
15681 * compile/compile-c-symbols.c (generate_vla_size): Take a
15682 'string_file &' instead of a 'ui_file *'.
15683 (generate_c_for_for_one_variable): Take a 'string_file &' instead
15684 of a 'ui_file *'. Use string_file.
15685 (generate_c_for_variable_locations): Take a 'string_file &'
15686 instead of a 'ui_file *'.
15687 * compile/compile-internal.h (generate_c_for_for_one_variable):
15688 Take a 'string_file &' instead of a 'ui_file *'.
15689 * compile/compile-loc2c.c (push, pushf, unary, binary)
15690 (print_label, pushf_register_address, pushf_register)
15691 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
15692 'ui_file *'. Adjust.
15693 * compile/compile.c (compile_to_object): Use string_file.
15694 * compile/compile.h (compile_dwarf_expr_to_c)
15695 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
15696 'ui_file *'.
15697 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
15698 (replace_typedefs_qualified_name): Use string_file and
15699 obstack_copy0.
15700 * disasm.c (gdb_pretty_print_insn): Use string_file.
15701 (gdb_disassembly): Adjust reference the null_stream global.
15702 (do_ui_file_delete): Delete.
15703 (gdb_insn_length): Use null_stream.
15704 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
15705 * dwarf2loc.c (dwarf2_compile_property_to_c)
15706 (locexpr_generate_c_location, loclist_generate_c_location): Take a
15707 'string_file &' instead of a 'ui_file *'.
15708 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
15709 * dwarf2read.c (do_ui_file_peek_last): Delete.
15710 (dwarf2_compute_name): Use string_file.
15711 * event-top.c (gdb_setup_readline): Use stdio_file.
15712 * gdbarch.sh (verify_gdbarch): Use string_file.
15713 * gdbtypes.c (safe_parse_type): Use null_stream.
15714 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
15715 string_file.
15716 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
15717 'string_file *' instead of a 'ui_file *'.
15718 (gdbscm_arch_disassemble): Use string_file.
15719 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
15720 * guile/scm-ports.c (class ioscm_file_port): Now a class that
15721 inherits from ui_file.
15722 (ioscm_file_port_delete, ioscm_file_port_rewind)
15723 (ioscm_file_port_put): Delete.
15724 (ioscm_file_port_write): Rename to ...
15725 (ioscm_file_port::write): ... this. Remove file_port_magic
15726 checks.
15727 (ioscm_file_port_new): Delete.
15728 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
15729 ui_file_up.
15730 * guile/scm-type.c (tyscm_type_name): Use string_file.
15731 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
15732 Use string_file.
15733 * infcmd.c (print_return_value_1): Use string_file.
15734 * infrun.c (print_target_wait_results): Use string_file.
15735 * language.c (add_language): Use string_file.
15736 * location.c (explicit_to_string_internal): Use string_file.
15737 * main.c (captured_main_1): Use null_file.
15738 * maint.c (maintenance_print_architecture): Use stdio_file.
15739 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
15740 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
15741 event_channel>: Change type to mi_console_file pointer.
15742 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
15743 (mi_console_file_delete): Delete.
15744 (struct mi_console_file): Delete.
15745 (mi_console_file_magic): Delete.
15746 (mi_console_file_new): Delete.
15747 (mi_console_file::mi_console_file): New.
15748 (mi_console_file_delete): Delete.
15749 (mi_console_file_fputs): Delete.
15750 (mi_console_file::write): New.
15751 (mi_console_raw_packet): Delete.
15752 (mi_console_file::flush): New.
15753 (mi_console_file_flush): Delete.
15754 (mi_console_set_raw): Rename to ...
15755 (mi_console_file::set_raw): ... this.
15756 * mi/mi-console.h (class mi_console_file): New class.
15757 (mi_console_file_new, mi_console_set_raw): Delete.
15758 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
15759 (mi_set_logging): Use delete and tee_file. Adjust.
15760 * mi/mi-main.c (output_register): Use string_file.
15761 (mi_cmd_data_evaluate_expression): Use string_file.
15762 (mi_cmd_data_read_memory): Use string_file.
15763 (mi_cmd_execute, print_variable_or_computed): Use string_file.
15764 * mi/mi-out.c (mi_ui_out::main_stream): New.
15765 (mi_ui_out::rewind): Use main_stream and
15766 string_file.
15767 (mi_ui_out::put): Use main_stream and string_file.
15768 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
15769 Allocate a 'string_file' instead.
15770 (mi_out_new): Don't allocate a mem_fileopen stream here.
15771 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
15772 (mi_ui_out::main_stream): Declare method.
15773 * printcmd.c (eval_command): Use string_file.
15774 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
15775 * python/py-arch.c (archpy_disassemble): Use string_file.
15776 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
15777 * python/py-frame.c (frapy_str): Use string_file.
15778 * python/py-framefilter.c (py_print_type, py_print_single_arg):
15779 Use string_file.
15780 * python/py-type.c (typy_str): Use string_file.
15781 * python/py-unwind.c (unwind_infopy_str): Use string_file.
15782 * python/py-value.c (valpy_str): Use string_file.
15783 * record-btrace.c (btrace_insn_history): Use string_file.
15784 * regcache.c (regcache_print): Use stdio_file.
15785 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
15786 * remote.c (escape_buffer): Use string_file.
15787 * rust-lang.c (rust_get_disr_info): Use string_file.
15788 * serial.c (serial_open_ops_1): Use stdio_file.
15789 (do_serial_close): Use delete.
15790 * stack.c (print_frame_arg): Use string_file.
15791 (print_frame_args): Remove local mem_fileopen stream, not used.
15792 (print_frame): Use string_file.
15793 * symmisc.c (maintenance_print_symbols): Use stdio_file.
15794 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
15795 Take a 'string_file *' instead of a 'ui_file *'.
15796 * top.c (new_ui): Use stdio_file and stderr_file.
15797 (free_ui): Use delete.
15798 (execute_command_to_string): Use string_file.
15799 (quit_confirm): Use string_file.
15800 * tracepoint.c (collection_list::append_exp): Use string_file.
15801 * tui/tui-disasm.c (tui_disassemble): Use string_file.
15802 * tui/tui-file.c: Don't include "ui-file.h".
15803 (enum streamtype, struct tui_stream): Delete.
15804 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
15805 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
15806 (tui_file::tui_file): New method.
15807 (tui_file_fputs): Delete.
15808 (tui_file_get_strbuf): Delete.
15809 (tui_file::puts): New method.
15810 (tui_file_adjust_strbuf): Delete.
15811 (tui_file_flush): Delete.
15812 (tui_file::flush): New method.
15813 * tui/tui-file.h: Tweak intro comment.
15814 Include ui-file.h.
15815 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
15816 (tui_file_adjust_strbuf): Delete declarations.
15817 (class tui_file): New class.
15818 * tui/tui-io.c (tui_initialize_io): Use tui_file.
15819 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
15820 (tui_register_format): Use string_stream.
15821 * tui/tui-stack.c (tui_make_status_line): Use string_file.
15822 (tui_get_function_from_frame): Use string_file.
15823 * typeprint.c (type_to_string): Use string_file.
15824 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
15825 (null_stream): New global.
15826 (ui_file_delete): Delete.
15827 (ui_file::ui_file): New.
15828 (null_file_isatty): Delete.
15829 (ui_file::~ui_file): New.
15830 (null_file_rewind): Delete.
15831 (ui_file::printf): New.
15832 (null_file_put): Delete.
15833 (null_file_flush): Delete.
15834 (ui_file::putstr): New.
15835 (null_file_write): Delete.
15836 (ui_file::putstrn): New.
15837 (null_file_read): Delete.
15838 (ui_file::putc): New.
15839 (null_file_fputs): Delete.
15840 (null_file_write_async_safe): Delete.
15841 (ui_file::vprintf): New.
15842 (null_file_delete): Delete.
15843 (null_file::write): New.
15844 (null_file_fseek): Delete.
15845 (null_file::puts): New.
15846 (ui_file_data): Delete.
15847 (null_file::write_async_safe): New.
15848 (gdb_flush, ui_file_isatty): Adjust.
15849 (ui_file_put, ui_file_rewind): Delete.
15850 (ui_file_write): Adjust.
15851 (ui_file_write_for_put): Delete.
15852 (ui_file_write_async_safe, ui_file_read): Adjust.
15853 (ui_file_fseek): Delete.
15854 (fputs_unfiltered): Adjust.
15855 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
15856 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
15857 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
15858 (set_ui_file_data): Delete.
15859 (string_file::~string_file, string_file::write)
15860 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
15861 (do_ui_file_as_string, ui_file_as_string): Delete.
15862 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
15863 (struct mem_file): Delete.
15864 (mem_file_new): Delete.
15865 (stdio_file::stdio_file): New.
15866 (mem_file_delete): Delete.
15867 (stdio_file::stdio_file): New.
15868 (mem_fileopen): Delete.
15869 (stdio_file::~stdio_file): New.
15870 (mem_file_rewind): Delete.
15871 (stdio_file::set_stream): New.
15872 (mem_file_put): Delete.
15873 (stdio_file::open): New.
15874 (mem_file_write): Delete.
15875 (stdio_file_magic, struct stdio_file): Delete.
15876 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
15877 (stdio_file::flush): New.
15878 (stdio_file_read): Rename to ...
15879 (stdio_file::read): ... this. Adjust.
15880 (stdio_file_write): Rename to ...
15881 (stdio_file::write): ... this. Adjust.
15882 (stdio_file_write_async_safe): Rename to ...
15883 (stdio_file::write_async_safe) ... this. Adjust.
15884 (stdio_file_fputs): Rename to ...
15885 (stdio_file::puts) ... this. Adjust.
15886 (stdio_file_isatty): Delete.
15887 (stdio_file_fseek): Delete.
15888 (stdio_file::isatty): New.
15889 (stderr_file_write): Rename to ...
15890 (stderr_file::write) ... this. Adjust.
15891 (stderr_file_fputs): Rename to ...
15892 (stderr_file::puts) ... this. Adjust.
15893 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
15894 (stderr_file::stderr_file): New.
15895 (tee_file_magic): Delete.
15896 (struct tee_file): Delete.
15897 (tee_file::tee_file): New.
15898 (tee_file_new): Delete.
15899 (tee_file::~tee_file): New.
15900 (tee_file_delete): Delete.
15901 (tee_file_flush): Rename to ...
15902 (tee_file::flush): ... this. Adjust.
15903 (tee_file_write): Rename to ...
15904 (tee_file::write): ... this. Adjust.
15905 (tee_file::write_async_safe): New.
15906 (tee_file_fputs): Rename to ...
15907 (tee_file::puts): ... this. Adjust.
15908 (tee_file_isatty): Rename to ...
15909 (tee_file::isatty): ... this. Adjust.
15910 * ui-file.h (struct obstack, struct ui_file): Don't
15911 forward-declare.
15912 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
15913 (ui_file_write_ftype)
15914 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
15915 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
15916 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
15917 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
15918 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
15919 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
15920 (set_ui_file_fseek): Delete.
15921 (ui_file_data, ui_file_delete, ui_file_rewind)
15922 (struct ui_file): New.
15923 (ui_file_up): New.
15924 (class null_file): New.
15925 (null_stream): Declare.
15926 (ui_file_write_for_put, ui_file_put): Delete.
15927 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
15928 Delete.
15929 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
15930 (gdb_fopen, tee_file_new): Delete.
15931 (struct string_file): New.
15932 (struct stdio_file): New.
15933 (stdio_file_up): New.
15934 (struct stderr_file): New.
15935 (class tee_file): New.
15936 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
15937 of a 'ui_file *'. Adjust.
15938 * ui-out.h (class ui_out) <field_stream>: Likewise.
15939 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
15940 (null_stream): Delete.
15941 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
15942 Adjust.
15943 * utils.h (struct ui_file): Delete forward declaration..
15944 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
15945 (error_stream): Take a 'string_file &' instead of a
15946 'ui_file *'.
15947 * varobj.c (varobj_value_get_print_value): Use string_file.
15948 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
15949 * gdbarch.c: Regenerate.
15950
187808b0
PA
159512017-02-02 Pedro Alves <palves@redhat.com>
15952
15953 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
15954 (gdb_pretty_print_insn): ... this. Now a free function. Add back
15955 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
15956 Adjust to call gdb_print_insn instead of
15957 gdb_disassembler::print_insn.
15958 (dump_insns, do_mixed_source_and_assembly_deprecated)
15959 (do_mixed_source_and_assembly, do_assembly_only): Add back a
15960 'gdbarch' parameter. Remove gdb_disassembler parameter.
15961 (gdb_disassembly): Don't allocate a gdb_disassembler here.
15962 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
15963 declaration.
15964 (gdb_pretty_print_insn): Re-add declaration.
15965 * record-btrace.c (btrace_insn_history): Don't allocate a
15966 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
15967
7a8eb317
SM
159682017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
15969
15970 * disasm.h (gdb_disassembly): Remove file_string parameter.
15971 * disasm.c (gdb_disassembly): Likewise.
15972 * cli/cli-cmds.c (print_disassembly): Adapt.
15973 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
15974 * stack.c (do_gdb_disassembly): Likewise.
15975
7346ef59
AA
159762017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
15977
15978 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
15979 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
15980 targets. And if the implicit value is longer than needed, extract
15981 the first bytes instead of the "least significant" ones.
15982
cd4007e4
MM
159832017-02-01 Markus Metzger <markus.t.metzger@intel.com>
15984
15985 * btrace.c (btrace_enable): Do not call btrace_add_pc for
15986 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
15987 (btrace_fetch): Assert can_access_registers_ptid.
15988 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
15989 validate_registers_access.
15990
cf77c34e
MM
159912017-02-01 Markus Metzger <markus.t.metzger@intel.com>
15992
15993 * gdbthread.h (can_access_registers_ptid): New.
15994 * thread.c (can_access_registers_ptid): New.
15995
be85ce7d
PA
159962017-02-01 Pedro Alves <palves@redhat.com>
15997
15998 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
15999
29b0b251
PA
160002017-01-31 Pedro Alves <palves@redhat.com>
16001
16002 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
16003 Fix typos.
16004
289b5b24
PA
160052017-01-31 Pedro Alves <palves@redhat.com>
16006
16007 * stack.c (print_frame_args): Remove local mem_fileopen stream,
16008 not used.
16009
b47413b4
PA
160102017-01-31 Pedro Alves <palves@redhat.com>
16011
16012 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
16013
60adb36c
PA
160142017-01-31 Pedro Alves <palves@redhat.com>
16015
16016 * common/scoped_restore.h
16017 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
16018 change the value's parameter type to T2.
16019 (make_scoped_restore): Likewise.
16020
2735833d
WT
160212017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
16022 Richard Henderson <rth@redhat.com>
16023
16024 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
16025 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
16026 GS_BASE for older kernels.
16027 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
16028 GS_BASE for older kernels.
16029 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
16030 and GS_BASE to the offset table.
16031 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
16032 system register group.
16033 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
16034 for older kernels.
16035 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
16036 amd64 ABI.
16037 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
16038 AMD64_GSBASE_REGNUM.
16039 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
16040 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
16041 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
16042 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
16043 i386/64bit-segments.xml in those rules.
16044 * features/i386/64bit-segments.xml: New file.
16045 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
16046 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
16047 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
16048 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
16049 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
16050 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
16051 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
16052 * features/i386/amd64-avx-linux.c: Regenerated.
16053 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
16054 * features/i386/amd64-avx-mpx.c: Regenerated.
16055 * features/i386/amd64-avx512-linux.c: Regenerated.
16056 * features/i386/amd64-linux.c: Regenerated.
16057 * features/i386/amd64-mpx-linux.c: Regenerated.
16058 * features/i386/i386-avx-mpx-linux.c: Regenerated.
16059 * features/i386/i386-avx-mpx.c: Regenerated.
16060 * features/i386/x32-avx-linux.c: Regenerated.
16061 * features/i386/x32-avx512-linux.c: Regenerated.
16062 * regformats/i386/amd64-avx-linux.dat: Regenerated.
16063 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
16064 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
16065 * regformats/i386/amd64-linux.dat: Regenerated.
16066 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
16067 * regformats/i386/x32-avx-linux.dat: Regenerated.
16068 * regformats/i386/x32-avx512-linux.dat: Regenerated.
16069 * regformats/i386/x32-linux.dat: Regenerated.
16070
8884e97e
WT
160712017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
16072
16073 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
16074 Set to AMD64_NUM_REGS.
16075
7005d26a
WT
160762017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
16077
16078 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
16079 that checks validity of a register number.
16080
4bd2e1b2
KC
160812017-01-27 Kees Cook <keescook@google.com>
16082
16083 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
16084 fetch_fpregs if target has fpa registers.
16085 (arm_linux_store_inferior_registers): Call store_fpregs if target
16086 has fpa registers.
16087
7cf1de6c
AA
160882017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
16089
16090 * cris-tdep.c (cris_gdbarch_init): Remove check for
16091 info.byte_order and force it to BFD_ENDIAN_LITTLE.
16092
874a1c8c
AT
160932017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
16094
16095 * corelow.c (get_core_register_section): Check for regset
16096 existence before checking for REGSET_VARIABLE_SIZE.
16097
d8b49cf0
YQ
160982017-01-26 Yao Qi <yao.qi@linaro.org>
16099 Pedro Alves <palves@redhat.com>
16100
16101 PR gdb/20939
16102 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
16103 call memory_error, save memaddr instead.
16104 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
16105 negative, cal memory_error.
16106 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
16107
658ca58c
YQ
161082017-01-26 Yao Qi <yao.qi@linaro.org>
16109
16110 * disasm-selftests.c (memory_error_test): New function.
16111 (_initialize_disasm_selftests): Register memory_error_test.
16112
79843d45
YQ
161132017-01-26 Yao Qi <yao.qi@linaro.org>
16114
16115 * Makefile.in (SFILES): Add disasm-selftests.c and
16116 selftest-arch.c.
16117 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
16118 * disasm-selftests.c: New file.
16119 * selftest-arch.c: New file.
16120 * selftest-arch.h: New file.
16121
8cafda32
YQ
161222017-01-26 Yao Qi <yao.qi@linaro.org>
16123
16124 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
16125 to bfd_arch_mep. Don't return 0 if section is not
16126 found. Call print_insn_mep.
16127
e47ad6c0
YQ
161282017-01-26 Pedro Alves <palves@redhat.com>
16129 Yao Qi <yao.qi@linaro.org>
16130
16131 * arm-tdep.c: Include "disasm.h".
16132 (gdb_print_insn_arm): Update code to get gdbarch.
16133 * disasm.c (dis_asm_read_memory): Change it to
16134 gdb_disassembler::dis_asm_read_memory.
16135 (dis_asm_memory_error): Likewise.
16136 (dis_asm_print_address): Likewise.
16137 (gdb_pretty_print_insn): Change it to
16138 gdb_disassembler::pretty_print_insn.
16139 (dump_insns): Add one argument gdb_disassemlber. All
16140 callers updated.
16141 (do_mixed_source_and_assembly_deprecated): Likewise.
16142 (do_mixed_source_and_assembly): Likewise.
16143 (do_assembly_only): Likewise.
16144 (gdb_disassembler::gdb_disassembler): New.
16145 (gdb_disassembler::print_insn): New.
16146 * disasm.h (class gdb_disassembler): New.
16147 (gdb_pretty_print_insn): Remove declaration.
16148 (gdb_disassemble_info): Likewise.
16149 * guile/scm-disasm.c (class gdbscm_disassembler): New.
16150 (gdbscm_disasm_read_memory_worker): Update.
16151 (gdbscm_disasm_read_memory): Update.
16152 (gdbscm_disasm_memory_error): Remove.
16153 (gdbscm_disasm_print_address): Remove.
16154 (gdbscm_disassembler::gdbscm_disassembler): New.
16155 (gdbscm_print_insn_from_port): Update.
16156 * mips-tdep.c: Include disasm.h.
16157 (gdb_print_insn_mips): Update code to get gdbarch.
16158 * record-btrace.c (btrace_insn_history): Update.
16159 * spu-tdep.c: Include disasm.h.
16160 (struct spu_dis_asm_data): Remove.
16161 (struct spu_dis_asm_info): New.
16162 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
16163 SPU id.
16164 (gdb_print_insn_spu): Cast disassemble_info to
16165 spu_dis_asm_info.
16166
80d75874
YQ
161672017-01-26 Yao Qi <yao.qi@linaro.org>
16168
16169 * disasm.c (do_ui_file_delete): Delete.
16170 (gdb_insn_length): Move code creating stream to ...
16171 * utils.c (null_stream): ... here. New function.
16172 * utils.h (null_stream): Declare.
16173
60685cd0
SM
161742017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
16175
16176 * python/py-inferior.c (find_thread_object): Return directly
16177 from the loop. Remove "found" variable.
16178
eb1cdb62
JB
161792017-01-21 Joel Brobecker <brobecker@adacore.com>
16180
16181 GDB 7.12.1 released.
16182
b1ce6568
SM
161832017-01-20 Simon Marchi <simon.marchi@ericsson.com>
16184
16185 * python/py-function.c (fnpy_call): Reorder declarations to have
16186 the gdbpy_enter object declared first.
16187 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
16188
6f8b0407
SM
161892017-01-20 Simon Marchi <simon.marchi@ericsson.com>
16190
fec93fb1 16191 PR python/21068
6f8b0407
SM
16192 * python/python-internal.h (PyMem_RawMalloc): Define for
16193 Python < 3.4.
16194 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
16195 PyMem_RawMalloc instead of PyMem_Malloc.
16196
78cbbba8
LM
161972017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
16198 Luis Machado <lgustavo@codesourcery.com>
16199
16200 * NEWS (New commands): Mention flash-erase.
16201 (New MI commands): Mention target-flash-erase.
16202 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
16203 command.
16204 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
16205 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
16206 * target.c (flash_erase_command): New function.
16207 (initialize_targets): Add new flash-erase command.
16208 * target.h (flash_erase_command): New declaration.
16209
2132fe85
JB
162102017-01-20 Joel Brobecker <brobecker@adacore.com>
16211
16212 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
16213 HAVE_SYS_PROCFS_H is defined.
16214
d1dff226
AH
162152017-01-18 Alan Hayward <alan.hayward@arm.com>
16216
16217 * remote.c (struct cached_reg): Change data into a pointer.
16218 * (stop_reply_dtr): Free data pointers before deleting vector.
16219 (process_stop_reply): Likewise.
16220 (remote_parse_stop_reply): Allocate space for data
16221
9890e433
AH
162222017-01-18 Alan Hayward <alan.hayward@arm.com>
16223
16224 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
16225 MAX_REGISTER_SIZE.
16226 (amd64_pseudo_register_read_value): Likewise.
16227 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
16228 (store_register_using_P): Likewise.
16229 * regcache.c (regcache_xfer_part): Likewise.
16230
7a36499a
IR
162312017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
16232
16233 Split real and pseudo registers.
16234 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
16235 (sparc32_pseudo_regnum): New enum.
16236 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
16237 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
16238 (SPARC32_CP0_REGISTERS): New macro.
16239 (sparc32_pseudo_register_name): New function.
16240 (sparc32_register_name): Use sparc32_pseudo_register_name.
16241 (sparc32_pseudo_register_type): New function.
16242 (sparc32_register_type): Use sparc32_pseudo_register_type.
16243 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
16244 pseudo register numbers.
16245 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
16246 (SPARC64_CP0_REGISTERS): New macro.
16247 (sparc64_pseudo_register_name): New function.
16248 (sparc64_register_name): Use sparc64_pseudo_register_name.
16249 (sparc64_pseudo_register_type): New function.
16250 (sparc64_register_type): Use sparc64_pseudo_register_type.
16251 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
16252 pseudo register numbers.
16253 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
16254 sparc64_store_arguments): Handle pseudo register numbers.
16255
6f8976bf
YQ
162562017-01-13 Yao Qi <yao.qi@linaro.org>
16257
16258 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
16259 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
16260 output.
16261 (getpkt_or_notif_sane_1): Likewise.
16262
e4241ace
YQ
162632017-01-13 Yao Qi <yao.qi@linaro.org>
16264
16265 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
16266 of CC. Pass "-x c++-header" instead of "-x c".
16267
3015c064
SM
162682017-01-12 Simon Marchi <simon.marchi@ericsson.com>
16269
16270 * remote.c (remote_can_async_p): Update comment.
16271
fde1b17d
SM
162722017-01-12 Simon Marchi <simon.marchi@ericsson.com>
16273
16274 * linux-nat.c (linux_nat_can_async_p): Update comment.
16275
ca1ca08b
SM
162762017-01-12 Simon Marchi <simon.marchi@ericsson.com>
16277
16278 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
16279
4ad2da73
SM
162802017-01-11 Simon Marchi <simon.marchi@ericsson.com>
16281
16282 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
16283
c8b23b3f
TT
162842017-01-10 Tom Tromey <tom@tromey.com>
16285
16286 * python/py-type.c (typy_legacy_template_argument): Update.
16287 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
16288 ~demangle_parse_info): Declare new members.
16289 (cp_demangled_name_to_comp): Return unique_ptr.
16290 (cp_demangled_name_parse_free)
16291 (make_cleanup_cp_demangled_name_parse_free)
16292 (cp_new_demangle_parse_info): Remove.
16293 * cp-support.c (do_demangled_name_parse_free_cleanup)
16294 (make_cleanup_cp_demangled_name_parse_free): Remove.
16295 (inspect_type, cp_canonicalize_string_full)
16296 (cp_canonicalize_string): Update.
16297 (mangled_name_to_comp): Change return type.
16298 (cp_class_name_from_physname, method_name_from_physname)
16299 (cp_func_name, cp_remove_params): Update.
16300 * cp-name-parser.y (demangle_parse_info): New constructor, from
16301 cp_new_demangle_parse_info.
16302 (~demangle_parse_info): New destructor, from
16303 cp_demangled_name_parse_free.
16304 (cp_merge_demangle_parse_infos): Update.
16305 (cp_demangled_name_to_comp): Change return type.
16306
1ac32117
TT
163072017-01-10 Tom Tromey <tom@tromey.com>
16308
16309 * top.c (prevent_dont_repeat): Change return type.
16310 * python/python.c (execute_gdb_command): Use std::string.
16311 Update.
16312 * guile/guile.c (gdbscm_execute_gdb_command): Update.
16313 * command.h (prevent_dont_repeat): Change return type.
16314 * breakpoint.c (bpstat_do_actions_1): Update.
16315
0cf08227
TT
163162017-01-10 Tom Tromey <tom@tromey.com>
16317
16318 * value.h (scoped_value_mark::~scoped_value_mark): Call
16319 free_to_mark.
16320 (scoped_value_mark::free_to_mark): New method.
16321 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
16322 scoped_value_mark.
16323
eb115069
TT
163242017-01-10 Tom Tromey <tom@tromey.com>
16325
16326 * python/py-value.c (valpy_dereference, valpy_referenced_value)
16327 (valpy_reference_value, valpy_const_value, valpy_get_address)
16328 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
16329 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
16330 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
16331 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
16332 scoped_value_mark.
16333 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
16334 * value.h (scoped_value_mark): New class.
16335
906768f9
TT
163362017-01-10 Tom Tromey <tom@tromey.com>
16337
16338 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
16339 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
16340 * psymtab.c (discard_psymtabs_upto): Remove.
16341 (make_cleanup_discard_psymtabs): Remove.
16342 (struct psymtab_state): Remove.
16343
bef155c3
TT
163442017-01-10 Tom Tromey <tom@tromey.com>
16345
16346 * record-full.c (record_full_save_cleanups): Remove.
16347 (record_full_save): Use gdb::unlinker.
16348 * gcore.c (do_bfd_delete_cleanup): Remove.
16349 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
16350 cleanups.
16351 * dwarf2read.c (unlink_if_set): Remove.
16352 (write_psymtabs_to_index): Use gdb::unlinker.
16353 * common/gdb_unlinker.h: New file.
16354
192b62ce
TT
163552017-01-10 Tom Tromey <tom@tromey.com>
16356
16357 * windows-tdep.c (windows_xfer_shared_library): Update.
16358 * windows-nat.c (windows_make_so): Update.
16359 * utils.h (make_cleanup_bfd_unref): Remove.
16360 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
16361 * symfile.h (symfile_bfd_open)
16362 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
16363 * symfile.c (read_symbols, symbol_file_add)
16364 (separate_debug_file_exists): Update.
16365 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
16366 (generic_load, reread_symbols): Update.
16367 * symfile-mem.c (symbol_file_add_from_memory): Update.
16368 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
16369 (spu_symbol_file_add_from_memory): Update.
16370 * solist.h (struct target_so_ops) <bfd_open>: Return
16371 gdb_bfd_ref_ptr.
16372 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
16373 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
16374 gdb_bfd_ref_ptr.
16375 (solib_map_sections, reload_shared_libraries_1): Update.
16376 * solib-svr4.c (enable_break): Update.
16377 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
16378 * solib-frv.c (enable_break2): Update.
16379 * solib-dsbt.c (enable_break): Update.
16380 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
16381 gdb_bfd_ref_ptr.
16382 (darwin_solib_get_all_image_info_addr_at_init): Update.
16383 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
16384 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
16385 * record-full.c (record_full_save): Update.
16386 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
16387 * procfs.c (insert_dbx_link_bpt_in_file): Update.
16388 * minidebug.c (find_separate_debug_file_in_section): Return
16389 gdb_bfd_ref_ptr.
16390 * machoread.c (macho_add_oso_symfile): Change abfd to
16391 gdb_bfd_ref_ptr.
16392 (macho_symfile_read_all_oso): Update.
16393 (macho_check_dsym): Return gdb_bfd_ref_ptr.
16394 (macho_symfile_read): Update.
16395 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
16396 (jit_bfd_try_read_symtab): Update.
16397 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
16398 (gdb_bfd_openw, gdb_bfd_openr_iovec)
16399 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
16400 gdb_bfd_ref_ptr.
16401 (gdb_bfd_ref_policy): New struct.
16402 (gdb_bfd_ref_ptr): New typedef.
16403 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
16404 (gdb_bfd_openw, gdb_bfd_openr_iovec)
16405 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
16406 gdb_bfd_ref_ptr.
16407 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
16408 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
16409 (gcore_command): Update.
16410 * exec.c (exec_file_attach): Update.
16411 * elfread.c (elf_symfile_read): Update.
16412 * dwarf2read.c (dwarf2_get_dwz_file): Update.
16413 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
16414 (open_and_init_dwo_file): Update.
16415 (open_dwp_file): Return gdb_bfd_ref_ptr.
16416 (open_and_init_dwp_file): Update.
16417 * corelow.c (core_open): Update.
16418 * compile/compile-object-load.c (compile_object_load): Update.
16419 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
16420 * coffread.c (coff_symfile_read): Update.
16421 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
16422 gdb_bfd_ref_ptr. Rename.
16423 (dump_bfd_file, restore_command): Update.
16424 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
16425 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
16426 (find_separate_debug_file_by_buildid): Update.
16427
50315b21
TT
164282017-01-10 Tom Tromey <tom@tromey.com>
16429
16430 * common/gdb_ref_ptr.h: New file.
16431 * python/py-ref.h (struct gdbpy_ref_policy): New.
16432 (gdbpy_ref): Now a typedef.
16433
fc4007c9
TT
164342017-01-10 Tom Tromey <tom@tromey.com>
16435
16436 * utils.h (make_cleanup_htab_delete): Don't declare.
16437 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
16438 Remove.
16439 * linespec.c (decode_compound_collector): Add constructor,
16440 destructor.
16441 (lookup_prefix_sym): Remove cleanup.
16442 (symtab_collector): Add constructor, destructor.
16443 (collect_symtabs_from_filename): Remove cleanup.
16444 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
16445 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
16446 Use htab_up.
16447 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
16448 * dwarf2read.c (dw2_expand_symtabs_matching)
16449 (dw2_map_symbol_filenames, dwarf_decode_macros)
16450 (write_psymtabs_to_index): Use htab_up.
16451 * dwarf2loc.c (func_verify_no_selftailcall)
16452 (call_site_find_chain_1, func_verify_no_selftailcall)
16453 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
16454 std::vector, gdb::unique_xmalloc_ptr.
16455 (call_sitep): Remove typedef.
16456 (dwarf2_locexpr_baton_eval): Remove unused variable.
16457
8dbcee67
TT
164582017-01-10 Tom Tromey <tom@tromey.com>
16459
16460 * python/python-internal.h (make_cleanup_py_decref)
16461 (make_cleanup_py_xdecref): Don't declare.
16462 * python/py-utils.c (py_decref, make_cleanup_py_decref)
16463 (py_xdecref, make_cleanup_py_xdecref): Remove.
16464
13df46cc
TT
164652017-01-10 Tom Tromey <tom@tromey.com>
16466
16467 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
16468 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
16469
06fc9bf7
TT
164702017-01-10 Tom Tromey <tom@tromey.com>
16471
16472 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
16473
830a4934
TT
164742017-01-10 Tom Tromey <tom@tromey.com>
16475
16476 * python/py-utils.c (unicode_to_encoded_string)
16477 (python_string_to_target_string)
16478 (python_string_to_target_python_string)
16479 (python_string_to_host_string, gdbpy_obj_to_string)
16480 (get_addr_from_python): Use gdbpy_ref.
16481
4586d543
TT
164822017-01-10 Tom Tromey <tom@tromey.com>
16483
16484 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
16485 gdbpy_ref.
16486
59876f8f
TT
164872017-01-10 Tom Tromey <tom@tromey.com>
16488
16489 * python/python.c (eval_python_command, gdbpy_decode_line)
16490 (gdbpy_run_events, gdbpy_start_type_printers)
16491 (gdbpy_apply_type_printers): Use gdbpy_ref.
16492
97d83487
TT
164932017-01-10 Tom Tromey <tom@tromey.com>
16494
16495 * python/py-param.c (get_doc_string, compute_enum_values): Use
16496 gdbpy_ref.
16497
9205649a
TT
164982017-01-10 Tom Tromey <tom@tromey.com>
16499
16500 * python/py-inferior.c (find_thread_object, build_inferior_list):
16501 Use gdbpy_ref.
16502
74c49d45
TT
165032017-01-10 Tom Tromey <tom@tromey.com>
16504
16505 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
16506
16361ffb
TT
165072017-01-10 Tom Tromey <tom@tromey.com>
16508
16509 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
16510 gdbpy_ref.
16511
905f2cca
TT
165122017-01-10 Tom Tromey <tom@tromey.com>
16513
16514 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
16515 extra incref.
16516 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
16517 Use gdbpy_ref.
16518
64081434
TT
165192017-01-10 Tom Tromey <tom@tromey.com>
16520
16521 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
16522 gdbpy_ref.
16523
59e9e831
TT
165242017-01-10 Tom Tromey <tom@tromey.com>
16525
16526 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
16527 decref results of PyArg_ParseTupleAndKeywords.
16528
9de10f6d
TT
165292017-01-10 Tom Tromey <tom@tromey.com>
16530
16531 * python/python.c (python_run_simple_file): Use
16532 unique_xmalloc_ptr, gdbpy_ref.
16533
2bd5759d
TT
165342017-01-10 Tom Tromey <tom@tromey.com>
16535
16536 * python/py-prettyprint.c (print_stack_unless_memory_error)
16537 (print_string_repr, print_children): Use gdbpy_ref.
16538 (dummy_python_frame): New class.
16539 (dummy_python_frame::dummy_python_frame): Rename from
16540 push_dummy_python_frame.
16541 (py_restore_tstate): Remove.
16542
3b4e0e01
TT
165432017-01-10 Tom Tromey <tom@tromey.com>
16544
16545 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
16546
17a22718
TT
165472017-01-10 Tom Tromey <tom@tromey.com>
16548
16549 * python/python.c (ensure_python_env, restore_python_env):
16550 Remove.
16551 * python/python-internal.h (ensure_python_env): Don't declare.
16552 * varobj.h (varobj_ensure_python_env): Don't declare.
16553 * varobj.c (varobj_ensure_python_env): Remove.
16554
68cdc557
TT
165552017-01-10 Tom Tromey <tom@tromey.com>
16556
16557 * varobj.c (varobj_value_get_print_value): Use
16558 gdbpy_enter_varobj.
16559
1eba6383
TT
165602017-01-10 Tom Tromey <tom@tromey.com>
16561
16562 * python/py-prettyprint.c (print_string_repr, print_children):
16563 Update.
16564 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
16565 of "encoding".
16566 * varobj.c (varobj_value_get_print_value): Update.
16567 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
16568
bde7b3e3
TT
165692017-01-10 Tom Tromey <tom@tromey.com>
16570
16571 * varobj.c (varobj_get_display_hint)
16572 (dynamic_varobj_has_child_method, install_new_value_visualizer)
16573 (varobj_set_visualizer, free_variable): Use
16574 gdbpy_enter_varobj.
16575
a7785f8c
TT
165762017-01-10 Tom Tromey <tom@tromey.com>
16577
16578 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
16579 (do_finish_initialization): New function. Use gdbpy_ref.
16580 (gdbpy_finish_initialization): Use gdbpy_enter. Call
16581 do_finish_initialization.
16582
2865bfce
TT
165832017-01-10 Tom Tromey <tom@tromey.com>
16584
16585 * python/py-param.c (get_set_value, get_show_value): Use
16586 gdbpy_enter, gdbpy_ref.
16587
0e9dcc75
TT
165882017-01-10 Tom Tromey <tom@tromey.com>
16589
16590 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
16591
12a5cedd
TT
165922017-01-10 Tom Tromey <tom@tromey.com>
16593
16594 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
16595
788f2586
TT
165962017-01-10 Tom Tromey <tom@tromey.com>
16597
16598 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
16599 Use gdbpy_enter_varobj.
16600
6cd67bea
TT
166012017-01-10 Tom Tromey <tom@tromey.com>
16602
16603 * varobj.c (gdbpy_enter_varobj): New constructor.
16604 * python/python-internal.h (gdbpy_enter_varobj): New class.
16605 * python/py-varobj.c (py_varobj_get_iterator): Use
16606 gdbpy_enter_varobj.
16607
14b122bf
TT
166082017-01-10 Tom Tromey <tom@tromey.com>
16609
16610 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
16611 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
16612 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
16613 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
16614 unique_xmalloc_ptr.
16615 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
16616
bf1ca3b9
TT
166172017-01-10 Tom Tromey <tom@tromey.com>
16618
16619 * python/py-xmethods.c (invoke_match_method): Use
16620 gdbpy_ref.
16621
572a5524
TT
166222017-01-10 Tom Tromey <tom@tromey.com>
16623
16624 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
16625 gdbpy_enter, gdbpy_ref.
16626
396a78b6
TT
166272017-01-10 Tom Tromey <tom@tromey.com>
16628
16629 * python/python.c (python_interactive_command): Use gdbpy_enter.
16630
a88b13c7
TT
166312017-01-10 Tom Tromey <tom@tromey.com>
16632
16633 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
16634 gdbpy_ref.
16635
e9f0c363
TT
166362017-01-10 Tom Tromey <tom@tromey.com>
16637
16638 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
16639 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
16640
6349f452
TT
166412017-01-10 Tom Tromey <tom@tromey.com>
16642
16643 * utils.h (htab_deleter): New struct.
16644 (htab_up): New typedef.
16645 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
16646 gdbpy_enter, gdbpy_ref, htab_up.
16647
c0171de6
TT
166482017-01-10 Tom Tromey <tom@tromey.com>
16649
16650 * python/py-unwind.c (pending_frame_invalidate): Remove.
16651 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
16652
f18e226f
TT
166532017-01-10 Tom Tromey <tom@tromey.com>
16654
16655 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
16656 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
16657
c57af3f1
TT
166582017-01-10 Tom Tromey <tom@tromey.com>
16659
16660 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
16661
60e600ec
TT
166622017-01-10 Tom Tromey <tom@tromey.com>
16663
16664 * python/python.c (gdbpy_eval_from_control_command)
16665 (gdbpy_source_script, gdbpy_run_events)
16666 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
16667 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
16668 gdbpy_enter.
16669
bf7da5b0
TT
166702017-01-10 Tom Tromey <tom@tromey.com>
16671
16672 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
16673
2d38bced
TT
166742017-01-10 Tom Tromey <tom@tromey.com>
16675
16676 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
16677
07bc7329
TT
166782017-01-10 Tom Tromey <tom@tromey.com>
16679
16680 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
16681 (python_on_inferior_call_pre, python_on_inferior_call_post)
16682 (python_on_memory_change, python_on_register_change)
16683 (python_inferior_exit, python_new_objfile, add_thread_object)
16684 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
16685
6e7c365e
TT
166862017-01-10 Tom Tromey <tom@tromey.com>
16687
16688 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
16689 (bpfinishpy_handle_exit): Use gdbpy_enter.
16690
6ba0cd40
TT
166912017-01-10 Tom Tromey <tom@tromey.com>
16692
16693 * python/py-cmd.c (cmdpy_destroyer)
16694 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
16695 gdbpy_enter.
16696
de2dc875
TT
166972017-01-10 Tom Tromey <tom@tromey.com>
16698
16699 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
16700 gdbpy_enter.
16701 (gdbpy_breakpoint_has_cond): Likewise.
16702
4ecee2c4
TT
167032017-01-10 Tom Tromey <tom@tromey.com>
16704
16705 * python/python.c (gdbpy_enter): New constructor.
16706 (~gdbpy_enter): New destructor.
16707 (restore_python_env, ensure_python_env): Rewrite.
16708 * python/python-internal.h (gdbpy_enter): New class.
16709
37fce74f
TT
167102017-01-10 Tom Tromey <tom@tromey.com>
16711
16712 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
16713
53a0cca3
TT
167142017-01-10 Tom Tromey <tom@tromey.com>
16715
16716 * python/py-value.c (value_has_field, get_field_flag)
16717 (get_field_type, valpy_getitem, convert_value_from_python): Use
16718 gdbpy_ref.
16719
ff3724f5
TT
167202017-01-10 Tom Tromey <tom@tromey.com>
16721
16722 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
16723 gdbpy_ref.
16724
0700aea5
TT
167252017-01-10 Tom Tromey <tom@tromey.com>
16726
16727 * python/py-prettyprint.c (search_pp_list)
16728 (find_pretty_printer_from_objfiles)
16729 (find_pretty_printer_from_progspace)
16730 (find_pretty_printer_from_gdb, find_pretty_printer)
16731 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
16732 gdbpy_ref.
16733
1bb44c9f
TT
167342017-01-10 Tom Tromey <tom@tromey.com>
16735
16736 * python/py-param.c (call_doc_function): Use gdbpy_ref.
16737
87ce03fd
TT
167382017-01-10 Tom Tromey <tom@tromey.com>
16739
16740 * python/py-linetable.c (build_line_table_tuple_from_pcs)
16741 (ltpy_get_all_source_lines): Use gdbpy_ref.
16742
ee0a3fb8
TT
167432017-01-10 Tom Tromey <tom@tromey.com>
16744
16745 * python/py-framefilter.c (extract_sym, extract_value)
16746 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
16747 gdbpy_ref.
16748
bf2a52fa
TT
167492017-01-10 Tom Tromey <tom@tromey.com>
16750
16751 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
16752
f59fe7f8
TT
167532017-01-10 Tom Tromey <tom@tromey.com>
16754
16755 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
16756
80bd970a
TT
167572017-01-10 Tom Tromey <tom@tromey.com>
16758
16759 * python/py-function.c (convert_values_to_python, fnpy_init): Use
16760 gdbpy_ref.
16761
d1b3de2e
TT
167622017-01-10 Tom Tromey <tom@tromey.com>
16763
16764 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
16765
3bb43384
TT
167662017-01-10 Tom Tromey <tom@tromey.com>
16767
16768 * python/py-type.c (convert_field, make_fielditem, typy_fields)
16769 (typy_range): Use gdbpy_ref.
16770
abf5651e
TT
167712017-01-10 Tom Tromey <tom@tromey.com>
16772
16773 * python/py-threadevent.c (create_thread_event_object): Use
16774 gdbpy_ref.
16775 * python/py-stopevent.c (create_stop_event_object): Simplify.
16776 (emit_stop_event): Use gdbpy_ref.
16777 * python/py-signalevent.c (create_signal_event_object): Use
16778 gdbpy_ref.
16779 * python/py-newobjfileevent.c (create_new_objfile_event_object)
16780 (emit_new_objfile_event, create_clear_objfiles_event_object)
16781 (emit_clear_objfiles_event): Use gdbpy_ref.
16782 * python/py-infevents.c (create_inferior_call_event_object)
16783 (create_register_changed_event_object)
16784 (create_memory_changed_event_object, emit_inferior_call_event)
16785 (emit_memory_changed_event, emit_register_changed_event): Use
16786 gdbpy_ref.
16787 * python/py-exitedevent.c (create_exited_event_object)
16788 (emit_exited_event): Use gdbpy_ref.
16789 * python/py-event.h (evpy_emit_event): Remove
16790 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
16791 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
16792 * python/py-continueevent.c (emit_continue_event): Use
16793 gdbpy_ref.
16794 * python/py-breakpoint.c (gdbpy_breakpoint_created)
16795 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
16796 gdbpy_ref.
16797 * python/py-bpevent.c (create_breakpoint_event_object): Use
16798 gdbpy_ref.
16799
a68ff33e
TT
168002017-01-10 Tom Tromey <tom@tromey.com>
16801
16802 * python/py-ref.h: New file.
16803
7becfd03
SM
168042017-01-10 Simon Marchi <simon.marchi@ericsson.com>
16805
16806 * cli-out.c (cli_ui_out::do_redirect): Change return type to
16807 void.
16808 * cli-out.h (cli_ui_out::do_redirect): Likewise.
16809 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
16810 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
16811 * ui-out.c (ui_out::redirect): Likewise.
16812 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
16813 * cli/cli-logging.c (set_logging_redirect): Update call site of
16814 ui_out::redirect.
16815 (handle_redirections): Likewise.
16816 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
16817 * top.c (execute_command_to_string): Likewise.
16818 * utils.c (do_ui_out_redirect_pop): Likewise.
16819
df294654
SM
168202017-01-10 Simon Marchi <simon.marchi@ericsson.com>
16821
16822 * stack.c (_initialize_stack): Update "frame" command help message.
16823
f5e6296e
IB
168242017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
16825
16826 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
16827
0e2d6fa6
YQ
168282017-01-06 Yao Qi <yao.qi@linaro.org>
16829
16830 * x86-linux-nat.h: Include gdb_proc_service.h.
16831
44d6d3f9
YQ
168322017-01-06 Yao Qi <yao.qi@linaro.org>
16833
16834 * ser-base.h: Include serial.h.
16835
656731fe
YQ
168362017-01-06 Yao Qi <yao.qi@linaro.org>
16837
16838 * ppc-linux-tdep.h: Include ppc-tdep.h.
16839
1ca8f924
YQ
168402017-01-06 Yao Qi <yao.qi@linaro.org>
16841
16842 * nat/amd64-linux-siginfo.h: Include signal.h.
16843
bc3008c4
YQ
168442017-01-06 Yao Qi <yao.qi@linaro.org>
16845
16846 * nat/aarch64-linux-hw-point.h: Include break-common.h.
16847
66c80d03
YQ
168482017-01-06 Yao Qi <yao.qi@linaro.org>
16849
16850 * mi/mi-parse.h: Include mi-cmds.h.
16851
051d2dda
YQ
168522017-01-06 Yao Qi <yao.qi@linaro.org>
16853
16854 * inf-loop.c: Don't include "target.h".
16855 * inf-loop.h: Include it here.
16856
8018d34f
YQ
168572017-01-06 Yao Qi <yao.qi@linaro.org>
16858
16859 * dfp.h: Include "dboulest.h" and "expression.h".
16860
c0b8369c
YQ
168612017-01-06 Yao Qi <yao.qi@linaro.org>
16862
16863 * ax-gdb.h: Include "ax.h".
16864
ad5cba2a
YQ
168652017-01-06 Yao Qi <yao.qi@linaro.org>
16866
16867 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
16868 with nat/gdb_ptrace.h.
16869
1c33cd7f
YQ
168702017-01-05 Yao Qi <yao.qi@linaro.org>
16871
16872 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
16873 new line.
16874 (mips64_fbsd_sigframe_init): Likewise.
16875
c988ac1d
JB
168762017-01-04 John Baldwin <jhb@FreeBSD.org>
16877
16878 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
16879 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
16880
b268007c
JB
168812017-01-04 John Baldwin <jhb@FreeBSD.org>
16882
16883 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
16884 * NEWS: Mention new FreeBSD/mips native configuration.
16885 * config/mips/fbsd.mh: New file.
16886 * configure.host: Add mips*-*-freebsd*.
16887 * mips-fbsd-nat.c: New file.
16888
387360da
JB
168892017-01-04 John Baldwin <jhb@FreeBSD.org>
16890
16891 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
16892 (ALLDEPFILES): Add mips-fbsd-tdep.c.
16893 * NEWS: Mention new FreeBSD/mips target.
16894 * configure.tgt: Add mips*-*-freebsd*.
16895 * mips-fbsd-tdep.c: New file.
16896 * mips-fbsd-tdep.h: New file.
16897
2aaaf250
YQ
168982017-01-04 Yao Qi <yao.qi@linaro.org>
16899
16900 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
16901 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
16902
61baf725
JB
169032017-01-01 Joel Brobecker <brobecker@adacore.com>
16904
6dbb839a 16905 Update copyright year range in all GDB files.
61baf725 16906
c113e7ff 169072017-01-01 Joel Brobecker <brobecker@adacore.com>
ce0db137 16908
c113e7ff 16909 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
ce0db137 16910
c113e7ff 16911For older changes see ChangeLog-2016.
c906108c
SS
16912\f
16913Local Variables:
16914mode: change-log
16915left-margin: 8
16916fill-column: 74
16917version-control: never
57da7796 16918coding: utf-8
c906108c 16919End:
This page took 2.746012 seconds and 4 git commands to generate.